/* Макет: ровный песочный фон под цвет рендеров; одна ширина колонки на всю страницу;
   у каждого раздела один и тот же заголовок и одна цельная панель. Одна светлая тема. */
:root {
  --sand: #efe8dd;
  --surface: #f6f1e9;
  --raised: #fbf8f2;
  --ink: #23252a;
  --ink-soft: #625c53;
  --line: rgba(60, 48, 30, .12);
  --glow: #e9820f;
  --off: #b93d33;
  --display: "Unbounded", "Onest", system-ui, sans-serif;
  --body: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --width: 1120px;
  --bar: 44px;                 /* полоса контактов над шапкой */
  --radius: 20px;
  --gap: 20px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }
body { margin: 0; background: var(--sand); color: var(--ink); font: 400 16.5px/1.6 var(--body); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; }
img { max-width: 100%; display: block; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
h1, h2, h3 { font-family: var(--display); text-wrap: balance; margin: 0; }
h1 { font-weight: 300; font-size: clamp(30px, 4vw, 46px); line-height: 1.1; letter-spacing: -.035em; }
h2 { font-weight: 300; font-size: clamp(27px, 3.2vw, 40px); line-height: 1.15; letter-spacing: -.03em; }
h3 { font-weight: 400; font-size: 17.5px; line-height: 1.35; letter-spacing: -.012em; }

.contact-bar, .top, main, footer { width: min(var(--width), 100% - 40px); margin-inline: auto; }

/* полоса контактов: самый верх страницы, над шапкой; уезжает при прокрутке, шапка остаётся */
.contact-bar { height: var(--bar); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 4px 0 6px; font-size: 13px; }
.cb-author { display: flex; align-items: center; gap: 9px; min-width: 0; text-decoration: none; white-space: nowrap; }
.cb-ring { flex: none; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--ink); color: #fbf6ee; font: 400 9px var(--display); box-shadow: inset 0 0 0 1.5px var(--ink), inset 0 0 0 2.5px var(--glow); }
.cb-name { font-weight: 600; }
.cb-site { font: 400 11.5px var(--mono); color: var(--ink-soft); }
.cb-author:hover .cb-site { color: var(--ink); }
.cb-links { display: flex; align-items: center; gap: 2px; }
.cb-links a { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px; border-radius: 100px; color: var(--ink-soft); text-decoration: none; white-space: nowrap; transition: background .2s, color .2s; }
.cb-links a:hover { background: rgba(60, 48, 30, .07); color: var(--ink); }
.cb-links svg { width: 16px; height: 16px; flex: none; }
.cb-links .cb-write { margin-left: 6px; padding: 0 15px; background: var(--ink); color: #fbf6ee; font-weight: 500; }
.cb-links .cb-write:hover { background: #000; color: #fff; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 24px 44px -36px rgba(70, 52, 28, .4); }
.kicker { margin: 0 0 10px; display: flex; align-items: center; gap: 9px; font: 500 11.5px var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.kicker::before { content: ""; width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--glow); }

/* шапка */
.top {
  position: sticky; top: 10px; z-index: 20; margin-top: 0; height: 52px;
  display: flex; align-items: center; gap: 24px; padding: 0 10px 0 16px; border-radius: 16px;
  background: rgba(246, 241, 233, .86); border: 1px solid var(--line);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.brand { display: flex; align-items: center; gap: 10px; font: 500 13.5px var(--display); text-decoration: none; white-space: nowrap; }
.brand-ring { width: 20px; height: 20px; border-radius: 50%; background: var(--ink); box-shadow: inset 0 0 0 4px var(--ink), inset 0 0 0 6px var(--glow); }
.top nav { display: flex; gap: 22px; margin-left: auto; font-size: 14.5px; }
.top nav a { text-decoration: none; color: var(--ink-soft); white-space: nowrap; }
.top nav a:hover, .top nav a[aria-current="true"] { color: var(--ink); }
/* кнопка меню: видна, только когда разделы не помещаются в шапку */
.menu { display: none; flex: none; width: 38px; height: 38px; padding: 0; border-radius: 12px; border: 1px solid var(--line); background: var(--raised); cursor: pointer; place-items: center; }
.menu span, .menu span::before { display: block; width: 16px; height: 1.5px; border-radius: 2px; background: var(--ink); transition: translate .25s, rotate .25s; }
.menu span { position: relative; translate: 0 -3px; }
.menu span::before { content: ""; position: absolute; top: 6px; }
.top.open .menu span { translate: 0 0; rotate: 45deg; }
.top.open .menu span::before { top: 0; rotate: -90deg; }
.chip { display: inline-flex; align-items: center; gap: 8px; padding: 4px 11px; border: 1px solid var(--line); border-radius: 100px; font: 500 11.5px var(--mono); white-space: nowrap; }
.chip i { width: 7px; height: 7px; border-radius: 50%; background: var(--glow); animation: blink 2.4s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .35; } }

/* первый экран. Широкий: слева название и возможности одной колонкой, справа облёт */
.hero {
  --side: max(20px, calc(50vw - var(--width) / 2));
  height: calc(100svh - 52px - var(--bar)); min-height: 640px; padding: 10px 0 16px var(--side);
  display: grid; grid-template-columns: 340px minmax(0, 1fr); grid-template-rows: 1fr auto auto 1fr;
  grid-template-areas: ". film" "text film" "powers film" ". film"; column-gap: 12px;
}
.hero-text { grid-area: text; padding-bottom: 22px; }
.lead { margin: 12px 0 0; font-size: 17.5px; line-height: 1.5; color: var(--ink-soft); }
/* края кадра растворяются в фоне страницы: и по границам блока, и по границам самого кадра, когда он уменьшен */
.film {
  grid-area: film; position: relative; overflow: hidden; min-height: 0;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 3%, #000 97%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 3%, #000 97%, transparent 100%);
}
/* кадр шире блока не режется самим собой: тогда уменьшение (--fit из film.js) показывает его целиком */
.film video, .film canvas {
  position: absolute; top: 0; left: 50%; translate: -50% 0; height: 100%; width: auto; min-width: 100%; max-width: none; aspect-ratio: 16 / 9;
  object-fit: cover; object-position: 50% 52%; scale: var(--fit, 1);
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%), linear-gradient(180deg, transparent 0, #000 5%, #000 90%, transparent 100%);
  mask-image: linear-gradient(90deg, transparent 0, #000 6%, #000 94%, transparent 100%), linear-gradient(180deg, transparent 0, #000 5%, #000 90%, transparent 100%);
  -webkit-mask-composite: source-in; mask-composite: intersect;
}
.film canvas { opacity: 0; pointer-events: none; }

.powers { grid-area: powers; position: relative; z-index: 1; overflow: hidden; align-self: start; }
.powers-head { display: flex; align-items: center; gap: 12px; padding: 6px 12px; height: 66px; border-bottom: 1px solid var(--line); }
.round { width: 34px; height: 34px; flex: none; border-radius: 50%; border: 1px solid var(--line); background: var(--raised); font-size: 12px; cursor: pointer; }
.ghost { flex: none; padding: 6px 12px; border-radius: 100px; border: 1px solid var(--line); background: var(--raised); font-size: 13px; font-weight: 500; cursor: pointer; white-space: nowrap; }
.round:hover, .ghost:hover { background: #fff; }
.caption { margin: 0; flex: 1; min-width: 0; line-height: 1.3; }
.caption b { display: block; font: 400 13.5px/1.3 var(--display); }
.caption span { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; font-size: 12px; line-height: 1.35; color: var(--ink-soft); }
/* ячейки делят одну панель тонкими линиями: линии — это зазоры, сквозь которые виден фон списка */
.cells { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--line); }
.cells li { display: grid; background: var(--surface); }
.cells button { position: relative; display: block; width: 100%; text-align: left; border: 0; background: transparent; cursor: pointer; padding: 9px 16px 10px; transition: background .25s; }
.cells button:hover { background: var(--raised); }
.cells b { display: block; font-weight: 600; font-size: 14.5px; line-height: 1.35; }
.cells span { display: block; font-size: 12.5px; line-height: 1.4; color: var(--ink-soft); }
.cells button[aria-current="true"] { background: var(--raised); }
.cells button[aria-current="true"]::after { content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: calc(var(--p, 0) * 100%); background: var(--glow); }
.cells button[aria-current="true"] b { color: var(--glow); }

/* разделы: один и тот же шаг и заголовок */
.block { padding-top: 96px; }
.head { margin-bottom: 28px; max-width: 640px; }
.head > p:last-child { margin: 12px 0 0; color: var(--ink-soft); }

.statement { padding-top: 72px; }
.big { margin: 0 0 28px; max-width: 30em; font: 300 clamp(20px, 2.5vw, 30px)/1.5 var(--display); letter-spacing: -.022em; }
.big em { font-style: normal; color: var(--glow); }
.facts { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.facts div { display: flex; flex-direction: column-reverse; padding: 18px 22px; }
.facts div + div { border-left: 1px solid var(--line); }
.facts dt { font: 400 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); }
.facts dd { margin: 0; font: 300 30px/1.3 var(--display); font-variant-numeric: tabular-nums; letter-spacing: -.03em; white-space: nowrap; }
.facts small { font-size: .6em; margin-inline: 1px; color: var(--ink-soft); }

.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; overflow: hidden; background: var(--line); }
.card { background: var(--surface); padding: 24px 22px 26px; display: flex; flex-direction: column; gap: 10px; }
.card p { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--ink-soft); }
.card .warn { font-size: 13px; color: var(--off); }
.tag { font: 500 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--glow); }

/* разговор: одна панель, слева колонка, справа пульт */
.view { position: relative; overflow: hidden; }
.view canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.view .fallback { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.view .why { position: absolute; left: 16px; right: 16px; bottom: 14px; margin: 0; font: 400 12px var(--mono); color: var(--ink-soft); text-align: center; }
.talk-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); overflow: hidden; }
.view-talk { min-height: 500px; background: radial-gradient(closest-side, var(--raised), var(--surface)); border-right: 1px solid var(--line); }
.view-talk canvas { object-fit: contain; }
.state { position: absolute; z-index: 2; left: 16px; top: 16px; display: flex; align-items: center; gap: 10px; padding: 6px 13px; border-radius: 100px; background: var(--raised); border: 1px solid var(--line); font: 500 12px var(--mono); }
.state i { width: 9px; height: 9px; border-radius: 50%; background: var(--glow); transition: background .3s; }
.console { display: flex; flex-direction: column; min-width: 0; }
.phrases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: var(--gap); border-bottom: 1px solid var(--line); }
.phrases button { padding: 9px 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--raised); font-size: 13.5px; font-weight: 500; line-height: 1.3; cursor: pointer; }
.phrases button:hover { background: #fff; }
.phrases button[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fbf6ee; }
.phrases .mute { color: var(--off); }
.phrases .mute[aria-pressed="true"] { background: var(--off); border-color: var(--off); color: #fff; }
.dialog { flex: 1; padding: 22px var(--gap) 16px; display: flex; flex-direction: column; }
.who { margin: 0; font: 500 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.line { margin: 4px 0 18px; font-size: 18px; line-height: 1.45; min-height: 2.9em; }
.line-bot { font-family: var(--display); font-weight: 300; font-size: 17px; }
#wave { width: 100%; height: 72px; margin-top: auto; }
.note { margin: 0; padding: 14px var(--gap) 16px; border-top: 1px solid var(--line); font-size: 12.5px; line-height: 1.5; color: var(--ink-soft); }

/* что внутри: переключатели, сцена и список в одной панели */
.inside { overflow: hidden; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.toolbar-low { border-top: 1px solid var(--line); border-bottom: 0; }
.seg { display: inline-flex; flex-wrap: wrap; gap: 2px; padding: 3px; border-radius: 13px; background: rgba(60, 48, 30, .06); }
.seg button { display: inline-flex; align-items: center; gap: 7px; padding: 7px 13px; border: 0; border-radius: 10px; background: transparent; font-size: 13.5px; font-weight: 500; white-space: nowrap; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--raised); box-shadow: 0 1px 4px rgba(60, 48, 30, .2); }
.sw { width: 12px; height: 12px; border-radius: 50%; box-shadow: 0 0 0 1px #fff8; }
.sw-sand { background: #b4a48b; }
.sw-graphite { background: #474a50; }
.tilt { display: flex; align-items: center; gap: 10px; flex: 1; justify-content: flex-end; min-width: 180px; font: 400 11px var(--mono); color: var(--ink-soft); }
.tilt input { max-width: 190px; }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 22px; background: transparent; cursor: pointer; }
input[type=range]::-webkit-slider-runnable-track { height: 2px; background: var(--line); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 14px; height: 14px; margin-top: -6px; border-radius: 50%; background: var(--ink); border: 3px solid var(--glow); }
input[type=range]::-moz-range-track { height: 2px; background: var(--line); }
input[type=range]::-moz-range-thumb { width: 8px; height: 8px; border-radius: 50%; background: var(--ink); border: 3px solid var(--glow); }

.inside-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; }
.stage { display: flex; flex-direction: column; min-width: 0; }
/* фон ровно того цвета, в который декодируется видео (на тон отличается от --surface): иначе видна кромка кадра */
.view-inside { height: clamp(520px, calc(100svh - 200px), 760px); background: #f6f0e9; }
.view video.reel { position: absolute; left: 0; top: 0; width: 2px; height: 2px; opacity: 0; pointer-events: none; }
.view-inside canvas { cursor: grab; touch-action: pan-y; user-select: none; }
.view-inside canvas:active { cursor: grabbing; }
.leaders { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; }
.leaders line { stroke: rgba(35, 37, 42, .3); stroke-width: 1; }
.leaders circle { fill: var(--glow); }
.leaders .halo { fill: none; stroke: var(--glow); stroke-width: 2; animation: halo 1.4s ease-in-out infinite; }
@keyframes halo { 50% { r: 27px; opacity: .35; } }
.hint, .busy { position: absolute; z-index: 2; margin: 0; font: 400 12px var(--mono); color: var(--ink-soft); pointer-events: none; }
.hint { left: 16px; top: 12px; transition: opacity .5s; }
.hint.gone { opacity: 0; }
.busy { inset: 0; display: grid; place-content: center; }
.busy[hidden] { display: none; }
.pin { position: absolute; z-index: 2; right: 14px; translate: 0 -50%; max-width: 38%; padding: 3px 10px; border-radius: 8px; background: var(--raised); border: 1px solid var(--line); font: 500 11.5px/1.6 var(--mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; pointer-events: none; }
.pin.hot { background: var(--ink); color: #fbf6ee; }
.partlist { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); max-height: calc(clamp(520px, calc(100svh - 200px), 760px) + 62px); overflow-y: auto; }
.partlist li { border-bottom: 1px solid var(--line); }
.partlist button { display: block; width: 100%; height: 100%; text-align: left; padding: 9px 16px; border: 0; background: transparent; cursor: pointer; font-weight: 600; font-size: 14px; line-height: 1.35; }
.partlist button span { display: block; font-weight: 400; font-size: 12.5px; color: var(--ink-soft); }
.partlist button:hover { background: var(--raised); }
.partlist button[aria-pressed="true"] { background: var(--raised); box-shadow: inset 3px 0 0 var(--glow); }

/* лента: на телефоне карточки листаются вбок, полоска под ними показывает, где вы */
.rail-bar { display: none; }
/* галерея: шесть одинаковых плиток */
.gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.shot { margin: 0; display: flex; flex-direction: column; overflow: hidden; }
.shot img { width: 100%; aspect-ratio: 4 / 5; object-fit: contain; background: radial-gradient(closest-side at 50% 45%, var(--raised), #ebe4d8 140%); }
.shot-night img { object-fit: cover; object-position: 25% 50%; background: #14121a; }
.shot figcaption { flex: 1; padding: 12px 16px 14px; border-top: 1px solid var(--line); font-size: 13.5px; line-height: 1.45; color: var(--ink-soft); }

.table-wrap { overflow-x: auto; padding: 4px 22px; }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
thead th { font: 500 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
th, td { text-align: left; vertical-align: top; padding: 13px 16px 13px 0; border-bottom: 1px solid var(--line); }
tbody th { font-weight: 600; width: 46%; }
tbody td { color: var(--ink-soft); }
tbody tr:last-child > * { border-bottom: 0; }

/* путь: список с линией слева; пройденное закрашено, текущее светится */
.road { list-style: none; margin: 0; padding: 8px 22px; }
.road li { position: relative; display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 4px 20px; padding: 14px 0 14px 34px; }
.road li::before { content: ""; position: absolute; left: 0; top: 19px; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); border: 2px solid rgba(60, 48, 30, .25); }
.road li::after { content: ""; position: absolute; left: 6px; top: 35px; bottom: -17px; width: 2px; background: var(--line); }
.road li:last-child::after { display: none; }
.road .done::before { background: var(--ink); border-color: var(--ink); }
.road .done::after { background: var(--ink); }
.road li.now::before { border: 4px solid var(--glow); box-shadow: 0 0 0 5px rgba(233, 130, 15, .18); }
.road b { font-weight: 600; font-size: 15px; line-height: 1.5; }
.road span { font-size: 14.5px; line-height: 1.55; color: var(--ink-soft); }
.road .now b::after { content: "сейчас"; display: inline-block; margin-left: 9px; padding: 1px 8px; border-radius: 100px; background: var(--glow); color: #fff; font: 500 10.5px var(--mono); vertical-align: 1px; }

/* контакты: слева автор и ссылки, справа форма — одна панель, как «Разговор» */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); overflow: hidden; }
.author { display: flex; flex-direction: column; gap: 18px; padding: 26px 24px; border-right: 1px solid var(--line); background: radial-gradient(120% 80% at 0 0, var(--raised), var(--surface)); }
.who-am-i { display: flex; align-items: center; gap: 14px; }
.mono-ring { flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--ink); color: #fbf6ee; font: 400 16px var(--display); letter-spacing: .02em; box-shadow: inset 0 0 0 3px var(--ink), inset 0 0 0 5px var(--glow); }
.author-name { margin: 0; font: 400 20px/1.25 var(--display); letter-spacing: -.02em; }
.author-role { margin: 3px 0 0; font-size: 13.5px; color: var(--ink-soft); }
.author-text { margin: 0; font-size: 14.5px; line-height: 1.55; color: var(--ink-soft); }
.author-page { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 14px; background: var(--ink); color: #fbf6ee; text-decoration: none; transition: background .2s; }
.author-page:hover { background: #000; }
.author-page span { font: 500 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; opacity: .7; }
.author-page b { font: 400 16px var(--display); letter-spacing: -.01em; }
.author-page i { margin-left: auto; font-style: normal; color: var(--glow); font-size: 18px; }
.links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--line); }
.links li { display: grid; background: var(--raised); }
.links a { display: block; padding: 11px 14px 12px; text-decoration: none; transition: background .2s; min-width: 0; }
.links a:hover { background: #fff; }
.links span { display: block; font: 500 10.5px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.links b { display: block; font-weight: 500; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.feedback { display: flex; flex-direction: column; gap: 16px; padding: 26px 24px; min-width: 0; }
.feedback h3 { font-size: 19px; }
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; margin: 0; padding: 0; border: 0; }
.field > span, .field legend span { font: 500 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
.field > span em { margin-left: 6px; font: italic 400 12px var(--body); letter-spacing: 0; text-transform: none; opacity: .8; }
.field legend { padding: 0; margin-bottom: 6px; }
.field input, .field textarea {
  width: 100%; padding: 11px 13px; border-radius: 12px; border: 1px solid var(--line); background: var(--raised);
  font: 400 15.5px/1.45 var(--body); color: var(--ink); transition: border-color .2s, background .2s;
}
.field textarea { resize: vertical; min-height: 128px; }
.field input::placeholder, .field textarea::placeholder { color: #a69f94; }
.field input:hover, .field textarea:hover { background: #fff; }
.field input:focus, .field textarea:focus { outline: none; background: #fff; border-color: var(--ink); }
.field .bad { border-color: var(--off); }
.topics .seg { align-self: flex-start; }
.topics .seg label { position: relative; display: inline-flex; padding: 7px 13px; border-radius: 10px; font-size: 13.5px; font-weight: 500; white-space: nowrap; cursor: pointer; }
/* сама радиокнопка невидима и лежит внутри своей подписи: иначе на телефоне она раздвигает страницу вбок */
.topics .seg input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; pointer-events: none; }
.topics .seg label:has(input:checked) { background: var(--raised); box-shadow: 0 1px 4px rgba(60, 48, 30, .2); }
.topics .seg label:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 1px; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.send { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 16px; margin-top: 2px; }
.submit { padding: 12px 26px; border: 0; border-radius: 100px; background: var(--ink); color: #fbf6ee; font-weight: 500; font-size: 15px; cursor: pointer; transition: background .2s; }
.submit:hover { background: #000; }
.submit:disabled { opacity: .5; cursor: default; }
.form-note { flex: 1; min-width: 200px; margin: 0; font-size: 13px; line-height: 1.45; color: var(--ink-soft); }
.form-note.bad { color: var(--off); }
.form-note.ok { color: var(--ink); }
.form-note button { padding: 0; border: 0; background: none; font: inherit; color: var(--ink); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }

footer { margin-top: 96px; padding: 24px 0 44px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--ink-soft); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 30px; }
footer p { margin: 0; }
footer b { font-weight: 600; color: var(--ink); }
footer a { text-underline-offset: 2px; }

/* проявление при прокрутке */
.reveal { opacity: 0; translate: 0 24px; transition: opacity .7s ease, translate .7s cubic-bezier(.2, .7, .2, 1); }
.reveal.in { opacity: 1; translate: 0 0; }

/* уже 1101: название, облёт, возможности друг под другом, всё в первом экране */
@media (max-width: 1100px) {
  .hero { --side: 20px; display: flex; flex-direction: column; min-height: 660px; padding: 14px 0 14px; }
  .hero-text { padding: 0 var(--side); text-align: center; }
  .hero .kicker { justify-content: center; margin-bottom: 6px; }
  .lead { margin-top: 6px; font-size: 16px; }
  .film { flex: 1 1 0; min-height: 230px; width: 100%; }
  .powers { width: min(var(--width), 100% - 40px); margin: 0 auto; align-self: center; }
  .powers-head { height: 56px; }
  .cells { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cells button { height: 100%; }
  .inside-layout { grid-template-columns: minmax(0, 1fr); }
  .partlist { max-height: none; border-left: 0; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); }
  .partlist li { border: 0; background: var(--surface); }
}
/* шесть разделов в шапку помещаются от 981 px; уже — кнопка меню */
@media (max-width: 980px) {
  .top { gap: 10px; padding-right: 7px; }
  .top nav { display: none; }
  .chip { margin-left: auto; }
  .menu { display: grid; }
  .top.open nav {
    display: flex; flex-direction: column; gap: 0; position: absolute; top: calc(100% + 8px); left: 0; right: 0;
    padding: 6px; border-radius: 16px; border: 1px solid var(--line); background: #faf7f1;
    box-shadow: 0 24px 44px -24px rgba(70, 52, 28, .45); font-size: 16px;
  }
  .top.open nav a { padding: 12px 14px; border-radius: 10px; color: var(--ink); }
  .top.open nav a:hover, .top.open nav a[aria-current="true"] { background: rgba(60, 48, 30, .06); }
  .top.open nav a[aria-current="true"] { box-shadow: inset 3px 0 0 var(--glow); }
}
@media (max-width: 880px) {
  /* разговор: ответ сразу под кольцом, фразы ниже — видно вместе */
  .dialog { order: -1; border-bottom: 1px solid var(--line); padding-top: 16px; }
  .line { margin-bottom: 12px; }
  #wave { height: 48px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .card:last-child { grid-column: 1 / -1; }
  .talk-layout { grid-template-columns: minmax(0, 1fr); }
  .view-talk { min-height: 0; height: 420px; border-right: 0; border-bottom: 1px solid var(--line); }
  .view-inside { height: min(580px, 74svh); }
  .pin, .leaders line, .leaders circle:not(.halo) { display: none; }
  .partlist { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gallery { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cells { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .road li { grid-template-columns: minmax(0, 1fr); }
  .contact { grid-template-columns: minmax(0, 1fr); }
  .author { border-right: 0; border-bottom: 1px solid var(--line); }
  .block { padding-top: 76px; }
  .statement { padding-top: 56px; }
}
@media (max-width: 540px) {
  body { font-size: 15.5px; }
  .contact-bar, .top, main, footer { width: calc(100% - 24px); }
  .contact-bar { padding: 0; gap: 6px; }
  .cb-site { display: none; }
  .cb-links .cb-write { margin-left: 4px; padding: 0 13px; }
  /* телефон: в первом экране название, колонка и названия возможностей */
  .hero { min-height: 600px; padding-top: 10px; }
  .hero h1 { font-size: 27px; }
  .lead { font-size: 14.5px; }
  .powers { width: calc(100% - 24px); }
  .cells button { min-height: 44px; display: flex; align-items: center; padding: 6px 12px; }
  .cells b { font-size: 13px; }
  .cells span { display: none; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts div:nth-child(3) { border-left: 0; }
  .facts div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .partlist { grid-template-columns: minmax(0, 1fr); }
  .card:last-child { grid-column: auto; }
  /* возможности и галерея — лентой вбок, край следующей карточки виден */
  .rail {
    display: grid; grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 84%; gap: 10px;
    margin-inline: -12px; padding: 2px 12px 18px; scroll-padding-inline: 12px;
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none;
    background: none; border: 0; border-radius: 0; box-shadow: none;
  }
  .rail::-webkit-scrollbar { display: none; }
  .rail > * { scroll-snap-align: start; }
  .rail > .card { border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 18px 30px -26px rgba(70, 52, 28, .45); }
  .rail-bar { display: block; position: relative; height: 2px; margin: 2px auto 0; width: 38%; border-radius: 2px; background: var(--line); overflow: hidden; }
  .rail-bar i { position: absolute; top: 0; bottom: 0; left: 0; border-radius: 2px; background: var(--glow); }
  .view-talk { height: 280px; }
  .phrases { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 14px; }
  .toolbar { justify-content: center; }
  .toolbar { padding-inline: 6px; }
  .seg button { padding: 7px 9px; font-size: 12.5px; }
  .tilt { justify-content: center; flex-basis: 100%; }
  .table-wrap { padding: 4px 16px; }
  tbody th, tbody td { display: block; width: auto; border: 0; padding: 0; }
  tbody tr { display: block; padding: 12px 0; border-bottom: 1px solid var(--line); }
  tbody tr:last-child { border-bottom: 0; }
  thead { display: none; }
  .road { padding: 6px 16px; }
  .author, .feedback { padding: 20px 16px; }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .links { grid-template-columns: minmax(0, 1fr); }
  .field input, .field textarea { font-size: 16px; }
  .topics .seg label { padding: 7px 10px; font-size: 13px; }
  .submit { width: 100%; }
}
/* полоса контактов: на узком экране у ссылок остаются только значки */
@media (max-width: 760px) {
  .cb-links a:not(.cb-write) span { display: none; }
  .cb-links a:not(.cb-write) { width: 34px; padding: 0; justify-content: center; }
  .cb-links svg { width: 18px; height: 18px; }
}
@media (max-width: 400px) {
  .cb-name { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .chip i, .leaders .halo { animation: none; }
  .cells button { transition: none; }
}
