/* Оформление сайтов «Ойла!»: из прототипов этапов (Oila! 1 этап.html, Oila! 2 этап.html), общее для главного сайта и обоих этапов. */
:root {
  --bg: #F6F5FC;
  --surface: #FFFFFF;
  --field: #F2F3FA;
  --ink: #1A1646;
  --muted: #5E5C7E;
  --line: #E1DFF0;
  --accent: #3A22E0;
  --accent-ink: #FFFFFF;
  --accent-soft: #ECEAFF;
  --dot: #9B3A9B;
  --grad: linear-gradient(90deg, #2F66E8 0%, #3A1FDC 55%, #8A2FA0 100%);
  --warn: #D2420C;
  --warn-soft: #FDE7DC;
  --ok: #12794A;
  --font-display: "Unbounded", "Onest", system-ui, sans-serif;
  --font-body: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0F0D28; --surface: #181548; --field: #121036; --ink: #EEEDFB; --muted: #A5A3C8; --line: #2C2A5C;
    --accent: #8B7CFF; --accent-ink: #0F0D28; --accent-soft: #25226A; --dot: #D07BD0;
    --warn: #FF8F60; --warn-soft: #3A2218; --ok: #4CC98A; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0F0D28; --surface: #181548; --field: #121036; --ink: #EEEDFB; --muted: #A5A3C8; --line: #2C2A5C;
  --accent: #8B7CFF; --accent-ink: #0F0D28; --accent-soft: #25226A; --dot: #D07BD0;
  --warn: #FF8F60; --warn-soft: #3A2218; --ok: #4CC98A; color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }   /* иначе a.btn { display: inline-flex } показывает скрытые ссылки */
body {
  background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.5;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 0 48px;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.wrap { max-width: 760px; margin: 0 auto; min-width: 0; }
.narrow { max-width: 560px; }

/* Top bar */
.top { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--bg); padding-block: 14px 10px; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--bg); }
.bar-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.brand { font-family: var(--font-display); font-weight: 600; font-size: 14px; letter-spacing: .02em; display: flex; align-items: center; gap: 10px; }
.brand small { font-family: var(--font-mono); font-weight: 500; font-size: 12px; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; }
.timer { font-family: var(--font-mono); font-weight: 700; font-size: 30px; line-height: 1; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.timer.warn { color: var(--warn); }
.track { height: 5px; background: var(--line); border-radius: 3px; overflow: hidden; margin-top: 10px; }
.track i { display: block; height: 100%; width: 100%; background: var(--accent); transform-origin: left; }
.track.warn i { background: var(--warn); }

/* Typography */
h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 5.2vw, 34px); line-height: 1.15; letter-spacing: -.01em; margin: 28px 0 10px; text-wrap: balance; }
h2 { font-family: var(--font-display); font-weight: 600; font-size: 19px; margin: 0 0 12px; text-wrap: balance; }
p { margin: 0 0 12px; }
.lead { color: var(--muted); font-size: 17px; max-width: 52ch; }
.mono { font-family: var(--font-mono); }
.eyebrow { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }

/* Panels & forms */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; }
.stack { display: grid; gap: 18px; }
.field { display: grid; gap: 6px; }
.field label, .field .lab { font-weight: 700; font-size: 14px; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 520px) { .row2 { grid-template-columns: 1fr; } }
input[type=text], input[type=tel], input[type=number], select {
  width: 100%; min-height: 46px; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line);
  background: var(--bg); color: var(--ink);
}
.hint { font-size: 13px; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 44px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--bg); font-weight: 600; }
.chip[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn { min-height: 48px; padding: 10px 22px; border-radius: 10px; border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); font-weight: 700; }
.btn:disabled { opacity: .4; cursor: not-allowed; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.small { min-height: 40px; padding: 6px 14px; font-size: 14px; }
.btn.danger { border-color: var(--warn); color: var(--warn); background: transparent; }
.btn.danger.armed { background: var(--warn); color: var(--surface); }
.actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.linklike { background: none; border: 0; padding: 4px 0; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; font-size: 14px; }

/* Rules list */
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0 0 20px; padding: 0; list-style: none; }
.facts li { border: 1px solid var(--line); border-radius: 12px; padding: 14px; background: var(--surface); }
.facts b { display: block; font-family: var(--font-mono); font-size: 26px; line-height: 1.1; }
.facts span { font-size: 13px; color: var(--muted); }
@media (max-width: 520px) { .facts { grid-template-columns: 1fr; } .facts li { display: flex; align-items: baseline; gap: 12px; } }
.rules { margin: 0 0 22px; padding-left: 20px; display: grid; gap: 8px; }

/* Question */
.qcard { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px; margin-top: 8px; }
.meta { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.tag { font-family: var(--font-mono); font-size: 12px; letter-spacing: .05em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; background: var(--accent-soft); color: var(--accent); font-weight: 700; }
.tag.lv { background: transparent; border: 1px solid var(--line); color: var(--muted); }
.qtext { font-size: clamp(19px, 3.6vw, 24px); font-weight: 700; line-height: 1.3; margin: 0 0 20px; text-wrap: pretty; }
.opts { display: grid; gap: 10px; }
.opt { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 56px; padding: 10px 14px; text-align: left; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); font-weight: 600; }
.opt .k { flex: none; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; font-family: var(--font-mono); font-size: 13px; font-weight: 700; border: 1px solid var(--line); background: var(--surface); color: var(--muted); }
.opt[aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); }
.opt[aria-pressed="true"] .k { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.nav { display: flex; justify-content: space-between; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.auto { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); margin-top: 14px; }
.auto input { width: 18px; height: 18px; accent-color: var(--accent); }

/* Number grid */
.map { display: flex; flex-wrap: wrap; gap: 18px 22px; margin-top: 22px; }
.grp { min-width: 0; }
.grp .eyebrow { margin-bottom: 8px; }
.cells { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 6px; }
.cell { width: 100%; height: 40px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface); font-family: var(--font-mono); font-weight: 700; font-size: 14px; display: grid; place-items: center; padding: 0; }
.cell.done { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.cell.cur { outline: 3px solid var(--accent); outline-offset: 2px; }
.legend { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 16px; font-size: 13px; color: var(--muted); }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 4px; vertical-align: -1px; margin-right: 6px; border: 1px solid var(--line); background: var(--surface); }
.legend i.d { background: var(--accent); border-color: var(--accent); }

/* Done */
.big { font-family: var(--font-mono); font-size: 40px; font-weight: 700; line-height: 1; }
.status { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); }
.status i { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.status.ok i { background: var(--ok); }
.status.bad i { background: var(--warn); }

/* Admin */
.tablebox { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
table { border-collapse: collapse; width: 100%; min-width: 680px; font-size: 14px; }
th, td { padding: 10px 10px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
th { white-space: normal; vertical-align: bottom; }
td.sv { white-space: normal; min-width: 150px; }
th { font-family: var(--font-mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
td.n, th.n { text-align: right; font-variant-numeric: tabular-nums; font-family: var(--font-mono); }
tr:last-child td { border-bottom: 0; }
tr.pass td { background: var(--accent-soft); }
.sub { color: var(--muted); font-size: 12px; }
.pill { font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line); }
.pill.y { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.kpis { display: flex; gap: 12px; flex-wrap: wrap; margin: 18px 0; }
.kpi { border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; background: var(--surface); min-width: 130px; }
.kpi b { display: block; font-family: var(--font-mono); font-size: 24px; }
.kpi span { font-size: 12px; color: var(--muted); }
.empty { padding: 28px; text-align: center; color: var(--muted); }
.rowbtn { background: none; border: 0; padding: 2px 0; text-align: left; display: grid; font-weight: 700; }
.rowbtn .sub { font-weight: 500; }
tr.drow td { white-space: normal; padding: 0; background: var(--bg); }
.dwrap { padding: 16px; max-width: 100vw; }
.dhead { display: flex; gap: 14px 28px; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; }
.dsum { display: flex; gap: 8px 28px; flex-wrap: wrap; }
.dsum .mono { font-size: 13px; }
.detail { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.dq { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); counter-increment: none; }
.dq::before { content: attr(value); flex: none; width: 28px; font-family: var(--font-mono); font-weight: 700; color: var(--muted); }
.dq .dbody { flex: 1; min-width: 0; }
.dtext { font-weight: 600; margin: 2px 0; white-space: normal; }
.dans { font-size: 14px; color: var(--muted); white-space: normal; }
.dans b { color: var(--ink); }
.dq.ok { border-left: 4px solid var(--ok); }
.dq.bad { border-left: 4px solid var(--warn); }
.dq.skip { border-left: 4px solid var(--muted); border-style: dashed; border-left-style: solid; }
.pill.v-ok { color: var(--ok); border-color: var(--ok); }
.pill.v-bad { color: var(--warn); border-color: var(--warn); }
.pill.v-skip { color: var(--muted); }
.dq .pill { flex: none; }
footer { margin-top: 36px; display: flex; gap: 18px; flex-wrap: wrap; }
/* Фирменный стиль Newton Kazakhstan: светлый лавандовый фон, широкий жирный гротеск, сине-фиолетовый градиент */
#app.wrap { max-width: none; }
.inner { margin: 0 auto; }
.inner.n, .wrap.narrow { max-width: 560px; }
.inner.t, .wrap.t { max-width: 880px; margin-left: auto; margin-right: auto; }
.inner.w, .wrap.wide { max-width: 1120px; margin-left: auto; margin-right: auto; }
.top.static { position: static; }
@media (min-width: 900px) {
  .cells { grid-template-columns: repeat(20, minmax(0, 1fr)); }
  .qcard { padding: 34px 36px; }
  .qtext { font-size: 26px; margin-bottom: 26px; }
  .opt { min-height: 62px; font-size: 17px; }
  .timer { font-size: 38px; }
  .hero { padding-top: 24px; }
  .hero .lead { font-size: 19px; }
}
@media (max-width: 520px) {
  .panel, .qcard { padding: 20px; border-radius: 22px; }
  .timer { font-size: 28px; }
  .wm { font-size: 14px; }
  .actions .btn { flex: 1 1 auto; }
  .nav .btn { flex: 1 1 0; }
}
.brand { gap: 12px; }
.logo { flex: none; }
.wm { font-family: var(--font-display); font-weight: 700; font-size: 15px; line-height: 1.02; letter-spacing: -.01em; }
.stage { font-weight: 700; font-size: 13px; padding: 8px 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); }
.kick { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 13px; letter-spacing: .09em; text-transform: uppercase; color: var(--accent); }
.kick::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--dot); }
h1 { font-weight: 700; letter-spacing: -.025em; line-height: 1.1; font-size: clamp(26px, 4.6vw, 44px); }
h2 { font-weight: 700; letter-spacing: -.01em; }
.hero h1 { font-size: clamp(30px, 5.4vw, 54px); margin-top: 18px; }
.gr { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 440px); gap: 48px; align-items: start; margin-top: 36px; }
@media (max-width: 900px) { .split { grid-template-columns: minmax(0, 1fr); gap: 28px; margin-top: 20px; } }
.pills { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.pillbox { padding: 10px 18px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); font-weight: 600; font-size: 15px; }
.panel { border-radius: 28px; padding: 28px; box-shadow: 0 24px 60px -34px rgba(40, 25, 140, .4); }
.qcard { border-radius: 26px; }
.nocopy, .nocopy * { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; }
@media print { .qcard { display: none !important; } }
input[type=text], input[type=tel], input[type=number], select { min-height: 54px; border-radius: 16px; background: var(--field); }
.btn { border: 0; background: var(--grad); color: #fff; border-radius: 18px; min-height: 54px; font-weight: 800; }
.btn.ghost { background: transparent; border: 1px solid var(--line); color: var(--ink); }
.btn.danger { border: 1px solid var(--warn); }
.btn.small { min-height: 42px; border-radius: 14px; }
.btn.block { width: 100%; }
.chip { background: var(--field); }
.seg { display: grid; grid-template-columns: 1fr 1fr; }
.seg .chip { border-radius: 16px; min-height: 52px; }
.chip[aria-pressed="true"] { background: var(--grad); border-color: transparent; color: #fff; }
.opt { border-radius: 16px; background: var(--field); }
.track i, .cell.done { background: var(--grad); }
.cell.done { border-color: transparent; color: #fff; }
.cell.miss { opacity: .45; text-decoration: line-through; }
.cell.cur { cursor: default; }
.track.warn i { background: var(--warn); }
.timer { color: var(--ink); }
.map { margin: 6px 0 12px; }
.map .cells { flex: 1 1 100%; min-width: 0; }
.legend { margin: 12px 0 14px; }
.facts li { border-radius: 18px; }
@media (prefers-reduced-motion: no-preference) { .track i { transition: transform .25s linear; } .opt, .cell { transition: background .12s, border-color .12s; } }

/* ---------- Дополнения для боевых сайтов ---------- */
a { color: var(--accent); }
a.btn { display: inline-flex; align-items: center; justify-content: center; text-align: center; text-decoration: none; }
.btn.ghost, a.btn.ghost { color: var(--ink); }
.logo { width: 40px; height: 40px; display: block; }
.brand a { display: flex; align-items: center; gap: 12px; color: inherit; text-decoration: none; }
.right { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.lang { display: inline-flex; padding: 3px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); }
.lang button { min-height: 34px; min-width: 44px; padding: 0 10px; border: 0; border-radius: 999px; background: transparent; font-weight: 700; font-size: 13px; color: var(--muted); }
.lang button[aria-pressed="true"] { background: var(--grad); color: #fff; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 20; background: var(--surface); padding: 8px 12px; border-radius: 10px; }
.err { color: var(--warn); font-size: 13px; font-weight: 600; margin: 0; }
[aria-invalid="true"] { border-color: var(--warn) !important; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.note { font-size: 13px; color: var(--muted); margin: 0; }
.spin { display: inline-block; width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; vertical-align: -3px; margin-right: 8px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
#toasts { position: fixed; left: 50%; bottom: max(20px, env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); display: grid; gap: 8px; z-index: 30; width: min(92vw, 420px); }
.toast { background: var(--ink); color: var(--bg); padding: 12px 16px; border-radius: 14px; font-weight: 600; font-size: 14px; box-shadow: 0 12px 30px -12px rgba(0, 0, 0, .4); }
.pairs { display: grid; gap: 8px; }
.pairs .chip { text-align: left; border-radius: 14px; min-height: 48px; }
select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 40px; }
.codebox { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 14px 18px; border-radius: 18px; background: var(--accent-soft); }
.codebox b { font-family: var(--font-mono); font-size: 26px; letter-spacing: .04em; }
.count { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 18px 0; }
.count div { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 8px; text-align: center; }
.count b { display: block; font-family: var(--font-mono); font-size: clamp(26px, 7vw, 40px); line-height: 1; font-variant-numeric: tabular-nums; }
.count span { font-size: 12px; color: var(--muted); }
.opensat { font-weight: 800; font-size: clamp(20px, 4.4vw, 28px); margin: 6px 0 0; }
.tag.e { background: #E3F6EC; color: var(--ok); }
.tag.m { background: var(--accent-soft); color: var(--accent); }
.tag.h { background: var(--warn-soft); color: var(--warn); }
.cells .cell.e { box-shadow: inset 0 -3px 0 #8FD7B1; }
.cells .cell.m { box-shadow: inset 0 -3px 0 #A99BFF; }
.cells .cell.h { box-shadow: inset 0 -3px 0 #F4A27F; }
.cells .cell.done { box-shadow: none; }
.result { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 14px 0; }
.result div { background: var(--field); border-radius: 16px; padding: 14px 10px; text-align: center; }
.result b { display: block; font-family: var(--font-mono); font-size: 28px; line-height: 1.1; }
.result span { font-size: 12px; color: var(--muted); }
@media (max-width: 420px) { .result { grid-template-columns: 1fr 1fr; } .count { gap: 6px; } }
/* главный сайт */
.sec { margin-top: 56px; }
.sec > h2 { font-size: clamp(22px, 4vw, 30px); margin-bottom: 8px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; margin-top: 18px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 22px; }
.card h3 { font-family: var(--font-display); font-weight: 700; font-size: 20px; margin: 8px 0 6px; }
.card p { color: var(--muted); margin: 0; font-size: 15px; }
.card .when { font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); font-weight: 700; }
.card.hot { background: var(--grad); border-color: transparent; color: #fff; }
.card.hot p, .card.hot .when { color: rgba(255, 255, 255, .86); }
.prizes { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin-top: 18px; }
.prize b { display: block; font-family: var(--font-display); font-size: 26px; margin-top: 4px; }
details { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 18px; margin-top: 10px; }
summary { font-weight: 700; cursor: pointer; }
details p { margin: 10px 0 0; color: var(--muted); }
/* тест 1 этапа и карточка для сторис */
.warnbar { margin: 4px 0 0; padding: 10px 14px; border-radius: 14px; background: var(--warn-soft); color: var(--warn); font-size: 14px; font-weight: 600; }
.share { margin-top: 16px; }
/* места: связка, город, школа, страна */
.ranks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
.ranks div { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 14px 12px; min-width: 0; }
.ranks div:first-child { background: var(--grad); border-color: transparent; color: #fff; }
.ranks b { display: block; font-family: var(--font-display); font-size: clamp(20px, 4.4vw, 28px); line-height: 1.1; }
.ranks span { display: block; font-size: 12px; line-height: 1.35; color: var(--muted); }
.ranks div:first-child span { color: rgba(255, 255, 255, .85); }
@media (max-width: 520px) { .ranks { grid-template-columns: 1fr 1fr; } }
/* три карточки для сторис: лента с прокруткой по одной */
.stack > * { min-width: 0; }
.story { min-width: 0; display: grid; grid-auto-flow: column; grid-auto-columns: min(72%, 260px); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 4px 10px; margin: 0 -4px; scrollbar-width: none; overscroll-behavior-x: contain; }
.story::-webkit-scrollbar { display: none; }
.frame { margin: 0; scroll-snap-align: center; display: grid; gap: 8px; }
.frame .ph { width: 100%; height: auto; aspect-ratio: 9 / 16; border-radius: 18px; background: var(--field); display: grid; place-items: center; box-shadow: 0 20px 44px -28px rgba(40, 25, 140, .65); color: var(--muted); }
.frame figcaption { font-size: 13px; font-weight: 700; color: var(--muted); text-align: center; }
.dots { display: flex; justify-content: center; gap: 8px; }
.dots button { width: 28px; height: 28px; border: 0; background: none; padding: 0; display: grid; place-items: center; }
.dots button::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--line); transition: width .2s; }
.dots button[aria-selected="true"]::before { width: 22px; border-radius: 4px; background: var(--accent); }
/* выбор героя */
.heroes { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 8px; }
.heroopt { border: 2px solid transparent; border-radius: 16px; background: var(--field); padding: 6px 4px 0; display: grid; place-items: end center; aspect-ratio: 4 / 5; overflow: hidden; }
.heroopt img { width: 100%; height: 100%; object-fit: contain; object-position: bottom; }
.heroopt[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
/* достижения */
.achgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.achcard { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 18px; background: var(--field); min-width: 0; }
.achcard img { flex: none; width: 56px; height: 56px; }
.achcard b { display: block; font-size: 15px; }
.achcard small { display: block; font-size: 12px; color: var(--muted); line-height: 1.35; }
.achcard.locked b { color: var(--muted); }
.achcard .rare { display: inline-block; margin-top: 4px; font-family: var(--font-mono); font-size: 11px; font-weight: 700; color: var(--accent); }
.finalbox.in { background: var(--grad); color: #fff; border-color: transparent; }
.finalbox.in .kick, .finalbox.in .note { color: rgba(255, 255, 255, .9); }
.finalbox.in .kick::before { background: #fff; }
/* главный сайт: приглашение, герои и значки */
.refnote { margin: -4px 0 0; padding: 10px 14px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); font-weight: 700; font-size: 14px; }
.herorow { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; margin-top: 22px; align-items: end; }
.herorow img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: contain; object-position: bottom; filter: drop-shadow(0 14px 18px rgba(40, 25, 140, .18)); }
@media (max-width: 700px) { .herorow { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.badgerow { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 14px 8px; margin-top: 22px; }
.badgerow figure { margin: 0; display: grid; justify-items: center; gap: 6px; text-align: center; }
.badgerow img { width: 64px; height: 64px; }
.badgerow figcaption { font-size: 12px; font-weight: 700; line-height: 1.25; color: var(--muted); }
.card.hot .btn.onhot { color: #fff; border-color: rgba(255, 255, 255, .6); }
/* кабинет участника */
.mehero { display: grid; grid-template-columns: minmax(0, 260px) minmax(0, 1fr); gap: 28px; align-items: end; margin-top: 18px; }
.meart { position: relative; display: grid; place-items: end center; }
.meart::before { content: ""; position: absolute; inset: 18% 4% 0; border-radius: 50% 50% 28px 28px; background: var(--grad); opacity: .16; }
.meart img { position: relative; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: contain; object-position: bottom; filter: drop-shadow(0 18px 24px rgba(40, 25, 140, .22)); }
.meinfo { display: grid; gap: 12px; min-width: 0; padding-bottom: 6px; }
.meinfo h1 { margin: 0; }
.meprog .track { height: 8px; border-radius: 4px; margin-top: 8px; }
@media (max-width: 640px) { .mehero { grid-template-columns: 1fr; gap: 6px; } .meart { max-width: 220px; margin: 0 auto; } }
#heropick.panel { margin-top: 14px; }
.steps { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; }
.step { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); }
.step .dot { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display); font-weight: 700; background: var(--field); color: var(--muted); }
.step.done .dot { background: var(--ok); color: #fff; }
.step.live { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.step.live .dot { background: var(--grad); color: #fff; }
.sbody { flex: 1; min-width: 0; }
.sname { font-family: var(--font-display); font-weight: 700; font-size: 16px; }
.sstat { font-size: 14px; color: var(--muted); }
.sdet { font-size: 14px; font-weight: 700; margin-top: 2px; }
@media (max-width: 520px) { .step { flex-wrap: wrap; } .step .btn { flex: 1 1 100%; } }
.invite { display: grid; grid-template-columns: minmax(0, 1fr) 200px; gap: 28px; align-items: center; }
.invite .qr { background: #fff; border-radius: 20px; padding: 10px; }
.invite .qr svg { display: block; width: 100%; height: auto; }
.invite .qr svg path, .invite .qr svg rect[fill="#000000"] { fill: #1A1646; }
.invcount { margin: 14px 0 8px; font-size: 14px; color: var(--muted); }
.invcount b { color: var(--ink); }
@media (max-width: 640px) { .invite { grid-template-columns: 1fr; } .invite .qr { max-width: 200px; } }
footer a { font-weight: 700; font-size: 14px; }
/* рейтинг */
.tophero { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: end; margin-top: 8px; }
.tophero h1 { margin-top: 10px; }
.bigstat { text-align: right; display: grid; }
.bigstat b { font-family: var(--font-display); font-size: clamp(40px, 8vw, 72px); line-height: 1; background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.bigstat span { font-weight: 700; }
.bigstat small { font-size: 12px; color: var(--muted); font-family: var(--font-mono); }
@media (max-width: 640px) { .tophero { grid-template-columns: 1fr; } .bigstat { text-align: left; } }
.seg3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.seg3 .chip { border-radius: 16px; min-height: 50px; padding: 8px; }
.pairchips .chip { min-height: 40px; font-size: 14px; padding: 6px 14px; }
.pairchips .chip small { font-family: var(--font-mono); font-size: 11px; opacity: .7; margin-left: 4px; }
.podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; align-items: end; text-align: center; }
.pod { min-width: 0; }
.pname { font-family: var(--font-display); font-weight: 700; font-size: clamp(13px, 2.6vw, 17px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pmeta { font-size: 12px; color: var(--muted); margin-bottom: 8px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pbar { position: relative; border-radius: 18px 18px 8px 8px; padding: 14px 6px 34px; display: grid; color: #fff; }
.pbar b { font-family: var(--font-display); font-size: clamp(22px, 5vw, 34px); line-height: 1; }
.pbar span { font-family: var(--font-mono); font-size: 12px; opacity: .85; }
.pbar i { position: absolute; left: 50%; bottom: 8px; transform: translateX(-50%); font-style: normal; font-family: var(--font-display); font-weight: 700; font-size: 14px; opacity: .9; }
.p1 .pbar { background: linear-gradient(160deg, #FFC93C, #F59E0B); color: #1A1646; min-height: 150px; }
.p2 .pbar { background: linear-gradient(160deg, #B8D7FF, #7EA6E0); color: #1A1646; min-height: 118px; }
.p3 .pbar { background: linear-gradient(160deg, #FFB48A, #E27D4E); color: #1A1646; min-height: 96px; }
.medal { display: inline-grid; place-items: center; min-width: 30px; height: 30px; padding: 0 6px; border-radius: 999px; font-family: var(--font-mono); font-weight: 700; font-size: 13px; background: var(--field); }
.medal.m1 { background: #FFC93C; color: #1A1646; } .medal.m2 { background: #B8D7FF; color: #1A1646; } .medal.m3 { background: #FFB48A; color: #1A1646; }
table.lb { min-width: 560px; }
table.lb td { vertical-align: middle; }
.duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 36px; }
@media (max-width: 860px) { .duo { grid-template-columns: 1fr; } }
.bars, .rows { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 8px; }
.bars li, .rows li { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); min-width: 0; }
.bn { flex: none; min-width: 26px; font-family: var(--font-mono); font-weight: 700; color: var(--muted); }
.bb, .bl { flex: 1; min-width: 0; }
.bl { display: grid; }
.bl b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bl span { font-size: 12px; color: var(--muted); }
.bt { height: 6px; border-radius: 3px; background: var(--field); margin-top: 6px; overflow: hidden; }
.bt i { display: block; height: 100%; background: var(--grad); border-radius: 3px; }
.bs { flex: none; font-family: var(--font-display); }
.bs small { font-family: var(--font-body); font-size: 12px; color: var(--muted); }
.ambs { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin-top: 16px; }
.amb { display: flex; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.amb div { display: grid; min-width: 0; }
.amb span { font-size: 12px; color: var(--muted); }
/* пульт руководства */
.kpis2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px; margin-top: 18px; }
.kpi2 { background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 16px 18px; display: grid; gap: 2px; min-width: 0; }
.kpi2 b { font-family: var(--font-display); font-size: clamp(26px, 4vw, 36px); line-height: 1.05; }
.kpi2 span { font-weight: 700; font-size: 14px; }
.kpi2 small { font-size: 12px; color: var(--muted); }
.kpi2.hot { background: var(--grad); color: #fff; border-color: transparent; }
.kpi2.hot small { color: rgba(255, 255, 255, .85); }
.chart { width: 100%; height: auto; display: block; }
.chart .ax text { font-family: var(--font-mono); font-size: 11px; fill: var(--muted); }
.funnel { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 10px; }
.fl { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 14px; }
.fl span { color: var(--muted); font-family: var(--font-mono); font-size: 13px; }
.fl em { font-style: normal; color: var(--accent); }
.ft { height: 14px; border-radius: 7px; background: var(--field); overflow: hidden; margin-top: 4px; }
.ft i { display: block; height: 100%; background: var(--grad); border-radius: 7px; }
.split2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; margin-top: 14px; }
/* Grand Final и прокторинг */
.finalh { font-size: clamp(38px, 7vw, 72px) !important; background: linear-gradient(100deg, #F59E0B, #3716FF 45%, #9E2D95); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; }
.check { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 16px; align-items: center; }
.camwrap { position: relative; aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden; background: var(--field); display: grid; place-items: center; color: var(--muted); font-size: 28px; }
.camwrap video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.ck { display: grid; gap: 6px; justify-items: start; }
.ck span, .ckrow span { font-size: 13px; color: var(--muted); }
.ck .okc { color: var(--ok); font-weight: 700; }
.ckrow { display: grid; gap: 2px; padding: 12px 14px; border-radius: 16px; background: var(--field); }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.45; cursor: pointer; }
.consent input { flex: none; width: 22px; height: 22px; margin-top: 1px; accent-color: var(--accent); }
.pchip { font-size: 12px; font-weight: 700; padding: 6px 10px; border-radius: 999px; background: var(--field); color: var(--muted); }
.pchip.bad { background: var(--warn-soft); color: var(--warn); }
.selfie { position: relative; width: 44px; height: 44px; border-radius: 50%; overflow: hidden; background: var(--field); flex: none; }
.selfie video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.selfie i { position: absolute; right: 3px; top: 3px; width: 9px; height: 9px; border-radius: 50%; background: #E5484D; box-shadow: 0 0 0 2px var(--bg); }
@media (prefers-reduced-motion: no-preference) { .selfie i { animation: rec 1.6s ease-in-out infinite; } @keyframes rec { 50% { opacity: .35; } } }
.ovl { position: fixed; inset: 0; z-index: 40; background: rgba(15, 13, 40, .72); display: grid; place-items: center; padding: 20px; }
.ovl .panel { max-width: 440px; text-align: center; }
.verdict { display: grid; gap: 4px; margin-top: 14px; padding: 14px 16px; border-radius: 16px; background: var(--field); }
.verdict.ok { background: #E3F6EC; color: var(--ok); }
.verdict.dq { background: var(--warn-soft); color: var(--warn); }
.verdict span { font-size: 13px; color: var(--muted); }
.revgrid { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: 22px; }
@media (max-width: 760px) { .revgrid { grid-template-columns: 1fr; } }
.evlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 14px; }
.evlist li { display: flex; gap: 10px; padding: 6px 10px; border-radius: 10px; background: var(--surface); border: 1px solid var(--line); }
.evlist li.bad { border-left: 4px solid var(--warn); }
.shots { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 8px; }
.shots figure { margin: 0; display: grid; gap: 4px; }
.shots img { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 10px; background: var(--field); }
.shots figcaption { font-size: 11px; color: var(--muted); }
tr.flag td { background: var(--warn-soft); }
/* кнопка «В сторис Instagram» и подсказка */
.btn.insta { background: linear-gradient(45deg, #FEDA75 0%, #FA7E1E 22%, #D62976 50%, #962FBF 75%, #4F5BD5 100%); color: #fff; gap: 10px; display: inline-flex; align-items: center; justify-content: center; }
.btn.insta .ig { width: 20px; height: 20px; flex: none; }
.howto { padding: 16px 18px; border-radius: 18px; background: var(--accent-soft); display: grid; gap: 10px; }
.howto ol { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 14px; }

/* ---------- Формат 2026-10-22: Блиц, Лестница, Арена ---------- */
.qtext { white-space: pre-line; }
/* плашка Instagram над карточками */
.instaplate { display: flex; gap: 14px; align-items: center; padding: 14px 16px; border-radius: 20px; color: #fff;
  background: linear-gradient(45deg, #FA7E1E 0%, #D62976 45%, #962FBF 75%, #4F5BD5 100%); }
.instaplate .ig { width: 34px; height: 34px; flex: none; }
.instaplate div { display: grid; gap: 2px; }
.instaplate b { font-size: 16px; }
.instaplate span { font-size: 13px; opacity: .92; line-height: 1.4; }
/* мини-рейтинг связки между этапами */
.miniboard { margin-top: 16px; }
.mbstatus { margin: 6px 0 4px; font-weight: 800; }
.mbstatus.in { color: var(--ok); } .mbstatus.out { color: var(--muted); }
.mbrows { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.mbrows li { display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: 14px; background: var(--field); }
.mbrows li.pass { box-shadow: inset 4px 0 0 var(--ok); }
.mbrows li.me { background: var(--accent-soft); outline: 2px solid var(--accent); }
.mbn { flex: 1; min-width: 0; display: grid; }
.mbn b, .mbn small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mbn small { color: var(--muted); font-size: 12px; }
.mbn em { font-style: normal; font-size: 11px; font-weight: 700; color: var(--accent); }
.mbs { font-family: var(--font-mono); }
/* Блиц: кольцо таймера вопроса, серия, отклик */
.qhead { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 10px 0 4px; }
.qhead .mono { font-size: 14px; color: var(--muted); }
.ring { --p: 1; position: relative; width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: conic-gradient(var(--accent) calc(var(--p) * 360deg), var(--line) 0); }
.ring::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: var(--bg); }
.ring b { position: relative; font-family: var(--font-mono); font-size: 20px; }
.ring.warn { background: conic-gradient(var(--warn) calc(var(--p) * 360deg), var(--line) 0); }
.scorebar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.scorebar .pchip b { color: var(--ink); }
.pchip.hot { background: linear-gradient(90deg, #FFB627, #FF6A3D); color: #fff; }
.dots30 { display: grid; grid-template-columns: repeat(30, minmax(0, 1fr)); gap: 3px; margin: 8px 0 2px; }
.dots30 i { height: 6px; border-radius: 3px; background: var(--line); }
.dots30 i.ok { background: var(--ok); } .dots30 i.bad { background: var(--warn); } .dots30 i.skip { background: var(--muted); opacity: .5; } .dots30 i.cur { background: var(--accent); }
.opt.right { background: #E3F6EC; border-color: var(--ok); }
.opt.right .k { background: var(--ok); border-color: var(--ok); color: #fff; }
.opt.wrong { background: var(--warn-soft); border-color: var(--warn); }
.opt.wrong .k { background: var(--warn); border-color: var(--warn); color: #fff; }
.opt:disabled { cursor: default; opacity: 1; color: inherit; }
.flash { margin-top: 14px; padding: 12px 16px; border-radius: 16px; font-weight: 800; text-align: center; }
.flash.ok { background: #E3F6EC; color: var(--ok); } .flash.bad { background: var(--warn-soft); color: var(--warn); } .flash.skip { background: var(--field); color: var(--muted); }
:root[data-theme="dark"] .opt.right, :root[data-theme="dark"] .flash.ok { background: #143A2A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .opt.right, :root:not([data-theme="light"]) .flash.ok { background: #143A2A; } }
/* Лестница: ступени, жизни */
.ladderwrap { display: grid; grid-template-columns: minmax(0, 1fr) 210px; gap: 22px; align-items: start; }
@media (max-width: 760px) { .ladderwrap { grid-template-columns: 1fr; } .rungs { order: -1; } }
.rungs { list-style: none; margin: 0; padding: 0; display: grid; gap: 3px; }
@media (max-width: 760px) { .rungs { grid-template-columns: repeat(20, minmax(0, 1fr)); } .rungs li span { display: none; } .rungs li { justify-content: center; padding: 6px 0; } }
.rungs li { display: flex; justify-content: space-between; padding: 4px 12px; border-radius: 10px; font-family: var(--font-mono); font-size: 13px; background: var(--field); color: var(--muted); }
.rungs li.ok { background: #E3F6EC; color: var(--ok); } .rungs li.bad { background: var(--warn-soft); color: var(--warn); }
.rungs li.cur { background: var(--grad); color: #fff; font-weight: 700; }
.hearts { font-size: 22px; letter-spacing: 3px; color: #E5484D; }
.hearts .lost { color: var(--line); }
/* Арена */
.livebadge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #E5484D; }
.livebadge::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: #E5484D; }
@media (prefers-reduced-motion: no-preference) { .livebadge::before { animation: rec 1.6s ease-in-out infinite; } }
.arenagrid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 22px; align-items: start; margin-top: 16px; }
@media (max-width: 900px) { .arenagrid { grid-template-columns: 1fr; } }
.meetbox { display: flex; gap: 12px; align-items: center; justify-content: space-between; flex-wrap: wrap; padding: 14px 16px; border-radius: 18px; background: var(--accent-soft); }
.roundbar { display: flex; gap: 6px; flex-wrap: wrap; }
.roundbar span { padding: 6px 12px; border-radius: 999px; font-size: 13px; font-weight: 700; background: var(--field); color: var(--muted); }
.roundbar span.on { background: var(--grad); color: #fff; }
.stakebox { display: grid; gap: 12px; }
.stakebox input[type=range] { width: 100%; accent-color: var(--accent); }
.stakebox .big { font-family: var(--font-display); font-size: 36px; }
.stakechips { display: flex; gap: 8px; flex-wrap: wrap; }
.boardlist { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.boardlist li { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 12px; background: var(--field); font-size: 14px; }
.boardlist li.me { background: var(--accent-soft); outline: 2px solid var(--accent); }
.boardlist li.out { opacity: .55; }
.boardlist li .mbn { font-weight: 700; }
.waitbig { font-family: var(--font-display); font-size: clamp(28px, 6vw, 48px); }
.hostgrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 18px; }
@media (max-width: 900px) { .hostgrid { grid-template-columns: 1fr; } }
.counts { display: grid; gap: 6px; }
.counts div { display: grid; grid-template-columns: 26px 1fr 40px; gap: 8px; align-items: center; font-size: 14px; }
.counts i { display: block; height: 10px; border-radius: 5px; background: var(--grad); }
.counts .ok i { background: var(--ok); }
.roomcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.roomcard { display: grid; gap: 6px; padding: 16px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); text-align: left; color: inherit; }
.roomcard[aria-pressed="true"] { outline: 3px solid var(--accent); }
.st { font-size: 12px; font-weight: 700; padding: 3px 9px; border-radius: 999px; background: var(--field); justify-self: start; }
.st.open, .st.stake, .st.reveal { background: #FDE2E2; color: #C21F2F; } .st.over { background: #E3F6EC; color: var(--ok); }
table.host td { font-size: 13px; }
table.host tr.out td { opacity: .5; }

/* ---------- доработки 2026-10-23: отступы, всплывающие достижения, итоги в кабинете ---------- */
.panel + .facts { margin-top: 18px; }
.codebox .note b { font-family: inherit; font-size: inherit; letter-spacing: 0; }
.achtoast { display: flex; gap: 12px; align-items: center; padding: 10px 14px; border-radius: 18px; color: var(--ink); border: 2px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, var(--grad) border-box;
  box-shadow: 0 16px 40px -16px rgba(40, 25, 140, .5); animation: achin .5s cubic-bezier(.2, .9, .3, 1.2); }
.achtoast img { flex: none; width: 48px; height: 48px; }
.achtoast div { display: grid; min-width: 0; }
.achtoast b { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.achtoast span { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@keyframes achin { from { transform: translateY(30px) scale(.9); opacity: 0; } }
.finalgrid { display: grid; grid-template-columns: minmax(0, 250px) minmax(0, 1fr); gap: 22px; align-items: start; }
.finalgrid img.ph { width: 100%; height: auto; aspect-ratio: 9 / 16; border-radius: 18px; background: var(--field); box-shadow: 0 20px 44px -28px rgba(40, 25, 140, .65); }
.certprev { width: 100%; height: auto; aspect-ratio: 1600 / 1131; border-radius: 12px; border: 1px solid var(--line); background: var(--field); }
@media (max-width: 640px) { .finalgrid { grid-template-columns: 1fr; } .finalgrid img.ph { max-width: 250px; margin: 0 auto; } }
.pairpick { display: grid; gap: 8px; }
.closedbox { display: grid; gap: 12px; }

/* демо-стенд (хост demo.*): пометка внизу слева, ставит common.js */
.demo-ribbon { position: fixed; left: 12px; bottom: 12px; z-index: 9999; background: var(--warn); color: #fff; font: 600 12px/1 var(--font-body); padding: 9px 13px; border-radius: 999px; box-shadow: 0 4px 14px rgba(0, 0, 0, .2); text-decoration: none; cursor: pointer; }
.demo-ribbon:hover { filter: brightness(1.1); }
