/* ============================================================
   PHASE 0 — DESIGN TOKENS
   ============================================================ */

@font-face {
  font-family: 'Neuzeit Antiqua';
  src: url('../assets/fonts/NeuzeitAntiqua.woff2') format('woff2'),
       url('../assets/fonts/Neuzeit Antiqua.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Palette */
  --color-brown-dark:   #3B2314;
  --color-brown-mid:    #9F6429;
  --color-gold:         #F5B143;
  --color-cream-light:  #F5EEE0;
  --color-cream-bg:     #F5E8CF;
  --color-white:        #FFFFFF;
  --color-paper:        #EDE6DD;   /* фон холста макета 668:2 */
  --color-ink:          #3B2314;

  /* Hero gradient stops */
  --hero-grad-1: #ECD095;
  --hero-grad-2: #F5E8CF;
  --hero-grad-3: #EDD29D;
  --hero-grad-4: #F5E7C8;

  /* Typography — две гарнитуры на весь сайт (решение владельца 22.10.2026):
     --font-head — заголовки и крупные акценты-подзаголовки (бывший рукописный
     Marck Script), --font-text — всё остальное: текст, кнопки, подписи, формы.
     Arsenal, Montserrat, Marck Script и Cormorant SC больше не подключаются. */
  --font-head: 'Neuzeit Antiqua', serif;
  --font-text: 'Inter', sans-serif;

  /* Spacing */
  --space-xs:  4px;
  --space-sm:  8px;
  --space-md:  16px;
  --space-lg:  24px;
  --space-xl:  40px;

  /* Shadows */
  --shadow-card:   1px 4px 10.6px rgba(0,0,0,0.91);
  --shadow-btn:    3px 4px 4px rgba(0,0,0,0.11);
  --shadow-rating: 0 0 5.8px rgba(128,66,34,0.5);

  /* Motion — единый словарь движения для всех *-fx модулей (прелоадер живёт
     на своём --pl-ease и сюда не подключён).
     out    — большие объекты: заголовки из прорези, шторки, панели;
     soft   — всё обычное: всплытия, ховеры, сдвиги;
     bounce — бумага/полароиды «легли» с маленьким перелётом;
     spring — печати, кнопки, пины: «шлёп» с отскоком;
     inout  — UI-переходы и бесконечные блики/фольга;
     pen    — рукописные строки: перо пишет сразу, без разгона. */
  --ease-out:    cubic-bezier(0.19, 1, 0.22, 1);
  --ease-soft:   cubic-bezier(0.22, 1, 0.36, 1);
  --ease-bounce: cubic-bezier(0.22, 1.25, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-inout:  cubic-bezier(0.65, 0, 0.35, 1);
  --ease-pen:    cubic-bezier(0.3, 0.2, 0.25, 1);
  --dur-write:   1.3s;
}

/* ============================================================
   PHASE 0 — BASE
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
  /* Без своего фона в любом зазоре/сабпиксельном промахе просвечивает
     системный фон браузера — на телефоне с тёмной темой это выглядит
     чёрной полосой сбоку. overflow-x задублирован с body: на части
     мобильных браузеров именно html, а не body, является реальным
     скролл-контейнером страницы. */
  background: var(--color-paper);
  overflow-x: hidden;
}

body {
  /* Геометрия перегородки clouds2.png (2151×758 → h = w × 0.3524):
     тянется на всю ширину экрана, но не уже макетных 1400px */
  --cd-w: max(1400px, 100vw);
  --cd-h: calc(var(--cd-w) * 0.3524);
  font-family: var(--font-text);
  color: var(--color-brown-dark);
  background: var(--color-paper);
  margin: 0;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }

a { text-decoration: none; color: inherit; }

/* Штора слева (Figma 670:77) — теперь часть .utp__stage, z-index на 1 ниже .utp__clouds (2624) */

/* ============================================================
   HEADER — «театральная программка»
   Наверху страницы шапка прозрачная и лежит на hero; после прокрутки
   собирается в парящую бумажную плашку (класс .is-scrolled, js/header.js),
   при прокрутке вниз прячется (.is-hidden), вверх — возвращается.
   Размеры фиксированные, в резиновый масштаб (--fluid-k) шапка не входит.
   ============================================================ */

.site-header {
  --hdr-ink: #2A170C;
  --hdr-paper: rgba(248, 241, 229, 0.8);
  --hdr-ease: var(--ease-soft);
  --hdr-fg: var(--hdr-ink);
  --hdr-fg-soft: var(--color-brown-mid);
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  padding: 0;
  pointer-events: none;
  transition: transform 0.6s var(--hdr-ease);
}
.site-header.is-hidden { transform: translateY(calc(-100% - 24px)); }

.site-header__inner {
  position: relative;
  pointer-events: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 24px;
  min-height: 76px;
  margin: 0;
  padding: 10px 28px 10px 30px;
  border: 1px solid transparent;
  border-radius: 0;
  background-color: transparent;
  transition:
    margin 0.6s var(--hdr-ease),
    padding 0.6s var(--hdr-ease),
    min-height 0.6s var(--hdr-ease),
    border-radius 0.6s var(--hdr-ease),
    background-color 0.4s ease,
    border-color 0.4s ease,
    box-shadow 0.4s ease;
}
/* лёгкая бумажная подложка наверху, чтобы шапка читалась на любом фоне hero */
.site-header__inner::before {
  content: '';
  position: absolute;
  inset: 0 0 -28px;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(to bottom, rgba(245, 238, 224, 0.85), rgba(245, 238, 224, 0));
  transition: opacity 0.4s ease;
}

.site-header.is-scrolled .site-header__inner {
  margin: 12px 16px 0;
  min-height: 62px;
  padding: 7px 8px 7px 12px;
  border-color: rgba(159, 100, 41, 0.22);
  border-radius: 20px;
  background-color: var(--hdr-paper);
  -webkit-backdrop-filter: blur(16px) saturate(1.25);
  backdrop-filter: blur(16px) saturate(1.25);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 22px 44px -22px rgba(59, 35, 20, 0.5),
    0 2px 6px rgba(59, 35, 20, 0.06);
}
.site-header.is-scrolled .site-header__inner::before { opacity: 0; }

/* ── Идентификатор: печать + название ── */
.site-header__id {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  justify-self: start;
}
.site-header__logo {
  position: relative;
  z-index: 1;
  flex-shrink: 0;
  display: block;
  width: 52px;
  height: 52px;
  margin: 0 7px;
  line-height: 0;
  border-radius: 50%;
  transition: width 0.6s var(--hdr-ease), height 0.6s var(--hdr-ease), transform 0.5s var(--hdr-ease);
}
.site-header__logo img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-cream-light);
  box-shadow: 0 0 0 1px rgba(159, 100, 41, 0.35), 0 6px 14px -6px rgba(59, 35, 20, 0.5);
}
.site-header__logo:hover { transform: rotate(-8deg) scale(1.04); }
.site-header.is-scrolled .site-header__logo { width: 42px; height: 42px; }

/* кольцо с текстом вокруг печати, медленно вращается */
.site-header__ring {
  position: absolute;
  left: 0;
  top: 50%;
  width: 66px;
  height: 66px;
  margin-top: -33px;
  pointer-events: none;
  overflow: visible;
  animation: hdr-ring 26s linear infinite;
  transition: opacity 0.4s ease, transform 0.6s var(--hdr-ease);
}
.site-header__ring text {
  font-family: var(--font-text);
  font-size: 8.6px;
  font-weight: 600;
  letter-spacing: 0.21em;
  fill: var(--hdr-fg-soft);
}
.site-header__id:hover .site-header__ring { animation-duration: 7s; }
.site-header.is-scrolled .site-header__ring { opacity: 0; transform: scale(0.8); }
@keyframes hdr-ring { to { rotate: 360deg; } }

.site-header__brand {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1;
}
.site-header__brand-name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--hdr-fg);
}
.site-header__brand-tag {
  max-height: 24px;
  margin-top: 4px;
  font-family: var(--font-head);
  font-size: 15px;
  white-space: nowrap;
  color: var(--hdr-fg-soft);
  transition: opacity 0.4s ease, margin 0.6s var(--hdr-ease), max-height 0.6s var(--hdr-ease);
}
.site-header.is-scrolled .site-header__brand-tag { opacity: 0; max-height: 0; margin-top: 0; }

/* ── Навигация: номера + перекатывание слова ── */
@property --ry {
  syntax: '<length>';
  inherits: true;
  initial-value: 0px;
}
.site-header__nav { justify-self: center; }
.site-header__menu {
  display: flex;
  align-items: center;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: hdr-nav;
}
.site-header__menu li {
  --roll: 40px;
  position: relative;
  height: var(--roll);
  overflow: hidden;
  counter-increment: hdr-nav;
}
.site-header__menu a {
  display: block;
  height: var(--roll);
  padding: 0 16px;
  line-height: var(--roll);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 12.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  /* «Перекатывание» слова: сама ссылка НЕ сдвигается (иначе при наведении она
     уезжала из-под курсора и клик попадал в пустой <li>). Текст прозрачный,
     видимое слово — две тени: основная на месте и золотая ниже; при наведении
     обе уезжают вверх на --roll (анимируется --ry, см. @property). */
  color: transparent;
  --ry: 0px;
  text-shadow:
    0 var(--ry) 0 var(--hdr-fg),
    0 calc(var(--ry) + var(--roll)) 0 var(--hdr-roll-c, var(--color-brown-mid));
  transition: --ry 0.55s var(--ease-inout);
}
.site-header__menu a::before {
  content: counter(hdr-nav, decimal-leading-zero);
  margin-right: 7px;
  font-family: var(--font-head);
  font-size: 11px;
  letter-spacing: 0.04em;
  vertical-align: 5px;
  color: transparent;
  text-shadow:
    0 var(--ry) 0 var(--hdr-num-c, var(--color-brown-mid)),
    0 calc(var(--ry) + var(--roll)) 0 var(--hdr-num-c, var(--color-brown-mid));
}
.site-header__menu li:hover a,
.site-header__menu a:focus-visible { --ry: calc(-1 * var(--roll)); }
.site-header__menu a:focus-visible { outline: none; }
/* текущая секция — золотая точка под словом */
.site-header__menu li::after {
  content: '';
  position: absolute;
  left: 50%;
  bottom: 3px;
  width: 5px;
  height: 5px;
  margin-left: 6px;
  border-radius: 50%;
  background: var(--color-gold);
  box-shadow: 0 0 8px rgba(245, 177, 67, 0.9);
  transform: translateX(-50%) scale(0);
  transition: transform 0.45s var(--hdr-ease);
}
.site-header__menu li.is-active::after { transform: translateX(-50%) scale(1); }

/* ── Справа: телефон + билет ── */
.site-header__actions {
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 20px;
}
.site-header__phone {
  position: relative;
  padding-left: 16px;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  color: var(--hdr-fg);
  background: linear-gradient(currentColor, currentColor) 16px 100% / 0 1px no-repeat;
  transition: background-size 0.45s var(--hdr-ease), color 0.2s ease;
}
.site-header__phone:hover { background-size: calc(100% - 16px) 1px; }
/* «на связи» — пульсирующая точка */
.site-header__phone::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  width: 7px;
  height: 7px;
  margin-top: -3.5px;
  border-radius: 50%;
  background: #3FAE5C;
  animation: hdr-pulse 2.2s ease-out infinite;
}
@keyframes hdr-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(63, 174, 92, 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(63, 174, 92, 0); }
  100% { box-shadow: 0 0 0 0 rgba(63, 174, 92, 0); }
}

/* кнопка — прежняя, золотая текстура сайта (button1 → button2 при наведении) */
.site-header__cta {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 180px;
  height: 47px;
  padding: 0 28px;
  border-radius: 999px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  white-space: nowrap;
  box-shadow: var(--shadow-btn);
  border: none;
  position: relative;
  z-index: 0;
  transition: box-shadow 0.25s ease, color 0.2s ease;
}
.site-header__cta::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.site-header__cta:hover {
  box-shadow: 3px 6px 12px rgba(0, 0, 0, 0.18);
  color: var(--color-brown-dark);
}
.site-header__cta:hover::after { opacity: 1; }

/* ── Страница программы: наверху шапка лежит на тёмном hero — светлый вариант ── */
.page-program .site-header:not(.is-scrolled) {
  --hdr-fg: #F6EBD6;
  --hdr-fg-soft: #E8B96A;
}
.page-program .site-header:not(.is-scrolled) .site-header__inner::before {
  background: linear-gradient(to bottom, rgba(26, 14, 7, 0.55), rgba(26, 14, 7, 0));
}
.page-program .site-header:not(.is-scrolled) .site-header__menu a { --hdr-roll-c: var(--color-gold); --hdr-num-c: #E8B96A; }

/* ── Бургер (≤ 768 px) ── */
.site-header__burger {
  display: none;
  position: relative;
  flex-shrink: 0;
  justify-self: end;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(159, 100, 41, 0.3);
  border-radius: 50%;
  background: rgba(248, 241, 229, 0.85);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  cursor: pointer;
  z-index: 1001;
  transition: background-color 0.3s ease, transform 0.4s var(--hdr-ease);
}
.site-header__burger span {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 18px;
  height: 1.5px;
  margin-left: -9px;
  border-radius: 2px;
  background: var(--hdr-ink);
  transition: transform 0.5s var(--hdr-ease), width 0.4s var(--hdr-ease);
}
.site-header__burger span:nth-child(1) { transform: translateY(-3.5px); }
.site-header__burger span:nth-child(2) { transform: translateY(3.5px); width: 12px; }
.site-header__burger:active { transform: scale(0.94); }
.site-header__burger.is-open span:nth-child(1) { transform: rotate(45deg); }
.site-header__burger.is-open span:nth-child(2) { transform: rotate(-45deg); width: 18px; }

/* ── Мобильное меню: полноэкранная «сцена», открывается кругом от бургера ── */
.mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  pointer-events: none;
}
.mobile-menu[aria-hidden="false"] { pointer-events: auto; }
.mobile-menu__overlay { display: none; }
.mobile-menu__panel {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 32px;
  padding: 116px 28px calc(32px + env(safe-area-inset-bottom));
  overflow-y: auto;
  background:
    radial-gradient(120% 60% at 100% 0%, rgba(245, 177, 67, 0.22), transparent 60%),
    var(--color-cream-light) url('../assets/img/bg-paper.webp') center / cover;
  clip-path: circle(0 at calc(100% - 39px) 39px);
  transition: clip-path 0.8s var(--ease-inout);
}
.mobile-menu[aria-hidden="false"] .mobile-menu__panel { clip-path: circle(150% at calc(100% - 39px) 39px); }
.mobile-menu__list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: mm-nav;
}
.mobile-menu__list li {
  overflow: hidden;
  border-bottom: 1px solid rgba(59, 35, 20, 0.12);
  counter-increment: mm-nav;
}
.mobile-menu__link {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 16px 0 12px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(34px, 10vw, 46px);
  line-height: 1;
  text-transform: uppercase;
  color: #2A170C;
  transform: translateY(105%);
  transition: transform 0.7s var(--ease-soft), color 0.2s ease;
}
.mobile-menu__link::before {
  content: counter(mm-nav, decimal-leading-zero);
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--color-brown-mid);
}
.mobile-menu__link:active { color: var(--color-brown-mid); }
.mobile-menu[aria-hidden="false"] .mobile-menu__link { transform: none; }
.mobile-menu[aria-hidden="false"] li:nth-child(1) .mobile-menu__link { transition-delay: 0.25s; }
.mobile-menu[aria-hidden="false"] li:nth-child(2) .mobile-menu__link { transition-delay: 0.33s; }
.mobile-menu[aria-hidden="false"] li:nth-child(3) .mobile-menu__link { transition-delay: 0.41s; }
.mobile-menu__foot {
  display: flex;
  flex-direction: column;
  gap: 14px;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.6s var(--ease-soft);
}
.mobile-menu[aria-hidden="false"] .mobile-menu__foot { opacity: 1; transform: none; transition-delay: 0.5s; }
.mobile-menu__phone {
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 20px;
  color: #2A170C;
}
.mobile-menu__cta {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 56px;
  border-radius: 999px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  box-shadow: var(--shadow-btn);
}

/* ── Промежуточные ширины: сначала уходит телефон, потом название ── */
@media (max-width: 1280px) {
  .site-header__phone { display: none; }
}
@media (max-width: 1080px) {
  .site-header__brand { display: none; }
  .site-header__menu a { padding: 0 12px; }
}

@media (max-width: 768px) {
  .site-header__inner {
    grid-template-columns: 1fr auto;
    min-height: 68px;
    padding: 10px 14px 10px 12px;
  }
  .site-header.is-scrolled .site-header__inner {
    margin: 8px 10px 0;
    min-height: 58px;
    padding: 6px 6px 6px 8px;
    border-radius: 18px;
  }
  .site-header__brand { display: flex; }
  .site-header__brand-tag { display: none; }
  .site-header__brand-name { font-size: 14px; letter-spacing: 0.12em; }
  .site-header__logo { width: 44px; height: 44px; margin: 0 5px; }
  .site-header__ring { width: 54px; height: 54px; margin-top: -27px; }
  .site-header__nav,
  .site-header__actions { display: none; }
  .site-header__burger { display: block; }
  .mobile-menu { display: block; }
  /* пока меню открыто — шапка без плашки, бургер-крестик над «сценой» */
  body.menu-open .site-header { --hdr-fg: #2A170C; --hdr-fg-soft: var(--color-brown-mid); }
  body.menu-open .site-header__inner {
    background-color: transparent;
    border-color: transparent;
    box-shadow: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  body.menu-open .site-header__inner::before { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .site-header__ring,
  .site-header__phone::before { animation: none; }
  .site-header,
  .site-header__inner,
  .site-header__menu a,
  .mobile-menu__panel,
  .mobile-menu__link { transition-duration: 0.01s; }
}

/* Fade-up: используется для секций ниже hero */

/* ============================================================
   PHASE 1 — HERO (Figma 670:52, frame 1400 × 739)
   ============================================================ */

#hero {
  position: relative;
  width: 100%;
  min-height: 100dvh;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  overflow: hidden;
  /* center bottom: у hero-bg.png рваный прозрачный низ + цветы по углам; при center cover
     на широких экранах низ картинки срезался краем секции ровной линией */
  background: url('../assets/img/hero-bg.webp') center bottom / cover no-repeat, var(--color-paper);
  padding: 88px 40px 0 100px; /* header + 100px от левого края экрана */
  box-sizing: border-box;
}

.hero__stage {
  position: relative;
  flex-shrink: 0;
  width: 1400px;
  height: 739px;
  z-index: 1;
  transform: scale(var(--hero-scale, 1));
  transform-origin: left center;
}

/* --- Книга с полароидами (Figma 670:76) ---
   Книга и её тень — два файла: book-hero.png (1372 × 819) и book-shadow.png
   (1209 × 244), обе в своих пропорциях с общим масштабом 0.4236. Координаты
   совпадают с тем, что рисует hero-orbit.js в канвасе, поэтому переход
   «есть WebGL / нет WebGL» не сдвигает книгу ни на пиксель. */
.hero__book {
  position: absolute;
  left: 777px;
  top: 183.5px;
  width: 581px;
  height: 347px;
  z-index: 2;
  pointer-events: none;
  transform: rotate(0deg);
  animation: heroBookIn 0.9s var(--ease-soft) 0.15s both;
}
.hero__book-shadow {
  position: absolute;
  left: 811.5px;
  top: 513.5px;
  width: 512px;
  height: 103px;
  z-index: 1;
  pointer-events: none;
  user-select: none;
  animation: heroBookIn 0.9s var(--ease-soft) 0.15s both;
}
@keyframes heroBookIn {
  from { opacity: 0; transform: translateY(34px) scale(0.97); }
  to   { opacity: 1; transform: none; }
}

/* --- 3D-орбита полароидов вокруг книги (js/hero-orbit.js) ---
   Канвас центрирован ровно по центру статичной книги:
     X = 765 + 605/2 = 1067.5  →  left = 1067.5 − 1000/2 = 567.5
     Y = 151 + 428/2 = 365     →  top  = 365    − 730/2  = 0
   Внутри канваса 1 мировая единица = 1 px макета (дистанция камеры выведена
   из FOV в hero-orbit.js), поэтому книга в GL встаёт пиксель в пиксель туда
   же, где лежал .hero__book. Габариты канваса шире холста 1400 — правый
   край орбиты уходит за него и обрезается тем же overflow: hidden у #hero,
   которым и сейчас подрезается правый край книги на узких экранах. */
.hero__orbit {
  position: absolute;
  left: 567.5px;
  top: 0;
  width: 1000px;
  height: 730px;
  z-index: 2;
}
.hero__orbit-canvas {
  display: block;
  width: 100%;
  height: 100%;
  /* pan-y, а не none: горизонтальный драг забираем себе, вертикальный
     отдаём странице — иначе с пальцем на книге страница не скроллится */
  touch-action: pan-y;
  -webkit-user-select: none;
          user-select: none;
}
/* канвас нарисовал книгу и тень сам — статичные прячем, из разметки не убираем */
.hero__stage.is-orbit-on .hero__book,
.hero__stage.is-orbit-on .hero__book-shadow { visibility: hidden; }

/* --- Бейджи на рваной бумаге (Figma 668:10-12) --- */
.hero__badge {
  position: absolute;
  z-index: 4;
  top: 117px;
  display: flex;
  align-items: center;
  font-family: var(--font-text);
  font-size: 16px;
  font-weight: 400;
  color: var(--color-brown-dark);
  white-space: nowrap;
}
.hero__badge-paper {
  position: absolute;
  z-index: -1;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  user-select: none;
  max-width: none;
}
.hero__badge--top {
  left: 57px;
  width: 332px;
  justify-content: center;
}
.hero__badge--top .hero__badge-paper { left: -73px; width: 479px; height: 55px; }
.hero__badge--top strong { font-weight: 600; margin: 0 4px; }

/* Рейтинг и «500+» — та же рваная крафт-бумага, что у плашки ТОП-5:
   assets/img/v2/badge-torn-*.png собраны из plashka2.png (выпрямлены, корона
   убрана, ширина набрана стыковкой двух кусков одной полосы). Подложка теперь
   background, а не <img> с ручным сдвигом: высота у обеих одна, содержимое
   центрируется само, и плашки стоят ровно на одной линии. */
.hero__badge--rating,
.hero__badge--stats {
  /* 102 + 48/2 = 126 — тот же центр по вертикали, что у плашки ТОП-5
     (её top 117 при высоте содержимого 19), так что все три стоят на одной оси */
  top: 102px;
  height: 48px;
  justify-content: center;
  background-repeat: no-repeat;
  background-position: center;
  background-size: 100% 100%;
  box-sizing: border-box;
  color: var(--color-brown-dark);
}

.hero__badge--rating {
  left: 736px;
  width: 260px;
  padding: 0 20px;
  gap: 6px;
  background-image: url('../assets/img/v2/badge-torn-sm.png');
}
.hero__rating-num {
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 36px;
  line-height: 30px;
  color: var(--color-brown-dark);
}
.hero__rating-star {
  width: 29px;
  height: 29px;
  display: block;
  /* лёгкий тёплый бархат под звездой — то же, чем на плашке «светится» корона */
  filter: drop-shadow(0 1px 1px rgba(139, 85, 24, .35));
}
.hero__rating-label {
  font-family: var(--font-text);
  font-size: 12px;
  color: var(--color-brown-dark);
  margin-left: 5px;
}

.hero__badge--stats {
  left: 1012px;
  width: 300px;
  padding: 0 22px;
  background-image: url('../assets/img/v2/badge-torn-md.png');
}

/* Враппер двух бейджей — только для мобильной раскладки */
.hero__badges { display: contents; }

/* --- Заголовок --- */
.hero__title {
  position: absolute;
  left: 0;
  top: 171px;
  margin: 0;
  z-index: 3;
  display: flex;
  flex-direction: column;
  animation: heroFadeUp 0.7s var(--ease-soft) 0.1s both;
}
.hero__title-line {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 68px;
  line-height: 57px;
  color: var(--color-brown-dark);
  display: block;
  text-transform: uppercase;
}
/* Вторая строка отличается только цветом — толщина везде 700 */
.hero__title-line + .hero__title-line { color: var(--color-brown-mid); }

@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* --- Подзаголовок (рукописный) --- */
.hero__subtitle {
  position: absolute;
  left: 0;
  top: 301px;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 44px;
  line-height: 52px;
  color: var(--color-brown-dark);
  animation: heroFadeUp 0.7s var(--ease-soft) 0.2s both;
}

/* --- Кнопки --- */
.hero__btn {
  position: absolute;
  left: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 253px;
  height: 47px;
  border-radius: 37px;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  box-shadow: var(--shadow-btn);
  border: none;
  transition: box-shadow 0.25s ease, background 0.2s ease, color 0.2s ease, transform 0.25s ease;
  cursor: pointer;
  animation: heroFadeUp 0.7s var(--ease-soft) 0.3s both;
}
.hero__btn:hover { box-shadow: 3px 6px 12px rgba(0,0,0,0.18); transform: scale(1.06); }
.hero__btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.hero__btn--primary {
  top: 417px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
}
.hero__btn--primary::after {
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
}
.hero__btn--primary:hover { color: var(--color-brown-dark); }
.hero__btn--outline {
  top: 478px;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  color: var(--color-brown-dark);
}
.hero__btn--outline::after {
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
}
.hero__btn--outline:hover { color: var(--color-white); }
.hero__btn:hover::after { opacity: 1; }

/* --- Соцсети --- */
.hero__social-label {
  position: absolute;
  left: 0;
  top: 563px;
  z-index: 3;
  font-family: var(--font-text);
  font-size: 16px;
  font-weight: 400;
  color: var(--color-brown-dark);
  white-space: nowrap;
  animation: heroFadeUp 0.7s var(--ease-soft) 0.38s both;
}
.hero__social-icons {
  position: absolute;
  left: 0;
  top: 590px;
  z-index: 3;
  display: flex;
  gap: 9px;
  animation: heroFadeUp 0.7s var(--ease-soft) 0.45s both;
}
/* Сургучные печати — те же, что в «Свяжитесь с нами сами» (.note__socials):
   каждая кнопка вырезает свою печать из общего note-socials.webp (1742×513).
   Печать 481×493 → кнопка 56×57. background-size: 1742/w, 513/493;
   background-position: left / (1742 − w), 9 / 20. */
.hero__social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 57px;
  border-radius: 50%;
  background: url('../assets/img/v2/note-socials.webp') no-repeat;
  background-size: 362.2% 104.1%;
  filter: drop-shadow(0 4px 7px rgba(59, 35, 20, 0.28));
  transition: transform 0.2s ease, filter 0.2s ease;
}
.hero__social-icon:nth-child(1) { --bp: 0.71% 45%;  --bs: 362.2% 104.1%; --gd: 0s; }     /* звонок */
.hero__social-icon:nth-child(2) { --bp: 50.16% 45%; --bs: 364.4% 104.1%; --gd: 0.25s; }  /* Max */
.hero__social-icon:nth-child(3) { --bp: 99.13% 45%; --bs: 360.7% 104.1%; --gd: 0.5s; }   /* ВК */
.hero__social-icon { position: relative; background-position: var(--bp); background-size: var(--bs); }
.hero__social-icon:hover { transform: translateY(-4px) rotate(-7deg) scale(1.08); filter: drop-shadow(0 10px 14px rgba(59, 35, 20, 0.36)); }
/* старые белые иконки остаются в разметке (data-cms-id), но не видны — рисует печать */
.hero__social-icon img { display: none; }

/* ============================================================
   КРАФТ-ПОЛОТНО — общий фон для УТП и СРАВНЕНИЯ
   (Figma 668:17 + запечённая карта 668:18)
   Глобальные Y макета: 602 … 3600
   ============================================================ */

.craft {
  position: relative;
  width: 100%;
  height: 2916px;
  overflow-x: clip;        /* облака-подложка шире экрана — режем по ширине, вертикаль не трогаем */
  margin-top: -11px;       /* Figma 670:128 заходит на hero на 11px */
  z-index: 2;
  background-image: url('../assets/img/v2/craft-bg-paper.webp');
  background-repeat: no-repeat;
  background-position: center 350px;
  background-size: 100% auto;   /* ровно ширина экрана, пропорции сохранены */

  /* Рваный нижний край крафт-бумаги (Figma 671:157) — маска, чтобы прямой срез "обрывался" */
  --craft-tear-h: 46px;
  -webkit-mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--craft-tear-h)) no-repeat,
    url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='600'%20height='46'%3E%3Cpath%20d='M0%200H600V14L576%2030%20552%2018%20528%2038%20504%2022%20480%2033%20456%2012%20432%2028%20408%2040%20384%2020%20360%2031%20336%2016%20312%2036%20288%2024%20264%209%20240%2030%20216%2019%20192%2037%20168%2023%20144%2032%20120%2013%2096%2027%2072%2039%2048%2017%2024%2029%200%2020Z'%20fill='%23000'/%3E%3C/svg%3E") bottom left / 600px var(--craft-tear-h) repeat-x;
  mask:
    linear-gradient(#000 0 0) top / 100% calc(100% - var(--craft-tear-h)) no-repeat,
    url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='600'%20height='46'%3E%3Cpath%20d='M0%200H600V14L576%2030%20552%2018%20528%2038%20504%2022%20480%2033%20456%2012%20432%2028%20408%2040%20384%2020%20360%2031%20336%2016%20312%2036%20288%2024%20264%209%20240%2030%20216%2019%20192%2037%20168%2023%20144%2032%20120%2013%2096%2027%2072%2039%2048%2017%2024%2029%200%2020Z'%20fill='%23000'/%3E%3C/svg%3E") bottom left / 600px var(--craft-tear-h) repeat-x;
}

/* Радиальное затемнение по верхнему краю карты — убрано по макету 670:77 */
.craft__vignette {
  display: none;
}

/* ============================================================
   PHASE 2 — УТП «Мы открываем портал в настоящую сказку»
   Figma 668:2, локальный отсчёт от Y=602
   ============================================================ */

#utp {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 1438px;
  z-index: 1;
}

.utp__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 1438px;
}

/* Штора слева (Figma 670:77) — лежит ПОВЕРХ полароидов (.utp__card: 6, на ховере 7)
   и перекрывает их край, как занавес перед сценой (было z-index 1 — под всем) */
.site-curtain {
  position: absolute;
  left: -400px;
  top: 0px;
  width: 805px;
  height: auto;
  z-index: 8;
  pointer-events: none;
  filter: drop-shadow(6px 10px 20px rgba(0, 0, 0, .35));
  will-change: transform;
  /* transform/opacity выставляются напрямую из JS на каждый кадр скролла (scroll-linked, см. main.js) */
}

/* Облачная дымка по нижнему краю карты */
.utp__clouds {
  position: absolute;
  left: 50%;
  top: 840px;
  width: max(1967px, calc(100vw / var(--stage-scale, 1)));
  height: auto;          /* без обрезки — иначе по верху появляется прямая линия среза */
  transform: translateX(-50%);
  max-width: none;
  z-index: 2;
  pointer-events: none;
  opacity: 1;
  will-change: transform;   /* отдельный слой: без него широкая полупрозрачная картинка
                               перерисовывается на каждом кадре скролла */
}

/* Пунктирный маршрут (векторизован, см. index.html) */
.utp__route {
  position: absolute;
  left: 270px;
  top: 564px;
  width: 796px;
  height: 968px;
  max-width: none;
  z-index: 3;
  pointer-events: none;
  overflow: visible;
  will-change: transform;
  /* без filter: анимируемая clip-маска + фильтр = пересчёт на каждый кадр */
}
.utp__route-path {
  fill: none;
  stroke: #f5f4f2;
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 28 25;
}
/* Прорисовка маршрута по скроллу средствами CSS (scroll-driven animations).
   Не зависит от JS: .utp__route задаёт именованный view-timeline, маска-путь
   внутри clipPath тянет по нему stroke-dashoffset от 1000 (скрыт) до 0 (виден). */
@property --utp-route-dash {
  syntax: "<number>";
  initial-value: 1000;
  inherits: true;        /* значение наследуется внутрь <defs> к пути-маске */
}
@supports (animation-timeline: view()) {
  /* анимация висит на самом <svg> — у него свой анонимный view()-таймлайн,
     искать именованный таймлайн у предков не нужно */
  .utp__route {
    animation: utpRouteDraw linear both;
    animation-timeline: view();
  }
  .utp__route-reveal {
    stroke-dasharray: 1000;                        /* pathLength="1000" в разметке */
    stroke-dashoffset: var(--utp-route-dash, 0);   /* 1000 — скрыт, 0 — виден целиком */
  }
  @media (prefers-reduced-motion: reduce) {
    .utp__route { animation: none; }
    .utp__route-reveal { stroke-dasharray: none; stroke-dashoffset: 0; }
  }
}
@keyframes utpRouteDraw {
  from { --utp-route-dash: 1000; }
  to   { --utp-route-dash: 0; }
}
/* Толстый невидимый дублёр пути — им main.js «дорисовывает» clip-path вдоль кривой
   (stroke-dasharray/-dashoffset = длина пути), а не прямоугольной шторкой сверху вниз */
.utp__route-reveal {
  fill: none;
  stroke: #000;
  stroke-width: 24;
  stroke-linecap: round;
}

/* Метки-пины */
.utp__pin {
  position: absolute;
  width: 39px;
  height: 55px;
  z-index: 4;
  pointer-events: none;
  filter: drop-shadow(0 3px 4px rgba(59, 35, 20, 0.35))
          drop-shadow(0 0 12px rgba(245, 177, 67, 0.8));
}
.utp__pin--1 { left:  443px; top:  594px; }
.utp__pin--2 { left: 1033px; top:  746px; }
.utp__pin--3 { left:  867px; top: 1272px; }
.utp__pin--4 { left:  336px; top: 1183px; }
.utp__pin--5 { left:  781px; top:  932px; }

/* Заголовок — по центру полотна */
.utp__title {
  position: absolute;
  left: 0;
  top: 52px;
  width: 1400px;
  margin: 0;
  z-index: 9;   /* над шторой (.site-curtain: 8) — текст не прячется под занавес */
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  text-transform: uppercase;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 68px;
  letter-spacing: .035em;
}
.utp__title-dark  { color: var(--color-brown-dark); display: block; }
.utp__title-light {
  display: block;
  color: var(--color-brown-mid);
  text-shadow: 0 1px 0 rgba(255, 255, 255, .45);
}

.utp__subtitle {
  position: absolute;
  left: 50%;
  top: 232px;              /* было 262 — поднято на 30px по просьбе */
  transform: translateX(-50%);
  width: 1020px;
  margin: 0;
  padding-top: 10px;
  z-index: 9;   /* плашка тоже над шторой, как было */
  text-align: center;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 32px;
  line-height: 29px;
  color: var(--color-brown-dark);
}
/* Бумажная плашка-свиток под подзаголовком (Figma 741:98) */
.utp__subtitle::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -10px;
  width: 850px;
  height: 160px;
  transform: translateX(-50%);
  background: url('../assets/img/v2/utp-plate.webp') 0 0 / 100% 100% no-repeat;
  filter: drop-shadow(0 8px 14px rgba(59, 35, 20, .22));
  z-index: -1;
}

/* Полароиды (наклон запечён в PNG) */
.utp__card {
  position: absolute;
  z-index: 6;
  opacity: 0;
  transform: scale(0.35) translateY(60px) rotate(-6deg);
  transition: opacity 0.6s ease,
              transform 0.35s var(--ease-soft),
              filter 0.35s ease;
  will-change: transform, opacity;
}
/* Появление при скролле: зум с вылетом (transition-delay ставит main.js для каскада) */
.utp__card.is-in {
  opacity: 1;
  transform: none;
  transition: opacity 0.6s ease,
              transform 0.7s var(--ease-spring),
              filter 0.35s ease;
}
.utp__card img { width: 100%; height: 100%; display: block; }
/* Подпись полароида — живой текст поверх плашки картинки (*-blank.webp).
   Центр, ширина и наклон — по плашке конкретной карточки (--cx/--cy/--cw/--cr),
   кегль в cqw от ширины карточки — одинаково на десктопе и в мобильной раскладке. */
.utp__card { container-type: inline-size; }
.utp__cap {
  position: absolute;
  left: var(--cx);
  top: var(--cy);
  width: var(--cw);
  margin: 0;
  transform: translate(-50%, -50%) rotate(var(--cr, 0deg));
  text-align: center;
  pointer-events: none;
}
.utp__cap-main {
  display: block;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: var(--cfs, 8.2cqw);
  line-height: 1.05;
  color: var(--color-brown-dark);
}
.utp__cap-sub {
  display: block;
  margin-top: 0.45em;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 3.5cqw;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-brown-mid);
}
.utp__card:hover {
  transform: translateY(-10px) scale(1.035);
  filter: drop-shadow(0 14px 24px rgba(35, 20, 10, 0.45));
  z-index: 7;
}
.utp__card--1 { left:  84px; top:  479px; width: 348px; height: 340px; }
.utp__card--2 { left: 634px; top:  382px; width: 401px; height: 392px; }
.utp__card--3 { left: 850px; top:  835px; width: 401px; height: 392px; }
.utp__card--4 { left: 137px; top:  813px; width: 356px; height: 348px; }
.utp__card--5 { left: 481px; top: 1003px; width: 374px; height: 365px; }
.utp__card--1 { --cx: 53.3%; --cy: 79%;   --cw: 54%; --cr: -7.9deg; }
.utp__card--2 { --cx: 46.5%; --cy: 75.6%; --cw: 50%; --cr:  9.1deg; }
.utp__card--3 { --cx: 49.5%; --cy: 82.8%; --cw: 66%; --cr:  0deg; }
.utp__card--4 { --cx: 45%;   --cy: 80%;   --cw: 60%; --cr:  8.8deg; }
.utp__card--5 { --cx: 50.7%; --cy: 82.3%; --cw: 70%; --cr:  0deg; --cfs: 6.9cqw; }

/* Без анимаций для тех, кто просил их не показывать */
@media (prefers-reduced-motion: reduce) {
  .utp__route-path { clip-path: none; }
  .utp__card  { opacity: 1; transform: none; transition: filter 0.35s ease; }
}

/* ============================================================
   PHASE 6 — ВОЗМОЖНОСТИ «Можем реализовать любую идею»
   Figma 668:20 + 668:181, локальный отсчёт от глобального Y = 4346
   ============================================================ */

#capabilities {
  position: relative;
  width: 100%;
  height: 1100px;
  z-index: 3;
  overflow: hidden;
  /* book-bg.png имеет прозрачные поля вокруг рваной карточки. Заливки цветом тут быть
     не должно: снизу блок лежит поверх #programs (z-index 2), и именно сквозь эти
     прозрачные поля рваный край бумаги ложится на стену — без плоской полосы-шва.
     Сверху и по бокам под ними всё равно виден body (тот же --color-paper). */
  background: url('../assets/img/book-bg.webp') center / cover no-repeat;
}

.cap__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 1100px;
}

/* Фото-полароиды и плашка-заголовок поверх книги */
.cap__card {
  position: absolute;
  z-index: 2;
  max-width: none;
  container-type: inline-size;
  transform: rotate(var(--rot, 0deg));
  filter: drop-shadow(4px 10px 18px rgba(59, 35, 20, .35));
  transition: transform 0.35s var(--ease-soft),
              filter 0.35s ease;
}
.cap__card:hover {
  transform: rotate(var(--rot, 0deg)) scale(1.06) translateY(-6px);
  z-index: 5;
  filter: drop-shadow(6px 16px 26px rgba(59, 35, 20, .45));
}

.cap__card--title { left:   20px; top:  40px; width: 360px; height: 309px; --rot: -5deg; }
.cap__card--1     { left:   30px; top: 380px; width: 300px; height: 371px; --rot: -6deg; }
.cap__card--2     { left: 1040px; top:  30px; width: 340px; height: 298px; --rot:  7deg; }
.cap__card--3     { left: 1060px; top: 480px; width: 300px; height: 395px; --rot: -5deg; }
.cap__card img { display: block; width: 100%; height: 100%; }

/* Надписи на карточках — живой текст поверх картинок без надписей (*-blank.webp);
   координаты — по плашкам на картинке, кегль в cqw от ширины карточки */
.cap__tag,
.cap__title,
.cap__note {
  position: absolute;
  margin: 0;
  transform: translate(-50%, -50%) rotate(var(--r, 0deg));
  text-align: center;
  font-family: var(--font-head);
  font-weight: 400;
  color: var(--color-brown-dark);
  pointer-events: none;
}
/* ярлык «Возможности» на бирке со скрепкой */
.cap__tag {
  left: 39.5%;
  top: 19.4%;
  --r: -12.5deg;
  font-size: 5.4cqw;
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}
/* заголовок блока — как заголовки секций сайта: капс, акцент коричнево-золотым */
.cap__title {
  left: 53%;
  top: 55%;
  width: 64%;
  --r: -4deg;
  font-size: 8.8cqw;
  line-height: 1.06;
  text-transform: uppercase;
}
.cap__title em { font-style: normal; color: var(--color-brown-mid); }
.cap__note {
  font-size: 6.2cqw;
  line-height: 1.15;
}
.cap__card--1 .cap__note { left: 53%; top: 80.3%; width: 52%; --r: -4deg; }
.cap__card--3 .cap__note { left: 50.5%; top: 83.8%; width: 66%; }

/* ============================================================
   PHASE 3 — СРАВНЕНИЕ «Разница видна с одного взгляда»
   Figma 668:2, локальный отсчёт от Y=2110
   ============================================================ */

#comparison {
  position: absolute;
  top: 1438px;
  left: 0;
  width: 100%;
  height: 836px;
  z-index: 3;
}

.cmp__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 836px;
}

/* Карточка-подложка в золотой рамке (Figma 668:24) */
.cmp__panel {
  position: absolute;
  left: 54px;
  top: 22px;
  width: 1294px;
  height: 760px;
  background: url('../assets/img/v2/cmp-panel-2.webp') 0 0 / 100% 100% no-repeat;
  filter: drop-shadow(0 14px 30px rgba(59, 35, 20, 0.22));
  z-index: 1;
}

/* Корона перед заголовком — растр crown-gold.png (132×111, ratio 1.189),
   вырезанный из той же плашки «ТОП-5»; пропорции сохранены точно, чтобы
   при масштабировании не сплющивалась. */
.cmp__crown {
  position: absolute;
  left: 98px;
  top: 58px;
  width: 44px;
  height: 37px;
  z-index: 3;
  filter: drop-shadow(0 1px 1px rgba(139, 85, 24, .35));
}

.cmp__title {
  position: absolute;
  left: 162px;
  top: 54px;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 51px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}
.cmp__subtitle {
  position: absolute;
  left: 164px;
  top: 116px;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 40px;
  line-height: 46px;
  color: var(--color-brown-dark);
}

/* --- Слайдер до/после (Figma 668:70-76) --- */
.cmp__slider {
  position: absolute;
  left: 96px;
  top: 238px;
  width: 761px;
  height: 481px;
  border-radius: 29px;
  overflow: hidden;
  z-index: 3;
  cursor: ew-resize;
  user-select: none;
  box-shadow: 0 10px 26px rgba(59, 35, 20, 0.22);
  --slider-pos: 70.6%;
}
.cmp__img {
  position: absolute;
  inset: 0;
  width: 761px;
  height: 481px;
  object-fit: cover;
  max-width: none;
  pointer-events: none;
}
.cmp__before-wrap {
  position: absolute;
  inset: 0;
  overflow: hidden;
  clip-path: inset(0 0 0 var(--slider-pos));
  pointer-events: none;
}
.cmp__divider {
  position: absolute;
  top: 0;
  left: 70.6%;
  width: 2px;
  height: 100%;
  background: var(--color-white);
  z-index: 4;
  pointer-events: none;
}
.cmp__handle {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 55px;
  height: 55px;
  border-radius: 50%;
  background: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(59, 35, 20, 0.25);
}
.cmp__handle svg { width: 24px; height: 24px; }

.cmp__label {
  position: absolute;
  left: 380px;                    /* по центру фото слайдера */
  top: 404px;                     /* у нижнего края кадра, как в макете */
  transform: translateX(-50%);    /* плашка растёт симметрично от центра */
  width: auto;
  height: 39px;
  padding: 0 26px;
  border-radius: 33px;
  background: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;            /* всегда одна строка — текст не вылезает за плашку */
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 19px;
  color: var(--color-brown-mid);
  z-index: 5;
  pointer-events: none;
}

/* Сургучная печать с лентой */
.cmp__seal {
  position: absolute;
  left: 878px;
  top: 190px;
  width: 470px;
  height: 470px;
  max-width: none;
  z-index: 4;
  pointer-events: none;
  filter: drop-shadow(0 8px 16px rgba(59, 35, 20, 0.32));   /* чистая PNG-вырезка без белой подложки */
  animation: sealIn 0.8s var(--ease-soft) both;
}
@keyframes sealIn {
  from { opacity: 0; transform: scale(0.86) rotate(-8deg); }
  to   { opacity: 1; transform: none; }
}

/* ============================================================
   PHASE 4 — РАЗВОРОТ БЛОКНОТА: СТОИМОСТЬ + ЛОФТ
   Figma 668:21, локальный отсчёт от глобального Y = 2958
   ============================================================ */

#cost {
  position: relative;
  width: 100%;
  height: 1390px;
  margin-top: -642px;      /* блокнот заходит на низ крафта: 3600 − 2958 */
  z-index: 4;
}

.note__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 1390px;
}

.note__anchor {
  position: absolute;
  top: 100px;
  left: 0;
  width: 1px;
  height: 1px;
}

.note__spread {
  position: absolute;
  left: 61px;
  top: 40px;
  width: 1278px;
  height: 831px;         /* ровно родные пропорции book-empty.webp (1920×1248) — без леттербокса */
  max-width: none;
  z-index: 1;
  pointer-events: none;
  object-fit: contain; /* книга показывается целиком, без обрезки и растяжения */
}

/* --- Общая типографика страниц блокнота --- */
.note__stage h2 {
  position: absolute;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 36px;
  line-height: 38px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}
.note__stage p {
  position: absolute;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 400;
  color: var(--color-brown-dark);
}

/* --- Левая страница: Лофт --- */
.note__paper-loft {
  position: absolute;
  left: 135px;
  top: 110px;
  width: 420px;
  height: 210px;
  max-width: none;
  z-index: 2;
  pointer-events: none;
}
.note__stage .note__h-loft   { left: 210px; top: 144px; font-size: 30px; line-height: 32px; }
.note__sub-loft { left: 209px; top: 183px; font-size: 26px; line-height: 26px; }

/* --- Превью видео --- */
.note__video {
  position: absolute;
  z-index: 3;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(59, 35, 20, 0.28);
  transition: transform 0.3s var(--ease-soft), box-shadow 0.3s ease;
}
.note__video img { width: 100%; height: 100%; object-fit: cover; display: block; }
.note__video:hover { transform: scale(1.02); box-shadow: 0 12px 28px rgba(59, 35, 20, 0.36); }
.note__video--loft { left: 160px; top: 270px; width: 450px; height: 282px; border-radius: 18px; }
.note__video--prog {
  left: 740px; top: 190px; width: 340px; height: 220px;
  border-radius: 12px;
  transform: rotate(7.78deg);
  box-shadow: 0 10px 24px rgba(59, 35, 20, 0.30);
}
.note__video--prog:hover { transform: rotate(7.78deg) scale(1.02); }
.note__play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  /* сплошной кружок — полностью закрывает белую кнопку, запечённую в превью-webp; без полупрозрачного кольца-«плашки» */
  width: 86px;
  height: 86px;
  border-radius: 50%;
  background: var(--color-gold);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35), inset 0 -3px 0 rgba(201, 138, 46, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s ease, transform 0.25s ease;
}
.note__play svg { width: 32px; height: 32px; margin-left: 4px; }
.note__play svg path { fill: #2A170C; }
.note__video:hover .note__play {
  background: #FFC75F;
  transform: translate(-50%, -50%) scale(1.08);
}

/* --- Отдельный блок под книгой: форма расчёта + контакты (на страницы блокнота
   больше не помещаются, книга стала компактнее) --- */
.note__stage .note__h-cost {
  left: 180px;
  top: 890px;
  font-size: 61px;
  line-height: 64px;
  letter-spacing: .035em;
  text-transform: uppercase;
}
.note__h-cost-em {
  color: var(--color-brown-mid);
  text-shadow: 0 1px 0 rgba(255, 255, 255, .45);
}
.note__accent-cost{ left: 182px; top: 1012px; font-size: 48px; line-height: 56px; }

.note__form-card {
  position: absolute;
  left: 175px;
  top: 1095px;
  width: 517px;
  height: 196px;
  z-index: 4;
}
/* Пергаментная плашка с золотой рамкой: рисуется псевдоэлементом ЗА содержимым,
   поэтому абсолютные координаты полей внутри .note__form не сдвигаются.
   border-image держит углы неискажёнными при любой пропорции коробки. */
.note__form-card::before {
  content: '';
  position: absolute;
  inset: -16px -20px;
  border: 20px solid transparent;
  border-image: url('../assets/img/plashka.webp') 100 fill / 20px stretch;
  filter: drop-shadow(0 8px 18px rgba(59, 35, 20, 0.26));
  pointer-events: none;
}
.note__form { position: relative; z-index: 1; width: 100%; height: 100%; }
/* сообщение после отправки: «Спасибо!» на 1-й строке, остальное на 2-й, по центру плашки */
.note__form .cost__success {
  position: absolute;
  inset: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 0 22px;
  text-align: center;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 22px;
  line-height: 1.3;
  color: var(--color-brown-dark);
}
.note__form .cost__success b { font-weight: 400; font-size: 28px; }
.note__form-label {
  position: absolute;
  left: 20px;
  top: 15px;
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 18px;
  color: var(--color-brown-dark);
  white-space: nowrap;
}
.note__input {
  position: absolute;
  left: 20px;
  top: 55px;
  width: 472px;
  height: 48px;
  border-radius: 11px;
  border: 1px solid #D9D2C8;
  background: var(--color-white);
  padding: 0 18px;
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 18px;
  color: var(--color-brown-dark);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.note__input::placeholder { color: #B0B0B0; }
.note__input:focus { border-color: var(--color-gold); box-shadow: 0 0 0 3px rgba(245,177,67,0.20); }

.note__consent {
  position: absolute;
  left: 20px;
  top: 118px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  width: 224px;
  font-family: var(--font-text);
  font-size: 11px;
  line-height: 13px;
  color: #8B7967;
  cursor: pointer;
}
.note__check { width: 13px; height: 13px; margin: 0; accent-color: var(--color-gold); flex: none; }
.note__consent a { color: var(--color-brown-mid); text-decoration: underline; }

.note__btn {
  position: absolute;
  left: 252px;
  top: 133px;
  width: 253px;
  height: 47px;
  z-index: 0;
  border: none;
  border-radius: 37px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  box-shadow: var(--shadow-btn);
  transition: box-shadow 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}
.note__btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.note__btn:hover:not(:disabled) { box-shadow: 3px 6px 12px rgba(0,0,0,0.18); color: var(--color-brown-dark); }
.note__btn:hover:not(:disabled)::after { opacity: 1; }
.note__btn:disabled { opacity: 0.55; cursor: not-allowed; }

/* --- Бейджи-звёзды --- */
.note__badge {
  position: absolute;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}
.note__badge img { position: absolute; inset: 0; width: 100%; height: 100%; }
.note__badge span {
  position: relative;
  font-family: var(--font-text);
  font-weight: 700;
  font-size: 18px;
  line-height: 22px;
  color: var(--color-white);
  text-align: center;
}
.note__badge--calc  { left: 105px;  top: 1230px; width: 116px; height: 116px; }
.note__badge--calc span { font-size: 16px; line-height: 17px; }
.note__badge--watch { left: 1035px; top: 325px; width: 104px; height: 104px; }
.note__badge--watch span { font-size: 14px; line-height: 15px; }

/* --- Свяжитесь с нами сами (правая колонка блока под книгой) --- */
.note__stage .note__h-contact { left: 800px; top: 1030px; }
.note__socials {
  position: absolute;
  left: 820px;
  top: 1138px;
  width: 400px;
  height: 118px;
  z-index: 4;
}
/* Каждая ссылка сама рисует СВОЮ печать из общего note-socials.webp (1742×513):
   раньше печати были фоном контейнера, а ссылки — невидимые круги 68px подряд
   слева (6–254px), и печать ВК (286–397px) вообще не нажималась; ховер
   увеличивал невидимую ссылку. Координаты — по альфе картинки, в % от
   контейнера, поэтому совпадают и на мобилке (там контейнер резиновый).
   background-position в %: left / (W − w). */
.note__socials a {
  position: absolute;
  top: 1.75%;              /* 9 / 513 */
  height: 96.1%;           /* 493 / 513 */
  border-radius: 50%;
  background: url('../assets/img/v2/note-socials.webp') no-repeat;
  background-size: 362.2% 104.1%;   /* 1742 / w, 513 / 493 — w у каждой печати свой, см. ниже */
  filter: drop-shadow(0 5px 9px rgba(59, 35, 20, 0.28));   /* чистая PNG-вырезка без белой подложки */
  transition: transform 0.45s var(--ease-spring), filter 0.3s ease;
}
.note__socials a:nth-child(1) { left: 0.52%;  width: 27.61%; --bp: 0.71% 45%;  --bs: 362.2% 104.1%; --gd: 0s; }     /* звонок: 9…490 */
.note__socials a:nth-child(2) { left: 36.4%;  width: 27.44%; --bp: 50.16% 45%; --bs: 364.4% 104.1%; --gd: 0.25s; }  /* Max: 634…1112 */
.note__socials a:nth-child(3) { left: 71.64%; width: 27.73%; --bp: 99.13% 45%; --bs: 360.7% 104.1%; --gd: 0.5s; }   /* ВК: 1248…1731 */
.note__socials a { background-position: var(--bp); background-size: var(--bs); }
/* лёгкая анимация: печать приподнимается и чуть поворачивается, тень глубже */
.note__socials a:hover,
.note__socials a:focus-visible {
  transform: translateY(-5px) rotate(-7deg) scale(1.08);
  filter: drop-shadow(0 12px 16px rgba(59, 35, 20, 0.36));
}
.note__socials a:active {
  transform: translateY(-1px) rotate(-3deg) scale(0.95);
  transition-duration: 0.12s;
}
.note__socials a:focus-visible { outline: 2px solid var(--color-gold); outline-offset: 4px; }

/* ---------- Блик по сургучным печатям (обе группы: «Свяжитесь с нами сами»
   и первый экран) — привлекает внимание к кнопкам мессенджеров.
   Раз в 4 с по печатям по очереди (--gd) пробегает глянцевый блик, в этот
   же момент печать чуть «вздрагивает» (scale — отдельное свойство, ховер
   с transform не ломает). Блик обрезан маской ТОЙ ЖЕ картинки, что и печать
   (--bs/--bp), поэтому ложится только на воск, а не на фон вокруг.
   За экраном анимация на паузе (site-fx.js → .sfx-off). */
.note__socials a::after,
.hero__social-icon::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  /* полоса ~0.7 ширины печати; при size 250% позиция 100% → 0% проводит её
     от «только вошла слева» до «только вышла справа» — виден весь проход */
  background: linear-gradient(115deg,
    rgba(255, 236, 228, 0) 36%,
    rgba(255, 236, 228, 0.4) 45%,
    rgba(255, 255, 255, 0.9) 50%,
    rgba(255, 236, 228, 0.4) 55%,
    rgba(255, 236, 228, 0) 64%) no-repeat;
  background-size: 250% 100%;
  background-position: 100% 0;
  -webkit-mask: url('../assets/img/v2/note-socials.webp') no-repeat;
          mask: url('../assets/img/v2/note-socials.webp') no-repeat;
  -webkit-mask-size: var(--bs);
          mask-size: var(--bs);
  -webkit-mask-position: var(--bp);
          mask-position: var(--bp);
  animation: sealGlint 4s var(--ease-inout) var(--gd, 0s) infinite;
}
@keyframes sealGlint {            /* проход 1.2 с, потом пауза до следующего круга */
  0%        { background-position: 100% 0; }
  30%, 100% { background-position: 0% 0; }
}
.note__socials a {
  animation: sealNudge 4s ease-in-out var(--gd, 0s) infinite;
}
@keyframes sealNudge {            /* «вздрагивает», пока по ней идёт блик */
  0%, 30%, 100% { scale: 1; }
  15%           { scale: 1.07; }
}
@media (prefers-reduced-motion: reduce) {
  .note__socials a,
  .note__socials a::after,
  .hero__social-icon::after { animation: none; }
}

/* --- Правая страница --- */
.note__stage .note__h-prog      { left: 740px; top: 80px; font-size: 26px; line-height: 28px; }
.note__accent-prog { left: 740px; top: 136px; font-size: 28px; line-height: 34px; }

/* «Место, где детские мечты…» + марки — отдельный блок под видео, на книгу не пересобирается,
   только сдвинут вверх (было top 661/768…, книга стала короче).
   Свой font-size — по умолчанию блок наследует от .note__stage h2 (36px), а на
   width: 540px это давало «МЕЧТЫ» вплотную к правому краю страницы книги;
   28px тот же приём, что уже применён к note__h-loft/note__h-prog по соседству. */
.note__h-dream     { left: 724px; top: 445px; width: 540px; font-size: 28px; line-height: 32px; }
.note__h-dream em  { font-style: normal; color: var(--color-brown-mid); }

/* Враппер марок — только для мобильной сетки, на десктопе не участвует в вёрстке */
.note__stamps { display: contents; }

/* Марки — одна марка-шаблон в стиле сайта: светлая бумага с перфорацией,
   золотая двойная рамка как у пергаментных плашек, надпись — шрифтами сайта.
   Все пять одного размера и без наклона, ровными рядами: на левой странице —
   от левого края видео, на правой — от левого края заголовка. Кегль и отступы
   в cqw — от ширины самой марки, поэтому так же ложится и в мобильной сетке. */
.note__stamp {
  position: absolute;
  z-index: 3;
  width: 140px;
  aspect-ratio: 122 / 100;
  container-type: inline-size;
  filter: drop-shadow(0 1px 1px rgba(59, 35, 20, 0.22)) drop-shadow(0 6px 10px rgba(59, 35, 20, 0.22));
  transition: transform 0.3s var(--ease-soft);
}
.note__stamp:hover { transform: translateY(-5px); }
.note__stamp-paper {
  --r: 3.2px;   /* радиус зубца перфорации */
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0 11cqw;
  text-align: center;
  /* тёплый пергамент: текстура сайта + кремовая подсветка к центру */
  background:
    radial-gradient(ellipse at 50% 45%, rgba(255, 246, 226, 0.75), rgba(240, 220, 182, 0.15) 75%),
    url('../assets/img/v2/paper-strip.webp') center / cover,
    #EFDDBC;
  /* перфорация: сетка кругов по краю + сплошная середина */
  -webkit-mask:
    radial-gradient(var(--r), #0000 97%, #000) round calc(-1.5 * var(--r)) calc(-1.5 * var(--r)) / calc(3 * var(--r)) calc(3 * var(--r)),
    linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 3 * var(--r)) calc(100% - 3 * var(--r));
          mask:
    radial-gradient(var(--r), #0000 97%, #000) round calc(-1.5 * var(--r)) calc(-1.5 * var(--r)) / calc(3 * var(--r)) calc(3 * var(--r)),
    linear-gradient(#000 0 0) no-repeat 50% / calc(100% - 3 * var(--r)) calc(100% - 3 * var(--r));
}
/* золотая двойная рамка — как кант у пергаментных плашек сайта */
.note__stamp-paper::before {
  content: '';
  position: absolute;
  inset: 8.5cqw;
  border: 3px double #B68945;
  border-radius: 2px;
  pointer-events: none;
}
.note__stamp-top {
  display: block;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 10px;
  font-size: 6.8cqw;
  line-height: 1.15;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-brown-mid);
}
/* тонкая золотая черта между строками */
.note__stamp-top::after {
  content: '';
  display: block;
  width: 22cqw;
  height: 1px;
  margin: 2.6cqw auto 2.4cqw;
  background: linear-gradient(90deg, rgba(182, 137, 69, 0), #B68945, rgba(182, 137, 69, 0));
}
.note__stamp-main {
  display: block;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 19px;
  font-size: 13.6cqw;
  line-height: 1.05;
  color: var(--color-brown-dark);
}
/* слева — два от края видео (x 160), справа — три от края заголовка (x 724), шаг 164 */
.note__stamp--1 { left: 160px; top: 578px; }
.note__stamp--4 { left: 324px; top: 578px; }
.note__stamp--2 { left: 724px; top: 578px; }
.note__stamp--3 { left: 888px; top: 578px; }
.note__stamp--5 { left: 1052px; top: 578px; }

/* ============================================================
   PHASE 7 — ПРОГРАММЫ «Новинки каждый год»
   Figma 668:15/668:16, локальный отсчёт от глобального Y = 6276
   ============================================================ */

#programs {
  position: relative;
  width: 100%;
  height: 1307px;
  margin-top: -165px;      /* подтянуть блок к «Возможностям», убрать зазор */
  z-index: 2;              /* ниже #capabilities (3): рваный низ крафт-карты ложится ПОВЕРХ прямого верха стены */
  overflow: hidden;
}

.prog__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 1307px;
}

.prog__wall {
  position: absolute;
  left: 50%;
  top: 0;                 /* рваный край стены впритык к нижней кромке крафт-карты — без коричневой полосы */
  /* 2322px = 1307 * (2560/1441) — коробка ровно в пропорциях самой картинки,
     поэтому cover не режет её на узких экранах. На широких коробка = 100vw,
     картинка тянется во всю ширину экрана в родных пропорциях (подрезается снизу). */
  width: max(2322px, calc(100vw / var(--stage-scale, 1)));
  height: 1307px;
  transform: translateX(-50%);
  background: url('../assets/img/programs_bg.webp') center top / cover no-repeat;
  z-index: 1;
  pointer-events: none;
}

.prog__title {
  position: absolute;
  left: 96px;
  top: 188px;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 51px;
  text-transform: uppercase;
  /* у Neuzeit Antiqua пробел всего 0.2em — в капсе слова слипаются, добиваем */
  letter-spacing: .02em;
  word-spacing: .18em;
  color: var(--color-white);
}
.prog__subtitle {
  position: absolute;
  left: 92px;
  top: 252px;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 32px;
  line-height: 37px;
  color: var(--color-white);
}

/* --- Фильтры по возрасту (Figma 668:103-124) --- */
.prog__filters {
  position: absolute;
  left: 92px;
  top: 383px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 18px;
}
.prog__pill {
  height: 37px;
  border: none;
  border-radius: 46px;
  background: var(--color-white);
  color: var(--color-brown-dark);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 18px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.prog__pill--wide { width: 108px; }
.prog__pill--num  { width: 38px; }
.prog__pill:hover { transform: translateY(-2px); }
.prog__pill.is-active { background: var(--color-gold); color: var(--color-brown-dark); }

/* --- Плавающая карточка-CTA (Figma 668:172) --- */
.prog__cta {
  position: absolute;
  left: 1029px;
  top: 146px;
  width: 497px;
  height: 380px;
  z-index: 6;
}
.prog__cta-lion {
  position: absolute;
  left: 131px;
  top: -6px;
  width: 141px;
  height: 141px;
  z-index: 2;
  transform: rotate(180deg);   /* лев «правильной» стороной — облокачивается на плашку */
  pointer-events: none;
}
.prog__cta-card {
  position: absolute;
  left: 0;
  top: 126px;
  width: 285px;
  height: 240px;
  z-index: 1;
}
/* Пергаментная плашка — псевдоэлементом за содержимым: border на самом блоке
   сдвинул бы padding-box и увёл абсолютные координаты title/desc/btn/social. */
.prog__cta-card::before {
  content: '';
  position: absolute;
  inset: -12px -14px;
  border: 14px solid transparent;
  border-image: url('../assets/img/plashka.webp') 100 fill / 14px stretch;
  filter: drop-shadow(0 8px 20px rgba(59, 35, 20, 0.26));
  pointer-events: none;
}
.prog__cta-title {
  position: absolute;
  left: 16px;
  top: 15px;
  margin: 0;
  width: 255px;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 23px;
  line-height: 24px;
  text-transform: uppercase;
  white-space: nowrap;   /* две строки через <br>; перенос внутри строки наезжал на описание */
  color: #5A2F15;
}
.prog__cta-title span { font-weight: 700; color: var(--color-gold); }
.prog__cta-price { font-weight: 700; color: var(--color-gold); }
.prog__cta-desc {
  position: absolute;
  left: 16px;
  top: 77px;
  margin: 0;
  width: 250px;
  font-family: var(--font-text);
  font-size: 13px;
  line-height: 15px;
  color: var(--color-brown-dark);
}
.prog__cta-btn {
  position: absolute;
  left: 16px;
  top: 125px;
  width: 253px;
  height: 47px;
  z-index: 0;
  border-radius: 37px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-btn);
  transition: box-shadow 0.2s ease, color 0.2s ease;
}
.prog__cta-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.prog__cta-btn:hover { box-shadow: 3px 6px 12px rgba(0,0,0,0.18); color: var(--color-brown-dark); }
.prog__cta-btn:hover::after { opacity: 1; }
.prog__cta-social {
  position: absolute;
  left: 86px;
  top: 184px;
  width: 114px;
  height: 39px;
  background: url('../assets/img/v2/prog-socials-2.webp') center / contain no-repeat;
  display: flex;
  align-items: center;
  gap: 6px;
  padding-left: 4px;
}
.prog__cta-social a {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  transition: transform 0.2s ease;
}
.prog__cta-social a:hover { transform: scale(1.1); }

/* --- Карусель программ (свайп + стрелки) --- */
.prog__carousel {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
}
.prog__carousel > * { pointer-events: auto; }

/* Лента — родная горизонтальная прокрутка с примагничиванием к карточкам:
   свайп пальцем и тачпадом работают сами (main.js initProgramsCarousel).
   Кадр — 3 карточки (842px = 3 * 260 + 2 * 31); по бокам ещё по 28px поля,
   где уезжающая карточка плавно гаснет (маска), а не режется краем. Поле
   уже зазора между карточками (31px): в покое соседняя в него не заходит. */
.prog__viewport {
  position: absolute;
  left: 251px;                    /* 279 − 28 */
  top: 522px;
  width: 898px;                   /* 842 + 2 * 28 */
  height: 480px;
  /* прокрутка режет и вертикаль, поэтому подъём карточки на ховере и
     свечение живут внутри верхнего паддинга, а не за границей вьюпорта */
  padding: 30px 0 0;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 28px;
  overscroll-behavior-x: contain; /* у края ленты не листать историю браузера жестом */
  scrollbar-width: none;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 28px, #000 calc(100% - 28px), transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 28px, #000 calc(100% - 28px), transparent 100%);
  outline: none;
  cursor: grab;
}
.prog__viewport::-webkit-scrollbar { display: none; }
/* тянут мышью: без примагничивания, иначе лента дёргается к карточкам */
.prog__viewport.is-grabbing { scroll-snap-type: none; cursor: grabbing; }

.prog__track {
  display: flex;
  gap: 31px;
  width: max-content;
  height: 371px;
  padding: 0 28px;                /* = scroll-padding: крайние карточки встают в кадр */
}

.prog__card {
  position: relative;
  flex: 0 0 260px;
  scroll-snap-align: start;
  width: 260px;
  height: 371px;                  /* пропорция полароида prog-polaroid.webp 1118x1596 */
  cursor: pointer;
  transition: transform 0.45s var(--ease-soft);
  animation: progCardIn 0.55s ease both;
  animation-delay: calc(min(var(--card-i, 0), 6) * 70ms);
}
.prog__card.is-hidden { display: none; }
.prog__card:hover,
.prog__card:focus-visible { transform: translateY(-14px); z-index: 5; }
/* фокус с клавиатуры: не прямоугольная рамка вокруг карточки, а то же тёплое
   свечение, что на ховере, + подъём и подчёркнутое название */
.prog__card:focus-visible { outline: none; }
.prog__card:focus-visible::before { opacity: 1; }
.prog__card:focus-visible .prog__card-title {
  text-decoration: underline 2px var(--color-gold);
  text-underline-offset: 3px;
}

@keyframes progCardIn {
  from { opacity: 0; filter: blur(7px); }
  to   { opacity: 1; filter: blur(0); }
}

/* Тёплое свечение за полароидом — включается на ховере */
.prog__card::before {
  content: "";
  position: absolute;
  inset: -6% -9% -4%;
  z-index: 0;
  border-radius: 24px;
  background: radial-gradient(58% 54% at 50% 40%, rgba(255, 199, 104, 0.55), rgba(255, 170, 60, 0) 72%);
  filter: blur(12px);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}
.prog__card:hover::before { opacity: 1; }

/* Фото в окне полароида (с 22.10.2026; раньше — арка, резавшая фото).
   Окно квадратное: горизонтальные фото режутся по бокам, вертикальные —
   снизу, лица держит object-position (верхняя треть кадра). */
.prog__card-photo {
  position: absolute;
  top: 3.7%;
  left: 5.4%;
  right: 5.6%;
  bottom: 34%;
  overflow: hidden;
  background: #3B2314;
  transition: filter 0.32s ease;
  z-index: 1;
}
.prog__card-img {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 50% 30%;
  transition: transform 0.6s var(--ease-soft);
}
/* лёгкая тень по краю окна — фото «утоплено» под бумагу */
.prog__card-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  box-shadow: inset 0 0 14px rgba(20, 12, 6, 0.4);
  pointer-events: none;
}
/* Полароид поверх фото — та же бумага, что у полароидов на карте */
.prog__card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: url('../assets/img/v2/prog-polaroid.webp') center / 100% 100% no-repeat;
  z-index: 2;
  pointer-events: none;
  /* тень по силуэту бумаги, а не прямоугольником — полароид лежит на стене */
  filter: drop-shadow(0 10px 16px rgba(28, 16, 8, 0.42));
  transition: filter 0.42s ease;
}
.prog__card:hover::after { filter: drop-shadow(0 22px 30px rgba(28, 16, 8, 0.55)); }
.prog__card:hover .prog__card-photo { filter: brightness(1.08) saturate(1.05); }
.prog__card:hover .prog__card-img { transform: scale(1.05); }

/* Золотая пилюля «Подробнее» — выезжает на ховере, внизу фото */
.prog__card-cta {
  position: absolute;
  left: 50%;
  bottom: 38%;
  z-index: 3;
  padding: 9px 22px;
  border-radius: 30px;
  background: var(--color-gold);
  color: var(--color-brown-dark);
  font-family: var(--font-text);
  font-weight: 700;
  font-size: 14px;
  line-height: 1;
  letter-spacing: 0.02em;
  white-space: nowrap;
  box-shadow: 0 6px 16px rgba(28, 16, 8, 0.45);
  opacity: 0;
  transform: translate(-50%, 10px);
  transition: opacity 0.3s ease, transform 0.34s var(--ease-soft);
  pointer-events: none;
}
.prog__card:hover .prog__card-cta { opacity: 1; transform: translate(-50%, 0); }

/* Подпись — на нижнем поле полароида, как подписи полароидов на карте:
   название шрифтом заголовков, возраст — гротеском капсом */
.prog__card-plate {
  position: absolute;
  left: 9%;
  right: 9%;
  top: 67%;
  bottom: 6.5%;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.prog__card-title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 21px;
  line-height: 1.05;
  color: var(--color-brown-dark);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.prog__card-age {
  margin: 7px 0 0;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 11px;
  line-height: 1.2;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-brown-mid);
}

/* Полоса прокрутки + счётчик под каруселью */
.prog__meter {
  position: absolute;
  left: 279px;
  top: 1016px;
  width: 842px;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 20px;
  pointer-events: none;
}
.prog__meter-track {
  flex: 1;
  height: 4px;
  border-radius: 4px;
  background: rgba(255, 238, 210, 0.24);
  overflow: hidden;
}
.prog__meter-bar {
  display: block;
  height: 100%;
  width: 30%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--color-gold), #FFE3AC);
  box-shadow: 0 0 10px rgba(245, 177, 67, 0.7);
  transition: width 0.42s var(--ease-inout), margin-left 0.42s var(--ease-inout);
}
.prog__meter-count {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 15px;
  line-height: 1;
  letter-spacing: 0.02em;
  /* под каруселью тёмный паркет — светлый текст с мягкой тенью */
  color: rgba(255, 246, 232, 0.94);
  text-shadow: 0 2px 7px rgba(18, 9, 3, 0.8);
  white-space: nowrap;
}

/* Круглые стрелки-навигация (Figma 738:83-86) */
.prog__nav {
  position: absolute;
  top: 687px;
  width: 60px;
  height: 60px;
  border: none;
  border-radius: 50%;
  background: var(--color-gold);
  color: var(--color-brown-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(30, 18, 10, 0.35);
  transition: transform 0.2s ease, opacity 0.2s ease, box-shadow 0.2s ease;
  z-index: 6;
}
.prog__nav svg { width: 24px; height: 24px; display: block; }
.prog__nav--prev { left: 207px; }
.prog__nav--next { right: 207px; }
.prog__nav:hover { transform: translateY(-2px); box-shadow: 0 10px 22px rgba(30, 18, 10, 0.45); }
.prog__nav.is-off { opacity: 0.3; pointer-events: none; }

/* ============================================================
   ПОП-АП ПРОГРАММЫ
   ============================================================ */

/* ============================================================
   ПЕРЕГОРОДКА между рулеткой и галереей — драпировка с облаками.
   Блок нулевой высоты на стыке секций: не двигает поток, картинка
   свисает вниз, в галерею (обе секции с overflow:hidden, поэтому
   элемент вынесен наружу, а не внутрь одной из них).
   ============================================================ */
.cloud-divider {
  position: relative;
  z-index: 4;
  height: 0;
  pointer-events: none;
}
/* Облака clouds2.png нигде не сплошные (в самом плотном ряду ~84 % пикселей
   непрозрачны), поэтому сквозь просветы читался прямой стык фона рулетки и
   галереи. Под облаками — вуаль цвета галереи: низ рулетки растворяется в
   ней к самому стыку, стыка больше не видно. */
.cloud-divider::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: calc(var(--cd-h) * 0.26);
  background: linear-gradient(to bottom,
    rgba(237, 230, 221, 0) 0%,
    rgba(237, 230, 221, 0.55) 45%,
    rgba(237, 230, 221, 0.92) 80%,
    rgba(237, 230, 221, 1) 100%);
}
.cloud-divider img {
  z-index: 1;
  position: absolute;
  left: 50%;
  /* тянем вверх: драпировка висит в рулетке, за стык свисает только кромка облаков */
  top: calc(var(--cd-h) * -0.72);
  width: var(--cd-w);
  height: auto;
  max-width: none;
  transform: translateX(-50%);
  display: block;
}

/* ============================================================
   PHASE 9 — ГАЛЕРЕЯ «Контент с наших праздников…»
   ============================================================ */

#gallery {
  position: relative;
  padding: 104px 0 96px;
  overflow: hidden;
  /* по ширине, не cover: на широких экранах секция высокая (коллаж в масштабе),
     и cover растягивал картинку 2560×1440 по высоте в разы — были видны пиксели */
  background: var(--color-paper) url('../assets/img/gallery-bg.webp') center top / max(100%, 2560px) auto no-repeat;
}

/* Кремовая вуаль поверх фона: текстура остаётся, декоративные снимки фона
   уходят на второй план, чтобы коллаж и заголовок читались */
#gallery::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg,
              rgba(237, 230, 221, 1)    0px,
              rgba(237, 230, 221, 0.72) 90px,
              rgba(237, 230, 221, 0.50) 26%,
              rgba(237, 230, 221, 0.44) 62%,
              rgba(237, 230, 221, 0.74) calc(100% - 110px),
              rgba(237, 230, 221, 1)    100%);
  pointer-events: none;
  z-index: 0;
}

/* ── Заголовок (типографика hero) ── */
.gal__header {
  position: relative;
  z-index: 2;
  width: 1400px;
  max-width: 100%;
  margin: 0 auto 58px;
  padding: 0 0 0 96px;
  box-sizing: border-box;
}

/* Золотой штрих-акцент над заголовком */
.gal__header::before {
  content: '';
  position: absolute;
  left: 96px;
  top: -26px;
  width: 74px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--color-gold) 0%, rgba(245,177,67,0) 100%);
}

.gal__title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 68px;
  line-height: 57px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}
.gal__title em { font-style: normal; color: var(--color-brown-mid); }

.gal__subtitle {
  margin: 26px 0 0 -4px;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 38px;
  line-height: 46px;
  color: var(--color-brown-dark);
}

/* ── Коллаж ── */
.gal__collage {
  display: flex;
  flex-direction: column;
  gap: 0;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  padding: 16px 0 0;
  position: relative;
  z-index: 1;
}

.gal__collage:active { cursor: grabbing; }
.gal__collage:active .gal__photo { cursor: grabbing; }

/* Стрелки навигации */
.gal__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 200;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: rgba(245, 238, 224, 0.95);
  -webkit-backdrop-filter: blur(6px);
          backdrop-filter: blur(6px);
  border: 1.5px solid rgba(245, 177, 67, 0.85);
  color: var(--color-brown-dark);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(59, 35, 20, 0.22);
  transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  flex-shrink: 0;
}

.gal__arrow:hover {
  background: var(--color-gold);
  border-color: var(--color-gold);
  transform: translateY(-50%) scale(1.09);
  box-shadow: 0 12px 30px rgba(59, 35, 20, 0.30);
}
.gal__arrow:active { transform: translateY(-50%) scale(0.97); }
.gal__arrow:focus-visible {
  outline: 3px solid var(--color-gold);
  outline-offset: 3px;
}

.gal__arrow--prev { left: 28px; }
.gal__arrow--next { right: 28px; }

/* Ряды накладываются друг на друга */
.gal__row {
  overflow: visible;
  position: relative;
  /* края уходят в фон, а не обрубаются */
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 96px, #000 calc(100% - 96px), transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 96px, #000 calc(100% - 96px), transparent 100%);
}

/* Каждый следующий ряд заходит поверх предыдущего.
   -166 = прежние -30 минус прирост padding у .gal__strip (22 → 70 сверху,
   22 → 110 снизу) — визуальный нахлёст карточек тот же. */
.gal__row + .gal__row { margin-top: -166px; }
/* маска создаёт stacking context, поэтому увеличенное фото поднимаем вместе с рядом */
.gal__row { z-index: 1; }
.gal__row:hover { z-index: 60; }

.gal__strip {
  display: flex;
  gap: 26px;
  align-items: flex-start;
  /* padding вмещает карточку при наведении: scale(1.16) + подъём на 10px +
     тень 0 26px 54px — mask-image у .gal__row режет всё за своим боксом, как
     overflow:hidden, поэтому снизу нужно ~100px, сверху ~65px */
  padding: 70px 0 110px;
  will-change: transform;
}

/* ── Polaroid-фото ── */
.gal__photo {
  flex-shrink: 0;
  width: 270px;
  background: #ffffff;
  padding: 13px 13px 52px;
  border-radius: 2px;
  box-shadow: 0 10px 26px rgba(59, 35, 20, 0.26),
              0 2px 6px rgba(59, 35, 20, 0.16);
  transform: rotate(var(--rot, 0deg));
  transition: transform 0.42s var(--ease-spring),
              box-shadow 0.42s ease;
  cursor: zoom-in;
  position: relative;
  z-index: 1;
}

.gal__photo:hover,
.gal__photo:focus-visible {
  transform: rotate(0deg) translateY(-10px) scale(1.16);
  box-shadow: 0 26px 54px rgba(59, 35, 20, 0.38),
              0 4px 12px rgba(59, 35, 20, 0.20);
  z-index: 50;
}

/* Обёртка изображения для zoom внутри рамки (создаётся в main.js) */
.gal__photo-img-wrap {
  overflow: hidden;
  display: block;
  width: 100%;
  background: #efe7dc;
  position: relative;
}

.gal__photo-img-wrap img,
.gal__photo > img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}

.gal__photo:hover .gal__photo-img-wrap img {
  transform: scale(1.07);
}

/* Лупа при наведении */
.gal__photo-img-wrap::after {
  content: '';
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(245, 177, 67, 0.94) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' viewBox='0 0 24 24' fill='none' stroke='%233B2314' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-4.2-4.2M11 8v6M8 11h6'/%3E%3C/svg%3E") center / 18px 18px no-repeat;
  box-shadow: 0 4px 12px rgba(59, 35, 20, 0.35);
  opacity: 0;
  transform: scale(0.7);
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: none;
}
.gal__photo:hover .gal__photo-img-wrap::after {
  opacity: 1;
  transform: scale(1);
}

.gal__photo-label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 19px;
  line-height: 1.1;
  color: var(--color-brown-mid);
  /* у Marck Script большой нижний вынос: без этого отступа текст
     визуально прилипает к фотографии */
  padding: 20px 10px 0;
  text-align: center;
  overflow: hidden;
  transition: color 0.25s ease;
}
.gal__photo:hover .gal__photo-label { color: var(--color-brown-dark); }

/* ── Подсказка ── */
.gal__hint {
  display: block;
  width: fit-content;
  margin: 34px auto 0;
  padding: 9px 20px;
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(245, 177, 67, 0.55);
  text-align: center;
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 14px;
  color: var(--color-brown-mid);
  letter-spacing: 0.04em;
  pointer-events: none;
  position: relative;
  z-index: 2;
}

/* ── Лайтбокс ── */
.gal__lightbox {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  /* visibility: закрытый лайтбокс с одной лишь opacity:0 оставался
     полноэкранным слоем и участвовал в композитинге на каждом кадре */
  visibility: hidden;
  transition: opacity 0.30s ease, visibility 0s linear 0.30s;
}

.gal__lightbox[aria-hidden="false"] {
  opacity: 1;
  pointer-events: all;
  visibility: visible;
  transition: opacity 0.30s ease, visibility 0s;
}

.gal__lb-bg {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.93);
  cursor: pointer;
}

.gal__lb-close {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  color: #fff;
  font-size: 18px;
  cursor: pointer;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.18s;
}

.gal__lb-close:hover { background: rgba(255, 255, 255, 0.28); }

.gal__lb-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  padding: 24px;
  max-width: 90vw;
  max-height: 90vh;
}

.gal__lb-img {
  max-width: 100%;
  max-height: calc(90vh - 80px);
  object-fit: contain;
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.85);
  border: 10px solid #fff;
  display: block;
}

.gal__lb-caption {
  color: rgba(255, 255, 255, 0.85);
  font-family: var(--font-head);
  font-size: 26px;
  line-height: 1.2;
  margin: 0;
  text-align: center;
  letter-spacing: 0.02em;
}

/* Навигация внутри лайтбокса */
.gal__lb-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  border: 1.5px solid rgba(245, 177, 67, 0.55);
  background: rgba(255, 255, 255, 0.10);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}
.gal__lb-nav:hover {
  background: var(--color-gold);
  border-color: var(--color-gold);
  color: var(--color-brown-dark);
  transform: translateY(-50%) scale(1.08);
}
.gal__lb-nav--prev { left: 24px; }
.gal__lb-nav--next { right: 24px; }

.gal__lb-counter {
  font-family: var(--font-text);
  font-size: 13px;
  letter-spacing: 0.10em;
  color: rgba(255, 255, 255, 0.55);
  margin: -6px 0 0;
}

@media (max-width: 768px) {
  .gal__lb-nav { width: 44px; height: 44px; }
  .gal__lb-nav--prev { left: 8px; }
  .gal__lb-nav--next { right: 8px; }
}

/* ============================================================
   PHASE 8.1 — УСИЛИТЕЛИ «Усилители вашего праздника»
   Figma 668:13/14/182/183, локальный отсчёт от глобального Y = 8803
   ============================================================ */

#boosters {
  position: relative;
  width: 100%;
  height: 1229px;
  overflow: hidden;
  z-index: 4;
  /* Бумага заходит НА стену «Программ», которая лежит выше (z-index 4 против 2),
     поэтому её рваный верх ложится на дерево, а не встык к нему. */
  margin-top: -150px;
  /* Тот же бумажный фон, что у блока «Возможности», но без книги:
     assets/img/v2/boosters-bg.webp — это book-bg.png, из которого книга и её
     тень заретушированы (освещение и тени листвы взяты интерполяцией от краёв
     зоны, фактура — мозаикой из чистых участков той же бумаги).
     Заливки цветом здесь быть не должно — ровно по той же причине, что и у
     #capabilities: над рваным краем у картинки прозрачные поля, и сквозь них
     должна просвечивать стена снизу. С --color-paper на их месте шла белая
     полоса поперёк всей ширины.
     ВТОРЫМ слоем (то есть НИЖЕ первого) идёт paper-strip.webp — бесшовная по
     горизонтали полоса той же бумаги, прижатая к низу. Она закрывает такой же
     прозрачный зазор под нижним рваным краем, где иначе до самой «Рулетки»
     тянулась плоская светлая полоса. Верх при этом остаётся прозрачным, и
     стена «Программ» по-прежнему видна. */
  background:
    url('../assets/img/v2/boosters-bg.webp') center / cover no-repeat,
    url('../assets/img/v2/paper-strip.webp') bottom center / auto 300px repeat-x;
}

.bst__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 1229px;
}

.bst__title {
  position: absolute;
  left: 96px;
  top: 166px;
  margin: 0;
  z-index: 4;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 51px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}
.bst__subtitle {
  position: absolute;
  left: 92px;
  top: 229px;
  margin: 0;
  z-index: 4;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 36px;
  line-height: 44px;
  color: var(--color-brown-dark);
}

.bst__suitcase {
  position: absolute;
  left: 258px;
  top: 385px;
  width: 916px;
  height: 610px;
  max-width: none;
  z-index: 4;
  container-type: inline-size;
}
.bst__suitcase-img { display: block; width: 100%; height: 100%; max-width: none; }
/* Подпись наклейки — новая плашка поверх старой (на картинке плашки с надписями
   были нарисованы вместе с текстом и чисто не вытираются): бумага сайта, двойная
   тонкая рамка в цвет наклейки, текст шрифтом заголовков. Размеры — в cqw от
   ширины картинки, центр и наклон — по старой плашке. */
.bst__label {
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: var(--w);
  height: var(--h);
  transform: translate(-50%, -50%) rotate(var(--r));
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: 0 1.2cqw;
  border-radius: 0.9cqw;
  background: linear-gradient(180deg, #FAEFD8, #F1DFBC);
  border: 0.22cqw solid var(--line);
  box-shadow: inset 0 0 0 0.4cqw #F7E9CD, inset 0 0 0 0.5cqw var(--line), 0 0.25cqw 0.5cqw rgba(40, 20, 8, 0.35);
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 2.85cqw;
  line-height: 1;
  white-space: nowrap;
  color: var(--color-brown-dark);
  pointer-events: none;
}

/* ============================================================
   PHASE 8.2 — РУЛЕТКА «Подарок при заказе праздника»
   Figma 668:132/68/184, локальный отсчёт от глобального Y = 10294
   ============================================================ */

#roulette {
  position: relative;
  width: 100%;
  height: 877px;
  overflow: hidden;
  background: var(--color-paper) url('../assets/img/roulete-bg.webp') center / cover no-repeat;
  z-index: 3;
}

.rl__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 877px;
}

/* --- Золотой разделитель на стыке с «Усилителями» ---
   Бумага сверху и бордовая штора снизу сходятся встык, и граница читается
   как случайный обрыв. Линия набрана теми же двумя золотыми, что рамка
   рулетки и полоса прогресса у «Программ» (--color-gold → #FFE3AC), гаснет
   к краям экрана и подсвечена мягким свечением, чтобы работать и на светлой
   бумаге, и на тёмной шторе. Ромб по центру — тот же винтажный акцент, что
   у звёзд на фоне рулетки. */
#roulette::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 4px;
  z-index: 4;
  pointer-events: none;
  background: linear-gradient(90deg,
    rgba(245, 177, 67, 0) 0%,
    rgba(245, 177, 67, .35) 10%,
    var(--color-gold) 32%,
    #FFE3AC 50%,
    var(--color-gold) 68%,
    rgba(245, 177, 67, .35) 90%,
    rgba(245, 177, 67, 0) 100%);
  box-shadow: 0 0 22px rgba(245, 177, 67, .7),
              0 2px 0 rgba(59, 35, 20, .18);
}
#roulette::after {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  width: 14px;
  height: 14px;
  z-index: 5;
  pointer-events: none;
  transform: translate(-50%, 1px) rotate(45deg);
  background: linear-gradient(135deg, #FFE3AC 0%, var(--color-gold) 55%, #C98A2E 100%);
  box-shadow: 0 0 12px rgba(245, 177, 67, .6);
}

.rl__title {
  position: absolute;
  left: 96px;
  top: 60px;
  margin: 0;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 51px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}
.rl__title em { font-style: normal; color: var(--color-brown-mid); }
.rl__subtitle {
  position: absolute;
  left: 92px;
  top: 128px;
  margin: 0;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 32px;
  line-height: 40px;
  color: var(--color-brown-dark);
}

.rl__btn {
  position: absolute;
  left: 96px;
  top: 300px;
  width: 253px;
  height: 47px;
  z-index: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 37px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  box-shadow: var(--shadow-btn);
  transition: box-shadow 0.2s ease, color 0.2s ease;
}
.rl__btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.rl__btn:hover { box-shadow: 3px 6px 12px rgba(0,0,0,0.18); color: var(--color-brown-dark); }
.rl__btn:hover::after { opacity: 1; }

.rl__hint-text {
  position: absolute;
  left: 98px;
  top: 366px;
  margin: 0;
  font-family: var(--font-text);
  font-size: 15px;
  color: #7A6353;
}

.rl__wheel-img {
  position: absolute;
  left: 720px;
  top: 107px;
  width: 587px;
  height: 770px;
  max-width: none;
  object-fit: contain;
  cursor: pointer;
  transition: transform 0.4s var(--ease-soft);
}
.rl__wheel-img:hover { transform: rotate(-2deg) scale(1.03); }

.rl__modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
  align-items: center;
  justify-content: center;
}
.rl__modal.is-open { display: flex; }

.rl__modal-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(55% 55% at 30% 50%, rgba(245, 177, 67, 0.22), transparent 70%),
    rgba(34, 18, 9, 0.72);
  backdrop-filter: blur(7px);
  cursor: pointer;
}

/* Окно рулетки — бумажная карточка в золотой рамке, как форма «Контакты»
   (plashka.webp через border-image). Десктоп: колесо слева, текст и форма справа. */
.rl__modal-box {
  position: relative;
  z-index: 1;
  width: calc(100% - 40px);
  max-width: 1000px;
  max-height: 94vh;
  padding: 30px 44px 34px;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  border: 32px solid transparent;
  border-image: url('../assets/img/plashka.webp') 100 fill / 32px stretch;
  filter: drop-shadow(0 30px 60px rgba(20, 10, 4, 0.55));
  animation: rlPopIn 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
.rl__modal-box::-webkit-scrollbar { display: none; }
@keyframes rlPopIn {
  from { transform: translateY(28px) scale(0.94); opacity: 0; }
  to   { transform: none; opacity: 1; }
}

.rl__modal-close {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 3;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1.5px solid rgba(159, 100, 41, 0.45);
  background: rgba(255, 250, 240, 0.8);
  cursor: pointer;
  font-size: 15px;
  color: var(--color-brown-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease, transform 0.3s ease;
}
.rl__modal-close:hover { background: var(--color-gold); color: #2A170C; transform: rotate(90deg); }

.rl__spin-view[hidden],
.rl__success-view[hidden] { display: none !important; }

.rl__spin-view {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: center;
  gap: 40px;
}

/* --- Колесо: рисует main.js (лицо — иллюстрация из секции rl-wheel-face.webp,
   обод с лампочками — canvas). Canvas 640×640, CSS тянет под колонку. --- */
.rl__wheel-wrap {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  filter: drop-shadow(0 22px 28px rgba(59, 35, 20, 0.4));
}
/* золотое сияние + медленно вращающиеся лучи за колесом */
.rl__wheel-wrap::before {
  content: '';
  position: absolute;
  inset: -16%;
  z-index: -1;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(255, 220, 150, 0.75) 0%, rgba(255, 214, 140, 0.35) 38%, rgba(255, 214, 140, 0) 66%),
    repeating-conic-gradient(from 0deg, rgba(245, 177, 67, 0.16) 0deg 9deg, transparent 9deg 22.5deg);
  -webkit-mask: radial-gradient(circle, #000 45%, transparent 70%);
          mask: radial-gradient(circle, #000 45%, transparent 70%);
  animation: rlRays 28s linear infinite;
}
@keyframes rlRays { to { rotate: 360deg; } }
/* блёстки вокруг колеса */
.rl__sparkles {
  position: absolute;
  inset: -6%;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(circle, #FFF6D8 0 2px, transparent 3px) 8% 22% / 100% 100% no-repeat,
    radial-gradient(circle, #FFE6A3 0 1.5px, transparent 2.5px) 92% 30% / 100% 100% no-repeat,
    radial-gradient(circle, #FFF6D8 0 2.5px, transparent 3.5px) 88% 78% / 100% 100% no-repeat,
    radial-gradient(circle, #FFE6A3 0 1.5px, transparent 2.5px) 14% 84% / 100% 100% no-repeat,
    radial-gradient(circle, #FFF6D8 0 2px, transparent 3px) 50% 100% / 100% 100% no-repeat;
  animation: rlTwinkle 2.4s ease-in-out infinite alternate;
}
@keyframes rlTwinkle { from { opacity: 0.35; } to { opacity: 1; } }
.rl__canvas {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
}
/* указатель — красный «камень» в золотой оправе, как на иллюстрации */
.rl__pointer {
  position: absolute;
  left: 50%;
  top: -6%;
  width: 15%;
  transform: translateX(-50%);
  z-index: 1;
  line-height: 0;
  filter: drop-shadow(0 3px 3px rgba(59, 35, 20, 0.45));
}
.rl__pointer svg { width: 100%; height: auto; }

/* --- Текст и форма --- */
.rl__side {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
  min-width: 0;
}

.rl__kicker {
  margin: 0 0 6px;
  font-family: var(--font-head);
  font-size: 24px;
  line-height: 1;
  color: var(--color-brown-mid);
}

.rl__modal-heading {
  font-family: var(--font-head);
  font-size: clamp(32px, 3.4vw, 44px);
  font-weight: 700;
  line-height: 1.02;
  text-transform: uppercase;
  color: var(--color-brown-dark);
  margin: 0 0 12px;
}

.rl__modal-sub {
  font-family: var(--font-text);
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-brown-mid);
  margin: 0 0 16px;
}

/* ряд подарков — значки из самого колеса */
.rl__prizes {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}
.rl__prizes li {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 12px 0 3px;
  border: 1px solid rgba(201, 138, 46, 0.45);
  border-radius: 999px;
  background: rgba(255, 251, 242, 0.85);
  font-family: var(--font-text);
  font-size: 13px;
  font-weight: 600;
  color: var(--color-brown-dark);
  white-space: nowrap;
}
.rl__prizes img {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  box-shadow: 0 0 0 1.5px #E0A93F;
}

.rl__form {
  width: 100%;
}

.rl__form-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

.rl__field-wrap {
  display: flex;
  flex-direction: column;
  text-align: left;
}

/* поля — как в форме «Контакты» */
.rl__field {
  width: 100%;
  height: 54px;
  padding: 0 16px;
  border: 1.5px solid #D4CAB8;
  border-radius: 12px;
  font-family: var(--font-text);
  font-size: 16px;
  background: #FAFAF8;
  color: var(--color-brown-dark);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.rl__field::placeholder { color: #BBBBB0; }
.rl__field:focus { border-color: var(--color-gold); box-shadow: 0 0 0 3px rgba(245, 177, 67, 0.2); }
.rl__field.is-error { border-color: #d94f35; }

.rl__field-error {
  display: none;
  font-family: var(--font-text);
  font-size: 12px;
  color: #c2412a;
  margin-top: 5px;
  padding-left: 4px;
}

.rl__field.is-error ~ .rl__field-error { display: block; }

/* --- Shared consent checkbox (рулетка, контакт) --- */
.consent-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  margin-bottom: 14px;
  text-align: left;
}

.consent-check { display: none; }

.consent-box {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border: 1.5px solid rgba(159,100,41,0.4);
  border-radius: 4px;
  margin-top: 1px;
  background: #fff;
  transition: background 0.15s, border-color 0.15s;
  position: relative;
}

.consent-check:checked ~ .consent-box {
  background: var(--color-gold);
  border-color: var(--color-gold);
}

.consent-check:checked ~ .consent-box::after {
  content: '';
  position: absolute;
  left: 3px;
  top: 6px;
  width: 10px;
  height: 5px;
  border-left: 2px solid #fff;
  border-bottom: 2px solid #fff;
  transform: rotate(-45deg) translateY(-3px);
}

.consent-text {
  font-family: var(--font-text);
  font-size: 11px;
  color: var(--color-brown-mid);
  line-height: 1.5;
  opacity: 0.85;
}

.consent-link {
  color: var(--color-brown-mid);
  text-decoration: underline;
}

/* кнопка — золотая текстура сайта; у «Крутить колесо!» бегущий блик и мягкая пульсация */
.rl__do-spin,
.rl__success-btn {
  position: relative;
  z-index: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 62px;
  padding: 0 40px;
  border: none;
  border-radius: 999px;
  overflow: hidden;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  font-family: var(--font-text);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--color-white);
  cursor: pointer;
  box-shadow: 0 12px 26px -10px rgba(159, 100, 41, 0.75);
  transition: transform 0.2s ease, box-shadow 0.25s ease, color 0.2s ease, opacity 0.2s ease;
}
.rl__do-spin::after,
.rl__success-btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.rl__do-spin::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -40%;
  width: 30%;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(100deg, transparent, rgba(255, 248, 225, 0.75), transparent);
  transform: skewX(-20deg);
  animation: rlShine 3.2s ease-in-out infinite;
}
@keyframes rlShine {
  0%, 55% { left: -40%; }
  100% { left: 130%; }
}
.rl__do-spin:not(:disabled) { animation: rlPulse 2.2s ease-in-out infinite; }
@keyframes rlPulse {
  0%, 100% { box-shadow: 0 12px 26px -10px rgba(159, 100, 41, 0.75), 0 0 0 0 rgba(245, 177, 67, 0.55); }
  50%      { box-shadow: 0 12px 26px -10px rgba(159, 100, 41, 0.75), 0 0 0 10px rgba(245, 177, 67, 0); }
}
.rl__do-spin:hover:not(:disabled),
.rl__success-btn:hover {
  color: var(--color-brown-dark);
  transform: translateY(-2px);
}
.rl__do-spin:hover:not(:disabled)::after,
.rl__success-btn:hover::after { opacity: 1; }

.rl__do-spin:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}
.rl__do-spin:disabled::before { animation: none; opacity: 0; }

.rl__note {
  margin: 10px 0 0;
  font-family: var(--font-text);
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--color-brown-mid);
  opacity: 0.9;
}

/* --- Вид успеха: выигранный бонус + конфетти --- */
.rl__success-view {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 460px;
  margin: 0 auto;
  padding: 6px 0;
}

.rl__success-badge {
  width: 72px;
  height: 72px;
  display: block;
  margin: 0 auto 10px;
  animation: starAnim 6s ease-in-out infinite;
}
/* иконка выигранного приза вместо звезды */
.rl__success-icon {
  width: 150px;
  height: 150px;
  margin: 0 auto 12px;
  border-radius: 50%;
  box-shadow: 0 0 0 4px #E0A93F, 0 0 0 9px rgba(245, 177, 67, 0.25), 0 18px 36px -12px rgba(59, 35, 20, 0.55);
  animation: rlPrizeIn 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
.rl__success-icon:not([hidden]) ~ .rl__success-badge,
.rl__success-icon:not([hidden]) + .rl__success-badge { display: none; }
@keyframes rlPrizeIn {
  from { transform: scale(0.3) rotate(-30deg); opacity: 0; }
  to   { transform: none; opacity: 1; }
}

.rl__success-title {
  font-family: var(--font-head);
  font-size: clamp(32px, 4vw, 42px);
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
  color: var(--color-brown-dark);
  margin: 0 0 14px;
}

/* «Ваш бонус: Пиньята» — заполняет main.js */
.rl__success-prize {
  margin: 0 0 16px;
  padding: 12px 28px 14px;
  border: 1.5px dashed rgba(159, 100, 41, 0.5);
  border-radius: 14px;
  background: rgba(255, 250, 238, 0.75);
  font-family: var(--font-head);
  font-size: 34px;
  line-height: 1.1;
  color: var(--color-brown-mid);
}
.rl__success-prize:empty { display: none; }
.rl__success-prize small {
  display: block;
  margin-bottom: 4px;
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}

.rl__success-text {
  font-family: var(--font-text);
  font-size: 14.5px;
  color: var(--color-brown-mid);
  line-height: 1.6;
  margin: 0 0 24px;
}

.rl__success-btn { max-width: 280px; }

/* конфетти (main.js создаёт кусочки при выигрыше) */
.rl__confetti {
  position: absolute;
  top: -10px;
  width: 9px;
  height: 14px;
  border-radius: 2px;
  pointer-events: none;
  z-index: 4;
  animation: rlConfetti var(--cf-t, 1.8s) cubic-bezier(0.2, 0.6, 0.35, 1) forwards;
}
@keyframes rlConfetti {
  from { transform: translate(0, 0) rotate(0deg); opacity: 1; }
  to   { transform: translate(var(--cf-x, 0), var(--cf-y, 420px)) rotate(var(--cf-r, 540deg)); opacity: 0; }
}

@media (max-width: 900px) {
  .rl__spin-view {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  .rl__wheel-wrap { max-width: 300px; margin-top: 18px; }
  .rl__side { align-items: center; text-align: center; }
  .rl__prizes { justify-content: center; }
}
@media (max-width: 768px) {
  .rl__modal-box {
    width: calc(100% - 16px);
    padding: 22px 12px 22px;
    border-width: 22px;
    border-image-width: 22px;
  }
  .rl__kicker { font-size: 20px; }
  .rl__modal-heading { font-size: 28px; }
  .rl__modal-sub { font-size: 14px; }
  .rl__wheel-wrap { max-width: 240px; margin-top: 14px; }
  /* на телефоне призы и так видны на колесе — ряд значков прячем ради формы */
  .rl__prizes { display: none; }
  .rl__modal-sub { margin-bottom: 14px; }
  .rl__form-fields { grid-template-columns: 1fr; }
  .rl__do-spin { height: 58px; font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) {
  .rl__wheel-wrap::before, .rl__sparkles, .rl__do-spin::before, .rl__do-spin:not(:disabled) { animation: none; }
}

/* ============================================================
   ОКНО «УЗНАТЬ СТОИМОСТЬ / СВОБОДНЫЕ ДАТЫ» (js/lib/lead-modal.js)
   Та же бумажная карточка в золотой рамке, что окно рулетки.
   ============================================================ */
.lead-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 99999;
  align-items: center;
  justify-content: center;
}
.lead-modal[aria-hidden="false"] { display: flex; }
.lead-modal__bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(50% 50% at 50% 50%, rgba(245, 177, 67, 0.2), transparent 70%),
    rgba(34, 18, 9, 0.7);
  backdrop-filter: blur(7px);
  cursor: pointer;
}
.lead-modal__box {
  position: relative;
  z-index: 1;
  width: calc(100% - 32px);
  max-width: 500px;
  max-height: 94vh;
  overflow-y: auto;
  scrollbar-width: none;
  padding: 26px 34px 28px;
  text-align: center;
  border: 32px solid transparent;
  border-image: url('../assets/img/plashka.webp') 100 fill / 32px stretch;
  filter: drop-shadow(0 28px 56px rgba(20, 10, 4, 0.55));
  animation: rlPopIn 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.lead-modal__box::-webkit-scrollbar { display: none; }
.lead-modal__close {
  position: absolute;
  top: 0;
  right: 0;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1.5px solid rgba(159, 100, 41, 0.45);
  background: rgba(255, 250, 240, 0.8);
  color: var(--color-brown-dark);
  font-size: 15px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.3s ease;
}
.lead-modal__close:hover { background: var(--color-gold); transform: rotate(90deg); }
.lead-modal__kicker {
  margin: 0 0 6px;
  font-family: var(--font-head);
  font-size: 22px;
  line-height: 1;
  color: var(--color-brown-mid);
}
.lead-modal__title {
  margin: 0 0 12px;
  font-family: var(--font-head);
  font-size: clamp(30px, 3.4vw, 40px);
  font-weight: 700;
  line-height: 1.02;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}
.lead-modal__sub {
  margin: 0 0 20px;
  font-family: var(--font-text);
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-brown-mid);
}
.lead-modal__form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}
.lead-modal__field {
  width: 100%;
  height: 54px;
  padding: 0 18px;
  border: 1.5px solid #D4CAB8;
  border-radius: 12px;
  background: #FAFAF8;
  font-family: var(--font-text);
  font-size: 16px;
  color: var(--color-brown-dark);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.lead-modal__field::placeholder { color: #BBBBB0; }
.lead-modal__field:focus { border-color: var(--color-gold); box-shadow: 0 0 0 3px rgba(245, 177, 67, 0.2); }
.lead-modal__form .consent-row { margin: 4px 0 6px; }
.lead-modal__btn {
  position: relative;
  z-index: 0;
  height: 60px;
  border: none;
  border-radius: 999px;
  overflow: hidden;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  font-family: var(--font-text);
  font-size: 17px;
  font-weight: 600;
  color: var(--color-white);
  cursor: pointer;
  box-shadow: 0 12px 26px -10px rgba(159, 100, 41, 0.75);
  transition: transform 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}
.lead-modal__btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.lead-modal__btn:hover:not(:disabled) { color: var(--color-brown-dark); transform: translateY(-2px); }
.lead-modal__btn:hover:not(:disabled)::after { opacity: 1; }
.lead-modal__btn:disabled { opacity: 0.55; cursor: not-allowed; box-shadow: none; }
.lead-modal__note {
  margin: 12px 0 0;
  font-family: var(--font-text);
  font-size: 12.5px;
  color: var(--color-brown-mid);
}
@media (max-width: 768px) {
  .lead-modal__box {
    width: calc(100% - 16px);
    padding: 20px 14px 22px;
    border-width: 22px;
    border-image-width: 22px;
  }
  .lead-modal__kicker { font-size: 19px; }
  .lead-modal__title { font-size: 28px; }
  .lead-modal__sub { font-size: 14px; }
}

/* ============================================================
   PHASE 10 — ОТЗЫВЫ «Нам доверяют мамы Ростова»
   Figma 668:134/185, локальный отсчёт от глобального Y = 12051
   ============================================================ */

#reviews {
  position: relative;
  width: 100%;
  height: 908px;
  overflow: hidden;
  background: var(--color-paper);
  z-index: 3;
}

#reviews::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.3;
  background: url('../assets/img/book-bg.webp') center / cover no-repeat;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 15%, #000 85%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 15%, #000 85%, transparent 100%);
}

.rev__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 908px;
}

.rev__title {
  position: absolute;
  left: 96px;
  top: 0;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 51px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}

.rev__board {
  position: absolute;
  left: 54px;
  top: 26px;
  width: 1292px;
  height: 794px;
  max-width: none;
  z-index: 1;
  pointer-events: none;
}

/* Враппер для мобильной раскладки — на десктопе не участвует в вёрстке */
.rev__board-wrap { display: contents; }
.rev__video-frame { display: contents; }
.rev__board-video-m,
.rev__board-list-m { display: none; }

/* Надписи доски — живой текст поверх reviews.webp (на картинке текста больше нет).
   Слой повторяет картинку: 1292×794 от того же угла. Каждая надпись ставится
   центром в точку на картинке (--x/--y) и поворачивается вместе с бумажкой (--r). */
.rev__ink {
  position: absolute;
  left: 54px;
  top: 26px;
  width: 1292px;
  height: 794px;
  z-index: 2;
  pointer-events: none;
}
.rev__ink > * {
  position: absolute;
  left: var(--x);
  top: var(--y);
  margin: 0;
  transform: translate(-50%, -50%) rotate(var(--r, 0deg));
  color: var(--color-brown-dark);
}
/* имя — на деревянной бирке со скрепкой */
.rev__ink-name {
  width: 140px;
  font-family: var(--font-head);
  font-size: 16.5px;
  line-height: 1.1;
  text-align: center;
  white-space: nowrap;
}
.rev__ink-name--1 { --x: 223px; --y: 198px; --r: -0.6deg; }
.rev__ink-name--2 { --x: 225px; --y: 351px; --r: -2.9deg; }
.rev__ink-name--3 { --x: 223px; --y: 508px; --r: -1.7deg; }
.rev__ink-name--4 { --x: 223px; --y: 661px; --r: 0deg; }
/* текст отзыва — на рваной крафт-бумаге, до украшений справа */
.rev__ink-text {
  width: 352px;
  font-family: var(--font-text);
  font-size: 13.5px;
  line-height: 1.5;
  color: #3B2314;
}
.rev__ink-text--1 { --x: 517px; --y: 224px; }
.rev__ink-text--2 { --x: 509px; --y: 376px; width: 336px; }   /* справа билет заходит на бумагу */
.rev__ink-text--3 { --x: 517px; --y: 530px; }
.rev__ink-text--4 { --x: 517px; --y: 682px; }
/* видео-полароид: бирка сверху и подпись снизу */
.rev__ink-tag {
  --x: 982px; --y: 141px; --r: 5deg;
  font-family: var(--font-head);
  font-size: 18px;
  line-height: 1.12;
  text-align: center;
  white-space: nowrap;
}
.rev__ink-cap {
  --x: 1021px; --y: 702px; --r: 2.2deg;
  font-family: var(--font-head);
  font-size: 24px;
  line-height: 1.08;
  text-align: center;
  white-space: nowrap;
}
/* билет и записка «Спасибо!» — украшения, тем же шрифтом заголовков */
.rev__ink-ticket {
  --x: 758px; --y: 388px;
  font-family: var(--font-head);
  font-size: 13px;
  line-height: 1.12;
  letter-spacing: 0.06em;
  text-align: center;
  text-transform: uppercase;
  color: #6B2414;
}
.rev__ink-thanks {
  --x: 765px; --y: 694px; --r: -7deg;
  font-family: var(--font-head);
  font-size: 21px;
  line-height: 1;
}
/* мобильные копии надписей видео-полароида — только в мобильной раскладке */
.rev__vm-tag,
.rev__vm-cap { display: none; }

/* Прозрачная кнопка поверх видео-полароида на подложке.
   Координаты — ровно кадр видео на reviews.webp (раньше зона была сдвинута
   влево на ~115px: кликалась лаванда, а правая часть видео — нет). */
.rev__video-hit {
  position: absolute;
  left: 940px;
  top: 235px;
  width: 330px;
  height: 440px;
  z-index: 4;
  border: none;
  background: transparent;
  border-radius: 12px;
  cursor: pointer;
}
.rev__video-hit:focus-visible { outline: 3px solid var(--color-gold); }

/* Жёлтая кнопка play поверх белой, нарисованной на подложке (тот же стиль,
   что .note__play у видео блокнота). Центр и диаметр — по нарисованному кругу:
   центр 46.5% / 51.5% зоны, диаметр ~97px холста — берём с запасом. */
.rev__play {
  position: absolute;
  left: 46.5%;
  top: 51.5%;
  width: 104px;
  height: 104px;
  transform: translate(-50%, -50%);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--color-gold);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35), inset 0 -3px 0 rgba(201, 138, 46, 0.55);
  pointer-events: none;
  transition: background 0.25s ease, transform 0.25s ease;
}
.rev__play svg { width: 38%; height: 38%; margin-left: 5%; }
.rev__play path { fill: #2A170C; }
.rev__video-hit:hover .rev__play,
.rev__video-hit:focus-visible .rev__play {
  background: #FFC75F;
  transform: translate(-50%, -50%) scale(1.08);
}

/* Модальное окно видео-отзыва */
.rev__modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}
.rev__modal[aria-hidden="false"] { opacity: 1; visibility: visible; }
.rev__modal-bg { position: absolute; inset: 0; background: rgba(30, 17, 9, 0.78); }
.rev__modal-inner {
  position: relative;
  width: min(900px, 92vw);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}
.rev__modal-video { display: block; width: 100%; height: auto; max-height: 86vh; background: #000; }
.rev__modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,0.92);
  color: var(--color-brown-dark);
  font-size: 18px;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}
.rev__modal-close:hover { background: var(--color-gold); color: #fff; transform: rotate(90deg); }

/* ============================================================
   PHASE 11 — О РУКОВОДИТЕЛЕ
   Figma 668:135/186/187/36, локальный отсчёт от глобального Y = 12959
   ============================================================ */

#about {
  position: relative;
  width: 100%;
  height: 743px;
  overflow: hidden;
  background: var(--color-paper);
  z-index: 3;
}

.about__stage {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1400px;
  height: 743px;
}

.about__label {
  position: absolute;
  left: 96px;
  top: 0;
  margin: 0;
  z-index: 3;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 61px;
  line-height: 51px;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}

.about__photo {
  position: absolute;
  left: 72px;
  top: 105px;
  width: 561px;
  height: 638px;
  max-width: none;
  z-index: 2;
}

.about__board {
  position: absolute;
  left: 645px;
  top: 98px;
  width: 751px;
  height: 501px;
  max-width: none;
  z-index: 2;
  container-type: inline-size;
}
.about__board-img { display: block; width: 100%; height: 100%; max-width: none; }
/* надписи таблички: % и cqw — от ширины таблички (751px на десктопе) */
.about__name,
.about__role,
.about__quote {
  position: absolute;
  margin: 0;
  color: var(--color-brown-dark);
  pointer-events: none;
}
/* имя — на крафт-полоске с кнопкой-гвоздиком */
.about__name {
  left: 39.4%;
  top: 29.1%;
  transform: translate(-50%, -50%);
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 5.9cqw;
  line-height: 1;
  white-space: nowrap;
}
/* подпись — на светлой полосе под ним */
.about__role {
  left: 49.3%;
  top: 44.9%;
  transform: translate(-50%, -50%);
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 1.95cqw;
  line-height: 1.2;
  white-space: nowrap;
  color: #4A3527;
}
/* цитата — письмом на карточке, шрифтом заголовков */
.about__quote {
  left: 16.4%;
  top: 75.8%;
  width: 63.5%;
  transform: translateY(-50%);
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 2.45cqw;
  line-height: 1.5;
}

.about__btn {
  position: absolute;
  left: 734px;
  top: 636px;
  width: 253px;
  height: 47px;
  z-index: 3;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 37px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  box-shadow: var(--shadow-btn);
  transition: box-shadow 0.2s ease, color 0.2s ease;
}
.about__btn::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.about__btn:hover { box-shadow: 3px 6px 12px rgba(0,0,0,0.18); color: var(--color-brown-dark); }
.about__btn:hover::after { opacity: 1; }

/* ============================================================
   МОДАЛЬНЫЕ ОКНА С ВИДЕО (разворот блокнота)
   ============================================================ */

.cost__modal,
.venue__modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.28s ease, visibility 0.28s ease;
}
.cost__modal[aria-hidden="false"],
.venue__modal[aria-hidden="false"] {
  opacity: 1;
  visibility: visible;
}
.cost__modal-bg,
.venue__modal-bg {
  position: absolute;
  inset: 0;
  background: rgba(30, 17, 9, 0.78);
}
.cost__modal-inner,
.venue__modal-inner {
  position: relative;
  width: min(1000px, 92vw);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
}
.cost__modal-video,
.venue__modal-video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 88vh;
  background: #000;
}
.cost__modal-close,
.venue__modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  color: var(--color-brown-dark);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}
.cost__modal-close:hover,
.venue__modal-close:hover {
  background: var(--color-gold);
  color: #fff;
  transform: rotate(90deg);
}

/* ============================================================
   FLUID LAYOUT — пропорционально от 720 px и без потолка сверху
   --stage-scale обновляется через JS (main.js) как чистое число:
     ≥ 1540 px  → vw / 1540       (1920 → 1.247, 2560 → 1.662)
     < 1540 px  → (vw − 140) / 1400 (1440 → 0.929, 720 → 0.414)
   --fluid-k — тот же коэффициент для блоков без холста 1400 px
   (FAQ, форма, футер) через zoom; ≤ 768 px — 1 (мобильная вёрстка).
   Шапка сознательно НЕ масштабируется — фиксированные размеры.
   scale() принимает только <number>, поэтому JS, а не CSS calc.
   ============================================================ */

@media (min-width: 769px) {
  .faq__inner,
  #contacts,
  .success-modal__box,
  .gal__header,
  .gal__collage,
  .gal__hint {
    zoom: var(--fluid-k, 1);
  }
  #faq {
    padding: calc(100px * var(--fluid-k, 1)) 0 calc(110px * var(--fluid-k, 1));
  }
  /* коллаж: +30px сверху и снизу у .gal__strip под тени — компенсируем, чтобы
     расстояния до заголовка и подсказки не изменились */
  .gal__collage { margin-top: -48px; margin-bottom: -88px; }
  /* пустые поля рядов (под тени) накрывают соседний ряд — пропускаем мышь
     сквозь них к карточкам; перетаскивание висит на .gal__collage */
  .gal__row,
  .gal__strip { pointer-events: none; }
  .gal__photo { pointer-events: auto; }
  /* подвал: коэффициент ещё и по высоте окна — целиком помещается в экран
     (--footer-k считает main.js, не больше --fluid-k) */
  .site-footer { zoom: var(--footer-k, var(--fluid-k, 1)); }
  /* галерея: сама секция не зумится — внутри лайтбокс на vw/vh */
  #gallery {
    padding: calc(104px * var(--fluid-k, 1)) 0 calc(96px * var(--fluid-k, 1));
  }
}

/* ── HERO (1400 × 739, fullscreen) ── */
#hero {
  min-height: 100dvh;
  min-height: 100vh;
  height: auto;
  /* поля растут вместе с холстом на экранах шире 1540 px (см. main.js) */
  padding: calc(88px * var(--stage-scale, 1)) max(20px, calc(20px * var(--stage-scale, 1))) 0 max(100px, calc(100px * var(--stage-scale, 1)));
}
.hero__stage {
  transform: scale(var(--hero-scale, var(--stage-scale, 1)));
  transform-origin: left center;
}

/* ── КРАФТ-ПОЛОТНО (УТП + СРАВНЕНИЕ), 1400 × 2916 ── */
.craft {
  height: calc(2916px * var(--stage-scale, 1));
  margin-top: calc(-11px * var(--stage-scale, 1));
  background-size: 100% auto;   /* бумажная карта ровно во всю ширину экрана, пропорции сохранены */
}
.craft__vignette {
  transform: scale(var(--stage-scale, 1));
  transform-origin: top center;
  top: calc(126px * var(--stage-scale, 1));
}

/* ── УТП (1400 × 1438) ── */
#utp {
  height: calc(1438px * var(--stage-scale, 1));
}
.utp__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* ── СРАВНЕНИЕ (1400 × 836) ── */
#comparison {
  top: calc(1438px * var(--stage-scale, 1));
  height: calc(836px * var(--stage-scale, 1));
}
/* карточка «Новый уровень» на фоне соседних блоков читалась слишком крупной —
   уменьшена на 18 % и отцентрована по вертикали в своей зоне 836 px */
.cmp__stage {
  --cmp-k: 0.82;
  transform: translateX(-50%) translateY(calc(836px * (1 - var(--cmp-k)) / 2 * var(--stage-scale, 1))) scale(calc(var(--stage-scale, 1) * var(--cmp-k)));
  transform-origin: top center;
}

/* ── РАЗВОРОТ БЛОКНОТА: СТОИМОСТЬ + ЛОФТ (1400 × 900) ── */
#cost {
  height: calc(1390px * var(--stage-scale, 1));
  margin-top: calc(-642px * var(--stage-scale, 1));
}
.note__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* ── ВОЗМОЖНОСТИ (1400 × 1100, фон во всю ширину экрана) ── */
#capabilities {
  height: calc(1100px * var(--stage-scale, 1));
  background-size: cover;
}
.cap__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* ── УСИЛИТЕЛИ (1400 × 1229) ── */
#boosters {
  height: calc(1229px * var(--stage-scale, 1));
  margin-top: calc(-150px * var(--stage-scale, 1));
}
.bst__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* ── РУЛЕТКА (1400 × 877) ── */
#roulette {
  height: calc(877px * var(--stage-scale, 1));
}
.rl__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* Рваный низ «Усилителей» ложится НА рулетку (#boosters z-index 4 > #roulette 3):
   рулетка заезжает под него на 100 px холста — ровно полоса, где у
   boosters-bg.webp идёт разрыв (альфа ~0.92–0.98 высоты). Подложку
   paper-strip.webp под разрывом убираем — сквозь просветы должна быть видна
   рулетка, а не плоская полоса бумаги. Золотая линия стыка больше не нужна.
   Заголовок и подзаголовок опущены ниже полосы перекрытия. Только десктоп —
   на мобильном своя раскладка. */
@media (min-width: 769px) {
  #boosters {
    background: url('../assets/img/v2/boosters-bg.webp') center / cover no-repeat;
  }
  #roulette {
    margin-top: calc(-100px * var(--stage-scale, 1));
  }
  #roulette::before,
  #roulette::after { display: none; }
  .rl__title { top: 118px; }
  .rl__subtitle { top: 186px; }
}

/* ── ОТЗЫВЫ (1400 × 908) ── */
#reviews {
  height: calc(908px * var(--stage-scale, 1));
}
.rev__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* ── О РУКОВОДИТЕЛЕ (1400 × 743) ── */
#about {
  height: calc(743px * var(--stage-scale, 1));
}
.about__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* ── ПРОГРАММЫ (1400 × 1307) ── */
#programs {
  height: calc(1307px * var(--stage-scale, 1));
  margin-top: calc(-165px * var(--stage-scale, 1));
}
.prog__stage {
  transform: translateX(-50%) scale(var(--stage-scale, 1));
  transform-origin: top center;
}

/* Десктоп: блок целиком в одном экране. Свой масштаб --prog-k (main.js) =
   min(--stage-scale, по высоте окна). Стык с «Возможностями» (верхние 165px
   холста уходят под рваный край) остаётся на --stage-scale, ниже стыка холст
   идёт в --prog-k; стена растянута вверх на разницу и во всю ширину экрана. */
@media (min-width: 769px) {
  #programs {
    --pk: var(--prog-k, var(--stage-scale, 1));
    height: calc(165px * var(--stage-scale, 1) + 1142px * var(--pk));
  }
  .prog__stage {
    top: calc(165px * (var(--stage-scale, 1) - var(--pk)));
    transform: translateX(-50%) scale(var(--pk));
  }
  .prog__wall {
    top: calc(-165px * (var(--stage-scale, 1) / var(--pk) - 1));
    height: calc(1307px + 165px * (var(--stage-scale, 1) / var(--pk) - 1));
    width: max(2322px, calc(100vw / var(--pk)));
  }
}

/* ============================================================
   FAQ — АККОРДИОН «Часто спрашивают»
   ============================================================ */

#faq {
  position: relative;
  z-index: 0;
  background: var(--color-paper);
  padding: 100px 0 110px;
}

#faq::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  /* размер — только от ширины (не cover): при раскрытии вопроса секция растёт
     по высоте, и cover пересчитывал масштаб — фон «прыгал». Картинка 2560 px
     не растягивается уже экрана; снизу, если секция выше картинки, — бумага. */
  background: url('../assets/img/hero-bg.webp') center top / max(100%, 2560px) auto no-repeat;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 15%, #000 85%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 15%, #000 85%, transparent 100%);
}

.faq__inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 clamp(24px, 5vw, 64px);
}

.faq__header {
  margin-bottom: 52px;
}

.faq__label {
  margin: 0 0 16px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 24px;
  line-height: 1;
  color: var(--color-brown-mid);
}

.faq__title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(36px, 5vw, 55px);
  line-height: 1.05;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}

.faq__title strong {
  font-weight: 700;
}

.faq__list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Вопрос — та же пергаментная плашка с золотой рамкой, что у «Что входит»,
   отзывов и формы (с 22.10.2026; раньше белые карточки). Плашка — псевдоэлементом:
   border-image на самом блоке сдвинул бы контент, а тень по силуэту даёт filter. */
.faq__item {
  position: relative;
  isolation: isolate;
}
.faq__item::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border: 22px solid transparent;
  border-image: url('../assets/img/plashka.webp') 100 fill / 22px stretch;
  filter: drop-shadow(0 4px 14px rgba(59, 35, 20, 0.16));
  transition: filter 0.25s ease;
  pointer-events: none;
}
.faq__item:hover::before,
.faq__item[open]::before {
  filter: drop-shadow(0 8px 22px rgba(59, 35, 20, 0.24));
}

.faq__question {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 28px 34px;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.faq__question::-webkit-details-marker { display: none; }

/* номер — шрифтом заголовков, как порядковый номер главы */
.faq__num {
  flex-shrink: 0;
  min-width: 36px;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: 28px;
  line-height: 1;
  color: var(--color-brown-mid);
}

.faq__q-text {
  flex: 1;
  font-family: var(--font-head);
  font-weight: 400;
  font-size: clamp(19px, 2vw, 23px);
  line-height: 1.2;
  color: var(--color-brown-dark);
}

/* стрелка — в золотом кружке, как кнопки карусели программ */
.faq__chevron {
  flex-shrink: 0;
  box-sizing: content-box;
  width: 20px;
  height: 20px;
  padding: 8px;
  margin-left: 8px;
  border-radius: 50%;
  background: var(--color-gold);
  color: var(--color-brown-dark);
  box-shadow: 0 3px 8px rgba(59, 35, 20, 0.25);
  transition: transform 0.32s var(--ease-spring), background 0.2s ease;
}
.faq__item:hover .faq__chevron { background: #FFC75F; }

.faq__item.is-open .faq__chevron {
  transform: rotate(180deg);
}

.faq__item.is-open .faq__question {
  padding-bottom: 18px;
}

.faq__item.is-open .faq__num {
  color: var(--color-gold);
}

.faq__body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.38s var(--ease-inout);
}

.faq__item.is-open .faq__body {
  grid-template-rows: 1fr;
}

.faq__body-inner {
  overflow: hidden;
}

/* ответ — под вопросом, от линии текста вопроса, отделён пунктиром как на карточке-письме */
.faq__body-inner p {
  margin: 0 34px 30px calc(34px + 36px + 20px);
  padding-top: 16px;
  border-top: 1px dashed rgba(159, 100, 41, 0.4);
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  line-height: 1.65;
  color: #4A3527;
}

/* ============================================================
   === КОНТАКТ ===  Финальная форма
   ============================================================ */

.contact {
  background: transparent;
  padding: 100px 0 110px;
}

.contact__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 clamp(24px, 5vw, 64px);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 542px);
  gap: clamp(32px, 6vw, 80px);
  align-items: start;
}

.contact__header {
  text-align: left;
}

.contact__title {
  margin: 0 0 20px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(36px, 4.5vw, 55px);
  line-height: 1.05;
  text-transform: uppercase;
  color: var(--color-brown-dark);
}

.contact__title strong {
  font-weight: 700;
}

.contact__subtitle {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: clamp(16px, 2vw, 20px);
  line-height: 1.5;
  color: var(--color-brown-mid);
  max-width: 480px;
}

/* ----- Карточка формы ----- */
.contact__card {
  position: relative;
  isolation: isolate;
  padding: 42px 46px 46px;
}
.contact__card::before {
  content: '';
  position: absolute;
  inset: 0;
  border: 28px solid transparent;
  border-image: url('../assets/img/plashka.webp') 100 fill / 28px stretch;
  filter: drop-shadow(0 4px 26px rgba(59, 35, 20, 0.26));
  pointer-events: none;
}

.contact__form {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.contact__field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact__field-label {
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 16px;
  color: #666;
}

.contact__input {
  width: 100%;
  height: 58px;
  border: 1.5px solid #D4CAB8;
  border-radius: 12px;
  padding: 0 18px;
  font-family: var(--font-text);
  font-size: 18px;
  color: var(--color-brown-dark);
  background: #FAFAF8;
  outline: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.contact__input:focus { border-color: var(--color-gold); }
.contact__input::placeholder { color: #BBBBB0; }

/* ----- Кнопки канала связи ----- */
.contact__channels {
  margin: 0;
  padding: 0;
  border: none;
}

.contact__channels-legend {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.contact__channels-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.contact__channel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 72px;
  padding: 10px 8px;
  border: 1.5px solid #D4CAB8;
  border-radius: 12px;
  background: #FAFAF8;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  user-select: none;
}

.contact__channel input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.contact__channel:has(input:checked) {
  border-color: var(--color-gold);
  background: var(--color-white);
  box-shadow: 0 0 0 1px var(--color-gold);
}

.contact__channel:has(input:checked) .contact__channel-text {
  color: var(--color-brown-mid);
  font-weight: 600;
}

/* Печать вместо плоского значка: та же вырезка из note-socials.webp, что
   у .hero__social-icon (см. комментарий там). img остаётся в DOM ради
   data-cms-id у VK (в CMS поле теоретически заменяемо), но не виден. */
.contact__channel-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: url('../assets/img/v2/note-socials.webp') no-repeat;
}
.contact__channel-icon img { display: none; }
.contact__channel-icon--call { background-position: 0.71% 45%; background-size: 362.2% 104.1%;  }
.contact__channel-icon--max  { background-position: 50.16% 45%; background-size: 364.4% 104.1%;  }
.contact__channel-icon--vk   { background-position: 99.13% 45%; background-size: 360.7% 104.1%;  }

.contact__channel-text {
  font-family: var(--font-text);
  font-weight: 500;
  font-size: 13px;
  line-height: 1.2;
  color: var(--color-brown-dark);
  text-align: center;
}

/* ----- Юридический текст ----- */
.contact__legal {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  line-height: 1.45;
  color: #666;
}

.contact__policy-link {
  color: var(--color-gold);
  text-decoration: underline;
}
.contact__policy-link:hover { color: #e8a530; }

/* ----- Кнопка отправки ----- */
.contact__submit {
  /* текстура button1.png (1759×316) искажалась на всю ширину формы —
     ширина ограничена, кнопка по центру */
  display: block;
  width: min(100%, 360px);
  margin-inline: auto;
  height: 47px;
  z-index: 0;
  border: none;
  border-radius: 37px;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  color: var(--color-white);
  cursor: pointer;
  position: relative;
  transition: box-shadow 0.2s ease, color 0.2s ease, transform 0.1s ease;
  box-shadow: var(--shadow-btn);
}
.contact__submit::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  pointer-events: none;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.contact__submit:hover:not(:disabled) {
  box-shadow: 3px 6px 12px rgba(0,0,0,0.18);
  color: var(--color-brown-dark);
}
.contact__submit:hover:not(:disabled)::after { opacity: 1; }
.contact__submit:active:not(:disabled) { transform: scale(0.98); }
.contact__submit:disabled {
  background: #D4CAB8;
  color: #A09080;
  box-shadow: none;
  cursor: not-allowed;
  transform: none;
}
.contact__submit:disabled::after { opacity: 0; }

.contact__success {
  padding: 24px 0 8px;
  font-family: var(--font-text);
  font-size: 18px;
  font-weight: 600;
  color: var(--color-brown-dark);
  text-align: center;
  line-height: 1.5;
}

/* ----- Альтернативные контакты ----- */
.contact__alt {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding-top: 6px;
  text-align: center;
}

.contact__alt-text {
  margin: 0;
  font-family: var(--font-text);
  font-weight: 400;
  font-size: 14px;
  color: #666;
}

.contact__social {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
}

.contact__social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 47px;
  height: 47px;
  border-radius: 50%;
  background: url('../assets/img/v2/note-socials.webp') no-repeat;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.contact__social-link--tel { order: 1; background-position: 0.71% 45%; background-size: 362.2% 104.1%;  }
.contact__social-link--max { order: 2; background-position: 50.16% 45%; background-size: 364.4% 104.1%;  }
.contact__social-link--vk  { order: 3; background-position: 99.13% 45%; background-size: 360.7% 104.1%;  }

.contact__social-link:hover {
  transform: scale(1.08);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.contact__social-link img { display: none; }

/* ============================================================
   SUCCESS MODAL — общий поп-ап «Заявка принята»
   ============================================================ */

.success-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
}
.success-modal[aria-hidden="false"] {
  display: flex;
  align-items: center;
  justify-content: center;
}
.success-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(59, 35, 20, 0.60);
  animation: smOverlayIn 0.25s ease;
}
.success-modal__box {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: min(420px, calc(100vw - 40px));
  padding: 25px 36px 36px;
  background: var(--color-white);
  border-radius: 24px;
  box-shadow: 0 8px 48px rgba(59, 35, 20, 0.22);
  text-align: center;
  animation: smBoxIn 0.3s var(--ease-spring);
}
.success-modal__lion {
  width: 240px;
  height: 240px;
  object-fit: contain;
  flex-shrink: 0;
}
.success-modal__title {
  margin: 0;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 30px;
  color: var(--color-brown-dark);
}
.success-modal__text {
  margin: 0;
  font-family: var(--font-text);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.55;
  color: var(--color-brown-mid);
}
.success-modal__btn {
  margin-top: 8px;
  width: 100%;
  height: 52px;
  border: none;
  border-radius: 12px;
  background: var(--color-gold);
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 17px;
  cursor: pointer;
  transition: background 0.2s, box-shadow 0.2s, transform 0.1s;
  box-shadow: 0 4px 16px rgba(245, 177, 67, 0.38);
}
.success-modal__btn:hover {
  background: var(--color-brown-mid);
  box-shadow: 0 6px 22px rgba(59, 35, 20, 0.22);
  transform: scale(1.06);
}
.success-modal__btn:active { transform: scale(0.97); }

@keyframes smOverlayIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes smBoxIn {
  from { opacity: 0; transform: scale(0.88) translateY(16px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

/* ============================================================
   LAP* — анимация появления существующих изображений лапок
   ============================================================ */

/* lapi1.svg — полоса следов: раскрытие слева направо */

/* lapa.svg / lapi2*.svg — отдельные лапки: плавное появление */

/* ============================================================
   МОБИЛЬНЫЙ / ПЛАНШЕТНЫЙ РЕЖИМ
   Макет 668:2 сделан только под 1400 px и целиком построен на
   абсолютном позиционировании, поэтому узкие экраны обслуживает
   тот же механизм --stage-scale (js/main.js): холст 1400 px
   пропорционально ужимается под ширину окна. Ниже — только то,
   что масштабом не решается.
   ============================================================ */

@media (max-width: 1024px) {
  /* Крафт-полотно и стена программ шире холста — прячем боковой вынос */
  .craft, #programs, #capabilities, #boosters { overflow: hidden; }
}

@media (max-width: 768px) {

  /* ============================================================
     HERO — макет мобильной версии: сверху летающая книга с фото
     (та же WebGL-орбита, что на десктопе), ниже слева ТОП-5, заголовок,
     подзаголовок, кнопки, соцсети и два бейджа в ряд.
     Холст 1400px тут не работает (--stage-scale ~0.18 съёживал всё в
     комок), поэтому обычный поток. Орбита масштабонезависима: мир у неё
     фиксированный 1000×730, а размер буфера берётся из getBoundingClientRect
     канваса — так что канвас просто стилизуем под ширину экрана.
     Фон — общий с десктопом assets/img/hero-bg.webp (cover по центру).
     ============================================================ */
  #hero {
    min-height: 100dvh;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    padding: 72px 24px 60px;   /* снизу — рваный край фона с цветами */
    background: url('../assets/img/hero-bg.webp') center / cover no-repeat, var(--color-paper);
  }
  .hero__stage {
    /* ширина канваса орбиты: чуть шире экрана (края режет overflow хоста),
       чтобы книга была крупной, а самые широкие карточки не упирались в край */
    --orb-w: min(470px, 116vw);
    position: static;
    width: 100%;
    height: auto;
    transform: none;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  /* --- Летающая книга (WebGL-орбита) — первой в колонке --- */
  .hero__orbit {
    position: relative;
    left: auto;
    top: auto;
    order: 0;
    /* на всю ширину экрана, компенсируя боковой padding hero */
    width: calc(100% + 48px);
    /* высота хоста меньше канваса (0.73), но overflow НЕ режем: карточки
       на орбите вылетают за рамку хоста, и при overflow:hidden они
       обрезались бы ровной линией сверху/снизу. Сверху отступ равен
       выступу канваса, чтобы он не уходил под фиксированную шапку. */
    height: calc(var(--orb-w) * 0.66);
    margin: calc(var(--orb-w) * 0.035) -24px 0;
    overflow: visible;
  }
  .hero__orbit-canvas {
    position: absolute;
    left: 50%;
    top: 50%;
    width: var(--orb-w);
    height: calc(var(--orb-w) * 0.73);   /* 1000×730 — пропорции мира орбиты */
    transform: translate(-50%, -50%);
  }
  .hero__book-shadow { display: none; }
  /* Статичная книга — запасной вариант, пока орбита не поднялась (или
     если WebGL нет): лежит поверх места под орбиту, без сдвига вёрстки */
  .hero__book {
    position: absolute;
    left: 0;
    right: 0;
    top: calc(72px + var(--orb-w) * 0.035 + (var(--orb-w) * 0.66 - min(300px, 78vw) * 0.5972) / 2);
    margin: 0 auto;
    width: min(300px, 78vw);
    height: auto;
    max-width: none;
  }
  .hero__stage.is-orbit-off .hero__orbit { display: none; }
  .hero__stage.is-orbit-off .hero__book {
    position: relative;
    top: auto;
    order: 0;
    align-self: center;
  }

  /* --- Порядок блоков как в макете (DOM-порядок другой: бейджи идут выше) --- */
  .hero__badge--top   { order: 1; }
  .hero__title        { order: 2; }
  .hero__subtitle     { order: 3; }
  .hero__btn--primary { order: 4; }
  .hero__btn--outline { order: 5; }
  .hero__social-label { order: 6; }
  .hero__social-icons { order: 7; }
  .hero__badges       { order: 8; }

  /* --- Бейджи на рваной бумаге --- */
  .hero__badge {
    /* relative, не static: .hero__badge-paper (картинка рваной бумаги ТОП-5)
       — абсолютный ребёнок, ему нужна точка отсчёта */
    position: relative;
    top: auto;
    left: auto;
    width: auto;
    height: auto;
    padding: 10px 24px;
    border-radius: 999px;
    overflow: hidden;
    white-space: nowrap;
    text-align: center;
    font-size: clamp(10px, 3vw, 13px);
  }
  /* ТОП-5 — plashka2.png: на десктопе вынесена шире бейджа и сдвинута
     (left:-73px через более специфичный .hero__badge--top .hero__badge-paper),
     на мобильном растягиваем на весь бейдж тем же по специфичности селектором */
  .hero__badge-paper,
  .hero__badge--top .hero__badge-paper {
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    transform: none;
    object-fit: cover;
  }
  .hero__badge--top { padding-left: 46px; padding-right: 26px; }
  /* Рейтинг/«500+»: те же PNG рваной бумаги, background-size:100% 100%
     уже тянется под любой размер */
  .hero__badge--rating,
  .hero__badge--stats { box-sizing: border-box; }
  .hero__badge--rating { padding: 8px 13px; gap: 4px; }
  .hero__badge--stats  { padding: 8px 13px; font-size: clamp(10px, 2.9vw, 12px); }
  .hero__rating-num { font-size: 22px; line-height: 1; }
  .hero__rating-star { width: 18px; height: 18px; }
  .hero__rating-label { font-size: clamp(9.5px, 2.7vw, 11px); margin-left: 1px; }

  /* два бейджа рядом (обёртка на десктопе display:contents) */
  .hero__badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
  }

  /* --- Заголовок, подзаголовок --- */
  .hero__title {
    position: static;
    align-items: flex-start;
    text-align: left;
    margin-top: 6px;
  }
  .hero__title-line {
    font-size: clamp(21px, 7.9vw, 34px);
    line-height: 1.08;
    white-space: nowrap;
  }
  .hero__subtitle {
    position: static;
    text-align: left;
    font-size: clamp(22px, 6.6vw, 30px);
    line-height: 1.2;
  }

  /* --- Кнопки и соцсети --- */
  .hero__btn {
    /* relative: ::after (hover-подсветка, inset:0) центрируется на самой
       кнопке, а не на случайном позиционированном предке. left/top у
       --primary/--outline из десктопной абсолютной раскладки (417px/478px)
       при position:relative читались бы как смещение — обнуляем. */
    position: relative;
    left: auto;
    top: auto;
    width: min(250px, 72vw);
  }
  .hero__social-label {
    position: static;
    text-align: left;
    margin-top: 4px;
    margin-bottom: -6px;
  }
  .hero__social-icons {
    position: static;
    justify-content: flex-start;
  }

  /* ============================================================
     УТП (маршрут+полароиды) и СРАВНЕНИЕ (карточка «Новый уровень») —
     держат общий --stage-scale ((100vw-140px)/1400), рассчитанный под
     десктопный отступ. На телефоне это ~0.13–0.18 — маршрут с пинами
     и карточка сравнения превращаются в мелкие нечитаемые марки.
     Не меняем сам --stage-scale (от него зависят другие секции),
     а даём этим двум секциям СВОЙ, более щедрый масштаб --utp-scale
     (отступ по бокам 16px вместо 140px) — картинки, SVG-маршрут со
     скролл-анимацией (animation-timeline: view()) и JS-реавил карточек
     (.utp__card.is-in) продолжают работать как есть, просто крупнее:
     все элементы внутри .utp__stage/.cmp__stage — это единый
     transform:scale(), логика анимаций к пиксельным координатам
     не привязана. .craft больше не должен резервировать 642px под
     наезд #cost — на мобильном у #cost margin-top уже обнулён отдельно. */
  .craft {
    --utp-scale: min(1, calc((100vw - 32px) / 1400px));
    /* Карточка «Новый уровень» — свой, более крупный масштаб: панель
       (1294px макета) растягиваем почти на всю ширину экрана, по 10px по бокам */
    --cmp-scale: min(1, calc((100vw - 20px) / 1294px));
    /* Высота холста сравнения: на мобильном печать убрана, слайдер по центру
       и крупнее (1040px вместо 761px), панель-подложка вытянута на +190px */
    --cmp-h: 1026px;
    /* хвост крафта под карточкой сравнения: облако-переход (#cost::before)
       заходит на него сверху — без хвоста облако накрыло бы рамку карточки целиком */
    --craft-tail: 50px;
    /* Заголовок+плашка увеличены на 30%, им нужно больше места сверху —
       весь маршрут (SVG, пины, карточки, дымка) и всё, что ниже, съезжает
       на --utp-shift вниз, чтобы плашка не наезжала на верхние полароиды */
    --utp-shift: 148px;
    /* Композиция из карточек/пинов/маршрута увеличена и
       отцентрована по оси холста (700px): центр её габарита по X у десктопа
       667.5px, то есть на 32px левее середины — отсюда «неровно». Масштаб —
       от верхнего центра композиции (верх карточки №2 остаётся на месте),
       растёт вниз, поэтому дымка со шторой и блок «Новый уровень» уезжают
       на --utp-grow ниже. */
    --utp-grow: 394px;
    height: calc((1438px + var(--utp-shift) + var(--utp-grow)) * var(--utp-scale) + var(--cmp-h) * var(--cmp-scale) + var(--craft-tail));
    /* подтягиваем блок вверх на низ hero: иначе между бейджами hero и
       заголовком — ~100px пустой бумаги */
    margin-top: -30px;
    /* фон (карта с компасом/горами) держится на своём --stage-scale
       (center 350px в базовом правиле не масштабируется вовсе), а тут
       у нас локальный --utp-scale — без пересчёта смещения фон уезжает
       за пределы укороченной секции и просто не виден */
    background-position: center calc((350px + var(--utp-shift)) * var(--utp-scale));
    /* рваный нижний край (маска) на мобильном убран: сквозь вырезы
       просвечивала белая бумага body между крафтом и блоком «Лофт» */
    -webkit-mask: none;
    mask: none;
  }
  #utp {
    height: calc((1438px + var(--utp-shift) + var(--utp-grow)) * var(--utp-scale));
  }
  .utp__stage {
    transform: translateX(-50%) scale(var(--utp-scale));
  }
  .utp__clouds {
    /* та же формула самокомпенсации ширины, что и для --stage-scale,
       но под наш локальный (больший) масштаб — иначе дымка либо не
       дотянется до краёв экрана, либо уедет за них */
    width: max(1967px, calc(100vw / var(--utp-scale)));
  }
  #comparison {
    top: calc((1438px + var(--utp-shift) + var(--utp-grow)) * var(--utp-scale));
    height: calc(var(--cmp-h) * var(--cmp-scale));
  }
  .cmp__stage {
    height: var(--cmp-h);
    transform: translateX(-50%) scale(var(--cmp-scale));
  }

  /* «Новый уровень» на мобильном: без сургучной печати, слайдер до/после
     по центру панели и крупнее (761→1040px макета, пропорции 761:481) */
  .cmp__seal { display: none; }
  .cmp__panel { height: 950px; }
  .cmp__slider {
    left: 181px;
    top: 225px;
    width: 1040px;
    height: 657px;
    border-radius: 40px;
  }
  .cmp__img { width: 100%; height: 100%; }
  /* Ползунок слайдера до/после — в 2 раза крупнее, на мобилке терялся */
  .cmp__handle { width: 110px; height: 110px; }
  .cmp__handle svg { width: 48px; height: 48px; }
  /* Заголовок и подзаголовок карточки — крупнее на ~25%; корона и
     подзаголовок сдвинуты под новую высоту строк, слайдер (top 225) не задет */
  .cmp__crown { left: 96px; top: 71px; width: 55px; height: 46px; }
  .cmp__title { left: 166px; top: 61px; font-size: 76px; line-height: 64px; }
  .cmp__subtitle { left: 168px; top: 131px; font-size: 60px; line-height: 66px; }
  /* Плашка «Наша театрализация»: по центру слайдера (520 = 1040/2 —
     десктопные 380px были центром 761px-слайдера) и крупнее (×1.9 к десктопу) */
  .cmp__label {
    left: 50%;
    top: 552px;
    height: 78px;
    padding: 0 50px;
    border-radius: 56px;
    font-size: 37px;
  }

  /* Штора на мобилке на 30% больше (2026-09-26): ширина 805 → 1046px холста,
     left −400 → −520px — пропорция «спрятано/видно» та же, выезжающая часть
     тоже ×1.3. Через width, а не scale: transform занят JS (translateX в %
     от собственной ширины) — так выезд считается от новой ширины сам. */
  .site-curtain {
    width: 1046px;
    left: -520px;
  }

  /* Заголовок «Мы открываем портал…» и плашка-подзаголовок — на 30% крупнее.
     transform:scale от верхнего центра: шрифт, рамка плашки (::before) и
     подпись растут вместе, пропорции не ломаются */
  .utp__title {
    top: 40px;
    transform: scale(1.3);
    transform-origin: 50% 0;
  }
  .utp__subtitle {
    top: 262px;
    transform: translateX(-50%) scale(1.69);
    transform-origin: 50% 0;
    /* текст плашки крупнее: самая длинная строка при 32px — 589px из ~780px
       полезной ширины плашки (850px минус рваные края), при 38px — ~700px */
    font-size: 38px;
    line-height: 35px;
    padding-top: 16px;
  }
  /* Композиция: карточки крупнее (×1.4 к десктопу; №1, №2, №4 — ×1.6), сдвинуты друг к другу
     (расстояния между центрами ×1.1 по X и ×1.3 по Y — меньше, чем при
     чистом масштабе, поэтому плотнее), центр по X = 705px (ось холста 700 +
     поправка на прозрачные поля PNG). Пины и маршрут отображены той же
     аффинной картой, что и центры карточек, — привязка к карточкам не
     разъезжается. Все top — плюс --utp-shift (сдвиг под увеличенный заголовок). */
  .utp__clouds { top: calc(840px + var(--utp-shift) + var(--utp-grow)); }
  .utp__route { left: 267.7px; top: calc(638.2px + var(--utp-shift)); width: 875.6px; height: 1258.4px; }
  .utp__pin--1 { left: 452.2px; top: calc(674.4px + var(--utp-shift)); width: 54.6px; height: 77px; }
  .utp__pin--2 { left: 1101.2px; top: calc(872px + var(--utp-shift)); width: 54.6px; height: 77px; }
  .utp__pin--3 { left: 918.6px; top: calc(1555.8px + var(--utp-shift)); width: 54.6px; height: 77px; }
  .utp__pin--4 { left: 334.5px; top: calc(1440.2px + var(--utp-shift)); width: 54.6px; height: 77px; }
  .utp__pin--5 { left: 824px; top: calc(1113.8px + var(--utp-shift)); width: 54.6px; height: 77px; }
  .utp__card--1 { left: -23.9px; top: calc(406.7px + var(--utp-shift)); width: 556.8px; height: 544px; }
  .utp__card--2 { left: 567.9px; top: calc(342.8px + var(--utp-shift)); width: 641.6px; height: 627.2px; }
  .utp__card--3 { left: 845.6px; top: calc(970.9px + var(--utp-shift)); width: 561.4px; height: 548.8px; }
  .utp__card--4 { left: 32.4px; top: calc(889.7px + var(--utp-shift)); width: 569.6px; height: 556.8px; }
  .utp__card--5 { left: 443.7px; top: calc(1250.7px + var(--utp-shift)); width: 523.6px; height: 511px; }

  /* ============================================================
     О РУКОВОДИТЕЛЕ — та же болезнь, что у hero: секция держит
     высоту через calc(743px * stage-scale) и на узких экранах
     сплющивается в ~130px, контент становится нечитаемым. Обычный
     поток, фото/плашка тянутся по ширине с сохранением пропорций.
     ============================================================ */
  #about {
    height: auto;
    padding: 36px 0 36px;
  }
  .about__stage {
    position: static;
    width: 100%;
    height: auto;
    transform: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    padding: 0 24px;
  }
  .about__label {
    position: static;
    text-align: center;
    font-size: clamp(30px, 8vw, 38px);
    line-height: 1.15;
  }
  .about__photo {
    position: static;
    width: min(220px, 60vw);
    height: auto;
    max-width: none;
  }
  .about__board {
    position: relative;   /* опора для надписей таблички */
    left: auto;           /* десктопные координаты на relative сдвинули бы табличку за экран */
    top: auto;
    /* +20% к видимой части плашки (≈ +20% к прежней ширине колонки). В самой
       картинке прозрачные поля (видимая часть — 9–87% ширины), поэтому файл
       можно сделать шире экрана: лишнее — прозрачное и клипается секцией,
       а сама плашка остаётся в пределах экрана */
    width: min(calc((100vw - 48px) * 1.2), 470px);
    max-width: none;
    height: auto;
  }
  /* на телефоне табличка ~400px — надписи крупнее, подпись в две строки */
  .about__role { width: 54%; font-size: 2.35cqw; white-space: normal; text-align: center; }
  .about__quote { font-size: 2.95cqw; line-height: 1.42; }
  .about__btn {
    position: relative;
    left: auto;
    top: auto;
    width: min(260px, 80vw);
  }

  /* ============================================================
     РАЗВОРОТ БЛОКНОТА (#cost) — самая насыщенная секция: два
     «разворота» книги (лофт+форма, промо+марки), 20+ абсолютных
     элементов на 1400px-канвасе. На мобильном разворот книги
     убираем (незачем ужимать иллюстрацию до нечитаемости), контент
     идёт обычным потоком по центру, карточка формы — как в
     остальных формах сайта.
     ============================================================ */
  #cost {
    height: auto;
    margin-top: 0;
    padding: 10px 0 36px;
    background: var(--color-cream-bg);
  }
  /* Облако-переход между крафтовым фоном (карта/штора) и кремовым блоком
     «Лофт»: assets/img/cloud-bg.webp (2172×724, прозрачные края), 112vw × 37.3vw.
     Должно лежать ПОД карточкой «Новый уровень» (#comparison, z-index 3 внутри
     .craft) и в то же время заходить на верх #cost (z-index 4, кремовая
     заливка, перекрыла бы всё, что рисуется внутри .craft ниже его границы).
     Поэтому облако нарезано по линии стыка на две части одной и той же
     картинки: верхняя (--cloud-up) — .craft::after, под карточкой; нижняя —
     #cost::before, под заголовком «Лофт». Швов нет: размеры/смещения фона
     считаются от одной и той же линии стыка. */
  :root {
    --cloud-w: 165vw;          /* облако крупное: края картинки далеко за экраном */
    --cloud-h: 55vw;           /* пропорции 2172×724 (3:1) */
    --cloud-shift: 6vw;        /* сдвиг облака вправо */
    --cloud-up: 46vw;          /* сколько облака выше линии стыка: «впадина»
                                  между двумя кучами уходит за нижнюю рамку
                                  карточки, под ней остаётся плотная масса */
  }
  .craft::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    width: var(--cloud-w);
    height: var(--cloud-up);
    transform: translateX(calc(-50% + var(--cloud-shift)));
    z-index: 2;
    pointer-events: none;
    background:
      url('../assets/img/cloud-bg.webp') 50% 0 / var(--cloud-w) var(--cloud-h) no-repeat,
      /* подложка: последние 20vw плавно уходят в кремовый фон блока «Лофт» —
         иначе между низом облака и стыком просвечивала серая бумага body */
      linear-gradient(to bottom, rgba(245, 232, 207, 0) calc(100% - 20vw), var(--color-cream-bg) 100%);
  }
  #cost::before {
    content: '';
    position: absolute;
    left: 50%;
    top: 0;
    width: var(--cloud-w);
    height: calc(var(--cloud-h) - var(--cloud-up));
    transform: translateX(calc(-50% + var(--cloud-shift)));
    z-index: -1;
    pointer-events: none;
    background: url('../assets/img/cloud-bg.webp') 50% calc(-1 * var(--cloud-up)) / var(--cloud-w) var(--cloud-h) no-repeat;
  }
  .note__stage {
    position: static;
    width: 100%;
    height: auto;
    transform: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding: 0 24px;
  }
  .note__spread,
  .note__paper-loft,
  .note__badge--calc,
  .note__badge--watch { display: none; }

  .note__stage h2,
  .note__stage p {
    position: static;
    text-align: center;
    width: auto;
  }
  .note__stage .note__h-loft,
  .note__stage .note__h-cost,
  .note__stage .note__h-contact,
  .note__stage .note__h-prog,
  .note__h-dream {
    font-size: clamp(24px, 7vw, 30px);
    line-height: 1.2;
  }
  /* «Видео-тур по лофту» ближе к заголовку «Лофт «Портал»» над ним:
     общий gap колонки 20px, тут забираем 14px */
  .note__stage .note__sub-loft { margin-top: -14px; }
  /* «Узнайте стоимость праздника» на 10px ниже видео над ним; остальное
     (за 2 минуты, форма…) уезжает вместе, отступы между ними прежние */
  .note__stage .note__h-cost { margin-top: 10px; }
  /* «Всё про наши премиум-праздники» — тоже на 10px ниже блока соцсетей над ним */
  .note__stage .note__h-prog { margin-top: 10px; }
  .note__sub-loft,
  .note__accent-prog {
    font-size: clamp(20px, 5.6vw, 24px);
    line-height: 1.2;
  }
  .note__accent-cost {
    font-size: clamp(28px, 8vw, 36px);
    line-height: 1.15;
  }
  .note__h-dream { width: 100%; max-width: 380px; }

  .note__video {
    /* relative, не static: остаётся в потоке колонки, но продолжает быть
       точкой отсчёта для .note__play (position:absolute, центр по 50%/50%) */
    position: relative;
    width: 100%;
    max-width: 340px;
    height: auto;
  }
  .note__video--loft {
    /* position:relative у .note__video выше означает, что left/top из
       десктопной абсолютной раскладки (160px/270px) теперь читаются как
       смещение, а не координата — обнуляем */
    left: auto;
    top: auto;
    aspect-ratio: 450 / 282;
  }
  .note__video--prog {
    left: auto;
    top: auto;
    aspect-ratio: 340 / 220;
    transform: none;
  }
  .note__video--prog:hover { transform: scale(1.02); }

  /* Пергаментная рамка ::before (border-image + filter:drop-shadow) на
     десктопе тюнингована под фикс 517×196px; при пересчёте под мобильный
     auto-размер эта комбинация ловит баг рендера Chromium — контент
     ВЫШЕ карточки перестаёт прорисовываться (хотя в DOM всё на месте,
     проверено getBoundingClientRect/elementFromPoint). Проще и надёжнее
     на мобильном её не использовать — обычная карточка с тенью. */
  .note__form-card {
    position: static;
    width: 100%;
    max-width: 380px;
    height: auto;
    padding: 26px 20px 20px;
    box-sizing: border-box;
    background: var(--color-cream-light);
    border-radius: 20px;
    box-shadow: 0 10px 24px rgba(59, 35, 20, 0.18);
  }
  .note__form-card::before { content: none; }
  .note__form {
    display: flex;
    flex-direction: column;
    gap: 14px;
  }
  .note__form-label {
    position: static;
    white-space: normal;
    font-size: 15px;
    line-height: 1.35;
  }
  .note__input { position: static; width: 100%; }
  .note__consent { position: static; width: 100%; }
  .note__btn { position: relative; left: auto; top: auto; width: 100%; }

  .note__socials {
    position: relative;    /* было static: ссылки-печати теперь абсолютные внутри */
    left: auto;            /* иначе relative сдвинул бы на десктопные 820/1138px */
    top: auto;
    width: min(300px, 85vw);
    height: auto;
    aspect-ratio: 400 / 118;
  }

  /* Марки: 2 ряда — сверху 3, снизу 2 (по центру). Сетка на 6 колонок,
     каждая марка занимает 2; в нижнем ряду 4-я и 5-я начинаются со 2-й и
     4-й колонки, так что ряд сам центрируется */
  .note__stamps {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    justify-items: center;
    align-items: center;
    gap: 12px 0;
    /* чуть шире колонки контента (на 12px с каждой стороны) — марки крупнее,
       а 24px бокового padding .note__stage всё равно оставляют им воздух у края */
    width: calc(100% + 24px);
    max-width: 410px;
    margin: 0 -12px;
  }
  .note__stamps > .note__stamp { grid-column: span 2; }
  .note__stamps > .note__stamp--4 { grid-column: 2 / span 2; }
  .note__stamps > .note__stamp--5 { grid-column: 4 / span 2; }
  .note__stamp {
    /* relative, не static: в потоке сетки, но остаётся опорой для бумаги
       внутри (она absolute); inset гасит десктопные left/top */
    position: relative;
    inset: auto;
    /* ~29% ширины блока марок (потолок — при 380px); между марками ~4% воздуха */
    width: calc(min(100vw - 24px, 410px) * 0.29);
    height: auto;
  }

  /* ============================================================
     ВОЗМОЖНОСТИ (#capabilities) — 4 полароида, тот же трюк со
     stage-scale ужимал их до нечитаемых марок. Раскладка сеткой
     2×2, поворот (--rot) остался для «живого» вида.
     ============================================================ */
  #capabilities {
    /* Композиция по мобильному макету: заголовочная плашка слева сверху,
       «Цирк» справа сверху, «Площадка» слева снизу, «Живая музыка» справа
       снизу, книга посередине (это сам фон book-bg.png). Секция держит
       пропорцию 10:17 — карточки лежат в процентах от неё и не разъезжаются
       на разной ширине экрана. */
    height: auto;
    aspect-ratio: 10 / 17;
    padding: 0;
    /* Сквозь прозрачный рваный верх book-bg.png (первые ~6.3% высоты) просвечивала
       серая бумага body — белая полоса между кремовым блоком «Разворот» и
       картинкой. Подложка кремового цвета только под верхние 7%: низ
       по-прежнему прозрачный, чтобы рваный край ложился на стену «Программ». */
    /* Переход сверху — через прозрачность (2026-09-26): картинка вынесена в
       ::before и её верх растворяется маской в кремовую подложку блока выше,
       вместо резкой линии. Маска на самой секции задела бы и плашку-заголовок
       (она у верхнего края), поэтому только на слое фона. Подложка кремовая
       теперь до 16% (зона растворения), ниже — прозрачная, как и была:
       рваный низ ложится на стену «Программ». */
    background: linear-gradient(to bottom, var(--color-cream-bg) 0, var(--color-cream-bg) 16%, rgba(245, 232, 207, 0) 16%);
  }
  #capabilities::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: url('../assets/img/book-bg.webp') 50% calc(50% - 30px) / cover no-repeat;
    -webkit-mask-image: linear-gradient(to bottom, transparent 3%, #000 15%);
            mask-image: linear-gradient(to bottom, transparent 3%, #000 15%);
  }
  .cap__stage {
    position: absolute;
    inset: 0;
    z-index: 1;               /* над слоем фона ::before */
    width: auto;
    height: auto;
    transform: none;
    left: 0;
  }
  .cap__card {
    height: auto;
    max-width: none;
  }
  .cap__card img { height: auto; }
  .cap__card--title { left:  5%; top:  3%;   width: 57%; }
  .cap__card--3     { left: 59%; top: 10%;   width: 38%; }
  .cap__card--1     { left:  4%; top: 60%;   width: 43%; }
  .cap__card--2     { left: 52%; top: 70%;   width: 42%; }

  /* ============================================================
     ПРОГРАММЫ «Новинки каждый год» — весь блок на 30% крупнее.
     Стена, арки, заголовок, фильтры возраста, карусель карточек и
     стрелки — единый холст 1400px под transform:scale, поэтому просто
     свой масштаб: --stage-scale × 1.69 (два раза по +30%; потолок — ширина
     экрана плюс 20px по бокам: у холста по краям пустая сцена без
     интерфейса, лёгкий обрез там не виден). JS карусели читает реальные размеры карточек
     (getBoundingClientRect), так что шаг и число видимых карточек
     пересчитываются сами. Высота и подтяжка к блоку выше — от того же
     масштаба; ширина стены (самокомпенсация full-bleed) тоже.
     ============================================================ */
  #programs {
    --prog-scale: min(calc(var(--stage-scale, 1) * 1.69), calc((100vw + 40px) / 1400px));
    --prog-extra: 1428px;      /* добавка высоты холста под плашку со львом (+188px под 2-й ряд фильтров) */
    height: calc((1307px + var(--prog-extra)) * var(--prog-scale));
    /* верх (60px холста) — цвет верха стены под рваным краем «Возможностей»,
       стык утверждён; низ — бумага (#programs::before), стена в неё растворяется */
    /* 2026-09-26 (по просьбе): коричневая полоса #271309 под рваным краем
       «Возможностей» убрана — стена больше не сдвинута вниз на 60px (см. .prog__wall),
       рваная бумага сразу ложится на стену. */
    background: none;
    /* Рваный нижний край #capabilities (book-bg.png) прозрачный на нижние ~8.9%
       его высоты (высота = 1.7×ширины экрана → ≈15.1vw). Стена «Программ»
       заходит под него на всю эту глубину: рваная бумага перекрывает стену,
       а в прорехах видна сама стена — ни светлого, ни коричневого зазора. */
    margin-top: -15.2vw;
  }
  .prog__stage {
    height: calc(1307px + var(--prog-extra));
    transform: translateX(-50%) scale(var(--prog-scale));
  }
  .prog__wall {
    width: max(2322px, calc(100vw / var(--prog-scale)));
    /* Сама стена (картинка-фон) крупнее на 40% и чуть ниже: scale 1.4 от
       верхнего центра (растёт вниз и в стороны) + сдвиг на 60px холста вниз.
       Карточки, заголовок и остальное — отдельные элементы, размеров не меняют;
       образовавшуюся сверху полоску 60px закрашивает фон #programs. */
    transform: translate(-50%, 0) scale(1.4);   /* было translate(-50%, 60px): давало коричневую полосу-зазор сверху */
    transform-origin: 50% 0;
  }
  /* Карусель — ОДНА карточка в кадре. Вьюпорт сужен до ширины одной карточки
     (260px) по центру холста; JS карусели считает «сколько влезает» как
     clientWidth / шаг = 1, так что стрелка/свайп листают по одной, а счётчик
     показывает «N из 34». Карточка одна — значит можно крупнее: вся карусель
     (вьюпорт, стрелки, счётчик) scale 2.6 от верхнего центра, карточка на
     экране ≈ 52% ширины. Стрелки заранее расставлены по краям экрана. */
  .prog__viewport {
    left: 570px; width: 260px; top: 710px;   /* 522 + 188: место под 2-й ряд фильтров */
    scroll-padding-inline: 0;
    -webkit-mask-image: none;
            mask-image: none;
  }
  .prog__track { padding: 0; }
  .prog__meter { left: 570px; width: 260px; top: calc(1204px - 150px / (2.6 * var(--prog-scale))); }   /* 1016 + 188 */
  .prog__carousel {
    transform: scale(2.6);
    transform-origin: 700px 710px;   /* 522 + 188 — держит вьюпорт неподвижным при масштабе */
  }
  .prog__nav { top: 875px; }   /* 687 + 188 */
  .prog__nav--prev { left: calc(700px - (50vw - 38px) / (var(--prog-scale) * 2.6) - 30px); }
  .prog__nav--next { right: calc(700px - (50vw - 38px) / (var(--prog-scale) * 2.6) - 30px); }

  /* Плашка со львом «Праздники на любой вкус» — из правого верхнего угла
     вниз, под карусель, по центру холста и крупнее (×2.03 от десктопной,
     шрифты 23/13/16px → 47/26/32px холста — на экране читается). Стена
     кончается на 1307px, ниже — полоса цвета её низа, кромка стены плавно
     уходит в неё (::after у .prog__wall). */
  .prog__cta {
    left: 353px;               /* 700 − (285 × 2.436) / 2 — центр карточки на оси холста */
    top: 1708px;               /* 1520 + 188: место под 2-й ряд фильтров */
    transform: scale(2.436);   /* 2.03 × 1.2: ещё +20% */
    transform-origin: 0 0;
  }
  /* Иконки звонка/почты/VK под кнопкой — ещё +30% сверх общего масштаба плашки,
     от центра ряда (он и так стоит по центру карточки) */
  .prog__cta-social {
    /* translateY — в координатах ДО собственного scale, поэтому 10px на
       экране = 10 / 2.436 (масштаб .prog__cta) ≈ 4.1px здесь */
    transform: translateY(4.1px) scale(1.69);
    transform-origin: center;
  }
  /* Под плашкой со львом вместо коричневой полосы — бумага (та же текстура,
     что под блоком «Усилители»). Слой лежит под стеной; низ стены растворяется
     маской (полностью прозрачна с 1800px холста), так что переход мягкий,
     через прозрачность, как у рваного края сверху. */
  #programs::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: calc((1307px + var(--prog-extra) - 1500px) * var(--prog-scale));
    background: url('../assets/img/v2/paper-strip.webp') center / cover no-repeat;
    pointer-events: none;
  }
  .prog__wall {
    -webkit-mask-image: linear-gradient(to bottom, #000 0, #000 1071px, transparent 1243px);
    mask-image: linear-gradient(to bottom, #000 0, #000 1071px, transparent 1243px);
  }
  /* счётчик «N из 34» теперь на бумаге — тёмный текст и дорожка */
  .prog__meter-count { color: var(--color-brown-dark); text-shadow: none; }
  .prog__meter-track { background: rgba(59, 35, 20, 0.22); }

  /* Подпись полароида на мобильном — чуть крупнее (в единицах холста карусели) */
  .prog__card-title { font-size: 22px; }
  .prog__card-age { margin-top: 6px; font-size: 12px; }

  /* «Новинки каждый год» и подзаголовок — на 20% крупнее (61→73px, 32→38px);
     подзаголовок сдвинут вниз под выросшую строку заголовка */
  .prog__title { font-size: 102px; line-height: 85px; }      /* 73→102px: ещё +40% */
  .prog__subtitle { top: 280px; font-size: 69px; line-height: 73px; }   /* откат 78→69px: на реальном устройстве текст вылезал за край экрана */
  /* Кнопки возраста — в 2 ряда и крупнее: ширина холста 400px (нескейленная)
     при gap 12px даёт устойчивый перенос 5+6 кнопок; сам ряд ещё ×2.9 —
     на экране пилюля выросла с ~19px до ~32px высотой. Место под второй
     ряд просело вниз каскадом (плашка со львом/карусель/счётчик/стрелки
     ниже на те же 188px холста, --prog-extra увеличена на столько же). */
  .prog__filters {
    top: 470px;                /* 446→470: чуть ниже, под выросший подзаголовок */
    width: 400px;
    flex-wrap: wrap;
    gap: 12px;
    transform: scale(2.5);     /* 2.9→2.5: чуть меньше */
    transform-origin: 0 0;
  }

  /* ============================================================
     УСИЛИТЕЛИ (#boosters) — заголовок/подзаголовок/чемодан обычным
     потоком; margin-top:-150px (бумажный шов со стеной «Программ»)
     не трогаем — это фон, а не контент.
     ============================================================ */
  #boosters {
    height: auto;
    padding: 34px 24px 34px;
  }
  .bst__stage {
    position: static;
    width: 100%;
    height: auto;
    transform: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
  }
  .bst__title {
    position: static;
    left: auto;
    top: auto;
    text-align: center;
    font-size: clamp(28px, 8vw, 38px);
    line-height: 1.15;
  }
  .bst__subtitle {
    position: static;
    left: auto;
    top: auto;
    text-align: center;
    font-size: clamp(20px, 6vw, 26px);
    line-height: 1.25;
  }
  .bst__suitcase {
    position: relative;   /* опора для подписей наклеек */
    left: auto;
    top: auto;
    width: min(380px, 100%);
    height: auto;
    margin-top: -10px;
  }
  .bst__suitcase-img { height: auto; }

  /* ============================================================
     РУЛЕТКА (#roulette) — сам попап уже адаптирован отдельно
     (.rl__modal), здесь только «витрина»: заголовок/подзаголовок/
     кнопка/подсказка/лев обычным потоком.
     ============================================================ */
  /* Ромб по центру золотого разделителя на стыке с «Усилителями» — убран */
  #roulette::after { display: none; }
  #roulette {
    /* У roulete-bg.png сверху полоска карты с соснами (~6% высоты) и лишь
       под ней золотая рамка пергамента — на мобильном это выглядело как
       разрыв между «Усилителями» и рулеткой. Картинка чуть крупнее и
       прижата вниз: полоска уходит за верхний край, пергамент начинается
       сразу под золотой линией-разделителем. */
    background: url('../assets/img/roulete-bg.webp') 50% 100% / auto 114% no-repeat, var(--color-paper);
    height: auto;
    padding: 34px 24px 40px;
  }
  .rl__stage {
    position: static;
    width: 100%;
    height: auto;
    transform: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    text-align: center;
  }
  .rl__title {
    position: static;
    left: auto;
    top: auto;
    font-size: clamp(28px, 8vw, 38px);
    line-height: 1.15;
  }
  .rl__subtitle {
    position: static;
    left: auto;
    top: auto;
    font-size: clamp(20px, 6vw, 24px);
    line-height: 1.3;
  }
  .rl__btn {
    position: relative;
    left: auto;
    top: auto;
    width: min(280px, 80vw);
  }
  .rl__hint-text {
    position: static;
    left: auto;
    top: auto;
  }
  .rl__wheel-img {
    position: static;
    left: auto;
    top: auto;
    width: min(300px, 78vw);
    height: auto;
    margin-top: 6px;
  }

  /* ============================================================
     ОТЗЫВЫ (#reviews) — вся «доска» с отзывами и видео-полароидом
     это одна картинка (reviews.webp); просто тянем её по ширине,
     кликабельную зону видео держим в процентах от неё же.
     ============================================================ */
  #reviews {
    height: auto;
    padding: 28px 20px 32px;
  }
  .rev__stage {
    position: static;
    width: 100%;
    height: auto;
    transform: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
  }
  .rev__title {
    position: static;
    left: auto;
    top: auto;
    text-align: center;
    font-size: clamp(28px, 8vw, 38px);
    line-height: 1.15;
  }
  .rev__board-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
    max-width: 480px;
  }
  .rev__board,
  .rev__ink { display: none; }
  /* Видео-карточка отдельной картинкой сверху; надписи — живым текстом поверх,
     кегль в cqw от ширины карточки (картинка 431×718 в единицах 1x) */
  .rev__video-frame {
    display: block;
    position: relative;
    width: min(68%, 300px);
    container-type: inline-size;
  }
  .rev__vm-tag,
  .rev__vm-cap {
    display: block;
    position: absolute;
    margin: 0;
    transform: translate(-50%, -50%);
    font-family: var(--font-head);
    line-height: 1.1;
    text-align: center;
    white-space: nowrap;
    color: var(--color-brown-dark);
    pointer-events: none;
  }
  .rev__vm-tag { left: 33.4%; top: 9.3%; font-size: 4.6cqw; }
  .rev__vm-cap { left: 45%; top: 87.1%; font-size: 6.2cqw; }
  .rev__board-video-m {
    display: block;
    width: 100%;
    height: auto;
  }
  /* Отзывы отдельной картинкой снизу, на всю ширину блока */
  .rev__board-list-m {
    display: block;
    width: 100%;
    height: auto;
  }
  .rev__video-hit {
    position: absolute;
    left: 0.5%;
    top: 17.5%;
    width: 78.9%;
    height: 55.7%;
  }
  /* нарисованный круг на reviews-video-m.webp: центр 59.5% / 59.4% зоны, ~28% её ширины */
  .rev__play {
    left: 59.5%;
    top: 59.4%;
    width: 29%;
    height: auto;
    aspect-ratio: 1;
  }

  /* Галерея (в макете не нарисована) — обычный поток */
  #gallery { padding: 62px 0 44px; }
  .gal__header {
    width: 100%;
    padding: 0 20px;
    height: auto;
    margin-bottom: 8px;
  }
  .gal__header::before { left: 20px; top: -18px; width: 54px; }
  .gal__title    { font-size: 32px; line-height: 32px; }
  .gal__subtitle { font-size: 22px; line-height: 28px; margin-top: 14px; }
  .gal__collage  { padding-top: 4px; }
  .gal__row {
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 30px, #000 calc(100% - 30px), transparent 100%);
            mask-image: linear-gradient(90deg, transparent 0, #000 30px, #000 calc(100% - 30px), transparent 100%);
  }
  .gal__photo { width: 190px; padding: 9px 9px 42px; }
  .gal__photo-label { height: 42px; font-size: 17px; padding-top: 16px; }
  .gal__photo:hover { transform: rotate(var(--rot, 0deg)); box-shadow: 0 10px 26px rgba(59, 35, 20, 0.26); }
  /* padding сверху/снизу должен вмещать тень карточки (blur 26px + offset 10px),
     иначе mask-image у .gal__row (горизонтальное растворение краёв) обрезает
     её по границе своего бокса, как по overflow:hidden */
  .gal__strip { gap: 16px; padding: 42px 0; }
  /* margin-top компенсирует выросший padding .gal__strip (было 14px → стало 42px,
     +28px на каждую сторону), чтобы визуальный нахлёст карточек не изменился */
  .gal__row + .gal__row { margin-top: -78px; }
  .gal__arrow { display: none; }
  .gal__hint { font-size: 13px; margin-top: 24px; }

  /* Поп-апы на всю ширину */

  #faq { padding: 48px 0 48px; }
  .faq__inner { padding: 0 20px; }
  .faq__item::before { border-width: 18px; border-image-width: 18px; }
  .faq__question { padding: 22px 22px; gap: 12px; }
  .faq__num { min-width: 28px; font-size: 22px; }
  .faq__q-text { font-size: 18px; }
  .faq__chevron { width: 16px; height: 16px; padding: 7px; margin-left: 4px; }
  .faq__body-inner p { margin: 0 22px 24px 22px; font-size: 15px; }

  /* ============================================================
     КОНТАКТ — финальная форма
     ============================================================ */
  .contact { padding: 56px 0 28px; }
  .contact__inner {
    grid-template-columns: 1fr !important;
    padding: 0 20px !important;
  }
  .contact__header { text-align: center; }
  .contact__subtitle { max-width: none; }
  .contact__card { padding: 36px 30px 38px; }
  .contact__card::before { border-width: 22px; border-image-width: 22px; }
  .contact__channels-row { gap: 8px; }
  .contact__alt { padding-top: 2px; }

  /* ============================================================
     SUCCESS MODAL
     ============================================================ */
  .success-modal__lion { width: 170px; height: 170px; }
  .success-modal__box { padding: 22px 24px 30px; }
}

/* ============================================================
   PHASE 12 — ФУТЕР «после спектакля»
   Тёмная сцена под светлой бумагой сайта: рваный бумажный край сверху
   (тот же мотив, что у стыков блоков), тёплое золотое свечение, зерно.
   Сверху — финальный призыв с телефоном, ниже — колонки с нумерованными
   ссылками, гигантская золотая подпись, обрезанная снизу, и кнопка
   «Наверх» с вращающимся текстом (пара к печати в шапке).
   ============================================================ */
.site-footer {
  --ft-bg: #3A1712;
  --ft-ink: #F3E6CE;
  --ft-soft: rgba(243, 230, 206, 0.6);
  --ft-line: rgba(245, 177, 67, 0.18);
  --ft-ease: var(--ease-soft);
  position: relative;
  z-index: 0;
  padding-top: 124px;
  color: var(--ft-ink);
  background:
    radial-gradient(70% 60% at 50% 110%, rgba(245, 177, 67, 0.22), transparent 70%),
    linear-gradient(180deg, #4A1D16 0%, var(--ft-bg) 55%, #2C120E 100%);
}
/* рваный край бумаги: тёмная сцена «выглядывает» из-под светлого листа */
.site-footer::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: calc(100% - 1px);
  height: 34px;
  pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 48' preserveAspectRatio='none'%3E%3Cpath fill='%236B3524' d='M0,48 L0.0,19.4 L8.6,19.6 L15.1,16.2 L21.9,23.5 L26.6,15.1 L33.8,14.5 L42.6,21.8 L46.4,14.2 L49.6,16.3 L52.6,19.6 L60.7,20.2 L66.7,21.9 L71.2,26.0 L79.3,22.5 L83.6,18.0 L88.9,24.2 L97.7,17.3 L106.2,19.6 L111.6,14.9 L119.3,17.2 L124.2,25.6 L127.7,17.0 L130.9,23.6 L137.2,19.4 L144.6,15.6 L148.1,19.0 L152.6,25.7 L157.4,24.6 L162.6,24.3 L166.1,25.9 L170.5,23.3 L175.2,14.9 L181.6,16.9 L186.8,19.4 L192.6,20.9 L196.6,15.8 L204.5,17.0 L212.0,25.3 L220.8,24.6 L226.2,18.4 L230.5,22.5 L238.5,21.2 L242.4,16.1 L248.8,24.2 L253.3,25.0 L256.2,17.2 L259.4,16.1 L265.8,15.6 L274.2,25.8 L281.4,21.0 L284.4,14.2 L291.6,24.4 L297.4,22.8 L306.5,14.9 L314.0,24.8 L321.2,23.5 L326.2,22.2 L334.5,19.0 L342.8,20.9 L348.0,21.0 L351.3,21.7 L359.6,22.7 L367.1,21.0 L375.1,15.0 L378.1,21.2 L382.4,22.4 L389.0,25.0 L391.9,17.6 L396.0,16.0 L402.9,19.3 L407.8,22.0 L413.3,23.7 L421.7,18.6 L426.5,15.6 L434.5,24.2 L443.3,17.3 L449.0,17.3 L454.4,21.5 L459.2,24.1 L464.8,16.8 L467.9,22.5 L472.6,15.7 L478.3,14.3 L482.6,14.4 L488.2,21.6 L496.1,25.5 L500.1,19.7 L503.0,19.7 L506.9,17.3 L514.1,20.2 L521.7,18.7 L530.2,15.0 L537.5,15.6 L544.3,24.9 L550.7,24.6 L559.4,19.6 L563.5,22.7 L570.4,22.6 L578.8,25.8 L585.0,23.5 L593.5,24.3 L596.9,19.3 L604.5,20.9 L607.7,23.6 L612.6,23.5 L616.3,20.2 L624.4,22.3 L630.3,25.4 L634.5,20.3 L641.9,21.7 L650.0,20.7 L655.2,24.1 L659.4,24.2 L665.5,20.9 L671.6,20.0 L674.6,25.6 L679.9,23.6 L685.8,19.8 L691.2,25.5 L695.7,19.7 L701.3,23.8 L707.1,17.8 L713.8,25.1 L721.5,14.3 L725.7,22.2 L730.7,21.4 L738.1,15.5 L742.5,16.4 L748.1,18.5 L754.2,15.9 L761.0,21.7 L769.2,21.3 L773.4,22.9 L781.9,17.8 L790.5,16.6 L798.9,15.6 L806.3,17.1 L814.3,19.1 L817.9,18.8 L820.8,16.4 L829.4,25.6 L835.4,23.1 L842.5,8.1 L845.5,20.6 L851.9,15.8 L856.0,24.1 L864.6,18.1 L870.3,23.2 L876.1,20.2 L882.7,14.2 L890.8,16.2 L898.2,18.9 L902.1,22.3 L909.9,22.5 L916.7,18.9 L922.7,25.8 L927.1,24.9 L934.8,23.8 L943.2,24.6 L950.9,23.2 L958.2,14.8 L964.0,14.1 L970.8,21.5 L979.6,22.0 L986.5,20.8 L991.8,26.0 L999.0,23.1 L1001.9,21.4 L1006.4,11.8 L1011.5,15.2 L1020.0,20.6 L1028.9,20.8 L1035.7,22.0 L1043.3,14.5 L1047.1,19.7 L1053.1,24.2 L1058.5,20.3 L1063.6,17.4 L1069.9,17.4 L1074.6,14.2 L1077.7,15.9 L1082.9,24.8 L1086.0,25.9 L1089.3,24.9 L1095.1,25.7 L1101.2,25.2 L1107.0,25.7 L1113.6,15.4 L1119.2,13.8 L1122.8,19.3 L1128.5,17.1 L1133.9,23.3 L1143.0,25.4 L1147.3,15.4 L1155.1,21.5 L1159.6,22.2 L1166.1,21.6 L1170.1,17.0 L1178.7,15.7 L1183.2,19.1 L1186.6,12.0 L1193.7,20.6 L1198.8,19.7 L1203.8,22.9 L1207.1,15.4 L1213.8,23.2 L1219.3,17.1 L1224.4,21.8 L1229.2,20.6 L1237.8,19.1 L1241.3,16.0 L1247.6,19.8 L1252.3,16.5 L1259.3,15.0 L1266.6,22.3 L1270.3,18.3 L1275.4,15.4 L1281.8,25.0 L1290.4,19.3 L1295.1,17.8 L1303.8,24.7 L1308.9,18.4 L1314.2,18.7 L1320.5,23.6 L1328.6,20.8 L1336.2,24.6 L1339.1,20.2 L1345.5,25.6 L1353.3,14.8 L1361.1,15.0 L1368.6,24.8 L1375.3,15.7 L1382.2,16.9 L1389.9,20.3 L1395.1,18.1 L1402.2,19.9 L1409.5,22.5 L1414.9,23.9 L1423.1,23.7 L1431.5,25.5 L1437.6,22.5 L1440.0,20.0 L1440,48 Z'/%3E%3Cpath fill='%234A1D16' d='M0,48 L0.0,29.0 L6.7,31.5 L14.1,24.2 L21.6,29.2 L24.6,27.8 L29.9,24.1 L33.8,31.3 L37.1,30.4 L42.8,26.3 L46.4,25.7 L53.5,26.3 L58.8,29.4 L66.3,29.5 L73.5,26.4 L76.8,21.4 L82.4,24.0 L86.7,26.5 L91.7,26.5 L97.9,24.5 L100.4,30.0 L102.9,30.3 L108.4,19.3 L116.0,25.6 L123.4,31.5 L127.7,28.2 L130.7,30.0 L137.7,24.3 L140.6,26.7 L148.0,26.7 L153.3,26.5 L156.7,24.6 L162.8,32.0 L165.5,31.9 L170.1,25.9 L176.9,27.6 L179.6,29.3 L186.5,25.0 L194.1,29.0 L197.0,27.5 L204.0,26.4 L211.8,30.8 L216.7,27.9 L221.6,26.3 L224.8,27.0 L232.4,29.0 L236.6,24.7 L243.3,30.9 L249.9,30.2 L255.9,30.1 L262.1,26.2 L268.7,29.5 L276.2,29.2 L278.6,28.4 L284.7,27.7 L290.6,30.4 L296.4,29.9 L300.7,30.7 L306.8,31.8 L312.0,28.2 L319.0,31.5 L325.1,29.8 L328.4,30.2 L334.4,27.4 L341.0,29.1 L343.5,25.3 L349.5,25.8 L355.3,24.3 L358.9,24.4 L363.0,25.5 L365.6,27.7 L371.3,28.7 L378.6,24.0 L382.5,27.3 L389.4,26.0 L392.3,28.4 L397.8,31.7 L402.5,30.5 L406.9,25.1 L412.3,31.7 L418.0,26.8 L420.4,24.9 L426.1,25.1 L433.3,27.0 L437.0,26.3 L441.4,31.7 L447.0,26.1 L452.1,27.3 L459.8,27.9 L464.8,25.0 L469.6,26.3 L476.5,24.1 L480.3,31.5 L484.1,26.1 L491.8,26.3 L496.8,29.2 L503.2,24.9 L507.2,28.3 L511.2,28.2 L515.6,30.0 L518.2,26.0 L525.5,31.1 L528.0,30.2 L533.5,29.7 L538.5,31.3 L543.0,30.8 L547.0,31.6 L553.2,27.5 L559.8,31.3 L564.8,28.4 L568.9,25.2 L575.7,24.5 L582.6,30.3 L585.1,29.8 L592.9,30.6 L596.5,29.2 L602.7,25.1 L610.1,25.2 L614.7,25.3 L617.3,24.9 L620.1,24.5 L626.5,31.0 L631.3,26.5 L636.3,31.5 L639.0,29.6 L644.8,28.0 L650.2,29.0 L655.6,26.0 L660.8,25.1 L665.2,29.9 L671.4,29.2 L677.5,24.7 L683.1,25.9 L688.1,26.6 L690.6,24.7 L698.2,29.4 L701.2,31.8 L708.0,25.1 L712.3,25.9 L718.0,26.8 L721.2,30.6 L727.9,27.5 L733.1,28.7 L739.5,27.2 L742.1,27.0 L747.1,27.8 L754.3,29.0 L759.2,24.8 L762.5,27.0 L769.6,25.2 L773.5,25.3 L777.2,29.6 L781.6,31.5 L787.6,27.8 L790.7,29.3 L796.7,29.8 L800.2,24.2 L803.0,27.2 L807.4,26.5 L811.3,29.9 L814.6,25.9 L822.1,29.2 L829.7,24.5 L834.3,24.4 L842.1,28.2 L845.0,24.6 L850.1,27.2 L852.7,23.0 L857.3,20.4 L865.0,25.4 L869.5,28.3 L873.6,24.9 L881.0,28.8 L884.6,24.1 L889.6,28.6 L895.4,29.8 L899.4,27.6 L903.0,24.9 L905.9,30.2 L910.0,25.0 L913.7,24.7 L919.2,25.7 L921.9,25.6 L926.3,24.8 L930.4,30.0 L937.7,29.2 L943.2,27.5 L949.1,31.6 L955.3,26.1 L959.8,20.1 L963.6,29.4 L966.3,30.1 L968.9,24.4 L973.2,30.9 L978.9,25.8 L983.3,25.4 L990.1,29.8 L995.4,25.4 L1000.2,31.5 L1003.2,26.5 L1008.1,27.5 L1014.7,31.5 L1022.3,28.8 L1029.1,29.6 L1031.7,28.6 L1038.8,27.1 L1042.7,25.6 L1047.1,30.0 L1051.4,26.0 L1058.3,30.8 L1062.9,25.1 L1067.9,24.3 L1070.8,29.7 L1074.3,30.4 L1080.4,30.9 L1087.1,25.1 L1092.7,25.5 L1096.8,24.2 L1101.3,27.8 L1105.8,31.9 L1113.2,29.5 L1118.5,30.4 L1124.1,29.4 L1128.1,24.6 L1132.4,28.6 L1138.6,26.5 L1142.5,30.0 L1148.5,31.7 L1154.6,30.7 L1160.3,25.7 L1167.6,25.9 L1172.9,24.2 L1176.3,29.2 L1183.6,28.9 L1186.6,29.5 L1192.9,27.0 L1196.4,26.4 L1202.2,31.2 L1208.0,30.1 L1210.7,28.5 L1217.9,29.8 L1222.6,28.2 L1226.6,26.2 L1234.2,20.1 L1239.6,28.8 L1243.1,28.8 L1249.2,27.7 L1256.1,31.7 L1263.1,29.2 L1266.7,29.6 L1271.7,24.8 L1275.0,24.7 L1280.7,24.8 L1287.1,30.5 L1293.3,31.4 L1299.1,31.7 L1302.0,24.5 L1306.5,27.7 L1312.9,24.7 L1318.2,27.0 L1323.8,27.0 L1328.9,31.7 L1331.7,30.1 L1335.7,24.9 L1340.0,29.9 L1344.5,26.3 L1350.6,30.3 L1354.6,26.7 L1359.8,24.4 L1363.5,25.3 L1366.4,27.8 L1371.8,27.1 L1374.7,26.8 L1377.1,30.1 L1379.6,26.0 L1384.0,23.7 L1391.7,27.5 L1394.6,26.2 L1400.7,25.1 L1407.3,27.5 L1414.6,29.2 L1417.1,24.2 L1421.8,31.0 L1429.1,27.0 L1435.6,31.1 L1440.0,28.0 L1440,48 Z'/%3E%3C/svg%3E") bottom / 100% 100% no-repeat;
  filter: drop-shadow(0 -6px 10px rgba(59, 35, 20, 0.18));
}
/* зерно бумаги поверх тёмного фона */
.site-footer::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.09;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Задвигающиеся шторы. Полотна (pl-curtain.webp, кант по внутреннему краю)
   не выезжают, а «задёргиваются»: растягиваются от края к центру, складки
   сначала собраны гармошкой (scaleX от края) и расправляются по мере
   прокрутки. --ft-p (0…1) — ход штор, --ft-v — скорость прокрутки (main.js):
   низ полотна отстаёт и пружинит, как ткань. --ft-sway — лёгкое «дыхание»
   в покое. Сверху опускается ламбрекен, снизу разгорается свет рампы. */
@property --ft-sway {
  syntax: '<number>';
  inherits: false;
  initial-value: 0;
}
.site-footer__curtains {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.site-footer__curtain {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 52%;
  /* одно полотно на всю ширину (без повтора — иначе кант тайла давал лишние швы) */
  background: url('../assets/img/v2/pl-curtain.webp') right top / 100% 100% no-repeat;
  filter: brightness(0.86) saturate(1.08);
  will-change: transform;
  animation: ft-sway 7s ease-in-out infinite alternate;
}
.site-footer__curtain--l {
  left: 0;
  transform-origin: 0 0;
  transform:
    scaleX(calc(0.16 + 0.84 * var(--ft-p, 1)))
    skewX(calc((var(--ft-v, 0) + var(--ft-sway)) * 1deg));
}
.site-footer__curtain--r {
  right: 0;
  background: none;
  transform-origin: 100% 0;
  transform:
    scaleX(calc(0.16 + 0.84 * var(--ft-p, 1)))
    skewX(calc((var(--ft-v, 0) - var(--ft-sway)) * 1deg));
  animation-delay: -3.5s;
}
/* правое полотно — зеркальная копия левого (кант к центру); зеркалим только
   картинку, сам бокс сжимается от правого края */
.site-footer__curtain--r::before {
  content: '';
  position: absolute;
  inset: 0;
  /* одно полотно на всю ширину (без повтора — иначе кант тайла давал лишние швы) */
  background: url('../assets/img/v2/pl-curtain.webp') right top / 100% 100% no-repeat;
  transform: scaleX(-1);
}
@keyframes ft-sway {
  from { --ft-sway: -0.6; }
  to   { --ft-sway: 0.6; }
}
/* блик по бархату — скользит по полотну вместе с ходом штор */
.site-footer__curtain::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 214, 160, 0.16) 45%, transparent 60%) no-repeat;
  background-size: 250% 100%;
  background-position: calc(100% - 100% * var(--ft-p, 1)) 0;
  mix-blend-mode: screen;
}

/* ламбрекен: опускается сверху, пока шторы задёргиваются */
.site-footer__valance {
  --vh: 104px;
  --tw: calc(var(--vh) * 924 / 407);
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: var(--vh);
  z-index: 2;
  background: url('../assets/img/v2/pl-valance.webp') calc(50% - var(--tw) * 0.248) 0 / var(--tw) var(--vh) repeat-x;
  filter: brightness(0.92) drop-shadow(0 10px 14px rgba(0, 0, 0, 0.45));
  transform: translateY(calc(-100% * (1 - var(--ft-p, 1))));
  will-change: transform;
}

/* рампа: тёплый свет снизу + вуаль для читаемости текста */
.site-footer__curtains::before {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 70%;
  z-index: 1;
  background: radial-gradient(60% 90% at 50% 100%, rgba(255, 190, 110, 0.32), rgba(255, 170, 80, 0.08) 55%, transparent 75%);
  opacity: calc(0.25 + 0.75 * var(--ft-p, 1));
}
.site-footer__curtains::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(75% 70% at 50% 50%, rgba(33, 14, 10, 0.6), rgba(33, 14, 10, 0.34) 60%, rgba(33, 14, 10, 0.12) 100%),
    linear-gradient(to bottom, rgba(33, 14, 10, 0.2), rgba(33, 14, 10, 0) 35%, rgba(33, 14, 10, 0) 75%, rgba(33, 14, 10, 0.45));
}

.site-footer__stage {
  position: relative;
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 64px 0;
}

/* ── Финальный призыв ── */
.site-footer__hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 20px 60px;
  padding: 8px 0 44px;
  border-bottom: 1px solid var(--ft-line);
}
.site-footer__eyebrow {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0;
  font-family: var(--font-head);
  font-size: 22px;
  color: var(--color-gold);
}
.site-footer__eyebrow::before {
  content: '';
  width: 46px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-gold));
}
.site-footer__headline {
  margin: 0;
  max-width: 820px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 58px;
  line-height: 0.98;
  letter-spacing: -0.005em;
  text-transform: uppercase;
  color: var(--ft-ink);
}
.site-footer__headline em {
  font-style: normal;
  background: linear-gradient(100deg, #C98A2E 0%, #FFE3AC 45%, var(--color-gold) 70%, #C98A2E 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.site-footer__hero-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 18px;
}
.site-footer__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 230px;
  height: 56px;
  padding: 0 34px;
  border-radius: 999px;
  position: relative;
  z-index: 0;
  background: url('../assets/img/button1.webp') center / 100% 100% no-repeat;
  color: var(--color-white);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 16px;
  box-shadow: 0 10px 30px -10px rgba(245, 177, 67, 0.55);
  transition: box-shadow 0.3s ease, color 0.2s ease, transform 0.4s var(--ft-ease);
}
.site-footer__cta::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  opacity: 0;
  background: url('../assets/img/button2.webp') center / 100% 100% no-repeat;
  transition: opacity 0.3s ease;
}
.site-footer__cta:hover { color: var(--color-brown-dark); transform: translateY(-2px); box-shadow: 0 16px 36px -12px rgba(245, 177, 67, 0.7); }
.site-footer__cta:hover::after { opacity: 1; }
.site-footer__bigphone {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 30px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  color: var(--ft-ink);
  background: linear-gradient(var(--color-gold), var(--color-gold)) 0 100% / 0 1px no-repeat;
  transition: background-size 0.5s var(--ft-ease), color 0.2s ease;
}
.site-footer__bigphone:hover { color: var(--color-gold); background-size: 100% 1px; }

/* ── Колонки ── */
.site-footer__top {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1.15fr;
  gap: 40px;
  padding: 40px 0 28px;
}
.site-footer__brand { min-width: 0; }
.site-footer__logo {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--color-cream-light);
  box-shadow: 0 0 0 1px rgba(245, 177, 67, 0.45), 0 0 0 7px rgba(245, 177, 67, 0.08);
}
.site-footer__tagline {
  margin: 16px 0 0;
  font-family: var(--font-text);
  font-size: 15px;
  line-height: 1.6;
  color: var(--ft-soft);
}
.site-footer__social {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.site-footer__social a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 16px;
  border: 1px solid rgba(245, 177, 67, 0.35);
  border-radius: 999px;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--ft-ink);
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.site-footer__social a::after {
  content: '↗';
  font-size: 13px;
  transition: transform 0.4s var(--ft-ease);
}
.site-footer__social a:hover { background: var(--color-gold); border-color: var(--color-gold); color: var(--ft-bg); }
.site-footer__social a:hover::after { transform: translate(2px, -2px); }

.site-footer__col { min-width: 0; }
.site-footer__col-title {
  margin: 6px 0 22px;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--color-gold);
}
.site-footer__col-list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: ft-nav;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.site-footer__col-list li { counter-increment: ft-nav; }
.site-footer__col-list a {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 21px;
  line-height: 1.15;
  color: var(--ft-ink);
  transition: color 0.25s ease, transform 0.45s var(--ft-ease);
}
.site-footer__col-list a::before {
  content: counter(ft-nav, decimal-leading-zero);
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: rgba(245, 177, 67, 0.6);
}
.site-footer__col-list a:hover { color: var(--color-gold); transform: translateX(6px); }

.site-footer__contact-text {
  display: block;
  margin: 0 0 12px;
  font-family: var(--font-text);
  font-size: 15px;
  line-height: 1.6;
  color: var(--ft-soft);
}
.site-footer__contact-phone {
  font-weight: 600;
  font-size: 17px;
  color: var(--ft-ink);
  transition: color 0.2s ease;
}
.site-footer__contact-phone:hover { color: var(--color-gold); }
.site-footer__contact-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-family: var(--font-text);
  font-size: 13px;
  color: var(--ft-soft);
}
.site-footer__contact-note::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #3FAE5C;
  box-shadow: 0 0 0 3px rgba(63, 174, 92, 0.2);
}

/* ── Гигантская подпись: SVG с textLength — всегда ровно во всю ширину,
   нижняя часть букв срезана краем viewBox ── */
.site-footer__wordmark {
  width: 86%;
  margin: 4px auto 0;
  line-height: 0;
  pointer-events: none;
  user-select: none;
}
.site-footer__wordmark svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: hidden;
}
.site-footer__wordmark text {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 150px;
  text-transform: uppercase;
}

/* ── Нижняя строка ── */
.site-footer__bottom {
  display: flex;
  align-items: center;
  gap: 32px;
  padding: 18px 0 22px;
  border-top: 1px solid var(--ft-line);
}
.site-footer__copy {
  margin: 0;
  font-family: var(--font-text);
  font-size: 13px;
  color: var(--ft-soft);
}
.site-footer__dev {
  margin: 0;
  font-family: var(--font-text);
  font-size: 12px;
  color: var(--ft-soft);
  opacity: 0.75;
}
.site-footer__dev a {
  color: inherit;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: color 0.2s ease, background-size 0.45s var(--ft-ease);
}
.site-footer__dev a:hover { color: var(--ft-ink); background-size: 100% 1px; }
.site-footer__legal {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
  margin-left: auto;
}
.site-footer__legal a {
  font-family: var(--font-text);
  font-size: 13px;
  color: var(--ft-soft);
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: color 0.2s ease, background-size 0.45s var(--ft-ease);
}
.site-footer__legal a:hover { color: var(--ft-ink); background-size: 100% 1px; }

.site-footer__totop {
  position: relative;
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  color: var(--color-gold);
  transition: color 0.3s ease;
}
.site-footer__totop-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  animation: ft-ring 22s linear infinite;
}
.site-footer__totop-ring text {
  font-family: var(--font-text);
  font-size: 9.4px;
  font-weight: 600;
  fill: currentColor;
}
.site-footer__totop-arrow {
  position: relative;
  width: 34px;
  height: 34px;
  padding: 7px;
  border-radius: 50%;
  background: rgba(245, 177, 67, 0.12);
  transition: transform 0.5s var(--ft-ease), background-color 0.3s ease, color 0.3s ease;
}
.site-footer__totop:hover .site-footer__totop-ring { animation-duration: 6s; }
.site-footer__totop:hover .site-footer__totop-arrow { transform: translateY(-4px); background: var(--color-gold); color: var(--ft-bg); }
@keyframes ft-ring { to { rotate: 360deg; } }

@media (max-width: 1100px) {
  .site-footer__headline { font-size: 52px; }
  .site-footer__top { grid-template-columns: 1fr 1fr; }
}

/* ============================================================
   ФУТЕР — мобильная раскладка (после базовых правил — выигрывает
   при равной специфичности)
   ============================================================ */
@media (max-width: 768px) {
  .site-footer { padding-top: 36px; }
  .site-footer::before { height: 30px; }
  .site-footer__stage { padding: 0 20px; }
  .site-footer__hero {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 12px 0 40px;
  }
  .site-footer__eyebrow { font-size: 19px; }
  .site-footer__headline { font-size: clamp(32px, 9.6vw, 44px); }
  .site-footer__hero-actions { align-items: stretch; }
  .site-footer__cta { width: 100%; }
  .site-footer__bigphone { font-size: 26px; text-align: center; }
  .site-footer__top {
    grid-template-columns: 1fr 1fr;
    gap: 34px 20px;
    padding: 40px 0 28px;
  }
  .site-footer__brand { grid-column: 1 / -1; }
  .site-footer__col:last-child { grid-column: 1 / -1; }
  .site-footer__col-list a { font-size: 19px; }
  .site-footer__bottom {
    flex-wrap: wrap;
    gap: 16px 20px;
    padding: 22px 0 26px;
  }
  .site-footer__copy { order: 2; width: 100%; }
  .site-footer__dev { order: 3; width: 100%; margin-top: -10px; }
  .site-footer__legal { order: 1; margin-left: 0; flex: 1; flex-direction: column; gap: 8px; }
  .site-footer__totop { order: 1; width: 64px; height: 64px; }
}

@media (prefers-reduced-motion: reduce) {
  .site-footer__totop-ring { animation: none; }
}

/* ============================================================
   ДОСТУПНОСТЬ — служебные классы (визуально ничего не меняют)
   ============================================================ */
/* Скрыт визуально, доступен скринридерам и формам (поле «Приз рулетки» и т.п.) */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
/* «Перейти к содержимому»: появляется только при фокусе с клавиатуры */
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 2000;
  padding: 10px 18px;
  border-radius: 999px;
  background: #2A170C;
  color: #F8E6BF;
  font-family: var(--font-text);
  font-weight: 600;
  font-size: 14px;
  transform: translateY(-160%);
  transition: transform 0.2s ease;
}
.skip-link:focus { transform: none; outline: 2px solid var(--color-gold); outline-offset: 2px; }

/* ============================================================
   ОТЛОЖЕННЫЕ ФОНЫ (скрипт в <head> index.html): пока блок далеко от экрана,
   его CSS-картинки (и у потомков) не запрашиваются. Цвет фона остаётся.
   ============================================================ */
.lazy-bg [data-lazy-bg]:not(.bg-in),
.lazy-bg [data-lazy-bg]:not(.bg-in)::before,
.lazy-bg [data-lazy-bg]:not(.bg-in)::after,
.lazy-bg [data-lazy-bg]:not(.bg-in) *,
.lazy-bg [data-lazy-bg]:not(.bg-in) *::before,
.lazy-bg [data-lazy-bg]:not(.bg-in) *::after {
  background-image: none !important;
  border-image-source: none !important;
}
