/* 新途英语靶场 v2 · 双配色：B = 奶油青柠（默认），C = 暗夜深色。配色值沿用 V9。 */
:root, [data-theme="B"] {
  --bg: #f4f8e4;
  --surface: #ffffff;
  --surface-2: #e9f3be;
  --surface-muted: #eff6d4;
  --primary: #5a7800;
  --btn: #b9de07;
  --btn-text: #182204;
  --btn-border: #8eb000;
  --soft: rgba(185, 222, 7, 0.25);
  --sec-bg: #ffffff;
  --sec-text: #222d12;
  --sec-border: #b8ca84;
  --sec-hover: #f5fbe0;
  --danger: #c92a52;
  --danger-soft: #ffdbe3;
  --danger-text: #8c2a44;
  --ok: #2b6e1b;
  --border: #d3e0a8;
  --border-strong: #b5c77e;
  --t1: #161f0b;
  --t2: #283416;
  --t3: #465430;
  --t4: #687850;
  --r-lg: 20px;
  --r-md: 12px;
  --r-sm: 8px;
  --shadow: 0 6px 22px rgba(24, 34, 10, 0.055);
  color-scheme: light;
}
[data-theme="C"] {
  --bg: #212027;
  --surface: #2b2933;
  --surface-2: #25232c;
  --surface-muted: #322f3b;
  --primary: #e04a6c;
  --btn: #c4244b;
  --btn-text: #f5f5f7;
  --btn-border: #b02244;
  --soft: rgba(196, 36, 75, 0.22);
  --sec-bg: #35323e;
  --sec-text: #e2e2e6;
  --sec-border: #524d5e;
  --sec-hover: #413d4c;
  --danger: #e05c7a;
  --danger-soft: #482c38;
  --danger-text: #f0bac8;
  --ok: #6da67a;
  --border: #3d3947;
  --border-strong: #534e61;
  --t1: #e4e4e8;
  --t2: #cecdd6;
  --t3: #a6a4b3;
  --t4: #858394;
  --r-lg: 18px;
  --r-md: 11px;
  --r-sm: 8px;
  --shadow: 0 8px 24px rgba(0, 0, 0, 0.24);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--t1);
  font-family: -apple-system, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 15px;
  line-height: 1.55;
  -webkit-text-size-adjust: 100%;
  min-height: 100vh;
}
button, input, select, textarea { font: inherit; color: inherit; }
.hidden { display: none !important; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 42px; padding: 0 18px;
  border-radius: var(--r-md); border: 1.5px solid var(--btn-border);
  background: var(--btn); color: var(--btn-text);
  font-weight: 700; cursor: pointer; white-space: nowrap;
  transition: filter .15s, transform .05s;
}
.btn:hover { filter: brightness(1.04); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn.sec { background: var(--sec-bg); color: var(--sec-text); border-color: var(--sec-border); }
.btn.sec:hover { background: var(--sec-hover); filter: none; }
.btn.danger { background: var(--danger-soft); color: var(--danger-text); border-color: var(--danger); }
.btn.sm { min-height: 34px; padding: 0 12px; font-size: 13.5px; border-radius: var(--r-sm); }
.btn.block { width: 100%; }

/* ---------- 主题切换 ---------- */
.theme-switch {
  display: inline-flex; padding: 3px; gap: 2px;
  background: var(--surface-muted); border: 1px solid var(--border); border-radius: 999px;
}
.theme-switch button {
  border: 0; background: transparent; padding: 5px 12px; border-radius: 999px;
  font-size: 13px; font-weight: 700; color: var(--t3); cursor: pointer;
}
.theme-switch button[aria-pressed="true"] { background: var(--btn); color: var(--btn-text); }

/* ---------- 表单 ---------- */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: 13px; font-weight: 700; color: var(--t3); }
.input {
  width: 100%; min-height: 46px; padding: 0 14px;
  border-radius: var(--r-md); border: 1.5px solid var(--border-strong);
  background: var(--surface); color: var(--t1); font-size: 16px; /* 16px 防止 iOS 自动放大 */
}
.input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--soft); }
.msg { font-size: 13.5px; font-weight: 700; min-height: 20px; }
.msg.err { color: var(--danger); }
.msg.ok { color: var(--ok); }

/* ---------- 登录页 ---------- */
.login-wrap { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 16px 48px; }
.login-top { position: fixed; top: 14px; right: 16px; }
.login-card {
  width: 100%; max-width: 400px; background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow);
  padding: 28px 24px 24px;
}
.brand { display: flex; align-items: center; gap: 12px; margin-bottom: 6px; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px; flex: none;
  background: var(--btn); border: 1.5px solid var(--btn-border);
  display: grid; place-items: center; color: var(--btn-text); font-weight: 900; font-size: 18px;
}
.brand h1 { font-size: 21px; margin: 0; letter-spacing: .5px; }
.login-sub { color: var(--t3); font-size: 13.5px; margin: 0 0 22px; }
.login-form { display: flex; flex-direction: column; gap: 14px; }
.login-foot { margin-top: 18px; color: var(--t4); font-size: 12.5px; text-align: center; }

/* ---------- 应用外壳 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 10px 16px; background: var(--surface); border-bottom: 1px solid var(--border);
}
.topbar .brand { margin: 0; }
.topbar .brand h1 { font-size: 17px; }
.topbar .brand-mark { width: 32px; height: 32px; font-size: 15px; border-radius: 10px; }
.topbar .spacer { flex: 1; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px;
  border-radius: 999px; background: var(--surface-muted); border: 1px solid var(--border);
  font-size: 13.5px; font-weight: 700; color: var(--t2);
}
.chip .role { color: var(--primary); }
.main { max-width: 1080px; margin: 0 auto; padding: 18px 16px 48px; display: flex; flex-direction: column; gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 18px; }
.card h2 { font-size: 17px; margin: 0 0 4px; }
.card .sub { color: var(--t3); font-size: 13.5px; margin: 0 0 14px; }
.notice { background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: var(--r-md); padding: 12px 14px; color: var(--t2); font-size: 14px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 560px) { .grid-2 { grid-template-columns: 1fr; } .topbar .brand h1 { display: none; } .topbar { position: static; padding: 8px 12px; gap: 8px; } .topbar .btn.sm { min-height: 30px; padding: 0 10px; } .theme-switch button { padding: 4px 9px; } }

/* ---------- 表格（手机上转为卡片列表） ---------- */
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font-size: 12.5px; color: var(--t4); font-weight: 700; padding: 8px 10px; border-bottom: 1px solid var(--border); }
.table td { padding: 10px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.tag { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 700; background: var(--surface-muted); color: var(--t3); border: 1px solid var(--border); }
.tag.on { background: var(--soft); color: var(--primary); border-color: var(--btn-border); }
.tag.warn { background: var(--danger-soft); color: var(--danger-text); border-color: var(--danger); }
.muted { color: var(--t4); }
@media (max-width: 720px) {
  .table thead { display: none; }
  .table, .table tbody, .table tr, .table td { display: block; width: 100%; }
  .table tr { border: 1px solid var(--border); border-radius: var(--r-md); padding: 8px 4px; margin-bottom: 10px; }
  .table td { border: 0; padding: 4px 10px; }
  .table td[data-k]::before { content: attr(data-k) "："; color: var(--t4); font-size: 12.5px; }
}

/* ---------- 弹窗 ---------- */
.modal-back { position: fixed; inset: 0; background: rgba(10, 12, 6, .45); display: flex; align-items: center; justify-content: center; padding: 16px; z-index: 50; }
.modal { width: 100%; max-width: 420px; background: var(--surface); border-radius: var(--r-lg); border: 1px solid var(--border); padding: 20px; box-shadow: var(--shadow); }
.modal h3 { margin: 0 0 8px; font-size: 17px; }
.code-big { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 24px; font-weight: 800; letter-spacing: 2px; padding: 12px; text-align: center; border-radius: var(--r-md); background: var(--surface-muted); border: 1px dashed var(--border-strong); margin: 12px 0; user-select: all; }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--t1); color: var(--bg); padding: 10px 16px; border-radius: 999px; font-size: 14px; font-weight: 700; z-index: 60; max-width: calc(100% - 32px); }

/* =================== 第二阶段：学生端 =================== */
.nav-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.nav-tabs button { border: 1.5px solid var(--sec-border); background: var(--sec-bg); color: var(--sec-text); border-radius: 999px; padding: 6px 14px; font-weight: 700; font-size: 14px; cursor: pointer; }
.nav-tabs button[aria-current="true"] { background: var(--btn); color: var(--btn-text); border-color: var(--btn-border); }

.hero { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; align-items: center; }
@media (max-width: 720px) { .hero { grid-template-columns: 1fr; } }
.hero h2 { font-size: 20px; }
.streak { display: flex; align-items: baseline; gap: 6px; font-weight: 800; }
.streak .num { font-size: 34px; color: var(--primary); line-height: 1; }
.checked { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px; border-radius: 999px; font-weight: 800; font-size: 13.5px; }
.checked.yes { background: var(--soft); color: var(--primary); border: 1px solid var(--btn-border); }
.checked.no { background: var(--surface-muted); color: var(--t3); border: 1px solid var(--border); }

.bar { height: 10px; border-radius: 999px; background: var(--surface-muted); border: 1px solid var(--border); overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--btn); border-right: 1px solid var(--btn-border); transition: width .35s ease; }
.bar-row { display: flex; flex-direction: column; gap: 6px; }
.bar-row .lbl { display: flex; justify-content: space-between; font-size: 13.5px; font-weight: 700; color: var(--t2); }
.bar-row .lbl b { color: var(--t1); font-variant-numeric: tabular-nums; }

.dots7 { display: flex; gap: 6px; }
.dots7 .d { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11.5px; color: var(--t4); }
.dots7 .d span { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 800; border: 1.5px solid var(--border); background: var(--surface-muted); color: var(--t4); }
.dots7 .d.full span { background: var(--ok); border-color: var(--ok); color: #fff; }
.dots7 .d.half span { background: var(--soft); border-color: var(--btn-border); color: var(--primary); }
.dots7 .d.today span { outline: 2px solid var(--primary); outline-offset: 2px; }

.tasks { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; }
.task { display: flex; flex-direction: column; gap: 10px; }
.task .kicker { font-size: 12.5px; font-weight: 800; color: var(--t4); letter-spacing: .5px; }
.task h3 { margin: 0; font-size: 18px; }
.task .count { font-size: 28px; font-weight: 900; font-variant-numeric: tabular-nums; }
.task .count small { font-size: 15px; color: var(--t4); font-weight: 700; }
.task.done { border-color: var(--btn-border); }

/* 刷题 */
.quiz-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.quiz-top .grow { flex: 1; min-width: 160px; }
.q-meta { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.q-prompt { font-size: 18px; line-height: 1.65; margin: 4px 0 16px; word-break: break-word; }
.opts { display: flex; flex-direction: column; gap: 10px; }
.opt { display: flex; align-items: flex-start; gap: 10px; width: 100%; text-align: left; padding: 12px 14px; border-radius: var(--r-md); border: 1.5px solid var(--border-strong); background: var(--surface); color: var(--t1); cursor: pointer; font-size: 16px; line-height: 1.5; }
.opt:hover:not(:disabled) { background: var(--sec-hover); }
.opt .k { flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: var(--surface-muted); border: 1px solid var(--border); }
.opt[aria-pressed="true"] { border-color: var(--primary); box-shadow: 0 0 0 3px var(--soft); }
.opt.right { border-color: var(--ok); background: color-mix(in srgb, var(--ok) 12%, var(--surface)); }
.opt.wrong { border-color: var(--danger); background: var(--danger-soft); }
.opt:disabled { cursor: default; }
.tokens { display: flex; flex-wrap: wrap; gap: 8px; margin: 6px 0 16px; }
.tok { padding: 8px 12px; border-radius: 10px; border: 1.5px solid var(--border-strong); background: var(--surface); font-size: 17px; cursor: pointer; }
.tok[aria-pressed="true"] { border-color: var(--primary); background: var(--soft); font-weight: 800; }
.tok.right { border-color: var(--ok); background: color-mix(in srgb, var(--ok) 14%, var(--surface)); font-weight: 800; }
.tok.wrong { border-color: var(--danger); background: var(--danger-soft); }
.verdict { display: flex; align-items: center; gap: 8px; font-size: 17px; font-weight: 900; margin: 16px 0 8px; }
.verdict.ok { color: var(--ok); }
.verdict.no { color: var(--danger); }
.explain { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: var(--r-md); background: var(--surface-muted); border: 1px solid var(--border); font-size: 15px; line-height: 1.7; }
.explain .lbl { font-size: 12.5px; font-weight: 800; color: var(--t4); }
.explain u { text-decoration-color: var(--primary); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.sticky-actions { position: sticky; bottom: 0; padding: 12px 0 4px; background: linear-gradient(to top, var(--surface) 70%, transparent); }

/* 背词 */
.bands { display: flex; gap: 6px; flex-wrap: wrap; }
.bands button { border: 1.5px solid var(--sec-border); background: var(--sec-bg); color: var(--sec-text); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 700; cursor: pointer; }
.bands button[aria-pressed="true"] { background: var(--btn); color: var(--btn-text); border-color: var(--btn-border); }
.bands button:disabled { opacity: .45; cursor: not-allowed; }
.speak { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 4px 0 14px; }
.speak .big { min-height: 56px; padding: 0 22px; font-size: 17px; border-radius: 16px; }
.step-title { font-size: 14px; font-weight: 800; color: var(--t3); margin: 14px 0 8px; }
.opt .play { margin-left: auto; flex: none; border: 1px solid var(--border); background: var(--surface-muted); border-radius: 8px; padding: 2px 8px; font-size: 13px; cursor: pointer; color: var(--t2); }
.word-big { font-size: 26px; font-weight: 900; letter-spacing: .5px; }

/* 闪电测 */
.timer { font-variant-numeric: tabular-nums; font-weight: 900; font-size: 18px; padding: 4px 12px; border-radius: 999px; background: var(--surface-muted); border: 1px solid var(--border); }
.timer.low { color: var(--danger); border-color: var(--danger); background: var(--danger-soft); }
.qnav { display: flex; gap: 6px; flex-wrap: wrap; }
.qnav button { width: 34px; height: 34px; border-radius: 10px; border: 1.5px solid var(--border-strong); background: var(--surface); font-weight: 800; cursor: pointer; color: var(--t2); }
.qnav button.answered { background: var(--soft); border-color: var(--btn-border); color: var(--primary); }
.qnav button[aria-current="true"] { outline: 2px solid var(--primary); outline-offset: 1px; }
.score { font-size: 44px; font-weight: 900; line-height: 1; }

/* 荣誉墙 */
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.badge { display: flex; gap: 10px; align-items: center; padding: 10px; border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface-muted); }
.badge .ic { font-size: 22px; filter: grayscale(1); opacity: .45; }
.badge.on .ic { filter: none; opacity: 1; }
.badge.on { border-color: var(--btn-border); background: var(--soft); }
.badge .nm { font-weight: 800; font-size: 14px; }
.badge .cd { font-size: 12px; color: var(--t4); line-height: 1.4; }
details > summary { cursor: pointer; font-weight: 800; color: var(--t2); }
textarea.input { min-height: 96px; padding: 10px 14px; resize: vertical; line-height: 1.6; }
.empty { text-align: center; padding: 28px 12px; }
.empty .ic { font-size: 40px; }

/* 学生端顶部导航：桌面三列一行；手机上首页单独一行，下面两个并排 */
.stu-nav { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 8px; border-radius: var(--r-lg); background: var(--surface-2); border: 1px solid var(--border-strong); }
.stu-nav button { min-height: 46px; border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface); color: var(--t1); font-weight: 800; font-size: 15px; cursor: pointer; }
.stu-nav button[aria-current="true"] { background: var(--btn); color: var(--btn-text); border-color: var(--btn-border); }
@media (max-width: 560px) { .stu-nav { grid-template-columns: 1fr 1fr; } }

/* =================== 第三阶段：教师端 =================== */
#staffNav .nav-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; scrollbar-width: thin; }
#staffNav .nav-tabs button { flex: none; }
.lnk { color: var(--primary); font-weight: 800; text-decoration: none; }
.lnk:hover { text-decoration: underline; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.tile .kicker { font-size: 12.5px; font-weight: 800; color: var(--t4); }
.tile .big { font-size: 28px; font-weight: 900; color: var(--primary); margin: 4px 0; font-variant-numeric: tabular-nums; }
.wf-list { display: flex; flex-direction: column; gap: 10px; }
.wf-row { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 12px; border: 1px solid var(--border); border-radius: var(--r-md); background: var(--surface-muted); }
.wf-name { min-width: 220px; flex: 1; }
.dots7.mini { gap: 3px; }
.dots7.mini .d span { width: 18px; height: 18px; font-size: 10px; border-width: 1px; }
.dots7.mini .d.today span { outline-width: 1.5px; outline-offset: 1px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; align-items: end; }
.chk { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; font-weight: 700; color: var(--t2); cursor: pointer; }
.chk input { width: 18px; height: 18px; accent-color: var(--primary); }
.lbl-s { font-size: 12.5px; font-weight: 800; color: var(--t4); margin-bottom: 4px; }
.habit { border: 1px solid var(--border); border-radius: var(--r-md); padding: 12px; margin-top: 10px; background: var(--surface); }
.habit .grid-2 { margin-top: 8px; font-size: 14px; line-height: 1.6; }
.input.sm { min-height: 34px; padding: 0 8px; font-size: 13.5px; width: auto; }
select.input { padding-right: 8px; }
.lrow { display: grid; grid-template-columns: 170px 1fr 230px; gap: 10px; align-items: center; padding: 5px 0; font-size: 13.5px; }
.lname { font-weight: 700; color: var(--t2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lbar { height: 10px; background: var(--surface-muted); border-radius: 999px; border: 1px solid var(--border); overflow: hidden; }
.lbar i { display: block; height: 100%; background: var(--danger); opacity: .75; }
.lnum { color: var(--t3); font-variant-numeric: tabular-nums; }
@media (max-width: 720px) { .lrow { grid-template-columns: 1fr; gap: 3px; } }
details.dead { padding: 8px 0; border-bottom: 1px solid var(--border); }
details.dead summary { font-weight: 700; }
.words { display: flex; flex-wrap: wrap; gap: 6px; }
svg.spark { width: 100%; max-width: 420px; height: 90px; display: block; margin: 4px 0 8px; }
svg.spark polyline { fill: none; stroke: var(--primary); stroke-width: 2.5; stroke-linejoin: round; }
svg.spark circle { fill: var(--surface); stroke: var(--primary); stroke-width: 2; }
.transcript { height: 46vh; overflow-y: auto; padding: 12px; border-radius: var(--r-md); background: var(--surface-muted); border: 1px solid var(--border); font-size: 15px; line-height: 1.7; margin-bottom: 8px; }
.seg { margin-bottom: 4px; }
ol li.ans { color: var(--ok); font-weight: 800; }
ol li.chosen { color: var(--danger); font-weight: 800; }

/* ---------- Kev 老师分身 ---------- */
.kev-ask { margin-top: 12px; }
.kev-box { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; padding: 14px; border-radius: var(--r-md); border: 1px solid var(--border-strong); background: var(--surface-2); }
.kev-box .actions { margin-top: 0; align-items: center; }
.kev-list { display: flex; flex-direction: column; gap: 10px; }
.kev-list:empty { display: none; }
.kev-msg { padding: 10px 12px; border-radius: var(--r-md); border: 1px solid var(--border); background: var(--surface); }
.kev-msg.user { background: var(--surface-muted); }
.kev-msg .who { font-size: 12.5px; font-weight: 800; color: var(--t4); margin-bottom: 4px; }
.kev-msg .txt { white-space: pre-wrap; line-height: 1.75; font-size: 15px; overflow-wrap: anywhere; }
.kev-photo img { display: block; max-width: 100%; max-height: 320px; margin-top: 12px; border-radius: var(--r-md); border: 1px solid var(--border); }
.kev-log { border-top: 1px solid var(--border); padding: 10px 0; }
.kev-log .q { font-weight: 700; white-space: pre-wrap; }
.kev-log .a { white-space: pre-wrap; color: var(--t2); margin-top: 4px; font-size: 14px; line-height: 1.7; }
.paper-q { border-top: 1px solid var(--border); padding: 10px 0; display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; align-items: start; }
.paper-q .no { font-weight: 900; min-width: 2.2em; }
.paper-q .ans { color: var(--ok); font-weight: 800; }
@media print {
  .topbar, #staffNav, .no-print, .toast { display: none !important; }
  .card { box-shadow: none !important; border: none !important; }
}
.print-area { display: none; }
@media print {
  body.print-mode > *:not(.print-area) { display: none !important; }
  body.print-mode .print-area { display: block; color: #000; background: #fff; font-size: 13pt; }
  .print-area .paper-q { break-inside: avoid; border-top: 1px solid #ccc; }
  .print-area .ans { color: #000; }
}

/* =====================================================================
   v2.2 版式：照 V9 / V9_mobile 重做（颜色沿用两套配色；只改布局与样式）
   ===================================================================== */
:root, [data-theme="B"] {
  --dot-done-bg: #2b6e1b; --dot-done-text: #ffffff; --dot-done-border: #1d4f10;
  --dot-doing-bg: #d4f069; --dot-doing-text: #1b2905; --dot-doing-border: #97b818;
  --dot-miss-bg: #ffdbe3; --dot-miss-text: #8c2a44; --dot-miss-border: #f3b0c1;
  --tag-heavy: #c92a52; --tag-focal: #4e6a00; --tag-done: #2b6e1b;
  --bubble: #d44267;
}
[data-theme="C"] {
  --dot-done-bg: #3b6344; --dot-done-text: #e8f0ea; --dot-done-border: #52805c;
  --dot-doing-bg: #78946a; --dot-doing-text: #171f14; --dot-doing-border: #91ad82;
  --dot-miss-bg: #4a333c; --dot-miss-text: #dfb3c1; --dot-miss-border: #6e4c59;
  --tag-heavy: #e05c7a; --tag-focal: #e0607e; --tag-done: #6da67a;
  --bubble: #c4244b;
}
body { font-size: 16px; line-height: 1.6; }
.card { border-width: 1.5px; }
.card.alt { background: var(--surface-2); border-color: var(--border-strong); }
.btn { font-weight: 800; }
.btn:not(.sec):not(.danger) { box-shadow: 0 3px 10px var(--soft); }
.only-narrow { display: none; }
.theme-icon { width: 30px; height: 30px; border-radius: 8px; border: 1.5px solid var(--border-strong); background: var(--surface-muted); cursor: pointer; font-size: 14px; }
.lnk-btn { border: 0; background: none; padding: 0; color: var(--primary); font-weight: 800; font-size: 13px; cursor: pointer; }

/* ---------- 外壳 ---------- */
.app { min-height: 100vh; }
.app.is-staff { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 22px; max-width: 1440px; margin: 0 auto; padding: 20px 24px 60px; align-items: start; }
.app.is-staff .main { max-width: none; padding: 0; margin: 0; }
.app.is-student .main { max-width: 940px; padding-top: 20px; gap: 14px; }
.side { position: sticky; top: 20px; max-height: calc(100vh - 40px); overflow-y: auto; background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-lg); padding: 16px 12px; box-shadow: var(--shadow); }
.side[hidden] { display: none; }
.nav-brand { display: flex; flex-direction: column; gap: 9px; padding: 2px 4px 14px; margin-bottom: 8px; border-bottom: 1.5px solid var(--border); }
.nav-brand-row { display: flex; align-items: center; justify-content: center; gap: 8px; }
.nav-title { font-size: 22px; font-weight: 800; color: var(--t1); text-align: center; letter-spacing: -.01em; }
.nav-me { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 7px 10px; border: 1.5px solid var(--border-strong); border-radius: var(--r-md); font-weight: 800; font-size: 14px; color: var(--t1); }
.nav-me > span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-brand .theme-switch { justify-content: center; }
.nav-group { font-size: 13px; font-weight: 800; color: var(--t4); letter-spacing: .04em; padding: 10px 8px 6px; }
.nav-link { position: relative; width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 10px 12px; margin-bottom: 8px; border-radius: var(--r-md); background: var(--sec-bg); border: 1.5px solid var(--border); color: var(--t2); font-size: 15.5px; font-weight: 700; cursor: pointer; text-align: left; }
.nav-link:hover { border-color: var(--primary); }
.nav-link.active { background: var(--btn); color: var(--btn-text); border-color: var(--btn-border); font-weight: 800; box-shadow: 0 3px 10px var(--soft); }
.nav-stat { font-size: 12.5px; font-weight: 700; color: var(--t4); white-space: nowrap; }
.nav-link.active .nav-stat, .tree-stu.active .nav-stat { color: var(--btn-text); opacity: .85; }
.nav-bubble { position: absolute; top: -7px; right: -5px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 99px; background: var(--bubble); color: #fff; border: 1.5px solid #fff; font-size: 11.5px; font-weight: 900; display: inline-flex; align-items: center; justify-content: center; }
.nav-tree { background: var(--surface-2); border: 1.5px solid var(--border-strong); border-radius: var(--r-md); padding: 6px; margin: -2px 0 10px; max-height: 340px; overflow-y: auto; }
.nav-tree.collapsed { display: none; }
.tree-stu { width: 100%; display: flex; justify-content: space-between; align-items: center; padding: 6px 10px; margin-bottom: 2px; border-radius: var(--r-sm); border: 1px solid transparent; background: transparent; color: var(--t2); font-size: 14.5px; font-weight: 600; cursor: pointer; }
.tree-stu:hover { background: var(--sec-bg); border-color: var(--border-strong); }
.tree-stu.active { background: var(--btn); color: var(--btn-text); font-weight: 800; }

/* ---------- 学生端抬头与入口 ---------- */
.stu-head { background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 14px 18px; display: flex; flex-direction: column; gap: 10px; }
.stu-head-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 10px; }
.stu-head-side { display: flex; align-items: center; gap: 8px; }
.stu-head-side.right { justify-content: flex-end; }
.stu-head-title { font-size: 26px; font-weight: 800; color: var(--t1); white-space: nowrap; letter-spacing: -.01em; }
.stu-name { font-weight: 800; color: var(--t1); white-space: nowrap; }
.stu-head-tools { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; padding-top: 8px; border-top: 1px dashed var(--border); }
.stu-tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; padding: 8px; background: var(--surface-2); border: 1.5px solid var(--border-strong); border-radius: var(--r-md); }
.stu-tab { padding: 12px 14px; border-radius: var(--r-sm); border: 1.5px solid transparent; background: var(--sec-bg); color: var(--t2); font-size: 17px; font-weight: 800; cursor: pointer; }
.stu-tab.active { background: var(--btn); color: var(--btn-text); border-color: rgba(0,0,0,.1); box-shadow: 0 3px 10px var(--soft); }
.stu-nav { display: none; }

/* 打卡圆点条 */
.strip { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; padding: 14px 18px; }
.strip-text { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 14px; font-size: 14px; }
.date-dots { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding-top: 12px; }
.date-dots.mini { gap: 5px; padding-top: 0; }
.date-col { position: relative; display: inline-flex; }
.date-arrow { position: absolute; top: -15px; left: 50%; transform: translateX(-50%); font-size: 11px; font-style: normal; color: var(--primary); line-height: 1; }
.date-circle { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 15px; font-weight: 800; border: 2px solid var(--border); background: var(--surface-muted); color: var(--t4); }
.date-dots.mini .date-circle { width: 28px; height: 28px; font-size: 12.5px; border-width: 1.5px; }
.date-circle.done { background: var(--dot-done-bg); color: var(--dot-done-text); border-color: var(--dot-done-border); }
.date-circle.doing { background: var(--dot-doing-bg); color: var(--dot-doing-text); border-color: var(--dot-doing-border); }
.date-circle.miss { background: var(--dot-miss-bg); color: var(--dot-miss-text); border-color: var(--dot-miss-border); }
.date-col.is-today .date-circle { box-shadow: 0 0 0 3px var(--soft); }

/* 小标签：● 文字 */
.info-tag { display: inline-flex; align-items: center; gap: 5px; font-size: 14.5px; font-weight: 800; white-space: nowrap; }
.info-tag::before { content: "●"; font-size: 11px; }
.info-tag.heavy { color: var(--tag-heavy); }
.info-tag.focal { color: var(--tag-focal); }
.info-tag.done { color: var(--tag-done); }
.info-tag.neutral { color: var(--t3); font-weight: 700; }
.info-tag.neutral::before { content: "｜"; color: var(--t4); }

/* 首页任务卡 */
.grid-tasks { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.task-big, .task-small { display: flex; flex-direction: column; text-align: center; gap: 10px; }
.task-big { padding: 22px 24px; }
.kicker-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 13.5px; }
.task-title { font-size: 26px; font-weight: 800; color: var(--t1); line-height: 1.3; }
.task-title.sm { font-size: 20px; }
.task-num { font-size: 36px; font-weight: 800; color: var(--primary); letter-spacing: -.03em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.task-big .btn { min-height: 48px; font-size: 16.5px; margin-top: 4px; }
.task-big.done .task-num { color: var(--tag-done); }
.grid-small { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; align-items: stretch; }
.grid-small.n1 { grid-template-columns: 1fr; }
.grid-small.n2 { grid-template-columns: 1fr 1fr; }
.task-small { justify-content: space-between; padding: 18px 16px; }

/* ---------- 教师端 ---------- */
.h-l2 { font-size: 22px !important; font-weight: 800; color: var(--t1); }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-bottom: 12px; margin-bottom: 16px; border-bottom: 1.5px solid var(--border); }
.card-head .sub { margin: 2px 0 0; }
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; }
.kpi { background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 20px 18px; text-align: center; }
.kpi:nth-child(even) { background: var(--surface-2); border-color: var(--border-strong); }
.kpi.click { cursor: pointer; }
.kpi.click:hover { border-color: var(--primary); }
.kpi-label { font-size: 14.5px; color: var(--t4); font-weight: 600; }
.kpi-big { font-size: 36px; font-weight: 800; color: var(--primary); letter-spacing: -.03em; line-height: 1.25; margin: 4px 0; font-variant-numeric: tabular-nums; }
.kpi-big.warn { color: var(--tag-heavy); }
.kpi-sub { font-size: 14.5px; color: var(--t2); line-height: 1.5; }
.wf-list { gap: 14px; }
.wf-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 18px 20px; border-radius: var(--r-md); border: 1.5px solid var(--border); background: var(--surface); }
.wf-row.alt { background: var(--surface-2); border-color: var(--border-strong); }
.wf-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-bottom: 6px; }
.wf-name { font-size: 21px; font-weight: 800; color: var(--t1); text-decoration: none; }
.wf-name:hover { color: var(--primary); }
.wf-meta { font-size: 14.5px; color: var(--t2); line-height: 1.6; }
.wf-actions { display: flex; gap: 8px; padding-left: 16px; border-left: 1.5px dashed var(--border-strong); }
.wf-actions .btn { min-height: 44px; }
.table-wrap { width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--r-md); }
.table-clean { width: 100%; min-width: 620px; border-collapse: collapse; font-size: 15px; }
.table-clean th { text-align: center; padding: 12px; font-size: 14px; font-weight: 800; color: var(--t3); background: var(--surface-muted); border-bottom: 1.5px solid var(--border-strong); white-space: nowrap; }
.table-clean td { text-align: center; padding: 12px; border-bottom: 1px solid var(--border); white-space: nowrap; vertical-align: middle; }
.chip-well { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; padding: 12px; border-radius: var(--r-md); background: var(--surface-2); border: 1.5px solid var(--border-strong); }
.chip-btn { padding: 9px 12px; border-radius: var(--r-md); border: 1.5px solid var(--sec-border); background: var(--sec-bg); color: var(--t1); font-weight: 800; font-size: 14.5px; cursor: pointer; }
.chip-btn:hover { border-color: var(--primary); }
.foot-row { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: 12px; font-size: 14px; color: var(--t4); }
.foot-row strong { color: var(--t2); }

/* ---------- 手机（照 V9_mobile） ---------- */
@media (max-width: 860px) {
  .only-wide { display: none !important; }
  .only-narrow { display: inline-flex; }
  .only-wide-inline { display: none; }
  .app.is-staff { display: block; padding: 10px 12px 40px; }
  .app.is-staff .main { margin-top: 12px; }
  .side { position: static; max-height: none; padding: 10px; }
  .nav-brand { padding: 0 0 10px; margin-bottom: 8px; }
  .nav-brand-row { justify-content: space-between; }
  .nav-title { font-size: 18px; flex: 1; }
  .nav-me { font-size: 13px; padding: 5px 10px; }
  .nav-group, .nav-tree { display: none; }
  .nav-links { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
  .nav-link { margin: 0; padding: 9px 4px; justify-content: center; font-size: 13.5px; text-align: center; }
  .nav-link .nav-stat { display: none; }
  .app.is-student .main { padding: 10px 12px 32px; gap: 12px; }
  .stu-head { padding: 10px 12px; border-radius: 14px; }
  .stu-head-row { grid-template-columns: auto 1fr auto; gap: 6px; }
  .stu-head-title { font-size: 18.5px; text-align: center; }
  .stu-name { font-size: 14px; }
  .stu-head-tools { padding-top: 6px; gap: 6px; }
  .stu-head-tools .btn.sm { min-height: 30px; padding: 0 9px; font-size: 12.5px; }
  .stu-tabs { grid-template-columns: 1fr 1fr; gap: 8px; padding: 6px; border-radius: 12px; }
  .stu-tabs .stu-tab:first-child { grid-column: 1 / -1; }
  .stu-tab { font-size: 14.5px; padding: 10px 4px; }
  .date-dots { gap: 6px; }
  .date-circle { width: 32px; height: 32px; font-size: 14px; }
  .grid-tasks, .grid-small, .grid-small.n2 { grid-template-columns: 1fr; gap: 12px; }
  .task-big { padding: 16px 14px; }
  .task-title { font-size: 21px; }
  .task-num { font-size: 30px; }
  .task-title.sm { font-size: 18px; }
  .kpi-grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .kpi { padding: 10px; }
  .kpi-label { font-size: 12px; }
  .kpi-big { font-size: 22px; }
  .kpi-sub { font-size: 11.5px; }
  .h-l2 { font-size: 17px !important; }
  .wf-row { grid-template-columns: 1fr; padding: 12px; gap: 10px; }
  .wf-name { font-size: 17px; }
  .wf-meta { font-size: 12.5px; }
  .wf-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; padding: 0; border: 0; }
  .wf-actions .btn { min-height: 38px; padding: 0 2px; font-size: 12.5px; white-space: normal; line-height: 1.2; }
  .table-clean { font-size: 13.5px; min-width: 520px; }
  .table-clean th, .table-clean td { padding: 9px 8px; }
  .chip-well { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
  .chip-btn { font-size: 13px; padding: 7px 6px; }
}
.grid-2 .date-dots.mini, td .date-dots.mini { display: flex; margin-top: 6px; }
.grid-2 .date-dots.mini { justify-content: flex-start; }
td .date-dots.mini { justify-content: center; margin-top: 0; }

/* ---------- v2.2.1：工作流行（按钮在下、右侧语法死穴）、打卡一览、常驻录音条 ---------- */
.wf-row { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); align-items: stretch; }
.wf-actions { padding: 0; border: 0; margin-top: 12px; flex-wrap: wrap; }
.wf-dead { padding-left: 16px; border-left: 1.5px dashed var(--border-strong); display: flex; flex-direction: column; gap: 6px; justify-content: center; }
.wf-dead-item { display: flex; align-items: baseline; gap: 8px; font-size: 14px; line-height: 1.45; }
.wf-dead-item .t { flex: 1; min-width: 0; color: var(--t1); font-weight: 700; }
.wf-dead-item .tag { flex: none; }
.wf-dead-item .muted { flex: none; white-space: nowrap; }
.chip-btn.done { background: var(--dot-done-bg); color: var(--dot-done-text); border-color: var(--dot-done-border); }
.chip-btn.doing { background: var(--dot-doing-bg); color: var(--dot-doing-text); border-color: var(--dot-doing-border); }
.chip-btn.mini { padding: 1px 8px; font-size: 12px; cursor: default; }
.legend { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.rec-bar { position: fixed; left: 50%; bottom: 12px; transform: translateX(-50%); z-index: 40; width: min(980px, calc(100% - 24px)); background: var(--surface); border: 2px solid var(--danger); border-radius: var(--r-lg); box-shadow: 0 12px 32px rgba(0, 0, 0, .22); padding: 10px 14px; }
.rec-bar[hidden] { display: none; }
.rec-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rec-head .grow { flex: 1; }
.rec-head .timer { font-size: 15px; padding: 2px 10px; }
.rec-dot { width: 12px; height: 12px; border-radius: 50%; background: #e0263f; animation: recblink 1.2s infinite; flex: none; }
@keyframes recblink { 50% { opacity: .25; } }
.rec-stop { width: 44px; height: 44px; border-radius: 50%; border: 0; background: #e0263f; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 3px 10px rgba(224, 38, 63, .4); flex: none; }
.rec-stop i { width: 15px; height: 15px; border-radius: 3px; background: #fff; display: block; }
.rec-stop:disabled { background: var(--surface-muted); box-shadow: none; cursor: not-allowed; }
.rec-stop:disabled i { background: var(--t4); }
.rec-lines { margin-top: 8px; max-height: 150px; overflow-y: auto; font-size: 14.5px; line-height: 1.6; padding: 8px 10px; border-radius: var(--r-md); background: var(--surface-muted); }
.rec-err { margin-top: 6px; font-size: 13px; color: var(--danger); font-weight: 700; }
body.has-rec-bar .main { padding-bottom: 240px; }
@media (max-width: 860px) {
  .wf-row { grid-template-columns: 1fr; }
  .wf-dead { padding: 10px 0 0; border-left: 0; border-top: 1.5px dashed var(--border-strong); }
  .wf-actions { display: grid; grid-template-columns: repeat(3, 1fr); }
  .rec-bar { bottom: 6px; padding: 8px 10px; }
  .rec-head .btn.sm { min-height: 30px; padding: 0 8px; font-size: 12px; }
  .rec-lines { max-height: 110px; font-size: 13.5px; }
}
@media (min-width: 861px) { .rec-bar { left: auto; right: 24px; transform: none; width: min(860px, calc(100% - 320px)); } }
.tip { position: relative; display: inline-flex; margin-left: 6px; vertical-align: middle; }
.info-tip { width: 20px; height: 20px; border-radius: 50%; background: var(--surface-muted); border: 1.5px solid var(--border-strong); color: var(--t3); font: 800 12px/1 serif; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; padding: 0; }
.tip-pop { display: none; position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); width: max-content; max-width: min(280px, 80vw); background: var(--surface); color: var(--t1); border: 1.5px solid var(--btn-border); border-radius: 10px; padding: 10px 12px; font-size: 13.5px; font-weight: 600; line-height: 1.55; text-align: left; box-shadow: 0 8px 24px rgba(0,0,0,.18); z-index: 30; }
.tip:hover .tip-pop, .tip.show .tip-pop { display: block; }
.st-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 14.5px; }
.kv dt { color: var(--t4); font-weight: 700; }
.kv dd { margin: 0; color: var(--t1); font-weight: 700; overflow-wrap: anywhere; }
.ok-dot { color: var(--tag-done); font-weight: 800; }
.bad-dot { color: var(--tag-heavy); font-weight: 800; }

/* ---------- v2.2.3：弹性折叠、分组名单、学生课程管理、隐藏滚动条 ---------- */
.fold { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .42s cubic-bezier(.34, 1.36, .64, 1); }
.fold.open { grid-template-rows: 1fr; }
.fold > .fold-in { overflow: hidden; min-height: 0; opacity: 0; transform: translateY(-6px) scale(.97); transform-origin: top center; transition: opacity .25s ease, transform .42s cubic-bezier(.34, 1.56, .64, 1); }
.fold.open > .fold-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .fold, .fold > .fold-in { transition: none; } }
.nav-tree { background: transparent; border: 0; padding: 0; margin: -2px 0 10px; max-height: none; overflow: visible; }
.nav-tree > .fold-in { background: var(--surface-2); border: 1.5px solid var(--border-strong); border-radius: var(--r-md); }
.nav-tree.open > .fold-in { padding: 6px; }
.tree-group { width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 6px; padding: 7px 9px; margin: 4px 0 2px; border-radius: var(--r-sm); border: 1px solid var(--border); background: var(--sec-bg); color: var(--t1); font-weight: 800; font-size: 14px; cursor: pointer; text-align: left; }
.tree-group:first-child { margin-top: 0; }
.tree-group[aria-expanded="true"] .nav-stat, .tree-group .nav-stat { transition: transform .2s; }
.tree-group.big { font-size: 16px; padding: 10px 14px; margin: 10px 0 6px; border-width: 1.5px; }
.nav-tree-groups .fold-in { padding-left: 6px; border-left: 2px solid var(--border-strong); margin-left: 4px; }
.co { color: var(--primary); font-weight: 800; font-size: 11px; }
.name-btns { display: flex; flex-wrap: wrap; gap: 8px; padding: 6px 2px 10px; }
.name-btn { padding: 8px 14px; border-radius: var(--r-md); border: 1.5px solid var(--sec-border); background: var(--sec-bg); color: var(--t1); font-weight: 800; font-size: 15px; cursor: pointer; transition: transform .15s, background .15s; }
.name-btn:hover { border-color: var(--primary); transform: translateY(-1px); }
.name-btn.active { background: var(--btn); color: var(--btn-text); border-color: var(--btn-border); box-shadow: 0 3px 10px var(--soft); }
.course-group > .fold:last-child > .fold-in { }
.course-group > .fold:last-child.open > .fold-in { padding: 4px 2px 14px; }
.course-form { padding: 16px; border-radius: var(--r-md); border: 1.5px solid var(--border-strong); background: var(--surface-2); }
.pick-list { max-height: 60vh; overflow-y: auto; }
.only-narrow-inline { display: none; }
.diag-tools:has(> :only-child) { display: none; }
/* 侧栏与名单不显示滚动条（仍可滚动） */
.side, .nav-tree, .pick-list { scrollbar-width: none; -ms-overflow-style: none; }
.side::-webkit-scrollbar, .nav-tree::-webkit-scrollbar, .pick-list::-webkit-scrollbar { display: none; }
@media (max-width: 860px) { .only-narrow-inline { display: inline-flex; } }
@media (max-width: 860px) { .side .nav-tree { display: none; } }

/* ---------- v2.3：工作流行左右比例、侧栏间距、果冻展开、文件选择 ---------- */
.wf-row { grid-template-columns: minmax(260px, .8fr) minmax(0, 1.3fr); }
.wf-dead { justify-content: flex-start; }
/* 侧栏：收起时不留空隙，展开时才有下边距 */
.nav-tree { margin: 0; }
.nav-tree.open { margin: -2px 0 8px; }
.nav-tree:not(.open) > .fold-in { border-width: 0; }
/* 果冻效果：展开时内容先被"拉长"再回弹两下 */
.fold { transition: grid-template-rows .32s cubic-bezier(.2, .9, .3, 1); }
.fold > .fold-in { transition: opacity .18s ease; transform: none; }
.fold.open.anim > .fold-in { animation: jelly .62s cubic-bezier(.2, .8, .3, 1) both; transform-origin: top center; }
@keyframes jelly {
  0%   { transform: scaleY(.6); opacity: 0; }
  40%  { transform: scaleY(1.035); opacity: 1; }
  65%  { transform: scaleY(.99); }
  100% { transform: scaleY(1); }
}
/* 侧栏展开让页面变长时，滚动条出现会把整页往左挤一下（看起来像抖动）：提前给滚动条留好位置 */
html { scrollbar-gutter: stable; }
@media (prefers-reduced-motion: reduce) { .fold.open.anim > .fold-in { animation: none; } }
.file-hidden { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.drop-zone { position: relative; display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 18px; border: 2px dashed var(--border-strong); border-radius: var(--r-md); background: var(--surface-muted); cursor: pointer; transition: border-color .15s, background .15s; }
.drop-zone:hover, .drop-zone.over { border-color: var(--primary); background: var(--soft); }

/* ---------- v2.3：解析先给一句话秒杀，完整解析折叠 ---------- */
.tip-line { display: flex; gap: 10px; align-items: flex-start; font-weight: 600; color: var(--t1); }
.tip-line .tip-ico { flex: none; font-size: 18px; line-height: 1.5; }
.explain-more > summary { font-size: 13.5px; color: var(--primary); list-style: none; }
.explain-more > summary::-webkit-details-marker { display: none; }
.explain-more > summary::before { content: "▸ "; display: inline-block; transition: transform .2s; }
.explain-more[open] > summary::before { transform: rotate(90deg); }
.explain-body { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }

/* ---------- v2.3：单生诊断台分页 ---------- */
.diag-head { position: sticky; top: 0; z-index: 5; padding-bottom: 0; }
.diag-head .diag-tools { margin-bottom: 12px; }
.diag-tabs { display: flex; gap: 4px; border-top: 1px solid var(--border); margin: 0 -18px; padding: 0 12px; overflow-x: auto; scrollbar-width: none; }
.diag-tabs::-webkit-scrollbar { display: none; }
.diag-tab { appearance: none; border: 0; background: none; padding: 12px 14px 11px; font: inherit; font-weight: 700; color: var(--t3); border-bottom: 3px solid transparent; cursor: pointer; white-space: nowrap; }
.diag-tab:hover { color: var(--t1); }
.diag-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.diag-body { display: flex; flex-direction: column; gap: inherit; }
.diag-body > .card { animation: paneIn .22s ease both; }
@keyframes paneIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .diag-body > .card { animation: none; } }

/* ---------- v2.3：家长速览（屏幕上是一张 A4 纸，打印时只打这张纸） ---------- */
.parent-sheet { background: #fff; color: #1d1d1f; max-width: 760px; width: 100%; margin: 0 auto; padding: 32px 36px; border-radius: 6px; box-shadow: 0 1px 3px rgba(0,0,0,.08), 0 8px 24px rgba(0,0,0,.06); font-size: 14px; line-height: 1.65; box-sizing: border-box; }
.parent-sheet h2 { margin: 2px 0 0; font-size: 22px; color: #1d1d1f; }
.parent-sheet h3 { margin: 0 0 8px; font-size: 14px; color: #2b6e1b; letter-spacing: .02em; }
.ps-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; padding-bottom: 14px; border-bottom: 2px solid #2b6e1b; flex-wrap: wrap; }
.ps-brand { font-size: 12px; color: #6e6e73; font-weight: 700; }
.ps-meta { font-size: 12.5px; color: #6e6e73; text-align: right; }
.ps-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 18px 0 6px; }
.ps-kpi { border: 1px solid #e3e3e6; border-radius: 6px; padding: 10px 12px; }
.ps-kpi-l { font-size: 12px; color: #6e6e73; }
.ps-kpi-b { font-size: 18px; font-weight: 800; margin: 2px 0; font-variant-numeric: tabular-nums; }
.ps-kpi-s { font-size: 11.5px; color: #6e6e73; }
.ps-sec { margin-top: 16px; break-inside: avoid; }
.ps-sec ul { margin: 0; padding-left: 20px; }
.ps-days { display: flex; flex-wrap: wrap; gap: 4px; }
.ps-day { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; font-size: 11px; font-variant-numeric: tabular-nums; border: 1px solid #d2d2d7; color: #6e6e73; background: #fff; vertical-align: middle; }
.ps-day.full { background: #2b6e1b; border-color: #2b6e1b; color: #fff; }
.ps-day.half { background: #d4f069; border-color: #97b818; color: #1b2905; }
i.ps-day { width: 12px; height: 12px; margin: 0 4px 0 0; }
.ps-legend { margin: 8px 0 0; font-size: 12px; color: #6e6e73; }
.ps-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ps-table th, .ps-table td { text-align: left; padding: 5px 8px; border-bottom: 1px solid #ececf0; }
.ps-table th { font-size: 12px; color: #6e6e73; font-weight: 700; }
.ps-table td:first-child, .ps-table td:last-child { white-space: nowrap; }
.ps-words { white-space: pre-wrap; margin: 0; padding: 10px 12px; background: #f6f8f2; border-left: 3px solid #2b6e1b; border-radius: 4px; }
.ps-foot { margin-top: 20px; padding-top: 10px; border-top: 1px solid #ececf0; font-size: 11.5px; color: #8e8e93; }
@media (max-width: 640px) {
  .parent-sheet { padding: 20px 16px; }
  .ps-kpis { grid-template-columns: repeat(2, 1fr); }
  .ps-meta { text-align: left; }
}
@media print {
  @page { size: A4; margin: 12mm; }
  body.print-mode .print-parent { font-size: 11pt; }
  .print-parent .parent-sheet { box-shadow: none; max-width: none; padding: 0; border-radius: 0; }
  .print-parent .ps-day, .print-parent .ps-kpi, .print-parent .ps-words { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ---------- v2.3：云端督导报告收件箱 ---------- */
.drive-inbox { border: 1.5px solid var(--primary); border-radius: var(--r-md); padding: 12px 14px; margin-bottom: 14px; background: var(--soft); display: flex; flex-direction: column; gap: 10px; }
.drive-inbox-h { font-weight: 800; }
.drive-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-md); padding: 10px 12px; }
.drive-changes { margin: 6px 0 0; padding-left: 20px; }
.drive-recent { margin-bottom: 12px; }
.drive-recent ul { margin: 6px 0 0; padding-left: 20px; font-size: 13.5px; color: var(--t3); }
.ps-lessons { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px 18px; }
.ps-lesson { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; border-bottom: 1px solid #ececf0; font-size: 13px; }
.ps-lesson b { font-variant-numeric: tabular-nums; }
@media (max-width: 640px) { .ps-lessons { grid-template-columns: 1fr; } }
@media print {
  body.print-mode { background: #fff !important; }
  .print-parent .ps-sec { margin-top: 11px; }
  .print-parent .ps-kpis { margin-top: 12px; }
  .print-parent .parent-sheet { font-size: 10.5pt; line-height: 1.5; }
}
@media print {
  .print-parent .ps-foot { margin-top: 10px; padding-top: 6px; }
  .print-parent .ps-head { padding-bottom: 10px; }
  .print-parent .ps-day { width: 22px; height: 22px; }
}
@media print {
  @page { size: A4; margin: 10mm 12mm; }
  .print-parent i.ps-day { width: 10px; height: 10px; }
  .print-parent .ps-table th, .print-parent .ps-table td { padding: 3px 8px; }
  .print-parent .ps-lesson { padding: 2px 0; }
}

/* ---------- v2.3.1：申诉 / 意见箱按状态分组，已处理默认收起 ---------- */
.grp-h { font-weight: 800; color: var(--t2); margin: 4px 2px -4px; }
.grp-toggle { appearance: none; display: flex; justify-content: space-between; align-items: center; width: 100%; padding: 12px 16px; border: 1.5px dashed var(--border-strong); border-radius: var(--r-md); background: var(--surface-muted); font: inherit; font-weight: 800; color: var(--t2); cursor: pointer; }
.grp-toggle:hover { border-color: var(--primary); }
.grp-toggle[aria-expanded="true"] { border-style: solid; }
.fold > .fold-in > .card + .card { margin-top: 16px; }
.fold > .fold-in > .habit + .habit { margin-top: 0; }
.drive-older { margin-top: 6px; font-size: 13.5px; }
.drive-older summary { font-weight: 600; color: var(--t3); }
.drive-older ul { margin: 4px 0 0; padding-left: 20px; color: var(--t3); }

/* ---------- v2.3.4：工作流行——左栏按按钮宽度收紧，打卡状态与按钮右缘对齐，中线贴着按钮 ---------- */
.wf-row { grid-template-columns: fit-content(460px) minmax(0, 1fr); column-gap: 22px; }
.wf-info { min-width: 0; }
.wf-title { justify-content: space-between; align-items: center; flex-wrap: nowrap; }
.wf-title .info-tag { flex: none; }
.wf-sup { color: var(--t3); font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
@media (max-width: 860px) {
  .wf-row { grid-template-columns: 1fr; }
  .wf-sup { white-space: normal; }
}
.sup-row { margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--border-strong); }
.sup-embed { margin-top: 12px; display: flex; flex-direction: column; gap: 10px; }
.drive-unknown { border: 1.5px dashed var(--border-strong); border-radius: var(--r-md); padding: 12px 14px; margin-bottom: 14px; display: flex; flex-direction: column; gap: 10px; }
.drive-create { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); }
.copy-box { white-space: pre-wrap; background: var(--surface-muted); border: 1px solid var(--border); border-radius: var(--r-md); padding: 12px; font-size: 14px; margin: 8px 0; user-select: all; }
[hidden] { display: none !important; }

/* ---------- v2.3.5：课程管理里的停课/毕业、最新督导摘要 ---------- */
.course-status { gap: 6px; }
.sup-brief { padding: 10px 12px; border-left: 3px solid var(--primary); background: var(--surface); border-radius: 6px; font-size: 14px; line-height: 1.6; }
.sup-brief .muted { font-size: 13px; }

/* ===== v2.4.0：录音回收站、AI 转写状态 ===== */
button.lnk { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.danger-lnk { color: var(--danger-text) !important; margin-left: 8px; }
.rec-list li { margin-bottom: 6px; line-height: 1.7; }
.rec-recycle { margin-top: 10px; }
.rec-recycle summary { cursor: pointer; font-size: 13px; }
.rec-bin ul { margin: 6px 0 0; }
.ai-line { margin: 6px 0; padding: 8px 10px; border-radius: 10px; background: var(--soft); font-size: 14px; line-height: 1.6; }
.ai-line .muted { font-size: 13px; }
.ai-line details summary { cursor: pointer; font-size: 13px; }

/* ===== v2.4.0：手机端教师导航精简为 4 个常用入口 +「更多」 ===== */
.nav-more { display: none; }
@media (max-width: 860px) {
  /* 15 列：常用 4 个 +「更多」各占 3 列（一行 5 个）；展开后其余入口各占 5 列（一行 3 个，字不挤） */
  .nav-links { grid-template-columns: repeat(15, 1fr); }
  .nav-link.nav-pri { order: 0; grid-column: span 3; }
  .nav-link.nav-more { display: flex; order: 1; grid-column: span 3; }
  .nav-link.nav-sec { display: none; order: 2; grid-column: span 5; }
  .side.more-open .nav-link.nav-sec { display: flex; }
  .side.more-open .nav-more .nav-bubble { display: none; }
  .nav-link { padding: 10px 2px; font-size: 13.5px; }
  .nav-link .nav-bubble { top: -6px; right: -4px; }
}
@media (max-width: 400px) { .nav-link { font-size: 12.5px; } }

/* ===== v2.4.3：服务器状态页卡片改成上下排列（三栏太挤，字被折成好几行） ===== */
.st-grid { grid-template-columns: 1fr; }
.st-grid .kv { grid-template-columns: minmax(150px, 220px) 1fr; }
.file-desc { text-align: left; font-weight: 700; }
.file-name { font-size: 12.5px; text-align: left; }
@media (max-width: 560px) { .st-grid .kv { grid-template-columns: 105px 1fr; } }
/* 闪电测错题：显示原题和选项 */
.lt-wrong { display: grid; gap: 10px; margin: 8px 0 4px; }
.lt-item { padding: 10px 12px; border: 1.5px solid var(--border); border-radius: 12px; background: var(--surface); }
.lt-head { margin-bottom: 4px; }
.lt-prompt { margin: 4px 0 6px; line-height: 1.7; }
.lt-opts { margin: 0; padding-left: 22px; line-height: 1.8; }
.lt-opts li.right { color: var(--ok-text, #2e7d32); font-weight: 800; }
.lt-opts li.wrong { color: var(--danger-text); text-decoration: line-through; }
.yd-fold { margin-top: 14px; }
.yd-fold > summary { cursor: pointer; font-weight: 800; color: var(--t2); }
/* 学生搜索（姓名 / 拼音首字母联想） */
.stu-search { position: relative; flex: 1 1 220px; max-width: 320px; }
.stu-search.in-tree { max-width: none; margin: 0 0 8px; }
.stu-search-in { width: 100%; }
.stu-suggest { position: absolute; z-index: 40; left: 0; right: 0; top: calc(100% + 4px); background: var(--surface); border: 1.5px solid var(--border);
  border-radius: 12px; box-shadow: var(--shadow); padding: 4px; max-height: 320px; overflow-y: auto; }
.stu-sug { display: flex; justify-content: space-between; gap: 10px; width: 100%; padding: 8px 10px; border: 0; background: none; border-radius: 8px;
  font: inherit; font-weight: 700; color: var(--t1); cursor: pointer; text-align: left; }
.stu-sug .muted { font-size: 12.5px; font-weight: 500; }
.stu-sug.on, .stu-sug:hover { background: var(--soft); }
.stu-sug-none { padding: 8px 10px; }
.stu-search.in-tree .stu-suggest { position: static; box-shadow: none; margin-top: 4px; }
/* 学生端：今日目标完成提示条 */
.done-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-radius: 14px;
  border: 1.5px solid var(--ok, #4caf50); background: var(--soft); }
.done-bar[hidden] { display: none; }
.done-bar .done-sub { display: block; font-size: 13px; color: var(--t3, inherit); margin-top: 2px; font-weight: 500; }
.stu-search-in { box-sizing: border-box; min-width: 0; } .stu-search.in-tree { width: 100%; box-sizing: border-box; padding-right: 2px; }
.stu-search .input.stu-search-in { width: 100%; }
/* 成绩走势：带分数标签 */
svg.spark.spark-lab { height: auto; aspect-ratio: 340 / 132; max-width: 460px; margin: 4px 0 2px; overflow: visible; }
svg.spark-lab .grid { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 3; }
svg.spark-lab .axis { fill: var(--t4); font-size: 9px; }
svg.spark-lab .val { fill: var(--t1); font-size: 11px; font-weight: 800; }
.spark-note { font-size: 12px; margin-bottom: 8px; }
.acc-search { width: 100%; max-width: 520px; margin: 8px 0 4px; box-sizing: border-box; } tr[hidden] { display: none; }
.chip-well .well-sub { grid-column: 1 / -1; border-top: 1px dashed var(--border-strong); padding-top: 8px; }
.chip-well .well-sub-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin-top: 6px; }
@media (max-width: 860px) { .chip-well .well-sub-row { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); } }
.chip-btn.exempt { opacity: .75; }

/* ===== v2.4.8：状态 ≠ 按钮。状态 = 带小圆点的文字（进行中的换成转圈）；能点的一律是按钮 ===== */
.state { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 700; white-space: nowrap; vertical-align: middle; }
.state::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
.state.ok { color: var(--ok); }
.state.warn { color: var(--danger-text); }
.state.info { color: var(--primary); }
.state.muted { color: var(--t4); }
.state.busy::before { width: 11px; height: 11px; background: none; border: 2px solid currentColor; border-right-color: transparent; animation: st-spin .8s linear infinite; }
@keyframes st-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .state.busy::before { animation-duration: 2.4s; } }
.act-row { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; vertical-align: middle; }
.btn.xs { min-height: 26px; padding: 0 9px; font-size: 12.5px; border-radius: 8px; }
.rec-list { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 10px; }
.rec-row { padding: 10px 12px; border: 1.5px solid var(--border); border-radius: 12px; background: var(--surface); display: grid; gap: 6px; }
.rec-main { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; }
.rec-note { font-size: 12.5px; }
a.btn.xs { text-decoration: none; display: inline-flex; align-items: center; }
.ai-lbl { color: var(--primary); }
.auto-sum { margin-top: 12px; }
.auto-kv { grid-template-columns: max-content 1fr; font-size: 14px; margin-top: 4px; }
.auto-kv dt { font-weight: 700; }
.auto-kv dd { font-weight: 500; }
.ai-habits { margin-top: 4px; } .ai-habits ul { margin: 2px 0 0; padding-left: 20px; font-size: 13px; }
/* 家长只读链接 */
body.parent-public { background: var(--bg); }
.pp-main { max-width: 860px; margin: 0 auto; padding: 16px 16px 40px; }
.pp-sheet { margin: 0 auto; }
.pp-at { font-size: 12px; margin-top: 4px; }
.pp-appear { animation: pp-in .5s ease; }
@keyframes pp-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .pp-appear { animation: none; } }

/* ===== v2.5.2 作业检查 / 剩余课时 / 家长链接标记 ===== */
.hours-btn { font-size: inherit; font-weight: 700; }
.btn.hw-warn { border-color: var(--danger); color: var(--danger-text); }
.hw-from { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 8px; }
.hw-extract { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.hw-list { display: flex; flex-direction: column; gap: 8px; }
.hw-item { border: 1px solid var(--border); border-radius: var(--r-sm); padding: 8px 10px; background: var(--surface); }
.hw-item.att { border-color: var(--danger); background: var(--danger-soft); }
.hw-top { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.hw-text { flex: 1 1 260px; min-width: 0; }
.hw-text-ro { flex: 1 1 260px; font-weight: 700; }
.hw-segs { display: flex; gap: 4px; align-items: center; }
.btn.hw-st.on.done { background: var(--ok); border-color: var(--ok); color: #fff; }
.btn.hw-st.on.partial { background: var(--btn); border-color: var(--btn-border); color: var(--btn-text); }
.btn.hw-st.on.undone { background: var(--danger); border-color: var(--danger); color: #fff; }
.hw-del { font-size: 18px; color: var(--t4); padding: 0 4px; }
.hw-miss { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.hw-miss .input { flex: 1 1 240px; }
.hw-att { display: inline-flex; gap: 5px; align-items: center; font-size: 13px; font-weight: 700; color: var(--danger-text); cursor: pointer; }
.hw-hist { margin-top: 10px; }
.hw-hist summary { cursor: pointer; color: var(--t3); font-size: 13.5px; }
.hw-hist-row { padding: 6px 0; border-bottom: 1px dashed var(--border); font-size: 13.5px; }
.hw-hist-i { font-size: 12.5px; padding-left: 10px; }
.hw-att-tag { margin-left: 8px; font-size: 12px; font-weight: 800; color: var(--danger-text); background: var(--danger-soft); border-radius: 999px; padding: 1px 8px; }
.pl-chip { margin-left: 4px; font-size: 10.5px; font-weight: 800; border-radius: 999px; padding: 0 6px; line-height: 16px; display: inline-block; vertical-align: 1px;
  border: 1px solid var(--primary); color: var(--primary); }
.pl-chip.opened { background: var(--primary); color: var(--surface); }
.pl-msg { font-size: 13.5px; resize: vertical; }
.ps-hw { margin: 0; }
.ps-hw-serious { margin-top: 3px; color: #8c2a44; }
.ps-hw-note { color: #6e6e73; }
.mic-row { margin-top: 8px; gap: 8px; flex-wrap: wrap; align-items: center; }

/* ===== v2.5.8 使用指南 / 单词选项标意思 ===== */
.modal.guide { max-width: 520px; }
.guide-list { margin: 8px 0 4px; padding-left: 20px; line-height: 1.7; }
.guide-list li { margin-bottom: 6px; }
.guide-dots { display: flex; gap: 6px; justify-content: center; margin: 10px 0 4px; }
.guide-dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--border-strong); }
.guide-dots i.on { background: var(--primary); }
.opt-mean { display: block; font-size: 13px; color: var(--t3); font-weight: 400; margin-top: 2px; }
.pp-q { margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px dashed var(--border); }
.pp-words li { margin-bottom: 4px; }
.ex-cmp { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 8px; }
.ex-old { opacity: .75; }
.warn-notice { border-color: var(--danger); background: var(--danger-soft); margin: 6px 0; }
@media (max-width: 760px) { .ex-cmp { grid-template-columns: 1fr; } }
.fix-sibs { margin-top: 10px; }
.fix-sibs > summary { cursor: pointer; font-weight: 600; }
.fix-sib { padding: 8px 0; border-top: 1px dashed var(--line, #d9e0b8); }
.fix-q .input { margin: 2px 0; }
/* v2.6.2 大屏：今日排课卡片左边更宽，四个按钮排一行 */
@media (min-width: 1200px) {
  .wf-row { grid-template-columns: minmax(440px, 1fr) minmax(340px, 1fr); }
  .wf-actions { flex-wrap: nowrap; }
  .wf-actions .btn { white-space: nowrap; padding-left: 14px; padding-right: 14px; }
}

/* v2.6.3 弹窗内容太长时在弹窗里滚动（以前没法滑，只能缩放页面）；底部按钮一直露在下面 */
.modal { max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain; }
.modal > .actions:last-child { position: sticky; bottom: -20px; margin-bottom: -20px; padding: 12px 0 20px; background: var(--surface); border-top: 1px solid var(--border); z-index: 1; }

/* v2.8 工作台：上完课沉底变淡、今天不上课、作业检查两行、课时确认、漏报告提醒；左栏不再被右边挤 */
.wf-info { min-width: 0; }
.wf-actions { flex-wrap: wrap; }
.wf-row.done { opacity: .62; }
.wf-row.done:hover { opacity: 1; }
.wf-row.off { grid-template-columns: 1fr; padding: 10px 16px; opacity: .6; border-style: dashed; }
.wf-st { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.wf-off-btn { font-size: 12.5px; color: var(--t3); }
.btn.btn-2line { display: inline-flex; flex-direction: column; justify-content: center; line-height: 1.15; padding-top: 4px; padding-bottom: 4px; }
.btn-2line .btn-sub { font-size: 11.5px; font-weight: 500; color: var(--t3); margin-top: 2px; }
.hours-confirm { color: var(--danger-text); font-weight: 600; }
.hours-confirm.ok { color: var(--t3); }
.alert-card { border-color: var(--danger-text); }
.alert-row { gap: 8px; padding: 4px 0; align-items: baseline; }
.alert-row .grow { flex: 1; min-width: 0; }

/* v2.8 日历 */
.cal-head, .cal-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.cal-head { margin: 10px 0 6px; font-size: 13px; color: var(--t3); text-align: center; font-weight: 700; }
.cal-cell { min-height: 92px; text-align: left; border: 1.5px solid var(--border); border-radius: var(--r-md); background: var(--surface); padding: 6px; display: flex; flex-direction: column; gap: 3px; cursor: pointer; font: inherit; color: inherit; min-width: 0; }
.cal-cell.blank { border: 0; background: none; cursor: default; }
.cal-cell.empty { background: var(--surface-muted); }
.cal-cell.today { border-color: var(--accent, var(--t1)); box-shadow: 0 0 0 2px var(--accent, var(--t1)) inset; }
.cal-cell.pick { outline: 2px dashed var(--t3); outline-offset: 1px; }
.cal-cell.leave { background: repeating-linear-gradient(135deg, var(--surface), var(--surface) 6px, var(--surface-muted) 6px, var(--surface-muted) 12px); }
.cal-d { display: flex; align-items: center; gap: 4px; font-weight: 800; font-size: 14px; }
.cal-wd { display: none; font-weight: 500; color: var(--t3); font-size: 12px; }
.cal-badge { display: inline-block; min-width: 18px; height: 18px; line-height: 18px; text-align: center; border-radius: 9px; background: var(--danger-text); color: var(--surface); font-size: 11px; font-weight: 700; padding: 0 4px; margin-left: auto; }
.cal-exam { font-size: 11.5px; font-weight: 700; color: var(--danger-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cal-leave { font-size: 11.5px; color: var(--t3); }
.cal-chip { display: inline-block; font-size: 12px; line-height: 1.5; padding: 0 6px; border-radius: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; border: 1px solid var(--border); }
.cal-chip.c-done { background: var(--surface-muted); color: var(--t3); text-decoration: line-through; text-decoration-color: transparent; }
.cal-chip.c-plan { background: var(--accent-soft, var(--surface-2)); color: var(--t1); font-weight: 700; border-color: var(--border-strong); }
.cal-chip.c-off { color: var(--t3); border-style: dashed; opacity: .75; }
.cal-chip.c-miss, .cal-chip.warn { color: var(--danger-text); border-color: var(--danger-text); }
.cal-chip.c-past { color: var(--t3); opacity: .6; }
.cal-legend { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 8px; }
.cal-legend .cal-badge { margin-left: 4px; }
.cal-item { justify-content: flex-start; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--border); flex-wrap: wrap; align-items: center; }
.cal-item .grow { flex: 1; }
.cal-todo { margin: 6px 0 10px; display: flex; flex-direction: column; gap: 3px; }
@media (max-width: 720px) {
  .cal-head { display: none; }
  .cal-grid { grid-template-columns: 1fr; gap: 4px; }
  .cal-cell.blank, .cal-cell.empty:not(.today) { display: none; }
  .cal-cell { min-height: 0; flex-direction: row; flex-wrap: wrap; align-items: center; }
  .cal-d { min-width: 80px; }
  .cal-wd { display: inline; }
  .cal-badge { margin-left: 4px; }
}

@media (max-width: 720px) {
  .wf-title { flex-wrap: wrap; gap: 4px 10px; }
  .wf-st { flex-direction: row; align-items: center; gap: 10px; }
  .wf-row.off .wf-title { justify-content: flex-start; }
}
/* 11-11 实站：中等宽度（1000~1200）右栏太窄、长英文撑出横向滚动条 */
.wf-dead-item .t { overflow-wrap: anywhere; }
.wf-dead { min-width: 0; }
@media (min-width: 900px) and (max-width: 1199px) { .wf-row { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); } }

/* 11-11：语法死穴的课号胶囊和标题放进同一段文字里（标题绕着胶囊往下排），错几次靠右 */
.wf-dead-item { display: block; line-height: 1.55; }
.wf-dead-item .tag { display: inline-block; margin-right: 6px; vertical-align: 1px; }
.wf-dead-item .t { display: inline; }
.wf-dead-item .muted { float: right; margin-left: 8px; }
/* 11-11：今天不上课做成小胶囊；停课 / 学生账号折叠 */
.wf-off-btn { display: inline-block; font-size: 12px; font-weight: 700; color: var(--t3); padding: 1px 10px; border: 1.5px solid var(--border-strong); border-radius: 999px; background: var(--surface); text-decoration: none; line-height: 1.6; }
.wf-off-btn:hover { color: var(--t1); border-color: var(--t3); }
.fold-paused { margin-top: 12px; }
.fold-paused > summary { cursor: pointer; font-weight: 700; color: var(--t3); padding: 6px 0; }
.stu-search-in { min-width: 0; width: 100%; }
.ai-cost td:last-child { white-space: normal; word-break: break-word; min-width: 140px; }
.input.sm.acc-search { width: 100%; max-width: 520px; }

/* v2.9 作文批改 */
.essay-done { border-color: var(--accent, var(--border-strong)); }
.essay-files { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.essay-file { width: 110px; border: 1.5px solid var(--border); border-radius: var(--r-md); padding: 6px; background: var(--surface); font-size: 12px; }
.essay-file img { width: 100%; height: 130px; object-fit: cover; border-radius: 6px; display: block; }
.essay-pdf { height: 130px; display: flex; align-items: center; justify-content: center; background: var(--surface-muted); border-radius: 6px; font-weight: 800; color: var(--t3); }
.essay-file-name { margin: 4px 0 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--t3); }
.essay-file .row { gap: 6px; }
.essay-list { display: flex; flex-direction: column; gap: 8px; }
.essay-item { border: 1.5px solid var(--border); border-radius: var(--r-md); padding: 10px 12px; background: var(--surface); display: flex; flex-direction: column; gap: 4px; font-size: 14px; }
.essay-item .row { gap: 8px; align-items: baseline; flex-wrap: wrap; }
.essay-item .grow { flex: 1; }

/* v2.9.2：日历某天的明细按列对齐（名字 | 状态 | 说明 | 按钮）；侧栏：配色切换和上面等宽、学生端自测按钮、底部版本号 */
.cal-item { display: grid; grid-template-columns: 76px 96px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px dashed var(--border); }
.cal-item-name { font-size: 15px; }
.cal-item-st { text-align: center; }
.cal-item-note { display: flex; flex-wrap: wrap; gap: 4px 12px; min-width: 0; }
.cal-item-act { display: flex; gap: 12px; justify-content: flex-end; flex-wrap: wrap; }
@media (max-width: 720px) {
  .cal-item { grid-template-columns: 1fr auto; grid-template-areas: "n s" "x x" "a a"; }
  .cal-item-name { grid-area: n; } .cal-item-st { grid-area: s; text-align: right; } .cal-item-note { grid-area: x; } .cal-item-act { grid-area: a; justify-content: flex-start; }
}
.nav-brand .theme-switch { display: flex; width: 100%; box-sizing: border-box; }
.nav-brand .theme-switch button { flex: 1; }
.nav-selftest { width: 100%; margin: 8px 0; }
.nav-ver { margin-top: 14px; text-align: center; font-size: 12px; color: var(--t3); }
@media (min-width: 861px) { .nav-link.only-narrow-flex { display: none; } }

/* v3.0 教研看板 */
.rs-filters { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-top: 6px; }
.rs-filters > div { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rs-chips { gap: 6px; }
.rs-rate { white-space: nowrap; }
.rs-bar { display: inline-block; width: 60px; height: 8px; border-radius: 4px; background: var(--surface-muted); vertical-align: middle; overflow: hidden; border: 1px solid var(--border); }
.rs-bar > span { display: block; height: 100%; background: var(--t3); }
.rs-bar > span.mid { background: #c98a1a; }
.rs-bar > span.hi { background: var(--danger-text); }
.rs-top { display: flex; flex-direction: column; gap: 2px; }
a.rs-card { font-weight: 700; color: var(--t1); text-decoration: none; }
a.rs-card:hover { text-decoration: underline; }
.rs-qlist { display: flex; flex-direction: column; gap: 8px; }
.rs-q { border: 1.5px solid var(--border); border-radius: var(--r-md); padding: 10px 12px; display: flex; flex-direction: column; gap: 4px; }
.rs-q.flag { border-color: var(--danger-text); }
.rs-q-top { gap: 8px; align-items: baseline; flex-wrap: nowrap; }
.rs-q-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: var(--t2, var(--t1)); }
.rs-flag { font-size: 13px; font-weight: 700; color: var(--danger-text); }
.rs-rule { font-size: 13px; color: var(--t3); margin-bottom: 8px; }
.rs-table th, .rs-table td { white-space: normal; }
.rs-table td:last-child, .rs-table th:last-child { text-align: left; min-width: 260px; }
.rs-table .rs-top { align-items: flex-start; }
.rs-table td:first-child { min-width: 110px; }
.rs-q-top .grow { flex: 1; }

a.rs-card { font-size: 13.5px; }
.rs-top > div { line-height: 1.5; }
/* 打卡图例只是颜色说明，不能点：不变色、不是手指光标 */
.legend .chip-btn, .legend .chip-btn:hover { cursor: default; pointer-events: none; box-shadow: none; transform: none; }
.rs-q.trap { border-color: #c98a1a; }
.rs-trap { font-size: 13px; font-weight: 700; color: #a8700f; }

/* v3.1 家长寄语草稿、考试节点 */
.draft-card.done { opacity: .7; }
.draft-flags { margin: 6px 0 8px; padding-left: 18px; color: #a8700f; font-size: 13.5px; font-weight: 600; }
.draft-text { width: 100%; box-sizing: border-box; min-height: 150px; line-height: 1.6; }
.draft-acts { gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.draft-rewrite { gap: 8px; margin-top: 8px; }
.draft-rewrite .input { flex: 1; min-width: 0; }
.exam-line { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.exam-rows { display: flex; flex-direction: column; gap: 6px; margin: 8px 0; }
.exam-rows .row { gap: 8px; align-items: center; }


/* v3.2 试课 */
.trial-form { display: grid; gap: 8px; margin: 10px 0; }
.trial-form .row { gap: 8px; flex-wrap: nowrap; }
.trial-form .row .input { flex: 1; min-width: 0; }
.wf-row.trial-row { grid-template-columns: minmax(0, 1fr); border-left: 3px solid var(--accent, var(--border-strong)); }
.wf-row.trial-row.due { border-left-color: var(--danger-text, #c0392b); }
.trial-closed { display: grid; gap: 6px; }
.trial-closed-item { gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--border, #e6e6e0); }
.trial-closed-item:last-child { border-bottom: 0; }
/* v3.2.1 录音要补记 */
.manual-card { border-color: var(--danger-text, #c0392b); }
.manual-item { gap: 10px; padding: 6px 0; border-top: 1px solid var(--border); flex-wrap: wrap; }
/* v3.3 作文：我们的分 / 学校给分 */
.essay-score { display: flex; gap: 8px; align-items: baseline; margin-top: 4px; font-size: 14px; }
.essay-score .lbl { font-size: 12px; color: var(--t3, #888); min-width: 2.4em; }
.essay-score.real strong { color: var(--accent-text, var(--t1)); }
.essay-name { font-weight: 700; color: inherit; text-decoration: none; }
.notice.calib { margin: 0 0 10px; font-size: 13px; }
.extra-pick { flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.calib-due .row { gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.calib-due .row .input { flex: 1; min-width: 200px; }
.calib-log { margin: 0 0 10px; font-size: 13px; }
.calib-log ul { margin: 6px 0 0; padding-left: 18px; }
.holder:empty { display: none; }
/* v3.4 课时账本 */
.ledger-big { display: flex; align-items: baseline; gap: 10px; }
.ledger-big strong { font-size: 28px; }
.ledger-form { margin: 10px 0; }
.ledger-form .row { gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.ledger-form .row .input { flex: 1; min-width: 120px; }
.ledger-list { margin: 6px 0; padding-left: 18px; font-size: 13px; }
.ledger-table tr.bad td { background: color-mix(in srgb, var(--danger-text, #c0392b) 8%, transparent); }
.ledger-table tr.low td:nth-child(2) strong { color: var(--danger-text, #c0392b); }
.mm-box { display: block; }
.mm-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.ledger-paused { margin-top: 14px; } .ledger-paused summary { cursor: pointer; padding: 6px 0; }

/* v3.5.0 闪电测回顾 / 这题有问题 */
.task-small .lt-hist-btn { margin-top: -4px; }
.lt-hist > summary { cursor: pointer; font-size: 16px; }
.lt-hist-q { border-top: 1px solid var(--border); padding-top: 12px; margin-top: 12px; }
.lt-flag { margin-top: 8px; }
.ai-review { border-left: 3px solid var(--primary); background: var(--surface-muted); padding: 8px 12px; border-radius: 6px; margin-top: 8px; font-size: 14px; }
.ai-review .v { font-weight: 600; }

/* v3.6.0 作文批不了 */
.essay-fail { background: var(--danger-soft); color: var(--danger-text); border-radius: var(--r-md); padding: 8px 12px; font-size: 13px; margin: 6px 0; }
.essay-fail ul { margin: 4px 0 4px 18px; padding: 0; }
.essay-fail .lnk-btn { color: var(--danger-text); }

/* v3.6.1 闪电测做题时标记 */
.lt-mark { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 0; font-size: 14px; }
.lt-mark.on { color: var(--danger-text); }
.qnav button.marked { box-shadow: inset 0 -3px 0 var(--danger); }
.timer.paused { background: var(--soft); }
/* v3.8.0 工作台卡片：语法死穴挪到上课页，卡片只剩信息 + 「开始上课」 */
.wf-row.wf-compact { grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
.wf-row.wf-compact .wf-actions { margin-top: 0; padding: 0; border: 0; flex-direction: column; align-items: flex-end; gap: 6px; }
.wf-row.wf-compact .wf-actions .btn { min-width: 132px; }
.cls-dead { padding-left: 0; border-left: 0; }
@media (max-width: 760px) { .wf-row.wf-compact { grid-template-columns: 1fr; } .wf-row.wf-compact .wf-actions { align-items: stretch; } }
/* v3.8.0 工作台：每个学生一张磁贴（宽屏三列 / 两列，手机一列） */
.wf-list.wf-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.wf-tiles > .wf-row.off { grid-column: 1 / -1; }
.wf-tile { display: flex; flex-direction: column; gap: 10px; padding: 16px 16px 14px; border: 1.5px solid var(--border); border-radius: var(--r-md); background: var(--surface); min-width: 0; }
.wf-tile.live { border-color: var(--danger); box-shadow: 0 0 0 3px var(--danger-soft); }
.wf-tile.done { background: var(--surface-muted); opacity: .82; }
.wt-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.wt-name { font-size: 21px; font-weight: 900; color: var(--t1); text-decoration: none; letter-spacing: .5px; }
.wt-meta { font-size: 12.5px; color: var(--t4); margin-top: 2px; }
.wt-st { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.wt-st .info-tag { font-size: 13px; }
.wt-days-row { display: flex; align-items: center; gap: 10px; }
.wt-days { display: flex; gap: 4px; flex: 1; }
.wt-day { flex: 1; height: 7px; border-radius: 4px; background: rgba(120, 130, 110, 0.18); }
.wt-day.full { background: var(--primary); }
.wt-day.half { background: var(--btn); }
.wt-day.today { box-shadow: 0 0 0 1.5px var(--t3); }
.wt-days-n { font-size: 11.5px; font-weight: 800; color: var(--t4); white-space: nowrap; }
.wt-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.wt-cell { background: var(--surface-muted); border-radius: var(--r-sm); padding: 8px 8px 7px; min-width: 0; }
.wt-cell.warn { background: var(--danger-soft); }
.wt-cell .wt-v { font-size: 18px; font-weight: 900; color: var(--t1); line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wt-cell .wt-v .hours-btn { font-size: 18px; font-weight: 900; padding: 0; }
.wt-cell .wt-sub { font-size: 11.5px; color: var(--t4); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wt-k { font-size: 11.5px; font-weight: 700; color: var(--t4); }
.wt-line { display: flex; gap: 8px; align-items: baseline; font-size: 13.5px; color: var(--t2); min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wt-line .wt-k { flex: none; width: 3.2em; }
.wt-alerts { display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.wt-alert { color: var(--danger-text); }
.wt-foot { display: flex; align-items: center; gap: 12px; margin-top: auto; padding-top: 4px; flex-wrap: wrap; }
.wt-foot .wt-go { flex: 1; min-height: 44px; }
.wt-foot .lnk-btn { font-size: 13px; }
/* ======================= v3.8.0 上课页 ======================= */
.cl-page { display: flex; flex-direction: column; gap: 14px; }
.cl-back { font-size: 13px; font-weight: 700; color: var(--t4); text-decoration: none; }
.cl-back:hover { color: var(--primary); }
/* 顶栏：左边学生，右边录音（上课页最显眼的东西；录音中整条变红） */
.cl-head { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; padding: 20px 24px; border-radius: var(--r-lg);
  background: var(--surface); border: 1.5px solid var(--border); box-shadow: var(--shadow); }
.cl-head.live { background: var(--danger-soft); border-color: var(--danger); }
.cl-name { font-size: 34px; font-weight: 900; letter-spacing: 2px; color: var(--t1); line-height: 1.1; }
.cl-meta { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 6px; font-size: 13.5px; color: var(--t3); }
.cl-meta a { color: var(--primary); font-weight: 700; }
.cl-rec { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; justify-content: flex-end; }
.cl-clock { display: flex; align-items: center; gap: 10px; font-size: 34px; font-weight: 900; font-variant-numeric: tabular-nums; color: var(--danger); }
.cl-dot { width: 14px; height: 14px; border-radius: 50%; background: var(--danger); animation: clPulse 1.6s ease-in-out infinite; }
@keyframes clPulse { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .cl-dot { animation: none; } }
.cl-rec-sub { font-size: 13px; color: var(--t3); max-width: 220px; }
.cl-rec-btn { min-height: 52px; padding: 0 26px; font-size: 17px; }
.cl-rec-link { font-size: 13px; color: var(--t3); }
/* 两栏：今天讲什么（宽）+ 课前 / 课后（窄） */
.cl-body { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(260px, 1fr); gap: 14px; align-items: start; }
.cl-col { background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-lg); padding: 18px 20px 20px; box-shadow: var(--shadow); }
.cl-sec-h { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.cl-sec-h h2 { font-size: 18px; margin: 0; }
.cl-kind { font-size: 13px; font-weight: 800; color: var(--primary); }
/* 课程路线图：一课一个站点，学过的实心，上次讲到的带圈，推荐的虚线，今天讲的亮绿 */
.cl-track-h { font-size: 12.5px; font-weight: 800; color: var(--t4); margin: 12px 0 6px; }
.cl-track { position: relative; display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 6px; }
.cl-track.m { grid-template-columns: repeat(5, minmax(0, 1fr)); max-width: 52%; }
.cl-track::before { content: ""; position: absolute; left: 4%; right: 4%; top: 22px; height: 2px; background: var(--border); z-index: 0; }
.cl-node { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 0; border: 0; background: none; cursor: pointer; min-width: 0; font: inherit; color: var(--t3); }
.cl-node:disabled { cursor: default; }
.cl-node-n { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--surface); border: 2px solid var(--border-strong);
  font-size: 16px; font-weight: 900; color: var(--t3); transition: transform .12s ease; }
.cl-node-t { font-size: 11.5px; line-height: 1.25; text-align: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cl-node:not(:disabled):hover .cl-node-n { transform: scale(1.07); }
.cl-node:focus-visible .cl-node-n { outline: 3px solid var(--primary); outline-offset: 2px; }
.cl-node.done .cl-node-n { background: var(--surface-2); border-color: var(--primary); color: var(--primary); }
.cl-node.sugg .cl-node-n { border-style: dashed; border-color: var(--primary); }
.cl-node.focus .cl-node-n { box-shadow: 0 0 0 4px var(--soft); border-color: var(--primary); border-width: 3px; }
.cl-node.on .cl-node-n { background: var(--btn); border-color: var(--btn-border); color: var(--btn-text); transform: scale(1.12); }
.cl-node.on .cl-node-t { color: var(--t1); font-weight: 800; }
.cl-node.arm .cl-node-n { border-color: var(--btn-border); }
.cl-legend { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 12px; font-size: 12px; color: var(--t4); }
.cl-legend .lg::before { content: ""; display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; border: 2px solid var(--border-strong); }
.cl-legend .lg.done::before { background: var(--surface-2); border-color: var(--primary); }
.cl-legend .lg.focus::before { border-color: var(--primary); box-shadow: 0 0 0 3px var(--soft); }
.cl-legend .lg.sugg::before { border-style: dashed; border-color: var(--primary); }
.cl-legend .lg.on::before { background: var(--btn); border-color: var(--btn-border); }
.cl-today { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 16px; padding-top: 14px; border-top: 1.5px dashed var(--border); }
.cl-pill { display: inline-flex; align-items: center; gap: 8px; padding: 7px 8px 7px 14px; border-radius: 999px; background: var(--btn); color: var(--btn-text); font-weight: 800; font-size: 14px; }
.cl-pill button { border: 0; background: rgba(0,0,0,.12); color: inherit; width: 22px; height: 22px; border-radius: 50%; cursor: pointer; font-weight: 900; line-height: 1; }
.cl-today .lnk-btn.armed { color: var(--danger); }
.cl-hw { display: inline-flex; align-items: center; gap: 4px; font-size: 14px; margin-left: auto; }
.cl-mats { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.cl-mat { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 12px; border-radius: var(--r-md); background: var(--surface-muted); }
.cl-mat-t { flex: 1; min-width: 140px; font-weight: 800; color: var(--t1); }
.cl-note { margin: 14px 0 0; font-size: 12.5px; color: var(--t4); }
/* 右栏：课前 / 课后，每样一行：名字 + 现状 + 按钮 */
.cl-tool { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.cl-tool-t { font-weight: 800; color: var(--t1); font-size: 15px; }
.cl-tool-s { font-size: 12.5px; color: var(--t4); margin-top: 2px; }
.cl-dead { padding: 10px 0 2px; display: flex; flex-direction: column; gap: 6px; }
.cl-dead-i { display: block; padding: 8px 10px; border-radius: var(--r-sm); background: var(--surface-muted); font-size: 13px; line-height: 1.6; color: var(--t2); font-weight: 700; }
.cl-dead-i .tag { font-size: 11px; vertical-align: 1px; }
.cl-dead-n { float: right; margin-left: 8px; font-size: 12px; font-weight: 600; color: var(--t4); }
@media (max-width: 1000px) { .cl-body { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .cl-head { padding: 16px; } .cl-name { font-size: 26px; } .cl-clock { font-size: 26px; } .cl-rec { width: 100%; justify-content: space-between; }
  .cl-track { grid-template-columns: repeat(5, minmax(0, 1fr)); row-gap: 12px; } .cl-track::before { display: none; } .cl-track.m { max-width: none; }
  .cl-hw { margin-left: 0; }
}
.cl-head.live .cl-rec-btn { background: var(--danger); border-color: var(--danger); color: #fff; }
/* ======================= v3.8.2 课件 ======================= */
.cw-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 10px 0; border-bottom: 1px solid var(--border); }
.cw-row:last-child { border-bottom: 0; }
.cw-t { min-width: 0; flex: 1; }
.cw-s { font-size: 12.5px; color: var(--t4); margin-top: 2px; }
.cw-a { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.cw-views { font-size: 13px; color: var(--t3); line-height: 1.8; margin-top: 8px; }
.cw-stage { display: flex; flex-direction: column; gap: 10px; background: var(--surface); border: 1.5px solid var(--border); border-radius: var(--r-lg); padding: 12px; }
.cw-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cw-title { font-size: 16px; }
.cw-num { font-weight: 900; font-variant-numeric: tabular-nums; min-width: 64px; text-align: center; }
.cw-jump { max-width: 72px; min-height: 34px; padding: 4px 8px; }
.cw-view { display: grid; place-items: center; background: #2a2d26; border-radius: var(--r-md); padding: 10px; min-height: 60vh; }
.cw-img { max-width: 100%; max-height: 74vh; object-fit: contain; background: #fff; box-shadow: 0 6px 24px rgba(0,0,0,.35); cursor: pointer; user-select: none; }
.cw-stage { position: relative; overflow: hidden; }
.cw-strip { display: flex; gap: 8px; overflow-x: auto; padding: 8px 8px 10px; position: absolute; left: 12px; right: 12px; bottom: 12px; z-index: 5;
  background: rgba(30, 33, 27, .92); border-radius: var(--r-md); box-shadow: 0 -6px 24px rgba(0,0,0,.3);
  transform: translateY(calc(100% + 16px)); opacity: 0; transition: transform .22s ease, opacity .22s ease; pointer-events: none; }
.cw-stage.strip-on .cw-strip { transform: none; opacity: 1; pointer-events: auto; }
.cw-strip .cw-th span { color: #d8dccf; }
.cw-hint { font-size: 12px; color: var(--t4); text-align: center; margin-top: -4px; }
.cw-num { cursor: pointer; }
.cw-minor { font-weight: 600; }
@media (prefers-reduced-motion: reduce) { .cw-strip { transition: none; } }
.cw-th { flex: none; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 3px; border: 2px solid transparent; border-radius: 6px; background: none; cursor: pointer; }
.cw-th img { width: 112px; height: 84px; object-fit: contain; background: #fff; border: 1px solid var(--border); border-radius: 3px; }
.cw-th span { font-size: 11px; color: var(--t4); }
.cw-th.on { border-color: var(--btn-border); background: var(--soft); }
.cw-stage:fullscreen { background: #000; padding: 0; border: 0; border-radius: 0; justify-content: center; }
.cw-stage:fullscreen .cw-bar, .cw-stage:fullscreen .cw-hint { display: none; }
.cw-stage:fullscreen .cw-view { background: #000; min-height: 100vh; padding: 0; border-radius: 0; }
.cw-stage:fullscreen .cw-img { max-height: 100vh; max-width: 100vw; box-shadow: none; }

/* ======================= v3.9.0 作业 ======================= */
.hw-doc-view .cw-view { place-items: start center; overflow: auto; max-height: 82vh; }
.hw-doc-view .cw-img { max-height: none; width: min(100%, 860px); max-width: 100%; }
.hw-doc-view:fullscreen .cw-img { width: auto; max-height: none; max-width: 100vw; }
.hw-id { display: inline-block; min-width: 2.6em; text-align: center; font-weight: 800; font-size: 12px; padding: 2px 7px; border-radius: 999px;
  background: var(--surface-2, #eef3dc); color: var(--t2); border: 1px solid var(--border); margin-right: 8px; letter-spacing: .02em; }
.hw-id.t-A { background: #d8f0a0; border-color: #a9cc55; color: #2f4a00; }
.hw-id.t-B { background: #e7f1d6; }
.hw-id.t-C { background: #f6efd9; border-color: #e2d19c; color: #6a5212; }
.hw-id.t-R, .hw-id.t-T { background: #e3ecf6; border-color: #b9cbe2; color: #23446b; }
.hw-lib-g { padding: 4px 0 8px; }
.hw-lib-gh { font-weight: 800; font-size: 13px; color: var(--t3); margin: 10px 0 2px; }
.hw-lib-row { display: flex; justify-content: space-between; align-items: center; gap: 10px 16px; flex-wrap: wrap; padding: 8px 0; border-bottom: 1px solid var(--border); }
.hw-lib-row:last-child { border-bottom: 0; }
.hw-lib-t { min-width: 0; flex: 1 1 320px; display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 0; }
.hw-lib-s { flex-basis: 100%; padding-left: calc(2.6em + 22px); font-size: 12.5px; color: var(--t4); }
.hw-lib-a { display: flex; gap: 14px; flex-wrap: wrap; }
.hw-side { display: flex; align-items: center; gap: 8px; min-width: 210px; }
.hw-side-n { font-size: 12px; color: var(--t4); width: 3em; }
.hw-bad { font-size: 13px; line-height: 1.7; max-height: 50vh; overflow: auto; }
.cl-hwa { margin-top: 22px; }
.cl-hwg { font-weight: 800; font-size: 13.5px; margin: 12px 0 4px; display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.cl-hwg small { font-weight: 500; color: var(--t4); }
.cl-hwn { margin: 4px 0; font-size: 13px; }
.cl-hwr { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 7px 10px; border: 1px solid var(--border); border-radius: var(--r-md); margin: 5px 0; cursor: pointer; background: var(--surface); }
.cl-hwr.on { border-color: #a9cc55; background: #f3fadf; }
.cl-hwr.off { opacity: .6; cursor: default; }
.cl-hwr input { margin: 0; }
.cl-hwr-t { flex: 1 1 220px; min-width: 0; display: flex; flex-direction: column; }
.cl-hwr-t small { color: var(--t4); font-size: 12px; display: flex; flex-wrap: wrap; gap: 2px 10px; }
.cl-hwr-t small b { font-weight: 600; }
.cl-hwr-t small:empty { display: none; }
.cl-hwr-t .warn-txt { color: #a5551d; }
.cl-hwr-a { display: flex; gap: 10px; margin-left: auto; }
.cl-hwrev { margin-top: 10px; }
.cl-hwrev summary { cursor: pointer; font-weight: 700; font-size: 13.5px; color: var(--t3); }
.cl-hwf { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 12px; }
.cl-hwf .muted { font-size: 12.5px; }
.hw-doc { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 6px; font-size: 13px; }
.hw-wrong { width: 64px; display: inline-block; padding: 3px 6px; }
.hw-stu .kicker-row { margin-bottom: 6px; }
.hw-stu-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 9px 0; border-top: 1px solid var(--border); }
.hw-stu-t { display: flex; flex-direction: column; min-width: 0; flex: 1 1 220px; }
.hw-stu-a { display: flex; gap: 8px; }
.hw-stu-old summary { cursor: pointer; font-size: 13px; color: var(--t3); margin-top: 6px; }
[data-theme="C"] .hw-id.t-A { background: #3d4a1c; border-color: #6c8a2a; color: #e3f5b0; }
[data-theme="C"] .hw-id.t-B { background: #333b28; color: #d8e6bd; }
[data-theme="C"] .hw-id.t-C { background: #463d22; border-color: #7a6a35; color: #f1dfa6; }
[data-theme="C"] .hw-id.t-R, [data-theme="C"] .hw-id.t-T { background: #24344a; border-color: #3f5878; color: #c9dcf3; }
[data-theme="C"] .cl-hwr.on { background: #333b28; border-color: #6c8a2a; }

/* v3.9.1 学生首页课后作业：默认收起 */
details.hw-stu { padding-top: 12px; padding-bottom: 12px; }
details.hw-stu > summary { list-style: none; display: flex; align-items: center; gap: 10px; cursor: pointer; }
details.hw-stu > summary::-webkit-details-marker { display: none; }
.hw-stu-sum { font-weight: 800; color: #b0392f; }
.hw-stu-sum.ok { color: var(--ok, #3d7a12); }
.hw-stu-more { margin-left: auto; font-size: 12.5px; color: var(--t4); }
.hw-stu-more::after { content: " ▾"; }
details.hw-stu[open] .hw-stu-more { font-size: 0; }
details.hw-stu[open] .hw-stu-more::after { content: "收起 ▴"; font-size: 12.5px; }
.hw-stu-h { font-size: 12.5px; font-weight: 700; color: var(--t3); margin: 12px 0 2px; }
.hw-it { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 8px 0; border-top: 1px solid var(--border); }
.hw-it-l { display: flex; align-items: flex-start; gap: 10px; flex: 1 1 220px; min-width: 0; cursor: pointer; }
.hw-tick { width: 20px; height: 20px; margin-top: 1px; flex: none; accent-color: #7aa61b; }
.hw-it-t { display: flex; flex-direction: column; line-height: 1.45; }
.hw-it.done .hw-it-t { color: var(--t4); text-decoration: line-through; }
.hw-carry { color: #a5551d; font-size: 12px; text-decoration: none; }
.hw-stu-tip { font-size: 12px; margin: 8px 0 0; }
.cl-hwr-o { cursor: default; }
.cl-hwo { display: flex; gap: 8px; margin-top: 6px; }
.cl-hwo .input { flex: 1; }

/* v3.10.0 Drive 同步记录 */
.ms-strip { padding: 12px 16px; }
.ms-strip summary { list-style: none; cursor: pointer; }
.ms-strip summary::-webkit-details-marker { display: none; }
.ms-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ms-sum { font-size: 13px; color: var(--t3); }
.ms-sec { margin-top: 10px; }
.ms-sec-h { font-size: 12.5px; font-weight: 800; color: var(--t3); margin-bottom: 2px; }
.ms-li { font-size: 13px; padding: 3px 0; border-top: 1px dashed var(--border); }
.ms-li small { color: var(--t4); }
.ms-note { font-size: 12px; margin: 8px 0 0; }

/* v3.11.0 看课件：原文并排、方法目录、倒计时 */
.cw-body { display: flex; gap: 0; min-height: 60vh; position: relative; }
.cw-body > .cw-view { flex: 1 1 auto; min-width: 0; }
.cw-div, .cw-side { display: none; }
.cw-body.split .cw-div { display: block; flex: none; width: 10px; cursor: col-resize; background: linear-gradient(90deg, transparent 4px, var(--border) 4px, var(--border) 6px, transparent 6px); touch-action: none; }
.cw-body.split .cw-side { display: block; position: relative; flex: 0 0 42%; min-width: 0; max-height: 78vh; overflow-y: auto; background: #f4f4ef; border-radius: var(--r-md); padding: 0 8px 8px; }
.cw-side-h { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 8px 2px; background: #f4f4ef; border-bottom: 1px solid var(--border); margin-bottom: 8px; }
.cw-side-h strong { font-size: 13px; margin-right: 4px; }
.cw-chip { border: 1px solid var(--border); background: #fff; border-radius: 999px; font-size: 12px; padding: 2px 9px; cursor: pointer; }
.cw-chip:hover { border-color: var(--btn-border); }
.cw-side-img { display: block; width: 100%; background: #fff; margin: 0 0 10px; box-shadow: 0 2px 10px rgba(0,0,0,.12); }
.cw-body.split .cw-img { max-width: 100%; }
.cw-msel { width: auto; max-width: 200px; flex: none; min-height: 34px; padding: 4px 8px; font-size: 13px; }
.btn.on { background: var(--soft); border-color: var(--btn-border); }
.cw-timer { position: absolute; top: 12px; left: 12px; z-index: 6; display: flex; align-items: center; gap: 10px; padding: 6px 12px 6px 18px;
  background: rgba(20, 22, 18, .86); color: #f1f6e4; border-radius: 14px; cursor: pointer; box-shadow: 0 6px 24px rgba(0,0,0,.35); }
.cw-timer-t { font-size: 54px; font-weight: 900; font-variant-numeric: tabular-nums; line-height: 1.1; letter-spacing: .02em; }
.cw-timer.paused .cw-timer-t { opacity: .5; }
.cw-timer.over { background: rgba(190, 36, 30, .92); }
.cw-timer-x { background: none; border: 0; color: inherit; font-size: 22px; cursor: pointer; opacity: .7; }
.cw-stage:fullscreen .cw-timer { top: 18px; left: 18px; }
.cw-stage:fullscreen .cw-timer-t { font-size: 72px; }
.cw-stage:fullscreen .cw-body { min-height: 100vh; height: 100vh; }
.cw-stage:fullscreen .cw-body.split .cw-side { max-height: 100vh; border-radius: 0; }
.cw-stage:fullscreen .cw-body.split .cw-view { min-height: 100vh; }
.cw-stage:fullscreen .cw-body.split .cw-img { max-width: 100%; }

/* v3.11.0 上课页：这一课的流程 */
.cl-flow { flex-direction: column; align-items: stretch !important; gap: 10px; }
.cl-steps { display: flex; align-items: stretch; gap: 6px; flex-wrap: wrap; }
.cl-step { flex: 1 1 140px; display: flex; gap: 10px; align-items: flex-start; padding: 10px; border: 1.5px solid var(--border); border-radius: var(--r-md); background: var(--surface); min-width: 0; }
.cl-step.done { border-color: #a9cc55; background: #f3fadf; }
.cl-step-n { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-weight: 900; font-size: 13px; background: var(--soft); border: 1.5px solid var(--btn-border); }
.cl-step.done .cl-step-n { background: #b9de4a; border-color: #7aa61b; }
.cl-step-b { display: flex; flex-direction: column; gap: 6px; min-width: 0; align-items: flex-start; }
.cl-step-t { font-weight: 800; font-size: 14px; }
.cl-step-t small { font-weight: 500; color: var(--t4); }
.cl-step-s { font-size: 12px; color: var(--t4); display: flex; gap: 10px; flex-wrap: wrap; }
.cl-arrow { align-self: center; color: var(--t4); font-weight: 900; }
@media (max-width: 760px) { .cl-arrow { display: none; } }
[data-theme="C"] .cl-step.done { background: #333b28; border-color: #6c8a2a; }
.hw-id.t-J { background: #efe6f7; border-color: #cdb6e3; color: #4b2a6b; }
[data-theme="C"] .hw-id.t-J { background: #3a2c48; border-color: #6b4f86; color: #e6d6f5; }
.hw-lib-row.old { opacity: .6; }
.cw-seg { display: inline-flex; border: 1px solid var(--border); border-radius: 999px; overflow: hidden; }
.cw-seg button { border: 0; background: #fff; font-size: 12px; padding: 3px 10px; cursor: pointer; }
.cw-seg button.on { background: var(--btn, #b9de4a); font-weight: 800; }
.cw-side-h.t { background: #fbeee0; }
.hw-del { color: #a33 !important; font-size: 12.5px; }
.hw-lib-row:not(.old) .hw-del { opacity: .55; }
.hw-lib-row.old { opacity: 1; }
.hw-lib-row.old .hw-lib-t, .hw-lib-row.old .hw-side { opacity: .55; }

/* v3.11.3 折叠分类 */
details.xfold > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline; gap: 10px; }
details.xfold > summary::-webkit-details-marker { display: none; }
details.xfold > summary::before { content: "▸"; color: var(--t4); font-size: 13px; transition: transform .15s; display: inline-block; }
details.xfold[open] > summary::before { transform: rotate(90deg); }
details.xfold > summary h2 { margin: 0; }
details.xfold.card > summary { margin-bottom: 4px; }
details.xfold.card:not([open]) > summary { margin-bottom: 0; }
.fold-meta { font-size: 12.5px; color: var(--t4); font-weight: 500; }
details.xfold.hw-lib-g > summary { padding: 8px 0 4px; border-top: 1px dashed var(--border); }
details.xfold.hw-lib-g > summary .hw-lib-gh { margin: 0; }
@media (prefers-reduced-motion: reduce) { details.xfold > summary::before { transition: none; } }

/* v3.11.7 删除账号 */
.acc-del { margin-left: auto; color: #b0392f; border-color: #e3b5ae; }
.btn.danger { background: #c8402f; border-color: #a8321f; color: #fff; }
.btn.danger:disabled { opacity: .45; }

/* v3.12.0 课堂做题：记答案窗口 */
.modal.qz-modal { max-width: 640px; width: calc(100vw - 32px); }
.qz-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.qz-head h3 { margin: 0; }
.qz-tip { font-size: 13px; color: var(--t3); margin: 6px 0 10px; line-height: 1.6; }
.qz-who { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 14px; }
.qz-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.qz-tab { border: 1px solid var(--border); background: var(--surface); color: var(--t2); border-radius: 999px; padding: 5px 12px; font-size: 13px; font-weight: 700; cursor: pointer; }
.qz-tab small { color: var(--t4); font-weight: 600; }
.qz-tab.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.qz-tab.on small { color: rgba(255,255,255,.8); }
.qz-list { max-height: min(56vh, 520px); overflow-y: auto; border: 1px solid var(--border); border-radius: var(--r-md); }
.qz-row { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-bottom: 1px solid var(--border); }
.qz-row:last-child { border-bottom: 0; }
.qz-row.done { background: var(--surface-muted); }
.qz-no { width: 34px; flex: none; font-weight: 800; color: var(--t1); font-variant-numeric: tabular-nums; }
.qz-opts { display: flex; gap: 5px; flex: 1; flex-wrap: wrap; }
.qz-o, .qz-m { min-width: 36px; height: 34px; border: 1px solid var(--btn-border); background: var(--surface); color: var(--t2); border-radius: var(--r-sm); font-weight: 800; font-size: 15px; cursor: pointer; }
.qz-o.on { background: var(--primary); border-color: var(--primary); color: #fff; }
.qz-marks { display: flex; gap: 4px; flex: none; }
.qz-m { min-width: 32px; font-size: 14px; }
.qz-m:disabled { opacity: .3; cursor: default; }
.qz-m.on { background: var(--ok); border-color: var(--ok); color: #fff; }
.qz-m.warn.on { background: var(--danger); border-color: var(--danger); }
:fullscreen .modal-back { position: fixed; inset: 0; z-index: 50; }
.cl-quiz { display: block; margin-top: 4px; font-size: 13px; }

/* 工作台：课堂做题待确认 */
.qz-card { border: 1px solid var(--border); border-radius: var(--r-md); padding: 10px 12px; margin-top: 10px; background: var(--surface); }
.qz-card-h { font-size: 14px; line-height: 1.7; }
.qz-card-h .muted { font-size: 13px; }
.qz-rep { font-size: 13px; margin: 4px 0 6px; color: var(--t3); }
.qz-rep.done { color: var(--t2); }
.qz-mt td, .qz-mt th { padding: 6px 8px; vertical-align: top; font-size: 13px; }
.qz-mt select { min-width: 92px; }
.qz-bad { color: var(--danger-text); font-weight: 700; }
.qz-qs summary { cursor: pointer; font-size: 13px; color: var(--t3); margin-top: 6px; }
.qz-qgrid { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.qz-q { font-size: 12px; padding: 3px 8px; border-radius: var(--r-sm); background: var(--surface-muted); color: var(--t2); }
.qz-q.bad { background: var(--danger-soft); color: var(--danger-text); }
.qz-q b { margin-right: 2px; }

/* 方法弱项 */
.mw-l { margin-bottom: 10px; }
.mw-lt { font-weight: 800; font-size: 13px; color: var(--t3); margin: 6px 0 4px; }
.mw-i { padding: 7px 10px; border-radius: var(--r-sm); background: var(--surface-muted); font-size: 13px; line-height: 1.6; color: var(--t2); margin-bottom: 5px; }
.mw-i .tag { font-size: 11px; vertical-align: 1px; }
.mw-i.gone { opacity: .55; }
.mw-st { display: inline-block; margin-left: 6px; padding: 0 7px; border-radius: 999px; font-size: 12px; font-weight: 700; border: 1px solid var(--border); color: var(--t3); }
.mw-st.warn { background: var(--danger-soft); color: var(--danger-text); border-color: var(--danger); }
.mw-st.ok { color: var(--ok); border-color: var(--ok); }
.mw-n { float: right; margin-left: 8px; font-size: 12px; font-weight: 600; color: var(--t4); }
@media (max-width: 640px) { .qz-row { flex-wrap: wrap; } .qz-o, .qz-m { height: 38px; } }

/* v3.12.0 课堂做题计时：悬浮在课件上的一块（准备 / 计时中），大字 */
.cw-timer { flex-direction: column; align-items: stretch; gap: 8px; padding: 12px 16px; cursor: default; max-width: min(640px, calc(100% - 24px)); }
.cw-timer.ready { background: rgba(20, 22, 18, .9); }
.cw-tr-tip { font-size: 15px; line-height: 1.55; font-weight: 700; color: #fff3c4; }
.cw-tr-tip.sm { font-size: 13px; font-weight: 600; color: rgba(241, 246, 228, .75); }
.cw-tr-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.cw-tr-chips:empty { display: none; }
.cw-tr-chip { border: 1px solid rgba(255,255,255,.35); background: transparent; color: inherit; border-radius: 999px; padding: 4px 12px; font-size: 14px; font-weight: 700; cursor: pointer; }
.cw-tr-chip.on { background: #f1f6e4; color: #1d2317; border-color: #f1f6e4; }
.cw-tr-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.cw-tr-min { font-size: 30px; font-weight: 900; font-variant-numeric: tabular-nums; min-width: 4.4em; text-align: center; }
.cw-tr-run { display: flex; align-items: baseline; gap: 14px; }
.cw-tr-l { font-size: 18px; font-weight: 800; opacity: .8; }
.cw-timer.run .cw-timer-t { font-size: 88px; line-height: 1; }
.cw-tb { min-height: 40px; padding: 6px 16px; border-radius: 10px; border: 1px solid rgba(255,255,255,.4); background: rgba(255,255,255,.1); color: inherit;
  font-size: 17px; font-weight: 800; cursor: pointer; }
.cw-tb:hover { background: rgba(255,255,255,.2); }
.cw-tb.go { background: #f1f6e4; color: #1d2317; border-color: #f1f6e4; margin-left: 6px; }
.cw-tb.end { background: #f1f6e4; color: #1d2317; border-color: #f1f6e4; }
.cw-timer.over .cw-tb.end { color: #a8231b; }
.cw-timer.ready .cw-timer-x { margin-left: auto; }
.cw-stage:fullscreen .cw-timer.run .cw-timer-t { font-size: 120px; }
.cw-stage:fullscreen .cw-tr-tip { font-size: 18px; }
.cw-locked .cw-view { cursor: not-allowed; }
.cw-locked .cw-strip { pointer-events: none; opacity: .5; }

/* v3.12.3 新建账号：这个名字以前有人用过 */
.reuse-box { margin: 4px 0 12px; padding: 12px 14px; border-radius: var(--r-md); background: var(--surface-muted); border: 1px solid var(--border-strong); border-left: 4px solid var(--primary); }
.reuse-box[hidden] { display: none; }
.reuse-box p { margin: 6px 0; font-size: 13.5px; color: var(--t2); line-height: 1.6; }
.reuse-title { font-weight: 800; color: var(--t1); font-size: 14.5px; }
.reuse-list { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 2px; }
.reuse-chip { font-size: 12.5px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); color: var(--t2); }
.reuse-box .reuse-tip { color: var(--t1); font-weight: 700; }
.reuse-box .row { margin-top: 8px; gap: 8px; flex-wrap: wrap; }

/* v3.12.4 声音条（代替原来的声纹）：有人说话时条会跳；最近 3 秒都没声音写「没声音」 */
.mic-lv { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 700; color: var(--t2); white-space: nowrap; }
.mic-lv-ic { font-size: 13px; line-height: 1; }
.mic-lv-bar { position: relative; display: inline-block; width: 72px; height: 8px; border-radius: 999px; background: var(--surface-muted); border: 1px solid var(--border); overflow: hidden; }
.mic-lv-bar b { position: absolute; left: 0; top: 0; bottom: 0; width: var(--lv, 0%); border-radius: inherit; background: var(--ok); transition: width .12s linear; }
.mic-lv[data-cat="none"] .mic-lv-bar b { background: var(--t3); }
.mic-lv[data-cat="none"] .mic-lv-t { color: var(--danger-text); }
.cl-head.live .mic-lv-bar { background: var(--surface); }
@media (prefers-reduced-motion: reduce) { .mic-lv-bar b { transition: none; } }

/* v3.12.4 Drive 同步：最上面一行 + 要处理的；记录在页面最下面、默认收起 */
.ms-strip .ms-bad { margin-top: 10px; padding: 8px 12px; border-radius: var(--r-md); background: var(--danger-soft); border: 1px solid var(--danger); }
.ms-strip .ms-bad .ms-sec-h { color: var(--danger-text); }
.ms-strip .ms-bad .ms-li { border-top-color: color-mix(in srgb, var(--danger) 30%, transparent); }
.ms-strip .ms-bad .ms-li small { color: var(--danger-text); }
.ms-jump { font-size: 13px; }
.ms-log { padding: 12px 16px; }
.ms-log[hidden] { display: none; }
.ms-log summary { cursor: pointer; }
.ms-log summary .ms-sum { font-weight: 400; }

/* v3.12.5 上课页「阶段测」：每 4 节课提醒一次；出卷在弹窗里 */

.cl-due-tag { margin-left: 6px; vertical-align: 1px; }
.stage-in-modal > .card { border: 0; box-shadow: none; padding: 0; margin: 0; background: none; }
.modal.stage-modal { max-width: 860px; }

/* v3.12.5 上课日 + 几点上课：勾上的那天变成实心胶囊，后面出来时间 */
.dt-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.dt-day { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 3px 12px 3px 10px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); cursor: pointer; font-size: 14px; color: var(--t2); user-select: none; }
.dt-day.on { border-color: var(--primary); background: var(--surface-muted); color: var(--t1); font-weight: 700; }
.dt-day input[type=checkbox] { margin: 0; accent-color: var(--primary); }
.dt-day .dt-time { display: none; width: calc(3.3em + 9px); cursor: text; border: 0; border-left: 1px solid var(--border); border-radius: 0; background: transparent; font: inherit; font-weight: 800; color: var(--t1); padding: 0 0 0 8px; font-variant-numeric: tabular-nums; outline: none; }
.dt-day .dt-time::placeholder { color: var(--t4); font-weight: 600; }
.dt-day.on .dt-time { display: inline-block; }
.dt-day:has(.dt-time:focus) { box-shadow: 0 0 0 2px var(--primary); }
.dt-day .dt-time.bad { color: var(--danger-text); }
.dt-day:has(.dt-time.bad) { border-color: var(--danger); box-shadow: 0 0 0 1px var(--danger); }
.dt-day .dt-time:disabled { color: var(--t3); }
/* 工作台磁贴：名字后面今天几点上 */
.wt-time { display: inline-block; margin-left: 8px; vertical-align: 3px; padding: 1px 9px; border-radius: 999px; border: 1px solid var(--border-strong); font-size: 14px; font-weight: 800; color: var(--t1); font-variant-numeric: tabular-nums; }

/* v3.13.0 作文类型：应用文写给谁 / 续写主题；诊断台「写作」每类写过几篇 */
.essay-sub-row { gap: 6px; flex-wrap: wrap; }
.essay-sub-btn { margin-left: 8px; }
.essay-cov-box { display: grid; gap: 6px; margin: 4px 0 12px; }
.essay-cov-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.essay-cov-row .lbl-s { min-width: 5.5em; }
.essay-cov { display: inline-block; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-muted); font-size: 13px; color: var(--t1); }
.essay-cov b { font-weight: 800; }
.essay-cov.none { background: transparent; border-style: dashed; color: var(--t3); }
.essay-cov.none b { font-weight: 600; }

.essay-sub + .essay-sub { margin-top: 10px; }

/* v3.14.0 添加到主屏幕 */
.a2hs-steps { margin: 4px 0 8px; padding-left: 1.4em; display: grid; gap: 8px; line-height: 1.6; }
.nav-a2hs { display: block; margin: 6px 0 0; font-size: 13px; }

/* v3.14.0 雅思：目标 / 倒计时、课程设置、上课页、Band 成绩 */
.ielts-tag { display: inline-block; padding: 1px 9px; border-radius: 999px; background: var(--surface-muted); border: 1px solid var(--border); font-size: 12.5px; font-weight: 700; color: var(--t2); }
h2 + .ielts-tag { margin-top: 4px; }
.ielts-box { border: 1px dashed var(--border); border-radius: 12px; padding: 10px 12px 6px; }
.ielts-box > label { font-weight: 800; }
.ielts-tier { gap: 6px; }
.ielts-hs { align-items: flex-start; margin: 8px 0 4px; }
.ielts-hs small { display: block; color: var(--t3); font-size: 12.5px; line-height: 1.5; margin-top: 2px; font-weight: 400; }
.cl-hs-more { margin: 6px 0 10px; }
.cl-hs-more > summary { cursor: pointer; font-weight: 700; color: var(--t2); padding: 6px 0; }
.cl-tiers { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 2px 0 8px; }
.band-row { gap: 6px; flex-wrap: wrap; }
.band-row .band-in { width: 5.2em; }
.band-row .band-in:nth-child(5) { width: 11em; }
.band-table td, .band-table th { text-align: center; }
.band-table td:nth-child(2), .band-table th:nth-child(2) { text-align: left; }
.ielts-strip { display: flex; flex-wrap: wrap; gap: 10px 28px; align-items: flex-end; }
.ielts-k { display: grid; gap: 2px; }
.ielts-k small { color: var(--t3); font-size: 12.5px; }
.ielts-k b { font-size: 26px; font-weight: 900; line-height: 1.1; color: var(--t1); font-variant-numeric: tabular-nums; }
.ielts-k b span { font-size: 14px; font-weight: 700; color: var(--t2); }

/* v3.15.0 雅思作业：学生交作业、录音、老师工作台 */
.ih-btns { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 4px; }
.ih-list { display: grid; gap: 6px; margin-top: 10px; border-top: 1px dashed var(--border); padding-top: 10px; }
.ih-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ih-t { display: grid; gap: 2px; min-width: 0; }
.ih-t strong { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ih-a { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.ih-score { display: inline-block; min-width: 2.4em; text-align: center; padding: 1px 8px; border-radius: 999px; background: var(--btn); color: var(--btn-text); font-weight: 900; font-variant-numeric: tabular-nums; margin-left: 6px; }
.ih-chips { gap: 6px; flex-wrap: wrap; }
.ih-files { display: flex; flex-wrap: wrap; gap: 6px; }
.ih-file { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 10px; border: 1px solid var(--border); border-radius: 999px; font-size: 13px; background: var(--surface-muted); }
.ih-file button { border: 0; background: transparent; color: var(--t3); font-size: 15px; cursor: pointer; padding: 0 4px; }
.ih-qs { display: grid; gap: 10px; margin: 6px 0 8px; }
.ih-q { border: 1px solid var(--border); border-radius: 12px; padding: 10px 12px; display: grid; gap: 8px; background: var(--surface); }
.ih-q-h { display: flex; justify-content: space-between; align-items: center; }
.ih-mock { justify-self: start; }
.rec-box { display: grid; gap: 6px; }
.rec-line { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.rec-time { font-weight: 800; font-variant-numeric: tabular-nums; color: var(--t2); min-width: 3.5em; }
.rec-box.on .rec-btn { background: var(--danger); border-color: var(--danger); color: #fff; }
.rec-box.on .rec-time { color: var(--danger-text); }
.rec-box.warn .rec-time { color: var(--warn-text, #b26b00); }
.rec-box audio { width: 100%; max-width: 420px; height: 36px; }
.rec-tip { color: var(--t3); }
.rec-box.warn .rec-tip { color: var(--warn-text, #b26b00); font-weight: 700; }
.ih-done .ih-trow { display: flex; align-items: center; gap: 10px; padding: 8px 0; }
.ih-done .ih-trow + .ih-trow { border-top: 1px dashed var(--border); }
.ih-done .ih-trow .grow { flex: 1; min-width: 0; }
.ih-form .field { margin-top: 14px; }
.ih-form .ih-qs { margin-top: 14px; }
.ih-drag { cursor: grab; }
.ih-hist { margin-top: 14px; }
.ih-hist .ih-trow { display: flex; align-items: center; gap: 10px; padding: 7px 0; }
.ih-hist .ih-trow + .ih-trow { border-top: 1px dashed var(--border); }
.ih-hist .ih-trow .grow { flex: 1; min-width: 0; }
.ih-wait { margin: 4px 0 12px; font-size: 13px; }

/* v3.16.0 词汇量测试 */
.vt-card .vt-last { display: grid; gap: 10px; margin-top: 8px; }
.vt-est { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 6px; }
.vt-est b { font-size: 30px; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.vt-est > span { font-weight: 800; color: var(--t2); }
.vt-est small { flex-basis: 100%; color: var(--t3); font-size: 13px; }
.vt-why { font-size: 13px; margin: 8px 0 0; }
.vt-bars { display: grid; gap: 7px; }
.vt-bar { display: grid; grid-template-columns: 2.6em 1fr 4.6em; align-items: center; gap: 10px; font-size: 14px; }
.vt-bars.sm .vt-bar { font-size: 13px; gap: 8px; }
.vt-lv { color: var(--t2); font-weight: 700; }
.vt-track { height: 10px; border-radius: 999px; background: var(--surface-muted); overflow: hidden; border: 1px solid var(--border); }
.vt-track i { display: block; height: 100%; border-radius: 999px; background: var(--btn); }
.vt-bar b { font-variant-numeric: tabular-nums; text-align: right; font-weight: 800; white-space: nowrap; }
.vt-bar.est .vt-track i { background: repeating-linear-gradient(-45deg, var(--btn) 0 5px, transparent 5px 9px); opacity: .7; }
.vt-bar.est b { color: var(--t3); font-weight: 600; }
.vt-bar small { font-size: 11px; color: var(--t3); }
.vt-page { max-width: 560px; margin: 0 auto; display: grid; gap: 14px; }
.vt-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.vt-title { font-weight: 800; color: var(--t2); }
.vt-dots { display: flex; gap: 6px; justify-content: center; }
.vt-dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--surface-muted); border: 1px solid var(--border-strong); }
.vt-dots i.done { background: var(--border-strong); }
.vt-dots i.on { background: var(--btn); border-color: var(--btn-border); transform: scale(1.25); }
.vt-word { text-align: center; font-size: clamp(36px, 9vw, 52px); font-weight: 900; letter-spacing: .5px; color: var(--t1); padding: 26px 0 18px; overflow-wrap: anywhere; }
.vt-act { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.vt-act .vt-yes, .vt-act .vt-no { min-height: 54px; font-size: 18px; font-weight: 800; }
.vt-q { grid-column: 1 / -1; color: var(--t3); font-weight: 700; }
.vt-opts { grid-column: 1 / -1; display: grid; gap: 8px; }
.vt-opt { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; padding: 12px 14px; border-radius: var(--r-md); border: 1.5px solid var(--sec-border); background: var(--sec-bg); color: var(--sec-text); font: inherit; font-size: 15px; cursor: pointer; }
.vt-opt:hover { background: var(--sec-hover); border-color: var(--border-strong); }
.vt-opt:focus-visible { outline: 3px solid var(--soft); outline-offset: 2px; }
.vt-k { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px; display: inline-grid; place-items: center; font-size: 12px; font-weight: 800; background: var(--surface-muted); color: var(--t3); }
.vt-idk { border-style: dashed; color: var(--t3); }
.vt-hint { font-size: 13px; text-align: center; margin: 0; min-height: 1em; }
.vt-wait { text-align: center; padding: 30px 0; }
.vt-rules { margin: 0; padding-left: 1.2em; display: grid; gap: 6px; color: var(--t2); }
.vt-big { display: flex; align-items: baseline; justify-content: center; gap: 10px; padding: 14px 0 6px; flex-wrap: wrap; }
.vt-big b { font-size: clamp(44px, 12vw, 64px); font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; color: var(--t1); }
.vt-unit { font-size: 20px; font-weight: 800; color: var(--t2); }
.vt-tip { font-weight: 800; font-size: 17px; text-align: center; margin: 4px 0 0; }
.vt-warn { color: var(--danger-text); background: var(--danger-soft); border-radius: var(--r-sm); padding: 8px 12px; font-size: 14px; margin: 0; }
.vt-note { font-size: 12px; margin: 0; }
.vt-tcard .vt-tlast { display: grid; gap: 12px; max-width: 560px; }
.vt-hist { margin-top: 12px; }
.vt-hist summary { cursor: pointer; color: var(--t3); font-weight: 700; }
.vt-hrow { display: flex; gap: 12px; align-items: baseline; padding: 6px 0; border-top: 1px dashed var(--border); font-size: 14px; }
@media (max-width: 420px) { .vt-act .vt-yes, .vt-act .vt-no { min-height: 60px; } }

/* v3.17.0 雅思学生的上课页：雅思 / 高中课两块 */
.cl-blk { border: 1.5px solid var(--border); border-radius: var(--r-md); padding: 12px 16px 14px; margin: 12px 0; background: var(--surface); }
.cl-blk-ielts { border-left: 5px solid var(--btn); }
.cl-blk-h, .cl-blk-hs > summary { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.cl-blk-t { font-weight: 900; font-size: 17px; color: var(--t1); }
.cl-blk-h small, .cl-blk-hs > summary small { color: var(--t3); font-size: 13px; }
.cl-blk-hs > summary { cursor: pointer; list-style: none; padding: 2px 0; }
.cl-blk-hs > summary::-webkit-details-marker { display: none; }
.cl-blk-hs > summary::before { content: "▸"; color: var(--t3); font-size: 14px; transition: transform .15s; display: inline-block; }
.cl-blk-hs[open] > summary::before { transform: rotate(90deg); }
.cl-blk-hs[open] > summary { margin-bottom: 8px; }
.cl-blk .cl-hwa { margin-top: 14px; }
.cl-blk .cl-hwa h3 { margin: 0; font-size: 15.5px; }
.cl-blk .cl-hw { display: inline-flex; margin: 8px 0 0; }
@media (prefers-reduced-motion: reduce) { .cl-blk-hs > summary::before { transition: none; } }

/* v3.17.0 月结：每个月一行 */
.month-list { display: grid; gap: 8px; margin: 6px 0 4px; }
.month-row { display: grid; grid-template-columns: 4.2em 1fr auto; gap: 12px; align-items: start; padding: 10px 12px; border: 1.5px solid var(--border); border-radius: var(--r-md); }
.month-row.done { background: var(--surface-muted); }
.month-m { display: grid; line-height: 1.2; }
.month-m strong { font-size: 18px; }
.month-m span { font-size: 12px; }
.month-h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.month-h details { flex-basis: 100%; font-size: 13px; }
.month-h summary { cursor: pointer; }
.month-days { margin-top: 4px; }
.month-s { display: grid; justify-items: end; gap: 4px; font-size: 13px; text-align: right; }
