/* ═══════════════════════════════════════════════════════════
   VEO Studio Admin Panel — Premium Dark Theme
   ═══════════════════════════════════════════════════════════ */

:root {
    --bg-primary: #0f1117;
    --bg-secondary: #1a1d27;
    --bg-card: #1e2132;
    --bg-card-hover: #252840;
    --bg-input: #161824;
    --bg-modal: #1e2132;

    --border: #2a2d3e;
    --border-light: #33364a;
    --border-focus: #6366f1;

    --text-primary: #f1f5f9;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --text-heading: #e2e8f0;

    --accent: #6366f1;
    --accent-hover: #818cf8;
    --accent-glow: rgba(99, 102, 241, 0.25);

    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.12);
    --warning: #f59e0b;
    --warning-bg: rgba(245, 158, 11, 0.12);
    --danger: #ef4444;
    --danger-bg: rgba(239, 68, 68, 0.12);
    --info: #3b82f6;
    --info-bg: rgba(59, 130, 246, 0.12);
    --purple: #8b5cf6;
    --purple-bg: rgba(139, 92, 246, 0.12);

    --radius-sm: 6px;
    --radius: 10px;
    --radius-lg: 14px;
    --radius-xl: 18px;

    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.35);
    --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.4);
    --shadow-glow: 0 0 20px var(--accent-glow);

    --sidebar-width: 220px;
    --navbar-height: 60px;

    --transition: 0.2s ease;
}

/* ═══════════════ RESET & BASE ═══════════════ */

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 14px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.5;
    overflow-x: hidden;
    min-height: 100vh;
}

.page {
    display: none;
}

.page.active {
    display: block;
}

/* ═══════════════ SCROLLBAR ═══════════════ */

::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* ═══════════════ LOGIN PAGE ═══════════════ */

.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(99, 102, 241, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(139, 92, 246, 0.06) 0%, transparent 50%),
        var(--bg-primary);
}

.login-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 40px 36px;
    width: 100%;
    max-width: 420px;
    box-shadow: var(--shadow-lg);
    animation: fadeUp 0.5s ease;
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-logo {
    text-align: center;
    margin-bottom: 32px;
}

.logo-icon {
    font-size: 48px;
    margin-bottom: 12px;
    filter: drop-shadow(0 0 16px var(--accent-glow));
}

.login-logo h1 {
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent), var(--purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-subtitle {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-top: 4px;
}

/* ═══════════════ FORMS ═══════════════ */

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-group input::placeholder {
    color: var(--text-muted);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.form-row-3 {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
}

.form-group.checkbox-group {
    display: flex;
    align-items: center;
    gap: 8px;
}

.form-group.checkbox-group input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--accent);
}

.form-group.checkbox-group label {
    margin-bottom: 0;
    color: var(--text-primary);
}

.form-section-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--accent);
    margin: 16px 0 8px 0;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--border);
}

/* Date input calendar icon - dark theme */
.form-group input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(0.8);
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s;
}

.form-group input[type="date"]::-webkit-calendar-picker-indicator:hover {
    background: rgba(99, 102, 241, 0.2);
}

.form-group input[type="date"] {
    color-scheme: dark;
}

/* Provider list in Edit User modal */
.providers-list {
    margin-bottom: 12px;
}

.provider-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 12px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    margin-bottom: 6px;
}

.provider-email {
    font-size: 0.9rem;
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 12px;
}

.provider-assign-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 12px;
}

.provider-assign-row select {
    flex: 1;
    padding: 8px 12px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.9rem;
}

.provider-assign-row select:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Searchable provider dropdown */
.provider-search-container input {
    width: 100%;
    padding: 10px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-size: 0.9rem;
    font-family: inherit;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.provider-search-container input:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.provider-search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    max-height: 200px;
    overflow-y: auto;
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius);
    margin-top: 4px;
    z-index: 200;
    box-shadow: var(--shadow-lg);
}

.provider-search-item {
    padding: 10px 14px;
    cursor: pointer;
    font-size: 0.88rem;
    color: var(--text-primary);
    transition: background 0.15s;
    border-bottom: 1px solid var(--border);
}

.provider-search-item:last-child {
    border-bottom: none;
}

.provider-search-item:hover {
    background: rgba(99, 102, 241, 0.12);
    color: var(--accent-hover);
}

.provider-search-item.no-result {
    color: var(--text-muted);
    cursor: default;
    font-style: italic;
}

.provider-search-item.no-result:hover {
    background: transparent;
    color: var(--text-muted);
}

/* New provider form */
.new-provider-form {
    border: 1px dashed var(--border-light);
    border-radius: var(--radius);
    padding: 14px;
    margin-top: 4px;
    margin-bottom: 8px;
    background: rgba(99, 102, 241, 0.03);
}

/* Provider search result tags */
.provider-search-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.provider-assigned-tag {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-style: italic;
    margin-left: 8px;
    white-space: nowrap;
}

.provider-free-tag {
    font-size: 0.72rem;
    color: var(--success);
    font-weight: 600;
    margin-left: 8px;
    white-space: nowrap;
}

.error-msg {
    background: var(--danger-bg);
    color: var(--danger);
    padding: 10px 14px;
    border-radius: var(--radius);
    border: 1px solid rgba(239, 68, 68, 0.2);
    font-size: 0.9rem;
    margin-top: 16px;
    text-align: center;
}

/* ═══════════════ BUTTONS ═══════════════ */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 9px 18px;
    border: none;
    border-radius: var(--radius);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}

.btn:active {
    transform: scale(0.97);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), #818cf8);
    color: white;
    box-shadow: 0 2px 8px var(--accent-glow);
}

.btn-primary:hover {
    box-shadow: var(--shadow-glow);
    filter: brightness(1.1);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-success:hover {
    filter: brightness(1.15);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    filter: brightness(1.15);
}

.btn-warning {
    background: var(--warning);
    color: #1a1d27;
}

.btn-warning:hover {
    filter: brightness(1.15);
}

.btn-accent {
    background: var(--bg-card);
    color: var(--accent);
    border: 1px solid var(--border);
}

.btn-accent:hover {
    background: var(--bg-card-hover);
    border-color: var(--accent);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 0.82rem;
}

.btn-xs {
    padding: 4px 10px;
    font-size: 0.78rem;
    border-radius: var(--radius-sm);
}

.btn-full {
    width: 100%;
}

.btn-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ═══════════════ NAVBAR ═══════════════ */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--navbar-height);
    background: rgba(15, 17, 23, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 100;
}

.nav-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.hamburger {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.4rem;
    cursor: pointer;
    padding: 4px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.brand-icon {
    font-size: 1.4rem;
}

.brand-text {
    font-size: 1.1rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent), var(--purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-user {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* ═══════════════ SIDEBAR ═══════════════ */

.sidebar {
    position: fixed;
    top: var(--navbar-height);
    left: 0;
    bottom: 0;
    width: var(--sidebar-width);
    z-index: 90;
}

.sidebar-overlay {
    display: none;
}

.sidebar-content {
    height: 100%;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    padding: 16px 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.sidebar-tab {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 12px 14px;
    border: none;
    border-radius: var(--radius);
    background: transparent;
    color: var(--text-secondary);
    font-family: inherit;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition);
    text-align: left;
}

.sidebar-tab:hover {
    background: rgba(99, 102, 241, 0.08);
    color: var(--text-primary);
}

.sidebar-tab.active {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(139, 92, 246, 0.1));
    color: var(--accent-hover);
    font-weight: 600;
    border-left: 3px solid var(--accent);
}

.tab-icon {
    font-size: 1.15rem;
}

/* ═══════════════ MAIN CONTENT ═══════════════ */

.main-content {
    margin-left: var(--sidebar-width);
    margin-top: var(--navbar-height);
    padding: 24px;
    min-height: calc(100vh - var(--navbar-height));
}

.tab-content {
    display: none;
    animation: fadeIn 0.25s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.content-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}

.content-header h2 {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-heading);
}

.header-actions {
    display: flex;
    gap: 8px;
}

/* ═══════════════ STAT CARDS ═══════════════ */

.stat-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px;
    text-align: center;
    transition: all var(--transition);
}

.stat-card:hover {
    border-color: var(--border-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.stat-value {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.2;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 4px;
    font-weight: 500;
}

.stat-blue .stat-value {
    color: var(--info);
}

.stat-green .stat-value {
    color: var(--success);
}

.stat-yellow .stat-value {
    color: var(--warning);
}

.stat-red .stat-value {
    color: var(--danger);
}

.stat-purple .stat-value {
    color: var(--purple);
}

.stat-cyan .stat-value {
    color: #06b6d4;
}

/* ═══════════════ DASHBOARD ═══════════════ */

.stat-cards-dashboard {
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
}

.dash-section {
    margin-bottom: 28px;
}

.dash-section-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-secondary);
    margin-bottom: 12px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--border);
    background: linear-gradient(90deg, rgba(99, 102, 241, 0.06), transparent);
    padding: 8px 12px;
    border-radius: var(--radius) var(--radius) 0 0;
}

.row-highlight {
    background: rgba(99, 102, 241, 0.06) !important;
    border-left: 3px solid var(--accent);
}

.row-highlight td:first-child {
    padding-left: 13px;
}

.badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    vertical-align: middle;
    margin-left: 6px;
}

.badge-accent {
    background: var(--accent);
    color: #fff;
}

.stat-inline {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.85rem;
}

.stat-inline-blue {
    background: rgba(59, 130, 246, 0.12);
    color: var(--info);
}

.stat-inline-purple {
    background: rgba(139, 92, 246, 0.12);
    color: var(--purple);
}

.text-muted {
    color: var(--text-muted);
}

/* Badge pills for Days Left column */
.badge-pill {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.3px;
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--success);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--warning);
}

.badge-danger {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
}

.badge-accent {
    background: var(--accent);
    color: #fff;
}

/* ═══════════════ FILTER BAR ═══════════════ */

.filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.filter-input {
    flex: 1;
    min-width: 200px;
    padding: 9px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-size: 0.9rem;
    font-family: inherit;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.filter-input:focus {
    outline: none;
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.filter-input::placeholder {
    color: var(--text-muted);
}

.filter-select {
    padding: 9px 14px;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
    min-width: 120px;
}

.filter-select:focus {
    outline: none;
    border-color: var(--border-focus);
}

.filter-select option {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* ═══════════════ DATA TABLES ═══════════════ */

.table-wrapper {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--bg-card);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}

.data-table thead th {
    background: var(--bg-secondary);
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    padding: 12px 14px;
    text-align: left;
    border-bottom: 2px solid var(--border);
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 5;
    user-select: none;
}

.data-table thead th.sortable {
    cursor: pointer;
}

.data-table thead th.sortable:hover {
    color: var(--accent);
}

.data-table thead th.sort-asc::after {
    content: ' ▲';
    font-size: 0.7rem;
}

.data-table thead th.sort-desc::after {
    content: ' ▼';
    font-size: 0.7rem;
}

.data-table tbody tr {
    border-bottom: 1px solid var(--border);
    transition: background var(--transition);
}

.data-table tbody tr:hover {
    background: rgba(99, 102, 241, 0.04);
}

.data-table tbody tr:last-child {
    border-bottom: none;
}

.data-table tbody td {
    padding: 10px 14px;
    white-space: nowrap;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.data-table .actions-cell {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

/* ═══════════════ STATUS BADGES ═══════════════ */

.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: capitalize;
}

.badge-active {
    background: var(--success-bg);
    color: var(--success);
}

.badge-pending {
    background: var(--warning-bg);
    color: var(--warning);
}

.badge-suspended {
    background: var(--danger-bg);
    color: var(--danger);
}

.badge-claimed {
    background: var(--info-bg);
    color: var(--info);
}

.badge-unclaimed {
    background: var(--purple-bg);
    color: var(--purple);
}

.badge-expired {
    background: var(--danger-bg);
    color: var(--danger);
}

.badge-admin {
    background: var(--purple-bg);
    color: var(--purple);
}

.badge-manual {
    background: var(--info-bg);
    color: var(--info);
}

.badge-auto {
    background: var(--success-bg);
    color: var(--success);
}

.badge-user {
    background: rgba(148, 163, 184, 0.12);
    color: var(--text-secondary);
}

/* ═══════════════ EMPTY & LOADING STATES ═══════════════ */

.empty-state,
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-icon {
    font-size: 3rem;
    margin-bottom: 12px;
    opacity: 0.5;
}

.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--border);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
    margin-bottom: 12px;
}

/* ═══════════════ MODALS ═══════════════ */

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 200;
    padding: 20px;
    animation: fadeIn 0.15s ease;
}

.modal-overlay.visible {
    display: flex;
}

.modal {
    background: var(--bg-modal);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--shadow-lg);
    animation: modalIn 0.25s ease;
}

@keyframes modalIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }

    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 24px;
    border-bottom: 1px solid var(--border);
}

.modal-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-heading);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    transition: all var(--transition);
}

.modal-close:hover {
    color: var(--danger);
    background: var(--danger-bg);
}

.modal-body {
    padding: 20px 24px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 14px 24px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

/* ═══════════════ TOASTS ═══════════════ */

#toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 300;
    display: flex;
    flex-direction: column;
    gap: 8px;
    pointer-events: none;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 12px 18px;
    font-size: 0.9rem;
    box-shadow: var(--shadow-lg);
    animation: toastIn 0.3s ease;
    pointer-events: auto;
    max-width: 380px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.toast.toast-success {
    border-left: 3px solid var(--success);
}

.toast.toast-error {
    border-left: 3px solid var(--danger);
}

.toast.toast-info {
    border-left: 3px solid var(--info);
}

.toast-exit {
    animation: toastOut 0.3s ease forwards;
}

@keyframes toastIn {
    from {
        opacity: 0;
        transform: translateX(40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes toastOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        transform: translateX(40px);
    }
}

/* ═══════════════ ROW HIGHLIGHTS ═══════════════ */

.row-expiring {
    background: rgba(245, 158, 11, 0.06) !important;
}

.row-expired {
    background: rgba(239, 68, 68, 0.06) !important;
}

/* ═══════════════ RESPONSIVE ═══════════════ */

@media (max-width: 1024px) {
    .hide-tablet {
        display: none !important;
    }
}

@media (max-width: 768px) {
    .hide-mobile {
        display: none !important;
    }

    .hamburger {
        display: block;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 100%;
        z-index: 150;
        pointer-events: none;
        transform: translateX(-100%);
        transition: transform 0s;
    }

    .sidebar.open {
        pointer-events: auto;
        transform: translateX(0);
    }

    .sidebar.open .sidebar-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: 1;
    }

    .sidebar.open .sidebar-content {
        position: relative;
        z-index: 2;
        width: var(--sidebar-width);
        padding-top: calc(var(--navbar-height) + 16px);
        box-shadow: var(--shadow-lg);
    }

    .main-content {
        margin-left: 0;
        padding: 16px;
    }

    .content-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .stat-cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .filter-bar {
        flex-direction: column;
    }

    .filter-input,
    .filter-select {
        width: 100%;
    }

    .form-row,
    .form-row-3 {
        grid-template-columns: 1fr;
    }

    .modal {
        max-height: 95vh;
        margin: 10px;
    }

    .nav-user {
        display: none;
    }

    #toast-container {
        top: auto;
        bottom: 20px;
        right: 10px;
        left: 10px;
    }

    .toast {
        max-width: 100%;
    }
}

@media (max-width: 480px) {
    .stat-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .stat-card {
        padding: 12px 8px;
    }

    .stat-value {
        font-size: 1.3rem;
    }

    .content-header h2 {
        font-size: 1.2rem;
    }

    .header-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

/* ═══════════════ PAGINATION ═══════════════ */

.pagination-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-top: 16px;
    padding: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.pagination-info {
    font-size: 0.85rem;
    color: var(--text-secondary);
    font-weight: 500;
}

.pagination-controls .btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.pagination-controls .btn:not(:disabled):hover {
    background: rgba(99, 102, 241, 0.12);
    color: var(--accent-hover);
}

/* -------------- DASHBOARD CHARTS --------------- */

.dash-charts-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
    margin-bottom: 1.5rem;
}

.dash-chart-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem;
    height: 320px;
    position: relative;
}

.dash-chart-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 0.75rem 0;
}

.dash-chart-card canvas {
    max-height: 260px !important;
    width: 100% !important;
}

@media (max-width: 768px) {
    .dash-charts-row {
        grid-template-columns: 1fr;
    }
}

/* ═══════════════ EXPIRED PROVIDER ALERT ═══════════════ */

.expired-alert-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px;
    margin-bottom: 16px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.12), rgba(239, 68, 68, 0.08));
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: var(--radius-lg);
    animation: fadeIn 0.3s ease;
}

.expired-alert-icon {
    font-size: 1.3rem;
    flex-shrink: 0;
}

.expired-alert-text {
    flex: 1;
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--warning);
    line-height: 1.4;
}

.expired-alert-dismiss {
    flex-shrink: 0;
}