/* ЕГЭ-Репетитор — «Тетрадь»: бумага, чернила, пометка красной ручкой (docs/architecture/ege_app.md). */
@font-face {
  font-family: "Literata";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("/ege/fonts/literata-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Literata";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("/ege/fonts/literata-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Onest";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/ege/fonts/onest-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Onest";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/ege/fonts/onest-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --paper: #f6f1e7;
  --paper-deep: #ece5d6;
  --paper-out: #e6dfd0;
  --rule: #d8cfbd;
  --rule-dashed: #bfb6a2;
  --ink: #1d2540;
  --ink-on: #f6f1e7;
  --text: #1d2540;
  --text-soft: #6b6656;
  --text-muted: #8a8472;
  --pen: #c8432e;
  --ok: #3f6b3a;
  --card: #ffffff;
  --shadow: 0 6px 24px rgba(29, 37, 64, 0.16);
  --serif: "Literata", Georgia, "Times New Roman", serif;
  --sans: "Onest", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  color-scheme: light;
}


* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
}

body {
  background: var(--paper);
  color: var(--text);
  font: 15px/1.45 var(--sans);
  -webkit-text-size-adjust: 100%;
  overflow: hidden;
}

button { font: inherit; color: inherit; }

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

.chat {
  display: flex;
  flex-direction: column;
  height: 100dvh;
  max-width: 760px;
  margin: 0 auto;
  background: var(--paper);
  position: relative;
}

/* Шапка: монограмма, имя, статус связи. position: relative — якорь для меню разминок. */
.chat__head {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px;
  border-bottom: 1.5px solid var(--ink);
  flex: none;
}

.chat__avatar {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  flex: none;
}

.chat__who { flex: 1; min-width: 0; }

.chat__name {
  margin: 0;
  font: 600 18px/1.2 var(--serif);
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chat__status {
  margin: 2px 0 0;
  font-size: 12px;
  color: var(--text-soft);
}

.chat__status::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--text-muted);
  vertical-align: 1px;
}

.chat__status--online::before { background: var(--ok); }

/* Кнопка разминок в шапке (справа) и выпадающее меню типов. */
.chat__warmup {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  border: 1.5px solid var(--ink);
  border-radius: 10px;
  background: var(--card);
  color: var(--ink);
  cursor: pointer;
}

.chat__warmup svg { fill: currentColor; }
.chat__warmup:hover { background: var(--paper-deep); }
.chat__warmup[aria-expanded="true"] { background: var(--ink); color: var(--ink-on); }

.warmup-menu[hidden] { display: none; }

.warmup-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 16px;
  z-index: 30;
  width: min(300px, calc(100vw - 32px));
  /* Без скролла на обычных экранах: 16 пунктов ≈ 440px; запас только на крошечных вьюпортах. */
  max-height: calc(100vh - 90px);
  overflow-y: auto;
  padding: 6px;
  border: 1.5px solid var(--ink);
  border-radius: 14px;
  background: var(--card);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.warmup-menu__item {
  padding: 6px 10px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  font: 13px/1.25 var(--sans);
  white-space: nowrap;
}

.warmup-menu__item:hover { background: var(--paper-deep); }

/* Меню «Задание ЕГЭ»: та же панель, но якорь у левой кнопки (справа от неё — разминки). */
.task-menu { right: 68px; }

.task-menu__section {
  padding: 8px 10px 3px;
  font: 600 11px/1.2 var(--sans);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.task-menu__section:first-child { padding-top: 4px; }

/* Лента. */
.chat__feed {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 16px 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* Реплика Репетитора — не пузырь, а запись в тетради. */
.msg--in {
  align-self: stretch;
}

.msg__meta {
  font-size: 12px;
  color: var(--text-muted);
}

.msg__meta b {
  color: var(--text);
  font-weight: 600;
}

.msg--in .msg__text {
  font: 400 16px/1.55 var(--serif);
  color: var(--text);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

/* Разбор ошибки в записи Репетитора: ~~wrong~~ → **right** — why. */
.correction {
  margin-top: 8px;
  padding: 8px 12px;
  border-left: 3px solid var(--pen);
  background: var(--paper-deep);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.correction__line {
  font: 400 15px/1.5 var(--serif);
  color: var(--text);
  overflow-wrap: anywhere;
}

.correction__line s {
  color: var(--pen);
  text-decoration-thickness: 1.5px;
}

.correction__line b {
  color: var(--ok);
  font-weight: 600;
}

/* Реплика ученика — пузырь справа. */
.msg--out {
  align-self: flex-end;
  max-width: min(82%, 520px);
  padding: 9px 14px;
  border-radius: 14px 14px 4px;
  background: var(--paper-out);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.msg--out .msg__meta {
  display: block;
  margin-top: 2px;
  text-align: right;
}

.msg--pending { opacity: 0.6; }

.msg--typing .msg__text {
  font: italic 400 15px/1.55 var(--serif);
  color: var(--text-soft);
}

.typing-dots span {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-left: 3px;
  border-radius: 50%;
  background: var(--text-soft);
  animation: typing 1.2s infinite ease-in-out;
}

.typing-dots span:nth-child(2) { animation-delay: 0.15s; }
.typing-dots span:nth-child(3) { animation-delay: 0.3s; }

@keyframes typing {
  0%, 60%, 100% { opacity: 0.3; }
  30% { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .typing-dots span { animation: none; opacity: 0.7; }
}

/* Быстрые темы под приветствием — как разлинованный список. */
.topics {
  margin: 4px 0 0 36px;
  padding: 0;
  list-style: none;
  border-top: 1.5px solid var(--ink);
}

.topics button {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  width: 100%;
  min-height: 44px;
  padding: 10px 2px;
  border: 0;
  border-bottom: 1px dashed var(--rule-dashed);
  background: none;
  text-align: left;
  cursor: pointer;
}

.topics button:hover { background: var(--paper-deep); }

.topics__kim {
  font-size: 12px;
  color: var(--text-soft);
  white-space: nowrap;
}

/* Ошибка с действием. */
.msg-error {
  margin-left: 36px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--pen);
  font-size: 14px;
}

.msg-error::before {
  content: "!";
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border: 1.5px solid var(--pen);
  border-radius: 50%;
  font-weight: 700;
  font-size: 12px;
}

.msg-error button {
  min-height: 36px;
  padding: 6px 14px;
  border: 1.5px solid var(--ink);
  border-radius: 30px;
  background: none;
  color: var(--ink);
  font-weight: 600;
  cursor: pointer;
}

/* Поле ввода: «Меню» + строка + отправка. */
.composer {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--rule);
  flex: none;
}

.composer__menu {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex: none;
  border: 0;
  border-radius: 50%;
  background: var(--ink);
  color: var(--ink-on);
  cursor: pointer;
}

.composer__menu svg { fill: currentColor; }
.composer__menu:hover { background: #2a3560; }

/* Голосовое сообщение: кнопка отправки = микрофон, когда поле пусто (как в Telegram). */
.composer__send svg { display: none; }
.composer__send[data-mode="send"] .icon-send { display: block; stroke: currentColor; }
.composer__send[data-mode="mic"] .icon-mic { display: block; fill: currentColor; }
.composer__send[data-mode="stop"] .icon-stop { display: block; fill: currentColor; }
.composer__send[data-mode="stop"] { background: var(--pen); animation: rec 1.2s infinite ease-in-out; }
.composer__timer {
  flex: none;
  align-self: center;
  min-width: 44px;
  text-align: center;
  font: 600 14px/1 var(--sans);
  font-variant-numeric: tabular-nums;
  color: var(--pen);
}

.composer__input {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  max-height: 160px;
  padding: 11px 16px;
  border: 1px solid transparent;
  border-radius: 22px;
  background: var(--paper-deep);
  color: var(--text);
  font: 15px/1.4 var(--sans);
  resize: none;
  outline: none;
  overflow-y: hidden;
}

.composer__input::placeholder { color: var(--text-muted); }
.composer__input:focus { border-color: var(--ink); }

.composer__send {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: none;
  border: 0;
  border-radius: 50%;
  background: var(--ink);
  color: var(--ink-on);
  cursor: pointer;
}

.composer__send .icon-send { stroke: currentColor; }

/* Меню-лист снизу. */
.sheet {
  position: relative;
  width: 100%;
  max-width: 760px;
  margin: auto auto 0;
  padding: 0 0 calc(12px + env(safe-area-inset-bottom));
  border: 0;
  border-radius: 20px 20px 0 0;
  background: var(--paper);
  color: var(--text);
  box-shadow: 0 -8px 32px rgba(29, 37, 64, 0.22);
}

.sheet::backdrop { background: rgba(19, 22, 31, 0.45); }

.sheet__close {
  position: absolute;
  top: 10px;
  right: 12px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: var(--paper-deep);
  color: var(--text);
  cursor: pointer;
}
.sheet__close svg { fill: currentColor; }
.sheet__close:hover { background: var(--paper-out); }

.sheet__grabber {
  width: 36px;
  height: 4px;
  margin: 8px auto 0;
  border-radius: 2px;
  background: var(--rule-dashed);
}

.sheet__title {
  margin: 14px 20px 0;
  font: 600 18px/1.3 var(--serif);
  color: var(--ink);
}

.sheet__lead {
  margin: 2px 20px 0;
  font-size: 13px;
  color: var(--text-soft);
}

.sheet__list {
  margin: 12px 12px 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.sheet__item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 56px;
  padding: 10px 12px;
  border: 1px solid var(--rule);
  border-radius: 14px;
  background: var(--card);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.sheet__item:hover { border-color: var(--ink); background: var(--paper-deep); }

.sheet__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 12px;
  background: var(--paper-deep);
  color: var(--ink);
}

.sheet__icon svg { fill: currentColor; }

.sheet__text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }

.sheet__name { font-weight: 600; font-size: 15px; }

.sheet__desc { font-size: 13px; color: var(--text-soft); }

.sheet__chevron { flex: none; fill: var(--text-muted); }

.sheet__danger {
  display: block;
  width: calc(100% - 40px);
  min-height: 44px;
  margin: 16px 20px 0;
  border: 1.5px solid var(--pen);
  border-radius: 30px;
  background: none;
  color: var(--pen);
  font-weight: 600;
  cursor: pointer;
}

/* Подтверждение. */
.confirm {
  max-width: min(360px, calc(100% - 32px));
  border: 0;
  border-radius: 16px;
  padding: 20px;
  background: var(--paper);
  color: var(--text);
  box-shadow: var(--shadow);
}

.confirm::backdrop { background: rgba(19, 22, 31, 0.45); }

.confirm__text {
  margin: 0 0 16px;
  font: 400 16px/1.5 var(--serif);
}

.confirm__actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.confirm__btn {
  min-height: 40px;
  padding: 8px 16px;
  border: 1.5px solid var(--ink);
  border-radius: 30px;
  background: none;
  color: var(--ink);
  font-weight: 600;
  cursor: pointer;
}

.confirm__btn--danger {
  border-color: var(--pen);
  color: var(--pen);
}

.chat__toast {
  position: absolute;
  left: 50%;
  bottom: 84px;
  transform: translateX(-50%);
  max-width: calc(100% - 32px);
  margin: 0;
  padding: 10px 16px;
  border-radius: 12px;
  background: var(--ink);
  color: var(--ink-on);
  font-size: 14px;
  text-align: center;
  box-shadow: var(--shadow);
}

/* ── Карточка задания КИМ: лист в тетради ── */
.tcard {
  padding: 14px 16px 16px;
  border: 1.5px solid var(--ink);
  border-radius: 4px;
  background: var(--card);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Тело карточки (материал + ответ): gap .tcard не доходит до вложенных элементов. */
.tcard__body { display: flex; flex-direction: column; gap: 12px; }

.tcard__head {
  display: flex;
  flex-wrap: nowrap;
  gap: 4px 10px;
  justify-content: space-between;
  align-items: baseline;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-soft);
}

/* Одна строка на любом экране: название не переносится, а обрезается многоточием. */
/* Метка «Разминка ЕГЭ» / «Задание ЕГЭ» — фиксированная ширина, без переноса «ЕГЭ». */
.tcard__tag { flex: none; white-space: nowrap; }

.tcard__kim {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--pen);
  font-weight: 600;
  letter-spacing: 0.04em;
}
.tcard__instr { margin: 0; font-size: 14px; color: var(--text-soft); }

.tpassage, .tletter, .tanswer {
  margin: 0;
  font: 400 16px/1.6 var(--serif);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.tletter, .tanswer {
  padding: 10px 12px;
  border-left: 3px solid var(--rule-dashed);
  background: var(--paper);
}

.tq { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 14px; }
.tq__text { margin: 0 0 8px; font: 400 16px/1.5 var(--serif); }
.topts { display: flex; flex-direction: column; gap: 6px; }

.topt {
  display: flex;
  gap: 10px;
  align-items: center;
  min-height: 44px;
  padding: 8px 12px;
  border: 1px solid var(--rule);
  border-radius: 10px;
  background: var(--paper);
  text-align: left;
  cursor: pointer;
}

.topt__n {
  flex: none;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border: 1px solid var(--rule-dashed);
  border-radius: 50%;
  font-size: 12px;
}

.topt--chosen { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.topt--chosen .topt__n { background: var(--ink); color: var(--ink-on); border-color: var(--ink); }
.topt--key { border-color: var(--ok); }
.topt:disabled { cursor: default; }

.tmark { display: inline-block; margin-top: 6px; font-size: 13px; font-weight: 600; }
.tmark--ok { color: var(--ok); }
.tmark--bad { color: var(--pen); }

.tmatch__options { margin: 0; padding-left: 22px; font: 400 15px/1.5 var(--serif); }
.tmatch { display: flex; flex-direction: column; gap: 10px; }
.tmatch__row { display: grid; grid-template-columns: 22px 1fr; gap: 4px 10px; padding-bottom: 10px; border-bottom: 1px dashed var(--rule-dashed); }
.tmatch__label { font: 600 16px/1.5 var(--serif); color: var(--pen); }
.tmatch__text { margin: 0; font: 400 15px/1.5 var(--serif); }
.tmatch__pick { grid-column: 2; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tmatch__key { font-size: 13px; color: var(--text-soft); }

.tselect, .tgap {
  min-height: 40px;
  padding: 6px 10px;
  border: 1px solid var(--rule-dashed);
  border-radius: 8px;
  background: var(--paper);
  color: var(--text);
  font: 15px var(--sans);
}

.tpassage--gaps { line-height: 2.4; }
.tgap { width: 8.5em; min-height: 34px; margin: 0 2px; border-width: 0 0 1.5px; border-radius: 0; background: transparent; }
.tgap:focus { outline: none; border-color: var(--pen); }
.tbase { font: 600 13px var(--sans); color: var(--text-soft); letter-spacing: 0.04em; }

.tresults { margin: 0; padding-left: 20px; font-size: 14px; }

.twrite {
  width: 100%;
  min-height: 180px;
  padding: 12px;
  border: 1px solid var(--rule-dashed);
  border-radius: 8px;
  background: var(--paper);
  color: var(--text);
  font: 400 16px/1.6 var(--serif);
  resize: vertical;
}

.tcount { margin: 0; font-size: 13px; color: var(--text-soft); text-align: right; }
.tcount--warn { color: var(--pen); }

.tref { margin: 0; font-size: 14px; color: var(--text-soft); }
.tref b { color: var(--pen); font-weight: 600; }

.ttable { width: 100%; border-collapse: collapse; font-size: 14px; }
.ttable th, .ttable td { padding: 6px 8px; border-bottom: 1px dashed var(--rule-dashed); text-align: left; }
.ttable th { border-bottom: 1.5px solid var(--ink); font-weight: 600; }

.tplayer { display: flex; align-items: center; gap: 12px; }
.tplayer__btn, .trec__btn {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex: none;
  border: 0;
  border-radius: 50%;
  background: var(--ink);
  color: var(--ink-on);
  font-size: 18px;
  cursor: pointer;
}
.trec__btn svg { fill: currentColor; }
.tplayer__btn:disabled { opacity: 0.35; cursor: default; }
.tplayer__label, .trec__info { font-size: 14px; color: var(--text-soft); }

.trec { display: flex; flex-direction: column; gap: 10px; }
.trec__row { display: flex; align-items: center; gap: 12px; }
.trec__btn--on { background: var(--pen); animation: rec 1.2s infinite ease-in-out; }
@keyframes rec { 50% { transform: scale(0.92); } }
@media (prefers-reduced-motion: reduce) { .trec__btn--on { animation: none; } }

.tmaterial { display: flex; flex-direction: column; gap: 10px; }
.tad { padding: 12px; border: 1.5px dashed var(--ink); text-align: center; }
.tad__title { margin: 0 0 6px; font: 600 18px var(--serif); }
.tad p { margin: 2px 0; }
.tpoints { margin: 0; padding-left: 22px; font-size: 15px; }
.tnote { margin: 0; font-size: 13px; color: var(--text-soft); }

.tphotos { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tphoto { margin: 0; }
.tphoto img { width: 100%; height: auto; border-radius: 4px; display: block; }
.tphoto figcaption { margin-top: 4px; font-size: 11px; color: var(--text-muted); }
.tphoto figcaption a { color: inherit; }
@media (max-width: 420px) { .tphotos { grid-template-columns: 1fr; } }

.tsubmit {
  align-self: flex-start;
  min-height: 44px;
  padding: 0 22px;
  border: 0;
  border-radius: 22px;
  background: var(--ink);
  color: var(--ink-on);
  font-weight: 600;
  cursor: pointer;
}
.tsubmit:disabled { opacity: 0.35; cursor: default; }

.tresult { border-top: 1.5px solid var(--ink); padding-top: 10px; }
.tresult--wait { margin: 0; color: var(--text-soft); font-style: italic; }
.tresult__score { margin: 0; font: 600 16px var(--serif); display: flex; align-items: center; gap: 8px; }
.tresult__icon { color: var(--pen); }
.tresult--ok .tresult__icon { color: var(--ok); }
.tcriteria { margin: 6px 0 0; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; color: var(--text-soft); }
.tcriteria b { color: var(--text); }

.tcard__error { display: flex; align-items: center; gap: 10px; color: var(--pen); font-size: 14px; }
.tcard__error button { min-height: 36px; padding: 6px 14px; border: 1.5px solid var(--ink); border-radius: 30px; background: none; color: var(--ink); font-weight: 600; cursor: pointer; }

/* Карточка плана на сегодня. */
.plan {
  padding: 14px 16px 12px;
  border: 1.5px solid var(--ink);
  border-radius: 4px;
  background: var(--card);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.plan__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-soft);
}
.plan__left { color: var(--pen); font-weight: 600; letter-spacing: 0.04em; text-transform: none; }

.plan__lead { margin: 0; font: 600 16px var(--serif); }

.plan__items { margin: 0; padding: 0; list-style: none; counter-reset: plan; border-top: 1.5px solid var(--ink); }

.plan__item button {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 44px;
  padding: 10px 2px;
  border: 0;
  border-bottom: 1px dashed var(--rule-dashed);
  background: none;
  color: var(--text);
  font: 15px var(--sans);
  text-align: left;
  cursor: pointer;
}
.plan__item button:hover { background: var(--paper-deep); }
.plan__item button::before {
  counter-increment: plan;
  content: counter(plan) ".";
  min-width: 18px;
  color: var(--text-muted);
}
.plan__title { flex: 1; }
.plan__count { color: var(--pen); font-weight: 600; }
.plan__item--done .plan__title { color: var(--text-soft); text-decoration: line-through; text-decoration-color: var(--rule-dashed); }

.plan__status { font-size: 12px; color: var(--text-soft); white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; }
.plan__status--done { color: var(--ok); font-weight: 600; }
.plan__status--done svg { fill: currentColor; }

.plan__hint { margin: 4px 0 0; font-size: 12px; color: var(--text-muted); }

/* Викторина слов: степпер (слово + 4 варианта), штрафное предложение, разбор серии. */
.wquiz { display: flex; flex-direction: column; gap: 12px; }
.wquiz__progress { margin: 0; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-soft); }
.wquiz__stage { display: flex; flex-direction: column; gap: 10px; }
.wquiz__word { margin: 0; font: 600 26px/1.2 var(--serif); color: var(--ink); }
.wquiz__q { margin: 0; font-size: 14px; color: var(--text-soft); }
.wquiz__note { margin: 0; font-size: 14px; color: var(--ok); }
.wquiz__note b { color: var(--ink); }
.wquiz__sentence { width: 100%; }
.wquiz__finish { align-self: flex-start; }

.wquiz__review { margin: 0; padding-left: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.wquiz__row { display: flex; gap: 10px; padding: 8px 10px; border: 1px solid var(--rule); border-radius: 10px; background: var(--paper); }
.wquiz__row--ok { border-color: var(--ok); }
.wquiz__row--bad { border-color: var(--pen); }
.wquiz__mark { flex: none; font-weight: 700; }
.wquiz__row--ok .wquiz__mark { color: var(--ok); }
.wquiz__row--bad .wquiz__mark { color: var(--pen); }
.wquiz__rowbody { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.wquiz__rowword { margin: 0; font: 600 16px/1.4 var(--serif); }
.wquiz__rowtrans { font: 400 14px/1.4 var(--sans); color: var(--text-soft); }
.wquiz__rowgiven { margin: 0; font-size: 13px; color: var(--pen); }
.wquiz__rowsent { margin: 0; font-size: 13px; color: var(--text); }
.wquiz__rowwhy { color: var(--pen); }
