:root {
  --desk: #e4eaf2;
  --paper: #fcfdfe;
  --ink: #1c2b4b;
  --ink-soft: #52607d;
  --rule: #cddaee;
  --margin: #de4f4a;
  --hl: #f7e463;
  --ok: #2c8a66;
  --line: 1.75rem;
  --en: "Bitter", Georgia, serif;
  --zh: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  color-scheme: light;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--desk);
  color: var(--ink);
  font: 400 1rem/1.65 var(--zh);
  padding-bottom: calc(5.5rem + env(safe-area-inset-bottom));
}

button, input, textarea, select { font: inherit; color: inherit; }

button { cursor: pointer; }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }

[hidden] { display: none !important; }

.icon-svg { flex: none; vertical-align: -0.2em; }

.top {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  max-width: 36rem;
  margin: 0 auto;
  padding: 1rem 1.25rem 0;
}

.home-link { color: var(--ink-soft); font-size: 0.875rem; }

.top-title { font-weight: 700; font-size: 0.95rem; }

.install-btn {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  align-self: center;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: var(--paper);
  padding: 0.25rem 0.8rem;
  font-size: 0.85rem;
  font-weight: 700;
}

.install-sheet {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  background: rgba(28, 43, 75, 0.45);
  padding: 1rem 1rem calc(1rem + env(safe-area-inset-bottom));
}

.install-card {
  width: 100%;
  max-width: 26rem;
  max-height: calc(100vh - 2rem);
  overflow: auto;
  box-shadow: 0 18px 40px -18px rgba(28, 43, 75, 0.6);
}

.install-qr {
  display: block;
  margin: 0 auto;
  padding: 0.5rem;
  background: #fff;
  border: 1px solid var(--rule);
  border-radius: 8px;
}

@media (min-width: 40rem) {
  .install-sheet { align-items: center; }
}

.view {
  max-width: 36rem;
  margin: 0 auto;
  padding: 1rem 1.25rem 2rem;
}

h1, h2, h3 { line-height: 1.3; margin: 0; }

h1 { font-size: 1.75rem; font-weight: 700; }

h2 { font-size: 1.25rem; font-weight: 700; }

h3 { font-size: 1rem; font-weight: 700; }

p { margin: 0; }

.en { font-family: var(--en); }

.muted { color: var(--ink-soft); }

.small { font-size: 0.875rem; }

.stack > * + * { margin-top: 1rem; }

.stack-lg > * + * { margin-top: 1.75rem; }

/* Index card: title above the red rule, body text sits on the blue rules */
.index-card {
  position: relative;
  background: var(--paper);
  border-radius: 3px;
  box-shadow: 0 1px 0 rgba(28, 43, 75, 0.08), 0 10px 24px -14px rgba(28, 43, 75, 0.35);
  padding: 0.9rem 1.25rem 0.4rem;
}

.index-card .card-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 2.6rem;
  margin: 0 -1.25rem;
  padding: 0 1.25rem 0.55rem;
  border-bottom: 2px solid var(--margin);
}

.title-block { display: grid; gap: 0.2rem; min-width: 0; }

.index-card .card-body {
  margin-top: 0.6rem;
  padding-bottom: var(--line);
  line-height: var(--line);
  background-image: repeating-linear-gradient(to bottom, transparent 0 calc(var(--line) - 1px), var(--rule) calc(var(--line) - 1px) var(--line));
  background-position: 0 -0.3rem;
}

.index-card .card-body > * { line-height: var(--line); }

.plain {
  background: var(--paper);
  border-radius: 10px;
  padding: 1.1rem 1.25rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.9rem;
  padding: 0.6rem 1.3rem;
  border: 2px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-weight: 700;
}

.btn.ghost { background: transparent; color: var(--ink); }

.btn.small-btn { min-height: 2.3rem; padding: 0.3rem 0.9rem; font-size: 0.875rem; }

.btn.wide { width: 100%; }

.btn:disabled { opacity: 0.45; cursor: default; }

.link-btn {
  background: none;
  border: 0;
  padding: 0.25rem 0;
  color: var(--ink-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.row { display: flex; gap: 0.75rem; flex-wrap: wrap; align-items: center; }

.row.end { justify-content: flex-end; }

.row.split { justify-content: space-between; }

/* Intro */
.intro-hero { padding-top: 0.5rem; }

.intro-hero h1 { font-size: 2rem; }

.intro-word {
  font-family: var(--en);
  font-size: 2.6rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.intro-word .pos { font-weight: 400; font-style: italic; font-size: 1rem; color: var(--ink-soft); margin-left: 0.5rem; }

.intro-list { margin: 0; padding-left: 1.2rem; }

/* Quiz */
.quiz-meta { display: flex; justify-content: space-between; align-items: center; font-size: 0.875rem; color: var(--ink-soft); }

.progress {
  height: 4px;
  background: var(--rule);
  border-radius: 2px;
  overflow: hidden;
}

.progress > span { display: block; height: 100%; background: var(--margin); transition: width 0.25s ease; }

.q-kind { font-size: 0.875rem; color: var(--margin); font-weight: 700; }

.q-text { font-size: 1.2rem; font-weight: 700; line-height: var(--line); }

.q-text.en { font-weight: 600; }

.options { list-style: none; margin: 0; padding: 0; }

.options li + li { margin-top: 0.6rem; }

.option {
  width: 100%;
  text-align: left;
  background: var(--paper);
  border: 1.5px solid var(--rule);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  line-height: 1.5;
}

.option:hover { border-color: var(--ink-soft); }

.option .mark {
  background-image: linear-gradient(100deg, transparent 0.2em, var(--hl) 0.2em, var(--hl) calc(100% - 0.2em), transparent calc(100% - 0.2em));
  background-repeat: no-repeat;
  background-position: 0 62%;
  background-size: 0% 72%;
  transition: background-size 0.3s ease;
  padding: 0 0.15em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.option.picked { border-color: var(--ink); }

.option.picked .mark { background-size: 100% 72%; }

/* Result */
.result-name { font-size: 1.9rem; font-weight: 800; line-height: 1.2; }

.result-short { font-family: var(--en); font-style: italic; color: var(--ink-soft); }

.label-chip {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--margin);
}

.steps { margin: 0; padding-left: 1.3rem; }

.steps li + li { margin-top: 0.4rem; }

.bars { list-style: none; margin: 0; padding: 0; }

.bars li { display: grid; grid-template-columns: 6.5rem 1fr 2.6rem; gap: 0.6rem; align-items: center; font-size: 0.9rem; }

.bars li + li { margin-top: 0.5rem; }

.bar { height: 0.7rem; background: var(--rule); border-radius: 2px; overflow: hidden; }

.bar > span { display: block; height: 100%; background: var(--ink); }

.bars li.top .bar > span { background: var(--margin); }

.bars .pct { font-family: var(--en); text-align: right; }

.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }

.facts div { background: var(--paper); border-radius: 8px; padding: 0.7rem 0.8rem; }

.facts dt { font-size: 0.8rem; color: var(--ink-soft); }

.facts dd { margin: 0; font-weight: 700; }

.note {
  border-left: 3px solid var(--hl);
  padding: 0.2rem 0 0.2rem 0.9rem;
  font-size: 0.9rem;
  color: var(--ink-soft);
}

/* Today */
.today-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; }

.streak { display: inline-flex; align-items: center; gap: 0.35rem; font-weight: 700; color: var(--margin); }

.streak .num { font-family: var(--en); font-size: 1.5rem; }

.tasks { list-style: none; margin: 0; padding: 0; }

.task {
  display: grid;
  grid-template-columns: 2.4rem 1fr;
  gap: 0.75rem;
  align-items: start;
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--rule);
}

.task:last-child { border-bottom: 0; }

.check {
  width: 2.2rem;
  height: 2.2rem;
  border: 2px solid var(--ink);
  border-radius: 6px;
  background: var(--paper);
  display: grid;
  place-items: center;
  padding: 0;
}

.check svg { opacity: 0; }

.task.done .check { background: var(--ink); color: var(--paper); }

.task.done .check svg { opacity: 1; }

.task.done .task-title { text-decoration: line-through; text-decoration-color: var(--margin); color: var(--ink-soft); }

.task-title { font-weight: 500; line-height: 1.5; }

.task-meta { font-size: 0.82rem; color: var(--ink-soft); margin-top: 0.2rem; display: flex; gap: 0.8rem; flex-wrap: wrap; align-items: center; }

.task-meta .link-btn { font-size: 0.82rem; color: var(--ink); }

.phrase .en-big { font-family: var(--en); font-size: 1.35rem; font-weight: 600; line-height: var(--line); }

.daily-line .card-head { gap: 0.6rem; flex-wrap: wrap; }

.daily-line .hl { color: var(--margin); font-weight: 700; }

.daily-word { margin-top: 0.4rem; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0.2rem 0.45rem; font-size: 0.9rem; }

.daily-word .w { font-family: var(--en); font-weight: 700; }

.daily-word .pos { padding: 0 0.4rem; border: 1px solid var(--ink-soft); border-radius: 4px; font-size: 0.72rem; color: var(--ink-soft); }

.daily-actions { margin-top: 0.6rem; gap: 0.5rem; }

.placement select { min-height: 2.4rem; max-width: 100%; padding: 0.2rem 0.5rem; border: 1.5px solid var(--ink); border-radius: 6px; background: #fff; }

/* Flashcards */
.flash-wrap { perspective: 1200px; }

.flash {
  position: relative;
  width: 100%;
  min-height: 15.75rem;
  border: 0;
  padding: 0;
  background: none;
  text-align: left;
  transform-style: preserve-3d;
  transition: transform 0.45s cubic-bezier(.3,.7,.3,1);
}

.flash.flipped { transform: rotateY(180deg); }

.flash .face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  display: flex;
  flex-direction: column;
}

.flash .face .card-body { flex: 1; }

.flash .back { transform: rotateY(180deg); }

.flash .meta-row { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; }

.flash .word { font-family: var(--en); font-size: 2.2rem; font-weight: 800; line-height: 1.15; overflow-wrap: anywhere; }

.flash .zh { font-size: 1.2rem; font-weight: 700; }

.flash .ex { font-family: var(--en); font-style: italic; color: var(--ink-soft); }

.card-ex { display: grid; gap: 0.15rem; }

.card-ex .ex { font-family: var(--en); font-style: italic; color: var(--ink-soft); }

.flash .pos { display: inline-block; margin-right: 0.45rem; padding: 0 0.4rem; border: 1px solid var(--ink-soft); border-radius: 4px; font-size: 0.75rem; font-weight: 600; line-height: 1.5; vertical-align: 0.2em; color: var(--ink-soft); }

.flash .hint { font-size: 0.875rem; color: var(--ink-soft); }

.box-dots { display: inline-flex; gap: 4px; }

.box-dots i { width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid var(--ink-soft); }

.box-dots i.on { background: var(--ink); border-color: var(--ink); }

.rate { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }

.rate .btn { padding: 0.5rem; }

.rate .btn[data-rate="again"] { background: var(--paper); color: var(--margin); border-color: var(--margin); }

.rate .btn[data-rate="hard"] { background: var(--paper); color: var(--ink); }

.empty { text-align: center; padding: 2rem 1rem; }

.empty h2 { margin-bottom: 0.4rem; }

.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  border: 1.5px solid var(--rule);
  background: var(--paper);
  padding: 0;
}

/* Speak */
.sentence { font-family: var(--en); font-size: 1.4rem; font-weight: 600; line-height: var(--line); }

.compare { font-family: var(--en); line-height: var(--line); }

.compare .hit { background: linear-gradient(transparent 55%, rgba(44, 138, 102, 0.28) 55%); }

.compare .miss { color: var(--margin); text-decoration: underline wavy; text-underline-offset: 4px; }

.score { font-family: var(--en); font-size: 2rem; font-weight: 800; }

.seg { display: inline-flex; border: 1.5px solid var(--ink); border-radius: 999px; overflow: hidden; }

.seg button { border: 0; background: transparent; padding: 0.3rem 0.8rem; font-size: 0.85rem; }

.seg button.on { background: var(--ink); color: var(--paper); }

.btn.listening { background: var(--margin); border-color: var(--margin); }

/* Progress */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.5rem; }

.stats div { background: var(--paper); border-radius: 8px; padding: 0.75rem; }

.stats .n { font-family: var(--en); font-size: 1.6rem; font-weight: 800; line-height: 1.2; }

.stats .l { font-size: 0.8rem; color: var(--ink-soft); }

.heat { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }

.heat span { aspect-ratio: 1; border-radius: 4px; background: var(--paper); border: 1px solid var(--rule); }

.heat span.l1 { background: #c9d6ec; border-color: #c9d6ec; }

.heat span.l2 { background: #7d93bd; border-color: #7d93bd; }

.heat span.l3 { background: var(--ink); border-color: var(--ink); }

.heat span.today { outline: 2px solid var(--margin); outline-offset: 1px; }

.heat-legend { display: flex; justify-content: space-between; font-size: 0.78rem; color: var(--ink-soft); margin-top: 0.4rem; }

.form { display: grid; gap: 0.6rem; }

.form label { display: grid; gap: 0.25rem; font-size: 0.875rem; color: var(--ink-soft); }

.form input {
  border: 1.5px solid var(--rule);
  border-radius: 8px;
  background: var(--paper);
  padding: 0.6rem 0.75rem;
  color: var(--ink);
}

.form input:focus { border-color: var(--ink); outline: none; }

.deck-list { list-style: none; margin: 0; padding: 0; max-height: 18rem; overflow: auto; }

.deck-list li { display: flex; justify-content: space-between; gap: 0.75rem; align-items: center; padding: 0.5rem 0; border-bottom: 1px solid var(--rule); }

.deck-list .w { font-family: var(--en); font-weight: 600; }

/* Tabs */
.tabs {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  background: var(--paper);
  border-top: 1px solid var(--rule);
  padding-bottom: env(safe-area-inset-bottom);
  z-index: 10;
}

.tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  border: 0;
  background: none;
  padding: 0.55rem 0 0.6rem;
  font-size: 0.78rem;
  color: var(--ink-soft);
  border-top: 3px solid transparent;
}

.tab.on { color: var(--ink); font-weight: 700; border-top-color: var(--margin); }

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(5.5rem + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  background: var(--ink);
  color: var(--paper);
  padding: 0.6rem 1.1rem;
  border-radius: 999px;
  font-size: 0.9rem;
  z-index: 20;
  max-width: calc(100% - 2rem);
}

@media (min-width: 40rem) {
  .tabs { left: 50%; right: auto; width: 36rem; transform: translateX(-50%); border: 1px solid var(--rule); border-bottom: 0; border-radius: 12px 12px 0 0; }
}

/* ---------- v2: review, practice, progress ---------- */
.num { font-family: var(--en); font-weight: 800; }

.row.center { justify-content: center; }

.title-block.wide { width: 100%; }

.progress.thick { height: 8px; border-radius: 4px; }

.goal-bar { display: grid; gap: 0.35rem; }

.cta-card {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  background: var(--ink); color: var(--paper);
  border-radius: 10px;
  padding: 1rem 1.1rem;
}

.cta-card .btn { background: var(--paper); color: var(--ink); border-color: var(--paper); flex: none; }

.cta-card .btn.ghost { background: transparent; color: var(--paper); }

.cta-card.done { background: var(--paper); color: var(--ink); }

.cta-card.done .btn.ghost { color: var(--ink); border-color: var(--ink); }

.cta-title { font-weight: 700; font-size: 1.05rem; }

.cta-meta { display: flex; flex-wrap: wrap; gap: 0.9rem; font-size: 0.88rem; opacity: 0.92; margin-top: 0.15rem; }

.cta-meta .num { font-size: 1.15rem; }

.quick { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.5rem; }

.quick-btn {
  display: grid; justify-items: center; gap: 0.3rem;
  padding: 0.75rem 0.25rem;
  background: var(--paper); color: var(--ink);
  border: 1.5px solid var(--rule); border-radius: 10px;
  font-size: 0.8rem; text-align: center; text-decoration: none;
}

.chip { font-size: 0.72rem; font-weight: 700; padding: 0.05rem 0.5rem; border-radius: 999px; border: 1.5px solid var(--ink-soft); color: var(--ink-soft); }

.chip.new { border-color: var(--margin); color: var(--margin); }

.chip.learn { border-color: #c48a00; color: #8a6100; }

kbd { font: 600 0.7rem/1 var(--zh); opacity: 0.55; margin-left: 0.4rem; }

.rate4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.4rem; }

.rate-btn {
  display: grid; justify-items: center; gap: 0.05rem;
  padding: 0.55rem 0.2rem 0.45rem;
  border: 2px solid var(--ink); border-radius: 12px;
  background: var(--paper); color: var(--ink);
  font-weight: 700;
}

.rate-btn small { font-weight: 400; font-size: 0.72rem; color: var(--ink-soft); }

.rate-btn kbd { margin: 0; }

.rate-btn.r-again { color: var(--margin); border-color: var(--margin); }

.rate-btn.r-good { background: var(--ink); color: var(--paper); }

.rate-btn.r-good small { color: var(--rule); }

.say-check { display: flex; align-items: center; gap: 0.7rem; flex-wrap: wrap; }

.say-result { display: inline-flex; align-items: center; gap: 0.25rem; font-size: 0.85rem; font-weight: 700; }

.say-result.ok { color: var(--ok); }

.say-result.bad { color: var(--margin); }

.inline-say { border: 0; background: none; padding: 0 0.3rem 0 0; color: var(--ink-soft); vertical-align: -0.1em; }

.flash .ex { pointer-events: none; }

.flash .ex .inline-say { pointer-events: auto; }

.big-num { font: 800 3rem/1 var(--en); }

.state-bar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; background: var(--rule); }

.state-bar span { display: block; }

.s-new { background: #c9d6ec; }

.s-learn { background: #7d93bd; }

.s-mature { background: var(--ink); }

.legend { display: flex; flex-wrap: wrap; gap: 1rem; color: var(--ink-soft); }

.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 0.3rem; vertical-align: -1px; }

.decks { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem; }

.deck {
  display: flex; align-items: center; justify-content: space-between; gap: 0.8rem;
  background: var(--paper);
  border-radius: 10px;
  border-left: 4px solid var(--rule);
  padding: 0.75rem 0.9rem;
}

.deck.on { border-left-color: var(--margin); }

.deck-name { font-weight: 700; }

.deck-progress { display: flex; align-items: center; gap: 0.5rem; margin-top: 0.3rem; }

.deck-progress .bar { width: 7rem; height: 6px; background: var(--rule); border-radius: 3px; overflow: hidden; display: block; }

.deck-progress .bar span { display: block; height: 100%; background: var(--ink); }

.seg.wide-seg { display: flex; width: 100%; }

.seg.wide-seg button { flex: 1; }

.search, .type-input, .settings select {
  width: 100%;
  border: 1.5px solid var(--rule);
  border-radius: 8px;
  background: var(--paper);
  padding: 0.6rem 0.75rem;
  color: var(--ink);
}

.search:focus, .type-input:focus { border-color: var(--ink); outline: none; }

.type-input { font-size: 1.2rem; resize: vertical; }

.deck-list li { gap: 0.5rem; }

.deck-list .w-main { flex: 1; min-width: 0; }

.deck-list .w-due { flex: none; }

.icon-btn.small { width: 2rem; height: 2rem; flex: none; }

.icon-gap { width: 2rem; flex: none; }

.icon-btn.listening { background: var(--margin); border-color: var(--margin); color: var(--paper); }

.modes { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem; }

.mode-btn {
  width: 100%;
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 0.85rem;
  background: var(--paper); color: var(--ink);
  border: 1.5px solid var(--rule); border-radius: 10px;
  padding: 0.8rem 0.95rem;
  text-align: left;
}

.mode-btn > span { display: grid; gap: 0.05rem; }

.mode-name { font-weight: 700; }

.promo { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 0.85rem; color: var(--ink); text-decoration: none; }

.promo > span { display: grid; gap: 0.1rem; }

.promo-seal {
  width: 2.6rem; height: 2.6rem; border-radius: 50%;
  display: grid; place-items: center;
  border: 2px solid #d23b4a; color: #d23b4a;
  font: 900 1.2rem/1 "Noto Serif TC", serif;
  transform: rotate(-8deg);
}

.q-box {
  background: var(--paper);
  border-radius: 10px;
  padding: 1.2rem 1.1rem;
  display: grid; justify-items: center; gap: 0.6rem;
  text-align: center;
  border-top: 3px solid var(--margin);
}

.q-label { color: var(--ink-soft); font-size: 0.9rem; }

.q-word { font: 800 2.2rem/1.15 var(--en); overflow-wrap: anywhere; }

.q-sentence { font: 600 1.25rem/1.55 var(--en); }

.play-big {
  width: 4.2rem; height: 4.2rem; border-radius: 50%;
  border: 0; background: var(--ink); color: var(--paper);
  display: grid; place-items: center;
}

.option { display: flex; align-items: center; gap: 0.75rem; }

.option .opt-key { flex: none; width: 1.6rem; height: 1.6rem; border-radius: 50%; border: 1.5px solid var(--ink-soft); display: grid; place-items: center; font-size: 0.75rem; color: var(--ink-soft); }

.option.right { border-color: var(--ok); background: #e3f3ec; }

.option.right .opt-key { background: var(--ok); border-color: var(--ok); color: #fff; }

.option.wrong { border-color: var(--margin); background: #fbe7e6; }

.option.wrong .opt-key { background: var(--margin); border-color: var(--margin); color: #fff; }

.option:disabled { cursor: default; color: var(--ink); }

.verdict { display: flex; align-items: center; gap: 0.5rem; font-weight: 700; font-size: 1.05rem; }

.verdict.ok { color: var(--ok); }

.verdict.bad { color: var(--margin); }

.answer-card .w.big { font: 800 1.4rem/1.2 var(--en); }

.answer-card .ex { font-style: italic; color: var(--ink-soft); }

.miss-list, .say-list { list-style: none; margin: 0; padding: 0; }

.miss-list li { display: flex; align-items: center; gap: 0.6rem; padding: 0.45rem 0; border-bottom: 1px solid var(--rule); }

.miss-list .w, .say-row .w { font-family: var(--en); font-weight: 600; }

.say-row { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; background: var(--paper); border-radius: 10px; padding: 0.7rem 0.9rem; }

.say-row + .say-row { margin-top: 0.5rem; }

.stats.four { grid-template-columns: repeat(2, 1fr); }

@media (min-width: 30rem) { .stats.four { grid-template-columns: repeat(4, 1fr); } }

.heat12 { display: grid; grid-auto-flow: column; grid-template-rows: repeat(7, 1fr); grid-template-columns: repeat(12, 1fr); gap: 4px; }

.heat12 span { aspect-ratio: 1; border-radius: 3px; background: var(--paper); border: 1px solid var(--rule); }

.heat12 span.l1, .heat-legend i.l1 { background: #c9d6ec; border-color: #c9d6ec; }

.heat12 span.l2, .heat-legend i.l2 { background: #7d93bd; border-color: #7d93bd; }

.heat12 span.l3, .heat-legend i.l3 { background: var(--ink); border-color: var(--ink); }

.heat12 span.future { background: transparent; border-style: dashed; }

.heat12 span.today { outline: 2px solid var(--margin); outline-offset: 1px; }

.heat-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin: 0 2px; vertical-align: -1px; }

.forecast { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(14, 1fr); gap: 4px; height: 7.5rem; align-items: end; }

.forecast li { display: grid; grid-template-rows: auto 1fr auto; height: 100%; text-align: center; }

.forecast .f-bar { align-self: end; background: var(--ink); border-radius: 3px 3px 0 0; min-height: 2px; width: 100%; }

.forecast li:first-child .f-bar { background: var(--margin); }

.forecast .f-n { font: 600 0.7rem/1.4 var(--en); color: var(--ink-soft); }

.forecast .f-d { font-size: 0.68rem; color: var(--ink-soft); padding-top: 3px; border-top: 1px solid var(--rule); }

.set-row { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; flex-wrap: wrap; }

.set-row > span:first-child { font-size: 0.92rem; }

.set-row input[type="range"] { flex: 1; min-width: 10rem; accent-color: var(--ink); }

.settings select { width: auto; max-width: 60%; padding: 0.4rem 0.6rem; }

.toggle { width: 1.3rem; height: 1.3rem; accent-color: var(--ink); }

.file-btn { cursor: pointer; }

.plain h2 .icon-svg { vertical-align: -0.15em; margin-right: 0.2rem; }

@media (max-width: 22.6rem) {
  .quick { grid-template-columns: repeat(2, 1fr); }
  .rate-btn kbd { display: none; }
  .tab { font-size: 0.72rem; }
}

@media (hover: none) {
  kbd { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
