/* =========================================================
   Дизайн-система
   ========================================================= */
:root {
  /* Палитра из ТЗ */
  --bg: #EAE6DF;
  --bg-soft: #F5F3EF;
  --card: #FFFFFF;
  --sand: #E2DDD5;
  --accent: #E07A2E;
  --accent-hover: #EB8A40;
  --ink: #2C2623;
  --soft-ink: #7A7267;
  /* #7A7267 из ТЗ, чуть темнее: мелкий текст на бежевом и песочном должен проходить WCAG AA */
  --muted: #665E55;
  /* Терракота для текста и цифр на светлом фоне: #E07A2E там слишком бледный для чтения */
  --accent-text: #AD5313;
  /* Терракота для текста на терракотовой подложке (.12): --accent-text там даёт 4.2:1, этот — 4.9:1 */
  --accent-text-tint: #9E4A10;
  /* Терракота на тёмном для мелкого текста */
  --accent-on-dark: #EB8A40;
  --line: rgba(44, 38, 35, .12);
  --line-strong: rgba(44, 38, 35, .24);
  --on-dark: #F5F3EF;
  --on-dark-muted: rgba(245, 243, 239, .7);
  --error: #B3261E;
  --success: #2F6B3F;

  --r-xl: 32px;
  --r-lg: 28px;
  --r-md: 20px;
  --r-sm: 14px;

  --max: 1440px;
  --gutter: clamp(16px, 3.2vw, 40px);
  --gap: clamp(10px, 1.1vw, 16px);
  --pad: clamp(22px, 2.6vw, 40px);
  --header-h: 76px;

  --font: "Geologica", "Segoe UI", system-ui, -apple-system, sans-serif;
  --fs-body: clamp(15px, .9rem + .12vw, 17px);
  --fs-h1: clamp(42px, 1rem + 4vw, 92px);
  --fs-h2: clamp(34px, 1rem + 3.1vw, 68px);
  --fs-h3: clamp(22px, 1rem + .6vw, 28px);

  --ease: cubic-bezier(.22, .8, .24, 1);
  --shadow-float: 0 30px 60px -30px rgba(44, 38, 35, .45), 0 2px 6px rgba(44, 38, 35, .08);

  --check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232C2623' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12.5 4.5 4.5L19 7.5'/%3E%3C/svg%3E");
  --arrow-right: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232C2623' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14M13 6l6 6-6 6'/%3E%3C/svg%3E");
  /* Лёгкое зерно микроцемента под фоном страницы */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .17 0 0 0 0 .15 0 0 0 0 .13 .09 0 0 0 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");

  color-scheme: light;
}

/* =========================================================
   База
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
  -webkit-text-size-adjust: 100%;
}

/* Полоса прокрутки в палитре сайта: бежевый трек, терракотовый «ползунок» с зазором-рамкой */
html { scrollbar-width: thin; scrollbar-color: var(--accent) var(--sand); }
@supports selector(::-webkit-scrollbar) {
  html { scrollbar-width: auto; scrollbar-color: auto; }
  ::-webkit-scrollbar { width: 14px; height: 14px; }
  ::-webkit-scrollbar-track { background: var(--sand); }
  ::-webkit-scrollbar-thumb {
    background: var(--accent);
    border: 4px solid var(--sand);
    border-radius: 99px;
  }
  ::-webkit-scrollbar-thumb:hover { background: var(--accent-hover); }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.55;
  color: var(--ink);
  background: var(--grain), var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img, svg, video { display: block; max-width: 100%; }
h1, h2, h3, p, figure { margin: 0; }
h1, h2, h3 {
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -.035em;
  text-wrap: balance;
}
p { text-wrap: pretty; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
ul, ol { list-style: none; margin: 0; padding: 0; }

:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 8px; }

.icon {
  width: 20px;
  height: 20px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

.skip-link {
  position: fixed;
  left: 16px;
  top: -100px;
  z-index: 100;
  padding: 12px 18px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--on-dark);
}
.skip-link:focus { top: 16px; }

/* =========================================================
   Кнопки, пилюли
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 22px;
  border-radius: 999px;
  border: 1.5px solid transparent;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -.01em;
  white-space: nowrap;
  transition: background-color .2s, border-color .2s, color .2s, transform .25s var(--ease);
}
.btn:active { transform: translateY(1px); }
.btn--sm { min-height: 40px; padding: 0 18px; font-size: 14px; }
.btn--lg { min-height: 56px; padding: 0 28px; font-size: 16px; }

/* Текст на терракоте — тёмный: белый на #E07A2E не проходит по контрасту */
.btn--accent { background: var(--accent); color: var(--ink); }
.btn--accent:hover { background: var(--accent-hover); }
.btn--outline { border-color: var(--line-strong); color: var(--ink); }
.btn--outline:hover { border-color: var(--ink); background: rgba(255, 255, 255, .6); }
.btn[disabled] { opacity: .6; pointer-events: none; }

.round-btn {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--on-dark);
  transition: transform .4s var(--ease), background-color .2s;
}
.round-btn:hover { transform: rotate(45deg); }
.round-btn--accent { background: var(--accent); color: var(--ink); }
.round-btn--light { background: rgba(255, 255, 255, .92); color: var(--ink); }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 5px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--bg-soft);
  font-size: 13.5px;
  line-height: 1.25;
  white-space: nowrap;
}
.pill .icon { width: 16px; height: 16px; }
.pill--sand { background: var(--sand); border-color: transparent; }
.pill--white { background: #fff; border-color: transparent; }
.pill--accent { background: var(--accent); border-color: transparent; color: var(--ink); }
.pill--glass {
  background: rgba(255, 255, 255, .74);
  border-color: rgba(255, 255, 255, .55);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  color: var(--ink);
}
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pills .pill { white-space: normal; }

/* =========================================================
   Шапка
   ========================================================= */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding-top: 10px;
}
.header__bar {
  display: flex;
  align-items: center;
  gap: 20px;
  height: 64px;
  padding: 0 10px 0 14px;
  border-radius: 999px;
  /* Шапка — всегда плашка: прозрачная над бежевым фоном она терялась */
  background: rgba(245, 243, 239, .72);
  -webkit-backdrop-filter: saturate(1.4) blur(16px);
  backdrop-filter: saturate(1.4) blur(16px);
  box-shadow: 0 0 0 1px var(--line);
  transition: background-color .3s, box-shadow .3s;
}
.header.is-scrolled .header__bar,
.header.is-menu-open .header__bar {
  background: rgba(245, 243, 239, .9);
  box-shadow: 0 0 0 1px var(--line), 0 14px 32px -16px rgba(44, 38, 35, .4);
}

.logo { display: inline-flex; align-items: center; gap: 12px; min-width: 0; }
.logo__mark { width: 38px; height: 38px; fill: var(--ink); transition: transform .35s var(--ease); }
.logo__mark .f-top { fill: var(--accent); }
.logo__mark .f-left { fill: var(--sand); }
.logo__mark .f-right { fill: var(--soft-ink); }
.logo:hover .logo__mark { transform: rotate(-6deg); }
.logo__text { display: grid; gap: 1px; line-height: 1.15; min-width: 0; }
.logo__name { font-weight: 650; font-size: 20px; letter-spacing: -.04em; }
.logo__descr { font-size: 11.5px; color: var(--muted); white-space: nowrap; }

.nav { display: flex; gap: 2px; margin-inline: auto; padding: 4px; border-radius: 999px; background: rgba(44, 38, 35, .05); }
.nav a {
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 500;
  white-space: nowrap;
  color: var(--muted);
  transition: color .2s, background-color .2s, box-shadow .2s;
}
@media (max-width: 1440px) {
  .nav a { padding: 8px 12px; }
  .header__bar { gap: 14px; }
}
/* Ниже этой ширины подпись под логотипом не помещается рядом с меню */
@media (max-width: 1360px) {
  .header .logo__descr { display: none; }
}
.nav a:hover { color: var(--ink); background: rgba(255, 255, 255, .6); }
.nav a[aria-current="true"] { color: var(--ink); background: #fff; box-shadow: 0 1px 2px rgba(44, 38, 35, .1), 0 4px 10px -4px rgba(44, 38, 35, .2); }

.header__actions { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.nav + .header__actions { margin-left: 0; }
.header__tg {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  padding: 0 16px 0 12px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  font-size: 14.5px;
  font-weight: 500;
  transition: border-color .2s, color .2s, background-color .2s;
}
.header__tg .icon { width: 18px; height: 18px; color: var(--accent-text); }
.header__tg:hover { border-color: var(--accent-text); color: var(--accent-text); background: rgba(255, 255, 255, .6); }

.header__cta::after {
  content: "";
  width: 16px;
  height: 16px;
  background: var(--arrow-right) center / contain no-repeat;
  transition: transform .25s var(--ease);
}
.header__cta:hover::after { transform: translateX(3px); }

.burger {
  display: none;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 1px var(--line);
  transition: background-color .2s;
}
.burger:hover { background: var(--bg-soft); }
.burger .icon { width: 22px; height: 22px; }

/* Меню поверх страницы, а не в потоке — контент под шапкой не прыгает */
.mobile-menu { position: absolute; left: 0; right: 0; top: 100%; padding-top: 8px; }
.mobile-menu[hidden] { display: none; }
.mobile-menu__panel {
  display: grid;
  gap: 8px;
  max-height: calc(100dvh - 100px);
  overflow-y: auto;
  padding: 8px;
  border-radius: var(--r-md);
  background: #fff;
  box-shadow: 0 24px 60px -20px rgba(44, 38, 35, .45);
}
.mobile-menu nav { display: grid; }
.mobile-menu nav a { padding: 14px 16px; border-radius: 14px; font-size: 18px; letter-spacing: -.01em; }
.mobile-menu nav a:hover { background: var(--bg-soft); }
.mobile-menu .btn { width: 100%; }

/* =========================================================
   Главный экран
   ========================================================= */
.hero { padding-top: clamp(40px, 4.5vw, 64px); }

.hero__card {
  --hero-pad: clamp(26px, 4vw, 64px);
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  /* Пустые строки сверху и снизу прижимают заголовок и цифры друг к другу и центрируют их напротив высокой правой колонки */
  grid-template-areas:
    ".       portrait"
    "content portrait"
    "stats   portrait"
    ".       portrait";
  grid-template-rows: 1fr auto auto 1fr;
  column-gap: clamp(24px, 4vw, 64px);
  row-gap: 40px;
  min-height: min(740px, calc(100svh - 170px));
  padding: var(--hero-pad);
  border-radius: var(--r-xl);
  background: var(--card);
}

.hero__content { grid-area: content; align-self: center; }
.hero__title { font-size: var(--fs-h1); line-height: .98; letter-spacing: -.045em; }
.hero__line { display: block; }
.hero__line--soft { color: var(--soft-ink); }
.hero__dot { color: var(--accent); }
.hero__lead {
  max-width: 46ch;
  margin-top: clamp(20px, 2vw, 28px);
  font-size: clamp(16px, .95rem + .25vw, 19px);
  color: var(--muted);
}
/* Две главные кнопки одной ширины; когда колонка узкая — встают друг под друга */
.hero__actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr));
  gap: 14px;
  margin-top: clamp(28px, 3vw, 40px);
}
.hero__actions .btn { min-height: 64px; padding: 0 28px; font-size: 18px; }

/* «Примеры работ» — строка-превью с миниатюрами собственных рендеров, как плашка Telegram в контактах */
.hero__works {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 64px;
  padding: 8px 8px 8px 10px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: var(--bg-soft);
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -.01em;
  white-space: nowrap;
  transition: background-color .2s, border-color .2s;
}
.hero__works:hover { background: #fff; border-color: var(--ink); }
.hero__works .round-btn { margin-left: auto; }
.hero__works:hover .round-btn { transform: rotate(45deg); }
.hero__thumbs { display: flex; flex: none; }
.hero__thumbs img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 3px var(--bg-soft);
  transition: box-shadow .2s, translate .35s var(--ease);
}
.hero__thumbs img + img { margin-left: -12px; }
.hero__works:hover .hero__thumbs img { box-shadow: 0 0 0 3px #fff; }
.hero__works:hover .hero__thumbs img:nth-child(2) { translate: 4px 0; }
.hero__works:hover .hero__thumbs img:nth-child(3) { translate: 8px 0; }

.hero__stats {
  grid-area: stats;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px var(--gap);
}
.hero__stats li { display: grid; gap: 4px; padding-top: 16px; border-top: 1px solid var(--line); }
/* Иконка-кружок над цифрой: на hover заливается акцентом, как кнопки-стрелки в блоке */
.hero__stats .icon {
  box-sizing: border-box;
  width: 40px;
  height: 40px;
  margin-bottom: 10px;
  padding: 10px;
  border-radius: 50%;
  background: var(--bg-soft);
  color: var(--accent-text);
  transition: background-color .25s, color .25s, transform .35s var(--ease);
}
.hero__stats li:hover .icon { background: var(--accent); color: #fff; transform: rotate(-8deg) scale(1.06); }
.hero__stats strong {
  font-size: clamp(26px, 1rem + 1.5vw, 42px);
  font-weight: 300;
  line-height: 1.05;
  letter-spacing: -.04em;
  white-space: nowrap;
}
.hero__stats span { font-size: 13.5px; line-height: 1.35; color: var(--muted); }

/* Портрет с фоном в скруглённой рамке; уже и ниже, чем колонка, и стоит по центру карточки.
   Тёмный тёплый фон снимка работает как контрастная плашка кофейного цвета из палитры. */
.hero__side {
  grid-area: portrait;
  align-self: center;
  justify-self: end;
  display: grid;
  gap: 28px; /* больше ширины рамки-ореола вокруг портрета (10px) */
  width: min(100%, 500px);
}
/* Та же жирная линия сверху, что у блока «2 в 1 / Под ключ» слева, — читается как единая редакторская сетка */
.hero__about {
  display: grid;
  gap: 14px;
  padding-top: 22px;
  border-top: 2px solid var(--ink);
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}
.hero__about b { font-weight: 500; color: var(--ink); }
.hero__about-name {
  font-size: clamp(22px, 1rem + .8vw, 30px);
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: -.035em;
  color: var(--ink);
}
.hero__about-goal { padding-left: 16px; border-left: 2px solid var(--accent); color: var(--ink); }
.hero__portrait {
  position: relative;
  aspect-ratio: 4 / 5;
  margin: 0;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--ink);
}
.hero__portrait > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 30%;
}

.glass {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 14px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: "status btn" "text btn";
  align-items: center;
  column-gap: 16px;
  row-gap: 4px;
  padding: 16px 14px 16px 20px;
  border-radius: var(--r-md);
  border: 1px solid rgba(255, 255, 255, .6);
  background: rgba(255, 255, 255, .58);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
  backdrop-filter: blur(18px) saturate(1.3);
  overflow: hidden;
  isolation: isolate;
}
.glass::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  z-index: -1;
  width: 45%;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, .55), transparent);
  translate: -120% 0;
  pointer-events: none;
}
@keyframes glass-sheen {
  0% { translate: -120% 0; }
  22%, 100% { translate: 320% 0; }
}
@keyframes btn-call {
  0% { box-shadow: 0 0 0 0 rgba(224, 122, 46, .55); }
  45%, 100% { box-shadow: 0 0 0 11px rgba(224, 122, 46, 0); }
}
.glass__status { grid-area: status; display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; }
.glass__text { grid-area: text; font-size: 15px; line-height: 1.4; text-wrap: balance; }
.glass .round-btn { grid-area: btn; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #3DA35D; box-shadow: 0 0 0 4px rgba(61, 163, 93, .18); }

.hero__tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: 16px;
}
.tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 18px 0 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .5);
  font-size: 14.5px;
  white-space: nowrap;
  transition: background-color .2s, border-color .2s;
}
.tag .icon { color: var(--accent-text); }
.tag:hover { background: #fff; border-color: transparent; }

@media (prefers-reduced-motion: no-preference) {
  .hero__card { animation: rise .9s var(--ease) both; }
  .hero__portrait { animation: rise 1s .15s var(--ease) both; }
  .glass { animation: rise .8s .7s var(--ease) both; transition: transform .5s var(--ease); }
  .glass:hover { transform: translateY(-3px); }
  /* Блик пробегает по стеклу раз в несколько секунд и ждёт остаток цикла */
  .glass::before { animation: glass-sheen 7s 2.2s ease-in-out infinite; }
  .glass .round-btn { animation: btn-call 3.2s 3s ease-out infinite; }
  .tag { animation: rise .7s var(--ease) both; }
  .tag:nth-child(1) { animation-delay: .5s; }
  .tag:nth-child(2) { animation-delay: .56s; }
  .tag:nth-child(3) { animation-delay: .62s; }
  .tag:nth-child(4) { animation-delay: .68s; }
  .tag:nth-child(5) { animation-delay: .74s; }
  .tag:nth-child(6) { animation-delay: .8s; }
}
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
}

/* =========================================================
   Секции и карточки
   ========================================================= */
.section { padding-block: clamp(72px, 9vw, 136px); }
.hero + .section { padding-top: clamp(80px, 10vw, 150px); }
.section--soft { background: var(--bg-soft); }
/* Следующая секция того же цвета — второй отступ не нужен */
.section--flush-bottom { padding-bottom: 0; }
.nowrap { white-space: nowrap; }

.section-head {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 18px var(--gap);
  margin-bottom: clamp(32px, 4vw, 56px);
}
/* Метка раздела: точка и линия вместо плашки — читается как рубрика, а не как кнопка */
.section-head > .pill {
  grid-column: 1 / -1;
  justify-self: start;
  gap: 12px;
  min-height: 0;
  padding: 0;
  border: 0;
  background: none;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: .02em;
  color: var(--accent-text);
}
.section-head > .pill::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); }
.section-head > .pill::after { content: ""; width: 56px; height: 1px; background: var(--line-strong); }
.section-head h2 { grid-column: 1 / span 9; font-size: var(--fs-h2); font-weight: 560; line-height: 1.1; letter-spacing: -.03em; }
.section-head p { grid-column: 10 / -1; align-self: end; max-width: 44ch; color: var(--muted); }

.card {
  position: relative;
  padding: var(--pad);
  border-radius: var(--r-lg);
  background: var(--card);
}
.card--sand { background: var(--sand); }
.card--dark { background: var(--ink); color: var(--on-dark); }
.card--photo { padding: 0; overflow: hidden; isolation: isolate; }
.card--photo > img { width: 100%; height: 100%; object-fit: cover; }
.card--photo > figcaption.pill { position: absolute; left: 16px; bottom: 16px; }

/* Плашка прижата к правому верхнему углу; длинный заголовок переносится, а не выталкивает её вниз */
.card__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px 14px; margin-bottom: 16px; }
.card__head .pill { flex-shrink: 0; }
.card__head h3 { font-size: var(--fs-h3); }
.card__lead { max-width: 58ch; color: var(--muted); }

.features { display: grid; gap: 14px; margin-top: 24px; }
.features li { position: relative; padding-left: 22px; font-size: 15px; color: var(--muted); }
.features li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .6em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}
.features b { font-weight: 600; color: var(--ink); }

.usage { display: grid; gap: 10px; margin-top: 28px; }
.usage__label { font-size: 13px; color: var(--muted); }

.checks { display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 32px; font-size: 15px; }
.checks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .12em;
  width: 21px;
  height: 21px;
  border-radius: 50%;
  background: var(--accent) var(--check) center / 12px no-repeat;
}

/* ---------- 1.1 Студийная визуализация ---------- */
.studio {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(24px, 4vw, 64px);
  align-items: center;
  margin-bottom: var(--gap);
}
/* Пункты списка: заголовок отдельной строкой, между пунктами тонкая линия */
.features--rows { gap: 0; margin-top: 22px; }
.features--rows li { padding: 14px 0 14px 22px; border-top: 1px solid var(--line); }
.features--rows li::before { top: calc(14px + .6em); }
.features--rows b { display: block; margin-bottom: 2px; font-size: 16px; }

/* Витрина: тёплый «студийный» фон со световым пятном. */
.studio__stage {
  position: relative;
  isolation: isolate;
  align-self: stretch;
  display: grid;
  grid-template-rows: 1fr auto;
  justify-items: center;
  align-items: center;
  gap: 12px;
  padding: clamp(20px, 2.5vw, 32px) clamp(14px, 2vw, 28px) clamp(16px, 2vw, 22px);
  border-radius: var(--r-md);
  background:
    radial-gradient(60% 52% at 50% 42%, #fff, transparent 72%),
    var(--grain),
    linear-gradient(180deg, #F5F3EF, #E7E1D8);
  box-shadow: inset 0 0 0 1px var(--line);
}
/* Все рендеры лежат в одной ячейке, показан выбранный. Светлый фон кадра растворяется в витрине через multiply */
.studio__scene { display: grid; width: 100%; }
.studio__chair {
  grid-area: 1 / 1;
  width: 100%;
  max-height: 520px;
  object-fit: contain;
  mix-blend-mode: multiply;
  /* Серый фон кадра (~235/255) подтягиваем к белому, иначе multiply оставляет заметный прямоугольник */
  filter: brightness(1.1);
  /* Края кадра слегка растушёваны, чтобы серый фон рендера не давал прямоугольник */
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 97%, transparent), linear-gradient(0deg, transparent, #000 7%, #000 93%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 97%, transparent), linear-gradient(0deg, transparent, #000 7%, #000 93%, transparent);
  mask-composite: intersect;
  opacity: 0;
  transition: opacity .5s var(--ease);
}
.studio[data-material="fern"] .studio__chair[data-chair="fern"],
.studio[data-material="willow-dark"] .studio__chair[data-chair="willow-dark"],
.studio[data-material="jungle"] .studio__chair[data-chair="jungle"],
.studio[data-material="willow-light"] .studio__chair[data-chair="willow-light"] { opacity: 1; }

.swatches {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px 18px;
  padding: 8px 12px 8px 20px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .7);
  background: rgba(255, 255, 255, .72);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  box-shadow: 0 14px 30px -22px rgba(44, 38, 35, .5);
}
.swatches__label { font-size: 14px; color: var(--muted); }
.swatches__label b { display: inline-block; min-width: 17ch; color: var(--ink); font-weight: 500; }
.swatches__list { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; padding: 4px; }
.swatch {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, .38), transparent 55%), var(--c);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1);
  transition: box-shadow .25s, transform .25s var(--ease);
}
/* Образец — увеличенный фрагмент ткани с сиденья рендера */
.swatch { position: relative; background: var(--fabric) 52% 58% / 700% no-repeat; }
.swatch::after { content: ""; position: absolute; inset: -5px; }
.swatch[data-swatch="fern"] { --fabric: url("../assets/img/chair-fern.webp"); }
.swatch[data-swatch="willow-dark"] { --fabric: url("../assets/img/chair-willow-dark.webp"); }
.swatch[data-swatch="jungle"] { --fabric: url("../assets/img/chair-jungle.webp"); }
.swatch[data-swatch="willow-light"] { --fabric: url("../assets/img/chair-willow-light.webp"); }
.swatch:hover { transform: scale(1.1); }
.swatch[aria-pressed="true"] { transform: scale(1.06); box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--ink); }

/* ---------- 1.2 Lifestyle ---------- */
.duo {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: var(--gap);
  margin-bottom: var(--gap);
}
/* Карточка берёт пропорции самого кадра, поэтому фото не обрезается; соседняя карточка тянется по высоте */
.lifestyle { aspect-ratio: 960 / 1072; }
.lifestyle > img { position: absolute; inset: 0; z-index: -2; }
/* Тёплый свет в углу песочной карточки; блок «Где применяется» прижат к низу и выравнивает карточку по фото */
.lifestyle__info {
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(520px 380px at 100% 0, rgba(224, 122, 46, .2), transparent 70%),
    var(--grain),
    var(--sand);
}
.lifestyle__info .features { margin-bottom: 28px; }
.lifestyle__info .usage { margin-top: auto; padding-top: 22px; border-top: 1px solid var(--line-strong); }
.lifestyle__styles { position: absolute; top: 18px; left: 18px; right: 84px; display: flex; flex-wrap: wrap; gap: 6px; }
.lifestyle__more { position: absolute; top: 18px; right: 18px; }

/* ---------- 1.3 Коммерция ---------- */
.commercial {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gap);
  margin-bottom: var(--gap);
}
.commercial__text {
  grid-column: 1 / span 5;
  grid-row: 1 / span 2;
  display: flex;
  flex-direction: column;
  background: radial-gradient(520px 380px at 100% 0, rgba(224, 122, 46, .12), transparent 70%), var(--card);
}
.commercial__text .features { margin-bottom: 28px; }
.commercial__text .usage { margin-top: auto; padding-top: 22px; border-top: 1px solid var(--line-strong); }
.commercial__a { grid-column: 6 / span 4; grid-row: 1; min-height: 300px; }
.commercial__b { grid-column: 10 / span 3; grid-row: 1 / span 2; min-height: 300px; }
.commercial__plate { grid-column: 6 / span 4; grid-row: 2; min-height: 250px; }
/* Кадр вытянут вертикально, а карточка широкая: смещаем вниз, чтобы в неё попали стол, книга и чашка */
.commercial__plate > img { position: absolute; inset: 0; object-position: center; }

/* ---------- Почему 3D выгоднее ---------- */
.why {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  gap: var(--pad);
}
.why__intro { display: flex; flex-direction: column; align-items: flex-start; }
.why__title { font-size: var(--fs-h3); max-width: 12ch; }
/* Короткая терракотовая черта под заголовком, как точка и линия у меток разделов */
.why__title::after { content: ""; display: block; width: 48px; height: 3px; margin-top: 20px; border-radius: 3px; background: var(--accent); }
.why__lead { max-width: 24ch; margin-top: 18px; font-size: 15px; color: var(--on-dark-muted); }
/* Контурный куб из знака логотипа прижат к низу колонки и выравнивает её с ячейками */
.why__cube {
  width: clamp(72px, 7vw, 104px);
  margin-top: auto;
  padding-top: 24px;
  box-sizing: content-box;
  fill: none;
  stroke: var(--accent);
  stroke-width: 1;
  stroke-linejoin: round;
  opacity: .55;
}
.why__list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); counter-reset: why; }
/* Каждый довод в своей «стеклянной» ячейке: на тёмном фоне читается как отдельный аргумент, а не колонка текста */
.why__list li {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: grid;
  align-content: start;
  gap: 8px;
  padding: clamp(20px, 2vw, 28px);
  border: 1px solid rgba(245, 243, 239, .1);
  border-radius: var(--r-md);
  background: linear-gradient(165deg, rgba(245, 243, 239, .08), rgba(245, 243, 239, .02));
  box-shadow: inset 0 1px 0 rgba(245, 243, 239, .08);
  counter-increment: why;
  transition: border-color .4s, transform .5s var(--ease);
}
.why__list li::before {
  content: counter(why, decimal-leading-zero);
  margin-bottom: 22px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .12em;
  color: var(--accent-on-dark);
}
/* Тёплое свечение из угла ячейки при наведении */
.why__list li::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: radial-gradient(320px 220px at 0 0, rgba(224, 122, 46, .24), transparent 70%);
  opacity: 0;
  transition: opacity .5s;
}
@media (hover: hover) {
  .why__list li:hover { border-color: rgba(224, 122, 46, .5); transform: translateY(-4px); }
  .why__list li:hover::after { opacity: 1; }
}
.why__big {
  margin-bottom: 14px;
  font-size: clamp(40px, 1rem + 3vw, 64px);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -.055em;
  color: var(--accent);
}
.why__list b { font-weight: 500; font-size: 17px; }
.why__list p { font-size: 15px; color: var(--on-dark-muted); }

/* =========================================================
   Направление 2: упаковка
   ========================================================= */
.pack {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(24px, 4vw, 64px);
  align-items: center;
}
.pack__list { display: grid; gap: 8px; counter-reset: pack; }
.pack__item {
  counter-increment: pack;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  transition: background-color .3s, border-color .3s, box-shadow .4s;
}
.pack__item:has([aria-expanded="true"]) { background: #fff; border-color: transparent; box-shadow: 0 28px 50px -34px rgba(44, 38, 35, .5); }
.pack__trigger {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  padding: 20px 68px 20px 22px;
  text-align: left;
  border-radius: var(--r-md);
}
/* Круглый индикатор «плюс / минус»: без него не видно, что пункты раскрываются */
.pack__trigger::after {
  content: "";
  position: absolute;
  top: 18px;
  right: 18px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background:
    linear-gradient(var(--ink), var(--ink)) center / 12px 1.5px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 1.5px 12px no-repeat;
  transition: background-color .3s, border-color .3s, background-size .3s var(--ease);
}
.pack__trigger[aria-expanded="true"]::after { background-color: var(--accent); border-color: var(--accent); background-size: 12px 1.5px, 1.5px 0; }
.pack__trigger:hover::after { border-color: var(--ink); }
.pack__title { font-size: clamp(18px, .9rem + .5vw, 22px); font-weight: 600; line-height: 1.2; letter-spacing: -.02em; }
.pack__title::before {
  content: counter(pack, decimal-leading-zero);
  display: block;
  margin-bottom: 6px;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .12em;
  color: var(--accent-text);
}
.pack__trigger[aria-expanded="false"] .pack__title { color: var(--muted); }
.pack__trigger:hover .pack__title { color: var(--ink); }
.pack__panel {
  display: grid;
  grid-template-rows: 0fr;
  visibility: hidden;
  transition: grid-template-rows .45s var(--ease), visibility .45s;
}
.pack__panel > * { min-height: 0; overflow: hidden; }
[aria-expanded="true"] + .pack__panel { grid-template-rows: 1fr; visibility: visible; }
.pack__panel .checks { padding: 0 22px 24px; }

/* Плашки формата: мягкая терракотовая заливка вместо фото-текстуры, чтобы не спорить с фотографиями на странице */
.format-tag {
  flex: none;
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 4px 13px;
  border-radius: 999px;
  border: 1px solid rgba(224, 122, 46, .32);
  background: rgba(224, 122, 46, .12);
  color: var(--accent-text-tint);
  font-size: 12.5px;
  font-weight: 500;
  white-space: nowrap;
}

.pack__showcase {
  position: sticky;
  top: calc(var(--header-h) + 20px);
  display: grid;
  aspect-ratio: 4 / 3;
  border-radius: var(--r-lg);
  overflow: hidden;
  background:
    radial-gradient(60% 55% at 50% 45%, rgba(255, 255, 255, .7), transparent 75%),
    radial-gradient(520px 380px at 100% 0, rgba(224, 122, 46, .16), transparent 70%),
    var(--grain),
    var(--sand);
  box-shadow: inset 0 0 0 1px var(--line);
  container-type: size;
  --show-pad: clamp(18px, 4vw, 56px);
}
.show {
  grid-area: 1 / 1;
  display: grid;
  place-items: center;
  min-width: 0;
  padding: var(--show-pad);
  opacity: 0;
  visibility: hidden;
  transform: scale(.97);
  transition: opacity .45s, visibility .45s, transform .7s var(--ease);
}
.show.is-active { opacity: 1; visibility: visible; transform: none; }
/* Макет вписывается и по ширине, и по высоте витрины: разворот 3:2, окно браузера ≈ 16:10 + шапка */
.show .book { width: min(100%, (100cqh - 2 * var(--show-pad)) * 1.5); }
.show .browser { width: min(100%, (100cqh - 2 * var(--show-pad) - 30px) * 1.6); }


/* =========================================================
   Макеты: разворот каталога / КП
   ========================================================= */
.book { display: block; width: 100%; container-type: inline-size; }
.spread {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  aspect-ratio: 3 / 2;
  border-radius: 6px;
  overflow: hidden;
  background: #fbfaf8;
  box-shadow: var(--shadow-float);
  color: var(--ink);
  text-align: left;
}
/* Сгиб посередине разворота */
.spread::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 50%;
  width: 14%;
  translate: -50% 0;
  background: linear-gradient(90deg, transparent, rgba(44, 38, 35, .1) 44%, rgba(44, 38, 35, .22) 50%, rgba(44, 38, 35, .06) 53%, transparent);
  pointer-events: none;
}
.page {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 1.4cqi;
  min-width: 0;
  padding: 5cqi 4.4cqi 4.4cqi;
  overflow: hidden;
  font-size: 1.45cqi;
  line-height: 1.4;
}
.page > * { display: block; }
.page--bleed { padding: 0; }
.page--bleed > img { width: 100%; height: 100%; object-fit: cover; }
.page--cover { justify-content: space-between; background: var(--sand); }
.page--kp { background: var(--ink); color: var(--on-dark); }
.page--kp .page__kicker { color: var(--accent); }
.page--back { justify-content: center; align-items: center; background: var(--ink); color: var(--on-dark); }
.page--kp-back { align-items: flex-start; gap: 3cqi; padding-inline: 5cqi; }
.page__brand { font-size: 2cqi; font-weight: 700; letter-spacing: .32em; }
.page__cover-title { font-size: 4.6cqi; font-weight: 600; line-height: 1; letter-spacing: -.04em; }
.page__small { font-size: 1.3cqi; opacity: .7; }
.page__kicker { font-size: 1.25cqi; font-weight: 500; color: var(--accent-text); }
.page__title { font-size: 3cqi; font-weight: 600; line-height: 1.05; letter-spacing: -.03em; }
.page__text { color: var(--muted); }
.page__product { flex: 1; min-height: 0; width: 100%; object-fit: contain; mix-blend-mode: multiply; }
.page__specs { display: flex !important; flex-wrap: wrap; gap: .8cqi; }
.page__specs span { padding: .4cqi 1.2cqi; border: 1px solid var(--line); border-radius: 99px; font-size: 1.15cqi; }
.page__swatches { display: flex !important; gap: .8cqi; }
.page__swatches i { width: 3cqi; height: 3cqi; border-radius: 50%; background: var(--c); }
.page__num { position: absolute; right: 4cqi; bottom: 3cqi; font-size: 1.15cqi; color: var(--muted); }
.page__caption {
  position: absolute;
  left: 3cqi;
  bottom: 3cqi;
  padding: .5cqi 1.3cqi;
  border-radius: 99px;
  background: rgba(255, 255, 255, .85);
  font-size: 1.15cqi;
}
.page__table { display: grid !important; margin-top: 1cqi; }
.page__table > span { display: flex; justify-content: space-between; gap: 1cqi; padding: 1.1cqi 0; border-bottom: 1px solid var(--line); font-size: 1.35cqi; }
.page__table i { font-style: normal; color: var(--muted); white-space: nowrap; }
.page__table b { font-weight: 500; }
.page__table .page__total { border-bottom: 0; }
.page__table .page__total b, .page__table .page__total i { font-weight: 600; color: var(--ink); }
.page--back .page__title { font-size: 3.6cqi; }
.page__cta { padding: 1cqi 2.4cqi; border-radius: 99px; background: var(--accent); color: var(--ink); font-size: 1.45cqi; font-weight: 500; }
/* =========================================================
   Каталоги (.ed): редакционная вёрстка — тёплая бумага,
   шоколадные плашки, тонкие заглавные заголовки
   ========================================================= */
.ed {
  --paper: #F4F1EC;
  --choc: #4B3D35;
  --ed-ink: #3B302A;
  --ed-muted: #7C7067;
  --ed-line: rgba(59, 48, 42, .16);
  gap: 0;
  padding: 4.6cqi 4cqi 5.4cqi;
  background: var(--paper);
  color: var(--ed-ink);
  font-size: 1.05cqi;
  line-height: 1.55;
}
/* Вёрстка целиком на span, поэтому по умолчанию все они блочные; :where не перебивает классы ниже */
:where(.ed) span { display: block; }
.ed img { display: block; width: 100%; min-height: 0; object-fit: cover; }
.ed b { font-weight: 500; }
.ed i { font-style: normal; }

.ed__brand { padding-left: .42em; text-align: center; font-size: 1.15cqi; font-weight: 500; line-height: 1.2; letter-spacing: .42em; text-transform: uppercase; }
.ed__brand small { display: block; margin-top: .6cqi; font-size: .7cqi; font-weight: 400; letter-spacing: .3em; opacity: .7; }
.ed__display { font-size: 4.4cqi; font-weight: 300; line-height: 1.04; letter-spacing: .01em; text-transform: uppercase; color: var(--choc); }
.ed__title { font-size: 2.3cqi; font-weight: 300; line-height: 1.12; letter-spacing: .02em; text-transform: uppercase; color: var(--choc); }
.ed__quote { font-size: 2.6cqi; font-weight: 300; line-height: 1.12; letter-spacing: .02em; text-transform: uppercase; }
.ed__lead { font-size: 1.2cqi; font-weight: 300; color: var(--ed-muted); }
.ed__num { font-size: 3cqi; font-weight: 300; line-height: 1; color: var(--choc); }
.ed__name { font-size: 1.05cqi; font-weight: 500; line-height: 1.3; letter-spacing: .12em; text-transform: uppercase; }
.ed__text { color: var(--ed-muted); }
.ed__rows > span { display: flex; justify-content: space-between; align-items: center; gap: 1cqi; padding: .55cqi 0; border-top: 1px solid var(--ed-line); font-size: .92cqi; }
.ed__rows > span > i { color: var(--ed-muted); }
.ed__dots { display: inline-flex; align-items: center; gap: .6cqi; }
.ed__dots i { width: 1.2cqi; height: 1.2cqi; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(59, 48, 42, .28); }
/* Колонтитул: название каталога слева, номер страницы справа */
.ed__folio { position: absolute; left: 4cqi; right: 4cqi; bottom: 2.2cqi; display: flex; justify-content: space-between; font-size: .7cqi; letter-spacing: .24em; text-transform: uppercase; color: var(--ed-muted); }

/* Обложка: марка, крупное название, снизу рендер в край */
.ed--cover { align-items: center; padding-top: 3.6cqi; padding-bottom: 3.6cqi; text-align: center; }
.ed--cover .ed__display { margin-top: 3.4cqi; }
.ed--cover .ed__lead { margin-top: 1.2cqi; }
/* Рендеры вертикальные 3:4: показываем кадр целиком, иначе в широкой полосе режется низ мебели */
.ed--cover img { flex: 1; align-self: center; width: auto; max-width: 100%; aspect-ratio: 3 / 4; margin-top: 3cqi; }

/* Шоколадные страницы: рендер в рамке, сверху плашка с названием */
.ed--frame, .ed--dark { padding: 1.8cqi 1.8cqi 2.2cqi; background: var(--choc); color: var(--paper); }
.ed__bar { display: flex; justify-content: space-between; padding: .6cqi .6cqi 1.8cqi; font-size: .78cqi; font-weight: 500; letter-spacing: .4em; text-transform: uppercase; }
.ed--frame img { flex: 1; }
.ed__stage { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; }
.ed__stage img { flex: 1; }
/* Затемнение сверху, чтобы светлый заголовок читался на любом рендере */
.ed__stage::before { content: ""; position: absolute; inset: 0 0 auto; height: 42%; background: linear-gradient(rgba(38, 29, 24, .55), transparent); pointer-events: none; }
.ed__over { position: absolute; top: 3cqi; left: 3cqi; right: 3cqi; display: grid; gap: 1cqi; color: #fff; }
.ed__over .ed__num { color: inherit; }
/* Карточка под фото, а не поверх: иначе она закрывает низ мебели */
.ed__card { display: grid; grid-template-columns: 1.3fr 1fr; gap: 2.4cqi; align-items: center; padding: 1.6cqi 2cqi; background: var(--paper); color: var(--ed-ink); }

/* Оглавление: три вертикальных рендера с номерами страниц и список */
.ed--strips { flex-direction: row; gap: 1.2cqi; padding: 4.6cqi 0 0 4cqi; }
.ed__strip { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.ed__strip b { font-size: 3cqi; font-weight: 300; line-height: 1; color: var(--choc); }
.ed__strip span { min-height: 2.6em; margin: .9cqi 0 2.2cqi; font-size: .82cqi; font-weight: 500; line-height: 1.3; letter-spacing: .12em; text-transform: uppercase; }
.ed__strip img { flex: 1; }
.ed--toc { padding-inline: 5cqi; }
.ed--toc .ed__title { margin: 1.6cqi 0 4cqi; text-align: center; }
.ed__toc > span { display: flex; justify-content: space-between; gap: 1cqi; padding: 1.05cqi 0; border-bottom: 1px solid var(--ed-line); }
.ed__toc i { color: var(--ed-muted); font-variant-numeric: tabular-nums; }
.ed__note { margin-top: auto; max-width: 80%; }

/* Товар: рендер (или два) сверху, под ним номер, название и характеристики в две колонки */
.ed__pics { flex: 0 0 66%; min-height: 0; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 1.2cqi; margin-bottom: 2.8cqi; }
.ed__pics img { height: 100%; }
.ed--product .ed__info { display: grid; grid-template-columns: 1fr 1.35fr; gap: 3cqi; }
.ed__head { display: grid; gap: 1cqi; align-content: start; }
.ed__body { display: grid; gap: 1.4cqi; align-content: start; }

/* Два товара на странице: рендер слева, описание справа */
.ed--pair { gap: 2.6cqi; }
.ed__item { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 2.4cqi; }
.ed__item + .ed__item { padding-top: 2.6cqi; border-top: 1px solid var(--ed-line); }
.ed__item img { height: 100%; }
.ed__item .ed__info { display: grid; gap: 1cqi; align-content: center; }

/* Вся коллекция: сетка 3 × 2 */
.ed--grid .ed__text { max-width: 80%; margin: 1.2cqi 0 2.8cqi; }
.ed__tiles { flex: 1; min-height: 0; display: grid; grid-template: 1fr 1fr / repeat(3, 1fr); gap: 2.2cqi 1.4cqi; }
.ed__tiles > span { min-height: 0; display: flex; flex-direction: column; gap: .5cqi; }
.ed__tiles img { flex: 1; margin-bottom: .4cqi; object-position: 50% 80%; }
.ed__tiles b { font-size: .8cqi; line-height: 1.3; letter-spacing: .1em; text-transform: uppercase; }
.ed__tiles i { font-size: .8cqi; color: var(--ed-muted); }

/* Лукбук: короткая подпись и четыре ракурса */
.ed__top { display: grid; gap: .8cqi; margin-bottom: 2.6cqi; }
.ed__quad { flex: 1; min-height: 0; display: grid; grid-template: 1fr 1fr / 1fr 1fr; gap: 1.2cqi; }
.ed__quad img { height: 100%; }

/* Финал: как заказать, задняя обложка с шоколадной полосой */
.ed--about .ed__text { margin: 1cqi 0 1.8cqi; }
.ed__steps > span { display: flex; gap: 1.6cqi; padding: .9cqi 0; border-top: 1px solid var(--ed-line); }
.ed__steps b { color: var(--choc); font-variant-numeric: tabular-nums; }
.ed--about img { flex: 1; margin-top: 2cqi; }
.ed--back { flex-direction: row; padding: 0; }
.ed--back img { flex: 1; min-width: 0; height: 100%; }
.ed__band { flex: 0 0 38%; display: flex; flex-direction: column; justify-content: space-between; padding: 4.6cqi 2.4cqi 4cqi; background: var(--choc); color: var(--paper); }
.ed__band .ed__brand { padding-left: 0; text-align: left; }
.ed__contacts { display: grid; gap: 1.8cqi; font-size: .85cqi; line-height: 1.45; }
.ed__contacts > span { color: rgba(244, 241, 236, .75); }
.ed__contacts b { display: block; margin-bottom: .3cqi; color: var(--paper); font-size: .8cqi; letter-spacing: .14em; text-transform: uppercase; }

/* =========================================================
   Каталог кроватей (.bd): светлый серый лист, заголовки с засечками,
   терракотовые акценты и точечные сетки
   ========================================================= */
.bd {
  --b-paper: #EEEDEB;
  --b-ink: #2B2826;
  --b-muted: #6B655F;
  --b-accent: #B5835A;
  /* Терракота темнее для мелкого текста: светлая на сером не проходит по контрасту */
  --b-accent-text: #8E5F38;
  --b-line: rgba(43, 40, 38, .14);
  --b-serif: "Cormorant Garamond", Georgia, serif;
  gap: 0;
  padding: 4.4cqi 4cqi 5.4cqi;
  background: var(--b-paper);
  color: var(--b-ink);
  font-size: 1cqi;
  line-height: 1.5;
}
:where(.bd) span { display: block; }
.bd img { display: block; width: 100%; min-height: 0; object-fit: cover; background: #c2c2c2; }
.bd b { font-weight: 600; }
.bd i { font-style: normal; }
.bd__title { font-family: var(--b-serif); font-size: 3cqi; font-weight: 600; line-height: 1.05; }
.bd__text { color: var(--b-muted); }
.bd__dots { flex: none; width: 4.6cqi; height: 2.6cqi; background: radial-gradient(circle, var(--b-ink) .2cqi, transparent .24cqi) 0 0 / .92cqi .92cqi; opacity: .7; }
.bd__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 2cqi; margin-bottom: 2.6cqi; }
.bd__sub { font-family: var(--b-serif); font-size: 1.7cqi; font-weight: 600; line-height: 1.15; margin-bottom: .8cqi; }
.bd__folio { position: absolute; left: 4cqi; right: 4cqi; bottom: 2.2cqi; display: flex; justify-content: space-between; font-size: .72cqi; letter-spacing: .2em; text-transform: uppercase; color: var(--b-muted); }
/* Подвал обложек: подпись и тонкая линия до края */
.bd__foot { display: flex; align-items: center; gap: 2cqi; font-size: .8cqi; font-weight: 500; letter-spacing: .22em; text-transform: uppercase; }
.bd__foot::after { content: ""; flex: 1; height: 1px; background: var(--b-ink); opacity: .6; }

/* Обложка */
.bd--cover { padding: 5cqi 4.4cqi 3.6cqi; }
.bd__lines { position: absolute; top: 5.8cqi; right: 4.4cqi; width: 7cqi; height: 2.1cqi; background: repeating-linear-gradient(var(--b-accent) 0 .2cqi, transparent .2cqi .95cqi); }
.bd__brand { font-family: var(--b-serif); font-size: 6cqi; font-weight: 600; line-height: .9; letter-spacing: .08em; text-transform: uppercase; color: var(--b-accent); }
.bd__kicker { margin-top: 1.4cqi; font-size: 1.05cqi; font-weight: 500; letter-spacing: .18em; text-transform: uppercase; }
.bd__year { display: flex; align-items: center; justify-content: space-between; margin-top: 3.4cqi; font-family: var(--b-serif); font-size: 4.4cqi; font-weight: 500; line-height: 1; letter-spacing: .14em; }
.bd__no { margin-top: 2.4cqi; font-size: 1.05cqi; font-weight: 500; letter-spacing: .1em; }
/* Вертикальная метка с точками на концах, как в референсе */
.bd__rule { position: absolute; left: 5cqi; top: 43%; width: 1px; height: 8cqi; background: var(--b-accent); }
.bd__rule::before, .bd__rule::after { content: ""; position: absolute; left: -.3cqi; width: .6cqi; height: .6cqi; border-radius: 50%; background: var(--b-accent); }
.bd__rule::before { top: 0; }
.bd__rule::after { bottom: 0; }
.bd__specs { position: absolute; left: 4.4cqi; bottom: 9.6cqi; display: grid; gap: .5cqi; font-size: .82cqi; }
.bd__specs i { display: inline-block; min-width: 2.4cqi; font-weight: 600; }
.bd__code { width: 7cqi; height: 1.8cqi; margin-top: 1.2cqi; background: repeating-linear-gradient(90deg, var(--b-ink) 0 .14cqi, transparent .14cqi .34cqi, var(--b-ink) .34cqi .42cqi, transparent .42cqi .78cqi); }
/* Рендер с терракотовым уголком за ним */
.bd__hero { position: relative; align-self: flex-end; width: 64%; margin: 2.4cqi 2.6cqi 0 0; aspect-ratio: 4 / 3.6; }
.bd__hero::before { content: ""; position: absolute; right: -2.6cqi; bottom: -2.6cqi; width: 58%; height: 82%; border: solid var(--b-accent); border-width: 0 2.6cqi 2.6cqi 0; }
.bd__hero img { position: relative; height: 100%; }
.bd--cover .bd__foot { margin-top: auto; }

/* Содержание */
.bd__toc { display: grid; grid-template-columns: 1fr 1fr; gap: 2.2cqi 3cqi; }
.bd__entry { display: grid; grid-template-columns: auto 1fr; column-gap: 1.2cqi; align-content: start; }
.bd__entry i { grid-row: span 2; font-family: var(--b-serif); font-size: 2cqi; font-weight: 600; line-height: 1; color: var(--b-accent-text); }
.bd__entry b { font-size: 1.05cqi; line-height: 1.3; }
.bd__entry span { font-size: .82cqi; color: var(--b-muted); }
.bd--toc > img { flex: 1; margin-top: 3.4cqi; }

/* Приветствие: рендер в край сверху, номер раздела и текст в две колонки */
.bd--welcome { padding-top: 0; }
.bd--welcome > img { flex: 0 0 48%; width: calc(100% + 8cqi); max-width: none; margin: 0 -4cqi 3cqi; }
.bd__num { font-family: var(--b-serif); font-size: 3.2cqi; font-weight: 600; line-height: 1; color: var(--b-accent); }
.bd__cols { display: grid; grid-template-columns: 1fr 1fr; gap: 2.4cqi 3cqi; }


/* Карточки моделей: рендер 4:3, полоска цветов обивки, название, описание, номер */
.bd__cards { flex: 1; min-height: 0; display: grid; grid-template: 1fr 1fr / 1fr 1fr; gap: 2.4cqi 2.2cqi; }
.bd__card { display: flex; flex-direction: column; gap: .4cqi; min-height: 0; }
.bd__shot { display: flex; gap: .5cqi; margin-bottom: .8cqi; }
.bd__shot img { flex: 1; min-width: 0; aspect-ratio: 4 / 3; }
.bd__tones { display: flex; flex-direction: column; width: 1.2cqi; }
.bd__tones i { flex: 1; background: var(--c); }
.bd__card b, .bd__row b { font-size: 1.1cqi; line-height: 1.3; }
.bd__desc { font-size: .85cqi; line-height: 1.4; color: var(--b-muted); }
.bd__id { margin-top: .3cqi; font-size: .85cqi; font-weight: 600; color: var(--b-accent-text); }

/* Особые формы: три строки «рендер слева, описание справа» */
.bd__row { flex: 1; min-height: 0; display: grid; grid-template-columns: 1.2fr 1fr; gap: 2.4cqi; align-items: center; border-top: 1px solid var(--b-line); }
.bd__row .bd__shot { margin: 0; }
.bd__row > span:last-child { display: grid; gap: .5cqi; }

/* Как выбрать и заказ */
.bd--about > img, .bd--guide > img, .bd--order > img { flex: 1; margin-top: 3cqi; }
.bd__steps { margin-top: 2.4cqi; }
.bd__steps > span { display: flex; gap: 1.6cqi; padding: 1cqi 0; border-top: 1px solid var(--b-line); }
.bd__steps i { font-weight: 600; color: var(--b-accent-text); }

/* Задняя обложка: небольшой кадр и благодарность по центру */
.bd--back { align-items: center; padding: 6cqi 4.4cqi 3.6cqi; text-align: center; }
.bd--back > img { width: 58%; aspect-ratio: 4 / 3; }
.bd--back .bd__title { margin-top: 4cqi; font-size: 2.6cqi; }
.bd__notes { display: grid; gap: .7cqi; margin-top: 2.6cqi; font-size: .9cqi; color: var(--b-muted); }
.bd--back .bd__foot { align-self: stretch; margin-top: auto; }

/* =========================================================
   Макет: сайт в окне браузера
   ========================================================= */
.browser {
  display: block;
  width: 100%;
  border-radius: 12px;
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow-float), 0 0 0 1px rgba(44, 38, 35, .06);
  text-align: left;
}
.browser__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 30px;
  padding: 0 12px;
  background: #F1EEE9;
  border-bottom: 1px solid var(--line);
}
.browser__bar i { width: 9px; height: 9px; border-radius: 50%; background: #D9D2C8; }
.browser__url {
  flex: 0 1 220px;
  margin-left: 10px;
  padding: 2px 12px;
  border-radius: 99px;
  background: #fff;
  font-size: 11px;
  color: var(--muted);
}
.browser__viewport {
  display: block;
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  container-type: size;
}

/* Скриншот сайта внутри макета: листается transform-ом, в окне просмотра заменяется живым iframe */
.ms { display: block; width: 100%; height: auto; background: #FAF8F5; transition: transform 1.2s var(--ease); }
.browser__viewport > iframe { display: block; width: 100%; height: 100%; border: 0; }

@media (prefers-reduced-motion: no-preference) {
  .browser--auto .ms { animation: site-scroll 28s ease-in-out infinite alternate; }
}
@keyframes site-scroll {
  0%, 8% { transform: translateY(0); }
  92%, 100% { transform: translateY(calc(-100% + 100cqh)); }
}

/* =========================================================
   Синергия
   ========================================================= */
.synergy { display: grid; gap: clamp(32px, 4vw, 56px); padding: clamp(28px, 4.6vw, 72px); }
.synergy__head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 18px var(--gap); align-items: end; }
.synergy__head h2 { font-size: var(--fs-h2); }
.synergy__head p { color: var(--on-dark-muted); max-width: 42ch; }

.chain { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.chain__step {
  position: relative;
  display: grid;
  align-content: start;
  gap: 14px;
  padding: 14px 14px 18px;
  border-radius: var(--r-md);
  isolation: isolate;
  border: 1px solid rgba(245, 243, 239, .1);
  background: linear-gradient(165deg, rgba(245, 243, 239, .08), rgba(245, 243, 239, .02));
  box-shadow: inset 0 1px 0 rgba(245, 243, 239, .08);
  transition: border-color .4s, transform .5s var(--ease);
}
/* Стрелка выступает за край ячейки, поэтому каждая ячейка лежит выше следующей */
.chain__step:nth-child(1) { z-index: 3; }
.chain__step:nth-child(2) { z-index: 2; }
.chain__step:nth-child(3) { z-index: 1; }
/* Конечный результат цепочки выделен терракотовой рамкой */
.chain__step:last-child { border-color: rgba(224, 122, 46, .5); }
/* Тёплое свечение из угла при наведении, как у ячеек в «Почему 3D выгоднее» */
.chain__step::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: radial-gradient(300px 200px at 0 0, rgba(224, 122, 46, .22), transparent 70%);
  opacity: 0;
  transition: opacity .5s;
}
@media (hover: hover) {
  .chain__step:hover { border-color: rgba(224, 122, 46, .5); transform: translateY(-4px); }
  .chain__step:hover::before { opacity: 1; }
}
.chain__step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 38%;
  right: calc(var(--gap) / -2);
  z-index: 1;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  translate: 50% -50%;
  background: var(--accent) var(--arrow-right) center / 15px no-repeat;
  box-shadow: 0 0 0 5px var(--ink);
}
.chain__num {
  justify-self: start;
  padding: 2px 10px;
  border-radius: 999px;
  border: 1px solid rgba(235, 138, 64, .45);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  letter-spacing: .06em;
  color: var(--accent-on-dark);
}
.chain__visual {
  display: grid;
  place-items: center;
  aspect-ratio: 12 / 8;
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-soft);
  color: var(--ink);
}
.chain__visual > img { width: 100%; height: 100%; object-fit: cover; }
.chain__visual--sketch svg { width: 74%; }
.chain__visual .book--tiny { width: 84%; }
.chain__visual .browser--tiny { width: 84%; translate: 0 18%; border-radius: 8px; }
.browser--tiny .browser__bar { height: 12px; padding: 0 6px; gap: 3px; }
.browser--tiny .browser__bar i { width: 4px; height: 4px; }
.browser--tiny .browser__url { display: none !important; }
.chain__step b { font-size: 16px; font-weight: 500; line-height: 1.3; }

.benefits {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--pad);
  padding-top: clamp(28px, 3vw, 40px);
  border-top: 1px solid rgba(245, 243, 239, .14);
}
.benefits li::before { content: ""; display: block; width: 32px; height: 3px; margin-bottom: 18px; border-radius: 3px; background: var(--accent); }
.benefits h3 { margin-bottom: 10px; font-size: 20px; letter-spacing: -.02em; }
.benefits p { font-size: 15px; color: var(--on-dark-muted); }

/* =========================================================
   Портфолио
   ========================================================= */
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
/* Точка есть у каждого фильтра, у выбранного она загорается: ширина кнопок не меняется, лента не прыгает */
.pill--btn {
  min-height: 44px;
  padding: 0 18px 0 15px;
  font-size: 14.5px;
  background: transparent;
  border-color: var(--line-strong);
}
.pill--btn::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .25; transition: opacity .2s, scale .3s var(--ease); }
.pill--btn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--on-dark); box-shadow: 0 14px 26px -16px rgba(44, 38, 35, .7); }
.pill--btn[aria-pressed="true"]::before { background: var(--accent); opacity: 1; scale: 1.15; }

.works {
  --media-h: clamp(250px, 26vw, 400px);
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(20px, 2vw, 28px) var(--gap);
  grid-auto-flow: dense;
}
.work { --title-fs: 17px; grid-column: span 4; display: grid; align-content: start; gap: 12px; min-width: 0; }
.work--half { grid-column: span 6; }
.work[hidden] { display: none; }
.work.is-entering { animation: rise .5s var(--ease) both; }

/* Якорь и хвост сетки. Считаем только видимые карточки (:nth-child(… of …)), поэтому раскладка
   подстраивается под любой фильтр без JS. «Трети» — обычные карточки, «половины» — сайты */
@media (min-width: 1101px) {
  /* В фильтре одних сайтов они встают как обычные карточки, иначе рядом с якорем не поместятся */
  .works:not(:has(> :not([hidden], .work--half))) > .work--half { grid-column: span 4; }
  /* Первая видимая работа — якорь на 8 колонок и две строки, рядом две работы столбиком */
  .work:nth-child(1 of :not([hidden])) {
    --title-fs: var(--fs-h3);
    /* Высоту якоря задают соседние строки; contain: size не даёт снимку раздуть их своим размером */
    --media-h: 100%;
    --media-contain: size;
    --media-r: var(--r-lg);
    grid-column: span 8;
    grid-row: span 2;
    grid-template-rows: minmax(0, 1fr) auto;
  }
  /* Якорь занимает ячейки целого ряда плюс одну, поэтому остаток зависит только от числа «третей»:
     лишняя одна — последние четыре встают по две в ряд, лишние две — последние две.
     Если якорь сам попал в хвост (в фильтре две работы), он снова обычная карточка, со своей высотой снимка */
  .works:has(> :nth-last-child(1 of :not([hidden], .work--half)):nth-child(3n + 2 of :not([hidden], .work--half))) > :nth-last-child(-n + 2 of :not([hidden], .work--half)),
  .works:has(> :nth-last-child(1 of :not([hidden], .work--half)):nth-child(3n + 1 of :not([hidden], .work--half))) > :nth-last-child(-n + 4 of :not([hidden], .work--half)) {
    --title-fs: 17px;
    --media-h: inherit;
    --media-contain: initial;
    --media-r: initial;
    grid-column: span 6;
    grid-row: auto;
    grid-template-rows: none;
  }
}
@media (min-width: 721px) and (max-width: 1100px) {
  /* Две колонки: якорь во всю ширину, а при чётном числе работ во всю ширину встаёт и последняя */
  .works { --wide-h: clamp(320px, 56vw, 520px); }
  .work:nth-child(1 of :not([hidden])) { --title-fs: var(--fs-h3); }
  .work:nth-child(1 of :not([hidden])),
  .works:has(> :nth-last-child(1 of :not([hidden])):nth-child(even of :not([hidden]))) > :nth-last-child(1 of :not([hidden])) {
    --media-h: var(--wide-h);
    grid-column: 1 / -1;
  }
}

.work__media {
  position: relative;
  display: block;
  width: 100%;
  height: var(--media-h);
  contain: var(--media-contain);
  border-radius: var(--media-r, var(--r-md));
  overflow: hidden;
  background: var(--sand);
  box-shadow: 0 26px 44px -34px rgba(44, 38, 35, .55);
}
.work__media > img { width: 100%; height: 100%; object-fit: cover; }
@media (prefers-reduced-motion: no-preference) {
  .work__media { transition: transform .5s var(--ease); }
  .work__media > img { transition: transform .9s var(--ease); }
}
/* Наведение только там, где оно есть: на тач-экранах после тапа ничего не «залипает» */
@media (hover: hover) {
  .pill--btn:not([aria-pressed="true"]):hover { border-color: var(--ink); background: rgba(255, 255, 255, .6); }
  .pill--btn:not([aria-pressed="true"]):hover::before { opacity: .6; }
  .work__media[data-open="image"]:hover::after { opacity: 1; scale: 1; }
  .work:has(> .work__media:hover) .work__meta h3 { color: var(--accent-text); }
  .work:has(> .work__media:hover) .work__meta h3::after { transform: scaleX(1); }
  /* Скролл-превью сайта при наведении */
  .work__media--site:hover .ms { transform: translateY(calc(-100% + 100cqh)); transition: transform 24s linear; }
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .work__media:hover { transform: translateY(-4px); }
  .work__media:hover > img { transform: scale(1.04); }
  .work__media--book:hover { transform: none; }
  .work__media--book:hover .spread { transform: translateY(-4px); }
}
/* Кнопка «открыть» появляется на фото при наведении и подсказывает, что снимок раскрывается */
.work__media[data-open="image"]::after {
  content: "";
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--accent) var(--arrow-right) center / 18px no-repeat;
  rotate: -45deg;
  opacity: 0;
  scale: .8;
  transition: opacity .3s, scale .4s var(--ease);
}
.work__media[data-open="image"]:focus-visible::after { opacity: 1; scale: 1; }
/* Журнал лежит прямо на странице, без карточки: ни фона, ни рамки, а разворот почти во всю ширину ячейки */
.work .work__media--book { display: grid; place-items: center; height: auto; contain: none; aspect-ratio: auto; padding: 0 2% 8px; overflow: visible; background: none; box-shadow: none; }
.work .work__media--book::before { content: none; }
.work__media--book .spread { transition: transform .5s var(--ease); }
.work__hint { position: absolute; right: 12px; bottom: 12px; }
.work__media--site { padding: 7% 7% 0; background: var(--grain), var(--sand); }
/* Окно браузера заполняет ячейку по высоте: в крупной ячейке под ним не остаётся пустого песка */
.work__media--site .browser { display: flex; flex-direction: column; height: 100%; border-radius: 12px 12px 0 0; }
.work__media--site .browser__viewport { flex: 1; aspect-ratio: auto; }
.work__media--site:focus-visible .ms { transform: translateY(calc(-100% + 100cqh)); transition: transform 24s linear; }
.work__meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.work__meta h3 { position: relative; font-size: var(--title-fs); font-weight: 500; letter-spacing: -.01em; line-height: 1.3; }
/* Подчёркивание названия: выезжает при наведении на снимок или фокусе на нём */
.work__meta h3::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1.5px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
}
@media (prefers-reduced-motion: no-preference) {
  .work__meta h3::after { transition: transform .45s var(--ease); }
}
.work:has(> .work__media:focus-visible) .work__meta h3 { color: var(--accent-text); }
.work:has(> .work__media:focus-visible) .work__meta h3::after { transform: scaleX(1); }
/* Метка категории одна на все рубрики: спокойная плашка с точкой акцента, цвет не спорит с активным фильтром */
.work__meta .pill { flex: none; gap: 7px; min-height: 28px; padding: 3px 12px 3px 10px; font-size: 13px; color: var(--muted); }
.work__meta .pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
/* Тонкая рамка поверх светлых снимков: белый фон кресла и дивана не растворяется в странице */
.work__media::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(44, 38, 35, .08);
  pointer-events: none;
}

/* =========================================================
   Пакеты и этапы
   ========================================================= */
/* Угол «орбиты» на рамке должен уметь плавно меняться */
@property --angle { syntax: "<angle>"; inherits: false; initial-value: 0deg; }

.packages { position: relative; isolation: isolate; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); counter-reset: package; }
/* Тёплое свечение за тёмной карточкой: глубина без новых цветов */
.packages::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -8%;
  right: -6%;
  width: 46%;
  height: 116%;
  background: radial-gradient(closest-side, rgba(224, 122, 46, .24), transparent);
  filter: blur(36px);
  pointer-events: none;
}
.package {
  counter-increment: package;
  display: flex;
  flex-direction: column;
  gap: 16px;
  border: 1px solid var(--line);
  background: radial-gradient(420px 300px at 100% 0, rgba(224, 122, 46, .1), transparent 70%), var(--card);
  transition: transform .45s var(--ease), box-shadow .45s var(--ease), border-color .45s;
}
.package::before {
  content: "Пакет " counter(package, decimal-leading-zero);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent-text);
}
.package--full::before { color: var(--accent-on-dark); }
@media (hover: hover) {
  .package:hover {
    transform: translateY(-6px);
    border-color: rgba(224, 122, 46, .38);
    box-shadow: var(--shadow-float);
  }
}
.package h3 { font-size: var(--fs-h3); letter-spacing: -.02em; }
.package__top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.package__lead {
  padding-bottom: 20px;
  background: linear-gradient(90deg, var(--line-strong), transparent) bottom / 100% 1px no-repeat;
  color: var(--muted);
}
.package .checks { flex: 1; margin-top: 4px; align-content: start; }
.package .checks li::before { transition: box-shadow .4s; }
@media (hover: hover) {
  .package:hover .checks li::before { box-shadow: 0 0 0 4px rgba(224, 122, 46, .16); }
}
/* «Всё из предыдущего пакета» читается как база, на которой строится остальное */
.checks__inherit { font-weight: 600; }

.package__btn { gap: 0; margin-top: 16px; }
/* Стрелка выезжает при наведении: ширина растёт от нуля, текст остаётся по центру */
.package__btn::after {
  content: "";
  width: 0;
  height: 16px;
  background: currentColor;
  -webkit-mask: var(--arrow-right) center / contain no-repeat;
  mask: var(--arrow-right) center / contain no-repeat;
  opacity: 0;
  transition: width .35s var(--ease), margin .35s var(--ease), opacity .3s;
}
.package__btn:is(:hover, :focus-visible)::after { width: 16px; margin-left: 10px; opacity: 1; }
.package__btn.btn--outline:hover { border-color: var(--ink); background: var(--ink); color: var(--on-dark); }
/* Блик пробегает по кнопке главного пакета */
.package__btn.btn--accent {
  background-image: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, .42) 50%, transparent 65%);
  background-size: 260% 100%;
  background-position: 140% 0;
  background-repeat: no-repeat;
  transition: background-color .2s, border-color .2s, color .2s, transform .25s var(--ease), background-position .9s var(--ease);
}
.package__btn.btn--accent:hover { background-position: -40% 0; }

/* Тёмная карточка: двойной селектор нужен, чтобы перебить .card--dark, который объявлен ниже по файлу */
.package.package--full {
  border-color: transparent;
  background: radial-gradient(760px 460px at 100% 0, rgba(224, 122, 46, .24), transparent 62%), var(--ink);
  box-shadow: 0 40px 70px -36px rgba(224, 122, 46, .4), 0 34px 60px -34px rgba(44, 38, 35, .7);
}
.package--full .package__lead { background-image: linear-gradient(90deg, rgba(245, 243, 239, .3), transparent); color: var(--on-dark-muted); }
/* Световая «орбита» по рамке — единственный постоянно движущийся элемент блока, выделяет главный пакет */
.package--full::after {
  content: "";
  position: absolute;
  inset: -1px;
  padding: 1.5px;
  border-radius: inherit;
  background: conic-gradient(from var(--angle), transparent 0 60%, rgba(235, 138, 64, .9) 84%, #FFD7B0 90%, transparent 96%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .package--full::after { animation: package-orbit 7s linear infinite; }
}
@keyframes package-orbit { to { --angle: 360deg; } }

.process { margin-top: clamp(64px, 8vw, 112px); }
.process__title { margin-bottom: clamp(28px, 3vw, 44px); font-size: clamp(28px, 1rem + 1.6vw, 44px); }
/* Колонки без зазора, чтобы линия шла непрерывно от первого шага до последнего */
.steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; }
.step:nth-child(2) { --i: 1; }
.step:nth-child(3) { --i: 2; }
.step:nth-child(4) { --i: 3; }
.step { --i: 0; --track: 1.5px; position: relative; padding: 28px var(--pad) 0 0; border-top: var(--track) solid var(--line-strong); }
/* Заливка дорожки: каждый шаг закрашивает свой отрезок, пока не дойдёт до финиша */
.step::after {
  content: "";
  position: absolute;
  top: calc(-1 * var(--track));
  right: 0;
  left: 0;
  height: var(--track);
  background: rgba(224, 122, 46, .75);
  transform-origin: left;
  transition: transform .55s cubic-bezier(.5, 0, .2, 1) calc(var(--i) * .5s);
}
.step::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: -7px;
  left: 0;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--bg-soft), 0 0 0 5px rgba(224, 122, 46, .35);
  transition: scale .4s var(--ease), background-color .3s calc(var(--i) * .5s), box-shadow .3s calc(var(--i) * .5s);
}
/* Финиш: последний шаг отмечен галочкой, как пункты в списках пакетов */
.step:last-child::before {
  top: -11px;
  width: 22px;
  height: 22px;
  background: var(--accent) var(--check) center / 12px no-repeat;
}
@media (hover: hover) {
  .step:hover::before { scale: 1.3; }
  .step:hover .step__num { color: var(--accent); }
}
.step__num {
  display: block;
  margin-bottom: 18px;
  font-size: clamp(44px, 1rem + 2.6vw, 66px);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -.055em;
  color: var(--accent-text);
  transition: color .3s;
}
.step h3 { margin-bottom: 8px; font-size: 19px; letter-spacing: -.02em; }
.step p { max-width: 30ch; font-size: 15px; color: var(--muted); }

/* Появление этапов: main.js ставит data-armed до наблюдения, поэтому без скрипта и при reduced-motion всё сразу на месте.
   Линия идёт слева направо, точки загораются, когда её фронт доходит до них, текст проявляется следом */
@media (prefers-reduced-motion: no-preference) {
  .step > * {
    --d: calc(var(--i) * .5s + .2s);
    transition: opacity .7s var(--ease) var(--d), translate .7s var(--ease) var(--d), color .3s;
  }
  .steps[data-armed]:not(.is-in) .step::after { transform: scaleX(0); }
  .steps[data-armed]:not(.is-in) .step::before {
    scale: .6;
    background-color: var(--sand);
    box-shadow: 0 0 0 4px var(--bg-soft), 0 0 0 5px var(--line-strong);
  }
  .steps[data-armed]:not(.is-in) .step:last-child::before { background-image: none; }
  .steps[data-armed]:not(.is-in) .step > * { opacity: 0; translate: 0 14px; }
}

/* Появление блоков: показывает GSAP из main.js, а до его запуска (класс .motion) они скрыты без сдвига вёрстки */
@media (prefers-reduced-motion: no-preference) {
  .motion :is([data-reveal], [data-reveal-items] > *) { visibility: hidden; }
}

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    /* Снимки «оседают»: чуть приближены при входе в кадр и замедляются к центру экрана.
       Свойство scale не конфликтует с transform при наведении */
    /* overflow:hidden делает контейнер скроллером, и view() у картинки следил бы за ним, а не за страницей;
       overflow:clip обрезает так же, но скроллером не становится */
    .work__media, .card--photo { overflow: clip; }
    .work__media > img, .card--photo > img {
      animation: settle linear both;
      animation-timeline: view();
      animation-range: entry 0% cover 55%;
    }
  }
}
@keyframes settle { from { scale: 1.12; } }

/* =========================================================
   Контакты
   ========================================================= */
.contact__panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  overflow: hidden;
  border-radius: var(--r-xl);
  background: radial-gradient(640px 420px at 0 100%, rgba(224, 122, 46, .2), transparent 70%), var(--ink);
  color: var(--on-dark);
}
.contact__body {
  position: relative;
  z-index: 1;
  padding: clamp(28px, 5vw, 80px);
}
.contact__body h2 { font-size: clamp(40px, 1rem + 4vw, 88px); line-height: .98; letter-spacing: -.04em; text-wrap: balance; }
.contact__lead { max-width: 46ch; margin-top: clamp(18px, 2vw, 28px); font-size: clamp(16px, .95rem + .3vw, 19px); color: var(--on-dark-muted); }

.contact__cta {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  max-width: 520px;
  margin-top: clamp(32px, 4vw, 48px);
  padding: 14px 26px 14px 14px;
  border-radius: var(--r-md);
  background: var(--accent);
  color: var(--ink);
  transition: background-color .25s, transform .3s var(--ease), box-shadow .3s;
}
.contact__cta:hover { background: var(--accent-hover); transform: translateY(-2px); box-shadow: 0 22px 44px -22px rgba(224, 122, 46, .7); }
.contact__cta:focus-visible { outline-color: var(--on-dark); border-radius: var(--r-md); }
.contact__cta-icon { display: grid; place-items: center; width: 60px; height: 60px; border-radius: var(--r-sm); background: var(--ink); color: var(--accent-on-dark); }
.contact__cta-icon .icon { width: 28px; height: 28px; }
.contact__cta-label { display: block; font-size: 14px; font-weight: 500; }
.contact__cta-handle { display: block; font-size: clamp(20px, 1rem + .7vw, 28px); font-weight: 600; letter-spacing: -.02em; }
.contact__cta-arrow { width: 28px; height: 28px; transition: transform .4s var(--ease); }
.contact__cta:hover .contact__cta-arrow { transform: rotate(45deg); }

.contact__points { gap: 12px; margin-top: clamp(28px, 3vw, 40px); }
.contact__points li { font-size: 16px; color: var(--on-dark-muted); }

/* Рендер растворяется в тёмной панели, поэтому между текстом и кадром нет жёсткого шва */
.contact__media { position: relative; min-height: 100%; }
.contact__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 42%;
  mask-image: linear-gradient(90deg, transparent, #000 38%);
  transition: scale 1.2s var(--ease);
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .contact__panel:has(.contact__cta:hover) .contact__media img { scale: 1.04; }
}

@media (max-width: 860px) {
  .contact__panel { grid-template-columns: minmax(0, 1fr); }
  .contact__media { order: -1; min-height: 0; aspect-ratio: 4 / 3; }
  .contact__media img { mask-image: linear-gradient(180deg, #000 55%, transparent); }
  .contact__body { padding-top: 12px; }
}
@media (max-width: 380px) {
  .contact__cta { gap: 14px; padding-right: 18px; }
  .contact__cta-icon { width: 52px; height: 52px; }
  .contact__cta-arrow { display: none; }
}

/* Страница политики конфиденциальности */
.legal-bar { padding-block: 20px; border-bottom: 1px solid var(--line); }
.legal-bar__inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.legal-bar__back { color: var(--muted); transition: color .2s; }
.legal-bar__back:hover { color: var(--ink); }

.legal { padding-block: clamp(40px, 6vw, 96px) clamp(64px, 8vw, 128px); }
.legal h1 { max-width: 22ch; margin-inline: auto; font-size: clamp(34px, 1rem + 3.2vw, 64px); line-height: 1; letter-spacing: -.04em; text-align: center; text-wrap: balance; }
.legal__date { margin-top: 16px; color: var(--muted); text-align: center; }

.legal__layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0 clamp(40px, 6vw, 96px); margin-top: clamp(32px, 4vw, 64px); }
.legal__toc { display: none; }
.legal__text { max-width: 760px; }
.legal h2 { scroll-margin-top: 28px; margin: clamp(36px, 4vw, 56px) 0 14px; padding-top: clamp(24px, 3vw, 36px); border-top: 1px solid var(--line); font-size: clamp(22px, 1rem + .8vw, 30px); letter-spacing: -.02em; }
.legal h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.legal__text p, .legal__text li { line-height: 1.7; }
.legal__text p + p, .legal__text ul, .legal__text ul + p { margin-top: 12px; }
.legal__text ul { display: grid; gap: 8px; padding-left: 0; list-style: none; }
.legal__text li { position: relative; padding-left: 22px; }
.legal__text li::before { content: ""; position: absolute; left: 2px; top: .8em; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
.legal a { text-decoration: underline; text-decoration-color: rgba(173, 83, 19, .4); text-underline-offset: 3px; transition: text-decoration-color .2s; }
.legal a:hover { text-decoration-color: currentColor; }

@media (min-width: 1000px) {
  .legal__layout { grid-template-columns: 260px minmax(0, 1fr); }
  .legal__toc { display: block; position: sticky; top: 28px; align-self: start; }
  .legal__toc ol { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
  .legal__toc a { display: block; padding: 8px 14px; border-radius: var(--r-sm); color: var(--muted); text-decoration: none; transition: background-color .2s, color .2s; }
  .legal__toc a:hover { background: var(--bg-soft); color: var(--ink); }
}

/* =========================================================
   Подвал
   ========================================================= */
.footer { padding-block: clamp(56px, 7vw, 96px) 28px; border-top: 1px solid var(--line); }
.footer__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 36px var(--gap); }
.footer { background: radial-gradient(700px 360px at 0 100%, rgba(224, 122, 46, .12), transparent 70%); }
.footer__brand { grid-column: 1 / span 5; display: grid; align-content: start; justify-items: start; gap: 20px; }
.footer__tagline { max-width: 26ch; font-size: clamp(18px, 1rem + .4vw, 22px); font-weight: 500; line-height: 1.3; letter-spacing: -.02em; color: var(--muted); }
.footer__nav { grid-column: 7 / span 3; display: grid; align-content: start; gap: 10px; font-size: 16px; }
.footer__nav a { width: fit-content; color: var(--muted); transition: color .2s, translate .3s var(--ease); }
.footer__nav a:hover { color: var(--ink); translate: 4px 0; }
.footer__contacts { grid-column: 10 / -1; display: grid; align-content: start; gap: 18px; }
.footer__contacts a { display: grid; gap: 2px; width: fit-content; font-size: 18px; letter-spacing: -.02em; transition: color .2s; }
.footer__contacts a:hover { color: var(--accent-text); }
/* Подписи колонок в одном стиле: мелкие заглавные, терракотовый акцент */
.footer__contacts .footer__cta { display: inline-flex; margin-top: 6px; font-size: 15px; letter-spacing: 0; }
.footer__contacts .footer__cta:hover { color: var(--ink); }
.footer__label { margin-bottom: 4px; font-size: 12.5px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--accent-text); }
.footer__value { display: inline-flex; align-items: center; gap: 8px; }
.footer__value .icon { width: 20px; height: 20px; color: var(--accent-text); }

.footer__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: clamp(40px, 5vw, 64px);
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--muted);
}
.footer__up {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  color: var(--ink);
  transition: background-color .2s, border-color .2s, translate .3s var(--ease);
}
.footer__up:hover { background: var(--accent); border-color: var(--accent); translate: 0 -3px; }
.footer__up .icon { width: 18px; height: 18px; }

@media (max-width: 960px) {
  .footer__brand { grid-column: 1 / -1; }
  .footer__nav { grid-column: 1 / span 6; }
  .footer__contacts { grid-column: 7 / -1; }
}
@media (max-width: 480px) {
  .footer__nav, .footer__contacts { grid-column: 1 / -1; }
  .footer__nav { gap: 0; }
  .footer__nav a { padding-block: 10px; }
}

/* =========================================================
   Окно просмотра
   ========================================================= */
.viewer {
  width: min(1200px, calc(100vw - 24px));
  max-width: none;
  max-height: calc(100dvh - 24px);
  padding: 0;
  border: 0;
  border-radius: var(--r-lg);
  background: var(--bg-soft);
  color: var(--ink);
  overflow: hidden;
}
.viewer[open] { display: flex; flex-direction: column; }
/* Пока открыто окно просмотра, страница под ним не прокручивается (в том числе колесом поверх iframe) */
html:has(.viewer[open]) { overflow: hidden; }
.viewer::backdrop { background: rgba(44, 38, 35, .62); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
@media (prefers-reduced-motion: no-preference) {
  .viewer[open] { animation: viewer-in .4s var(--ease); }
}
@keyframes viewer-in { from { opacity: 0; transform: translateY(16px) scale(.98); } }
.viewer__bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 12px 12px 24px; }
.viewer__bar .round-btn:hover { transform: rotate(90deg); }
.viewer__title { font-weight: 500; }
.viewer__body { min-height: 0; padding: 0 12px 12px; overflow: auto; }
.viewer__body > img {
  width: 100%;
  max-height: calc(100dvh - 110px);
  object-fit: contain;
  border-radius: var(--r-md);
}
.viewer__body > .browser { box-shadow: none; }
.viewer__body > .browser .browser__viewport { aspect-ratio: auto; height: calc(100dvh - 150px); overflow-y: auto; container-type: size; }

/* Фото: окно фиксированного размера, чтобы при листании не прыгало; поля заполняет размытая копия кадра */
.viewer--photo { width: min(860px, calc(100vw - 24px)); }
.viewer--photo .viewer__title { font-size: clamp(17px, 1.4vw, 21px); letter-spacing: -.01em; }
.shot { display: grid; gap: 12px; margin: 0; padding-bottom: 2px; }
.shot:focus { outline: none; }
.shot__stage {
  position: relative;
  height: min(calc(100dvh - 176px), 780px);
  border-radius: var(--r-md);
  overflow: hidden;
  isolation: isolate;
  background: var(--sand);
  box-shadow: 0 26px 44px -34px rgba(44, 38, 35, .55);
}
.shot__ambient {
  position: absolute;
  inset: -8%;
  z-index: -1;
  width: 116%;
  height: 116%;
  object-fit: cover;
  opacity: .6;
  filter: blur(34px) saturate(1.15);
}
.shot__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.shot__stage:has(.shot__dock) .shot__photo { cursor: pointer; }
/* Капсула внизу: счётчик и кнопки для телефона и клавиатуры */
.shot__dock {
  position: absolute;
  bottom: 16px;
  left: 50%;
  translate: -50% 0;
  z-index: 3;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 5px;
  border: 1px solid rgba(255, 255, 255, .6);
  border-radius: 999px;
  background: rgba(255, 255, 255, .78);
  box-shadow: 0 18px 32px -18px rgba(44, 38, 35, .6);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}
.shot__dock-btn {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  transition: background-color .25s, color .25s;
}
.shot__dock-btn:hover { background: var(--ink); color: var(--on-dark); }
.shot__dock-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .3em;
  min-width: 56px;
  overflow: hidden;
  font-size: 14.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.shot__dock-now { display: inline-block; }
.shot__caption { display: flex; align-items: center; gap: 12px; padding: 0 6px; }
.shot__cta { position: relative; margin-left: auto; overflow: hidden; }
.shot__cta::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .45) 50%, transparent 65%);
  translate: -120% 0;
  pointer-events: none;
}
@media (prefers-reduced-motion: no-preference) {
  .shot__cta { animation: btn-call 3.2s 2s ease-out infinite; }
  .shot__cta:hover { animation: none; }
  .shot__cta:hover::after { translate: 120% 0; transition: translate 1.5s var(--ease); }
}
.shot__tag {
  padding: 5px 14px;
  border: 1px solid rgba(224, 122, 46, .32);
  border-radius: 999px;
  background: rgba(224, 122, 46, .12);
  color: var(--accent-text-tint);
  font-size: 13.5px;
  line-height: 1.25;
}
@media (max-width: 640px) {
  .shot__dock { bottom: 12px; }
}

/* clip: поднятый лист не должен раздувать прокрутку окна (из-за неё прыгала вёрстка и вылезал скроллбар) */
.flip { display: grid; gap: 14px; padding: 16px 4px 8px; overflow: clip; overflow-clip-margin: 24px; }
.flip .book { position: relative; max-width: calc((100dvh - 202px) * 1.5); margin-inline: auto; perspective: 4500px; }
/* Перелистывание: лист (две стороны) поворачивается вокруг корешка, см. turnPage в main.js */
/* Страницу можно тянуть: вертикальная прокрутка пальцем остаётся, горизонталь забирает листание */
.flip .book { touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.flip .book:active { cursor: grabbing; }
.flip .book img { -webkit-user-drag: none; }
:where(.turn__page) { background: #fbfaf8; }
.turn__page { position: absolute; inset: 0; }
.turn__rest--left, .turn__rest--right { right: auto; width: 50%; border-radius: 2px 0 0 2px; }
.turn__rest--right { left: 50%; border-radius: 0 2px 2px 0; }
.turn { position: absolute; top: 0; bottom: 0; width: 50%; transform-style: preserve-3d; will-change: transform; }
.turn--right { left: 50%; transform-origin: left center; }
.turn--left { left: 0; transform-origin: right center; }
.turn__front, .turn__back { backface-visibility: hidden; }
.turn__back { transform: rotateY(180deg); }
.turn--right .turn__front, .turn--left .turn__back { border-radius: 0 2px 2px 0; }
.turn--left .turn__front, .turn--right .turn__back { border-radius: 2px 0 0 2px; }
/* Поднятый лист отбрасывает мягкую тень на разворот */
.turn__front, .turn__back { box-shadow: 0 0 28px rgba(20, 15, 12, .22); }
/* Тень у корешка на обеих сторонах листа, как сгиб на развороте */
.turn__front::after, .turn__back::after { content: ""; position: absolute; inset: 0; pointer-events: none; }
.turn--right .turn__front::after, .turn--left .turn__back::after { background: linear-gradient(90deg, rgba(44, 38, 35, .2), transparent 14%); }
.turn--left .turn__front::after, .turn--right .turn__back::after { background: linear-gradient(270deg, rgba(44, 38, 35, .2), transparent 14%); }
.flip__nav { display: flex; align-items: center; justify-content: center; gap: 18px; }
.flip__count { min-width: 56px; text-align: center; font-size: 14.5px; color: var(--muted); }
.flip__nav .round-btn:hover { transform: none; background: #3d3531; }
.flip__nav .round-btn[disabled] { opacity: .35; pointer-events: none; }
/* Каталог открывается не в окне, а как журнал, лежащий на тёмном столе */
.viewer--book { width: 100vw; height: 100dvh; max-height: none; border-radius: 0; background: transparent; color: var(--on-dark); }
.viewer--book::backdrop { background: radial-gradient(ellipse 70% 60% at 50% 46%, rgba(62, 50, 43, .94), rgba(18, 14, 12, .97)); }
.viewer--book .viewer__bar { position: absolute; inset: 0 0 auto; z-index: 1; padding: 16px 16px 0 28px; pointer-events: none; }
.viewer--book .viewer__bar > * { pointer-events: auto; }
.viewer--book .viewer__title { font-size: 12px; font-weight: 500; letter-spacing: .28em; text-transform: uppercase; color: var(--on-dark-muted); }
.viewer--book .round-btn,
.viewer--book .round-btn--light { background: rgba(245, 243, 239, .1); color: var(--on-dark); }
.viewer--book .flip__nav .round-btn:hover,
.viewer--book .round-btn--light:hover { background: rgba(245, 243, 239, .2); }
.viewer--book .viewer__body { flex: 1; display: grid; align-content: center; padding: 68px 32px 24px; overflow: hidden; }
.viewer--book .flip { gap: 26px; padding: 0; overflow: visible; }
.viewer--book .flip .book { width: 100%; max-width: min(1480px, calc((100dvh - 180px) * 1.5)); }
.viewer--book .flip__count { color: var(--on-dark-muted); letter-spacing: .12em; }

/* Журнал: обрез страниц по краям блока, глубокий корешок и лёгкое затенение внешних краёв */
.flip .spread {
  border-radius: 2px;
  box-shadow:
    -1px 1px 0 #ebe6de, 1px 1px 0 #ebe6de,
    -2px 2px 0 #d8d0c5, 2px 2px 0 #d8d0c5,
    -3px 3px 0 #ebe6de, 3px 3px 0 #ebe6de,
    -4px 4px 0 #cfc6ba, 4px 4px 0 #cfc6ba,
    0 34px 70px -20px rgba(0, 0, 0, .6),
    0 14px 28px -14px rgba(0, 0, 0, .45);
}
.flip .spread::after {
  inset: 0;
  width: auto;
  translate: none;
  background: linear-gradient(90deg,
    rgba(30, 22, 18, .06), transparent 5%,
    transparent 42%, rgba(30, 22, 18, .1) 47%, rgba(30, 22, 18, .32) 49.9%,
    rgba(255, 255, 255, .1) 50.2%, rgba(30, 22, 18, .12) 52.5%, transparent 58%,
    transparent 95%, rgba(30, 22, 18, .06));
}

/* Телефон: журнал во всю ширину, кнопки листания компактнее */
@media (max-width: 640px) {
  .viewer--book .viewer__bar { padding: 10px 10px 0 16px; }
  .viewer--book .viewer__body { padding: 60px 8px 16px; }
  .viewer--book .flip { gap: 20px; }
  .flip__nav .round-btn { width: 38px; height: 38px; }
  .flip__nav { gap: 14px; }
}

/* =========================================================
   Атмосфера и глубина
   ========================================================= */
/* Тёплые пятна света на фоне страницы, чтобы бежевое не читалось плоским */
body {
  background:
    radial-gradient(1000px 700px at 96% -6%, rgba(224, 122, 46, .2), transparent 62%) no-repeat,
    radial-gradient(900px 800px at -10% 36%, rgba(224, 122, 46, .11), transparent 62%) no-repeat,
    radial-gradient(1000px 800px at 108% 74%, rgba(224, 122, 46, .1), transparent 62%) no-repeat,
    var(--grain), var(--bg);
}
.section--soft { background: linear-gradient(180deg, #F8F6F2, #EEEAE3); }

.card { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .9), 0 26px 50px -36px rgba(44, 38, 35, .5); }
.card--dark {
  background: radial-gradient(760px 460px at 100% 0, rgba(224, 122, 46, .24), transparent 62%), var(--ink);
  box-shadow: 0 34px 60px -34px rgba(44, 38, 35, .7);
}
.card--photo > img { transition: transform .9s var(--ease); }
@media (hover: hover) {
  .card--photo:hover > img { transform: scale(1.045); }
}

.hero__card {
  isolation: isolate;
  overflow: clip;
  background: linear-gradient(125deg, #fff 52%, #FBEFE3);
  box-shadow: 0 50px 90px -52px rgba(44, 38, 35, .55), inset 0 1px 0 #fff;
}
.hero__card::before {
  content: "";
  position: absolute;
  z-index: -1;
  right: -8%;
  top: 50%;
  width: 62%;
  aspect-ratio: 1;
  translate: 0 -50%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(224, 122, 46, .34), transparent 66%);
}
.hero__portrait { box-shadow: 0 0 0 10px rgba(224, 122, 46, .16), 0 44px 70px -34px rgba(44, 38, 35, .7); }
.hero__stats li { border-top: 2px solid var(--ink); }
.hero__stats strong { font-size: clamp(30px, 1rem + 1.6vw, 48px); }

.step__num { font-size: clamp(56px, 1rem + 3.6vw, 96px); }

/* =========================================================
   Адаптив
   ========================================================= */
@media (max-width: 1180px) {
  .nav { display: none; }
  .nav + .header__actions { margin-left: auto; }
  .burger { display: grid; }

  .commercial__text { grid-column: 1 / -1; grid-row: auto; }
  .commercial__a { grid-column: 1 / span 7; grid-row: 2; }
  .commercial__plate { grid-column: 1 / span 7; grid-row: 3; }
  .commercial__b { grid-column: 8 / -1; grid-row: 2 / span 2; }

  .why { grid-template-columns: minmax(0, 1fr); }
  .why__title { max-width: none; }
  .why__lead { max-width: none; }
  .why__cube { display: none; }

  .pack { grid-template-columns: minmax(0, 1fr); }
  .pack__showcase { position: relative; top: 0; order: -1; aspect-ratio: 16 / 10; }

  .synergy__head { grid-template-columns: minmax(0, 1fr); }
  .chain { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain__step:nth-child(2)::after { display: none; }

  .work { grid-column: span 6; }
}

@media (max-width: 900px) {
  .hero__card {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "content" "portrait" "stats";
    grid-template-rows: auto;
    row-gap: 32px;
    min-height: 0;
  }
  .hero__side { justify-self: center; width: min(100%, 440px); }
  .hero__portrait { aspect-ratio: 5 / 6; }

  .section-head h2, .section-head p { grid-column: 1 / -1; }
  .section-head p { align-self: start; }

  .studio { grid-template-columns: minmax(0, 1fr); }
  .duo { grid-template-columns: minmax(0, 1fr); }

  .packages { grid-template-columns: minmax(0, 1fr); }
  .packages::before { display: none; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; }
  .benefits { grid-template-columns: minmax(0, 1fr); gap: 24px; }

  .filters {
    flex-wrap: nowrap;
    /* Поля сверху и снизу — место для кольца фокуса, иначе overflow его обрежет */
    margin: -6px calc(-1 * var(--gutter)) 22px;
    padding: 6px max(var(--gutter), 48px) 6px var(--gutter);
    overflow-x: auto;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
    scroll-padding-inline: var(--gutter);
    /* Правый край ленты гаснет: видно, что фильтры продолжаются за экраном */
    -webkit-mask-image: linear-gradient(to left, transparent, #000 48px);
    mask-image: linear-gradient(to left, transparent, #000 48px);
  }
  .pill--btn { scroll-snap-align: start; }
  .filters::-webkit-scrollbar { display: none; }
  .pill--btn { flex: none; }
}

@media (max-width: 720px) {
  .header__tg { display: none; }
  .header .logo__descr { display: none; }

  .hero { padding-top: 24px; }
  .hero__side { width: 100%; }
  .hero__portrait { aspect-ratio: 4 / 5; }
  .hero__portrait > img { object-position: 50% 8%; }
  .hero__tags {
    flex-wrap: nowrap;
    justify-content: flex-start; /* при центрировании левая часть ленты уехала бы за экран */
    margin-inline: calc(-1 * var(--gutter));
    padding-inline: var(--gutter);
    overflow-x: auto;
    scrollbar-width: none;
    scroll-snap-type: x proximity;
  }
  .hero__tags::-webkit-scrollbar { display: none; }
  .tag { scroll-snap-align: start; }
  .hero__actions .btn { width: 100%; }

  .lifestyle__styles .pill { min-height: 28px; padding: 3px 11px; font-size: 12.5px; }

  .pack__trigger { flex-direction: column; align-items: flex-start; gap: 10px; }

  .commercial__a, .commercial__plate, .commercial__b, .commercial__text { grid-column: 1 / -1; grid-row: auto; }
  .commercial__a { aspect-ratio: 1; min-height: 0; }
  .commercial__b { aspect-ratio: 501 / 1024; min-height: 0; }

  .why__list { grid-template-columns: minmax(0, 1fr); gap: 28px; }

  /* Шесть образцов в один ряд под подписью, а не овал с переносом */
  .swatches { padding: 10px 12px; border-radius: var(--r-md); }
  .swatches__list { gap: 8px; padding: 4px 0; }
  .swatch { width: 30px; height: 30px; }

  .show { padding: 18px; }
  .pack__showcase { aspect-ratio: 4 / 3; }

  .works { --media-h: auto; }
  .work, .work--half { grid-column: 1 / -1; }
  .work__media { aspect-ratio: 4 / 3; }
  /* Фото в своих пропорциях (по width/height из разметки, без сдвига вёрстки), чтобы не резать главное.
     Очень вытянутые ограничены высотой экрана */
  .work__media[data-open="image"] { aspect-ratio: auto; }
  .work__media[data-open="image"] > img { height: auto; max-height: 75svh; }

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

@media (max-width: 480px) {
  .header__actions .btn { display: none; }
  .hero__card { --hero-pad: 20px; }
  .hero__actions .btn { padding: 0 18px; font-size: 16px; }
  .hero__works { gap: 12px; padding-left: 8px; font-size: 16px; }
  .hero__thumbs img { width: 36px; height: 36px; }
  .hero__works .round-btn { width: 44px; height: 44px; }
  /* Подпись не должна переноситься: на узких экранах убираем лишние миниатюры */
  .hero__thumbs img:nth-child(3) { display: none; }
  /* «Визуализирую» — самое длинное слово, при 42px оно не помещается в карточку на 320–360px */
  .hero__title { font-size: clamp(28px, 10vw, 42px); }
  .hero__stats strong { font-size: clamp(20px, 7.5vw, 30px); }
  .hero__stats { gap: 20px 8px; }
  .hero__stats span { font-size: 12.5px; }
  .hero__stats .icon { width: 34px; height: 34px; padding: 8px; margin-bottom: 6px; }
  /* Компактная плашка, чтобы не закрывала лицо на узком портрете */
  .glass { left: 10px; right: 10px; bottom: 10px; column-gap: 10px; padding: 11px 10px 11px 14px; }
  .glass__status { font-size: 12px; }
  .glass__text { font-size: 13.5px; line-height: 1.35; }
  .glass .round-btn { width: 40px; height: 40px; }
  .lifestyle__styles .pill, .card__head .pill { white-space: normal; }
  /* Плашка не сжимается (flex-shrink: 0), поэтому на узком экране уходит под заголовок, а не за край */
  .card__head { flex-wrap: wrap; }
  .footer .logo__descr { white-space: normal; }
  .chain__step { padding: 10px 10px 14px; }
  .chain__step b { font-size: 14px; }
}

@media (max-width: 340px) {
  .hero__thumbs img:nth-child(2) { display: none; }
}

/* На тач-экранах нет наведения — превью сайта листается само */
@media (hover: none) and (prefers-reduced-motion: no-preference) {
  .work__media--site .ms { animation: site-scroll 45s ease-in-out infinite alternate; }
}

/* Боковая навигация: ряд точек в левом поле страницы, у текущего раздела подпись. На узких экранах скрыта */
.progress {
  position: fixed;
  left: 0;
  top: 50%;
  z-index: 40;
  width: var(--gutter);
  display: none;
  translate: 0 -50%;
}
@media (min-width: 1100px) { .progress { display: block; } }
.progress ol {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.progress li {
  position: relative;
  width: 12px;
  height: 12px;
  border-radius: 12px;
  background: var(--line-strong);
  transition: height .4s var(--ease), background-color .3s;
}
.progress li.is-passed { background: var(--ink); }
.progress li.is-active { height: 40px; background: var(--accent); }
/* Ссылка шире самой точки, чтобы в неё было легко попасть */
.progress a { position: absolute; inset: -8px -12px; border-radius: 10px; }
.progress a:focus-visible { outline: 2px solid var(--accent); }
.progress span {
  position: absolute;
  top: 50%;
  left: calc(100% + 2px);
  padding: 8px 16px;
  border-radius: 999px;
  background: var(--card);
  box-shadow: var(--shadow-float);
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  translate: -6px -50%;
  transition: opacity .3s, translate .4s var(--ease);
  pointer-events: none;
}
.progress a:is(:hover, :focus-visible) span,
.progress .is-active span { opacity: 1; translate: 0 -50%; }
