/* Топ-Ремонт — тёмная архитектурная тема.
   Одна тема на всю страницу (без инверсий по секциям), один акцент.
   Радиусы по правилу: кнопки и чипы — пилюля, карточки 20px,
   вложенные ядра и медиа 14px, поля ввода 12px. */

@import url("fonts/fonts.css");
@import url("vendor/ph-light.css");

:root {
  --ink: #0b0b0c;
  --ink-2: #0f0f11;
  --surface: #141416;
  --surface-2: #1a1a1d;
  --line: rgba(241, 239, 233, 0.1);
  --line-2: rgba(241, 239, 233, 0.18);
  --bone: #f1efe9;
  --muted: #9c9a94;
  --muted-2: #6f6d68;
  --accent: #e2613c;
  --accent-hi: #f0774f;
  --accent-soft: rgba(226, 97, 60, 0.14);

  --r-card: 20px;
  --r-core: 14px;
  --r-field: 12px;
  --r-pill: 999px;

  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --shell: 1px solid var(--line);

  --pad: clamp(18px, 4vw, 40px);
  --gap: clamp(20px, 3vw, 36px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: 96px; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--bone);
  font-family: "Onest", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.locked { overflow: hidden; }

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }

::selection { background: var(--accent); color: #fff; }

/* Зерно поверх всего: фиксированный слой, не в потоке прокрутки. */
.grain {
  position: fixed;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  opacity: 0.035;
  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='.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── сетка ─────────────────────────────────────────────── */
.wrap { width: min(1360px, 100% - 2 * var(--pad)); margin-inline: auto; }
.sec { padding-block: clamp(64px, 9vw, 132px); position: relative; }
.sec--tight { padding-block: clamp(48px, 6vw, 88px); }

/* ── типографика ───────────────────────────────────────── */
h1, h2, h3, h4 { margin: 0; font-weight: 500; letter-spacing: -0.03em; line-height: 1.06; }
h1 { font-size: clamp(38px, 5.4vw, 76px); font-weight: 400; }
h2 { font-size: clamp(28px, 3.6vw, 52px); }
h3 { font-size: clamp(20px, 1.9vw, 27px); letter-spacing: -0.02em; line-height: 1.2; }
p { margin: 0; }

.lead { color: var(--muted); font-size: clamp(15px, 1.25vw, 19px); line-height: 1.6; max-width: 62ch; }
.small { font-size: 14px; color: var(--muted); line-height: 1.6; }
.tiny { font-size: 12.5px; color: var(--muted-2); line-height: 1.5; }

.mono {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-variant-numeric: tabular-nums;
}

.eyebrow {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
  display: inline-block;
  margin-bottom: 18px;
}

.hl { color: var(--bone); }
.acc { color: var(--accent); }

/* заголовок секции: вертикальный стек, без правого «плавающего» абзаца.
   Мера в px, а не в ch: ch считается по шрифту самого .head (16px), а не по
   кеглю заголовка внутри — от 26ch колонка выходила в 220px. */
.head { max-width: min(100%, 720px); }
.head p { margin-top: 20px; max-width: 58ch; }
.head--wide { max-width: min(100%, 900px); }

/* ── кнопки ────────────────────────────────────────────── */
.btn {
  --bg: var(--accent);
  --fg: #fff;
  display: inline-flex;
  align-items: center;
  gap: 14px;
  padding: 13px 14px 13px 26px;
  border: 0;
  border-radius: var(--r-pill);
  background: var(--bg);
  color: var(--fg);
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 0.5s var(--ease), background 0.4s var(--ease), box-shadow 0.5s var(--ease);
  box-shadow: 0 10px 30px rgba(226, 97, 60, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.btn i {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, 0.16);
  font-size: 15px;
  transition: transform 0.5s var(--ease);
}
.btn:hover { background: var(--accent-hi); transform: translateY(-2px); }
.btn:hover i { transform: translateX(3px); }
.btn:active { transform: scale(0.985); }

.btn--ghost {
  --bg: transparent;
  --fg: var(--bone);
  border: var(--shell);
  box-shadow: none;
  backdrop-filter: none;
}
.btn--ghost i { background: rgba(241, 239, 233, 0.1); }
.btn--ghost:hover { background: rgba(241, 239, 233, 0.07); border-color: var(--line-2); }

.btn--bone { --bg: var(--bone); --fg: #121212; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4); }
.btn--bone i { background: rgba(0, 0, 0, 0.1); }
.btn--bone:hover { background: #fff; }

.btn--sm { padding: 10px 11px 10px 20px; font-size: 14px; }
.btn--sm i { width: 26px; height: 26px; font-size: 13px; }

.btn--wide { width: 100%; justify-content: space-between; }

.link-u {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  border-bottom: 1px solid var(--line-2);
  padding-bottom: 3px;
  transition: color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.link-u:hover { color: var(--bone); border-color: var(--accent); }

/* ── шапка ─────────────────────────────────────────────── */
.nav {
  position: fixed;
  z-index: 40;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  width: min(1360px, 100% - 2 * var(--pad));
  height: 66px;
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 0 10px 0 22px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(241, 239, 233, 0.09);
  background: rgba(13, 13, 14, 0.66);
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: height 0.5s var(--ease), background 0.5s var(--ease);
}
.nav.shrunk { height: 58px; background: rgba(13, 13, 14, 0.86); }

.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.brand img { height: 34px; width: auto; }
.brand b { font-size: 16px; font-weight: 600; letter-spacing: -0.02em; }
.brand span { display: block; font-size: 10px; color: var(--muted-2); letter-spacing: 0.04em; }

.nav-links { display: flex; gap: 4px; margin-left: auto; }
.nav-links a {
  padding: 8px 13px;
  border-radius: var(--r-pill);
  font-size: 14px;
  color: var(--muted);
  transition: color 0.35s var(--ease), background 0.35s var(--ease);
}
.nav-links a:hover { color: var(--bone); background: rgba(241, 239, 233, 0.07); }

.nav-phone { display: flex; flex-direction: column; line-height: 1.15; margin-left: 8px; }
.nav-phone b { font-size: 15px; font-weight: 500; letter-spacing: -0.01em; }
.nav-phone span { font-size: 10.5px; color: var(--muted-2); }

.burger {
  display: none;
  width: 44px;
  height: 44px;
  border: var(--shell);
  border-radius: var(--r-pill);
  background: transparent;
  position: relative;
  cursor: pointer;
  flex-shrink: 0;
}
.burger i {
  position: absolute;
  left: 13px;
  width: 18px;
  height: 1.5px;
  background: var(--bone);
  transition: transform 0.55s var(--ease), opacity 0.3s var(--ease);
}
.burger i:nth-child(1) { top: 18px; }
.burger i:nth-child(2) { top: 24px; }
.burger i:nth-child(3) { top: 30px; }
.burger.on i:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger.on i:nth-child(2) { opacity: 0; }
.burger.on i:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

.sheet {
  position: fixed;
  inset: 0;
  z-index: 39;
  background: rgba(9, 9, 10, 0.88);
  backdrop-filter: blur(26px);
  -webkit-backdrop-filter: blur(26px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  padding: 96px var(--pad) 40px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s var(--ease), visibility 0.5s;
}
.sheet.on { opacity: 1; visibility: visible; }
.sheet a {
  font-size: clamp(26px, 7vw, 40px);
  letter-spacing: -0.035em;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}
.sheet.on a { opacity: 1; transform: none; }
.sheet.on a:nth-child(1) { transition-delay: 0.06s; }
.sheet.on a:nth-child(2) { transition-delay: 0.11s; }
.sheet.on a:nth-child(3) { transition-delay: 0.16s; }
.sheet.on a:nth-child(4) { transition-delay: 0.21s; }
.sheet.on a:nth-child(5) { transition-delay: 0.26s; }
.sheet.on a:nth-child(6) { transition-delay: 0.31s; }
.sheet.on a:nth-child(7) { transition-delay: 0.36s; }
.sheet .sheet-cta { margin-top: 28px; border: 0; opacity: 0; transform: translateY(28px); }
.sheet.on .sheet-cta { opacity: 1; transform: none; transition-delay: 0.42s; }

/* ── герой ─────────────────────────────────────────────── */
.hero { padding-top: 108px; position: relative; }
.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: clamp(24px, 3vw, 56px);
  align-items: end;
}
.hero-copy { padding-bottom: clamp(8px, 2vw, 30px); }
.hero h1 { margin-bottom: 26px; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lead { max-width: 46ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

.hero-media {
  position: relative;
  border-radius: var(--r-card);
  border: var(--shell);
  padding: 6px;
  background: rgba(241, 239, 233, 0.035);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.hero-media img {
  border-radius: var(--r-core);
  width: 100%;
  height: clamp(300px, 46vw, 560px);
  object-fit: cover;
}
.hero-badge {
  position: absolute;
  left: 22px;
  bottom: 22px;
  right: 22px;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border-radius: var(--r-core);
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(12, 12, 13, 0.6);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.hero-badge .score { font-size: 30px; font-weight: 500; letter-spacing: -0.04em; }
.hero-badge .stars { color: var(--accent); font-size: 13px; letter-spacing: 2px; }

/* полоса выгод под героем */
.hero-strip {
  margin-top: clamp(26px, 3vw, 44px);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
}
.hero-strip div {
  padding: 22px 22px 0 0;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 14.5px;
  color: var(--muted);
  line-height: 1.45;
}
.hero-strip i { color: var(--accent); font-size: 19px; flex-shrink: 0; }

/* ── цифры ─────────────────────────────────────────────── */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line); border-block: 1px solid var(--line); }
.facts > div { background: var(--ink); padding: clamp(26px, 3vw, 40px) clamp(16px, 2vw, 28px); }
.facts b { display: block; font-size: clamp(40px, 4.6vw, 64px); font-weight: 400; letter-spacing: -0.05em; line-height: 1; }
.facts b s { text-decoration: none; color: var(--accent); }
.facts span { display: block; margin-top: 12px; font-size: 14px; color: var(--muted); max-width: 22ch; }

/* ── бегущая строка ЖК ─────────────────────────────────── */
.marquee { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.marquee-track { display: flex; gap: 56px; width: max-content; animation: slide 46s linear infinite; }
/* знаки уже перекрашены в костяной при сборке ассетов — фильтр не нужен */
.marquee img { height: 46px; width: auto; opacity: 0.55; transition: opacity 0.4s var(--ease); }
.marquee img:hover { opacity: 1; }
@keyframes slide { to { transform: translateX(-50%); } }

/* ── портфолио ─────────────────────────────────────────── */
.works {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: var(--gap);
  margin-top: clamp(34px, 4vw, 56px);
}
.tile { position: relative; border-radius: var(--r-card); overflow: hidden; cursor: pointer; background: var(--surface); }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s var(--ease), filter 0.7s var(--ease); }
.tile:hover img { transform: scale(1.045); }
.tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 55%, rgba(8, 8, 9, 0.5));
  pointer-events: none;
}
/* Затемнение живёт на самой подписи, а не на всей плитке: подпись из двух
   строк тогда тоже лежит на тёмном, а не всплывает на светлое фото. */
.tile-meta {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(8, 8, 9, 0) 0%, rgba(8, 8, 9, 0.88) 58%);
  padding: 64px 22px 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  align-items: center;
}
.tile-meta span { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: rgba(241, 239, 233, 0.86); }
.tile-meta i { color: var(--accent); font-size: 16px; }
.tile-count {
  position: absolute;
  z-index: 1;
  top: 16px;
  right: 16px;
  padding: 6px 13px;
  border-radius: var(--r-pill);
  font-size: 12px;
  background: rgba(12, 12, 13, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(12px);
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.45s var(--ease), transform 0.45s var(--ease);
}
.tile:hover .tile-count { opacity: 1; transform: none; }
/* На тач-экранах :hover не наступает никогда — счётчик кадров показываем сразу,
   иначе на телефоне его не видит вообще никто. */
@media (hover: none) {
  .tile-count { opacity: 1; transform: none; }
}

.tile--video { grid-column: span 3; aspect-ratio: 16 / 10; }
.tile--a { grid-column: span 3; aspect-ratio: 16 / 10; }
.tile--b { grid-column: span 2; aspect-ratio: 4 / 3.4; }

.play {
  position: absolute;
  z-index: 1;
  inset: 0;
  display: grid;
  place-items: center;
}
.play span {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  border-radius: var(--r-pill);
  background: rgba(226, 97, 60, 0.9);
  color: #fff;
  font-size: 26px;
  box-shadow: 0 0 0 0 rgba(226, 97, 60, 0.45);
  transition: transform 0.5s var(--ease);
}
.tile--video:hover .play span { transform: scale(1.08); }
@media (prefers-reduced-motion: no-preference) {
  .play span { animation: pulse 2.6s ease-out infinite; }
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 26px rgba(226, 97, 60, 0); }
  100% { box-shadow: 0 0 0 0 rgba(226, 97, 60, 0); }
}

/* ── услуги: липкий индекс + панели ────────────────────── */
.svc { display: grid; grid-template-columns: minmax(0, 0.72fr) minmax(0, 1.28fr); gap: clamp(24px, 4vw, 72px); margin-top: clamp(34px, 4vw, 56px); }
.svc-index { position: sticky; top: 108px; align-self: start; display: flex; flex-direction: column; }
.svc-index button {
  text-align: left;
  background: none;
  border: 0;
  border-top: 1px solid var(--line);
  padding: 20px 4px;
  font-size: clamp(19px, 1.7vw, 25px);
  letter-spacing: -0.025em;
  color: var(--muted-2);
  cursor: pointer;
  display: flex;
  align-items: baseline;
  gap: 16px;
  transition: color 0.45s var(--ease), padding 0.45s var(--ease);
}
.svc-index button:last-child { border-bottom: 1px solid var(--line); }
.svc-index button em { font-style: normal; font-family: "JetBrains Mono", monospace; font-size: 12px; opacity: 0.65; }
.svc-index button:hover { color: var(--muted); }
.svc-index button.on { color: var(--bone); padding-left: 16px; }
.svc-index button.on em { color: var(--accent); opacity: 1; }

.svc-panels { position: relative; }
.svc-panel { display: none; }
.svc-panel.on { display: block; animation: fadeup 0.6s var(--ease) both; }
@keyframes fadeup { from { opacity: 0; transform: translateY(18px); } }

.svc-panel .shot { border-radius: var(--r-card); overflow: hidden; border: var(--shell); }
.svc-panel .shot img { width: 100%; height: clamp(190px, 24vw, 300px); object-fit: cover; }
.svc-body { margin-top: 28px; }
.svc-body h3 { margin-bottom: 16px; }
.svc-body ul { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 14px; }
.svc-body li { display: flex; gap: 14px; font-size: 15px; color: var(--muted); line-height: 1.5; }
.svc-body li i { color: var(--accent); font-size: 18px; flex-shrink: 0; margin-top: 1px; }
.svc-body li b { color: var(--bone); font-weight: 500; }
.svc-body .btn { margin-top: 30px; }

/* ── квиз ──────────────────────────────────────────────── */
.quiz-shell {
  border-radius: calc(var(--r-card) + 6px);
  border: var(--shell);
  background: rgba(241, 239, 233, 0.035);
  padding: 6px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.quiz {
  border-radius: var(--r-card);
  background: var(--surface);
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.65fr);
  overflow: hidden;
}
.quiz-main { padding: clamp(24px, 3vw, 46px); display: flex; flex-direction: column; }
.quiz-bar { height: 3px; border-radius: var(--r-pill); background: rgba(241, 239, 233, 0.1); overflow: hidden; }
.quiz-bar span { display: block; height: 100%; width: 20%; background: var(--accent); border-radius: var(--r-pill); transition: width 0.6s var(--ease); }
.quiz-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 14px; font-size: 12px; }
.quiz-step { display: none; }
.quiz-step.on { display: block; animation: fadeup 0.5s var(--ease) both; }
.quiz-step h3 { margin: 26px 0 22px; }
.quiz-opts { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; }
.opt {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 18px;
  border-radius: var(--r-field);
  border: var(--shell);
  background: rgba(241, 239, 233, 0.025);
  font-size: 15px;
  cursor: pointer;
  text-align: left;
  transition: border-color 0.4s var(--ease), background 0.4s var(--ease), transform 0.4s var(--ease);
}
.opt::before {
  content: "";
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid var(--line-2);
  flex-shrink: 0;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.opt:hover { border-color: var(--line-2); background: rgba(241, 239, 233, 0.05); }
.opt.on { border-color: var(--accent); background: var(--accent-soft); }
.opt.on::before { border-color: var(--accent); box-shadow: inset 0 0 0 4px var(--accent); }
.quiz-nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: auto; padding-top: 32px; }
.quiz-side {
  position: relative;
  background: linear-gradient(180deg, var(--surface-2), #101012);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 320px;
  border-left: 1px solid var(--line);
}
.quiz-side img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.quiz-side .who {
  position: relative;
  z-index: 1;
  padding: 22px;
  background: linear-gradient(180deg, rgba(16, 16, 18, 0) 0%, rgba(16, 16, 18, 0.94) 42%);
}
.quiz-side .who b { display: block; font-weight: 500; font-size: 17px; letter-spacing: -0.02em; }
.quiz-side .who span { font-size: 13px; color: var(--muted); }
.quiz-side .who p { margin-top: 14px; font-size: 13.5px; color: var(--muted); line-height: 1.5; }

/* ── бенто преимуществ ─────────────────────────────────── */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: var(--gap); margin-top: clamp(34px, 4vw, 56px); }
.cell {
  position: relative;
  border-radius: var(--r-card);
  border: var(--shell);
  background: var(--surface);
  padding: clamp(22px, 2.2vw, 34px);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 250px;
}
.cell h3 { margin-bottom: 12px; max-width: 18ch; }
.cell p { color: var(--muted); font-size: 14.5px; line-height: 1.55; max-width: 40ch; position: relative; z-index: 1; }
.cell em {
  font-style: normal;
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  color: var(--accent);
  margin-bottom: auto;
  display: block;
}
.cell .art { position: absolute; right: -3%; bottom: -4%; width: 36%; opacity: 0.9; pointer-events: none; }
/* Предметка лежит в правом нижнем углу, поэтому текст в такой ячейке жмётся
   в свою колонку — иначе строки уезжают под картинку и не читаются. */
.cell:has(.art) h3, .cell:has(.art) p { max-width: min(40ch, 64%); }
.cell--w3 { grid-column: span 3; }
.cell--w2 { grid-column: span 2; }
.cell--tint { background: linear-gradient(150deg, rgba(226, 97, 60, 0.16), rgba(20, 20, 22, 0.4) 58%), var(--surface); }
.cell--photo { padding: 0; min-height: 300px; }
.cell--photo img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.cell--photo .over {
  position: relative;
  z-index: 1;
  margin-top: auto;
  padding: clamp(22px, 2.2vw, 34px);
  background: linear-gradient(180deg, rgba(10, 10, 11, 0) 0%, rgba(10, 10, 11, 0.9) 45%);
}

/* ── сплит текст + медиа ───────────────────────────────── */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 84px); align-items: center; }
.split--rev .split-media { order: -1; }
.split-media { border-radius: var(--r-card); border: var(--shell); padding: 6px; background: rgba(241, 239, 233, 0.035); }
.split-media img { border-radius: var(--r-core); width: 100%; object-fit: cover; }
/* заголовок в половине ширины — на кегль ниже секционного, иначе он
   рассыпается в восемь строк и перевешивает вторую половину */
.split-body h2 { font-size: clamp(26px, 3.1vw, 44px); }
.split-body ul { list-style: none; margin: 26px 0 0; padding: 0; display: grid; gap: 16px; }
.split-body li { display: flex; gap: 14px; font-size: 15.5px; color: var(--muted); line-height: 1.5; }
.split-body li i { color: var(--accent); font-size: 19px; flex-shrink: 0; margin-top: 1px; }
.split-body li b { color: var(--bone); font-weight: 500; }
.split-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

/* ── гарантии: строки с крупной цифрой ─────────────────── */
.guards { margin-top: clamp(30px, 4vw, 50px); border-top: 1px solid var(--line); }
.guard {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(16px, 3vw, 44px);
  align-items: baseline;
  padding: clamp(22px, 2.4vw, 32px) 0;
  border-bottom: 1px solid var(--line);
  transition: background 0.5s var(--ease);
}
.guard:hover { background: rgba(241, 239, 233, 0.022); }
.guard em { font-style: normal; font-family: "JetBrains Mono", monospace; font-size: 12px; color: var(--accent); }
.guard h3 { font-size: clamp(18px, 1.6vw, 23px); }
.guard p { color: var(--muted); font-size: 15px; }
.guard p b { color: var(--bone); font-weight: 500; }

/* ── акции ─────────────────────────────────────────────── */
/* 7 колонок под несимметричное трио 3 + 2 + 2: на пяти третья карточка
   не помещалась в строку и уезжала вниз одна. */
.gifts { display: grid; grid-template-columns: repeat(7, 1fr); gap: var(--gap); margin-top: clamp(34px, 4vw, 56px); }
.gift {
  grid-column: span 2;
  border-radius: var(--r-card);
  border: var(--shell);
  background: var(--surface);
  padding: clamp(22px, 2.2vw, 32px);
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow: hidden;
  position: relative;
}
.gift:first-child { grid-column: span 3; }
.gift img { width: min(210px, 46%); align-self: flex-end; margin-top: -10px; }
.gift .amount { font-size: clamp(30px, 3.4vw, 46px); letter-spacing: -0.045em; line-height: 1; }
.gift h3 { max-width: 20ch; }
.gift .btn { margin-top: auto; align-self: flex-start; }
.gift-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }

/* ── формы ─────────────────────────────────────────────── */
.form-shell {
  border-radius: calc(var(--r-card) + 6px);
  border: var(--shell);
  background: rgba(241, 239, 233, 0.035);
  padding: 6px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.form-core { border-radius: var(--r-card); background: var(--surface); padding: clamp(24px, 2.6vw, 38px); }
.field { display: grid; gap: 8px; margin-bottom: 16px; }
.field label { font-size: 13px; color: var(--muted); letter-spacing: 0.01em; }
.field input, .field textarea, .field select {
  width: 100%;
  padding: 14px 16px;
  border-radius: var(--r-field);
  border: 1px solid var(--line-2);
  background: rgba(10, 10, 11, 0.6);
  color: var(--bone);
  font: inherit;
  font-size: 15px;
  transition: border-color 0.35s var(--ease), box-shadow 0.35s var(--ease);
}
.field textarea { min-height: 96px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #7a7873; }
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field .hint { font-size: 12px; color: var(--muted-2); }
.field .err { font-size: 12.5px; color: #ff8a6a; display: none; }
.field.bad input { border-color: #ff8a6a; }
.field.bad .err { display: block; }

.file-drop {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--r-field);
  border: 1px dashed var(--line-2);
  color: var(--muted);
  font-size: 14.5px;
  cursor: pointer;
  transition: border-color 0.35s var(--ease), color 0.35s var(--ease);
}
.file-drop:hover { border-color: var(--accent); color: var(--bone); }
.file-drop i { font-size: 19px; color: var(--accent); }
.file-drop input { display: none; }

.consent { display: flex; gap: 10px; align-items: flex-start; margin: 6px 0 20px; font-size: 12.5px; color: var(--muted-2); line-height: 1.5; }
.consent input { width: 17px; height: 17px; margin: 1px 0 0; accent-color: var(--accent); flex-shrink: 0; }
.consent a { color: var(--muted); border-bottom: 1px solid var(--line-2); }

.form-note { margin-top: 16px; font-size: 12.5px; color: var(--muted-2); }
.form-done, .form-fail { display: none; padding: 18px; border-radius: var(--r-field); font-size: 15px; margin-top: 16px; }
.form-done { background: rgba(90, 190, 130, 0.12); border: 1px solid rgba(90, 190, 130, 0.35); color: #9fdcb8; }
.form-fail { background: rgba(255, 138, 106, 0.1); border: 1px solid rgba(255, 138, 106, 0.35); color: #ffa287; }
.is-done .form-done, .is-fail .form-fail { display: block; }
.is-done .form-fields { display: none; }

.btn[disabled] { opacity: 0.6; cursor: progress; }
.btn .spin { display: none; }
.btn.loading .spin { display: inline-block; animation: rot 0.9s linear infinite; }
.btn.loading .ico { display: none; }
@keyframes rot { to { transform: rotate(360deg); } }

/* ── аудит сметы ───────────────────────────────────────── */
.audit { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(28px, 5vw, 72px); align-items: center; }

/* ── награды и сертификаты ─────────────────────────────── */
.awards { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
/* Кубок сверху, площадки — строкой снизу через волосяную линию: врозь по
   горизонтали они болтались в пустой карточке. */
.awards-shot {
  position: relative;
  border-radius: var(--r-card);
  border: var(--shell);
  overflow: hidden;
  background: radial-gradient(120% 90% at 50% 0%, rgba(226, 97, 60, 0.1), transparent 62%), var(--surface);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
  padding: clamp(28px, 3vw, 44px);
  min-height: 320px;
}
.awards-shot > img { max-height: 200px; width: auto; }
.awards-plat {
  display: flex;
  align-items: center;
  gap: 28px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  width: min(100%, 300px);
  justify-content: center;
}
.awards-plat img { max-height: 40px; width: auto; }
.serts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 30px; }
.sert { border-radius: var(--r-core); overflow: hidden; border: var(--shell); background: var(--surface); cursor: pointer; transition: border-color 0.4s var(--ease), transform 0.5s var(--ease); }
.sert:hover { border-color: var(--line-2); transform: translateY(-3px); }
.sert img { width: 100%; height: 200px; object-fit: cover; object-position: top; }

/* ── качество ──────────────────────────────────────────── */
.quality { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(28px, 5vw, 72px); margin-top: clamp(30px, 4vw, 50px); }
.q-item { display: flex; gap: 16px; padding: 20px 0; border-bottom: 1px solid var(--line); align-items: center; }
.q-item:first-child, .q-item:nth-child(2) { border-top: 1px solid var(--line); }
.q-item i { color: var(--accent); font-size: 22px; flex-shrink: 0; }
.q-item span { font-size: 15.5px; }

/* ── отзывы ────────────────────────────────────────────── */
.rev-rail {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding-bottom: 18px;
  margin-top: clamp(30px, 4vw, 48px);
  scrollbar-width: thin;
  scrollbar-color: var(--line-2) transparent;
}
.rev-rail::-webkit-scrollbar { height: 5px; }
.rev-rail::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: var(--r-pill); }
.rev {
  flex: 0 0 clamp(260px, 26vw, 330px);
  scroll-snap-align: start;
  border-radius: var(--r-card);
  border: var(--shell);
  background: var(--surface);
  padding: 6px;
  cursor: zoom-in;
}
/* Скриншоты отзывов разной высоты. Карточки режем по общей высоте и гасим
   низ градиентом — иначе под короткими зияет пустая половина рамки, а целиком
   отзыв всё равно открывается в лайтбоксе по клику. */
.rev-shot { position: relative; display: block; max-height: 480px; border-radius: var(--r-core); overflow: hidden; }
.rev-shot::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 64px;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(20, 20, 22, 0), var(--surface));
}
/* по ширине — целиком (иначе cover срезает первые буквы строк), лишнее по
   высоте прячет рамка */
.rev img { border-radius: 0; width: 100%; height: auto; display: block; }
.rail-nav { display: flex; gap: 10px; margin-top: 8px; }
.rail-nav button {
  width: 44px;
  height: 44px;
  border-radius: var(--r-pill);
  border: var(--shell);
  background: transparent;
  cursor: pointer;
  font-size: 18px;
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease);
}
.rail-nav button:hover { background: rgba(241, 239, 233, 0.07); border-color: var(--line-2); }

/* ── тарифы ────────────────────────────────────────────── */
.packs { margin-top: clamp(34px, 4vw, 56px); }
.pack-head { display: grid; grid-template-columns: minmax(230px, 1.5fr) repeat(4, minmax(0, 1fr)); gap: 12px; align-items: stretch; }
.pack-card {
  border-radius: var(--r-card);
  border: var(--shell);
  background: var(--surface);
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.pack-card.hot { border-color: rgba(226, 97, 60, 0.5); background: linear-gradient(180deg, rgba(226, 97, 60, 0.12), var(--surface) 62%); }
.pack-card h3 { font-size: 20px; }
.pack-card .price { margin-top: 6px; font-size: clamp(24px, 2.3vw, 32px); letter-spacing: -0.04em; line-height: 1; }
.pack-card .price small { display: block; font-size: 12px; color: var(--muted-2); letter-spacing: 0; margin-bottom: 4px; }
.pack-card .price span { font-size: 14px; color: var(--muted); letter-spacing: 0; }
.pack-card .btn { margin-top: auto; }
.pack-lead { display: flex; flex-direction: column; justify-content: flex-end; padding: 22px 4px; }

.pack-group { margin-top: 30px; }
.pack-group > h4 {
  font-family: "JetBrains Mono", monospace;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted-2);
  font-weight: 400;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line-2);
}
.prow {
  display: grid;
  grid-template-columns: minmax(230px, 1.5fr) repeat(4, minmax(0, 1fr));
  gap: 12px;
  align-items: center;
  padding: 13px 0;
}
.prow + .prow { border-top: 1px solid rgba(241, 239, 233, 0.05); }
.prow > span:first-child { font-size: 15px; color: var(--muted); }
.prow b { justify-self: center; font-size: 19px; line-height: 1; }
.prow b.y { color: var(--accent); }
.prow b.n { color: #3a3a3d; }
/* Липнет ровно к нижней кромке плавающей навигации (72px): при большем
   отступе в щель между ними проглядывали строки таблицы. */
.pack-sticky { position: sticky; top: 72px; z-index: 5; background: var(--ink); padding-block: 16px 10px; }

.pack-cards { display: none; }

/* ── этапы ─────────────────────────────────────────────── */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); margin-top: clamp(34px, 4vw, 56px); }
.step { border-top: 1px solid var(--line-2); padding-top: 24px; display: flex; flex-direction: column; gap: 14px; }
.step .n { font-family: "JetBrains Mono", monospace; font-size: 12px; color: var(--accent); }
.step img { width: 74px; height: 74px; object-fit: contain; }
.step h3 { font-size: clamp(17px, 1.5vw, 21px); }
.step p { color: var(--muted); font-size: 14.5px; line-height: 1.55; }

/* ── FAQ ───────────────────────────────────────────────── */
.faq { margin-top: clamp(30px, 4vw, 50px); border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none;
  cursor: pointer;
  padding: 22px 56px 22px 0;
  font-size: clamp(16px, 1.4vw, 19px);
  letter-spacing: -0.02em;
  position: relative;
  transition: color 0.35s var(--ease);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "\e3d4";
  font-family: "Phosphor-Light";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
  color: var(--muted-2);
  transition: transform 0.5s var(--ease), color 0.4s var(--ease);
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); color: var(--accent); }
.faq summary:hover { color: var(--accent); }
.faq .ans { padding: 0 20% 26px 0; color: var(--muted); font-size: 15px; line-height: 1.65; }

/* ── контакты и подвал ─────────────────────────────────── */
.contacts { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); margin-top: clamp(30px, 4vw, 50px); }
.contact { border-top: 1px solid var(--line-2); padding-top: 22px; }
.contact i { font-size: 24px; color: var(--accent); display: block; margin-bottom: 16px; }
.contact span { display: block; font-size: 13px; color: var(--muted-2); margin-bottom: 6px; }
.contact b, .contact a { font-size: clamp(16px, 1.4vw, 19px); font-weight: 500; letter-spacing: -0.02em; }
.contact a:hover { color: var(--accent); }

.foot { border-top: 1px solid var(--line); padding-block: 40px 56px; }
.foot-grid { display: flex; flex-wrap: wrap; gap: 26px; justify-content: space-between; align-items: flex-start; }
.foot .soc { display: flex; gap: 10px; }
.foot .soc a {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: var(--r-pill);
  border: var(--shell);
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease);
}
.foot .soc a:hover { background: rgba(241, 239, 233, 0.07); border-color: var(--line-2); }
.foot .soc img { width: 20px; opacity: 0.8; }
.foot .soc i { font-size: 20px; }
.foot-legal { margin-top: 34px; display: flex; flex-wrap: wrap; gap: 8px 26px; }

/* ── модалки и лайтбокс ────────────────────────────────── */
.modal {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: var(--pad);
  background: rgba(7, 7, 8, 0.82);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s var(--ease), visibility 0.45s;
}
.modal.on { opacity: 1; visibility: visible; }
.modal-box {
  width: min(560px, 100%);
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: translateY(24px) scale(0.98);
  transition: transform 0.55s var(--ease);
}
.modal.on .modal-box { transform: none; }
.modal-box.wide { width: min(1000px, 100%); }
.modal-close {
  position: absolute;
  z-index: 2;
  top: 14px;
  right: 14px;
  width: 40px;
  height: 40px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(12, 12, 13, 0.7);
  backdrop-filter: blur(10px);
  cursor: pointer;
  font-size: 18px;
  transition: background 0.4s var(--ease);
}
.modal-close:hover { background: rgba(226, 97, 60, 0.85); }
.modal .form-core { padding-top: 34px; }
.modal h3 { margin-bottom: 8px; max-width: 24ch; }
.modal .modal-sub { color: var(--muted); font-size: 14.5px; margin-bottom: 24px; }
.embed { aspect-ratio: 16 / 9; border-radius: var(--r-card); overflow: hidden; border: var(--shell); background: #000; }
.embed iframe { width: 100%; height: 100%; border: 0; display: block; }

.lb { position: fixed; inset: 0; z-index: 70; background: rgba(6, 6, 7, 0.95); display: none; place-items: center; }
.lb.on { display: grid; }
.lb img { max-width: 92vw; max-height: 84vh; border-radius: var(--r-core); object-fit: contain; }
.lb-bar { position: absolute; bottom: 22px; left: 0; right: 0; display: flex; justify-content: center; gap: 12px; align-items: center; }
.lb-bar button, .lb-close {
  width: 48px;
  height: 48px;
  border-radius: var(--r-pill);
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(20, 20, 22, 0.7);
  cursor: pointer;
  font-size: 20px;
  transition: background 0.35s var(--ease);
}
.lb-bar button:hover, .lb-close:hover { background: rgba(226, 97, 60, 0.85); }
.lb-close { position: absolute; top: 22px; right: 22px; }
.lb-num { font-family: "JetBrains Mono", monospace; font-size: 13px; color: var(--muted); min-width: 56px; text-align: center; }

/* всплывающая кнопка звонка */
.dock {
  position: fixed;
  z-index: 35;
  right: 20px;
  bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
}
.dock.on { opacity: 1; transform: none; pointer-events: auto; }
.dock a, .dock button {
  width: 54px;
  height: 54px;
  border-radius: var(--r-pill);
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(20, 20, 22, 0.82);
  backdrop-filter: blur(14px);
  font-size: 22px;
  cursor: pointer;
  transition: background 0.4s var(--ease), transform 0.4s var(--ease);
}
.dock a:hover, .dock button:hover { transform: translateY(-2px); background: rgba(226, 97, 60, 0.9); }
.dock .accent { background: var(--accent); border-color: transparent; box-shadow: 0 10px 26px rgba(226, 97, 60, 0.3); }

/* ── появление на скролле ──────────────────────────────── */
@media (prefers-reduced-motion: no-preference) {
  .rv { opacity: 0; transform: translateY(26px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
  .rv.in { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
  html { scroll-behavior: auto; }
  .marquee-track { animation: none; }
}

/* ── адаптив ───────────────────────────────────────────── */
@media (max-width: 1180px) {
  .nav-links { display: none; }
  .burger { display: block; margin-left: auto; }
  .nav-phone { margin-left: 0; }
  .quality { grid-template-columns: 1fr; }
  .q-item:nth-child(2) { border-top: 0; }
}

@media (max-width: 1024px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-media img { height: clamp(260px, 52vw, 420px); }
  .hero-strip { grid-template-columns: repeat(2, 1fr); }
  .hero-strip div { padding-right: 14px; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .svc { grid-template-columns: 1fr; }
  .svc-index { position: static; }
  .quiz { grid-template-columns: 1fr; }
  .quiz-side { min-height: 260px; border-left: 0; border-top: 1px solid var(--line); }
  .quiz-side img { object-position: center 18%; }
  .works { grid-template-columns: repeat(4, 1fr); }
  .tile--video, .tile--a { grid-column: span 4; }
  .tile--b { grid-column: span 2; }
  .bento { grid-template-columns: repeat(4, 1fr); }
  .cell--w3, .cell--w2 { grid-column: span 2; }
  .split { grid-template-columns: 1fr; }
  .split--rev .split-media { order: 0; }
  .audit, .awards { grid-template-columns: 1fr; }
  .gifts { grid-template-columns: repeat(2, 1fr); }
  .gift, .gift:first-child { grid-column: span 1; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .contacts { grid-template-columns: repeat(2, 1fr); }
  .guard { grid-template-columns: 54px 1fr; }
  .guard p { grid-column: 2; }
  .faq .ans { padding-right: 8%; }
}

@media (max-width: 720px) {
  .facts { grid-template-columns: 1fr; }
  .facts b { font-size: 42px; }
  .hero-strip { grid-template-columns: 1fr; }
  .works, .bento { grid-template-columns: 1fr; }
  .tile--video, .tile--a, .tile--b, .cell--w3, .cell--w2 { grid-column: span 1; }
  .tile--b { aspect-ratio: 4 / 3; }
  .gifts, .steps, .contacts { grid-template-columns: 1fr; }
  .serts { grid-template-columns: 1fr; }
  .sert img { height: 220px; }
  .quiz-opts { grid-template-columns: 1fr; }
  .quiz-nav { flex-direction: column-reverse; align-items: stretch; }
  .quiz-nav .btn { justify-content: center; }
  .brand span { display: none; }
  .nav-phone { display: none; }
  /* В пилюле на телефоне «Заказать звонок» с текстом не помещается и выдавливает
     бургер за край — остаётся круглая кнопка с трубкой, номер целиком в меню. */
  .nav > .btn { width: 44px; height: 44px; padding: 0; gap: 0; font-size: 0; justify-content: center; }
  .nav > .btn i { width: 44px; height: 44px; background: transparent; font-size: 19px; }
  .nav { gap: 10px; padding-right: 8px; }
  .hero { padding-top: 96px; }
  /* тарифы: матрица не помещается — показываем карточки пакетов */
  .pack-head, .pack-group { display: none; }
  .pack-cards { display: grid; gap: 16px; margin-top: 26px; }
  .pack-m { border-radius: var(--r-card); border: var(--shell); background: var(--surface); padding: 22px; }
  .pack-m.hot { border-color: rgba(226, 97, 60, 0.5); }
  .pack-m .price { font-size: 30px; letter-spacing: -0.04em; margin: 6px 0 16px; }
  .pack-m .price small { display: block; font-size: 12px; color: var(--muted-2); }
  .pack-m ul { list-style: none; margin: 0 0 20px; padding: 0; display: grid; gap: 9px; }
  .pack-m li { display: flex; gap: 10px; font-size: 14.5px; color: var(--muted); }
  .pack-m li i { color: var(--accent); font-size: 17px; flex-shrink: 0; }
  .lb-close { top: 14px; right: 14px; }
  .dock { right: 14px; bottom: 14px; }
}
