/* ============================================================
   АЗБУКА СЕВЕРА — стили сайта
   Структура файла:
     1. Дизайн-токены (CSS-переменные)
     2. Базовые сбросы и типографика
     3. Переиспользуемые элементы (контейнер, кнопки, плейсхолдеры)
     4. Секции сверху вниз (шапка → hero → каталог → квиз → доверие → почему → FAQ → подвал)
     5. Адаптив (медиа-запросы)
   ============================================================ */

/* 1. ДИЗАЙН-ТОКЕНЫ ------------------------------------------------
   :root — это корень документа. Переменные здесь доступны во всём CSS.
   Значения взяты ровно из макета Figma (стили цветов и шрифтов). */
:root {
  --bg:        #22140C; /* основной тёмный фон (токен "background") */
  --text:      #FFECCE; /* кремовый текст и заливка карточек (токен "main text") */
  --light:     #F3E6D1; /* фон светлых секций (токен "light") */
  --muted:     #655043; /* лого и вторичный/приглушённый текст (токен "logo color") */
  --olive:     #9FA37C; /* акцент-олива (токен "olive"); точный hex недоступен на View-доступе */

  /* Контейнер: в макете ширина кадра 1440px, поля по 160px → контент 1120px */
  --container: 1120px;
  --gap: 20px;          /* базовый отступ между карточками (как в макете) */
  --radius-card: 12px;  /* скругление карточек */
  --radius-btn: 10px;   /* скругление кнопок */
}

/* 2. БАЗА ---------------------------------------------------------- */
/* Сброс: убираем стандартные отступы и переводим box-sizing в border-box,
   чтобы padding не увеличивал ширину элементов (так считать размеры проще). */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }              /* плавная прокрутка к якорям #... */

body {
  font-family: 'Raleway', system-ui, sans-serif; /* основной шрифт — Raleway */
  font-weight: 400;
  font-size: 16px;                                /* базовый размер тела (body 16/24) */
  line-height: 24px;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;            /* сглаживание шрифта в WebKit */
  overflow-x: hidden;                             /* прячем горизонтальную прокрутку */
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

/* Курсивный акцент — Playfair Display Italic (токен h2). Используется в заголовках. */
.accent-serif {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-weight: 600;
}

/* 3. ПЕРЕИСПОЛЬЗУЕМЫЕ ЭЛЕМЕНТЫ ------------------------------------ */

/* Контейнер центрирует контент и держит максимальную ширину 1120px */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px; /* боковые поля на узких экранах */
}

/* Универсальный заголовок секции (h2): Playfair italic, 40/54 */
.section-title {
  font-size: 40px;
  line-height: 54px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

/* --- Кнопки ---
   btn--ghost: прозрачная с кремовой рамкой и мягким свечением (как в макете).
   btn--dark:  для светлых секций — тёмная рамка/текст. */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 18px 32px;            /* паддинг кнопки из макета */
  border-radius: var(--radius-btn);
  font-size: 18px;               /* токен "button" 18/24 */
  line-height: 24px;
  font-weight: 500;
  transition: all .25s ease;     /* плавность при наведении */
  white-space: nowrap;
}
.btn--ghost {
  color: var(--text);
  border: 1px solid rgba(255, 236, 206, .55);
  box-shadow: 0 0 8px rgba(255, 236, 206, .30); /* кремовое свечение (drop shadow из макета) */
  background: rgba(255, 236, 206, .02);
}
.btn--ghost:hover {
  background: rgba(255, 236, 206, .12);
  box-shadow: 0 0 16px rgba(255, 236, 206, .45);
}
.btn--dark {
  color: var(--bg);
  border: 1px solid rgba(34, 20, 12, .5);
  background: transparent;
}
.btn--dark:hover { background: rgba(34, 20, 12, .07); }
.btn--sm { padding: 12px 22px; font-size: 14px; }

/* Круглая стрелка (карусель, «следующий вопрос») */
.round-arrow {
  width: 40px; height: 40px;
  border-radius: 50%;
  border: 1px solid currentColor;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 20px; line-height: 1;
  transition: all .2s ease;
}
.round-arrow:hover { background: var(--text); color: var(--bg); }   /* var(--text), не currentColor — иначе иконка сливалась с фоном (особенно «залипший» hover на тач-экранах) */
.round-arrow--inline { width: 28px; height: 28px; font-size: 16px; }

/* --- Плейсхолдеры изображений ---
   Пока в папке assets/ нет реальных фото, показываем красивую «заглушку»
   в цветах макета. JS (main.js) попытается подставить реальное фото из data-img;
   если файла нет — останется эта заглушка. */
.ph {
  background-color: #2c1c12;
  background-image:
    radial-gradient(120% 80% at 30% 10%, rgba(159,163,124,.18), transparent 60%),
    radial-gradient(120% 90% at 80% 90%, rgba(101,80,67,.55), transparent 55%),
    linear-gradient(135deg, #34241a 0%, #20130b 100%);
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
}
/* Маленькая подпись «фото» в углу заглушки — чтобы было понятно, что сюда встанет картинка */
.ph::after {
  content: "фото";
  position: absolute; right: 10px; bottom: 8px;
  font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: rgba(255,236,206,.35);
}
.ph.is-loaded::after { content: none; } /* когда подставлено реальное фото — подпись убираем */

/* Арка/овал — для фото товара в квизе и в секции «Почему нас выбирают» */
.ph--arch { border-radius: 50% / 38%; }

/* 4. СЕКЦИИ -------------------------------------------------------- */

/* --- 4.1 ШАПКА --- */
.site-header {
  position: absolute;     /* лежит поверх hero, не занимая высоту */
  top: 0; left: 0; right: 0;
  z-index: 20;
  padding-top: 15px;      /* лого в макете на top:15px */
}
.header__inner {
  display: flex;
  align-items: center;
  gap: 32px;
}
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--text); }
.logo__mark { color: var(--text); flex: none; }
.logo__text {
  font-weight: 700;
  font-size: 13px;
  line-height: 14px;
  letter-spacing: .14em;
}
.header__nav { display: flex; gap: 28px; margin: 0 auto 0 24px; } /* mx-auto толкает блок в центр-лево */
.nav-link {
  font-size: 14px; line-height: 24px;       /* токен "menu" 14/24 */
  color: var(--text); opacity: .85;
  transition: opacity .2s;
}
.nav-link:hover { opacity: 1; }
.header__actions { display: flex; align-items: center; gap: 22px; }
.pill {
  border: 1px solid rgba(255,236,206,.6);
  border-radius: 20px;
  padding: 7px 20px;
  font-size: 14px;
}
.pill:hover { background: rgba(255,236,206,.1); }
.header__phone { font-size: 14px; line-height: 24px; white-space: nowrap; } /* токен "telephone" */

/* Бургер скрыт на десктопе, показывается только в адаптиве */
.burger { display: none; flex-direction: column; gap: 5px; padding: 6px; }
.burger span { width: 26px; height: 2px; background: var(--text); transition: .3s; }

/* --- 4.2 HERO --- */
.hero { position: relative; padding-top: 108px; padding-bottom: 60px; } /* заголовок на top:108 в макете */
.hero__heading { text-align: center; }
.hero__title {
  font-weight: 300;                 /* h1 Raleway Light 300 */
  font-size: 36px; line-height: 54px;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.hero__title-accent {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic; font-weight: 600;
  font-size: 40px; line-height: 54px;   /* h2 40/54 */
  text-transform: uppercase;
}
.hero__subtitle { margin-top: 10px; font-size: 14px; opacity: .8; }

/* Большое изображение hero: в макете 1320×700 (поля по 60px).
   Приём ниже центрирует элемент шире контейнера (выходим за 1120px к 1320px). */
.hero__image {
  width: min(1320px, calc(100vw - 48px));
  aspect-ratio: 1320 / 700;          /* держим пропорции кадра из макета */
  margin: 36px auto 0;
  margin-left: 50%;
  transform: translateX(-50%);
  border-radius: 18px;
}
.hero__buttons { display: flex; justify-content: center; gap: var(--gap); margin-top: 28px; }

/* --- 4.3 КАТАЛОГ --- */
.catalog { padding: 70px 0 90px; }
.catalog__top {
  display: grid;
  grid-template-columns: 1.3fr 1fr;  /* слева коллаж, справа вводный текст */
  gap: 40px;
  align-items: center;
  margin-bottom: 36px;
}
.catalog__collage {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  height: 150px;
}
.collage__img { border-radius: 10px; height: 100%; }
.collage__tag {
  display: flex; align-items: center; justify-content: center;
  background: var(--text);
  border-radius: 10px;
  color: var(--bg);
}
.collage__tag .accent-serif { font-size: 22px; text-transform: uppercase; letter-spacing: .03em; }
.catalog__intro { font-size: 16px; line-height: 24px; color: var(--text); opacity: .9; max-width: 480px; }
.catalog__intro b { font-weight: 700; }

.catalog__slogan {
  font-size: 40px;
  line-height: 54px;
  font-weight: 300;
  text-transform: uppercase;
  letter-spacing: .01em;
  max-width: 1000px;
  margin: 0 auto 40px;
  text-align: center;
}

/* Карусель: горизонтальная лента карточек, листается через JS */
.carousel { overflow: hidden; }
.carousel__track {
  display: flex;
  gap: var(--gap);
  transition: transform .4s ease;   /* плавное смещение при листании */
}
.product-card {
  flex: 0 0 calc((100% - 3 * var(--gap)) / 4); /* по 4 карточки в ряд */
  background: var(--text);                       /* кремовая заливка (как в макете) */
  border-radius: var(--radius-card);
  position: relative;
  overflow: hidden;
  display: flex; flex-direction: column;
  color: var(--bg);                              /* тёмный текст на кремовой карточке */
  transition: transform .25s ease, box-shadow .25s ease;
}
.product-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(0,0,0,.35); }
/* Верхняя часть — фото товара (квадрат) на белом фоне */
.product-card__img { display: block; width: 100%; aspect-ratio: 1 / 1; background: #fff; }
.product-card__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* Нижняя часть — название и цена */
.product-card__info { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px 16px; flex: 1; }
.product-card__name {
  font-size: 13px; line-height: 18px; font-weight: 600;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; /* не более 2 строк */
}
.product-card__price { font-size: 16px; font-weight: 700; margin-top: auto; }
.card-add {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--bg); color: var(--text);
  font-size: 18px; line-height: 1;
  display: flex; align-items: center; justify-content: center;
}
.product-card:hover .card-add { background: var(--olive); color: var(--bg); }

.carousel__nav { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 26px; }
.carousel__progress { width: 120px; height: 2px; background: rgba(255,236,206,.25); position: relative; border-radius: 2px; }
.carousel__progress i { position: absolute; left: 0; top: 0; height: 100%; width: 40%; background: var(--text); border-radius: 2px; transition: left .4s ease; }

/* --- 4.4 КВИЗ (светлая секция) --- */
.quiz {
  background: var(--light);
  color: var(--bg);                 /* на светлом фоне текст тёмный */
  padding: 80px 0;
}
.quiz__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}
.quiz__title { font-size: 36px; line-height: 54px; font-weight: 300; text-transform: uppercase; }
.quiz__title .accent-serif { font-size: 40px; }
.quiz__hint { font-size: 14px; opacity: .7; margin-top: 4px; }
.quiz__question { font-size: 16px; line-height: 24px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; margin: 40px 0 24px; }

/* Радио-кнопки в две колонки */
.quiz__options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  margin-bottom: 36px;
}
.radio { display: flex; align-items: center; gap: 12px; font-size: 16px; cursor: pointer; }
.radio input { display: none; }                 /* прячем родной кружок, рисуем свой */
.radio__dot {
  width: 18px; height: 18px; border-radius: 50%;
  border: 1.5px solid var(--bg);
  flex: none; position: relative;
}
/* когда radio выбран — рисуем точку внутри */
.radio input:checked + .radio__dot::after {
  content: ""; position: absolute; inset: 3px;
  background: var(--bg); border-radius: 50%;
}
.quiz__next {
  display: inline-flex; align-items: center; gap: 14px;
  font-size: 16px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase;
  color: var(--bg);
}
.quiz__next .round-arrow--inline { border-color: var(--bg); }
.quiz__next:hover .round-arrow--inline { background: var(--bg); color: var(--light); }

.quiz__image { width: 100%; aspect-ratio: 1 / 1.05; }

/* --- 4.5 НАМ ДОВЕРЯЮТ --- */
.trust { padding: 80px 0; }
.trust .section-title { text-align: center; margin-bottom: 40px; }
.trust__label { font-size: 14px; color: var(--olive); margin: 24px 0 16px; letter-spacing: .04em; }

.cases, .reviews {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--gap);
  align-items: start;
}
.case-card { display: flex; flex-direction: column; color: inherit; text-decoration: none; transition: transform .25s ease; }
.case-card:hover { transform: translateY(-4px); }                          /* кейсы кликабельны → ведут на товар */
.case-card:hover .case-card__img { box-shadow: 0 12px 28px rgba(0,0,0,.35); }
.case-card__img {
  background-color: var(--text);
  background-size: cover; background-position: center; background-repeat: no-repeat;  /* ВАЖНО: явно, иначе background-shorthand сбрасывал размер и фото показывалось куском из угла */
  border-radius: var(--radius-card);
  aspect-ratio: 1 / 1;              /* квадрат — как главное фото товара */
  margin-bottom: 14px;
}
.case-card__img::after { color: rgba(34,20,12,.3); } /* подпись «фото» на кремовой карточке темнее */
.case-card__title { font-size: 13px; font-weight: 700; letter-spacing: .03em; margin-bottom: 10px; }
.case-card__row { font-size: 13px; line-height: 20px; color: var(--text); opacity: .85; margin-bottom: 4px; }
.case-card__row b { font-weight: 700; opacity: 1; }

.reviews { margin-top: 4px; }
.review__author { font-size: 14px; color: var(--olive); letter-spacing: .04em; margin-bottom: 12px; }
.review__text { font-size: 14px; line-height: 22px; color: var(--text); opacity: .8; }

/* Кейс + его отзыв в одной колонке: «для этих собрали то-то → вот такой отзыв» */
.case-col { display: flex; flex-direction: column; }
.case-review { margin-top: 16px; padding-top: 16px; border-top: 1px solid rgba(255,236,206,.14); }
.case-review .review__author { margin-bottom: 8px; }

/* --- 4.6 ПОЧЕМУ НАС ВЫБИРАЮТ (светлая секция) --- */
.why { background: var(--light); color: var(--bg); padding: 80px 0; }
.why__inner {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: 50px;
  align-items: center;
}
.why__image { width: 100%; aspect-ratio: 1 / 1.25; }
.why .section-title { margin-bottom: 18px; }
.why__intro { font-size: 16px; line-height: 24px; max-width: 520px; margin-bottom: 30px; }
.why__intro b, .why__cta-text b { font-weight: 700; }

.features {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px 30px;
  margin-bottom: 34px;
}
.feature__num { font-size: 40px; line-height: 1; display: block; margin-bottom: 6px; }
.feature__title { font-size: 16px; line-height: 22px; }
.why__cta-text { font-size: 14px; line-height: 22px; max-width: 540px; margin-bottom: 22px; }

/* --- 4.7 FAQ --- */
.faq { padding: 70px 0 90px; }
.faq__title { font-size: 40px; line-height: 54px; font-weight: 300; text-transform: uppercase; text-align: center; margin-bottom: 40px; }

.accordion { max-width: 760px; margin: 0 auto; }
.acc-item { border-bottom: 1px solid rgba(255,236,206,.12); }
.acc-q {
  width: 100%; text-align: center;
  padding: 18px 10px;
  font-size: 15px; line-height: 22px; color: var(--text);
  position: relative;
  transition: opacity .2s;
}
.acc-q:hover { opacity: .75; }
/* Раскрытый ответ: по умолчанию скрыт (max-height:0), раскрывается классом is-open */
.acc-a {
  max-height: 0; overflow: hidden;
  transition: max-height .35s ease, padding .35s ease;
}
.acc-a p {
  font-size: 14px; line-height: 22px; color: var(--text); opacity: .7;
  max-width: 620px; margin: 0 auto;
}
/* Открытый элемент аккордеона: подсвечиваем карточкой и показываем ответ */
.acc-item.is-open {
  background: rgba(255,236,206,.05);
  border-radius: 14px;
  border-bottom-color: transparent;
}
.acc-item.is-open .acc-a { max-height: 300px; padding: 0 16px 22px; }

/* --- 4.8 ПОДВАЛ --- */
.footer { background: #2a1a10; padding: 60px 0 24px; } /* фон чуть светлее основного — как в макете */
.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.4fr;
  gap: 30px;
}
.footer__phone { font-size: 22px; font-weight: 700; }
.footer__buttons { display: flex; gap: 12px; margin: 18px 0; flex-wrap: wrap; }
.footer__socials { display: flex; gap: 14px; }
.soc {
  width: 32px; height: 32px; border-radius: 50%;
  border: 1px solid rgba(255,236,206,.4);
  display: flex; align-items: center; justify-content: center;
  font-size: 12px;
}
.soc:hover { background: rgba(255,236,206,.12); }

.footer__col-title { font-size: 14px; font-weight: 600; margin-bottom: 14px; }
.footer__col a, .footer__stores li {
  display: block;
  font-size: 13px; line-height: 28px;
  color: var(--text); opacity: .7;
}
.footer__col a:hover { opacity: 1; }
.footer__stores li { margin-bottom: 6px; }
.footer__all { display: inline-block; font-size: 13px; color: var(--olive); margin-top: 6px; }

.rating { display: flex; align-items: center; gap: 8px; margin-top: 18px; background: var(--text); color: var(--bg); padding: 8px 12px; border-radius: 8px; width: fit-content; }
.rating__score { font-weight: 700; }
.rating__stars { color: #e8b04b; letter-spacing: 2px; }
.rating__cap { font-size: 10px; opacity: .7; max-width: 120px; line-height: 12px; }

.footer__bottom {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  margin-top: 40px; padding-top: 20px;
  border-top: 1px solid rgba(255,236,206,.12);
}
.footer__legal { display: flex; gap: 26px; flex-wrap: wrap; }
.footer__legal a { font-size: 12px; opacity: .6; }
.footer__legal a:hover { opacity: 1; }
.footer__copy { font-size: 12px; opacity: .6; }

/* 5. АДАПТИВ ------------------------------------------------------- */

/* Планшеты и небольшие ноутбуки */
@media (max-width: 1024px) {
  .footer__inner { grid-template-columns: 1fr 1fr; gap: 36px 24px; }
  .product-card { flex-basis: calc((100% - var(--gap)) / 2); } /* по 2 карточки */
}

/* Телефоны */
@media (max-width: 720px) {
  /* Шапка: прячем «десктопные» элементы, показываем бургер */
  .header__nav, .header__actions { display: none; }
  .burger { display: flex; }
  .header__inner { justify-content: space-between; }

  /* Мобильное меню: выпадает поверх, переключается классом .is-open через JS */
  .site-header.menu-open .header__nav,
  .site-header.menu-open .header__actions {
    display: flex; flex-direction: column; gap: 16px;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--bg); padding: 24px;
    border-top: 1px solid rgba(255,236,206,.12);
  }
  .site-header.menu-open .header__nav { margin: 0; }

  /* Заголовки уменьшаем */
  .hero__title, .quiz__title { font-size: 26px; line-height: 38px; }
  .hero__title-accent, .quiz__title .accent-serif { font-size: 30px; line-height: 38px; }
  .section-title, .catalog__slogan, .faq__title { font-size: 28px; line-height: 38px; }

  /* Всё в одну колонку */
  .catalog__top, .quiz__inner, .why__inner { grid-template-columns: 1fr; gap: 28px; }
  .why__image, .quiz__image { max-width: 340px; margin: 0 auto; }
  .quiz__options, .features { grid-template-columns: 1fr; }
  .cases, .reviews { grid-template-columns: 1fr 1fr; gap: 24px 16px; }
  .product-card { flex-basis: calc((100% - var(--gap)) / 2); }
  .footer__inner { grid-template-columns: 1fr; }
  /* Правовые ссылки — в столбик, по одной на строку (а не в строку с переносом) */
  .footer__bottom { flex-direction: column; align-items: flex-start; gap: 18px; }
  .footer__legal { flex-direction: column; gap: 14px; }
  .catalog__collage { height: 110px; }
  .hero__buttons { flex-direction: column; align-items: center; }
  .btn { width: 100%; max-width: 320px; }
}

/* Совсем узкие экраны */
@media (max-width: 460px) {
  .cases, .reviews { grid-template-columns: 1fr; }
  .product-card { flex-basis: 100%; }
}

/* ============================================================
   ПОЛИРОВКА (frontend-design): движение · микровзаимодействия · доступность
   Принцип: в ПОКОЕ вид не меняется (совпадает с макетом Figma) —
   анимации живут только при загрузке / скролле / наведении / фокусе
   и полностью отключаются при prefers-reduced-motion.
   ============================================================ */

/* Плавная прокрутка к якорям (кнопки «Рассчитать стоимость» → #quiz и пр.) */
html { scroll-behavior: smooth; }

/* — Вход первого экрана при загрузке: мягкий подъём со сдвигом — */
.hero__title, .hero__title-accent, .hero__subtitle, .hero__buttons {
  opacity: 0;
  animation: fadeUp .9s cubic-bezier(.22, .61, .36, 1) forwards;
}
.hero__title        { animation-delay: .05s; }
.hero__title-accent { animation-delay: .15s; }
.hero__subtitle     { animation-delay: .25s; }
.hero__buttons      { animation-delay: .45s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }

/* Hero-изображение центрируется через transform: translateX(-50%),
   поэтому анимируем ТОЛЬКО прозрачность — иначе центрирование собьётся
   и картинка «уедет» вправо. */
.hero__image { opacity: 0; animation: heroImgFade .9s ease .30s forwards; }
@keyframes heroImgFade { from { opacity: 0; } to { opacity: 1; } }

/* — Появление блоков при попадании в зону видимости (класс вешает JS;
     без JS контент остаётся видимым) — */
.reveal { opacity: 0; transform: translateY(26px); }
.reveal.is-visible {
  opacity: 1; transform: none;
  transition: opacity .8s cubic-bezier(.22, .61, .36, 1), transform .8s cubic-bezier(.22, .61, .36, 1);
}

/* Сетки (коллаж, кейсы, отзывы, преимущества) — со стаггером по детям */
.reveal-group > * { opacity: 0; transform: translateY(22px); }
.reveal-group.is-visible > * {
  opacity: 1; transform: none;
  transition: opacity .65s cubic-bezier(.22, .61, .36, 1), transform .65s cubic-bezier(.22, .61, .36, 1);
}
.reveal-group.is-visible > *:nth-child(2) { transition-delay: .08s; }
.reveal-group.is-visible > *:nth-child(3) { transition-delay: .16s; }
.reveal-group.is-visible > *:nth-child(4) { transition-delay: .24s; }

/* — Микровзаимодействие: лёгкий зум фото товара при наведении — */
.product-card__img { overflow: hidden; }
.product-card__img img { transition: transform .55s cubic-bezier(.22, .61, .36, 1); }
.product-card:hover .product-card__img img { transform: scale(1.05); }

/* — Подчёркивание ссылок в шапке при наведении — */
.nav-link { position: relative; }
.nav-link::after {
  content: ""; position: absolute; left: 0; bottom: -4px;
  width: 100%; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: left;
  transition: transform .35s cubic-bezier(.22, .61, .36, 1);
}
.nav-link:hover::after { transform: scaleX(1); }

/* — Доступность: заметный фокус с клавиатуры (не появляется при кликах мышью) — */
a:focus-visible, button:focus-visible, input:focus-visible,
.product-card:focus-visible, .acc-q:focus-visible, .radio:focus-within {
  outline: 2px solid var(--olive);
  outline-offset: 3px;
  border-radius: 6px;
}

/* — Уважаем системную настройку «уменьшить движение» — */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero__title, .hero__title-accent, .hero__subtitle, .hero__buttons,
  .reveal, .reveal-group > * {
    opacity: 1 !important; transform: none !important;
    animation: none !important; transition: none !important;
  }
  /* hero-изображению transform НЕ сбрасываем — это его центрирование */
  .hero__image { opacity: 1 !important; animation: none !important; }
}

/* ============================================================
   МОДАЛЬНАЯ ФОРМА ЗАЯВКИ — в стиле макета (светлая карточка, как блок-квиз)
   ============================================================ */
.modal {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  opacity: 0; visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.modal.is-open { opacity: 1; visibility: visible; }
.modal__overlay {
  position: absolute; inset: 0;
  background: rgba(20, 12, 7, .72);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
}
.modal__card {
  position: relative; z-index: 1;
  width: min(520px, 100%);
  max-height: calc(100vh - 48px); overflow-y: auto;
  background: var(--light); color: var(--bg);
  border-radius: 20px;
  padding: 42px 38px 30px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .5);
  transform: translateY(18px) scale(.98);
  transition: transform .35s cubic-bezier(.22, .61, .36, 1);
}
.modal.is-open .modal__card { transform: none; }
.modal__close {
  position: absolute; top: 16px; right: 18px;
  width: 36px; height: 36px; border-radius: 50%;
  font-size: 26px; line-height: 1; color: var(--bg);
  display: flex; align-items: center; justify-content: center;
  transition: background .2s ease;
}
.modal__close:hover { background: rgba(34, 20, 12, .08); }
.modal__title { font-size: 30px; line-height: 1.12; margin-bottom: 8px; }
.modal__sub { font-size: 15px; line-height: 22px; opacity: .72; margin-bottom: 24px; }
.modal__form { display: flex; flex-direction: column; gap: 16px; }
/* hidden-атрибут должен реально прятать форму/успех (иначе display:flex его перебивает) */
.modal__form[hidden], .modal__success[hidden] { display: none; }
.field { display: flex; flex-direction: column; gap: 7px; }
.field__label { font-size: 13px; font-weight: 600; }
.field__opt { font-weight: 400; opacity: .55; }
.field__input {
  font-family: inherit; font-size: 15px; color: var(--bg);
  padding: 13px 15px; border-radius: 10px;
  background: #FBF6EE; border: 1px solid rgba(34, 20, 12, .18);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field__input::placeholder { color: rgba(34, 20, 12, .4); }
.field__input:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 3px rgba(159, 163, 124, .22); }
.field__textarea { resize: vertical; min-height: 78px; }
.field.is-invalid .field__input { border-color: #b23b3b; box-shadow: 0 0 0 3px rgba(178, 59, 59, .15); }
.field__error { display: none; margin-top: 2px; font-size: 12px; line-height: 16px; color: #b23b3b; }
.field.is-invalid .field__error { display: block; }
.modal__submit { width: 100%; margin-top: 6px; background: var(--bg); color: var(--text); border: 1px solid var(--bg); }
.modal__submit:hover { background: #2e1c11; }
.modal__legal { font-size: 12px; line-height: 17px; opacity: .62; margin-top: 12px; text-align: center; }
.modal__legal a { text-decoration: underline; }
.modal__success { text-align: center; padding: 14px 0 4px; }
.modal__success-mark {
  width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 50%;
  background: var(--olive); color: var(--light);
  display: flex; align-items: center; justify-content: center; font-size: 32px;
}
.modal__success .btn { margin-top: 18px; }
@media (max-width: 460px) {
  .modal__card { padding: 34px 22px 26px; }
  .modal__title { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  .modal, .modal__card { transition: opacity .2s ease, visibility .2s ease; }
  .modal__card { transform: none; }
}
