/* styles/tokens.css */
/* ═══════════════════════════════════════════════════════════
   Токены. Единственный источник значений для всего проекта.
   Хардкод цветов в компонентах запрещён.
   Обоснования и правила — в BRAND.md
   ═══════════════════════════════════════════════════════════ */

:root {
  /* ── Цвет ──────────────────────────────────────────────── */
  --bg:           #F2F1ED;
  --surface:      #FFFFFF;
  --surface-2:    #EAE8E1;
  --ink:          #161616;
  --ink-muted:    #5A5652;
  --line:         #DCD9D2;
  --line-accent:  #B38F6F;
  --accent:       #710014;
  --accent-hover: #59000F;
  --accent-soft:  #F1E3E5;
  --gold:         #B38F6F;
  --gold-soft:    #EFE8DF;
  --on-accent:    #FFFFFF;
  --focus-ring:   0 0 0 3px rgba(113, 0, 20, .28);
  --scrim:        rgba(22, 22, 22, .38);
  --bg-fade:      rgba(242, 241, 237, 0);

  /* ── Радиусы ───────────────────────────────────────────── */
  --r-sm:   8px;
  --r-md:   16px;
  --r-lg:   24px;
  --r-pill: 999px;

  /* ── Тени ──────────────────────────────────────────────── */
  --sh-1: 0 1px 2px rgba(22, 22, 22, .05);
  --sh-2: 0 10px 28px rgba(22, 22, 22, .08);

  /* ── Шкала отступов. Промежуточных значений нет ────────── */
  --s-1:  4px;
  --s-2:  8px;
  --s-3:  12px;
  --s-4:  16px;
  --s-5:  24px;
  --s-6:  32px;
  --s-7:  48px;
  --s-8:  64px;
  --s-9:  96px;

  /* ── Раскладка ─────────────────────────────────────────── */
  --container: 640px;
  --gutter:    20px;
  --sec-y:     var(--s-5);   /* 24 */

  /* Точные значения из ТЗ, не попадающие в шкалу 4-8-12-16-24-32.
     Держим их именованными токенами, чтобы в компонентах
     не появлялось магических чисел. */
  --card-pad:      20px;   /* внутренний отступ карточки */
  --btn-pad-x:     28px;   /* боковые поля кнопки */
  --gap-title-desc: 6px;   /* h3 → описание */
  --gap-desc-price: 14px;  /* описание → цена */
  --gap-photo-name: 20px;  /* аватар → h1 */
  --gap-phrase-cta: 28px;  /* фраза → кнопка */
  --gap-ico-text:  10px;   /* иконка → текст */

  /* ── Шрифты ────────────────────────────────────────────── */
  --font-display: "Editorial", Georgia, serif;
  --font-text:    "Aeonik Pro", "Manrope", "Helvetica Neue", Arial, sans-serif;

  /* Иерархия: 68 → 44 → 20 → 15. Соседние уровни разведены
     размером, начертанием и цветом одновременно. */
  --fs-h1:    clamp(46px, 11vw, 68px);
  --fs-h2:    clamp(32px, 8vw, 44px);
  --fs-h3:    18px;
  --fs-body:  15px;
  --fs-price: 17px;
  --fs-cur:   13px;
  --fs-small: 13px;
  --fs-label: 11px;

  --lh-h1:   1.02;
  --lh-h2:   1.05;
  --lh-h3:   1.3;
  --lh-body: 1.55;

  --ls-h1:    -0.02em;
  --ls-h2:    -0.015em;
  --ls-h3:    -0.01em;
  --ls-label: 0.14em;

  /* ── Иконки ────────────────────────────────────────────── */
  --ico-card: 20px;
  --ico-list: 18px;

  /* ── Движение ──────────────────────────────────────────── */
  --ease:      cubic-bezier(.22, .61, .36, 1);
  --dur-fast:  200ms;
  --dur-slow:  520ms;
  --stagger:   60ms;
}

@media (min-width: 768px) {
  :root {
    --gutter:   24px;
    --fs-h3:    20px;
    --card-pad: var(--s-5);
  }
}

@media (min-width: 1024px) {
  :root { --sec-y: var(--s-6); }   /* 32 */
}

/* styles/fonts.css */
/* ═══════════════════════════════════════════════════════════
   Шрифты. Самохостинг, файлы в /fonts.

   'Editorial' — одно логическое семейство, разведённое по unicode-range:
   латиница из PP Editorial New, кириллица из Playfair Display.

   ВНИМАНИЕ. Файлов PP Editorial New и Aeonik Pro в проекте нет — это
   коммерческие гарнитуры, скачать их я не могу. Блоки под них лежат
   ниже закомментированными. Пока их нет:
     · латиницу 'Editorial' тоже закрывает Playfair, иначе узбекская
       версия сидела бы на Georgia
     · роль текстового шрифта временно исполняет Manrope, он прописан
       вторым в --font-text, а 'Aeonik Pro' первым — как только файлы
       появятся, подмена произойдёт сама

   Как класть PP Editorial New:
     1) убедиться, что в лицензии есть web-embedding
     2) конвертировать в .woff2 (.otf в вебе не подключаем)
     3) раскомментировать блоки PP ниже
     4) сузить playfair-latin: убрать его @font-face, латиницу заберёт PP
     5) подогнать size-adjust у кириллических блоков по /type-check.html
   ═══════════════════════════════════════════════════════════ */

/* ── Editorial · латиница ───────────────────────────────────
@font-face{
  font-family:"Editorial";
  src:url("/fonts/PPEditorialNew-Regular.woff2") format("woff2");
  font-weight:400; font-style:normal; font-display:swap;
  unicode-range:U+0000-024F, U+2000-206F;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/PPEditorialNew-Medium.woff2") format("woff2");
  font-weight:500; font-style:normal; font-display:swap;
  unicode-range:U+0000-024F, U+2000-206F;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/PPEditorialNew-Italic.woff2") format("woff2");
  font-weight:400; font-style:italic; font-display:swap;
  unicode-range:U+0000-024F, U+2000-206F;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/PPEditorialNew-MediumItalic.woff2") format("woff2");
  font-weight:500; font-style:italic; font-display:swap;
  unicode-range:U+0000-024F, U+2000-206F;
}
──────────────────────────────────────────────────────────── */

/* ── Editorial · латиница, временно на Playfair ───────────
   Диапазоны взяты один в один из подмножеств Google: обещать
   больше, чем есть в файле, нельзя — браузер выберет это
   начертание, не найдёт глиф и уйдёт на Georgia. Так узбекские
   ʻ (U+02BB) и ʼ (U+02BC) теряли шрифт. */
@font-face{
  font-family:"Editorial";
  src:url("/fonts/playfair-latin.woff2") format("woff2");
  font-weight:400 700; font-style:normal; font-display:swap;
  unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/playfair-latin-ext.woff2") format("woff2");
  font-weight:400 700; font-style:normal; font-display:swap;
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/playfair-italic-latin.woff2") format("woff2");
  font-weight:400 700; font-style:italic; font-display:swap;
  unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/playfair-italic-latin-ext.woff2") format("woff2");
  font-weight:400 700; font-style:italic; font-display:swap;
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ── Editorial · кириллица ────────────────────────────────
   size-adjust подгоняется под рост строчных PP Editorial New.
   Пока обе половины — Playfair, поэтому 100%. */
@font-face{
  font-family:"Editorial";
  src:url("/fonts/playfair-cyrillic.woff2") format("woff2");
  font-weight:400 700; font-style:normal; font-display:swap;
  unicode-range:U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
  size-adjust:100%;
}
@font-face{
  font-family:"Editorial";
  src:url("/fonts/playfair-italic-cyrillic.woff2") format("woff2");
  font-weight:400 700; font-style:italic; font-display:swap;
  unicode-range:U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
  size-adjust:100%;
}

/* ── Текстовый шрифт ────────────────────────────────────────
@font-face{
  font-family:"Aeonik Pro";
  src:url("/fonts/AeonikPro-Regular.woff2") format("woff2");
  font-weight:400; font-style:normal; font-display:swap;
}
@font-face{
  font-family:"Aeonik Pro";
  src:url("/fonts/AeonikPro-Medium.woff2") format("woff2");
  font-weight:500; font-style:normal; font-display:swap;
}
──────────────────────────────────────────────────────────── */

/* Временный дублёр текстового шрифта */
@font-face{
  font-family:"Manrope";
  src:url("/fonts/manrope-cyrillic.woff2") format("woff2");
  font-weight:400 700; font-style:normal; font-display:swap;
  unicode-range:U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face{
  font-family:"Manrope";
  src:url("/fonts/manrope-latin-ext.woff2") format("woff2");
  font-weight:400 700; font-style:normal; font-display:swap;
  unicode-range:U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face{
  font-family:"Manrope";
  src:url("/fonts/manrope-latin.woff2") format("woff2");
  font-weight:400 700; font-style:normal; font-display:swap;
  unicode-range:U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* styles/base.css */
/* ═══════════════════════════════════════════════════════════
   База: сброс, типографика, раскладка, кнопки, иконки, движение.

   Правило интервалов: margin у заголовков, абзацев и карточек
   не задаётся вообще. Всё расстояние — gap у родителя.
   ═══════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; }
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  scrollbar-gutter: stable;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--fs-body);
  font-weight: 400;
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; -webkit-tap-highlight-color: transparent; }
img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; border: 0; background: none; cursor: pointer; -webkit-tap-highlight-color: transparent; padding: 0; }

:focus-visible { outline: none; box-shadow: var(--focus-ring); border-radius: var(--r-sm); }

/* ── Иерархия заголовков ─────────────────────────────────── */

/* h1 — имя. Курсивный сериф, самый крупный, --ink */
h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: italic;
  font-size: var(--fs-h1);
  line-height: var(--lh-h1);
  letter-spacing: var(--ls-h1);
  color: var(--ink);
}

/* h2 — заголовок секции. Тот же курсивный сериф, но в 2.2 раза мельче h1 */
h2 {
  font-family: var(--font-display);
  font-weight: 400;
  font-style: italic;
  font-size: var(--fs-h2);
  line-height: var(--lh-h2);
  letter-spacing: var(--ls-h2);
  color: var(--ink);
}

/* h3 — название услуги. Гротеск, прямой, вдвое мельче h2:
   три отличия сразу, поэтому с h2 не сливается */
h3 {
  font-family: var(--font-text);
  font-weight: 500;
  font-style: normal;
  font-size: var(--fs-h3);
  line-height: var(--lh-h3);
  letter-spacing: var(--ls-h3);
  color: var(--ink);
}

/* Микро-лейбл секции: 01 Услуги */
.label {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: var(--fs-label);
  line-height: 1;
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
  color: var(--ink-muted);
}
.label i { font-style: normal; color: var(--accent); font-variant-numeric: tabular-nums; }
.label::before {
  content: "";
  width: 24px;
  height: 1px;
  flex: none;
  background: var(--line-accent);
  order: -1;
}

/* Волосяная линия под заголовком секции */
.hairline { height: 1px; background: var(--line); border: 0; }

.desc { font-size: var(--fs-body); line-height: var(--lh-body); color: var(--ink-muted); }
.fine { font-size: var(--fs-small); line-height: var(--lh-body); color: var(--ink-muted); }

/* Цена */
.price {
  display: flex;
  align-items: baseline;
  gap: var(--s-1);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: var(--fs-price);
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
  white-space: nowrap;
}
.price .cur { font-size: var(--fs-cur); font-weight: 400; color: var(--ink-muted); }

/* ── Раскладка ───────────────────────────────────────────── */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Каждая секция — колонка с явным gap. Одинаковый ритм у всех. */
.section {
  display: flex;
  flex-direction: column;
  padding-block: var(--sec-y);
}
.section > * + * { margin: 0; }

/* Шапка секции: лейбл → 12 → h2 → 16 → линия → 32 → контент */
.head {
  display: flex;
  flex-direction: column;
  gap: var(--s-3);
  padding-block-end: var(--s-4);
}
.head .hairline { margin-block-start: var(--s-1); }

/* ── Иконки ──────────────────────────────────────────────── */

.ico {
  width: var(--ico-list);
  height: var(--ico-list);
  flex: none;
  color: var(--gold);
  /* выравнивание по оптическому центру первой строки, а не по верху блока */
  vertical-align: -0.15em;
}
.ico-card { width: var(--ico-card); height: var(--ico-card); }

/* Квадрат под иконкой в карточке услуги */
.ico-box {
  width: 40px;
  height: 40px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: var(--r-sm);
  background: var(--gold-soft);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  height: 52px;
  padding-inline: var(--btn-pad-x);
  border-radius: var(--r-pill);
  font-family: var(--font-text);
  font-size: var(--fs-body);
  font-weight: 500;
  transition: background-color var(--dur-fast) var(--ease),
              box-shadow var(--dur-fast) var(--ease),
              transform var(--dur-fast) var(--ease);
}
.btn .ico { color: currentColor; }

.btn-primary { background: var(--accent); color: var(--on-accent); box-shadow: var(--sh-1); }
.btn-secondary { background: var(--surface); color: var(--ink); border: 1px solid var(--line); box-shadow: var(--sh-1); }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .6; pointer-events: none; }

@media (hover: hover) {
  .btn-primary:hover { background: var(--accent-hover); box-shadow: var(--sh-2); }
  .btn-secondary:hover { background: var(--gold-soft); box-shadow: var(--sh-2); }
}

/* ── Карточка ────────────────────────────────────────────── */

.card {
  display: flex;
  flex-direction: column;
  padding: var(--card-pad);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-1);
  transition: transform var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}

@media (hover: hover) {
  .card-hover:hover { transform: translateY(-2px); box-shadow: var(--sh-2); }
}

/* ── Появление секций ────────────────────────────────────── */

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity var(--dur-slow) var(--ease), transform var(--dur-slow) var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
}
.reveal.is-in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* styles/sections.css */
/* ═══════════════════════════════════════════════════════════
   Секции.

   Интервалы задаются ТОЛЬКО через gap. Там, где соседние пары
   должны отстоять по-разному, вводится вложенный контейнер со
   своим gap — вместо margin у контента.
   ═══════════════════════════════════════════════════════════ */

/* Расстояние между секциями — один gap на всю страницу,
   поэтому стык секций не может дать двойной отступ. */
.page {
  display: flex;
  flex-direction: column;
  gap: var(--sec-y);
  padding-block-end: var(--s-5);
}

/* ── Переключатель языка ─────────────────────────────────── */
.topbar { display: flex; justify-content: flex-end; padding-block-start: var(--s-4); }
.lang {
  display: inline-flex;
  gap: var(--s-1);
  padding: var(--s-1);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
}
.lang button {
  min-width: 48px;
  min-height: 44px;
  padding-inline: var(--s-3);
  border-radius: var(--r-pill);
  font-family: var(--font-text);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: var(--ls-label);
  color: var(--ink-muted);
  transition: color var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease);
}
.lang button[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent); }

/* ── Шапка ───────────────────────────────────────────────── */
/* Вложенность повторяет заданный ритм:
   фото →20→ имя →8→ роль, группа →24→ чипы, →16→ фраза, →28→ кнопка */
.hero { display: flex; flex-direction: column; align-items: center; gap: var(--gap-phrase-cta); }
.hero-body { display: flex; flex-direction: column; align-items: center; gap: var(--s-4); }
.hero-intro { display: flex; flex-direction: column; align-items: center; gap: var(--s-5); }
.hero-top { display: flex; flex-direction: column; align-items: center; gap: var(--gap-photo-name); }
.hero-id { display: flex; flex-direction: column; align-items: center; gap: var(--s-2); text-align: center; }

.hero-photo {
  width: 112px;
  height: 112px;
  border-radius: var(--r-pill);
  object-fit: cover;
  background: var(--surface-2);
  border: 1px solid var(--line-accent);
}
/* Логотип вместо набранного имени. Размеры заданы заранее,
   поэтому подстановка не двигает вёрстку. */
.hero-logo { width: min(100%, 300px); color: var(--ink); }
.hero-logo img { width: 100%; height: auto; aspect-ratio: 554 / 110; }

.hero-role { color: var(--ink-muted); }
.hero-phrase { max-width: 30ch; text-align: center; color: var(--ink-muted); }
.hero .btn { width: 100%; }

.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: var(--s-2); }
.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-2) var(--s-3);
  border-radius: var(--r-pill);
  background: var(--surface-2);
  font-size: var(--fs-small);
  color: var(--ink);
  white-space: nowrap;
}

/* ── 01. Услуги ──────────────────────────────────────────── */
.services { display: flex; flex-direction: column; gap: var(--s-3); }
.service { flex-direction: row; align-items: flex-start; gap: var(--gap-ico-text); }
.service-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--gap-desc-price); }
.service-title { display: flex; flex-direction: column; gap: var(--gap-title-desc); }

/* ── 02. Выгода ──────────────────────────────────────────── */
.offers { display: flex; flex-direction: column; gap: var(--s-3); }
.offer { gap: var(--s-3); }
.offer-main { display: flex; flex-direction: column; gap: var(--gap-title-desc); }
.offer-badge {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  padding: var(--s-1) var(--s-3);
  border-radius: var(--r-pill);
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--font-text);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
}
.offer-badge .ico { color: var(--accent); }

.stamps { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-2); }
.stamp {
  flex: 1 1 0;
  min-width: 0;
  max-width: 32px;
  aspect-ratio: 1;
  border-radius: var(--r-pill);
  border: 1px solid var(--line-accent);
  display: grid;
  place-items: center;
  font-family: var(--font-text);
  font-size: var(--fs-small);
  font-variant-numeric: tabular-nums;
  color: var(--ink-muted);
}
.stamp-gift { border-color: transparent; background: var(--accent); }
.stamp-gift .ico { color: var(--on-accent); width: 16px; height: 16px; }
.stamps-label { flex-basis: 100%; font-size: var(--fs-small); color: var(--ink-muted); }

/* ── 03. Работы ──────────────────────────────────────────── */
.ba { display: flex; flex-direction: column; gap: var(--s-3); }
.ba-stage {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--surface-2);
  touch-action: pan-y;
  cursor: ew-resize;
  user-select: none;
  -webkit-user-select: none;
  transition: opacity var(--dur-fast) var(--ease);
}
.ba-stage.is-swap { opacity: .5; }
.ba-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; -webkit-user-drag: none; }
.ba-clip { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--x)) 0 0); }

.ba-tag, .ba-hint {
  position: absolute;
  z-index: 2;
  pointer-events: none;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 1px solid var(--line);
  color: var(--ink);
  font-family: var(--font-text);
  white-space: nowrap;
  transition: opacity var(--dur-fast) var(--ease);
}
.ba-tag {
  inset-block-end: var(--s-3);
  padding: var(--s-1) var(--s-3);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
}
.ba-tag-l { inset-inline-start: var(--s-3); }
.ba-tag-r { inset-inline-end: var(--s-3); }
.ba.hide-l .ba-tag-l, .ba.hide-r .ba-tag-r { opacity: 0; }
.ba-hint {
  inset-block-start: var(--s-3);
  inset-inline-start: 50%;
  transform: translateX(-50%);
  padding: var(--s-2) var(--s-3);
  font-size: var(--fs-small);
}
.ba.touched .ba-hint { opacity: 0; }

.ba-handle {
  position: absolute;
  inset-block: 0;
  inset-inline-start: var(--x);
  z-index: 3;
  width: 48px;
  margin-inline-start: -24px;
  display: grid;
  place-items: center;
  cursor: ew-resize;
  outline: none;
}
.ba-handle::before {
  content: "";
  position: absolute;
  inset-block: 0;
  inset-inline-start: 50%;
  width: 2px;
  margin-inline-start: -1px;
  background: var(--surface);
}
.ba-grip {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: var(--r-pill);
  display: grid;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--sh-2);
}
.ba-grip .ico { color: var(--accent); width: var(--ico-card); height: var(--ico-card); }
.ba-handle:focus-visible .ba-grip { box-shadow: var(--focus-ring); }

.ba-cap { text-align: center; color: var(--ink); }
.ba-thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s-3); }
.thumb {
  position: relative;
  aspect-ratio: 1;
  border-radius: var(--r-sm);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-2);
  transition: border-color var(--dur-fast) var(--ease);
}
.thumb img { width: 100%; height: 100%; object-fit: cover; opacity: .6; transition: opacity var(--dur-fast) var(--ease); }
.thumb[aria-pressed="true"] { border-color: var(--accent); }
.thumb[aria-pressed="true"] img { opacity: 1; }
@media (hover: hover) { .thumb:hover img { opacity: 1; } }

/* ── 04. Кабинет ─────────────────────────────────────────── */
.place { gap: var(--s-5); }
.place dl { display: flex; flex-direction: column; gap: var(--s-4); }
.place dl > div { display: flex; gap: var(--gap-ico-text); }
.place-text { display: flex; flex-direction: column; gap: var(--s-1); }
.place dt {
  font-family: var(--font-text);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
  color: var(--ink-muted);
}
.place dd { color: var(--ink); }
.map-frame {
  border-radius: var(--r-sm);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-2);
  line-height: 0;
  aspect-ratio: 16 / 10;
}
.map-frame iframe { display: block; width: 100%; height: 100%; border: 0; }
.maps { display: flex; flex-direction: column; gap: var(--s-3); }
.maps-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-3); }
.maps-row .btn { padding-inline: var(--s-3); font-size: var(--fs-small); }

/* ── 05. Связь ───────────────────────────────────────────── */
.contact { flex-direction: row; align-items: center; gap: var(--gap-ico-text); }
.contact-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--s-1); }
.contact .lbl {
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
  color: var(--ink-muted);
}
.contact .val { font-weight: 500; color: var(--ink); }
.contact .arw { color: var(--ink-muted); }


/* ── Липкая панель ───────────────────────────────────────── */
.dock {
  position: fixed;
  inset-inline: 0;
  inset-block-end: 0;
  z-index: 20;
  display: flex;
  justify-content: center;
  padding: var(--s-3) var(--gutter);
  padding-block-end: calc(var(--s-3) + env(safe-area-inset-bottom));
  background: linear-gradient(to bottom, var(--bg-fade), var(--bg) 45%);
  transform: translateY(130%);
  transition: transform var(--dur-slow) var(--ease);
  pointer-events: none;
}
.dock.is-on { transform: none; pointer-events: auto; }
.dock-in { display: flex; gap: var(--s-3); width: 100%; max-width: var(--container); }
.dock .btn-primary { flex: 1; }
.dock .btn-call {
  width: 52px;
  height: 52px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: var(--r-pill);
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--sh-1);
}
.dock .btn-call .ico { color: var(--accent); width: var(--ico-card); height: var(--ico-card); }

/* ── Форма записи ────────────────────────────────────────── */
.sheet {
  --scrim: rgba(22, 22, 22, .38);
  width: 100%;
  max-width: var(--container);
  max-height: 92dvh;
  margin: auto auto 0;
  padding: 0;
  border: 0;
  background: var(--bg);
  color: var(--ink);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  overscroll-behavior: contain;
  transform: translateY(16px);
  opacity: 0;
  transition: transform var(--dur-fast) var(--ease), opacity var(--dur-fast) var(--ease);
}
.sheet.is-open { transform: none; opacity: 1; }
.sheet::backdrop { background: var(--scrim); opacity: 0; transition: opacity var(--dur-fast) var(--ease); touch-action: none; }
.sheet.is-open::backdrop { opacity: 1; }
.sheet-in {
  position: relative;
  outline: none;
  max-height: 92dvh;
  display: flex;
  flex-direction: column;
  gap: var(--s-4);
  padding: var(--s-4) var(--gutter);
  padding-block-end: calc(var(--s-5) + env(safe-area-inset-bottom));
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.grip { width: 40px; height: 4px; border-radius: var(--r-pill); background: var(--line); align-self: center; }
.sheet-head { display: flex; align-items: flex-start; gap: var(--s-3); }
.sheet-head > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--s-2); }
.sheet-head h2 {
  font-family: var(--font-text);
  font-weight: 500;
  font-style: normal;
  font-size: var(--fs-h3);
  line-height: var(--lh-h3);
  letter-spacing: var(--ls-h3);
}
.x {
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: var(--r-pill);
  display: grid;
  place-items: center;
  background: var(--surface);
  border: 1px solid var(--line);
}
.x .ico { color: var(--ink-muted); }

form { display: flex; flex-direction: column; gap: var(--s-4); }
.fields { display: flex; flex-direction: column; gap: var(--s-4); }
.field { display: flex; flex-direction: column; gap: var(--s-2); }
.field .lab {
  font-family: var(--font-text);
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: var(--ls-label);
  text-transform: uppercase;
  color: var(--ink-muted);
}
.ctrl-wrap {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  min-height: 52px;
  padding-inline: var(--s-4);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}
.ctrl-wrap:focus-within { border-color: var(--accent); box-shadow: var(--focus-ring); }
.pfx { flex: none; color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.ctrl {
  flex: 1;
  min-width: 0;
  width: 100%;
  border: 0;
  background: none;
  font-family: var(--font-text);
  font-size: 16px; /* меньше 16px — iOS зумит страницу при фокусе */
  color: var(--ink);
}
.ctrl:focus { outline: none; }
.ctrl::placeholder { color: var(--ink-muted); opacity: .7; }
input[name="tel"] { font-variant-numeric: tabular-nums; letter-spacing: .04em; }
.err { display: none; font-size: var(--fs-small); color: var(--accent); font-weight: 500; }
.field.is-err .err { display: block; }
.field.is-err .ctrl-wrap { border-color: var(--accent); }

.submit-area { display: flex; flex-direction: column; gap: var(--s-3); padding-block-start: var(--s-2); }
.submit-area .btn { width: 100%; }
.sheet-note { text-align: center; }
.sheet-note a { color: var(--accent); font-weight: 500; }

.done { display: flex; flex-direction: column; gap: var(--s-4); }
.done-head { display: flex; align-items: flex-start; gap: var(--s-3); }
.done-head > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: var(--s-2); }
.done-ic {
  width: 44px;
  height: 44px;
  border-radius: var(--r-pill);
  display: grid;
  place-items: center;
  background: var(--gold-soft);
  align-self: flex-start;
}
.done-ic .ico { color: var(--accent); width: var(--ico-card); height: var(--ico-card); }
.done .btn { width: 100%; }

/* ── Десктоп ─────────────────────────────────────────────── */
@media (min-width: 768px) {
  .sheet { margin: auto; border-radius: var(--r-lg); }
  .grip { display: none; }
}