/* =========================================================
   岐黄声训 · 管理后台
   ========================================================= */
.admin-body { background: #eff2ed; color: var(--ink); }
.admin-shell { display: flex; min-height: 100dvh; }

.admin-sidebar {
  position: sticky; top: 0; width: 244px; height: 100dvh; flex: none;
  display: flex; flex-direction: column; padding: 24px 16px 18px;
  background:
    radial-gradient(circle at 20% 0%, rgba(74, 154, 125, 0.17), transparent 35%),
    linear-gradient(170deg, #0c3d2f, #06261e 70%);
  color: var(--cream); overflow-y: auto;
}
.admin-brand { display: flex; align-items: center; gap: 10px; padding: 0 8px; margin-bottom: 32px; }
.admin-brand strong { display: block; font-family: var(--serif); font-size: 18px; letter-spacing: 0.12em; font-weight: 600; }
.admin-brand small { display: block; margin-top: 2px; font-size: 8px; letter-spacing: 0.16em; color: rgba(246, 241, 231, 0.4); }
.admin-nav { display: grid; gap: 4px; }
.admin-nav-item {
  display: flex; align-items: center; gap: 10px; padding: 10px 11px;
  border-radius: 9px; font-size: 12px; color: rgba(246, 241, 231, 0.55);
  transition: all 0.18s ease; position: relative;
}
.admin-nav-item .icon { width: 17px; height: 17px; }
.admin-nav-item:hover { color: var(--cream); background: rgba(255, 255, 255, 0.05); }
.admin-nav-item.active { background: rgba(196, 154, 74, 0.15); color: var(--gold); }
.admin-nav-item.active::before {
  content: ""; position: absolute; left: -16px; top: 9px; bottom: 9px;
  width: 3px; border-radius: 0 3px 3px 0; background: var(--gold);
}
.admin-side-card {
  margin-top: auto; padding: 14px; border-radius: 12px;
  background: rgba(255, 255, 255, 0.045); border: 1px solid rgba(246, 241, 231, 0.08);
}
.side-card-icon { width: 30px; height: 30px; border-radius: 50%; background: rgba(196, 154, 74, 0.15); color: var(--gold); display: grid; place-items: center; margin-bottom: 9px; }
.side-card-icon .icon { width: 14px; height: 14px; }
.admin-side-card strong { display: block; font-size: 10px; margin-bottom: 4px; }
.admin-side-card p { font-size: 9px; line-height: 1.7; color: rgba(246, 241, 231, 0.4); }
.admin-side-card a { display: inline-flex; align-items: center; gap: 3px; margin-top: 9px; font-size: 9px; color: var(--gold); }
.admin-side-card a .icon { width: 11px; height: 11px; }
.admin-user { display: flex; align-items: center; gap: 9px; margin-top: 16px; padding: 13px 4px 0; border-top: 1px solid rgba(246, 241, 231, 0.08); }
.admin-user > div { flex: 1; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.admin-user strong { font-size: 10px; }
.admin-user span { font-size: 8px; color: rgba(246, 241, 231, 0.4); }
.admin-user .icon-btn { color: rgba(246, 241, 231, 0.45); width: 30px; height: 30px; }
.admin-user .icon-btn .icon { width: 14px; height: 14px; }

.admin-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.admin-topbar {
  height: 66px; flex: none; display: flex; align-items: center; gap: 20px;
  padding: 0 32px; background: rgba(255, 253, 248, 0.88);
  border-bottom: 1px solid rgba(23, 53, 43, 0.07);
  backdrop-filter: blur(16px); position: sticky; top: 0; z-index: 30;
}
.admin-mobile-brand { display: none; align-items: center; gap: 8px; }
.admin-mobile-brand strong { font-family: var(--serif); font-size: 16px; letter-spacing: 0.1em; }
.topbar-context { display: flex; flex-direction: column; gap: 1px; }
.topbar-kicker { font-size: 8px; font-weight: 800; letter-spacing: 0.18em; color: var(--green-600); }
.topbar-date { font-size: 10px; color: var(--muted-2); }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.topbar-link { display: inline-flex; align-items: center; gap: 5px; padding: 6px 9px; border-radius: 7px; font-size: 9px; color: var(--red); background: var(--red-soft); }
.topbar-link .icon { width: 12px; height: 12px; }
.topbar-link i { font-style: normal; width: 15px; height: 15px; border-radius: 50%; background: var(--red); color: #fff; display: grid; place-items: center; font-size: 8px; }
.topbar-bell { position: relative; width: 34px; height: 34px; }
.topbar-bell .icon { width: 17px; height: 17px; }
.topbar-bell i { position: absolute; top: 8px; right: 8px; width: 5px; height: 5px; border-radius: 50%; background: var(--red); }
.topbar-logout { display: none; width: 32px; height: 32px; color: var(--muted); }
.topbar-logout .icon { width: 15px; height: 15px; }
.admin-mobile-nav { display: none; }
.admin-view { flex: 1; padding: 28px 32px 44px; max-width: 1560px; width: 100%; margin: 0 auto; }
.admin-page { animation: fade-up 0.35s ease both; }

@keyframes fade-up { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.admin-page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.admin-kicker { display: block; margin-bottom: 4px; font-size: 8px; font-weight: 800; letter-spacing: 0.18em; color: var(--green-600); }
.admin-page-head h1 { font-family: var(--serif); font-size: 30px; font-weight: 600; letter-spacing: -0.035em; line-height: 1.2; }
.admin-page-head p { margin-top: 5px; font-size: 11px; color: var(--muted); line-height: 1.6; max-width: 760px; }
.admin-head-actions { display: flex; align-items: center; gap: 8px; flex: none; }
.select-wrap {
  display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 11px;
  border: 1px solid var(--line); border-radius: 8px; background: var(--paper);
  color: var(--muted); position: relative;
}
.select-wrap > .icon:first-child { width: 13px; height: 13px; }
.select-wrap > .icon:last-child { width: 11px; height: 11px; pointer-events: none; }
.select-wrap select { appearance: none; border: 0; background: transparent; font-size: 10px; color: var(--ink-2); padding-right: 8px; outline: none; cursor: pointer; }
.select-wrap select:focus { color: var(--green-700); }

.admin-alert {
  display: flex; align-items: center; gap: 11px; padding: 13px 15px; margin-bottom: 16px;
  background: linear-gradient(100deg, #f8ecd9, #fbf5e9); border: 1px solid rgba(181, 133, 63, 0.22);
  border-radius: 11px;
}
.admin-alert > .icon { width: 18px; height: 18px; color: var(--amber); flex: none; }
.admin-alert > div { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.admin-alert strong { font-size: 11px; color: var(--amber); }
.admin-alert p { font-size: 9px; color: var(--muted); }
.admin-alert a { display: inline-flex; align-items: center; gap: 3px; font-size: 9px; font-weight: 600; color: var(--amber); }
.admin-alert a .icon { width: 11px; height: 11px; }

/* ---------- KPI ---------- */
.kpi-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin-bottom: 16px; }
.kpi-card {
  position: relative; overflow: hidden; padding: 15px 15px 13px;
  background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07);
  border-radius: 13px; box-shadow: 0 3px 12px rgba(23, 53, 43, 0.035);
}
.kpi-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--kpi, var(--green-600)); }
.kpi-green { --kpi: var(--green-600); }
.kpi-blue { --kpi: var(--blue); }
.kpi-gold { --kpi: var(--gold); }
.kpi-purple { --kpi: var(--purple); }
.kpi-red { --kpi: var(--red); }
.kpi-amber { --kpi: var(--amber); }
.kpi-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 9px; color: var(--muted); }
.kpi-icon { width: 26px; height: 26px; border-radius: 7px; display: grid; place-items: center; background: color-mix(in srgb, var(--kpi) 10%, transparent); color: var(--kpi); }
.kpi-icon .icon { width: 13px; height: 13px; }
.kpi-value { margin: 8px 0 5px; font-family: var(--serif); font-size: 28px; line-height: 1; font-weight: 600; letter-spacing: -0.03em; color: var(--ink); }
.kpi-value small { margin-left: 2px; font-family: var(--sans); font-size: 8px; font-weight: 500; color: var(--muted-2); letter-spacing: 0; }
.kpi-foot { display: flex; align-items: center; justify-content: space-between; gap: 5px; font-size: 8px; color: var(--muted-2); }
.kpi-delta { display: inline-flex; align-items: center; gap: 2px; color: var(--muted-2); white-space: nowrap; }
.kpi-delta .icon { width: 9px; height: 9px; }
.kpi-delta.up { color: var(--green-600); }
.kpi-delta.down { color: var(--red); }

/* ---------- Layout ---------- */
.dash-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 14px; }
.admin-panel { background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); border-radius: 14px; padding: 18px; box-shadow: 0 3px 12px rgba(23, 53, 43, 0.03); min-width: 0; }
.admin-panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.admin-panel-head h2 { font-family: var(--serif); font-size: 17px; font-weight: 600; letter-spacing: -0.02em; }
.admin-panel-head .text-link { margin-top: 3px; }
.chart-panel { grid-column: span 8; }
.radar-panel { grid-column: span 4; display: flex; flex-direction: column; }
.dist-panel { grid-column: span 5; }
.attention-panel { grid-column: span 7; }
.chart-tabs { display: flex; gap: 3px; padding: 3px; border-radius: 7px; background: rgba(23, 53, 43, 0.045); }
.chart-tabs button { padding: 5px 9px; border-radius: 5px; font-size: 9px; color: var(--muted); }
.chart-tabs button.active { background: var(--paper); color: var(--ink); box-shadow: 0 1px 4px rgba(23, 53, 43, 0.08); }
.chart-legend { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 8px; color: var(--muted); }
.chart-legend span { display: inline-flex; align-items: center; gap: 4px; }
.chart-legend .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green-600); display: inline-block; }
.chart-legend .dot.green { background: var(--green-600); }
.trend-wrap { margin: 0 -6px; }
.trend-chart { width: 100%; height: auto; min-height: 230px; }
.axis-text { font-family: var(--sans); font-size: 8px; fill: var(--muted-2); }
.admin-radar { flex: 1; display: flex; align-items: center; justify-content: center; margin: -10px 0; }
.admin-radar svg { width: 100%; max-width: 360px; height: auto; }
.radar-foot { display: flex; align-items: center; gap: 6px; margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--line-soft); font-size: 8px; color: var(--muted-2); }
.radar-foot strong { color: var(--ink); font-size: 9px; }
.radar-foot a { margin-left: auto; display: inline-flex; align-items: center; gap: 2px; color: var(--green-700); font-size: 8px; }
.radar-foot a .icon { width: 10px; height: 10px; }

.dist-list { display: grid; gap: 11px; }
.dist-row { display: grid; grid-template-columns: 78px 1fr 34px; align-items: center; gap: 9px; }
.dist-label { display: flex; flex-direction: column; gap: 1px; }
.dist-label span { font-size: 9px; color: var(--ink-2); }
.dist-label strong { font-family: var(--serif); font-size: 13px; font-weight: 600; }
.dist-label small { font-family: var(--sans); font-size: 7px; color: var(--muted-2); }
.dist-track { height: 5px; border-radius: 4px; background: rgba(23, 53, 43, 0.06); overflow: hidden; }
.dist-track i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, var(--green-600), #72b59a); }
.dist-row:nth-child(2) .dist-track i { background: linear-gradient(90deg, var(--gold), #ddbd7b); }
.dist-row:nth-child(3) .dist-track i { background: linear-gradient(90deg, var(--blue), #7fa7c9); }
.dist-row:nth-child(4) .dist-track i { background: linear-gradient(90deg, var(--purple), #a596c8); }
.dist-row:nth-child(5) .dist-track i { background: linear-gradient(90deg, var(--red), #d79285); }
.dist-row em { font-style: normal; text-align: right; font-size: 8px; color: var(--muted-2); }
.dist-total { display: flex; align-items: baseline; gap: 5px; margin-top: 15px; padding-top: 11px; border-top: 1px solid var(--line-soft); font-size: 8px; color: var(--muted-2); }
.dist-total strong { font-family: var(--serif); font-size: 18px; color: var(--ink); font-weight: 500; }

.attention-list { display: grid; gap: 2px; }
.attention-row { display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; padding: 8px 5px; border-radius: 8px; }
.attention-row:hover { background: rgba(23, 53, 43, 0.03); }
.attention-body { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.attention-body strong { font-size: 10px; }
.attention-body strong small { font-size: 7px; color: var(--muted-2); font-weight: 400; margin-left: 3px; }
.attention-body em { font-style: normal; font-size: 8px; color: var(--red); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.attention-score { display: flex; align-items: baseline; gap: 1px; font-family: var(--serif); font-size: 19px; color: var(--amber); }
.attention-score.green { color: var(--green-600); }
.attention-score.red { color: var(--red); }
.attention-score small { font-family: var(--sans); font-size: 7px; color: var(--muted-2); }
.attention-row > .icon { width: 12px; height: 12px; color: var(--muted-2); }
.attention-foot { display: flex; align-items: center; gap: 4px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line-soft); font-size: 8px; color: var(--muted-2); }
.attention-foot .icon { width: 10px; height: 10px; color: var(--gold); }
.all-good { display: flex; align-items: center; gap: 8px; padding: 22px 12px; color: var(--green-600); font-size: 9px; }
.all-good .icon { width: 18px; height: 18px; }

.dash-lower { display: grid; grid-template-columns: 1.35fr 1fr; gap: 14px; margin-top: 14px; }
.admin-bottom-note { display: flex; align-items: flex-start; gap: 5px; margin-top: 16px; font-size: 8px; color: var(--muted-2); line-height: 1.6; }
.admin-bottom-note .icon { width: 10px; height: 10px; margin-top: 2px; flex: none; }

/* ---------- Tables ---------- */
.table-panel { padding: 0; overflow: hidden; }
.table-scroll { width: 100%; overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 10px; white-space: nowrap; }
.admin-table th {
  text-align: left; padding: 11px 12px; font-size: 8px; font-weight: 700;
  letter-spacing: 0.04em; color: var(--muted-2); background: rgba(23, 53, 43, 0.025);
  border-bottom: 1px solid var(--line-soft);
}
.admin-table td { padding: 10px 12px; border-bottom: 1px solid rgba(231, 223, 208, 0.55); vertical-align: middle; }
.admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-table tbody tr { transition: background 0.15s ease; cursor: pointer; }
.admin-table tbody tr:hover { background: rgba(47, 125, 100, 0.035); }
.admin-table.compact td { padding: 8px 10px; }
.admin-table.compact th { padding: 9px 10px; }
.table-user { display: flex; align-items: center; gap: 7px; }
.table-user > span { display: flex; flex-direction: column; gap: 1px; }
.table-user strong { font-size: 10px; font-weight: 600; }
.table-user small { font-size: 7px; color: var(--muted-2); }
.table-score { font-family: var(--serif); font-size: 16px; font-weight: 600; }
.table-score.pass, .table-score.green { color: var(--green-700); }
.table-score.fail, .table-score.red { color: var(--red); }
.table-score.gold { color: var(--gold-deep); }
.table-score.blue { color: var(--blue); }
.table-score.amber { color: var(--amber); }
.table-score + small { font-size: 7px; color: var(--muted-2); }
.team-tag { display: inline-block; padding: 3px 6px; border-radius: 4px; background: rgba(23, 53, 43, 0.045); font-size: 8px; color: var(--muted); }
.mini-exam-score { display: inline-grid; place-items: center; min-width: 26px; height: 22px; padding: 0 5px; border-radius: 5px; font-family: var(--serif); font-size: 12px; font-weight: 600; }
.mini-exam-score.pass { background: var(--green-100); color: var(--green-700); }
.mini-exam-score.fail { background: var(--red-soft); color: var(--red); }
.muted-dash { color: var(--muted-2); font-size: 9px; }
.table-link { font-size: 9px; color: var(--green-700); font-weight: 600; padding: 3px 0; }
.table-link:hover { text-decoration: underline; }
.table-link.strong { color: var(--red); }
.table-actions { display: flex; gap: 10px; }
.table-empty { padding: 32px; text-align: center; color: var(--muted-2); font-size: 10px; }
.exam-type-dot { display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: var(--blue); margin-right: 5px; vertical-align: 1px; }
.exam-type-dot.actual { background: var(--red); }
.record-scenario { display: flex; flex-direction: column; gap: 1px; }
.record-scenario strong { font-size: 10px; font-weight: 600; }
.record-scenario small { font-size: 7px; color: var(--muted-2); }

.wrong-top-list { display: grid; gap: 1px; }
.wrong-top-row { display: flex; align-items: center; gap: 9px; padding: 9px 0; border-bottom: 1px solid rgba(231, 223, 208, 0.55); }
.wrong-top-row:last-child { border-bottom: 0; }
.rank-num { font-family: var(--serif); font-size: 13px; color: var(--gold-deep); width: 20px; flex: none; }
.wrong-top-row > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wrong-top-row strong { font-size: 9px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.wrong-top-row span { font-size: 7px; color: var(--muted-2); }
.wrong-top-row em { font-style: normal; font-size: 9px; color: var(--red); white-space: nowrap; }
.wrong-top-tip { display: flex; align-items: center; gap: 4px; margin-top: 11px; padding: 8px; border-radius: 6px; background: var(--gold-soft); font-size: 8px; color: var(--muted); }
.wrong-top-tip .icon { width: 10px; height: 10px; color: var(--gold-deep); flex: none; }
.wrong-top-tip strong { color: var(--gold-deep); }

/* ---------- Filters ---------- */
.filter-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.admin-search { display: flex; align-items: center; gap: 7px; height: 38px; min-width: 240px; padding: 0 11px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.admin-search .icon { width: 13px; height: 13px; color: var(--muted-2); }
.admin-search input { flex: 1; border: 0; outline: 0; background: transparent; font-size: 10px; }
.filter-count { margin-left: auto; font-size: 9px; color: var(--muted-2); }
.filter-count strong { color: var(--ink); font-family: var(--serif); font-size: 12px; }
.switch-label { display: inline-flex; align-items: center; gap: 6px; font-size: 9px; color: var(--muted); cursor: pointer; }
.switch-label input { display: none; }
.switch-label span { width: 28px; height: 16px; border-radius: 999px; background: rgba(23, 53, 43, 0.12); position: relative; transition: background 0.2s ease; }
.switch-label span::after { content: ""; position: absolute; left: 2px; top: 2px; width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: transform 0.2s ease; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.12); }
.switch-label input:checked + span { background: var(--green-600); }
.switch-label input:checked + span::after { transform: translateX(12px); }
.employees-table th, .employees-table td { padding-left: 10px; padding-right: 10px; }

/* ---------- Wrong analysis ---------- */
.wrong-stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
.wrong-stat { position: relative; padding: 14px 15px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); border-radius: 12px; display: flex; flex-direction: column; gap: 2px; }
.ws-icon { position: absolute; right: 13px; top: 13px; width: 28px; height: 28px; border-radius: 50%; background: var(--red-soft); color: var(--red); display: grid; place-items: center; }
.ws-icon .icon { width: 13px; height: 13px; }
.wrong-stat strong { font-family: var(--serif); font-size: 27px; font-weight: 600; line-height: 1; }
.wrong-stat strong small { margin-left: 2px; font-family: var(--sans); font-size: 8px; color: var(--muted-2); }
.wrong-stat > span:last-child { font-size: 8px; color: var(--muted-2); }
.wrong-admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.cat-weak-list { display: grid; gap: 9px; }
.cat-weak-row { display: flex; align-items: center; gap: 9px; }
.cat-weak-icon { width: 28px; height: 28px; border-radius: 7px; background: var(--green-100); color: var(--green-700); display: grid; place-items: center; flex: none; }
.cat-weak-icon .icon { width: 13px; height: 13px; }
.cat-weak-row > div { flex: 1; min-width: 0; }
.cat-weak-row strong { font-size: 9px; font-weight: 600; }
.cat-weak-track { height: 4px; border-radius: 4px; background: rgba(23, 53, 43, 0.06); margin-top: 4px; overflow: hidden; }
.cat-weak-track i { display: block; height: 100%; background: linear-gradient(90deg, var(--red), #d29487); border-radius: 4px; }
.cat-weak-row em { font-style: normal; font-family: var(--serif); font-size: 11px; color: var(--muted); width: 34px; text-align: right; }
.cat-weak-tip { display: flex; gap: 6px; margin-top: 13px; padding: 9px; border-radius: 7px; background: var(--gold-soft); }
.cat-weak-tip .icon { width: 11px; height: 11px; color: var(--gold-deep); flex: none; margin-top: 1px; }
.cat-weak-tip p { font-size: 8px; line-height: 1.6; color: var(--ink-2); }
.top-question { padding: 2px 0; }
.top-question h3 { margin: 8px 0 10px; font-family: var(--serif); font-size: 14px; line-height: 1.6; font-weight: 600; }
.tq-rate { display: flex; align-items: baseline; gap: 5px; }
.tq-rate strong { font-family: var(--serif); font-size: 24px; color: var(--red); font-weight: 500; }
.tq-rate span { font-size: 8px; color: var(--muted-2); }
.tq-rate > div { flex: 1; height: 4px; border-radius: 4px; background: rgba(176, 74, 58, 0.1); overflow: hidden; margin-left: 6px; }
.tq-rate > div i { display: block; height: 100%; background: var(--red); border-radius: 4px; }
.top-question > p { margin: 8px 0 10px; font-size: 8px; line-height: 1.6; color: var(--muted); }
.top-question > p strong { color: var(--ink); }
.wrong-admin-tabs { width: fit-content; min-width: 300px; margin-bottom: 12px; }
.wrong-admin-row { display: flex; align-items: center; gap: 11px; width: 100%; text-align: left; padding: 13px 15px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); border-radius: 11px; margin-bottom: 7px; transition: all 0.18s ease; }
.wrong-admin-row:hover { border-color: rgba(176, 74, 58, 0.25); transform: translateX(2px); }
.wrong-rank { font-family: var(--serif); font-size: 16px; color: var(--gold-deep); width: 24px; flex: none; }
.wrong-admin-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.wrong-admin-meta { display: flex; align-items: center; gap: 6px; font-size: 7px; color: var(--muted-2); }
.wrong-admin-meta em { font-style: normal; color: var(--gold-deep); background: var(--gold-soft); padding: 2px 5px; border-radius: 3px; }
.wrong-admin-meta i { font-style: normal; }
.wrong-admin-meta b { font-weight: 600; color: var(--red); }
.wrong-admin-body strong { font-size: 10px; line-height: 1.5; }
.wrong-admin-body small { font-size: 8px; color: var(--muted-2); }
.wrong-rate { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; flex: none; }
.wrong-rate strong { font-family: var(--serif); font-size: 19px; color: var(--red); font-weight: 500; }
.wrong-rate small { font-size: 7px; color: var(--muted-2); }
.wrong-admin-row > .icon { width: 13px; height: 13px; color: var(--muted-2); }
.admin-practice-card { padding: 15px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); border-radius: 12px; margin-bottom: 9px; }
.apc-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.apc-head strong { font-size: 9px; color: var(--muted); }
.apc-example { padding: 9px 0; border-top: 1px solid var(--line-soft); }
.apc-quote { font-size: 9px; line-height: 1.6; color: var(--muted); }
.apc-example > p:nth-child(2) { margin-top: 3px; font-size: 9px; line-height: 1.6; }
.apc-example > div { display: flex; gap: 4px; margin-top: 5px; font-size: 8px; line-height: 1.6; color: var(--green-700); }
.apc-example > div .icon { width: 10px; height: 10px; flex: none; margin-top: 1px; }

/* ---------- Exam results ---------- */
.result-overview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
.result-overview > div { position: relative; overflow: hidden; padding: 15px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); border-radius: 12px; display: flex; flex-direction: column; gap: 2px; }
.result-overview span { font-size: 9px; color: var(--muted); }
.result-overview strong { font-family: var(--serif); font-size: 27px; font-weight: 600; line-height: 1.1; }
.result-overview strong small { font-family: var(--sans); font-size: 8px; color: var(--muted-2); }
.result-overview i { position: absolute; left: 0; bottom: 0; height: 2px; width: var(--p); background: var(--gold); }
.exam-filter-tabs { margin: 0; min-width: 360px; }
.exam-filter-tabs button { flex: none; padding: 0 14px; }
.result-overview + .filter-bar { margin-top: 4px; }

/* ---------- Content ---------- */
.content-overview { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 14px; }
.content-kpi { display: flex; align-items: center; gap: 11px; padding: 15px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); border-radius: 12px; }
.content-kpi > span { width: 38px; height: 38px; border-radius: 10px; background: var(--green-100); color: var(--green-700); display: grid; place-items: center; flex: none; }
.content-kpi > span .icon { width: 17px; height: 17px; }
.content-kpi > div { display: flex; flex-direction: column; gap: 1px; }
.content-kpi strong { font-family: var(--serif); font-size: 24px; font-weight: 600; line-height: 1; }
.content-kpi small { font-size: 8px; color: var(--muted-2); }
.content-kpi p { margin-left: auto; font-size: 8px; color: var(--muted-2); }
.content-tabs { width: fit-content; min-width: 300px; margin-bottom: 12px; }
.content-title { display: flex; align-items: center; gap: 8px; }
.content-icon { width: 28px; height: 28px; border-radius: 7px; background: var(--s, var(--green-100)); color: var(--c, var(--green-700)); display: grid; place-items: center; flex: none; }
.content-icon .icon { width: 13px; height: 13px; }
.content-title > span:last-child { display: flex; flex-direction: column; gap: 1px; }
.content-title strong { font-size: 10px; font-weight: 600; }
.content-title small { font-size: 7px; color: var(--muted-2); }
.completion-cell { display: flex; align-items: center; gap: 6px; }
.completion-cell > div { width: 64px; height: 4px; border-radius: 4px; background: rgba(23, 53, 43, 0.07); overflow: hidden; }
.completion-cell i { display: block; height: 100%; background: var(--green-600); border-radius: 4px; }
.completion-cell span { font-size: 8px; color: var(--muted-2); }

/* =========================================================
   Fulfillment center
   ========================================================= */
.demo-badge { display: inline-flex; align-items: center; gap: 4px; padding: 7px 10px; border-radius: 7px; background: var(--gold-soft); color: var(--gold-deep); font-size: 9px; font-weight: 700; }
.demo-badge .icon { width: 12px; height: 12px; }
.fulfillment-alert { margin-bottom: 12px; }
.fulfill-role-links { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; padding: 9px 11px; border-radius: 8px; background: rgba(23, 53, 43, 0.035); }
.fulfill-role-links > span { font-size: 8px; color: var(--muted); margin-right: 3px; }
.fulfill-role-links a { display: inline-flex; align-items: center; gap: 3px; padding: 4px 7px; border-radius: 5px; background: var(--paper); border: 1px solid var(--line-soft); font-size: 8px; color: var(--green-700); }
.fulfill-role-links a:hover { border-color: var(--green-600); }
.fulfill-role-links .icon { width: 10px; height: 10px; }
.fulfill-stats { display: grid; grid-template-columns: repeat(5, 1fr); gap: 9px; margin-bottom: 12px; }
.fulfill-stats > div { display: flex; align-items: baseline; gap: 3px; padding: 12px 14px; border-radius: 11px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); }
.fulfill-stats span { font-size: 8px; color: var(--muted); }
.fulfill-stats strong { font-family: var(--serif); font-size: 24px; font-weight: 600; line-height: 1; margin-left: auto; }
.fulfill-stats small { font-size: 7px; color: var(--muted-2); }
.kanban-scroll { overflow-x: auto; padding-bottom: 7px; }
.fulfillment-board { display: flex; gap: 9px; min-width: max-content; align-items: flex-start; }
.fulfill-column { width: 214px; flex: none; background: rgba(255, 253, 248, 0.5); border: 1px solid rgba(23, 53, 43, 0.06); border-radius: 12px; padding: 8px; }
.fc-column-head { display: flex; align-items: center; gap: 5px; padding: 4px 3px 9px; border-bottom: 1px solid var(--line-soft); }
.fc-column-head strong { font-size: 9px; }
.fc-column-head em { margin-left: auto; font-style: normal; font-family: var(--serif); font-size: 12px; color: var(--muted-2); }
.stage-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--amber); flex: none; }
.stage-dot.pharmacy_pending { background: var(--blue); }
.stage-dot.dispense_pending { background: var(--purple); }
.stage-dot.ship_pending { background: var(--gold); }
.stage-dot.shipped, .stage-dot.notified, .stage-dot.handed_over, .stage-dot.assistant_received { background: var(--green-600); }
.fc-column-body { display: grid; gap: 7px; padding-top: 8px; }
.fc-empty { padding: 18px 8px; text-align: center; font-size: 8px; color: var(--muted-2); border: 1px dashed var(--line); border-radius: 8px; }
.fulfill-card { padding: 10px; border-radius: 9px; background: var(--paper); border: 1px solid rgba(23, 53, 43, 0.07); box-shadow: 0 2px 7px rgba(23, 53, 43, 0.025); }
.fc-top { display: flex; align-items: center; justify-content: space-between; gap: 5px; }
.fc-top .chip { font-size: 7px; }
.fulfill-card h3 { margin: 5px 0 2px; font-family: var(--serif); font-size: 14px; font-weight: 600; }
.fulfill-card h3 small { margin-left: 3px; font-family: var(--sans); font-size: 7px; color: var(--muted-2); font-weight: 400; }
.fc-plan { font-size: 8px; color: var(--muted); line-height: 1.5; }
.fc-rx, .fc-ship, .fc-handover { display: flex; align-items: flex-start; gap: 3px; margin-top: 5px; padding: 5px 6px; border-radius: 5px; background: rgba(23, 53, 43, 0.035); font-size: 7px; line-height: 1.5; color: var(--muted); }
.fc-rx .icon, .fc-ship .icon, .fc-handover .icon { width: 9px; height: 9px; flex: none; margin-top: 1px; color: var(--green-700); }
.fc-ship { background: var(--green-100); color: var(--green-700); }
.fc-ship strong { font-family: var(--serif); font-size: 9px; }
.fc-handover { background: var(--gold-soft); color: var(--gold-deep); }
.fc-wait { margin-top: 6px; padding: 4px 6px; border-radius: 4px; background: rgba(196, 154, 74, 0.08); font-size: 7px; color: var(--gold-deep); text-align: center; }
.fc-foot { display: flex; align-items: center; justify-content: space-between; gap: 5px; margin-top: 7px; padding-top: 6px; border-top: 1px solid var(--line-soft); }
.fc-foot .table-link { font-size: 7px; }
.fc-wait-role { font-size: 7px; color: var(--muted-2); text-align: right; }
.fulfill-action { display: inline-flex; align-items: center; gap: 2px; padding: 4px 7px; border-radius: 5px; background: var(--green-800); color: var(--cream); font-size: 7px; font-weight: 600; }
.fulfill-action .icon { width: 9px; height: 9px; }
.fulfill-action:hover { background: var(--green-900); }
.fulfill-legend { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 14px; font-size: 8px; color: var(--muted-2); }
.fulfill-legend span { display: inline-flex; align-items: center; gap: 3px; }
.fulfill-legend .icon { width: 10px; height: 10px; color: var(--green-700); }
.fulfill-modal h2, .order-timeline-modal h2 { margin: 4px 0 4px; font-family: var(--serif); font-size: 22px; font-weight: 600; }
.fm-lead { font-size: 9px; line-height: 1.6; color: var(--muted); }
.demo-rx { display: flex; flex-direction: column; gap: 3px; margin: 12px 0; padding: 12px; border-radius: 8px; background: var(--green-100); border: 1px dashed rgba(47, 125, 100, 0.3); }
.demo-rx span { font-size: 7px; font-weight: 700; letter-spacing: 0.06em; color: var(--green-700); }
.demo-rx strong { font-family: var(--serif); font-size: 16px; }
.demo-rx small { font-size: 8px; color: var(--muted); }
.fm-note { display: flex; gap: 5px; margin-top: 9px; padding: 8px; border-radius: 6px; background: var(--gold-soft); font-size: 8px; line-height: 1.6; color: var(--ink-2); }
.fm-note .icon { width: 11px; height: 11px; flex: none; margin-top: 1px; color: var(--gold-deep); }
.fulfill-modal .form-grid { margin-top: 10px; }
.fulfill-modal .photo-field { margin-top: 8px; }
.timeline-list { display: grid; gap: 10px; margin-top: 13px; }
.timeline-row { display: flex; gap: 8px; }
.tl-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green-600); flex: none; margin-top: 4px; box-shadow: 0 0 0 3px rgba(47, 125, 100, 0.1); }
.timeline-row > div { display: flex; flex-direction: column; gap: 1px; }
.timeline-row strong { font-size: 9px; }
.timeline-row small { font-size: 8px; color: var(--muted-2); }
.timeline-row p { margin-top: 2px; font-size: 8px; line-height: 1.5; color: var(--muted); }

/* =========================================================
   Admin modals
   ========================================================= */
.employee-modal, .session-modal, .result-modal, .question-modal, .review-modal { color: var(--ink); }
.emp-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--line-soft); }
.emp-identity { display: flex; align-items: center; gap: 12px; }
.emp-identity h2 { font-family: var(--serif); font-size: 24px; margin-top: 3px; font-weight: 600; }
.emp-identity p { margin-top: 2px; font-size: 9px; color: var(--muted); }
.emp-modal-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.emp-modal-stats div { display: flex; flex-direction: column; gap: 1px; text-align: right; }
.emp-modal-stats strong { font-family: var(--serif); font-size: 23px; font-weight: 600; line-height: 1; }
.emp-modal-stats span { font-size: 8px; color: var(--muted-2); }
.emp-permission-line { display: flex; align-items: center; gap: 6px; margin-top: 10px; padding: 8px 10px; border-radius: 7px; background: rgba(47, 125, 100, 0.055); font-size: 8px; color: var(--muted); }
.emp-permission-line > .icon { width: 12px; height: 12px; color: var(--green-700); }
.emp-permission-line span { font-weight: 700; color: var(--green-700); }
.emp-permission-line b { padding: 2px 5px; border-radius: 4px; background: var(--green-100); color: var(--green-700); font-weight: 600; }
.emp-permission-line i { display: inline-flex; align-items: center; gap: 3px; margin-left: auto; font-style: normal; color: var(--red); }
.emp-permission-line i .icon { width: 10px; height: 10px; }
.emp-modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 12px; }
.emp-chart-card, .emp-list-card { border: 1px solid var(--line-soft); border-radius: 11px; padding: 13px; background: rgba(255, 255, 255, 0.4); min-width: 0; }
.mini-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.mini-head strong { font-size: 10px; }
.mini-head span, .mini-head a { font-size: 8px; color: var(--muted-2); }
.emp-chart-card .radar-chart { max-height: 225px; margin: 0 auto; }
.emp-chart-card .trend-chart { max-height: 190px; }
.emp-mini-stats { display: flex; justify-content: space-between; gap: 8px; padding-top: 7px; border-top: 1px solid var(--line-soft); font-size: 8px; color: var(--muted-2); }
.emp-mini-stats strong { color: var(--ink); }
.emp-session-row { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; padding: 8px 0; border-bottom: 1px solid rgba(231, 223, 208, 0.55); }
.emp-session-row:last-child { border-bottom: 0; }
.emp-session-icon { width: 26px; height: 26px; border-radius: 7px; background: var(--green-100); color: var(--green-700); display: grid; place-items: center; flex: none; }
.emp-session-icon.fail { background: var(--red-soft); color: var(--red); }
.emp-session-icon .icon { width: 12px; height: 12px; }
.emp-session-row > span:nth-child(2) { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.emp-session-row strong { font-size: 9px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.emp-session-row small { font-size: 7px; color: var(--muted-2); }
.emp-session-row em { font-style: normal; font-family: var(--serif); font-size: 15px; }
.emp-session-row em.green { color: var(--green-700); }
.emp-session-row em.red { color: var(--red); }
.emp-session-row em.gold { color: var(--gold-deep); }
.emp-session-row em.blue { color: var(--blue); }
.emp-session-row em.amber { color: var(--amber); }
.emp-session-row > .icon { width: 11px; height: 11px; color: var(--muted-2); }
.emp-wrong-line { padding: 7px 0; border-top: 1px solid var(--line-soft); }
.emp-wrong-line span { font-size: 7px; color: var(--red); }
.emp-wrong-line p { margin: 2px 0; font-size: 8px; line-height: 1.5; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.emp-wrong-line em { font-style: normal; font-size: 7px; color: var(--muted-2); }
.emp-focus { display: flex; align-items: flex-start; gap: 9px; margin-top: 12px; padding: 11px; border-radius: 9px; background: var(--gold-soft); }
.emp-focus > span { display: inline-flex; align-items: center; gap: 3px; font-size: 8px; font-weight: 700; color: var(--gold-deep); flex: none; }
.emp-focus .icon { width: 10px; height: 10px; }
.emp-focus p { font-size: 8px; line-height: 1.7; color: var(--ink-2); }
.emp-focus strong { color: var(--gold-deep); }

.session-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--line-soft); }
.session-modal-head h2 { margin-top: 2px; font-family: var(--serif); font-size: 22px; font-weight: 600; }
.session-modal-head p { margin-top: 3px; font-size: 9px; color: var(--muted); }
.session-modal-score { font-family: var(--serif); font-size: 36px; font-weight: 600; color: var(--green-700); line-height: 1; }
.session-modal-score.red { color: var(--red); }
.session-modal-score.gold { color: var(--gold-deep); }
.session-modal-score small { font-family: var(--sans); font-size: 8px; color: var(--muted-2); margin-left: 2px; }
.session-modal-meta { display: flex; flex-wrap: wrap; gap: 12px; padding: 10px 0; font-size: 8px; color: var(--muted); }
.session-modal-meta span { display: inline-flex; align-items: center; gap: 3px; }
.session-modal-meta .icon { width: 10px; height: 10px; }
.session-modal-meta .pass { color: var(--green-600); }
.session-modal-meta .fail, .session-modal-meta .risk { color: var(--red); }
.session-risk-banner { display: flex; gap: 5px; padding: 8px 9px; margin-bottom: 10px; border-radius: 6px; background: var(--red-soft); color: var(--red); font-size: 8px; line-height: 1.55; }
.session-risk-banner .icon { width: 11px; height: 11px; flex: none; margin-top: 1px; }
.modal-transcript { max-height: 420px; overflow-y: auto; padding: 12px; background: var(--cream-2); border-radius: 10px; }
.modal-bubble-row { display: flex; gap: 7px; margin-bottom: 9px; }
.modal-bubble-row.me { flex-direction: row-reverse; }
.modal-bubble-avatar { width: 24px; height: 24px; border-radius: 50%; background: var(--green-100); color: var(--green-700); display: grid; place-items: center; font-size: 8px; flex: none; }
.modal-bubble-row.me .modal-bubble-avatar { background: var(--green-800); color: var(--cream); }
.modal-bubble-row > div { max-width: 76%; display: flex; flex-direction: column; gap: 2px; }
.modal-bubble-row.me > div { align-items: flex-end; }
.modal-bubble { padding: 7px 9px; border-radius: 3px 9px 9px 9px; background: var(--paper); border: 1px solid var(--line-soft); font-size: 9px; line-height: 1.6; }
.modal-bubble-row.me .modal-bubble { background: var(--green-800); border-color: var(--green-800); color: var(--cream); border-radius: 9px 3px 9px 9px; }
.modal-bubble-row small { font-size: 7px; color: var(--muted-2); }
.session-mistakes { margin-top: 11px; padding: 10px; border: 1px solid var(--line-soft); border-radius: 8px; }
.session-mistakes > strong { font-size: 9px; }
.session-mistakes p { margin-top: 5px; font-size: 8px; line-height: 1.6; color: var(--muted); }
.session-mistakes em { display: inline-block; font-style: normal; margin-right: 5px; color: var(--red); }

.result-modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--line-soft); }
.result-modal-head h2 { margin-top: 2px; font-family: var(--serif); font-size: 22px; font-weight: 600; }
.result-modal-head p { margin-top: 3px; font-size: 9px; color: var(--muted); }
.result-modal-score { font-family: var(--serif); font-size: 38px; font-weight: 600; line-height: 1; color: var(--green-700); }
.result-modal-score.fail { color: var(--red); }
.result-modal-score small { font-family: var(--sans); font-size: 8px; color: var(--muted-2); margin-left: 2px; }
.result-modal-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; padding: 10px 0; font-size: 8px; color: var(--muted); }
.review-note { display: flex; gap: 6px; padding: 9px; border-radius: 7px; background: var(--gold-soft); margin-bottom: 10px; }
.review-note .icon { width: 12px; height: 12px; color: var(--gold-deep); flex: none; margin-top: 1px; }
.review-note p { font-size: 8px; line-height: 1.6; }
.modal-wrong-list { max-height: 440px; overflow-y: auto; padding-right: 3px; }
.modal-wrong-item { padding: 11px 0; border-bottom: 1px solid var(--line-soft); }
.modal-wrong-item:last-child { border-bottom: 0; }
.mwi-head { display: flex; gap: 7px; align-items: flex-start; }
.mwi-head > span { width: 18px; height: 18px; border-radius: 50%; background: var(--red-soft); color: var(--red); display: grid; place-items: center; font-size: 7px; flex: none; }
.mwi-head strong { font-size: 9px; line-height: 1.5; }
.mwi-options { display: grid; gap: 4px; margin: 7px 0; }
.mwi-options > div { display: flex; gap: 5px; align-items: flex-start; padding: 5px 7px; border-radius: 5px; background: rgba(23, 53, 43, 0.025); font-size: 8px; line-height: 1.5; }
.mwi-options > div > span { font-family: var(--serif); color: var(--muted-2); }
.mwi-options > div.correct { background: var(--green-100); color: var(--green-700); }
.mwi-options > div.wrong { background: var(--red-soft); color: var(--red); }
.mwi-options em { margin-left: auto; }
.mwi-options em .icon { width: 10px; height: 10px; }
.mwi-explain { padding: 6px 8px; border-radius: 5px; background: var(--gold-soft); font-size: 8px; line-height: 1.6; color: var(--ink-2); }

.question-modal .qm-head { display: flex; align-items: center; gap: 8px; }
.qm-stat { font-size: 8px; color: var(--red); }
.question-modal h2 { margin: 10px 0 12px; font-family: var(--serif); font-size: 18px; line-height: 1.55; font-weight: 600; }
.qm-options { display: grid; gap: 6px; }
.qm-options > div { display: flex; align-items: center; gap: 7px; padding: 8px 9px; border-radius: 7px; background: rgba(23, 53, 43, 0.025); font-size: 9px; }
.qm-options > div > span { width: 18px; height: 18px; border-radius: 50%; background: rgba(23, 53, 43, 0.06); display: grid; place-items: center; font-size: 8px; flex: none; }
.qm-options > div.correct { background: var(--green-100); color: var(--green-700); }
.qm-options > div.correct > span { background: var(--green-600); color: #fff; }
.qm-options em { margin-left: auto; display: inline-flex; align-items: center; gap: 2px; font-style: normal; font-size: 7px; }
.qm-options em .icon { width: 10px; height: 10px; }
.qm-explain { margin-top: 10px; padding: 9px; border-radius: 7px; background: var(--gold-soft); }
.qm-explain strong { display: flex; align-items: center; gap: 3px; font-size: 8px; color: var(--gold-deep); }
.qm-explain .icon { width: 11px; height: 11px; }
.qm-explain p { margin-top: 4px; font-size: 8px; line-height: 1.7; }
.qm-users { margin-top: 10px; }
.qm-users > strong { font-size: 8px; color: var(--muted); }
.qm-users > div { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.qm-users span { padding: 2px 6px; border-radius: 999px; background: var(--red-soft); color: var(--red); font-size: 7px; }
.review-modal h2 { margin: 4px 0 3px; font-family: var(--serif); font-size: 21px; }
.review-modal > p { font-size: 9px; color: var(--muted); }
.review-summary { display: flex; gap: 14px; margin: 12px 0; padding: 9px 11px; border-radius: 7px; background: rgba(23, 53, 43, 0.03); font-size: 8px; color: var(--muted); }
.review-summary .pass { color: var(--green-600); }
.review-summary .fail { color: var(--red); }
.review-comment { display: flex; flex-direction: column; gap: 5px; font-size: 9px; font-weight: 600; }
.review-comment textarea { border: 1px solid var(--line); border-radius: 8px; padding: 9px; font-size: 10px; line-height: 1.6; background: var(--paper); outline: none; resize: vertical; }
.review-comment textarea:focus { border-color: var(--green-600); }

/* =========================================================
   Responsive admin
   ========================================================= */
@media (max-width: 1320px) {
  .kpi-grid { grid-template-columns: repeat(3, 1fr); }
  .kpi-value { font-size: 26px; }
  .employee-stage { gap: 40px; }
}
@media (max-width: 1120px) {
  .admin-sidebar { width: 214px; }
  .admin-view { padding: 24px 24px 40px; }
  .admin-topbar { padding: 0 24px; }
  .dash-lower { grid-template-columns: 1fr; }
  .wrong-admin-grid { grid-template-columns: 1fr; }
}
@media (max-width: 960px) {
  .admin-sidebar { display: none; }
  .topbar-logout { display: inline-flex; }
  .admin-mobile-brand { display: flex; }
  .topbar-context { display: none; }
  .admin-topbar { height: 58px; padding: 0 18px; }
  .admin-mobile-nav {
    display: flex; gap: 2px; overflow-x: auto; padding: 8px 14px;
    background: rgba(255, 253, 248, 0.92); border-bottom: 1px solid rgba(23, 53, 43, 0.06);
    position: sticky; top: 58px; z-index: 25; scrollbar-width: none;
  }
  .admin-mobile-nav::-webkit-scrollbar { display: none; }
  .admin-mobile-nav a { display: inline-flex; align-items: center; gap: 4px; flex: none; padding: 7px 9px; border-radius: 7px; font-size: 9px; color: var(--muted); }
  .admin-mobile-nav a .icon { width: 13px; height: 13px; }
  .admin-mobile-nav a.active { background: var(--green-100); color: var(--green-700); }
  .admin-view { padding: 20px 18px 36px; }
  .kpi-grid { grid-template-columns: repeat(3, 1fr); }
  .chart-panel, .radar-panel, .dist-panel, .attention-panel { grid-column: span 12; }
  .admin-radar svg { max-width: 330px; }
  .result-overview { grid-template-columns: repeat(2, 1fr); }
  .wrong-stat-grid { grid-template-columns: repeat(2, 1fr); }
  .fulfill-stats { grid-template-columns: repeat(3, 1fr); }
  .content-overview { grid-template-columns: 1fr; }
  .content-kpi p { margin-left: auto; }
  .emp-modal-grid { grid-template-columns: 1fr; }
  .emp-modal-head { flex-direction: column; align-items: flex-start; }
  .emp-modal-stats { width: 100%; justify-content: space-between; }
  .emp-modal-stats div { text-align: left; }
}
@media (max-width: 640px) {
  .admin-page-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .admin-page-head h1 { font-size: 25px; }
  .admin-head-actions { width: 100%; flex-wrap: wrap; }
  .admin-head-actions .select-wrap { flex: 1; }
  .admin-head-actions .btn { flex: 1; }
  .kpi-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .kpi-card { padding: 12px; }
  .kpi-value { font-size: 24px; }
  .kpi-foot { flex-direction: column; align-items: flex-start; gap: 2px; }
  .dash-grid { gap: 10px; }
  .admin-panel { padding: 14px; }
  .admin-panel-head h2 { font-size: 15px; }
  .trend-chart { min-height: 190px; }
  .filter-bar { gap: 6px; }
  .admin-search { min-width: 100%; }
  .filter-count { margin-left: 0; }
  .admin-head-actions .btn { min-height: 38px; }
  .result-overview, .wrong-stat-grid, .fulfill-stats { gap: 8px; }
  .fulfill-stats { grid-template-columns: repeat(2, 1fr); }
  .result-overview > div, .wrong-stat { padding: 12px; }
  .result-overview strong, .wrong-stat strong { font-size: 23px; }
  .wrong-admin-tabs, .content-tabs, .exam-filter-tabs { min-width: 100%; width: 100%; overflow-x: auto; }
  .exam-filter-tabs button { padding: 0 10px; font-size: 9px; }
  .wrong-admin-row { padding: 11px; gap: 8px; }
  .wrong-rank { width: 18px; font-size: 13px; }
  .wrong-admin-body strong { font-size: 9px; }
  .wrong-rate strong { font-size: 16px; }
  .modal-card { padding: 22px 16px calc(20px + var(--safe-bottom)); }
  .modal-backdrop { padding: 0; align-items: flex-end; }
  .session-modal-head, .result-modal-head { flex-direction: column; }
  .session-modal-score, .result-modal-score { align-self: flex-end; }
  .modal-transcript { max-height: 52vh; }
  .emp-modal-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
  .emp-modal-stats strong { font-size: 19px; }
  .topbar-link span { display: none; }
  .topbar-actions { gap: 7px; }
  .admin-view { padding: 18px 14px 32px; }
  .admin-mobile-nav { padding: 7px 10px; }
  .admin-panel-head { flex-wrap: wrap; }
  .chart-tabs { margin-left: auto; }
  .trend-wrap { margin: 0 -10px; }
  .dist-row { grid-template-columns: 64px 1fr 30px; }
  .dist-label span { font-size: 8px; }
  .admin-table { font-size: 9px; }
  .admin-table th, .admin-table td { padding: 8px 9px; }
  .table-user strong { font-size: 9px; }
  .content-kpi { padding: 12px; }
  .content-kpi p { display: none; }
  .session-modal-meta { gap: 7px; }
  .review-modal { padding-bottom: 10px; }
}
