/* Aabha Theme Engine v2.0.3 - 2026 Release */
/* Fonts loaded via <link> in header.php — fonts.googleapis.com not needed here */

/* Brand lockup theme switching */
.app-brand-lockup-dark {
    display: none !important;
}
html.dark-mode .app-brand-lockup-light,
html[data-theme="dark"] .app-brand-lockup-light,
body.dark-mode .app-brand-lockup-light {
    display: none !important;
}
html.dark-mode .app-brand-lockup-dark,
html[data-theme="dark"] .app-brand-lockup-dark,
body.dark-mode .app-brand-lockup-dark {
    display: inline-block !important;
}

/*
  Theme layer
  - `default` intentionally has no overrides so the existing style remains unchanged.
  - Non-default themes only apply under body[data-ui-theme="..."].
*/

[data-ui-theme]:not([data-ui-theme="default"]) {
    /* Transitions removed on root container to prevent paint flash/flicker */
}

[data-ui-theme]:not([data-ui-theme="default"]) .container,
[data-ui-theme]:not([data-ui-theme="default"]) .container-fluid {
    color: var(--dark);
}

[data-ui-theme]:not([data-ui-theme="default"]) .table {
    --bs-table-bg: rgba(255, 255, 255, 0.86);
    --bs-table-color: var(--dark);
    --bs-table-border-color: var(--border);
}

[data-ui-theme]:not([data-ui-theme="default"]) .stat-card-inline {
    border-color: var(--border);
}

[data-ui-theme]:not([data-ui-theme="default"]) .table thead.table-light th,
[data-ui-theme]:not([data-ui-theme="default"]) .table .table-light th {
    background: color-mix(in srgb, var(--dark-gray) 12%, transparent) !important;
    color: var(--dark);
    border-color: var(--border);
}

[data-ui-theme]:not([data-ui-theme="default"]) .table-hover > tbody > tr:hover > * {
    --bs-table-accent-bg: color-mix(in srgb, var(--primary) 8%, transparent);
}

[data-ui-theme]:not([data-ui-theme="default"]) .modal-content {
    border: 1px solid var(--border);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.18);
}

[data-ui-theme]:not([data-ui-theme="default"]) .modal-header,
[data-ui-theme]:not([data-ui-theme="default"]) .modal-footer {
    border-color: var(--border);
}

[data-ui-theme]:not([data-ui-theme="default"]) .dropdown-menu {
    border: 1px solid var(--border);
    background: color-mix(in srgb, var(--light) 97%, transparent);
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.12);
}

[data-ui-theme]:not([data-ui-theme="default"]) .dropdown-item {
    color: var(--dark);
}

[data-ui-theme]:not([data-ui-theme="default"]) .dropdown-item:hover,
[data-ui-theme]:not([data-ui-theme="default"]) .dropdown-item:focus {
    background: color-mix(in srgb, var(--primary) 12%, transparent);
    color: var(--dark);
}

[data-ui-theme]:not([data-ui-theme="default"]) .dropdown-item.active,
[data-ui-theme]:not([data-ui-theme="default"]) .dropdown-item:active {
    background: var(--gradient-primary);
    color: #fff;
}

/* ─── Universal Brand Token Bridge ─── */
[data-ui-theme]:not([data-ui-theme="default"]) .btn-primary {
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
    color: #fff !important;
    box-shadow: var(--primary-glow, 0 4px 14px -2px color-mix(in srgb, var(--primary) 35%, transparent));
}

[data-ui-theme]:not([data-ui-theme="default"]) .btn-primary:hover,
[data-ui-theme]:not([data-ui-theme="default"]) .btn-primary:focus {
    background-color: var(--primary-light, var(--primary)) !important;
    border-color: var(--primary-light, var(--primary)) !important;
    color: #fff !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .btn-outline-primary {
    color: var(--primary) !important;
    border-color: var(--primary) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .btn-outline-primary:hover,
[data-ui-theme]:not([data-ui-theme="default"]) .btn-outline-primary:focus {
    background-color: var(--primary) !important;
    border-color: var(--primary) !important;
    color: #fff !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .text-primary {
    color: var(--primary) !important;
}

/* ─── Bootstrap 5 Token Bridge ─── */
/* Maps Bootstrap's own --bs-* tokens to our theme's --primary so
   utility classes (.bg-primary-subtle, .text-primary-emphasis, links etc.)
   respect the active theme instead of defaulting to Bootstrap's #0d6efd */
[data-ui-theme]:not([data-ui-theme="default"]) {
    --bs-primary: var(--primary);
    --bs-primary-rgb: var(--bs-primary-rgb, 37, 99, 235); /* overridden per-theme */
    --bs-primary-bg-subtle: var(--primary-faint, color-mix(in srgb, var(--primary) 10%, transparent));
    --bs-primary-text-emphasis: var(--primary-dark, var(--primary));
    --bs-link-color: var(--primary);
    --bs-link-hover-color: var(--primary-dark, var(--primary));
}

[data-ui-theme]:not([data-ui-theme="default"]) .bg-primary-subtle,
[data-ui-theme]:not([data-ui-theme="default"]) .bg-primary-subtle.text-primary {
    background-color: var(--primary-faint, color-mix(in srgb, var(--primary) 10%, transparent)) !important;
    color: var(--primary) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .text-primary-emphasis {
    color: var(--primary-dark, var(--primary)) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .border-primary-subtle {
    border-color: color-mix(in srgb, var(--primary) 28%, transparent) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .bg-primary {
    background-color: var(--primary) !important;
    color: #fff;
}

[data-ui-theme]:not([data-ui-theme="default"]) .badge.bg-primary {
    background-color: var(--primary) !important;
    color: #fff !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .border-primary {
    border-color: var(--primary) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .nav-pills .nav-link.active {
    background-color: var(--primary) !important;
    color: #fff !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .nav-pills .nav-link.active .badge {
    background-color: rgba(255, 255, 255, 0.22) !important;
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .form-control:focus,
[data-ui-theme]:not([data-ui-theme="default"]) .form-select:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 0.2rem var(--primary-faint, color-mix(in srgb, var(--primary) 18%, transparent)) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .alert {
    border: 1px solid var(--border);
}

[data-ui-theme]:not([data-ui-theme="default"]) .nav-link.active,
[data-ui-theme]:not([data-ui-theme="default"]) .navbar .nav-link.active {
    color: var(--primary) !important;
}

[data-ui-theme]:not([data-ui-theme="default"]) .attendance-view-tabs .nav-link.active {
    color: #fff !important;
    --bs-nav-link-color: #fff;
    --bs-nav-pills-link-active-color: #fff;
    -webkit-text-fill-color: #fff;
    text-shadow: none;
}

[data-ui-theme]:not([data-ui-theme="default"]) .pagination .page-link {
    color: var(--dark);
    border-color: var(--border);
    background: rgba(255, 255, 255, 0.9);
}

[data-ui-theme]:not([data-ui-theme="default"]) .pagination .page-item.active .page-link {
    border-color: var(--primary);
    background: var(--gradient-primary);
    color: #fff;
}

[data-ui-theme]:not([data-ui-theme="default"]) .pagination .page-link:focus:not(:focus-visible),
[data-ui-theme]:not([data-ui-theme="default"]) .btn:focus:not(:focus-visible),
[data-ui-theme]:not([data-ui-theme="default"]) .form-control:focus:not(:focus-visible),
[data-ui-theme]:not([data-ui-theme="default"]) .form-select:focus:not(:focus-visible) {
    outline: none;
}

@media screen {
body[data-ui-theme="modern-polished"] {
    --primary: #0b5ed7;
    --primary-light: #3b82f6;
    --primary-dark: #1e3a8a;
    --success: #15803d;
    --warning: #a16207;
    --danger: #b91c1c;
    --info: #0369a1;
    --light: #f7fafc;
    --light-gray: #f1f5f9;
    --dark: #0f172a;
    --dark-gray: #334155;
    --border: #d9e2ec;
    --border-light: #e6edf4;
    --gradient-primary: linear-gradient(135deg, #0b5ed7 0%, #2563eb 60%, #0891b2 100%);
    --gradient-bg: linear-gradient(150deg, #f8fbff 0%, #f3f7fb 45%, #eef4fb 100%);
    background:
        radial-gradient(circle at 5% 0%, rgba(59, 130, 246, 0.12), transparent 30%),
        radial-gradient(circle at 100% 95%, rgba(8, 145, 178, 0.12), transparent 34%),
        linear-gradient(180deg, rgba(255,255,255,0.55), rgba(241,245,249,0.25)),
        var(--light);
}

body[data-ui-theme="modern-polished"] .navbar {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.9) !important;
    border-bottom: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
    z-index: 1200;
}

body[data-ui-theme="modern-polished"] .navbar-toggler {
    border-color: rgba(148, 163, 184, 0.32);
    border-radius: 10px;
}

body[data-ui-theme="modern-polished"] .card {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 20px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.09);
    overflow: hidden;
}

body[data-ui-theme="modern-polished"] .card-header {
    background: linear-gradient(120deg, rgba(255,255,255,0.98) 0%, #f6f9fd 48%, #eef6ff 100%);
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

body[data-ui-theme="modern-polished"] .btn {
    border-radius: 14px;
    font-weight: 700;
    letter-spacing: 0.015em;
}

body[data-ui-theme="modern-polished"] .btn-primary {
    box-shadow: 0 14px 30px rgba(37, 99, 235, 0.26);
    background: linear-gradient(135deg, #0b5ed7 0%, #2563eb 55%, #0891b2 100%);
}

body[data-ui-theme="modern-polished"] .btn-outline-secondary,
body[data-ui-theme="modern-polished"] .btn-light {
    border-color: #cfd8e3;
}

body[data-ui-theme="modern-polished"] .form-control,
body[data-ui-theme="modern-polished"] .form-select {
    border-radius: 14px;
    border-color: #d4dee8;
    min-height: 46px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.8);
}

body[data-ui-theme="modern-polished"] .form-control:focus,
body[data-ui-theme="modern-polished"] .form-select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.14);
}

body[data-ui-theme="modern-polished"] .table thead th {
    font-weight: 700;
    letter-spacing: 0.02em;
}

body[data-ui-theme="modern-polished"] .badge {
    border-radius: 999px;
    font-weight: 700;
}

body[data-ui-theme="modern-polished"] .alert {
    border-radius: 12px;
}

body[data-ui-theme="modern-polished"] .container-fluid {
    --mp-gap: 1.15rem;
}

body[data-ui-theme="modern-polished"] h1,
body[data-ui-theme="modern-polished"] h2,
body[data-ui-theme="modern-polished"] h3,
body[data-ui-theme="modern-polished"] h4,
body[data-ui-theme="modern-polished"] h5,
body[data-ui-theme="modern-polished"] h6 {
    letter-spacing: -0.01em;
    font-weight: 800;
    color: #0f172a;
}

body[data-ui-theme="modern-polished"] .card:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.10);
}

body[data-ui-theme="modern-polished"] .dashboard-panel-card {
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px);
}

body[data-ui-theme="modern-polished"] .card .text-muted {
    color: #64748b !important;
}

body[data-ui-theme="modern-polished"] .navbar .nav-link {
    border-radius: 10px;
    padding-inline: 0.85rem !important;
    font-weight: 700;
}

body[data-ui-theme="modern-polished"] .navbar .nav-link:hover {
    background: rgba(37, 99, 235, 0.09);
}

body[data-ui-theme="modern-polished"] .navbar .dropdown-toggle::after {
    margin-left: 0.45rem;
}

body[data-ui-theme="modern-polished"] .dropdown-menu {
    border-radius: 14px;
    padding: 0.45rem;
    z-index: 1210;
}

body[data-ui-theme="modern-polished"] .dropdown-item {
    border-radius: 10px;
    font-weight: 600;
    padding: 0.6rem 0.85rem;
}

body[data-ui-theme="modern-polished"] .dropdown-item:hover,
body[data-ui-theme="modern-polished"] .dropdown-item:focus {
    background: rgba(37, 99, 235, 0.1);
    color: #0f172a;
}

body[data-ui-theme="modern-polished"] .table {
    border-radius: 14px;
    overflow: hidden;
}

body[data-ui-theme="modern-polished"] .table th {
    background: linear-gradient(120deg, #f8fbff 0%, #edf3fb 55%, #e7f1fb 100%);
    font-size: 0.78rem;
    letter-spacing: 0.08em;
}

body[data-ui-theme="modern-polished"] .table td {
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

body[data-ui-theme="modern-polished"] .table-hover > tbody > tr:hover > * {
    --bs-table-accent-bg: rgba(37, 99, 235, 0.07);
}

body[data-ui-theme="modern-polished"] .table-responsive {
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
    -webkit-overflow-scrolling: touch;
}

body[data-ui-theme="modern-polished"] .form-label {
    letter-spacing: 0.06em;
    font-size: 0.77rem;
    font-weight: 700;
    color: #334155;
}

body[data-ui-theme="modern-polished"] .input-group-text {
    border-color: #d4dee8;
    background: #f8fbff;
    color: #334155;
}

body[data-ui-theme="modern-polished"] .btn {
    min-height: 40px;
}

body[data-ui-theme="modern-polished"] .btn-primary,
body[data-ui-theme="modern-polished"] .btn-success,
body[data-ui-theme="modern-polished"] .btn-danger,
body[data-ui-theme="modern-polished"] .btn-warning {
    border: 0;
}

body[data-ui-theme="modern-polished"] .btn-outline-secondary {
    color: #334155;
    background: #fff;
}

body[data-ui-theme="modern-polished"] .btn-outline-secondary:hover {
    background: #eef4ff;
    color: #1e3a8a;
    border-color: #bfdbfe;
}

body[data-ui-theme="modern-polished"] .badge {
    letter-spacing: 0.03em;
    padding: 0.46rem 0.8rem;
}

body[data-ui-theme="modern-polished"] .alert {
    border: 1px solid rgba(148, 163, 184, 0.2);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.05);
}

body[data-ui-theme="modern-polished"] .pagination .page-link {
    border-radius: 10px;
    margin: 0 0.15rem;
}

/* Teacher dashboard visual polish */
body[data-ui-theme="modern-polished"] .action-card:hover {
    border-color: rgba(37, 99, 235, 0.26);
    box-shadow: 0 12px 26px rgba(37, 99, 235, 0.14);
}

body[data-ui-theme="modern-polished"] .course-card {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 14px;
    background: linear-gradient(130deg, #ffffff 0%, #f8fbff 100%);
}

/* Student calendar (attendance.php) */
body[data-ui-theme="modern-polished"] .cal-grid {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 14px;
    padding: 0.5rem;
    background: #fff;
}

body[data-ui-theme="modern-polished"] .cal-day {
    border-radius: 10px;
    border: 1px solid rgba(148, 163, 184, 0.15);
    background: #f9fbff;
}

body[data-ui-theme="modern-polished"] .cal-day:hover {
    border-color: rgba(37, 99, 235, 0.3);
    background: #f3f8ff;
}

/* Dashboard stat cards and bordered variants */
body[data-ui-theme="modern-polished"] .card.border-left-primary,
body[data-ui-theme="modern-polished"] .card.border-left-success,
body[data-ui-theme="modern-polished"] .card.border-left-warning,
body[data-ui-theme="modern-polished"] .card.border-left-info,
body[data-ui-theme="modern-polished"] .card.border-left-danger {
    border-left-width: 5px;
}

body[data-ui-theme="modern-polished"] .h5,
body[data-ui-theme="modern-polished"] .h4,
body[data-ui-theme="modern-polished"] .h3 {
    font-weight: 750;
}

/* Modal and toast consistency */
body[data-ui-theme="modern-polished"] .modal-content {
    border-radius: 16px;
}

body[data-ui-theme="modern-polished"] .modal-header {
    background: linear-gradient(120deg, #f8fbff 0%, #eff5ff 100%);
}

body[data-ui-theme="modern-polished"] .toast {
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.18);
}

body[data-ui-theme="modern-polished"] .modal-dialog {
    margin-top: 1rem;
    margin-bottom: 1rem;
}

/* Shared page-specific components */
body[data-ui-theme="modern-polished"] .sms-footer {
    border-top: 1px solid rgba(148, 163, 184, 0.22);
    background: linear-gradient(120deg, #f8fbff 0%, #eff4fb 100%) !important;
}

body[data-ui-theme="modern-polished"] .status-pill {
    border-radius: 8px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    background: #fff;
}
body[data-ui-theme="modern-polished"] .status-pill-label {
    font-weight: 600;
}
body[data-ui-theme="modern-polished"] .cr-status-pill {
    border-radius: 8px;
    border: 1px solid rgba(148, 163, 184, 0.2);
    background: #fff;
}
body[data-ui-theme="modern-polished"] .rubric-status-group {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.82);
}
body[data-ui-theme="modern-polished"] .watchlist-item {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.82);
}
body[data-ui-theme="modern-polished"] .sortable-table th {
    background: linear-gradient(120deg, #f8fbff 0%, #edf3fb 55%, #e7f1fb 100%);
    font-weight: 700;
}
body[data-ui-theme="modern-polished"] .promotion-card {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.85);
}

body[data-ui-theme="modern-polished"] .breadcrumb {
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    padding: 0.55rem 0.85rem;
}

body[data-ui-theme="modern-polished"] .breadcrumb .breadcrumb-item + .breadcrumb-item::before {
    color: #94a3b8;
}

body[data-ui-theme="modern-polished"] .list-group-item {
    border-color: rgba(148, 163, 184, 0.18);
    background: rgba(255, 255, 255, 0.82);
}

body[data-ui-theme="modern-polished"] .nav-tabs {
    border-bottom: 1px solid rgba(148, 163, 184, 0.25);
}

body[data-ui-theme="modern-polished"] .nav-tabs .nav-link {
    border: 1px solid transparent;
    border-radius: 10px 10px 0 0;
    color: #475569;
    font-weight: 600;
}

body[data-ui-theme="modern-polished"] .nav-tabs .nav-link:hover {
    border-color: rgba(148, 163, 184, 0.22);
    background: rgba(248, 251, 255, 0.9);
}

body[data-ui-theme="modern-polished"] .nav-tabs .nav-link.active {
    color: #0b5ed7;
    border-color: rgba(148, 163, 184, 0.28) rgba(148, 163, 184, 0.28) #fff;
    background: #fff;
}

body[data-ui-theme="modern-polished"] .attendance-view-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem !important;
}

body[data-ui-theme="modern-polished"] .attendance-view-tabs .nav-item {
    margin: 0;
}

body[data-ui-theme="modern-polished"] .attendance-view-tabs .nav-link {
    border: 1px solid rgba(203, 213, 225, 0.82);
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(247, 250, 255, 0.98));
    color: #1e293b;
    font-weight: 700;
    padding: 0.7rem 1.35rem;
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.05);
}

body[data-ui-theme="modern-polished"] .attendance-view-tabs .nav-link:hover,
body[data-ui-theme="modern-polished"] .attendance-view-tabs .nav-link:focus-visible {
    color: #0f172a;
    border-color: rgba(59, 130, 246, 0.34);
    background: linear-gradient(135deg, rgba(255,255,255,1), rgba(239, 246, 255, 0.98));
}

body[data-ui-theme="modern-polished"] .attendance-view-tabs .nav-link.active {
    color: #ffffff !important;
    border-color: transparent;
    background: linear-gradient(135deg, #2563eb, #3b82f6 55%, #0891b2) !important;
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
}

body[data-ui-theme="modern-polished"] .progress {
    height: 8px;
    border-radius: 999px;
    background-color: #e8eef6;
}

body[data-ui-theme="modern-polished"] .progress .progress-bar {
    border-radius: 999px;
}

body[data-ui-theme="modern-polished"] .student-search-dropdown {
    border: 1px solid rgba(148, 163, 184, 0.24);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
    border-radius: 12px;
    background: #fff;
}

body[data-ui-theme="modern-polished"] .student-search-item {
    border-radius: 8px;
    font-weight: 500;
}

body[data-ui-theme="modern-polished"] .student-search-item:hover {
    background: #eff6ff;
}

body[data-ui-theme="modern-polished"] .timeline::before {
    background: linear-gradient(180deg, #dbeafe 0%, #bfdbfe 100%);
}

body[data-ui-theme="modern-polished"] .timeline-marker {
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.14);
}

body[data-ui-theme="modern-polished"] .timeline-content {
    border: 1px solid rgba(148, 163, 184, 0.16);
    border-radius: 12px;
    background: linear-gradient(130deg, #ffffff 0%, #f8fbff 100%);
}

body[data-ui-theme="modern-polished"] .metric-card {
    border-color: rgba(148, 163, 184, 0.2) !important;
    border-radius: 12px !important;
    background: linear-gradient(130deg, #ffffff 0%, #f9fbff 100%);
}

body[data-ui-theme="modern-polished"] .summary-stat {
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px !important;
    background: linear-gradient(130deg, #ffffff 0%, #f9fbff 100%) !important;
}

body[data-ui-theme="modern-polished"] .card-clickable:hover {
    background: #eff6ff !important;
}

body[data-ui-theme="modern-polished"] .stat-card {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(255,255,255,0.98) 0%, #f6faff 52%, #eef6ff 100%);
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.09);
}

body[data-ui-theme="modern-polished"] .stat-card:hover {
    border-color: rgba(37, 99, 235, 0.24);
    box-shadow: 0 14px 32px rgba(37, 99, 235, 0.14);
}

body[data-ui-theme="modern-polished"] .stat-icon {
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.15);
}

body[data-ui-theme="modern-polished"] .stat-number {
    letter-spacing: -0.02em;
}

body[data-ui-theme="modern-polished"] .batch-metric {
    border: 1px solid rgba(148, 163, 184, 0.2);
    border-radius: 12px;
    background: linear-gradient(130deg, #ffffff 0%, #f9fbff 100%);
}

body[data-ui-theme="modern-polished"] .batch-metric-label {
    color: #64748b;
}

body[data-ui-theme="modern-polished"] .batch-metric-value {
    color: #0f172a;
}

body[data-ui-theme="modern-polished"] .sms-segmented {
    border-radius: 14px;
    border-color: rgba(148, 163, 184, 0.26);
    background: #fff;
}

body[data-ui-theme="modern-polished"] .navbar-brand {
    font-weight: 800;
    letter-spacing: -0.02em;
}

body[data-ui-theme="modern-polished"].auth-page {
    background:
        radial-gradient(circle at 10% 10%, rgba(37, 99, 235, 0.14), transparent 32%),
        radial-gradient(circle at 90% 0%, rgba(8, 145, 178, 0.12), transparent 34%),
        linear-gradient(180deg, #f8fbff 0%, #eef4fb 100%);
}

body[data-ui-theme="modern-polished"].auth-page .auth-shell,
body[data-ui-theme="modern-polished"].auth-page .login-container {
    position: relative;
}

body[data-ui-theme="modern-polished"].auth-page .auth-card,
body[data-ui-theme="modern-polished"].auth-page .login-container .card {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 24px;
    box-shadow: 0 26px 60px rgba(15, 23, 42, 0.14);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(12px);
}

body[data-ui-theme="modern-polished"].auth-page h3 {
    font-size: clamp(2.2rem, 4vw, 3rem);
    letter-spacing: -0.04em;
}

body[data-ui-theme="modern-polished"].auth-page .text-muted {
    color: #52627a !important;
}

body[data-ui-theme="modern-polished"].auth-page .auth-brand-mark {
    width: 88px;
    height: 88px;
    margin-inline: auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 28px;
    background: linear-gradient(135deg, rgba(11, 94, 215, 0.14), rgba(8, 145, 178, 0.16));
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.75);
}

body[data-ui-theme="modern-polished"].auth-page .card-header {
    border-radius: 24px 24px 0 0 !important;
    background: linear-gradient(135deg, #0b5ed7 0%, #2563eb 55%, #0891b2 100%) !important;
    color: #fff;
}

body[data-ui-theme="modern-polished"].auth-page .btn-primary {
    min-height: 48px;
}

body[data-ui-theme="modern-polished"].public-landing {
    background:
        radial-gradient(circle at 8% 12%, rgba(37, 99, 235, 0.16), transparent 34%),
        radial-gradient(circle at 86% 4%, rgba(8, 145, 178, 0.12), transparent 32%),
        linear-gradient(180deg, #f8fbff 0%, #eef4fb 100%);
}

body[data-ui-theme="modern-polished"].public-landing .public-nav {
    backdrop-filter: blur(16px);
}

body[data-ui-theme="modern-polished"].public-landing .public-browser-frame {
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.05), rgba(37, 99, 235, 0.06));
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.14);
}

body[data-ui-theme="modern-polished"].public-landing .public-feature-card {
    background: rgba(255,255,255,0.92);
    border-color: rgba(148, 163, 184, 0.18);
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

body[data-ui-theme="modern-polished"].public-landing .public-feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 22px 46px rgba(37, 99, 235, 0.14);
}

body[data-ui-theme="modern-polished"]::before,
body[data-ui-theme="modern-polished"]::after {
    content: "";
    position: fixed;
    inset: auto;
    pointer-events: none;
    z-index: 0;
    filter: blur(2px);
}

body[data-ui-theme="modern-polished"]::before {
    top: -8rem;
    right: -4rem;
    width: 22rem;
    height: 22rem;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.16) 0%, rgba(37, 99, 235, 0) 72%);
}

body[data-ui-theme="modern-polished"]::after {
    left: -7rem;
    bottom: -8rem;
    width: 26rem;
    height: 26rem;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(8, 145, 178, 0.14) 0%, rgba(8, 145, 178, 0) 74%);
}

body[data-ui-theme="modern-polished"] .navbar {
    position: relative;
    isolation: isolate;
}

body[data-ui-theme="modern-polished"] .navbar::after {
    content: "";
    position: absolute;
    left: 1.1rem;
    right: 1.1rem;
    bottom: -1px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(11, 94, 215, 0.16) 0%, rgba(37, 99, 235, 0.7) 38%, rgba(8, 145, 178, 0.78) 100%);
    opacity: 0.68;
    z-index: -1;
}

body[data-ui-theme="modern-polished"] .navbar-brand {
    background-image: var(--gradient-primary);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent !important;
    text-shadow: none;
}

body[data-ui-theme="modern-polished"] .navbar .nav-link.active {
    background: linear-gradient(135deg, rgba(11, 94, 215, 0.10), rgba(8, 145, 178, 0.10));
    box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.14);
}

body[data-ui-theme="modern-polished"] .card.shadow,
body[data-ui-theme="modern-polished"] .card.shadow-sm {
    border-color: rgba(203, 213, 225, 0.7);
    box-shadow: 0 24px 50px rgba(15, 23, 42, 0.08), 0 8px 20px rgba(37, 99, 235, 0.04);
}

body[data-ui-theme="modern-polished"] .card-header h5,
body[data-ui-theme="modern-polished"] .card-header h6,
body[data-ui-theme="modern-polished"] .card-header .m-0,
body[data-ui-theme="modern-polished"] .card-header .card-title {
    font-weight: 800;
    letter-spacing: -0.015em;
}

body[data-ui-theme="modern-polished"] .card-header .text-primary,
body[data-ui-theme="modern-polished"] .card-header .font-weight-bold.text-primary {
    color: #134a9f !important;
}

body[data-ui-theme="modern-polished"] .dashboard-welcome {
    position: relative;
    overflow: hidden;
    padding: 1.7rem 1.8rem;
    border: 1px solid rgba(203, 213, 225, 0.75);
    border-radius: 26px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.97) 0%, rgba(244, 249, 255, 0.98) 60%, rgba(236, 246, 255, 0.94) 100%),
        linear-gradient(120deg, rgba(11, 94, 215, 0.04), rgba(8, 145, 178, 0.05));
    box-shadow: 0 26px 54px rgba(15, 23, 42, 0.08);
}

body[data-ui-theme="modern-polished"] .dashboard-welcome::after {
    content: "";
    position: absolute;
    top: -4rem;
    right: -3rem;
    width: 14rem;
    height: 14rem;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.12) 0%, rgba(37, 99, 235, 0) 72%);
    pointer-events: none;
}

body[data-ui-theme="modern-polished"] .dashboard-welcome h1,
body[data-ui-theme="modern-polished"] .dashboard-welcome .h2 {
    margin-bottom: 0.35rem !important;
    font-size: clamp(2rem, 3.4vw, 3rem);
    line-height: 1.04;
}

body[data-ui-theme="modern-polished"] .dashboard-welcome p.text-muted {
    max-width: 46rem;
    font-size: 1rem;
    line-height: 1.68;
    color: #475569 !important;
}

body[data-ui-theme="modern-polished"] .admin-context-hero {
    border: none !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0.5rem 0 1rem 0 !important;
}

body[data-ui-theme="modern-polished"] .admin-context-kicker {
    color: #0f4bb4 !important;
}

body[data-ui-theme="modern-polished"] .admin-context-title {
    letter-spacing: -0.04em;
}

body[data-ui-theme="modern-polished"] .admin-context-subtitle {
    color: #475569 !important;
}

body[data-ui-theme="modern-polished"] .admin-context-chip {
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(247, 250, 255, 0.98)) !important;
    border-color: rgba(203, 213, 225, 0.82) !important;
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.05), inset 0 1px 0 rgba(255,255,255,0.92);
}

body[data-ui-theme="modern-polished"] .admin-context-chip-label {
    color: #64748b;
    letter-spacing: 0.06em;
}

body[data-ui-theme="modern-polished"] .admin-context-chip-value {
    color: #0f172a;
}

body[data-ui-theme="modern-polished"] .stat-card,
body[data-ui-theme="modern-polished"] .metric-card,
body[data-ui-theme="modern-polished"] .summary-stat,
body[data-ui-theme="modern-polished"] .batch-metric,
body[data-ui-theme="modern-polished"] .focus-mini-card {
    position: relative;
    overflow: hidden;
}

body[data-ui-theme="modern-polished"] .stat-card::before,
body[data-ui-theme="modern-polished"] .metric-card::before,
body[data-ui-theme="modern-polished"] .summary-stat::before,
body[data-ui-theme="modern-polished"] .batch-metric::before,
body[data-ui-theme="modern-polished"] .focus-mini-card::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #0b5ed7, #2563eb 58%, #0891b2);
    opacity: 0.92;
}

body[data-ui-theme="modern-polished"] .stat-icon {
    background: linear-gradient(135deg, rgba(11, 94, 215, 0.16), rgba(8, 145, 178, 0.18));
    border-radius: 18px;
}

body[data-ui-theme="modern-polished"] .stat-label,
body[data-ui-theme="modern-polished"] .batch-metric-label,
body[data-ui-theme="modern-polished"] .focus-mini-card small {
    letter-spacing: 0.04em;
    color: #64748b !important;
}

body[data-ui-theme="modern-polished"] .focus-mini-card {
    padding: 1rem 1.05rem;
    border: 1px solid rgba(203, 213, 225, 0.72);
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(245, 249, 255, 0.98));
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.06);
}

body[data-ui-theme="modern-polished"] .action-card {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
    background: linear-gradient(140deg, rgba(255,255,255,0.98), rgba(244, 249, 255, 1));
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
}

body[data-ui-theme="modern-polished"] .action-card::after {
    content: "";
    position: absolute;
    top: -1.7rem;
    right: -1.7rem;
    width: 4.5rem;
    height: 4.5rem;
    border-radius: 999px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.18), rgba(37, 99, 235, 0));
    pointer-events: none;
}

body[data-ui-theme="modern-polished"] .table-responsive {
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(10px);
}

body[data-ui-theme="modern-polished"] .table {
    margin-bottom: 0;
}

body[data-ui-theme="modern-polished"].page-project-evaluation .card,
body[data-ui-theme="modern-polished"].page-project-evaluation-migration .card {
    overflow: visible;
}

body[data-ui-theme="modern-polished"].page-project-evaluation .navbar,
body[data-ui-theme="modern-polished"].page-project-evaluation-migration .navbar {
    z-index: 5000 !important;
    isolation: isolate;
}

body[data-ui-theme="modern-polished"].page-project-evaluation .dropdown-menu,
body[data-ui-theme="modern-polished"].page-project-evaluation-migration .dropdown-menu {
    z-index: 5100 !important;
}

body[data-ui-theme="modern-polished"].page-project-evaluation .table-responsive,
body[data-ui-theme="modern-polished"].page-project-evaluation-migration .table-responsive {
    overflow-x: auto;
    overflow-y: visible;
}

body[data-ui-theme="modern-polished"].page-project-evaluation .table td,
body[data-ui-theme="modern-polished"].page-project-evaluation .table th,
body[data-ui-theme="modern-polished"].page-project-evaluation-migration .table td,
body[data-ui-theme="modern-polished"].page-project-evaluation-migration .table th {
    position: relative;
}

body[data-ui-theme="modern-polished"] .table th {
    color: #234062;
    text-transform: uppercase;
    position: sticky;
    top: 0;
    z-index: 10;
}

body[data-ui-theme="modern-polished"] .table tbody tr {
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}

body[data-ui-theme="modern-polished"] .table-hover > tbody > tr:hover {
    transform: translateY(-1px);
    box-shadow: inset 0 0 0 999px rgba(37, 99, 235, 0.03);
}

body[data-ui-theme="modern-polished"] .btn-primary,
body[data-ui-theme="modern-polished"] .btn-success,
body[data-ui-theme="modern-polished"] .btn-danger,
body[data-ui-theme="modern-polished"] .btn-warning,
body[data-ui-theme="modern-polished"] .btn-outline-primary,
body[data-ui-theme="modern-polished"] .btn-outline-secondary,
body[data-ui-theme="modern-polished"] .btn-light {
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, color .18s ease;
}

body[data-ui-theme="modern-polished"] .btn-primary:hover,
body[data-ui-theme="modern-polished"] .btn-success:hover,
body[data-ui-theme="modern-polished"] .btn-danger:hover,
body[data-ui-theme="modern-polished"] .btn-warning:hover {
    transform: translateY(-1px);
    box-shadow: 0 18px 34px rgba(37, 99, 235, 0.22);
}

body[data-ui-theme="modern-polished"] .btn-outline-primary,
body[data-ui-theme="modern-polished"] .btn-outline-secondary {
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(8px);
}

body[data-ui-theme="modern-polished"] .btn-outline-primary:hover,
body[data-ui-theme="modern-polished"] .btn-outline-secondary:hover,
body[data-ui-theme="modern-polished"] .btn-light:hover {
    background: var(--primary) !important;
    color: #fff !important;
    transform: translateY(-1px);
}

body[data-ui-theme="modern-polished"] .alert-info {
    background: linear-gradient(135deg, rgba(224, 242, 254, 0.95), rgba(240, 249, 255, 0.95));
    border-color: rgba(125, 211, 252, 0.5);
}

body[data-ui-theme="modern-polished"] .alert-success {
    background: linear-gradient(135deg, rgba(220, 252, 231, 0.96), rgba(240, 253, 244, 0.96));
    border-color: rgba(134, 239, 172, 0.55);
}

body[data-ui-theme="modern-polished"] .alert-warning {
    background: linear-gradient(135deg, rgba(254, 249, 195, 0.96), rgba(255, 251, 235, 0.96));
    border-color: rgba(253, 224, 71, 0.55);
}

body[data-ui-theme="modern-polished"] .alert-danger {
    background: linear-gradient(135deg, rgba(254, 226, 226, 0.96), rgba(255, 241, 242, 0.96));
    border-color: rgba(252, 165, 165, 0.55);
}

body[data-ui-theme="modern-polished"] .entry-layout-protected .form-control,
body[data-ui-theme="modern-polished"] .entry-layout-protected .form-select,
body[data-ui-theme="modern-polished"] .entry-layout-protected .btn,
body[data-ui-theme="modern-polished"] .entry-layout-protected .table-responsive,
body[data-ui-theme="modern-polished"] .entry-layout-protected .table th,
body[data-ui-theme="modern-polished"] .entry-layout-protected .table td {
    transition: none;
}

body[data-ui-theme="modern-polished"].page-dashboard .card {
    border-color: rgba(203, 213, 225, 0.78);
    box-shadow: 0 22px 46px rgba(15, 23, 42, 0.075), 0 8px 20px rgba(37, 99, 235, 0.035);
}

body[data-ui-theme="modern-polished"].page-dashboard .card-header {
    position: relative;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

body[data-ui-theme="modern-polished"].page-dashboard .card-header::before {
    content: "";
    position: absolute;
    left: 1.1rem;
    right: 1.1rem;
    top: 0;
    height: 4px;
    border-radius: 999px;
    background: linear-gradient(90deg, #0b5ed7 0%, #2563eb 58%, #0891b2 100%);
    opacity: 0.9;
}

body[data-ui-theme="modern-polished"].page-dashboard .card-header h5,
body[data-ui-theme="modern-polished"].page-dashboard .card-header h6,
body[data-ui-theme="modern-polished"].page-dashboard .card-header .m-0 {
    color: #12385f !important;
}

body[data-ui-theme="modern-polished"].page-dashboard .table-responsive {
    border-radius: 16px;
}

body[data-ui-theme="modern-polished"].page-dashboard .table th {
    font-size: 0.76rem;
    letter-spacing: 0.085em;
}

body[data-ui-theme="modern-polished"].page-dashboard .table td {
    vertical-align: middle;
}

body[data-ui-theme="modern-polished"].role-admin.page-dashboard .stat-card {
    padding: 2rem 1.5rem;
}

body[data-ui-theme="modern-polished"].role-admin.page-dashboard .avatar-sm {
    border: 2px solid rgba(255, 255, 255, 0.96);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.12);
}

body[data-ui-theme="modern-polished"].role-admin.page-dashboard .batch-card {
    border: 1px solid rgba(203, 213, 225, 0.82);
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(255,255,255,0.98), rgba(246, 250, 255, 0.98));
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.07);
}

body[data-ui-theme="modern-polished"].role-admin.page-dashboard .batch-header {
    border-bottom-color: rgba(191, 219, 254, 0.72);
}

body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .action-card:not(.action-card--compact) {
    min-height: 126px;
}

body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .action-card span {
    font-weight: 700;
    letter-spacing: -0.01em;
}

body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .focus-mini-card strong {
    font-size: 1.35rem;
    letter-spacing: -0.025em;
    color: #0f172a;
}

body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .focus-mini-card strong.text-success {
    color: #15803d !important;
}

body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .focus-mini-card strong.text-warning {
    color: #a16207 !important;
}

body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .modal-content {
    border-radius: 22px;
    box-shadow: 0 26px 58px rgba(15, 23, 42, 0.14);
}

body[data-ui-theme="modern-polished"].role-student.page-dashboard .card-header {
    background: linear-gradient(120deg, rgba(255,255,255,0.98) 0%, rgba(244, 248, 255, 0.98) 50%, rgba(237, 247, 255, 0.96) 100%);
}

body[data-ui-theme="modern-polished"].role-student.page-dashboard .card-body h5 {
    font-weight: 800;
    letter-spacing: -0.015em;
}

body[data-ui-theme="modern-polished"].role-student.page-dashboard .progress {
    height: 12px;
    background: linear-gradient(90deg, #e7eef8, #edf3fb);
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.06);
}

body[data-ui-theme="modern-polished"].role-student.page-dashboard .progress .progress-bar {
    font-size: 0.67rem;
    font-weight: 700;
    line-height: 12px;
}

body[data-ui-theme="modern-polished"].role-student.page-dashboard .btn-sm.btn-primary,
body[data-ui-theme="modern-polished"].role-student.page-dashboard .btn-sm.btn-outline-primary {
    min-height: 36px;
    padding-inline: 0.9rem;
}

/* Mobile refinements */
@media screen and (max-width: 991.98px) {
    body[data-ui-theme="modern-polished"] .container,
    body[data-ui-theme="modern-polished"] .container-fluid {
        padding-left: 0.8rem;
        padding-right: 0.8rem;
    }

    body[data-ui-theme="modern-polished"] .navbar-brand {
        font-size: 1.25rem;
    }

    body[data-ui-theme="modern-polished"] .navbar .nav-link {
        padding: 0.55rem 0.75rem !important;
    }

    body[data-ui-theme="modern-polished"] .card-body {
        padding: 1.25rem;
    }

    body[data-ui-theme="modern-polished"] .card-header {
        padding: 1rem 1.15rem;
    }

    body[data-ui-theme="modern-polished"] .dashboard-welcome {
        padding: 1.35rem 1.15rem;
        border-radius: 20px;
    }

    body[data-ui-theme="modern-polished"] .btn {
        min-height: 42px;
    }

    body[data-ui-theme="modern-polished"] .btn.btn-sm,
    body[data-ui-theme="modern-polished"] .btn-sm {
        min-height: 30px !important;
        padding: 0.25rem 0.6rem !important;
        font-size: 0.78rem !important;
    }

    body[data-ui-theme="modern-polished"] .table th,
    body[data-ui-theme="modern-polished"] .table td {
        padding: 0.8rem 0.65rem;
    }

    body[data-ui-theme="modern-polished"] .nav-tabs {
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        white-space: nowrap;
    }

    body[data-ui-theme="modern-polished"] .nav-tabs .nav-item {
        flex: 0 0 auto;
    }

    body[data-ui-theme="modern-polished"] .stat-card {
        border-radius: 14px;
    }

    body[data-ui-theme="modern-polished"] .action-card,
    body[data-ui-theme="modern-polished"] .course-card {
        border-radius: 12px;
    }

    body[data-ui-theme="modern-polished"] .breadcrumb {
        padding: 0.48rem 0.75rem;
    }

    body[data-ui-theme="modern-polished"] .admin-context-hero {
        border-radius: 22px !important;
    }

    body[data-ui-theme="modern-polished"] .focus-mini-card {
        padding: 0.9rem 0.95rem;
    }

    body[data-ui-theme="modern-polished"].page-dashboard .dashboard-welcome h1,
    body[data-ui-theme="modern-polished"].page-dashboard .dashboard-welcome .h2 {
        font-size: 1.8rem;
    }

    body[data-ui-theme="modern-polished"].page-dashboard .card-header::before {
        left: 0.9rem;
        right: 0.9rem;
    }

    body[data-ui-theme="modern-polished"].role-teacher.page-dashboard .action-card:not(.action-card--compact) {
        min-height: 108px;
    }

    body[data-ui-theme="modern-polished"].role-student.page-dashboard .table th,
    body[data-ui-theme="modern-polished"].role-student.page-dashboard .table td {
        padding: 0.72rem 0.6rem;
    }

    body[data-ui-theme="modern-polished"] .modal-dialog {
        margin: 0.6rem;
    }
}

/* Dark Mode Theme */
html.dark-mode,
html.dark-mode body,
html body.dark-mode {
    --primary: #818cf8;
    --primary-light: #a5b4fc;
    --primary-dark: #6366f1;
    --success: #34d399;
    --success-light: #6ee7b7;
    --warning: #fbbf24;
    --warning-light: #fcd34d;
    --danger: #f87171;
    --danger-light: #fca5a5;
    --info: #22d3ee;
    --info-light: #67e8f9;
    --light: #0f172a;
    --light-gray: #1e293b;
    --dark: #f1f5f9;
    --dark-gray: #94a3b8;
    --border: #334155;
    --border-light: #1e293b;
    --bs-secondary-color: #94a3b8;
    --shadow: 0 1px 3px 0 rgb(0 0 0 / 0.3);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.4);
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #818cf8 100%);
    --gradient-success: linear-gradient(135deg, #10b981 0%, #34d399 100%);
    --gradient-bg: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color-scheme: dark;
    background: var(--light);
    color: var(--dark);
}

html body.dark-mode .navbar {
    background: rgba(15, 23, 42, 0.95) !important;
    border-bottom: 1px solid rgba(51, 65, 85, 0.8);
}

html body.dark-mode .sidebar-user-name,
html body.dark-mode .sidebar-brand,
body.dark-mode .sidebar-user-name,
body.dark-mode .sidebar-brand {
    color: #f8fafc !important;
}

html body.dark-mode .navbar-brand {
    color: var(--primary) !important;
}

html body.dark-mode .nav-link {
    color: var(--dark) !important;
}

html body.dark-mode .nav-link:hover {
    background: rgba(129, 140, 248, 0.1);
}

html body.dark-mode .card {
    background: #1e293b;
    border: 1px solid rgba(51, 65, 85, 0.8);
}

html body.dark-mode .card-header {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border-bottom: 1px solid rgba(51, 65, 85, 0.8);
    color: var(--dark);
}

html body.dark-mode .card-header::before {
    background: linear-gradient(90deg, var(--primary) 0%, var(--primary-light) 100%);
}

html body.dark-mode .table {
    background: #1e293b;
    --bs-table-bg: #1e293b;
    --bs-table-color: #f1f5f9;
    --bs-table-border-color: #334155;
    --bs-table-striped-bg: rgba(255,255,255,0.02);
}

html body.dark-mode .table th {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: var(--dark);
}

html body.dark-mode .table td {
    border-bottom: 1px solid rgba(51, 65, 85, 0.5);
}

html body.dark-mode .table > :not(caption) > * > * {
    background-color: var(--bs-table-bg) !important;
    color: var(--bs-table-color) !important;
    border-color: var(--bs-table-border-color) !important;
}

html body.dark-mode .table > thead > tr > th {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%) !important;
    color: var(--dark) !important;
}

html body.dark-mode .table > tbody > tr > td,
html body.dark-mode .table > tbody > tr > th {
    background-color: #1e293b !important;
    color: #f1f5f9 !important;
}

html body.dark-mode .table-hover tbody tr:hover {
    background: rgba(129, 140, 248, 0.05);
}

html body.dark-mode .table-hover > tbody > tr:hover > * {
    background-color: rgba(51, 65, 85, 0.96) !important;
    color: #f8fafc !important;
}

html body.dark-mode .table-light {
    --bs-table-bg: #0f172a;
    --bs-table-color: var(--dark);
    --bs-table-border-color: #334155;
}

html body.dark-mode .table-danger {
    --bs-table-bg: rgba(248, 113, 113, 0.1);
    --bs-table-color: #fca5a5;
}

html body.dark-mode .table-secondary {
    --bs-table-bg: rgba(148, 163, 184, 0.1);
    --bs-table-color: #cbd5e1;
}

html body.dark-mode .table-striped > tbody > tr:nth-of-type(odd) > * {
    --bs-table-bg: rgba(255, 255, 255, 0.02);
    color: var(--dark);
}

html body.dark-mode .table-bordered {
    border-color: #334155;
}

html body.dark-mode .table-bordered th,
html body.dark-mode .table-bordered td {
    border-color: #334155;
}

html body.dark-mode .form-control,
html body.dark-mode .form-select {
    background: #1e293b;
    border-color: #334155;
    color: var(--dark);
}

html body.dark-mode .form-control:focus,
html body.dark-mode .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(129, 140, 248, 0.15);
}

html body.dark-mode .form-label {
    color: var(--dark);
}

html body.dark-mode .dropdown-menu {
    background: #1e293b;
    border: 1px solid rgba(51, 65, 85, 0.8);
}

html body.dark-mode .dropdown-item {
    color: var(--dark);
}

html body.dark-mode .dropdown-item:hover {
    background: rgba(129, 140, 248, 0.1);
}

html body.dark-mode .modal-content {
    background: #1e293b;
    border: 1px solid rgba(51, 65, 85, 0.8);
}

html body.dark-mode .modal-header,
html body.dark-mode .modal-footer {
    border-color: #334155;
}

html body.dark-mode .badge {
    box-shadow: none;
}

html body.dark-mode .alert {
    border: 1px solid rgba(51, 65, 85, 0.8);
}

html body.dark-mode .border,
html body.dark-mode .border-top,
html body.dark-mode .border-bottom,
html body.dark-mode .border-start,
html body.dark-mode .border-end,
body.dark-mode .border,
body.dark-mode .border-top,
body.dark-mode .border-bottom,
body.dark-mode .border-start,
body.dark-mode .border-end {
    border-color: #334155 !important;
}

html body.dark-mode .text-dark,
body.dark-mode .text-dark,
html body.dark-mode [class*="text-dark"],
body.dark-mode [class*="text-dark"] {
    color: #f1f5f9 !important;
}

html body.dark-mode .text-muted,
body.dark-mode .text-muted {
    color: #94a3b8 !important;
}

html body.dark-mode .text-secondary,
body.dark-mode .text-secondary {
    color: #cbd5e1 !important;
}

html body.dark-mode .form-text,
body.dark-mode .form-text {
    color: #94a3b8 !important;
}

html body.dark-mode .bg-white,
body.dark-mode .bg-white,
html body.dark-mode [class*="bg-white"],
body.dark-mode [class*="bg-white"] {
    background-color: #1e293b !important;
    color: #f1f5f9 !important;
}

html body.dark-mode .bg-light,
body.dark-mode .bg-light,
html body.dark-mode [class*="bg-light"],
body.dark-mode [class*="bg-light"] {
    background-color: #0f172a !important;
    color: #f1f5f9 !important;
    border-color: #334155 !important;
}

/* Subtle Badges in Dark Mode */
html body.dark-mode .bg-primary-subtle,
body.dark-mode .bg-primary-subtle {
    background-color: rgba(14, 165, 233, 0.18) !important;
    color: #38bdf8 !important;
    border-color: rgba(14, 165, 233, 0.3) !important;
}

html body.dark-mode .bg-secondary-subtle,
body.dark-mode .bg-secondary-subtle {
    background-color: rgba(148, 163, 184, 0.16) !important;
    color: #cbd5e1 !important;
    border-color: rgba(148, 163, 184, 0.25) !important;
}

html body.dark-mode .bg-success-subtle,
body.dark-mode .bg-success-subtle {
    background-color: rgba(34, 197, 94, 0.18) !important;
    color: #4ade80 !important;
    border-color: rgba(34, 197, 94, 0.3) !important;
}

html body.dark-mode .bg-warning-subtle,
body.dark-mode .bg-warning-subtle {
    background-color: rgba(234, 179, 8, 0.18) !important;
    color: #facc15 !important;
    border-color: rgba(234, 179, 8, 0.3) !important;
}

html body.dark-mode .bg-danger-subtle,
body.dark-mode .bg-danger-subtle {
    background-color: rgba(239, 68, 68, 0.18) !important;
    color: #f87171 !important;
    border-color: rgba(239, 68, 68, 0.3) !important;
}

html body.dark-mode .bg-info-subtle,
body.dark-mode .bg-info-subtle {
    background-color: rgba(6, 182, 212, 0.18) !important;
    color: #22d3ee !important;
    border-color: rgba(6, 182, 212, 0.3) !important;
}

/* Sidebar Badges (Sidebar Navigation) */
.sidebar-item .badge.bg-secondary-subtle,
.sidebar-item .badge.bg-light,
.sidebar-item .badge.sidebar-badge-muted {
    background-color: rgba(255, 255, 255, 0.1) !important;
    color: #94a3b8 !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    font-weight: 500;
    letter-spacing: 0.03em;
}

body.dark-mode .sidebar-item .badge.bg-secondary-subtle,
body.dark-mode .sidebar-item .badge.bg-light,
body.dark-mode .sidebar-item .badge.sidebar-badge-muted {
    background-color: rgba(148, 163, 184, 0.15) !important;
    color: #cbd5e1 !important;
    border: 1px solid rgba(148, 163, 184, 0.22) !important;
}

html body.dark-mode .header-date-badge,
body.dark-mode .header-date-badge {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #f1f5f9 !important;
}

html body.dark-mode .header-date-badge .text-dark,
body.dark-mode .header-date-badge .text-dark {
    color: #f1f5f9 !important;
}

html body.dark-mode .header-date-badge .text-secondary,
body.dark-mode .header-date-badge .text-secondary {
    color: #94a3b8 !important;
}

html body.dark-mode h1,
html body.dark-mode h2,
html body.dark-mode h3,
html body.dark-mode h4,
html body.dark-mode h5,
html body.dark-mode h6 {
    color: #f1f5f9 !important;
}

html body.dark-mode .card-body {
    color: var(--dark);
}

html body.dark-mode .empty-state h5 {
    color: var(--dark);
}

html body.dark-mode .empty-state p {
    color: var(--dark-gray);
}

html body.dark-mode .btn-outline-primary {
    border-color: var(--primary);
    color: var(--primary);
}
html body.dark-mode .btn-outline-primary:hover {
    background: var(--primary);
    color: #fff;
}

html body.dark-mode .btn-secondary {
    background: #1e293b;
    border-color: #334155;
    color: var(--dark);
}
html body.dark-mode .btn-secondary:hover {
    background: #0f172a;
    border-color: #475569;
    color: var(--dark);
}

html body.dark-mode .btn-outline-secondary {
    border-color: #475569;
    color: #94a3b8;
}
html body.dark-mode .btn-outline-secondary:hover {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

html body.dark-mode .btn-light {
    background: #1e293b;
    border-color: #334155;
    color: var(--dark);
}

html body.dark-mode .btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, color-mix(in srgb, var(--primary) 70%, var(--light)) 100%);
    color: #fff;
}
html body.dark-mode .btn-primary:hover {
    background: linear-gradient(135deg, color-mix(in srgb, var(--primary) 70%, var(--light)) 0%, var(--primary) 100%);
}
html body.dark-mode .btn-success {
    background: linear-gradient(135deg, var(--success) 0%, color-mix(in srgb, var(--success) 70%, #000) 100%);
    color: #fff;
}
html body.dark-mode .btn-success:hover {
    background: linear-gradient(135deg, color-mix(in srgb, var(--success) 70%, #000) 0%, var(--success) 100%);
}
html body.dark-mode .btn-warning {
    background: linear-gradient(135deg, var(--warning) 0%, color-mix(in srgb, var(--warning) 70%, #000) 100%);
    color: #0f172a;
}
html body.dark-mode .btn-warning:hover {
    background: linear-gradient(135deg, color-mix(in srgb, var(--warning) 70%, #000) 0%, var(--warning) 100%);
}
html body.dark-mode .btn-danger {
    background: linear-gradient(135deg, var(--danger) 0%, color-mix(in srgb, var(--danger) 70%, #000) 100%);
    color: #fff;
}
html body.dark-mode .btn-danger:hover {
    background: linear-gradient(135deg, color-mix(in srgb, var(--danger) 70%, #000) 0%, var(--danger) 100%);
}
html body.dark-mode .btn-info {
    background: linear-gradient(135deg, var(--info) 0%, color-mix(in srgb, var(--info) 70%, #000) 100%);
    color: #fff;
}
html body.dark-mode .btn-info:hover {
    background: linear-gradient(135deg, color-mix(in srgb, var(--info) 70%, #000) 0%, var(--info) 100%);
}

html body.dark-mode .list-group-item {
    background: #1e293b;
    border-color: #334155;
    color: var(--dark);
}

html body.dark-mode .page-link {
    background: #1e293b;
    border-color: #334155;
    color: var(--dark);
}

html body.dark-mode .page-item.active .page-link {
    background: var(--gradient-primary);
    border-color: var(--primary);
}

html body.dark-mode .progress {
    background: #0f172a;
}

html body.dark-mode .breadcrumb {
    background: rgba(15, 23, 42, 0.75);
}

html body.dark-mode .nav-tabs .nav-link {
    color: #94a3b8;
}

html body.dark-mode .nav-tabs .nav-link.active {
    background: #1e293b;
    border-color: #334155 #334155 #1e293b;
    color: #fff;
}

html body.dark-mode .attendance-view-tabs .nav-link.active {
    color: #fff !important;
    --bs-nav-link-color: #fff;
    --bs-nav-pills-link-active-color: #fff;
    -webkit-text-fill-color: #fff;
    text-shadow: none;
    opacity: 1;
}

body[data-ui-theme] .attendance-view-tabs .nav-link:not(.active) {
    color: #334155 !important;
    --bs-nav-link-color: #334155;
    opacity: 1;
}

body[data-ui-theme] .attendance-view-tabs .nav-link.active {
    color: #fff !important;
    --bs-nav-link-color: #fff;
    --bs-nav-pills-link-active-color: #fff;
    -webkit-text-fill-color: #fff;
    text-shadow: none;
    opacity: 1;
}

html body.dark-mode .stat-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.98) 0%, rgba(15, 23, 42, 0.98) 100%);
    border-color: rgba(51, 65, 85, 0.8);
}

html body.dark-mode .stat-card-inline {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.98) 0%, rgba(15, 23, 42, 0.98) 100%);
    border-color: rgba(51, 65, 85, 0.8);
}
html body.dark-mode .stat-card-inline .h5 {
    color: var(--dark) !important;
}
html body.dark-mode .stat-card-inline .col-auto i {
    color: var(--dark-gray);
    opacity: 0.4;
}
html body.dark-mode .stat-card-inline .text-xs {
    color: var(--primary-light) !important;
}
html body.dark-mode .stat-card-inline .text-xs.text-success { color: var(--success) !important; }
html body.dark-mode .stat-card-inline .text-xs.text-warning { color: var(--warning) !important; }
html body.dark-mode .stat-card-inline .text-xs.text-danger { color: var(--danger) !important; }
html body.dark-mode .stat-card-inline .text-xs.text-info { color: var(--info) !important; }

html body.dark-mode .stat-icon {
    background: color-mix(in srgb, var(--primary) 12%, transparent);
}

html body.dark-mode .dashboard-hero {
    background: radial-gradient(circle at top right, rgba(129, 140, 248, 0.08), transparent 28%),
                linear-gradient(180deg, rgba(30, 41, 59, 0.97), rgba(15, 23, 42, 0.98));
    border-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .admin-context-hero {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

html body.dark-mode .dashboard-kicker {
    background: rgba(129, 140, 248, 0.15);
    color: var(--primary);
}

html body.dark-mode .admin-context-kicker {
    background: color-mix(in srgb, var(--primary) 15%, transparent);
    border-color: color-mix(in srgb, var(--primary) 20%, transparent);
    color: var(--primary-light);
}

html body.dark-mode .dashboard-meta-chip,
html body.dark-mode .admin-context-chip {
    background: rgba(30, 41, 59, 0.9);
    border-color: rgba(51, 65, 85, 0.6);
    color: var(--dark);
}

html body.dark-mode .action-card {
    background: #1e293b;
    border-color: rgba(51, 65, 85, 0.6);
    color: var(--dark);
}

html body.dark-mode .action-card:hover {
    background: rgba(129, 140, 248, 0.08);
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
    border-color: rgba(129, 140, 248, 0.3);
}

html body.dark-mode .focus-mini-card {
    background: var(--light-gray) !important;
    border-color: var(--border) !important;
}

html body.dark-mode .avatar-sm,
html body.dark-mode .avatar-lg {
    background: linear-gradient(135deg, #6366f1 0%, #818cf8 100%);
}

html body.dark-mode .teacher-data-table thead th {
    background: #0f172a;
    color: var(--dark);
}

html body.dark-mode .auth-page .auth-card {
    background: rgba(30, 41, 59, 0.96);
    border: 1px solid rgba(51, 65, 85, 0.6);
}

html body.dark-mode.auth-page {
    background: radial-gradient(circle at 10% 10%, rgba(129, 140, 248, 0.08), transparent 32%),
                radial-gradient(circle at 90% 0%, rgba(99, 102, 241, 0.06), transparent 34%),
                linear-gradient(180deg, #0f172a 0%, #1e293b 100%) !important;
}

html body.dark-mode .auth-brand-mark {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2), rgba(129, 140, 248, 0.2));
}

html body.dark-mode ::-webkit-scrollbar-track {
    background: #0f172a;
}

html body.dark-mode ::-webkit-scrollbar-thumb {
    background: #334155;
}

html body.dark-mode ::-webkit-scrollbar-thumb:hover {
    background: var(--primary);
}

html body.dark-mode .table-responsive {
    border-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .hero-filter-card {
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.96), rgba(30, 41, 59, 0.98));
    border-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .dashboard-panel-card,
html body.dark-mode .resource-panel {
    background: #1e293b;
    border-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .section-kicker {
    color: #94a3b8;
}

html body.dark-mode .batch-card {
    background: #1e293b;
    border-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .batch-header {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-bottom-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .sms-footer {
    background: #0f172a !important;
    border-top: 1px solid rgba(51, 65, 85, 0.6);
}

html body.dark-mode .sms-segmented {
    border-color: #334155;
}

html body.dark-mode .sms-segmented .btn {
    background: #0f172a;
    color: #94a3b8;
    border-color: #334155;
}

html body.dark-mode .teacher-table-wrap {
    border-color: #334155;
    background: #1e293b;
}

html body.dark-mode.public-landing {
    background: #0f172a !important;
    color: #f1f5f9;
}
html body.dark-mode.public-landing .text-dark,
html body.dark-mode.public-landing .text-slate-900,
html body.dark-mode.public-landing h1,
html body.dark-mode.public-landing h2 {
    color: #f1f5f9 !important;
}
html body.dark-mode.public-landing .text-slate-700,
html body.dark-mode.public-landing .text-slate-600 {
    color: #94a3b8 !important;
}

html body.dark-mode .public-feature-card {
    background: rgba(30, 41, 59, 0.92);
    border-color: rgba(51, 65, 85, 0.6);
}

html body.dark-mode .public-nav span {
    color: #f1f5f9 !important;
}

/* Dark mode: catch remaining inline-style patterns */
@media screen {
html body.dark-mode .sheet-wrap,
html body.dark-mode .marksheet-page,
html body.dark-mode .admit-card-wrap {
    background: var(--light) !important;
    border-color: var(--border) !important;
    color: var(--dark) !important;
}
html body.dark-mode .sheet-wrap th,
html body.dark-mode .marksheet-page th {
    background: var(--light-gray) !important;
    color: var(--dark) !important;
    border-color: var(--border) !important;
}
html body.dark-mode .sheet-wrap td,
html body.dark-mode .marksheet-page td {
    border-color: var(--border) !important;
}
html body.dark-mode .external-table,
html body.dark-mode .external-table th,
html body.dark-mode .external-table td {
    border-color: var(--border) !important;
}
html body.dark-mode .external-table th {
    background: var(--light-gray) !important;
    color: var(--dark) !important;
}
html body.dark-mode .external-table td {
    color: var(--dark) !important;
}
html body.dark-mode .external-title,
html body.dark-mode .external-subject,
html body.dark-mode .external-footer,
html body.dark-mode .external-footer p,
html body.dark-mode .external-footer-block,
html body.dark-mode .external-footer-block p,
html body.dark-mode .external-footer-block span,
html body.dark-mode .signature-dots {
    color: var(--dark) !important;
}
}
html body.dark-mode .batch-stats {
    background: var(--light) !important;
}
html body.dark-mode .promotion-card {
    border-color: var(--border) !important;
}
html body.dark-mode .focus-mini-card {
    background: var(--light-gray) !important;
    border-color: var(--border) !important;
}
html body.dark-mode .search-dropdown-wrap {
    background: var(--light) !important;
    border-color: var(--border) !important;
}
html body.dark-mode .search-dropdown-wrap .search-item {
    background: var(--light) !important;
    color: var(--dark) !important;
}
html body.dark-mode .search-dropdown-wrap .search-item:hover {
    background: rgba(99, 102, 241, 0.1) !important;
}
html body.dark-mode .attendance-export-btn {
    background: #059669 !important;
    border-color: #059669 !important;
}

/* Dark mode: component gaps */
html body.dark-mode .timeline-content {
    background: var(--light);
    border-color: var(--border);
}
html body.dark-mode .timeline-marker {
    background: var(--dark);
    border-color: var(--primary);
}
html body.dark-mode .skeleton {
    background: linear-gradient(90deg, var(--light-gray) 25%, var(--light) 50%, var(--light-gray) 75%);
}
html body.dark-mode .sortable-table th.sortable:hover {
    background: color-mix(in srgb, var(--primary) 10%, var(--light-gray));
}
html body.dark-mode .sortable-table th.sort-asc,
html body.dark-mode .sortable-table th.sort-desc {
    background: color-mix(in srgb, var(--primary) 15%, var(--light-gray));
}
html body.dark-mode .insights-table-wrap {
    border-color: var(--border);
}
html body.dark-mode .insights-table thead th {
    background: var(--light-gray);
    color: var(--dark);
    border-bottom-color: var(--border);
}
html body.dark-mode .insights-table tbody td {
    border-bottom-color: var(--border-light);
}
html body.dark-mode .section-kicker {
    color: var(--primary-light);
    background: color-mix(in srgb, var(--primary) 20%, transparent);
}
html body.dark-mode .metadata-label {
    color: var(--dark-gray);
}
html body.dark-mode .metadata-value {
    color: var(--dark);
}
html body.dark-mode .mw-140,
html body.dark-mode .mw-320 {
    color: inherit;
}
html body.dark-mode .admin-context-title {
    color: var(--dark);
}
html body.dark-mode .admin-context-subtitle {
    color: var(--dark-gray);
}
html body.dark-mode .admin-context-breadcrumb .breadcrumb-item,
html body.dark-mode .admin-context-breadcrumb .breadcrumb-item.active {
    color: var(--dark-gray);
}
html body.dark-mode .admin-context-breadcrumb .breadcrumb-item + .breadcrumb-item::before {
    color: var(--border);
}
html body.dark-mode .admin-context-breadcrumb .breadcrumb-item a:hover {
    color: var(--primary);
}
html body.dark-mode .admin-context-chip-label {
    color: var(--dark-gray);
}
html body.dark-mode .alert-success {
    color: var(--success);
}
html body.dark-mode .alert-danger {
    color: var(--danger);
}
html body.dark-mode .alert-warning {
    color: var(--warning);
}
html body.dark-mode .alert-info {
    color: var(--info);
}
html body.dark-mode .badge.bg-warning {
    color: #0f172a !important;
}
html body.dark-mode .badge.rubric-final {
    color: var(--dark) !important;
}
html body.dark-mode .stat-card:hover {
    border-color: color-mix(in srgb, var(--primary) 25%, var(--border));
}
html body.dark-mode .password-toggle-btn {
    color: var(--dark-gray);
}
html body.dark-mode .password-toggle-btn:hover,
html body.dark-mode .password-toggle-btn:focus {
    color: var(--primary);
}
html body.dark-mode .teacher-data-table {
    background: transparent;
}
html body.dark-mode .sms-sticky-actions {
    background: var(--light-gray);
}
html body.dark-mode .mobile-sticky-save {
    background: rgba(15, 23, 42, 0.95);
}
html body.dark-mode .navbar-collapse .dropdown-menu {
    background-color: #0f172a !important;
}
html body.dark-mode .batch-header {
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}
html body.dark-mode .watchlist-item {
    background: var(--light-gray);
}
html body.dark-mode .status-pill {
    background: var(--light-gray);
}
html body.dark-mode .status-pill-present .status-input:checked + .status-pill-label {
    color: var(--success);
    background: color-mix(in srgb, var(--success) 20%, var(--light-gray));
}
html body.dark-mode .status-pill-absent .status-input:checked + .status-pill-label {
    color: var(--danger);
    background: color-mix(in srgb, var(--danger) 20%, var(--light-gray));
}
html body.dark-mode .status-pill-late .status-input:checked + .status-pill-label {
    color: var(--warning);
    background: color-mix(in srgb, var(--warning) 20%, var(--light-gray));
}
html body.dark-mode .mobile-sticky-count {
    color: var(--dark-gray);
}
html body.dark-mode .cal-cell {
    background: var(--light-gray);
}
html body.dark-mode .cal-cell.today {
    background: color-mix(in srgb, var(--primary) 15%, var(--light-gray));
    border-color: var(--primary);
}
html body.dark-mode .cal-dot.present {
    background: var(--success);
}
html body.dark-mode .cal-dot.late {
    background: var(--warning);
}
html body.dark-mode .cal-dot.absent {
    background: var(--danger);
}
html body.dark-mode .cal-day.present {
    background: color-mix(in srgb, var(--success) 20%, var(--light-gray));
}
html body.dark-mode .cal-day.absent {
    background: color-mix(in srgb, var(--danger) 20%, var(--light-gray));
}
html body.dark-mode .cal-day.late {
    background: color-mix(in srgb, var(--warning) 20%, var(--light-gray));
}
html body.dark-mode .cr-status-pill {
    background: var(--light-gray);
}
html body.dark-mode .cr-status-pill-present .cr-status-input:checked + .cr-status-pill-label {
    color: var(--success);
    background: color-mix(in srgb, var(--success) 20%, var(--light-gray));
}
html body.dark-mode .cr-status-pill-late .cr-status-input:checked + .cr-status-pill-label {
    color: var(--warning);
    background: color-mix(in srgb, var(--warning) 20%, var(--light-gray));
}
html body.dark-mode .cr-status-pill-absent .cr-status-input:checked + .cr-status-pill-label {
    color: var(--danger);
    background: color-mix(in srgb, var(--danger) 20%, var(--light-gray));
}
html body.dark-mode .cr-status-pill-excused .cr-status-input:checked + .cr-status-pill-label {
    color: var(--info);
    background: color-mix(in srgb, var(--info) 20%, var(--light-gray));
}
html body.dark-mode .stat-card-primary .stat-icon {
    color: var(--primary) !important;
    background: color-mix(in srgb, var(--primary) 15%, transparent);
}
html body.dark-mode .stat-card-success .stat-icon {
    color: var(--success) !important;
    background: color-mix(in srgb, var(--success) 15%, transparent);
}
html body.dark-mode .stat-card-warning .stat-icon {
    color: var(--warning) !important;
    background: color-mix(in srgb, var(--warning) 15%, transparent);
}
html body.dark-mode .stat-card-info .stat-icon {
    color: var(--info) !important;
    background: color-mix(in srgb, var(--info) 15%, transparent);
}
html body.dark-mode .pdf-disabled-btn::after {
    background: rgba(30, 41, 59, 0.95);
    color: var(--dark);
}
html body.dark-mode .students-grid .action-menu-btn:hover,
html body.dark-mode .students-grid .action-menu-btn:focus {
    background: rgba(129, 140, 248, 0.15);
}
html body.dark-mode .student-search-item:hover {
    background: rgba(129, 140, 248, 0.12);
}
html body.dark-mode .student-override-reason.is-invalid,
html body.dark-mode .student-override-reason.is-invalid:focus {
    background-color: rgba(248, 113, 113, 0.12) !important;
}
html body.dark-mode .attendance-export-disabled {
    background: color-mix(in srgb, var(--success) 15%, var(--light));
}
html body.dark-mode .resource-status-mirrored {
    color: var(--success);
    background: color-mix(in srgb, var(--success) 15%, transparent);
}
html body.dark-mode .resource-status-pending {
    color: var(--warning);
    background: color-mix(in srgb, var(--warning) 15%, transparent);
}
html body.dark-mode .resource-note-box {
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.10), rgba(251, 191, 36, 0.06));
    border-color: rgba(251, 191, 36, 0.18);
    color: var(--warning);
}
html body.dark-mode .resource-note-box i {
    color: var(--warning);
}

html body.dark-mode .toast {
    background: #1e293b;
    border: 1px solid rgba(51, 65, 85, 0.8);
    color: var(--dark);
}
html body.dark-mode .rubric-status-group {
    background: var(--light-gray);
    border-color: var(--border);
}
html body.dark-mode .publish-toggle-input {
    background: var(--light-gray);
    border-color: var(--border);
}
html body.dark-mode .key-stat {
    background: var(--light-gray);
    border-color: var(--border);
    color: var(--dark);
}
html body.dark-mode .form-check-input {
    background-color: var(--light-gray);
    border-color: var(--border);
}
html body.dark-mode .form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

html body.dark-mode .override-policy-toggle {
    border-color: var(--border);
    background: var(--light-gray);
}
html body.dark-mode .override-policy-toggle__title {
    color: var(--dark);
}
html body.dark-mode .override-policy-toggle__hint {
    color: var(--dark-gray);
}
html body.dark-mode .override-policy-toggle__chevron {
    color: var(--primary-light);
}
html body.dark-mode .override-policy-toggle__body {
    border-top-color: var(--border);
}

html body.dark-mode .student-profile-page {
    background:
        radial-gradient(circle at 8% 0%, rgba(129, 140, 248, 0.08), transparent 40%),
        radial-gradient(circle at 96% 4%, rgba(52, 211, 153, 0.06), transparent 34%);
}
html body.dark-mode .student-profile-page .admin-context-hero::before {
    background: radial-gradient(circle, rgba(129, 140, 248, 0.18), transparent 68%);
}
html body.dark-mode .student-profile-page .admin-context-hero::after {
    background: radial-gradient(circle, rgba(52, 211, 153, 0.14), transparent 72%);
}
html body.dark-mode .student-profile-page .admin-context-breadcrumb .breadcrumb {
    border-color: rgba(51, 65, 85, 0.7);
    background: rgba(0, 0, 0, 0.15);
}
html body.dark-mode .student-profile-page .admin-context-chip {
    border-color: rgba(51, 65, 85, 0.75);
    background: linear-gradient(135deg, rgba(51, 65, 85, 0.5), rgba(15, 23, 42, 0.3));
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255,255,255,0.06);
}

/* ── Theme Selector UI (admin/change-theme.php) ── */
.theme-option {
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #fff;
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.theme-option:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 26px rgba(15, 23, 42, .08);
    border-color: #cbd5e1;
}
.preview-box {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 10px 12px;
    background: #f8fafc;
    font-size: 0.92rem;
}
.theme-preview {
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    overflow: hidden;
}
.preview-top {
    height: 24px;
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 0 10px;
}
.dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,.55);
}
.preview-body {
    padding: 10px;
}
.preview-body .bar {
    height: 10px;
    border-radius: 999px;
    margin-bottom: 8px;
}
.preview-body .pill {
    width: 45%;
    height: 8px;
    border-radius: 999px;
    margin-bottom: 10px;
}
.row-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.row-cards > div {
    height: 42px;
    border-radius: 8px;
}

.theme-preview-default .preview-top { background: linear-gradient(135deg, #4f46e5, #6366f1); }
.theme-preview-default .preview-body { background: #f8fafc; }
.theme-preview-default .bar { background: #4f46e5; }
.theme-preview-default .pill { background: #94a3b8; }
.theme-preview-default .row-cards > div { background: #ffffff; border: 1px solid #e2e8f0; }





.theme-preview-modern-polished .preview-top {
    background:
        radial-gradient(circle at 100% 0%, rgba(255,255,255,0.18), transparent 34%),
        linear-gradient(125deg, #0b5ed7, #2563eb 58%, #0891b2);
}
.theme-preview-modern-polished .preview-body {
    background:
        radial-gradient(circle at 10% 0%, rgba(37, 99, 235, 0.10), transparent 26%),
        #f7fafc;
}
.theme-preview-modern-polished .bar {
    background: linear-gradient(90deg, #0b5ed7, #2563eb 62%, #0891b2);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.18);
}
.theme-preview-modern-polished .pill {
    background: linear-gradient(135deg, #475569, #1e293b);
}
.theme-preview-modern-polished .row-cards > div {
    background: linear-gradient(135deg, #ffffff, #f5f9ff);
    border: 1px solid #d9e2ec;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.06);
}

.theme-preview-nextgen .preview-top {
    background: linear-gradient(135deg, #ffffff, #f8fafc);
    border-bottom: 1px solid #e2e8f0;
}
.theme-preview-nextgen .preview-body {
    background: #f8fafc;
}
.theme-preview-nextgen .bar {
    background: linear-gradient(90deg, #2563eb, #3b82f6);
}
.theme-preview-nextgen .pill {
    background: #475569;
}
.theme-preview-nextgen .row-cards > div {
    background: #ffffff;
    border: 1px solid #e2e8f0;
}

.theme-preview-obsidian-2026 .preview-top {
    background: linear-gradient(135deg, #090d16, #1e293b);
}
.theme-preview-obsidian-2026 .preview-body {
    background: #f8fafc;
}
.theme-preview-obsidian-2026 .bar {
    background: linear-gradient(90deg, #4f46e5, #6366f1);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}
.theme-preview-obsidian-2026 .pill {
    background: #4f46e5;
}
.theme-preview-obsidian-2026 .row-cards > div {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}

.theme-preview-nordic-frost .preview-top {
    background: linear-gradient(135deg, #0369a1, #0ea5e9);
}
.theme-preview-nordic-frost .preview-body {
    background: #f0f9ff;
}
.theme-preview-nordic-frost .bar {
    background: linear-gradient(90deg, #0284c7, #38bdf8);
}
.theme-preview-nordic-frost .pill {
    background: #0284c7;
}
.theme-preview-nordic-frost .row-cards > div {
    background: #ffffff;
    border: 1px solid #bae6fd;
}

.theme-preview-atelier-clay .preview-top {
    background: linear-gradient(135deg, #7c2d12, #c2410c);
}
.theme-preview-atelier-clay .preview-body {
    background: #faf5f0;
}
.theme-preview-atelier-clay .bar {
    background: linear-gradient(90deg, #c2410c, #ea580c);
}
.theme-preview-atelier-clay .pill {
    background: #9a3412;
}
.theme-preview-atelier-clay .row-cards > div {
    background: #ffffff;
    border: 1px solid #fed7aa;
}

/* Modern Polished dark mode: restore strong contrast on dashboard/admin hero */
body[data-ui-theme="modern-polished"].dark-mode .dashboard-hero,
body[data-ui-theme="modern-polished"].dark-mode .admin-context-hero {
    background:
        radial-gradient(circle at top right, rgba(129, 140, 248, 0.12), transparent 30%),
        radial-gradient(circle at bottom left, rgba(34, 211, 238, 0.08), transparent 32%),
        linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.98)) !important;
    border-color: rgba(71, 85, 105, 0.72) !important;
    box-shadow: 0 20px 42px rgba(2, 6, 23, 0.32) !important;
}

body[data-ui-theme="modern-polished"].dark-mode .admin-context-title,
body[data-ui-theme="modern-polished"].dark-mode .dashboard-title {
    color: #f8fafc;
    text-shadow: none;
}

body[data-ui-theme="modern-polished"].dark-mode .admin-context-subtitle,
body[data-ui-theme="modern-polished"].dark-mode .dashboard-subtitle {
    color: #cbd5e1;
}

body[data-ui-theme="modern-polished"].dark-mode .admin-context-kicker,
body[data-ui-theme="modern-polished"].dark-mode .dashboard-kicker {
    background: rgba(99, 102, 241, 0.16) !important;
    border-color: rgba(129, 140, 248, 0.28) !important;
    color: #c7d2fe !important;
}

body[data-ui-theme="modern-polished"].dark-mode .dashboard-meta-chip,
body[data-ui-theme="modern-polished"].dark-mode .admin-context-chip,
body[data-ui-theme="modern-polished"].dark-mode .stat-card-inline {
    background: rgba(15, 23, 42, 0.74) !important;
    border-color: rgba(71, 85, 105, 0.7) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

body[data-ui-theme="modern-polished"].dark-mode .admin-context-chip-label,
body[data-ui-theme="modern-polished"].dark-mode .stat-card-inline .text-xs {
    color: #94a3b8;
}

body[data-ui-theme="modern-polished"].dark-mode .admin-context-chip-value,
body[data-ui-theme="modern-polished"].dark-mode .stat-card-inline .h5,
body[data-ui-theme="modern-polished"].dark-mode .stat-card-inline .col-auto i {
    color: #f8fafc;
}
}

/* ============================================================
   2026 NEXT-GEN SAAS DESIGN THEMES (Linear / Raycast / Stripe Tier)
   1. ✨ Obsidian Zinc (2026 Flagship)
   2. ❄️ Nordic Frost (Polar Minimal)
   3. 🏛️ Atelier Clay (Modern Editorial)
   ============================================================ */

/* ─── Preview Cards for /admin/change-theme.php ─── */
.theme-preview-obsidian-2026 .preview-top {
    background: linear-gradient(135deg, #090d16 0%, #1e1b4b 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.theme-preview-obsidian-2026 .preview-body {
    background: radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.15) 0px, transparent 60%), #f8fafc;
}
.theme-preview-obsidian-2026 .bar {
    background: linear-gradient(90deg, #4f46e5, #818cf8);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}
.theme-preview-obsidian-2026 .pill {
    background: #475569;
}
.theme-preview-obsidian-2026 .row-cards > div {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}

.theme-preview-nordic-frost .preview-top {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
}
.theme-preview-nordic-frost .preview-body {
    background: #fcfcfd;
}
.theme-preview-nordic-frost .bar {
    background: linear-gradient(90deg, #0284c7, #38bdf8);
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.25);
}
.theme-preview-nordic-frost .pill {
    background: #64748b;
}
.theme-preview-nordic-frost .row-cards > div {
    background: #ffffff;
    border: 1px solid #e2e8f0;
}

.theme-preview-atelier-clay .preview-top {
    background: linear-gradient(135deg, #9a3412 0%, #c2410c 100%);
}
.theme-preview-atelier-clay .preview-body {
    background: #f9f8f6;
}
.theme-preview-atelier-clay .bar {
    background: linear-gradient(90deg, #c2410c, #ea580c);
    box-shadow: 0 4px 12px rgba(194, 65, 12, 0.25);
}
.theme-preview-atelier-clay .pill {
    background: #78716c;
}
.theme-preview-atelier-clay .row-cards > div {
    background: #ffffff;
    border: 1px solid #e5e0d8;
}

.theme-preview-nextgen .preview-top {
    background: linear-gradient(135deg, #115e59 0%, #0f766e 100%);
}
.theme-preview-nextgen .preview-body {
    background: #f0fdfa;
}
.theme-preview-nextgen .bar {
    background: linear-gradient(90deg, #0f766e, #14b8a6);
    box-shadow: 0 4px 12px rgba(15, 118, 110, 0.25);
}
.theme-preview-nextgen .pill {
    background: #0d9488;
}
.theme-preview-nextgen .row-cards > div {
    background: #ffffff;
    border: 1px solid #ccfbf1;
    box-shadow: 0 1px 3px rgba(15, 118, 110, 0.04);
}

/* ══════════════════════════════════════════════════════════════
   THEME 1: ✨ OBSIDIAN ZINC (2026 FLAGSHIP)
   ══════════════════════════════════════════════════════════════ */
body[data-ui-theme="obsidian-2026"] {
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --primary: #4f46e5;
    --primary-light: #6366f1;
    --primary-dark: #3730a3;
    --primary-glow: 0 8px 24px -4px rgba(79, 70, 229, 0.20); /* was 0.35 — calmer glow */
    --primary-faint: rgba(79, 70, 229, 0.08);
    --success: #059669;
    --success-faint: rgba(5, 150, 105, 0.08);
    --warning: #d97706;
    --warning-faint: rgba(217, 119, 6, 0.08);
    --danger: #e11d48;
    --danger-faint: rgba(225, 29, 72, 0.08);
    --info: #0284c7;
    --light: #ffffff;
    --light-gray: #eef2f7;         /* was #f8fafc (same as canvas) — now distinct */
    --dark: #090d16;
    --dark-gray: #64748b;
    --border: #e2e8f0;
    --border-light: rgba(226, 232, 240, 0.9);
    --bg-canvas: #f4f6fa;          /* was #f8fafc — slightly deeper for separation */
    --bg-surface: rgba(255, 255, 255, 0.85);
    --sidebar-bg: rgba(255, 255, 255, 0.85);
    --sidebar-border: rgba(226, 232, 240, 0.9);
    --sidebar-text: #475569;
    --sidebar-active: #4f46e5;
    --sidebar-active-bg: rgba(79, 70, 229, 0.08);
    --sidebar-text-active: #4f46e5;  /* was missing */
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 1), 0 1px 3px rgba(0, 0, 0, 0.02), 0 8px 24px -4px rgba(15, 23, 42, 0.04);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 1), 0 12px 32px -4px rgba(79, 70, 229, 0.12), 0 0 0 1px rgba(79, 70, 229, 0.15);
    /* Per-theme Bootstrap rgb override */
    --bs-primary-rgb: 79, 70, 229;
    font-family: var(--font-sans);
    letter-spacing: -0.015em;
    background-color: var(--bg-canvas);
    background-image: radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.05) 0px, transparent 50%),
                      radial-gradient(at 100% 0%, rgba(14, 165, 233, 0.04) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--dark);
}

/* Obsidian Zinc Dark Mode */
html body.dark-mode[data-ui-theme="obsidian-2026"],
body[data-ui-theme="obsidian-2026"].dark-mode {
    --bg-canvas: #060911;
    --bg-surface: rgba(15, 23, 42, 0.65);
    --bg-subtle: rgba(30, 41, 59, 0.7);
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --primary-glow: 0 8px 28px -4px rgba(99, 102, 241, 0.5);
    --primary-faint: rgba(99, 102, 241, 0.15);
    --success: #10b981;
    --success-faint: rgba(16, 185, 129, 0.15);
    --warning: #fbbf24;
    --warning-faint: rgba(251, 191, 36, 0.15);
    --danger: #f43f5e;
    --danger-faint: rgba(244, 63, 94, 0.15);
    --dark: #f8fafc;
    --dark-gray: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.05);
    --sidebar-bg: rgba(9, 13, 22, 0.8);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-text: #94a3b8;
    --sidebar-active: #ffffff;
    --sidebar-active-bg: rgba(255, 255, 255, 0.08);
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 16px 36px -4px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(99, 102, 241, 0.4);
    background-color: var(--bg-canvas) !important;
    background-image: radial-gradient(at 0% 0%, rgba(99, 102, 241, 0.12) 0px, transparent 60%),
                      radial-gradient(at 100% 0%, rgba(14, 165, 233, 0.08) 0px, transparent 50%) !important;
    color: var(--dark) !important;
}

/* ══════════════════════════════════════════════════════════════
   THEME 2: ❄️ NORDIC FROST (POLAR MINIMAL)
   ══════════════════════════════════════════════════════════════ */
body[data-ui-theme="nordic-frost"] {
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --primary: #0369a1;           /* was #0284c7 — deepened for less harshness */
    --primary-light: #0284c7;     /* was #38bdf8 — use previous primary as light */
    --primary-dark: #075985;
    --primary-glow: 0 8px 24px -4px rgba(3, 105, 161, 0.20); /* was 0.35 — calmer glow */
    --primary-faint: rgba(3, 105, 161, 0.08);
    --success: #059669;
    --success-faint: rgba(5, 150, 105, 0.08);
    --warning: #d97706;
    --warning-faint: rgba(217, 119, 6, 0.08);
    --danger: #dc2626;
    --danger-faint: rgba(220, 38, 38, 0.08);
    --info: #0891b2;
    --light: #ffffff;
    --light-gray: #f1f5f9;        /* was #fcfcfd (same as canvas) — now distinct */
    --dark: #0f172a;
    --dark-gray: #64748b;
    --border: #e2e8f0;
    --border-light: rgba(226, 232, 240, 0.95);
    --bg-canvas: #fcfcfd;
    --bg-surface: rgba(255, 255, 255, 0.9);
    --sidebar-bg: rgba(248, 250, 252, 0.85);
    --sidebar-border: rgba(226, 232, 240, 0.9);
    --sidebar-text: #475569;
    --sidebar-active: #0369a1;
    --sidebar-active-bg: rgba(3, 105, 161, 0.08);
    --sidebar-text-active: #0369a1;  /* was missing */
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 1), 0 1px 3px rgba(0, 0, 0, 0.02);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 1), 0 12px 28px -4px rgba(3, 105, 161, 0.12), 0 0 0 1px rgba(3, 105, 161, 0.2);
    /* Per-theme Bootstrap rgb override */
    --bs-primary-rgb: 3, 105, 161;
    font-family: var(--font-sans);
    letter-spacing: -0.015em;
    background-color: var(--bg-canvas);
    color: var(--dark);
}

/* Nordic Frost Dark Mode */
html body.dark-mode[data-ui-theme="nordic-frost"],
body[data-ui-theme="nordic-frost"].dark-mode {
    --bg-canvas: #030712;
    --bg-surface: rgba(15, 23, 42, 0.7);
    --bg-subtle: rgba(30, 41, 59, 0.8);
    --primary: #38bdf8;
    --primary-light: #7dd3fc;
    --primary-dark: #0284c7;
    --primary-glow: 0 8px 28px -4px rgba(56, 189, 248, 0.45);
    --primary-faint: rgba(56, 189, 248, 0.15);
    --success: #34d399;
    --success-faint: rgba(52, 211, 153, 0.15);
    --warning: #fbbf24;
    --warning-faint: rgba(251, 191, 36, 0.15);
    --danger: #f87171;
    --danger-faint: rgba(248, 113, 113, 0.15);
    --dark: #f8fafc;
    --dark-gray: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.05);
    --sidebar-bg: rgba(8, 14, 26, 0.8);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-text: #94a3b8;
    --sidebar-active: #ffffff;
    --sidebar-active-bg: rgba(56, 189, 248, 0.12);
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 16px 36px -4px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(56, 189, 248, 0.4);
    background-color: var(--bg-canvas) !important;
    color: var(--dark) !important;
}

/* ══════════════════════════════════════════════════════════════
   THEME 3: 🏛️ ATELIER CLAY (WARM EDITORIAL)
   ══════════════════════════════════════════════════════════════ */
body[data-ui-theme="atelier-clay"] {
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --primary: #c2410c;
    --primary-light: #ea580c;
    --primary-dark: #9a3412;
    --primary-glow: 0 8px 24px -4px rgba(194, 65, 12, 0.20); /* was 0.35 — calmer glow */
    --primary-faint: rgba(194, 65, 12, 0.08);
    --success: #15803d;
    --success-faint: rgba(21, 128, 61, 0.08);
    --warning: #b45309;
    --warning-faint: rgba(180, 83, 9, 0.08);
    --danger: #b91c1c;
    --danger-faint: rgba(185, 28, 28, 0.08);
    --info: #0369a1;
    --light: #ffffff;
    --light-gray: #eeeae5;         /* was #f9f8f6 (same as canvas) — now distinct warm tone */
    --dark: #262320;
    --dark-gray: #6e675f;
    --border: #e2ded4;
    --border-light: rgba(229, 224, 216, 0.95);
    --bg-canvas: #f9f8f6;
    --bg-surface: rgba(255, 255, 255, 0.9);
    --sidebar-bg: rgba(242, 239, 233, 0.85);
    --sidebar-border: rgba(226, 222, 212, 0.9);
    --sidebar-text: #6e675f;
    --sidebar-active: #c2410c;
    --sidebar-active-bg: rgba(194, 65, 12, 0.08);
    --sidebar-text-active: #c2410c;  /* was missing */
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 1), 0 1px 3px rgba(38, 35, 32, 0.03);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 1), 0 12px 28px -4px rgba(194, 65, 12, 0.12), 0 0 0 1px rgba(194, 65, 12, 0.2);
    /* Per-theme Bootstrap rgb override */
    --bs-primary-rgb: 194, 65, 12;
    font-family: var(--font-sans);
    letter-spacing: -0.015em;
    background-color: var(--bg-canvas);
    color: var(--dark);
}

/* Atelier Clay Dark Mode */
html body.dark-mode[data-ui-theme="atelier-clay"],
body[data-ui-theme="atelier-clay"].dark-mode {
    --bg-canvas: #0f0d0c;
    --bg-surface: rgba(28, 25, 23, 0.75);
    --bg-subtle: rgba(41, 37, 36, 0.85);
    --primary: #fb923c;
    --primary-light: #fdba74;
    --primary-dark: #ea580c;
    --primary-glow: 0 8px 28px -4px rgba(251, 146, 60, 0.45);
    --primary-faint: rgba(251, 146, 60, 0.15);
    --success: #4ade80;
    --success-faint: rgba(74, 222, 128, 0.15);
    --warning: #facc15;
    --warning-faint: rgba(250, 204, 21, 0.15);
    --danger: #f87171;
    --danger-faint: rgba(248, 113, 113, 0.15);
    --dark: #fafaf9;
    --dark-gray: #a8a29e;
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.05);
    --sidebar-bg: rgba(20, 18, 16, 0.85);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-text: #a8a29e;
    --sidebar-active: #ffffff;
    --sidebar-active-bg: rgba(251, 146, 60, 0.12);
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.12), 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 16px 36px -4px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(251, 146, 60, 0.4);
    background-color: var(--bg-canvas) !important;
    color: var(--dark) !important;
}

/* ══════════════════════════════════════════════════════════════
   2026 COMPONENT REFINEMENTS (Scoped to the 3 2026 Themes)
   ══════════════════════════════════════════════════════════════ */
body[data-ui-theme="obsidian-2026"] .admin-context-hero,
body[data-ui-theme="nordic-frost"] .admin-context-hero,
body[data-ui-theme="atelier-clay"] .admin-context-hero {
    background: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0.25rem 0 1rem 0 !important;
}

body[data-ui-theme="obsidian-2026"] .card,
body[data-ui-theme="nordic-frost"] .card,
body[data-ui-theme="atelier-clay"] .card {
    background: var(--bg-surface) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border-light) !important;
    border-radius: 16px !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

body[data-ui-theme="obsidian-2026"] .stat-card,
body[data-ui-theme="nordic-frost"] .stat-card,
body[data-ui-theme="atelier-clay"] .stat-card {
    border-radius: 16px !important;
    box-shadow: var(--shadow-card) !important;
    border: 1px solid var(--border-light) !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

body[data-ui-theme="obsidian-2026"] .stat-card:hover,
body[data-ui-theme="nordic-frost"] .stat-card:hover,
body[data-ui-theme="atelier-clay"] .stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover) !important;
}

body[data-ui-theme="obsidian-2026"] .action-card,
body[data-ui-theme="nordic-frost"] .action-card,
body[data-ui-theme="atelier-clay"] .action-card {
    border-radius: 14px !important;
    border: 1px solid var(--border-light) !important;
    background: var(--bg-surface) !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

body[data-ui-theme="obsidian-2026"] .action-card:hover,
body[data-ui-theme="nordic-frost"] .action-card:hover,
body[data-ui-theme="atelier-clay"] .action-card:hover {
    transform: translateY(-3px);
    border-color: var(--primary) !important;
    box-shadow: var(--shadow-hover) !important;
}

/* Attendance Status Pills Tactile Styling */
body[data-ui-theme="obsidian-2026"] .status-pill-fieldset,
body[data-ui-theme="nordic-frost"] .status-pill-fieldset,
body[data-ui-theme="atelier-clay"] .status-pill-fieldset {
    background: rgba(0, 0, 0, 0.04);
    border-radius: 12px;
    padding: 3px;
}

body[data-ui-theme="obsidian-2026"].dark-mode .status-pill-fieldset,
body[data-ui-theme="nordic-frost"].dark-mode .status-pill-fieldset,
body[data-ui-theme="atelier-clay"].dark-mode .status-pill-fieldset {
    background: rgba(255, 255, 255, 0.05);
}

body[data-ui-theme="obsidian-2026"] .status-pill-label,
body[data-ui-theme="nordic-frost"] .status-pill-label,
body[data-ui-theme="atelier-clay"] .status-pill-label {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.82rem;
    line-height: 1 !important;
    padding: 0 4px !important;
    transition: all 0.15s ease;
}

body[data-ui-theme="obsidian-2026"] .status-pill-present .status-input:checked + .status-pill-label,
body[data-ui-theme="nordic-frost"] .status-pill-present .status-input:checked + .status-pill-label,
body[data-ui-theme="atelier-clay"] .status-pill-present .status-input:checked + .status-pill-label {
    background: var(--success) !important;
    color: #fff !important;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.28);
}

body[data-ui-theme="obsidian-2026"] .status-pill-absent .status-input:checked + .status-pill-label,
body[data-ui-theme="nordic-frost"] .status-pill-absent .status-input:checked + .status-pill-label,
body[data-ui-theme="atelier-clay"] .status-pill-absent .status-input:checked + .status-pill-label {
    background: var(--danger) !important;
    color: #fff !important;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.28);
}

body[data-ui-theme="obsidian-2026"] .status-pill-late .status-input:checked + .status-pill-label,
body[data-ui-theme="nordic-frost"] .status-pill-late .status-input:checked + .status-pill-label,
body[data-ui-theme="atelier-clay"] .status-pill-late .status-input:checked + .status-pill-label {
    background: var(--warning) !important;
    color: #fff !important;
    box-shadow: 0 2px 6px rgba(245, 158, 11, 0.28);
}

/* Mobile Sticky Save Dock */
body[data-ui-theme="obsidian-2026"] .mobile-sticky-save,
body[data-ui-theme="nordic-frost"] .mobile-sticky-save,
body[data-ui-theme="atelier-clay"] .mobile-sticky-save {
    background: var(--bg-surface) !important;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-light) !important;
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.12);
}

/* Monospace Numbers & Roll Numbers */
body[data-ui-theme="obsidian-2026"] code,
body[data-ui-theme="nordic-frost"] code,
body[data-ui-theme="atelier-clay"] code,
body[data-ui-theme="obsidian-2026"] .sidebar-live-time,
body[data-ui-theme="nordic-frost"] .sidebar-live-time,
body[data-ui-theme="atelier-clay"] .sidebar-live-time,
body[data-ui-theme="obsidian-2026"] .roll-number,
body[data-ui-theme="nordic-frost"] .roll-number,
body[data-ui-theme="atelier-clay"] .roll-number {
    font-family: 'JetBrains Mono', monospace !important;
    letter-spacing: -0.02em;
}

/* 2026 Form Controls */
body[data-ui-theme="obsidian-2026"] .form-control,
body[data-ui-theme="obsidian-2026"] .form-select,
body[data-ui-theme="nordic-frost"] .form-control,
body[data-ui-theme="nordic-frost"] .form-select,
body[data-ui-theme="atelier-clay"] .form-control,
body[data-ui-theme="atelier-clay"] .form-select {
    border-radius: 10px !important;
    border: 1px solid var(--border) !important;
    padding: 0.6rem 0.9rem !important;
    font-size: 0.9rem !important;
    background-color: var(--bg-surface) !important;
    color: var(--dark) !important;
    transition: all 0.2s ease !important;
}

body[data-ui-theme="obsidian-2026"] .form-control:focus,
body[data-ui-theme="obsidian-2026"] .form-select:focus,
body[data-ui-theme="nordic-frost"] .form-control:focus,
body[data-ui-theme="nordic-frost"] .form-select:focus,
body[data-ui-theme="atelier-clay"] .form-control:focus,
body[data-ui-theme="atelier-clay"] .form-select:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 3px var(--primary-faint) !important;
}

/* 2026 Buttons & Interactive Elements */
body[data-ui-theme="obsidian-2026"] .btn-primary,
body[data-ui-theme="nordic-frost"] .btn-primary,
body[data-ui-theme="atelier-clay"] .btn-primary {
    border-radius: 10px !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em !important;
    box-shadow: var(--primary-glow) !important;
    border: none !important;
    background: var(--primary) !important;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

body[data-ui-theme="obsidian-2026"] .btn-primary:hover,
body[data-ui-theme="nordic-frost"] .btn-primary:hover,
body[data-ui-theme="atelier-clay"] .btn-primary:hover {
    transform: translateY(-1px) !important;
    filter: brightness(1.08) !important;
}

/* 2026 Batch Progression & Promotion Cards */
body[data-ui-theme="obsidian-2026"] .batch-card,
body[data-ui-theme="nordic-frost"] .batch-card,
body[data-ui-theme="atelier-clay"] .batch-card,
body[data-ui-theme="obsidian-2026"] .promotion-card,
body[data-ui-theme="nordic-frost"] .promotion-card,
body[data-ui-theme="atelier-clay"] .promotion-card {
    border-radius: 16px !important;
    border: 1px solid var(--border-light) !important;
    background: var(--bg-surface) !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.22s ease !important;
}

body[data-ui-theme="obsidian-2026"] .promotion-card:hover,
body[data-ui-theme="nordic-frost"] .promotion-card:hover,
body[data-ui-theme="atelier-clay"] .promotion-card:hover {
    border-color: var(--primary) !important;
    box-shadow: var(--shadow-hover) !important;
}

/* Option 2: Brand-Tinted Header Accent with Smooth Flow */
body[data-sidebar-theme="true"] .sidebar-header,
body[data-ui-theme="nordic-frost"] .sidebar-header,
body[data-ui-theme="obsidian-2026"] .sidebar-header,
body[data-ui-theme="atelier-clay"] .sidebar-header {
    background: linear-gradient(
        180deg,
        color-mix(in srgb, var(--primary) 9%, var(--sidebar-bg)) 0%,
        color-mix(in srgb, var(--primary) 4%, var(--sidebar-bg)) 70%,
        var(--sidebar-bg) 100%
    ) !important;
    border-bottom: 1px solid color-mix(in srgb, var(--primary) 14%, var(--sidebar-border)) !important;
}

body[data-sidebar-theme="true"] .sidebar-footer,
body[data-ui-theme="nordic-frost"] .sidebar-footer,
body[data-ui-theme="obsidian-2026"] .sidebar-footer,
body[data-ui-theme="atelier-clay"] .sidebar-footer {
    background: var(--sidebar-bg) !important;
    border-top: 1px solid var(--sidebar-border) !important;
}

body[data-sidebar-theme="true"] .sidebar-brand-text,
body[data-ui-theme="nordic-frost"] .sidebar-brand-text,
body[data-ui-theme="obsidian-2026"] .sidebar-brand-text,
body[data-ui-theme="atelier-clay"] .sidebar-brand-text {
    color: var(--dark) !important;
    font-weight: 700 !important;
}


/* ══════════════════════════════════════════════════════════════
   THEME 4: 🪨 CALM SLATE (NEUTRAL PROFESSIONAL)
   ══════════════════════════════════════════════════════════════ */

/* ─── Preview Card ─── */
.theme-preview-calm-slate .preview-top {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
}
.theme-preview-calm-slate .preview-body {
    background: #f1f5f9;
}
.theme-preview-calm-slate .bar {
    background: linear-gradient(90deg, #334155, #475569);
    box-shadow: 0 4px 12px rgba(51, 65, 85, 0.18);
}
.theme-preview-calm-slate .pill {
    background: #64748b;
}
.theme-preview-calm-slate .row-cards > div {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

/* ─── Calm Slate Light Mode ─── */
body[data-ui-theme="calm-slate"] {
    --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --primary: #334155;           /* Cool Steel Slate (Slate-700) — pure neutral, 0% bright blue */
    --primary-light: #475569;     /* Slate-600 */
    --primary-dark: #1e293b;      /* Slate-800 */
    --primary-glow: none;         /* No button glow — clean distraction-free corporate look */
    --primary-faint: rgba(51, 65, 85, 0.08);
    --success: #059669;
    --success-faint: rgba(5, 150, 105, 0.08);
    --warning: #d97706;
    --warning-faint: rgba(217, 119, 6, 0.08);
    --danger: #dc2626;
    --danger-faint: rgba(220, 38, 38, 0.08);
    --info: #0369a1;
    --light: #ffffff;
    --light-gray: #e2e8f0;        /* Slate-200 — clearly distinct from canvas */
    --dark: #0f172a;              /* Slate-900 */
    --dark-gray: #64748b;         /* Slate-500 */
    --border: #cbd5e1;            /* Slate-300 */
    --border-light: rgba(203, 213, 225, 0.85);
    --bg-canvas: #f1f5f9;         /* Slate-100 — soft neutral steel canvas */
    --bg-surface: rgba(255, 255, 255, 0.97);
    --sidebar-bg: rgba(255, 255, 255, 0.94);
    --sidebar-border: rgba(203, 213, 225, 0.85);
    --sidebar-text: #475569;
    --sidebar-active: #334155;
    --sidebar-active-bg: rgba(51, 65, 85, 0.08); /* Soft steel tint only — no solid block */
    --sidebar-text-active: #334155;
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 1), 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(15, 23, 42, 0.03);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 1), 0 8px 20px -4px rgba(51, 65, 85, 0.12), 0 0 0 1px rgba(51, 65, 85, 0.15);
    /* Bootstrap 5 bridge */
    --bs-primary-rgb: 51, 65, 85;
    font-family: var(--font-sans);
    letter-spacing: -0.015em;
    background-color: var(--bg-canvas);
    color: var(--dark);
}

/* Calm Slate Dark Mode */
html body.dark-mode[data-ui-theme="calm-slate"],
body[data-ui-theme="calm-slate"].dark-mode {
    --bg-canvas: #090d16;
    --bg-surface: rgba(15, 23, 42, 0.72);
    --bg-subtle: rgba(30, 41, 59, 0.85);
    --primary: #94a3b8;           /* Muted Silver / Steel Slate */
    --primary-light: #cbd5e1;
    --primary-dark: #64748b;
    --primary-glow: none;
    --primary-faint: rgba(148, 163, 184, 0.12);
    --success: #34d399;
    --success-faint: rgba(52, 211, 153, 0.15);
    --warning: #fbbf24;
    --warning-faint: rgba(251, 191, 36, 0.15);
    --danger: #f87171;
    --danger-faint: rgba(248, 113, 113, 0.15);
    --dark: #f8fafc;
    --dark-gray: #94a3b8;
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.05);
    --sidebar-bg: rgba(9, 13, 22, 0.85);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-text: #94a3b8;
    --sidebar-active: #ffffff;
    --sidebar-active-bg: rgba(148, 163, 184, 0.12);
    --sidebar-text-active: #f8fafc;
    --shadow-card: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 4px 20px rgba(0, 0, 0, 0.55);
    --shadow-hover: inset 0 1px 0 rgba(255, 255, 255, 0.14), 0 12px 32px -4px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(148, 163, 184, 0.25);
    --bs-primary-rgb: 148, 163, 184;
    background-color: var(--bg-canvas) !important;
    color: var(--dark) !important;
}

/* ─── Calm Slate Component Refinements ─── */
body[data-ui-theme="calm-slate"] .admin-context-hero {
    background: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0.25rem 0 1rem 0 !important;
}

body[data-ui-theme="calm-slate"] .card {
    background: var(--bg-surface) !important;
    border: 1px solid var(--border-light) !important;
    border-radius: 16px !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

body[data-ui-theme="calm-slate"] .stat-card {
    border-radius: 16px !important;
    box-shadow: var(--shadow-card) !important;
    border: 1px solid var(--border-light) !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

body[data-ui-theme="calm-slate"] .stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover) !important;
}

body[data-ui-theme="calm-slate"] .action-card {
    border-radius: 14px !important;
    border: 1px solid var(--border-light) !important;
    background: var(--bg-surface) !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.25s ease;
}

body[data-ui-theme="calm-slate"] .action-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary) !important;
    box-shadow: var(--shadow-hover) !important;
}

body[data-ui-theme="calm-slate"] .btn-primary {
    border-radius: 10px !important;
    font-weight: 700 !important;
    letter-spacing: -0.01em !important;
    box-shadow: none !important; /* No glow — intentional */
    border: none !important;
    background: var(--primary) !important;
    transition: all 0.2s ease !important;
}

body[data-ui-theme="calm-slate"] .btn-primary:hover {
    transform: translateY(-1px) !important;
    filter: brightness(1.10) !important;
}

body[data-ui-theme="calm-slate"] .form-control,
body[data-ui-theme="calm-slate"] .form-select {
    background: var(--bg-surface) !important;
    border-color: var(--border) !important;
    color: var(--dark) !important;
    border-radius: 10px;
}

body[data-ui-theme="calm-slate"] .form-control:focus,
body[data-ui-theme="calm-slate"] .form-select:focus {
    border-color: var(--primary) !important;
    box-shadow: 0 0 0 0.2rem var(--primary-faint) !important;
}

body[data-ui-theme="calm-slate"] .batch-card,
body[data-ui-theme="calm-slate"] .promotion-card {
    border-radius: 16px !important;
    border: 1px solid var(--border-light) !important;
    background: var(--bg-surface) !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.22s ease !important;
}

body[data-ui-theme="calm-slate"] .promotion-card:hover {
    border-color: var(--primary) !important;
    box-shadow: var(--shadow-hover) !important;
}

body[data-ui-theme="calm-slate"] .sidebar-header {
    background: linear-gradient(
        180deg,
        color-mix(in srgb, var(--primary) 7%, var(--sidebar-bg)) 0%,
        color-mix(in srgb, var(--primary) 3%, var(--sidebar-bg)) 70%,
        var(--sidebar-bg) 100%
    ) !important;
    border-bottom: 1px solid color-mix(in srgb, var(--primary) 12%, var(--sidebar-border)) !important;
}

body[data-ui-theme="calm-slate"] .sidebar-footer {
    background: var(--sidebar-bg) !important;
    border-top: 1px solid var(--sidebar-border) !important;
}

body[data-ui-theme="calm-slate"] .sidebar-brand-text {
    color: var(--dark) !important;
    font-weight: 700 !important;
}

body[data-ui-theme="calm-slate"] .status-pill-fieldset {
    background: rgba(0, 0, 0, 0.03);
    border-radius: 12px;
    padding: 3px;
}
