*,
*::before,
*::after { box-sizing: border-box; }

html, body { margin: 0; }

body {
  background: #e9e6e1;
  color: #1c1b1a;
  font-family: "Manrope", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}

img, video { display: block; max-width: 100%; }

/* ---------- Первый экран ---------- */

.hero {
  --ink: #241d1a;
  --paper: #f4eee6;     /* светлая «Дарья», текст на кнопке */
  --hero-bg: #3f1119;   /* цвет студийного фона — бордовый */
  --floor: #796b60;     /* цвет пола на фото */
  --name-top: 16%;
  --name-size: 13vw;
  --role-size: clamp(22px, 2.6vw, 44px);
  --front-top: 50%;
  /* первый экран стоит на месте, следующий блок наезжает на него.
     --hero-top < 0, если экран выше окна: тогда он сначала докручивается до низа */
  position: sticky;
  top: var(--hero-top, 0px);
  z-index: 0;
  background: var(--hero-bg);
  color: var(--paper);   /* светлый текст на бордовом */
  overflow: hidden;
}

.nav {
  position: absolute;
  inset: 0 0 auto;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 22px clamp(16px, 3vw, 48px);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #f3ece2;   /* молочный — теплее белого */
}

.nav a { color: inherit; text-decoration: none; }

.nav__menu {
  display: flex;
  gap: clamp(20px, 3vw, 48px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav__menu a {
  padding: 6px 0;
  /* тонкое подчёркивание цвета шампани, выезжает слева при наведении */
  background: linear-gradient(#e3c9a0, #e3c9a0) 0 100% / 0 1px no-repeat;
  transition: background-size 0.3s;
}
.nav__menu a:hover,
.nav__menu a:focus-visible { background-size: 100% 1px; }

/* ---------- Полоса с меню ниже первого экрана ---------- */
section[id] { scroll-margin-top: 48px; }   /* при переходе по меню заголовок блока не прячется под полосой */
.topbar {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  padding: 14px clamp(16px, 4vw, 64px);
  background: #5E1726;
  color: #f3ece2;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  box-shadow: 0 6px 20px rgb(40 8 16 / 0.18);
  transform: translateY(-100%);
  visibility: hidden;                      /* спрятанные ссылки не ловят Tab */
  transition: transform 0.4s cubic-bezier(.2, .8, .2, 1), visibility 0s 0.4s;
}
.topbar.is-visible { transform: none; visibility: visible; transition: transform 0.4s cubic-bezier(.2, .8, .2, 1); }
.topbar a { color: inherit; text-decoration: none; }
@media (max-width: 760px) {
  .topbar { padding: 12px 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .topbar, .topbar.is-visible { transition: none; }
}

.btn {
  display: inline-block;
  padding: 15px 30px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.25s, color 0.25s;
}

.btn:hover,
.btn:focus-visible { background: transparent; color: var(--ink); }

.hero__stage {
  position: relative;
  height: max(100svh, 640px);
}

/* Имя: «Дубровская» уходит за фото, «Дарья» — поверх */
.hero__name {
  margin: 0;
  color: #e3c9a0;   /* «Дубровская» и «Дарья» — золотистые */
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: var(--name-size);
  line-height: 0.8;
  text-transform: uppercase;
}

.hero__name-back,
.hero__name-front {
  position: absolute;
  white-space: nowrap;
}

.hero__name-back {
  z-index: 1;
  top: var(--name-top);
  left: 50%;
  transform: translateX(-50%);
}

.hero__name-front {
  z-index: 3;
  top: var(--front-top);
  right: calc(50% - var(--name-size) * 2.605);   /* правый край как у «Дубровская»: буквы «Я» друг под другом */
  color: #e3c9a0;
}

/* Два слоя одного размера: оригинальное фото с фоном и вырезанная фигура.
   «Дубровская» лежит между ними. */
.hero__layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 50% 100%;
}
.hero__layer--bg  { z-index: 0; }
.hero__layer--cut { z-index: 2; }

/* Круглая кнопка — сразу под «Веб-дизайнер», левый край по той же букве «Д» */
.hero__side {
  position: absolute;
  z-index: 4;
  top: calc(var(--name-top) + var(--name-size) * 0.8 + 3vw + var(--role-size) + clamp(20px, 2.4vw, 40px));
  left: calc(50% - var(--name-size) * 2.605);
}

.hero__role {
  /* под «Дубровская», левый край — по букве «Д», как у «Дарья» (фамилия по центру шириной 5.21em) */
  position: absolute;
  z-index: 3;
  top: calc(var(--name-top) + var(--name-size) * 0.8 + 3vw);
  left: calc(50% - var(--name-size) * 2.605);
  margin: 0;
  color: #f3ece2;   /* «Веб-дизайнер» — светлый */
  font-family: "Oranienbaum", Georgia, serif;
  font-size: var(--role-size);
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* Кнопка-пилюля: тёмная, справа светлый кружок со стрелкой.
   При наведении кружок разливается на всю кнопку, текст темнеет, стрелка поворачивается вправо. */
.hero__cta {
  --core: 52px;
  --pad: 7px;
  position: relative;
  isolation: isolate;
  display: inline-flex;
  align-items: center;
  gap: 24px;
  padding: var(--pad) var(--pad) var(--pad) 30px;
  border-radius: 999px;
  overflow: hidden;
  background: var(--ink);
  color: var(--paper);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
  transition: color 0.45s cubic-bezier(.6, 0, .2, 1);
}

/* светлая заливка растёт из центра кружка */
.hero__cta::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 50%;
  right: calc(var(--pad) + var(--core) / 2);
  width: var(--core);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--paper);
  transform: translate(50%, -50%) scale(0);
  transition: transform 0.6s cubic-bezier(.6, 0, .2, 1);
}

.hero__cta-core {
  display: grid;
  place-items: center;
  width: var(--core);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--paper);
  color: var(--ink);
  transition: background 0.45s, color 0.45s;
}
.hero__cta-core svg {
  width: 18px;
  transition: transform 0.5s cubic-bezier(.6, 0, .2, 1);
}

.hero__cta:hover,
.hero__cta:focus-visible { color: var(--ink); }
.hero__cta:hover::before,
.hero__cta:focus-visible::before { transform: translate(50%, -50%) scale(9); }
.hero__cta:hover .hero__cta-core,
.hero__cta:focus-visible .hero__cta-core { background: var(--ink); color: var(--paper); }
.hero__cta:hover .hero__cta-core svg,
.hero__cta:focus-visible .hero__cta-core svg { transform: rotate(45deg); }
.hero__cta:focus-visible { outline: 1px solid var(--paper); outline-offset: 4px; }
/* на бордовом фоне первого экрана — светлая пилюля и тёмный кружок */
.hero .hero__cta { --ink: #e3c9a0; --paper: #3a1a20; }   /* золотистая пилюля, текст и кружок — тёмно-бордовые */
.hero .hero__cta:focus-visible { outline-color: #e3c9a0; }
/* наведение: пилюля из шампани становится молочной (заливка растекается из кружка), текст и кружок остаются тёмными */
.hero .hero__cta::before { background: #f3ece2; }
.hero .hero__cta:hover,
.hero .hero__cta:focus-visible { color: var(--paper); }
.hero .hero__cta:hover .hero__cta-core,
.hero .hero__cta:focus-visible .hero__cta-core { background: var(--paper); color: var(--ink); }

/* кружок-«печать» (как у кнопок ▶ в кейсах): без фона, при наведении печать чуть поворачивается, а стрелка — вправо */
.hero .hero__cta-core--seal,
.hero .hero__cta:hover .hero__cta-core--seal,
.hero .hero__cta:focus-visible .hero__cta-core--seal { background: none; border-radius: 0; }
.hero .hero__cta-core--seal svg { width: 100%; height: 100%; filter: drop-shadow(0 3px 5px rgb(30 6 12 / 0.3)); }
.hero .hero__cta:hover .hero__cta-core--seal svg,
.hero .hero__cta:focus-visible .hero__cta-core--seal svg { transform: rotate(-8deg); }
.hero__cta-arrow { transform-origin: 32px 32px; transition: transform 0.5s cubic-bezier(.6, 0, .2, 1); }
.hero__cta:hover .hero__cta-arrow,
.hero__cta:focus-visible .hero__cta-arrow { transform: rotate(53deg); }   /* вместе с поворотом печати −8° — ровно вправо */

/* Появление первого экрана (телефон): «Дубровская» поднимается из-за головы, «Дарья» выезжает справа, кнопка — последней */
@keyframes hero-rise  { from { translate: 0 0.6em; opacity: 0; } }
@keyframes hero-slide { from { translate: 60vw 0; opacity: 0; } }
@keyframes hero-fade  { from { translate: 0 12px; opacity: 0; } }
@media (max-width: 760px) {   /* только на телефоне */
  .js-anim .hero__name-back  { animation: hero-rise 1.3s cubic-bezier(.2, .8, .2, 1) .2s backwards; }
  .js-anim .hero__role       { animation: hero-fade .9s ease .9s backwards; }
  .js-anim .hero__name-front { animation: hero-slide 1.1s cubic-bezier(.2, .8, .2, 1) .7s backwards; }
  .js-anim .hero__pitch      { animation: hero-fade .9s ease 1.6s backwards; }
}

@media (prefers-reduced-motion: reduce) {
  .js-anim .hero__name-back, .js-anim .hero__role, .js-anim .hero__name-front, .js-anim .hero__pitch { animation: none; }
  .hero__cta, .hero__cta::before, .hero__cta-core, .hero__cta-core svg, .hero__cta-arrow { transition: none; }
}

/* ---------- Плавающая кнопка (только телефон) ---------- */

.float-cta {
  --ink: #241d1a;
  --paper: #f4eee6;
  display: none;
  position: fixed;
  z-index: 20;
  left: 50%;
  bottom: max(20px, env(safe-area-inset-bottom));
  transform: translate(-50%, 24px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s, transform 0.5s cubic-bezier(.2, .8, .2, 1);
}
.float-cta.is-visible { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.float-cta .hero__cta { --ink: #5E1726; --paper: #F3ECE2; box-shadow: 0 10px 30px rgb(36 29 26 / 0.3); white-space: nowrap; }   /* бордовая пилюля, светлый кружок */
/* светлая печать: без фона-кружка, при нажатии чуть поворачивается, стрелка — вправо */
.float-cta .hero__cta-core--seal,
.float-cta .hero__cta:hover .hero__cta-core--seal,
.float-cta .hero__cta:focus-visible .hero__cta-core--seal { background: none; border-radius: 0; }
.float-cta .hero__cta-core--seal svg { width: 100%; height: 100%; filter: drop-shadow(0 3px 5px rgb(30 6 12 / 0.35)); }
.float-cta .hero__cta:hover .hero__cta-core--seal svg,
.float-cta .hero__cta:focus-visible .hero__cta-core--seal svg { transform: rotate(-8deg); }

@media (max-width: 760px) {
  .float-cta { display: block; }
}

/* ---------- Прайс: тарифы в конвертах ---------- */
.price {
  position: relative;
  z-index: 1;
  background: #f4efe8;
  padding: clamp(80px, 9vw, 140px) clamp(16px, 4vw, 64px) clamp(32px, 3.5vw, 55px);   /* снизу вдвое меньше — фраза ближе к прайсу */
  text-align: center;
}
.price__title {
  margin: 0;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: clamp(42px, 3.48vw, 54px);
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #241d1a;
}
.price__lead {
  max-width: 34em;
  margin: 16px auto 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(18px, 1.45vw, 22.4px);
  line-height: 1.35;
  color: #6B5A52;
}
.price__list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 48px);
  max-width: 1180px;
  margin: clamp(96px, 8vw, 116px) auto 0;   /* сверху место под выехавшее письмо первого конверта */
}

/* конверт */
.env {
  --env: #EFE5D3;          /* бумага конверта */
  --env-in: #E2D3BA;       /* внутренняя сторона */
  --fold: #cdb896;         /* линии сгибов */
  --name: #241d1a;
  --price: #5E1726;
  position: relative;
  height: clamp(380px, 31vw, 440px);
  outline: none;
  text-align: center;
}

/* задняя стенка и открытый клапан сверху */
.env__back {
  position: absolute; left: 0; right: 0; bottom: 0; height: 58%;
  background: var(--env-in);
  border-radius: 4px;
}
.env__back::before {
  content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: 38%;
  background: var(--env-in);
  clip-path: polygon(0 100%, 50% 0, 100% 100%);
}
/* письмо */
.env__letter {
  position: absolute; left: 7%; right: 7%; bottom: 4%; height: 70%;
  padding: 20px 20px;
  background: #FBF7F0;
  box-shadow: 0 2px 8px rgb(60 20 25 / .12);
  transform: translateY(0);
  transition: transform .7s cubic-bezier(.2,.8,.2,1);
  text-align: left;
}
/* первое письмо выехало целиком — видно описание и состав */
.env:first-child .env__letter { transform: translateY(-60%); }
.env__desc {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic; font-weight: 500;
  font-size: 18px; line-height: 1.3; color: #5E1726;
}
.env__list { margin: 14px 0 0; padding: 0; list-style: none; font-size: 14px; line-height: 1.55; color: #5c5450; }
.env__list li { position: relative; padding-left: 16px; }
.env__list li::before { content: ""; position: absolute; left: 0; top: .65em; width: 6px; height: 6px; border-radius: 50%; background: #c9a46a; }
.env__term { margin: 12px 0 0; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: #8a7a70; }

/* передний карман со сгибами */
.env__front {
  position: absolute; left: 0; right: 0; bottom: 0; height: 58%;
  display: flex; flex-direction: column; justify-content: flex-end; align-items: center;
  padding: 0 16px clamp(22px, 2vw, 30px);
  background: var(--env);
  border-radius: 4px;
  box-shadow: 0 14px 28px rgb(60 20 25 / .16), 0 2px 4px rgb(60 20 25 / .1);
}
.env__folds { position: absolute; inset: 0; width: 100%; height: 100%; }
.env__folds path { fill: none; stroke: var(--fold); stroke-width: 1; vector-effect: non-scaling-stroke; }
.env__name {
  position: relative; margin: 0;
  font-family: "Oranienbaum", Georgia, serif; font-weight: 400;
  font-size: clamp(22px, 1.9vw, 30px); letter-spacing: .06em; text-transform: uppercase; line-height: 1.05;
  color: var(--name);
}
.env__price {
  position: relative; margin: 6px 0 0;
  font-family: "Cormorant Garamond", Georgia, serif; font-style: italic; font-weight: 500;
  font-size: clamp(24px, 2vw, 32px); color: var(--price);
}

/* у остальных из конверта выглядывает только описание; при наведении письмо выезжает целиком */
.env:hover .env__letter,
.env:focus-visible .env__letter,
.env:focus-within .env__letter { transform: translateY(-60%); }
.env:focus-visible .env__front { outline: 2px solid #5E1726; outline-offset: 6px; }

/* появление: конверты по очереди */
.js-anim .price__list .env { opacity: 0; transform: translateY(40px); transition: opacity .6s ease, transform .9s cubic-bezier(.2,.8,.2,1); }
.js-anim .price__list .env:nth-child(2) { transition-delay: .12s; }
.js-anim .price__list .env:nth-child(3) { transition-delay: .24s; }
.js-anim .price__list.is-in .env { opacity: 1; transform: none; }

.price__note {
  max-width: 40em; margin: clamp(40px, 4vw, 64px) auto 0;
  font-size: 14px; line-height: 1.6; color: #5c5450;
}

/* на телефоне и планшете наведения нет — письма сразу выдвинуты */
@media (hover: none), (max-width: 760px) {
  .env .env__letter { transform: translateY(-60%); }   /* на телефоне наведения нет — все письма выехали */
}
@media (max-width: 960px) {
  .price__list { grid-template-columns: minmax(0, 1fr); max-width: 420px; gap: 96px; }
  .env { height: 400px; }
}
@media (prefers-reduced-motion: reduce) {
  .env__letter, .js-anim .price__list .env { transition: none; }
}

/* ---------- Финальная фраза: журнальная «лесенка», слова наливаются цветом при прокрутке ---------- */

.closing {
  position: relative;
  z-index: 1;
  background: #f4efe8;
  color: #5E1726;
  padding: clamp(96px, 12vw, 200px) clamp(16px, 4vw, 64px);
  padding-top: clamp(48px, 6vw, 100px);   /* вдвое меньше — ближе к прайсу */
  overflow: hidden;
}

.ladder {
  width: fit-content;   /* блок по ширине фразы — и по центру экрана */
  max-width: 100%;
  margin: 0 auto;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: clamp(28px, 4.6vw, 84px);
  line-height: 1.02;
  --step: 1.28em;   /* шаг ступеньки растёт и уменьшается вместе со шрифтом */
  letter-spacing: -0.005em;
}

.ladder__line {
  display: block;
  padding-left: calc(var(--i) * var(--step));   /* каждая строка — ступенькой правее */
}
.ladder__line + .ladder__line { margin-top: 0.06em; }

/* смысловые слова — курсив Cormorant (он мельче, поэтому чуть крупнее) */
.ladder em {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-weight: 500;
  font-size: 1.14em;
  letter-spacing: 0;
}

/* слово: пока до него не дошла прокрутка — бледное */
.ladder .w {
  opacity: var(--o, 1);
  transition: opacity 0.25s linear;
}
.js-anim .ladder .w { --o: 0.16; }

@media (max-width: 760px) {
  .ladder { font-size: clamp(22px, 8vw, 40px); --step: 0.5em; }
  .ladder__line + .ladder__line { margin-top: 0.12em; }
  /* первая строка длинная — на телефоне она сама становится двумя ступеньками */
  .ladder__wrap { display: block; margin-top: 0.12em; padding-left: var(--step); }
  .ladder__line:not(:first-child) { padding-left: calc((var(--i) + 1) * var(--step)); }
}

@media (prefers-reduced-motion: reduce) {
  .js-anim .ladder .w { --o: 1 !important; transition: none; }
}

/* ---------- Плашки связи: Telegram, WhatsApp, «Оставить заявку» ---------- */

.reach {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px 18px;
  max-width: 1400px;
  margin: clamp(56px, 7vw, 96px) auto 0;
  padding: 0;
  list-style: none;
}

.reach__btn {
  --bg: #FBF7F0;          /* светлая плашка */
  --fg: #5E1726;          /* бордовый текст */
  --fill: #5E1726;        /* заливка при наведении */
  --fill-fg: #F3ECE2;
  box-sizing: border-box;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 18px;
  min-width: 290px;
  justify-content: space-between;
  padding: 9px 9px 9px 32px;
  border: 1px solid rgb(94 23 38 / 0.35);
  border-radius: 999px;
  background: var(--bg);
  color: var(--fg);
  font-family: "Manrope", sans-serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  overflow: hidden;
  isolation: isolate;
  box-shadow: 0 6px 18px rgb(60 14 24 / 0.08);
  transition: color 0.45s, border-color 0.45s, box-shadow 0.45s, transform 0.45s cubic-bezier(.2, .8, .2, 1);
}
/* заливка растекается от печати */
.reach__btn::before {
  content: "";
  position: absolute;
  z-index: -1;
  right: 36px;
  top: 50%;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--fill);
  transform: translate(50%, -50%) scale(0);
  transition: transform 0.6s cubic-bezier(.6, 0, .2, 1);
}
.reach__btn:hover,
.reach__btn:focus-visible {
  color: var(--fill-fg);
  border-color: var(--fill);
  box-shadow: 0 12px 28px rgb(60 14 24 / 0.18);
  transform: translateY(-2px);
}
.reach__btn:hover::before,
.reach__btn:focus-visible::before { transform: translate(50%, -50%) scale(18); }
.reach__btn:focus-visible { outline: 1px solid var(--fill); outline-offset: 4px; }

/* печать с иконкой */
.reach__seal { flex: none; width: 54px; height: 54px; }
.reach__seal svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 3px 5px rgb(30 6 12 / 0.28));
  transition: transform 0.5s cubic-bezier(.6, 0, .2, 1);
}
.reach__wax { fill: #5E1726; }
.reach__icon path {
  fill: none;
  stroke: #E3C9A0;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.reach__icon--arrow path { stroke-width: 2.4; }
.reach__icon--arrow { transform-origin: 32px 32px; transition: transform 0.5s cubic-bezier(.6, 0, .2, 1); }

.reach__btn:hover .reach__seal svg,
.reach__btn:focus-visible .reach__seal svg { transform: rotate(-8deg); }
.reach__btn:hover .reach__icon--arrow,
.reach__btn:focus-visible .reach__icon--arrow { transform: rotate(53deg); }   /* вместе с −8° — ровно вправо */

/* на бордовой заливке печать становится светлой */
.reach__btn:hover .reach__wax,
.reach__btn:focus-visible .reach__wax { fill: #F3ECE2; transition: fill 0.45s 0.15s; }
.reach__btn:hover .reach__icon path,
.reach__btn:focus-visible .reach__icon path { stroke: #5E1726; transition: stroke 0.45s 0.15s; }
.reach__wax, .reach__icon path { transition: fill 0.3s, stroke 0.3s; }

@media (max-width: 760px) {
  .reach { flex-direction: column; align-items: stretch; max-width: 360px; gap: 12px; }
  .reach__btn { width: 100%; min-width: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .reach__btn, .reach__btn::before, .reach__seal svg, .reach__icon--arrow { transition: none; }
}

/* ---------- Подвал: тонкая полоса с подписью и ссылкой «Наверх» ---------- */

.footer {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding: 22px clamp(16px, 4vw, 64px);
  background: #f4efe8;
  border-top: 1px solid rgb(94 23 38 / 0.18);
  font-family: "Manrope", sans-serif;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #8a7a70;
}
.footer__name { margin: 0; }
.footer__top {
  color: #5E1726;
  text-decoration: none;
  transition: opacity 0.3s;
}
.footer__top span { display: inline-block; transition: transform 0.3s cubic-bezier(.2, .8, .2, 1); }
.footer__top:hover span,
.footer__top:focus-visible span { transform: translateY(-3px); }
.footer__top:focus-visible { outline: 1px solid #5E1726; outline-offset: 4px; }

@media (max-width: 760px) {
  .footer { flex-direction: column; text-align: center; padding-bottom: 28px; }   /* плавающая кнопка внизу страницы спрятана — запас не нужен */
}

/* ---------- Окно «Оставить заявку» ---------- */

.request {
  width: min(460px, calc(100% - 32px));
  max-height: calc(100% - 32px);
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: #FBF7F0;
  color: #241d1a;
  box-shadow: 0 30px 80px rgb(40 8 16 / 0.35);
}
.request::backdrop { background: rgb(36 12 18 / 0.55); backdrop-filter: blur(3px); }
.request[open] { animation: request-in 0.4s cubic-bezier(.2, .8, .2, 1); }
@keyframes request-in { from { opacity: 0; transform: translateY(16px); } }

.request__form, .request__done { position: relative; padding: clamp(28px, 5vw, 44px); }
.request__close {
  position: absolute; top: 10px; right: 12px;
  width: 40px; height: 40px;
  border: 0; background: none; cursor: pointer;
  font-size: 28px; line-height: 1; color: #8a7a70;
}
.request__close:hover { color: #5E1726; }
.request__title {
  margin: 0;
  font-family: "Oranienbaum", Georgia, serif; font-weight: 400;
  font-size: clamp(30px, 3vw, 38px); letter-spacing: 0.06em; text-transform: uppercase;
  color: #5E1726;
}
.request__lead {
  margin: 8px 0 24px;
  font-family: "Cormorant Garamond", Georgia, serif; font-style: italic; font-weight: 500;
  font-size: 19px; line-height: 1.35; color: #6B5A52;
}
.request__done .request__lead { margin-bottom: 0; }

.request__field { display: block; margin-bottom: 16px; }
.request__label {
  display: block; margin-bottom: 6px;
  font-size: 12px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: #5c5450;
}
.request__label small { font-size: inherit; letter-spacing: 0.04em; text-transform: none; color: #8a7a70; }
.request__label b { color: #5E1726; font-weight: 500; }
.request__field input {
  box-sizing: border-box; width: 100%;
  padding: 13px 16px;
  border: 1px solid rgb(94 23 38 / 0.25); border-radius: 4px;
  background: #fff;
  font: 16px "Manrope", sans-serif; color: #241d1a;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.request__field input::placeholder { color: #b3a79e; }
.request__field input:focus { outline: none; border-color: #5E1726; box-shadow: 0 0 0 3px rgb(94 23 38 / 0.12); }
.request__error { display: none; margin-top: 6px; font-size: 13px; color: #a1263c; }
.request__field.is-bad input { border-color: #a1263c; }
.request__field.is-bad .request__error { display: block; }

.request__submit {
  width: 100%; margin-top: 8px;
  padding: 17px 24px;
  border: 0; border-radius: 999px;
  background: #5E1726; color: #F3ECE2;
  font: 500 14px "Manrope", sans-serif; letter-spacing: 0.14em; text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s, transform 0.3s;
}
.request__submit:hover, .request__submit:focus-visible { background: #4A1120; transform: translateY(-1px); }
.request__submit:focus-visible { outline: 1px solid #5E1726; outline-offset: 4px; }
.request__fail { margin: 12px 0 0; font-size: 13px; line-height: 1.5; text-align: center; color: #a1263c; }
.request__fail a { color: inherit; }
.request__submit:disabled { opacity: 0.7; cursor: default; transform: none; }
.request__trap { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

@media (prefers-reduced-motion: reduce) { .request[open] { animation: none; } }

/* ---------- Что я делаю ---------- */

.services {
  position: relative;
  z-index: 1;                                   /* наезжает на первый экран */
  background: #f4efe8;
  color: #241d1a;
  box-shadow: 0 -24px 60px rgb(0 0 0 / 0.22);
  padding: clamp(72px, 9vw, 140px) clamp(16px, 4vw, 64px);
}
@media (min-width: 761px) {
  .services { padding-bottom: clamp(36px, 4.5vw, 70px); }   /* вдвое меньше — вместе с отступом над «Кейсами» */
}

.services__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: clamp(32px, 5vw, 96px);
  max-width: 1440px;
  margin: 0 auto;
}

.services__title {
  margin: 0;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: clamp(40px, 5vw, 84px);
  line-height: 0.95;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* заголовок с подзаголовком стоят на месте, пока прокручивается список */
/* «Что я делаю» — стопка папок (см. .folders ниже), остаётся на месте, пока листаешь услуги */
.services__head {
  align-self: start;
  position: sticky;
  top: 48px;
}

.services__lead {
  margin: 24px 0 0;
  max-width: 22ch;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 300;
  font-size: clamp(22px, 1.9vw, 32px);
  line-height: 1.2;
  color: #5c5450;
}

.services__list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-bottom: 1px solid #4c121e;   /* бордовый, как стена на первом экране */
}

.services__item {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr) minmax(0, 1.25fr);
  gap: 8px 32px;
  align-items: start;   /* название, номер и описание начинаются на одной высоте */
  padding: clamp(24px, 2.6vw, 40px) 0;
  border-top: 1px solid #4c121e;
  transition:
    opacity 0.7s ease var(--delay, 0s),
    transform 0.8s cubic-bezier(.2, .8, .2, 1) var(--delay, 0s);
}
/* 3. Строки услуг появляются по очереди при скролле */
.js-anim .services__item:not(.is-in) { opacity: 0; transform: translateY(28px); }

.services__num {
  font-family: "Oranienbaum", Georgia, serif;
  font-size: 18px;
  letter-spacing: 0.08em;
  color: #a9805f;
  transition: color 0.3s;
}
/* …а при наведении номер становится бордовым */
.services__item:hover .services__num { color: #6b1f28; }

@media (prefers-reduced-motion: reduce) {
  .services__item { transition: none; }
  .js-anim .services__item:not(.is-in) { opacity: 1; transform: none; }
}

.services__name {
  margin: 0;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: clamp(22px, 2vw, 32px);
  line-height: 1.1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #4c121e;   /* бордовый, как стена на первом экране */
}

.services__text {
  margin: -0.2em 0 0;   /* компенсирует межстрочный отступ: верх букв на одной линии с названием */
  font-size: clamp(15px, 1.1vw, 18px);
  line-height: 1.55;
  color: #5c5450;
}

/* Кнопка-заголовок аккордеона: на десктопе выглядит и ведёт себя как обычный текст */
.services__toggle {
  all: unset;
  display: block;
}

/* ---------- Кейсы: сетка 2 колонки ---------- */

.cases {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  --gap: clamp(24px, 2.2vw, 32px);
  gap: var(--gap);                   /* светлые поля между карточками — каждая работа «в рамке» */
  padding: 0 clamp(16px, 4vw, 64px) var(--gap);  /* боковые поля как у «Что я делаю» — края блоков на одной линии */
  background: #f4efe8;
}

/* ---------- «Что я делаю»: стопка папок (вариант A из папка-что-я-делаю/index.html) ---------- */
.services__head .folders{--burg:#5E1726;        /* бордовый папок */
  --burg-deep:#4A1120;
  --cream:#F1E8DA;       /* молочная бумага */
  --cream-deep:#E4D6C1;
  --champ:#E3C9A0;       /* шампань */
  --ink:#2A1A1C;         /* тёмный текст */
  --page:#F3ECE2;        /* фон секции */

  /* фактура бумаги: мелкое зерно + крупные пятна, как у крафтового картона */
  --grain:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .22 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  --mottle:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='600' height='600'><filter id='m'><feTurbulence type='fractalNoise' baseFrequency='.012' numOctaves='4' seed='7' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .55 -.12'/></filter><rect width='100%' height='100%' filter='url(%23m)'/></svg>");
  --grain-soft:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .35  0 0 0 0 .25  0 0 0 0 .15  0 0 0 .13 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  --mottle-soft:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='600' height='600'><filter id='m'><feTurbulence type='fractalNoise' baseFrequency='.008' numOctaves='3' seed='11' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .55  0 0 0 0 .42  0 0 0 0 .3  0 0 0 .22 -.06'/></filter><rect width='100%' height='100%' filter='url(%23m)'/></svg>");
  --specks:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='260' height='260'><filter id='s'><feTurbulence type='fractalNoise' baseFrequency='.55' numOctaves='1' seed='5' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 .9  0 0 0 0 .85  0 0 0 9 -7.6'/></filter><rect width='100%' height='100%' filter='url(%23s)'/></svg>");
}
/* ============ стопка папок ============ */
.services__head .folders{position:relative;width:min(100%,720px);container-type:inline-size}   /* высоту задаёт передняя папка по своему тексту */

.services__head .folder{position:absolute;left:0;right:0;bottom:0;
  filter:drop-shadow(0 -3px 6px rgba(42,10,18,.22)) drop-shadow(0 -1px 1px rgba(42,10,18,.15))}
.services__head .folder .tab,.services__head .folder .body{position:absolute;background-color:var(--c);
  background-image:var(--tex);background-blend-mode:var(--blend);background-size:260px,240px,600px}
.services__head .folder .tab{top:0;height:7cqw;width:max-content;min-width:32%;border-radius:2.2cqw 2.6cqw 0 0;display:flex;align-items:center;padding:0 3.4cqw}
.services__head .folder .tab::after{content:"";position:absolute;bottom:0;width:2cqw;height:2cqw;
  background:radial-gradient(circle at var(--fx) 0,transparent 1.95cqw,var(--c) 2cqw)}
.services__head .folder.left .tab{left:0}
.services__head .folder.left .tab::after{right:-1.98cqw;--fx:100%}
.services__head .folder.right .tab{right:0;justify-content:flex-end}
.services__head .folder.right .tab::after{left:-1.98cqw;--fx:0%}
.services__head .folder .body{top:calc(7cqw - 1px);left:0;right:0;bottom:0;border-radius:2.2cqw}
.services__head .folder.left .body{border-top-left-radius:0}
.services__head .folder.right .body{border-top-right-radius:0}
/* лёгкий блик по верхней кромке */
.services__head .folder .body::before{content:"";position:absolute;inset:0;border-radius:inherit;
  background:linear-gradient(to bottom,rgba(255,255,255,.10),transparent 3cqw)}

.services__head .burg{--c:var(--burg);--tex:var(--specks),var(--grain),var(--mottle);--blend:screen,multiply,soft-light}
.services__head .cream{--c:var(--cream);--tex:var(--specks),var(--grain-soft),var(--mottle-soft);--blend:normal,multiply,multiply}
.services__head .cream .tab,.services__head .cream .body{background-image:var(--grain-soft),var(--mottle-soft);background-size:240px,600px}
.services__head .label{font-family:'Cormorant Garamond',serif;font-style:italic;font-weight:500;font-size:max(14px,4.3cqw);line-height:1;white-space:nowrap;letter-spacing:.01em}
.services__head .burg .label{color:var(--champ)}
.services__head .cream .label{color:var(--burg)}

.services__head .f1{top:0}
.services__head .f2{top:14cqw}
/* передняя папка стоит в потоке: её высота = текст + одинаковые отступы сверху и снизу */
.services__head .f3{position:relative;top:auto;left:auto;right:auto;bottom:auto;margin-top:29cqw;padding-top:calc(7cqw - 1px)}
.services__head .f3 .body{position:relative;top:auto}

/* передняя папка: заголовок */
.services__head .f3 .body{display:flex;flex-direction:column;justify-content:center;padding:8cqw 6cqw}
.services__head .f3 h2{font-family:'Oranienbaum',serif;font-weight:400;font-size:8cqw;letter-spacing:.06em;line-height:1;color:var(--cream)}
.services__head .f3 p{margin-top:2cqw;font-size:3.6cqw;line-height:1.3;color:var(--champ)}

/* ============ полароиды ============ */
.services__head .photo{position:absolute;display:block;background:#FBF7F0;padding:1cqw 1cqw 3.8cqw;
  box-shadow:0 1.6cqw 3cqw rgba(42,10,18,.28),0 .3cqw .6cqw rgba(42,10,18,.2);
  transform:rotate(var(--r));transition:transform .45s cubic-bezier(.2,.8,.2,1),box-shadow .45s}
.services__head .photo img{display:block;width:100%;aspect-ratio:16/10;object-fit:cover;object-position:top}
.services__head .photo::before{content:"";position:absolute;inset:0;background-image:var(--grain);opacity:.35;mix-blend-mode:multiply;pointer-events:none}
.services__head .photo figcaption{position:absolute;left:0;right:0;bottom:.8cqw;text-align:center;
  font-family:'Cormorant Garamond',serif;font-style:italic;font-weight:500;font-size:2.3cqw;color:var(--burg)}
.services__head .photo:hover{transform:rotate(calc(var(--r) * .4)) translateY(-1.6cqw) scale(1.02);
  box-shadow:0 3cqw 5cqw rgba(42,10,18,.32),0 .4cqw .8cqw rgba(42,10,18,.2)}
.services__head .clip{position:absolute;top:-3.2cqw;width:2.6cqw;height:7.4cqw;filter:drop-shadow(0 .3cqw .3cqw rgba(0,0,0,.3))}
.services__head .p1{--r:-3deg;left:36%;top:2.4cqw;width:30cqw}
.services__head .p1 .clip{right:14%}
.services__head .p2{--r:2.5deg;right:9%;top:21.6cqw;width:30cqw}
.services__head .p2 .clip{left:12%}

.services__head .spark{position:absolute;right:5%;bottom:9%;width:3.6cqw;fill:var(--champ);opacity:.9}

/* ============ анимация стопки (прежняя) ============
   1. Пока блок не виден, листы спрятаны за передней папкой. Когда видно 40% стопки, поднимаются по очереди:
      «Лендинги» → фото «Францевна» → «Корпоративные сайты» → вкладка «Интернет-магазины» → фото отеля
      (оно по пути доворачивается от 0° до своего наклона). 1.4 с на лист, шаг 0.22 с, срабатывает один раз.
   2. После появления: наведение на лист поднимает его на 14px с наклоном −1.5°. */
.services__head .f1{--i:0}
.services__head .p1{--i:.5}
.services__head .f2{--i:1}
.services__head .f3 .tab{--i:2}
.services__head .p2{--i:3}
.services__head .folders :is(.f1,.f2,.photo,.f3 .tab){
  --d:calc(var(--i,0) * .22s);
  transform-origin:50% 100%;
  transition:
    translate 1.4s cubic-bezier(.2,.8,.2,1) var(--d),
    rotate 1.4s cubic-bezier(.2,.8,.2,1) var(--d),
    opacity .9s ease var(--d),
    transform .35s cubic-bezier(.2,.8,.2,1),
    box-shadow .45s}
.js-anim .services__head .folders:not(.is-in) :is(.f1,.f2,.photo){translate:0 32cqw;opacity:0}
.js-anim .services__head .folders:not(.is-in) .f3 .tab{translate:0 110%}
.js-anim .services__head .folders:not(.is-in) .p2{rotate:calc(var(--r) * -1)}   /* итог 0°, потом до своего наклона */
/* пока листы «внутри», всё ниже передней стенки обрезается, чтобы ничего не торчало снизу */
.js-anim .services__head .folders:not(.is-done){clip-path:inset(-60% -60% 0 -60%)}
/* наведение — только после появления */
/* все три папки при наведении поднимаются на 14px и слегка наклоняются */
.services__head .f3{transform-origin:50% 100%;transition:transform .35s cubic-bezier(.2,.8,.2,1)}
.services__head .folders.is-done :is(.f1,.f2,.f3):hover{transform:translateY(-14px) rotate(-1.5deg)}
.services__head .folders:not(.is-done) .photo:hover{transform:rotate(var(--r));box-shadow:0 1.6cqw 3cqw rgba(42,10,18,.28),0 .3cqw .6cqw rgba(42,10,18,.2)}
@media (prefers-reduced-motion:reduce){
  .services__head .folders *{transition:none!important;translate:none!important;rotate:none!important;opacity:1!important}
  .js-anim .services__head .folders:not(.is-done){clip-path:none}
}
/* заголовок и подпись на передней папке — размеры из компонента, поверх общих стилей блока */
.services__head .f3 .services__title{text-transform:uppercase;font-size:clamp(32px,12cqw,84px)}   /* как было раньше */
.services__head .f3 .services__lead{max-width:none;font-weight:400;font-size:clamp(17px,5cqw,32px)}

/* ---------- Заголовок «Кейсы»: рваный лист крафтовой бумаги с бордовым зажимом ---------- */
.cases__head {
  grid-column: 1 / -1;
  padding: clamp(32px, 4vw, 60px) 0 clamp(32px, 3vw, 48px);   /* вдвое меньше — «Кейсы» ближе к «Что я делаю» */
}
.paper {
  position: relative;
  width: min(460px, 100%);
  margin: 0 auto;
  container-type: inline-size;
}
.paper__img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 10px 16px rgb(60 14 24 / 0.16)) drop-shadow(0 1px 2px rgb(60 14 24 / 0.12));
}
.paper__clip {
  position: absolute;
  left: 8.6%;
  top: 1.8%;
  width: 23.2%;
  height: auto;
  filter: drop-shadow(0 3px 3px rgb(40 10 16 / 0.35)) drop-shadow(0 1px 1px rgb(40 10 16 / 0.3));
}
.paper__text {
  position: absolute;
  left: 50%;
  top: 64%;           /* центр самого листа (над ним — зажим) */
  translate: -50% -50%;
  width: 84%;
  text-align: center;
}
.cases__title {
  margin: 0;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: clamp(42px, 3.48vw, 54px);   /* как «Что я делаю» */
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #f3ece2;   /* светлый на бордовом листе */
}
.paper__lead {
  margin: clamp(6px, 1.8cqw, 14px) 0 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-style: italic;
  font-weight: 500;
  font-size: clamp(18px, 1.45vw, 22.4px);   /* как подпись «Что я делаю» */
  line-height: 1.25;
  color: #e3c9a0;   /* шампань */
}
/* появление: лист плавно опускается и выпрямляется, затем проявляется надпись */
.js-anim .paper { opacity: 0; transform: translateY(-24px) rotate(2deg); transition: opacity .6s ease, transform 1s cubic-bezier(.2,.8,.2,1); }
.js-anim .paper .paper__text { opacity: 0; transition: opacity .7s ease .5s; }
.js-anim .paper.is-in { opacity: 1; transform: none; }
.js-anim .paper.is-in .paper__text { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .js-anim .paper, .js-anim .paper .paper__text { opacity: 1; transform: none; transition: none; }
}



.case {
  aspect-ratio: 1 / 0.96;
  display: grid;
  place-items: center;
  padding: 6%;
  color: var(--accent);   /* цвет заголовка */
}

/* Фон каждой карточки — в стиле своего сайта.
   --accent — заголовок, --desc — описание, --more — «Смотреть проект» */

/* Татьяна Францевна: детская комната — гирлянда, пол, коврик, кубики, растение */
.case--frantsevna {
  --accent: #87384e;
  background: #f8f1e6 url("assets/case-bg/frantsevna.svg") center bottom / cover no-repeat;
}

/* Фокус: тёмно-синий чертёж — сетка, схемы, жёлтые ромбы, как в блоке «Наши услуги» */
.case--fokus {
  --accent: #f2f5fa;
  --desc: rgb(214 225 240 / 0.72);
  --more: #f5b800;
  background: #0c1a2e url("assets/case-bg/fokus.svg") center / cover no-repeat;
}

/* Palácio: бордовый тиснёный дамаск с сайта, золотая рамка, конверт с сургучной печатью */
.case--palacio {
  --accent: #f3e6cc;
  --desc: rgb(243 230 204 / 0.72);
  --more: #d9b878;
  background:
    url("assets/case-bg/palacio.svg") center / cover no-repeat,
    url("assets/case-bg/palacio-damask.jpg") center top / auto 105% repeat-x,   /* тиснёный дамаск с сайта; по высоте на всю карточку — без шва */
    #5c1a22;
}

/* клапан конверта с сургучной печатью — отдельным элементом, чтобы печать была чёткой */
.case--palacio { position: relative; overflow: hidden; }
.case__envelope {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: clamp(64px, 12.7%, 110px);
  pointer-events: none;
}
.case__envelope svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
  filter: drop-shadow(0 -3px 6px rgb(26 4 7 / 0.5));
}
.case__envelope img {
  position: absolute;
  left: 50%;
  top: 57%;
  width: 46px;
  height: auto;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 3px 3px rgb(26 4 7 / 0.55));
}

/* Gurada: фото металлопроката с сайта, затемнённое, в холодных стальных тонах — без красного */
.case--gurada {
  --accent: #f4f5f7;
  --desc: rgb(222 226 232 / 0.72);
  --more: #cfd5dd;
  --play-color: #e9ecf0;   /* серебристый значок ▶ */
  background:
    radial-gradient(60% 55% at 50% 45%, rgb(9 10 12 / 0.55), transparent 100%),   /* темнее под текстом */
    linear-gradient(rgb(9 10 12 / 0.62), rgb(9 10 12 / 0.78)),
    url("assets/case-bg/gurada-metal.jpg") center / cover no-repeat,
    #0b0c0e;
}

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

.case__card {
  position: relative;
  display: block;
  width: 82%;   /* видео крупнее (было 74%) */
}

.case__card:hover .case__media {
  transform: translateY(-6px);
  box-shadow: 0 40px 70px -30px rgb(0 0 0 / 0.45);
}

.case__media {
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #000;
  box-shadow: 0 30px 60px -30px rgb(0 0 0 / 0.35);
  transition: transform 0.5s cubic-bezier(.2,.7,.2,1), box-shadow 0.5s;
}

.case__media img,
.case__media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}

.case__caption {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 0 28px;
  text-align: center;
}

.case__title {
  margin: 0 0 14px;
  font-family: "Oranienbaum", Georgia, serif;
  font-weight: 400;
  font-size: clamp(22px, 2.6vw, 52px);
  line-height: 1;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.case__more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--more, inherit);
  text-decoration: none;
}
/* вся карточка ведёт на сайт: ссылка «Смотреть проект» растянута на всю карточку */
.case__more::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}
.case__more:focus-visible { outline: none; }
.case__more:focus-visible::after { outline: 2px solid currentColor; outline-offset: 8px; }

/* левые кейсы: под картинкой кнопка «Смотреть видео» + «Смотреть проект» в одну строку */
.case--clickplay .case__media { position: relative; z-index: 2; }   /* клик по видео — пауза, а не переход */
/* курсор над видео — глаз (см. [data-eye]); клик по видео открывает сайт, видео включается кнопкой */

.case__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 10px 28px;
  margin-top: 18px;
}
.case__actions .case__more { margin-top: 0; }

/* кнопка ▶/❚❚ — «печать»: бордовая у первых двух кейсов, светлая у третьего и четвёртого */
.case__play {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  filter: drop-shadow(0 4px 6px rgb(30 6 12 / 0.25));
  transition: transform 0.3s cubic-bezier(.2,.8,.2,1);
}
.case__play:hover { transform: rotate(-8deg) scale(1.06); }
.case__play-ico { grid-area: 1 / 1; width: 100%; height: 100%; }
.case__play-ico--pause { display: none; }
.is-playing .case__play-ico--play { display: none; }
.is-playing .case__play-ico--pause { display: block; }
.case__play:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 50%; }
.case__more svg {
  width: 24px;
  height: 12px;
  transition: transform 0.35s cubic-bezier(.2,.7,.2,1);
}
.case__card:hover .case__more svg,
.case__card:focus-visible .case__more svg { transform: translateX(6px); }

.case__desc {
  margin: 0;
  font-size: clamp(14px, 1.15vw, 19px);
  line-height: 1.4;
  color: var(--desc, color-mix(in srgb, var(--accent) 35%, #4a4440));
}

/* ============ Курсор-глаз ============ */
/* на карточках с курсором обычная стрелка скрыта (только у мыши, не на телефоне) */
@media (hover:hover) and (pointer:fine){
  [data-eye]{cursor:none}
  [data-eye] :is(.case__play, a){cursor:pointer}   /* над ▶ и «Смотреть проект» — обычный курсор */
}
/* на компьютере сайт открывается кликом по карточке, поэтому «Смотреть проект» под карточками не нужен */
@media (hover:hover) and (pointer:fine) and (min-width:761px){
  .case .case__more{display:none}
}
.eye-cursor{
  position:fixed;left:0;top:0;width:104px;height:104px;margin:-52px 0 0 -52px;
  pointer-events:none;z-index:9999;
  transform:translate3d(var(--x,-200px),var(--y,-200px),0) scale(0);
  transition:transform .35s cubic-bezier(.2,.8,.2,1);
}
.eye-cursor.is-on{transform:translate3d(var(--x),var(--y),0) scale(1)}
.eye-cursor .spin{animation:eye-sp 9s linear infinite;transform-origin:52px 52px}
.eye-cursor .blink-eye{animation:eye-bl 3.6s infinite;transform-origin:48px 33px}
@keyframes eye-sp{to{transform:rotate(360deg)}}
@keyframes eye-bl{0%,92%,100%{transform:scaleY(1)}95%{transform:scaleY(.08)}}
@media (prefers-reduced-motion:reduce){.eye-cursor .spin,.eye-cursor .blink-eye{animation:none}}

/* ---------- Мобильная версия ---------- */

@media (max-width: 760px) {
  .services__inner { grid-template-columns: 1fr; }
  /* на iPhone между «Что я делаю» и «Кейсы» просвечивал бордовый первый экран тонкой линией — перекрываем шов */
  .services { margin-bottom: -1px; padding-bottom: 36px; }
  .services__head { position: static; }
  .folders { margin-inline: auto; }
  .cases__head { padding: 28px 0 32px; }   /* отступ от пункта 06 до «Кейсов» — вдвое меньше */
  .services__item { grid-template-columns: 40px minmax(0, 1fr); }
  /* «Что я делаю» — аккордеон: видны только заголовки, описание раскрывается по нажатию */
  .services__item { padding: 18px 0; cursor: pointer; -webkit-tap-highlight-color: transparent; align-items: center; row-gap: 0; }
  .services__toggle {
    position: relative;
    width: 100%;
    box-sizing: border-box;
    padding-right: 36px;
    cursor: pointer;
  }
  .services__toggle:focus-visible { outline: 1px solid #4c121e; outline-offset: 6px; }
  /* плюс справа, при раскрытии поворачивается в крестик */
  .services__toggle::before,
  .services__toggle::after {
    content: "";
    position: absolute;
    right: 4px;
    top: 50%;
    width: 14px;
    height: 1.5px;
    background: #a9805f;
    transition: transform .4s cubic-bezier(.2, .8, .2, 1), background .3s;
  }
  .services__toggle::after { transform: rotate(90deg); }
  .services__item.is-open .services__toggle::before { transform: rotate(45deg); background: #6b1f28; }
  .services__item.is-open .services__toggle::after  { transform: rotate(135deg); background: #6b1f28; }
  .services__item.is-open .services__num { color: #6b1f28; }
  .services__body {
    grid-column: 2;
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows .45s cubic-bezier(.2, .8, .2, 1);
  }
  .services__body > .services__text { min-height: 0; overflow: hidden; margin: 0; padding-top: 0; transition: padding-top .45s cubic-bezier(.2, .8, .2, 1); }
  .services__item.is-open .services__body { grid-template-rows: 1fr; }
  .services__item.is-open .services__body > .services__text { padding-top: 10px; }

  /* Первый экран на телефоне — фото на весь экран, как на десктопе; текст поверх */
  .hero {
    --name-top: 12svh;   /* фамилия уходит за голову, как на десктопе (было 16svh) */
    --name-size: 17.6vw;   /* «Дубровская» почти на всю ширину экрана */
    --front-top: 61svh;   /* «Дарья» лежит на сиденье и бедре, кисть руки остаётся открытой */
  }
  .nav { font-size: 11px; gap: 12px; }
  .nav__menu { gap: 16px; }

  .hero__stage { height: 100svh; min-height: 560px; }
  .hero__layer { object-position: 30% 100%; }   /* узкое фото: так фигура встаёт по центру экрана */
  .hero__role {
    top: calc(var(--name-top) + var(--name-size) * 0.8 + 14px);   /* левый край — по букве «Д», как на десктопе */
    font-family: "Manrope", sans-serif;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.32em;
    color: #f3ece2;   /* светлый, как на десктопе */
    text-shadow: 0 1px 8px rgb(40 8 16 / 0.6);  /* мягкая тень, чтобы буквы отделялись от фона */
  }
  /* Фигура приподнята на --lift: под ногами остаётся полоса пола, на ней по центру стоит кнопка */
  .hero { --lift: 56px; }   /* туфли — над кнопкой, кончики ножек табурета уходят за неё */
  .hero__stage { background: linear-gradient(to top, #8b7c71 calc(var(--lift) + 8px), transparent calc(var(--lift) + 8px)); }
  .hero__layer { inset: auto 0 var(--lift); }
  .hero__layer--bg {   /* нижний край фото мягко растворяется в цвете пола */
    -webkit-mask-image: linear-gradient(to top, transparent, #000 8px);
            mask-image: linear-gradient(to top, transparent, #000 8px);
  }
  .hero__side {
    top: auto;
    bottom: max(24px, calc(env(safe-area-inset-bottom) + 12px));
    left: 50%;
    transform: translateX(-50%);
  }
  .hero__side .hero__cta,
  .float-cta .hero__cta {   /* на ~12% меньше десктопной, чтобы не спорить с именем; плавающая — такая же */
    --core: 46px;
    --pad: 6px;
    gap: 18px;
    padding-left: 24px;
    font-size: 11.5px;
    white-space: nowrap;
  }
  /* затемнение низа первого экрана: пол уходит в тёмно-бордовый */
  .hero__stage::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 32%;
    z-index: 1;   /* над фоном фото, но под фигурой (2): темнеет только пол, ноги и табурет остаются яркими */
    pointer-events: none;
    background: linear-gradient(to bottom,
      rgb(63 17 25 / 0) 0%,
      rgb(63 17 25 / 0.55) 45%,
      rgb(52 13 21 / 0.8) 100%);
  }
  /* тень кнопки на тёмном фоне делаем мягче */
  .hero .hero__cta { box-shadow: 0 8px 24px rgb(20 4 8 / 0.35); }

  .cases { grid-template-columns: 1fr; row-gap: 44px; }   /* между карточками больше воздуха — каждый кейс отдельной историей */
  /* на телефоне порядок: Францевна, Фокус, Гурада, Palácio */
  .case--gurada { order: 1; }
  .case__play { display: none; }   /* на телефоне видео играют сами */
  .case--palacio { order: 2; }
  .case { aspect-ratio: auto; padding: 48px 16px; }
  .case--frantsevna {
    padding: 100px 16px 140px;   /* место под гирлянду и пол с игрушками */
    background-position: left bottom;   /* узкая карточка обрезает фон по бокам — прижимаем влево, чтобы растение и кубики «А Б В» были целиком */
  }
  .case--palacio { padding: 64px 16px 120px; }  /* место под конверт с печатью */
  .case__card { width: 100%; }
  .case__caption { padding-bottom: 20px; }
  .case__title { font-size: min(6.4vw, 32px); }
}

@media (prefers-reduced-motion: reduce) {
  .services__body, .services__body > .services__text, .services__toggle::before, .services__toggle::after { transition: none; }
}
