/* ============================================================
   状元答题 · 宣纸书院风格
   ============================================================ */
:root {
  --paper: #f6f1e4;
  --paper-2: #fffdf6;
  --ink: #23211c;
  --ink-soft: #6f675a;
  --ink-faint: #9a9184;
  --line: #e2d8c3;
  --line-strong: #cdbfa4;
  --seal: #b23a2e;
  --seal-dark: #8f2b21;
  --seal-soft: #f7e5e0;
  --gold: #c19a3c;
  --gold-soft: #f6ecd4;
  --jade: #3f6b58;
  --jade-soft: #e3efe8;
  --shadow-sm: 0 1px 2px rgba(60, 48, 30, 0.08);
  --shadow-md: 0 6px 20px rgba(60, 48, 30, 0.10);
  --shadow-lg: 0 18px 48px rgba(60, 48, 30, 0.16);
  --radius: 14px;
  --serif: "Songti SC", "STSong", "SimSun", "Noto Serif CJK SC", serif;
  --sans: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: var(--sans);
  color: var(--ink);
  background:
    radial-gradient(1100px 620px at 88% -10%, #fff8e6 0%, rgba(255, 248, 230, 0) 62%),
    radial-gradient(900px 520px at 4% 104%, #efe7d3 0%, rgba(239, 231, 211, 0) 60%),
    var(--paper);
  -webkit-font-smoothing: antialiased;
}

.paper-grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.5;
  background-image:
    repeating-linear-gradient(0deg, rgba(150, 130, 96, 0.045) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, rgba(150, 130, 96, 0.035) 0 1px, transparent 1px 4px);
}

#app {
  position: relative;
  z-index: 1;
}

button {
  font-family: inherit;
  font-size: 15px;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

button:disabled { cursor: not-allowed; opacity: 0.45; }

input, textarea {
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
}

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: 0.02em;
  margin: 0;
}

/* ---------------------------------------------------------- 通用组件 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
  background: linear-gradient(180deg, #c04236, var(--seal));
  color: #fff8ef;
  box-shadow: 0 6px 16px rgba(178, 58, 46, 0.28);
}
.btn-primary:hover:not(:disabled) { background: linear-gradient(180deg, #cb4a3d, #a8342a); }

.btn-ghost {
  background: var(--paper-2);
  border-color: var(--line-strong);
  color: var(--ink);
}
.btn-ghost:hover:not(:disabled) { border-color: var(--seal); color: var(--seal); }

.btn-gold {
  background: linear-gradient(180deg, #d3ac4e, var(--gold));
  color: #3a2c0c;
  box-shadow: 0 6px 16px rgba(193, 154, 60, 0.28);
}

.btn-sm { padding: 8px 14px; font-size: 13.5px; border-radius: 8px; }
.btn-block { width: 100%; }

.card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.muted { color: var(--ink-soft); }
.tiny { font-size: 12.5px; }

/* ---------------------------------------------------------- 登录页 */
.auth-wrap {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
}
.auth-side {
  position: relative;
  padding: 64px 56px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 253, 246, 0.7), rgba(246, 241, 228, 0.2)),
    repeating-linear-gradient(95deg, rgba(160, 140, 104, 0.06) 0 2px, transparent 2px 9px);
}
.auth-side .brand-mark {
  width: 62px; height: 62px;
  border-radius: 8px;
  background: var(--seal);
  color: #fff7ea;
  font-family: var(--serif);
  font-size: 26px;
  display: grid;
  place-items: center;
  letter-spacing: 2px;
  box-shadow: 0 8px 20px rgba(178, 58, 46, 0.25);
}
.auth-side h1 {
  font-size: 44px;
  line-height: 1.32;
  margin: 34px 0 18px;
}
.auth-side h1 em {
  font-style: normal;
  color: var(--seal);
}
.auth-side h1 .hero-dedic {
  display: inline-block;
  margin-top: 10px;
  font-size: 20px;
  font-weight: 500;
  color: var(--ink-soft);
  letter-spacing: 0.04em;
}
.auth-side p.lead {
  color: var(--ink-soft);
  font-size: 15.5px;
  line-height: 1.9;
  max-width: 30em;
  margin: 0;
}
.auth-feats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 38px;
}
.auth-feat {
  flex: 1 1 150px;
  padding: 16px 18px;
  border-left: 3px solid var(--line-strong);
  background: rgba(255, 253, 246, 0.6);
}
.auth-feat b { display: block; font-family: var(--serif); font-size: 17px; margin-bottom: 6px; }
.auth-feat span { font-size: 12.5px; color: var(--ink-soft); line-height: 1.7; }

.auth-side footer { font-size: 12px; color: var(--ink-faint); }

.auth-panel {
  display: grid;
  place-items: center;
  padding: 40px 28px;
}
.auth-card {
  width: min(398px, 100%);
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 34px 32px 30px;
  box-shadow: var(--shadow-lg);
  animation: rise 0.45s ease both;
}
.auth-card h2 { font-size: 24px; margin-bottom: 6px; }
.auth-card .sub { font-size: 13px; color: var(--ink-soft); margin: 0 0 24px; }

.tabs {
  display: flex;
  gap: 6px;
  padding: 5px;
  background: #f1ead9;
  border-radius: 10px;
  margin-bottom: 22px;
}
.tab {
  flex: 1;
  padding: 9px 0;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
  transition: all 0.18s ease;
}
.tab.active {
  background: var(--paper-2);
  color: var(--seal);
  box-shadow: var(--shadow-sm);
}

.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 12.5px;
  color: var(--ink-soft);
  margin-bottom: 7px;
  letter-spacing: 0.04em;
}
.field input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  background: #fffefa;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}
.field input:focus {
  outline: none;
  border-color: var(--seal);
  box-shadow: 0 0 0 3px rgba(178, 58, 46, 0.10);
}
.form-error {
  min-height: 18px;
  font-size: 12.5px;
  color: var(--seal);
  margin: -4px 0 12px;
}

/* ---------------------------------------------------------- 顶部导航 */
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 12px 28px;
  background: rgba(250, 246, 236, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.logo { display: flex; align-items: center; gap: 11px; }
.logo .mark {
  width: 36px; height: 36px;
  border-radius: 6px;
  background: var(--seal);
  color: #fff7ea;
  font-family: var(--serif);
  font-size: 17px;
  display: grid;
  place-items: center;
  letter-spacing: 1px;
}
.logo strong { font-family: var(--serif); font-size: 17.5px; letter-spacing: 0.06em; }

.nav { display: flex; gap: 4px; margin-left: 8px; }
.nav button {
  padding: 8px 15px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--ink-soft);
  font-weight: 600;
}
.nav button:hover { background: #f0e9d8; color: var(--ink); }
.nav button.active { background: var(--seal-soft); color: var(--seal-dark); }

.wallet { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--paper-2);
  font-size: 13px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.pill .dot {
  width: 15px; height: 15px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 9px;
  color: #fff;
  font-family: var(--serif);
}
.dot-gold { background: linear-gradient(150deg, #e0bd63, #a8802a); }
.dot-seal { background: linear-gradient(150deg, #c9564a, #8f2b21); }

.user-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 12px 5px 6px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--paper-2);
}
.avatar {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: linear-gradient(150deg, #e6dcc4, #cbbb9a);
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 14px;
  color: #5b4a28;
  border: 2px solid transparent;
}
.avatar.frame_bamboo { border-color: var(--jade); box-shadow: 0 0 0 2px var(--jade-soft); }
.avatar.frame_gilt {
  border-color: var(--gold);
  box-shadow: 0 0 0 2px var(--gold-soft), 0 0 12px rgba(193, 154, 60, 0.5);
}
.user-chip .who { display: flex; flex-direction: column; line-height: 1.25; }
.user-chip .who b { font-size: 13px; font-weight: 600; }
.user-chip .who span { font-size: 11px; color: var(--ink-soft); }

/* ---------------------------------------------------------- 内容容器 */
.page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 34px 28px 72px;
  animation: rise 0.35s ease both;
}

.section-head { margin-bottom: 18px; }
.section-head h2 { font-size: 26px; }
.section-head p { margin: 8px 0 0; color: var(--ink-soft); font-size: 13.5px; }

.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 30px;
  margin-bottom: 26px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background:
    radial-gradient(600px 200px at 100% 0%, rgba(246, 236, 212, 0.9), rgba(255, 253, 246, 0)) ,
    var(--paper-2);
  box-shadow: var(--shadow-sm);
}
.hero h2 { font-size: 27px; margin-bottom: 8px; }
.hero p { margin: 0; color: var(--ink-soft); font-size: 13.5px; line-height: 1.8; }
.hero-stats { display: flex; gap: 26px; }
.hero-stat b {
  display: block;
  font-family: var(--serif);
  font-size: 24px;
  font-variant-numeric: tabular-nums;
}
.hero-stat span { font-size: 11.5px; color: var(--ink-soft); letter-spacing: 0.06em; }

.level-bar {
  position: relative;
  height: 8px;
  border-radius: 999px;
  background: #ece3cf;
  overflow: hidden;
  margin-top: 10px;
}
.level-bar i {
  position: absolute;
  inset: 0 auto 0 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #d3ac4e, var(--tier, var(--seal)));
  transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.subject-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(206px, 1fr));
  gap: 14px;
}
.subject {
  position: relative;
  text-align: left;
  padding: 18px 18px 16px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  overflow: hidden;
}
.subject:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.subject.selected { border-color: var(--seal); box-shadow: 0 0 0 1px var(--seal) inset; }
.subject .glyph {
  width: 42px; height: 42px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 21px;
  color: #fffdf6;
  margin-bottom: 13px;
}
.subject h3 { font-size: 17px; margin-bottom: 5px; }
.subject p { margin: 0; font-size: 12px; color: var(--ink-soft); }
.subject .corner {
  position: absolute;
  right: -18px; top: -18px;
  width: 46px; height: 46px;
  transform: rotate(45deg);
  background: var(--seal-soft);
}

.round-config {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 26px;
  padding: 18px 22px;
  border-radius: 13px;
  border: 1px dashed var(--line-strong);
  background: rgba(255, 253, 246, 0.7);
}
.seg { display: flex; gap: 6px; padding: 4px; background: #f1ead9; border-radius: 9px; }
.seg button {
  padding: 8px 16px;
  border-radius: 7px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--ink-soft);
  white-space: nowrap;
}
.seg button.active { background: var(--paper-2); color: var(--seal); box-shadow: var(--shadow-sm); }

/* ---------------------------------------------------------- 答题 */
.quiz-shell {
  max-width: 800px;
  margin: 0 auto;
}
.quiz-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  font-size: 13px;
  color: var(--ink-soft);
}
.progress {
  height: 6px;
  border-radius: 999px;
  background: #eae0cb;
  overflow: hidden;
  margin-bottom: 20px;
}
.progress i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #d3ac4e, var(--seal));
  transition: width 0.35s ease;
}
.quiz-replay-hint {
  margin: -8px 0 16px;
  font-size: 12px;
  color: var(--ink-faint);
  padding: 6px 10px;
  border-radius: var(--radius-sm, 8px);
  background: #f6efe0;
}

.q-card {
  padding: 30px 32px 26px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-md);
  animation: rise 0.3s ease both;
}
.q-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.badge {
  font-size: 11.5px;
  padding: 4px 10px;
  border-radius: 6px;
  letter-spacing: 0.05em;
  font-weight: 600;
}
.badge-type { background: var(--seal-soft); color: var(--seal-dark); }
.badge-tag { background: #efe9d8; color: var(--ink-soft); font-weight: 500; }
.stars { margin-left: auto; color: var(--gold); font-size: 12px; letter-spacing: 2px; }

.q-stem {
  font-family: var(--serif);
  font-size: 21px;
  line-height: 1.75;
  margin-bottom: 24px;
}

.options { display: flex; flex-direction: column; gap: 10px; }
.option {
  display: flex;
  align-items: flex-start;
  gap: 13px;
  width: 100%;
  text-align: left;
  padding: 14px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fffefa;
  transition: all 0.16s ease;
  font-size: 15px;
  line-height: 1.6;
}
.option:hover { border-color: var(--line-strong); background: #fffdf4; }
.option .key {
  flex: 0 0 26px;
  height: 26px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  background: #f0e9d8;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--ink-soft);
  transition: all 0.16s ease;
}
.option.selected {
  border-color: var(--seal);
  background: var(--seal-soft);
  box-shadow: 0 0 0 1px var(--seal) inset;
}
.option.selected .key { background: var(--seal); color: #fff8ef; }
.option.correct { border-color: var(--jade); background: var(--jade-soft); }
.option.correct .key { background: var(--jade); color: #fff; }
.option.wrong { border-color: var(--seal); background: var(--seal-soft); }
.option.wrong .key { background: var(--seal); color: #fff; }
.option .mark { margin-left: auto; font-size: 12px; font-weight: 600; }

.judge-row { display: flex; gap: 14px; }
.judge-row .option { justify-content: center; padding: 22px; font-size: 17px; font-family: var(--serif); }
.judge-row .option .key { display: none; }

.answer-input {
  width: 100%;
  padding: 14px 16px;
  border: none;
  border-bottom: 2px solid var(--line-strong);
  background: transparent;
  font-size: 17px;
  font-family: var(--serif);
}
.answer-input:focus { outline: none; border-bottom-color: var(--seal); }
textarea.answer-input {
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  min-height: 128px;
  resize: vertical;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.8;
  background: #fffefa;
}
textarea.answer-input:focus { border-color: var(--seal); }
.hint { margin-top: 10px; font-size: 12.5px; color: var(--ink-faint); }

.quiz-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 22px;
}
.dots { display: flex; gap: 6px; }
.dots i {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #ddd2ba;
}
.dots i.done { background: var(--jade); }
.dots i.current { background: var(--seal); transform: scale(1.35); }

/* ---------------------------------------------------------- 结算 */
.result-hero {
  text-align: center;
  padding: 34px 24px 26px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background:
    radial-gradient(420px 220px at 50% -20%, rgba(246, 236, 212, 1), rgba(255, 253, 246, 0)),
    var(--paper-2);
  box-shadow: var(--shadow-md);
  margin-bottom: 18px;
}
.score-ring {
  width: 132px; height: 132px;
  margin: 0 auto 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: conic-gradient(var(--seal) var(--pct, 0%), #ece3cf 0);
  position: relative;
}
.score-ring::after {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 50%;
  background: var(--paper-2);
}
.score-ring b {
  position: relative;
  z-index: 1;
  font-family: var(--serif);
  font-size: 34px;
  font-variant-numeric: tabular-nums;
}
.score-ring b small { font-size: 13px; color: var(--ink-soft); font-family: var(--sans); }
.result-hero h2 { font-size: 24px; margin-bottom: 8px; }
.reward-row { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.reward {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fffefa;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  animation: pop 0.5s cubic-bezier(0.22, 1.4, 0.36, 1) both;
}
.reward.points { color: var(--seal); border-color: #efd3cd; background: var(--seal-soft); }
.reward.coins { color: #8a6a20; border-color: #ecdcb4; background: var(--gold-soft); }
.levelup {
  margin-top: 16px;
  padding: 11px 16px;
  border-radius: 10px;
  background: linear-gradient(90deg, var(--gold-soft), #fbf3dd);
  border: 1px solid #e7d3a2;
  color: #7a5b16;
  font-size: 13.5px;
  font-weight: 600;
  animation: glow 1.8s ease-in-out infinite;
}

/* ------------------------------------------------------------ 段位与升级仪式 */
.tier-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px 3px 3px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--tier, #6f9c7a) 12%, #fffdf6);
  border: 1px solid color-mix(in srgb, var(--tier, #6f9c7a) 32%, #fffdf6);
  color: var(--tier, #6f9c7a);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.6;
  vertical-align: middle;
  white-space: nowrap;
}
.tier-badge i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: block;
  background: var(--tier, #6f9c7a);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--tier, #6f9c7a) 18%, transparent);
  margin: 0 1px 0 4px;
}
.tier-badge.compact { padding: 1px 7px 1px 3px; font-size: 11px; gap: 5px; }
.tier-badge.compact i { width: 6px; height: 6px; }

.hero-level {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 2px 0 12px;
}
.hero-level .hero-title {
  font-family: var(--serif);
  font-size: 18px;
  letter-spacing: 0.02em;
}
.hero-level b { color: var(--seal); font-variant-numeric: tabular-nums; }
.hero-level-foot {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 9px;
}
.tier-track { display: inline-flex; gap: 4px; }
.tier-track i {
  width: 15px;
  height: 4px;
  border-radius: 999px;
  background: #e6dcc6;
}
.tier-track i.on { background: var(--tier, #6f9c7a); }

.levelup-card {
  position: relative;
  margin-top: 18px;
  padding: 15px 20px 16px;
  border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--tier, #c19a3c) 34%, #efe6d2);
  background:
    radial-gradient(420px 140px at 100% 0%, color-mix(in srgb, var(--tier, #c19a3c) 14%, transparent), transparent 70%),
    linear-gradient(135deg, color-mix(in srgb, var(--tier, #c19a3c) 8%, #fffdf6), #fffdf6 62%);
  animation: rise 0.4s ease both;
}
.levelup-card.tier-up {
  box-shadow: 0 12px 32px color-mix(in srgb, var(--tier, #c19a3c) 22%, transparent);
  animation: rise 0.4s ease both, glow 2.6s ease-in-out infinite;
}
.lu-flag {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--tier, #c19a3c);
  color: #fffdf6;
  font-size: 11px;
  letter-spacing: 0.1em;
}
.lu-main { display: flex; align-items: center; gap: 16px; margin: 12px 0 8px; }
.lu-side { display: flex; align-items: baseline; gap: 7px; }
.lu-side b { font-family: var(--serif); font-size: 22px; color: var(--ink-faint); }
.lu-side span { font-size: 13px; color: var(--ink-faint); }
.lu-side.now b,
.lu-side.now span { color: var(--tier, var(--seal)); }
.lu-arrow { color: var(--ink-faint); font-size: 16px; }
.lu-note { font-size: 13px; color: #6b551c; }
.lu-note b { color: var(--tier, #7a5b16); }
.lu-next { margin-top: 6px; font-size: 12px; color: var(--ink-faint); }

.review { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.review-item {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper-2);
  overflow: hidden;
}
.review-head {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  width: 100%;
  text-align: left;
}
.review-head .state {
  flex: 0 0 auto;
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
  margin-top: 2px;
}
.state.ok { background: var(--jade-soft); color: var(--jade); }
.state.half { background: var(--gold-soft); color: #8a6a20; }
.state.no { background: var(--seal-soft); color: var(--seal-dark); }
.review-head .txt { flex: 1; font-size: 14.5px; line-height: 1.65; }
.review-body {
  padding: 0 16px 16px;
  border-top: 1px dashed var(--line);
  margin-top: 2px;
  font-size: 13.5px;
  line-height: 1.85;
  color: var(--ink-soft);
  padding-top: 14px;
}
.review-body b { color: var(--ink); }
.review-body .exp { margin-top: 8px; color: var(--ink); }
.review-toggle { font-size: 12px; color: var(--ink-faint); margin-left: auto; white-space: nowrap; }
.review-verify {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--paper-2);
  border: 0.5px solid var(--line);
  flex-wrap: wrap;
}
.review-verify .tiny { flex: 1; min-width: 180px; }
.cb-review {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--paper-2);
  border: 0.5px solid var(--line);
  flex-wrap: wrap;
}
.cb-review .tiny { flex: 1; min-width: 140px; }

/* ---------------------------------------------------------- 商店 */
.shop-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(238px, 1fr));
  gap: 14px;
}
.item {
  display: flex;
  flex-direction: column;
  padding: 18px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.item:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.item.equipped { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold) inset; }
.item-top { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.item .glyph {
  width: 44px; height: 44px;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 20px;
  background: #f0e9d8;
  color: #6b5a34;
}
.item.equipped .glyph { background: var(--gold-soft); color: #8a6a20; }
.item h3 { font-size: 16px; margin-bottom: 3px; }
.item .cat { font-size: 11px; color: var(--ink-faint); letter-spacing: 0.08em; }
.item .desc { font-size: 12.5px; color: var(--ink-soft); line-height: 1.7; margin: 0 0 14px; flex: 1; }
.item-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.price { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 14px; color: #8a6a20; font-variant-numeric: tabular-nums; }
.tag-equipped {
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 5px;
  background: var(--gold-soft);
  color: #8a6a20;
  font-weight: 700;
}

/* ---------------------------------------------------------- 排行 */
.rank-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.rank-table th {
  text-align: left;
  font-size: 11.5px;
  letter-spacing: 0.08em;
  color: var(--ink-faint);
  font-weight: 600;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}
.rank-table td { padding: 13px 14px; border-bottom: 1px solid #f0e9d8; font-variant-numeric: tabular-nums; }
.rank-table tr:last-child td { border-bottom: none; }
.rank-no {
  width: 26px; height: 26px;
  border-radius: 7px;
  display: inline-grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 13px;
  background: #f0e9d8;
  color: var(--ink-soft);
}
.rank-no.top1 { background: linear-gradient(150deg, #e5c46b, #b8912f); color: #fff9ea; }
.rank-no.top2 { background: linear-gradient(150deg, #d7d2c6, #a8a294); color: #fff; }
.rank-no.top3 { background: linear-gradient(150deg, #d8a97e, #ab7546); color: #fff; }
.me-row td { background: #fdf6e4; font-weight: 600; }

/* ---------------------------------------------------------- 我的 */
.profile-grid { display: grid; grid-template-columns: 320px 1fr; gap: 18px; align-items: start; }
.profile-card { padding: 26px 24px; text-align: center; }
.profile-card .avatar-lg {
  width: 78px; height: 78px;
  border-radius: 50%;
  margin: 0 auto 14px;
  display: grid;
  place-items: center;
  font-family: var(--serif);
  font-size: 32px;
  background: linear-gradient(150deg, #e8dfc9, #cdbc9a);
  color: #5b4a28;
  border: 3px solid transparent;
}
.profile-card .avatar-lg.frame_bamboo { border-color: var(--jade); box-shadow: 0 0 0 4px var(--jade-soft); }
.profile-card .avatar-lg.frame_gilt { border-color: var(--gold); box-shadow: 0 0 0 4px var(--gold-soft), 0 0 24px rgba(193, 154, 60, 0.55); }
.profile-card h3 { font-size: 21px; }
.profile-card .title-tag {
  display: inline-block;
  margin-top: 8px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--seal-soft);
  color: var(--seal-dark);
  font-size: 12px;
  font-weight: 600;
}
.profile-card .level-line { margin-top: 18px; text-align: left; }
.profile-card .level-line .row { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-soft); }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 1px; background: var(--line); border-radius: 12px; overflow: hidden; border: 1px solid var(--line); }
.stat { background: var(--paper-2); padding: 18px 16px; }
.stat b { display: block; font-family: var(--serif); font-size: 23px; font-variant-numeric: tabular-nums; }
.stat span { font-size: 11.5px; color: var(--ink-soft); }

.history-list { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.history-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper-2);
  font-size: 13.5px;
}
.history-row .score { margin-left: auto; font-weight: 700; font-variant-numeric: tabular-nums; }
.history-units { display: flex; gap: 5px; flex-wrap: wrap; min-width: 0; }
.history-units i {
  font-style: normal;
  font-size: 11px;
  color: var(--jade);
  background: var(--jade-soft);
  border: 1px solid #cfe0d6;
  border-radius: 6px;
  padding: 1px 7px;
  white-space: nowrap;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.empty {
  padding: 46px 20px;
  text-align: center;
  color: var(--ink-faint);
  font-size: 13.5px;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
}

/* ---------------------------------------------------------- 提示条 */
.toast {
  position: fixed;
  left: 50%;
  bottom: 34px;
  transform: translate(-50%, 20px);
  padding: 12px 22px;
  border-radius: 10px;
  background: #2b2822;
  color: #f8f2e4;
  font-size: 13.5px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: all 0.28s ease;
  z-index: 100;
  max-width: min(420px, 88vw);
  text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: var(--seal-dark); }

/* ---------------------------------------------------------- 动效 */
@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pop {
  0% { opacity: 0; transform: scale(0.86); }
  100% { opacity: 1; transform: scale(1); }
}
@keyframes glow {
  0%, 100% { box-shadow: 0 0 0 rgba(193, 154, 60, 0); }
  50% { box-shadow: 0 0 18px rgba(193, 154, 60, 0.35); }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ---------------------------------------------------------- 响应式 */
@media (max-width: 900px) {
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-side { display: none; }
  .profile-grid { grid-template-columns: 1fr; }
  .hero { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 720px) {
  .topbar { flex-wrap: wrap; padding: 10px 16px; gap: 10px; }
  .nav { order: 3; width: 100%; overflow-x: auto; }
  .wallet { gap: 6px; }
  .pill { padding: 6px 10px; font-size: 12px; }
  .user-chip .who { display: none; }
  .page { padding: 22px 16px 60px; }
  .q-card { padding: 22px 18px; }
  .q-stem { font-size: 18.5px; }
  .hero { padding: 20px; }
  .hero h2 { font-size: 22px; }
  .hero-stats { gap: 18px; flex-wrap: wrap; }
}

/* ---------------------------------------------------------- 教材目录导航 */
.desk-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 286px;
  gap: 14px;
  align-items: stretch;
  margin-top: 22px;
}
.desk-top .book-bar { margin-top: 0; }
.book-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 18px;
  box-shadow: var(--shadow-sm);
  margin-top: 22px;
}

/* ---------------------------------------------------------- 错题集训模块 */
.train-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 9px;
  padding: 14px 16px;
  border-radius: var(--radius);
  border: 1px solid #e6cdb9;
  background: linear-gradient(165deg, #fffbf4 0%, #fbeee0 100%);
  box-shadow: var(--shadow-sm);
}
.train-card::after {
  content: "集训";
  position: absolute;
  right: -6px;
  bottom: -24px;
  font-family: var(--serif);
  font-size: 68px;
  line-height: 1;
  letter-spacing: 0.02em;
  color: rgba(178, 58, 46, 0.055);
  pointer-events: none;
}
.train-card.is-idle { background: linear-gradient(165deg, #fffdf7 0%, #f6f1e4 100%); border-color: var(--line); }
.train-head { display: flex; align-items: center; gap: 10px; position: relative; z-index: 1; }
.train-seal {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--seal);
  color: #fff;
  font-family: var(--serif);
  font-size: 15px;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.16);
}
.train-card.is-idle .train-seal { background: #b9ad99; }
.train-title { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.train-title b {
  font-family: var(--serif);
  font-size: 15.5px;
  letter-spacing: 0.06em;
  color: var(--ink);
}
.train-title em {
  font-style: normal;
  font-size: 11.5px;
  color: var(--ink-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.train-stats {
  display: flex;
  align-items: baseline;
  gap: 14px;
  font-size: 11.5px;
  color: var(--ink-soft);
  position: relative;
  z-index: 1;
}
.train-stats b {
  font-family: var(--serif);
  font-size: 21px;
  color: var(--seal-dark);
  margin-right: 4px;
  font-variant-numeric: tabular-nums;
}
.train-stats .resolved b { color: var(--jade); font-size: 16px; }
.train-tags { display: flex; flex-wrap: wrap; gap: 5px; position: relative; z-index: 1; }
.train-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 11px;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.train-tag i { font-style: normal; color: var(--ink); }
.train-hint { margin: 0; font-size: 11.5px; color: var(--ink-faint); position: relative; z-index: 1; }
.train-foot { display: flex; align-items: center; gap: 10px; position: relative; z-index: 1; }
.train-foot .btn { flex: 1; }
.train-link {
  flex: 0 0 auto;
  border: 0;
  background: none;
  padding: 2px 0;
  font-size: 11.5px;
  color: var(--ink-faint);
  cursor: pointer;
}
.train-link:hover { color: var(--seal); }

.book-main { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.book-main b { font-family: var(--serif); font-size: 17px; }

/* 按学科分类的教材下拉菜单 */
.book-picker { position: relative; }
.bp-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 268px;
  max-width: 340px;
  padding: 7px 12px 7px 8px;
  border: 1px solid var(--line-strong);
  border-radius: 11px;
  background: #fff;
  text-align: left;
  color: var(--ink);
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}
.bp-trigger:hover { border-color: var(--gold); }
.book-picker.open .bp-trigger {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(193, 154, 60, 0.16);
}
.bp-seal {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--tone, var(--ink-soft));
  color: #fff;
  font-family: var(--serif);
  font-size: 14.5px;
  letter-spacing: 0;
  box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.14);
}
.bp-now { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1; }
.bp-now b {
  font-size: 13.5px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bp-now em {
  font-style: normal;
  font-size: 11.5px;
  color: var(--ink-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bp-caret {
  flex: 0 0 auto;
  font-size: 11px;
  color: var(--ink-faint);
  transition: transform 0.2s ease;
}
.book-picker.open .bp-caret { transform: rotate(180deg); }

.bp-panel {
  position: absolute;
  z-index: 70;
  top: calc(100% + 8px);
  left: 0;
  width: min(552px, calc(100vw - 48px));
  padding: 10px 12px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: var(--paper-2);
  box-shadow: var(--shadow-lg);
  display: none;
}
.book-picker.open .bp-panel { display: block; animation: bpIn 0.16s ease-out; }
@keyframes bpIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}
.bp-panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 2px 4px 9px;
  margin-bottom: 4px;
  border-bottom: 1px dashed var(--line);
}
.bp-panel-head b { font-family: var(--serif); font-size: 14px; letter-spacing: 0.04em; }
.bp-panel-head span { font-size: 11.5px; color: var(--ink-faint); white-space: nowrap; }
.bp-stages {
  display: flex;
  gap: 7px;
  padding: 9px 4px 5px;
}
.bp-stage {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  cursor: pointer;
  text-align: left;
  transition: border-color 0.16s ease, background 0.16s ease, box-shadow 0.16s ease;
}
.bp-stage b {
  font-family: var(--serif);
  font-size: 13.5px;
  letter-spacing: 0.08em;
  color: var(--ink);
}
.bp-stage em {
  font-style: normal;
  font-size: 11px;
  color: var(--ink-faint);
  white-space: nowrap;
}
.bp-stage:hover { border-color: var(--gold); }
.bp-stage.active {
  border-color: var(--seal);
  background: linear-gradient(180deg, #fffdf7, var(--gold-soft));
  box-shadow: 0 1px 0 rgba(140, 92, 30, 0.12);
}
.bp-stage.active b { color: var(--seal-dark); }
.bp-stage.active em { color: #8a6a2c; }
.bp-empty { margin: 10px 4px; font-size: 13px; color: var(--ink-faint); }
/* 年级筛选：学段内再细分，一次只看一个年级 */
.bp-grades {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 4px 4px 2px;
}
.bp-grade {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease;
}
.bp-grade b {
  font-family: var(--serif);
  font-size: 12.5px;
  letter-spacing: 0.05em;
  color: var(--ink);
}
.bp-grade em {
  font-style: normal;
  font-size: 10.5px;
  color: var(--ink-faint);
  white-space: nowrap;
}
.bp-grade:hover { border-color: var(--gold); }
.bp-grade.active {
  border-color: var(--seal);
  background: linear-gradient(180deg, #fffdf7, var(--gold-soft));
}
.bp-grade.active b { color: var(--seal-dark); }
.bp-grade.active em { color: #8a6a2c; }

/* 年级内的教材卡片：学科印章 + 册次信息，两列排布 */
.bp-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  align-content: start;
  max-height: min(50vh, 380px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px 2px 2px;
}
.bp-card {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  text-align: left;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}
.bp-card:hover { border-color: var(--gold); background: var(--gold-soft); }
.bp-card.active {
  border-color: var(--seal);
  background: var(--gold-soft);
  box-shadow: inset 0 0 0 1px var(--seal);
}
.bp-card-main {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}
.bp-card-main b {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bp-card-main em {
  font-style: normal;
  font-size: 11px;
  color: var(--ink-faint);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bp-card.active .bp-card-main b { color: var(--seal-dark); }

/* 同名同册多版本时的年份标识（如 2024 / 2026），只在确有版本冲突时出现 */
.bp-ver {
  display: inline-block;
  margin-left: 6px;
  padding: 0 5px;
  border: 1px solid var(--gold);
  border-radius: 5px;
  background: var(--gold-soft);
  color: #8a6a2c;
  font-size: 10px;
  font-style: normal;
  font-weight: 600;
  line-height: 14px;
  letter-spacing: 0.02em;
  vertical-align: 1px;
}
.bp-card.active .bp-ver { background: var(--gold); border-color: var(--gold); color: #fff; }
.bp-now .bp-ver { font-size: 10.5px; vertical-align: 1.5px; }
.bp-card.is-practiced .bp-card-main b::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--jade);
  margin-right: 5px;
  vertical-align: 2px;
}
.bp-tick { width: 12px; font-size: 11px; color: var(--jade); text-align: right; flex: 0 0 auto; }

.chip {
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: #fff;
  font-size: 13px;
  color: var(--ink-soft);
  transition: all 0.18s ease;
}
.chip:hover { border-color: var(--gold); }
.chip.active {
  background: var(--seal-soft);
  border-color: #e0aca2;
  color: var(--seal-dark);
  font-weight: 600;
}
.chip.ghost { opacity: 0.6; cursor: default; }

.practice-panel {
  margin-top: 16px;
  display: grid;
  grid-template-columns: 1.3fr 1.5fr 1.3fr auto;
  gap: 18px;
  align-items: center;
  padding: 16px 20px;
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fffdf6, #f8f2e1);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-md);
}
.practice-scope { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.practice-scope b {
  font-family: var(--serif);
  font-size: 16.5px;
  color: var(--ink);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.practice-field { display: flex; flex-direction: column; gap: 8px; }

.units { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.unit {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.unit-head {
  display: grid;
  grid-template-columns: 78px 1fr auto 22px;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 16px 20px;
  text-align: left;
  background: linear-gradient(180deg, #fffdf7, #faf4e6);
  transition: background 0.2s ease;
}
.unit-head:hover { background: var(--gold-soft); }
.unit-no {
  font-family: var(--serif);
  font-size: 13px;
  color: var(--seal-dark);
  border: 1px solid #e0c3a0;
  border-radius: 6px;
  text-align: center;
  padding: 3px 0;
  background: #fff;
}
.unit-head h3 { font-size: 19px; margin: 0; }
.unit-meta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  font-size: 12.5px;
  color: var(--ink-faint);
}
.unit-meta-top { white-space: nowrap; }
.unit-meta-bar { display: flex; align-items: center; gap: 8px; }
.unit-track {
  display: block;
  width: 78px;
  height: 5px;
  border-radius: 999px;
  background: #e9e0cd;
  overflow: hidden;
}
.unit-track i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #dcc08a, var(--gold));
  transition: width 0.3s ease;
}
.unit.is-practiced .unit-track i { background: linear-gradient(90deg, #8fb5a0, var(--jade)); }
.unit-meta-bar em {
  font-style: normal;
  font-size: 11.5px;
  color: var(--ink-faint);
  min-width: 32px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.unit-meta-bar em.on { color: var(--jade); font-weight: 600; }
.unit.is-practiced .unit-head { box-shadow: inset 3px 0 0 #b8d2c3; }
.unit-arrow { color: var(--ink-faint); font-size: 13px; transition: transform 0.2s ease; }
.unit.open .unit-arrow { transform: rotate(180deg); }
.unit-body { display: none; padding: 4px 12px 12px; border-top: 1px dashed var(--line); }
.unit.open .unit-body { display: block; }

.point-row {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border-radius: 10px;
  cursor: pointer;
  transition: background 0.16s ease, box-shadow 0.16s ease;
}
.point-row + .point-row { border-top: 1px dashed var(--line); }
.point-row:hover { background: #fffaf0; }
.point-row.selected { background: var(--seal-soft); box-shadow: inset 3px 0 0 var(--seal); }
.point-no { font-family: var(--serif); font-size: 13px; color: var(--ink-soft); text-align: right; }
.point-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.point-info b { font-size: 15.5px; font-weight: 600; }
.point-info span {
  font-size: 12.5px;
  color: var(--ink-faint);
  line-height: 1.55;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
}
.point-stats { display: flex; gap: 6px; }
.point-stats i {
  font-style: normal;
  font-size: 11.5px;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
}
.point-stats i.d1 { color: var(--jade); border-color: #cfe0d6; background: var(--jade-soft); }
.point-stats i.d2 { color: #8a6a20; border-color: #e6d5ac; background: var(--gold-soft); }
.point-stats i.d3 { color: var(--seal-dark); border-color: #e7c4bc; background: #fbece8; }

/* 练习足迹：知识点练习状态徽标 */
.pg-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  font-size: 11.5px;
  color: var(--ink-faint);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.pg-pill i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.85;
}
.pg-pill.is-new { border-style: dashed; }
.pg-pill.is-doing { color: #8a6a20; border-color: #e6d5ac; background: var(--gold-soft); }
.pg-pill.is-weak { color: var(--seal-dark); border-color: #e7c4bc; background: #fbece8; }
.pg-pill.is-done { color: var(--jade); border-color: #cfe0d6; background: var(--jade-soft); }
.pg-pill.is-mastered { color: #fff; border-color: var(--jade); background: var(--jade); }
.point-row.is-practiced .point-no { color: var(--jade); }
.point-row.is-practiced .point-info b { color: #2f3a33; }

/* 练习足迹：目录筛选标签 */
.section-head.split {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.progress-tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.progress-tab {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: #fff;
  font-size: 12.5px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all 0.16s ease;
}
.progress-tab i {
  font-style: normal;
  font-size: 11px;
  color: var(--ink-faint);
  background: var(--paper);
  border-radius: 999px;
  padding: 0 5px;
  min-width: 18px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.progress-tab:hover { border-color: var(--gold); color: var(--ink); }
.progress-tab.active {
  background: var(--seal-soft);
  border-color: #e0aca2;
  color: var(--seal-dark);
  font-weight: 600;
}
.progress-tab.active i { background: #fff; color: var(--seal-dark); }

.unit-foot { display: flex; justify-content: flex-end; gap: 10px; padding: 12px 6px 4px; flex-wrap: wrap; }

.mixed-entry {
  margin-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 16px 20px;
  border-radius: var(--radius);
  border: 1px dashed var(--line-strong);
  background: rgba(255, 253, 246, 0.7);
}
.mixed-entry > div { display: flex; flex-direction: column; gap: 4px; }
.mixed-entry b { font-family: var(--serif); font-size: 16px; }

@media (max-width: 960px) {
  .desk-top { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .train-card { gap: 8px; }
}
@media (max-width: 980px) {
  .practice-panel { grid-template-columns: 1fr 1fr; }
  .practice-scope { grid-column: 1 / -1; }
  .practice-panel .btn { grid-column: 1 / -1; }
  .practice-field .seg { flex-wrap: wrap; }
  .practice-field .seg button { flex: 1 1 auto; min-width: 0; }
}
@media (max-width: 720px) {
  .practice-panel { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .book-bar { padding: 12px 14px; flex-direction: column; align-items: stretch; gap: 10px; }
  .train-card { padding: 13px 14px; }
  .train-card::after { font-size: 56px; bottom: -18px; }
  .book-main { flex-direction: column; align-items: stretch; gap: 8px; }
  .book-main b { font-size: 16px; }
  .book-picker { width: 100%; }
  .book-bar > .chip.ghost { align-self: flex-start; }
  .bp-trigger { width: 100%; min-width: 0; max-width: none; }
  .bp-panel { width: 100%; left: 0; padding: 8px 10px 10px; }
  .bp-cards { grid-template-columns: 1fr; max-height: 52vh; }
  .practice-panel { padding: 14px; gap: 14px; }
  .unit-head { grid-template-columns: 64px minmax(0, 1fr) auto 18px; padding: 13px 14px; gap: 9px; }
  .unit-meta-top { display: none; }
  .unit-track { display: none; }
  .unit-meta-bar em { min-width: 0; font-size: 11px; }
  .unit-head h3 { font-size: 17px; }
  .point-row {
    grid-template-columns: 46px minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    gap: 6px 9px;
    padding: 11px 8px;
  }
  .point-row .point-no { grid-column: 1; grid-row: 1; }
  .point-row .point-info { grid-column: 2; grid-row: 1; }
  .point-row .pg-pill { grid-column: 2; grid-row: 2; justify-self: start; }
  .point-row > .btn { grid-column: 3; grid-row: 1 / span 2; }
  .point-stats { display: none; }
  .point-info span { -webkit-line-clamp: 2; }
  .progress-tabs { width: 100%; }
  .progress-tab { flex: 1 1 auto; justify-content: center; }
  .unit-foot { justify-content: stretch; }
  .unit-foot .btn { flex: 1; }
}

/* ============================================================
   答题激励：点赞动画 / 错题讲解
   ============================================================ */
.notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin: 0 0 22px;
  padding: 13px 18px;
  border-radius: 12px;
  border: 1px solid #e7d3a2;
  background: linear-gradient(90deg, #fbf3dd, #fffdf6);
  font-size: 13.5px;
  line-height: 1.7;
  color: #6d5417;
}
.notice-tag {
  flex: 0 0 auto;
  padding: 2px 9px;
  border-radius: 6px;
  background: var(--gold);
  color: #fff9ea;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
}
.notice p { margin: 0; white-space: pre-wrap; }

.streak { color: var(--seal); }

.check-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.check-row .hint { margin: 0; }

.option.correct { border-color: var(--jade); background: var(--jade-soft); box-shadow: 0 0 0 1px var(--jade) inset; }
.option.correct .key { background: var(--jade); color: #fff; }
.option.wrong { border-color: var(--seal); background: var(--seal-soft); }
.option.wrong .key { background: var(--seal); color: #fff; }
.option.muted { opacity: 0.62; }
.option[aria-disabled="true"] { cursor: default; }

.dots i.ok { background: var(--jade); }
.dots i.no { background: var(--seal); }

.q-feedback {
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #fffdf6;
  animation: rise 0.28s ease both;
  font-size: 13.5px;
  line-height: 1.8;
}
.q-feedback.ok { border-color: #cfe0d6; background: linear-gradient(180deg, #f1f8f3, #fbfefc); }
.q-feedback.half { border-color: #e7d3a2; background: linear-gradient(180deg, #fdf6e4, #fffdf6); }
.q-feedback.no { border-color: #e7c4bc; background: linear-gradient(180deg, #fdf0ed, #fffdf9); }
.qf-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.qf-head b { font-family: var(--serif); font-size: 16px; }
.qf-badge {
  font-size: 11.5px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
  background: var(--jade-soft);
  color: var(--jade);
}
.q-feedback.half .qf-badge { background: var(--gold-soft); color: #8a6a20; }
.q-feedback.no .qf-badge { background: var(--seal-soft); color: var(--seal-dark); }
.qf-gain { margin-left: auto; font-weight: 700; color: #8a6a20; font-variant-numeric: tabular-nums; }
.qf-gain.replay { color: var(--ink-faint); font-weight: 400; font-size: 12px; }
.qf-line, .qf-exp, .qf-point { display: flex; gap: 10px; margin-top: 8px; }
.qf-line span, .qf-exp span, .qf-point span {
  flex: 0 0 auto;
  color: var(--ink-faint);
  font-size: 12px;
  padding-top: 2px;
  letter-spacing: 0.04em;
}
.qf-line b { color: var(--ink); }
.qf-exp p, .qf-point p { margin: 0; color: var(--ink-soft); }
.qf-exp p { color: var(--ink); }

/* ---------------------------------------------------------- 全屏点赞 / 讲解卡 */
.cb-layer {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(35, 33, 28, 0.42);
  backdrop-filter: blur(4px);
  animation: cbFade 0.2s ease both;
}
.cb-card {
  width: min(452px, 100%);
  max-height: 93vh;
  overflow-y: auto;
  padding: 18px 24px 22px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-lg);
  text-align: center;
  animation: cbPop 0.42s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}
.cb-card.ok { border-color: #cfe0d6; }
.cb-card.no { border-color: #e7c4bc; }
.cb-card.half { border-color: #e7d3a2; }
.cb-stage {
  position: relative;
  height: 164px;
  display: grid;
  place-items: center;
  margin-bottom: 4px;
}
.cb-stage::before {
  content: "";
  position: absolute;
  width: 210px;
  height: 150px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(246, 236, 212, 0.95), rgba(255, 253, 246, 0));
}
.cb-card.no .cb-stage::before { background: radial-gradient(circle, rgba(247, 229, 224, 0.9), rgba(255, 253, 246, 0)); }
.cb-mascot { position: relative; width: 168px; height: 168px; overflow: visible; }
.cb-mascot .cb-ink { fill: none; stroke: #2f2a24; stroke-width: 4.4; stroke-linecap: round; }
.cb-mascot .cb-ink-soft { fill: none; stroke: #2f2a24; stroke-width: 3; stroke-linecap: round; opacity: 0.55; }
.cb-mascot .cb-ray { fill: none; stroke: var(--gold); stroke-width: 4; stroke-linecap: round; }
.cb-mascot .cb-body { transform-origin: 50% 92%; animation: cbBob 2.6s ease-in-out infinite; }
.cb-mascot.is-ok .cb-thumb { transform-origin: 58% 76%; animation: cbThumb 0.95s cubic-bezier(0.22, 1.4, 0.36, 1) both; }
.cb-mascot.is-no .cb-thumb { transform-origin: 62% 74%; animation: cbScratch 1.8s ease-in-out infinite; }
.cb-mascot .cb-bubble { transform-origin: 164px 66px; animation: cbBubble 1.6s ease-in-out infinite; }
.cb-like {
  position: absolute;
  left: 50%;
  bottom: 44%;
  padding: 3px 9px;
  border-radius: 999px;
  background: #fffdf6;
  border: 1px solid #e7c4bc;
  color: var(--seal);
  font-family: var(--serif);
  font-size: 12.5px;
  font-weight: 600;
  animation: cbFloat 1.9s ease-out both;
  animation-delay: calc(var(--i) * 0.1s);
  pointer-events: none;
}
.cb-card h2 { font-size: 22px; margin: 2px 0 8px; }
.cb-card.ok h2 { color: var(--jade); }
.cb-card.no h2 { color: var(--seal-dark); }
.cb-card.half h2 { color: #8a6a20; }
.cb-sub {
  margin: 0 0 14px;
  font-size: 13px;
  color: var(--ink-soft);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.cb-tip {
  margin: 0 0 16px;
  padding: 12px 14px;
  border-radius: 10px;
  background: #f6f2e6;
  border: 1px solid var(--line);
  text-align: left;
  font-size: 13px;
  line-height: 1.8;
  color: var(--ink-soft);
}
.cb-tip b { color: var(--ink); }
.cb-detail { text-align: left; margin-bottom: 16px; display: flex; flex-direction: column; gap: 10px; }
.cb-answer, .cb-exp, .cb-point {
  padding: 11px 14px;
  border-radius: 10px;
  background: #fffdf6;
  border: 1px solid var(--line);
  font-size: 13px;
  line-height: 1.8;
}
.cb-answer { background: #eef7f1; border-color: #cfe0d6; }
.cb-answer span, .cb-exp span, .cb-point span {
  display: block;
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  margin-bottom: 3px;
}
.cb-answer b { color: var(--jade); }
.cb-exp p, .cb-point p { margin: 0; color: var(--ink); }

/* 关键词命中明细：告诉孩子差在哪个要点 */
.kw-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border-radius: 10px;
  background: #fffdf6;
  border: 1px solid var(--line);
}
.kw-label {
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  margin-right: 2px;
}
.kw-chips i {
  font-style: normal;
  font-size: 12.5px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
}
.kw-chips i.hit { color: var(--jade); border-color: #cfe0d6; background: #eef7f1; }
.kw-chips i.miss { color: var(--seal-dark); border-color: #edd8cf; background: #fdf0eb; }

/* 后台：学生作答 + 一键接纳 */
.accept-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px dashed #e0cfa8;
  background: var(--gold-soft);
}
.accept-bar span {
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
}
.accept-bar b { font-size: 14px; color: var(--ink); }
.accept-bar button { margin-left: auto; }

/* ---------------------------------------------------------- 后台管理 */
.admin-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.admin-head h2 { font-size: 27px; }
.admin-head p { margin: 6px 0 0; }
.admin-flag {
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--seal-soft);
  border: 1px solid #e0aca2;
  color: var(--seal-dark);
  font-size: 12.5px;
  font-weight: 600;
}
.admin-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}
.admin-tabs button {
  padding: 10px 16px;
  border-radius: 9px 9px 0 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-soft);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}
.admin-tabs button:hover { color: var(--ink); background: #f1ead9; }
.admin-tabs button.active { color: var(--seal-dark); border-bottom-color: var(--seal); background: rgba(247, 229, 224, 0.6); }

.admin-body { display: flex; flex-direction: column; gap: 16px; }
.admin-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(158px, 1fr)); gap: 12px; }
.admin-card {
  padding: 16px 18px;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
}
.admin-card span { font-size: 12px; color: var(--ink-soft); letter-spacing: 0.04em; }
.admin-card b {
  display: block;
  font-family: var(--serif);
  font-size: 26px;
  margin: 6px 0 4px;
  font-variant-numeric: tabular-nums;
}
.admin-card em { font-style: normal; font-size: 11.5px; color: var(--ink-faint); }

.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.admin-panel {
  padding: 18px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
}
.admin-panel > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.admin-panel h3 { font-size: 17px; }
.admin-hint { margin: -4px 0 12px; line-height: 1.7; }
.link { color: var(--seal); font-size: 12.5px; cursor: pointer; font-weight: 600; }

.admin-chart { display: flex; align-items: flex-end; gap: 10px; height: 168px; padding: 6px 2px 0; }
.bar-col {
  flex: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 5px;
}
.bar-col i {
  width: 100%;
  max-width: 36px;
  min-height: 4px;
  border-radius: 6px 6px 3px 3px;
  background: linear-gradient(180deg, #d3ac4e, var(--seal));
  animation: barGrow 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
}
.bar-col .bar-value { font-size: 11px; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.bar-col b { font-size: 11px; font-weight: 500; color: var(--ink-faint); }

.subject-dist { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.dist-row { display: grid; grid-template-columns: 54px 1fr auto; gap: 10px; align-items: center; font-size: 12.5px; }
.dist-row b { font-weight: 600; }
.dist-row span { color: var(--ink-faint); font-size: 11.5px; }
.dist-bar { height: 8px; border-radius: 999px; background: #ece3cf; overflow: hidden; }
.dist-bar i { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #d3ac4e, var(--seal)); }

.admin-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.admin-table th {
  text-align: left;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
  padding: 9px 10px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.admin-table td { padding: 10px; border-bottom: 1px solid #f0e9d8; vertical-align: middle; }
.admin-table tbody tr:last-child td { border-bottom: none; }

/* 券类报表：小节标题与合计行 */
.coupon-table-title {
  margin: 20px 0 10px;
  font-size: 14px;
  color: var(--ink);
  letter-spacing: 0.04em;
}
.admin-table tfoot td {
  font-weight: 600;
  color: var(--ink);
  background: var(--gold-soft);
  border-top: 2px solid var(--gold);
  border-bottom: none;
}
.admin-panel .admin-cards { margin-bottom: 6px; }
.admin-table tbody tr:hover { background: #fffaf0; }
.admin-table.compact { font-size: 12.5px; }
.admin-table.compact td, .admin-table.compact th { padding: 8px; }
.admin-table .empty { text-align: center; color: var(--ink-faint); padding: 22px; }
.table-wrap { overflow-x: auto; }
.row-disabled { opacity: 0.62; }
.tag {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 8px;
  border-radius: 5px;
  font-size: 11px;
  font-weight: 600;
}
.tag-admin { background: var(--seal-soft); color: var(--seal-dark); }
.tag-ok { background: var(--jade-soft); color: var(--jade); }
.tag-off { background: #efe9d8; color: var(--ink-soft); }

.admin-search, .admin-filters { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; }
.admin-search input { min-width: 190px; }
.admin-filters { margin-bottom: 14px; }
.admin-filters label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--ink-soft); }
.admin-filters label.grow { flex: 1 1 200px; }

.admin-form { display: flex; flex-direction: column; gap: 12px; }
.admin-form label { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--ink-soft); }
.admin-form label.checkbox { flex-direction: row; align-items: center; gap: 8px; font-size: 13px; color: var(--ink); }
.admin-form .btn { align-self: flex-start; }

.admin-search input, .admin-filters input, .admin-filters select,
.admin-form input, .admin-form textarea, .admin-form select,
.modal-grid input, .modal-grid select {
  padding: 9px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fffefa;
  font-size: 13.5px;
  color: var(--ink);
  font-family: inherit;
}
.admin-search input:focus, .admin-filters input:focus, .admin-filters select:focus,
.admin-form input:focus, .admin-form textarea:focus, .admin-form select:focus,
.modal-grid input:focus, .modal-grid select:focus {
  outline: none;
  border-color: var(--seal);
  box-shadow: 0 0 0 3px rgba(178, 58, 46, 0.1);
}
.admin-form textarea { resize: vertical; line-height: 1.7; }

.pager { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 14px; }

.bank-stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  padding: 10px 12px;
  margin-bottom: 14px;
  border-radius: 9px;
  background: #f7f2e3;
  border: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.bank-list { display: flex; flex-direction: column; gap: 12px; }
.bank-item {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fffdf6;
}
.bank-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.bank-head .stars { margin-left: auto; }
.bank-stem { margin: 0 0 10px; font-family: var(--serif); font-size: 15.5px; line-height: 1.7; }
.bank-options { margin: 0 0 10px; padding-left: 4px; list-style: none; display: flex; flex-direction: column; gap: 4px; font-size: 13.5px; color: var(--ink-soft); }
.bank-options li { padding: 3px 8px; border-radius: 6px; }
.bank-options li.right { background: var(--jade-soft); color: var(--jade); font-weight: 600; }
.bank-answer { font-size: 13px; color: var(--ink-soft); }
.bank-answer b { color: var(--jade); }
.bank-exp { margin-top: 8px; font-size: 13px; color: var(--ink-soft); }
.bank-exp summary { cursor: pointer; color: var(--seal); font-size: 12.5px; }
.bank-exp p { margin: 8px 0 0; line-height: 1.8; }

/* ---------------------------------------------------------- 弹窗 */
.modal-layer {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(35, 33, 28, 0.45);
  backdrop-filter: blur(3px);
  animation: cbFade 0.2s ease both;
}
.modal-card {
  width: min(520px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  padding: 20px 22px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-lg);
  animation: cbPop 0.3s cubic-bezier(0.22, 1.2, 0.36, 1) both;
}
.modal-card.wide { width: min(760px, 100%); }
.modal-card header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.modal-card h3 { font-size: 18px; }
.modal-close { font-size: 22px; line-height: 1; color: var(--ink-faint); padding: 2px 8px; border-radius: 6px; }
.modal-close:hover { background: #f1ead9; color: var(--ink); }
.modal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 14px 0 18px; }
.modal-grid label { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--ink-soft); }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; }
.modal-danger {
  margin-top: 16px;
  width: 100%;
  padding: 9px;
  border-radius: 8px;
  border: 1px dashed #e0aca2;
  color: var(--seal-dark);
  font-size: 12.5px;
}
.modal-danger:hover { background: var(--seal-soft); }

.round-items { display: flex; flex-direction: column; gap: 8px; margin: 12px 0 16px; max-height: 52vh; overflow-y: auto; }
.round-item { padding: 10px 12px; border-radius: 9px; border: 1px solid var(--line); background: #fffdf6; }
.round-item.ok { border-color: #cfe0d6; background: #f5fbf7; }
.round-item.no { border-color: #e7c4bc; background: #fdf3f0; }
.round-q { display: flex; gap: 9px; font-size: 13px; line-height: 1.65; }
.round-q span {
  flex: 0 0 20px;
  height: 20px;
  border-radius: 5px;
  display: grid;
  place-items: center;
  background: #efe9d8;
  color: var(--ink-soft);
  font-size: 11px;
}
.round-q p { margin: 0; }
.round-meta { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 6px; align-items: center; }

.log-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 12.5px; }
.log-list li { display: flex; gap: 8px; flex-wrap: wrap; align-items: baseline; padding-bottom: 8px; border-bottom: 1px dashed var(--line); color: var(--ink-soft); }
.log-list li:last-child { border-bottom: none; padding-bottom: 0; }
.log-list li b { color: var(--ink); }
.log-list li span { color: var(--ink-soft); }
.log-list li em { margin-left: auto; font-style: normal; color: var(--ink-faint); font-size: 11.5px; }

.sound-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 16px; }

@keyframes cbFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes cbPop {
  0% { opacity: 0; transform: scale(0.86) translateY(18px); }
  60% { opacity: 1; transform: scale(1.02) translateY(0); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}
@keyframes cbBob {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-5px) rotate(-1.2deg); }
}
@keyframes cbSway {
  0%, 100% { transform: rotate(-2deg) translateY(0); }
  50% { transform: rotate(2deg) translateY(-3px); }
}
@keyframes cbThumb {
  0% { transform: rotate(-26deg) scale(0.86); }
  45% { transform: rotate(-26deg) scale(0.9); }
  70% { transform: rotate(10deg) scale(1.06); }
  100% { transform: rotate(0deg) scale(1); }
}
@keyframes cbScratch {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(-5deg); }
}
@keyframes cbBubble {
  0%, 100% { transform: translateY(0); opacity: 0.9; }
  50% { transform: translateY(-4px); opacity: 1; }
}
@keyframes cbFloat {
  0% { opacity: 0; transform: translate(-50%, 8px) scale(0.7); }
  25% { opacity: 1; }
  100% { opacity: 0; transform: translate(calc(-50% + var(--x)), -96px) scale(1.12); }
}
@keyframes barGrow { from { height: 0 !important; } }

/* ---------------------------------------------------------- 错题本 */
.wrong-toolbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.wrong-tabs { margin-bottom: 16px; border-bottom: 1px solid var(--line); }
.wrong-list { display: grid; gap: 14px; }
.wrong-card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px 18px;
  display: grid;
  gap: 10px;
}
.wrong-card.resolved { opacity: 0.82; background: #f4f1e4; }
.wrong-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.wrong-head .stars { margin-left: 2px; }
.wrong-count {
  font-size: 12px;
  font-weight: 700;
  color: var(--seal-dark);
  background: rgba(247, 229, 224, 0.75);
  border-radius: 999px;
  padding: 2px 10px;
}
.wrong-card .q-stem { font-size: 15px; line-height: 1.7; }
.wrong-detail {
  background: rgba(255, 255, 255, 0.65);
  border: 1px dashed var(--line);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13px;
  line-height: 1.8;
}
.wrong-detail p { margin: 2px 0; }
.wrong-actions { display: flex; gap: 10px; flex-wrap: wrap; }

@media (max-width: 980px) {
  .admin-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .admin-head h2 { font-size: 23px; }
  .modal-grid { grid-template-columns: 1fr; }
  .admin-table { font-size: 12px; }
  .cb-card { padding: 14px 18px 18px; }
  .cb-stage { height: 146px; }
  .cb-mascot { width: 148px; height: 148px; }
  .cb-card h2 { font-size: 19px; }
  .admin-filters label, .admin-filters label.grow { flex: 1 1 100%; }
  .admin-filters .btn { width: 100%; }
  .admin-search { width: 100%; }
  .admin-search input { flex: 1; min-width: 0; }
}

/* ============================================================
   形象系统（动漫小书童换装）
   ============================================================ */
.avatar-layout {
  display: grid;
  grid-template-columns: 350px 1fr;
  gap: 22px;
  align-items: start;
}

.avatar-side { padding: 18px; }

.avatar-stage {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
}

.avatar-stage .av-big { display: block; width: 100%; height: auto; }

.av-mini {
  max-width: 190px;
  margin: 0 auto 10px;
}

.base-picks {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 14px;
}

.av-glyph {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 2px rgba(255, 253, 246, 0.55);
  flex: none;
}

.item.av-locked { opacity: 0.66; }

.item.av-previewing {
  border-color: var(--seal);
  box-shadow: 0 0 0 1px var(--seal) inset;
}

.item-top[data-action] { cursor: pointer; }

.av-lv {
  color: var(--seal);
  font-weight: 600;
}

/* ---------- 收集进度 / 筛选 / 试穿 ---------- */
.av-collect {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-sm, 10px);
  background: var(--paper-2);
  border: 1px solid var(--line);
}

.av-collect .row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 12.5px;
  color: var(--ink-soft);
  margin-bottom: 8px;
}

.av-collect b { color: var(--ink); font-size: 15px; }

.av-bar {
  height: 7px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.av-bar i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--gold), var(--seal));
  transition: width 0.35s ease;
}

.av-bar.sm { height: 5px; }

.av-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 10px 0 16px;
}

.av-filter { display: flex; gap: 6px; }

.av-filter button {
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink-soft);
  font-size: 12.5px;
  padding: 5px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.av-filter button:hover { border-color: var(--gold); color: var(--ink); }

.av-filter button.active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.av-actions { display: flex; gap: 8px; }

.av-tabs button em {
  font-style: normal;
  font-size: 11px;
  margin-left: 6px;
  opacity: 0.62;
}

.av-tabs button.active em { opacity: 0.85; }

.av-progress {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 10px;
}

.av-progress .av-bar { flex: 1; }

.av-tryon {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-sm, 10px);
  border: 1px dashed var(--seal);
  background: rgba(178, 58, 46, 0.05);
  font-size: 12.5px;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.av-tryon b { color: var(--ink); }

.av-tryon-btns { display: flex; gap: 6px; }

@media (max-width: 980px) {
  .avatar-layout { grid-template-columns: 1fr; }
  .avatar-side { max-width: 380px; margin: 0 auto; width: 100%; }
  .av-toolbar { align-items: flex-start; flex-direction: column; }
}

/* ============================================================
   小游戏：五子棋 / 中国象棋
   ============================================================ */
.game-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 18px;
}
.game-card {
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  padding: 20px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: linear-gradient(165deg, #fffdf6 0%, #f8f1e0 100%);
  box-shadow: var(--shadow-sm);
  color: var(--ink);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.game-card:hover {
  transform: translateY(-2px);
  border-color: var(--gold);
  box-shadow: var(--shadow-md);
}
.game-icon {
  flex: none;
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--seal);
  color: #fff7ea;
  font-family: var(--serif);
  font-size: 24px;
  box-shadow: inset 0 -2px 0 rgba(0, 0, 0, 0.16);
}
.game-card:nth-child(2) .game-icon { background: var(--jade); }
.game-card-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.game-card-body b { font-family: var(--serif); font-size: 18px; letter-spacing: 0.05em; }
.game-card-desc { font-size: 13px; color: var(--ink); }
.game-card-detail { font-size: 11.5px; color: var(--ink-faint); line-height: 1.6; }
.game-go { flex: none; font-size: 12.5px; color: var(--seal); font-weight: 600; white-space: nowrap; }

/* 游戏时间兑换券 */
.gc-zone { margin-top: 22px; }
.gc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 620px) { .gc-grid { grid-template-columns: 1fr; } }
.gc-card {
  padding: 16px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
}
.gc-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.gc-icon {
  display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 11px;
  color: #fff; font-family: var(--serif); font-size: 20px;
  flex: none;
}
.gc-title { display: flex; flex-direction: column; gap: 2px; }
.gc-title b { font-family: var(--serif); font-size: 17px; letter-spacing: 0.03em; }
.gc-title span { font-size: 11.5px; color: var(--ink-faint); }
.gc-durations { display: flex; gap: 10px; }
.gc-dur {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 11px 8px; border-radius: 10px;
  border: 1px solid var(--line-strong); background: #fffdf7;
  cursor: pointer; transition: border-color .15s, background .15s;
}
.gc-dur:hover { border-color: var(--gold); }
.gc-dur.off { opacity: 0.55; cursor: not-allowed; }
.gc-dur-label { font-family: var(--serif); font-size: 16px; color: var(--ink); }
.gc-dur-cost { font-size: 12px; color: var(--seal); font-weight: 600; font-variant-numeric: tabular-nums; }
.gc-hint { margin-top: 12px; font-size: 11.5px; color: var(--ink-faint); }


.game-page { display: flex; flex-direction: column; gap: 14px; }
.game-head {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.game-title { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; }
.game-title b { font-family: var(--serif); font-size: 20px; letter-spacing: 0.04em; }
.game-title span { font-size: 12px; color: var(--ink-faint); }
.game-modes { margin-left: auto; }
.game-statusbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px 16px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow-sm);
}
.game-status { font-size: 14px; color: var(--ink); font-weight: 600; }
.game-status.think { color: var(--gold); }
.game-status.good { color: var(--jade); }
.game-status.bad { color: var(--seal); }
.game-status.warn { color: var(--seal-dark); }
.game-tools { display: flex; gap: 8px; }
.game-stage { display: flex; justify-content: center; }
.game-host { position: relative; width: 100%; max-width: 620px; }

.mg-board { position: relative; }
.mg-svg { display: block; width: 100%; height: auto; user-select: none; touch-action: manipulation; }
.mg-wood { fill: #f4e3bd; stroke: #cdb98c; stroke-width: 1.5; }
.mg-grid { stroke: #8a7a5c; stroke-width: 1.1; stroke-linecap: round; }
.mg-star { fill: #8a7a5c; }
.mg-mark { stroke: #a08d68; stroke-width: 1.2; }
.mg-river { fill: #9b8a67; font-family: var(--serif); font-size: 26px; letter-spacing: 10px; }
.mg-hit { fill: transparent; cursor: pointer; }
.mg-grid, .mg-star, .mg-mark, .mg-river, .mg-wood { pointer-events: none; }

.mg-gomoku .mg-stone.black circle { fill: #2c2923; stroke: #14120e; stroke-width: 1; }
.mg-gomoku .mg-stone.white circle { fill: #fdfaf1; stroke: #b9ac93; stroke-width: 1.4; }
.mg-last { fill: none; stroke: var(--seal); stroke-width: 2.4; }

.mg-piece circle { fill: #f9ecd0; stroke-width: 2; }
.mg-piece.red circle { stroke: var(--seal); }
.mg-piece.red text { fill: var(--seal-dark); }
.mg-piece.black circle { stroke: #55503f; }
.mg-piece.black text { fill: #35322b; }
.mg-piece text { font-family: var(--serif); font-size: 30px; font-weight: 700; pointer-events: none; }
.mg-select { fill: rgba(193, 154, 60, 0.28); stroke: none; }
.mg-dot { fill: rgba(178, 58, 46, 0.55); }
.mg-capture { fill: none; stroke: var(--seal); stroke-width: 2.6; stroke-dasharray: 5 4; }

.mg-overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(48, 38, 24, 0.42);
  border-radius: 10px;
  animation: bpIn 0.2s ease-out;
}
.mg-overlay-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 24px 34px;
  border-radius: 14px;
  background: var(--paper-2);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-lg);
  text-align: center;
}
.mg-overlay-title { font-family: var(--serif); font-size: 26px; letter-spacing: 0.08em; color: var(--ink); }
.mg-overlay.win .mg-overlay-title { color: var(--jade); }
.mg-overlay.lose .mg-overlay-title { color: var(--seal-dark); }
.mg-overlay-sub { font-size: 12.5px; color: var(--ink-soft); }

@media (max-width: 980px) {
  .game-cards { grid-template-columns: 1fr; }
  .game-modes { margin-left: 0; width: 100%; }
  .game-modes button { flex: 1 1 auto; }
}

/* ------------------------------------------------------------ 游戏时间 */
.game-timebar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 16px;
  padding: 14px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(150deg, #fdf8ec 0%, #f7efdb 100%);
  box-shadow: var(--shadow-sm);
}
.game-timebar.empty { border-color: var(--seal); background: linear-gradient(150deg, #fdf1ee 0%, #f9e4de 100%); }
.gt-left { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.gt-label { font-size: 12.5px; color: var(--ink-soft); letter-spacing: 0.08em; }
.gt-clock { font-family: var(--serif); font-size: 26px; color: var(--ink); letter-spacing: 0.06em; font-variant-numeric: tabular-nums; }
.game-timebar.empty .gt-clock { color: var(--seal-dark); }
.gt-coins { font-size: 12.5px; color: var(--gold); font-weight: 600; }
.game-gate {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  margin-top: 16px;
  padding: 28px 22px;
  border-radius: var(--radius);
  border: 1px dashed var(--line-strong);
  background: var(--paper-2);
}
.game-gate b { font-family: var(--serif); font-size: 19px; color: var(--ink); }
.game-gate span { font-size: 13px; color: var(--ink-soft); line-height: 1.7; max-width: 420px; }

/* ---------------------------------------------------------- 金圆券 */
.dot-coupon { background: linear-gradient(150deg, #d9b45c, #8f6a1e); }
.pill-coupon { cursor: pointer; font-family: inherit; }
.pill-coupon:hover { border-color: var(--gold); background: var(--gold-soft); }

.coupon-shell { display: flex; flex-direction: column; gap: 18px; }

.coupon-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 268px;
  gap: 18px;
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--line-strong);
  background: linear-gradient(150deg, #fffdf6 0%, #f7efdc 100%);
  box-shadow: var(--shadow-sm);
}
.ch-kicker { font-size: 12px; letter-spacing: 0.18em; color: var(--gold); }
.coupon-hero h2 { font-family: var(--serif); font-size: 26px; margin: 6px 0 8px; }
.ch-desc { font-size: 13px; line-height: 1.8; color: var(--ink-soft); margin: 0 0 16px; max-width: 540px; }
.ch-figures { display: flex; gap: 28px; flex-wrap: wrap; }
.ch-figure b {
  display: block;
  font-family: var(--serif);
  font-size: 28px;
  color: var(--seal-dark);
  font-variant-numeric: tabular-nums;
}
.ch-figure span { font-size: 12px; color: var(--ink-soft); }
.ch-figure.dim b { color: var(--ink-faint); }
.ch-code {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-left: 18px;
  border-left: 1px dashed var(--line-strong);
}
.chc-label { font-size: 12px; letter-spacing: 0.12em; color: var(--ink-soft); }
.chc-code {
  font-family: var(--serif);
  font-size: 26px;
  letter-spacing: 0.14em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.ch-code .btn { align-self: flex-start; }

.denom-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.denom-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent, var(--gold));
  background: var(--paper-2);
}
.dc-face { font-family: var(--serif); font-size: 24px; color: var(--accent, var(--gold)); min-width: 60px; }
.dc-meta b { display: block; font-size: 14px; }
.dc-meta span { font-size: 12px; color: var(--ink-soft); }

.denom-card.d1, .cp-row.d1, .rc-chip.d1 { --accent: #3f6b58; }
.denom-card.d5, .cp-row.d5, .rc-chip.d5 { --accent: #2f5f7a; }
.denom-card.d10, .cp-row.d10, .rc-chip.d10 { --accent: #8f2b21; }
.denom-card.d20, .cp-row.d20, .rc-chip.d20 { --accent: #7a5316; }

.section-head.coupon-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

.coupon-list { display: flex; flex-direction: column; gap: 10px; }
.cp-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--paper-2);
}
.cp-row.redeemed { opacity: 0.62; }
.cp-denom {
  min-width: 58px;
  font-family: var(--serif);
  font-size: 22px;
  color: var(--accent, var(--gold));
}
.cp-body { flex: 1; min-width: 0; }
.cp-code {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 13px;
  letter-spacing: 0.06em;
}
.cp-meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 3px;
  font-size: 12px;
  color: var(--ink-soft);
}
.cp-meta i, .cp-status i { font-style: normal; color: var(--ink-faint); }
.cp-status { font-size: 12px; color: var(--gold); text-align: right; white-space: nowrap; }
.cp-status i { display: block; }
.cp-row.redeemed .cp-status { color: var(--ink-faint); }

.cp-ticket {
  display: flex;
  width: 260px;
  overflow: hidden;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: #fffaf0;
  box-shadow: var(--shadow-sm);
}
.cp-ticket.big { width: 300px; margin: 0 auto; }
.cpt-side {
  writing-mode: vertical-rl;
  text-orientation: upright;
  padding: 10px 6px;
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 0.3em;
  color: #fff8ea;
  background: linear-gradient(160deg, #b98a2f, #8a5f14);
}
.cpt-face {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 12px 16px;
  border-left: 1px dashed var(--line-strong);
}
.cpt-face b { font-family: var(--serif); font-size: 30px; color: #8f2b21; }
.cpt-face span {
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 11.5px;
  letter-spacing: 0.06em;
  color: var(--ink-faint);
}

.qf-coupon {
  margin-left: 8px;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid #e3cd97;
  background: var(--gold-soft);
  color: #7a5316;
  font-size: 12px;
  font-weight: 600;
}
.cb-coupon {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin: 4px 0 12px;
  animation: pop 0.35s ease both;
}
.cb-coupon p { margin: 0; font-size: 12.5px; font-weight: 600; color: var(--gold); }

.result-coupon {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px dashed #dcc48a;
  background: var(--gold-soft);
}
.rc-head { font-size: 13px; font-weight: 600; color: #7a5316; }
.rc-strip { display: flex; gap: 8px; flex-wrap: wrap; }
.rc-chip {
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid var(--accent, var(--gold));
  background: #fffaf0;
  color: var(--accent, var(--gold));
  font-family: var(--serif);
  font-size: 14px;
}
.coupon-tip { margin: 4px 0 0; font-size: 12px; color: var(--ink-faint); }

@media (max-width: 900px) {
  .coupon-hero { grid-template-columns: 1fr; }
  .ch-code { padding-left: 0; padding-top: 14px; border-left: none; border-top: 1px dashed var(--line-strong); }
}
@media (max-width: 720px) {
  .denom-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .coupon-hero { padding: 18px; }
  .cp-row { flex-wrap: wrap; gap: 8px; }
  .cp-status { text-align: left; }
}

/* ---------------------------------------------------------------- 题目反馈 */
.q-report-btn {
  margin-left: 10px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px dashed var(--line-strong);
  background: transparent;
  color: var(--ink-faint);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.q-report-btn:hover { color: var(--seal-dark); border-color: var(--seal); background: var(--seal-soft); }
.q-meta .stars { margin-left: auto; }

.report-modal { width: min(560px, 100%); }
.report-reasons { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 16px; }
.report-chip {
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--paper-2);
  color: var(--ink-soft);
  font-size: 13px;
  cursor: pointer;
}
.report-chip:hover { border-color: var(--seal); color: var(--seal-dark); }
.report-chip.active { background: var(--seal); border-color: var(--seal); color: #fff; }
.report-note { display: flex; flex-direction: column; gap: 6px; font-size: 12.5px; color: var(--ink-soft); }
.rv-context {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 14px 0 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--paper-2);
  border: 0.5px solid var(--line);
}
.rv-row { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; line-height: 1.6; }
.rv-label {
  flex: 0 0 auto;
  min-width: 62px;
  color: var(--ink-soft);
  font-size: 12px;
  padding-top: 1px;
}
.rv-val { color: var(--ink); flex: 1; word-break: break-word; }
.rv-val.rv-answer {
  color: var(--seal-dark);
  font-weight: 600;
  background: #fff;
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
}
.report-note textarea, .report-field textarea, .report-field input, .report-field select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: #fff;
  font-family: inherit;
  font-size: 14px;
  color: var(--ink);
  resize: vertical;
}
.report-note textarea:focus, .report-field textarea:focus, .report-field input:focus, .report-field select:focus {
  outline: none;
  border-color: var(--seal);
  box-shadow: 0 0 0 3px var(--seal-soft);
}
.report-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; font-size: 12.5px; color: var(--ink-soft); }
.report-options { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.report-option { display: flex; align-items: center; gap: 8px; }
.report-option .key {
  width: 22px; height: 22px; flex: 0 0 22px;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: 6px; background: #efe9d8; color: var(--ink-soft);
  font-size: 12px; font-weight: 600;
}
.report-answer { display: flex; flex-direction: column; gap: 8px; }
.report-answer-item { display: flex; align-items: flex-start; gap: 8px; font-size: 13.5px; color: var(--ink); }
.report-answer-item input { width: auto; margin-top: 3px; }
.admin-subtabs { display: flex; gap: 6px; flex-wrap: wrap; margin: 12px 0 4px; }
.admin-subtabs button {
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: var(--paper-2);
  font-size: 13px;
  color: var(--ink-soft);
  cursor: pointer;
}
.admin-subtabs button.active { background: var(--seal); border-color: var(--seal); color: #fff; }
.admin-subtabs button i {
  margin-left: 6px; font-style: normal; font-size: 11px;
  background: rgba(255, 255, 255, 0.25); padding: 1px 6px; border-radius: 999px;
}
.admin-subtabs button:not(.active) i { background: var(--seal-soft); color: var(--seal-dark); }
.report-stem { max-width: 340px; font-size: 13px; line-height: 1.5; }
.report-actions { white-space: nowrap; }
@media (max-width: 720px) {
  .report-stem { max-width: none; }
  .report-modal { width: 100%; }
}

/* ------------------------------------------------------------ 英语听说 */
.listen-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}
.listen-head h2 { margin: 0 0 4px; font-family: var(--serif); font-size: 22px; letter-spacing: 0.04em; }
.listen-summary { display: flex; gap: 8px; }
.listen-summary span {
  min-width: 78px;
  padding: 8px 12px;
  text-align: center;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.listen-summary b { display: block; font-size: 18px; color: var(--ink); font-variant-numeric: tabular-nums; }
.listen-summary em { font-style: normal; font-size: 11.5px; color: var(--ink-faint); }

/* 英语学园总览页：听说 + 单词 + 短片三栏进度卡片 */
.ep-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.ep-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
}
.ep-card-head h3 { margin: 0 0 4px; font-family: var(--serif); font-size: 20px; letter-spacing: 0.03em; }
.ep-card-head p { margin: 0; }
.ep-stats { display: flex; gap: 8px; }
.ep-stat {
  flex: 1;
  min-width: 0;
  padding: 10px 8px;
  text-align: center;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.ep-stat b { display: block; font-size: 20px; color: var(--ink); font-variant-numeric: tabular-nums; }
.ep-stat em { font-style: normal; font-size: 11.5px; color: var(--ink-faint); }
.ep-progress { display: flex; flex-direction: column; gap: 6px; }
.ep-bar { height: 6px; background: #eee5d2; border-radius: 6px; overflow: hidden; }
.ep-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), #d9b566); }
.ep-back { margin-top: 8px; }
@media (max-width: 1080px) {
  .ep-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .ep-grid { grid-template-columns: 1fr; }
}

.listen-tip {
  margin-bottom: 12px;
  padding: 10px 14px;
  font-size: 13px;
  color: var(--ink-soft);
  background: var(--gold-soft);
  border: 1px solid #e8d9b4;
  border-radius: 12px;
}
.listen-wrong { margin-bottom: 12px; }

/* 英语短片（视频）模块 */
.vv-copyright {
  margin-bottom: 16px;
  padding: 12px 16px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--ink-soft);
  background: var(--gold-soft);
  border: 1px solid #e8d9b4;
  border-radius: 12px;
}
.vv-copyright b {
  display: block;
  margin-bottom: 4px;
  font-size: 14px;
  color: var(--ink);
}
.vv-copyright p { margin: 0; }
.vv-sortbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.vv-sort {
  padding: 5px 14px;
  font-size: 13px;
  color: var(--ink-soft);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.vv-sort:hover { border-color: var(--gold); color: var(--ink); }
.vv-sort.active {
  color: #fff;
  background: var(--gold);
  border-color: var(--gold);
}
.vv-group { margin-bottom: 22px; }
.vv-group-head {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
.vv-group-head b {
  font-size: 16px;
  color: var(--ink);
  font-family: var(--serif);
}
.vv-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.vv-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  cursor: pointer;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.vv-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(60, 48, 30, 0.1);
}
.vv-cover {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 90px;
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: 0.06em;
  color: #fffdf6;
  background: linear-gradient(135deg, #3e6e5c, #6a8f6a);
}
.vv-body { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px 14px; }
.vv-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.vv-head b { font-size: 15px; color: var(--ink); }
.vv-badge {
  flex: 0 0 auto;
  padding: 2px 8px;
  font-size: 11px;
  color: var(--ink-soft);
  background: var(--gold-soft);
  border-radius: 999px;
}
.vv-badge.done { color: #fff; background: #4a8a6a; }
.vv-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.vv-player {
  margin-bottom: 12px;
  overflow: hidden;
  background: #000;
  border-radius: 14px;
}
.vv-video { display: block; width: 100%; max-height: 68vh; background: #000; }
@media (max-width: 1080px) {
  .vv-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .vv-grid { grid-template-columns: 1fr; }
}

/* 分册切换：学段一行、册一个胶囊，只在有多册时出现 */
.ds-bar {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin: 0 0 14px;
  padding: 10px 12px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.ds-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ds-stage {
  flex: 0 0 auto;
  min-width: 30px;
  font-size: 11.5px;
  letter-spacing: 0.1em;
  color: var(--ink-faint);
}
.ds-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 12px;
  font-family: inherit;
  font-size: 13px;
  line-height: 1.2;
  color: var(--ink-soft);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.ds-chip:hover { border-color: var(--gold); color: var(--ink); }
.ds-chip.active {
  background: var(--gold-soft);
  border-color: var(--gold);
  color: var(--seal-dark);
  font-weight: 600;
}
.ds-chip i {
  font-style: normal;
  font-size: 10.5px;
  padding: 1px 5px;
  border-radius: 999px;
  background: var(--jade-soft);
  color: var(--jade);
  font-variant-numeric: tabular-nums;
}
.ds-chip i.due { background: var(--seal-soft); color: var(--seal-dark); }
.ds-chip.active i { background: #fff; }
.ds-edition { font-style: normal; font-size: 10.5px; color: var(--ink-faint); }

.listen-units { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.listen-unit {
  padding: 14px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.listen-unit.started { border-color: #d8c9a6; }
.lu-head { display: flex; align-items: center; gap: 10px; }
.lu-no {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 8px;
  background: var(--seal-soft);
  color: var(--seal-dark);
  font-family: var(--serif);
  font-size: 14px;
  font-weight: 700;
}
.lu-title { min-width: 0; }
.lu-title b { display: block; font-size: 15px; }
.lu-title em { font-style: normal; font-size: 12px; color: var(--ink-faint); }
.lu-count { margin-left: auto; font-size: 12px; color: var(--ink-faint); white-space: nowrap; }
.lu-kinds { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.lu-kinds span {
  padding: 2px 7px;
  font-size: 11.5px;
  color: var(--ink-soft);
  background: #f3ecdc;
  border-radius: 6px;
}
.lu-bar { height: 4px; background: #eee5d2; border-radius: 4px; overflow: hidden; }
.lu-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), #d9b566); }
.lu-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 10px; }

/* 答题 */
.listen-drill { max-width: 720px; margin: 0 auto; }
.ls-top { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.ls-progress b { font-size: 20px; color: var(--seal-dark); }
.ls-progress span { font-size: 13px; color: var(--ink-faint); }
.ls-score { margin-left: auto; font-size: 12.5px; color: var(--ink-soft); }
.ls-bar { height: 4px; margin-bottom: 14px; background: #eee5d2; border-radius: 4px; overflow: hidden; }
.ls-bar i { display: block; height: 100%; background: var(--jade); transition: width 0.25s ease; }
.ls-card { padding: 18px; }
.ls-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 14px; }
.ls-play {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 16px;
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
  background: linear-gradient(180deg, #fffdf7, #f7f0df);
  color: var(--seal-dark);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.04em;
  transition: transform 0.12s ease, box-shadow 0.16s ease;
}
.ls-play:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.ls-play:active { transform: scale(0.99); }
.ls-rate-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.ls-rate-label { font-size: 11.5px; color: var(--ink-faint); letter-spacing: 0.08em; margin-right: 2px; }
.ls-rate {
  min-width: 46px;
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fffdf7;
  color: var(--ink-soft);
  font-size: 12.5px;
  font-variant-numeric: tabular-nums;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.ls-rate:hover { border-color: #d8c9a6; color: var(--seal-dark); }
.ls-rate.active {
  background: var(--seal-soft);
  border-color: var(--seal);
  color: var(--seal-dark);
  font-weight: 600;
}
.ls-play-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--seal);
  color: #fff;
  font-size: 13px;
}
.ls-stem { margin: 16px 0 12px; font-size: 15.5px; line-height: 1.7; color: var(--ink); }
.ls-feedback { margin-top: 16px; padding: 14px; border-radius: 12px; }
.ls-feedback.ok { background: var(--jade-soft); border: 1px solid #cfe0d6; }
.ls-feedback.bad { background: var(--seal-soft); border: 1px solid #ecd3cb; }
.ls-verdict { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.ls-verdict b { font-size: 15px; }
.ls-feedback.ok .ls-verdict b { color: var(--jade); }
.ls-feedback.bad .ls-verdict b { color: var(--seal-dark); }
.ls-replay { font-style: normal; font-size: 11.5px; color: var(--ink-faint); margin-left: auto; }
.ls-script {
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.72);
  border-radius: 10px;
  font-size: 14px;
  line-height: 1.8;
  color: var(--ink);
}
.ls-script p { margin: 0; }
.ls-answer { display: flex; align-items: baseline; gap: 8px; margin-top: 10px; font-size: 13.5px; }
.ls-answer span { color: var(--ink-faint); }
.ls-answer b { color: var(--jade); font-size: 15px; }
.ls-explain { margin: 10px 0 0; font-size: 13px; line-height: 1.7; color: var(--ink-soft); }
.ls-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 14px; }

/* 结算 */
.listen-result { max-width: 720px; margin: 0 auto; display: grid; gap: 12px; }
.ls-result-card { padding: 20px; text-align: center; }
.ls-result-score { margin: 6px 0 14px; }
.ls-result-score b { font-size: 42px; font-family: var(--serif); color: var(--seal-dark); }
.ls-result-score span { font-size: 16px; color: var(--ink-faint); }
.ls-result-score em { display: block; font-style: normal; font-size: 13px; color: var(--ink-soft); }
.ls-result-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.ls-result-grid div { padding: 10px; background: #f8f2e3; border-radius: 12px; }
.ls-result-grid b { display: block; font-size: 18px; color: var(--gold); }
.ls-result-grid span { font-size: 11.5px; color: var(--ink-faint); }
.ls-rows-head { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 16px 8px; }
.ls-rows { padding: 0 8px 10px; }
.ls-row { display: flex; align-items: center; gap: 8px; padding: 8px 8px; border-bottom: 1px dashed var(--line); font-size: 13px; }
.ls-row:last-child { border-bottom: 0; }
.ls-row-no { width: 18px; color: var(--ink-faint); font-variant-numeric: tabular-nums; }
.ls-row-stem { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-soft); }
.ls-row-mark { font-weight: 700; }
.ls-row.ok .ls-row-mark { color: var(--jade); }
.ls-row.bad .ls-row-mark { color: var(--seal); }

/* 单词记忆 */
.vs-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0 16px;
}
.vs-toolbar .muted { margin-left: auto; }
.vs-due { color: var(--seal) !important; }
.vs-tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 11px;
  letter-spacing: 0.04em;
}
.vs-tag.new { background: var(--jade-soft); color: var(--jade); }
.vs-tag.due { background: var(--seal-soft); color: var(--seal-dark); }
.vs-sentence {
  margin: 4px 0 8px;
  padding: 12px 14px;
  background: #faf5e7;
  border-left: 3px solid var(--gold);
  border-radius: 8px;
  font-size: 15.5px;
  line-height: 1.75;
  color: var(--ink);
}
.vs-hint { margin: 0 0 10px; font-size: 12.5px; color: var(--ink-faint); letter-spacing: 0.02em; }
.vs-word {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin: 2px 0 8px;
}
.vs-word b { font-size: 20px; font-family: var(--serif); color: var(--seal-dark); letter-spacing: 0.02em; }
.vs-pos { font-size: 12px; color: var(--ink-faint); font-style: italic; }
.vs-cn { font-size: 14px; color: var(--ink); }
.vs-speak {
  margin-left: 2px;
  width: 28px;
  height: 28px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fffdf7;
  font-size: 13px;
  line-height: 1;
  transition: border-color 0.15s ease, transform 0.12s ease;
}
.vs-speak:hover { border-color: var(--seal); transform: scale(1.05); }
.vs-example {
  margin: 0;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.7);
  border-radius: 10px;
  font-size: 13.5px;
  line-height: 1.75;
  color: var(--ink-soft);
}
.vs-example em { display: block; font-style: normal; font-size: 12.5px; color: var(--ink-faint); }
.vs-gain { margin: 8px 0 0; font-size: 12.5px; color: var(--gold); }
.ls-row-word { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ls-row-word b { color: var(--ink); }

@media (max-width: 720px) {
  .listen-units { grid-template-columns: 1fr; }
  .ds-bar { padding: 9px 10px; gap: 6px; }
  .ds-chip { padding: 4px 10px; font-size: 12.5px; }
  .listen-summary span { min-width: 64px; padding: 6px 8px; }
  .ls-card { padding: 14px; }
  .ls-actions { flex-direction: column-reverse; }
  .vs-toolbar { flex-direction: column; align-items: stretch; }
  .vs-toolbar .muted { margin-left: 0; }
  .ls-actions .btn { width: 100%; }
}

/* 备案页脚：固定底部一行小字，不挡内容 */
.site-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  gap: 10px;
  justify-content: center;
  align-items: center;
  padding: 6px 0 calc(6px + env(safe-area-inset-bottom));
  font-size: 11.5px;
  color: var(--ink-faint);
  pointer-events: none;
  z-index: 5;
}
.site-footer a {
  color: var(--ink-faint);
  pointer-events: auto;
  text-decoration: none;
}

/* 口语跟读（一期） */
.btn-danger {
  background: linear-gradient(135deg, #d9534f, #b23a2e);
  color: #fff;
  border-color: #b23a2e;
}
.rd-card .rd-text {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.5;
  margin: 14px 0 4px;
  word-break: break-word;
}
.rd-card .rd-word {
  font-size: 40px;
  letter-spacing: 1px;
}
.rd-card .rd-hint {
  color: var(--ink-soft, var(--ink));
  font-size: 15px;
  margin-bottom: 2px;
}
.rd-card .rd-sub {
  color: var(--ink-faint);
  font-size: 13px;
  margin-bottom: 6px;
}
.rd-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 14px 0 4px;
}
.rd-actions .btn { flex: 1; min-width: 140px; }
.rd-rec-on { animation: rd-pulse 1.2s ease-in-out infinite; }
@keyframes rd-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.72; }
}
.rd-playback {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 10px 0 4px;
  padding: 10px 12px;
  border: 1px dashed var(--line, #ddd);
  border-radius: 10px;
}
.rd-playback audio {
  width: 100%;
  max-width: 260px;
  height: 36px;
}
.rd-rate { margin-top: 10px; }
.rd-stars {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 8px;
}
.rd-star {
  min-width: 84px;
  padding: 10px 0;
  border-radius: 10px;
  border: 1.5px solid var(--line, #ddd);
  background: #fff;
  font-weight: 600;
  cursor: pointer;
}
.rd-star.active {
  background: var(--primary, #b23a2e);
  border-color: var(--primary, #b23a2e);
  color: #fff7ea;
}
.rd-tip { text-align: center; margin-top: 12px; }
