/* =============================================================================
   SI Leader Portal — Main Stylesheet
   Covers: login page, app shell (sidebar + topbar), page layout, utilities
   ============================================================================= */

/* ── Reset & Base ────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --blue-700:   #1D4ED8;
    --blue-600:   #2563EB;
    --blue-500:   #3B82F6;
    --blue-100:   #DBEAFE;
    --blue-50:    #EFF6FF;
    --slate-900:  #0F172A;
    --slate-800:  #1E293B;
    --slate-700:  #334155;
    --slate-500:  #64748B;
    --slate-300:  #CBD5E1;
    --slate-200:  #E2E8F0;
    --slate-100:  #F1F5F9;
    --slate-50:   #F8FAFC;
    --white:      #FFFFFF;
    --green-700:  #15803D;
    --green-100:  #DCFCE7;
    --red-600:    #DC2626;
    --red-100:    #FEE2E2;
    --orange-100: #FFEDD5;
    --orange-700: #C2410C;
    --radius-sm:  6px;
    --radius-md:  10px;
    --radius-lg:  16px;
    --shadow-sm:  0 1px 3px rgba(0,0,0,.08);
    --shadow-md:  0 4px 16px rgba(0,0,0,.10);
    --shadow-lg:  0 8px 32px rgba(0,0,0,.12);
    --sidebar-w:  240px;
    --topbar-h:   64px;
    --font:       -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --ease-out-strong: cubic-bezier(0.23, 1, 0.32, 1);
    --ease-in-out-strong: cubic-bezier(0.77, 0, 0.175, 1);
    --motion-press: 140ms;
    --motion-fast: 180ms;
    --motion-medium: 240ms;
}

/* ── Exquisite Dark Mode Color Token Overrides ── */
html[data-theme="dark"] {
    --white:      #111827; /* dark charcoal card background */
    --slate-50:   #0B0F19; /* deepest pitch black/slate backdrop */
    --slate-100:  #0F172A; /* body background */
    --slate-200:  #1F2937; /* standard borders */
    --slate-300:  #374151; /* input/focused borders */
    --slate-500:  #94A3B8; /* soft helper text */
    --slate-700:  #CBD5E1; /* text secondary */
    --slate-800:  #E2E8F0; /* body text */
    --slate-900:  #F8FAFC; /* headers & emphasis */
    
    /* System high contrast highlights */
    --blue-50:    #1E293B;
    --blue-100:   #1E3A8A;
    --blue-500:   #60A5FA;
    --blue-600:   #3B82F6;
    --blue-700:   #2563EB;
}

/* ── Exquisite Premium Color Theme Presets ── */
/* 🍃 Emerald Preset */
html[data-preset="emerald"] {
    --blue-700: #15803D;
    --blue-600: #16A34A;
    --blue-500: #22C55E;
    --blue-100: #DCFCE7;
    --blue-50:  #F0FDF4;
}
html[data-theme="dark"][data-preset="emerald"] {
    --blue-700: #16A34A;
    --blue-600: #22C55E;
    --blue-500: #4ADE80;
    --blue-100: #064E3B;
    --blue-50:  #022C22;
}

/* 🔮 Indigo Preset */
html[data-preset="indigo"] {
    --blue-700: #4338CA;
    --blue-600: #4F46E5;
    --blue-500: #6366F1;
    --blue-100: #E0E7FF;
    --blue-50:  #EEF2FF;
}
html[data-theme="dark"][data-preset="indigo"] {
    --blue-700: #4F46E5;
    --blue-600: #6366F1;
    --blue-500: #818CF8;
    --blue-100: #312E81;
    --blue-50:  #1E1B4B;
}

/* 🍊 Amber Preset */
html[data-preset="amber"] {
    --blue-700: #B45309;
    --blue-600: #D97706;
    --blue-500: #F59E0B;
    --blue-100: #FEF3C7;
    --blue-50:  #FFFBEB;
}
html[data-theme="dark"][data-preset="amber"] {
    --blue-700: #D97706;
    --blue-600: #F59E0B;
    --blue-500: #FBBF24;
    --blue-100: #78350F;
    --blue-50:  #451A03;
}

/* 💎 Teal Preset */
html[data-preset="teal"] {
    --blue-700: #0F766E;
    --blue-600: #0D9488;
    --blue-500: #14B8A6;
    --blue-100: #CCFBF1;
    --blue-50:  #F0FDFA;
}
html[data-theme="dark"][data-preset="teal"] {
    --blue-700: #0D9488;
    --blue-600: #14B8A6;
    --blue-500: #2DD4BF;
    --blue-100: #115E59;
    --blue-50:  #134E4A;
}

/* Global transitions for beautiful fade effects */
html, body, .sidebar, .topbar, .card, .btn, .btn-icon, .topbar-leader, .table, td, th, .page-header, .sidebar-logo, .nav-links a {
    transition: background-color var(--motion-medium) ease, 
                color var(--motion-medium) ease, 
                border-color var(--motion-medium) ease,
                box-shadow var(--motion-medium) ease;
}

html, body {
    height: 100%;
    font-family: var(--font);
    font-size: 14px;
    color: var(--slate-800);
    background: var(--slate-100);
    line-height: 1.5;
}

/* ── App Shell ───────────────────────────────────────────────────────────── */
.app-shell {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* ── Sidebar ─────────────────────────────────────────────────────────────── */
.sidebar {
    width: var(--sidebar-w);
    flex-shrink: 0;
    background: var(--white);
    border-right: 1px solid var(--slate-200);
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    transition: width var(--motion-medium) var(--ease-out-strong), transform var(--motion-medium) var(--ease-out-strong), border-color var(--motion-fast) ease;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px 16px 16px;
    border-bottom: 1px solid var(--slate-200);
}

.sidebar-logo {
    width: 36px; height: 36px;
    background: var(--blue-600);
    border-radius: var(--radius-md);
    display: flex; align-items: center; justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.sidebar-title strong { display: block; font-size: 13px; color: var(--slate-800); }
.sidebar-title small  { display: block; font-size: 11px; color: var(--slate-500); }

.nav-links {
    list-style: none;
    padding: 12px 8px;
    flex: 1;
}

.nav-links li { margin-bottom: 2px; }

.nav-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    color: var(--slate-700);
    text-decoration: none;
    font-weight: 500;
    font-size: 13.5px;
    transition: background .15s, color .15s;
}

.nav-link:hover { background: var(--slate-100); color: var(--blue-600); }
.nav-link.active { background: var(--blue-600); color: var(--white); }
.nav-icon { font-size: 16px; width: 20px; text-align: center; }

/* ── Admin navigation section ─────────────────────────────────────────────── */
.nav-divider {
    height: 1px;
    background: var(--slate-200);
    margin: 12px 12px 8px;
}

html[data-theme="dark"] .nav-divider {
    background: rgba(75, 85, 99, 0.4);
}

.admin-section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px 6px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--slate-500);
}

.admin-badge-tag {
    font-size: 8px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 2px 7px;
    background: linear-gradient(135deg, var(--blue-600) 0%, var(--blue-500) 100%);
    color: white;
    border-radius: 9999px;
    box-shadow: 0 2px 6px rgba(59, 130, 246, 0.25);
    transition: background var(--motion-medium) ease, box-shadow var(--motion-medium) ease;
}

html[data-theme="dark"] .admin-badge-tag {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.admin-links-top {
    list-style: none;
    padding: 4px 8px 8px;
}

.admin-links-top li {
    margin-bottom: 2px;
}

.admin-nav {
    color: var(--slate-700);
    position: relative;
    transition: background var(--motion-fast) ease, color var(--motion-fast) ease, transform var(--motion-fast) var(--ease-out-strong), padding-left var(--motion-fast) var(--ease-out-strong);
}

html[data-theme="dark"] .admin-nav {
    color: var(--slate-700);
}

.admin-nav:hover:not(.active) {
    background: var(--slate-50);
    color: var(--blue-600);
    transform: translateX(4px);
}

html[data-theme="dark"] .admin-nav:hover:not(.active) {
    background: rgba(55, 65, 81, 0.4);
    color: var(--blue-500);
}

.admin-nav.active {
    background: linear-gradient(135deg, var(--blue-600) 0%, var(--blue-500) 100%);
    color: white !important;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.18);
    font-weight: 600;
}

.admin-nav.active::before {
    content: '';
    position: absolute;
    left: 0;
    top: 15%;
    bottom: 15%;
    width: 3px;
    background: white;
    border-radius: 0 4px 4px 0;
    box-shadow: 0 0 8px white;
}

.admin-nav-groups {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 8px 16px;
}

.admin-nav-group {
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-md);
    background: var(--white);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: border-color var(--motion-medium) ease, box-shadow var(--motion-medium) ease, background var(--motion-medium) ease;
}

.admin-nav-group[open] {
    border-color: var(--blue-500);
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.08);
}

html[data-theme="dark"] .admin-nav-group {
    background: rgba(31, 41, 55, 0.35);
    border-color: rgba(75, 85, 99, 0.45);
}

html[data-theme="dark"] .admin-nav-group[open] {
    border-color: var(--blue-600);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.admin-nav-group-title {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    font-size: 12.5px;
    font-weight: 700;
    color: var(--slate-700);
    cursor: pointer;
    transition: background var(--motion-fast) ease, color var(--motion-fast) ease;
}

html[data-theme="dark"] .admin-nav-group-title {
    color: var(--slate-700);
}

.admin-nav-group-title::-webkit-details-marker {
    display: none;
}

.admin-nav-group-title::after {
    content: "›";
    margin-left: auto;
    font-size: 16px;
    font-weight: 400;
    line-height: 1;
    transform: rotate(90deg);
    transition: transform var(--motion-medium) var(--ease-out-strong), color var(--motion-medium) ease;
}

.admin-nav-group[open] .admin-nav-group-title::after {
    transform: rotate(270deg);
    color: var(--blue-600);
}

.admin-nav-group-title:hover {
    background: var(--slate-50);
    color: var(--blue-600);
}

html[data-theme="dark"] .admin-nav-group-title:hover {
    background: rgba(55, 65, 81, 0.55);
    color: var(--blue-500);
}

.admin-nav-group-icon {
    font-size: 14px;
}

.grouped-admin-links {
    list-style: none;
    padding: 6px 8px 10px;
    border-top: 1px dashed var(--slate-200);
    background: rgba(248, 250, 252, 0.65);
    transition: background var(--motion-medium) ease;
}

html[data-theme="dark"] .grouped-admin-links {
    border-top-color: rgba(75, 85, 99, 0.4);
    background: rgba(17, 24, 39, 0.3);
}

.grouped-admin-links .nav-link {
    font-size: 12.5px;
    padding: 8px 10px;
    margin-bottom: 2px;
}

.sidebar-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 16px;
    border-top: 1px solid var(--slate-200);
}

.leader-avatar {
    width: 34px; height: 34px;
    background: var(--blue-100);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 12px; color: var(--blue-700);
    flex-shrink: 0;
}

.leader-info { flex: 1; min-width: 0; }
.leader-details strong { display: block; font-size: 12.5px; color: var(--slate-800); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.leader-details small  { display: block; font-size: 11px; color: var(--slate-500); }

/* ── Topbar ──────────────────────────────────────────────────────────────── */
.topbar {
    height: var(--topbar-h);
    background: var(--white);
    border-bottom: 1px solid var(--slate-200);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    flex-shrink: 0;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-date { color: var(--slate-500); font-size: 13px; }

.topbar-leader strong { display: block; font-size: 13px; color: var(--slate-800); }
.topbar-leader small  { display: block; font-size: 11px; color: var(--slate-500); text-align: right; }
.nav-toggle { display: inline-flex; }
.mobile-sidebar-close,
.mobile-nav-overlay,
.mobile-topbar-title { display: none; }

.mobile-topbar-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--slate-800);
}

/* ── Main content area ───────────────────────────────────────────────────── */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.page-content {
    flex: 1;
    overflow-y: auto;
    padding: 32px;
}

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn-icon {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    padding: 6px;
    border-radius: var(--radius-sm);
    color: var(--slate-500);
    transition: transform var(--motion-press) var(--ease-out-strong), background var(--motion-fast) ease, color var(--motion-fast) ease;
}
.btn-icon:hover { background: var(--slate-100); }
.btn-icon:active { transform: scale(0.97); }

.btn-logout {
    background: none;
    border: 1px solid var(--slate-300);
    border-radius: var(--radius-sm);
    padding: 6px 12px;
    font-size: 12.5px;
    color: var(--slate-600);
    cursor: pointer;
    transition: transform var(--motion-press) var(--ease-out-strong), background var(--motion-fast) ease, border-color var(--motion-fast) ease, color var(--motion-fast) ease;
}
.btn-logout:hover { background: var(--red-100); border-color: var(--red-600); color: var(--red-600); }
.btn-logout:active { transform: scale(0.97); }

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--blue-600);
    color: var(--white);
    border: none;
    border-radius: var(--radius-md);
    padding: 10px 20px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
    transition: transform var(--motion-press) var(--ease-out-strong), background var(--motion-fast) var(--ease-out-strong), box-shadow var(--motion-fast) ease;
}
.btn-primary:hover { background: var(--blue-700); }
.btn-primary:active { transform: scale(0.97); }

/* ── Cards ───────────────────────────────────────────────────────────────── */
.card {
    background: var(--white);
    border-radius: var(--radius-lg);
    border: 1px solid var(--slate-200);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.cards-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.card-action-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.card-icon { font-size: 22px; }
.card-label { font-size: 11px; font-weight: 700; color: var(--slate-500); letter-spacing: .05em; }

/* ── Page header ─────────────────────────────────────────────────────────── */
.page-header {
    margin-bottom: 32px;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--slate-900);
}

.page-subtitle {
    font-size: 13px;
    color: var(--slate-500);
    margin-top: 4px;
}

.text-primary { color: var(--blue-600); }
.text-muted   { color: var(--slate-500); font-size: 13px; }

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.section-header h2 { font-size: 16px; font-weight: 600; }
.link-view-all { font-size: 13px; color: var(--blue-600); text-decoration: none; }
.link-action   { font-size: 13px; color: var(--blue-600); text-decoration: none; font-weight: 600; }

.quick-actions { margin-bottom: 40px; }

/* ── Alerts ──────────────────────────────────────────────────────────────── */
.alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    font-size: 13.5px;
    margin-bottom: 18px;
}

.alert-error   { background: var(--red-100);    color: #991B1B; border: 1px solid #FECACA; }
.alert-warning { background: var(--orange-100); color: var(--orange-700); border: 1px solid #FED7AA; }
.alert-icon    { flex-shrink: 0; }

/* ── Spinner ─────────────────────────────────────────────────────────────── */
.spinner {
    width: 40px; height: 40px;
    border: 4px solid var(--slate-200);
    border-top-color: var(--blue-600);
    border-radius: 50%;
    animation: spin .7s linear infinite;
    margin: 0 auto;
}

.spinner-sm {
    display: inline-block;
    width: 16px; height: 16px;
    border: 2px solid rgba(255,255,255,.4);
    border-top-color: var(--white);
    border-radius: 50%;
    animation: spin .7s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.loading-auth {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 60px;
    color: var(--slate-500);
}

/* ── Login Page ──────────────────────────────────────────────────────────── */
.login-page {
    min-height: 100vh;
    background: var(--slate-100);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 16px;
}

.login-card {
    display: flex;
    width: 100%;
    max-width: 900px;
    background: var(--white);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    overflow: hidden;
    border: 1px solid var(--slate-200);
}

.login-card-left {
    flex: 1;
    padding: 48px;
    min-width: 0;
}

.login-card-right {
    flex: 0 0 380px;
    background: linear-gradient(145deg, #EFF6FF 0%, #DBEAFE 100%);
    padding: 48px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 32px;
}

.login-title {
    font-size: 26px;
    font-weight: 700;
    color: var(--slate-900);
    margin-bottom: 8px;
}

.login-subtitle {
    font-size: 14px;
    color: var(--slate-500);
    margin-bottom: 28px;
    line-height: 1.6;
}

/* Form */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 16px;
}

.form-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--slate-700);
}

.form-input {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid var(--slate-300);
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--slate-800);
    background: var(--white);
    transition: border-color .15s, box-shadow .15s;
    outline: none;
}

.form-input:focus {
    border-color: var(--blue-500);
    box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}

.form-input.input-error {
    border-color: var(--red-600);
}

.form-input:disabled {
    background: var(--slate-100);
    color: var(--slate-400);
    cursor: not-allowed;
}

.input-with-icon {
    position: relative;
}

.input-with-icon .input-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 15px;
    color: var(--slate-400);
    pointer-events: none;
}

.input-with-icon .form-input {
    padding-left: 38px;
}

.field-error {
    font-size: 12px;
    color: var(--red-600);
}

.form-check {
    flex-direction: row;
    align-items: center;
    gap: 10px;
    margin-bottom: 24px;
}

.form-check label {
    font-weight: 400;
    font-size: 13.5px;
    color: var(--slate-600);
    cursor: pointer;
}

.btn-login {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--blue-700);
    color: var(--white);
    border: none;
    border-radius: var(--radius-md);
    padding: 13px 24px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s, transform .1s;
    margin-bottom: 20px;
}

.btn-login:hover:not(:disabled) { background: var(--slate-800); }
.btn-login:active:not(:disabled) { transform: scale(.99); }
.btn-login:disabled { opacity: .65; cursor: not-allowed; }
.btn-arrow { font-size: 18px; }

.login-security {
    font-size: 12px;
    color: var(--slate-400);
    text-align: center;
}

.link-plain { color: var(--blue-600); text-decoration: none; }
.link-plain:hover { text-decoration: underline; }

.btn-link-secondary {
    background: none;
    border: none;
    color: var(--blue-600);
    font-size: 13px;
    font-weight: 500;
    padding: 0;
    cursor: pointer;
    text-decoration: none;
    transition: color .15s;
}
.btn-link-secondary:hover:not(:disabled) { 
    color: var(--blue-700);
    text-decoration: underline;
}
.btn-link-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Right panel */
.secure-badge {
    text-align: center;
}

.secure-icon {
    width: 72px; height: 72px;
    background: var(--blue-600);
    border-radius: var(--radius-lg);
    display: flex; align-items: center; justify-content: center;
    font-size: 34px;
    margin: 0 auto 16px;
    box-shadow: var(--shadow-md);
}

.secure-badge h2 {
    font-size: 18px;
    font-weight: 700;
    color: var(--slate-900);
    margin-bottom: 8px;
}

.secure-badge p {
    font-size: 13px;
    color: var(--slate-600);
    line-height: 1.6;
}

.feature-tiles {
    display: flex;
    gap: 16px;
}

.feature-tile {
    flex: 1;
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 16px;
    text-align: center;
    border: 1px solid var(--slate-200);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.feature-icon { font-size: 24px; }
.feature-label { font-size: 11px; font-weight: 700; color: var(--slate-700); letter-spacing: .08em; }

.login-footer {
    margin-top: 32px;
    font-size: 12px;
    color: var(--slate-400);
    text-align: center;
}

/* ── Empty layout (login page wrapper) ───────────────────────────────────── */
.empty-layout { min-height: 100vh; }

/* ── Not-found / not-authorized ──────────────────────────────────────────── */
.not-authorized-container,
.not-found-container {
    text-align: center;
    padding: 80px 20px;
}

.not-authorized-container h2,
.not-found-container h2 {
    font-size: 22px;
    margin-bottom: 12px;
    color: var(--slate-700);
}

/* ── Responsive: collapse sidebar on small screens ───────────────────────── */
@media (min-width: 769px) {
    .app-shell.sidebar-collapsed .sidebar {
        width: 0;
        min-width: 0;
        border-right-color: transparent;
        transform: translateX(-100%);
        overflow: hidden;
    }
}

@media (max-width: 768px) {
    .app-shell { height: 100dvh; position: relative; }

    .sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: min(86vw, 320px);
        z-index: 130;
        transform: translateX(-100%);
        transition: transform var(--motion-medium) var(--ease-out-strong);
        box-shadow: var(--shadow-lg);
    }

    .mobile-nav-open .sidebar {
        transform: translateX(0);
    }

    .mobile-nav-overlay {
        display: block;
        position: fixed;
        inset: 0;
        border: none;
        background: rgba(15, 23, 42, 0.45);
        opacity: 0;
        pointer-events: none;
        z-index: 120;
        transition: opacity var(--motion-fast) ease;
    }

    .mobile-nav-open .mobile-nav-overlay {
        opacity: 1;
        pointer-events: auto;
    }

    .mobile-sidebar-close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .mobile-sidebar-close {
        margin-left: auto;
    }

    .mobile-topbar-title { display: block; }

    .main-content {
        width: 100%;
        min-width: 0;
    }

    .topbar {
        padding: 0 12px;
        gap: 8px;
    }

    .topbar-right {
        gap: 8px;
    }

    .topbar-date,
    .topbar-leader small {
        display: none;
    }

    .topbar-leader strong {
        font-size: 12px;
    }

    .page-content {
        padding: 16px 14px 24px;
    }

    .login-card       { flex-direction: column; }
    .login-card-right { display: none; }
    .form-row         { grid-template-columns: 1fr; }
}

/* ── Blazor Error UI ─────────────────────────────────────────────────────── */
#blazor-error-ui {
    background: lightyellow;
    bottom: 0;
    box-shadow: 0 -1px 5px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

#blazor-error-ui a.reload {
    color: #c74430;
    text-decoration: underline;
}

/* ── Messages / Announcements Page ──────────────────────────────────────── */
.messages-page {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

.messages-page .page-header {
    margin-bottom: 32px;
}

.messages-page .page-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: var(--slate-800);
    margin-bottom: 4px;
}

.messages-page .subtitle {
    color: var(--slate-500);
    font-size: 14px;
}

.announcements-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.announcement-card {
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    padding: 24px;
    border-left: 4px solid var(--blue-500);
}

.announcement-card.priority-urgent {
    border-left-color: #DC2626;
    background: #FEF2F2;
}

.announcement-card.priority-high {
    border-left-color: #F59E0B;
    background: #FFFBEB;
}

.announcement-card.priority-normal {
    border-left-color: var(--blue-500);
}

.announcement-card.priority-low {
    border-left-color: var(--slate-400);
}

.announcement-header {
    margin-bottom: 16px;
}

.announcement-title-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
}

.priority-badge {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.priority-badge.priority-urgent {
    background: #FEE2E2;
    color: #DC2626;
}

.priority-badge.priority-high {
    background: #FEF3C7;
    color: #D97706;
}

.priority-badge.priority-normal {
    background: var(--blue-100);
    color: var(--blue-700);
}

.priority-badge.priority-low {
    background: var(--slate-200);
    color: var(--slate-600);
}

.announcement-title {
    font-size: 20px;
    font-weight: 600;
    color: var(--slate-800);
}

.announcement-meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: var(--slate-500);
}

.announcement-content {
    color: var(--slate-700);
    line-height: 1.6;
    font-size: 14px;
}

.announcement-footer {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--slate-200);
    font-size: 13px;
    color: var(--slate-500);
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
}

.empty-icon {
    font-size: 72px;
    margin-bottom: 16px;
}

.empty-state h3 {
    font-size: 20px;
    color: var(--slate-700);
    margin-bottom: 8px;
}

.empty-state p {
    color: var(--slate-500);
}


/* ── Notification Badge on Messages ─────────────────────────────────────────── */
.nav-messages {
    position: relative;
}

.notification-badge {
    position: absolute;
    top: 8px;
    right: 12px;
    min-width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
    color: white;
    font-size: 11px;
    font-weight: 700;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4);
    animation: pulse-badge 2s infinite;
}

@keyframes pulse-badge {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* ── Student Labels/Badges (ASAP, Freshman) ────────────────────────────────── */
.tier-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
    margin-left: 6px;
}

.tier-badge--asap {
    background: #DBEAFE;
    color: #1E40AF;
}

.tier-badge--freshman {
    background: #FEF3C7;
    color: #92400E;
}

/* ── Student Management Enhanced UI ─────────────────────────────────────────── */

/* Bulk Actions Bar */
.bulk-actions-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
    background: linear-gradient(135deg, var(--blue-600) 0%, var(--blue-700) 100%);
    border-radius: var(--radius-md);
    margin-bottom: 16px;
    box-shadow: var(--shadow-md);
}

.bulk-count {
    font-weight: 600;
    color: white;
    font-size: 14px;
}

.bulk-buttons {
    display: flex;
    gap: 8px;
}

.btn-bulk {
    padding: 6px 12px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: transform var(--motion-press) var(--ease-out-strong), background var(--motion-fast) ease;
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.btn-bulk:hover {
    background: rgba(255, 255, 255, 0.3);
}
.btn-bulk:active {
    transform: scale(0.97);
}

.btn-bulk-remove {
    background: rgba(239, 68, 68, 0.3);
}

.btn-bulk-remove:hover {
    background: rgba(239, 68, 68, 0.5);
}

.btn-bulk-clear {
    background: rgba(0, 0, 0, 0.2);
}

.btn-bulk-clear:hover {
    background: rgba(0, 0, 0, 0.3);
}

/* Student Badges */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    white-space: nowrap;
}

.badge + .badge {
    margin-left: 4px;
}

.badge-asap {
    background: #DBEAFE;
    color: #1E40AF;
}

.badge-freshman {
    background: #FEF3C7;
    color: #92400E;
}

.badge-active {
    background: var(--green-100);
    color: var(--green-700);
}

.badge-inactive {
    background: var(--slate-200);
    color: var(--slate-500);
}

/* Student Name Link */
.student-name-link {
    color: var(--blue-600);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.15s ease;
}

.student-name-link:hover {
    color: var(--blue-700);
    text-decoration: underline;
}

/* Notes Indicator */
.notes-indicator {
    cursor: default;
    font-size: 16px;
}

/* Row Selected State */
.row-selected {
    background-color: var(--blue-50) !important;
}

.row-selected:hover {
    background-color: var(--blue-100) !important;
}

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity var(--motion-fast) var(--ease-out-strong);
    @starting-style {
        opacity: 0;
    }
}

.modal-content {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 560px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    opacity: 1;
    transform: translateY(0) scale(1);
    transform-origin: center;
    transition: transform var(--motion-medium) var(--ease-out-strong), opacity var(--motion-fast) var(--ease-out-strong);
    @starting-style {
        opacity: 0;
        transform: translateY(14px) scale(0.97);
    }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--slate-200);
}

.modal-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--slate-800);
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    font-size: 20px;
    color: var(--slate-500);
    cursor: pointer;
    padding: 4px;
    line-height: 1;
    transition: color 0.15s ease;
}

.modal-close:hover {
    color: var(--slate-700);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    max-height: calc(90vh - 160px);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid var(--slate-200);
    background: var(--slate-50);
}

/* Student Profile Header */
.student-profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--slate-200);
    margin-bottom: 24px;
}

.student-avatar-large {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, var(--blue-600) 0%, var(--blue-700) 100%);
    color: white;
    font-size: 24px;
    font-weight: 600;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.student-profile-info h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--slate-800);
    margin: 0 0 4px 0;
}

.student-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

/* Student Detail Sections */
.student-detail-section {
    margin-bottom: 24px;
}

.student-detail-section:last-child {
    margin-bottom: 0;
}

.student-detail-section h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--slate-700);
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.notes-content {
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-md);
    padding: 16px;
}

.notes-content p {
    margin: 0;
    color: var(--slate-700);
    line-height: 1.6;
    white-space: pre-wrap;
}

.text-muted {
    color: var(--slate-400);
    font-style: italic;
}

/* Info Grid */
.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-label {
    font-size: 12px;
    font-weight: 500;
    color: var(--slate-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.info-value {
    font-size: 14px;
    color: var(--slate-800);
}

/* Admin Checkbox Label */
.admin-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px;
    color: var(--slate-700);
}

.admin-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--blue-600);
    cursor: pointer;
}

/* Filter Select */
.toolbar-filters {
    display: flex;
    gap: 12px;
}

.filter-select {
    min-width: 160px;
}

/* Admin Code Badge */
.admin-code {
    font-family: 'SF Mono', Consolas, 'Liberation Mono', Menlo, monospace;
    font-size: 12px;
    background: var(--slate-100);
    padding: 2px 8px;
    border-radius: 4px;
    color: var(--slate-600);
}

/* Import Modal */
.import-modal {
    max-width: 600px;
}

.import-instructions {
    background: var(--blue-50);
    border: 1px solid var(--blue-100);
    border-radius: var(--radius-md);
    padding: 16px;
}

.import-instructions h4 {
    margin: 0 0 12px 0;
    font-size: 14px;
    font-weight: 600;
    color: var(--blue-700);
    display: flex;
    align-items: center;
    gap: 6px;
}

.import-instructions ol {
    margin: 0;
    padding-left: 20px;
    font-size: 13px;
    color: var(--slate-700);
    line-height: 1.8;
}

.import-instructions li {
    margin-bottom: 6px;
}

.file-input {
    display: block;
    width: 100%;
    padding: 10px;
    border: 2px dashed var(--slate-300);
    border-radius: var(--radius-md);
    background: var(--slate-50);
    cursor: pointer;
    transition: transform var(--motion-press) var(--ease-out-strong), border-color var(--motion-fast) ease, background var(--motion-fast) ease;
}

.file-input:hover {
    border-color: var(--blue-500);
    background: var(--blue-50);
}
.file-input:active {
    transform: scale(0.99);
}

.file-selected {
    margin-top: 12px;
    padding: 12px;
    background: var(--green-100);
    border: 1px solid #10b981;
    border-radius: var(--radius-md);
    font-size: 13px;
    color: var(--green-700);
    display: flex;
    align-items: center;
    gap: 8px;
}


/* ═══════════════════════════════════════════════════════════════════════════
   MENTOR MANAGEMENT STYLES
   ═══════════════════════════════════════════════════════════════════════════ */

/* Mentor Cards Grid */
.mentor-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.mentor-card {
    background: white;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-lg);
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: transform var(--motion-medium) var(--ease-out-strong), border-color var(--motion-fast) ease, box-shadow var(--motion-medium) ease;
}

.mentor-card:hover {
    border-color: var(--blue-300);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

@media (prefers-reduced-motion: reduce) {
    .btn-icon,
    .btn-logout,
    .btn-primary,
    .btn-bulk,
    .modal-overlay,
    .modal-content,
    .file-input,
    .mentor-card,
    .sidebar,
    .mobile-nav-overlay,
    .admin-nav-group-title::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
    }

    .btn-icon:active,
    .btn-logout:active,
    .btn-primary:active,
    .btn-bulk:active,
    .file-input:active {
        transform: none;
    }

    .mentor-card:hover {
        transform: none;
    }
}

.mentor-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 600;
    flex-shrink: 0;
}

.mentor-info {
    flex: 1;
    min-width: 0;
}

.mentor-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--slate-800);
    margin: 0 0 4px 0;
}

.mentor-detail {
    font-size: 13px;
    color: var(--slate-500);
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mentor-stats {
    text-align: center;
    padding: 8px 16px;
    background: var(--blue-50);
    border-radius: var(--radius-md);
}

.mentee-count {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: var(--blue-600);
    line-height: 1;
}

.mentee-label {
    font-size: 11px;
    color: var(--blue-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Mentor Badge */
.badge-mentor {
    background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

/* Section Title */
.section-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--slate-800);
    margin: 0 0 16px 0;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--slate-200);
}

/* Notes Cell */
.notes-cell {
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: var(--slate-500);
    font-size: 13px;
}

/* Assign Modal */
.assign-modal {
    max-width: 500px;
}

/* Checkbox List for Mentor Selection */
.leader-checkbox-list {
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-md);
    padding: 8px;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background 0.15s ease;
}

.checkbox-item:hover {
    background: var(--slate-50);
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.checkbox-item span {
    flex: 1;
    font-size: 14px;
    color: var(--slate-700);
}

.checkbox-item .badge {
    margin-left: auto;
}

/* Page Actions */
.page-actions {
    display: flex;
    gap: 12px;
}

/* ─────────────────────────────────────────────────────────────────────────────
   Mentor & Mentee Sections (Dashboard)
   ───────────────────────────────────────────────────────────────────────────── */

.mentor-info-section,
.mentees-section {
    margin: 2rem 0;
}

.mentor-info-card {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 0.5rem;
}

.mentor-avatar,
.mentee-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--blue-500), var(--blue-600));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: 600;
    text-transform: uppercase;
    flex-shrink: 0;
}

.mentee-avatar {
    width: 48px;
    height: 48px;
    font-size: 18px;
    margin: 0 auto 0.75rem;
}

.mentor-details h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.25rem;
    color: var(--slate-800);
}

.mentor-details .text-muted {
    font-size: 14px;
    margin-bottom: 0.5rem;
}

.mentor-notes {
    margin: 0.75rem 0 0 0;
    padding: 0.75rem;
    background: var(--slate-50);
    border-left: 3px solid var(--blue-500);
    border-radius: var(--radius-sm);
    font-size: 14px;
    color: var(--slate-700);
}

.mentee-card {
    text-align: center;
    padding: 1.5rem 1rem;
}

.mentee-card h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1rem;
    color: var(--slate-800);
}

.mentee-card .small {
    font-size: 12px;
}

.badge-secondary {
    background: var(--slate-300);
    color: var(--slate-700);
}

.mentee-notes-preview {
    margin-top: 0.5rem;
    font-size: 12px;
    color: var(--slate-600);
    font-style: italic;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mentees-section .cards-row {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

/* === Appended: phase4.css (start) === */

/* =============================================================================
   Phase 4 CSS — Weekly Schedule / Calendar
   Append to wwwroot/css/app.css  OR  add as a separate phase4.css link
   ============================================================================= */

/* ── Schedule page header ────────────────────────────────────────────────── */
.schedule-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

.schedule-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    flex-wrap: wrap;
}

.week-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

/* ── Week navigation ─────────────────────────────────────────────────────── */
.week-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    background: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-md);
    padding: 3px;
}

.btn-week-nav {
    width: 32px; height: 32px;
    border: none;
    background: none;
    border-radius: var(--radius-sm);
    font-size: 18px;
    cursor: pointer;
    color: var(--slate-600);
    transition: background .15s;
    display: flex; align-items: center; justify-content: center;
}
.btn-week-nav:hover:not(:disabled) { background: var(--slate-100); }
.btn-week-nav:disabled             { opacity: .4; cursor: not-allowed; }

.btn-week-nav-text {
    width: auto;
    height: 32px;
    padding: 0 10px;
    font-size: 12.5px;
    font-weight: 600;
}

.btn-week-today {
    padding: 5px 14px;
    border: none;
    background: none;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    color: var(--blue-600);
    transition: background .15s;
}
.btn-week-today:hover:not(:disabled) { background: var(--blue-50); }

.week-picker-group {
    display: flex;
    align-items: center;
    gap: 6px;
}

.week-picker-label {
    font-size: 12px;
    color: var(--slate-600);
    font-weight: 600;
}

.week-picker-input {
    height: 32px;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-sm);
    padding: 4px 8px;
    font-size: 12.5px;
    color: var(--slate-700);
    background: var(--white);
}

/* ── Calendar loading state ──────────────────────────────────────────────── */
.calendar-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 80px;
    color: var(--slate-400);
}

/* ── Calendar wrap card ──────────────────────────────────────────────────── */
.calendar-wrap {
    padding: 0;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 16px;
}

/* ── Calendar grid: 7 columns (time gutter + Mon-Sat) ─────────────────────── */
.calendar-grid {
    display: grid;
    grid-template-columns: 72px repeat(6, 1fr);
    min-width: 980px;
}

/* ── Header row cells ────────────────────────────────────────────────────── */
.cal-header-cell {
    height: 56px;
    border-bottom: 1px solid var(--slate-200);
    background: var(--slate-50);
}

.cal-day-header {
    height: 56px;
    border-bottom: 1px solid var(--slate-200);
    border-left: 1px solid var(--slate-100);
    background: var(--slate-50);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 6px;
}

.cal-day-header--today {
    background: var(--blue-50);
}

.cal-day-name {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .06em;
    color: var(--slate-500);
}

.cal-day-header--today .cal-day-name {
    color: var(--blue-600);
}

.cal-day-number {
    font-size: 13px;
    color: var(--slate-700);
}

.cal-day-number--today {
    background: var(--blue-600);
    color: var(--white);
    width: 210px; height: 26px;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700;
    font-size: 13px;
    line-height: 1;
}

/* ── Time gutter label ───────────────────────────────────────────────────── */
.cal-time-label {
    height: 80px;
    border-bottom: 1px solid var(--slate-100);
    border-right: 1px solid var(--slate-200);
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 6px 8px 0 0;
}

.cal-time-label span {
    font-size: 11px;
    color: var(--slate-400);
    white-space: nowrap;
}

/* ── Calendar cell (one hour × one day) ──────────────────────────────────── */
.cal-cell {
    height: 80px;
    border-bottom: 1px solid var(--slate-100);
    border-left: 1px solid var(--slate-100);
    position: relative;
    padding: 2px;
    transition: background .1s;
}

.cal-cell--today {
    background: rgba(59,130,246,.03);
}

/* ── Event block inside a cell ───────────────────────────────────────────── */
.cal-event-block {
    position: absolute;
    left: 2px;
    right: 2px;
    top: 2px;
    border-radius: var(--radius-sm);
    border-left: 3px solid;
    padding: 4px 6px;
    cursor: pointer;
    overflow: hidden;
    transition: filter .15s, box-shadow .15s, transform .15s;
    z-index: 1;
}

.cal-event-block.cal-event-stacked {
    width: calc(100% - 16px);
    box-shadow: 0 1px 3px rgba(0,0,0,0.12);
}

.cal-event-block:hover {
    filter: brightness(.96);
    box-shadow: var(--shadow-md);
    z-index: 10 !important;
    transform: scale(1.02);
}

.cal-event-overflow {
    position: absolute;
    background: var(--slate-700);
    color: white;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 8px;
    pointer-events: none;
    z-index: 20;
    white-space: nowrap;
}

.cal-event-count-indicator {
    position: absolute;
    top: 6px;
    right: 6px;
    background: var(--slate-100);
    color: var(--slate-700);
    border: 1px solid var(--slate-200);
    font-size: 10px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 8px;
    pointer-events: none;
    z-index: 15;
    white-space: nowrap;
}

.cal-event-time {
    font-size: 10.5px;
    font-weight: 600;
    color: var(--slate-600);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cal-event-title {
    font-size: 12px;
    font-weight: 700;
    color: var(--slate-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 1px;
}

.cal-event-location {
    font-size: 11px;
    color: var(--slate-500);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Summary bar below calendar ──────────────────────────────────────────── */
.schedule-summary-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    padding: 12px 0;
}

.schedule-legend {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    color: var(--slate-600);
}

.legend-dot {
    width: 10px; height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.legend-label { white-space: nowrap; }

/* ── Slideover panel ─────────────────────────────────────────────────────── */
.slideover-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(15,23,42,.25);
    z-index: 40;
    animation: fadeIn .15s ease;
}

.slideover {
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 380px;
    max-width: 100vw;
    background: var(--white);
    box-shadow: -8px 0 32px rgba(0,0,0,.12);
    z-index: 50;
    display: flex;
    flex-direction: column;
    animation: slideInRight .2s ease;
}

@keyframes slideInRight {
    from { transform: translateX(100%); }
    to   { transform: translateX(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.slideover-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 24px;
    border-bottom: 1px solid var(--slate-200);
    gap: 12px;
}

.slideover-type {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .07em;
    text-transform: uppercase;
    color: var(--slate-500);
    margin-bottom: 4px;
}

.slideover-title {
    font-size: 18px;
    font-weight: 700;
    color: var(--slate-900);
    margin: 0;
}

.slideover-close {
    font-size: 16px;
    flex-shrink: 0;
}

.slideover-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.slideover-detail-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 14px;
    color: var(--slate-700);
}

.slideover-icon {
    font-size: 18px;
    flex-shrink: 0;
    margin-top: 1px;
}

.slideover-notes {
    background: var(--slate-50);
    border-radius: var(--radius-md);
    padding: 14px;
}

.slideover-notes strong {
    display: block;
    font-size: 12px;
    font-weight: 700;
    color: var(--slate-500);
    text-transform: uppercase;
    letter-spacing: .05em;
    margin-bottom: 6px;
}

.slideover-notes p {
    font-size: 13.5px;
    color: var(--slate-700);
    line-height: 1.6;
    margin: 0;
}

.slideover-readonly-notice {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    font-size: 12.5px;
    color: var(--slate-500);
    margin-top: auto;
}

/* ── Event detail page (EventDetail.razor) ───────────────────────────────── */
.breadcrumb-link {
    display: inline-block;
    font-size: 13px;
    color: var(--blue-600);
    text-decoration: none;
    margin-bottom: 8px;
}
.breadcrumb-link:hover { text-decoration: underline; }

.event-detail-card { padding: 32px; }

.event-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.event-detail-full {
    grid-column: 1 / -1;
}

.event-detail-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.event-detail-icon {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 2px;
}

.event-detail-item label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    color: var(--slate-400);
    text-transform: uppercase;
    letter-spacing: .06em;
    margin-bottom: 3px;
}

.event-detail-item strong {
    font-size: 14px;
    color: var(--slate-800);
}

.event-readonly-notice {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--slate-50);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    font-size: 13px;
    color: var(--slate-500);
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .schedule-header      { flex-direction: column; }
    .slideover            { width: 100vw; }
    .event-detail-grid    { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    .schedule-summary-bar { flex-direction: column; align-items: flex-start; }
    .schedule-legend      { gap: 10px; }
}

/* ── Substitute Coverage Styles ──────────────────────────────────────────── */
.cal-event-block.has-substitute {
    border-left-width: 4px;
    border-left-style: dashed;
    position: relative;
}

.cal-event-block.has-substitute::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: repeating-linear-gradient(
        -45deg,
        transparent,
        transparent 3px,
        rgba(0, 0, 0, 0.03) 3px,
        rgba(0, 0, 0, 0.03) 6px
    );
    pointer-events: none;
    border-radius: inherit;
}

.substitute-indicator {
    margin-left: 4px;
    font-size: 10px;
}

.cal-event-substitute {
    font-size: 9px;
    color: var(--slate-600);
    font-style: italic;
    margin-top: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.slideover-substitute-alert {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: linear-gradient(135deg, #e0e7ff 0%, #dbeafe 100%);
    border: 1px solid #818cf8;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    margin-bottom: 20px;
}

.slideover-substitute-icon {
    font-size: 20px;
}

.slideover-substitute-alert strong {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: var(--slate-800);
    margin-bottom: 2px;
}

.slideover-substitute-alert p {
    margin: 0;
    font-size: 12.5px;
    color: var(--slate-600);
}

/* ── Meeting Days Grid (Classes admin form) ─────────────────────────────── */
.meeting-days-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.meeting-day-checkbox {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-sm);
    background: var(--white);
    cursor: pointer;
    transition: all .15s;
    font-size: 13px;
    color: var(--slate-700);
}

.meeting-day-checkbox:hover {
    background: var(--slate-50);
    border-color: var(--slate-300);
}

.meeting-day-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    accent-color: var(--blue-600);
    cursor: pointer;
}

.meeting-day-checkbox input[type="checkbox"]:checked + span {
    color: var(--blue-600);
    font-weight: 600;
}

.meeting-day-checkbox:has(input:checked) {
    border-color: var(--blue-400);
    background: var(--blue-50);
}

/* === Appended: phase5.css (start) === */

/* =============================================================================
   Phase 5 CSS — Attendance System
   Append to wwwroot/css/app.css  OR  add as a separate phase5.css link
   ============================================================================= */

/* ── Attendance page header ──────────────────────────────────────────────── */
.att-page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

/* ── Class selector grid ─────────────────────────────────────────────────── */
.att-class-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.att-class-card {
    background: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-lg);
    padding: 24px;
    cursor: pointer;
    transition: box-shadow .15s, border-color .15s, transform .1s;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.att-class-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--blue-300, #93C5FD);
    transform: translateY(-2px);
}

.att-class-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.att-class-icon    { font-size: 22px; }
.att-class-period  { font-size: 11px; font-weight: 700; color: var(--slate-400); letter-spacing: .06em; }
.att-class-name    { font-size: 17px; font-weight: 700; color: var(--slate-800); margin: 0; }
.att-class-subject { font-size: 13px; color: var(--slate-600); }
.att-class-room    { font-size: 12.5px; }

.att-class-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 6px;
    padding-top: 12px;
    border-top: 1px solid var(--slate-100);
}

.att-class-grade {
    font-size: 12px;
    font-weight: 600;
    background: var(--blue-50);
    color: var(--blue-700);
    padding: 3px 8px;
    border-radius: 12px;
}

/* ── Open session card (prompt) ──────────────────────────────────────────── */
.att-open-session-card {
    max-width: 480px;
    margin: 0 auto;
    text-align: center;
    padding: 48px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.att-open-icon    { font-size: 48px; }
.att-open-btn     { width: 100%; justify-content: center; padding: 14px; font-size: 15px; }
.att-window-hint  { font-size: 12.5px; color: var(--slate-400); }

/* ── Session bar ─────────────────────────────────────────────────────────── */
.att-session-bar {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 16px 20px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.att-back {
    font-size: 13px;
    color: var(--blue-600);
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: var(--radius-sm);
    white-space: nowrap;
    font-weight: 600;
}
.att-back:hover { background: var(--blue-50); }

.att-session-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.att-session-info strong { font-size: 15px; color: var(--slate-800); }

/* ── Summary pills ───────────────────────────────────────────────────────── */
.att-summary-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-left: auto;
}

.att-pill {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 6px 14px;
    border-radius: var(--radius-md);
    min-width: 52px;
}

.att-pill-count { font-size: 20px; font-weight: 700; line-height: 1.1; }
.att-pill-label { font-size: 10px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; }

.att-pill--present  { background: var(--green-100);  color: var(--green-700); }
.att-pill--absent   { background: var(--red-100);    color: var(--red-600); }
.att-pill--tardy    { background: var(--orange-100); color: var(--orange-700); }
.att-pill--unmarked { background: var(--slate-100);  color: var(--slate-600); }

/* ── Attendance progress bar ─────────────────────────────────────────────── */
.att-progress-wrap {
    width: 100%;
    height: 6px;
    background: var(--slate-100);
    border-radius: 3px;
    overflow: hidden;
    margin-top: 4px;
}

.att-progress-bar {
    height: 100%;
    background: var(--blue-500);
    border-radius: 3px;
    transition: width .3s ease;
}

/* ── Submitted banner ────────────────────────────────────────────────────── */
.att-submitted-banner {
    background: var(--green-100);
    color: var(--green-700);
    border: 1px solid #86EFAC;
    border-radius: var(--radius-md);
    padding: 12px 18px;
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 12px;
}

/* ── Toolbar ─────────────────────────────────────────────────────────────── */
.att-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 12px;
}

.att-filter-tabs {
    display: flex;
    gap: 4px;
    background: var(--white);
    border: 1px solid var(--slate-200);
    border-radius: var(--radius-md);
    padding: 3px;
}

.att-filter-tab {
    padding: 6px 14px;
    border: none;
    background: none;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    color: var(--slate-600);
    cursor: pointer;
    transition: background .1s, color .1s;
    white-space: nowrap;
}

.att-filter-tab.active {
    background: var(--blue-600);
    color: var(--white);
    font-weight: 600;
}

.att-toolbar-actions {
    display: flex;
    gap: 10px;
}

.att-submit-btn {
    background: var(--green-700);
}
.att-submit-btn:hover:not(:disabled) {
    background: #15803D;
}

/* ── Leader exception request card ────────────────────────────────────────── */
.att-exception-card {
    margin-bottom: 12px;
    padding: 14px;
}

.att-exception-header {
    margin-bottom: 8px;
}

.att-exception-header p {
    margin: 4px 0 0;
    font-size: 13px;
}

.att-exception-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
}

.att-request-btn {
    background: var(--red-600);
    color: var(--white);
    border-color: var(--red-600);
}

.att-request-btn:hover:not(:disabled) {
    background: #B91C1C;
}

/* ── Roster container ────────────────────────────────────────────────────── */
.att-roster {
    padding: 0;
    overflow: hidden;
}

.att-roster-header {
    display: grid;
    grid-template-columns: 1fr 160px 120px;
    padding: 10px 16px;
    background: var(--slate-50);
    border-bottom: 1px solid var(--slate-200);
    font-size: 11.5px;
    font-weight: 700;
    color: var(--slate-500);
    letter-spacing: .05em;
    text-transform: uppercase;
}

.att-header-actions { text-align: center; }
.att-header-time    { text-align: right; padding-right: 8px; }

/* ── Student row ─────────────────────────────────────────────────────────── */
.student-row {
    display: grid;
    grid-template-columns: 4px 1fr 160px 120px;
    align-items: center;
    border-bottom: 1px solid var(--slate-100);
    transition: background .1s;
    min-height: 52px;
}

.student-row:last-child  { border-bottom: none; }
.student-row:hover       { background: var(--slate-50); }
.student-row--disabled   { opacity: .6; }

/* Left colour strip */
.student-status-strip {
    height: 100%;
    min-height: 52px;
    border-radius: 0;
    width: 4px;
}

.strip-present  { background: var(--green-700); }
.strip-absent   { background: var(--red-600); }
.strip-tardy    { background: var(--orange-700); }
.strip-unmarked { background: var(--slate-200); }

/* Student info cell */
.student-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    min-width: 0;
}

.student-code {
    font-size: 11px;
    font-weight: 700;
    color: var(--slate-400);
    flex-shrink: 0;
}

.student-name {
    font-size: 14px;
    font-weight: 500;
    color: var(--slate-800);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Tier badge */
.tier-badge {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .05em;
    padding: 2px 6px;
    border-radius: 10px;
    flex-shrink: 0;
}

.tier-badge--honors, .tier-badge--1 {
    background: #FEF9C3;
    color: #854D0E;
}
.tier-badge--2 {
    background: var(--blue-100);
    color: var(--blue-700);
}
.tier-badge--3 {
    background: var(--slate-100);
    color: var(--slate-600);
}

/* Mark buttons cell */
.student-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 0 8px;
}

.btn-mark {
    padding: 10px;
    border-radius: var(--radius-sm);
    border: 1.5px solid transparent;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all .1s;
    background: var(--slate-100);
    color: var(--slate-500);
    min-width: 38px;
}

.btn-mark:hover:not(:disabled) { filter: brightness(.95); }
.btn-mark:disabled              { opacity: .4; cursor: not-allowed; }

.btn-mark-present { border-color: #86EFAC; }
.btn-mark-absent  { border-color: #FCA5A5; }
.btn-mark-tardy   { border-color: #FCD34D; }

.btn-mark-present.btn-mark--active {
    background: var(--green-700);
    color: var(--white);
    border-color: var(--green-700);
}

.btn-mark-absent.btn-mark--active {
    background: var(--red-600);
    color: var(--white);
    border-color: var(--red-600);
}

.btn-mark-tardy.btn-mark--active {
    background: #D97706;
    color: var(--white);
    border-color: #D97706;
}

/* Marked-at cell */
.student-marked-at {
    text-align: right;
    padding-right: 14px;
    font-size: 11.5px;
    color: var(--slate-400);
}

/* ── Countdown Timer component ───────────────────────────────────────────── */
.countdown-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--white);
    border: 2px solid var(--slate-200);
    border-radius: var(--radius-lg);
    padding: 12px 20px;
    min-width: 160px;
    text-align: center;
    transition: border-color .3s;
}

.countdown-block--warning  { border-color: #FCD34D; background: #FFFBEB; }
.countdown-block--critical { border-color: #FCA5A5; background: #FEF2F2; }
.countdown-block--expired  { border-color: var(--slate-300); background: var(--slate-50); }
.countdown-block--submitted { border-color: #86EFAC; background: #F0FDF4; }

.countdown-label {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .07em;
    color: var(--slate-500);
    margin-bottom: 2px;
}

.countdown-time {
    font-size: 28px;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
    letter-spacing: -1px;
    line-height: 1;
}

.countdown-time--green { color: var(--green-700); }
.countdown-time--amber { color: #D97706; }
.countdown-time--red   { color: var(--red-600); }

.countdown-progress-wrap {
    width: 100%;
    height: 4px;
    background: var(--slate-100);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 6px;
}

.countdown-progress-bar {
    height: 100%;
    border-radius: 2px;
    transition: width 1s linear, background .3s;
}

.countdown-hint {
    font-size: 10.5px;
    color: var(--slate-400);
    margin-top: 4px;
}

/* ── History page: extra column colours ──────────────────────────────────── */
.text-present { color: var(--green-700); font-weight: 700; }
.text-absent  { color: var(--red-600);   font-weight: 700; }
.text-tardy   { color: #D97706;          font-weight: 700; }

.badge-expired { background: var(--slate-100); color: var(--slate-500); }

/* ── Alert extras ────────────────────────────────────────────────────────── */
.alert-success {
    background: var(--green-100);
    color: var(--green-700);
    border: 1px solid #86EFAC;
}

.alert-dismiss {
    background: none;
    border: none;
    cursor: pointer;
    margin-left: auto;
    color: inherit;
    font-size: 14px;
    padding: 0 4px;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 900px) {
    .att-session-bar    { flex-wrap: wrap; }
    .att-summary-pills  { margin-left: 0; }
    .att-toolbar        { flex-direction: column; align-items: stretch; }
    .att-filter-tabs    { overflow-x: auto; }
    .att-toolbar-actions { flex-direction: column; }
    .att-exception-actions { flex-direction: column; }

    .att-roster-header  { grid-template-columns: 1fr 120px 80px; }
    .student-row        { grid-template-columns: 4px 1fr 120px 80px; }
    .student-marked-at  { font-size: 10px; }
}

@media (max-width: 768px) {
    /* Page header compact */
    .page-header {
        margin-bottom: 20px;
    }

    .page-title {
        font-size: 20px;
    }

    .page-subtitle {
        font-size: 12px;
    }

    /* Section headers stack */
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
        margin-bottom: 12px;
    }

    .section-header h2 {
        font-size: 15px;
    }

    /* Cards compact */
    .card {
        padding: 16px;
    }

    /* Cards row single column */
    .cards-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    /* Quick actions tighter */
    .quick-actions {
        margin-bottom: 24px;
    }

    /* Card action compact */
    .card-action-title {
        font-size: 14px;
    }

    .card-action-desc {
        font-size: 12px;
    }

    /* Mentor card stacked */
    .mentor-info-card {
        flex-direction: column;
        text-align: center;
    }

    .mentor-avatar {
        margin: 0 auto;
    }

    .mentor-details {
        align-items: center;
    }

    /* Mentee cards compact */
    .mentees-section .cards-row {
        grid-template-columns: 1fr 1fr;
        gap: 10px;
    }

    .mentee-card {
        padding: 14px;
    }

    .mentee-card h4 {
        font-size: 13px;
    }

    /* Notifications compact */
    .notif-row {
        gap: 10px;
        padding: 10px 0;
    }

    .notif-body strong {
        font-size: 12.5px;
    }

    .notif-text {
        font-size: 11.5px;
    }

    /* Dashboard lower row */
    .dashboard-lower-row {
        gap: 14px;
        margin-top: 16px;
    }

    /* Form inputs full width */
    .form-group {
        margin-bottom: 14px;
    }

    .form-input, .form-select, textarea.form-input {
        font-size: 14px;
    }

    /* Alerts compact */
    .alert {
        font-size: 13px;
        padding: 10px 14px;
    }
}

@media (max-width: 600px) {
    .att-roster-header  { grid-template-columns: 1fr 120px; }
    .att-header-time    { display: none; }
    .student-row        { grid-template-columns: 4px 1fr 120px; }
    .student-marked-at  { display: none; }
    .countdown-block    { min-width: 130px; padding: 10px 14px; }
    .countdown-time     { font-size: 22px; }

    /* Mentee cards single column on very small */
    .mentees-section .cards-row {
        grid-template-columns: 1fr;
    }

    /* Page title even smaller */
    .page-title {
        font-size: 18px;
    }
}

/* === Added helpers: btn-secondary === */
.btn-secondary { background: var(--slate-100); color: var(--slate-800); border: 1px solid var(--slate-200); padding: 8px 12px; border-radius: var(--radius-sm); cursor: pointer; } .btn-secondary:hover:not(:disabled) { background: var(--slate-50); }

