/* Лендинг: статичные HTML+CSS без сборки и без JS (ARCHITECTURE §2.2, ADR §10).
   Токены зеркалят светлую тему кабинета — web/app/src/index.css (:root). Тёмной темы нет:
   кадры кабинета на странице светлые. Анимации — только CSS; при prefers-reduced-motion
   показывается конечное состояние (последний блок файла). */

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/inter-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/inter-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
    U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215,
    U+FEFF, U+FFFD;
}

:root {
  color-scheme: light;
  --background: oklch(1 0 0);
  --foreground: oklch(0.32 0.007 250);
  --ink: oklch(0.22 0.006 250);
  --primary: oklch(0.56 0.225 260);
  --primary-hover: oklch(0.5 0.225 260);
  --primary-foreground: oklch(0.985 0.004 80);
  --primary-soft: oklch(0.945 0.026 260);
  --primary-ink: oklch(0.52 0.209 260);
  --highlight: oklch(0.675 0.288 340);
  --highlight-bright: oklch(0.52 0.222 340);
  --success: oklch(0.723 0.192 149.579);
  --success-ink: oklch(0.45 0.13 150);
  --muted: oklch(0.97 0.003 250);
  --muted-foreground: oklch(0.545 0.008 250);
  --border: oklch(0.925 0.004 250);
  --chart-1: oklch(0.45 0.14 260);
  --chart-1-soft: oklch(0.78 0.08 258);
  --code: oklch(0.19 0.004 250);
  --code-muted: oklch(0.72 0.008 250);

  --gutter: 16px;
  --max: 1160px;
  --radius: 8px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px oklch(0.22 0.006 250 / 6%);
  --shadow: 0 1px 2px oklch(0.22 0.006 250 / 5%), 0 24px 48px -16px oklch(0.22 0.006 250 / 18%);
  --dots: radial-gradient(oklch(0.22 0.006 250 / 9%) 1px, transparent 1.2px);
  /* Белая карточка интерфейса на точечной панели — общий приём всех разделов. */
  --card-shadow: 0 1px 2px oklch(0.22 0.006 250 / 6%), 0 14px 32px -12px oklch(0.22 0.006 250 / 20%);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 76px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--background);
  color: var(--foreground);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  font-feature-settings: 'cv11', 'ss01';
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink);
  line-height: 1.15;
  text-wrap: balance;
}

p,
figure,
ul,
ol {
  margin: 0;
}

a {
  color: inherit;
}

svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  width: 100%;
  max-width: calc(var(--max) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.skip {
  position: absolute;
  left: -9999px;
  top: 8px;
  z-index: 100;
  padding: 8px 12px;
  background: var(--background);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.skip:focus {
  left: 8px;
}

kbd {
  display: inline-grid;
  place-items: center;
  min-width: 1.6em;
  height: 1.6em;
  padding: 0 0.35em;
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 5px;
  background: var(--background);
  color: var(--foreground);
  font: 600 0.8em/1 ui-monospace, 'SF Mono', Menlo, monospace;
}

/* Каретка: мигает, как в редакторе. Цвет — фуксия кабинета (--highlight). */
.caret {
  display: inline-block;
  width: 0.08em;
  height: 0.9em;
  margin-left: 0.06em;
  vertical-align: -0.06em;
  background: var(--highlight);
  border-radius: 2px;
  animation: blink 1.1s steps(1) infinite;
}

.caret--doc {
  width: 2px;
  height: 1.15em;
  vertical-align: -0.2em;
  animation-delay: 1.3s;
}

.caret--sm {
  width: 2px;
  height: 1em;
  vertical-align: -0.15em;
  margin-left: 2px;
}

.caret--light {
  background: var(--highlight);
}

@keyframes blink {
  50% {
    opacity: 0;
  }
}

/* ——— Кнопки ——— */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 16px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.15s ease,
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

.btn--primary {
  background: var(--primary);
  color: var(--primary-foreground);
  box-shadow:
    inset 0 1px 0 oklch(1 0 0 / 18%),
    0 1px 2px oklch(0.45 0.2 260 / 30%);
}

.btn--primary:hover {
  background: var(--primary-hover);
}

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

.btn--ghost:hover {
  background: var(--muted);
}

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

.btn--light:hover {
  background: var(--primary-soft);
}

.btn--lg {
  min-height: 52px;
  padding: 0 26px;
  font-size: 17px;
  border-radius: 10px;
}

.btn--lg:hover {
  transform: translateY(-1px);
}

/* ——— Шапка ——— */

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: oklch(1 0 0 / 85%);
  backdrop-filter: saturate(1.5) blur(12px);
  border-bottom: 1px solid oklch(0.925 0.004 250 / 70%);
}

.topbar__in {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 64px;
}

.logo {
  display: inline-flex;
  align-items: center;
}

.topnav {
  display: none;
  gap: 28px;
  font-size: 15px;
}

.topnav a {
  color: var(--muted-foreground);
  text-decoration: none;
  transition: color 0.15s ease;
}

.topnav a:hover {
  color: var(--ink);
}

.topbar__actions {
  display: flex;
  gap: 4px;
  margin-left: auto;
}

/* ——— Первый экран ——— */

.hero {
  position: relative;
  padding: 56px 0 72px;
  overflow: hidden;
}

/* Точечная сетка полотна под первым экраном, гаснет книзу. */
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image: var(--dots);
  background-size: 22px 22px;
  mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 90%);
}

.hero__title {
  max-width: 11.5em;
  font-size: clamp(40px, 7vw, 80px);
  font-weight: 750;
  letter-spacing: -0.045em;
  line-height: 1.02;
}

.hero__lead {
  max-width: 38em;
  margin-top: 24px;
  color: var(--muted-foreground);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.55;
  text-wrap: pretty;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 32px;
}

/* ——— Живое полотно ———
   Повторяет кабинет: шапка редактора (только крошки), полотно с полями rf-*
   (web/shared/fields/fields.css — цвет текста, кольцо-тень поля, буквы вариантов),
   slash-меню, шторка ассистента (features/forms/chat/ChatDrawer.tsx). Правишь вид там —
   сверь здесь. */
.stage {
  position: relative;
  margin-top: 44px;
}

.apptop {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 0 16px;
  border-bottom: 1px solid var(--border);
  color: var(--ink);
  font-size: 13px;
  white-space: nowrap;
}

.apptop svg {
  flex: none;
  width: 16px;
  height: 16px;
}

.apptop i {
  color: var(--muted-foreground);
  font-style: normal;
  opacity: 0.7;
}

.apptop b {
  overflow: hidden;
  font-weight: 500;
  text-overflow: ellipsis;
}

.apptop__crumb {
  display: none;
}


.win {
  display: flex;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--background);
  box-shadow: var(--shadow);
}

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

/* Полотно: текст формы — тёплый --rf-text, а не холодный текст кабинета. */
.rf {
  --rf-text: rgb(55, 53, 47);
  --rf-muted: rgb(119, 118, 114);
  --field-shadow: 0 1px 1px 0 oklch(0 0 0 / 6%), 0 0 0 1px oklch(0 0 0 / 11%), 0 2px 5px 0 oklch(0 0 0 / 5%);
  color: var(--rf-text);
}

.doc__body {
  padding: 26px 20px 36px 52px;
}

.doc__title {
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 400;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.q {
  margin-top: 22px;
}

.q__label {
  font-size: 16px;
  font-weight: 650;
}

/* Звёздочка обязательного — синяя на полотне (у респондента она красная). */
.q__label em {
  margin-left: 4px;
  color: var(--primary);
  font-style: normal;
}

.q__input {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 320px;
  height: 40px;
  margin-top: 8px;
  padding: 0 12px;
  border-radius: var(--radius);
  color: var(--rf-muted);
  font-size: 15px;
  box-shadow: var(--field-shadow);
}

.q__input svg {
  width: 16px;
  height: 16px;
}

.q__aa,
.menu__aa {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.q__opts {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  margin-top: 8px;
}

.q__opts span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px 7px 8px;
  border-radius: var(--radius);
  font-size: 15px;
  box-shadow: var(--field-shadow);
}

.q__opts b {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background: oklch(0.42 0.006 250);
  color: #fff;
  font-size: 11px;
}

.q__stars {
  display: flex;
  gap: 4px;
  margin-top: 8px;
  color: var(--rf-muted);
}

.q__stars svg {
  width: 30px;
  height: 30px;
  stroke-width: 1.6;
}

/* Вопрос, добавленный ассистентом (раздел «Помощь ИИ»): подложка выделения. */
.q--added {
  margin-left: -10px;
  padding: 6px 10px 10px;
  border-radius: 10px;
  background: var(--primary-soft);
}

/* ——— Набор на полотне первого экрана ———
   Шаг .seq: строка «/» с меню (.cmd) живёт своё окно, затем на её месте встаёт вопрос
   (.blk) — подпись печатается, поле появляется. Время задают переменные шага: --at
   (начало), --cmd (сколько открыто меню), --pick (на сколько пунктов спускается
   выделение), --chars и --type (печать подписи). Конец анимации — все .cmd скрыты, все
   .blk видны; это же состояние показывает prefers-reduced-motion. */
.seq {
  position: relative;
  --blk-at: calc(var(--at) + var(--cmd));
  --type-at: calc(var(--blk-at) + 0.4s);
  --done-at: calc(var(--type-at) + var(--type));
}

.seq--1 {
  --at: 1s;
  --cmd: 1s;
  --pick: 0;
  --chars: 14;
  --type: 0.6s;
}

.seq--2 {
  --at: 3.4s;
  --cmd: 1.4s;
  --pick: 2;
  --chars: 10;
  --type: 0.45s;
}

.seq--3 {
  --at: 5.8s;
  --cmd: 1.6s;
  --pick: 3;
  --chars: 17;
  --type: 0.55s;
}

.seq + .seq,
.doc__title + .seq {
  margin-top: 20px;
}

.cmd {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  height: 32px;
  font-size: 16px;
  opacity: 0;
  animation: window var(--cmd) linear var(--at) forwards;
}

@keyframes window {
  0%,
  99% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

.blk,
.blk .q__label em {
  opacity: 0;
  animation: appear 0.15s ease-out forwards;
}

.blk {
  animation-delay: var(--blk-at);
}

.blk .q__label em {
  animation-delay: var(--done-at);
}

/* Плейсхолдер пустой подписи — пока не начали печатать. */
.ph {
  position: absolute;
  top: 0;
  left: 0;
  color: var(--rf-muted);
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  animation: window 0.4s linear var(--blk-at) forwards;
}

.blk .q__label {
  position: relative;
}

@keyframes appear {
  to {
    opacity: 1;
  }
}

/* Подпись вопроса печатается: обрезка снимается шагами по числу букв. */
.type {
  clip-path: inset(0 100% 0 0);
  animation: reveal var(--type) steps(var(--chars)) var(--type-at) forwards;
}

@keyframes reveal {
  to {
    clip-path: inset(0 0 0 0);
  }
}

.line__gutter {
  position: absolute;
  left: -46px;
  display: flex;
  gap: 1px;
  color: var(--muted-foreground);
}

.line__gutter svg {
  width: 14px;
  height: 14px;
}

.line__gutter svg:first-child {
  display: none;
}

.line__gutter .dots {
  fill: currentColor;
  stroke: none;
}

.menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 2;
  width: 250px;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--background);
  box-shadow: var(--shadow);
  color: var(--ink);
  font-size: 14px;
  opacity: 0;
  transform: translateY(-4px);
  animation: pop 0.2s ease-out calc(var(--at) + 0.15s) forwards;
}

@keyframes pop {
  to {
    opacity: 1;
    transform: none;
  }
}

.menu--up {
  top: auto;
  bottom: calc(100% + 6px);
  transform: translateY(4px);
}

.menu__head {
  padding: 6px 8px 4px;
  color: var(--muted-foreground);
  font-size: 12px;
}

.menu__item {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 32px;
  padding: 0 8px;
  border-radius: 6px;
}

.menu__item svg,
.menu__aa {
  flex: none;
  width: 16px;
  height: 16px;
  color: var(--muted-foreground);
  line-height: 16px;
}

/* Выделение пункта — серая подложка, как в редакторе; спускается на --pick пунктов,
   как при навигации стрелками. */
.menu__hl {
  position: absolute;
  top: 31px;
  left: 6px;
  right: 6px;
  height: 32px;
  border-radius: 6px;
  background: var(--muted);
  animation: walk calc(var(--pick) * 0.25s) steps(var(--pick), end) calc(var(--at) + 0.5s) forwards;
}

@keyframes walk {
  to {
    transform: translateY(calc(var(--pick) * 32px));
  }
}

.menu__item {
  position: relative;
}

/* Шторка «Помощь ИИ» — справа во всю высоту окна, как ChatDrawer кабинета. */
.drawer {
  display: flex;
  flex: none;
  flex-direction: column;
  width: 300px;
  border-left: 1px solid var(--border);
  background: var(--background);
  color: var(--ink);
}

.drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 16px 8px;
  font-size: 16px;
  font-weight: 650;
}

.drawer__head svg {
  width: 16px;
  height: 16px;
  color: var(--muted-foreground);
}

.drawer__feed {
  flex: 1;
  padding: 8px 16px 20px;
}

.drawer__input {
  position: relative;
  min-height: 96px;
  margin: 0 16px 16px;
  padding: 12px 52px 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--muted-foreground);
  font-size: 14px;
  line-height: 1.45;
}

.drawer__input .send {
  position: absolute;
  right: 8px;
  bottom: 8px;
  opacity: 0.5;
}

.turn {
  padding: 0 4px;
  font-size: 14px;
  line-height: 1.55;
}

.turn--me {
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.turn + .turn {
  margin-top: 8px;
}

.turn + .turn--me {
  margin-top: 20px;
}

.send {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--primary-foreground);
}

.send svg {
  width: 15px;
  height: 15px;
  stroke-width: 2;
}


/* ——— Разделы ——— */

.section {
  padding: 88px 0;
}

.head {
  max-width: 760px;
  margin: 0 0 48px;
}

.head--left {
  margin: 0;
}

.head__kicker {
  color: var(--primary-ink);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.head__title {
  margin-top: 10px;
  font-size: clamp(30px, 4.8vw, 48px);
  font-weight: 720;
  letter-spacing: -0.035em;
}

/* ——— Как это работает ——— */

.flow {
  display: grid;
  gap: 56px;
  padding: 0;
  list-style: none;
}

.flow__step {
  display: grid;
  gap: 24px;
  align-items: center;
}

.flow__num {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--background);
  font-size: 17px;
  font-weight: 700;
}

.flow__text h3 {
  margin-top: 16px;
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 720;
  letter-spacing: -0.03em;
}

.flow__text p {
  max-width: 28em;
  margin-top: 10px;
  color: var(--muted-foreground);
  font-size: 18px;
  text-wrap: pretty;
}

.flow__visual {
  position: relative;
  min-width: 0;
  padding: 28px 20px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--muted);
  background-image: var(--dots);
  background-size: 18px 18px;
}

.card-ui {
  max-width: 420px;
  margin: 0 auto;
  padding: 22px 22px 128px 38px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--background);
  box-shadow: var(--card-shadow);
}

.card-ui .q__label,
.embed .q__label {
  margin-top: 14px;
  font-size: 15px;
}

.card-ui .q__input,
.embed .q__input {
  height: 36px;
  font-size: 14px;
}

.mini-title {
  font-size: 22px;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.mini-line {
  position: relative;
  display: flex;
  align-items: center;
  height: 28px;
  margin-top: 16px;
}

.menu--static {
  width: 220px;
  opacity: 1;
  transform: none;
  animation: none;
  font-size: 13px;
}

.menu--static .menu__item {
  height: 30px;
}

.menu__item--on {
  background: var(--muted);
}

/* Сайт с формой блоком — как предпросмотр окна «Встраивание» («Ваша страница»). */
.site {
  max-width: 460px;
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--background);
  box-shadow: var(--card-shadow);
}

.site__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
  background: var(--muted);
}

.site__bar i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--border);
}

.site__bar span {
  flex: 1;
  margin: 0 40px 0 12px;
  padding: 3px 0;
  border-radius: 6px;
  background: var(--background);
  color: var(--muted-foreground);
  font-size: 12px;
  text-align: center;
}

.site__body {
  padding: 20px;
}

.sk {
  height: 9px;
  margin-top: 8px;
  border-radius: 4px;
  background: oklch(0.925 0.004 250 / 70%);
}

.sk--title {
  width: 55%;
  height: 16px;
  margin: 0 0 14px;
  background: oklch(0.85 0.004 250);
}

.sk--short {
  width: 60%;
}

.embed {
  margin-top: 18px;
  padding: 2px 16px 16px;
  border: 1.5px dashed oklch(0.56 0.225 260 / 45%);
  border-radius: 10px;
}

.embed .q__label em.red {
  color: oklch(0.6 0.22 27);
}

.rf-btn {
  display: inline-block;
  margin-top: 14px;
  padding: 8px 16px;
  border-radius: var(--radius);
  background: rgb(55, 53, 47);
  color: #fff;
  font-size: 14px;
  font-weight: 600;
}

/* «Ссылка на форму» таба «Поделиться»: поле и чёрная кнопка с иконкой копирования. */
.mini__link {
  display: flex;
  gap: 8px;
  font-size: 14px;
}

.mini__link span {
  flex: 1;
  min-width: 0;
  height: 38px;
  padding: 0 12px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--background);
  color: var(--ink);
  line-height: 36px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini__link b {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 6px;
  height: 38px;
  padding: 0 12px;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--background);
  font-weight: 600;
}

.mini__link svg {
  width: 15px;
  height: 15px;
}

.mini__link--float {
  max-width: 360px;
  margin: 16px auto 0;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--background);
  box-shadow: var(--shadow);
}

/* Таблица ответов кабинета: серые заголовки колонок, строки через линию. */
.mtable {
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--background);
  box-shadow: var(--shadow);
  font-size: 13px;
}

.mtable > div {
  display: grid;
  grid-template-columns: 7.5em minmax(0, 1fr);
  gap: 12px;
  padding: 10px 14px;
  color: var(--ink);
  white-space: nowrap;
}

.mtable span {
  overflow: hidden;
  text-overflow: ellipsis;
}

.mtable span:nth-child(3) {
  display: none;
}

.mtable > div + div {
  border-top: 1px solid var(--border);
}

.mtable__head {
  color: var(--muted-foreground) !important;
}

.mtable__head i {
  font-size: 10px;
  font-style: normal;
  font-weight: 600;
}

/* Новый ответ подсвечивается и гаснет. */
.mtable__new {
  animation: flash 2.4s ease-out 0.4s both;
}

.mail {
  display: flex;
  align-items: center;
  gap: 12px;
  max-width: 400px;
  margin: 16px 0 0 auto;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--background);
  box-shadow: var(--shadow);
}

.mail svg {
  flex: none;
  width: 22px;
  height: 22px;
  color: var(--primary);
}

.mail span {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.35;
}

.mail b {
  color: var(--ink);
  font-size: 14px;
}

.mail small {
  overflow: hidden;
  color: var(--muted-foreground);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ——— Помощь ИИ ——— */

.ai-sec {
  display: grid;
  gap: 32px;
  align-items: center;
}

.ai-sec__lead {
  max-width: 30em;
  margin-top: 20px;
  color: var(--muted-foreground);
  font-size: 18px;
  text-wrap: pretty;
}

.ai-sec__visual {
  padding: 28px 16px;
}

.ai-sec .win {
  box-shadow: var(--card-shadow);
}

.doc__body--ai {
  padding: 28px 24px 32px 40px;
}

/* На телефоне — только шторка: полотно рядом с ней не помещается. */
.ai-sec .win__main {
  display: none;
}

.ai-sec .drawer {
  width: 100%;
  border-left: 0;
}

/* ——— Бенто ——— */

.bento {
  display: grid;
  gap: 16px;
}

.tile {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--muted);
  background-image: var(--dots);
  background-size: 18px 18px;
  overflow: hidden;
}

.tile h3 {
  font-size: 22px;
  font-weight: 680;
  letter-spacing: -0.02em;
}

.tile p {
  margin-top: 8px;
  color: var(--muted-foreground);
  font-size: 16px;
  text-wrap: pretty;
}

.panel {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--background);
  box-shadow: var(--card-shadow);
  font-size: 14px;
}

.tile .panel p {
  margin: 0;
  font-size: 14px;
}

/* Аналитика: полоса карточек одной рамкой и таблица воронки — как вкладка «Обзор». */
.kpis {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--background);
}

.kpis div {
  padding: 10px 12px;
  border-color: var(--border);
  border-style: solid;
  border-width: 0 1px 1px 0;
}

.kpis small {
  display: block;
  color: var(--muted-foreground);
  font-size: 12px;
}

.kpis b {
  display: block;
  color: var(--ink);
  font-size: 22px;
  font-weight: 750;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.kpis i {
  color: var(--muted-foreground);
  font-size: 12px;
  font-style: normal;
}

.tile .panel .funnel__lead {
  margin: 14px 2px 8px;
  color: var(--muted-foreground);
  font-size: 13px;
}

.funnel__head,
.funnel__row {
  display: grid;
  grid-template-columns: 1fr 6.4em;
  align-items: center;
  gap: 4px 10px;
  padding: 6px 4px;
}

.funnel__head {
  border-bottom: 1px solid var(--border);
  color: var(--muted-foreground);
  font-size: 12px;
}

.funnel__head span:nth-child(2),
.funnel__head span:last-child,
.funnel__row i {
  display: none;
}

.funnel__head span:nth-child(3),
.funnel__row b {
  text-align: right;
}

.funnel__row + .funnel__row {
  border-top: 1px solid var(--border);
}

.funnel__row span:first-child {
  grid-column: 1 / -1;
  overflow: hidden;
  color: var(--ink);
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Полоса: тёмная часть — дошли до следующего шага (--l), светлая — ушли здесь (до --v).
   Цвета — --chart-1 и --chart-1-soft кабинета, как на настоящей воронке. */
.funnel .bar {
  height: 12px;
  border-radius: 4px;
  background:
    linear-gradient(var(--chart-1), var(--chart-1)) 0 / var(--l) 100% no-repeat,
    linear-gradient(var(--chart-1-soft), var(--chart-1-soft)) 0 / var(--v) 100% no-repeat,
    oklch(0.925 0.004 250 / 60%);
}

.funnel__row b {
  color: var(--ink);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.funnel__row i {
  color: var(--muted-foreground);
  font-style: normal;
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* Худший шаг — подложкой строки и жирным «Ушли здесь», как в кабинете. */
.funnel__row--worst {
  border-radius: 6px;
  background: oklch(0.925 0.004 250 / 55%);
}

.funnel__row--worst i {
  color: var(--ink);
  font-weight: 650;
}

/* Запись: SlotPicker респондента — квадраты дней, выбранное зелёной заливкой с кольцом
   (--rf-picked и --rf-picked-ring в fields.css), занятое время не показывается. */
.slots {
  --picked: oklch(0.723 0.192 149.579 / 0.16);
  --picked-ring: oklch(0.723 0.192 149.579 / 0.7);
  --field-shadow: 0 1px 1px 0 oklch(0 0 0 / 6%), 0 0 0 1px oklch(0 0 0 / 11%), 0 2px 5px 0 oklch(0 0 0 / 5%);
  color: rgb(55, 53, 47);
}

.slots__month {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
  color: rgb(119, 118, 114);
}

.slots__month span {
  display: flex;
  gap: 10px;
}

.slots__month svg {
  width: 16px;
  height: 16px;
}

.slots__month .off {
  opacity: 0.3;
}

.slots__days {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
}

.slots__days span,
.slots__times span {
  border-radius: var(--radius);
  background: var(--background);
  box-shadow: var(--field-shadow);
  text-align: center;
}

.slots__days span {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  color: rgb(119, 118, 114);
  font-size: 11px;
  line-height: 1.1;
}

.slots__days b {
  color: rgb(55, 53, 47);
  font-size: 15px;
  font-weight: 500;
}

.slots__days .off {
  opacity: 0.35;
}

.slots .on {
  background: var(--picked);
  box-shadow: 0 0 0 2px var(--picked-ring);
  color: rgb(55, 53, 47);
}

.tile .panel .slots__chosen {
  margin: 12px 0 8px;
  color: rgb(119, 118, 114);
  font-size: 13px;
}

.slots__times {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(4.4rem, 1fr));
  gap: 6px;
}

.slots__times span {
  padding: 8px 0;
  font-variant-numeric: tabular-nums;
}

/* Блок логики полотна: полоса слева, «Когда» и «Тогда» строками селектов. */
.logic-demo .q__label {
  font-size: 15px;
}

.logic-demo .q__input {
  max-width: 260px;
  height: 36px;
  font-size: 14px;
}

.q__opts--row {
  flex-direction: row;
}

.q__opts span.on {
  background: oklch(0.723 0.192 149.579 / 0.16);
  box-shadow: 0 0 0 2px oklch(0.723 0.192 149.579 / 0.7);
}

.logic {
  margin: 16px 0;
  padding: 2px 0 2px 14px;
  border-left: 3px solid var(--border);
}

.logic small {
  display: block;
  margin: 2px 0 6px;
  color: var(--muted-foreground);
  font-size: 12px;
}

.logic small + .logic__row + small {
  margin-top: 12px;
}

.logic__row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.sel {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 6px 32px 6px 10px;
  line-height: 1.3;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background:
    linear-gradient(45deg, transparent 50%, var(--muted-foreground) 50%) right 15px top 15px / 5px 5px no-repeat,
    linear-gradient(-45deg, transparent 50%, var(--muted-foreground) 50%) right 11px top 15px / 5px 5px no-repeat,
    var(--background);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}

.sel .menu__aa {
  width: auto;
}

.sel svg {
  width: 15px;
  height: 15px;
  color: var(--muted-foreground);
}

.canvas-demo p {
  margin: 6px 0 0;
  color: var(--rf-text);
  font-size: 14px;
}

.canvas-demo__h {
  font-size: 17px;
  font-weight: 650;
}

.canvas-demo__img {
  display: grid;
  place-items: center;
  height: 64px;
  margin-top: 12px;
  border-radius: 8px;
  background: var(--muted);
  color: var(--muted-foreground);
}

.canvas-demo__img svg {
  width: 26px;
  height: 26px;
}

.canvas-demo__break {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 10px;
  color: var(--muted-foreground);
  font-size: 12px;
  white-space: nowrap;
}

.canvas-demo__break i {
  flex: 1;
  border-top: 1px dashed var(--border);
}

.canvas-demo .q__label {
  font-size: 15px;
}

.types {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0;
  list-style: none;
}

.types li {
  padding: 5px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--background);
  box-shadow: var(--shadow-sm);
  color: var(--foreground);
  font-size: 13.5px;
  font-weight: 500;
}

.themes .turn {
  font-size: 14px;
}

.themes__pair {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}

.themes__to {
  color: var(--muted-foreground);
  font-size: 18px;
}

.swatch {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--background);
}

.swatch i {
  height: 8px;
  border-radius: 3px;
  background: var(--border);
}

.swatch i:first-child {
  width: 70%;
  background: var(--foreground);
}

.swatch b {
  width: 46%;
  height: 14px;
  margin-top: 4px;
  border-radius: 4px;
  background: var(--ink);
}

.swatch--dark {
  border-color: transparent;
  background: var(--code);
}

.swatch--dark i {
  background: oklch(1 0 0 / 14%);
}

.swatch--dark i:first-child {
  background: oklch(0.96 0.003 250);
}

.swatch--dark b {
  background: oklch(0.96 0.003 250);
}

/* «Мои подключения»: значок сервиса, имя с зелёной точкой, подпись, зелёный тумблер. */
.conns {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  padding: 6px 14px;
}

.conn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
}

.conn + .conn {
  border-top: 1px solid var(--border);
}

.conn__icon {
  flex: none;
  width: 28px;
  height: 28px;
}

/* Фирменные значки (ServiceIcon.tsx кабинета) красятся своими атрибутами: общая обводка
   svg на них не распространяется. */
.conn__icon.brand {
  stroke: none;
}

.conn__icon--hook {
  color: var(--primary);
  stroke-width: 2;
}

.conn__text {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.conn__text b {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 650;
}

.conn__text b i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
}

.conn__text small {
  color: var(--muted-foreground);
  font-size: 13px;
  line-height: 1.4;
}

.switch {
  position: relative;
  flex: none;
  width: 36px;
  height: 20px;
  border-radius: 999px;
  background: var(--success);
}

.switch::after {
  content: '';
  position: absolute;
  top: 2px;
  right: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
}


/* ——— Для тех, кто отвечает ——— */

.resp {
  display: grid;
  gap: 48px;
  align-items: center;
}

.resp__visual {
  padding: 40px 20px;
}

.phone {
  position: relative;
  width: min(72%, 272px);
  margin: 0 auto;
  padding: 4px;
  border-radius: 40px;
  background: #0d0d0f;
  box-shadow:
    0 0 0 1px #9c9ca2,
    var(--card-shadow);
}

/* Боковые кнопки корпуса. */
.phone::before,
.phone::after {
  content: '';
  position: absolute;
  width: 3px;
  border-radius: 2px;
  background: #b9b9bf;
}

.phone::before {
  top: 22%;
  left: -3px;
  height: 64px;
  box-shadow: 0 -52px 0 -16px #b9b9bf;
}

.phone::after {
  top: 30%;
  right: -3px;
  height: 84px;
}

.phone__screen {
  position: relative;
  overflow: hidden;
  border-radius: 36px;
  background: #fff;
}

.facts {
  display: grid;
  gap: 28px;
  margin-top: 36px;
  padding: 0;
  list-style: none;
}

.facts li {
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.facts h3 {
  font-size: 19px;
  font-weight: 680;
  letter-spacing: -0.015em;
}

.facts p {
  margin-top: 6px;
  color: var(--muted-foreground);
  text-wrap: pretty;
}

/* ——— Для кого ——— */

.uses {
  display: grid;
  gap: 40px 20px;
}

.use {
  display: flex;
  flex-direction: column;
}

.use h3 {
  margin-top: 20px;
  font-size: 19px;
  font-weight: 680;
  letter-spacing: -0.015em;
}

.use p {
  margin-top: 6px;
  color: var(--muted-foreground);
  font-size: 15.5px;
}

/* Точечная панель, как у шагов, на ней миниатюра настоящей формы. */
.use__cover {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  height: 248px;
  padding: 24px 24px 0;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--muted);
  background-image: var(--dots);
  background-size: 18px 18px;
}

.demo {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 280px;
  min-height: 100%;
  padding: 16px 16px 18px;
  border-radius: 12px 12px 0 0;
  background: var(--background);
  box-shadow: var(--card-shadow);
  font-size: 13px;
  /* Кнопка формы по умолчанию — тёмная, как у настоящей формы. */
  --accent: rgb(55, 53, 47);
}

.demo__title {
  font-size: 15px;
  font-weight: 650;
  line-height: 1.3;
}

.demo__label {
  margin-top: 10px;
  font-weight: 600;
}

.demo__input {
  margin-top: 5px;
  padding: 6px 10px;
  border-radius: 6px;
  color: var(--rf-muted);
  box-shadow: var(--field-shadow);
}

.demo__input--area {
  min-height: 46px;
}

.demo .rf-btn {
  align-self: flex-start;
  margin-top: 12px;
  padding: 6px 12px;
  background: var(--accent);
  font-size: 12.5px;
}

.demo__opts {
  display: flex;
  gap: 6px;
  margin-top: 6px;
}

.demo__opts i,
.demo__slots i,
.demo__scale i {
  font-style: normal;
}

.demo__opts i {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px 4px 5px;
  border-radius: 6px;
  box-shadow: var(--field-shadow);
}

.demo__opts b {
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  border-radius: 3px;
  background: oklch(0.42 0.006 250);
  color: #fff;
  font-size: 10px;
}

.demo__opts .on,
.demo__slots .on,
.demo__scale .on {
  background: oklch(0.723 0.192 149.579 / 0.16);
  box-shadow: 0 0 0 2px oklch(0.723 0.192 149.579 / 0.7);
}

.demo__slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  margin-top: 8px;
}

.demo__slots i {
  padding: 6px 0;
  border-radius: 6px;
  text-align: center;
  box-shadow: var(--field-shadow);
  font-variant-numeric: tabular-nums;
}

.demo__scale {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  gap: 3px;
  margin-top: 14px;
}

.demo__scale i {
  padding: 6px 0;
  border-radius: 5px;
  font-size: 11.5px;
  text-align: center;
  box-shadow: var(--field-shadow);
}

.demo__ends {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  color: var(--rf-muted);
  font-size: 11px;
}

.demo__file {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  padding: 7px 10px;
  border: 1.5px dashed oklch(0.22 0.006 250 / 20%);
  border-radius: 8px;
}

.demo__file svg {
  width: 16px;
  height: 16px;
  color: var(--accent);
}

.demo__file small {
  margin-left: auto;
  color: var(--rf-muted);
}

.demo__stars {
  display: flex;
  gap: 4px;
  margin-top: 10px;
  color: oklch(0.88 0.005 250);
  font-size: 24px;
  line-height: 1;
}

.demo__stars i {
  font-style: normal;
}

.demo__stars .on {
  color: var(--accent);
}

/* ——— Вопросы ——— */

.faq {
  display: grid;
  gap: 32px;
}

.faq__list details {
  border-bottom: 1px solid var(--border);
}

.faq__list details:first-child {
  border-top: 1px solid var(--border);
}

.faq__list summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px 0;
  color: var(--ink);
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}

.faq__list summary::-webkit-details-marker {
  display: none;
}

.faq__list summary::after {
  content: '';
  flex: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background:
    linear-gradient(var(--ink), var(--ink)) center / 11px 1.5px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 1.5px 11px no-repeat,
    var(--muted);
  transition: transform 0.2s ease;
}

.faq__list details[open] summary::after {
  transform: rotate(45deg);
}

.faq__list details p {
  max-width: 40em;
  padding-bottom: 22px;
  color: var(--muted-foreground);
}

/* ——— Финал и подвал ——— */

.final {
  padding: 0 0 88px;
}

.final__panel {
  position: relative;
  overflow: hidden;
  padding: 72px 24px;
  border-radius: 28px;
  background: var(--ink);
  text-align: center;
}

.final__panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(oklch(1 0 0 / 9%) 1px, transparent 1.2px);
  background-size: 22px 22px;
  mask-image: radial-gradient(ellipse at center, #000 20%, transparent 75%);
}

.final__title {
  position: relative;
  margin-bottom: 32px;
  color: var(--background);
  font-size: clamp(32px, 5.6vw, 60px);
  font-weight: 740;
  letter-spacing: -0.04em;
}

.final .btn {
  position: relative;
}

.footer {
  padding: 32px 0 40px;
  border-top: 1px solid var(--border);
  color: var(--muted-foreground);
  font-size: 14px;
}

.footer__in {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.footer a:not(.logo) {
  text-decoration: none;
}

.footer a:not(.logo):hover {
  color: var(--ink);
  text-decoration: underline;
}

/* ——— Планшет ——— */

@media (min-width: 640px) {
  :root {
    --gutter: 28px;
  }

  .hero {
    padding: 56px 0 104px;
  }

  .apptop__crumb {
    display: inline;
  }

  .doc__body {
    padding: 32px 32px 40px 80px;
  }

  .line__gutter {
    left: -60px;
  }

  .line__gutter svg:first-child {
    display: block;
  }

  .tile {
    padding: 28px;
  }

  .panel {
    padding: 18px;
  }

  .kpis {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .kpis div {
    border-width: 0 1px 0 0;
  }

  .kpis div:last-child {
    border-width: 0;
  }

  .funnel__head,
  .funnel__row {
    grid-template-columns: minmax(0, 15em) 1fr 6.6em 5.8em;
    white-space: nowrap;
  }

  .funnel__row span:first-child {
    grid-column: auto;
  }

  .funnel__head span:nth-child(2),
  .funnel__head span:last-child,
  .funnel__row i {
    display: block;
  }

  .funnel__head span:last-child {
    text-align: right;
  }

  .bento,
  .uses {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* На двух колонках широкие только воронка и подключения: иначе рядом с записью
     на время остаётся дыра. */
  .tile--insights,
  .tile--integrations {
    grid-column: span 2;
  }

  .section {
    padding: 112px 0;
  }

  .final {
    padding-bottom: 112px;
  }

  .final__panel {
    padding: 96px 32px;
  }

  .footer__links {
    margin-left: auto;
  }
}

@media (min-width: 900px) {
  .flow__step {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 56px;
  }

  /* Зигзаг: у второго шага картинка слева. */
  .flow__step:nth-child(even) .flow__text {
    order: 2;
  }

  .flow__visual {
    padding: 40px 32px;
  }

  .mtable span:nth-child(3) {
    display: block;
  }

  .mtable > div {
    grid-template-columns: 7.5em minmax(0, 1fr) minmax(0, 1.2fr);
  }

  .resp {
    grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
    gap: 72px;
  }

  .facts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 28px;
  }
}

@media (min-width: 700px) {
  .ai-sec .win__main {
    display: block;
  }

  .ai-sec .drawer {
    width: 280px;
    border-left: 1px solid var(--border);
  }
}

@media (min-width: 1000px) {
  .ai-sec {
    grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr);
    gap: 56px;
  }

  .ai-sec__visual {
    padding: 40px 32px;
  }
}

/* ——— Десктоп ——— */

@media (min-width: 1000px) {
  .topnav {
    display: flex;
  }


  .bento {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .tile--insights {
    grid-column: span 2;
    grid-row: span 2;
  }

  .tile--booking {
    grid-row: span 2;
  }

  .tile--logic,
  .tile--integrations {
    grid-column: span 2;
  }

  .tile--types,
  .tile--ai {
    grid-column: span 1;
  }

  /* Широкие плитки: текст слева, мини-интерфейс справа. */
  .tile--insights .panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .tile--booking .panel {
    margin-top: auto;
  }

  .uses {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .faq {
    grid-template-columns: 1fr 1.6fr;
    gap: 64px;
    align-items: start;
  }

  .faq .head {
    position: sticky;
    top: 112px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0s !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition: none !important;
  }

  .caret {
    animation: none !important;
  }
}
