/* ═══════════════════════════════════════════════════
   esm-theme.css  —  ESM Admin shell theme
   Covers: variables, reset, layout, topbar, sidebar,
           nav, panels, tables, metrics, dashboard,
           badges, filters, tags, responsive, dark mode
   ═══════════════════════════════════════════════════ */

/* ── CSS Variables ─────────────────────────────────── */
:root {
    --font-heading: 'Cabinet Grotesk', sans-serif;
    --font-body: 'IBM Plex Sans', sans-serif;
    --text-2xs: 11px;
    --text-xs: 12px;
    --text-sm: 13px;
    --text-base: 14px;
    --text-md: 15px;
    --text-lg: 17px;
    --bg: #f5f9ff;
    --surface: #ffffff;
    --surface-alt: #eef5fc;
    --panel: #ffffff;
    --border: #d7e3f3;
    --divider: #e3edf8;
    --accent: #1c4a96;
    --accent-soft: #e8f3fb;
    --accent-strong: #005a9e;
    --text: #1b1b1b;
    --text-soft: #4b5664;
    --text-faint: #6d7b8a;
    --danger: #d13438;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.06);
    --shadow-md: 0 8px 24px rgba(28,74,150,.12);
    --radius-xs: 4px;
    --radius-sm: 6px;
    --radius-md: 9px;
    --radius-lg: 14px;
}

[data-theme='dark'] {
    --bg: #0f172a;
    --surface: #111827;
    --surface-alt: #172036;
    --panel: #111827;
    --border: #22324d;
    --divider: #1f2d45;
    --accent: #4aa3ff;
    --accent-soft: rgba(74,163,255,.15);
    --accent-strong: #8cc8ff;
    --text: #eaf2ff;
    --text-soft: #b6c4d6;
    --text-faint: #7f90a8;
    --danger: #ff6b6b;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.35);
    --shadow-md: 0 10px 28px rgba(0,0,0,.42);
    color-scheme: dark;
}

/* ── Reset ─────────────────────────────────────────── */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

img, svg {
    max-width: 100%;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
}

body {
    margin: 0;
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.4;
    color: var(--text);
    background: linear-gradient(180deg, #f6fbff 0%, #eef5fc 100%);
}

[data-theme='dark'] body {
    background: linear-gradient(180deg, #0b1220 0, #111827 100%);
    color: var(--text);
}

/* ── App Shell ─────────────────────────────────────── */
.app-shell {
    display: grid;
    grid-template-columns: 240px minmax(0,1fr);
    grid-template-rows: 48px 1fr;
    min-height: 100vh;
    transition: grid-template-columns .18s ease;
    background: transparent;
}

    .app-shell.is-collapsed {
        grid-template-columns: 64px minmax(0,1fr);
    }

    .app-shell > .topbar {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .app-shell > .sidebar {
        grid-column: 1;
        grid-row: 2;
    }

    .app-shell > .main {
        grid-column: 2;
        grid-row: 2;
    }

/* ── Sidebar ───────────────────────────────────────── */
.sidebar {
    position: sticky;
    top: 48px !important;
    height: calc(100vh - 48px) !important;
    overflow-y: auto;
    overflow-x: visible;
    background: linear-gradient(180deg, #f8fbff 0%, #edf5fd 100%);
    border-right: 1px solid var(--border);
    padding: 8px 8px 10px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: padding .18s ease;
    z-index: 10020;
}

[data-theme='dark'] .sidebar {
    background: linear-gradient(180deg, #0f172a 0, #111827 100%);
    border-color: var(--border);
    color: var(--text);
}

.app-shell.is-collapsed .sidebar {
    padding-inline: 6px;
}

/* ── Logo ──────────────────────────────────────────── */
.logo-row {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 4px 6px;
    border-radius: var(--radius-md);
}

.logo-mark {
    width: 26px;
    height: 26px;
    border-radius: 999px;
    border: 1px solid var(--accent);
    background: var(--surface);
    display: grid;
    place-items: center;
    font-family: var(--font-heading);
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--accent);
}

.logo-text {
    display: flex;
    flex-direction: column;
    gap: 1px;
    min-width: 0;
}

.logo-title {
    font-family: var(--font-heading);
    font-size: var(--text-sm);
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    white-space: nowrap;
}

.logo-sub {
    font-size: var(--text-2xs);
    color: var(--text-soft);
    white-space: nowrap;
}

/* ═══════════════════════════════════════════════════
   NAV — sidebar navigation
   ═══════════════════════════════════════════════════ */

/* ── Category labels ────────────────────────────────── */
.nav-label {
    margin: 6px 4px 2px;
    font-size: var(--text-2xs);
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--text-faint);
}

.nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* ── ICON SIZE LOCK ──────────────────────────────────
   All .nav-icon SVGs are forced to exactly 14×14 px
   regardless of width/height attributes in the DB SVG.
   Caret icons are 12×12 px.
   ─────────────────────────────────────────────────── */
svg.nav-icon {
    width: 14px !important;
    height: 14px !important;
    min-width: 14px !important;
    max-width: 14px !important;
    flex: 0 0 14px !important;
    display: inline-block;
    vertical-align: middle;
    overflow: visible;
}

svg.nav-caret,
svg.nav-child-caret {
    width: 12px !important;
    height: 12px !important;
    min-width: 12px !important;
    max-width: 12px !important;
    flex: 0 0 12px !important;
    flex-shrink: 0;
}

/* ── L0 nav-parent button ───────────────────────────── */
.nav-item a,
.nav-parent {
    width: 100%;
    border: none;
    background: none;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 7px;
    border-radius: var(--radius-sm);
    font-size: var(--text-sm);
    color: var(--text-soft);
    cursor: pointer;
    text-align: left;
    transition: background .12s, color .12s;
}

.nav-parent-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    width: 100%;
}

.nav-parent-label {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    flex: 1;
    overflow: hidden;
}

    .nav-parent-label span {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

.nav-caret {
    transition: transform .15s ease;
}

.nav-section.is-open > .nav-parent .nav-caret {
    transform: rotate(90deg);
}

/* hover */
.nav-item:not(.is-active) a:hover,
.nav-parent:hover {
    background: rgba(28,74,150,.06);
    color: var(--text);
}

[data-theme='dark'] .nav-item a:hover,
[data-theme='dark'] .nav-parent:hover {
    background: rgba(74,163,255,.08);
}

/* dashboard active item */
.nav-item.is-active a {
    background: linear-gradient(90deg, rgba(28,74,150,.13), rgba(28,74,150,.04));
    color: var(--accent-strong);
    font-weight: 600;
    border-left: 3px solid var(--accent);
    padding-left: 4px;
}

[data-theme='dark'] .nav-item.is-active a {
    background: linear-gradient(90deg, rgba(74,163,255,.2), rgba(74,163,255,.07));
}

/* ── Dashboard item — unique treatment ───────────────
   Slightly elevated look to distinguish it as the
   "home" entry that isn't sourced from the database.  */
.nav-item-dashboard a {
    font-weight: 500;
}

    .nav-item-dashboard a svg {
        color: var(--text-soft);
        transition: color .12s;
    }

.nav-item-dashboard:not(.is-active) a:hover svg {
    color: var(--accent);
}

.nav-item-dashboard.is-active a {
    background: linear-gradient(90deg, rgba(28,74,150,.18), rgba(28,74,150,.06));
    color: var(--accent-strong);
    font-weight: 700;
    border-left: 3px solid var(--accent);
    padding-left: 4px;
    box-shadow: inset 0 0 0 1px rgba(28,74,150,.15);
}

    .nav-item-dashboard.is-active a svg {
        color: var(--accent);
    }

[data-theme='dark'] .nav-item-dashboard.is-active a {
    background: linear-gradient(90deg, rgba(74,163,255,.25), rgba(74,163,255,.08));
    box-shadow: inset 0 0 0 1px rgba(74,163,255,.2);
}

/* ── ACTIVE TRAIL on L0 button ───────────────────────
   Applied by VB when the current page is a descendant
   of this section.                                    */
.nav-section.is-trail > .nav-parent {
    background: linear-gradient(90deg, rgba(28,74,150,.11), rgba(28,74,150,.03));
    color: var(--accent-strong);
    font-weight: 600;
    border-left: 3px solid var(--accent);
    padding-left: 4px;
}

    .nav-section.is-trail > .nav-parent svg.nav-icon {
        color: var(--accent);
    }

[data-theme='dark'] .nav-section.is-trail > .nav-parent {
    background: linear-gradient(90deg, rgba(74,163,255,.18), rgba(74,163,255,.04));
    border-left-color: var(--accent);
}

/* ── Nav scroll container ───────────────────────────── */
.nav-scroll {
    flex: 1;
    overflow: visible;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-section {
    position: relative;
}

/* ═══════════════════════════════════════════════════
   L1 POPUP  (.nav-children)
   ═══════════════════════════════════════════════════ */
.nav-children {
    list-style: none;
    padding: 5px;
    margin: 0;
    position: fixed;
    min-width: 215px;
    max-width: 265px;
    z-index: 99999;
    background: var(--panel);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 28px rgba(0,0,0,.13), 0 0 0 1px var(--border);
    border: 1px solid var(--border);
    display: none;
}

.nav-section.is-open .nav-children {
    display: flex;
    flex-direction: column;
    gap: 1px;
}

/* Panel header — shows the section name */
.nav-children-header {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--accent);
    padding: 4px 8px 7px;
    border-bottom: 1px solid var(--divider);
    margin-bottom: 3px;
}

    .nav-children-header svg.nav-icon {
        width: 12px !important;
        height: 12px !important;
        min-width: 12px !important;
        flex: 0 0 12px !important;
        opacity: .8;
    }

/* ── L1 leaf item (.nav-child-item) ─────────────────── */
.nav-child-item {
    list-style: none;
}

    .nav-child-item > a {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 5px 8px;
        border-radius: var(--radius-xs);
        font-size: var(--text-2xs);
        color: var(--text-soft);
        text-decoration: none;
        white-space: nowrap;
        transition: background .12s, color .12s;
    }

        .nav-child-item > a:hover {
            background: rgba(28,74,150,.07);
            color: var(--accent-strong);
        }

[data-theme='dark'] .nav-child-item > a:hover {
    background: rgba(74,163,255,.10);
}

/* L1 active leaf */
.nav-child-item.is-active > a {
    background: linear-gradient(90deg, rgba(28,74,150,.14), rgba(28,74,150,.03));
    color: var(--accent-strong);
    font-weight: 600;
    border-left: 3px solid var(--accent);
    padding-left: 5px;
}

    .nav-child-item.is-active > a svg.nav-icon {
        color: var(--accent);
    }

[data-theme='dark'] .nav-child-item.is-active > a {
    background: linear-gradient(90deg, rgba(74,163,255,.22), rgba(74,163,255,.05));
    border-left-color: var(--accent);
}

/* text span inside child links */
.nav-child-text {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ═══════════════════════════════════════════════════
   L1 GROUP ROW with L2 flyout (.nav-child-group)
   ═══════════════════════════════════════════════════ */
.nav-child-group {
    list-style: none;
    position: relative;
}

a.nav-child-parent {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 5px 8px;
    border-radius: var(--radius-xs);
    font-size: var(--text-2xs);
    color: var(--text-soft);
    cursor: pointer;
    text-decoration: none;
    white-space: nowrap;
    transition: background .12s, color .12s;
}

    a.nav-child-parent:hover {
        background: rgba(28,74,150,.07);
        color: var(--accent-strong);
    }

[data-theme='dark'] a.nav-child-parent:hover {
    background: rgba(74,163,255,.10);
}

a.nav-child-parent svg.nav-child-caret {
    margin-left: auto;
    color: var(--text-faint);
    transition: color .12s, transform .12s;
}

a.nav-child-parent:hover svg.nav-child-caret,
.nav-child-group.is-open-sub a.nav-child-parent svg.nav-child-caret {
    color: var(--accent);
    transform: translateX(2px);
}

/* L1 group trail — active L2 child lives here */
.nav-child-group.is-trail > a.nav-child-parent {
    color: var(--accent-strong);
    font-weight: 600;
    background: rgba(28,74,150,.06);
    border-left: 3px solid rgba(28,74,150,.35);
    padding-left: 5px;
}

    .nav-child-group.is-trail > a.nav-child-parent svg.nav-icon {
        color: var(--accent);
    }

[data-theme='dark'] .nav-child-group.is-trail > a.nav-child-parent {
    background: rgba(74,163,255,.08);
    border-left-color: rgba(74,163,255,.35);
}

/* ═══════════════════════════════════════════════════
   L2 POPUP  (.nav-grandchildren)
   ═══════════════════════════════════════════════════ */
.nav-grandchildren {
    list-style: none;
    padding: 5px;
    margin: 0;
    position: fixed;
    min-width: 205px;
    max-width: 255px;
    z-index: 100001;
    background: var(--panel);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 28px rgba(0,0,0,.15), 0 0 0 1px var(--border);
    border: 1px solid var(--border);
    display: none;
    flex-direction: column;
    gap: 1px;
}

.nav-child-group:hover .nav-grandchildren,
.nav-child-group.is-open-sub .nav-grandchildren {
    display: flex;
}

/* Invisible bridge — fills the 6px gap between the sidebar
   button edge and the left border of .nav-children so the
   mouse never crosses empty space that would trigger mouseleave */
.nav-section.is-open .nav-children::before {
    content: '';
    position: fixed;
    top: 0;
    bottom: 0;
    left: -8px; /* reaches back to cover the gap */
    width: 8px;
    background: transparent;
    pointer-events: auto; /* catches the mouse mid-gap */
}

/* ── L2 leaf item (.nav-grand-item) ─────────────────── */
.nav-grand-item {
    list-style: none;
}

    .nav-grand-item > a {
        display: flex;
        align-items: center;
        gap: 8px;
        padding: 5px 8px;
        border-radius: var(--radius-xs);
        font-size: var(--text-2xs);
        color: var(--text-soft);
        text-decoration: none;
        white-space: nowrap;
        transition: background .12s, color .12s;
    }

        .nav-grand-item > a:hover {
            background: rgba(28,74,150,.07);
            color: var(--accent-strong);
        }

[data-theme='dark'] .nav-grand-item > a:hover {
    background: rgba(74,163,255,.10);
}

/* L2 active leaf */
.nav-grand-item.is-active > a {
    background: linear-gradient(90deg, rgba(28,74,150,.14), rgba(28,74,150,.03));
    color: var(--accent-strong);
    font-weight: 600;
    border-left: 3px solid var(--accent);
    padding-left: 5px;
}

    .nav-grand-item.is-active > a svg.nav-icon {
        color: var(--accent);
    }

[data-theme='dark'] .nav-grand-item.is-active > a {
    background: linear-gradient(90deg, rgba(74,163,255,.22), rgba(74,163,255,.05));
    border-left-color: var(--accent);
}

.nav-footer {
    margin-top: auto;
    padding-top: 4px;
    border-top: 1px solid var(--divider);
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.nav-meta {
    font-size: var(--text-2xs);
    color: var(--text-faint);
}

/* Collapsed sidebar — hide text labels */
.app-shell.is-collapsed .logo-text,
.app-shell.is-collapsed .nav-label,
.app-shell.is-collapsed .nav-footer,
.app-shell.is-collapsed .nav-item span,
.app-shell.is-collapsed .nav-parent-label span {
    display: none;
}

.app-shell.is-collapsed .nav-item a,
.app-shell.is-collapsed .nav-parent {
    justify-content: center;
    padding-inline: 0;
}

/* ── Nav Tooltip (collapsed state) ─────────────────── */
.nav-item, .nav-section {
    position: relative;
}

.nav-tooltip {
    position: fixed;
    background: #1e293b;
    color: #f1f5f9;
    font-size: 11px;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 5px;
    white-space: nowrap;
    pointer-events: none;
    z-index: 99999;
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity .12s ease, transform .12s ease;
    box-shadow: 0 4px 12px rgba(0,0,0,.25);
}

    .nav-tooltip::before {
        content: '';
        position: absolute;
        left: -4px;
        top: 50%;
        transform: translateY(-50%);
        border: 4px solid transparent;
        border-right-color: #1e293b;
        border-left: none;
    }

    .nav-tooltip.is-visible {
        opacity: 1;
        transform: translateX(0);
    }

[data-theme='dark'] .nav-tooltip {
    background: #334155;
}

    [data-theme='dark'] .nav-tooltip::before {
        border-right-color: #334155;
    }

/* ── Main content area ──────────────────────────────── */
.main {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.content-scroll {
    flex: 1;
    min-height: 0;
    overflow: auto;
    padding: 8px 12px 12px;
}

/* ── Topbar ─────────────────────────────────────────── */
.topbar {
    position: sticky;
    top: 0;
    z-index: 10030 !important;
    height: 48px;
    min-height: 48px;
    max-height: 48px;
    display: flex;
    align-items: center;
    padding: 0;
    background: #1c4a96;
    overflow: visible;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

[data-theme='dark'] .topbar {
    background: #001233;
}

.top-left {
    display: flex;
    align-items: center;
    gap: 0;
    flex-shrink: 0;
    height: 100%;
}

.az-hamburger {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #fff;
    flex-shrink: 0;
}

    .az-hamburger:hover {
        background: rgba(255,255,255,.12);
    }

    .az-hamburger svg {
        width: 20px;
        height: 20px;
    }

.az-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 12px 0 6px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: -.01em;
    white-space: nowrap;
    height: 100%;
    text-decoration: none;
}

    .az-logo svg {
        width: 22px;
        height: 22px;
        flex-shrink: 0;
    }

.top-school {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0 8px;
    height: 100%;
    border-left: 1px solid rgba(255,255,255,.2);
}

.crumb-current {
    color: rgba(255,255,255,.9);
    font-size: 12px;
    white-space: nowrap;
}

.top-middle {
    flex: 1 1 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    padding: 0 16px;
    height: 100%;
}

.search-box {
    position: relative;
    width: 100%;
    max-width: 420px;
}

    .search-box input {
        width: 100%;
        height: 30px;
        border-radius: 2px;
        border: 1px solid rgba(255,255,255,.35);
        padding: 0 32px 0 10px;
        font-size: 12px;
        font-family: inherit;
        background: rgba(255,255,255,.15);
        color: #fff;
        outline: none;
        transition: background .15s, border-color .15s;
    }

        .search-box input::placeholder {
            color: rgba(255,255,255,.7);
        }

        .search-box input:focus {
            background: rgba(255,255,255,.25);
            border-color: rgba(255,255,255,.7);
        }

    .search-box svg {
        position: absolute;
        right: 8px;
        top: 50%;
        transform: translateY(-50%);
        width: 14px;
        height: 14px;
        color: rgba(255,255,255,.8);
        pointer-events: none;
    }

.top-right {
    display: flex;
    align-items: center;
    gap: 0;
    flex-shrink: 0;
    flex-wrap: nowrap;
    height: 100%;
}

/* Azure-style topbar icon button */
.icon-btn {
    width: 48px;
    height: 48px;
    border-radius: 0;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    cursor: pointer;
    color: #fff;
    position: relative;
    flex-shrink: 0;
}

    .icon-btn:hover {
        background: rgba(255,255,255,.12);
    }

    .icon-btn svg {
        width: 16px;
        height: 16px;
    }

    .icon-btn .notif-dot {
        position: absolute;
        top: 10px;
        right: 10px;
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: #ff8c00;
        border: 1.5px solid #1c4a96;
    }

.badge-pill {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 2px;
    border: 1px solid rgba(255,255,255,.3);
    color: rgba(255,255,255,.9);
    background: rgba(255,255,255,.1);
    white-space: nowrap;
    margin: 0 4px;
}

.user-chip {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 0 14px;
    height: 48px;
    border-radius: 0;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #fff;
}

    .user-chip:hover {
        background: rgba(255,255,255,.12);
    }

.user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    display: grid;
    place-items: center;
    font-size: 11px;
    font-weight: 700;
    color: #1c4a96;
    flex-shrink: 0;
}

.user-name {
    font-size: 12px;
    font-weight: 400;
    color: #fff;
    white-space: nowrap;
}

/* Session selectors in topbar */
.session-select-simple {
    border: 1px solid var(--border);
    border-radius: var(--radius-xs);
    color: var(--text-faint);
    font-size: var(--text-2xs);
    font-family: inherit;
    padding: 2px 24px 2px 6px; /* right padding for custom arrow */
    min-width: 110px;
    cursor: pointer;
    /* Use appearance:none + custom SVG arrow so the browser never
       paints its own native widget — prevents the OS-light background
       showing inside the dark topbar                                  */
    appearance: none;
    -webkit-appearance: none;
    background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%237f90a8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 6px center / 10px;
}

[data-theme='dark'] .session-select-simple {
    background-color: rgba(255,255,255,.06); /* subtle glass tint on dark topbar */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%237f90a8' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 6px center;
    background-size: 10px;
    border-color: rgba(255,255,255,.12);
    color: var(--text-soft);
}

.session-select-simple:focus {
    outline: none;
    border-color: var(--accent-soft);
    box-shadow: 0 0 0 1px var(--accent-soft);
}

.session-select-simple option {
    background: var(--surface);
    color: var(--text);
}

[data-theme='dark'] .session-select-simple option {
    background: #111827;
    color: var(--text);
}

/* Admin dropdown */
.admin-menu {
    position: relative;
    z-index: 10000;
}

.admin-menu-panel {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    min-width: 190px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    padding: 6px;
    display: none;
    z-index: 9999;
}

.admin-menu.is-open .admin-menu-panel {
    display: block;
}

.admin-menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 8px;
    color: var(--text-soft);
    font-size: 13px;
}

    .admin-menu-item:hover {
        background: rgba(74,163,255,.08);
        color: var(--text);
    }

.admin-menu-divider {
    height: 1px;
    background: var(--divider);
    margin: 6px 0;
}

/* Topbar overflow (responsive) */
.topbar-overflow-trigger {
    display: none;
}

    .topbar-overflow-trigger.is-visible {
        display: flex;
    }

    .topbar-overflow-trigger .overflow-dot {
        position: absolute;
        top: 10px;
        right: 10px;
        width: 7px;
        height: 7px;
        border-radius: 999px;
        background: #ff8c00;
        border: 1.5px solid #1c4a96;
        display: none;
    }

    .topbar-overflow-trigger.has-items .overflow-dot {
        display: block;
    }

.top-right [data-overflow].is-hidden {
    display: none !important;
}

.topbar-overflow {
    position: relative;
    flex-shrink: 0;
}

.topbar-overflow-panel {
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    min-width: 210px;
    background: var(--panel);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    padding: 6px;
    display: none;
    z-index: 10050;
}

.topbar-overflow.is-open .topbar-overflow-panel {
    display: block;
}

.topbar-overflow-item {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 8px 10px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: var(--text-soft);
    font-size: var(--text-xs);
    cursor: pointer;
    text-align: left;
    text-decoration: none;
}

    .topbar-overflow-item:hover {
        background: rgba(0,0,0,.04);
        color: var(--text);
    }

    .topbar-overflow-item svg {
        width: 14px;
        height: 14px;
        flex-shrink: 0;
    }

.topbar-overflow-divider {
    height: 1px;
    background: var(--divider);
    margin: 6px 0;
}

.overflow-section-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-faint);
    padding: 6px 10px 2px;
}

/* ── Panels ─────────────────────────────────────────── */
.panel {
    background: var(--panel);
    border-radius: 12px;
    border: 1px solid var(--border);
    box-shadow: 0 1px 1px rgba(0,0,0,.03);
    padding: 8px 9px;
}

/* ── Alert / message panels ─────────────────────────── */
.panel-success {
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: var(--radius-sm);
    color: #166534;
    padding: 10px 14px;
    font-size: var(--text-sm);
    margin-bottom: 14px;
}

.panel-danger {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: var(--radius-sm);
    color: #991b1b;
    padding: 10px 14px;
    font-size: var(--text-sm);
    margin-bottom: 14px;
}

.panel-danger:empty,
.panel-info:empty,
.panel-warning:empty,
.panel-success:empty {
    display: none !important;
}

.panel-info {
    background: var(--accent-soft);
    border: 1px solid rgba(28,74,150,.25);
    border-radius: var(--radius-sm);
    color: var(--accent-strong);
    padding: 10px 14px;
    font-size: var(--text-sm);
    margin-bottom: 14px;
}

.panel-warning {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-radius: var(--radius-sm);
    color: #92400e;
    padding: 10px 14px;
    font-size: var(--text-sm);
    margin-bottom: 14px;
}

[data-theme='dark'] .panel-success {
    background: rgba(22,163,74,.12);
    border-color: rgba(22,163,74,.3);
    color: #4ade80;
}

[data-theme='dark'] .panel-danger {
    background: rgba(239,68,68,.12);
    border-color: rgba(239,68,68,.3);
    color: #f87171;
}

[data-theme='dark'] .panel-info {
    background: rgba(74,163,255,.1);
    border-color: rgba(74,163,255,.2);
    color: var(--accent);
}

[data-theme='dark'] .panel-warning {
    background: rgba(245,158,11,.12);
    border-color: rgba(245,158,11,.3);
    color: #fbbf24;
}

[data-theme='dark'] .panel {
    background: var(--surface);
    border-color: var(--border);
    color: var(--text);
    box-shadow: var(--shadow-md);
}

.panel-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    margin-bottom: 4px;
}

    .panel-title h2 {
        margin: 0;
        font-family: var(--font-heading);
        font-size: var(--text-sm);
        font-weight: 600;
    }

    .panel-title span {
        font-size: var(--text-2xs);
        color: var(--text-faint);
    }

/* ── Metrics ────────────────────────────────────────── */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
    gap: 6px;
    margin-top: 4px;
}

.metric {
    padding: 5px 6px;
    border-radius: var(--radius-sm);
    background: #fff;
    border: 1px solid var(--divider);
}

[data-theme='dark'] .metric {
    background: var(--surface);
    border-color: var(--border);
    color: var(--text);
    box-shadow: var(--shadow-md);
}

.metric-label {
    font-size: var(--text-2xs);
    color: var(--text-faint);
    text-transform: uppercase;
    letter-spacing: .09em;
}

[data-theme='dark'] .metric-label {
    color: var(--text-faint);
}

.metric-value {
    margin-top: 1px;
    font-size: var(--text-md);
    font-weight: 600;
}

.metric-sub {
    margin-top: 1px;
    font-size: var(--text-2xs);
    color: var(--text-soft);
}

[data-theme='dark'] .metric-sub {
    color: var(--text-soft);
}

/* ── Tables ─────────────────────────────────────────── */
.table-wrap {
    margin-top: 6px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--divider);
    overflow: hidden;
    background: var(--surface);
}

[data-theme='dark'] .table-wrap {
    background: var(--surface);
    border-color: var(--border);
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: var(--text-xs);
}

thead {
    background: var(--surface-alt);
}

[data-theme='dark'] table thead {
    background: var(--surface-alt);
}

th, td {
    padding: 4px 6px;
    border-bottom: 1px solid var(--divider);
    text-align: left;
    white-space: nowrap;
}

th {
    font-weight: 600;
    color: var(--text-soft);
    font-size: var(--text-2xs);
    text-transform: uppercase;
    letter-spacing: .08em;
}

[data-theme='dark'] th, [data-theme='dark'] td {
    border-color: var(--divider);
    color: var(--text);
}

tbody tr:nth-child(even) {
    background: rgba(0,0,0,.01);
}

tbody tr:hover {
    background: rgba(31,75,136,.06);
}

[data-theme='dark'] tbody tr:nth-child(even) td {
    background: #0f1724;
}

/* ── Status pills ───────────────────────────────────── */
.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 1px 6px;
    border-radius: 999px;
    font-size: var(--text-2xs);
    border: 1px solid var(--divider);
    color: var(--text-soft);
}

[data-theme='dark'] .status-pill {
    background: #0b1220;
    color: var(--text-soft);
    border-color: var(--border);
}

.status-pill.dot::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: var(--accent);
}

.status-pill.warn::before {
    background: var(--danger);
}

/* ── Mini list ──────────────────────────────────────── */
.mini-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
}

.mini-list {
    margin-top: 4px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    font-size: var(--text-xs);
}

.mini-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 3px 0;
    border-bottom: 1px dashed var(--divider);
}

    .mini-row:last-child {
        border-bottom: none;
    }

[data-theme='dark'] .mini-row {
    color: var(--text-soft);
}

/* ── Filter row / pills ─────────────────────────────── */
.filter-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: var(--text-xs);
    color: var(--text-soft);
    margin-top: 4px;
}

[data-theme='dark'] .filter-row {
    color: var(--text-soft);
}

.filter-pill {
    padding: 2px 6px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
}

[data-theme='dark'] .filter-pill {
    background: var(--surface);
    border-color: var(--border);
}

/* ── Tag bar ────────────────────────────────────────── */
.tag-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
}

.tag {
    padding: 1px 5px;
    border-radius: 999px;
    background: var(--accent-soft);
    font-size: var(--text-2xs);
    color: var(--accent-strong);
}

/* ── Shared page header (used on every page) ───────── */
/* .dash         = page wrapper                          */
/* .dash-header  = title row + actions                  */
/* .dash-title / .dash-sub / .dash-live / .live-dot     */
/* .dash-header-actions = right-side button group       */
.dash {
    padding: 16px 18px 24px;
    max-width: 1400px;
}

.dash-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    gap: 12px;
    flex-wrap: wrap;
}

.dash-title {
    margin: 0;
    font-family: var(--font-heading);
    font-size: 20px;
    font-weight: 700;
    color: var(--text);
}

.dash-sub {
    margin: 2px 0 0;
    font-size: var(--text-xs);
    color: var(--text-faint);
}

.dash-live {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #10b981;
    font-weight: 600;
}

.live-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #10b981;
    animation: pulse-dot 1.6s infinite;
}

@keyframes pulse-dot {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: .5;
        transform: scale(.7);
    }
}

.dash-header-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

/* Page icon (beside title, used on inner pages) */
.dash-page-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    background: var(--accent-soft);
    display: grid;
    place-items: center;
    color: var(--accent);
    flex-shrink: 0;
}

    .dash-page-icon svg {
        width: 18px;
        height: 18px;
    }

/* Title + subtitle stacked block */
.dash-title-block {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ── Dashboard hero / stats ─────────────────────────── */
.dashboard-hero {
    margin-bottom: 20px;
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px,1fr));
    gap: 16px;
}

.stat-card {
    display: flex;
    gap: 16px;
    padding: 20px;
    background: var(--panel);
    border-radius: 12px;
    border: 1px solid var(--border);
    transition: all .2s;
    cursor: pointer;
}

    .stat-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 24px rgba(28,74,150,.12);
    }

[data-theme='dark'] .stat-card {
    background: var(--surface);
    border-color: var(--border);
    box-shadow: var(--shadow-md);
}

.stat-icon {
    font-size: 32px;
}

.stat-info {
    flex: 1;
}

.stat-label {
    font-size: var(--text-xs);
    color: var(--text-faint);
    margin-bottom: 4px;
}

.stat-value {
    font-size: var(--text-lg);
    font-weight: 700;
    margin-bottom: 4px;
}

.stat-change {
    font-size: var(--text-2xs);
    opacity: .8;
}

    .stat-change.positive {
        color: #10b981;
    }

    .stat-change.neutral {
        color: var(--accent);
    }

/* ── Dashboard grid ─────────────────────────────────── */
.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.dashboard-side {
    display: grid;
    gap: 16px;
}

/* ── Quick actions ──────────────────────────────────── */
.quick-actions .action-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px,1fr));
    gap: 12px;
    margin-top: 12px;
}

.action-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: all .2s;
    font-size: var(--text-sm);
    text-align: center;
}

    .action-btn:hover {
        background: var(--surface-alt);
        border-color: var(--accent);
        transform: translateY(-1px);
        box-shadow: 0 10px 24px rgba(28,74,150,.12);
    }

[data-theme='dark'] .action-btn {
    background: var(--surface);
    border-color: var(--border);
    color: var(--text-soft);
}

    [data-theme='dark'] .action-btn:hover {
        background: rgba(74,163,255,.08);
    }

.action-icon {
    font-size: 24px;
}

/* ── Attendance list ────────────────────────────────── */
.attendance-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.attendance-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 12px;
    cursor: pointer;
    transition: all .15s;
    font-size: var(--text-sm);
    background: #fff;
}

    .attendance-item:hover {
        box-shadow: 0 10px 24px rgba(28,74,150,.12);
    }

    .attendance-item.high {
        background: rgba(34,197,94,.08);
    }

    .attendance-item.medium {
        background: rgba(251,191,36,.1);
    }

    .attendance-item.low {
        background: rgba(239,68,68,.08);
    }

[data-theme='dark'] .attendance-item {
    background: var(--surface);
    color: var(--text-soft);
    border-color: var(--border);
}

    [data-theme='dark'] .attendance-item:hover {
        background: rgba(74,163,255,.08);
    }

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

    .status-dot.green {
        background: #10b981;
    }

    .status-dot.yellow {
        background: #f59e0b;
    }

    .status-dot.red {
        background: #ef4444;
    }

/* ── Activity list ──────────────────────────────────── */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.activity-item {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 12px;
    border-radius: 12px;
    background: var(--surface);
    cursor: pointer;
    transition: all .15s;
}

    .activity-item:hover {
        background: var(--surface-alt);
        box-shadow: 0 10px 24px rgba(28,74,150,.12);
    }

[data-theme='dark'] .activity-item {
    background: var(--surface);
    box-shadow: var(--shadow-md);
}

    [data-theme='dark'] .activity-item:hover {
        background: rgba(74,163,255,.08);
    }

.activity-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.activity-time {
    font-size: var(--text-2xs);
    color: var(--text-faint);
    white-space: nowrap;
    margin-left: auto;
}

[data-theme='dark'] .activity-time {
    color: var(--text-faint);
}

/* ── Grid layouts ───────────────────────────────────── */
.grid-main {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 8px;
    align-items: flex-start;
}

/* ── AI prompt box ──────────────────────────────────── */
.ai-prompt-box {
    margin-bottom: 16px;
    background: linear-gradient(135deg, rgba(28,74,150,.10), rgba(28,74,150,.03));
    border: 2px solid rgba(28,74,150,.28);
    border-radius: var(--radius-lg);
    padding: 16px 20px;
    transition: all .2s;
}

    .ai-prompt-box:hover {
        box-shadow: var(--shadow-md);
    }

.ai-title h2 {
    font-size: var(--text-lg);
    margin-bottom: 4px;
}

.ai-input-row {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.ai-search {
    flex: 1;
    min-width: 280px;
    position: relative;
}

.ai-mic {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    color: var(--accent);
    cursor: pointer;
    opacity: .7;
}

    .ai-mic:hover {
        opacity: 1;
    }

.ai-examples {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.ai-example {
    padding: 4px 10px;
    border-radius: var(--radius-xs);
    background: var(--surface);
    color: var(--text-soft);
    font-size: var(--text-2xs);
    cursor: pointer;
    border: 1px solid var(--border);
    transition: all .15s;
    white-space: nowrap;
}

    .ai-example:hover {
        background: var(--accent-soft);
        color: var(--accent-strong);
        border-color: var(--accent);
    }

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 900px) {
    .app-shell:not(.force-open) {
        grid-template-columns: 0px minmax(0,1fr);
    }

        .app-shell:not(.force-open) .sidebar {
            width: 0;
            padding: 0;
            overflow: hidden;
            border-right: none;
        }

    .app-shell.force-open .sidebar {
        position: fixed;
        top: 48px;
        left: 0;
        height: calc(100vh - 48px);
        width: 240px;
        z-index: 10025;
        box-shadow: 4px 0 24px rgba(0,0,0,.18);
    }

    .app-shell.force-open::before {
        content: '';
        position: fixed;
        top: 48px;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0,0,0,.35);
        z-index: 10024;
    }

    .grid-main {
        grid-template-columns: 1fr;
    }

    .top-middle {
        display: none;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-side {
        display: none;
    }
}

@media (max-width: 640px) {
    .topbar {
        padding-inline: 8px;
    }

    .content-scroll {
        padding-inline: 8px;
    }

    .metrics-grid {
        grid-template-columns: repeat(2, minmax(0,1fr));
    }
}

/* ── Print ─────────────────────────────────────────────
   .content-scroll is a fixed-height, overflow:auto box (it's
   what makes the sidebar/topbar stay put while the page body
   scrolls) so by default the print engine only rasterizes
   whatever is currently visible on screen and cuts off
   everything below the fold. Reset the shell to unconstrained
   block layout for print so the full page content paginates
   normally.

   .sidebar/.topbar are hidden here (not left to individual
   pages) because .app-shell drops from grid to block layout
   above: with the grid gone, .sidebar (height: calc(100vh -
   48px) !important) and .topbar stop being grid siblings of
   .main and instead stack in normal block flow BEFORE it,
   each still claiming their full on-screen height. That
   reserves almost an entire page of blank space (just the
   collapsed sidebar's nav icons) ahead of the real content,
   pushing it to page 2 — the "blank first page when printing"
   bug. Hiding them here fixes it globally instead of relying
   on every page remembering to repeat this rule. */
@media print {
    .app-shell {
        display: block !important;
        min-height: 0 !important;
    }

    .sidebar,
    .topbar {
        display: none !important;
    }

    .main {
        display: block !important;
    }

    .content-scroll {
        overflow: visible !important;
        height: auto !important;
        max-height: none !important;
        padding: 0 !important;
    }
}

/* ══════════════════════════════════════════════════════════════════
   Shared report/admin component libraries — centralized here so any
   admin page can opt into either naming convention consistently.

   .va-* — originally authored inline in view-stu-atten.aspx.
   .rpt-* — originally authored inline in reports.aspx.

   Moved out to fix rep_studentsListClass.aspx / rep_StudentRank.aspx,
   which reference both conventions but never had either one's rules
   available to them (each convention lived only in its own page's
   page-scoped <style> block). Rules below are otherwise unchanged
   from their source pages; view-stu-atten.aspx and reports.aspx had
   their own copies removed to avoid duplication.
   ══════════════════════════════════════════════════════════════════ */

/* ── va-* : page header (was authored but commented-out/unused dead
   markup in view-stu-atten.aspx itself — it currently renders its
   header via the separate .dash-header/.dash-title-block classes
   instead — but rep_studentsListClass.aspx and rep_StudentRank.aspx
   DO use va-page-header/va-page-title/va-page-subtitle/va-print-btn
   live, so these rules are activated here for their benefit) ── */
.va-page-header { display:flex; align-items:center; justify-content:space-between; padding:14px 0 10px; gap:12px; }
.va-page-header-left { display:flex; align-items:center; gap:10px; }
.va-page-icon { width:36px; height:36px; border-radius:var(--radius-md); background:var(--accent-soft); border:1px solid rgba(31,75,136,.18); display:grid; place-items:center; flex-shrink:0; color:var(--accent); }
.va-page-icon svg { width:18px; height:18px; }
.va-page-title { margin:0; font-family:var(--font-heading); font-size:var(--text-lg); font-weight:700; color:var(--text); line-height:1.2; }
.va-page-subtitle { margin:2px 0 0; font-size:var(--text-xs); color:var(--text-soft); }
.va-print-btn { display:flex; align-items:center; gap:6px; padding:6px 12px; border-radius:var(--radius-sm); border:1px solid var(--border); background:var(--surface); color:var(--text-soft); font-size:var(--text-xs); cursor:pointer; font-family:var(--font-body); transition:background .14s,color .14s; text-decoration:none; }
.va-print-btn:hover { background:var(--surface-alt); color:var(--text); }
.va-print-btn svg { width:14px; height:14px; }

/* ── va-* : filter card ── */
.va-filter-card { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); padding:10px 14px; margin-bottom:8px; }
.va-filter-row { display:flex; align-items:flex-end; gap:0; flex-wrap:wrap; }
.va-filter-group { display:flex; flex-direction:column; gap:4px; padding:0 14px 0 0; }
.va-filter-label { font-size:var(--text-2xs); font-weight:600; letter-spacing:.1em; text-transform:uppercase; color:var(--text-faint); }
.va-select-wrap { position:relative; display:inline-flex; align-items:center; }
.va-select { appearance:none; -webkit-appearance:none; background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-sm); color:var(--text); font-size:var(--text-sm); font-family:var(--font-body); padding:5px 28px 5px 9px; cursor:pointer; outline:none; transition:border-color .14s,box-shadow .14s; min-width:140px; height:34px; }
.va-select:focus { border-color:var(--accent); box-shadow:0 0 0 2px var(--accent-soft); }
.va-select:disabled { opacity:.48; cursor:not-allowed; }
[data-theme='dark'] .va-select { background:#0b1220; color:var(--text); border-color:var(--border); }
.va-select-arrow { position:absolute; right:7px; width:13px; height:13px; color:var(--text-faint); pointer-events:none; }
.va-filter-divider { width:1px; height:32px; background:var(--divider); margin:0 14px 0 0; align-self:flex-end; margin-bottom:6px; }
.va-get-btn { display:flex; align-items:center; gap:7px; padding:6px 16px; border-radius:var(--radius-sm); border:none; background:var(--accent); color:#fff; font-size:var(--text-sm); font-family:var(--font-body); font-weight:600; cursor:pointer; transition:background .14s,transform .1s,box-shadow .14s; box-shadow:0 2px 6px rgba(31,75,136,.28); white-space:nowrap; height:34px; }
.va-get-btn:hover { background:var(--accent-strong); box-shadow:0 4px 12px rgba(31,75,136,.36); }
.va-get-btn:active { transform:scale(.97); }
.va-get-btn svg { width:13px; height:13px; }
.va-active-filters { display:flex; align-items:center; gap:6px; margin-top:10px; padding-top:8px; border-top:1px dashed var(--divider); flex-wrap:wrap; }
.va-af-label { font-size:var(--text-2xs); color:var(--text-faint); text-transform:uppercase; letter-spacing:.08em; }
.va-chip { display:inline-flex; align-items:center; gap:4px; padding:2px 8px; border-radius:999px; background:var(--accent-soft); color:var(--accent-strong); font-size:var(--text-2xs); font-weight:600; border:1px solid rgba(31,75,136,.15); }
.va-af-clear { display:inline-flex; align-items:center; gap:4px; padding:2px 8px; border-radius:999px; border:1px solid var(--border); background:transparent; color:var(--text-soft); font-size:var(--text-2xs); cursor:pointer; font-family:var(--font-body); }
.va-af-clear:hover { background:var(--surface-alt); }

/* ── va-* : message ── */
.va-msg { padding:10px 14px; border-radius:var(--radius-sm); background:var(--accent-soft); color:var(--accent-strong); font-size:var(--text-sm); border:1px solid var(--accent); margin-bottom:12px; }

/* ── va-* : metrics ── */
.va-metrics-row { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:6px; margin-bottom:8px; }
.va-metric-card { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); padding:10px 12px; display:flex; align-items:center; gap:10px; }
.va-metric-icon { width:32px; height:32px; border-radius:var(--radius-sm); display:grid; place-items:center; flex-shrink:0; }
.va-metric-icon svg { width:16px; height:16px; }
.va-metric-value { font-family:var(--font-heading); font-size:20px; font-weight:700; line-height:1; }
.va-metric-label { font-size:var(--text-2xs); color:var(--text-soft); margin-top:2px; }
.va-metric-total   .va-metric-icon { background:var(--accent-soft); color:var(--accent); }
.va-metric-total   .va-metric-value { color:var(--accent); }
.va-metric-present .va-metric-icon { background:#e6f5ec; color:#1b7a45; }
.va-metric-present .va-metric-value { color:#1b7a45; }
.va-metric-absent  .va-metric-icon { background:#fdecea; color:var(--danger); }
.va-metric-absent  .va-metric-value { color:var(--danger); }
.va-metric-late    .va-metric-icon { background:#fff4e3; color:#b76e00; }
.va-metric-late    .va-metric-value { color:#b76e00; }
.va-metric-rate    .va-metric-icon { background:#f0f0f5; color:#555; }
.va-metric-rate    .va-metric-value { color:var(--text); }
[data-theme='dark'] .va-metric-present .va-metric-icon { background:rgba(27,122,69,.18); color:#4caf7d; }
[data-theme='dark'] .va-metric-present .va-metric-value { color:#4caf7d; }
[data-theme='dark'] .va-metric-absent  .va-metric-icon { background:rgba(179,38,30,.2); color:#ffb4ab; }
[data-theme='dark'] .va-metric-absent  .va-metric-value { color:#ffb4ab; }
[data-theme='dark'] .va-metric-late    .va-metric-icon { background:rgba(183,110,0,.18); color:#ffb74d; }
[data-theme='dark'] .va-metric-late    .va-metric-value { color:#ffb74d; }

/* ── va-* : charts panel ── */
.va-charts-row  { display:grid; grid-template-columns:220px 1fr 200px; gap:8px; align-items:flex-start; }
.va-charts-row2 { display:grid; grid-template-columns:1fr 1fr 200px; gap:8px; align-items:flex-start; }
.va-chart-card { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); padding:12px 14px; display:flex; flex-direction:column; gap:10px; min-width:0; }
.va-chart-header { display:flex; align-items:center; justify-content:space-between; gap:6px; flex-shrink:0; }
.va-chart-title { font-family:var(--font-heading); font-size:var(--text-sm); font-weight:600; color:var(--text); }
.va-chart-sub { font-size:var(--text-2xs); color:var(--text-faint); }
.va-donut-outer { display:flex; flex-direction:column; align-items:center; gap:10px; }
.va-donut-canvas-wrap { position:relative; width:140px; height:140px; flex-shrink:0; }
.va-donut-canvas-wrap canvas { width:140px !important; height:140px !important; }
.va-donut-center { position:absolute; inset:0; display:flex; flex-direction:column; align-items:center; justify-content:center; pointer-events:none; }
.va-donut-pct { font-family:var(--font-heading); font-size:22px; font-weight:700; color:var(--text); line-height:1; }
.va-donut-sub { font-size:var(--text-2xs); color:var(--text-faint); margin-top:2px; }
.va-donut-legend { width:100%; display:flex; flex-direction:column; gap:5px; }
.va-dl-row { display:flex; align-items:center; gap:7px; font-size:var(--text-2xs); color:var(--text-soft); }
.va-dl-dot { width:9px; height:9px; border-radius:50%; flex-shrink:0; }
.va-dl-label { flex:1; }
.va-dl-val { font-weight:600; color:var(--text); }
.va-bar-wrap, .va-trend-wrap { flex:1; min-height:140px; position:relative; }
.va-bar-wrap canvas, .va-trend-wrap canvas { width:100% !important; }
.va-stat-list { display:flex; flex-direction:column; gap:8px; }
.va-stat-item { display:flex; align-items:flex-start; gap:8px; padding:6px 8px; border-radius:var(--radius-sm); background:var(--surface); border:1px solid var(--divider); }
.va-stat-item svg { width:15px; height:15px; flex-shrink:0; margin-top:1px; color:var(--accent); }
.va-stat-label { font-size:var(--text-2xs); color:var(--text-faint); }
.va-stat-value { font-size:var(--text-sm); font-weight:600; color:var(--text); margin-top:1px; }
.va-progress-list { display:flex; flex-direction:column; gap:6px; max-height:260px; overflow-y:auto; }
.va-progress-item { display:flex; flex-direction:column; gap:3px; }
.va-progress-meta { display:flex; justify-content:space-between; align-items:center; }
.va-progress-name { font-size:var(--text-xs); color:var(--text); }
.va-progress-pct  { font-size:var(--text-xs); font-weight:600; }
.va-progress-track { height:6px; border-radius:999px; background:var(--surface-alt); overflow:hidden; }
.va-progress-fill { height:100%; border-radius:999px; width:0; transition:width .7s cubic-bezier(.4,0,.2,1); }
.va-absentee-list { display:flex; flex-direction:column; gap:5px; max-height:260px; overflow-y:auto; }
.va-ab-item { display:flex; align-items:center; gap:8px; padding:5px 7px; border-radius:var(--radius-sm); background:var(--surface); border:1px solid var(--divider); }
.va-ab-avatar { width:26px; height:26px; border-radius:50%; display:grid; place-items:center; font-size:var(--text-2xs); font-weight:700; color:#fff; flex-shrink:0; }
.va-ab-detail { flex:1; min-width:0; display:flex; flex-direction:column; gap:3px; }
.va-ab-name { font-size:var(--text-xs); font-weight:500; color:var(--text); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.va-ab-pct  { font-size:var(--text-xs); font-weight:700; color:var(--danger); flex-shrink:0; }
.va-ab-bar-track { height:4px; border-radius:999px; background:var(--surface-alt); overflow:hidden; }
.va-ab-bar-fill  { height:100%; border-radius:999px; }
.va-no-data { color:var(--text-soft); font-size:var(--text-xs); margin:8px 0; text-align:center; }

/* ── va-* : results card ── */
.va-results-card { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); overflow:hidden; margin-bottom:12px; }
.va-results-toolbar { display:flex; align-items:center; justify-content:space-between; padding:8px 12px; border-bottom:1px solid var(--divider); gap:10px; flex-wrap:wrap; }
.va-results-toolbar-left { display:flex; align-items:center; gap:8px; }
.va-results-toolbar-right { display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.va-results-title { font-family:var(--font-heading); font-size:var(--text-sm); font-weight:600; }
.va-results-count { font-size:var(--text-xs); color:var(--text-faint); background:var(--surface-alt); padding:1px 7px; border-radius:999px; }
.va-legend { display:flex; align-items:center; gap:8px; font-size:var(--text-2xs); color:var(--text-soft); }
.va-legend-dot { width:8px; height:8px; border-radius:50%; display:inline-block; }
.va-legend-dot.present { background:#22a55b; }
.va-legend-dot.absent  { background:var(--danger); }
.va-table-search { position:relative; display:flex; align-items:center; }
.va-table-search svg { position:absolute; left:7px; width:13px; height:13px; color:var(--text-faint); pointer-events:none; }
.va-table-search input { border:1px solid var(--border); border-radius:var(--radius-sm); background:var(--surface); color:var(--text); font-size:var(--text-xs); font-family:var(--font-body); padding:4px 10px 4px 26px; outline:none; width:170px; transition:border-color .14s; }
.va-table-search input:focus { border-color:var(--accent); }
.va-export-btn { display:flex; align-items:center; gap:5px; padding:4px 10px; border-radius:var(--radius-sm); border:1px solid var(--border); background:var(--surface); color:var(--text-soft); font-size:var(--text-xs); font-family:var(--font-body); cursor:pointer; transition:background .14s; }
.va-export-btn:hover { background:var(--surface-alt); color:var(--text); }
.va-export-btn svg { width:13px; height:13px; }
.va-table-wrap { overflow-x:auto; }
.va-table { width:100%; border-collapse:collapse; font-size:var(--text-xs); }
.va-table thead { background:var(--surface-alt); position:sticky; top:0; }
.va-table th { padding:7px 10px; text-align:left; font-size:var(--text-2xs); font-weight:600; text-transform:uppercase; letter-spacing:.09em; color:var(--text-soft); border-bottom:1px solid var(--border); white-space:nowrap; }
.va-table td { padding:6px 10px; border-bottom:1px solid var(--divider); color:var(--text); white-space:nowrap; }
.va-th-num { width:36px; text-align:center; }
.va-table td:first-child { text-align:center; color:var(--text-faint); }
.va-table tbody tr:hover { background:rgba(31,75,136,.05); }
.va-table tbody tr:last-child td { border-bottom:none; }
.va-tbl-pct-wrap { display:flex; align-items:center; gap:6px; min-width:90px; }
.va-tbl-pct-track { flex:1; height:5px; border-radius:999px; background:var(--surface-alt); overflow:hidden; }
.va-tbl-pct-fill  { height:100%; border-radius:999px; }
.va-pagination { display:flex; align-items:center; justify-content:space-between; padding:8px 12px; border-top:1px solid var(--divider); font-size:var(--text-xs); color:var(--text-soft); }
.va-page-btns { display:flex; align-items:center; gap:6px; }
.va-pager-btn { width:26px; height:26px; border-radius:var(--radius-xs); border:1px solid var(--border); background:var(--surface); display:grid; place-items:center; cursor:pointer; color:var(--text-soft); transition:background .12s; }
.va-pager-btn:hover:not([disabled]) { background:var(--accent-soft); color:var(--accent); }
.va-pager-btn[disabled] { opacity:.4; cursor:default; }
.va-pager-btn svg { width:13px; height:13px; }
.va-pager-current { font-size:var(--text-xs); font-weight:600; color:var(--accent); min-width:18px; text-align:center; }

/* ── va-* : student info bar ── */
.va-student-bar { display:flex; align-items:center; gap:12px; background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); padding:10px 14px; margin-bottom:8px; flex-wrap:wrap; }
.va-student-avatar { width:40px; height:40px; border-radius:50%; background:var(--accent); color:#fff; display:grid; place-items:center; font-family:var(--font-heading); font-size:var(--text-sm); font-weight:700; flex-shrink:0; }
.va-student-info { display:flex; flex-direction:column; gap:2px; flex:1; min-width:120px; }
.va-student-name { font-family:var(--font-heading); font-size:var(--text-md); font-weight:700; color:var(--text); }
.va-student-meta { font-size:var(--text-xs); color:var(--text-soft); }
.va-student-bar-stats { display:flex; align-items:center; margin-left:auto; flex-wrap:wrap; }
.va-sbs-item { display:flex; flex-direction:column; align-items:center; padding:4px 14px; gap:2px; }
.va-sbs-val { font-family:var(--font-heading); font-size:18px; font-weight:700; color:var(--text); line-height:1; }
.va-sbs-val.present { color:#22a55b; }
.va-sbs-val.absent  { color:var(--danger); }
.va-sbs-val.late    { color:#f59e0b; }
.va-sbs-lbl { font-size:var(--text-2xs); color:var(--text-faint); text-transform:uppercase; letter-spacing:.08em; }
.va-sbs-sep { width:1px; height:28px; background:var(--divider); align-self:center; }
.va-stu-charts { display:grid; grid-template-columns:220px 1fr 260px; gap:8px; margin-bottom:8px; animation:vaFadeUp .3s ease both; }
.va-stu-donut-wrap { display:flex; flex-direction:column; align-items:center; gap:10px; }
.va-stu-bar-wrap, .va-stu-trend-wrap { flex:1; min-height:170px; position:relative; }
.va-stu-bar-wrap canvas, .va-stu-trend-wrap canvas { width:100% !important; }
.va-streak-row { display:flex; align-items:center; padding-top:8px; border-top:1px solid var(--divider); margin-top:4px; }
.va-streak-item { display:flex; align-items:center; gap:8px; flex:1; padding:0 8px; }
.va-streak-item svg { width:18px; height:18px; flex-shrink:0; }
.va-streak-val { font-family:var(--font-heading); font-size:16px; font-weight:700; color:var(--text); line-height:1; }
.va-streak-lbl { font-size:var(--text-2xs); color:var(--text-faint); margin-top:1px; }
.va-streak-sep { width:1px; height:32px; background:var(--divider); flex-shrink:0; }

/* ── va-* : calendar ── (NOTE: .p-chip/.a-chip/.h-chip/.t-chip/.x-chip,
   td.cal-*, and .l-chip/.e-chip are page-specific color classes, NOT
   part of the va-* convention — they remain in view-stu-atten.aspx) */
.va-cal-card { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); overflow:hidden; margin-bottom:8px; }
.va-cal-header { display:flex; align-items:center; justify-content:space-between; padding:9px 14px; border-bottom:1px solid var(--divider); flex-wrap:wrap; gap:8px; }
.va-cal-title { font-family:var(--font-heading); font-size:var(--text-sm); font-weight:600; color:var(--text); }
.va-cal-legend { display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
.va-cal-leg-item { display:flex; align-items:center; gap:4px; font-size:var(--text-2xs); color:var(--text-soft); }
.va-cal-chip { display:inline-flex; align-items:center; justify-content:center; width:18px; height:18px; border-radius:3px; font-size:9px; font-weight:700; }
.va-cal-scroll { overflow-x:auto; }
.va-cal-table { width:100%; border-collapse:collapse; font-size:10px; min-width:1000px; }
.va-cal-table thead { background:var(--surface-alt); position:sticky; top:0; }
.va-cal-table th { padding:5px 2px; text-align:center; font-size:10px; font-weight:600; color:var(--text-soft); border:1px solid var(--divider); white-space:nowrap; }
.va-cal-month-th { text-align:left !important; padding-left:10px !important; min-width:72px; }
.va-cal-sum-th { background:var(--accent-soft); color:var(--accent-strong) !important; min-width:60px; }
.va-cal-table td { padding:4px 2px; text-align:center; border:1px solid var(--divider); font-size:10px; color:var(--text-soft); min-width:20px; }
.va-cal-table tbody tr:nth-child(odd)  { background:var(--surface); }
.va-cal-table tbody tr:nth-child(even) { background:var(--panel); }
.va-cal-table tbody tr:hover { background:rgba(31,75,136,.05); }
.va-cal-month-cell { text-align:left !important; padding-left:10px !important; font-weight:600; color:var(--text); white-space:nowrap; }
.va-cal-table tfoot td { background:#1f4b88; color:#fff; padding:7px 14px; font-size:10px; font-weight:600; border:none; }
.va-cal-summary-foot { display:flex; align-items:center; justify-content:flex-end; gap:12px; }
.va-cal-session-pct { display:inline-block; background:#f59e0b; color:#fff; font-family:var(--font-heading); font-size:13px; font-weight:700; padding:2px 14px; border-radius:4px; min-width:52px; text-align:center; }

/* ── va-* : class-wise GridView ── */
.va-class-table-card { background:var(--panel); border:1px solid var(--border); border-radius:var(--radius-md); box-shadow:var(--shadow-sm); overflow:hidden; margin-bottom:12px; }
.va-class-table-header { padding:10px 14px; border-bottom:1px solid var(--divider); font-family:var(--font-heading); font-size:var(--text-sm); font-weight:600; color:var(--text); }

/* ── va-* : empty state ── */
.va-empty-state { display:flex; flex-direction:column; align-items:center; justify-content:center; padding:48px 24px; text-align:center; gap:6px; }
.va-empty-illustration { margin-bottom:8px; opacity:.85; }
.va-empty-title { font-family:var(--font-heading); font-size:var(--text-md); font-weight:600; color:var(--text); margin:0; }
.va-empty-sub { font-size:var(--text-xs); color:var(--text-soft); margin:0; max-width:340px; }

/* ── va-* : responsive ── */
@media (max-width:1100px) {
    .va-charts-row  { grid-template-columns:1fr 1fr; }
    .va-charts-row2 { grid-template-columns:1fr 1fr; }
    .va-chart-card--stats     { grid-column:1/-1; }
    .va-chart-card--absentees { grid-column:1/-1; }
    .va-stu-charts { grid-template-columns:1fr 1fr; }
    .va-stu-trend-card { grid-column:1/-1; }
}
@media (max-width:900px) {
    .va-filter-row { flex-direction:column; align-items:stretch; gap:10px; }
    .va-filter-divider { display:none; }
    .va-metrics-row { grid-template-columns:repeat(3,minmax(0,1fr)); }
    .va-charts-row, .va-charts-row2 { grid-template-columns:1fr; }
    .va-stu-charts { grid-template-columns:1fr; }
}
@media (max-width:640px) {
    .va-metrics-row { grid-template-columns:repeat(2,minmax(0,1fr)); }
    .va-page-subtitle { display:none; }
}

/* ── rpt-* : report hub layout ── */
.rpt-shell { display:grid; grid-template-columns:220px minmax(0, 1fr); gap:0; min-height:calc(100vh - 48px); }
.rpt-nav { border-right:1px solid var(--border); background:var(--surface); padding:16px 0; position:sticky; top:48px; height:calc(100vh - 48px); overflow-y:auto; }
.rpt-nav-section { margin-bottom:4px; }
.rpt-nav-label { font-size:var(--text-2xs); letter-spacing:.12em; text-transform:uppercase; color:var(--text-faint); padding:8px 16px 4px; }
.rpt-nav-item { display:flex; align-items:center; gap:8px; padding:7px 16px; font-size:var(--text-sm); color:var(--text-soft); cursor:pointer; border:none; background:none; width:100%; text-align:left; border-radius:0; transition:background .12s, color .12s; }
.rpt-nav-item svg { width:14px; height:14px; flex-shrink:0; opacity:.7; }
.rpt-nav-item:hover { background:rgba(28, 74, 150, .06); color:var(--text); }
.rpt-nav-item.is-active { background:linear-gradient(90deg, rgba(28,74,150,.13), rgba(28,74,150,.04)); color:var(--accent-strong); font-weight:600; border-left:3px solid var(--accent); padding-left:13px; }
.rpt-nav-item.is-active svg { opacity:1; color:var(--accent); }
[data-theme='dark'] .rpt-nav-item.is-active { background:linear-gradient(90deg, rgba(74,163,255,.2), rgba(74,163,255,.07)); }

/* ── rpt-* : main area ── */
.rpt-main { padding:20px 24px; background:var(--bg); }

/* ── rpt-* : report panels ── */
.rpt-panel { display:none; }
.rpt-panel.is-active { display:block; }

/* ── rpt-* : page header ── */
.rpt-page-header { display:flex; align-items:center; justify-content:space-between; margin-bottom:18px; flex-wrap:wrap; gap:10px; }
.rpt-page-title { font-family:var(--font-heading); font-size:var(--text-lg); font-weight:700; color:var(--text); }
.rpt-page-sub { font-size:var(--text-xs); color:var(--text-faint); margin-top:2px; }

/* ── rpt-* : filter bar ── */
.rpt-filters { background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-md); padding:14px 16px; margin-bottom:16px; }
.rpt-filter-row { display:flex; flex-wrap:wrap; gap:10px; align-items:flex-end; }
.rpt-filter-group { display:flex; flex-direction:column; gap:4px; min-width:130px; }
.rpt-filter-label { font-size:var(--text-2xs); font-weight:600; color:var(--text-faint); letter-spacing:.04em; }

/* ── rpt-* : metric strip ── */
.rpt-metrics { display:grid; grid-template-columns:repeat(auto-fit, minmax(130px, 1fr)); gap:10px; margin-bottom:16px; }
.rpt-metric-card { background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-md); padding:12px 14px; }
.rpt-metric-label { font-size:var(--text-2xs); color:var(--text-faint); margin-bottom:4px; }
.rpt-metric-val { font-size:var(--text-lg); font-weight:700; color:var(--text); line-height:1.2; }
.rpt-metric-card.accent-green .rpt-metric-val { color:#16a34a; }
.rpt-metric-card.accent-red .rpt-metric-val { color:var(--danger); }
.rpt-metric-card.accent-blue .rpt-metric-val { color:var(--accent); }

/* ── rpt-* : data table ── */
.rpt-table-wrap { background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-md); overflow:hidden; }
.rpt-table-toolbar { display:flex; align-items:center; justify-content:space-between; padding:10px 14px; border-bottom:1px solid var(--border); flex-wrap:wrap; gap:8px; }
.rpt-row-count { font-size:var(--text-xs); color:var(--text-faint); }
.rpt-export-btns { display:flex; gap:6px; }
.rpt-table { width:100%; border-collapse:collapse; font-size:var(--text-sm); }
.rpt-table th { background:var(--surface-alt); padding:8px 12px; text-align:left; font-size:var(--text-xs); font-weight:600; color:var(--text-soft); border-bottom:1px solid var(--border); white-space:nowrap; }
.rpt-table td { padding:8px 12px; border-bottom:1px solid var(--divider); vertical-align:middle; }
.rpt-table tbody tr:last-child td { border-bottom:none; }
.rpt-table tbody tr:hover td { background:var(--surface-alt); }
.rpt-table-footer { background:var(--surface-alt); border-top:1px solid var(--border); font-weight:600; }
.rpt-table-footer td { padding:8px 12px; font-size:var(--text-sm); }

/* ── rpt-* : chart containers ── */
.rpt-chart-row { display:grid; grid-template-columns:1fr 1fr; gap:14px; margin-bottom:16px; }
.rpt-chart-card { background:var(--surface); border:1px solid var(--border); border-radius:var(--radius-md); padding:14px 16px; }
.rpt-chart-title { font-size:var(--text-xs); font-weight:600; color:var(--text-soft); margin-bottom:12px; }

/* ── rpt-* : welcome / placeholder ── */
.rpt-welcome { text-align:center; padding:60px 20px; color:var(--text-faint); }
.rpt-welcome svg { width:48px; height:48px; margin:0 auto 16px; opacity:.35; }
.rpt-welcome h2 { font-size:var(--text-md); color:var(--text-soft); margin-bottom:8px; }
.rpt-placeholder { text-align:center; padding:40px 20px; color:var(--text-faint); font-size:var(--text-sm); }

/* ── rpt-* : attendance calendar legend (NOTE: .cal-dot/.cal-p-dot/
   .cal-a-dot/.cal-l-dot/.cal-e-dot are page-specific color classes,
   NOT part of the rpt-* convention — they remain in reports.aspx) ── */
.rpt-cal-legend { display:flex; gap:12px; flex-wrap:wrap; margin-bottom:10px; }
.rpt-cal-legend span { font-size:var(--text-2xs); color:var(--text-soft); }

/* ── rpt-* : responsive ── */
@media (max-width: 860px) {
    .rpt-shell { grid-template-columns: 1fr; }
    .rpt-nav { position:static; height:auto; border-right:none; border-bottom:1px solid var(--border); display:flex; flex-wrap:wrap; padding:8px; gap:4px; }
    .rpt-nav-label { display:none; }
    .rpt-nav-item { border-radius:var(--radius-sm); padding:6px 10px; }
    .rpt-nav-item.is-active { border-left:none; border-bottom:2px solid var(--accent); padding-left:10px; background:var(--accent-soft); }
    .rpt-chart-row { grid-template-columns:1fr; }
}
