/* ============================================================
   Арсений — портфолио веб-разработчика
   Dark editorial · warm graphite + clay accent
   ============================================================ */

/* ─── Шрифты ────────────────────────────────────────────────
   Свои файлы вместо fonts.googleapis.com: тот же рисунок, но
   без лишнего соединения и блокирующего CSS перед первым кадром.
   Каждый файл — вариативный, весь нужный диапазон насыщенности
   в одном запросе. Урезаны до латиницы, кириллицы и знаков со
   страницы (₽, №, тире, кавычки): 42 КБ вместо 290 КБ.
   Пересобрать при смене набора символов — см. README.
   Шрифты под лицензией OFL, текст в assets/fonts/OFL.txt. */
@font-face {
  font-family: 'Unbounded';
  src: url('assets/fonts/unbounded.woff2') format('woff2');
  font-weight: 300 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Manrope';
  src: url('assets/fonts/manrope.woff2') format('woff2');
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'JetBrains Mono';
  src: url('assets/fonts/jetbrains-mono.woff2') format('woff2');
  font-weight: 400 500;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Surfaces — warm off-black, never pure #000 */
  --ink-1000: #080807;
  --ink-950:  #0D0C0A;
  --ink-900:  #121110;
  --ink-850:  #181614;
  --ink-800:  #1F1C18;
  --ink-750:  #292521;

  /* Lines */
  --line:        rgba(240, 232, 220, 0.09);
  --line-soft:   rgba(240, 232, 220, 0.05);
  --line-strong: rgba(240, 232, 220, 0.16);

  /* Text */
  --text:   #F1EDE6;
  --text-2: #A29B90;
  --text-3: #6B655C;

  /* Single accent: warm bone / champagne — monochrome, no chroma glow */
  --accent:      #E3D9C4;
  --accent-hi:   #F1EAD9;
  --accent-dim:  rgba(227, 217, 196, 0.10);
  --accent-line: rgba(227, 217, 196, 0.24);
  --ink-on-accent: #17130E;

  /* Type */
  --font-display: 'Unbounded', 'Manrope', system-ui, sans-serif;
  --font-sans:    'Manrope', system-ui, -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', 'SF Mono', monospace;

  /* Rhythm */
  --wrap: 1240px;
  --gutter: 32px;
  --radius: 4px;
  --radius-lg: 12px;

  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --nav-h: 72px;
}

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

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

body {
  margin: 0;
  background: var(--ink-950);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4 { margin: 0; font-weight: 500; line-height: 1.1; }
p { margin: 0; }
ul, ol, dl, dd, figure { margin: 0; padding: 0; }
li { list-style: none; }
img { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }

::selection { background: var(--accent); color: var(--ink-on-accent); }

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

.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

.skip-link {
  position: fixed; top: -100px; left: 16px; z-index: 200;
  background: var(--accent); color: #fff;
  padding: 10px 16px; border-radius: var(--radius);
  transition: top 200ms var(--ease);
}
.skip-link:focus { top: 16px; }

/* ─── Ambient depth layers ──────────────────────────────── */
.ambient {
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(58vw 48vw at 82% 4%,   rgba(233, 226, 212, 0.045), transparent 60%),
    radial-gradient(50vw 42vw at 6% 58%,    rgba(200, 192, 178, 0.028), transparent 60%),
    radial-gradient(44vw 40vw at 64% 106%,  rgba(233, 226, 212, 0.03), transparent 60%);
  animation: drift 32s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to   { transform: translate3d(-2.2%, 1.6%, 0) scale(1.06); }
}

.grain {
  position: fixed; inset: 0; z-index: 60; pointer-events: none;
  opacity: 0.032;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ─── Layout primitives ─────────────────────────────────── */
.wrap {
  position: relative; z-index: 1;
  width: 100%; max-width: var(--wrap);
  margin: 0 auto; padding: 0 var(--gutter);
}

.section {
  position: relative; z-index: 1;
  padding: 120px 0;
  border-top: 1px solid var(--line-soft);
}
.section--surface { background: var(--ink-900); }

.section-head { max-width: 720px; margin-bottom: 64px; }
.section-head--row {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 48px; max-width: none;
}
.section-head__aside {
  color: var(--text-2); font-size: 15.5px; line-height: 1.6;
  max-width: 30ch; padding-bottom: 6px;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(27px, 3vw, 42px);
  letter-spacing: -0.035em;
  line-height: 1.12;
}

.lede {
  color: var(--text-2);
  font-size: 16.5px;
  line-height: 1.65;
  max-width: 58ch;
  margin-top: 22px;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-mono);
  font-size: 11px; font-weight: 500;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 22px;
}
.eyebrow--center { justify-content: center; }
.eyebrow__dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-dim);
}

/* ─── Buttons ───────────────────────────────────────────── */
.btn {
  --btn-bg: transparent; --btn-fg: var(--text);
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 22px;
  background: var(--btn-bg); color: var(--btn-fg);
  font-family: var(--font-sans); font-size: 14.5px; font-weight: 600;
  letter-spacing: -0.01em;
  border: 1px solid transparent; border-radius: var(--radius);
  transition: background 260ms var(--ease), border-color 260ms var(--ease),
              transform 200ms var(--ease), color 260ms var(--ease);
  white-space: nowrap;
}
.btn__icon { width: 16px; height: 16px; flex: none; transition: transform 320ms var(--ease); }
.btn:hover .btn__icon { transform: translateX(3px); }
.btn:active { transform: scale(0.985) translateY(1px); }

.btn--primary { --btn-bg: var(--accent); --btn-fg: var(--ink-on-accent); box-shadow: 0 12px 34px -20px rgba(0,0,0,0.7); }
.btn--primary:hover { --btn-bg: var(--accent-hi); }

.btn--ghost { border-color: var(--line-strong); --btn-fg: var(--text); }
.btn--ghost:hover { border-color: var(--text-3); background: rgba(240, 232, 220, 0.035); }

.btn--sm { padding: 9px 16px; font-size: 13px; }
.btn--lg { padding: 16px 28px; font-size: 15px; }
.btn--block { width: 100%; justify-content: center; }

/* ─── Nav ───────────────────────────────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 100;
  height: var(--nav-h);
  border-bottom: 1px solid transparent;
  transition: background 300ms var(--ease), border-color 300ms var(--ease), backdrop-filter 300ms var(--ease);
}
.nav.is-stuck {
  background: rgba(13, 12, 10, 0.72);
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border-bottom-color: var(--line);
}
.nav__inner {
  max-width: var(--wrap); height: 100%; margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}

.brand { display: inline-flex; align-items: center; }
.brand__text { font-family: var(--font-display); font-weight: 400; font-size: 16px; letter-spacing: -0.02em; }
.brand__dot { color: var(--accent); }

.nav__links { display: flex; align-items: center; gap: 30px; }
.nav__links a {
  position: relative; font-size: 14px; color: var(--text-2);
  transition: color 220ms var(--ease);
}
.nav__links a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -6px; height: 1px;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  transition: transform 300ms var(--ease);
}
.nav__links a:hover { color: var(--text); }
.nav__links a:hover::after { transform: scaleX(1); }

/* ─── Hero ──────────────────────────────────────────────── */
.hero {
  position: relative;
  padding-top: clamp(48px, 8vw, 96px);
  padding-bottom: 0;
}
.hero__grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: clamp(32px, 5vw, 80px);
  align-items: center;
  padding-bottom: 72px;
}
.hero__text { max-width: 620px; }

.hero__title {
  font-family: var(--font-display);
  font-weight: 300;
  font-size: clamp(34px, 5.2vw, 62px);
  line-height: 1.06;
  letter-spacing: -0.04em;
  margin-bottom: 28px;
}
.hero__accent {
  color: var(--accent-hi);
  font-style: italic;
  font-weight: 300;
}

.hero__lede {
  color: var(--text-2);
  font-size: clamp(16px, 1.5vw, 18.5px);
  line-height: 1.6;
  max-width: 46ch;
  margin-bottom: 40px;
}

.hero__cta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 26px; }

.hero__note {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13.5px; color: var(--text-3);
}
.hero__pulse {
  width: 7px; height: 7px; border-radius: 50%; flex: none;
  background: var(--accent-hi);
  box-shadow: 0 0 0 0 rgba(227, 217, 196, 0.5);
  animation: pulse 2.4s var(--ease) infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(227, 217, 196, 0.45); }
  70%  { box-shadow: 0 0 0 8px rgba(227, 217, 196, 0); }
  100% { box-shadow: 0 0 0 0 rgba(227, 217, 196, 0); }
}

/* Portrait */
.hero__aside { display: flex; justify-content: flex-end; }
.portrait { width: 100%; max-width: 380px; }
.portrait__frame {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background:
    linear-gradient(160deg, var(--ink-850), var(--ink-900));
  box-shadow: 0 40px 80px -40px rgba(0,0,0,0.8);
}
.portrait__frame img {
  position: absolute; inset: 0; z-index: 1;
  width: 100%; height: 100%; object-fit: cover;
  filter: saturate(0.92) contrast(1.02);
}
.portrait__frame img.is-empty { opacity: 0; }
.portrait__placeholder {
  position: absolute; inset: 0; z-index: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px;
  background:
    radial-gradient(70% 60% at 50% 30%, var(--accent-dim), transparent 70%),
    repeating-linear-gradient(135deg, rgba(240,232,220,0.02) 0 2px, transparent 2px 9px);
}
.portrait__hint {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.06em;
  color: var(--text-3);
  padding: 4px 10px; border: 1px solid var(--line); border-radius: 100px;
}
/* Ticker strip */
.hero__ticker {
  display: flex; flex-wrap: wrap; align-items: center; gap: 16px;
  /* только вертикальные поля — горизонтальные приходят из .wrap,
     шорткат padding:22px 0 их обнулял и прижимал текст к краю окна */
  padding-top: 22px; padding-bottom: 22px;
  border-top: 1px solid var(--line-soft);
  font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.04em;
  text-transform: uppercase; color: var(--text-3);
}
.hero__ticker .dot { color: var(--accent); }

/* ─── Pains ─────────────────────────────────────────────── */
.pains__list {
  border-top: 1px solid var(--line);
}
.pain {
  display: grid;
  grid-template-columns: 88px 1fr;
  gap: 24px;
  padding: 34px 0;
  border-bottom: 1px solid var(--line);
  transition: background 300ms var(--ease);
}
.pain:hover { background: linear-gradient(90deg, var(--accent-dim), transparent 60%); }
.pain__num {
  font-size: 15px; color: var(--accent-hi);
  padding-top: 4px;
}
.pain__title {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(19px, 2.1vw, 25px);
  letter-spacing: -0.025em; line-height: 1.2;
  margin-bottom: 12px;
}
.pain__text { color: var(--text-2); font-size: 15.5px; line-height: 1.62; max-width: 60ch; }

/* ─── Works ─────────────────────────────────────────────── */
.works__list { display: flex; flex-direction: column; gap: 28px; }

.work {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
  padding: clamp(24px, 3vw, 40px);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(160deg, rgba(240,232,220,0.018), transparent 70%);
  transition: border-color 340ms var(--ease), transform 340ms var(--ease), background 340ms var(--ease);
}
.work:hover {
  border-color: var(--line-strong);
  transform: translateY(-3px);
  background: linear-gradient(160deg, var(--accent-dim), transparent 60%);
}
.work--reverse .work__preview { order: 2; }

.work__preview { min-width: 0; }
.browser {
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: var(--ink-850);
  box-shadow: 0 30px 60px -34px rgba(0,0,0,0.75);
  transition: transform 400ms var(--ease);
}
.work:hover .browser { transform: translateY(-2px) scale(1.008); }
.browser__bar {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px;
  background: var(--ink-800);
  border-bottom: 1px solid var(--line);
}
.browser__dots { display: inline-flex; gap: 6px; }
.browser__dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--line-strong); }
.browser__url {
  font-size: 11.5px; color: var(--text-3);
  padding: 3px 12px; border-radius: 100px;
  background: var(--ink-950); border: 1px solid var(--line-soft);
}
.browser__shot {
  position: relative;
  aspect-ratio: 16 / 10;
  background-size: cover; background-position: top center;
  display: grid; place-items: center;
}
/* Скриншот лежит поверх градиента-заглушки: не загрузился — заглушка видна */
.browser__shot picture { position: absolute; inset: 0; z-index: 1; }
.browser__shot picture img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
}
.browser__shot picture img.is-empty { display: none; }
.browser__fallback {
  display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center;
  padding: 20px;
}
.browser__fall-title {
  font-family: var(--font-display); font-weight: 300; font-size: 22px;
  letter-spacing: -0.02em; color: var(--text-2);
}
.browser__fall-hint {
  font-size: 11px; color: var(--text-3);
  padding: 4px 10px; border: 1px solid var(--line); border-radius: 100px;
}
/* neutral abstract previews (until real screenshots dropped in) */
.work__shot--tea {
  background:
    radial-gradient(85% 95% at 22% 12%, rgba(233,226,212,0.11), transparent 58%),
    radial-gradient(70% 80% at 90% 94%, rgba(200,192,178,0.05), transparent 60%),
    linear-gradient(160deg, #211d18, #131110);
}
.work__shot--remont {
  background:
    radial-gradient(80% 90% at 86% 10%, rgba(233,226,212,0.085), transparent 58%),
    radial-gradient(65% 75% at 10% 92%, rgba(200,192,178,0.05), transparent 60%),
    linear-gradient(160deg, #1c1c18, #121211);
}
.work__shot--salon {
  background:
    radial-gradient(85% 95% at 50% 8%, rgba(233,226,212,0.10), transparent 58%),
    radial-gradient(60% 70% at 82% 96%, rgba(200,192,178,0.045), transparent 60%),
    linear-gradient(160deg, #1e1a16, #110f0e);
}

.work__info { min-width: 0; }
.work__index { font-size: 12px; color: var(--accent-hi); }
.work__name {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(24px, 2.6vw, 32px);
  letter-spacing: -0.03em;
  margin: 12px 0 14px;
}
.work__desc { color: var(--text-2); font-size: 15px; line-height: 1.6; margin-bottom: 24px; max-width: 44ch; }

.work__spec { display: grid; gap: 12px; padding: 20px 0; border-top: 1px solid var(--line); margin-bottom: 22px; }
.work__spec > div { display: grid; grid-template-columns: 108px 1fr; gap: 16px; align-items: baseline; }
.work__spec dt {
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--text-3);
}
.work__spec dd { font-size: 14px; color: var(--text); }

.work__open {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 600; color: var(--accent-hi);
}
.work__open svg { width: 15px; height: 15px; transition: transform 320ms var(--ease); }
.work:hover .work__open svg { transform: translate(2px, -2px); }

.works__cta { display: flex; justify-content: center; margin-top: 56px; }

/* ─── Pricing ───────────────────────────────────────────── */
.price-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.price {
  display: flex; flex-direction: column;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(170deg, rgba(240,232,220,0.02), transparent 65%);
  transition: border-color 320ms var(--ease), transform 320ms var(--ease);
}
.price:hover { border-color: var(--line-strong); transform: translateY(-3px); }
.price--featured {
  border-color: rgba(227, 217, 196, 0.40);
  background: linear-gradient(170deg, rgba(227, 217, 196, 0.06), transparent 68%);
  box-shadow: 0 24px 60px -40px rgba(0, 0, 0, 0.8);
}
.price__head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.price__name {
  font-family: var(--font-display); font-weight: 300;
  font-size: 22px; letter-spacing: -0.025em;
}
.price__badge {
  font-family: var(--font-mono); font-size: 10px; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--accent-hi);
  padding: 4px 9px; border-radius: 100px;
  background: var(--accent-dim); border: 1px solid var(--accent-line);
}
.price__badge--muted { color: var(--text-3); background: transparent; border-color: var(--line); }
.price__for { color: var(--text-2); font-size: 14px; line-height: 1.55; margin-bottom: 24px; min-height: 44px; }
.price__amount {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(26px, 3vw, 34px); letter-spacing: -0.03em;
  margin-bottom: 4px;
}
.price__term { font-size: 12.5px; color: var(--text-3); margin-bottom: 24px; }
.price__inc {
  display: grid; gap: 11px;
  padding-top: 22px; margin-top: auto;
  border-top: 1px solid var(--line);
}
.price__inc li {
  position: relative; padding-left: 24px;
  font-size: 14px; color: var(--text-2); line-height: 1.5;
}
.price__inc li::before {
  content: ""; position: absolute; left: 0; top: 8px;
  width: 10px; height: 6px;
  border-left: 1.5px solid var(--accent-hi); border-bottom: 1.5px solid var(--accent-hi);
  transform: rotate(-45deg);
}

.pricing__cta {
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  margin-top: 48px; text-align: center;
}

/* ─── Offer / первые кейсы ──────────────────────────────── */
.offer { padding-top: 0; border-top: 0; }

.offer__panel {
  /* Инверсия: светлая карточка на тёмной странице.
     Переопределяем токены локально — потомки перекрашиваются сами. */
  --text:   #17130E;
  --text-2: #4E463B;
  --text-3: #6F6558;
  --line:   rgba(23, 19, 14, 0.16);
  --accent:      #17130E;
  --accent-hi:   #2E271E;
  --accent-dim:  rgba(23, 19, 14, 0.08);
  --ink-on-accent: #F4EEE2;

  display: grid;
  grid-template-columns: 1.4fr 0.6fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
  padding: clamp(28px, 3.4vw, 46px);
  border: 0;
  border-radius: var(--radius-lg);
  color: var(--text);
  background:
    radial-gradient(130% 160% at 100% 0%, rgba(255, 255, 255, 0.5), transparent 60%),
    #E5DCC8;
  box-shadow:
    0 2px 0 rgba(255, 255, 255, 0.35) inset,
    0 40px 80px -40px rgba(0, 0, 0, 0.9);
}

.offer__title {
  display: flex; align-items: baseline; flex-wrap: wrap; gap: 6px 14px;
  margin-bottom: 18px;
}
.offer__new {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(32px, 4.4vw, 50px);
  letter-spacing: -0.04em; line-height: 1;
}
.offer__old { font-size: 15px; color: var(--text-3); font-weight: 400; }
.offer__old s { text-decoration-thickness: 1px; text-underline-offset: 2px; }

.offer__text {
  color: var(--text-2); font-size: 15.5px; line-height: 1.65;
  max-width: 58ch; margin-bottom: 24px;
}

.offer__terms { display: grid; gap: 11px; }
.offer__terms li {
  position: relative; padding-left: 26px;
  font-size: 14.5px; color: var(--text); line-height: 1.5;
}
.offer__terms li::before {
  content: ""; position: absolute; left: 0; top: 8px;
  width: 10px; height: 6px;
  border-left: 1.5px solid var(--accent); border-bottom: 1.5px solid var(--accent);
  transform: rotate(-45deg);
}

.offer__side {
  display: flex; flex-direction: column; gap: 18px;
  padding-left: clamp(0px, 2.4vw, 36px);
  border-left: 1px solid var(--line);
}
.offer__count-label {
  display: block;
  font-family: var(--font-mono); font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--text-3); margin-bottom: 4px;
}
.offer__count-num {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(46px, 5.4vw, 62px); line-height: 1;
  letter-spacing: -0.04em; color: var(--accent);
}
.offer__count-of {
  font-family: var(--font-mono); font-size: 12px;
  color: var(--text-3); margin-left: 8px;
}
.offer__note { font-size: 12.5px; color: var(--text-3); line-height: 1.5; }

/* ─── Process / steps ───────────────────────────────────── */
.steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.step {
  display: grid; grid-template-columns: auto 1fr; gap: 20px;
  padding: 34px;
  background: var(--ink-900);
  transition: background 300ms var(--ease);
}
.step:hover { background: var(--ink-850); }
.step__num {
  font-family: var(--font-display); font-weight: 300;
  font-size: 26px; color: var(--accent-hi); line-height: 1;
}
.step__title {
  font-family: var(--font-display); font-weight: 300;
  font-size: 20px; letter-spacing: -0.02em; margin-bottom: 10px;
}
.step__text { color: var(--text-2); font-size: 14.5px; line-height: 1.6; }

/* ─── About ─────────────────────────────────────────────── */
.about__grid {
  display: grid; grid-template-columns: 0.72fr 1.28fr;
  gap: clamp(32px, 5vw, 72px); align-items: center;
}
.about__photo { max-width: 340px; }
.portrait__frame--sm { aspect-ratio: 5 / 6; box-shadow: 0 30px 60px -36px rgba(0,0,0,0.75); }
.about__lede {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(19px, 2vw, 24px); letter-spacing: -0.02em; line-height: 1.35;
  margin: 22px 0 20px; color: var(--text);
}
.about__body { color: var(--text-2); font-size: 16px; line-height: 1.7; max-width: 54ch; }

/* ─── FAQ ───────────────────────────────────────────────── */
.faq__grid {
  display: grid; grid-template-columns: 0.85fr 1.15fr;
  gap: clamp(40px, 6vw, 96px); align-items: start;
}
.faq__head { position: sticky; top: calc(var(--nav-h) + 40px); }
.faq__list { border-top: 1px solid var(--line); }
.qa { border-bottom: 1px solid var(--line); }
.qa__q {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 26px 4px;
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(17px, 1.9vw, 21px); letter-spacing: -0.02em;
  list-style: none; cursor: pointer;
  transition: color 240ms var(--ease);
}
.qa__q::-webkit-details-marker { display: none; }
.qa__q:hover { color: var(--accent-hi); }
.qa__ico { position: relative; width: 16px; height: 16px; flex: none; }
.qa__ico::before, .qa__ico::after {
  content: ""; position: absolute; top: 50%; left: 50%;
  background: var(--accent-hi); transform: translate(-50%, -50%);
  transition: transform 300ms var(--ease), opacity 300ms var(--ease);
}
.qa__ico::before { width: 14px; height: 1.5px; }
.qa__ico::after  { width: 1.5px; height: 14px; }
.qa[open] .qa__ico::after { transform: translate(-50%, -50%) rotate(90deg); opacity: 0; }
.qa__a {
  overflow: hidden;
  max-height: 0;
  transition: max-height 400ms var(--ease);
}
.qa[open] .qa__a { max-height: 600px; }
.qa__a p {
  padding: 0 4px 28px; color: var(--text-2);
  font-size: 15px; line-height: 1.66; max-width: 60ch;
}

/* ─── Final CTA ─────────────────────────────────────────── */
.final { text-align: center; overflow: hidden; }
.final__inner { max-width: 780px; }
.final__title {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(28px, 4.4vw, 52px);
  letter-spacing: -0.04em; line-height: 1.12;
  margin: 6px 0 24px;
}
.final__sub { color: var(--text-2); font-size: 16.5px; line-height: 1.65; max-width: 52ch; margin: 0 auto 40px; }
.final__cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-bottom: 26px; }
.final__note { justify-content: center; display: inline-flex; }

/* ─── Legal / текстовая страница ────────────────────────── */
.legal { border-top: 0; }
.legal__inner { max-width: 760px; }
.legal__title {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(26px, 4vw, 46px);
  letter-spacing: -0.04em; line-height: 1.1;
  margin-bottom: 24px;
  /* «конфиденциальности» — длинное неразрывное слово, на узких
     экранах переносим по слогам, иначе вылезает за край */
  overflow-wrap: break-word;
  hyphens: auto;
}
.legal__lead {
  color: var(--text); font-size: 17px; line-height: 1.65;
  padding: 22px 24px; margin-bottom: 18px;
  border-left: 2px solid var(--accent-line);
  background: linear-gradient(90deg, var(--accent-dim), transparent 70%);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}
.legal__date { font-size: 12.5px; color: var(--text-3); margin-bottom: 56px; }

.legal h2 {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(19px, 2.2vw, 24px);
  letter-spacing: -0.025em;
  margin: 44px 0 16px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.legal p { color: var(--text-2); font-size: 16px; line-height: 1.72; margin-bottom: 14px; max-width: 68ch; }
/* :not(.btn) — иначе правило перебивает цвет кнопки и она
   становится светлой на светлом фоне */
.legal a:not(.btn) { color: var(--accent-hi); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.legal a:not(.btn):hover { color: var(--text); }

.legal__list { display: grid; gap: 10px; margin: 0 0 16px; max-width: 68ch; }
.legal__list li {
  position: relative; padding-left: 24px;
  color: var(--text-2); font-size: 16px; line-height: 1.65;
}
.legal__list li::before {
  content: ""; position: absolute; left: 2px; top: 11px;
  width: 6px; height: 1px; background: var(--accent);
}
.legal__foot { margin-top: 56px; padding-top: 36px; border-top: 1px solid var(--line); }

@media (max-width: 640px) {
  .legal__lead { font-size: 16px; padding: 18px 18px; }
  .legal p, .legal__list li { font-size: 16px; }
  .legal h2 { margin-top: 36px; }
}

/* ─── Footer ────────────────────────────────────────────── */
.footer { border-top: 1px solid var(--line); padding: 40px 0; }
.footer__inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}
.footer__links { justify-self: center; }
.footer__copy { justify-self: end; text-align: right; }
.brand--footer .brand__text { font-size: 15px; }
.footer__links { display: flex; gap: 24px; flex-wrap: wrap; }
.footer__links a { font-size: 14px; color: var(--text-2); transition: color 220ms var(--ease); }
.footer__links a:hover { color: var(--accent-hi); }
.footer__copy { font-size: 12px; color: var(--text-3); letter-spacing: 0.02em; }

/* ─── Reveal on scroll ──────────────────────────────────── */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 700ms var(--ease), transform 700ms var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }

/* ═══════════════════ RESPONSIVE ═══════════════════════════ */
@media (max-width: 1080px) {
  .hero__grid { grid-template-columns: 1.1fr 0.9fr; }
  .price-list { gap: 16px; }
}

@media (max-width: 900px) {
  .section { padding: 88px 0; }
  .hero__grid { grid-template-columns: 1fr; gap: 44px; }
  /* на узких экранах сначала оффер и кнопка, фото — после,
     во всю ширину колонки: края совпадают с текстом, пустоты справа нет */
  .hero__aside { justify-content: center; }
  .portrait { max-width: none; }
  .portrait__frame { aspect-ratio: 1 / 1; }
  .hero__ticker { justify-content: center; text-align: center; }
  .section-head--row { flex-direction: column; align-items: flex-start; gap: 16px; }
  .section-head__aside { max-width: none; }

  .work, .work--reverse {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .work--reverse .work__preview { order: 0; }

  .offer__panel { grid-template-columns: 1fr; gap: 28px; }
  .offer__side {
    padding-left: 0; border-left: 0;
    border-top: 1px solid var(--line); padding-top: 26px;
  }
  .price-list { grid-template-columns: 1fr; max-width: 480px; }
  .price__for { min-height: 0; }
  .steps { grid-template-columns: 1fr; }
  .about__grid { grid-template-columns: 1fr; gap: 36px; }
  .about__photo { width: min(260px, 100%); max-width: none; justify-self: center; }
  .faq__grid { grid-template-columns: 1fr; gap: 28px; }
  .faq__head { position: static; }

  /* трём колонкам нужно ~730px — ниже складываем в столбик */
  .footer__inner { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .footer__links { justify-self: center; justify-content: center; }
  .footer__copy { justify-self: center; text-align: center; }
}

@media (max-width: 640px) {
  :root { --gutter: 20px; }
  .nav__links { display: none; }
  .section { padding: 72px 0; }
  .section-head { margin-bottom: 44px; }
  .hero { padding-top: 32px; }
  .hero__grid { padding-bottom: 56px; }
  .hero__cta .btn { width: 100%; justify-content: center; }
  .pain { grid-template-columns: 1fr; gap: 8px; padding: 26px 0; }
  .pain__num { padding-top: 0; }
  .work { padding: 18px; }
  .work__spec > div { grid-template-columns: 96px 1fr; gap: 12px; }
  .step { padding: 26px; }
  .final__cta .btn { width: 100%; justify-content: center; }
  .footer__inner { gap: 20px; }

  /* ── Тап-таргеты: минимум 44px по высоте ── */
  .brand { padding: 10px 0; }
  .nav__actions .btn--sm { padding: 12px 18px; }
  .footer__links { gap: 0 22px; flex-wrap: wrap; }
  .footer__links a { padding: 11px 0; }

  /* ── Читаемость: основной текст крупнее, мелкие метки не ниже 11px ── */
  .hero__lede { font-size: 17px; }
  .pain__text,
  .offer__text,
  .qa__a p { font-size: 16px; }
  .about__body { font-size: 16.5px; }
  .work__desc,
  .step__text,
  .price__inc li,
  .price__for { font-size: 15px; }
  .work__spec dd { font-size: 15px; }
  .work__spec dt,
  .offer__count-label { font-size: 11.5px; }
  .price__badge { font-size: 11px; }
  .offer__note { font-size: 13px; }
  .footer__copy { font-size: 12.5px; }
}

/* На телефоне бесконечная анимация фонового слоя во весь экран держит
   отдельный композиторный слой и жжёт батарею ради движения, которого
   на маленьком экране почти не видно. Градиенты остаются, движение — нет. */
@media (max-width: 640px) {
  .ambient { animation: none; will-change: auto; }
}

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