/* ══════════════════════════════════════════════════════════════════════════
   Vebstroylab — приложение-портфолио. Стили (версия 7).

   Устройство: оболочка приложения (боковое меню на компьютере; верхняя
   панель и нижние вкладки на телефоне и планшете) + экраны, из которых
   виден один. Заголовки — Geologica, текст — Golos Text. Акцент — индиго
   (--accent и соседи). Тёмная тема — prefers-color-scheme и [data-theme].

   Разделы: 1 токены · 2 база · 3 кнопки, поля, пометки · 4 оболочка ·
   5 экраны · 6 главная и сцена · 7 работы и просмотр демо · 8 функции и
   живые примеры · 9 конструктор · 10 смета · 11 как работаю · 12 вопросы,
   «ещё» · 13 уведомления · 14 планшет · 15 телефон · 16 движение · 17 печать
   ══════════════════════════════════════════════════════════════════════════ */

/* ── 1. Токены ─────────────────────────────────────────────────────────── */
:root {
  --accent:      #3538cd;
  --accent-ink:  #2a2ca8;
  --accent-soft: #eeeffe;
  --accent-hi:   #9ea0ff;   /* акцент на тёмном */
  --accent-glow: #5256f2;   /* кнопка на тёмном */
  --on-accent:   #ffffff;

  --bg:          #f6f6f9;
  --surface:     #ffffff;
  --surface-2:   #f0f0f5;
  --ink:         #10111c;
  --ink-2:       #4a4e60;
  --ink-3:       #6e7285;
  --line:        #e4e4ec;
  --line-strong: #cfd0dc;
  --ok:          #1a7348;
  --ok-soft:     #e3f5eb;

  --night:       #0b0c16;   /* карточка первого экрана, итог */
  --night-card:  #0f1120;

  --shadow-sm: 0 1px 2px rgba(16, 17, 28, .06), 0 1px 3px rgba(16, 17, 28, .04);
  --shadow-md: 0 18px 40px -22px rgba(16, 17, 28, .3);
  --shadow-lg: 0 34px 70px -34px rgba(16, 17, 28, .42);

  --side-w: 264px;
  --bar-h:  56px;
  --tabs-h: 64px;

  --font:   "Golos Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-d: "Geologica", "Golos Text", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --ease:   cubic-bezier(.2, .7, .25, 1);
  --ease-io: cubic-bezier(.65, 0, .35, 1);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --accent: #8d8fff; --accent-ink: #b2b3ff; --accent-soft: #1d1e36; --on-accent: #10111c;
    --bg: #0b0c14; --surface: #13141d; --surface-2: #1a1b27; --ink: #f1f2f6; --ink-2: #a9adbc; --ink-3: #888c9c;
    --line: #262837; --line-strong: #363a4d; --ok: #6fd9a6; --ok-soft: rgba(52, 211, 153, .14);
    --night: #07080f; --night-card: #1a1c35;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4); --shadow-md: 0 18px 40px -22px rgba(0, 0, 0, .8); --shadow-lg: 0 34px 70px -34px rgba(0, 0, 0, .9);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --accent: #8d8fff; --accent-ink: #b2b3ff; --accent-soft: #1d1e36; --on-accent: #10111c;
  --bg: #0b0c14; --surface: #13141d; --surface-2: #1a1b27; --ink: #f1f2f6; --ink-2: #a9adbc; --ink-3: #888c9c;
  --line: #262837; --line-strong: #363a4d; --ok: #6fd9a6; --ok-soft: rgba(52, 211, 153, .14);
  --night: #07080f; --night-card: #1a1c35;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4); --shadow-md: 0 18px 40px -22px rgba(0, 0, 0, .8); --shadow-lg: 0 34px 70px -34px rgba(0, 0, 0, .9);
  color-scheme: dark;
}

/* ── 2. База ───────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--bar-h) + 16px); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font); font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
@supports (overflow-x: clip) { body { overflow-x: clip; } }
h1, h2, h3, h4, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
h1, h2, h3 { overflow-wrap: break-word; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 8px; }
a, button, summary, label, [role="button"] { -webkit-tap-highlight-color: transparent; touch-action: manipulation; }
.nw { white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 200; padding: 10px 16px; border-radius: 10px; background: var(--accent); color: var(--on-accent); font-weight: 600; transition: top .2s; }
.skip-link:focus { top: 12px; }
.ico { width: 22px; height: 22px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ico--theme .sun { opacity: 0; }
:root[data-theme="dark"] .ico--theme .sun { opacity: 1; }
:root[data-theme="dark"] .ico--theme .moon { opacity: 0; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .ico--theme .sun { opacity: 1; }
  :root:not([data-theme="light"]) .ico--theme .moon { opacity: 0; }
}
@supports (text-wrap: balance) { .scr-title, .block__t, .fx__title, .viewer__title { text-wrap: balance; } .scr-sub, .block__sub { text-wrap: pretty; } }

/* Список с галочками */
.ticks li { position: relative; padding-left: 29px; color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.ticks li + li { margin-top: 10px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .12em; width: 19px; height: 19px; border-radius: 50%; background: var(--accent-soft); }
.ticks li::after {
  content: ""; position: absolute; left: 4px; top: calc(.12em + 4px); width: 11px; height: 11px; background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5L19.5 7'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5L19.5 7'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ── 3. Кнопки, поля, пометки ──────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px; border: 1px solid transparent; border-radius: 999px;
  font-weight: 600; font-size: 15.5px; line-height: 1.2; white-space: nowrap; text-align: center; cursor: pointer;
  transition: transform .2s var(--ease), background-color .2s, border-color .2s, color .2s, box-shadow .2s;
}
.btn:active { transform: translateY(1px); }
.btn--sm { min-height: 40px; padding: 8px 16px; font-size: 14.5px; }
.btn--lg { min-height: 54px; padding: 14px 26px; font-size: 16.5px; }
.btn--block { display: flex; width: 100%; }
.btn--primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 12px 26px -14px rgba(53, 56, 205, .8); }
.btn--ghost { background: var(--surface); border-color: var(--line-strong); color: var(--ink); }
.btn--glass { background: rgba(255, 255, 255, .07); border-color: rgba(255, 255, 255, .2); color: #fff; }
.btn--glow { background: var(--accent-glow); color: #fff; box-shadow: 0 16px 32px -14px rgba(82, 86, 242, .95); }
@media (hover: hover) {
  .btn:hover { transform: translateY(-1px); }
  .btn--primary:hover { background: var(--accent-ink); }
  .btn--ghost:hover { border-color: var(--ink-3); }
  .btn--glass:hover { background: rgba(255, 255, 255, .13); border-color: rgba(255, 255, 255, .34); }
  .btn--glow:hover { background: #6164ff; }
}
.btn.is-done { background: #1f8a55; border-color: #1f8a55; color: #fff; box-shadow: none; }

.field {
  display: block; width: 100%; min-height: 48px; padding: 12px 14px;
  border: 1.5px solid var(--line); border-radius: 14px; background: var(--surface); color: var(--ink);
  font-size: 16px; line-height: 1.45; transition: border-color .2s, box-shadow .2s, background-color .2s;
}
.field:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
textarea.field { min-height: 108px; resize: vertical; }
.field.is-on { border-color: var(--accent); background: var(--accent-soft); }
.field--search {
  max-width: 560px; padding-left: 42px;
  background: var(--surface) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a7e8f' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4 4'/%3E%3C/svg%3E") 14px 50% / 18px no-repeat;
}
.lab { display: block; margin: 18px 0 6px; color: var(--ink-2); font-size: 14px; font-weight: 600; }

/* Пометка цены у пункта: «входит», «бесплатно» или «+ 4 000 ₽» */
.badge {
  display: inline-block; padding: 3px 9px; border-radius: 999px;
  background: var(--surface-2); color: var(--ink-2);
  font-style: normal; font-size: 13px; font-weight: 600; line-height: 1.35; white-space: nowrap;
  transition: background-color .25s, color .25s;
}
.badge.is-free { background: #e3f5eb; color: #1a7348; }

/* шаг 1 — тариф */
.tiers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.tier { position: relative; display: block; cursor: pointer; }
.tier input, .chk input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.tier__box {
  position: relative; display: flex; flex-direction: column; height: 100%;
  padding: 16px 16px 15px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--bg);
  transition: border-color .2s, background-color .2s, box-shadow .2s;
}
.tier__box::before {   /* кружок выбора */
  content: ""; position: absolute; right: 14px; top: 16px; width: 20px; height: 20px; border-radius: 50%;
  border: 1.5px solid var(--line-strong); background: var(--surface);
  transition: border-color .2s, box-shadow .2s, background-color .2s;
}
.tier__name { padding-right: 28px; font-size: 16px; font-weight: 600; line-height: 1.3; }
.tier__for { color: var(--ink-3); font-size: 13.5px; line-height: 1.35; }
.tier__price {
  margin-top: auto; padding-top: 14px;
  font-family: var(--font-d); font-size: 24px; font-weight: 700; letter-spacing: -.03em; line-height: 1.1; white-space: nowrap;
}
.tier__price small { margin-right: 1px; color: var(--ink-3); font-size: 14px; font-weight: 500; letter-spacing: 0; }
.tier__term { margin-top: 4px; color: var(--ink-2); font-size: 14px; }
.tier__badge {
  position: absolute; top: -11px; left: 14px; padding: 2px 10px; border-radius: 999px;
  background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 600; line-height: 1.5;
}
.tier input:checked + .tier__box { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent); }
.tier input:checked + .tier__box::before { border-color: var(--accent); background: var(--accent); box-shadow: inset 0 0 0 4.5px var(--surface); }
.tier input:focus-visible + .tier__box { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (hover: hover) { .tier:hover .tier__box { border-color: var(--line-strong); } .tier:hover input:checked + .tier__box { border-color: var(--accent); } }

.tinfo { margin-top: 12px; padding: 16px 18px 14px; border-radius: 16px; background: var(--surface-2); }
.js .tinfo__item:not(.is-on) { display: none; }
.tinfo__item + .tinfo__item { margin-top: 18px; }
.js .tinfo__item + .tinfo__item { margin-top: 0; }
.js .tinfo__item.is-on { animation: tinfo-in .35s var(--ease); }
@keyframes tinfo-in { from { opacity: 0; transform: translateY(-4px); } }
.tinfo__name { color: var(--ink); font-size: 14.5px; font-weight: 600; }
.tinfo__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 26px; margin-top: 10px; }
.tinfo__list li { font-size: 14.5px; }
.ticks.tinfo__list li + li { margin-top: 0; }
.tinfo__eg { display: inline-block; margin-top: 8px; padding: 7px 0; color: var(--accent); font-size: 14.5px; font-weight: 600; }
.tinfo__eg span { display: inline-block; transition: transform .2s var(--ease); }
@media (hover: hover) { .tinfo__eg:hover span { transform: translate(2px, -2px); } }

/* шаг 2 — страницы */
.pages {
  display: grid; grid-template-columns: minmax(0, 1fr) auto 104px; align-items: center; gap: 12px 18px;
  padding: 14px 16px 14px 18px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--bg);
  transition: border-color .2s, background-color .2s;
}
.pages.is-on { border-color: var(--accent); background: var(--accent-soft); }
.pages__main { font-size: 15.5px; font-weight: 600; line-height: 1.35; }
.pages__note { margin-top: 3px; color: var(--ink-3); font-size: 13.5px; line-height: 1.4; }
.pages__ctrl { display: flex; align-items: center; gap: 4px; }
.pages__btn {
  display: grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface);
  font-size: 21px; line-height: 1; cursor: pointer; transition: border-color .2s, opacity .2s;
}
@media (hover: hover) { .pages__btn:not(:disabled):hover { border-color: var(--accent); } }
.pages__btn:disabled { opacity: .38; cursor: default; }
.pages__val { min-width: 34px; font-family: var(--font-d); font-size: 20px; font-weight: 700; text-align: center; }
.pages__sum { justify-self: end; }

/* шаги 3 и 4 — галочки */
.feats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.chk {
  position: relative; display: flex; flex-direction: column;
  border: 1.5px solid var(--line); border-radius: 16px; background: var(--bg);
  transition: border-color .2s, background-color .2s;
}
.chk--wide { grid-column: 1 / -1; }
.chk__lbl { display: block; flex: 1; cursor: pointer; }
.chk__box {
  display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; column-gap: 12px; row-gap: 3px; align-items: start;
  padding: 14px 14px 12px 16px;
}
.chk__try {   /* «Попробовать» — открывает живой пример (раздел 18) */
  align-self: flex-start; display: inline-flex; align-items: center; gap: 7px;
  min-height: 34px; margin: -2px 0 12px 48px; padding: 5px 13px 5px 10px;
  border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); color: var(--ink);
  font-size: 13.5px; font-weight: 600; line-height: 1.2; cursor: pointer; transition: border-color .2s, background-color .2s, color .2s;
}
button.chk__try::before {   /* кружок с «плеем» */
  content: ""; flex: none; width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M6.3 4.8l4.6 3.2-4.6 3.2z' fill='%23fff'/%3E%3C/svg%3E") center / 16px no-repeat;
}
@media (hover: hover) { .chk__try:hover { border-color: var(--accent); color: var(--accent); } }
.chk__box::before {   /* квадратик галочки */
  content: ""; grid-row: 1; grid-column: 1; width: 20px; height: 20px; margin-top: 1px; border-radius: 6px;
  border: 1.5px solid var(--line-strong); background: var(--surface);
  transition: border-color .2s, background-color .2s;
}
.chk__box b { grid-column: 2; grid-row: 1; font-size: 15.5px; font-weight: 600; line-height: 1.35; }
.chk__box .badge { grid-column: 3; grid-row: 1; }
.chk__box small { grid-column: 2 / -1; color: var(--ink-3); font-size: 13.5px; line-height: 1.45; }
.chk__box small a { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.chk.is-on { border-color: var(--accent); background: var(--accent-soft); }
.chk input:checked + .chk__box::before, .chk--core .chk__box::before {
  border-color: var(--accent); background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5L19.5 7'/%3E%3C/svg%3E") center / 13px no-repeat;
}
.chk--core, .chk--core .chk__lbl { cursor: default; }
.chk--core .chk__box::before { opacity: .55; }
.chk input:focus-visible + .chk__box { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (hover: hover) { .chk:hover { border-color: var(--line-strong); } .chk.is-on:hover { border-color: var(--accent); } }

.calc__more {
  display: block; width: 100%; min-height: 96px; padding: 12px 14px; resize: vertical;
  border: 1.5px solid var(--line); border-radius: 16px; background: var(--bg); color: var(--ink);
  font-size: 16px; line-height: 1.5; transition: border-color .2s, background-color .2s;
}
.calc__more:focus { outline: none; border-color: var(--accent); }
.calc__more.is-on { border-color: var(--accent); background: var(--accent-soft); }


/* ── 4. Оболочка приложения ────────────────────────────────────────────── */
.shell { min-height: 100vh; }   /* оболочка; .app — это мини-сайты в живых примерах */
@supports (min-height: 100dvh) { .shell { min-height: 100dvh; } }

.side { display: none; }
.brand { display: flex; align-items: center; gap: 11px; padding: 6px 10px 20px; }
/* Логотип Vebstroylab: знак — белая «V» и мятная точка на индиго (тот же в иконках,
   make-app-icons.py); надпись — vebstroy и плашка lab */
.brand__mark, .doc__mark, .selfapp__mark {
  display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 11px;
  background: linear-gradient(135deg, #5a5ef6, #2f31b8);
  box-shadow: 0 8px 18px -10px rgba(53, 56, 205, .9), inset 0 1px 0 rgba(255, 255, 255, .18);
}
.brand__mark svg, .doc__mark svg, .selfapp__mark svg { width: 100%; height: 100%; }
.brand__mark path, .doc__mark path, .selfapp__mark path { fill: none; stroke: #fff; stroke-width: 4.6; stroke-linecap: round; stroke-linejoin: round; }
.brand__mark circle, .doc__mark circle, .selfapp__mark circle { fill: #7ef0c6; }
.wordmark { display: inline-flex; align-items: baseline; gap: 3px; font-family: var(--font-d); font-weight: 700; letter-spacing: -.03em; }
.wordmark i { padding: 1px 6px 2px; border-radius: 7px; background: var(--accent-soft); color: var(--accent); font-size: .78em; font-style: normal; letter-spacing: 0; line-height: 1.25; }
.brand__text .wordmark { display: flex; font-size: 18px; line-height: 1.2; }
.brand__text small { display: block; color: var(--ink-3); font-size: 12.5px; }
.side__nav { display: grid; gap: 2px; }
.nav-i, .side__btn {
  display: flex; align-items: center; gap: 12px; width: 100%; min-height: 44px; padding: 0 12px;
  border: 0; border-radius: 12px; background: none; color: var(--ink-2);
  font-size: 15px; font-weight: 500; text-align: left; white-space: nowrap; cursor: pointer; transition: background-color .2s, color .2s;
}
.side__btn { font-size: 14.5px; }
.nav-i[aria-current="page"] { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.nav-i[aria-current="page"] .ico { color: var(--accent); }
@media (hover: hover) { .nav-i:hover, .side__btn:hover { background: var(--surface-2); color: var(--ink); } .nav-i[aria-current="page"]:hover { background: var(--accent-soft); } }
.nav-i__n { margin-left: auto; color: var(--ink-3); font-size: 12.5px; font-style: normal; font-weight: 500; }
.nav-i__sum { margin-left: auto; padding: 2px 9px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 12px; font-style: normal; font-weight: 700; white-space: nowrap; }
.side__sep { height: 1px; margin: 10px 12px; background: var(--line); }
.side__foot { display: grid; gap: 2px; margin-top: auto; padding-top: 16px; }
.side__status { display: flex; align-items: flex-start; gap: 9px; margin: 12px 12px 0; color: var(--ink-3); font-size: 12.5px; line-height: 1.4; }
.side__status i, .pill--live i { flex: none; width: 8px; height: 8px; margin-top: 4px; border-radius: 50%; background: #34d399; box-shadow: 0 0 0 0 rgba(52, 211, 153, .6); }

.bar {
  position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 6px;
  height: var(--bar-h); padding: 0 8px 0 12px;
  background: var(--bg); border-bottom: 1px solid transparent; transition: border-color .25s, background-color .25s;
}
@supports (padding: max(0px)) {
  .bar { height: calc(var(--bar-h) + env(safe-area-inset-top)); padding-top: env(safe-area-inset-top); }
}
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .bar { background: rgba(246, 246, 249, .8); -webkit-backdrop-filter: saturate(1.5) blur(16px); backdrop-filter: saturate(1.5) blur(16px); }
  :root[data-theme="dark"] .bar { background: rgba(11, 12, 20, .78); }
  @media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .bar { background: rgba(11, 12, 20, .78); } }
}
.bar.is-stuck { border-bottom-color: var(--line); }
.bar__brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; font-family: var(--font-d); font-size: 17px; letter-spacing: -.02em; }
.bar__brand .brand__mark { width: 32px; height: 32px; border-radius: 10px; }
.bar__title {
  position: absolute; left: 64px; right: 64px; bottom: 0; height: var(--bar-h); display: flex; align-items: center; justify-content: center;
  overflow: hidden; font-weight: 600; font-size: 16px; white-space: nowrap; text-overflow: ellipsis;
  opacity: 0; transform: translateY(6px); transition: opacity .2s, transform .25s var(--ease); pointer-events: none;
}
.bar.is-titled .bar__title { opacity: 1; transform: none; }
.bar.is-nested .bar__brand { display: none; }
.bar.is-titled .bar__brand .wordmark { display: none; }   /* при прокрутке в панели — знак и заголовок экрана */
.bar__btn { display: grid; place-items: center; flex: none; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 12px; background: none; color: var(--ink); cursor: pointer; }
.bar__btn:last-child { margin-left: auto; }
@media (hover: hover) { .bar__btn:hover { background: var(--surface-2); } }

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  height: var(--tabs-h); background: var(--surface); border-top: 1px solid var(--line);
}
@supports (padding: max(0px)) { .tabs { height: calc(var(--tabs-h) + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom); } }
@supports ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .tabs { background: rgba(255, 255, 255, .86); -webkit-backdrop-filter: saturate(1.5) blur(18px); backdrop-filter: saturate(1.5) blur(18px); }
  :root[data-theme="dark"] .tabs { background: rgba(19, 20, 29, .86); }
  @media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tabs { background: rgba(19, 20, 29, .86); } }
}
.tab {
  position: relative; display: grid; justify-items: center; align-content: center; gap: 3px;
  color: var(--ink-3); font-size: 11px; font-weight: 600; letter-spacing: .01em; transition: color .2s;
}
.tab .ico { width: 24px; height: 24px; transition: transform .25s var(--ease); }
.tab[aria-current="page"] { color: var(--accent); }
.tab[aria-current="page"] .ico { transform: translateY(-1px) scale(1.06); }
.tab[aria-current="page"]::before { content: ""; position: absolute; top: -1px; left: 32%; right: 32%; height: 3px; border-radius: 0 0 3px 3px; background: var(--accent); }
.tab__sum {
  position: absolute; top: 4px; left: 50%; margin-left: 5px; padding: 1px 6px; border-radius: 999px;
  background: var(--accent); color: var(--on-accent); font-size: 10px; font-style: normal; font-weight: 700; line-height: 1.5; white-space: nowrap;
  pointer-events: none; /* выступает на соседнюю вкладку — нажатие проходит сквозь */
}

.main { min-width: 0; padding-bottom: calc(var(--tabs-h) + 28px); outline: none; scroll-margin-top: var(--bar-h); }   /* «Перейти к содержимому» не прячет заголовок под панелью */
@supports (padding: max(0px)) { .main { padding-bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 28px); } }
.foot { max-width: 1160px; margin: 0 auto; padding: 8px 16px 0; color: var(--ink-3); font-size: 13px; line-height: 1.6; }
.foot b { color: var(--ink-2); }
.foot p + p { margin-top: 2px; }

@media (min-width: 1024px) {
  .shell { display: grid; grid-template-columns: var(--side-w) minmax(0, 1fr); }
  .side {
    position: sticky; top: 0; display: flex; flex-direction: column; height: 100vh; overflow-y: auto;
    padding: 22px 14px 18px; background: var(--surface); border-right: 1px solid var(--line);
  }
  .bar, .tabs { display: none; }
  .main { padding-bottom: 32px; }
  .foot { padding: 8px 48px 0; }
  html { scroll-padding-top: 16px; }
}

/* ── 5. Экраны ─────────────────────────────────────────────────────────── */
.screen { width: 100%; max-width: 1160px; margin: 0 auto; padding: 18px 16px 28px; }
.scr-head { max-width: 760px; margin-bottom: 24px; }
.scr-title { font-family: var(--font-d); font-size: clamp(30px, 4vw, 44px); font-weight: 700; letter-spacing: -.035em; line-height: 1.08; }
.scr-sub { margin-top: 10px; color: var(--ink-2); font-size: clamp(15.5px, 1.3vw, 17.5px); line-height: 1.55; }
.block { margin-top: clamp(36px, 5vw, 56px); }
.block__head { max-width: 760px; margin-bottom: 18px; }
.block__t { font-family: var(--font-d); font-size: clamp(22px, 2.4vw, 28px); font-weight: 700; letter-spacing: -.025em; line-height: 1.2; }
.block__sub { margin-top: 6px; color: var(--ink-2); font-size: 15.5px; }
.block__head--row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px 24px; max-width: none; }
.block__head--row > div { max-width: 760px; }
.more-link { flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: var(--accent); font-size: 15px; font-weight: 600; white-space: nowrap; }
@media (hover: hover) { .more-link:hover { text-decoration: underline; text-underline-offset: 3px; } }
.block--works { margin-top: clamp(28px, 4vw, 44px); }
.note { max-width: 780px; margin-top: 26px; color: var(--ink-3); font-size: 14px; line-height: 1.6; }
.note b { color: var(--ink-2); }
/* «это портфолио — тоже веб-приложение» под работами */
.selfapp { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 14px 18px; margin-top: 14px; padding: 16px 18px; border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line)); border-radius: 20px; background: linear-gradient(120deg, var(--accent-soft), var(--surface) 70%); }
.selfapp__mark { width: 44px; height: 44px; border-radius: 13px; }
.selfapp__txt { color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.selfapp__txt b { color: var(--ink); }
.selfapp .btn[hidden] { display: none; }
@media (max-width: 680px) { .selfapp { grid-template-columns: auto minmax(0, 1fr); } .selfapp .btn { grid-column: 1 / -1; } }

/* на весь экран: демо или админка поверх приложения, та же вкладка */
.full { position: fixed; inset: 0; z-index: 90; display: grid; grid-template-rows: auto minmax(0, 1fr); background: var(--bg); }
.full__bar { display: flex; align-items: center; gap: 10px; min-height: 54px; padding: 6px 12px; border-bottom: 1px solid var(--line); background: var(--surface); }
@supports (padding: max(0px)) { .full__bar { padding-top: max(6px, env(safe-area-inset-top)); } }
.full__back { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; padding: 0 12px 0 6px; border-radius: 12px; color: var(--accent); font-weight: 600; }
.full__back .ico { width: 22px; height: 22px; }
@media (hover: hover) { .full__back:hover { background: var(--accent-soft); } }
.full__title { flex: 1; min-width: 0; overflow: hidden; font-family: var(--font-d); font-size: 16px; font-weight: 600; white-space: nowrap; text-overflow: ellipsis; text-align: center; }
.full__alt { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--line); border-radius: 999px; font-size: 14px; font-weight: 600; }
.full__frame { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
html.is-full body { overflow: hidden; }
html.is-full .tabs, html.is-full .bar, html.is-full .side, html.is-full #sumbar, html.is-full #toasts { visibility: hidden; }   /* под экраном «на весь экран» — ни фокуса, ни нажатий */

/* финал главной: тёмный блок с двумя кнопками */
.cta { position: relative; isolation: isolate; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 22px 40px; margin-top: clamp(40px, 5vw, 60px); padding: clamp(26px, 4vw, 44px); border: 1px solid rgba(255, 255, 255, .07); border-radius: 28px; background: var(--night); color: #fff; }
.cta::before { content: ""; position: absolute; z-index: -1; left: -12%; top: -70%; width: 62%; height: 180%; background: radial-gradient(closest-side, rgba(82, 86, 242, .5), rgba(82, 86, 242, 0)); pointer-events: none; }
.cta__t { font-family: var(--font-d); font-size: clamp(26px, 3vw, 38px); font-weight: 700; letter-spacing: -.03em; line-height: 1.1; }
.cta__txt p { max-width: 560px; margin-top: 10px; color: rgba(255, 255, 255, .72); font-size: 16px; line-height: 1.6; }
.cta__act { display: flex; flex-wrap: wrap; gap: 10px; }
@media (max-width: 1100px) { .cta { grid-template-columns: minmax(0, 1fr); } }
/* вопросы: список + «коротко» */
.faqwrap { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 24px 44px; align-items: start; }
.side-cta { position: sticky; top: 24px; margin-top: 16px; padding: 24px; border: 1px solid rgba(255, 255, 255, .07); border-radius: 24px; background: var(--night); color: #fff; }
.side-cta__k { color: var(--accent-hi); font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.side-cta__list { display: grid; gap: 12px; margin: 14px 0 20px; padding: 0; list-style: none; color: rgba(255, 255, 255, .7); font-size: 14.5px; line-height: 1.5; }
.side-cta__list b { color: #fff; font-weight: 600; }
.side-cta__note { margin-top: 14px; color: rgba(255, 255, 255, .6); font-size: 13.5px; line-height: 1.5; }
@media (max-width: 1100px) { .faqwrap { grid-template-columns: minmax(0, 1fr); } .side-cta { position: static; margin-top: 28px; } }
/* функции: строка про тариф */
.fnote { max-width: 760px; margin: -4px 0 18px; padding: 12px 16px; border-radius: 14px; background: var(--accent-soft); color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.fnote:empty { display: none; }
.fnote b { color: var(--ink); font-weight: 600; }
[data-screen="more"] .list { max-width: 720px; }
.howto { max-width: 780px; margin-top: 28px; padding: 16px 18px; border-left: 3px solid var(--accent); border-radius: 0 14px 14px 0; background: var(--surface); color: var(--ink-2); font-size: 15px; }
.howto b { color: var(--ink); }
@media (min-width: 681px) { .screen { padding: 28px 28px 40px; } }
@media (min-width: 1024px) { .screen { padding: 40px 48px 48px; } .scr-head { margin-bottom: 30px; } }

/* ── 6. Главная и сцена ────────────────────────────────────────────────── */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, 1fr); gap: 36px 44px; align-items: center;
  padding: clamp(30px, 4vw, 52px); border-radius: 28px; background: var(--night); color: #fff;
}
.hero__bg { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero__grid {
  position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 52px 52px;
  -webkit-mask-image: radial-gradient(ellipse 75% 70% at 70% 40%, #000 25%, transparent 75%);
          mask-image: radial-gradient(ellipse 75% 70% at 70% 40%, #000 25%, transparent 75%);
}
.hero__beam { position: absolute; left: -14%; top: -40%; width: 70%; height: 100%; background: radial-gradient(closest-side, rgba(82, 86, 242, .45), rgba(82, 86, 242, 0)); }
.pill {
  display: inline-flex; align-items: center; gap: 10px; padding: 6px 14px 6px 11px; border-radius: 999px;
  background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .13); color: rgba(255, 255, 255, .86);
  font-size: 13.5px; font-weight: 500; line-height: 1.35;
}
.pill--live i { margin-top: 0; }
.hero__title { margin-top: 22px; font-family: var(--font-d); font-size: clamp(30px, 2.95vw, 45px); font-weight: 700; line-height: 1.04; letter-spacing: -.035em; }
.hero__what { display: block; }
.hero__rot { display: inline-grid; color: var(--accent-hi); }
.hero__rot__w { grid-area: 1 / 1; opacity: 0; transform: translateY(.38em); transition: opacity .2s ease, transform .3s var(--ease); }
.hero__rot__w.is-on { opacity: 1; transform: none; transition: opacity .4s ease .1s, transform .55s var(--ease) .1s; }
.hero__rot__w.is-out { opacity: 0; transform: translateY(-.38em); }
.hero__sub { max-width: 34em; margin-top: 18px; color: rgba(255, 255, 255, .72); font-size: clamp(15.5px, 1.25vw, 17.5px); line-height: 1.6; }
.hero__act { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }

/* Сцена: окно + телефон + вкладки */
.stage { position: relative; padding-right: 34px; --pw: 25%; }
.stage__glow {   /* свет в цвет текущего сайта: выходит из-за окна */
  position: absolute; z-index: 0; left: -10%; right: -6%; top: -14%; bottom: -6%;
  border-radius: 50%; background-color: #c2557a; opacity: .42;
  filter: blur(90px); transition: background-color 1.2s ease;
}
.stage__win {
  position: relative; z-index: 1; display: block;
  border-radius: 14px; overflow: hidden; background: #fff;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .1), 0 46px 90px -34px rgba(0, 0, 0, .85);
}
.stage__bar { display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; background: #ecebe7; border-bottom: 1px solid #dddad3; }
.stage__bar i { flex: none; width: 9px; height: 9px; border-radius: 50%; background: #cbc7bf; }
.stage__url {
  flex: 1 1 auto; min-width: 0; max-width: 300px; height: 21px; margin-left: 10px; padding: 0 10px;
  border-radius: 6px; background: #fff; color: #676b76;
  font-size: 11.5px; line-height: 21px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.stage__screen { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: #fff; --end: -66.667%; }   /* экран 16:10, снимок 960×1800: дно снимка встаёт на дно экрана */
.stage__slide { position: absolute; inset: 0; opacity: 0; transition: opacity .8s ease; }
.stage__slide.is-on { opacity: 1; z-index: 1; }
.stage__page { display: block; width: 100%; height: auto; }
.stage__slide.is-on .stage__page { animation: stage-scroll var(--dur, 7.5s) var(--ease-io) both; }
@keyframes stage-scroll {
  0%, 12% { transform: translateY(0); }
  88%, 100% { transform: translateY(var(--end, 0px)); }
}
.stage__phone {
  position: absolute; z-index: 2; right: 0; bottom: 40px; width: var(--pw);
  padding: 6px; border-radius: 26px; background: #16171d;
  box-shadow: inset 0 0 0 1.5px #3b3e48, 0 34px 60px -22px rgba(0, 0, 0, .9);
}
.stage__phone::before {   /* кнопка на ребре */
  content: ""; position: absolute; right: -2px; top: 26%; width: 2px; height: 11%;
  border-radius: 0 2px 2px 0; background: #3b3e48;
}
.stage__notch {
  position: absolute; z-index: 3; left: 50%; top: 6px; width: 34%; height: 11px;
  transform: translateX(-50%); border-radius: 0 0 9px 9px; background: #16171d;
}
.stage__pscreen { position: relative; display: block; aspect-ratio: 390 / 800; overflow: hidden; border-radius: 20px; background: #fff; --end: -57.9%; }   /* снимок 390×1900 */
.stage__tabs {
  position: relative; z-index: 2; display: flex; gap: 8px;
  max-width: calc(100% - var(--pw) + 12px); margin-top: 24px;   /* до телефона остаётся ~13px */
}
.stage__tab {
  flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 9px;   /* по тексту: «Кофейня» не режется */
  padding: 8px 2px 10px; border: 0; background: none;
  color: rgba(255, 255, 255, .5); font-size: 14px; font-weight: 500; text-align: left;
  cursor: pointer; transition: color .3s;
}
.stage__tab span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stage__tab i { position: relative; display: block; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.stage__tab i::after { content: ""; position: absolute; inset: 0; background: #fff; transform: scaleX(0); transform-origin: left; }
.stage__tab.is-on { color: #fff; }
.stage__tab.is-on i::after { animation: tab-fill var(--dur, 7.5s) linear forwards; }
@keyframes tab-fill { to { transform: scaleX(1); } }
@media (hover: hover) { .stage__tab:hover { color: rgba(255, 255, 255, .85); } }
.stage.is-paused .stage__tab.is-on i::after,
.stage.is-paused .stage__slide.is-on .stage__page { animation-play-state: paused; }
.stage.is-static .stage__tab.is-on i::after { animation: none; transform: scaleX(1); }
.stage.is-static .stage__slide.is-on .stage__page { animation: none; }

/* Появление сцены */
.js .stage__win { animation: win-in 1s var(--ease) .15s both; }
.js .stage__phone { animation: phone-in 1.1s var(--ease) .5s both; }
.js .stage__glow { animation: glow-in 1.6s ease .2s both; }
@keyframes win-in { from { opacity: 0; transform: translateY(34px) scale(.97); } }
@keyframes phone-in { from { opacity: 0; transform: translate(40px, 26px) rotate(7deg); } }
@keyframes glow-in { from { opacity: 0; } }


.pstrip { display: none; }

.resume {
  display: flex; align-items: center; gap: 14px; margin-top: 14px; padding: 14px 16px;
  border: 1px solid color-mix(in srgb, var(--accent) 40%, var(--line)); border-radius: 20px; background: var(--accent-soft);
  animation: rise .45s var(--ease) backwards; transition: transform .2s var(--ease);
}
.resume__ico { display: grid; place-items: center; flex: none; width: 44px; height: 44px; border-radius: 14px; background: var(--accent); color: var(--on-accent); }
.resume__txt { display: grid; min-width: 0; }
.resume__txt small { color: var(--ink-3); font-size: 12.5px; }
.resume__txt b { font-family: var(--font-d); font-size: 20px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; }
.resume__txt span { color: var(--ink-2); font-size: 13.5px; }
.resume__go { display: inline-flex; align-items: center; gap: 2px; margin-left: auto; color: var(--accent); font-weight: 600; white-space: nowrap; }
.resume__go .ico { width: 18px; height: 18px; }
@media (hover: hover) { .resume:hover { transform: translateY(-2px); } }


.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 20px; background: var(--surface); }
.facts li { display: grid; gap: 1px; padding: 15px 18px; }
.facts li + li { border-left: 1px solid var(--line); }
.facts b { font-family: var(--font-d); font-size: 19px; font-weight: 700; letter-spacing: -.02em; }
.facts span { color: var(--ink-3); font-size: 13.5px; }

/* живые функции на главной: плитки-ссылки, на телефоне — лента вбок */
.hfx { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.hfx__i { display: flex; flex-direction: column; gap: 3px; min-height: 76px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); transition: border-color .2s, transform .2s var(--ease); }
.hfx__i b { font-size: 15.5px; font-weight: 650; }
.hfx__i span { color: var(--ink-3); font-size: 13.5px; }
.hfx__i--all { border-color: transparent; background: var(--accent-soft); }
.hfx__i--all b, .hfx__i--all span { color: var(--accent); }
@media (hover: hover) { .hfx__i:hover { border-color: var(--accent); transform: translateY(-2px); } }
.aud { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.aud__i {
  position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); grid-template-rows: auto 1fr auto; column-gap: 14px;
  padding: 18px 18px 16px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface);
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.aud__ico { grid-row: 1 / span 3; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); }
.aud__i b { align-self: center; font-family: var(--font-d); font-size: 16.5px; font-weight: 600; letter-spacing: -.015em; line-height: 1.3; }
.aud__i span { margin-top: 4px; color: var(--ink-2); font-size: 14px; line-height: 1.5; }
.aud__i em { margin-top: 10px; color: var(--accent); font-size: 14px; font-style: normal; font-weight: 600; }
.aud__i em::after { content: " →"; }
.aud__i.is-match { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), var(--shadow-md); }
.aud__i.is-match::after {
  content: "Это про вас"; position: absolute; top: -10px; right: 14px; padding: 2px 10px; border-radius: 999px;
  background: var(--accent); color: var(--on-accent); font-size: 12px; font-weight: 600;
}
@media (hover: hover) { .aud__i:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--line-strong); } }

/* ── 7. Работы и просмотр демо ─────────────────────────────────────────── */
.works { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.work {
  display: flex; flex-direction: column; overflow: hidden;
  border: 1px solid var(--line); border-radius: 24px; background: var(--surface);
  transition: transform .3s var(--ease), box-shadow .3s, border-color .3s;
}
.work__pic {
  position: relative; display: block; padding: 20px 20px 0; border-bottom: 1px solid var(--line);
  background: var(--surface-2);
  background: linear-gradient(160deg, color-mix(in srgb, var(--mock) 24%, var(--surface)), color-mix(in srgb, var(--mock) 6%, var(--surface)));
}
.work__shot { display: block; width: 100%; height: 230px; object-fit: cover; object-position: top; border-radius: 12px 12px 0 0; background: #fff; box-shadow: 0 22px 44px -26px rgba(0, 0, 0, .5); }
.work__phone {
  position: absolute; right: 28px; bottom: 12px; height: 76%; aspect-ratio: 1 / 2; padding: 4px;
  border-radius: 17px; background: #16171d; box-shadow: inset 0 0 0 1.5px #3b3e48, 0 22px 38px -16px rgba(0, 0, 0, .55);
  transition: transform .35s var(--ease);
}
.work__phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: 13px; background: #fff; }
.work__demo { position: absolute; top: 12px; right: 12px; padding: 3px 10px; border-radius: 999px; background: rgba(16, 17, 28, .82); color: #fff; font-size: 12px; font-weight: 600; }
.work__body { display: flex; flex: 1; flex-direction: column; gap: 4px; padding: 18px 20px; }
.work__tag { color: var(--ink-3); font-size: 13px; font-weight: 500; }
.work__title { font-family: var(--font-d); font-size: 21px; font-weight: 600; letter-spacing: -.02em; }
.work__text { flex: 1; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.work__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.work__price { font-family: var(--font-d); font-size: 17px; font-style: normal; font-weight: 700; white-space: nowrap; }
.work__price::before { content: "цена — "; color: var(--ink-3); font-family: var(--font); font-size: 13.5px; font-weight: 500; }
.work__go { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-weight: 600; }
.work__go::after { content: "→"; transition: transform .2s var(--ease); }
@media (hover: hover) {
  .work:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--line-strong); }
  .work:hover .work__phone { transform: translateY(-6px); }
  .work:hover .work__go::after { transform: translateX(3px); }
}

/* Примеры расчётов: чеки с цветной кромкой в цвет демо */
.examples { margin-top: clamp(56px, 7vw, 84px); }
.examples__head { max-width: 760px; margin-bottom: 24px; }
.examples__title { font-family: var(--font-d); font-size: clamp(25px, 2.6vw, 32px); font-weight: 700; letter-spacing: -.03em; line-height: 1.15; }
.examples__sub { margin-top: 8px; color: var(--ink-2); font-size: 16px; }
.examples__swipe { display: none; color: var(--ink-3); font-size: 13.5px; }
.exs { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 16px; }
.ex {
  position: relative; grid-column: span 2; display: flex; flex-direction: column; overflow: hidden;
  padding: 24px 22px 18px; border: 1px solid var(--line); border-radius: var(--r-lg); background: var(--surface);
  transition: transform .3s var(--ease), box-shadow .3s;
}
.ex:nth-child(n+4) { grid-column: span 3; }
.ex::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; background: var(--mock, var(--accent)); }
@media (hover: hover) { .ex:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); } }
.ex__tag { color: var(--ink-3); font-size: 13px; font-weight: 500; }
.ex__name { margin-top: 4px; font-family: var(--font-d); font-size: 19.5px; font-weight: 600; letter-spacing: -.02em; }
.ex__desc { margin-top: 6px; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.ex__lines { flex: 1; display: grid; align-content: start; gap: 7px; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line-strong); font-size: 14.5px; line-height: 1.4; }
.ex__lines li { display: flex; justify-content: space-between; gap: 12px; color: var(--ink-2); }
.ex__lines b { flex: none; color: var(--ink); font-weight: 600; white-space: nowrap; }
.ex__lines b.is-free { color: #1a7348; font-weight: 500; }
.ex__total { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.ex__total span { color: var(--ink-3); font-size: 14px; }
.ex__total b { font-family: var(--font-d); font-size: 23px; font-weight: 700; letter-spacing: -.03em; white-space: nowrap; }
.ex__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; margin-top: 16px; }
.ex__open { padding: 8px 0; color: var(--accent); font-size: 14.5px; font-weight: 600; }
.ex__open span { display: inline-block; transition: transform .2s var(--ease); }
@media (hover: hover) { .ex__open:hover span { transform: translate(2px, -2px); } }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .badge.is-free { background: rgba(52, 211, 153, .14); color: #6fd9a6; }
  :root:not([data-theme="light"]) .ex__lines b.is-free { color: #6fd9a6; }
}
:root[data-theme="dark"] .badge.is-free { background: rgba(52, 211, 153, .14); color: #6fd9a6; }
:root[data-theme="dark"] .ex__lines b.is-free { color: #6fd9a6; }


.screen--viewer { max-width: 1360px; }
.viewer { display: grid; grid-template-columns: minmax(0, 1fr) 320px; grid-template-areas: "head head" "stage info"; gap: 18px 28px; align-items: start; }
.viewer__head { grid-area: head; display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 16px; }
.viewer__tag { color: var(--ink-3); font-size: 13.5px; font-weight: 500; }
.viewer__title { margin-top: 2px; font-family: var(--font-d); font-size: clamp(26px, 3vw, 36px); font-weight: 700; letter-spacing: -.03em; line-height: 1.1; }
.viewer__tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.seg { display: inline-flex; gap: 2px; padding: 4px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface-2); }
.seg__i { min-height: 38px; padding: 0 16px; border: 0; border-radius: 10px; background: none; color: var(--ink-2); font-size: 14px; font-weight: 600; cursor: pointer; transition: background-color .2s, color .2s, box-shadow .2s; }
.seg__i.is-on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.viewer__stage {
  --mock: var(--accent);
  grid-area: stage; position: relative; display: flex; justify-content: center; align-items: flex-start;
  padding: 28px 20px; overflow: hidden; border: 1px solid var(--line); border-radius: 26px;
  background: radial-gradient(ellipse at 50% 20%, color-mix(in srgb, var(--mock) 20%, var(--surface-2)), var(--surface-2) 70%);
}
.device { position: relative; flex: none; transform-origin: top center; background: #16171d; box-shadow: inset 0 0 0 1.5px #3b3e48, 0 40px 80px -30px rgba(0, 0, 0, .55); }
.device__screen { position: relative; overflow: hidden; background: #fff; }
.device__screen iframe { display: block; width: 100%; height: 100%; border: 0; background: #fff; }
[data-device="phone"] .device { padding: 10px; border-radius: 48px; }
[data-device="phone"] .device__screen { width: 390px; height: 800px; border-radius: 38px; }
[data-device="desktop"] .device { padding: 34px 0 0; border-radius: 14px; background: #e9e8e4 radial-gradient(circle at 18px 17px, #ff6058 5px, transparent 5.5px) no-repeat, radial-gradient(circle at 38px 17px, #ffbd2e 5px, transparent 5.5px) no-repeat; }
[data-device="desktop"] .device::after { content: ""; position: absolute; left: 60px; right: 60px; top: 9px; height: 16px; border-radius: 6px; background: #fff; }
[data-device="desktop"] .device__screen { width: 1280px; height: 800px; border-radius: 0 0 14px 14px; }
.viewer__load { position: absolute; left: 0; right: 0; bottom: 12px; color: var(--ink-3); font-size: 13px; text-align: center; }
.viewer__full { display: none; }
.viewer__info { grid-area: info; position: sticky; top: 24px; display: grid; gap: 16px; }
.viewer__h { font-family: var(--font-d); font-size: 17px; font-weight: 600; letter-spacing: -.01em; }
.viewer__info > .viewer__h { margin-bottom: -4px; }
.viewer__receipt { display: grid; gap: 10px; padding: 18px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); }
.viewer__receipt .ex__lines { margin-top: 0; }
.viewer__receipt .ex__total { margin-bottom: 4px; }
.viewer__note { color: var(--ink-3); font-size: 13px; line-height: 1.5; }

/* ── 8. Функции и живые примеры ────────────────────────────────────────── */
.fgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 12px; }
.fcard {
  position: relative; display: grid; grid-template-columns: 46px minmax(0, 1fr); grid-template-rows: auto 1fr auto; column-gap: 14px;
  padding: 18px 18px 16px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface);
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s, background-color .25s;
}
.fcard__ico { grid-row: 1 / span 3; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: var(--accent-soft); color: var(--accent); }
.fcard b { align-self: center; padding-right: 22px; font-family: var(--font-d); font-size: 16.5px; font-weight: 600; letter-spacing: -.015em; line-height: 1.3; }
.fcard span { margin-top: 3px; color: var(--ink-2); font-size: 14px; line-height: 1.45; }
.fcard .badge { justify-self: start; margin-top: 12px; }
.fcard.is-on { border-color: var(--accent); background: var(--accent-soft); }
.fcard.is-on::after {
  content: ""; position: absolute; top: 14px; right: 14px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 13px no-repeat;
}
.fcard--ext b::after { content: " ↗"; color: var(--ink-3); font-weight: 500; }
@media (hover: hover) { .fcard:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--line-strong); } .fcard.is-on:hover { border-color: var(--accent); } }

.screen--feature { max-width: 1120px; }
.fx { display: grid; grid-template-columns: minmax(0, 1fr) 332px; grid-template-areas: "head stage" "about stage" "foot stage"; grid-template-rows: auto auto 1fr; gap: 0 48px; }   /* кнопки — сразу под текстом, без дыры */
.fx__head { grid-area: head; }
.fx__k { color: var(--accent); font-size: 12.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.fx__title { margin-top: 8px; font-family: var(--font-d); font-size: clamp(28px, 3.4vw, 40px); font-weight: 700; letter-spacing: -.035em; line-height: 1.08; }
.fx__price { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin-top: 12px; color: var(--ink-3); font-size: 14px; }
.fx__about { grid-area: about; margin-top: 18px; }
.fxd__about > p:first-child { color: var(--ink-2); font-size: 17px; line-height: 1.6; }
.fxd__about .ticks { margin-top: 18px; }
.fxd__for { margin-top: 16px; color: var(--ink-2); font-size: 14.5px; line-height: 1.55; }
.fxd__for b { color: var(--ink); font-weight: 600; }
.fxd__where { margin-top: 10px; color: var(--ink-3); font-size: 14.5px; }
.fxd__where a { color: var(--accent); font-weight: 600; }
.fxd__qr { display: flex; align-items: center; gap: 16px; margin-top: 18px; padding: 14px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); }
.fxd__qr .qr { flex: none; width: 116px; border-radius: 8px; }
.fxd__qr p { color: var(--ink-2); font-size: 14px; line-height: 1.5; }
.fx__stage { grid-area: stage; align-self: start; }
.fx__phone {
  position: relative; width: 312px; margin: 0 auto; padding: 10px; border-radius: 42px; background: #16171d;
  box-shadow: inset 0 0 0 1.5px #3b3e48, 0 30px 60px -24px rgba(0, 0, 0, .55);
}
.fx__phone::before { content: ""; position: absolute; z-index: 5; left: 50%; top: 10px; width: 92px; height: 20px; transform: translateX(-50%); border-radius: 0 0 14px 14px; background: #16171d; }
.fx__screen {
  position: relative; height: 620px; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain;
  border-radius: 32px; background: #fff; color: #13141a; scrollbar-width: none;
}
.fx__screen::-webkit-scrollbar { display: none; }
@media (max-height: 800px) and (min-width: 681px) { .fx__screen { height: calc(100vh - 170px); min-height: 440px; } }
.fx__cap { max-width: 300px; margin: 12px auto 0; color: var(--ink-3); font-size: 13px; line-height: 1.45; text-align: center; }
.fx__foot { grid-area: foot; align-self: start; display: grid; gap: 14px; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }
.fx__add { justify-self: start; }
.fx__add.is-on { background: var(--surface-2); color: var(--ink); box-shadow: none; border-color: var(--line-strong); }
.fx__nav { display: flex; align-items: center; gap: 8px; }
.fx__arrow, .fx__next {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 14px;
  border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); color: var(--ink); font-size: 14.5px;
  transition: border-color .2s;
}
.fx__arrow { width: 44px; justify-content: center; padding: 0; }
.fx__arrow .ico, .fx__next .ico { width: 18px; height: 18px; }
.fx__next span { color: var(--ink-3); }
.fx__next b { font-weight: 600; }
@media (hover: hover) { .fx__arrow:hover, .fx__next:hover { border-color: var(--ink-3); } }

/* ── Мини-сайты внутри телефона: всегда светлые, как настоящие сайты ── */
.app { --a: #3538cd; min-height: 100%; font-family: var(--font); font-size: 14px; line-height: 1.45; color: #13141a; background: #fff; }
.app button { cursor: pointer; }   /* шрифт и цвет кнопки наследуют из базы (раздел 2); font: inherit здесь перебивал .app__btn */
.app__bar {
  position: sticky; top: 0; z-index: 4; display: flex; align-items: center; gap: 9px;
  height: 58px; padding: 18px 16px 0; background: rgba(255, 255, 255, .94); border-bottom: 1px solid #efece6;
}
.app__logo {
  display: grid; place-items: center; flex: none; width: 26px; height: 26px; border-radius: 8px;
  background: var(--a); color: #fff; font-family: var(--font-d); font-size: 12.5px; font-weight: 700;
}
.app__bar b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 600; }
.app__menu { width: 18px; height: 10px; border-top: 2px solid #13141a; border-bottom: 2px solid #13141a; }
.app__main { padding: 18px 16px 26px; }
.app > .app__main:first-child { padding-top: 42px; }
.app__h { font-family: var(--font-d); font-size: 20px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; }
.app__l { margin: 16px 0 8px; color: #676b76; font-size: 12.5px; font-weight: 600; }
.app__l b { color: #13141a; }
.app__list { display: grid; gap: 7px; }
.app__row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%;
  padding: 10px 12px; border: 1.5px solid #e8e5df; border-radius: 12px; background: #fff; text-align: left;
  transition: border-color .15s, background-color .15s;
}
.app__row span { display: grid; font-weight: 500; }
.app__row small { color: #7a7e88; font-size: 12px; }
.app__row b { flex: none; font-weight: 600; }
.app__row.is-on { border-color: var(--a); background: #fff; box-shadow: inset 0 0 0 1px var(--a); }
.app__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.app__chips button, .app__seg button {
  min-height: 34px; padding: 6px 12px; border: 1.5px solid #e8e5df; border-radius: 999px; background: #fff;
  font-size: 13.5px; font-weight: 500; transition: background-color .15s, border-color .15s, color .15s;
}
.app__chips button.is-on { border-color: var(--a); background: var(--a); color: #fff; }
.app__chips--grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.app__chips--grid button { min-height: 44px; border-radius: 12px; font-size: 16px; font-weight: 600; }
.app__seg { display: flex; gap: 0; padding: 3px; border-radius: 12px; background: #f1efea; }
.app__seg button { flex: 1; min-height: 36px; border: 0; border-radius: 9px; background: none; }
.app__seg button.is-on { background: #fff; color: #13141a; font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.app__days, .app__wd { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 0 16px 2px; }
.app__days::-webkit-scrollbar, .app__wd::-webkit-scrollbar { display: none; }
.app__days button, .app__wd button {
  flex: none; display: grid; justify-items: center; gap: 1px; min-width: 48px; padding-left: 6px; padding-right: 6px; padding: 7px 0 8px;
  border: 1.5px solid #e8e5df; border-radius: 12px; background: #fff;
}
.app__days small, .app__wd small { color: #7a7e88; font-size: 11px; white-space: nowrap; }
.app__days b, .app__wd b { font-size: 16px; font-weight: 600; }
.app__days .is-on, .app__wd .is-on { border-color: var(--a); background: var(--a); color: #fff; }
.app__days .is-on small, .app__wd .is-on small { color: rgba(255, 255, 255, .8); }
.app__wd { margin-top: 12px; }
.app__wd button { min-width: 44px; }
.app__slots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.app__slots button { min-height: 36px; border: 1.5px solid #e8e5df; border-radius: 10px; background: #fff; font-size: 13.5px; font-weight: 500; }
.app__slots button.is-on { border-color: var(--a); background: var(--a); color: #fff; }
.app__slots p { grid-column: 1 / -1; color: #7a7e88; font-size: 13px; }
.app__in {
  display: block; width: 100%; min-height: 44px; margin-top: 12px; padding: 10px 12px;
  border: 1.5px solid #e8e5df; border-radius: 12px; background: #fff; color: #13141a; font-size: 16px;
}
.app__in:focus { outline: none; border-color: var(--a); }
.app__in--search { margin-top: 14px; padding-left: 38px; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a7e88' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='6.5'/%3E%3Cpath d='M16 16l4 4'/%3E%3C/svg%3E") 12px 50% / 18px no-repeat; }
.app__btn {
  display: block; width: 100%; min-height: 46px; margin-top: 16px; padding: 10px 14px;
  border: 0; border-radius: 12px; background: var(--a); color: #fff !important; font-weight: 600; font-size: 15px;
  transition: opacity .2s, transform .15s;
}
.app__btn:active { transform: translateY(1px); }
.app__btn:disabled { opacity: .45; cursor: default; }
.app__link { display: block; margin: 16px auto 0; padding: 8px 4px; border: 0; background: none; color: var(--a) !important; font-weight: 600; }
.app__done { padding: 36px 18px 26px; text-align: center; animation: fade-in .35s ease both; }
.app__ok {
  display: block; width: 58px; height: 58px; margin: 0 auto 14px; border-radius: 50%;
  background: var(--a) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='2.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 28px no-repeat;
  animation: ok-pop .5s var(--ease) both;
}
@keyframes ok-pop { from { transform: scale(.4); opacity: 0; } }
.app__sum { margin-top: 6px; color: #545865; }
.app__done .app__l { margin-top: 22px; text-align: left; }

/* Сообщение в Telegram — так заявка выглядит у владельца */
.tg { padding: 10px; border-radius: 14px; background: #dfe7ee; text-align: left; }
.tg__head { margin-bottom: 8px; padding-left: 2px; color: #56606b; font-size: 11.5px; font-weight: 600; }
.tg__msg { position: relative; padding: 9px 11px 20px; border-radius: 12px 12px 12px 4px; background: #fff; box-shadow: 0 1px 1px rgba(0, 0, 0, .08); }
.tg__msg p { font-size: 13px; line-height: 1.45; white-space: pre-line; }
.tg__msg p b { font-weight: 700; }
.tg__msg time { position: absolute; right: 10px; bottom: 5px; color: #8b95a0; font-size: 11px; }

.app__range { width: 100%; height: 30px; accent-color: var(--a); }
.app__check { display: flex; align-items: center; gap: 9px; margin-top: 14px; font-size: 14px; cursor: pointer; }
.app__check input { width: 18px; height: 18px; accent-color: var(--a); }
.app__check b { margin-left: auto; font-weight: 600; }
.app__total { display: grid; margin-top: 16px; padding: 14px; border-radius: 14px; background: #f6f4ef; }
.app__total span { color: #676b76; font-size: 12.5px; }
.app__total b { font-family: var(--font-d); font-size: 30px; font-weight: 700; letter-spacing: -.03em; }
.app__total small { color: #7a7e88; font-size: 12px; }
.app__step { display: flex; align-items: center; gap: 10px; }
.app__step button { display: grid; place-items: center; width: 44px; height: 44px; border: 1.5px solid #e8e5df; border-radius: 12px; background: #fff; font-size: 20px; }
.app__step b { min-width: 70px; font-family: var(--font-d); font-size: 26px; font-weight: 700; text-align: center; }
.app__card { margin-top: 18px; padding: 14px 14px 12px; border-radius: 14px; border: 1.5px solid var(--a); background: #fff; animation: fade-in .3s ease both; }
.app__card-k { color: var(--a); font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.app__card-t { margin-top: 4px; font-family: var(--font-d); font-size: 17px; font-weight: 700; line-height: 1.25; }
.app__facts { display: grid; gap: 5px; margin-top: 10px; }
.app__facts li { position: relative; padding-left: 16px; color: #454954; font-size: 13.5px; }
.app__facts li::before { content: ""; position: absolute; left: 2px; top: .55em; width: 6px; height: 6px; border-radius: 50%; background: var(--a); }
.app__card-p { margin-top: 10px; padding-top: 10px; border-top: 1px solid #efece6; font-weight: 600; }
.app__cnt { margin: 14px 0 8px; color: #676b76; font-size: 12.5px; }
.app__sched { display: grid; gap: 7px; }
.app__sched li { display: grid; grid-template-columns: 50px minmax(0, 1fr); gap: 10px; padding: 10px 12px; border-radius: 12px; background: #f6f4ef; animation: fade-in .25s ease both; }
.app__sched b { font-weight: 700; }
.app__sched span { display: grid; font-size: 13px; }
.app__sched small { color: #676b76; font-size: 12px; }
.app__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.app__ph { display: block; padding: 0; border: 0; background: none; text-align: left; animation: fade-in .25s ease both; }
.app__ph img { display: block; width: 100%; height: auto; aspect-ratio: 1; border-radius: 12px; background: #eee8dc; object-fit: cover; }
.app__ph span { display: block; margin-top: 5px; font-size: 12.5px; font-weight: 500; }
.app__lb {
  position: absolute; inset: 0; z-index: 6; display: flex; flex-direction: column; justify-content: center; gap: 12px;
  padding: 56px 14px 24px; background: rgba(15, 12, 8, .94); color: #fff; animation: fade-in .2s ease both;
}
.app__lb[hidden] { display: none; }
.app__lb img { width: 100%; height: auto; border-radius: 12px; }
.app__lb p { min-height: 2.9em; font-size: 13.5px; text-align: center; }
.app__lb-x { position: absolute; right: 12px; top: 44px; width: 40px; height: 40px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .14); color: #fff !important; font-size: 22px; }
.app__lb-nav { display: flex; align-items: center; justify-content: center; gap: 18px; color: rgba(255, 255, 255, .7); font-size: 13px; }
.app__lb-nav button { width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .14); color: #fff !important; font-size: 24px; line-height: 1; }
.app__prog { height: 5px; border-radius: 5px; background: #eceae4; overflow: hidden; }
.app__prog i { display: block; height: 100%; width: 33%; border-radius: 5px; background: var(--a); transition: width .35s var(--ease); }
.app__prog + .app__l { margin-top: 8px; }
[data-q] { animation: fade-in .3s ease both; }
[data-q] .app__h { margin-bottom: 14px; }
.app__err { margin-top: 6px; color: #c0392b; font-size: 12.5px; }
.app__agree { display: flex; gap: 8px; align-items: flex-start; margin-top: 10px; color: #676b76; font-size: 12.5px; line-height: 1.4; cursor: pointer; }
.app__agree input { flex: none; margin-top: 1px; accent-color: var(--a); }
.app__back { margin-top: 12px; padding: 8px 0; border: 0; background: none; color: #676b76 !important; font-size: 13.5px; }
.cert {
  position: relative; display: grid; align-content: start; aspect-ratio: 1.6; margin-top: 14px; padding: 14px 16px; overflow: hidden;
  border-radius: 16px; color: #fff; background: linear-gradient(135deg, #d7839f, #a8406a);
  box-shadow: 0 14px 26px -16px rgba(0, 0, 0, .6); transition: background .4s;
}
.cert::after { content: ""; position: absolute; right: -40px; top: -40px; width: 140px; height: 140px; border-radius: 50%; border: 18px solid rgba(255, 255, 255, .14); }
.cert.is-graphite { background: linear-gradient(135deg, #4a4d57, #17181d); }
.cert.is-sage { background: linear-gradient(135deg, #8fb49d, #4c7a5e); }
.cert__k { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; opacity: .85; }
.cert__sum { margin-top: 6px; font-family: var(--font-d); font-size: 30px; font-weight: 700; letter-spacing: -.02em; }
.cert__to { font-size: 13px; }
.cert__n { margin-top: auto; font-size: 11px; opacity: .8; }
.cert__brand { position: absolute; right: 14px; bottom: 12px; font-size: 11.5px; font-weight: 600; }
.app__dots { display: flex; gap: 10px; }
.app__dots button { width: 36px; height: 36px; padding: 0; border: 3px solid #fff; border-radius: 50%; box-shadow: 0 0 0 1.5px #e0ddd6; }
.app__dots button.is-on { box-shadow: 0 0 0 2.5px #13141a; }
.app__dots [data-skin="rose"] { background: #c2557a; }
.app__dots [data-skin="graphite"] { background: #2b2d34; }
.app__dots [data-skin="sage"] { background: #6d9a7e; }
.app__price { display: grid; gap: 2px; }
.app__price li { display: flex; justify-content: space-between; gap: 12px; padding: 9px 2px; border-bottom: 1px solid #f0ede7; font-size: 13.5px; }
.app__price li.is-sec { margin-top: 10px; padding-bottom: 4px; border: 0; color: var(--a); font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.app__price b { flex: none; font-weight: 600; white-space: nowrap; }
.app__price mark { border-radius: 3px; background: #ffe2a8; color: inherit; }
.app__empty { margin-top: 14px; padding: 12px; border-radius: 12px; background: #f6f4ef; font-size: 13.5px; }
.app__map { margin-top: 12px; overflow: hidden; border-radius: 14px; }
.app__map svg { display: block; width: 100%; height: auto; }
.app__pin { cursor: pointer; transition: opacity .2s; }
.app__pin circle { fill: #fff; stroke: var(--a); stroke-width: 3; transition: fill .2s; }
.app__pin text { fill: var(--a); font: 700 11px var(--font); text-anchor: middle; }
.app__pin.is-on circle { fill: var(--a); }
.app__pin.is-on text { fill: #fff; }
.app__pin.is-off { opacity: .25; }
.app__addr { display: grid; gap: 7px; }
.app__addr li { padding: 10px 12px 10px 38px; position: relative; border: 1.5px solid #e8e5df; border-radius: 12px; cursor: pointer; animation: fade-in .25s ease both; }
.app__addr li.is-on { border-color: var(--a); }
.app__addr i { position: absolute; left: 11px; top: 11px; display: grid; place-items: center; width: 19px; height: 19px; border-radius: 50%; background: var(--a); color: #fff; font-style: normal; font-size: 11px; font-weight: 700; }
.app__addr b { display: block; font-weight: 600; }
.app__addr span { display: block; color: #676b76; font-size: 12.5px; }
.app__addr em { display: block; margin-top: 3px; font-style: normal; font-size: 12.5px; font-weight: 600; color: #1a7348; }
.app__addr em.is-closed { color: #b0402f; }
.logos { display: grid; gap: 8px; margin-top: 14px; }
.logo {
  --c: #3538cd; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 76px; padding: 12px;
  border: 1.5px solid #e8e5df; border-radius: 14px; background: #fff; overflow: hidden;
}
.logo.is-on { border-color: #13141a; box-shadow: inset 0 0 0 1px #13141a; }
.logo__mark { display: grid; place-items: center; flex: none; width: 36px; height: 36px; border-radius: 10px; background: var(--c); color: #fff; font-family: var(--font-d); font-size: 19px; font-weight: 700; }
.logo__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--font-d); font-size: 21px; font-weight: 700; letter-spacing: -.03em; color: #13141a; }
.logo--serif { flex-direction: column; gap: 4px; }
.logo--serif .logo__name { font-family: Georgia, "Times New Roman", serif; font-size: 24px; font-style: italic; font-weight: 400; letter-spacing: 0; color: var(--c); }
.logo__line { width: 42px; height: 2px; background: var(--c); }
.logo__ring { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 50%; border: 2px solid var(--c); color: var(--c); font-family: var(--font-d); font-size: 13px; font-weight: 700; letter-spacing: .02em; }
.logo--round .logo__name { font-family: var(--font); font-size: 15px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.tabmock { display: flex; align-items: center; gap: 8px; max-width: 250px; padding: 9px 10px; border-radius: 10px 10px 0 0; background: #eceae4; border-bottom: 2px solid #fff; font-size: 12.5px; }
.tabmock__ico { display: grid; place-items: center; flex: none; width: 18px; height: 18px; border-radius: 5px; background: #3538cd; color: #fff; font-family: var(--font-d); font-size: 10.5px; font-weight: 700; }
.tabmock__t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tabmock__x { color: #7a7e88; }
.promo { display: grid; grid-template-columns: 1.1fr .9fr; gap: 10px; align-items: end; margin-top: 16px; }
.flyer, .story { display: flex; flex-direction: column; align-items: center; gap: 6px; overflow: hidden; text-align: center; box-shadow: 0 10px 22px -14px rgba(0, 0, 0, .5); }
.flyer { aspect-ratio: 105 / 148; padding: 12px 10px; border-radius: 6px; background: #fff; border: 1px solid #e8e5df; border-top: 6px solid var(--a); }
.story { aspect-ratio: 9 / 16; padding: 14px 8px; border-radius: 12px; background: linear-gradient(170deg, var(--a), #0f3d24); color: #fff; }
.flyer__brand, .story__brand { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: var(--font-d); font-size: 12px; font-weight: 700; }
.flyer__offer { font-family: var(--font-d); font-size: 13.5px; font-weight: 700; line-height: 1.15; }
.story__offer { font-family: var(--font-d); font-size: 12px; font-weight: 700; line-height: 1.15; }
.fxd__qr { display: flex; align-items: center; gap: 16px; margin-top: 20px; padding: 14px; border-radius: 16px; background: var(--surface-2); }
.fxd__qr .qr { flex: none; width: 116px; border-radius: 8px; }
.fxd__qr p { color: var(--ink-2); font-size: 14px; line-height: 1.5; }
.flyer .qr { width: 52%; margin-top: auto; }
.story .qr { width: 70%; margin-top: auto; border-radius: 6px; }
.flyer__cta, .story__cta { font-size: 9.5px; line-height: 1.3; opacity: .8; }
.qr { display: block; height: auto; }


/* ── 9. Конструктор ────────────────────────────────────────────────────── */
.wiz { display: grid; grid-template-columns: minmax(0, 1fr) 340px; grid-template-areas: "steps sum" "form sum"; gap: 14px 28px; align-items: start; }
.wiz__steps { grid-area: steps; display: flex; gap: 4px; padding: 5px; overflow-x: auto; border: 1px solid var(--line); border-radius: 18px; background: var(--surface); scrollbar-width: none; }
.wiz__steps::-webkit-scrollbar { display: none; }
.wiz__steps li { flex: 1 0 auto; }
.wiz__steps button {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; min-height: 44px; padding: 0 12px;
  border: 0; border-radius: 13px; background: none; color: var(--ink-3); font-size: 14px; font-weight: 600; white-space: nowrap; cursor: pointer;
  transition: background-color .2s, color .2s;
}
.wiz__steps i { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--surface-2); color: var(--ink-2); font-size: 12.5px; font-style: normal; font-weight: 700; transition: background-color .2s, color .2s; }
.wiz__steps .is-done i { background: var(--accent-soft); color: var(--accent); }
.wiz__steps .is-on button { background: var(--accent-soft); color: var(--accent-ink); }
.wiz__steps .is-on i { background: var(--accent); color: var(--on-accent); }
@media (hover: hover) { .wiz__steps button:hover { color: var(--ink); } }
.wiz__form { grid-area: form; min-width: 0; padding: 26px; border: 1px solid var(--line); border-radius: 24px; background: var(--surface); }
.wstep { min-width: 0; margin: 0; padding: 0; border: 0; }
.js .wstep:not(.is-on) { display: none; }
.js .wstep.is-on { animation: rise .35s var(--ease) backwards; }
.wstep__t { float: left; width: 100%; margin-bottom: 16px; padding: 0; font-family: var(--font-d); font-size: 22px; font-weight: 700; letter-spacing: -.02em; line-height: 1.2; }
.wstep__t + * { clear: both; }
.wstep__sub { margin: -4px 0 14px; color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.wiz__nav { display: flex; justify-content: space-between; gap: 10px; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--line); }
.wiz__nav .btn { min-width: 130px; }
.wiz__nav .btn[hidden] + .btn { margin-left: auto; }

.sum {
  grid-area: sum; position: sticky; top: 24px; overflow: hidden;
  padding: 24px; border-radius: 24px; background: var(--night-card); color: #fff; box-shadow: var(--shadow-lg);
}
.sum::before { content: ""; position: absolute; right: -30%; top: -40%; width: 90%; height: 90%; background: radial-gradient(closest-side, rgba(82, 86, 242, .45), rgba(82, 86, 242, 0)); pointer-events: none; }
.sum > * { position: relative; }
.sum.is-flash { animation: sum-flash .9s var(--ease); }
@keyframes sum-flash { 30% { box-shadow: 0 0 0 4px var(--accent-hi), var(--shadow-lg); } }
.sum__k { color: rgba(255, 255, 255, .58); font-size: 12.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; }
.sum__total { margin-top: 8px; font-family: var(--font-d); font-size: clamp(38px, 3.6vw, 48px); font-weight: 700; letter-spacing: -.04em; line-height: 1; white-space: nowrap; }
.sum__total span { display: inline-block; }
.sum__total.is-bump span { animation: bump .45s var(--ease); }
@keyframes bump { 40% { transform: translateY(-4px); color: var(--accent-hi); } }
.sum__plus { margin-top: 6px; color: var(--accent-hi); font-size: 15px; font-weight: 600; }
.sum__days { margin-top: 10px; color: rgba(255, 255, 255, .62); font-size: 14.5px; line-height: 1.45; }
.sum__days b { color: #fff; font-weight: 600; }
.sum__lines { display: grid; gap: 8px; margin-top: 16px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .12); font-size: 14px; line-height: 1.4; }
.sum__lines li { display: flex; justify-content: space-between; gap: 12px; color: rgba(255, 255, 255, .74); animation: line-in .35s var(--ease) backwards; }
.sum__lines b { flex: none; color: #fff; font-weight: 600; white-space: nowrap; }
.sum__lines b.is-free { color: #7ee2b0; font-weight: 500; }
.sum__lines b.is-talk { color: var(--accent-hi); font-weight: 500; }
@keyframes line-in { from { opacity: 0; transform: translateX(-6px); } }
.sum__tip { margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: rgba(158, 160, 255, .12); border: 1px solid rgba(158, 160, 255, .3); color: rgba(255, 255, 255, .88); font-size: 13.5px; line-height: 1.5; }
.sum__tip button { display: flex; align-items: center; width: fit-content; min-height: 40px; margin-top: 10px; padding: 0 16px; border: 1px solid rgba(158, 160, 255, .5); border-radius: 999px; background: rgba(158, 160, 255, .16); color: #fff; font-weight: 600; cursor: pointer; }   /* кнопка, а не ссылка в строке: пальцем попадать удобно */
@media (hover: hover) { .sum__tip button:hover { background: rgba(158, 160, 255, .28); } }
.sum__edits { margin: 14px 0 16px; color: rgba(255, 255, 255, .72); font-size: 13.5px; }
.sum .btn + .btn { margin-top: 8px; }
.sum__hint { margin-top: 10px; color: rgba(255, 255, 255, .56); font-size: 12.5px; line-height: 1.5; }
.sum__foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, .1); color: rgba(255, 255, 255, .5); font-size: 12.5px; }
.sum__reset { min-height: 36px; padding: 6px 12px; border: 1px solid rgba(255, 255, 255, .2); border-radius: 999px; background: none; color: rgba(255, 255, 255, .82); font-size: 13px; font-weight: 500; cursor: pointer; }
@media (hover: hover) { .sum__reset:hover { border-color: rgba(255, 255, 255, .42); color: #fff; } }

.sumbar { display: none; }

.incl { padding: 26px; border: 1px solid var(--line); border-radius: 24px; background: var(--surface); }
.incl__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 36px; margin-top: 16px; }
.incl__list li { position: relative; padding-left: 29px; color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.incl__list li::before { content: ""; position: absolute; left: 0; top: .12em; width: 19px; height: 19px; border-radius: 50%; background: var(--accent-soft); }
.incl__list li::after {
  content: ""; position: absolute; left: 4px; top: calc(.12em + 4px); width: 11px; height: 11px; background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5L19.5 7'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12.5l5 5L19.5 7'/%3E%3C/svg%3E") center / contain no-repeat;
}
.incl__list b { color: var(--ink); font-weight: 600; }

/* ── 10. Смета: «лист бумаги», всегда светлый, как в PDF ──────────────── */
.est { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 28px; align-items: start; }
.est__side { position: sticky; top: 24px; }
.est__side .lab { margin-top: 0; }
.est__actions { display: grid; gap: 8px; margin-top: 14px; }
.est__hint { margin-top: 12px; color: var(--ink-3); font-size: 13px; line-height: 1.5; }
.doc {
  min-width: 0; padding: 38px 42px 30px; border: 1px solid #e5e2dc; border-radius: 18px;
  background: #fff; color: #13141a; box-shadow: 0 22px 50px -30px rgba(16, 17, 28, .5);
  font-size: 14px; line-height: 1.5;
}
.doc__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding-bottom: 18px; border-bottom: 2px solid #13141a; }
.doc__brand { display: flex; align-items: center; gap: 10px; }
.doc__mark { width: 34px; height: 34px; border-radius: 10px; box-shadow: none; }
.doc__brand .wordmark { font-size: 16px; }
.doc__brand .wordmark i { background: #eeeffe; color: #3538cd; }
.doc__brand b { display: flex; line-height: 1.2; }
.doc__brand small { display: block; color: #676b76; font-size: 12px; }
.doc__meta { display: grid; justify-items: end; text-align: right; }
.doc__meta b { color: #3538cd; font-size: 12px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.doc__meta span { color: #545865; font-size: 13px; }
.doc__title { margin-top: 22px; font-family: var(--font-d); font-size: 28px; font-weight: 700; letter-spacing: -.03em; line-height: 1.15; }
.doc__lead { margin-top: 6px; color: #545865; font-size: 14.5px; }
.doc__table { width: 100%; margin-top: 20px; border-collapse: collapse; }
.doc__table th, .doc__table td { padding: 9px 0; text-align: left; vertical-align: top; font-weight: 400; }
.doc__table thead th { padding: 0 0 8px; border-bottom: 1px solid #13141a; color: #676b76; font-size: 11.5px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.doc__table thead th + th { text-align: right; }
.doc__table tbody td { border-bottom: 1px solid #e8e5df; font-size: 14.5px; }
.doc__table tbody td:first-child { width: 100%; padding-right: 16px; }
.doc__table tbody td + td { text-align: right; white-space: nowrap; font-weight: 600; }
.doc__table td small { display: block; margin-top: 1px; color: #7a7e88; font-size: 12.5px; }
.doc__table td.is-free { color: #1a7348; font-weight: 500; }
.doc__table td.is-talk { color: #3538cd; font-weight: 500; }
.doc__table tfoot th, .doc__table tfoot td { padding-top: 14px; border-top: 2px solid #13141a; font-family: var(--font-d); font-size: 22px; font-weight: 700; letter-spacing: -.02em; }
.doc__table tfoot td { text-align: right; white-space: nowrap; }
.doc__table tfoot td small { display: block; color: #3538cd; font-family: var(--font); font-size: 13px; font-weight: 600; letter-spacing: 0; }
.doc__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 30px; margin-top: 24px; }
.doc__grid h3, .doc__next h3 { color: #3538cd; font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.doc__grid p { margin-top: 4px; color: #3f434d; font-size: 13.5px; line-height: 1.55; }
.doc__next { margin-top: 22px; padding-top: 18px; border-top: 1px solid #e8e5df; }
.doc__next ol { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 10px; counter-reset: st; }
.doc__next li { position: relative; padding-top: 32px; color: #545865; font-size: 12.5px; line-height: 1.45; counter-increment: st; }
.doc__next li::before { content: counter(st); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid #3538cd; color: #3538cd; font-size: 12px; font-weight: 700; }
.doc__next li b { display: block; color: #13141a; font-size: 13.5px; font-weight: 600; }
.doc__foot { margin-top: 22px; padding-top: 14px; border-top: 1px dashed #d0ccc4; color: #676b76; font-size: 12.5px; }
.doc__url { margin-top: 4px; font-size: 11.5px; word-break: break-all; }

/* ── 11. Как работаю ───────────────────────────────────────────────────── */
.proc { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 36px; align-items: start; }
.steps { position: relative; display: grid; gap: 24px; }
.steps::before { content: ""; position: absolute; left: 21px; top: 22px; bottom: 30px; width: 2px; border-radius: 2px; background: linear-gradient(var(--accent), var(--line)); }
.step { position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; }
.step__n {
  position: relative; z-index: 1; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%;
  background: var(--accent); color: var(--on-accent); font-family: var(--font-d); font-size: 16px; font-weight: 700;
  box-shadow: 0 0 0 5px var(--bg);
}
.step__h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; padding-top: 9px; }
.step__h b { font-family: var(--font-d); font-size: 18px; font-weight: 600; letter-spacing: -.015em; }
.step__h small { color: var(--ink-3); font-size: 13px; }
.step p:not(.step__h) { margin-top: 6px; color: var(--ink-2); font-size: 15.5px; line-height: 1.6; }
.prep { position: sticky; top: 24px; padding: 24px; border: 1px solid var(--line); border-radius: 24px; background: var(--surface); box-shadow: var(--shadow-md); }
.prep__t { font-family: var(--font-d); font-size: 19px; font-weight: 600; letter-spacing: -.02em; }
.prep__sub { margin-top: 4px; color: var(--ink-3); font-size: 14px; }
.prep .ticks { margin-top: 16px; }
.prep__note { margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); color: var(--ink-3); font-size: 13.5px; }
.guar { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.guar__i { position: relative; overflow: hidden; padding: 20px 20px 22px; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); }
.guar__n { position: absolute; right: 14px; top: 6px; color: var(--accent); opacity: .12; font-family: var(--font-d); font-size: 44px; font-weight: 700; letter-spacing: -.04em; }
.guar__i b { display: block; padding-right: 40px; font-family: var(--font-d); font-size: 17px; font-weight: 600; letter-spacing: -.015em; line-height: 1.3; }
.guar__i p { margin-top: 8px; color: var(--ink-2); font-size: 14.5px; line-height: 1.55; }

/* ── 12. Вопросы, «ещё», пустой экран ─────────────────────────────────── */
.faq { margin-top: 16px; border-top: 1px solid var(--line); }
.faq__i { border-bottom: 1px solid var(--line); }
.faq__i summary { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 18px 0; list-style: none; cursor: pointer; font-size: 16.5px; font-weight: 600; line-height: 1.4; }
.faq__i summary::-webkit-details-marker { display: none; }
.faq__i summary::after {
  content: ""; flex: none; width: 28px; height: 28px; border-radius: 50%;
  background: var(--surface-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a7e8f' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 14px no-repeat;
}
.faq__i[open] summary { color: var(--accent); }
.faq__i[open] summary::after { background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a7e8f' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M6 12h12'/%3E%3C/svg%3E") center / 14px no-repeat; }
.faq__a { padding: 0 44px 18px 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.6; }
.faq__a a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.faq__i[open] .faq__a { animation: rise .35s var(--ease) backwards; }
.faq__empty { margin-top: 18px; color: var(--ink-3); }
@media (hover: hover) { .faq__i summary:hover { color: var(--accent); } }
mark.hl { border-radius: 3px; background: #ffe2a8; color: inherit; }

.list { display: grid; overflow: hidden; border: 1px solid var(--line); border-radius: 22px; background: var(--surface); }
.list__i { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 62px; padding: 12px 16px; border: 0; background: none; color: var(--ink); text-align: left; cursor: pointer; }
.list__i + .list__i { border-top: 1px solid var(--line); }
.list__i .ico { color: var(--accent); }
.list__i span { display: grid; min-width: 0; }
.list__i b { font-size: 15.5px; font-weight: 600; }
.list__i small { color: var(--ink-3); font-size: 13px; }
.list__i::after { content: ""; flex: none; width: 8px; height: 8px; margin-left: auto; border-top: 2px solid var(--ink-3); border-right: 2px solid var(--ink-3); transform: rotate(45deg); }
.empty { display: grid; justify-items: start; gap: 12px; max-width: 560px; padding: 40px 0; }
.empty__code { color: var(--accent); font-family: var(--font-d); font-size: 72px; font-weight: 700; letter-spacing: -.05em; line-height: 1; }

/* ── 13. Уведомления ───────────────────────────────────────────────────── */
.toasts { position: fixed; left: 50%; bottom: calc(var(--tabs-h) + 14px); z-index: 120; display: grid; gap: 8px; width: min(440px, calc(100% - 24px)); transform: translateX(-50%); pointer-events: none; }
@supports (padding: max(0px)) { .toasts { bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 14px); } }
.toast {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px 12px 16px; border-radius: 16px;
  background: #10111c; color: #fff; box-shadow: 0 18px 40px -14px rgba(0, 0, 0, .55); font-size: 14.5px; line-height: 1.4;
  pointer-events: auto; animation: toast-in .35s var(--ease) backwards;
}
:root[data-theme="dark"] .toast { background: #2a2c44; }
.toast button { flex: none; margin-left: auto; padding: 6px 10px; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .1); color: #c7c8ff; font-weight: 700; cursor: pointer; }
.toast.is-out { opacity: 0; transform: translateY(8px); transition: opacity .25s, transform .25s; }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px) scale(.98); } }
@media (min-width: 1024px) { .toasts { bottom: 24px; left: calc(50% + var(--side-w) / 2); } }

/* ── 14. Ноутбук и планшет ─────────────────────────────────────────────── */
@media (min-width: 1024px) and (max-width: 1359px) {
  .wiz { grid-template-columns: minmax(0, 1fr) 300px; gap: 14px 22px; }
  .wiz__form { padding: 22px; }
  .tiers { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .tier__box { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 12px; padding: 13px 14px 13px 46px; }
  .tier__box::before { left: 14px; right: auto; top: 50%; margin-top: -10px; }
  .tier__name { grid-column: 1; grid-row: 1; padding-right: 0; font-size: 15.5px; }
  .tier__for { grid-column: 1; grid-row: 2; }
  .tier__price { grid-column: 2; grid-row: 1; margin: 0; padding: 0; font-size: 19px; text-align: right; }
  .tier__term { grid-column: 2; grid-row: 2; margin: 0; font-size: 13px; text-align: right; }
  .tier__badge { left: auto; right: 12px; top: -10px; }
  .tinfo__list { grid-template-columns: minmax(0, 1fr); }
  .pages { grid-template-columns: auto minmax(0, 1fr); gap: 12px; }
  .pages__text { grid-column: 1 / -1; }
  .feats { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .est { grid-template-columns: minmax(0, 1fr); }
  .est__side { position: static; display: grid; grid-template-columns: minmax(0, 1fr); }
  .est__actions { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .doc__next ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1279px) { .aud { grid-template-columns: repeat(2, minmax(0, 1fr)); } .hfx { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1024px) and (max-width: 1199px) {
  .tier__box { grid-template-columns: minmax(0, 1fr); }
  .tier__price { grid-column: 1; grid-row: 3; margin-top: 8px; text-align: left; }
  .tier__term { grid-column: 1; grid-row: 4; text-align: left; }
  .est__actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1180px) {
  .hero { grid-template-columns: minmax(0, 1fr); }
  .stage { width: 100%; max-width: 620px; margin: 0 auto; }
  .viewer { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "stage" "info"; }
  .viewer__info { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .viewer__info > .viewer__h, .viewer__info > .ticks { grid-column: 1; }
  .viewer__receipt { grid-column: 2; grid-row: 1 / span 3; }
}
@media (max-width: 1023px) {
  .wiz { grid-template-columns: minmax(0, 1fr); grid-template-areas: "steps" "form" "sum"; }
  .sum { position: relative; top: auto; }
  .sumbar {
    position: fixed; left: 12px; right: 12px; z-index: 44; max-width: 560px; margin: 0 auto;
    bottom: calc(var(--tabs-h) + 10px);
    display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 16px; border-radius: 18px;
    background: var(--night-card); color: #fff; box-shadow: 0 18px 40px -14px rgba(0, 0, 0, .6);
    transition: opacity .25s, transform .3s var(--ease), visibility .25s;
  }
  @supports (padding: max(0px)) { .sumbar { bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom) + 10px); } }
  .sumbar.is-off { opacity: 0; visibility: hidden; transform: translateY(14px); }
  .sumbar__main { display: grid; flex: 1; min-width: 0; padding: 0; border: 0; background: none; color: #fff; text-align: left; cursor: pointer; }
  .sumbar__main small { color: rgba(255, 255, 255, .66); font-size: 12.5px; }
  .sumbar__main b { font-family: var(--font-d); font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
  .est { grid-template-columns: minmax(0, 1fr); }
  .est__side { position: static; }
  .est__actions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .proc { grid-template-columns: minmax(0, 1fr); }
  .prep { position: static; }
  .guar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aud { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toasts { bottom: calc(var(--tabs-h) + 84px); }
  .exs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ex, .ex:nth-child(n+4) { grid-column: auto; }
  .ex:last-child { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .fx { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "stage" "about" "foot"; }
  .fx__stage { margin-top: 20px; }
  .works { grid-template-columns: minmax(0, 1fr); }
  .viewer__info { grid-template-columns: minmax(0, 1fr); }
  .viewer__receipt { grid-column: auto; grid-row: auto; }
}

/* ── 15. Телефон ───────────────────────────────────────────────────────── */
@media (max-width: 680px) {
  body { font-size: 15.5px; }
  .screen { padding: 14px 14px 24px; }
  .scr-head { margin-bottom: 18px; }
  .scr-title { font-size: 30px; }

  .hero { gap: 0; padding: 24px 18px 20px; border-radius: 24px; }
  .hero__title { margin-top: 18px; font-size: clamp(24px, 7.5vw, 36px); }
  .hero__sub { margin-top: 14px; font-size: 15.5px; }
  .hero__act { margin-top: 22px; }
  .hero__act .btn { flex: 1 1 100%; }
  .stage { display: none; }
  .pstrip { display: block; margin-top: 26px; }
  .pstrip__label { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; color: rgba(255, 255, 255, .8); font-size: 13.5px; font-weight: 500; }
  .pstrip__hint { flex: none; color: rgba(255, 255, 255, .5); font-size: 12.5px; }
  .pstrip__list { display: flex; gap: 12px; margin: 12px -18px 0; padding: 4px 18px 6px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding: 0 18px; scrollbar-width: none; }
  .pstrip__list::-webkit-scrollbar { display: none; }
  .pstrip__list li { flex: none; scroll-snap-align: start; }
  .pstrip__item { display: block; width: 138px; }
  .pstrip__phone { display: block; padding: 5px; border-radius: 22px; background: #16171d; box-shadow: inset 0 0 0 1.5px #3b3e48, 0 20px 34px -18px rgba(0, 0, 0, .8); }
  .pstrip__screen { position: relative; display: block; aspect-ratio: 390 / 760; overflow: hidden; border-radius: 17px; background: #fff; }
  .pstrip__screen img { display: block; width: 100%; height: auto; }
  .pstrip.is-run .pstrip__screen img { animation: pstrip-scroll 16s var(--ease-io) infinite; }
  .pstrip.is-run li:nth-child(2) img { animation-delay: -4s; }
  .pstrip.is-run li:nth-child(3) img { animation-delay: -8s; }
  .pstrip.is-run li:nth-child(4) img { animation-delay: -12s; }
  .pstrip.is-paused .pstrip__screen img { animation-play-state: paused; }
  .pstrip__cap { display: block; margin-top: 9px; color: rgba(255, 255, 255, .56); font-size: 12.5px; line-height: 1.35; }
  .pstrip__cap b { display: block; color: #fff; font-size: 14px; font-weight: 600; }

  .resume { padding: 12px 14px; }
  .resume__txt b { font-size: 18px; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .facts li:nth-child(3) { border-left: 0; }
  .facts li:nth-child(n+3) { border-top: 1px solid var(--line); }
  .facts li { padding: 13px 14px; }
  .facts b { font-size: 17px; }
  .facts span { font-size: 12.5px; }
  .aud { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .cta { padding: 24px 20px; border-radius: 24px; }
  .cta__act .btn { flex: 1 1 100%; }
  .hfx { display: flex; gap: 8px; margin: 0 -14px; padding: 0 14px 4px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
  .hfx::-webkit-scrollbar { display: none; }
  .hfx__i { flex: 0 0 auto; min-width: 150px; scroll-snap-align: start; }
  .block__head--row { display: block; }
  .more-link { margin-top: 2px; }
  .aud__i { padding: 14px 14px 13px; }

  .work__pic { padding: 14px 14px 0; }
  .work__shot { height: 180px; }
  .work__phone { right: 18px; height: 68%; }   /* не наезжает на плашку «демо» */
  .work__body { padding: 14px 16px 16px; }
  .work__title { font-size: 19px; }
  .work__price::before { font-size: 12.5px; }

  .viewer__head { align-items: stretch; flex-direction: column; }
  .viewer__tools { justify-content: space-between; }
  .viewer__stage { padding: 0; border: 0; border-radius: 20px; background: none; }
  /* рамка — как телефон: тёмный корпус и отступ от вкладок портфолио, чтобы меню
     демо (у приложения — свои вкладки) не сливалось с меню портфолио */
  .viewer__stage[data-device="phone"] .device { width: 100%; padding: 7px; border-radius: 30px; background: #16171d; box-shadow: var(--shadow-md); transform: none !important; }
  .viewer__stage[data-device="phone"] .device__screen { width: 100%; height: calc(100vh - var(--bar-h) - var(--tabs-h) - 230px); min-height: 420px; border-radius: 24px; }
  @supports (height: 100dvh) { .viewer__stage[data-device="phone"] .device__screen { height: calc(100dvh - var(--bar-h) - var(--tabs-h) - 230px); } }
  .viewer__stage { flex-direction: column; justify-content: flex-start; align-items: center; }   /* кнопка — под рамкой, а не сбоку */
  .viewer__full { display: flex; margin-top: 12px; }
  .viewer__stage[data-device="desktop"] .viewer__full { display: none; }
  .viewer:has(.viewer__stage[data-device="phone"]) .viewer__tools #demo-open { display: none; }   /* в режиме «телефон» — большая кнопка под рамкой */
  .viewer__load { bottom: auto; top: 40%; }

  .fgrid { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .fcard { padding: 14px 14px 13px; }
  .fx__title { font-size: 27px; }
  .fx__phone { width: 100%; padding: 0; border-radius: 20px; background: none; box-shadow: 0 0 0 1px var(--line); }
  .fx__phone::before { display: none; }
  .fx__screen { height: auto; max-height: none; overflow: visible; border-radius: 20px; }
  .app__bar { position: relative; height: 50px; padding-top: 0; border-radius: 20px 20px 0 0; }
  .app > .app__main:first-child { padding-top: 20px; }
  .app__lb { position: fixed; z-index: 150; padding-top: 70px; }
  .app__lb-x { top: 16px; }
  .fxd__about > p:first-child { font-size: 15.5px; }
  .fx__foot {
    position: sticky; z-index: 5; margin: 18px -14px 0; padding: 10px 14px;
    bottom: var(--tabs-h); background: var(--bg); border-top: 1px solid var(--line);
    grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px;
  }
  @supports (padding: max(0px)) { .fx__foot { bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom)); } }
  .fx__add { justify-self: stretch; min-height: 46px; padding: 10px 14px; font-size: 15px; }
  .fx__next span, .fx__next b { display: none; }
  .fx__next { width: 44px; justify-content: center; padding: 0; }

  .tiers { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .tier__box { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 12px; padding: 13px 14px 13px 46px; }
  .tier__box::before { left: 14px; right: auto; top: 50%; margin-top: -10px; }
  .tier__name { grid-column: 1; grid-row: 1; padding-right: 0; font-size: 15.5px; }
  .tier__for { grid-column: 1; grid-row: 2; }
  .tier__price { grid-column: 2; grid-row: 1; margin: 0; padding: 0; font-size: 19px; text-align: right; }
  .tier__term { grid-column: 2; grid-row: 2; margin: 0; font-size: 13px; text-align: right; }
  .tier__badge { left: auto; right: 12px; top: -10px; }
  .tinfo { padding: 14px 14px 10px; }
  .tinfo__list { grid-template-columns: minmax(0, 1fr); }
  .pages { grid-template-columns: auto minmax(0, 1fr); gap: 12px; padding: 14px; }
  .pages__text { grid-column: 1 / -1; }
  .feats { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .chk__box { padding: 13px 12px 11px 14px; }
  .chk__try { margin-left: 46px; }
  .exs {
    display: flex; align-items: flex-start; gap: 12px; margin: 0 -14px; padding: 4px 14px 14px;
    overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scroll-padding: 0 14px; scrollbar-width: none;
  }
  .exs::-webkit-scrollbar { display: none; }
  .ex, .ex:nth-child(n+4), .ex:last-child { flex: none; width: 84%; max-width: 340px; scroll-snap-align: start; }
  .est { display: flex; flex-direction: column; gap: 0; }
  .est__side { display: contents; }
  .est__side .lab { order: 1; }
  .est__side .field { order: 2; }
  .doc { order: 3; margin-top: 16px; }
  .est__actions { order: 4; margin-top: 16px; }
  .est__hint { order: 5; }
  .wiz__steps { margin: 0 -14px; padding: 5px 14px; border: 0; border-radius: 0; background: none; }
  .wiz__steps li { flex: 0 0 auto; }
  .wiz__steps li.is-on { flex: 1 1 auto; }
  .wiz__steps li:not(.is-on) span { display: none; }   /* на телефоне подпись только у текущего шага — все пять влезают */
  .wiz__steps button { padding: 0 10px; border: 1px solid var(--line); background: var(--surface); }
  .wiz__form { padding: 18px 14px; border-radius: 22px; }
  .wstep__t { font-size: 20px; }
  .wiz__nav .btn { flex: 1 1 0; min-width: 0; }
  .sum { padding: 22px 18px; }
  .incl { padding: 20px 16px; }
  .incl__list { grid-template-columns: minmax(0, 1fr); gap: 10px; }

  .est__actions { grid-template-columns: minmax(0, 1fr); }
  .doc { padding: 22px 16px 18px; border-radius: 14px; }
  .doc__head { flex-direction: column; gap: 10px; }
  .doc__meta { justify-items: start; text-align: left; }
  .doc__title { font-size: 23px; }
  .doc__table tbody td { font-size: 14px; }
  .doc__table tfoot th, .doc__table tfoot td { font-size: 20px; }
  .doc__grid { grid-template-columns: minmax(0, 1fr); }
  .doc__next ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .step { grid-template-columns: 40px minmax(0, 1fr); gap: 12px; }
  .step__n { width: 40px; height: 40px; }
  .steps::before { left: 19px; }
  .step__h b { font-size: 17px; }
  .step p:not(.step__h) { font-size: 15px; }
  .prep { padding: 20px 16px; }
  .guar { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .faq__i summary { padding: 16px 0; font-size: 16px; }
  .faq__a { padding-right: 0; font-size: 15px; }
}
@media (max-width: 400px) {
  .tier__box { grid-template-columns: minmax(0, 1fr); }
  .tier__price { grid-column: 1; grid-row: 3; margin-top: 8px; text-align: left; }
  .tier__term { grid-column: 1; grid-row: 4; text-align: left; }
}
@media (max-width: 380px) {
  .wiz__steps span { display: none; }
  .tier__price { font-size: 17.5px; }
  .chk__box { grid-template-columns: 20px minmax(0, 1fr); }
  .chk__box .badge { grid-column: 2; grid-row: 2; justify-self: start; margin: 2px 0 3px; }
  .chk__box small { grid-row: 3; }
  .chk__try { margin-left: 46px; }
}
@media (max-height: 520px) and (orientation: landscape) {
  .bar { position: relative; }
  .sumbar { display: none; }
  .fx__foot { position: static; }
}

/* ── 16. Движение ──────────────────────────────────────────────────────── */
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@keyframes pstrip-scroll { 0%, 8% { transform: translateY(0); } 46%, 54% { transform: translateY(-60%); } 92%, 100% { transform: translateY(0); } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(52, 211, 153, .55); } 70%, 100% { box-shadow: 0 0 0 9px rgba(52, 211, 153, 0); } }
@keyframes beam { to { transform: translate(22%, 14%) scale(1.12); } }
@keyframes vt-in { from { opacity: 0; transform: translateX(26px); } }
@keyframes vt-in-back { from { opacity: 0; transform: translateX(-26px); } }
@keyframes vt-fade { from { opacity: 0; } }
@keyframes vt-out { to { opacity: 0; } }
@media (prefers-reduced-motion: no-preference) {
  .hero__beam { animation: beam 18s ease-in-out infinite alternate; }
  .side__status i, .pill--live i { animation: pulse 2.4s ease-out infinite; }
  /* переход между экранами: новая страница въезжает (вглубь — справа, назад — слева) */
  html.is-vt .main { view-transition-name: main; }   /* только на время перехода (Router), иначе .main — слой поверх всего */
  ::view-transition-old(main) { animation: vt-out .16s ease both; }
  ::view-transition-new(main) { animation: vt-in .34s var(--ease) both; }
  html[data-nav="back"]::view-transition-new(main) { animation-name: vt-in-back; }
  html[data-nav="tab"]::view-transition-new(main) { animation: vt-fade .26s ease both; }
  .screen.is-enter { animation: vt-in .34s var(--ease) backwards; }
  html[data-nav="back"] .screen.is-enter { animation-name: vt-in-back; }
  html[data-nav="tab"] .screen.is-enter { animation: vt-fade .26s ease backwards; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .stage__slide.is-on .stage__page, .pstrip.is-run .pstrip__screen img { animation: none !important; }
}

/* ── 17. Печать ────────────────────────────────────────────────────────── */
@media print {
  .side, .bar, .tabs, .sumbar, .toasts, .skip-link, .foot { display: none !important; }
  .shell { display: block; }
  .main { padding: 0; }
  /* смета: на лист только документ, A4 без полей браузера (@page ставит script.js на время печати) */
  html.is-print-smeta body { background: #fff !important; }
  html.is-print-smeta .screen:not([data-screen="estimate"]), html.is-print-smeta .scr-head, html.is-print-smeta .est__side { display: none !important; }
  html.is-print-smeta .screen, html.is-print-smeta .est { display: block; max-width: none; margin: 0; padding: 0; }
  html.is-print-smeta .doc { margin: 0; padding: 11mm 14mm; border: 0; border-radius: 0; box-shadow: none; }
  #smeta-doc, #smeta-doc * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .doc__grid section, .doc__next, .doc__table tr, .doc__foot { break-inside: avoid; }
  html.is-print-smeta .doc__head { padding-bottom: 12px; }
  html.is-print-smeta .doc__title { margin-top: 14px; font-size: 25px; }
  html.is-print-smeta .doc__lead { font-size: 13px; }
  html.is-print-smeta .doc__table { margin-top: 12px; }
  html.is-print-smeta .doc__table tbody td { padding: 5px 0; font-size: 13px; }
  html.is-print-smeta .doc--dense .doc__table tbody td { padding: 2px 0; font-size: 12.5px; line-height: 1.35; }
  html.is-print-smeta .doc--dense .doc__grid { margin-top: 10px; }
  html.is-print-smeta .doc__table td small { font-size: 11.5px; }
  html.is-print-smeta .doc__table tfoot th, html.is-print-smeta .doc__table tfoot td { padding-top: 10px; font-size: 20px; }
  html.is-print-smeta .doc__grid { gap: 10px 26px; margin-top: 14px; }
  html.is-print-smeta .doc__grid p { font-size: 12.5px; line-height: 1.45; }
  html.is-print-smeta .doc__next { margin-top: 12px; padding-top: 10px; }
  html.is-print-smeta .doc__next li { padding-top: 28px; font-size: 11.5px; }
  html.is-print-smeta .doc__foot { margin-top: 12px; padding-top: 10px; font-size: 11.5px; }
  .js .wstep:not(.is-on) { display: block; }
}
