/* =========================================================
   data/ — 数据视图页样式（移动端优先 · yxxs 专用扩展）
   设计原则：
   - 手机竖屏为主，桌面/平板也兼容
   - 删除全部 hover 效果，保留触摸 active
   - 留白 / 字号 / 阴影 都为触控 / 阅读服务
   ========================================================= */

* { -webkit-tap-highlight-color: transparent; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overscroll-behavior-y: none;
    color: #0f172a;
    font-size: 14px;
    line-height: 1.5;
    background: #f5f7fa;
}

/* ---------- Design tokens ---------- */
:root {
    --teal-50:  #ecfdf5;
    --teal-100: #d1fae5;
    --teal-200: #a7f3d0;
    --teal-300: #6ee7b7;
    --teal-400: #34d399;
    --teal-500: #10b981;
    --teal-600: #059669;
    --teal-700: #047857;
    --teal-800: #065f46;
    --teal-900: #064e3b;

    --ink-50:  #f8fafc;
    --ink-100: #f1f5f9;
    --ink-200: #e2e8f0;
    --ink-300: #cbd5e1;
    --ink-400: #94a3b8;
    --ink-500: #64748b;
    --ink-600: #475569;
    --ink-700: #334155;
    --ink-800: #1e293b;
    --ink-900: #0f172a;

    --amber-500:  #f59e0b;
    --amber-600:  #d97706;
    --purple-500: #a855f7;
    --purple-600: #9333ea;

    --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.04);
    --shadow-sm: 0 2px 4px rgba(15, 23, 42, 0.05);
    --shadow-md: 0 4px 12px -2px rgba(15, 23, 42, 0.07);
    --shadow-lg: 0 12px 24px -6px rgba(15, 23, 42, 0.10);
    --shadow-xl: 0 24px 48px -12px rgba(15, 23, 42, 0.18);
}

/* =========================================================
   Topbar
   ========================================================= */
.data-topbar {
    position: relative;
    overflow: hidden;
    color: #fff;
    isolation: isolate;
    padding-bottom: 18px;
    border-bottom-left-radius: 24px;
    border-bottom-right-radius: 24px;
}
.data-topbar-bg {
    position: absolute; inset: 0;
    background: linear-gradient(160deg, #064e3b 0%, #047857 55%, #059669 100%);
    z-index: -2;
}
.data-topbar-bg::before {
    content: '';
    position: absolute;
    top: -80px; right: -60px;
    width: 280px; height: 280px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(110, 231, 183, 0.30) 0%, transparent 65%);
    filter: blur(10px);
}
.data-topbar-bg::after {
    content: '';
    position: absolute;
    bottom: -100px; left: -40px;
    width: 220px; height: 220px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(52, 211, 153, 0.25) 0%, transparent 60%);
    filter: blur(14px);
}
.data-topbar-head {
    padding: 16px 20px 12px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.data-topbar-icon {
    width: 36px; height: 36px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.16);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex; align-items: center; justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.20);
    flex-shrink: 0;
}
.data-topbar-icon svg { color: #fff; }
.data-topbar-title-wrap { flex: 1; min-width: 0; }
.data-topbar-eyebrow {
    font-size: 10px;
    color: rgba(167, 243, 208, 0.95);
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    line-height: 1;
    margin-bottom: 4px;
}
.data-topbar-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    line-height: 1.2;
    letter-spacing: -0.01em;
}
.data-topbar-count {
    display: flex;
    align-items: baseline;
    gap: 4px;
    color: #fff;
    flex-shrink: 0;
}
.data-topbar-count-num {
    font-size: 24px;
    font-weight: 800;
    font-family: 'JetBrains Mono', monospace;
    line-height: 1;
}
.data-topbar-count-label {
    font-size: 10px;
    color: rgba(167, 243, 208, 0.9);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* =========================================================
   Searchbar
   ========================================================= */
.data-search-wrap {
    margin: 0 20px;
}
.data-searchbar {
    display: flex; align-items: center; gap: 8px;
    background: rgba(255, 255, 255, 0.97);
    border-radius: 14px;
    padding: 12px 14px;
    box-shadow:
        0 4px 14px rgba(0, 0, 0, 0.10),
        0 1px 3px rgba(0, 0, 0, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 1);
    transition: box-shadow 0.2s ease;
}
.data-searchbar:focus-within {
    box-shadow:
        0 0 0 3px rgba(52, 211, 153, 0.25),
        0 8px 24px rgba(16, 185, 129, 0.15);
}
.data-searchbar svg { color: var(--teal-600); flex-shrink: 0; }
.data-search-input {
    flex: 1; min-width: 0;
    background: transparent; border: 0; outline: 0;
    color: var(--ink-900); font-size: 14px;
    padding: 0;
}
.data-search-input::placeholder { color: var(--ink-400); }
.data-search-clear {
    display: none;
    color: var(--ink-500);
    font-size: 20px;
    line-height: 1;
    padding: 0 4px;
    font-weight: 300;
}
.data-search-clear.visible { display: inline-block; }

/* =========================================================
   Stat Strip
   ========================================================= */
.data-stat-strip {
    margin: -10px 16px 0;
    display: flex;
    background: #fff;
    border-radius: 14px;
    box-shadow: var(--shadow-md);
    overflow: hidden;
    position: relative;
    z-index: 2;
}
.data-stat-card {
    flex: 1;
    padding: 10px 4px;
    text-align: center;
    cursor: pointer;
    transition: background 0.12s ease;
    position: relative;
}
.data-stat-card:active { background: var(--ink-50); }
.data-stat-card + .data-stat-card::before {
    content: '';
    position: absolute;
    left: 0; top: 25%; bottom: 25%;
    width: 1px;
    background: var(--ink-100);
}
.data-stat-label {
    font-size: 10px;
    color: var(--ink-500);
    margin-bottom: 6px;
    line-height: 1;
    letter-spacing: 0.02em;
}
.data-stat-value {
    font-size: 17px;
    font-weight: 700;
    line-height: 1;
    font-family: 'JetBrains Mono', monospace;
    color: var(--ink-900);
}
.data-stat-value.teal   { color: var(--teal-700); }
.data-stat-value.amber  { color: var(--amber-600); }
.data-stat-value.purple { color: var(--purple-600); }

/* =========================================================
   Filter Bar
   ========================================================= */
.data-filterbar-wrap {
    position: sticky;
    top: 0;
    z-index: 30;
    background: var(--ink-50);
}
.data-filterbar-shadow {
    position: relative;
}
.data-filterbar-shadow::before,
.data-filterbar-shadow::after {
    content: '';
    position: absolute;
    top: 0; bottom: 0;
    width: 20px;
    pointer-events: none;
    z-index: 2;
}
.data-filterbar-shadow::before {
    left: 0;
    background: linear-gradient(90deg, var(--ink-50), rgba(245, 247, 250, 0));
}
.data-filterbar-shadow::after {
    right: 0;
    background: linear-gradient(-90deg, var(--ink-50), rgba(245, 247, 250, 0));
}
.data-filterbar {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 12px 16px 10px;
    gap: 6px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x pan-y;
    scroll-snap-type: x proximity;
}
.data-filterbar::-webkit-scrollbar { display: none; }
.data-filter-tab {
    display: flex; align-items: center; gap: 5px;
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 500;
    color: var(--ink-500);
    background: #fff;
    border: 1px solid var(--ink-200);
    border-radius: 999px;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.15s ease;
    flex-shrink: 0;
    scroll-snap-align: start;
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
}
.data-filter-tab:active { transform: scale(0.96); }
.data-filter-tab.active {
    color: #fff;
    background: var(--teal-600);
    border-color: var(--teal-600);
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.30);
}
.data-filter-tab.active svg { color: #fff; }

/* =========================================================
   Section
   ========================================================= */
.data-section {
    display: none;
    padding: 16px;
    animation: data-section-in 0.22s ease forwards;
}
.data-section.active { display: block; }
@keyframes data-section-in {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* =========================================================
   KPI Cards
   ========================================================= */
.data-kpi-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}
.data-kpi {
    background: #fff;
    border-radius: 14px;
    padding: 14px;
    box-shadow: var(--shadow-xs);
    border: 1px solid var(--ink-100);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.12s ease;
}
.data-kpi:active { transform: scale(0.98); }
.data-kpi-head {
    display: flex; align-items: center; gap: 6px;
    margin-bottom: 10px;
}
.data-kpi-head svg { flex-shrink: 0; }
.data-kpi-label {
    font-size: 11px;
    color: var(--ink-500);
    font-weight: 500;
    line-height: 1;
}
.data-kpi-value {
    font-size: 26px;
    font-weight: 700;
    line-height: 1;
    color: var(--ink-900);
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: -0.02em;
}
.data-kpi-unit {
    font-size: 12px;
    font-weight: 500;
    color: var(--ink-500);
    margin-left: 4px;
}
.data-kpi-hint {
    font-size: 10px;
    color: var(--ink-400);
    margin-top: 6px;
    line-height: 1.3;
}
.data-kpi-teal   { box-shadow: inset 3px 0 0 var(--teal-500); }
.data-kpi-amber  { box-shadow: inset 3px 0 0 var(--amber-500); }
.data-kpi-purple { box-shadow: inset 3px 0 0 var(--purple-500); }
.data-kpi-slate  { box-shadow: inset 3px 0 0 var(--ink-600); }

/* =========================================================
   Data Panel
   ========================================================= */
.data-panel {
    background: #fff;
    border-radius: 14px;
    box-shadow: var(--shadow-xs);
    overflow: hidden;
    border: 1px solid var(--ink-100);
    margin-bottom: 14px;
}
.data-panel:last-child { margin-bottom: 0; }
.data-panel-header {
    padding: 12px 14px;
    display: flex; align-items: center; justify-content: space-between;
    border-bottom: 1px solid var(--ink-100);
    background: var(--ink-50);
}
.data-panel-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink-900);
    letter-spacing: -0.005em;
    display: flex; align-items: center; gap: 6px;
}
.data-panel-title::before {
    content: '';
    width: 3px; height: 12px;
    background: var(--teal-500);
    border-radius: 2px;
}
.data-panel-meta {
    font-size: 10px;
    color: var(--ink-400);
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.02em;
}

/* =========================================================
   Chart
   ========================================================= */
.data-chart {
    padding: 20px 14px 16px;
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    gap: 10px;
    height: 180px;
}
.data-chart-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    height: 100%;
    min-width: 0;
}
.data-chart-bar-wrap {
    flex: 1;
    width: 100%;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    position: relative;
}
.data-chart-bar {
    width: 70%;
    background: var(--teal-500);
    border-radius: 6px 6px 2px 2px;
    min-height: 6px;
    position: relative;
    box-shadow: 0 2px 4px rgba(16, 185, 129, 0.15);
}
.data-chart-bar.current {
    background: linear-gradient(180deg, var(--teal-400) 0%, var(--teal-500) 100%);
    width: 90%;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.30);
}
.data-chart-bar::after {
    content: '';
    position: absolute;
    inset: 1px 1px auto 1px;
    height: 35%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.4), transparent);
    border-radius: 5px 5px 0 0;
}
.data-chart-value {
    font-size: 12px;
    font-weight: 700;
    color: var(--ink-900);
    font-family: 'JetBrains Mono', monospace;
    line-height: 1;
}
.data-chart-label {
    font-size: 10px;
    color: var(--ink-500);
    line-height: 1.2;
    margin-top: 2px;
    text-align: center;
}

/* =========================================================
   Top List (Top 10 schools)
   ========================================================= */
.data-toplist {
    padding: 4px 0;
}
.data-toplist-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    cursor: pointer;
    transition: background 0.12s ease;
}
.data-toplist-row:active { background: var(--ink-50); }
.data-toplist-row + .data-toplist-row { border-top: 1px solid var(--ink-100); }
.data-toplist-rank {
    width: 22px; height: 22px;
    border-radius: 6px;
    background: var(--ink-100);
    color: var(--ink-700);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    font-weight: 700;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.data-toplist-rank.top1 { background: linear-gradient(135deg, #fbbf24, #d97706); color: #fff; }
.data-toplist-rank.top2 { background: linear-gradient(135deg, #cbd5e1, #94a3b8); color: #fff; }
.data-toplist-rank.top3 { background: linear-gradient(135deg, #fb923c, #c2410c); color: #fff; }
.data-toplist-name {
    flex: 1;
    min-width: 0;
    font-size: 13px;
    color: var(--ink-800);
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.data-toplist-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    font-weight: 700;
    color: var(--teal-700);
    flex-shrink: 0;
}

/* =========================================================
   Data Notice
   ========================================================= */
.data-notice {
    background: linear-gradient(135deg, var(--teal-50) 0%, #ecfeff 100%);
    border: 1px solid var(--teal-200);
    border-radius: 14px;
    padding: 12px 14px;
    box-shadow: 0 1px 3px rgba(16, 185, 129, 0.06);
}
.data-notice-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--teal-800);
    margin-bottom: 4px;
    display: flex; align-items: center; gap: 6px;
}
.data-notice-text {
    font-size: 12px;
    color: var(--ink-600);
    line-height: 1.6;
}

/* =========================================================
   Section head
   ========================================================= */
.data-section-head {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 12px;
    padding: 0 2px;
}
.data-section-head-left {
    font-size: 12px;
    color: var(--ink-500);
}
.data-section-head-left .num {
    color: var(--teal-700);
    font-weight: 700;
    font-family: 'JetBrains Mono', monospace;
    margin: 0 2px;
}
.data-section-head-right {
    font-size: 10px;
    color: var(--ink-400);
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

/* =========================================================
   Data Table
   ========================================================= */
.data-table-wrap {
    background: #fff;
    border-radius: 14px;
    overflow-x: auto;
    box-shadow: var(--shadow-xs);
    border: 1px solid var(--ink-100);
}
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
.data-table thead {
    background: var(--ink-50);
    border-bottom: 1px solid var(--ink-200);
}
.data-table th {
    padding: 10px 12px;
    text-align: left;
    font-size: 10px;
    font-weight: 600;
    color: var(--ink-500);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    white-space: nowrap;
}
.data-table td {
    padding: 12px;
    border-bottom: 1px solid var(--ink-100);
    color: var(--ink-700);
    vertical-align: middle;
}
.data-table tbody tr {
    transition: background 0.12s ease;
    cursor: pointer;
}
.data-table tbody tr:active { background: var(--ink-50); }
.data-table tbody tr:last-child td { border-bottom: 0; }

.data-table .row-index {
    color: var(--ink-400);
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    text-align: right;
    font-weight: 600;
}
.data-table .row-name {
    font-weight: 600;
    color: var(--ink-900);
    letter-spacing: -0.005em;
    white-space: nowrap;
}
.data-table .row-school {
    color: var(--ink-600);
    font-size: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 180px;
    white-space: nowrap;
}
.data-table .row-note {
    font-size: 10px;
    padding: 3px 7px;
    border-radius: 4px;
    line-height: 1.3;
    white-space: nowrap;
    font-weight: 600;
    letter-spacing: 0.01em;
    text-align: center;
    display: inline-block;
}
.row-note-sanh { background: #fef3c7; color: var(--amber-600); }
.row-note-ganb { background: #f3e8ff; color: var(--purple-600); }
.row-note-chuz { background: var(--teal-100); color: var(--teal-700); }

/* =========================================================
   Card List
   ========================================================= */
.data-card-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.data-card {
    background: #fff;
    border-radius: 12px;
    padding: 12px;
    box-shadow: var(--shadow-xs);
    border: 1px solid var(--ink-100);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: background 0.12s ease;
}
.data-card:active { background: var(--ink-50); }
.data-card-avatar {
    width: 40px; height: 40px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--teal-400), var(--teal-600));
    color: #fff;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 700;
    font-size: 16px;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(16, 185, 129, 0.20);
}
.data-card-body { flex: 1; min-width: 0; }
.data-card-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--ink-900);
    margin-bottom: 4px;
    letter-spacing: -0.01em;
    line-height: 1.3;
}
.data-card-school {
    font-size: 11px;
    color: var(--ink-500);
    margin-bottom: 6px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.data-card-meta { display: flex; align-items: center; gap: 5px; }
.data-card-arrow {
    color: var(--ink-300);
    flex-shrink: 0;
}

/* =========================================================
   School Group (按学校 / 按奖项)
   ========================================================= */
.data-school-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.data-school-block {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-xs);
    border: 1px solid var(--ink-100);
}
.data-school-head {
    padding: 12px 14px;
    background: linear-gradient(180deg, var(--ink-50), #fff);
    border-bottom: 1px solid var(--ink-100);
    display: flex; align-items: center; gap: 8px;
    cursor: pointer;
    transition: background 0.12s ease;
}
.data-school-head:active { background: var(--ink-50); }
.data-school-head .name {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink-900);
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    letter-spacing: -0.005em;
}
.data-school-head .count {
    font-size: 11px;
    font-family: 'JetBrains Mono', monospace;
    color: var(--teal-700);
    font-weight: 700;
    flex-shrink: 0;
}
.data-school-head .arrow {
    color: var(--ink-400);
    flex-shrink: 0;
    transition: transform 0.2s ease;
}
.data-school-block.open .data-school-head .arrow { transform: rotate(90deg); }
.data-school-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.data-school-block.open .data-school-body { max-height: 4000px; }
.data-school-body-inner {
    padding: 4px 0;
    max-height: 360px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.data-school-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    border-top: 1px solid var(--ink-100);
    cursor: pointer;
    transition: background 0.12s ease;
}
.data-school-row:active { background: var(--ink-50); }
.data-school-row .name {
    flex: 1;
    font-size: 13px;
    color: var(--ink-800);
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* School filter chips */
.data-school-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
    padding: 0 2px;
}
.data-school-chip {
    padding: 5px 10px;
    font-size: 11px;
    color: var(--ink-600);
    background: #fff;
    border: 1px solid var(--ink-200);
    border-radius: 999px;
    cursor: pointer;
    transition: all 0.15s ease;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 600;
}
.data-school-chip:active { transform: scale(0.96); }
.data-school-chip.active {
    color: #fff;
    background: var(--teal-600);
    border-color: var(--teal-600);
}

/* =========================================================
   Label Badge
   ========================================================= */
.data-label {
    font-size: 10px;
    padding: 2px 7px;
    border-radius: 4px;
    line-height: 1.4;
    white-space: nowrap;
    letter-spacing: 0.01em;
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 600;
    line-height: 1.3;
}
.data-label-national { background: #fef3c7; color: var(--amber-600); }
.data-label-key      { background: #f3e8ff; color: var(--purple-600); }
.data-label-province { background: var(--teal-100); color: var(--teal-700); }

/* =========================================================
   Search Result Row
   ========================================================= */
.data-search-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.data-search-row {
    background: #fff;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: background 0.12s ease;
    border: 1px solid var(--ink-100);
    box-shadow: var(--shadow-xs);
}
.data-search-row:active { background: var(--ink-50); }

/* =========================================================
   Loading Sentinel
   ========================================================= */
.data-sentinel {
    padding: 20px 0 8px;
    text-align: center;
    min-height: 60px;
}
.data-sentinel.done {
    color: var(--ink-400);
    font-size: 11px;
    padding: 16px 0;
}
.data-loading {
    display: inline-flex;
    gap: 6px;
}
.data-loading .dot {
    width: 6px; height: 6px;
    background: var(--teal-500);
    border-radius: 50%;
    animation: data-bounce 1.4s ease-in-out infinite;
}
.data-loading .dot:nth-child(2) { animation-delay: 0.16s; }
.data-loading .dot:nth-child(3) { animation-delay: 0.32s; }
@keyframes data-bounce {
    0%, 80%, 100% { transform: scale(0.5); opacity: 0.4; }
    40% { transform: scale(1); opacity: 1; }
}

/* =========================================================
   Empty State
   ========================================================= */
.data-empty {
    background: #fff;
    border-radius: 14px;
    padding: 32px 20px;
    text-align: center;
    box-shadow: var(--shadow-xs);
    border: 1px dashed var(--ink-200);
}
.data-empty-title {
    font-size: 13px;
    color: var(--ink-700);
    font-weight: 500;
    margin-top: 8px;
}
.data-empty-hint {
    font-size: 11px;
    color: var(--ink-400);
    margin-top: 6px;
    font-family: 'JetBrains Mono', monospace;
}

/* =========================================================
   Bottom Sheet Modal
   ========================================================= */
.modal-overlay {
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    transition: opacity 0.25s ease;
}
.bottom-sheet {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    background: #fff;
    border-radius: 20px 20px 0 0;
    max-height: 88vh;
    overflow: hidden;
    transform: translateY(100%);
    transition: transform 0.36s cubic-bezier(0.22, 0.61, 0.36, 1);
    will-change: transform;
    box-shadow: 0 -16px 40px rgba(15, 23, 42, 0.14);
    display: flex;
    flex-direction: column;
}
.bottom-sheet.open { transform: translateY(0); }
.bottom-sheet .sheet-handle {
    width: 36px; height: 4px;
    background: var(--ink-300);
    border-radius: 9999px;
    margin: 8px auto 0;
    flex-shrink: 0;
}
.modal-cover-bar {
    height: 4px;
    background: linear-gradient(90deg, var(--teal-400), var(--teal-500), var(--teal-600));
    flex-shrink: 0;
}
.modal-header {
    padding: 16px 20px 12px;
    display: flex; align-items: flex-start; justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--ink-100);
    flex-shrink: 0;
}
.modal-eyebrow {
    font-size: 10px;
    color: var(--ink-400);
    font-family: 'JetBrains Mono', monospace;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    line-height: 1;
    margin-bottom: 4px;
}
.modal-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--ink-900);
    line-height: 1.3;
    letter-spacing: -0.01em;
}
.modal-close {
    width: 32px; height: 32px;
    border-radius: 9999px;
    background: var(--ink-100);
    border: 0;
    color: var(--ink-500);
    cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    transition: background 0.12s ease;
}
.modal-close:active { background: var(--ink-200); }
.modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px 28px;
    -webkit-overflow-scrolling: touch;
}

.modal-field {
    text-align: center;
    padding: 14px 6px 16px;
    flex: 1;
    border: 1px solid var(--ink-200);
    border-left-width: 0;
    transition: background 0.12s ease;
}
.modal-field:first-child { border-left-width: 1px; }
.modal-field-label {
    font-size: 10px;
    color: var(--ink-500);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    line-height: 1;
}
.modal-field-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 17px;
    font-weight: 700;
    margin-top: 6px;
    line-height: 1;
}

mark {
    background: linear-gradient(135deg, var(--teal-100), var(--teal-200));
    color: var(--teal-800);
    border-radius: 3px;
    padding: 0 3px;
    font-weight: 600;
}

/* =========================================================
   Responsive
   ========================================================= */
@media (min-width: 640px) {
    .data-kpi-grid { grid-template-columns: repeat(4, 1fr); }
    .data-card-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .data-school-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
}
@media (min-width: 1024px) {
    body { max-width: 540px; margin: 0 auto; border-left: 1px solid var(--ink-200); border-right: 1px solid var(--ink-200); min-height: 100vh; background: var(--ink-50); }
}