:root {
  --grad: linear-gradient(135deg, #4f6df5 0%, #7c5cf0 100%);
  --primary: #4f6df5;
  --primary-dark: #3b57d8;
  --bg: #f2f4fb;
  --card: #ffffff;
  --text: #22263a;
  --muted: #7b8098;
  --ok: #16a34a;
  --ok-bg: #e5f8ec;
  --bad: #e2454a;
  --bad-bg: #fdeaea;
  --gold: #f5a623;
  --radius: 16px;
  --shadow: 0 3px 14px rgba(50, 62, 130, .08);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
  margin: 0;
  font-family: "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
}

button { font-family: inherit; }

/* ---------- 通用 ---------- */

.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  margin-bottom: 16px;
}

h2 { margin: 0 0 14px; }
h3 { margin: 0 0 10px; font-size: 17px; }

.card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.card-head h3 { margin: 0; }

.home-duo-card {
  border: 1px solid #dfe6ff;
  background: linear-gradient(180deg, #f7f9ff 0%, #ffffff 60%);
}
.home-duo-tip { margin: 0 0 12px; }
.home-duo-tasks {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.home-duo-row {
  display: grid;
  grid-template-columns: 28px 1fr auto auto;
  gap: 8px 10px;
  align-items: center;
  padding: 12px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid #e7ebf8;
}
.home-duo-row .duo-idx {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  color: #fff;
  background: var(--primary);
}
.home-duo-row .duo-main { min-width: 0; }
.home-duo-row .duo-main b {
  display: block;
  font-size: 14px;
  margin-bottom: 2px;
}
.home-duo-row .duo-main .hint {
  display: block;
  margin: 0;
  font-size: 12px;
  line-height: 1.35;
}
.home-duo-row .duo-status,
.home-duo-row .duo-status.wait {
  background: #fff1d6;
  color: #b7791f;
}
.home-duo-row .duo-status.ok {
  background: var(--ok-bg);
  color: var(--ok);
}
.home-duo-row .btn { flex-shrink: 0; min-width: 72px; }
.home-read-row {
  border-color: #cfe9d8;
  background: linear-gradient(180deg, #f3fbf6 0%, #fff 70%);
}
.home-read-row .duo-idx { background: #16a34a; }

/* ---------- 每日阅读 ---------- */
.read-word-box {
  margin: 8px 0 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: #f3fbf6;
  border: 1px solid #cfe9d8;
  font-size: 12px;
  line-height: 1.55;
  color: var(--muted);
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.read-word-box b {
  color: #166534;
  margin-right: 6px;
}
.read-word-box span { color: var(--text); }
.read-passage {
  white-space: pre-wrap;
  line-height: 1.7;
  font-size: 16px;
  color: var(--text);
  background: #f7f9ff;
  border-radius: 12px;
  padding: 14px 16px;
  border: 1px solid #e7ebf8;
  margin: 8px 0 4px;
}
.read-passage mark.focus {
  background: #dcfce7;
  color: #14532d;
  padding: 0 3px;
  border-radius: 4px;
}
.read-passage mark.past {
  background: #e0e7ff;
  color: #312e81;
  padding: 0 3px;
  border-radius: 4px;
}
.read-tip { margin-top: 8px; }
.read-questions { display: flex; flex-direction: column; gap: 16px; }
.read-q {
  padding: 12px;
  border-radius: 12px;
  border: 1px solid #e7ebf8;
  background: #fff;
}
.read-q .rq-title {
  font-weight: 650;
  font-size: 14px;
  margin-bottom: 10px;
  line-height: 1.45;
}
.read-q .rq-opts { display: flex; flex-direction: column; gap: 8px; }
.read-q .rq-opt {
  text-align: left;
  border: 1px solid #dfe6ff;
  background: #f7f9ff;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  cursor: pointer;
  color: var(--text);
}
.read-q .rq-opt:disabled { cursor: default; opacity: 1; }
.read-q .rq-opt.correct {
  background: var(--ok-bg);
  border-color: #86efac;
  color: #166534;
  font-weight: 650;
}
.read-q .rq-opt.wrong {
  background: var(--bad-bg);
  border-color: #fca5a5;
  color: #991b1b;
}
.read-q .rq-fb {
  margin-top: 8px;
  font-size: 13px;
  color: var(--muted);
}
.read-q .rq-fb.ok { color: var(--ok); }
.read-q .rq-fb.bad { color: var(--bad); }
.read-result {
  margin: 14px 0;
  padding: 12px;
  border-radius: 12px;
  background: #eef1ff;
  font-size: 14px;
  line-height: 1.5;
}
.chip-status {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
}
.chip-status.warn { background: #fff1d6; color: #b7791f; }
.chip-status.ok { background: var(--ok-bg); color: var(--ok); }
.chip-status.muted { background: #eef0f6; color: var(--muted); }

.btn {
  border: none;
  border-radius: 12px;
  padding: 11px 20px;
  font-size: 15px;
  cursor: pointer;
  transition: transform .05s;
}
.btn:active { transform: scale(.97); }
.btn.primary { background: var(--grad); color: #fff; font-weight: 600; }
.btn.ghost { background: #edf0fa; color: var(--text); }
.btn.ghost.danger, .btn.small.danger { color: var(--bad); }
.btn.outline {
  background: #fff;
  border: 1.5px dashed var(--primary);
  color: var(--primary);
  font-weight: 600;
}
.btn.white { background: #fff; color: var(--primary); font-weight: 700; }
.btn.white.ghost { background: rgba(255,255,255,.22); color: #fff; }
.btn.link { background: none; color: var(--primary); padding: 4px 8px; font-size: 14px; }
.btn.big { width: 100%; padding: 14px; font-size: 16px; }
.btn.small { padding: 6px 14px; font-size: 13px; border-radius: 9px; }

.hint { color: var(--muted); font-size: 13px; margin: 6px 0; }
.hint code { background: #edf0fa; padding: 1px 6px; border-radius: 5px; }

.field { margin-bottom: 16px; }
.field > label { display: block; font-weight: 600; margin-bottom: 8px; }
.field-row { display: flex; gap: 12px; flex-wrap: wrap; }
.field-row .field { flex: 1; min-width: 130px; }

select, input[type=text], input[type=date], textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1.5px solid #dde1f0;
  border-radius: 11px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
}
textarea { resize: vertical; }

.plain-list { list-style: none; padding: 0; margin: 0; }
.plain-list li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 2px;
  border-bottom: 1px dashed #e8ebf5;
  font-size: 14px;
  color: var(--muted);
}
.plain-list li b { color: var(--text); }
.plain-list li:last-child { border-bottom: none; }

.empty-tip { color: var(--muted); text-align: center; padding: 26px 0; font-size: 14px; }

/* ---------- 登录 ---------- */

#screen-login {
  min-height: 100vh;
  background: var(--grad);
  padding: 0 16px 40px;
}

.login-hero {
  text-align: center;
  color: #fff;
  padding: 56px 0 28px;
}
.login-logo { font-size: 56px; }
.login-hero h1 { margin: 8px 0 6px; letter-spacing: 2px; }
.login-hero p { margin: 0; opacity: .85; font-size: 14px; }

.login-card { max-width: 420px; margin: 0 auto; padding: 24px; }

.profile-list { display: flex; flex-direction: column; gap: 10px; }
.profile-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border: 1.5px solid #e3e7f5;
  border-radius: 14px;
  background: #fff;
  cursor: pointer;
  font-size: 16px;
  width: 100%;
  text-align: left;
}
.profile-item:hover { border-color: var(--primary); background: #f5f7ff; }
.profile-item .pa { font-size: 26px; }
.profile-item .pn { font-weight: 700; flex: 1; }
.profile-item .pd { color: var(--muted); font-size: 12px; }
.profile-item .pdel {
  border: none; background: none; color: #c3c8da; font-size: 15px; cursor: pointer; padding: 4px;
}
.profile-item .pdel:hover { color: var(--bad); }

.divider {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin: 18px 0 12px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: #e8ebf5; }

.avatar-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.avatar-grid button {
  font-size: 24px;
  padding: 8px 0;
  border: 1.5px solid #e3e7f5;
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
}
.avatar-grid button.picked { border-color: var(--primary); background: #eef1ff; }

.auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  background: #edf0fa;
  border-radius: 12px;
  padding: 4px;
}
.auth-tab {
  flex: 1;
  border: none;
  background: transparent;
  padding: 10px;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
}
.auth-tab.active { background: #fff; color: var(--primary); box-shadow: var(--shadow); }

/* ---------- 顶栏与底部导航 ---------- */

#topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 18px;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(8px);
  box-shadow: 0 1px 0 rgba(50,62,130,.06);
}
#topbar .brand { font-weight: 800; font-size: 17px; }

.user-chip {
  border: none;
  background: #edf0fa;
  border-radius: 999px;
  padding: 5px 14px 5px 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
}

main { max-width: 680px; margin: 16px auto 84px; padding: 0 14px; }

.screen { display: none; }
.screen.active { display: block; }
#screen-login.screen { display: none; }
#screen-login.screen.active { display: block; }

#tabbar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  box-shadow: 0 -2px 12px rgba(50,62,130,.08);
  padding: 6px 0 max(6px, env(safe-area-inset-bottom));
}
.tab-btn {
  flex: 1;
  border: none;
  background: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 12px;
  color: var(--muted);
  cursor: pointer;
  padding: 4px 0;
}
.tab-btn span { font-size: 20px; }
.tab-btn.active { color: var(--primary); font-weight: 700; }

/* ---------- 今日 ---------- */

.hero-card {
  background: var(--grad);
  border-radius: 20px;
  color: #fff;
  padding: 22px;
  margin-bottom: 16px;
  box-shadow: 0 6px 20px rgba(79,109,245,.32);
}
.hero-date { opacity: .8; font-size: 13px; }
.hero-card h2 { margin: 6px 0 4px; font-size: 22px; }
.hero-card p { margin: 0 0 16px; opacity: .92; font-size: 15px; }
.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(90px, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}
.stat-card {
  background: var(--card);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 12px 8px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.stat-card b { font-size: 22px; color: var(--primary); }
.stat-card span { font-size: 12px; color: var(--muted); }

/* ---------- 计划 / 闯关地图 ---------- */

.plan-hero {
  background: var(--grad);
  color: #fff;
  border-radius: 20px;
  padding: 20px;
  margin-bottom: 14px;
  box-shadow: 0 6px 20px rgba(79,109,245,.28);
}
.plan-hero-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}
.plan-hero-kicker {
  font-size: 12px;
  opacity: .85;
  margin-bottom: 4px;
}
.plan-hero h2 {
  margin: 0 0 6px;
  font-size: 22px;
}
.plan-hero-top p {
  margin: 0;
  opacity: .9;
  font-size: 13px;
  line-height: 1.45;
}
.plan-hero-score {
  min-width: 72px;
  text-align: center;
  background: rgba(255,255,255,.16);
  border-radius: 14px;
  padding: 10px 8px;
}
.plan-hero-score b {
  display: block;
  font-size: 22px;
  line-height: 1.1;
}
.plan-hero-score span { font-size: 11px; opacity: .9; }

.plan-duo-tasks {
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.plan-duo-row {
  display: grid;
  grid-template-columns: 28px 1fr auto auto;
  gap: 8px 10px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.2);
}
.plan-duo-row .duo-idx {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  background: rgba(255,255,255,.22);
}
.plan-duo-row .duo-main { min-width: 0; }
.plan-duo-row .duo-main b {
  display: block;
  font-size: 14px;
  margin-bottom: 2px;
}
.plan-duo-row .duo-main .hint {
  display: block;
  margin: 0;
  color: rgba(255,255,255,.88);
  font-size: 11px;
  line-height: 1.35;
}
.duo-status {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
  white-space: nowrap;
}
.duo-status.wait { background: rgba(255,255,255,.18); color: #fff; }
.duo-status.ok { background: #dcfce7; color: #15803d; }
.plan-duo-row .btn.white {
  flex-shrink: 0;
  color: var(--primary);
  background: #fff;
  min-width: 72px;
}

.plan-bars { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.plan-bars.compact {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid rgba(255,255,255,.18);
  opacity: .92;
}
.plan-bars.compact .plan-bar-row { font-size: 11px; }
.plan-bar-row {
  display: grid;
  grid-template-columns: 36px 1fr 44px;
  gap: 8px;
  align-items: center;
  font-size: 12px;
}
.plan-bar-track {
  height: 8px;
  background: rgba(255,255,255,.25);
  border-radius: 999px;
  overflow: hidden;
}
.plan-bar-fill {
  height: 100%;
  width: 0;
  background: #fff;
  border-radius: inherit;
  transition: width .35s ease;
}
.plan-bar-fill.rev { background: #ffd98a; }
.plan-bar-row em { font-style: normal; text-align: right; opacity: .95; }

.plan-map-card { padding-top: 16px; }

.plan-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 14px;
}
.plan-legend .lg {
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #f1f3fa;
  color: #5c6585;
  font-weight: 600;
}
.plan-legend .lg.done { background: #e8f8ef; color: #168a4a; }
.plan-legend .lg.pending { background: #eef1ff; color: #4f6df5; }
.plan-legend .lg.today { background: #fff3d8; color: #c47b00; }
.plan-legend .lg.locked { background: #f1f2f6; color: #8a90a5; }
.plan-legend .lg.miss { background: #fdeaea; color: var(--bad); }

.plan-sections { display: flex; flex-direction: column; gap: 16px; }
.plan-section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}
.plan-section-head h4 { margin: 0; font-size: 15px; }
.plan-section-head span { font-size: 12px; color: var(--muted); }

.plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
  gap: 8px;
}
.plan-cell {
  border: 1.5px solid #e3e7f5;
  border-radius: 14px;
  background: #fff;
  padding: 10px 6px 8px;
  text-align: center;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font: inherit;
  color: inherit;
  min-height: 78px;
}
.plan-cell .pl-icon { font-size: 14px; line-height: 1; min-height: 16px; }
.plan-cell .pl-name { font-weight: 800; font-size: 15px; }
.plan-cell .pl-sub { font-size: 11px; color: var(--muted); font-weight: 600; }

.plan-cell.done { border-color: #22a85b; background: #e8f8ef; }
.plan-cell.done .pl-name,
.plan-cell.done .pl-sub { color: #168a4a; }
.plan-cell.today { border-color: #f0a933; background: #fff8e8; box-shadow: 0 0 0 2px rgba(240,169,51,.2); }
.plan-cell.today .pl-name,
.plan-cell.today .pl-sub { color: #c47b00; }
.plan-cell.miss { border-color: #f0b3b5; background: #fdf1f1; }
.plan-cell.miss .pl-name,
.plan-cell.miss .pl-sub { color: var(--bad); }
.plan-cell.pending { border-color: #c9d4f5; background: #f4f7ff; }
.plan-cell.pending .pl-name { color: #3f5fd0; }
.plan-cell.pending .pl-sub { color: #6b7eb8; }
.plan-cell.locked { opacity: .62; cursor: not-allowed; background: #f4f5fa; }
.plan-cell.rev { border-style: dashed; }
.plan-cell.rev.done { border-style: solid; }
.plan-cell.selected { outline: 2px solid var(--primary); outline-offset: 1px; }

.plan-action {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 16px;
  padding: 12px 14px;
  background: linear-gradient(135deg, #eef1ff, #f7f9ff);
  border-radius: 14px;
  border: 1px solid #dfe6ff;
}
.plan-action-row {
  display: flex;
  align-items: center;
  gap: 12px;
}
.plan-action-row.hard {
  padding-top: 10px;
  border-top: 1px dashed #d5dcf5;
}
.plan-action-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.plan-action-main b { font-size: 15px; }
.plan-action-main span { font-size: 12px; color: var(--muted); line-height: 1.4; }
.plan-action-row .btn { flex-shrink: 0; }

.rule-list {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}
.rule-list b { color: var(--text); }

/* ---------- 统计 ---------- */

.level-bars { display: flex; flex-direction: column; gap: 8px; }
.level-bar-row { display: flex; align-items: center; gap: 10px; font-size: 13px; }
.level-bar-row .lb-name { width: 56px; font-weight: 600; }
.level-bar-row .lb-track {
  flex: 1;
  height: 12px;
  background: #edf0fa;
  border-radius: 6px;
  overflow: hidden;
}
.level-bar-row .lb-fill { height: 100%; border-radius: 6px; background: var(--grad); }
.level-bar-row .lb-fill.low { background: linear-gradient(135deg, #f08c5c, #e2454a); }
.level-bar-row .lb-val { width: 72px; text-align: right; color: var(--muted); font-size: 12px; }

/* ---------- 我的 ---------- */

.me-card { display: flex; align-items: center; gap: 14px; }
.me-avatar {
  font-size: 38px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #eef1ff;
  display: flex;
  align-items: center;
  justify-content: center;
}
.me-info { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.me-info b { font-size: 18px; }

/* ---------- 选择芯片 ---------- */

.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 8px 13px;
  border: 1.5px solid #dde1f0;
  border-radius: 11px;
  cursor: pointer;
  font-size: 14px;
  user-select: none;
  background: #fff;
}
.chip small { color: var(--muted); font-size: 12px; }
.chip input { display: none; }
.chip:has(input:checked) { border-color: var(--primary); background: #eef1ff; color: var(--primary); }

.chip.compact { flex-direction: row; align-items: baseline; gap: 6px; padding: 6px 10px; font-size: 13px; }
.chip.compact small { font-size: 11px; }

.picker-tools { float: right; display: flex; gap: 6px; }
.picker-tools .btn { padding: 3px 10px; font-size: 12px; }

.switch-line { display: flex; align-items: center; gap: 8px; font-weight: 600; cursor: pointer; }
.switch-line input { width: 18px; height: 18px; }

/* ---------- 答题 ---------- */

.quiz-head { margin-bottom: 14px; }
.progress-wrap { height: 8px; background: #dfe4f5; border-radius: 4px; overflow: hidden; }
.progress-bar { height: 100%; width: 0; background: var(--grad); transition: width .3s; }
.quiz-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}
.quiz-meta .timer { font-weight: 700; color: var(--primary); font-variant-numeric: tabular-nums; }
.quiz-meta .timer.low { color: var(--bad); }
.quiz-meta button { margin-left: auto; }

.question-card { text-align: center; padding: 26px 20px; }

.q-type {
  display: inline-block;
  background: #eef1ff;
  color: var(--primary);
  font-size: 13px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 999px;
  margin-bottom: 14px;
}

.speak-zone {
  display: block;
  width: 100%;
  border: 1.5px dashed transparent;
  background: #f7f9ff;
  border-radius: 14px;
  padding: 14px 12px 10px;
  margin: 0 0 8px;
  cursor: pointer;
  font: inherit;
  color: inherit;
}
.speak-zone.enabled {
  border-color: rgba(79, 109, 245, .28);
}
.speak-zone.enabled:active {
  background: #eef1ff;
  border-color: var(--primary);
}
.speak-zone:disabled {
  cursor: default;
  background: transparent;
  border-color: transparent;
}
.speak-hint {
  margin-top: 6px;
  font-size: 12px;
  color: #8b93b0;
}

.q-prompt {
  font-size: 32px;
  font-weight: 800;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  line-height: 1.35;
}

.speak-btn {
  border: none;
  background: #eef1ff;
  font-size: 19px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  flex: none;
  transition: transform .12s, background .12s;
}
.speak-btn:hover { background: #dfe6ff; }
.speak-btn:active, .speak-btn.playing {
  background: #4f6df5;
  color: #fff;
  transform: scale(1.08);
}

.q-phonetic {
  color: #5b6b9a;
  margin-top: 8px;
  min-height: 22px;
  font-size: 18px;
  font-family: "Segoe UI", "Lucida Grande", "PingFang SC", sans-serif;
  letter-spacing: .02em;
}
.speak-zone.enabled .q-phonetic {
  text-decoration: underline dotted rgba(79, 109, 245, .45);
  text-underline-offset: 4px;
}

.options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 22px;
}
@media (max-width: 520px) { .options { grid-template-columns: 1fr; } }

.option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 12px;
  border: 1.5px solid #dde1f0;
  border-radius: 13px;
  font-size: 16px;
  cursor: pointer;
  background: #fff;
  text-align: left;
}
.option .opt-letter {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: #eef1ff;
  color: var(--primary);
  font-weight: 800;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
}
.option .opt-text { flex: 1; line-height: 1.4; }
.option:hover:not(:disabled) { border-color: var(--primary); background: #f6f8ff; }
.option.correct { border-color: var(--ok); background: var(--ok-bg); font-weight: 700; }
.option.correct .opt-letter { background: var(--ok); color: #fff; }
.option.wrong { border-color: var(--bad); background: var(--bad-bg); }
.option.wrong .opt-letter { background: var(--bad); color: #fff; }
.option.picked { border-color: var(--primary); background: #eef1ff; }
.option:disabled { cursor: default; color: var(--text); }

.write-box { display: flex; gap: 10px; margin-top: 22px; }
.write-box input { flex: 1; font-size: 17px; }

.feedback { margin-top: 18px; padding: 12px; border-radius: 11px; font-size: 16px; font-weight: 700; }
.feedback.ok { background: var(--ok-bg); color: var(--ok); }
.feedback.bad { background: var(--bad-bg); color: var(--bad); }

.q-actions { margin-top: 18px; display: flex; justify-content: center; gap: 12px; min-height: 44px; }

/* ---------- 本场进度板 ---------- */

.quiz-board { margin-top: 4px; }
.quiz-board-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 10px;
}
.quiz-board-head h3 { margin: 0; font-size: 16px; }

.quiz-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.quiz-stats .qs {
  background: #f4f6fc;
  border-radius: 12px;
  padding: 8px 4px;
  text-align: center;
}
.quiz-stats .qs b {
  display: block;
  font-size: 20px;
  color: var(--primary);
  line-height: 1.2;
}
.quiz-stats .qs.ok b { color: var(--ok); }
.quiz-stats .qs.bad b { color: var(--bad); }
.quiz-stats .qs span { font-size: 11px; color: var(--muted); }

.quiz-dots-wrap {
  max-height: 148px;
  overflow: auto;
  padding: 2px;
  margin: 0 -2px;
}
.quiz-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.qdot {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: none;
  font-size: 11px;
  font-weight: 700;
  cursor: default;
  color: #7b829c;
  background: #eef0f6;
  padding: 0;
}
.qdot.ok { background: #d8f5e4; color: #168a4a; }
.qdot.bad { background: #fde2e2; color: #d64545; }
.qdot.cur {
  outline: 2px solid var(--primary);
  outline-offset: 1px;
  background: #e8eeff;
  color: var(--primary);
}
.qdot.ok.cur { background: #c8efd8; }
.qdot.bad.cur { background: #fccccc; }
.qdot.wait { background: #eef0f6; color: #8a91a8; }
.qdot.ok, .qdot.bad { cursor: pointer; }

.quiz-dots-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
  font-size: 11px;
  color: var(--muted);
}
.quiz-dots-legend span { display: inline-flex; align-items: center; gap: 4px; }
.quiz-dots-legend .d {
  width: 10px;
  height: 10px;
  border-radius: 3px;
  display: inline-block;
}
.quiz-dots-legend .d.ok { background: #22a85b; }
.quiz-dots-legend .d.bad { background: #e2454a; }
.quiz-dots-legend .d.cur { background: var(--primary); }
.quiz-dots-legend .d.wait { background: #cfd3e0; }

/* ---------- 成绩 ---------- */

.result-card { text-align: center; }

.pass-banner {
  background: #fff9ec;
  color: var(--gold);
  font-weight: 800;
  font-size: 17px;
  border-radius: 12px;
  padding: 10px;
  margin-bottom: 14px;
}

.score-circle {
  width: 128px;
  height: 128px;
  margin: 6px auto 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  font-size: 42px;
  font-weight: 800;
  color: var(--primary);
  border: 8px solid #eef1ff;
}
.score-circle small { font-size: 15px; font-weight: 700; }

.result-summary { color: var(--muted); margin-bottom: 16px; line-height: 1.9; }
.result-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin: 12px 0 2px; }

.review-list { margin-top: 10px; }
.review-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 4px;
  border-bottom: 1px solid #eef1f8;
  font-size: 14px;
  text-align: left;
}
.review-item:last-child { border-bottom: none; }
.review-item .mark { font-size: 16px; width: 22px; text-align: center; flex: none; }
.review-item .w { font-weight: 700; min-width: 92px; }
.review-item .t { color: var(--muted); flex: 1; }
.review-item .ua { color: var(--bad); font-size: 12px; }
.review-item .cnt { color: var(--gold); font-size: 12px; font-weight: 700; flex: none; }
.review-item .speak-btn { width: 32px; height: 32px; font-size: 14px; }
.review-item .del { border: none; background: none; color: #c3c8da; cursor: pointer; font-size: 15px; }
.review-item .del:hover { color: var(--bad); }
