﻿/* ============================================================
   雅思鸭 · Andidas的全能提升宝典
   Design tokens + base
   ============================================================ */
:root {
  --bg: #f7f5f0;
  --bg-grad: radial-gradient(1200px 620px at 78% -10%, #ffffff 0%, #f8f6f1 50%, #f1ede5 100%);
  --surface: #ffffff;
  --surface-2: #fbfaf7;
  --surface-3: #f3f1ea;
  --ink: #191b1f;
  --ink-2: #3a3e45;
  --muted: #74777e;
  --faint: #9a9da4;
  --line: #e9e6de;
  --line-2: #f1eee7;
  --accent: #1c6b55;
  --accent-2: #2e8b6f;
  --accent-soft: #e6f1ec;
  --accent-ink: #124a3a;
  --again: #c75050;
  --hard: #b5822b;
  --good: #1c6b55;
  --easy: #4468b8;
  --shadow-sm: 0 1px 2px rgba(30, 26, 20, 0.05);
  --shadow: 0 1px 2px rgba(30, 26, 20, 0.04), 0 18px 40px -22px rgba(46, 38, 26, 0.22);
  --shadow-lg: 0 2px 4px rgba(30, 26, 20, 0.04), 0 40px 80px -40px rgba(46, 38, 26, 0.34);
  --radius: 22px;
  --radius-sm: 14px;
  --radius-xs: 10px;
  --radius-pill: 999px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.42, 0.64, 1);
  --dur-1: 0.14s;
  --dur-2: 0.24s;
  --dur-3: 0.42s;
  --font: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Source Serif Pro", Georgia,
    "Times New Roman", serif;
  --font-mono: "Cascadia Mono", "SF Mono", ui-monospace, Consolas, monospace;
  --sidebar-w: 236px;
  --page-max: 1180px;
  --mark-ring: rgba(16, 18, 22, 0.10);
  --splash-bg: radial-gradient(1100px 700px at 50% 32%, #fffdf7 0%, #f8f4ec 46%, #efe9de 100%);
}

:root[data-theme="dark"] {
  --bg: #0b0c0e;
  --bg-grad: radial-gradient(1200px 620px at 80% -12%, #171a1e 0%, #0d0f11 55%, #0a0b0d 100%);
  --surface: #14161a;
  --surface-2: #191c20;
  --surface-3: #1e2227;
  --ink: #eceef1;
  --ink-2: #c9cdd4;
  --muted: #9096a0;
  --faint: #6b717b;
  --line: #24272c;
  --line-2: #1d2024;
  --accent: #5fc9a8;
  --accent-2: #7fd9bc;
  --accent-soft: #16241f;
  --accent-ink: #b9f0dd;
  --again: #e07777;
  --hard: #d6a24a;
  --good: #5fc9a8;
  --easy: #7e9ce0;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 18px 40px -20px rgba(0, 0, 0, 0.8);
  --shadow-lg: 0 1px 2px rgba(0, 0, 0, 0.5), 0 40px 70px -34px rgba(0, 0, 0, 0.9);
  --mark-ring: rgba(255, 255, 255, 0.20);
  --splash-bg: radial-gradient(1100px 700px at 50% 32%, #1b1e22 0%, #131519 48%, #0b0c0e 100%);
}

@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] {
    --bg: #0b0c0e;
    --bg-grad: radial-gradient(1200px 620px at 80% -12%, #171a1e 0%, #0d0f11 55%, #0a0b0d 100%);
    --surface: #14161a;
    --surface-2: #191c20;
    --surface-3: #1e2227;
    --ink: #eceef1;
    --ink-2: #c9cdd4;
    --muted: #9096a0;
    --faint: #6b717b;
    --line: #24272c;
    --line-2: #1d2024;
    --accent: #5fc9a8;
    --accent-2: #7fd9bc;
    --accent-soft: #16241f;
    --accent-ink: #b9f0dd;
    --again: #e07777;
    --hard: #d6a24a;
    --good: #5fc9a8;
    --easy: #7e9ce0;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 18px 40px -20px rgba(0, 0, 0, 0.8);
    --shadow-lg: 0 1px 2px rgba(0, 0, 0, 0.5), 0 40px 70px -34px rgba(0, 0, 0, 0.9);
    --mark-ring: rgba(255, 255, 255, 0.20);
    --splash-bg: radial-gradient(1100px 700px at 50% 32%, #1b1e22 0%, #131519 48%, #0b0c0e 100%);
  }
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  background-image: var(--bg-grad);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow: hidden;
}

/* 一层很轻的斜向暖光，让大面积留白不死板 */
body::before {
  content: "";
  position: fixed;
  inset: -20%;
  pointer-events: none;
  z-index: 0;
  background: linear-gradient(112deg, transparent 34%, rgba(255, 205, 130, 0.10) 50%, transparent 66%);
}
:root[data-theme="dark"] body::before { opacity: 0.35; background: linear-gradient(112deg, transparent 34%, rgba(120, 200, 175, 0.06) 50%, transparent 66%); }
@media (prefers-color-scheme: dark) {
  :root[data-theme="auto"] body::before { opacity: 0.35; background: linear-gradient(112deg, transparent 34%, rgba(120, 200, 175, 0.06) 50%, transparent 66%); }
}
.app, .splash { position: relative; z-index: 1; }

h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0; }
button { font-family: inherit; font-size: inherit; color: inherit; border: 0; background: none; cursor: pointer; }
input, select, textarea { font-family: inherit; font-size: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
::selection { background: var(--accent-soft); color: var(--accent-ink); }

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 99px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: var(--faint); background-clip: content-box; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* ============================================================
   Layout · 顶部胶囊导航 + 大标题页头
   ============================================================ */
.app {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
}

.topnav {
  position: relative;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px clamp(20px, 3.2vw, 40px);
  border-bottom: 1px solid var(--line-2);
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  backdrop-filter: blur(18px) saturate(1.25);
  flex: 0 0 auto;
}

.brand { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.brand-mark {
  width: 34px; height: 34px; flex: 0 0 34px;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(16, 18, 22, 0.22), 0 0 0 1px var(--mark-ring);
  transition: transform 0.5s var(--ease-out);
}
.brand-mark svg { display: block; width: 100%; height: 100%; }
.brand:hover .brand-mark { transform: rotate(-4deg) scale(1.05); }
.brand-text { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.brand-text strong { font-size: 15.5px; font-weight: 800; letter-spacing: 0.01em; }
.brand-text span { font-size: 10.5px; color: var(--faint); letter-spacing: 0.08em; white-space: nowrap; }

.nav { display: flex; align-items: center; gap: 3px; flex: 0 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav { position: relative; }
.nav-pill {
  position: absolute; top: 50%; left: 0; height: 36px; width: 0;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  transform: translateY(-50%);
  transition: transform 0.34s var(--ease-spring), width 0.34s var(--ease-spring), opacity 0.2s;
  pointer-events: none; opacity: 0;
}
.nav-pill.is-ready { opacity: 1; }
.nav-item {
  position: relative;
  display: flex; align-items: center; gap: 7px;
  height: 36px; padding: 0 13px;
  border-radius: var(--radius-pill);
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 500;
  white-space: nowrap;
  background: transparent;
  transition: color 0.2s var(--ease);
}
.nav-item > * { position: relative; z-index: 1; }
.nav-item svg { width: 17px; height: 17px; flex: 0 0 17px; stroke-width: 1.7; opacity: 0.85; transition: transform 0.25s var(--ease-out); }
.nav-item:not(.is-active):hover { color: var(--ink); }
.nav-item:hover svg { transform: translateY(-1px) scale(1.06); }
.nav-item.is-active { color: var(--accent-ink); font-weight: 650; }
.nav-item.is-active svg { color: var(--accent); opacity: 1; }

.nav-badge {
  font-style: normal;
  font-size: 10.5px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  padding: 0 6px;
  height: 17px;
  line-height: 17px;
  border-radius: 99px;
  background: var(--surface-3);
  color: var(--muted);
  min-width: 18px;
  text-align: center;
}
.nav-item.is-active .nav-badge { background: var(--surface); color: var(--accent-ink); }

.topnav-right { margin-left: auto; display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.streak {
  display: inline-flex; align-items: center; gap: 4px;
  height: 28px; padding: 0 10px;
  border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--hard) 12%, transparent);
  color: var(--hard);
  font-size: 12px; font-weight: 600;
  white-space: nowrap;
}
.streak b { color: var(--ink); font-variant-numeric: tabular-nums; }
.streak svg { color: var(--hard); }
.date-chip { height: 28px; padding: 0 12px; background: var(--surface); border: 1px solid var(--line-2); font-variant-numeric: tabular-nums; }

.main { min-width: 0; flex: 1; display: flex; flex-direction: column; overflow: hidden; }

.view-head { position: relative; }
.view-head::before {
  content: "";
  position: absolute;
  left: -6%; top: -80px;
  width: 620px; height: 260px;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 10%, transparent), transparent 78%);
  pointer-events: none;
  z-index: -1;
}
.view-head {
  flex: 0 0 auto;
  max-width: var(--page-max);
  width: 100%;
  margin: 0 auto;
  padding: 26px clamp(20px, 3.2vw, 40px) 10px;
}
.view-head h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.032em; line-height: 1.15; }
.view-head p { font-size: 13.5px; color: var(--muted); margin-top: 7px; }

.icon-btn {
  width: 34px; height: 34px;
  display: grid; place-items: center;
  border-radius: var(--radius-pill);
  color: var(--muted);
  border: 1px solid transparent;
  transition: all 0.2s var(--ease);
}
.icon-btn:hover { background: var(--surface); color: var(--ink); border-color: var(--line-2); box-shadow: var(--shadow-sm); }
.icon-btn:active { transform: scale(0.94); }
.icon-btn svg { width: 18px; height: 18px; stroke-width: 1.7; }

.views { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; scroll-behavior: smooth; }
.view {
  display: none;
  max-width: var(--page-max);
  width: 100%;
  margin: 0 auto;
  padding: 6px clamp(20px, 3.2vw, 40px) 56px;
}
.view.is-active { display: block; animation: viewIn var(--dur-3) var(--ease-out); }
.view.is-active > .view-head, .view.is-active > .hero, .view.is-active > .grid-kpi { animation: riseIn 0.5s var(--ease-out) both; }
.view.is-active > *:nth-child(2) { animation-delay: 0.04s; }
.view.is-active > *:nth-child(3) { animation-delay: 0.08s; }
.view.is-active > *:nth-child(4) { animation-delay: 0.12s; }
@keyframes riseIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes viewIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* 柔和色块卡片（参考爱梨同学的浅色面） */
.kpi.tint-1 { background: color-mix(in srgb, var(--accent) 9%, var(--surface)); border-color: transparent; }
.rail-card.tint-1 { background: color-mix(in srgb, var(--accent) 5%, var(--surface)); border-color: transparent; }
.kpi.tint-2 { background: color-mix(in srgb, #e0a13c 15%, var(--surface)); border-color: transparent; }
.kpi.tint-3 { background: color-mix(in srgb, #6f86d6 12%, var(--surface)); border-color: transparent; }
.kpi.tint-4 { background: color-mix(in srgb, #c96f8e 11%, var(--surface)); border-color: transparent; }

.panel {
  background: var(--surface);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.panel-pad { padding: clamp(18px, 2.2vw, 26px); }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.panel-title { font-size: 15.5px; font-weight: 700; letter-spacing: -0.015em; }
.panel-sub { font-size: 12.5px; color: var(--faint); margin-top: 4px; line-height: 1.5; }
.eyebrow { font-size: 10.5px; font-weight: 700; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  height: 36px; padding: 0 17px;
  border-radius: var(--radius-pill);
  font-size: 13.5px; font-weight: 600;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  transition: all 0.2s var(--ease);
  white-space: nowrap;
}
.btn svg { width: 16px; height: 16px; stroke-width: 1.8; }
.btn:hover { border-color: var(--faint); box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.btn:active { transform: translateY(0) scale(0.985); }
.btn-primary { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.btn-primary:hover { background: var(--ink-2); border-color: var(--ink-2); }
.btn-accent { background: var(--accent); color: #fff; border-color: transparent; }
.btn-accent:hover { background: var(--accent-2); }
.btn-ghost { background: transparent; border-color: transparent; color: var(--muted); }
.btn-ghost:hover { background: var(--surface-3); color: var(--ink); box-shadow: none; }
.btn-sm { height: 30px; padding: 0 13px; font-size: 12.5px; border-radius: var(--radius-pill); }
.btn:disabled { opacity: 0.45; pointer-events: none; }

.chip {
  display: inline-flex; align-items: center; gap: 5px;
  height: 24px; padding: 0 10px;
  border-radius: var(--radius-pill);
  font-size: 11.5px; font-weight: 500;
  background: var(--surface-3);
  color: var(--muted);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.chip.tiny { height: 21px; padding: 0 8px; font-size: 11px; border-radius: var(--radius-pill); }
.chip-accent { background: var(--accent-soft); color: var(--accent-ink); }
.chip-outline { background: transparent; border: 1px solid var(--line); }

.seg {
  display: inline-flex; gap: 2px; padding: 3px;
  background: var(--surface-3);
  border-radius: var(--radius-pill);
  border: 1px solid var(--line-2);
}
.seg-btn {
  height: 30px; padding: 0 15px;
  border-radius: var(--radius-pill);
  font-size: 13px; font-weight: 500;
  color: var(--muted);
  transition: all 0.22s var(--ease);
}
.seg-btn:hover { color: var(--ink); }
.seg-btn.is-on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); font-weight: 600; }

.mini-select, .input {
  height: 34px;
  padding: 0 30px 0 11px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink-2);
  font-size: 13px;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%239a9da4' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  transition: border-color 0.2s, box-shadow 0.2s;
  cursor: pointer;
}
.mini-select:hover, .input:hover { border-color: var(--faint); }
.mini-select:focus, .input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.input { padding-right: 12px; cursor: text; }

.stat-num { font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.serif { font-family: var(--font-serif); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }

/* ============================================================
   Study view
   ============================================================ */
.study-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.study-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.session-bar { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.session-track { flex: 1; height: 4px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.session-fill {
  height: 100%; width: 0;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transition: width 0.55s var(--ease-out);
}
.session-count { font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; white-space: nowrap; }
.session-count b { color: var(--ink); font-weight: 600; }

.study-body { display: grid; grid-template-columns: minmax(0, 1fr) 248px; gap: 20px; align-items: start; }
@media (max-width: 1080px) { .study-body { grid-template-columns: 1fr; } .study-rail { display: none; } }

/* 大屏上把卡片放在视觉中心，避免下方空荡 */
@media (min-width: 1081px) {
  #v-study.is-active { display: flex; flex-direction: column; min-height: calc(100dvh - 190px); }
  #v-study.is-active .study-body { flex: 1; align-content: center; }
}

/* 3D card */
.card3d {
  position: relative;
  height: 400px;
  perspective: 1800px;
  cursor: pointer;
  transform-style: preserve-3d;
  transition: transform 0.4s var(--ease-out);
}
@media (min-width: 901px) {
  .card3d:hover { transform: translateY(-2px); }
}
.card3d-inner {
  position: relative; width: 100%; height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.62s cubic-bezier(0.24, 0.86, 0.28, 1);
}
.card3d.is-flipped .card3d-inner { transform: rotateY(180deg); }
.card3d.is-out { animation: cardOut 0.3s var(--ease) forwards; }
@keyframes cardOut { to { opacity: 0; transform: translateY(-12px) scale(0.985); } }
.card3d.is-in { animation: cardIn 0.42s var(--ease-out); }
@keyframes cardIn { from { opacity: 0; transform: translateY(14px) scale(0.985); } to { opacity: 1; transform: none; } }

.face {
  position: absolute; inset: 0;
  border-radius: 28px;
  scrollbar-width: none;
  background: linear-gradient(168deg, var(--surface) 0%, color-mix(in srgb, var(--accent) 3%, var(--surface)) 100%);
  border: 1px solid var(--line-2);
  box-shadow: var(--shadow-lg);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  padding: clamp(24px, 3vw, 38px);
  display: flex; flex-direction: column;
  overflow: auto;
  transform: translateZ(0.1px);
}
.face.back { transform: rotateY(180deg) translateZ(0.1px); }
.face::-webkit-scrollbar { width: 0; height: 0; }

.face-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: auto; position: relative; z-index: 1; }
.face-tags { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

.card-mark {
  position: absolute;
  right: -18px; bottom: -10px;
  width: 286px; height: 122px;
  color: var(--line);
  opacity: 0.75;
  pointer-events: none;
  z-index: 0;
}

.word-wrap { display: flex; align-items: center; justify-content: center; gap: 14px; margin: 8px 0 6px; position: relative; z-index: 1; }
.word {
  font-family: var(--font-serif);
  font-size: clamp(40px, 5.4vw, 58px);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.1;
  text-align: center;
  word-break: break-word;
  min-width: 0;
  animation: wordIn 0.5s var(--ease-out);
}
.word.len-m { font-size: clamp(32px, 4.4vw, 46px); }
.word.len-l { font-size: clamp(26px, 3.6vw, 38px); letter-spacing: -0.01em; }
.word.len-xl { font-size: clamp(22px, 3vw, 30px); letter-spacing: 0; }
.word.sm { font-size: clamp(26px, 3.4vw, 34px); }
@keyframes wordIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.speak-btn {
  width: 40px; height: 40px; flex: 0 0 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: var(--accent);
  background: var(--accent-soft);
  transition: all 0.25s var(--ease);
}
.speak-btn:hover { transform: scale(1.08); background: var(--accent); color: #fff; }
.speak-btn:active { transform: scale(0.96); }
.speak-btn svg { width: 19px; height: 19px; stroke-width: 1.8; }
.speak-btn.is-playing { animation: pulse 1.1s var(--ease) infinite; }
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 35%, transparent); }
  70% { box-shadow: 0 0 0 10px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

.face-foot { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: auto; padding-top: 18px; position: relative; z-index: 1; }
.hint { font-size: 12.5px; color: var(--faint); display: flex; align-items: center; gap: 7px; }
kbd {
  display: inline-grid; place-items: center;
  min-width: 22px; height: 21px; padding: 0 6px;
  font-family: var(--font); font-size: 10.5px; font-weight: 600;
  color: var(--muted);
  background: var(--surface-3);
  border: 1px solid var(--line);
  border-bottom-width: 2px;
  border-radius: 5px;
}

.back-inner { display: flex; flex-direction: column; gap: 16px; height: 100%; }
.back-body {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 15px;
}
.back-word-row { display: flex; align-items: center; gap: 10px; }
.back-word-row .speak-btn { width: 32px; height: 32px; flex-basis: 32px; }
.back-word-row .speak-btn svg { width: 16px; height: 16px; }
.back-word { font-family: var(--font-serif); font-size: 26px; font-weight: 500; letter-spacing: -0.01em; }
.pos { font-size: 12px; font-style: italic; color: var(--faint); }

.meaning { font-size: clamp(24px, 3vw, 31px); font-weight: 600; letter-spacing: -0.01em; line-height: 1.35; }
.example-block {
  padding: 15px 17px;
  border-radius: 13px;
  background: var(--surface-2);
  border: 1px solid var(--line-2);
  border-left: 2px solid var(--accent);
}
.example-en { font-size: 16.5px; line-height: 1.62; color: var(--ink-2); font-family: var(--font-serif); }
.example-en mark { background: none; color: var(--accent); font-weight: 600; font-style: normal; }
.example-cn { font-size: 13px; color: var(--muted); margin-top: 7px; line-height: 1.6; }
.syn-row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.syn-label { font-size: 11.5px; color: var(--faint); margin-right: 2px; }
.syn-chip { font-size: 12px; padding: 3px 9px; border-radius: 6px; background: var(--accent-soft); color: var(--accent-ink); font-family: var(--font-serif); }

.exam-note {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 11px 14px;
  border-radius: 11px;
  background: var(--surface-2);
  border: 1px dashed var(--line);
  font-size: 12px; color: var(--muted);
}
.exam-text { line-height: 1.5; }

/* Ratings */
.ratings { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 18px; }
.ratings.is-locked { opacity: 0.38; pointer-events: none; filter: saturate(0.4); }
.rating {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 11px 8px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--surface);
  transition: all 0.2s var(--ease);
  position: relative;
  overflow: hidden;
}
.rating::after {
  content: ""; position: absolute; inset: 0;
  background: currentColor; opacity: 0;
  transition: opacity 0.2s;
}
.rating:hover { transform: translateY(-2px); box-shadow: var(--shadow); border-color: currentColor; }
.rating:active { transform: translateY(0) scale(0.98); }
.r-lbl { font-size: 13.5px; font-weight: 600; z-index: 1; }
.r-iv { font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; z-index: 1; }
.r-key { position: absolute; top: 5px; right: 7px; font-size: 9.5px; color: var(--faint); opacity: 0.7; z-index: 1; }
.rating[data-g="1"] { color: var(--again); }
.rating[data-g="2"] { color: var(--hard); }
.rating[data-g="3"] { color: var(--good); }
.rating[data-g="4"] { color: var(--easy); }
.rating[data-g="3"] { border-color: color-mix(in srgb, var(--good) 28%, var(--line)); }

.rail-card { padding: 17px; border-radius: 15px; background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); }
.study-rail { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 0; }
.rail-title { font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); margin-bottom: 12px; }
.kv { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 0; font-size: 12.5px; }
.kv + .kv { border-top: 1px dashed var(--line-2); }
.kv span { color: var(--muted); }
.kv b { font-variant-numeric: tabular-nums; font-weight: 600; }
.mini-curve { width: 100%; height: 74px; display: block; margin-top: 10px; }

/* Empty / summary */
.empty-state { display: flex; flex-direction: column; align-items: center; gap: 16px; padding: 56px 20px; text-align: center; }
.empty-art { width: 120px; height: 120px; opacity: 0.9; }
.empty-state h3 { font-size: 18px; }
.empty-state p { font-size: 13.5px; color: var(--muted); max-width: 380px; line-height: 1.7; }
.empty-actions { display: flex; gap: 10px; margin-top: 4px; }

.summary { display: grid; gap: 18px; padding: clamp(24px, 3vw, 36px); }
.summary-head { display: flex; align-items: center; gap: 16px; }
.summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.summary-cell { padding: 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); }
.summary-cell em { display: block; font-style: normal; font-size: 11px; letter-spacing: 0.06em; color: var(--faint); text-transform: uppercase; }
.summary-cell strong { font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.summary-cell span { font-size: 11.5px; color: var(--muted); margin-left: 3px; }

.study-foot {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-top: 14px; padding: 10px 4px;
  font-size: 12px; color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.study-foot b { color: var(--ink); font-weight: 600; }
.study-foot .sep { width: 1px; height: 11px; background: var(--line); }

/* Spelling / listening modes */
.spell-box { display: flex; flex-direction: column; align-items: center; gap: 18px; padding: 8px 0; }
.spell-prompt { font-size: 13px; color: var(--faint); }
.big-meaning { font-size: clamp(28px, 4vw, 38px); font-weight: 600; text-align: center; line-height: 1.4; }
.spell-input {
  width: min(420px, 100%);
  height: 54px;
  text-align: center;
  font-family: var(--font-serif);
  font-size: 26px;
  letter-spacing: 0.02em;
  border: 1px solid var(--line);
  border-bottom: 2px solid var(--faint);
  border-radius: 12px;
  background: var(--surface);
  transition: all 0.2s var(--ease);
}
.spell-input:focus { outline: none; border-color: var(--accent); border-bottom-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.spell-input.is-wrong { animation: shake 0.42s var(--ease); border-color: var(--again); }
.spell-input.is-ok { border-color: var(--good); box-shadow: 0 0 0 4px color-mix(in srgb, var(--good) 14%, transparent); }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-7px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(2px); }
}
.answer-line { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); min-height: 22px; }
.answer-line b { color: var(--ink); font-family: var(--font-serif); font-size: 17px; }

.options { display: grid; gap: 9px; width: 100%; }
.option {
  display: flex; align-items: center; gap: 12px;
  padding: 13px 16px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 14.5px;
  text-align: left;
  transition: all 0.18s var(--ease);
}
.option:hover { border-color: var(--faint); transform: translateX(2px); }
.option .idx { width: 20px; font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; }
.option.is-ok { border-color: var(--good); background: color-mix(in srgb, var(--good) 8%, var(--surface)); }
.option.is-bad { border-color: var(--again); background: color-mix(in srgb, var(--again) 8%, var(--surface)); }
.option:disabled { cursor: default; transform: none; }

/* ============================================================
   Memory view
   ============================================================ */
.hero-curve { padding: clamp(20px, 2.6vw, 30px); }
.curve-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; flex-wrap: wrap; margin-bottom: 8px; }
.curve-title-row { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.curve-word { font-family: var(--font-serif); font-size: 22px; font-weight: 500; }
.curve-canvas-wrap { position: relative; margin-top: 6px; }
canvas.curve { width: 100%; height: 300px; display: block; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 11.5px; color: var(--muted); margin-top: 12px; }
.legend i { width: 14px; height: 2px; border-radius: 2px; display: inline-block; margin-right: 6px; vertical-align: middle; }
.legend .dot { width: 7px; height: 7px; border-radius: 50%; }

.formula {
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--ink-2);
  background: var(--surface-2);
  border: 1px solid var(--line-2);
  border-radius: 11px;
  padding: 13px 15px;
  margin-top: 14px;
  line-height: 1.85;
  overflow-x: auto;
}
.formula b { color: var(--accent); font-weight: 600; }

.bars-wrap { position: relative; }
canvas.bars { width: 100%; height: 190px; display: block; }
.load-note { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--faint); margin-top: 8px; }

.hist { display: flex; flex-direction: column; gap: 11px; margin-top: 4px; }
.hist-row { display: grid; grid-template-columns: 62px 1fr 42px; gap: 10px; align-items: center; font-size: 12px; }
.hist-row span:first-child { color: var(--muted); }
.hist-row b { font-variant-numeric: tabular-nums; text-align: right; font-weight: 600; }
.hist-track { height: 7px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.hist-fill { height: 100%; border-radius: 99px; background: var(--accent); transition: width 0.8s var(--ease-out); }

.gauge-wrap { display: flex; align-items: center; gap: 22px; }
.gauge {
  position: relative; width: 128px; height: 128px; flex: 0 0 128px;
  border-radius: 50%;
  background: conic-gradient(var(--accent) calc(var(--v) * 1%), var(--line-2) 0);
  transition: background 0.8s var(--ease-out);
  display: grid; place-items: center;
}
.gauge::before { content: ""; position: absolute; inset: 11px; border-radius: 50%; background: var(--surface); }
.gauge-inner { position: relative; text-align: center; line-height: 1.2; }
.gauge-inner strong { font-size: 26px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.gauge-inner em { font-style: normal; font-size: 11px; color: var(--faint); display: block; }

/* ============================================================
   Library
   ============================================================ */
.lib-toolbar { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.lib-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.search { position: relative; flex: 1; min-width: 220px; max-width: 420px; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--faint); stroke-width: 1.8; pointer-events: none; }
.search input {
  width: 100%; height: 38px;
  padding: 0 12px 0 36px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 13.5px;
  transition: all 0.2s var(--ease);
}
.search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.subject-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.schip {
  height: 30px; padding: 0 13px;
  border-radius: var(--radius-pill);
  font-size: 12.5px;
  color: var(--muted);
  border: 1px solid var(--line);
  background: var(--surface);
  transition: all 0.18s var(--ease);
  display: inline-flex; align-items: center; gap: 6px;
}
.schip:hover { border-color: var(--faint); color: var(--ink); }
.schip.is-on { background: var(--ink); color: var(--surface); border-color: var(--ink); }
.schip em { font-style: normal; font-size: 10.5px; opacity: 0.6; font-variant-numeric: tabular-nums; }

.lib-list { border-radius: var(--radius); border: 1px solid var(--line-2); background: var(--surface); overflow: hidden; box-shadow: var(--shadow); }
.lib-row { display: flex; align-items: center; gap: 14px; padding: 12px 18px; border-bottom: 1px solid var(--line-2); cursor: pointer; transition: background 0.16s; }
.lib-row:hover { background: var(--surface-2); }
.lib-row:last-child { border-bottom: 0; }
.lib-row-main { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 12px; }
.lib-word { font-family: var(--font-serif); font-size: 16px; font-weight: 500; min-width: 150px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lib-mean { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lib-side { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--line); }
.dot.new { background: var(--faint); }
.dot.learning { background: var(--hard); }
.dot.review { background: var(--accent); }
.dot.mastered { background: var(--easy); }
.lib-detail { padding: 18px 20px 22px; background: var(--surface-2); border-bottom: 1px solid var(--line-2); animation: detailIn 0.32s var(--ease-out); }
@keyframes detailIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.lib-detail-grid { display: grid; grid-template-columns: 1fr 240px; gap: 22px; }
@media (max-width: 860px) { .lib-detail-grid { grid-template-columns: 1fr; } }
.lib-more { display: flex; justify-content: center; padding: 18px; }

/* ============================================================
   Stats
   ============================================================ */
.kpi { padding: 18px; border-radius: 15px; background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--shadow-sm); position: relative; overflow: hidden; }
.kpi em { font-style: normal; font-size: 11.5px; color: var(--faint); letter-spacing: 0.04em; display: block; margin-bottom: 8px; }
.kpi strong { font-size: 27px; font-weight: 600; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; line-height: 1; }
.kpi span { font-size: 11.5px; color: var(--muted); margin-left: 4px; }
.kpi .kpi-spark { position: absolute; right: 12px; bottom: 12px; font-size: 11px; color: var(--faint); }
.kpi::after {
  content: ""; position: absolute; right: -20px; top: -20px; width: 70px; height: 70px;
  border-radius: 50%; background: var(--accent-soft); opacity: 0.55;
}

.heatmap { display: flex; gap: 3px; overflow-x: auto; padding: 0 0 4px; }
.hm-col { display: flex; flex-direction: column; gap: 3px; }
.hm-cell { width: 15px; height: 15px; border-radius: 3.5px; background: var(--line-2); transition: transform 0.15s, background 0.3s; }
.hm-cell:hover { transform: scale(1.22); }
.hm-cell.l1 { background: color-mix(in srgb, var(--accent) 22%, var(--surface-3)); }
.hm-cell.l2 { background: color-mix(in srgb, var(--accent) 45%, var(--surface-3)); }
.hm-cell.l3 { background: color-mix(in srgb, var(--accent) 70%, var(--surface-3)); }
.hm-cell.l4 { background: var(--accent); }
.hm-cell.empty { background: transparent; }
.hm-legend { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--faint); }
.hm-legend .hm-cell { width: 11px; height: 11px; }

.hm-row { display: flex; gap: 32px; align-items: flex-start; flex-wrap: wrap; }
.hm-block { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.hm-months { display: flex; gap: 3px; padding-left: 22px; height: 14px; }
.hm-month { width: 15px; flex: 0 0 15px; font-size: 10px; color: var(--faint); white-space: nowrap; overflow: visible; }
.hm-body { display: flex; gap: 6px; }
.hm-days { display: flex; flex-direction: column; gap: 3px; width: 16px; }
.hm-days span { height: 15px; line-height: 15px; font-size: 9.5px; color: var(--faint); text-align: right; }
.hm-side { display: flex; gap: 26px; flex-wrap: wrap; padding: 4px 0 0; }
.hm-stat em { display: block; font-style: normal; font-size: 11px; color: var(--faint); margin-bottom: 5px; letter-spacing: 0.02em; }
.hm-stat b { font-size: 21px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.hm-stat span { font-size: 11.5px; color: var(--muted); margin-left: 3px; }

.subj-progress { display: flex; flex-direction: column; gap: 14px; }
.sp-row { display: grid; grid-template-columns: 96px 1fr 74px; gap: 12px; align-items: center; font-size: 12.5px; }
.sp-name { color: var(--ink-2); display: flex; align-items: center; gap: 7px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-name i { width: 6px; height: 6px; border-radius: 2px; background: var(--accent); opacity: 0.75; flex: 0 0 6px; }
.sp-name em { font-style: normal; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sp-track { height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; position: relative; }
.sp-fill { height: 100%; border-radius: 99px; background: var(--accent); transition: width 0.9s var(--ease-out); }
.sp-fill.secondary { background: var(--easy); position: absolute; left: 0; top: 0; opacity: 0.55; }
.sp-val { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; font-size: 11.5px; }

/* ============================================================
   Settings
   ============================================================ */
.set-group { margin-bottom: 16px; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 15px 0; border-bottom: 1px solid var(--line-2); }
.set-row:last-child { border-bottom: 0; }
.set-label { font-size: 13.5px; }
.set-desc { font-size: 12px; color: var(--faint); margin-top: 3px; max-width: 420px; line-height: 1.55; }
.set-control { flex: 0 0 auto; display: flex; align-items: center; gap: 8px; }

.switch { position: relative; width: 42px; height: 24px; flex: 0 0 42px; border-radius: 99px; background: var(--line); transition: background 0.25s var(--ease); }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform 0.25s var(--ease-out); }
.switch.is-on { background: var(--accent); }
.switch.is-on::after { transform: translateX(18px); }

input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 140px; height: 4px; border-radius: 99px;
  background: var(--line);
  outline: none;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--surface);
  border: 1.5px solid var(--accent);
  box-shadow: 0 1px 4px rgba(0,0,0,.18);
  cursor: pointer;
  transition: transform 0.15s;
}
input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.15); }
.range-val { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; min-width: 42px; text-align: right; }

.about { font-size: 12.5px; color: var(--muted); line-height: 1.85; }
.about code { font-family: var(--font-mono); font-size: 11.5px; background: var(--surface-3); padding: 1px 5px; border-radius: 4px; }

/* ============================================================
   Reading bank
   ============================================================ */
.nav-group {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--faint);
  padding: 12px 12px 4px;
  font-weight: 600;
}
.nav-group:first-child { padding-top: 0; }

.tag {
  display: inline-flex; align-items: center;
  height: 20px; padding: 0 7px;
  border-radius: 5px;
  font-size: 10.5px; font-weight: 500;
  background: var(--surface-3);
  color: var(--muted);
  white-space: nowrap;
}
.tag.hot { background: color-mix(in srgb, var(--accent) 15%, transparent); color: var(--accent-ink); }
.tag.mid { background: color-mix(in srgb, var(--easy) 15%, transparent); color: var(--easy); }
.tag.warn { background: color-mix(in srgb, var(--again) 15%, transparent); color: var(--again); }

.rd-hero {
  display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap;
  margin-bottom: 16px;
  background: linear-gradient(118deg, color-mix(in srgb, var(--accent) 7%, var(--surface)) 0%, var(--surface) 46%, color-mix(in srgb, var(--hard) 5%, var(--surface)) 100%);
}
.rd-hero-title { font-size: 26px; font-weight: 700; letter-spacing: -0.03em; margin-top: 6px; }
.rd-hero-stats { display: flex; gap: 28px; }
.rd-hero-stats div { display: flex; flex-direction: column; gap: 2px; }
.rd-hero-stats b { font-size: 24px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.rd-hero-stats span { font-size: 11.5px; color: var(--faint); }

.rd-toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.rd-toolbar .search { flex: 1; min-width: 200px; max-width: 360px; }

.rd-list {
  border-radius: var(--radius);
  border: 1px solid var(--line-2);
  background: var(--surface);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.rd-row {
  display: flex; align-items: center; gap: 14px;
  width: 100%;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line-2);
  background: var(--surface);
  text-align: left;
  transition: background 0.15s;
}
.rd-row:last-child { border-bottom: 0; }
.rd-row:hover { background: var(--surface-2); }
.rd-cat {
  flex: 0 0 auto;
  display: inline-grid; place-items: center;
  min-width: 34px; height: 22px; padding: 0 8px;
  border-radius: 6px;
  font-size: 11px; font-weight: 600; letter-spacing: 0.02em;
  background: var(--surface-3); color: var(--muted);
}
.rd-cat.c-p1 { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent-ink); }
.rd-cat.c-p2 { background: color-mix(in srgb, var(--easy) 16%, transparent); color: var(--easy); }
.rd-cat.c-p3 { background: color-mix(in srgb, var(--hard) 17%, transparent); color: var(--hard); }
.rd-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.rd-en {
  font-family: var(--font-serif);
  font-size: 15.5px;
  font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.rd-zh { font-size: 11.5px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rd-meta { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.rd-diff { width: 40px; height: 4px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.rd-diff i { display: block; height: 100%; border-radius: 99px; background: var(--hard); }
.rd-state { flex: 0 0 62px; text-align: right; font-size: 12px; font-variant-numeric: tabular-nums; }
.rd-todo { color: var(--faint); }
.rd-pct { color: var(--accent); font-weight: 600; }
.rd-check { color: var(--accent); margin-left: 4px; }

.rd-loading { display: flex; align-items: center; gap: 16px; }
.spinner {
  width: 26px; height: 26px; border-radius: 50%;
  border: 2px solid var(--line);
  border-top-color: var(--accent);
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.rd-stat { padding: 14px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); }
.rd-stat b { display: block; font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.rd-stat span { font-size: 11.5px; color: var(--faint); }

/* ============================================================
   Reader
   ============================================================ */
body.is-reader .view-head { display: none; }
body.is-reader .views { overflow: hidden; }
body.is-reader .topnav { border-bottom-color: transparent; }
body.is-reader .main { padding-bottom: 0; }
#v-reader { padding: 0 !important; max-width: none !important; }
#v-reader.is-active { display: flex; height: 100%; }

.reader { display: flex; flex-direction: column; width: 100%; height: 100%; }
.reader-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 86%, transparent);
  backdrop-filter: blur(12px);
  flex: 0 0 auto;
}
.reader-title { min-width: 0; }
.rt-en {
  font-family: var(--font-serif);
  font-size: 16px; font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  max-width: 42vw;
}
.rt-zh { font-size: 11.5px; color: var(--faint); }
.reader-spacer { flex: 1; }
.reader-timer, .reader-score {
  font-size: 12.5px; color: var(--muted);
  font-variant-numeric: tabular-nums;
  padding: 4px 10px; border-radius: 8px;
  background: var(--surface-3);
  white-space: nowrap;
}
.reader-score { color: var(--accent-ink); background: var(--accent-soft); }

.reader-body { flex: 1; display: flex; min-height: 0; }
.reader-doc { flex: 1; min-width: 0; display: flex; flex-direction: column; background: var(--surface-2); min-height: 0; }

.doc-bar {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 18px;
  border-bottom: 1px solid var(--line-2);
  background: var(--surface);
  flex: 0 0 auto;
}
.doc-cap { font-size: 10.5px; font-weight: 600; letter-spacing: 0.12em; color: var(--faint); text-transform: uppercase; }
.doc-pages { font-size: 11px; color: var(--faint); }
.doc-spacer { flex: 1; }
.doc-btn {
  height: 26px; padding: 0 10px;
  border-radius: 7px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 11.5px; color: var(--muted);
  transition: all 0.16s var(--ease);
}
.doc-btn:hover { border-color: var(--faint); color: var(--ink); }

.doc-scroll { flex: 1; overflow-y: auto; padding: 30px clamp(24px, 5vw, 72px) 64px; }
.doc-page { max-width: 660px; margin: 0 auto; }
.doc-page-sep { margin-top: 30px; padding-top: 30px; border-top: 1px dashed var(--line); }
.doc-para {
  font-family: var(--font-serif);
  font-size: 16px;
  line-height: 1.95;
  color: var(--ink);
  margin: 0 0 20px;
}
.doc-label {
  display: inline-block;
  min-width: 1.5em;
  font-weight: 600;
  color: var(--accent);
  font-family: var(--font);
}
.doc-line { font-size: 13.5px; line-height: 1.9; color: var(--ink-2); margin-bottom: 4px; }
.doc-title {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin: 4px 0 22px;
}
.doc-head {
  font-size: 11px; font-weight: 600; letter-spacing: 0.1em;
  color: var(--faint); text-transform: uppercase;
  margin: 22px 0 12px;
}
.doc-head:first-child { margin-top: 0; }
.doc-loading { display: flex; align-items: center; gap: 12px; justify-content: center; padding: 50px 0; color: var(--faint); font-size: 13px; }
.doc-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 70px 20px; color: var(--faint); font-size: 12.5px; }
.doc-empty b { color: var(--ink-2); font-size: 14px; }

.reader-panel {
  width: 396px; flex: 0 0 396px;
  border-left: 1px solid var(--line);
  background: var(--surface);
  display: flex; flex-direction: column;
  min-height: 0;
}
.panel-switch { display: flex; gap: 4px; padding: 10px 12px; border-bottom: 1px solid var(--line-2); flex: 0 0 auto; }
.panel-switch button {
  flex: 1; height: 32px; border-radius: 8px;
  font-size: 12.5px; color: var(--muted);
  background: transparent;
  transition: all 0.18s var(--ease);
}
.panel-switch button em { font-style: normal; font-size: 10.5px; opacity: 0.6; margin-left: 3px; }
.panel-switch button.is-on { background: var(--surface-3); color: var(--ink); font-weight: 600; }
.reader-list { flex: 1; overflow-y: auto; padding: 12px; }

.q-group { margin-bottom: 18px; }
.q-group-title {
  font-size: 11px; font-weight: 600; letter-spacing: 0.05em;
  color: var(--faint);
  margin: 4px 2px 10px;
}
.q-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 11px 12px;
  margin-bottom: 9px;
  background: var(--surface);
  transition: border-color 0.2s, background 0.2s;
}
.q-item.is-ok { border-color: color-mix(in srgb, var(--good) 45%, var(--line)); }
.q-item.is-bad { border-color: color-mix(in srgb, var(--again) 42%, var(--line)); }
.q-item.is-pending { border-color: color-mix(in srgb, var(--hard) 45%, var(--line)); }
.q-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.q-num {
  font-size: 12px; font-weight: 600;
  font-variant-numeric: tabular-nums;
  padding: 1px 7px; border-radius: 6px;
  background: var(--surface-3); color: var(--ink-2);
}
.q-otype { font-size: 10.5px; color: var(--faint); letter-spacing: 0.03em; }
.q-flagwrap { margin-left: auto; }
.q-flag { font-size: 12px; font-weight: 700; }
.q-flag.ok { color: var(--good); }
.q-flag.bad { color: var(--again); }
.q-flag.mid { color: var(--hard); }
.q-q { font-size: 13.5px; line-height: 1.65; color: var(--ink); }
.q-cn { font-size: 12px; color: var(--muted); margin-top: 5px; line-height: 1.6; }

.q-opts { display: flex; gap: 6px; margin-top: 10px; flex-wrap: wrap; }
.q-opt {
  min-width: 40px; height: 32px; padding: 0 11px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 12.5px; font-weight: 600;
  color: var(--ink-2);
  transition: all 0.16s var(--ease);
}
.q-opt:hover { border-color: var(--faint); }
.q-opt.is-picked { background: var(--ink); border-color: var(--ink); color: var(--surface); }
.q-opt.is-answer { border-color: var(--good); box-shadow: 0 0 0 2px color-mix(in srgb, var(--good) 18%, transparent); }

.q-fill { display: flex; gap: 6px; margin-top: 10px; }
.q-fill input {
  flex: 1; height: 34px; padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 13px;
}
.q-fill input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.q-fill input:disabled { background: var(--surface-2); color: var(--muted); }

.q-res { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--line-2); }
.q-ansline { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--muted); flex-wrap: wrap; }
.q-ansline b { color: var(--ink); font-size: 14px; font-family: var(--font-serif); }
.q-verdict { font-size: 11.5px; font-weight: 600; padding: 1px 7px; border-radius: 5px; }
.q-verdict.ok { color: var(--good); background: color-mix(in srgb, var(--good) 12%, transparent); }
.q-verdict.bad { color: var(--again); background: color-mix(in srgb, var(--again) 12%, transparent); }
.q-self { display: flex; gap: 6px; margin-left: auto; }
.btn-xs { height: 26px; padding: 0 9px; font-size: 11.5px; border-radius: 7px; }
.q-ansfull { font-size: 12px; color: var(--muted); margin-top: 4px; }
.q-exp {
  font-size: 12px; color: var(--ink-2); line-height: 1.7;
  margin-top: 8px; padding: 9px 11px;
  border-radius: 8px;
  background: var(--surface-2);
  border-left: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
}

.rd-notes { display: flex; flex-direction: column; gap: 12px; }
.rd-note { border-left: 2px solid var(--line); padding-left: 10px; }
.rd-note-label { font-size: 11px; font-weight: 600; color: var(--accent); letter-spacing: 0.03em; }
.rd-note-text { font-size: 12.5px; color: var(--ink-2); line-height: 1.75; margin-top: 3px; }

.rd-empty-panel { display: flex; flex-direction: column; gap: 6px; padding: 26px 16px; text-align: center; color: var(--faint); font-size: 12.5px; }
.rd-empty-panel b { color: var(--ink-2); font-size: 13.5px; }

.rd-summary { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 18px 8px; }
.rd-sum-emoji { font-size: 34px; line-height: 1; }
.rd-sum-title { font-size: 15px; font-weight: 600; margin-top: 8px; }
.rd-sum-ring {
  position: relative;
  width: 108px; height: 108px; margin: 16px 0;
  border-radius: 50%;
  background: conic-gradient(var(--accent) calc(var(--v) * 1%), var(--line-2) 0);
  display: grid; place-items: center;
}
.rd-sum-ring::before { content: ""; position: absolute; inset: 9px; border-radius: 50%; background: var(--surface); }
.rd-sum-ring b { position: relative; font-size: 24px; font-weight: 600; letter-spacing: -0.02em; }
.rd-sum-ring span { position: absolute; bottom: 22px; font-size: 10px; color: var(--faint); }
.rd-sum-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; width: 100%; margin-bottom: 12px; }
.rd-sum-grid div { padding: 10px 6px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line-2); }
.rd-sum-grid b { display: block; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.rd-sum-grid span { font-size: 10.5px; color: var(--faint); }
.rd-sum-wrong { font-size: 12px; color: var(--again); margin-bottom: 14px; }
.rd-sum-wrong.ok { color: var(--good); }
.rd-sum-actions { display: flex; gap: 8px; }

@media (max-width: 1080px) {
  .reader-panel { width: 340px; flex-basis: 340px; }
}
@media (max-width: 900px) {
  body.is-reader .topnav { display: none; }
  .topnav {
    flex-wrap: wrap;
    gap: 8px 10px;
    padding: 10px 16px 12px;
    /* backdrop-filter 会成为 fixed 子元素的包含块，移动端要关掉，底部导航才能真正贴底 */
    backdrop-filter: none;
    background: var(--bg);
  }
  .brand-text span { display: none; }
  .nav {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 60;
    order: 3;
    display: flex;
    justify-content: space-around;
    gap: 0;
    padding: 6px 6px calc(6px + env(safe-area-inset-bottom));
    background: color-mix(in srgb, var(--surface) 88%, transparent);
    backdrop-filter: blur(20px) saturate(1.2);
    border-top: 1px solid var(--line-2);
    overflow: visible;
  }
  .nav-item {
    flex-direction: column;
    gap: 3px;
    height: auto;
    padding: 6px 8px;
    font-size: 10.5px;
    border-radius: 14px;
    flex: 1;
    align-items: center;
    justify-content: center;
    background: transparent;
  }
  .nav-item span { white-space: nowrap; font-size: 10px; }
  .nav-item.is-active { background: var(--accent-soft); }
  .nav-item.is-active::after {
    content: "";
    position: absolute; inset: auto 0 -3px;
    display: none;
  }
  .nav-badge {
    position: absolute;
    top: 2px;
    right: 50%;
    transform: translateX(26px);
    height: 15px;
    line-height: 15px;
    font-size: 9.5px;
    padding: 0 5px;
    min-width: 15px;
  }
  .topnav-right { margin-left: auto; gap: 4px; }
  .date-chip { display: none; }
  .main { padding-bottom: 0; }
  .views { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
  .view-head { padding: 18px 18px 8px; }
  .view-head h1 { font-size: 25px; }
  .view-head p { font-size: 12.5px; margin-top: 5px; }
  .view { padding: 4px 16px 26px; }
}

@media (max-width: 560px) {
  .study-tools { width: 100%; }
  .seg-btn { padding: 0 10px; font-size: 12px; }
  .lib-mean { display: none; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* ============================================================
   Splash（启动动画）
   ============================================================ */
.splash {
  position: fixed; inset: 0; z-index: 300;
  display: grid; place-items: center;
  background: var(--splash-bg);
  transition: opacity 0.55s var(--ease), visibility 0.55s;
}
.splash::after {
  content: "";
  position: absolute; inset: -15%;
  background: linear-gradient(112deg, transparent 36%, color-mix(in srgb, var(--accent) 9%, transparent) 50%, transparent 64%);
  pointer-events: none;
}
.splash.is-out { opacity: 0; visibility: hidden; }

.splash-inner { position: relative; display: flex; flex-direction: column; align-items: center; }

.splash-tile {
  width: 104px; height: 104px; padding: 10px;
  border-radius: 30px;
  background: #fff;
  box-shadow: 0 24px 50px -24px rgba(50, 40, 25, 0.45), 0 1px 0 rgba(255, 255, 255, 0.9) inset;
  animation: splashTile 0.5s var(--ease-out) both;
}
.splash-tile svg { display: block; width: 100%; height: 100%; border-radius: 22px; }

.splash-name {
  margin-top: 30px;
  font-size: 40px; font-weight: 800;
  letter-spacing: 0.04em;
  color: var(--ink);
  animation: splashUp 0.55s 1.12s var(--ease-out) both;
}
.splash-sub {
  margin-top: 12px;
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.2em; text-indent: 0.2em;
  color: var(--accent);
  animation: splashUp 0.55s 1.28s var(--ease-out) both;
}
.splash-bar {
  margin-top: 34px;
  width: 148px; height: 3px;
  border-radius: 99px;
  background: rgba(120, 120, 120, 0.16);
  overflow: hidden;
  animation: splashUp 0.55s 1.42s var(--ease-out) both;
}
.splash-bar i {
  display: block; height: 100%; width: 0;
  border-radius: 99px;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
  animation: splashBar 1.0s 1.46s var(--ease-out) forwards;
}

@keyframes splashTile { from { opacity: 0; transform: translateY(16px) scale(0.86); } to { opacity: 1; transform: none; } }
@keyframes splashUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes splashBar { to { width: 100%; } }

body.splashing { overflow: hidden; }

@media (prefers-reduced-motion: reduce) {
  .splash-tile, .splash-name, .splash-sub, .splash-bar { animation-duration: 0.01ms !important; }
  .splash-bar i { animation-duration: 0.01ms !important; }
}

/* A 与曲线自己「画」出来 */
.sp-letter, .sp-arc { stroke-dasharray: 1; stroke-dashoffset: 1; }
.sp-letter { animation: drawStroke 0.85s 0.18s cubic-bezier(0.65, 0, 0.35, 1) forwards; }
.sp-arc { animation: drawStroke 0.5s 0.82s cubic-bezier(0.65, 0, 0.35, 1) forwards; }
@keyframes drawStroke { to { stroke-dashoffset: 0; } }


.rd-mock-btn {
  flex: 0 0 auto;
  height: 26px; padding: 0 13px;
  margin-left: 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 11.5px; font-weight: 600;
  display: inline-flex; align-items: center;
  transition: all 0.18s var(--ease);
}
.rd-mock-btn:hover { background: var(--ink); color: var(--surface); border-color: var(--ink); }

/* ============================================================
   模考模式 · 机考阅读界面
   ============================================================ */
body.is-mock { overflow: hidden; }
body.is-mock .topnav, body.is-mock .view-head { display: none; }

.mock {
  position: fixed; inset: 0; z-index: 250;
  display: flex; flex-direction: column;
  background: #ffffff;
  color: #1d2126;
  font-size: 16px;
}
.mock [hidden] { display: none !important; }
:root[data-theme="dark"] .mock { background: #0e0f12; color: #e8eaee; }

/* ---- 顶栏 ---- */
.mk-top {
  flex: 0 0 auto;
  height: 92px;
  display: flex; align-items: center; gap: 20px;
  padding: 0 28px;
  border-bottom: 1px solid #eceef1;
  background: #fff;
}
:root[data-theme="dark"] .mk-top { background: #14161a; border-bottom-color: #23262c; }

.mk-logo {
  font-size: 34px; font-weight: 800; letter-spacing: -0.02em;
  color: #1c6b55; line-height: 1;
  display: flex; align-items: baseline; gap: 7px;
}
.mk-logo span { font-size: 15px; font-weight: 800; letter-spacing: 0.06em; color: #1c6b55; opacity: 0.75; }
.mk-div { width: 1px; height: 42px; background: #e3e6ea; }
:root[data-theme="dark"] .mk-div { background: #2b2f36; }

.mk-heading { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.mk-title { font-size: 20px; font-weight: 800; letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk-remain { font-size: 15px; color: #7b828b; font-variant-numeric: tabular-nums; }
.mk-remain.is-warn { color: #c0392b; font-weight: 700; }

.mk-right { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.mk-icon {
  position: relative;
  height: 38px; min-width: 38px; padding: 0 10px;
  border-radius: 9px; border: 1px solid transparent;
  background: transparent; color: #3a4048;
  font-family: inherit; font-size: 15px; font-weight: 600; cursor: pointer;
}
.mk-icon:hover { background: #f3f5f7; }
.mk-icon em { font-style: normal; font-size: 11px; color: #1c6b55; margin-left: 3px; }
:root[data-theme="dark"] .mk-icon { color: #c9ced6; }
:root[data-theme="dark"] .mk-icon:hover { background: #1d2126; }

/* ---- Part 条 ---- */
.mk-part {
  flex: 0 0 auto;
  margin: 12px 26px 0;
  padding: 20px 22px;
  background: #f4f5ef;
  border-radius: 3px;
}
:root[data-theme="dark"] .mk-part { background: #16181c; }
.mk-part-h { font-size: 17px; font-weight: 800; }
.mk-part-c { font-size: 15.5px; color: #3a4048; margin-top: 8px; }
:root[data-theme="dark"] .mk-part-c { color: #b9bfc7; }

/* ---- 主体 ---- */
.mk-body {
  flex: 1; min-height: 0;
  display: grid;
  grid-template-columns: 62% 1px 1fr;
  margin-top: 10px;
}
.mk-doc { overflow-y: auto; padding: 14px 34px 60px 26px; }
.mk-doc-text { font-size: calc(16.5px * var(--mk-scale, 1)); line-height: 1.85; text-align: justify; }
.mk-doc-text .doc-page { margin-bottom: 14px; }
.mk-doc-text .doc-para { margin: 0 0 26px; }
.mk-doc-text .doc-label { font-weight: 800; margin-right: 12px; }
.mk-doc-text .doc-head { font-weight: 800; margin: 16px 0 10px; }
.mk-doc-text .doc-title { font-size: calc(20px * var(--mk-scale, 1)); font-weight: 800; margin: 0 0 18px; }
.mk-doc-text .doc-line { margin: 0 0 10px; }
.mk-loading { color: #8a9099; font-size: 14px; padding: 20px 0; }

.mk-hl { background: #ffe98a; color: inherit; padding: 1px 0; }
:root[data-theme="dark"] .mk-hl { background: #6b5a17; color: #fff3c4; }

.mk-note-dot {
  display: inline-block; width: 9px; height: 9px; margin-left: 6px;
  border-radius: 50%; border: none; background: #e0a13c; cursor: pointer;
  vertical-align: middle;
}

/* 中缝：竖线 + 滚动位置指示 */
.mk-seam {
  position: relative;
  background: #e3e6ea;
  cursor: col-resize;
}
:root[data-theme="dark"] .mk-seam { background: #2b2f36; }
.mk-seam::before {
  content: ""; position: absolute; inset: 0; width: 3px; left: -1px;
  background: #1c6b55; opacity: 0.55;
}
.mk-seam i {
  position: absolute; left: -1px; width: 5px; top: 0; height: 20%;
  background: #9aa1aa; opacity: 0.7;
}

.mock.hide-doc .mk-body { grid-template-columns: 0 1px 1fr; }
.mock.hide-doc .mk-doc { padding: 0; overflow: hidden; }

/* ---- 题目 ---- */
.mk-qpane { overflow-y: auto; padding: 6px 58px 120px 40px; }
.mk-group { margin-bottom: 22px; }
.mk-group-h { font-size: 15px; font-weight: 800; }
.mk-group-sub { font-size: 13px; color: #8a9099; margin: 3px 0 10px; }

.mk-q { padding: 16px 0 6px; }
.mk-q.is-flagged { background: #fffaf0; }
:root[data-theme="dark"] .mk-q.is-flagged { background: #191713; }
.mk-q-head { display: flex; gap: 12px; align-items: baseline; }
.mk-q-head b { flex: 0 0 auto; font-size: calc(16px * var(--mk-scale, 1)); font-weight: 800; min-width: 16px; }
.mk-q-head span { font-size: calc(16px * var(--mk-scale, 1)); font-weight: 700; line-height: 1.5; }
.mk-q-cn { font-size: calc(13px * var(--mk-scale, 1)); color: #8a9099; margin: 6px 0 0 28px; }

.mk-opts { display: flex; flex-direction: column; gap: 6px; margin: 8px 0 0 28px; }
.mk-opt-row {
  display: flex; align-items: center; gap: 16px;
  padding: 9px 0;
  border: none; background: transparent;
  font-family: inherit; font-size: calc(16px * var(--mk-scale, 1)); color: inherit;
  text-align: left; cursor: pointer;
}
.mk-opt-row i {
  flex: 0 0 22px; width: 22px; height: 22px;
  border-radius: 50%;
  border: 1.5px solid #c3c9d0;
  background: #fff;
  transition: all 0.15s ease;
}
.mk-opt-row:hover i { border-color: #1c6b55; }
.mk-opt-row.on i { border-color: #1c6b55; background: #1c6b55; box-shadow: inset 0 0 0 4px #fff; }
:root[data-theme="dark"] .mk-opt-row i { background: #14161a; border-color: #3a4048; }
:root[data-theme="dark"] .mk-opt-row.on i { background: #1c6b55; border-color: #1c6b55; box-shadow: inset 0 0 0 4px #14161a; }

.mk-fill { margin: 10px 0 0 28px; }
.mk-input {
  width: min(280px, 70%);
  height: 38px; padding: 0 12px;
  border-radius: 3px; border: 1px solid #c3c9d0;
  background: #fff; color: inherit;
  font-family: inherit; font-size: calc(16px * var(--mk-scale, 1));
}
.mk-input:focus { outline: none; border-color: #1c6b55; box-shadow: 0 0 0 3px rgba(28, 107, 85, 0.14); }
:root[data-theme="dark"] .mk-input { background: #14161a; border-color: #3a4048; }

/* 右侧浮动箭头 */
.mk-arrows {
  position: fixed; right: 26px; bottom: 96px;
  display: flex; gap: 8px;
  z-index: 255;
}
.mk-arrow-btn {
  width: 52px; height: 44px;
  border-radius: 4px; border: 1px solid #dfe3e8;
  background: #fff; color: #1d2126;
  font-size: 20px; line-height: 1; cursor: pointer;
}
.mk-arrow-btn:hover { background: #f3f5f7; }
.mk-arrow-btn.is-dark { background: #111417; border-color: #111417; color: #fff; }
:root[data-theme="dark"] .mk-arrow-btn { background: #1a1d22; border-color: #2b2f36; color: #e8eaee; }
:root[data-theme="dark"] .mk-arrow-btn.is-dark { background: #e8eaee; color: #111417; border-color: #e8eaee; }

/* ---- 底栏 ---- */
.mk-foot {
  flex: 0 0 auto;
  height: 92px;
  display: flex; align-items: center; gap: 20px;
  padding: 0 28px;
  border-top: 1px solid #eceef1;
  background: #fff;
}
:root[data-theme="dark"] .mk-foot { background: #14161a; border-top-color: #23262c; }
.mk-foot-left { display: flex; align-items: center; gap: 14px; min-width: 0; }
.mk-foot-label { font-size: 15.5px; font-weight: 700; white-space: nowrap; }
.mk-palette { display: flex; gap: 4px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.mk-palette::-webkit-scrollbar { display: none; }
.mk-num {
  width: 30px; height: 30px; flex: 0 0 30px;
  border-radius: 3px; border: 1px solid #dfe3e8;
  background: #fff; color: #3a4048;
  font-size: 13.5px; font-weight: 600; cursor: pointer;
  position: relative;
}
.mk-num:hover { border-color: #1c6b55; }
.mk-num.ans { background: #1c6b55; border-color: #1c6b55; color: #fff; }
.mk-num.cur { border: 2px solid #1d2126; font-weight: 800; }
.mk-num.flag::after {
  content: ""; position: absolute; top: -3px; right: -3px;
  width: 7px; height: 7px; border-radius: 50%; background: #e0a13c;
}
:root[data-theme="dark"] .mk-num { background: #1a1d22; border-color: #2b2f36; color: #c9ced6; }
:root[data-theme="dark"] .mk-num.cur { border-color: #e8eaee; }

.mk-foot-mid { margin-left: auto; font-size: 14px; color: #7b828b; font-variant-numeric: tabular-nums; }
.mk-foot-right { display: flex; gap: 8px; }
.mk-sq {
  width: 46px; height: 44px;
  border-radius: 4px; border: 1px solid #dfe3e8;
  background: #f3f5f7; color: #1d2126;
  font-size: 17px; cursor: pointer;
}
.mk-sq:hover { background: #e9ecef; }
.mk-sq.is-dark { background: #111417; border-color: #111417; color: #fff; }
:root[data-theme="dark"] .mk-sq { background: #1a1d22; border-color: #2b2f36; color: #e8eaee; }
:root[data-theme="dark"] .mk-sq.is-dark { background: #e8eaee; color: #111417; }

/* ---- 菜单 / 笔记 ---- */
.mk-menu {
  position: fixed; z-index: 262; min-width: 180px; padding: 5px;
  border-radius: 8px; background: #fff; border: 1px solid #e2e5e9;
  box-shadow: 0 16px 36px -14px rgba(20, 24, 30, 0.35);
}
:root[data-theme="dark"] .mk-menu { background: #1b1f24; border-color: #2b2f36; }
.mk-menu button {
  display: block; width: 100%; text-align: left;
  padding: 9px 11px; border: none; border-radius: 6px;
  background: transparent; color: inherit;
  font-family: inherit; font-size: 14px; cursor: pointer;
}
.mk-menu button:hover:not(:disabled) { background: #f2f4f6; }
:root[data-theme="dark"] .mk-menu button:hover:not(:disabled) { background: #23272e; }
.mk-menu button:disabled { opacity: 0.4; cursor: default; }

.mk-note-pop {
  position: fixed; z-index: 263; width: 270px; padding: 10px;
  border-radius: 8px; background: #fff; border: 1px solid #e2e5e9;
  box-shadow: 0 18px 40px -16px rgba(20, 24, 30, 0.4);
}
:root[data-theme="dark"] .mk-note-pop { background: #1b1f24; border-color: #2b2f36; }
.mk-note-pop textarea {
  width: 100%; resize: vertical;
  border: 1px solid #dfe3e8; border-radius: 6px;
  padding: 8px 10px; font-family: inherit; font-size: 14px;
  background: #fff; color: inherit;
}
:root[data-theme="dark"] .mk-note-pop textarea { background: #14161a; border-color: #2b2f36; color: #e8eaee; }
.mk-note-act { display: flex; justify-content: flex-end; gap: 6px; margin-top: 8px; }

.mk-mini {
  height: 34px; padding: 0 14px;
  border-radius: 4px; border: 1px solid #dfe3e8;
  background: #fff; color: #1d2126;
  font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer;
}
.mk-mini:hover { background: #f3f5f7; }
.mk-mini.is-dark { background: #111417; border-color: #111417; color: #fff; }
:root[data-theme="dark"] .mk-mini { background: #1a1d22; border-color: #2b2f36; color: #e8eaee; }

.mk-notes-panel {
  position: fixed; right: 0; top: 92px; bottom: 78px;
  width: 310px; z-index: 258;
  background: #fff; border-left: 1px solid #eceef1;
  display: flex; flex-direction: column;
  box-shadow: -18px 0 34px -26px rgba(20, 24, 30, 0.4);
}
:root[data-theme="dark"] .mk-notes-panel { background: #14161a; border-left-color: #23262c; }
.mk-notes-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; font-size: 15px; font-weight: 700;
  border-bottom: 1px solid #eceef1;
}
:root[data-theme="dark"] .mk-notes-head { border-bottom-color: #23262c; }
.mk-notes-list { flex: 1; overflow-y: auto; padding: 12px 16px 20px; }
.mk-notes-empty { color: #8a9099; font-size: 13.5px; line-height: 1.7; }
.mk-note-item { padding: 10px 0; border-bottom: 1px dashed #eceef1; }
.mk-note-item b { font-size: 12px; color: #8a9099; font-weight: 600; }
.mk-note-item p { font-size: 14px; line-height: 1.6; margin: 4px 0 5px; }
.mk-note-del { border: none; background: none; color: #c75050; font-size: 12px; cursor: pointer; padding: 0; }

/* ---- 结果 ---- */
.mk-result {
  position: fixed; inset: 0; z-index: 270;
  display: grid; place-items: center;
  background: rgba(16, 20, 24, 0.42);
}
.mk-result-card {
  width: min(420px, 92vw); padding: 30px 28px 24px;
  border-radius: 14px; background: #fff; text-align: center;
  box-shadow: 0 40px 80px -40px rgba(10, 14, 20, 0.6);
}
:root[data-theme="dark"] .mk-result-card { background: #16191e; }
.mk-result-tag { font-size: 13px; color: #c75050; font-weight: 600; margin-bottom: 6px; }
.mk-result-title { font-size: 16px; font-weight: 700; color: #5c636c; }
.mk-result-score { margin: 10px 0 2px; }
.mk-result-score b { font-size: 54px; font-weight: 800; letter-spacing: -0.03em; }
.mk-result-score span { font-size: 18px; color: #8a9099; font-weight: 600; }
.mk-result-sub { font-size: 13.5px; color: #8a9099; }
.mk-result-bar { height: 6px; border-radius: 99px; background: #eceef1; overflow: hidden; margin: 18px 0 8px; }
.mk-result-bar i { display: block; height: 100%; background: #1c6b55; }
.mk-result-pct { font-size: 13px; color: #5c636c; }
.mk-result-actions { display: flex; gap: 8px; justify-content: center; margin-top: 20px; }

@media (max-width: 900px) {
  .mk-top { height: 62px; padding: 0 14px; gap: 10px; }
  .mk-logo { font-size: 21px; }
  .mk-logo span { display: none; }
  .mk-div { height: 30px; }
  .mk-title { font-size: 15px; max-width: 40vw; }
  .mk-remain { font-size: 12.5px; }
  .mk-icon { height: 34px; min-width: 34px; padding: 0 8px; font-size: 14px; }
  .mk-part { margin: 10px 14px 0; padding: 14px 16px; }
  .mk-part-h { font-size: 15px; }
  .mk-part-c { font-size: 13.5px; }
  .mk-body { grid-template-columns: 1fr; grid-template-rows: 38vh 1px 1fr; }
  .mk-doc { padding: 12px 16px 20px; }
  .mk-doc-text { font-size: calc(15.5px * var(--mk-scale, 1)); }
  .mk-seam { cursor: row-resize; }
  .mk-qpane { padding: 6px 18px 120px; }
  .mk-arrows { bottom: 104px; right: 14px; }
  .mk-arrow-btn { width: 44px; height: 40px; }
  .mk-foot { height: auto; padding: 8px 12px; flex-wrap: wrap; gap: 8px; }
  .mk-palette { flex-wrap: nowrap; overflow-x: auto; }
  .mk-foot-mid { margin-left: 0; width: 100%; order: 3; font-size: 12.5px; }
  .mk-foot-right { margin-left: auto; }
  .mk-notes-panel { top: 62px; bottom: 0; width: 86vw; }
}

/* 字号按钮状态 */
.mk-icon.is-aa { color: #1c6b55; border-color: #cfe5db; background: #f1f8f5; }
:root[data-theme="dark"] .mk-icon.is-aa { color: #7fd9bc; border-color: #234034; background: #14201b; }

/* 目标分面板 */
.target-panel {
  display: flex; align-items: center; gap: 28px; flex-wrap: wrap;
  padding: 22px 26px;
  margin-bottom: 16px;
  border-radius: var(--radius);
  background: linear-gradient(118deg, color-mix(in srgb, var(--accent) 9%, var(--surface)) 0%, var(--surface) 52%, color-mix(in srgb, #6f86d6 7%, var(--surface)) 100%);
  border: 1px solid transparent;
  box-shadow: var(--shadow-sm);
}
.target-left { flex: 0 0 auto; min-width: 150px; }
.target-score {
  font-size: 44px; font-weight: 800; letter-spacing: -0.04em;
  line-height: 1.05; color: var(--accent-ink);
  font-variant-numeric: tabular-nums;
}
.target-sub { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.target-sub b { color: var(--ink); }
.target-right { flex: 1 1 320px; min-width: 220px; }
.target-bar {
  height: 8px; border-radius: 99px; overflow: hidden;
  background: color-mix(in srgb, var(--ink) 8%, transparent);
}
.target-bar i {
  display: block; height: 100%; border-radius: 99px;
  background: linear-gradient(90deg, var(--accent-2), var(--accent));
  transition: width 0.6s var(--ease-out);
}
.target-meta { font-size: 12px; color: var(--faint); margin-top: 8px; }

/* ================= 训练页 ================= */
.train-hero { margin: 4px 0 20px; }
.train-h { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; margin: 6px 0 6px; }
.train-sub { font-size: 13px; color: var(--muted); margin: 0; }
.train-sub b { color: var(--accent-ink); }

.train-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); gap: 16px; }
.train-card {
  position: relative; display: flex; gap: 16px; align-items: flex-start;
  padding: 22px 22px 20px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line);
  cursor: pointer; transition: transform .22s var(--ease-out), box-shadow .22s var(--ease-out), border-color .22s;
}
.train-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: transparent; }
.tc-icon {
  flex: 0 0 46px; width: 46px; height: 46px; border-radius: 14px;
  display: grid; place-items: center; font-size: 19px; font-weight: 700;
  color: var(--accent-ink);
  background: color-mix(in srgb, var(--accent) 14%, var(--surface));
}
.tc-icon svg { width: 22px; height: 22px; }
.t-2 .tc-icon { color: #7a5cc4; background: color-mix(in srgb, #7a5cc4 12%, var(--surface)); }
.t-3 .tc-icon { color: #c07a2e; background: color-mix(in srgb, #c07a2e 12%, var(--surface)); }
.tc-body { flex: 1 1 auto; min-width: 0; }
.tc-title { font-size: 16px; font-weight: 650; margin-bottom: 6px; }
.tc-desc { font-size: 12.8px; line-height: 1.65; color: var(--muted); }
.tc-meta { font-size: 11.5px; color: var(--faint); margin-top: 10px; }
.tc-go {
  position: absolute; right: 20px; bottom: 18px;
  font-size: 12px; color: var(--accent-ink); opacity: 0; transition: opacity .2s;
}
.train-card:hover .tc-go { opacity: 1; }

/* ---- 训练通用 ---- */
.drill-wrap { max-width: 720px; margin: 8px auto 0; }
.drill-bar { height: 6px; border-radius: 99px; background: color-mix(in srgb, var(--ink) 7%, transparent); overflow: hidden; }
.drill-bar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--accent-2), var(--accent)); transition: width .35s var(--ease-out); }
.drill-count { font-size: 12px; color: var(--faint); margin: 10px 0 22px; }
.drill-foot { margin-top: 22px; display: flex; gap: 10px; align-items: center; }
.drill-done { text-align: center; padding: 26px 0 10px; min-height: 62vh; display: flex; flex-direction: column; justify-content: center; }
.drill-done .drill-hint { margin-top: 14px; }
.drill-done .syn-review, .drill-done .sr-cap, .drill-done .sr-row { text-align: left; }
.dd-num { font-size: 52px; font-weight: 800; letter-spacing: -0.04em; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.dd-num span { font-size: 20px; color: var(--faint); font-weight: 600; }
.dd-cap { font-size: 13px; color: var(--muted); margin-top: 2px; }
.dd-row { display: flex; gap: 8px; justify-content: center; margin-top: 16px; flex-wrap: wrap; }
.dd-note { font-size: 12.5px; color: var(--faint); margin: 16px auto 0; max-width: 420px; line-height: 1.7; }
.dd-acts { display: flex; gap: 10px; justify-content: center; margin-top: 24px; flex-wrap: wrap; }

/* ---- 摸底 ---- */
.lv-card {
  padding: 56px 30px; border-radius: var(--radius); background: var(--surface);
  border: 1px solid var(--line); text-align: center; box-shadow: var(--shadow-sm);
}
.lv-word { font-size: 44px; font-weight: 700; letter-spacing: -0.02em; word-break: break-word; }
.lv-hint { font-size: 12.5px; color: var(--faint); margin-top: 14px; }
.lv-acts { display: flex; gap: 12px; margin-top: 18px; }
.lv-acts .btn { flex: 1; height: 52px; font-size: 14px; }
.lv-know { border-color: color-mix(in srgb, var(--accent) 40%, transparent); color: var(--accent-ink); font-weight: 600; }
.lv-know:hover { background: color-mix(in srgb, var(--accent) 10%, var(--surface)); }
.lv-vague { color: #b07a24; }
.lv-no { color: var(--muted); }

/* ---- 同义替换 ---- */
.syn-drill { max-width: 680px; }
.syn-q {
  padding: 34px 34px 26px; border-radius: 24px;
  background: linear-gradient(168deg, var(--surface) 0%, color-mix(in srgb, var(--accent) 4%, var(--surface)) 100%);
  border: 1px solid var(--line);
  box-shadow: 0 1px 2px rgba(30,26,20,.04), 0 12px 32px -20px rgba(30,26,20,.22);
}
.syn-cap { font-size: 11.5px; color: var(--faint); letter-spacing: .1em; text-transform: uppercase; }
.syn-word {
  font-family: var(--font-serif); font-size: clamp(30px, 4vw, 40px); line-height: 1.18;
  letter-spacing: -0.015em; margin: 12px 0 6px; color: var(--ink);
}
.syn-quote { font-style: italic; color: var(--accent-ink); }
.syn-cn { font-size: 14px; color: var(--muted); }
.syn-ask {
  margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line-2);
  font-size: 14.5px; color: var(--ink); font-weight: 550;
}

.syn-opts { display: grid; grid-template-columns: 1fr; gap: 9px; margin-top: 14px; }
.syn-opt {
  display: flex; align-items: center; gap: 14px; width: 100%;
  padding: 15px 18px; border-radius: 15px; border: 1px solid var(--line);
  background: var(--surface); font-size: 16px; font-weight: 500; text-align: left;
  cursor: pointer; color: var(--ink);
  transition: transform .16s var(--ease-out), border-color .16s, background .16s, box-shadow .2s;
}
.syn-opt .so-k {
  flex: none; width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center;
  font-size: 11.5px; font-weight: 700; letter-spacing: 0;
  background: color-mix(in srgb, var(--ink) 6%, transparent); color: var(--muted);
  transition: background .16s, color .16s;
}
.syn-opt .so-t { flex: 1; min-width: 0; }
.syn-opt .so-ic { flex: none; font-style: normal; font-size: 15px; font-weight: 700; opacity: 0; transition: opacity .18s; }
.syn-opt:hover:not([disabled]) {
  border-color: color-mix(in srgb, var(--accent) 42%, transparent);
  transform: translateY(-1px); box-shadow: 0 6px 18px -12px rgba(13,148,88,.5);
}
.syn-opt:hover:not([disabled]) .so-k { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent-ink); }
.syn-opt[disabled] { cursor: default; }
.syn-opt.is-right {
  border-color: var(--accent); background: color-mix(in srgb, var(--accent) 9%, var(--surface));
  color: var(--accent-ink); box-shadow: 0 8px 24px -18px rgba(13,148,88,.6);
}
.syn-opt.is-right .so-k { background: var(--accent); color: #fff; }
.syn-opt.is-right .so-ic { opacity: 1; }
.syn-opt.is-wrong {
  border-color: color-mix(in srgb, #c9433f 55%, transparent);
  background: color-mix(in srgb, #c9433f 7%, var(--surface)); color: #a93a36;
}
.syn-opt.is-wrong .so-k { background: color-mix(in srgb, #c9433f 14%, transparent); color: #a93a36; }
.syn-opt.is-wrong .so-ic { opacity: 1; }
.syn-opt.is-dim { opacity: .48; }

.syn-note { margin-top: 16px; padding: 14px 16px; border-radius: 14px; font-size: 13px; }
.syn-note.tip { padding: 10px 2px 0; color: var(--faint); font-size: 12.5px; }
.syn-note.ok { background: color-mix(in srgb, var(--accent) 8%, var(--surface)); border: 1px solid color-mix(in srgb, var(--accent) 26%, transparent); }
.syn-note.bad { background: color-mix(in srgb, #c9433f 6%, var(--surface)); border: 1px solid color-mix(in srgb, #c9433f 22%, transparent); }
.syn-note .sn-head { font-size: 12px; font-weight: 650; letter-spacing: .04em; }
.syn-note.ok .sn-head { color: var(--accent-ink); }
.syn-note.bad .sn-head { color: #a93a36; }
.syn-note .sn-word { margin-top: 6px; font-size: 17px; font-family: var(--font-serif); color: var(--ink); }
.syn-note .sn-word span { font-family: inherit; font-size: 13px; color: var(--muted); margin-left: 8px; }
.syn-note .sn-alts { margin-top: 8px; font-size: 12.5px; color: var(--faint); font-family: var(--font-serif); }
.sn-tip { color: var(--faint); }

.syn-review { width: 100%; margin: 24px 0 8px; text-align: left; }
.sr-cap { font-size: 12px; color: var(--muted); margin: 20px 0 6px; letter-spacing: .02em; }
.sr-row {
  display: flex; align-items: baseline; gap: 14px; padding: 11px 0;
  border-top: 1px solid var(--line-2); font-size: 13px;
}
.sr-main { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 10px; }
.sr-main b { font-family: var(--font-serif); font-size: 15px; color: var(--ink); font-weight: 600; }
.sr-main span { color: var(--muted); }
.sr-row em { font-style: normal; color: var(--faint); font-family: var(--font-serif); font-size: 12.5px; text-align: right; }

.sr-ring {
  position: relative; width: 112px; height: 112px; margin: 0 auto 18px; border-radius: 50%;
  background: conic-gradient(var(--accent) calc(var(--p) * 1%), color-mix(in srgb, var(--ink) 9%, transparent) 0);
  display: grid; place-items: center;
  box-shadow: 0 10px 30px -22px rgba(13,148,88,.75);
}
.sr-ring::before {
  content: ""; position: absolute; inset: 9px; border-radius: 50%;
  background: var(--bg);
}
.sr-ring-in { position: relative; z-index: 1; display: flex; align-items: baseline; gap: 1px; }
.sr-ring-in b { font-size: 24px; color: var(--accent-ink); font-variant-numeric: tabular-nums; letter-spacing: -0.02em; }
.sr-ring-in span { font-size: 12px; color: var(--muted); }

/* ---- 整句听写 ---- */
.dict-card { padding: 30px 28px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); text-align: center; }
.dict-play {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 20px;
  border-radius: 99px; border: 1px solid var(--line); background: var(--surface);
  font-size: 13px; cursor: pointer; color: var(--accent-ink);
}
.dict-play svg { width: 16px; height: 16px; }
.dict-sent { font-size: 19px; line-height: 1.9; margin: 22px 0 8px; color: var(--ink); }
.dict-cn { font-size: 13px; color: var(--faint); }
.dict-input { display: flex; gap: 10px; margin-top: 16px; }
.dict-input input {
  flex: 1; height: 48px; padding: 0 16px; border-radius: 13px;
  border: 1px solid var(--line); background: var(--surface); font-size: 16px;
}
.dict-input input:focus { outline: none; border-color: var(--accent); }
.dict-fb { margin-top: 12px; font-size: 13.5px; }
.dict-fb.ok { color: var(--accent-ink); }
.dict-fb.bad { color: #b23c39; }

/* ---- 卡片背面：词根 / 真题 ---- */
.root-row, .read-hits { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-top: 12px; font-size: 12.5px; }
.root-label, .rh-label { color: var(--faint); flex: 0 0 auto; }
.root-body { color: var(--ink); font-family: "SF Mono", Consolas, monospace; font-size: 12.5px; }
.rh-chip { padding: 3px 9px; border-radius: 8px; background: color-mix(in srgb, var(--ink) 5%, transparent); color: var(--muted); }
.rh-more { color: var(--faint); }

/* ---- 阅读：本篇生词 ---- */
.rw-head { font-size: 12.5px; color: var(--muted); padding: 4px 2px 12px; }
.rw-row { display: flex; align-items: center; gap: 10px; padding: 10px 2px; border-bottom: 1px solid var(--line); }
.rw-main { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.rw-main b { font-size: 14.5px; font-weight: 600; }
.rw-main span { font-size: 12px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rw-empty { padding: 30px 10px; text-align: center; font-size: 13px; color: var(--faint); }
/* 训练页补充 */
.drill-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.drill-head b { font-size: 15px; font-weight: 650; }
.drill-head span { font-size: 12px; color: var(--faint); margin-left: 10px; }
.drill-hint { font-size: 12.5px; color: var(--faint); }
.lv-card { margin-top: 26px; }
.train-tips { margin-top: 26px; padding: 22px 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.tt-title { font-size: 12px; letter-spacing: .08em; color: var(--faint); margin-bottom: 14px; }
.tt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.tt-item { display: flex; gap: 10px; font-size: 12.8px; line-height: 1.7; color: var(--muted); }
.tt-item b { color: var(--accent-ink); font-weight: 700; }
.tt-item span b { color: var(--ink); }
/* ================= 梦校 ================= */
.plan-hero {
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
  padding: 24px 28px; margin-bottom: 16px; border-radius: var(--radius);
  background: linear-gradient(120deg, color-mix(in srgb, var(--accent) 10%, var(--surface)) 0%, var(--surface) 55%, color-mix(in srgb, #7a8fd6 8%, var(--surface)) 100%);
  box-shadow: var(--shadow-sm);
}
.ph-num { font-size: 54px; font-weight: 800; letter-spacing: -0.05em; line-height: 1; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.ph-num span { font-size: 18px; font-weight: 600; margin-left: 6px; color: var(--muted); }
.ph-cap { font-size: 12.5px; color: var(--faint); margin-top: 6px; }
.ph-side { flex: 0 1 300px; display: flex; flex-direction: column; gap: 8px; }
.ph-row { display: flex; align-items: baseline; gap: 10px; font-size: 12.5px; color: var(--muted); }
.ph-row b { font-size: 16px; color: var(--ink); font-variant-numeric: tabular-nums; }
.ph-row em { font-style: normal; color: var(--faint); font-size: 11.5px; margin-left: auto; padding-left: 10px; white-space: nowrap; }

.plan-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px; }
.plan-panel { transition: box-shadow 0.28s var(--ease), transform 0.28s var(--ease); }
.plan-panel:hover { transform: translateY(-1px); }
.plan-panel { padding: 20px 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.grade-grid { display: flex; gap: 12px; margin: 12px 0; flex-wrap: wrap; }
.grade-f { display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--faint); }
.grade-f .mini-select { min-width: 78px; font-size: 15px; font-weight: 600; }
.hku-calc { font-size: 13px; color: var(--muted); margin-top: 6px; }
.hku-calc b { color: var(--accent-ink); font-size: 15px; }
.hku-hint { display: block; font-size: 11.5px; color: var(--faint); margin-top: 4px; letter-spacing: .04em; }
.ielts-grid { display: flex; gap: 10px; margin: 12px 0; flex-wrap: wrap; }
.ielts-f { display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--faint); flex: 1 1 60px; }
.ielts-f input {
  width: 100%; height: 40px; padding: 0 10px; border-radius: 11px;
  border: 1px solid var(--line); background: color-mix(in srgb, var(--ink) 3%, var(--surface));
  font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums;
}
.ielts-f input:focus { outline: none; border-color: var(--accent); }
.ielts-sum { font-size: 12.5px; color: var(--muted); }
.ielts-sum b { color: var(--accent-ink); font-size: 15px; }

.plan-schools { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 14px; margin-bottom: 16px; }
.plan-school { padding: 20px 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); position: relative; }
.plan-school.tone-main { border-left: 3px solid var(--accent); }
.plan-school.tone-sub { border-left: 3px solid #7a8fd6; }
.plan-school.tone-safe { border-left: 3px solid #c99a4e; }
.plan-school.tone-alt { border-left: 3px solid #b9b3a6; }
.ps-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ps-tier { font-size: 10.5px; letter-spacing: .06em; padding: 2px 7px; border-radius: 6px; background: color-mix(in srgb, var(--ink) 6%, transparent); color: var(--muted); }
.ps-name { font-size: 15.5px; font-weight: 650; }
.ps-status { margin-left: auto; font-size: 11.5px; padding: 3px 9px; border-radius: 99px; }
.ps-status.ok { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent-ink); }
.ps-status.warn { background: color-mix(in srgb, #d9a13b 16%, transparent); color: #8a6116; }
.ps-status.bad { background: color-mix(in srgb, #d9534f 13%, transparent); color: #a53b38; }
.ps-meta { font-size: 12px; color: var(--faint); margin-top: 6px; }
.ps-when { font-size: 12px; color: var(--muted); margin-top: 8px; }
.ps-when b { color: var(--accent-ink); }
.ps-needs { margin: 12px 0 0; padding-left: 18px; font-size: 12.5px; color: var(--muted); line-height: 1.9; }
.ps-note { font-size: 11.5px; color: var(--faint); margin-top: 10px; }

.plan-tl .eyebrow { margin-bottom: 10px; }
.tl-row { display: flex; align-items: center; gap: 14px; padding: 9px 2px; border-bottom: 1px solid var(--line); font-size: 12.8px; }
.tl-row:last-child { border-bottom: 0; }
.tl-date { font-variant-numeric: tabular-nums; color: var(--faint); width: 62px; flex: 0 0 62px; }
.tl-label { flex: 1 1 auto; color: var(--ink); }
.tl-days { color: var(--muted); font-variant-numeric: tabular-nums; font-size: 12px; }
.tl-row.is-past { opacity: .45; }
.tl-row.is-soon .tl-label { color: var(--accent-ink); font-weight: 600; }
.tl-row.is-soon .tl-days { color: var(--accent-ink); }

@media (max-width: 900px) {
  .plan-cols { grid-template-columns: 1fr; }
}
/* 爱德思进度 */
.exam-track { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.et-cap { font-size: 11.5px; color: var(--faint); letter-spacing: .04em; }
.et-units { display: flex; gap: 6px; flex-wrap: wrap; margin: 8px 0 6px; }
.et-units i {
  font-style: normal; font-size: 11px; padding: 3px 8px; border-radius: 7px;
  background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent-ink);
}
.et-units i.on { background: color-mix(in srgb, var(--ink) 6%, transparent); color: var(--muted); }
.et-note { font-size: 11.5px; color: var(--faint); }

/* ============ 细节升级 ============ */
/* 顶部导航放大 */
.nav { gap: 4px; }
.nav-item { height: 40px; padding: 0 17px; font-size: 14.5px; gap: 8px; border-radius: 99px; }
.nav-item svg { width: 18px; height: 18px; flex: 0 0 18px; }
.nav-badge { font-size: 11.5px; }

/* 视图入场 */
@keyframes viewIn {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: none; }
}
.view.is-enter { animation: viewIn .34s cubic-bezier(.22,.61,.36,1) both; }

/* 阶梯上浮 */
@keyframes rowIn {
  from { opacity: 0; transform: translateY(18px) scale(.995); }
  to   { opacity: 1; transform: none; }
}
.lib-row { animation: rowIn .46s cubic-bezier(.22,.61,.36,1) both; animation-delay: calc(var(--i, 0) * 26ms); }
.plan-school { animation: rowIn .5s cubic-bezier(.22,.61,.36,1) both; animation-delay: calc(var(--i, 0) * 70ms); }
.train-card { animation: rowIn .5s cubic-bezier(.22,.61,.36,1) both; animation-delay: calc(var(--i, 0) * 80ms); }
.kpi { animation: rowIn .5s cubic-bezier(.22,.61,.36,1) both; }

/* 数字滚动不抖 */
.ph-num b { font-variant-numeric: tabular-nums; font-weight: 800; display: inline-block; min-width: 2ch; }
.kpi strong, .target-score, .dd-num { font-variant-numeric: tabular-nums; }
/* 学校内部列表（英国 5 校） */
.ps-rows { margin-top: 12px; display: flex; flex-direction: column; gap: 1px; }
.ps-row {
  display: grid; grid-template-columns: minmax(88px, auto) 1fr auto;
  gap: 10px; align-items: baseline;
  padding: 7px 0; border-bottom: 1px dashed color-mix(in srgb, var(--ink) 8%, transparent);
  font-size: 12.3px;
}
.ps-row:last-child { border-bottom: 0; }
.pr-s { color: var(--ink); font-weight: 600; white-space: nowrap; }
.pr-m { color: var(--muted); font-size: 11.8px; }
.pr-r { color: var(--accent-ink); font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
/* 申请日标注 */
.ps-apply { font-style: normal; color: var(--accent-ink); font-weight: 600; }
.ps-dl { font-size: 11.5px; color: var(--faint); margin-top: 4px; }
/* 开放→截止 标注 */
.ps-dates { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: 12px; }
.pd-open { color: var(--muted); }
.pd-close { color: var(--muted); }
.pd-arrow { color: var(--faint); }
.ps-first {
  font-style: normal; font-size: 10.5px; margin-left: 6px;
  padding: 1px 7px; border-radius: 99px;
  background: color-mix(in srgb, var(--accent) 15%, transparent); color: var(--accent-ink);
}
/* 雅思记录面板 */
.plan-ielts { margin-bottom: 16px; }
.pi-count { font-size: 11.5px; color: var(--faint); margin-left: 8px; letter-spacing: 0; }
.pi-report-btn { margin-left: auto; }
.plan-ielts .eyebrow { display: flex; align-items: center; }
.pi-form { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin: 12px 0 16px; }
.pi-form .ielts-f { flex: 0 0 86px; }
.pi-form .btn { height: 40px; }
.pi-chart { width: 100%; height: 190px; display: block; }
.pi-empty { padding: 26px 10px; text-align: center; font-size: 12.5px; color: var(--faint); }
.pi-forecast { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.pf-item { flex: 1 1 120px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, var(--ink) 3%, var(--surface)); font-size: 11.5px; color: var(--faint); }
.pf-item b { display: block; font-size: 17px; color: var(--accent-ink); margin-top: 3px; font-variant-numeric: tabular-nums; }
.pf-item.wide { flex: 1 1 100%; }
.pf-item.wide b { display: inline; font-size: 15px; }
.pi-list { margin-top: 12px; }
.pi-row { display: flex; align-items: center; gap: 12px; padding: 7px 2px; border-bottom: 1px dashed color-mix(in srgb, var(--ink) 8%, transparent); font-size: 12.5px; }
.pi-row:last-child { border-bottom: 0; }
.pl-d { color: var(--faint); font-variant-numeric: tabular-nums; width: 82px; }
.pl-s { color: var(--muted); font-variant-numeric: tabular-nums; }
.pl-t { margin-left: auto; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.pi-del { border: 0; background: none; color: var(--faint); font-size: 15px; cursor: pointer; padding: 0 4px; }
.pi-del:hover { color: #c0392b; }
/* 错题本 */
.train-card.t-4 .tc-icon { color: #c0504d; background: color-mix(in srgb, #c0504d 12%, var(--surface)); }
.wrong-panel { margin-top: 16px; padding: 20px 22px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.wp-head { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); margin-bottom: 12px; flex-wrap: wrap; }
.wp-head b { color: var(--accent-ink); }
.wp-head .btn { margin-left: auto; }
.wp-list { max-height: 320px; overflow: auto; }
.wp-row { display: grid; grid-template-columns: 1fr 1.2fr auto; gap: 10px; padding: 8px 2px; border-bottom: 1px dashed color-mix(in srgb, var(--ink) 8%, transparent); font-size: 12.5px; }
.wp-w { color: var(--ink); font-weight: 600; }
.wp-m { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wp-l { color: #c0504d; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wp-empty { padding: 26px 10px; text-align: center; color: var(--faint); font-size: 12.5px; }
/* 统计页工具条 */
.stats-tools { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.st-hint { font-size: 11.5px; color: var(--faint); }
/* ================= 写作模块 ================= */
.rd-tabs { display: flex; gap: 8px; margin-bottom: 16px; }
.rd-tabs button {
  padding: 8px 20px; border-radius: 99px; border: 1px solid var(--line);
  background: var(--surface); font-size: 13.5px; color: var(--muted); cursor: pointer;
  transition: all .2s var(--ease-out);
}
.rd-tabs button.is-on { background: var(--accent-soft); color: var(--accent-ink); border-color: transparent; font-weight: 650; }
.rd-tabs button:hover { border-color: color-mix(in srgb, var(--accent) 35%, transparent); }

.wr-head { margin-bottom: 8px; }
.wr-kpis { display: flex; gap: 8px; flex-wrap: wrap; }
.wr-tip { font-size: 12.5px; color: var(--faint); margin: 12px 0 0; }
.wr-sec { font-size: 13px; color: var(--muted); margin: 22px 0 10px; letter-spacing: .04em; }
.wr-list { border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); overflow: hidden; }
.wr-row {
  display: grid; grid-template-columns: 84px 1fr 92px 74px; gap: 12px; align-items: center;
  padding: 13px 18px; border-bottom: 1px solid var(--line); cursor: pointer;
  transition: background .18s;
}
.wr-row:last-child { border-bottom: 0; }
.wr-row:hover { background: color-mix(in srgb, var(--accent) 5%, var(--surface)); }
.wr-type { font-size: 11px; padding: 3px 8px; border-radius: 7px; text-align: center; background: color-mix(in srgb, var(--ink) 6%, transparent); color: var(--muted); }
.wr-type.t1 { background: color-mix(in srgb, #c07a2e 14%, transparent); color: #8a5a1e; }
.wr-text { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.wr-text b { font-size: 13.5px; font-weight: 550; line-height: 1.5; }
.wr-text em { font-style: normal; font-size: 11.5px; color: var(--faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wr-date { font-size: 11.5px; color: var(--faint); text-align: right; }
.wr-go { font-size: 12px; color: var(--accent-ink); text-align: right; opacity: 0; transition: opacity .2s; }
.wr-row:hover .wr-go { opacity: 1; }

/* 写作模考：铺满整屏 */
body.is-writing .topnav,
body.is-writing .view-head { display: none; }
body.is-writing .views { overflow: hidden; }
body.is-writing .main { padding: 0; max-width: none; }
#v-writing { padding: 0 !important; max-width: none !important; }
#v-writing.is-active { display: flex; height: 100%; }
.wri { display: flex; flex-direction: column; flex: 1; min-height: 0; height: 100%; background: var(--bg); }
.wri-bar { display: flex; align-items: center; gap: 14px; padding: 12px 20px; border-bottom: 1px solid var(--line); background: var(--surface); }
.wt-main { font-size: 15px; font-weight: 700; }
.wt-sub { font-size: 11.5px; color: var(--faint); margin-top: 2px; }
.wri-timer { margin-left: auto; font-size: 20px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--accent-ink); letter-spacing: .02em; }
.wri-band { display: flex; gap: 12px; align-items: center; padding: 14px 24px; background: color-mix(in srgb, #dff0e4 55%, var(--surface)); border-bottom: 1px solid var(--line); font-size: 13px; color: #2f5a43; }
.wri-band b { font-weight: 700; }
.wri-body { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 0; min-height: 0; }
.wri-left { padding: 24px 26px; overflow-y: auto; border-right: 1px solid var(--line); }
.wri-right { display: flex; flex-direction: column; padding: 18px 22px; min-height: 0; }
.wri-q p { font-size: 17px; line-height: 1.85; margin: 0 0 16px; }
.wri-cn { font-size: 13.5px; color: var(--faint); line-height: 1.9; border-left: 2px solid var(--line); padding-left: 12px; }
.wri-chart img { width: 100%; border-radius: 12px; border: 1px solid var(--line); }
.wri-ans-head { font-size: 13px; font-weight: 600; margin-bottom: 10px; display: flex; align-items: center; gap: 8px; }
.wri-hint { font-size: 11px; color: var(--faint); font-weight: 400; }
.wri-input {
  flex: 1; width: 100%; min-height: 320px; resize: none; padding: 16px 18px;
  border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
  font-family: Georgia, "Times New Roman", serif; font-size: 15.5px; line-height: 1.9;
}
.wri-input:focus { outline: none; border-color: var(--accent); }
.wri-foot { display: flex; gap: 16px; align-items: center; margin-top: 10px; font-size: 12.5px; color: var(--muted); }
.wri-foot b { color: var(--accent-ink); font-size: 14px; }
.wri-min.ok { color: var(--accent-ink); }
.wri-bottom { border-top: 1px solid var(--line); background: var(--surface); }
.wri-prog { height: 3px; background: color-mix(in srgb, var(--ink) 7%, transparent); }
.wri-prog i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent-2), var(--accent)); transition: width .3s; }
.wri-nums { display: flex; align-items: center; gap: 14px; padding: 10px 20px; font-size: 12.5px; color: var(--muted); }
.wri-pos { margin: 0 auto; }
.wri-acts { display: flex; gap: 8px; }

/* 交卷结果 */
.wri-score { max-width: 620px; margin: 60px auto; padding: 32px 34px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.wri-score h3 { margin: 0 0 20px; font-size: 20px; }
.ws-rows { display: flex; flex-direction: column; gap: 2px; }
.ws-row { display: grid; grid-template-columns: 70px 60px 24px 1fr; gap: 10px; align-items: center; padding: 10px 2px; border-bottom: 1px dashed var(--line); font-size: 13px; }
.ws-row b { font-size: 17px; font-variant-numeric: tabular-nums; color: var(--ink); }
.ws-row em { font-style: normal; color: var(--faint); font-size: 11.5px; }
.ws-ok { color: var(--accent); font-weight: 700; }
.ws-bad { color: #c0504d; font-weight: 700; }
.ws-acts { display: flex; gap: 10px; margin-top: 24px; }
.ws-note { margin-top: 18px; font-size: 12.5px; color: var(--faint); line-height: 1.8; }

@media (max-width: 900px) {
  .wri-body { grid-template-columns: 1fr; }
  .wri-left { border-right: 0; border-bottom: 1px solid var(--line); }
  .wr-row { grid-template-columns: 70px 1fr 60px; }
  .wr-date { display: none; }
}

/* 词汇量摸底：结果页 */
.vst-res { max-width: 720px; margin: 0 auto; padding: 24px 8px 8px; text-align: center; }
.vst-cap { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--faint); }
.vst-num { font-size: 72px; font-weight: 800; letter-spacing: -.05em; color: var(--accent-ink); font-variant-numeric: tabular-nums; line-height: 1.06; }
.vst-ci { color: var(--muted); font-size: 13px; margin-top: 6px; }
.vst-tags { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin: 16px 0 6px; }
.vst-title { font-size: 13px; color: var(--muted); text-align: left; margin: 26px 0 10px; }
.vst-bands { display: grid; gap: 9px; }
.vst-band { display: grid; grid-template-columns: 52px 1fr 44px 52px; gap: 10px; align-items: center; font-size: 12.5px; }
.vb-name { text-align: left; color: var(--ink-2); }
.vst-track { height: 8px; border-radius: 99px; background: var(--surface-3); overflow: hidden; display: block; }
.vst-track i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.vb-num { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink); font-weight: 600; }
.vb-size { text-align: right; color: var(--faint); font-variant-numeric: tabular-nums; }
.vst-note { text-align: left; font-size: 12.5px; color: var(--muted); line-height: 1.75; margin-top: 14px; }
.lv-acts kbd { margin-left: 6px; font: inherit; font-size: 11px; opacity: .45; border: 1px solid currentColor; border-radius: 4px; padding: 0 4px; }
.vst-caveat { font-size: 12px; opacity: .8; border-left: 2px solid var(--line); padding-left: 10px; }

/* 统计页：词汇量区间与历史 */
.vocab-panel { display: grid; grid-template-columns: 240px 1fr; gap: 22px; padding: 22px 24px; margin-bottom: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); align-items: start; }
.vp-left { border-right: 1px solid var(--line-2); padding-right: 22px; }
.vp-num { font-size: 50px; font-weight: 800; letter-spacing: -.04em; color: var(--accent-ink); font-variant-numeric: tabular-nums; line-height: 1.06; margin-top: 4px; }
.vp-num span { font-size: 15px; font-weight: 600; color: var(--faint); margin-left: 6px; letter-spacing: 0; }
.vp-range { font-size: 12.5px; color: var(--muted); margin-top: 8px; line-height: 1.6; }
.vp-delta-row { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.vp-delta { font-size: 21px; font-weight: 800; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.vp-delta.up { color: var(--accent); }
.vp-delta.down { color: var(--again); }
.vp-delta.flat { font-size: 13px; font-weight: 600; color: var(--muted); }
.vp-span { font-size: 12px; color: var(--faint); }
.vp-chart { height: 96px; margin: 8px 0 4px; }
.vp-spark { width: 100%; height: 100%; display: block; }
.vp-rows { display: grid; }
.vp-row { display: grid; grid-template-columns: 104px 88px 84px 1fr; gap: 8px; font-size: 12px; color: var(--muted); padding: 6px 0; border-top: 1px solid var(--line-2); align-items: center; }
.vp-row b { color: var(--ink); font-variant-numeric: tabular-nums; font-weight: 700; }
.vp-row em { font-style: normal; font-variant-numeric: tabular-nums; text-align: right; color: var(--faint); }
.vp-row em.up { color: var(--accent); }
.vp-row em.down { color: var(--again); }
.vp-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; gap: 10px; }
.vp-empty { font-size: 13px; color: var(--muted); margin: 0 0 12px; line-height: 1.75; }
@media (max-width: 900px) {
  .vocab-panel { grid-template-columns: 1fr; }
  .vp-left { border-right: 0; border-bottom: 1px solid var(--line-2); padding: 0 0 14px; }
}
.vp-answer { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 8px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line-2); }
.vp-answer div { display: flex; flex-direction: column; gap: 2px; }
.vp-answer em { font-style: normal; font-size: 11px; color: var(--faint); }
.vp-answer b { font-size: 16px; color: var(--ink); font-variant-numeric: tabular-nums; }
.dict-scope { font-size: 12.5px; padding: 6px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-family: inherit; cursor: pointer; }
.dict-hint { margin-top: 10px; font-size: 13px; letter-spacing: .16em; color: var(--faint); font-family: var(--font-serif); }
.dh-right { display: flex; align-items: center; gap: 8px; }
.dict-play-row { display: flex; align-items: center; justify-content: center; gap: 10px; }
.dict-slow { font-size: 12px; color: var(--muted); background: none; border: 1px solid var(--line); border-radius: 999px; padding: 5px 12px; cursor: pointer; font-family: inherit; }
.dict-slow:hover { color: var(--ink); border-color: var(--faint); }
.dict-hint-cn { letter-spacing: 0; font-family: inherit; font-size: 13.5px; color: var(--muted); }
.dict-words { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line-2); }
.dw-cap { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
.dw-cap em { font-style: normal; color: var(--faint); margin-left: 6px; }
.dw-row { display: grid; grid-template-columns: 170px 1fr 34px; max-width: 620px; align-items: center; gap: 10px; padding: 7px 0; border-bottom: 1px dashed var(--line-2); }
.dw-row:last-child { border-bottom: 0; }
.dw-row b { font-size: 14px; font-weight: 600; }
.dw-row span { font-size: 12.5px; color: var(--muted); }
.dw-add { width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); cursor: pointer; font-size: 15px; line-height: 1; color: var(--accent-ink); }
.dw-add:disabled { color: var(--faint); border-style: dashed; cursor: default; }
.vp-tip { margin: 18px 0 6px; padding: 22px 20px; border: 1px dashed var(--line-2); border-radius: 14px; color: var(--muted); font-size: 13px; text-align: center; }

/* 词汇量摸底：四选一 */
.lv-opts { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.lv-opt { display: flex; align-items: center; gap: 12px; width: 100%; padding: 15px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-sm); color: var(--ink); font-size: 15px; text-align: left; cursor: pointer; transition: border-color .16s, background .16s, transform .16s; }
.lv-opt:hover { border-color: var(--accent); transform: translateY(-1px); }
.lv-opt i { flex: none; width: 24px; height: 24px; border-radius: 7px; background: var(--surface-3); color: var(--muted); font-style: normal; font-size: 12px; font-weight: 650; display: grid; place-items: center; }
.lv-opt.is-right { border-color: var(--accent); background: var(--accent-soft); }
.lv-opt.is-right i { background: var(--accent); color: #fff; }
.lv-opt.is-wrong { border-color: var(--again); background: #fbeeee; }
.lv-opt.is-wrong i { background: #d9534f; color: #fff; }
.lv-opt.is-dim { opacity: .45; }
.lv-foot { display: flex; align-items: center; gap: 14px; margin-top: 14px; }
.lv-foot .drill-hint { margin: 0; }
/* 作文：本地估算分（提交页） */
.wg-band { display: grid; grid-template-columns: 200px 1fr; gap: 26px; align-items: center; margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--line-2); text-align: left; }
.wb-cap { font-size: 11.5px; letter-spacing: .12em; color: var(--faint); }
.wb-num { font-family: var(--font-serif); font-size: 52px; line-height: 1.05; color: var(--accent); }
.wb-range { font-size: 12px; color: var(--muted); }
.wb-row { display: grid; grid-template-columns: 76px 1fr 40px; align-items: center; gap: 12px; padding: 5px 0; }
.wb-row span { font-size: 12.5px; color: var(--muted); }
.wb-row b { font-size: 13px; font-variant-numeric: tabular-nums; text-align: right; }
.wb-track { height: 7px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.wb-track i { display: block; height: 100%; border-radius: 999px; background: var(--accent); }
.wb-note { font-size: 11.5px; color: var(--faint); margin-top: 6px; }
.wb-notes { margin: 16px 0 0; padding-left: 18px; text-align: left; }
.wb-notes li { font-size: 13px; color: var(--ink-2); line-height: 1.7; }
/* 作文统计 */
.wp-chart { height: 110px; margin: 14px 0 4px; }
.wp-chart canvas { width: 100%; height: 110px; display: block; }
.wp-sub { font-size: 12px; color: var(--faint); margin-bottom: 8px; }
.wp-lrow { display: grid; grid-template-columns: 58px 1fr 48px 52px 66px 88px; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line-2); font-size: 13px; }
.wp-lrow:last-child { border-bottom: 0; }
.wp-lrow .wp-d { color: var(--faint); font-variant-numeric: tabular-nums; }
.wp-lrow .wp-t { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wp-lrow b { text-align: right; font-variant-numeric: tabular-nums; }
.wp-lrow i { font-style: normal; color: var(--muted); font-size: 12px; }
.wp-lrow em { font-style: normal; color: var(--accent); font-variant-numeric: tabular-nums; }
.wp-lrow em.mute { color: var(--faint); }
.wp-lrow .ok { color: var(--accent-ink); font-size: 12px; }
.wp-lrow .bad { color: var(--again); font-size: 12px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }

/* ---------------- 梦校 · 免费申请清单 ---------------- */
.fa-panel { margin-top: 18px; }
.fa-total { margin-left: 10px; font-size: 12px; color: var(--faint); letter-spacing: 0; text-transform: none; }
.fa-lead { margin: 2px 0 14px; max-width: 780px; font-size: 13px; line-height: 1.7; color: var(--muted); }

.fa-tabs { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
.fa-tab {
  display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 13px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
  font-size: 13px; color: var(--muted); cursor: pointer; transition: all .18s var(--ease);
}
.fa-tab em { font-style: normal; font-size: 11.5px; color: var(--faint); }
.fa-tab:hover { border-color: var(--line-2); color: var(--ink); }
.fa-tab.is-on { background: var(--ink); border-color: var(--ink); color: #fff; }
.fa-tab.is-on em { color: rgba(255,255,255,.66); }
.fa-q {
  margin-left: auto; width: 210px; height: 34px; padding: 0 13px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
  font-size: 13px; color: var(--ink); outline: none;
}
.fa-q:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }

.fa-count { display: flex; align-items: center; margin: 0 0 10px; font-size: 12px; color: var(--faint); }
.fa-count b { color: var(--muted); margin: 0 3px; font-variant-numeric: tabular-nums; }

.fa-cont + .fa-cont { margin-top: 22px; }
.fa-cont-h {
  display: flex; align-items: baseline; gap: 10px; padding-bottom: 8px;
  border-bottom: 1px solid var(--line-2);
}
.fa-cont-h span { font-size: 15px; font-weight: 600; color: var(--ink); letter-spacing: .02em; }
.fa-cont-h em { font-style: normal; font-size: 12px; color: var(--faint); }

.fa-country { margin-top: 14px; }
.fa-ct { display: flex; align-items: baseline; gap: 9px; flex-wrap: wrap; margin-bottom: 5px; }
.fa-ct b { font-size: 13.5px; font-weight: 600; color: var(--ink); }
.fa-ct em { font-style: normal; font-size: 11.5px; color: var(--faint); }
.fa-ct span { font-size: 11.5px; color: var(--faint); }

.fa-list { display: flex; flex-direction: column; }
.fa-row {
  display: grid; grid-template-columns: 44px minmax(230px, 1.15fr) minmax(0, 1.45fr) minmax(178px, 1fr);
  gap: 5px 13px; align-items: start; padding: 10px 8px;
  border-radius: 10px; margin: 0 -8px;
  border-top: 1px dashed var(--line-2);
  transition: background .15s var(--ease);
}
.fa-row:first-child { border-top: 0; }
.fa-row:hover { background: var(--surface-2); }

.fa-tier {
  justify-self: start; padding: 1px 7px; border-radius: 999px;
  font-size: 10.5px; line-height: 18px; letter-spacing: .04em;
  border: 1px solid transparent;
}
.fa-tier.is-a { color: #9a4a2f; background: #fdf1ea; border-color: #f6ddcf; }
.fa-tier.is-b { color: var(--accent-deep); background: var(--accent-soft); border-color: rgba(31,107,79,.16); }
.fa-tier.is-c { color: #5d6b62; background: var(--surface-3); border-color: var(--line); }
.fa-tier.is-est { border-style: dashed; }

.fa-school { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; }
.fa-school b { font-size: 13.5px; font-weight: 500; color: var(--ink); }
.fa-qs { font-style: normal; font-size: 10.5px; color: var(--faint); letter-spacing: .02em; }
.fa-major { font-size: 12.5px; color: var(--muted); line-height: 1.55; }
.fa-req { display: flex; flex-direction: column; gap: 2px; }
.fr-pair { font-size: 12px; color: var(--muted); line-height: 1.5; }
.fr-pair b {
  display: inline-block; margin-right: 5px; padding: 0 5px; border-radius: 4px;
  background: var(--surface-3); color: var(--faint);
  font-size: 10.5px; font-weight: 500;
}
.fa-note { font-style: normal; font-size: 11.5px; color: var(--faint); line-height: 1.5; }

.fa-tips { margin: 20px 0 0; padding: 14px 16px; list-style: none; border-radius: 14px; background: var(--surface-2); }
.fa-tips li { position: relative; padding-left: 14px; font-size: 12.5px; line-height: 1.75; color: var(--muted); }
.fa-tips li + li { margin-top: 6px; }
.fa-tips li::before { content: ''; position: absolute; left: 0; top: 9px; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); opacity: .55; }
.fa-tips b { color: var(--ink); font-weight: 600; margin-right: 4px; }
.fa-empty { padding: 28px 0; text-align: center; font-size: 13px; color: var(--faint); }

@media (max-width: 1024px) {
  .fa-row { grid-template-columns: 40px minmax(0, 1fr); margin: 0 -8px; }
  .fa-major { grid-column: 2; }
  .fa-req { grid-column: 2; }
  .fa-q { flex: 1 1 100%; width: 100%; }
}
.fr-plain { font-size: 12px; color: var(--faint); }

/* 申请费状态芯片 */
.fa-fee { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 6px; font-size: 11px; font-style: normal; line-height: 17px; vertical-align: 1px; white-space: nowrap; }
.fa-fee.is-free { background: rgba(46,139,87,.10); color: #2f7a55; }
.fa-fee.is-paid { background: rgba(200,120,40,.10); color: #9a6a2a; }
.fa-fee.is-agent { background: rgba(60,120,160,.10); color: #2f6d92; }
.fa-fee.is-maybe { background: rgba(120,110,90,.10); color: #6f6553; }
.fa-fee.is-check { background: transparent; color: var(--faint); border: 1px dashed var(--line-3); }

/* 筛选芯片 */
.fa-ftab { font: inherit; font-size: 12.5px; color: var(--muted); background: none; border: 1px solid var(--line-2); border-radius: 999px; padding: 4px 11px; cursor: pointer; transition: all .16s; }
.fa-ftab:hover { color: var(--ink); border-color: var(--line-3); }
.fa-ftab.is-on { color: var(--ink); background: var(--surface-2); border-color: var(--line-3); font-weight: 600; }

.fa-tick { font-style: normal; font-size: 9px; margin-right: 3px; color: #2f7a55; vertical-align: 1px; }
.fa-legend { margin: 2px 0 12px; font-size: 11.5px; color: var(--faint); line-height: 1.7; }

.fa-warn { color: #8a5a20; background: rgba(200,140,40,.10); border-radius: 5px; padding: 1px 6px; margin: 0 2px; font-size: 12px; }

/* 专业类别芯片 */
.fa-cat {
  display: inline-block; margin-right: 7px; padding: 0 6px; border-radius: 5px;
  font-size: 10.5px; line-height: 17px; letter-spacing: .02em; vertical-align: 1px;
  border: 1px solid transparent; white-space: nowrap;
}
.fa-cat.is-social { color: #2f6d92; background: rgba(60,120,160,.09); border-color: rgba(60,120,160,.16); }
.fa-cat.is-business { color: #8a6a1f; background: rgba(200,160,50,.11); border-color: rgba(200,160,50,.20); }
.fa-cat.is-science { color: #4a6b52; background: rgba(80,130,95,.10); border-color: rgba(80,130,95,.18); }
.fa-cat.is-mixed { color: var(--faint); background: var(--surface-3); border-color: var(--line); }

/* 顶部工具条：洲 tabs + 搜索 */
.fa-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 2px 0 12px; }
.fa-bar .fa-tabs { margin: 0; flex: 1 1 auto; }
.fa-q {
  flex: 0 0 230px; width: 230px; height: 32px; padding: 0 12px;
  font: inherit; font-size: 12.5px; color: var(--ink);
  background: var(--surface); border: 1px solid var(--line-2); border-radius: 999px;
  transition: border-color .16s, box-shadow .16s;
}
.fa-q:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.fa-q::placeholder { color: var(--faint); }

/* 筛选行：左边标签 + 芯片 */
.fa-frow { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 10px; }
.fa-frow > b {
  min-width: 52px; font-size: 11.5px; font-weight: 500; color: var(--faint); letter-spacing: .03em;
}
.fa-ftab em { font-style: normal; margin-left: 2px; color: var(--faint); font-variant-numeric: tabular-nums; }
.fa-ftab.is-on em { color: var(--muted); }

/* 空结果 / 清空筛选 */
.fa-reset {
  margin-left: 10px; padding: 3px 11px; font: inherit; font-size: 12px;
  color: var(--accent-deep); background: var(--accent-soft);
  border: 1px solid rgba(31,107,79,.18); border-radius: 999px; cursor: pointer;
  transition: background .16s;
}
.fa-reset:hover { background: rgba(31,107,79,.16); }
.fa-empty .fa-reset { margin: 10px 0 0; }

/* ===== 丝滑化：微交互 ===== */
/* 训练卡 / 梦校卡：轻微上浮 */
.train-card, .plan-school { transition: transform 0.26s var(--ease-out), box-shadow 0.26s var(--ease); }
.train-card:hover, .plan-school:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(24, 48, 38, 0.09); }
.train-card:active, .plan-school:active { transform: translateY(0) scale(0.995); }

/* 分段控件 / 芯片：按压收缩 */
.seg button, .chip, .deck-chip, .fa-ftab, .fa-tab { transition: transform 0.16s var(--ease-out), background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease); }
.seg button:active, .chip:active, .deck-chip:active, .fa-ftab:active, .fa-tab:active { transform: scale(0.96); }

/* 词库行：悬浮时左侧出现提示条 */
.lib-row { position: relative; }
.lib-row::before {
  content: ''; position: absolute; left: 0; top: 8px; bottom: 8px; width: 2px;
  border-radius: 2px; background: var(--accent); opacity: 0;
  transform: scaleY(0.4); transition: opacity 0.2s var(--ease), transform 0.24s var(--ease-out);
}
.lib-row:hover::before { opacity: 0.55; transform: scaleY(1); }

/* 列表切换淡入（筛选/搜索后） */
.fa-body.enter, .lib-list.enter { animation: listIn 0.26s var(--ease-out); }
@keyframes listIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* 单词卡：翻转更顺手 */
.card3d .card-inner { will-change: transform; }

/* 授课语言芯片 */
.fa-lang { display: inline-block; font-size: 10.5px; padding: 1px 6px; border-radius: 6px; margin-right: 6px;
  border: 1px solid var(--line-2); color: var(--muted); background: var(--surface-2); white-space: nowrap; }
.fa-lang.is-de { color: #8a5a12; border-color: #e6cf9d; background: #fdf6e6; }
.fa-lang.is-local { color: #7a4a5c; border-color: #e3c3ce; background: #fbf1f4; }
.fa-lang.is-mixed { color: #4a5f74; border-color: #c8d5e0; background: #f2f6fa; }

/* 梦校：前 4 张卡一行 + 100 所申请池全宽卡 */
.plan-schools { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.plan-schools > .is-pool { grid-column: 1 / -1; }

@media (max-width: 1180px) {
  .plan-schools { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .plan-schools { grid-template-columns: minmax(0, 1fr); }
}

/* 四列时卡片更紧凑 */
.plan-schools > .plan-school:not(.is-pool) { padding: 16px 16px 14px; }
.plan-schools > .plan-school:not(.is-pool) .ps-name { font-size: 14.5px; }
.plan-schools > .plan-school:not(.is-pool) .ps-meta { font-size: 11.5px; }
.plan-schools > .plan-school:not(.is-pool) .ps-row { font-size: 11px; gap: 6px; }
.plan-schools > .plan-school:not(.is-pool) .ps-needs li { font-size: 11.5px; }
.plan-schools > .plan-school:not(.is-pool) .ps-note { font-size: 11px; }

/* ---- 100 所申请池：横向布局 ---- */
.plan-school.is-pool {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr) 240px;
  gap: 28px;
  align-items: center;
  padding: 22px 26px;
  background: linear-gradient(120deg, #fdf8ef 0%, var(--surface) 46%);
}
.pc-left { display: flex; flex-direction: column; gap: 4px; }
.pc-tier { font-size: 11px; color: #a3742a; letter-spacing: .08em; }
.pc-num { font-size: 44px; line-height: 1; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.pc-num span { font-size: 15px; font-weight: 400; color: var(--muted); margin-left: 3px; }
.pc-sub { font-size: 11.5px; color: var(--faint); }
.pc-mid { display: flex; flex-direction: column; gap: 9px; }
.pc-title { font-size: 16px; font-weight: 600; color: var(--ink); }
.pc-desc { font-size: 12px; color: var(--muted); line-height: 1.6; }
.pc-conts { display: flex; flex-wrap: wrap; gap: 6px; }
.pc-cont {
  font-size: 11.5px; color: var(--muted); padding: 2px 9px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--line);
}
.pc-cont b { color: var(--ink); font-weight: 600; margin-right: 4px; }
.pc-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.pc-chip {
  font-size: 11.5px; color: var(--muted); padding: 3px 10px; border-radius: 8px;
  background: #fff; border: 1px solid var(--line);
}
.pc-chip b { color: var(--ink); }
.pc-right { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; text-align: right; }
.pc-dl { font-size: 12.5px; color: var(--muted); }
.pc-dl b { color: var(--ink); font-size: 15px; }
.pc-note { font-size: 11px; color: var(--faint); line-height: 1.55; }
.pc-btn {
  margin-top: 2px; padding: 9px 18px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--accent); background: var(--accent); color: #fff;
  font-size: 12.5px; transition: transform .2s var(--ease-out), box-shadow .2s var(--ease);
}
.pc-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0,0,0,.12); }
.pc-btn:active { transform: scale(.97); }

@media (max-width: 1100px) {
  .plan-school.is-pool { grid-template-columns: 1fr; gap: 14px; text-align: left; }
  .pc-right { align-items: flex-start; text-align: left; }
}

/* ---- 100 句记完 8000 词 ---- */
.sent-wrap { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 18px; align-items: start; }
.sent-side { position: sticky; top: 0; }
.sent-progress { display: flex; align-items: baseline; gap: 7px; margin-bottom: 10px; }
.sent-progress b { font-size: 26px; font-family: var(--serif); color: var(--accent-deep); }
.sent-progress span { font-size: 12px; color: var(--muted); }
.sent-filters { display: flex; gap: 6px; margin-bottom: 8px; }
.sf { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 5px 11px; font-size: 12px; color: var(--muted); cursor: pointer; }
.sf.is-on { border-color: var(--accent); color: var(--ink); background: var(--accent-soft); }
.sent-q { width: 100%; height: 34px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); padding: 0 11px; font-size: 12.5px; color: var(--ink); margin-bottom: 10px; }
.sent-list { max-height: calc(100vh - 300px); overflow: auto; display: flex; flex-direction: column; gap: 2px; padding-right: 4px; }
.sl-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) 16px; align-items: center; gap: 8px; padding: 7px 8px; border-radius: 9px; border: 0; background: transparent; text-align: left; cursor: pointer; color: var(--muted); }
.sl-row:hover { background: var(--surface-2); }
.sl-row.is-on { background: var(--accent-soft); color: var(--ink); }
.sl-n { font-size: 11px; color: var(--faint); font-variant-numeric: tabular-nums; }
.sl-row.is-on .sl-n { color: var(--accent-deep); }
.sl-t { font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sl-ok { color: var(--accent); font-size: 11px; }

.sent-main { display: flex; flex-direction: column; gap: 12px; }
.sent-head { display: flex; align-items: center; gap: 10px; }
.sent-badge { background: var(--ink); color: #fff; border-radius: 999px; padding: 3px 10px; font-size: 11.5px; }
.sent-meta { font-size: 12px; color: var(--faint); }
.sent-done-chip { font-size: 11.5px; color: var(--accent-deep); background: var(--accent-soft); border-radius: 999px; padding: 3px 9px; }
.sent-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 24px 14px; box-shadow: var(--shadow-sm); }
.sent-text { font-size: 21px; line-height: 1.95; color: var(--ink); font-family: var(--serif); }
.sw { border-radius: 5px; padding: 1px 2px; cursor: pointer; transition: background .15s var(--ease); }
.sw.has { background: linear-gradient(transparent 62%, var(--accent-soft) 62%); }
.sw.has:hover { background: var(--accent-soft); }
.sw.is-blank { background: var(--surface-2); color: transparent; box-shadow: inset 0 -1px 0 var(--line); }
.sent-modes { display: flex; align-items: center; gap: 8px; margin-top: 16px; padding-top: 12px; border-top: 1px dashed var(--line); }
.sm { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 4px 12px; font-size: 12px; color: var(--muted); cursor: pointer; }
.sm.is-on { background: var(--ink); color: #fff; border-color: var(--ink); }
.sent-tip { font-size: 11.5px; color: var(--faint); margin-left: auto; }

.sent-player { display: flex; align-items: center; gap: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-pill); padding: 9px 14px; box-shadow: var(--shadow-sm); }
.sp-play { width: 40px; height: 40px; border-radius: 50%; border: 0; background: var(--accent); color: #fff; font-size: 13px; cursor: pointer; flex: 0 0 auto; }
.sp-bar { flex: 1; height: 5px; border-radius: 999px; background: var(--surface-3); overflow: hidden; cursor: pointer; }
.sp-bar i { display: block; height: 100%; width: 0; background: var(--accent); }
.sp-time { font-size: 11.5px; color: var(--faint); font-variant-numeric: tabular-nums; }
.sp-rate { border: 1px solid var(--line); background: transparent; border-radius: 8px; font-size: 11.5px; padding: 3px 7px; color: var(--muted); cursor: pointer; }
.sp-rate.is-on { border-color: var(--accent); color: var(--accent-deep); background: var(--accent-soft); }

.sent-words { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.sent-words-cap { font-size: 12px; color: var(--faint); margin-bottom: 10px; }
.sent-word-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; }
.sx { display: flex; flex-direction: column; gap: 2px; align-items: flex-start; text-align: left; border: 1px solid var(--line); background: var(--surface-2); border-radius: 10px; padding: 7px 10px; cursor: pointer; }
.sx:hover { border-color: var(--accent); background: var(--accent-soft); }
.sx b { font-size: 13px; color: var(--ink); font-weight: 500; }
.sx em { font-style: normal; font-size: 11.5px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.sent-acts { display: flex; gap: 10px; }

.sent-pop { position: fixed; z-index: 90; width: 250px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 12px 13px; }
.sp-h { display: flex; align-items: baseline; gap: 8px; }
.sp-h b { font-size: 16px; font-family: var(--serif); }
.sp-ipa { font-size: 12px; color: var(--faint); }
.sp-x { margin-left: auto; border: 0; background: transparent; color: var(--faint); font-size: 16px; cursor: pointer; line-height: 1; }
.sp-m { font-size: 12.5px; color: var(--ink); margin: 6px 0 0; }
.sp-ex { font-size: 11.5px; color: var(--muted); line-height: 1.6; margin: 6px 0 0; }
.sent-pop .btn { margin-top: 10px; width: 100%; }
.btn-sm { height: 30px; font-size: 12px; }

@media (max-width: 980px) {
  .sent-wrap { grid-template-columns: 1fr; }
  .sent-side { position: static; }
  .sent-list { max-height: 220px; }
  .sent-text { font-size: 18px; }
}

/* 训练页第五张卡 + 100 句课返回 */
.train-card.t-5 .tc-icon { background: #f2eefb; color: #6b5aa6; }
.sent-back { border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: 4px 11px; font-size: 12px; color: var(--muted); cursor: pointer; }
.sent-back:hover { border-color: var(--accent); color: var(--accent-deep); }

/* ===== 手绘风升级 ===== */
/* 图标统一：稍大的尺寸 + 略粗的描边，让手写线条在小尺寸下也立得住 */
.nav-item svg { width: 17px; height: 17px; stroke-width: 1.75; }
.tc-icon svg { width: 26px; height: 26px; stroke-width: 1.7; }

/* 图标底板：四角半径各不相同，像手工剪出来的纸片 */
.tc-icon {
  border-radius: 15px 17px 14px 18px;
  transform: rotate(-2.5deg);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .035), 0 1px 2px rgba(0, 0, 0, .03);
  transition: transform .35s var(--ease-spring), box-shadow .35s var(--ease);
}
.train-card:hover .tc-icon { transform: rotate(0deg) scale(1.04); }

/* 版心标题下面手画一道线 */
.view-head h1, .seam-title, .wr-sec {
  position: relative;
  padding-bottom: 9px;
}
.view-head h1::after, .wr-sec::after {
  content: '';
  position: absolute; left: 2px; bottom: -3px;
  width: 84px; height: 7px;
  background: no-repeat center/100% 100%
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 78 7'%3E%3Cpath d='M1.5 4.6C14 2.3 26 2.2 39 3.4c12 1.1 25 .6 37.5-1.2' fill='none' stroke='%23A9C6B2' stroke-width='2' stroke-linecap='round'/%3E%3C/svg%3E");
  opacity: .9;
}
.wr-sec::after { width: 46px; height: 6px; }

/* 打卡小圆点：手点上去的感觉 */
.pill, .chip, .deck-chip { border-radius: 11px 13px 12px 14px; }

/* 播放器、输入框这类方块也换掉死板圆角 */
.sent-card, .train-card, .plan-school, .panel { border-radius: 20px 22px 19px 23px; }

/* ===== EPQ / IPQ 工作台 ===== */
.eq-wrap { max-width: 1180px; margin: 0 auto; padding: 4px 0 40px; }
.eq-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.eq-tab {
  border: 1px solid var(--line); background: var(--surface); color: var(--muted);
  border-radius: 12px 14px 11px 15px; padding: 7px 15px; font-size: 13px; cursor: pointer;
  transition: color .2s var(--ease), border-color .2s var(--ease), background .2s var(--ease);
}
.eq-tab:hover { color: var(--ink); border-color: var(--line-2); }
.eq-tab.is-on { background: var(--accent-soft); border-color: transparent; color: var(--accent-deep); font-weight: 600; }

.eq-body { display: flex; flex-direction: column; gap: 16px; }
.eq-card {
  background: var(--surface); border-radius: 20px 22px 19px 23px;
  padding: 20px 22px; box-shadow: var(--shadow-sm);
}
.eq-h { font-size: 14px; font-weight: 600; color: var(--ink); margin: 0 0 12px; display: flex; align-items: baseline; gap: 10px; }
.eq-cnt { font-size: 11.5px; font-weight: 400; color: var(--faint); }
.eq-note { font-size: 12px; color: var(--muted); line-height: 1.7; margin: 6px 0 10px; }
.eq-empty { font-size: 12.5px; color: var(--faint); padding: 12px 0; }

/* 概览 */
.eq-hero { display: flex; gap: 24px; align-items: flex-start; justify-content: space-between; }
.eq-hero-l { min-width: 0; }
.eq-eyebrow { font-size: 10.5px; letter-spacing: .14em; color: var(--accent-deep); text-transform: uppercase; margin-bottom: 8px; }
.eq-rq { font-size: 17px; line-height: 1.55; color: var(--ink); margin: 0 0 8px; font-weight: 600; }
.eq-meta { font-size: 12px; color: var(--muted); margin: 0 0 6px; }
.eq-hero-r { text-align: center; flex: 0 0 auto; }
.eq-ring {
  width: 92px; height: 92px; border-radius: 50%; margin: 0 auto 6px; position: relative;
  background: conic-gradient(var(--accent) calc(var(--p) * 1%), var(--surface-3) 0);
}
.eq-ring::before { content: ''; position: absolute; inset: 9px; border-radius: 50%; background: var(--surface); }
.eq-ring span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 24px; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.eq-ring i { font-size: 11px; font-style: normal; color: var(--faint); margin-left: 1px; }
.eq-ring-cap { font-size: 11px; color: var(--faint); }
.eq-days { margin-top: 8px; font-size: 12px; color: var(--muted); }
.eq-days b { font-size: 15px; color: var(--accent-deep); }

.eq-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.eq-kpi { background: var(--surface); border-radius: 16px 18px 15px 19px; padding: 14px 16px; box-shadow: var(--shadow-sm); }
.eq-kpi b { display: block; font-size: 22px; font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.eq-kpi b i { font-size: 11px; font-style: normal; color: var(--faint); margin-left: 2px; }
.eq-kpi span { font-size: 11.5px; color: var(--muted); }

.eq-mile { display: flex; flex-direction: column; gap: 6px; }
.eq-ms { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; cursor: pointer; transition: background .2s var(--ease); }
.eq-ms:hover { background: var(--surface-2); }
.eq-ms input { width: 15px; height: 15px; accent-color: var(--accent); }
.eq-ms-t { font-size: 13px; color: var(--ink); flex: 1; }
.eq-ms.is-done .eq-ms-t { color: var(--faint); text-decoration: line-through; }
.eq-ms-w { font-size: 11px; color: var(--faint); }

.eq-req { margin: 0; padding-left: 18px; }
.eq-req li { font-size: 12.5px; color: var(--muted); line-height: 1.85; }
.eq-req b { color: var(--ink); font-weight: 600; }

/* 表单 */
.eq-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.eq-f { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--muted); }
.eq-f input, .eq-f textarea {
  border: 1px solid var(--line); border-radius: 11px; padding: 8px 11px; font-size: 13px;
  font-family: inherit; color: var(--ink); background: var(--surface); outline: none;
  transition: border-color .2s var(--ease);
}
.eq-f input:focus, .eq-f textarea:focus { border-color: var(--accent); }
.eq-checks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.eq-chk { font-size: 11.5px; color: var(--faint); border: 1px dashed var(--line-2); border-radius: 999px; padding: 4px 11px; }
.eq-chk.is-ok { color: var(--accent-deep); border-style: solid; border-color: var(--accent-soft); background: var(--accent-soft); }

/* 文献 / 日志表 */
.eq-lit-form, .eq-log-form { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.eq-lit-form input, .eq-log-form input {
  flex: 1 1 180px; border: 1px solid var(--line); border-radius: 10px; padding: 7px 10px;
  font-size: 12.5px; font-family: inherit; color: var(--ink); background: var(--surface); outline: none;
}
.eq-lit-form input:focus, .eq-log-form input:focus { border-color: var(--accent); }
.eq-btn {
  border: 0; background: var(--ink); color: #fff; border-radius: 10px;
  padding: 7px 16px; font-size: 12.5px; cursor: pointer; font-family: inherit;
}
.eq-btn:hover { background: var(--accent-deep); }
.eq-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.eq-table th { text-align: left; font-weight: 500; color: var(--faint); padding: 7px 8px; border-bottom: 1px solid var(--line); }
.eq-table td { padding: 8px; border-bottom: 1px dashed var(--line-2); color: var(--muted); vertical-align: top; line-height: 1.6; }
.eq-table td b { display: block; color: var(--ink); font-weight: 500; }
.eq-table td em { font-style: normal; color: var(--faint); font-size: 11px; }
.eq-table td i { font-style: normal; color: var(--faint); margin-left: 5px; }
.eq-c { text-align: center; width: 48px; }
.eq-mini { border: 1px solid var(--line); background: none; border-radius: 8px; padding: 2px 8px; font-size: 11px; color: var(--faint); cursor: pointer; font-family: inherit; }
.eq-mini:hover { color: #b4453c; border-color: #e6c9c5; }

/* 量表 */
.eq-items { display: flex; flex-direction: column; }
.eq-item { display: grid; grid-template-columns: 52px 1fr 74px 74px 74px; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px dashed var(--line-2); }
.eq-dim { font-size: 11px; color: var(--accent-deep); background: var(--accent-soft); border-radius: 6px; padding: 2px 6px; text-align: center; }
.eq-it { font-size: 12.5px; color: var(--ink); line-height: 1.5; }
.eq-it em { display: block; font-style: normal; font-size: 11px; color: var(--faint); margin-top: 2px; }
.eq-num { display: flex; align-items: center; gap: 5px; font-size: 10.5px; color: var(--faint); min-width: 0; white-space: nowrap; }
.eq-num span { flex: 0 0 auto; }
.eq-num input {
  width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 5px 7px;
  font-size: 12px; font-family: inherit; color: var(--ink); background: var(--surface); outline: none;
}
.eq-num input:focus { border-color: var(--accent); }

/* 数据 */
.eq-bars { display: flex; flex-direction: column; gap: 9px; }
.eq-bar { display: grid; grid-template-columns: 96px 1fr 52px; gap: 12px; align-items: center; }
.eq-bar-n { font-size: 12px; color: var(--ink); }
.eq-bar-n i { display: block; font-style: normal; font-size: 10px; color: var(--faint); }
.eq-bar-t { height: 9px; background: var(--surface-3); border-radius: 999px; overflow: hidden; }
.eq-bar-t b { display: block; height: 100%; border-radius: 999px; }
.eq-bar-t b.neg { background: #d98b83; }
.eq-bar-t b.pos { background: var(--accent); }
.eq-bar-v { font-size: 12px; color: var(--muted); text-align: right; font-variant-numeric: tabular-nums; }

.eq-ipa { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.eq-ipa-q { border-radius: 14px; padding: 16px; background: var(--surface-2); display: flex; flex-direction: column; gap: 3px; }
.eq-ipa-q b { font-size: 13px; color: var(--ink); }
.eq-ipa-q span { font-size: 11px; color: var(--faint); }
.eq-ipa-q.q1 { background: #fdf3f2; }
.eq-ipa-q.q2 { background: var(--accent-soft); }

/* 写作 */
.eq-prog { height: 8px; background: var(--surface-3); border-radius: 999px; overflow: hidden; margin-bottom: 16px; }
.eq-prog b { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.eq-chaps { display: flex; flex-direction: column; gap: 14px; }
.eq-chap-h { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--ink); }
.eq-chap-h span { color: var(--faint); font-variant-numeric: tabular-nums; }
.eq-chap-b { height: 5px; background: var(--surface-3); border-radius: 999px; overflow: hidden; margin: 5px 0 6px; }
.eq-chap-b b { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.eq-chap input {
  width: 120px; border: 1px solid var(--line); border-radius: 8px; padding: 5px 9px;
  font-size: 12px; font-family: inherit; color: var(--ink); background: var(--surface); outline: none;
}
.eq-chap input:focus { border-color: var(--accent); }

/* 自评 */
.eq-aos { display: flex; flex-direction: column; gap: 16px; }
.eq-ao-h { display: flex; justify-content: space-between; font-size: 12.5px; color: var(--ink); }
.eq-ao-h span { color: var(--faint); }
.eq-ao-s { display: flex; align-items: center; gap: 12px; margin: 8px 0; }
.eq-ao-s input { flex: 1; accent-color: var(--accent); }
.eq-ao-s output { font-size: 13px; color: var(--ink); font-variant-numeric: tabular-nums; width: 34px; text-align: right; }
.eq-ao ul { margin: 0; padding-left: 18px; }
.eq-ao li { font-size: 11.5px; color: var(--muted); line-height: 1.8; }

.eq-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 18px; font-size: 11px; color: var(--faint); }

@media (max-width: 900px) {
  .eq-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .eq-grid2 { grid-template-columns: 1fr; }
  .eq-hero { flex-direction: column; }
  .eq-item { grid-template-columns: 44px 1fr; }
  .eq-num { grid-column: span 1; }
  .eq-ipa { grid-template-columns: 1fr; }
}

/* EPQ 新增：IPA 图 / 粘贴框 / 下拉 */
.eq-ipa-svg { width: 100%; max-width: 660px; height: auto; display: block; margin: 10px auto 6px; }
.eq-paste {
  width: 100%; box-sizing: border-box; font-family: ui-monospace, Consolas, monospace;
  font-size: 12px; line-height: 1.6; color: var(--ink); background: var(--surface);
  border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; outline: none; resize: vertical;
}
.eq-paste:focus { border-color: var(--accent); }
.eq-row { display: flex; align-items: center; gap: 12px; margin-top: 10px; }
.eq-sel {
  border: 1px solid var(--line); border-radius: 10px; padding: 7px 10px; font-size: 12.5px;
  font-family: inherit; color: var(--ink); background: var(--surface); outline: none; flex: 0 0 96px;
}
.eq-sel:focus { border-color: var(--accent); }

/* EPQ v2：下一步 / 差距表 / 两间对比 / 引用 / 章节清单 */
.eq-next { display: flex; align-items: center; justify-content: space-between; gap: 18px; background: linear-gradient(180deg, #f7f5ee, var(--surface)); }
.eq-next b { display: block; font-size: 15px; color: var(--ink); margin: 2px 0 4px; }
.eq-next .eq-note { margin: 0; }
.eq-gap td.eq-neg { color: #b4453c; font-weight: 600; }
.eq-gap td.eq-pos { color: var(--accent-deep); font-weight: 600; }
.eq-find { background: var(--surface-2); border-radius: 12px; padding: 12px 14px; color: var(--ink); margin-top: 12px; }
.eq-cin {
  width: 76px; border: 1px solid var(--line); border-radius: 8px; padding: 5px 8px;
  font-size: 12px; font-family: inherit; color: var(--ink); background: var(--surface); outline: none;
}
.eq-cin:focus { border-color: var(--accent); }
.eq-cmp-svg { width: 100%; max-width: 660px; height: auto; display: block; margin: 12px auto 0; }
.eq-cite { margin-top: 4px; font-size: 11px; color: var(--accent-deep); word-break: break-word; }
.eq-chk-list { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; }
.eq-chk-item { display: flex; align-items: flex-start; gap: 7px; font-size: 11.5px; color: var(--faint); line-height: 1.6; cursor: pointer; }
.eq-chk-item input { margin-top: 2px; accent-color: var(--accent); }
.eq-chk-item.is-ok { color: var(--accent-deep); }
.eq-foot-r { display: flex; gap: 8px; align-items: center; }
.eq-mini--pri { border-color: var(--accent-soft); background: var(--accent-soft); color: var(--accent-deep); }
.eq-mini--pri:hover { border-color: var(--accent); }
/* ---------- EPQ 新手引导：简介页 + 每页提示卡 ---------- */
.eq-wrap--intro { padding-top: 4px; }

.eq-intro {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 34px 38px 30px;
  box-shadow: 0 18px 48px rgba(24, 32, 28, 0.06);
  animation: eqIntroIn 0.46s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes eqIntroIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}
.eq-intro-eyebrow {
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--accent-ink); font-weight: 600;
}
.eq-intro-t { font-size: 26px; margin: 10px 0 12px; letter-spacing: -0.01em; }
.eq-intro-p { font-size: 14.5px; line-height: 1.95; color: var(--ink-2); margin: 0 0 20px; }
.eq-intro-p b { color: var(--ink); }
.eq-intro-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px; margin: 0 0 22px;
}
.eq-intro-k {
  background: var(--surface-2); border-radius: 14px; padding: 14px 16px;
  animation: eqIntroIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}
.eq-intro-k:nth-child(1) { animation-delay: 0.06s; }
.eq-intro-k:nth-child(2) { animation-delay: 0.12s; }
.eq-intro-k:nth-child(3) { animation-delay: 0.18s; }
.eq-intro-k:nth-child(4) { animation-delay: 0.24s; }
.eq-intro-k b { display: block; font-size: 22px; color: var(--accent-ink); letter-spacing: -0.02em; }
.eq-intro-k span { display: block; margin-top: 4px; font-size: 12px; color: var(--muted); line-height: 1.6; }
.eq-intro-h { font-size: 14px; margin: 0 0 10px; }
.eq-intro-steps { margin: 0 0 18px; padding-left: 20px; }
.eq-intro-steps li { font-size: 13.5px; line-height: 2; color: var(--ink-2); }
.eq-intro-steps b { color: var(--ink); }
.eq-intro-note { font-size: 12.5px; color: var(--faint); line-height: 1.85; margin: 0 0 20px; }
.eq-intro-acts { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }

.eq-helprow { display: flex; justify-content: flex-end; margin: -2px 0 8px; }

.eq-coach {
  display: flex; gap: 14px; align-items: flex-start;
  background: linear-gradient(180deg, #f6f8f4, var(--surface));
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 16px;
  padding: 16px 18px 14px;
  margin-bottom: 14px;
  animation: eqCoachIn 0.42s cubic-bezier(0.16, 1, 0.3, 1) both;
}
@keyframes eqCoachIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}
.eq-coach-ico {
  flex: 0 0 26px; width: 26px; height: 26px; border-radius: 8px;
  background: var(--accent-soft); color: var(--accent-ink);
  font-weight: 700; font-size: 14px; display: grid; place-items: center;
}
.eq-coach-body { flex: 1 1 auto; min-width: 0; }
.eq-coach-body > b { font-size: 14px; display: block; margin-bottom: 4px; }
.eq-coach-body > p { font-size: 13px; line-height: 1.85; color: var(--ink-2); margin: 0 0 6px; }
.eq-coach-body ul { margin: 0; padding-left: 18px; }
.eq-coach-body li { font-size: 12.5px; line-height: 1.9; color: var(--muted); }
.eq-coach-ok {
  flex: 0 0 auto; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink-2); font-size: 12.5px; padding: 7px 13px; border-radius: 999px;
  cursor: pointer; transition: background 0.2s var(--ease-out), color 0.2s;
}
.eq-coach-ok:hover { background: var(--accent-soft); color: var(--accent-ink); }

[data-theme="dark"] .eq-intro { background: rgba(28, 32, 30, 0.72); }
[data-theme="dark"] .eq-intro-k { background: rgba(255, 255, 255, 0.04); }
[data-theme="dark"] .eq-coach { background: linear-gradient(180deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02)); }
@media (prefers-reduced-motion: reduce) {
  .eq-intro, .eq-intro-k, .eq-coach { animation: none; }
  .eq-intro-k { animation-delay: 0s; }
}
/* EPQ：渲染错误兜底 */
.eq-err { border-left: 3px solid #c0504d; }
.eq-err h3 { margin: 0 0 8px; font-size: 16px; }
.eq-err p { margin: 6px 0; font-size: 13px; line-height: 1.7; }
.eq-err .faint { color: var(--faint); }

/* 统计页：雅思实考趋势 */
.st-chart { height: 150px; margin: 10px 0 2px; }
.st-chart canvas { width: 100%; height: 100%; display: block; }
