:root {
    --primary: #16a34a;
    --primary-light: #22c55e;
    --primary-lighter: #bbf7d0;
    --primary-bg: #f0fdf4;
    --primary-dark: #15803d;
    --primary-darker: #166534;
    --sidebar-width: 260px;
    --sidebar-bg: #0f172a;
    --sidebar-hover: #1e293b;
    --sidebar-active: rgba(22,163,74,0.15);
    --sidebar-divider: rgba(255,255,255,0.06);
    --body-bg: #f1f5f9;
    --card-bg: #ffffff;
    --card-border: #e2e8f0;
    --card-shadow: 0 1px 2px rgba(0,0,0,0.04);
    --card-shadow-hover: 0 4px 16px rgba(0,0,0,0.08);
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --text-light: #cbd5e1;
    --border-color: #e2e8f0;
    --success: #16a34a;
    --danger: #dc2626;
    --warning: #f59e0b;
    --info: #0ea5e9;
    --radius: 12px;
    --radius-sm: 8px;
    --radius-xs: 6px;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--body-bg);
    color: var(--text-primary);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

#wrapper { min-height: 100vh; display: flex; }

/* ─── SIDEBAR ─── */
.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: var(--sidebar-bg);
    color: #94a3b8;
    position: fixed;
    left: 0; top: 0; bottom: 0;
    z-index: 1050;
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
    overflow-y: auto;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
    border-radius: 0 24px 24px 0;
    box-shadow: 4px 0 20px rgba(0,0,0,0.08);
}

.sidebar-logo {
    padding: 1.25rem 1.25rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid var(--sidebar-divider);
    flex-shrink: 0;
    border-radius: 0 24px 0 0;
}
.sidebar-logo .logo-icon {
    width: 40px; height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.15rem;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(22,163,74,0.3);
}
.sidebar-logo .logo-text h6 {
    margin: 0;
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: -0.01em;
    line-height: 1.2;
}
.sidebar-logo .logo-text small {
    font-size: 0.65rem;
    color: #64748b;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.sidebar-section {
    padding: 1.25rem 1.25rem 0.35rem;
    font-size: 0.6rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #334155;
    margin-top: 0.15rem;
}

.sidebar-nav {
    padding: 0.15rem 0.65rem;
    list-style: none;
    margin: 0;
}
.sidebar-nav .nav-item {
    margin-bottom: 2px;
}
.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.6rem 0.9rem;
    color: #64748b;
    border-radius: 12px;
    transition: all 0.2s ease;
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    position: relative;
    margin: 0 0.1rem;
}
.sidebar-nav .nav-link i {
    font-size: 1.05rem;
    width: 20px;
    text-align: center;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}
.sidebar-nav .nav-link:hover {
    background: var(--sidebar-hover);
    color: #e2e8f0;
}
.sidebar-nav .nav-link:hover i {
    transform: translateX(2px);
}
.sidebar-nav .nav-link.active {
    background: linear-gradient(135deg, rgba(22,163,74,0.2) 0%, rgba(22,163,74,0.1) 100%);
    color: var(--primary-light);
    font-weight: 600;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}
.sidebar-nav .nav-link.active i {
    color: var(--primary-light);
}

.sidebar-nav .nav-link.logout-link {
    color: #f87171;
    opacity: 0.6;
    margin-top: 0.15rem;
}
.sidebar-nav .nav-link.logout-link:hover {
    opacity: 1;
    background: rgba(239,68,68,0.12);
    color: #f87171;
}

.sidebar-user {
    padding: 0.85rem 1.25rem;
    border-top: 1px solid var(--sidebar-divider);
    margin-top: auto;
    flex-shrink: 0;
    border-radius: 0 0 24px 0;
}
.sidebar-user .user-avatar {
    width: 36px; height: 36px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(22,163,74,0.25);
}
.sidebar-user .user-info { flex: 1; min-width: 0; }
.sidebar-user .user-name {
    color: #e2e8f0;
    font-weight: 600;
    font-size: 0.82rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.sidebar-user .user-role {
    color: #475569;
    font-size: 0.7rem;
    font-weight: 500;
    text-transform: capitalize;
}

/* ─── MAIN CONTENT ─── */
.main-content {
    margin-left: var(--sidebar-width);
    flex: 1;
    min-height: 100vh;
    max-width: 100%;
    background: var(--body-bg);
    min-width: 0;
}

/* ─── TOP BAR ─── */
.topbar {
    background: var(--card-bg);
    border-bottom: 1px solid var(--border-color);
    padding: 0 2rem;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1000;
}
.topbar .page-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.01em;
}
.topbar-search {
    position: relative;
    width: 300px;
}
.topbar-search input {
    width: 100%;
    padding: 0.5rem 1rem 0.5rem 2.25rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    background: var(--body-bg);
    color: var(--text-primary);
    transition: all 0.2s;
}
.topbar-search input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(22,163,74,0.1);
    background: #fff;
}
.topbar-search i {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 0.85rem;
}
.topbar-actions {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.topbar-actions .btn-icon {
    width: 36px; height: 36px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: all 0.15s;
    position: relative;
    cursor: pointer;
    font-size: 0.9rem;
}
.topbar-actions .btn-icon:hover {
    background: var(--primary-bg);
    border-color: var(--primary-lighter);
    color: var(--primary);
}
.topbar-actions .btn-icon .badge-dot {
    position: absolute;
    top: 7px; right: 7px;
    width: 7px; height: 7px;
    background: var(--danger);
    border-radius: 50%;
    border: 2px solid #fff;
}

.topbar-user-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0.65rem 0.3rem 0.3rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    background: #fff;
    cursor: pointer;
    transition: all 0.15s;
}
.topbar-user-btn:hover {
    background: var(--primary-bg);
    border-color: var(--primary-lighter);
}
.topbar-user-btn .avatar {
    width: 30px; height: 30px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 0.75rem;
}
.topbar-user-btn .user-name-small {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ─── PAGE CONTENT ─── */
.page-content {
    padding: 1.5rem 2rem 2rem;
    min-width: 0;
}

/* ─── STAT CARDS ─── */
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    padding: 1.25rem 1.5rem;
    transition: all 0.2s ease;
}
.stat-card:hover {
    box-shadow: var(--card-shadow-hover);
    transform: translateY(-1px);
}
.stat-card .stat-icon {
    width: 44px; height: 44px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    flex-shrink: 0;
}
.stat-card .stat-icon.green { background: var(--primary-bg); color: var(--primary); }
.stat-card .stat-icon.blue { background: #eff6ff; color: #2563eb; }
.stat-card .stat-icon.red { background: #fef2f2; color: #dc2626; }
.stat-card .stat-icon.yellow { background: #fffbeb; color: #f59e0b; }
.stat-card .stat-icon.purple { background: #faf5ff; color: #9333ea; }
.stat-card .stat-icon.orange { background: #fff7ed; color: #ea580c; }
.stat-card .stat-icon.cyan { background: #ecfeff; color: #0891b2; }

.stat-card .stat-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.2;
    letter-spacing: -0.02em;
}
.stat-card .stat-label {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 500;
}
.stat-card .stat-trend {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 0.15rem 0.45rem;
    border-radius: 20px;
}
.stat-card .stat-trend.up { background: var(--primary-bg); color: var(--primary); }
.stat-card .stat-trend.down { background: #fef2f2; color: var(--danger); }

/* ─── CARDS ─── */
.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--card-shadow);
}
.card-header {
    background: transparent;
    border-bottom: 1px solid var(--card-border);
    padding: 1.1rem 1.25rem;
    border-radius: var(--radius) var(--radius) 0 0 !important;
}
.card-header h5,
.card-header h6 {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.card-body { padding: 1.25rem; min-width: 0; }

/* ─── GREETING CARD ─── */
.greeting-card {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: var(--radius);
    padding: 1.5rem 2rem;
    color: #fff;
    position: relative;
    overflow: hidden;
}
.greeting-card::after {
    content: '';
    position: absolute;
    right: -30px; top: -30px;
    width: 160px; height: 160px;
    background: rgba(255,255,255,0.06);
    border-radius: 50%;
}
.greeting-card h4 {
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 0.2rem;
}
.greeting-card p {
    opacity: 0.85;
    font-size: 0.85rem;
    margin: 0;
}

/* ─── TABLES ─── */
.table {
    margin-bottom: 0;
    font-size: 0.85rem;
}
.table thead th {
    background: transparent;
    border-bottom: 1px solid var(--border-color);
    font-weight: 600;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--text-muted);
    padding: 0.75rem 1rem;
    white-space: nowrap;
}
.table tbody td {
    padding: 0.7rem 1rem;
    border-bottom: 1px solid #f1f5f9;
    color: var(--text-secondary);
    vertical-align: middle;
}
.table tbody tr:hover td {
    background: rgba(22,163,74,0.03);
}
.table tbody tr:last-child td { border-bottom: none; }
.table .patient-cell {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}
.table .patient-avatar {
    width: 32px; height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.75rem;
    color: #fff;
    flex-shrink: 0;
}

/* ─── BUTTONS ─── */
.btn {
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.82rem;
    padding: 0.5rem 1.15rem;
    transition: all 0.15s ease;
    border: none;
    line-height: 1.4;
}
.btn-primary {
    background: var(--primary);
    color: #fff;
}
.btn-primary:hover {
    background: var(--primary-dark);
    box-shadow: 0 2px 8px rgba(22,163,74,0.3);
    transform: translateY(-1px);
    color: #fff;
}
.btn-success { background: var(--success); color: #fff; }
.btn-outline-primary {
    border: 1px solid var(--primary-lighter);
    color: var(--primary);
    background: transparent;
}
.btn-outline-primary:hover {
    background: var(--primary-bg);
    border-color: var(--primary);
    color: var(--primary-dark);
}
.btn-outline-secondary {
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    background: #fff;
}
.btn-outline-secondary:hover {
    background: var(--body-bg);
    border-color: #cbd5e1;
}
.btn-sm {
    padding: 0.35rem 0.65rem;
    font-size: 0.78rem;
    border-radius: 6px;
}
.btn-action {
    width: 30px; height: 30px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    border: none;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.15s;
}
.btn-action.edit { background: #dcfce7; color: #16a34a; }
.btn-action.edit:hover { background: #bbf7d0; }
.btn-action.view { background: #e0f2fe; color: #0ea5e9; }
.btn-action.view:hover { background: #bae6fd; }
.btn-action.delete { background: #fee2e2; color: #dc2626; }
.btn-action.delete:hover { background: #fecaca; }
.btn-action.print { background: #e0f2fe; color: #0284c7; }
.btn-action.print:hover { background: #bae6fd; }

/* ─── FORMS ─── */
.form-control, .form-select {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.55rem 0.75rem;
    font-size: 0.85rem;
    color: var(--text-primary);
    background: #fff;
    transition: all 0.15s;
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(22,163,74,0.1);
    outline: none;
}
.form-label {
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.35rem;
}
.input-group-text {
    background: var(--body-bg);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    font-size: 0.85rem;
    border-radius: 8px;
}

/* ─── BADGES ─── */
.badge {
    font-weight: 600;
    font-size: 0.7rem;
    padding: 0.25rem 0.55rem;
    border-radius: 6px;
    letter-spacing: 0.01em;
}
.badge.bg-success { background: var(--primary-bg) !important; color: var(--primary) !important; }
.badge.bg-warning { background: #fffbeb !important; color: #d97706 !important; }
.badge.bg-danger { background: #fef2f2 !important; color: #dc2626 !important; }
.badge.bg-info { background: #e0f2fe !important; color: #0284c7 !important; }
.badge.bg-primary { background: var(--primary-bg) !important; color: var(--primary) !important; }
.badge.bg-secondary { background: #f1f5f9 !important; color: #64748b !important; }
.badge.bg-dark { background: #1e293b !important; color: #fff !important; }

/* ─── TABS ─── */
.nav-tabs {
    border-bottom: 2px solid var(--border-color);
    gap: 0.25rem;
}
.nav-tabs .nav-link {
    border: none;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.82rem;
    padding: 0.65rem 1.15rem;
    border-radius: 6px 6px 0 0;
    transition: all 0.15s;
    background: transparent;
    cursor: pointer;
}
.nav-tabs .nav-link:hover {
    color: var(--text-primary);
    background: var(--primary-bg);
}
.nav-tabs .nav-link.active {
    color: var(--primary);
    background: var(--primary-bg);
    border-bottom: 2px solid var(--primary);
    border-color: var(--primary) transparent transparent;
}

/* ─── MODAL ─── */
.modal-content {
    border: none;
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
}
.modal-header {
    border-bottom: 1px solid var(--border-color);
    padding: 1.1rem 1.25rem;
}
.modal-title { font-weight: 700; font-size: 1rem; }
.modal-body { padding: 1.25rem; }
.modal-footer {
    border-top: 1px solid var(--border-color);
    padding: 0.85rem 1.25rem;
}

/* ─── DROPDOWN ─── */
.dropdown-menu {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    padding: 0.35rem;
}
.dropdown-item {
    border-radius: 6px;
    padding: 0.45rem 0.7rem;
    font-size: 0.82rem;
    font-weight: 500;
    color: var(--text-secondary);
}
.dropdown-item:hover {
    background: var(--primary-bg);
    color: var(--primary);
}

/* ─── PAGINATION ─── */
.page-link {
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.82rem;
    padding: 0.45rem 0.75rem;
    margin: 0 2px;
    border-radius: 6px !important;
}
.page-link:hover {
    background: var(--primary-bg);
    border-color: var(--primary);
    color: var(--primary);
}
.page-item.active .page-link {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* ─── DATA TABLES OVERRIDES ─── */
.dataTables_wrapper {
    width: 100%;
    max-width: 100%;
}
.table-responsive .dataTables_wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.table-responsive .dataTables_wrapper .dataTables_scroll {
    overflow-x: auto;
}
.dataTables_wrapper table.dataTable {
    width: 100% !important;
    max-width: 100%;
}
.dataTables_wrapper .dataTables_filter input {
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 0.4rem 0.7rem;
    font-size: 0.82rem;
}
.dataTables_wrapper .dataTables_filter input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(22,163,74,0.1);
}
.dataTables_wrapper .dataTables_length select {
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 0.35rem 0.5rem;
    font-size: 0.82rem;
}
.dataTables_wrapper .dataTables_info {
    color: var(--text-muted);
    font-size: 0.78rem;
}
.dataTables_wrapper .dataTables_paginate .paginate_button {
    border-radius: 6px !important;
    margin: 0 2px;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--primary) !important;
    border-color: var(--primary) !important;
    color: #fff !important;
    border-radius: 6px !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: var(--primary-bg) !important;
    border-color: var(--primary) !important;
    color: var(--primary) !important;
}

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ─── SELECT2 OVERRIDES ─── */
.select2-container--bootstrap-5 .select2-selection {
    border-radius: 8px !important;
    min-height: 36px;
    border-color: var(--border-color);
}

/* ─── MOBILE ─── */
@media (max-width: 991px) {
    .sidebar { transform: translateX(-100%); border-radius: 0 24px 24px 0; }
    .sidebar.show { transform: translateX(0); box-shadow: 0 0 60px rgba(0,0,0,0.4); }
    .main-content { margin-left: 0; max-width: 100vw; }
    .topbar { padding: 0 1rem; }
    .page-content { padding: 1rem; }
    .topbar-search { display: none; }
}

/* ─── LOGIN ─── */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    background: var(--sidebar-bg);
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    overflow: hidden;
}
.login-wrapper::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -30%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(22,163,74,0.08) 0%, transparent 70%);
    border-radius: 50%;
}
.login-wrapper::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -20%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(22,163,74,0.05) 0%, transparent 70%);
    border-radius: 50%;
}
.login-card {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 25px 60px rgba(0,0,0,0.3);
    width: 100%;
    max-width: 420px;
    overflow: hidden;
    position: relative;
    z-index: 1;
}
.login-header {
    padding: 2rem 2rem 1.25rem;
    text-align: center;
}
.login-header .logo-icon {
    width: 52px; height: 52px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: #fff;
    margin-bottom: 0.75rem;
}
.login-header h3 {
    font-weight: 800;
    font-size: 1.35rem;
    margin: 0;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}
.login-header p {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin: 0.25rem 0 0;
}
.login-body {
    padding: 0 2rem 2rem;
}
.login-body .form-control {
    padding: 0.7rem 0.85rem;
    border-radius: 8px;
}
.login-body .input-group-text {
    border-radius: 8px 0 0 8px;
    background: var(--body-bg);
}
.login-body .input-group .form-control {
    border-radius: 0 8px 8px 0;
}
.btn-login {
    padding: 0.75rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.9rem;
    background: var(--primary);
    border: none;
    color: #fff;
    width: 100%;
    transition: all 0.2s;
}
.btn-login:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(22,163,74,0.3);
}

/* ─── PRINT ─── */
@media print {
    .sidebar, .topbar, .btn, .topbar-actions, .no-print { display: none !important; }
    .main-content { margin-left: 0 !important; }
    .card { box-shadow: none !important; border: 1px solid #ddd !important; }
}

/* ─── MISC ─── */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.25rem;
}
.page-header h4 {
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.page-header h4 i { color: var(--primary); }
.divider {
    height: 1px;
    background: var(--border-color);
    margin: 0.85rem 0;
}
.text-primary { color: var(--primary) !important; }
.bg-primary { background-color: var(--primary) !important; }
.alert { border-radius: var(--radius-sm); border: none; font-weight: 500; }

/* ─── SCHEDULE TABLE ─── */
.table-bordered th, .table-bordered td {
    border-color: var(--border-color);
}

/* ─── ANCILLARY BUTTONS ─── */
.ancillary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}
.ancillary-btn {
    padding: 0.85rem;
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.35rem;
    cursor: pointer;
    transition: all 0.15s;
    font-weight: 600;
    font-size: 0.8rem;
    color: var(--text-secondary);
}
.ancillary-btn i { font-size: 1.3rem; }
.ancillary-btn:hover {
    border-color: var(--primary-lighter);
    background: var(--primary-bg);
    color: var(--primary);
}

/* ─── SMALL ADJUSTMENTS ─── */
.fw-semibold { font-weight: 600; }
.text-decoration-none { text-decoration: none; }
.object-fit-cover { object-fit: cover; }

/* ─── NOTIFICATIONS ─── */
.notif-panel { border: 1px solid var(--border-color); box-shadow: 0 8px 30px rgba(0,0,0,0.12); padding: 0; border-radius: var(--radius); }
.notif-list { padding: 0; }
.notif-item {
    display: block; padding: 10px 14px; border-bottom: 1px solid var(--border-color);
    cursor: pointer; transition: background 0.15s; text-decoration: none; color: inherit; position: relative;
}
.notif-item:last-child { border-bottom: none; }
.notif-item:hover { background: #f8fafc; }
.notif-item.unread { background: var(--primary-bg); }
.notif-item.unread::before {
    content: ''; position: absolute; left: 6px; top: 50%; transform: translateY(-50%);
    width: 6px; height: 6px; border-radius: 50%; background: var(--primary);
}
.notif-icon { font-size: 1.1rem; padding-top: 2px; flex-shrink: 0; }
.notif-title { font-weight: 600; font-size: 0.82rem; color: var(--text-primary); margin-bottom: 2px; }
.notif-msg { font-size: 0.78rem; color: var(--text-secondary); line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.notif-time { font-size: 0.7rem; color: var(--text-muted); margin-top: 3px; }
.notif-dismiss {
    position: absolute; top: 8px; right: 8px; background: none; border: none; color: var(--text-muted);
    font-size: 0.8rem; padding: 2px; opacity: 0; transition: opacity 0.15s;
}
.notif-item:hover .notif-dismiss { opacity: 1; }
.notif-dismiss:hover { color: var(--danger); }
.notif-panel .dropdown-menu-end { padding: 0; }
