* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: #f8fafc;
    color: #1f2937;
}

.navbar {
    background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%) !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.navbar-toggler {
    border: none;
    padding: 0.25rem 0.5rem;
}

.navbar-toggler:focus {
    box-shadow: 0 0 0 0.2rem rgba(37, 99, 235, 0.25);
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28255, 255, 255, 0.9%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

.card {
    border: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
    border-radius: 12px;
}

.card.h-100 {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.card .d-flex {
    align-items: center;
}

@media (max-width: 768px) {
    .card .d-flex {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .card .align-self-center {
        margin-top: 0.5rem;
    }
    
    .card-header .d-flex {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .card-header .d-flex > div:last-child {
        width: 100%;
        display: flex;
        justify-content: center;
        gap: 0.5rem;
    }
}

.card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.table th {
    background-color: #f3f4f6;
    border-bottom: 2px solid #e5e7eb;
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #374151;
}

.table td {
    border-bottom: 1px solid #e5e7eb;
    font-size: 14px;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.02);
}

.btn {
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.alert {
    border: none;
    border-radius: 12px;
    font-size: 14px;
}

.alert-success {
    background: linear-gradient(135deg, #dcfce7 0%, #bbf7d0 100%);
    color: #166534;
}

.alert-danger {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
    color: #991b1b;
}

.alert-info {
    background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
    color: #0c4a6e;
}

.alert-warning {
    background: linear-gradient(135deg, #fffbeb 0%, #fed7aa 100%);
    color: #92400e;
}

.badge {
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 6px;
}

.pagination .page-link {
    color: #2563eb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    margin: 0 2px;
}

.pagination .page-item.active .page-link {
    background-color: #2563eb;
    border-color: #2563eb;
}

.pagination .page-link:hover {
    background-color: #eef2ff;
    border-color: #2563eb;
}

.form-control, .form-select {
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    padding: 10px 12px;
    font-size: 14px;
}

.form-control:focus, .form-select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.table-responsive {
    border-radius: 12px;
    overflow: hidden;
}

.card-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-bottom: 1px solid #e5e7eb;
    font-weight: 600;
    border-radius: 12px 12px 0 0 !important;
}

.text-success {
    color: #16a34a !important;
}

.text-danger {
    color: #dc2626 !important;
}

.text-info {
    color: #0284c7 !important;
}

.text-warning {
    color: #d97706 !important;
}

.text-muted {
    color: #6b7280 !important;
}

.bg-primary {
    background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%) !important;
}

.bg-success {
    background: linear-gradient(135deg, #16a34a 0%, #22c55e 100%) !important;
}

.bg-danger {
    background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%) !important;
}

.bg-info {
    background: linear-gradient(135deg, #0284c7 0%, #06b6d4 100%) !important;
}

.bg-warning {
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%) !important;
}

.container-fluid {
    max-width: 1400px;
}

@media (max-width: 768px) {
    .table-responsive {
        font-size: 12px;
    }
    
    .btn {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .card-body {
        padding: 16px;
    }
    
    .row.g-3 {
        --bs-gutter-x: 1rem;
        --bs-gutter-y: 1rem;
    }
    
    .col-sm-12 {
        margin-bottom: 1rem;
    }
    
    .card h3 {
        font-size: 1.25rem;
    }
    
    .card .card-title {
        font-size: 0.875rem;
    }
    
    .d-flex.justify-content-between.align-items-center {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .pagination .page-link {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .form-label {
        font-size: 0.875rem;
    }
    
    .card-header h5 {
        font-size: 1rem;
    }
    
    /* Mobile improvements for header buttons */
    .d-flex.justify-content-between.align-items-center > div {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        justify-content: center;
    }
    
    .d-flex.justify-content-between.align-items-center > div .btn {
        margin-right: 0;
        margin-bottom: 0.25rem;
    }
    
    /* Mobile improvements for sync buttons */
    .d-flex.flex-wrap.gap-2 {
        flex-direction: column;
        align-items: stretch;
    }
    
    .d-flex.flex-wrap.gap-2 .btn {
        margin-right: 0;
        margin-bottom: 0.5rem;
        width: 100%;
    }
}

@media (max-width: 576px) {
    .row.g-3 {
        --bs-gutter-x: 0.75rem;
        --bs-gutter-y: 0.75rem;
    }
    
    .card h3 {
        font-size: 1.1rem;
    }
    
    .card .card-title {
        font-size: 0.8rem;
    }
    
    .navbar-brand {
        font-size: 1.25rem;
    }
    
    .nav-link {
        padding: 0.25rem 0.5rem;
        font-size: 0.875rem;
    }
    
    .btn-lg {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .container-fluid {
        padding-left: 0.5rem;
        padding-right: 0.5rem;
    }
    
    .mt-4 {
        margin-top: 1rem !important;
    }
    
    .d-grid {
        gap: 0.5rem;
    }
    
    .form-control, .form-select {
        font-size: 0.875rem;
        padding: 0.375rem 0.75rem;
    }
    
    .btn {
        padding: 0.375rem 0.75rem;
        font-size: 0.875rem;
    }
    
    .table th, .table td {
        padding: 0.5rem;
    }
    
    /* Further improvements for very small screens */
    .d-flex.justify-content-between.align-items-center > div {
        flex-direction: column;
        width: 100%;
    }
    
    .d-flex.justify-content-between.align-items-center > div .btn {
        width: 100%;
        margin-bottom: 0.5rem;
    }
    
    /* Sync button improvements for very small screens */
    .d-flex.flex-wrap.gap-2 .btn {
        padding: 0.5rem;
        font-size: 0.875rem;
    }
}