/* Анкета встречи Reisus — в визуальном языке прототипа (Прототип/reisus_final.html).
   Layout: «стенд» прототипа. Шапка → закреплённая консоль «Маршрут встречи» (шкала времени, размеченная по минутам блоков, бегунок «сейчас», нумерованные шаги, как в проигрывателе сценариев) → шаг: слева колонка «Текущий шаг», справа панели вопросов с тонкими разделителями.
   Цвет: токены прототипа, светлая и тёмная темы. Фирменный зелёный — основное действие (кнопки «Далее», «Смотреть», текущий шаг), зелёный — состояние (выбрано, отвечено), жёлтый — только маркер «сейчас». Шрифт: Inter, как в прототипе. */
:root {
  --green: #43B52B; --green-d: #2F9E24; --green-ink: #237A1B; --green-soft: #EFF8EB; --green-line: #CFE9C6;
  --ink: #363A3D; --ink-2: #686D70; --ink-3: #94999C;
  --bg: #F3F5F6; --light: #EEF1F2; --line: #E1E6E8; --card: #FFFFFF; --side: #FAFBFB; --road: #D8DEE1;
  --yellow: #F2C230; --yellow-ink: #765700; --yellow-soft: #FDF6DC;
  --warn: #DB8A22; --warn-ink: #94560A; --warn-soft: #FDF4E6; --warn-line: #F2D7AE;
  --crit: #D0453B; --crit-ink: #AE3128; --crit-soft: #FCEEEC; --crit-line: #F2C4BF;
  --primary: #363A3D; --primary-fg: #FFFFFF; --primary-hover: #2A2D2F;
  --accent: #43B52B; --accent-hover: #2F9E24; --accent-fg: #FFFFFF; /* основное действие — фирменный зелёный */
  --sel-norm: #2A8A1F; --sel-crit: #C2382E; --sel-warn: #A8620D; --sel-soft: #5B6064; --on-sel: #FFFFFF;
  --k-policy: #3D7BD9; --k-behav: #8E5BD9; --k-ctrl: #C2185B;
  --f: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --f-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --r-sm: 6px; --r-md: 8px; --r-lg: 10px; --r-xl: 12px;
  --float: 0 1px 2px rgba(0, 0, 0, .04), 0 4px 12px rgba(0, 0, 0, .04);
  --ease: cubic-bezier(.2, 0, 0, 1);
  --con-h: 150px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --green: #4CC234; --green-d: #3A9F27; --green-ink: #86D873; --green-soft: rgba(67, 181, 43, .14); --green-line: rgba(67, 181, 43, .38);
    --ink: #E9ECED; --ink-2: #A2A8AB; --ink-3: #72797C;
    --bg: #0D0F10; --light: #1F2325; --line: rgba(255, 255, 255, .10); --card: #15181A; --side: #111315; --road: #2D3336;
    --yellow: #E2B52A; --yellow-ink: #F1D073; --yellow-soft: rgba(242, 194, 48, .12);
    --warn: #E9A13F; --warn-ink: #F3BC6E; --warn-soft: rgba(219, 138, 34, .14); --warn-line: rgba(219, 138, 34, .38);
    --crit: #E0574D; --crit-ink: #F39088; --crit-soft: rgba(208, 69, 59, .16); --crit-line: rgba(208, 69, 59, .42);
    --primary: #E9ECED; --primary-fg: #15181A; --primary-hover: #FFFFFF;
    --accent: #3A9F27; --accent-hover: #4CC234; --accent-fg: #FFFFFF;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --green: #4CC234; --green-d: #3A9F27; --green-ink: #86D873; --green-soft: rgba(67, 181, 43, .14); --green-line: rgba(67, 181, 43, .38);
  --ink: #E9ECED; --ink-2: #A2A8AB; --ink-3: #72797C;
  --bg: #0D0F10; --light: #1F2325; --line: rgba(255, 255, 255, .10); --card: #15181A; --side: #111315; --road: #2D3336;
  --yellow: #E2B52A; --yellow-ink: #F1D073; --yellow-soft: rgba(242, 194, 48, .12);
  --warn: #E9A13F; --warn-ink: #F3BC6E; --warn-soft: rgba(219, 138, 34, .14); --warn-line: rgba(219, 138, 34, .38);
  --crit: #E0574D; --crit-ink: #F39088; --crit-soft: rgba(208, 69, 59, .16); --crit-line: rgba(208, 69, 59, .42);
  --primary: #E9ECED; --primary-fg: #15181A; --primary-hover: #FFFFFF;
  --accent: #3A9F27; --accent-hover: #4CC234; --accent-fg: #FFFFFF;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { background: var(--bg); }
body { margin: 0; color: var(--ink); font-family: var(--f); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
button, select, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus-visible, select:focus-visible, a:focus-visible, [tabindex]:focus-visible { outline: 2px solid var(--ink-3); outline-offset: 2px; }
h1, h2, h3, h4 { margin: 0; text-wrap: balance; font-weight: 600; letter-spacing: -.01em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
a { color: var(--green-ink); }
.ic { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink-2); font-size: 13px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Базовые контролы (как в прототипе) */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; border: 1px solid var(--line); background: var(--card); border-radius: var(--r-md); height: 32px; padding: 0 12px; font-weight: 500; font-size: 13px; white-space: nowrap; text-decoration: none; color: var(--ink); transition: background 120ms var(--ease); }
.btn:hover:not(:disabled) { background: var(--light); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn .ic { width: 15px; height: 15px; }
.btn.pri { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); font-weight: 600; }
.btn.pri:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn.icon { width: 32px; padding: 0; }
.btn.soft { background: var(--green-soft); border-color: var(--green-line); color: var(--green-ink); }
.btn.danger { color: var(--crit-ink); }
.btn-lg { height: 40px; padding: 0 16px; font-size: 14px; }
.seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: var(--r-md); background: var(--light); }
.seg button { border: 0; background: transparent; height: 28px; padding: 0 12px; border-radius: var(--r-sm); font-weight: 500; font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.seg button:disabled { cursor: not-allowed; opacity: .55; }
.tag { display: inline-flex; align-items: center; gap: 4px; height: 20px; font: 500 11.5px var(--f); font-variant-numeric: tabular-nums; padding: 0 7px; border-radius: 4px; background: var(--light); color: var(--ink-2); white-space: nowrap; }
.tag.act { background: var(--green-soft); color: var(--green-ink); }
.tag.warn { background: var(--warn-soft); color: var(--warn-ink); }
.tag.hard { background: var(--crit-soft); color: var(--crit-ink); }
.eyebrow { font-size: 12px; font-weight: 500; color: var(--ink-2); }
.dot { width: 6px; height: 6px; border-radius: 50%; flex: none; background: var(--ink-3); }
.k-norm { background: var(--green); } .k-hard { background: var(--crit); } .k-soft { background: var(--ink-3); }
.k-data, .k-net { background: var(--warn); } .k-crit { background: var(--crit); box-shadow: 0 0 0 2px var(--crit-soft); }
.k-policy { background: var(--k-policy); } .k-behav { background: var(--k-behav); } .k-ctrl { background: var(--k-ctrl); }
.k-money { background: var(--yellow); }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); min-width: 0; }
.panel-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 16px; border-bottom: 1px solid var(--line); min-height: 48px; }
.panel-h h2, .panel-h h3 { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 8px; }
.panel-h h2 .ic, .panel-h h3 .ic { color: var(--ink-2); }
.panel-b { padding: 14px 16px; display: grid; gap: 12px; }
.autonote { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; line-height: 1.45; color: var(--ink-2); background: var(--side); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 10px 12px; margin: 0; }
.autonote > .ic { width: 16px; height: 16px; margin-top: 1px; color: var(--green-d); }
.autonote b { color: var(--ink); font-weight: 600; }
.autonote ul { display: grid; gap: 4px; margin-top: 4px; }
.autonote li { display: flex; gap: 6px; }
.autonote li::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--ink-3); margin-top: 8px; flex: none; }
.hint { display: inline-flex; align-items: flex-start; gap: 6px; font-size: 12.5px; line-height: 1.4; color: var(--green-ink); }
.hint .ic { width: 14px; height: 14px; margin-top: 1px; }
input[type="text"], input[type="number"], input[type="date"], input[type="password"], select, textarea {
  width: 100%; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--card); padding: 7px 10px; font-size: 14px; line-height: 1.45; color: var(--ink);
  transition: border-color 120ms var(--ease), box-shadow 120ms var(--ease);
}
input::placeholder, textarea::placeholder { color: var(--ink-3); }
input:focus, select:focus, textarea:focus { outline: 0; border-color: var(--green-d); box-shadow: 0 0 0 3px var(--green-soft); }
input:disabled, textarea:disabled { opacity: .6; }
textarea { resize: vertical; min-height: 38px; display: block; }
.field { display: grid; gap: 4px; min-width: 0; }
.field > span, .field > label { font-size: 12px; font-weight: 500; color: var(--ink-2); }

/* ---------- Стенд и шапка */
.stand { max-width: 1400px; margin-inline: auto; padding-inline: clamp(16px, 2vw, 24px); padding-block: 16px 40px; display: flex; flex-direction: column; gap: 16px; }
.sbar { display: flex; align-items: center; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1 1 320px; border: 0; background: none; padding: 0; text-align: left; color: var(--ink); }
.brand-logo { display: block; flex: none; width: auto; height: 20px; }
.mark { width: 32px; height: 32px; border-radius: var(--r-md); background: var(--green-d); color: #fff; display: grid; place-items: center; flex: none; }
.mark .ic { width: 18px; height: 18px; stroke-width: 2; }
.brand-t { display: flex; flex-direction: column; min-width: 0; }
.brand-t b { font-size: 22px; font-weight: 800; line-height: 1.2; letter-spacing: -.025em; }
.brand-t span { font-size: 13px; color: var(--ink-2); }
.sbar-r { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.sbar-r > .btn { height: 34px; }

/* ---------- Консоль маршрута */
.console { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); position: sticky; top: 8px; z-index: 20; box-shadow: 0 -8px 0 var(--bg), var(--float); }
.con-head { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; padding: 8px 12px 8px 16px; min-height: 52px; flex-wrap: wrap; }
.con-title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.con-title b { font-size: 14px; font-weight: 600; white-space: nowrap; }
.con-client { font-size: 13px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.con-ctrl { display: flex; align-items: center; gap: 6px; margin-left: auto; flex-wrap: wrap; }
.con-ctrl .btn { height: 34px; }
.con-ctrl .btn.pri { min-width: 96px; }
.save { font-size: 12px; color: var(--ink-3); margin-right: 6px; white-space: nowrap; }
.save[data-kind="error"] { color: var(--crit-ink); }


.steps { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 4px; padding: 0 16px 12px; }
.step { display: flex; align-items: center; gap: 8px; min-width: 0; min-height: 36px; padding: 4px 8px; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--card); color: var(--ink-2); font-size: 12.5px; line-height: 1.2; font-weight: 500; text-align: left; transition: background 120ms var(--ease); }
.step:hover { background: var(--light); }
.step i { font-style: normal; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; background: var(--light); font-weight: 600; font-size: 11px; flex: none; }
.step i .ic { width: 11px; height: 11px; stroke-width: 2.6; }
.step span { display: flex; flex-direction: column; min-width: 0; }
.step span b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.step.done { color: var(--green-ink); }
.step.done i { background: var(--green-d); color: var(--primary-fg); }
.step.cur { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.step.cur i { background: var(--accent-fg); color: var(--accent); }

/* ---------- Шаг */
.view:focus { outline: 0; }
.stage { display: grid; grid-template-columns: minmax(240px, 300px) minmax(0, 1fr); gap: 24px; align-items: start; }
.info { position: sticky; top: calc(var(--con-h) + 24px); max-height: calc(100vh - var(--con-h) - 40px); overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding-right: 4px; min-width: 0; }
.info h1 { font-size: 22px; line-height: 1.25; letter-spacing: -.015em; }
.info .lede { font-size: 14px; color: var(--ink-2); }
.info .tags { display: flex; gap: 6px; flex-wrap: wrap; }
.check-t { font-size: 13px; color: var(--ink-2); }
.check-t b { color: var(--ink); font-weight: 500; }
.toc { display: grid; gap: 2px; border-top: 1px solid var(--line); padding-top: 10px; }
.toc a { display: flex; justify-content: space-between; gap: 10px; padding: 6px 8px; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; font-size: 13px; font-weight: 500; }
.toc a:hover { background: var(--light); }
.toc .cnt { font-size: 12px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.toc .cnt.full { color: var(--green-ink); }
.body { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.group { scroll-margin-top: calc(var(--con-h) + 24px); }

/* ---------- Вопрос */
.q { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 12px; padding: 14px 16px; border-top: 1px solid var(--line); scroll-margin-top: calc(var(--con-h) + 24px); }
.q:first-child { border-top: 0; }
.q-st { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--road); display: grid; place-items: center; margin-top: 2px; color: transparent; transition: background 120ms var(--ease), border-color 120ms var(--ease); }
.q-st .ic { width: 11px; height: 11px; stroke-width: 2.8; }
.q.is-answered .q-st { background: var(--green-d); border-color: var(--green-d); color: #fff; }
.q-main { display: grid; gap: 10px; min-width: 0; }
.q-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.q-t { font-size: 15px; font-weight: 600; line-height: 1.4; }
.opts { display: flex; flex-wrap: wrap; gap: 6px; }
.opt { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); background: var(--card); border-radius: var(--r-md); min-height: 34px; padding: 6px 12px; font-size: 13.5px; font-weight: 500; line-height: 1.25; text-align: left; transition: background 120ms var(--ease), border-color 120ms var(--ease); }
.opt:hover { background: var(--light); }
.opt .ic { width: 14px; height: 14px; stroke-width: 2.4; display: none; }
.opt[aria-pressed="true"] { background: var(--sel-norm); border-color: var(--sel-norm); color: var(--on-sel); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.opt[aria-pressed="true"] .ic { display: block; }
.num-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.numf { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--card); height: 34px; padding-right: 10px; transition: border-color 120ms var(--ease), box-shadow 120ms var(--ease); }
.numf:focus-within { border-color: var(--green-d); box-shadow: 0 0 0 3px var(--green-soft); }
.numf input { width: 84px; border: 0; background: transparent; box-shadow: none !important; height: 32px; padding: 0 10px; font-weight: 600; font-variant-numeric: tabular-nums; }
.numf span { font-size: 13px; color: var(--ink-2); white-space: nowrap; }
.preset { height: 30px; padding: 0 10px; border-radius: var(--r-sm); border: 0; background: var(--light); font-size: 12.5px; font-weight: 500; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.preset:hover { color: var(--ink); background: var(--road); }
.scale { display: grid; gap: 4px; justify-items: start; }
.scale .seg button { min-width: 44px; font-size: 14px; font-weight: 600; }
.scale-ends { display: flex; justify-content: space-between; width: 100%; max-width: 252px; font-size: 12px; color: var(--ink-3); }
.note { font-size: 13px; background: var(--side); }

/* ---------- Старт */
.start { display: grid; grid-template-columns: minmax(240px, 300px) minmax(0, 1fr); gap: 24px; align-items: start; }
.start .info { position: static; max-height: none; overflow: visible; }
.start h1 { font-size: 26px; line-height: 1.2; letter-spacing: -.02em; }
.plan { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.card { display: grid; gap: 8px; align-content: start; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); padding: 12px 14px; min-width: 0; }
.card-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.card-h > .ic { color: var(--green-d); }
.card-h b { font-size: 14.5px; font-weight: 600; }
.card-h .tag { margin-left: auto; }
.card-l { display: grid; gap: 4px; font-size: 12.5px; line-height: 1.35; color: var(--ink-2); }
.card-l span { display: flex; gap: 7px; align-items: flex-start; }
.card-l .ic { width: 13px; height: 13px; margin-top: 2px; color: var(--ink-3); }
.lead-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; }
.script { font-size: 13.5px; line-height: 1.5; color: var(--ink); background: var(--side); border: 1px solid var(--line); border-radius: var(--r-md); padding: 10px 12px; }
.checks { display: grid; gap: 2px; }
.ck { display: flex; align-items: center; gap: 10px; font-size: 13.5px; padding: 6px 0; cursor: pointer; }
.ck input { width: 16px; height: 16px; margin: 0; accent-color: var(--green-d); }

/* ---------- Главная боль */
.pains { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.pain { display: grid; gap: 8px; align-content: start; text-align: left; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); padding: 12px 14px; color: var(--ink); transition: background 120ms var(--ease), border-color 120ms var(--ease); }
.pain:hover { background: var(--side); }
.pain[aria-pressed="true"] { border-color: var(--green-d); box-shadow: inset 0 0 0 1px var(--green-d); }
.pain-h { display: flex; align-items: center; gap: 8px; }
.pain-h > .ic { color: var(--ink-2); }
.pain[aria-pressed="true"] .pain-h > .ic { color: var(--green-d); }
.pain-h b { font-size: 14.5px; font-weight: 600; line-height: 1.3; }
.rank { margin-left: auto; font-size: 11.5px; font-weight: 500; color: var(--ink-3); white-space: nowrap; }
.pain[aria-pressed="true"] .rank { color: var(--green-ink); }
.pain p { font-size: 12.5px; line-height: 1.4; color: var(--ink-2); }
.pain .tag { justify-self: start; }
.preview { display: grid; gap: 6px; }
.preview li { display: flex; align-items: center; gap: 8px; font-size: 13.5px; flex-wrap: wrap; }

/* ---------- Прототип и отзыв */
.demo-top { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; }
.demo-top h1 { font-size: 22px; letter-spacing: -.015em; }
.demo-top .lede { font-size: 14px; color: var(--ink-2); max-width: 70ch; }
.recs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); background: var(--card); border-radius: var(--r-md); height: 30px; padding: 0 10px; font-size: 13px; font-weight: 500; white-space: nowrap; }
.chip:hover { background: var(--light); }
.chip small { font-size: 11.5px; color: var(--ink-3); font-weight: 500; }
.chip .ic { width: 13px; height: 13px; color: var(--green-d); stroke-width: 2.4; }
.chip[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: var(--primary-fg); }
.chip[aria-pressed="true"] small, .chip[aria-pressed="true"] .ic { color: inherit; opacity: .75; }
.chip[aria-pressed="true"] .dot { background: currentColor; box-shadow: none; }
.chip select { border: 0; background: transparent; padding: 0; height: 28px; font-size: 13px; font-weight: 500; box-shadow: none; width: auto; color: var(--ink-2); }
.demo { display: grid; grid-template-columns: minmax(0, 1fr) 340px; grid-template-rows: auto auto 1fr; grid-template-areas: "player info" "player fb" "lists fb"; gap: 16px; align-items: start; }
.demo-info { grid-area: info; display: grid; gap: 6px; padding: 2px 2px 0; }
.demo-info h1 { font-size: 22px; line-height: 1.25; letter-spacing: -.015em; }
.demo-info .lede { font-size: 14px; color: var(--ink-2); }
.demo > .player { grid-area: player; }
.demo > .scn-cols { grid-area: lists; }
.demo > .fb { grid-area: fb; }
.fb { position: sticky; top: calc(var(--con-h) + 24px); max-height: calc(100vh - var(--con-h) - 40px); overflow-y: auto; }
.fb-sec { padding: 12px 14px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.fb-sec:first-child { border-top: 0; }
.fb-sec h3 { font-size: 16px; line-height: 1.3; }
.fb-what { font-size: 13px; color: var(--ink-2); }
.reacts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.react { display: grid; justify-items: center; gap: 4px; padding: 8px 4px; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--card); font-size: 12.5px; font-weight: 500; color: var(--ink-2); transition: background 120ms var(--ease); }
.react:hover { background: var(--light); color: var(--ink); }
.react .ic { width: 18px; height: 18px; }
.react[data-r="useful"][aria-pressed="true"] { background: var(--sel-norm); border-color: var(--sel-norm); color: var(--on-sel); }
.react[data-r="questions"][aria-pressed="true"] { background: var(--sel-warn); border-color: var(--sel-warn); color: var(--on-sel); }
.react[data-r="notus"][aria-pressed="true"] { background: var(--sel-crit); border-color: var(--sel-crit); color: var(--on-sel); }
.fb .opts .opt { min-height: 30px; padding: 4px 10px; font-size: 12.5px; }
.shown { display: grid; gap: 2px; }
.shown button { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 8px; border: 0; border-radius: var(--r-sm); background: transparent; text-align: left; font-size: 13px; color: var(--ink); }
.shown button:hover, .shown button[aria-current="true"] { background: var(--light); }
/* ---------- Список сценариев прототипа */
.scn-cols { display: grid; gap: 16px; min-width: 0; }
.scn-cols .panel { overflow: hidden; }
.scn-list { display: grid; }
.scn { width: 100%; display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; gap: 12px; align-items: start; padding: 12px 16px; border: 0; border-top: 1px solid var(--line); background: var(--card); color: var(--ink); text-align: left; transition: background 120ms var(--ease); }
.scn-list li:first-child .scn { border-top: 0; }
.scn:hover { background: var(--side); }
.scn[aria-pressed="true"] { background: var(--green-soft); }
.scn-n { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--light); font-size: 12px; font-weight: 600; color: var(--ink-2); margin-top: 1px; }
.scn-n .ic { width: 12px; height: 12px; stroke-width: 2.6; }
.scn-n.plain { background: transparent; }
.scn.is-shown .scn-n:not(.plain) { background: var(--green-d); color: #fff; }
.scn-b { display: grid; gap: 3px; min-width: 0; }
.scn-t { display: flex; align-items: center; gap: 8px; }
.scn-t b { font-size: 14.5px; font-weight: 600; }
.scn[aria-pressed="true"] .scn-t b { color: var(--green-ink); }
.scn-w { font-size: 13px; color: var(--ink-2); line-height: 1.45; }
.scn-dur { display: inline-flex; align-items: center; gap: 3px; margin-left: auto; font-size: 12px; font-weight: 500; color: var(--ink-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.scn-dur .ic { width: 10px; height: 10px; }
.scn-why { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: var(--warn-ink); }
.scn-why .ic { width: 12px; height: 12px; }
.scn-chk { font-size: 12px; color: var(--ink-3); line-height: 1.4; }
.scn-s { padding-top: 1px; }
.scn-g { padding: 10px 16px 4px; font-size: 12px; font-weight: 500; color: var(--ink-2); border-top: 1px solid var(--line); }
.panel-h + .scn-g { border-top: 0; }
.fb-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.fb-h .btn { height: 26px; padding: 0 8px; font-size: 12px; }
details.qa { border-top: 1px solid var(--line); }
details.qa:first-of-type { border-top: 0; }
details.qa summary { cursor: pointer; padding: 7px 0; font-size: 13px; font-weight: 500; color: var(--ink); list-style: none; display: flex; justify-content: space-between; gap: 8px; }
details.qa summary::-webkit-details-marker { display: none; }
details.qa summary::after { content: "+"; color: var(--ink-3); }
details.qa[open] summary::after { content: "−"; }
details.qa p { padding-bottom: 8px; font-size: 12.5px; color: var(--ink-2); }

/* ---------- Проигрыватель роликов
   Кадр ролика всегда белый, поэтому сцена белая в обеих темах, а кнопки поверх кадра — графитовые. */
.player { overflow: hidden; container-type: inline-size; }
.pl-h { flex-wrap: wrap; }
.pl-title { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 10px; min-width: 0; }
.pl-title h2 { font-size: 15px; align-self: center; }
.pl-title .muted { font-size: 12.5px; }
.pl-title .dot { width: 8px; height: 8px; }
.pl-nav { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.pl-pos { min-width: 48px; text-align: center; font-size: 12px; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
/* Высота сцены — не больше, чем помещается под консолью вместе с панелью управления; ширина по пропорции 16:9 */
.pl-stage { position: relative; height: min(56.25cqw, max(200px, calc(100vh - var(--con-h) - 200px))); aspect-ratio: 16 / 9; max-width: 100%; margin-inline: auto; background: #fff; }
.pl-stage:focus { outline: 0; }
.pl-stage video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; background: #fff; cursor: pointer; }
.pl-over { position: absolute; inset: 0; display: grid; place-items: end end; padding: 16px; pointer-events: none; }
.pl-over > * { pointer-events: auto; }
.player[data-state="ended"] .pl-over { place-items: center; background: rgba(13, 15, 16, .34); pointer-events: auto; }
.player[data-state="error"] .pl-over, .player[data-state="empty"] .pl-over { place-items: center; }
.pl-end { display: grid; gap: 12px; justify-items: center; text-align: center; max-width: 100%; padding: 16px 20px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: 0 8px 30px rgba(0, 0, 0, .18); }
.pl-end p { font-size: 14px; font-weight: 500; }
.pl-end-a { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.pl-end .btn { white-space: normal; text-align: left; }
.pl-msg { max-width: 100%; padding: 10px 14px; background: var(--card); color: var(--ink-2); border: 1px solid var(--line); border-radius: var(--r-md); font-size: 13px; text-align: center; }
.pl-bar { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-top: 1px solid var(--line); }
.pl-time { min-width: 84px; font-size: 12.5px; color: var(--ink-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.pl-seek { position: relative; flex: 1; min-width: 80px; height: 32px; display: flex; align-items: center; }
.pl-seek input { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; margin: 0; border: 0; border-radius: 3px; padding: 0; cursor: pointer; background: linear-gradient(to right, var(--accent) var(--p, 0%), var(--road) var(--p, 0%)); }
.pl-seek input:focus { box-shadow: none; }
.pl-seek input:focus-visible { box-shadow: 0 0 0 3px var(--green-soft); }
.pl-seek input:disabled { cursor: default; opacity: .5; }
.pl-seek input::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--yellow); border: 2px solid var(--card); box-shadow: 0 1px 3px rgba(0, 0, 0, .3); position: relative; z-index: 1; }
.pl-seek input::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; background: var(--yellow); border: 2px solid var(--card); box-shadow: 0 1px 3px rgba(0, 0, 0, .3); }
.pl-seek input::-moz-range-track { background: transparent; }
.pl-marks { position: absolute; inset: 0; pointer-events: none; }
.pl-marks i { position: absolute; top: 50%; width: 2px; height: 6px; margin: -3px 0 0 -1px; background: var(--card); }
.pl-ch { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 12px 12px; }
.pl-ch .chip[aria-current="true"] { background: var(--accent); border-color: var(--accent); color: var(--accent-fg); }
.pl-ch .chip[aria-current="true"] small { color: inherit; opacity: .75; }
/* На всё окно браузера: плеер поверх страницы, ролик по центру. Панель с прогрессом и главами скрыта
   и выезжает, когда курсор у нижнего края (полоса 64 px над панелью и сама панель) или фокус внутри неё */
html.pl-fs-lock, html.pl-fs-lock body { overflow: hidden; }
.player.is-fs { position: fixed; inset: 0; z-index: 70; margin: 0; border: 0; border-radius: 0; background: #fff; }
.player.is-fs .pl-h { display: none; }
.player.is-fs .pl-stage { position: absolute; inset: 0; width: auto; height: auto; max-width: none; aspect-ratio: auto; margin: 0; }
.player.is-fs .pl-dock { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; background: var(--card); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px rgba(13, 15, 16, .12); opacity: 0; transform: translateY(12px); transition: opacity .18s ease, transform .18s ease; }
.player.is-fs .pl-dock::before { content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: 64px; }
.player.is-fs .pl-dock:hover, .player.is-fs .pl-dock:focus-within { opacity: 1; transform: none; }
.player.is-fs .pl-bar { border-top: 0; }
@media (prefers-reduced-motion: reduce) { .player.is-fs .pl-dock { transition: none; transform: none; } }

/* ---------- Предложение пилота */
.offer { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.offer > div { padding: 14px 16px; border-left: 1px solid var(--line); display: grid; gap: 2px; }
.offer > div:first-child { border-left: 0; }
.offer b { font-size: 22px; font-weight: 600; letter-spacing: -.015em; line-height: 1.2; }
.offer span { font-size: 12.5px; color: var(--ink-2); }

/* ---------- Итог */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--card); overflow: hidden; }
.stats > div { padding: 14px 16px; border-left: 1px solid var(--line); display: grid; gap: 2px; align-content: start; min-width: 0; }
.stats > div:first-child { border-left: 0; }
.stats b { font-size: 22px; font-weight: 600; letter-spacing: -.015em; line-height: 1.25; overflow-wrap: anywhere; }
.stats b.txt { font-size: 16px; line-height: 1.35; }
.stats b small { font-size: 13px; font-weight: 500; color: var(--ink-2); }
.stats span { font-size: 12px; color: var(--ink-2); }
.stats .good b { color: var(--green-ink); }
.sum-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.dl { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 6px 12px; font-size: 13.5px; margin: 0; }
.dl dt { color: var(--ink-2); }
.dl dd { margin: 0; overflow-wrap: anywhere; }
.list { display: grid; gap: 6px; font-size: 13.5px; }
.list li { display: flex; gap: 8px; align-items: baseline; }
.list .n { font-weight: 600; color: var(--ink-3); font-variant-numeric: tabular-nums; min-width: 14px; }
.quote { font-size: 13.5px; color: var(--ink); background: var(--side); border-left: 2px solid var(--green-d); padding: 6px 10px; border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.empty { color: var(--ink-3); }
.hyp { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 10px 16px; border-top: 1px solid var(--line); }
.hyp:first-child { border-top: 0; }
.hyp-n { font: 500 12px var(--f-mono); color: var(--ink-3); }
.hyp-t { font-size: 13.5px; }
.hyp-t small { display: block; font-size: 12px; color: var(--ink-3); }
.hyp .seg button[aria-pressed="true"][data-v="yes"] { color: var(--green-ink); }
.hyp .seg button[aria-pressed="true"][data-v="no"] { color: var(--crit-ink); }
.export { display: flex; flex-wrap: wrap; gap: 8px; }
#md-fallback { min-height: 160px; font: 12px var(--f-mono); }
.final { display: flex; align-items: center; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; padding: 16px; }
.final p { font-size: 15px; font-weight: 500; max-width: 60ch; }

/* ---------- Список встреч, ключ, тост */
.scrim { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, .28); }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; z-index: 61; width: min(440px, 100vw); background: var(--card); border-left: 1px solid var(--line); box-shadow: -12px 0 40px rgba(0, 0, 0, .12); display: flex; flex-direction: column; }
.drawer-h { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; border-bottom: 1px solid var(--line); min-height: 56px; }
.drawer-h h2 { font-size: 16px; }
.drawer-b { flex: 1; overflow-y: auto; padding: 14px 16px; display: grid; gap: 12px; align-content: start; }
.drawer-f { padding: 12px 16px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.drawer-f .btn { height: 36px; }
.slist { display: grid; gap: 8px; }
.srow { border: 1px solid var(--line); border-radius: var(--r-lg); padding: 10px 12px; display: grid; gap: 6px; }
.srow[aria-current="true"] { border-color: var(--green-d); box-shadow: inset 0 0 0 1px var(--green-d); }
.srow-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.srow-top b { font-size: 14px; font-weight: 600; overflow-wrap: anywhere; }
.srow-meta { font-size: 12px; color: var(--ink-2); }
.bar { height: 4px; border-radius: 2px; background: var(--light); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--green-d); border-radius: 2px; }
.srow-act { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.keygate { position: fixed; inset: 0; z-index: 80; background: var(--bg); display: grid; place-items: center; padding: 16px; }
.keygate form { width: min(400px, 100%); padding: 24px; display: grid; gap: 12px; }
.keygate h1 { font-size: 20px; }
.keygate .err { color: var(--crit-ink); font-size: 13px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 90; background: var(--primary); color: var(--primary-fg); padding: 8px 14px; border-radius: var(--r-md); font-size: 13px; box-shadow: var(--float); opacity: 0; pointer-events: none; transition: opacity .18s var(--ease); max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; }

/* ---------- Мобильная навигация */
.mnav { display: none; }

/* ---------- Адаптив */
@media (max-width: 1180px) {
  .stage, .start { grid-template-columns: minmax(0, 1fr); }
  .info { position: static; max-height: none; overflow: visible; }
  .demo { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; grid-template-areas: "info" "player" "fb" "lists"; }
  .fb { position: static; max-height: none; }
    .toc { display: none; }
}
@media (max-width: 900px) {
  .console { position: static; box-shadow: none; }
  .con-ctrl #nav-back, .con-ctrl #nav-next, .con-ctrl   .steps { grid-auto-columns: minmax(118px, 1fr); overflow-x: auto; scrollbar-width: thin; }
  .lead-grid, .sum-grid { grid-template-columns: minmax(0, 1fr); }
  .plan { grid-template-columns: minmax(0, 1fr); }
  .mnav { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom, 0px)); background: var(--card); border-top: 1px solid var(--line); }
  .mnav .btn { height: 36px; }
  .mnav-pos { font-size: 12px; color: var(--ink-2); text-align: center; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .stand { padding-bottom: 88px; }
    }
@media (max-width: 640px) {
  .brand-t span { display: none; }
  .meta { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats > div:nth-child(3) { border-left: 0; }
  .stats > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .offer { grid-template-columns: minmax(0, 1fr); }
  .offer > div { border-left: 0; border-top: 1px solid var(--line); }
  .offer > div:first-child { border-top: 0; }
  .hyp { grid-template-columns: 26px minmax(0, 1fr); }
  .hyp .seg { grid-column: 2; justify-self: start; }
  .q { padding: 12px; gap: 10px; }
  .pl-bar { gap: 6px; padding: 8px; }
  .pl-time { min-width: 0; }
  }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Анкета клиента и ссылка для клиентов */
.linkrow { display: flex; gap: 8px; margin-top: 10px; }
.linkrow input { flex: 1; min-width: 0; height: 36px; padding: 0 10px; border: 1px solid var(--line); border-radius: var(--r-md); background: var(--side); color: var(--ink); font: 13px var(--f); }
.srow-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.linkbtn { background: none; border: 0; padding: 0; font: inherit; color: var(--green-ink); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
.final-t { display: grid; gap: 10px; flex: 1 1 320px; }
.sent { max-width: 560px; margin: 40px auto; padding: 28px 24px; display: grid; gap: 14px; justify-items: start; }
.sent .mark { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--green-soft); color: var(--green-ink); }
.sent .mark .ic { width: 22px; height: 22px; }
.sent h1 { font-size: 24px; line-height: 1.25; }
.sent p { color: var(--ink-2); line-height: 1.5; }
.is-sent #console, .is-sent .mnav { display: none !important; }
