/* ==========================================================================
   Лендинг «Пульс» — визуальная грамматика в духе aaru.com (насыщенное цветовое
   поле, гигантский дисплей, круглые «иллюминаторы», нумерованные ритуалы,
   микро-подписи капсом), переведённая в бренд «Пульса»: глубокий петроль
   вместо ультрамарина, засечный дисплей вместо гротеска, ЭКГ-линия как мотив,
   границы точности как орнамент. Токены палитры — от дизайн-системы платформы.
   ========================================================================== */

:root {
  /* Бумажная база платформы */
  --paper: oklch(0.987 0.004 95);
  --surface: oklch(0.998 0.0025 95);
  --surface-sunk: oklch(0.966 0.005 100);
  --ink: oklch(0.26 0.017 225);
  --ink-soft: oklch(0.4 0.015 223);
  --muted: oklch(0.53 0.014 221);
  --faint: oklch(0.66 0.011 219);
  --line: oklch(0.912 0.005 210);
  --line-soft: oklch(0.945 0.004 210);
  --accent: oklch(0.53 0.086 213);
  --accent-strong: oklch(0.45 0.085 213);
  --accent-soft: oklch(0.958 0.019 210);
  --accent-line: oklch(0.87 0.036 208);

  /* Петрольное поле лендинга (тёмная сцена) */
  --petrol: oklch(0.3 0.058 218);
  --petrol-deep: oklch(0.235 0.048 220);
  --petrol-raise: oklch(0.345 0.06 216);
  --petrol-line: oklch(0.52 0.05 213 / 0.34);
  --petrol-line-soft: oklch(0.52 0.05 213 / 0.18);
  --on-petrol: oklch(0.972 0.007 100);
  --on-petrol-soft: oklch(0.845 0.022 205);
  --on-petrol-faint: oklch(0.745 0.028 207);

  /* Светящийся пульс на петроле */
  --pulse: oklch(0.87 0.1 182);
  --pulse-dim: oklch(0.87 0.1 182 / 0.35);

  /* Семантика (тональности карты боли) */
  --positive-dot: oklch(0.64 0.11 152);
  --caution-dot: oklch(0.72 0.115 74);
  --negative-dot: oklch(0.63 0.17 25);
  --sim: oklch(0.48 0.115 300);
  --sim-bright: oklch(0.76 0.095 300);

  --font-display: "Literata", Georgia, "Times New Roman", serif;
  --font-ui: "Golos Text", "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --container: 1240px;
  --gutter: clamp(20px, 4vw, 56px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--pulse); color: var(--petrol-deep); }

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

h1, h2, h3 { font-optical-sizing: auto; text-wrap: balance; }
p { text-wrap: pretty; }

/* бумажное зерно на светлых секциях — против цифровой плоскости */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 60;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='p'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.018 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23p)'/%3E%3C/svg%3E");
}

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent-strong);
  outline-offset: 3px;
  border-radius: 2px;
}
.hero :focus-visible, .dark :focus-visible, .footer :focus-visible, .subhero :focus-visible {
  outline-color: var(--pulse);
}

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

/* ---------- микро-подписи (mono caps) ---------- */
.kicker {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-strong);
  display: flex;
  align-items: center;
  gap: 12px;
}
.kicker::before {
  content: "";
  width: 26px;
  height: 1px;
  background: currentColor;
  opacity: 0.7;
}
.dark .kicker, .kicker.on-dark { color: var(--pulse); }

/* ---------- навигация ---------- */
.nav {
  position: absolute;
  inset: 0 0 auto 0;
  z-index: 50;
  padding-top: 26px;
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.wordmark {
  display: flex;
  align-items: baseline;
  gap: 10px;
  color: var(--on-petrol);
}
.wordmark svg { align-self: center; display: block; }
.wordmark .wm-name {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.wordmark .wm-city {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--on-petrol-faint);
  transform: translateY(-2px);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.4vw, 34px);
}
.nav-links a:not(.btn) {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--on-petrol-soft);
  padding: 6px 2px;
  border-bottom: 1px solid transparent;
  transition: color 0.25s var(--ease-out), border-color 0.25s var(--ease-out);
}
.nav-links a:not(.btn):hover { color: var(--on-petrol); border-color: var(--pulse); }
.nav-links a.current { color: var(--on-petrol); border-color: var(--pulse); }
.footer .nav-links a.current { color: var(--on-petrol); }

/* skip-link для клавиатуры */
.skip-link {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  padding: 10px 16px;
  transition: top 0.2s var(--ease-out);
}
.skip-link:focus-visible { top: 12px; }

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 15px 28px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.3s var(--ease-out), background 0.3s var(--ease-out),
    color 0.3s var(--ease-out), border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out);
}
.btn:active { transform: scale(0.98); }
.btn-solid { background: var(--on-petrol); color: var(--petrol-deep); }
.btn-solid:hover { background: var(--pulse); box-shadow: 0 10px 34px oklch(0.87 0.1 182 / 0.25); transform: translateY(-1px); }
.btn-ghost { color: var(--on-petrol); border-color: var(--petrol-line); }
.btn-ghost:hover { border-color: var(--pulse); color: var(--pulse); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: var(--accent-strong); }
.btn-outline-ink { color: var(--ink); border-color: var(--line); background: transparent; }
.btn-outline-ink:hover { border-color: var(--accent); color: var(--accent-strong); }
.btn .arr { transition: transform 0.3s var(--ease-out); }
.btn:hover .arr { transform: translateX(4px); }

.textlink {
  font-family: var(--font-mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-petrol-soft);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: color 0.25s var(--ease-out), gap 0.25s var(--ease-out);
}
.textlink:hover { color: var(--pulse); gap: 12px; }
.textlink.on-paper { color: var(--accent-strong); }
.textlink.on-paper:hover { color: var(--accent); }

/* ---------- HERO ---------- */
.hero {
  position: relative;
  background:
    radial-gradient(1100px 700px at 82% 8%, oklch(0.36 0.07 210 / 0.55), transparent 62%),
    radial-gradient(900px 620px at -6% 96%, oklch(0.22 0.05 225 / 0.75), transparent 60%),
    var(--petrol);
  color: var(--on-petrol);
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.hero::after {
  /* зерно поверх поля — бумажная фактура на тёмном */
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.035 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
.hero-main {
  /* flex-элемент с margin:auto теряет stretch — фиксируем ширину контейнера явно */
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: clamp(110px, 15vh, 170px);
  padding-bottom: 44px;
  position: relative;
  z-index: 2;
}
.hero h1 {
  position: relative;
  z-index: 1;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(40px, 6vw, 86px);
  line-height: 1.07;
  letter-spacing: -0.015em;
  max-width: 21ch;
}
.hero h1 .rot {
  display: inline-block;
  color: var(--pulse);
  white-space: nowrap;
}
/* контролируемые переносы заголовка — только на широких экранах */
.bd { display: none; }
@media (min-width: 761px) { .bd { display: inline; } }
.hero h1 .rot span { display: inline-block; }
.hero-sub {
  position: relative;
  z-index: 1;
  margin-top: 28px;
  max-width: 54ch;
  font-size: clamp(16px, 1.35vw, 19px);
  line-height: 1.6;
  color: var(--on-petrol-soft);
}
.hero-cta {
  position: relative;
  z-index: 1;
  margin-top: 40px;
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
}

/* иллюминатор — справа, частично под заголовком (грамматика Aaru) */
.porthole-wrap {
  position: absolute;
  right: var(--gutter);
  top: 50%;
  transform: translateY(-54%);
  width: min(34vw, 470px);
  aspect-ratio: 1;
  z-index: 0;
}
.porthole {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  overflow: hidden;
  border: 1px solid var(--petrol-line);
  box-shadow:
    inset 0 0 80px oklch(0.16 0.04 222 / 0.85),
    0 30px 80px oklch(0.14 0.035 222 / 0.5);
  background: radial-gradient(circle at 38% 30%, oklch(0.34 0.06 214), var(--petrol-deep) 75%);
}
.porthole canvas { width: 100%; height: 100%; display: block; }
/* левый скрим: текст hero остаётся читаемым поверх прибора */
.porthole::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: linear-gradient(105deg, var(--petrol) 4%, oklch(0.3 0.058 218 / 0.78) 30%, oklch(0.3 0.058 218 / 0.25) 48%, transparent 62%);
  pointer-events: none;
}
/* гратикула прибора: перекрестье, кольца, деления по ободу */
.porthole-grid {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  color: var(--petrol-line);
  opacity: 0.55;
}
/* радарная развёртка */
.porthole-sweep {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(from 0deg, oklch(0.87 0.1 182 / 0.16) 0deg, transparent 52deg);
  animation: spin 26s linear infinite;
  pointer-events: none;
}
.porthole-caption {
  position: absolute;
  left: 50%;
  bottom: 40px;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--on-petrol-faint);
  white-space: nowrap;
  z-index: 2;
}
.porthole-ring {
  position: absolute;
  inset: -14px;
  border-radius: 50%;
  border: 1px dashed var(--petrol-line-soft);
  animation: spin 90s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ЭКГ-линия внизу hero */
.ecg-band {
  position: relative;
  z-index: 2;
  padding-bottom: 0;
}
.ecg-band svg { display: block; width: 100%; height: 84px; }
.ecg-trace {
  fill: none;
  stroke: var(--pulse);
  stroke-width: 1.6;
  filter: drop-shadow(0 0 6px var(--pulse-dim));
}
.ecg-base { fill: none; stroke: var(--petrol-line-soft); stroke-width: 1; }
.ecg-echo { fill: none; stroke: var(--pulse-dim); stroke-width: 1.1; opacity: 0.5; }

/* статистическая полоса — приборная строка с хайрлайн-делениями */
.statbar {
  position: relative;
  z-index: 2;
  border-top: 1px solid var(--petrol-line-soft);
  background: var(--petrol-deep);
}
.statbar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  padding-block: 0;
}
.stat {
  flex: 1 1 auto;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--on-petrol-faint);
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  padding: 17px 12px;
  border-left: 1px solid var(--petrol-line-soft);
}
.stat:first-child { border-left: 0; }
.stat b { color: var(--on-petrol); font-weight: 500; font-variant-numeric: tabular-nums; }

/* ---------- секции на бумаге ---------- */
.section { padding-block: clamp(80px, 11vh, 150px); position: relative; }
.section.sunk { background: var(--surface-sunk); }
/* фолио секции: хайрлайн во всю ширину + индекс справа */
.section-head {
  max-width: none;
  border-top: 1px solid var(--line);
  padding-top: 26px;
  position: relative;
}
.section-head > * { max-width: 1000px; }
.section-head::after {
  content: attr(data-index);
  position: absolute;
  top: 26px;
  right: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  color: var(--faint);
}
.dark .section-head { border-top-color: var(--petrol-line-soft); }
.dark .section-head::after { color: var(--on-petrol-faint); }
.section-head h2 {
  margin-top: 22px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(30px, 3.6vw, 52px);
  line-height: 1.12;
  letter-spacing: -0.014em;
}
.section-head .lede {
  margin-top: 18px;
  font-size: 18px;
  color: var(--ink-soft);
  max-width: 62ch;
}

/* философия: две колонки */
.philosophy-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(32px, 5vw, 80px);
  margin-top: clamp(36px, 5vh, 64px);
  align-items: start;
}
.philosophy-copy p + p { margin-top: 16px; }
.philosophy-copy p { color: var(--ink-soft); max-width: 58ch; }
.philosophy-copy strong { color: var(--ink); font-weight: 600; }

/* карта боли — мини-график */
.painmap {
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 26px 26px 20px;
}
.painmap-title {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  padding-bottom: 12px;
  border-bottom: 3px double var(--line);
  margin-bottom: 14px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.painrow .pval { font-variant-numeric: tabular-nums; }
.painrow { display: grid; grid-template-columns: 132px 1fr 44px; align-items: center; gap: 14px; padding-block: 9px; }
.painrow + .painrow { border-top: 1px solid var(--line-soft); }
.painrow .plabel { font-size: 14px; font-weight: 500; color: var(--ink-soft); }
.painrow .pval { font-family: var(--font-mono); font-size: 12px; color: var(--muted); text-align: right; }
.pbar { height: 8px; background: var(--surface-sunk); position: relative; overflow: hidden; }
.pbar i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  background: var(--bar, var(--accent));
  transition: width 1.1s var(--ease-out);
}
.in .pbar i { width: var(--w); }
.painmap-note { margin-top: 16px; font-size: 12.5px; color: var(--faint); }

/* ---------- шаги ---------- */
.steps { margin-top: clamp(40px, 6vh, 72px); border-top: 1px solid var(--line); }
.step {
  display: grid;
  grid-template-columns: 120px 1.15fr 0.85fr;
  gap: clamp(20px, 3vw, 48px);
  padding-block: clamp(32px, 4.5vh, 56px);
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.step-num {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--accent-strong);
  padding-top: 8px;
}
.step h3 {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.2vw, 30px);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
}
.step p { margin-top: 12px; color: var(--ink-soft); max-width: 52ch; }
.step-viz { justify-self: stretch; align-self: center; }
.step-viz svg { width: 100%; height: auto; display: block; }
.svg-label { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.08em; fill: var(--muted); text-transform: uppercase; }
.svg-line { stroke: var(--line); }
.svg-accent { stroke: var(--accent); }

/* ---------- вопросы ---------- */
.qa-list { margin-top: clamp(36px, 5vh, 64px); border-top: 1px solid var(--line); }
.qa-row {
  display: grid;
  grid-template-columns: 86px 300px 1fr;
  gap: clamp(18px, 3vw, 44px);
  padding-block: clamp(26px, 3.6vh, 42px);
  border-bottom: 1px solid var(--line);
  transition: background 0.3s var(--ease-out);
}
.qa-row:hover { background: oklch(0.966 0.005 100 / 0.6); }
.qa-num { font-family: var(--font-mono); font-size: 12.5px; color: var(--faint); padding-top: 6px; }
.qa-domain { font-weight: 600; font-size: 18px; letter-spacing: -0.005em; padding-top: 3px; }
.qa-qs { display: grid; gap: 14px; }
.qa-qs p {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(17px, 1.6vw, 21px);
  line-height: 1.42;
  color: var(--ink-soft);
  max-width: 62ch;
}
.qa-qs p::before { content: "— "; color: var(--accent); }

/* ---------- тёмная секция: три контура ---------- */
.dark {
  background:
    radial-gradient(1000px 600px at 90% -10%, oklch(0.36 0.07 210 / 0.5), transparent 60%),
    var(--petrol);
  color: var(--on-petrol);
  position: relative;
}
.dark::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.035 0'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
.dark > .container, .dark > .ecg-band { position: relative; z-index: 1; }
.dark .section-head h2 { color: var(--on-petrol); }
.dark .section-head .lede { color: var(--on-petrol-soft); }
.contours {
  margin-top: clamp(40px, 6vh, 72px);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--petrol-line-soft);
  border: 1px solid var(--petrol-line-soft);
}
.contour {
  background: oklch(0.265 0.052 219 / 0.92);
  padding: clamp(26px, 2.6vw, 40px);
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 380px;
  transition: background 0.35s var(--ease-out);
  position: relative;
}
.contour::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--pulse);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s var(--ease-out);
}
.contour.sim-c::before { background: var(--sim-bright); }
.contour:hover { background: oklch(0.3 0.056 217); }
.contour:hover::before { transform: scaleX(1); }
/* spotlight под курсором (тёмные карточки) */
.contour::after, .gnote::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.35s var(--ease-out);
  background: radial-gradient(240px circle at var(--mx, 50%) var(--my, 50%), oklch(0.87 0.1 182 / 0.08), transparent 65%);
}
.contour:hover::after, .gnote:hover::after { opacity: 1; }
.gnote { position: relative; }
.contour-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--pulse);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.contour-tag .t-order { color: var(--on-petrol-faint); }
.contour.sim-c .contour-tag { color: var(--sim-bright); }
.contour h3 {
  font-family: var(--font-display);
  font-size: clamp(22px, 2vw, 28px);
  font-weight: 600;
  line-height: 1.18;
}
.contour p { color: var(--on-petrol-soft); font-size: 15.5px; flex: 1; }
.contour-viz { height: 84px; }
.contour-viz svg { width: 100%; height: 100%; display: block; }
.contour-spec {
  border-top: 1px solid var(--petrol-line-soft);
  padding-top: 14px;
  display: grid;
  gap: 7px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--on-petrol-faint);
}
.contour-spec span::before { content: "── "; color: var(--pulse); opacity: 0.6; }
.contour.sim-c .contour-spec span::before { color: var(--sim-bright); }
.contours-cta { margin-top: 40px; display: flex; justify-content: center; }

/* ---------- честность ---------- */
.honesty-grid {
  display: grid;
  grid-template-columns: 1fr 0.95fr;
  gap: clamp(32px, 5vw, 80px);
  margin-top: clamp(36px, 5vh, 64px);
  align-items: start;
}
.honesty-points { display: grid; gap: 0; border-top: 1px solid var(--line); }
.hpoint { padding: 20px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 30px 1fr; gap: 14px; }
.hpoint .hp-i { font-family: var(--font-mono); font-size: 12px; color: var(--accent-strong); padding-top: 3px; }
.hpoint b { display: block; font-weight: 600; margin-bottom: 4px; }
.hpoint p { color: var(--ink-soft); font-size: 15.5px; max-width: 52ch; }

/* паспорт расчёта — документ */
.passport {
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 14px 34px oklch(0.26 0.017 225 / 0.07);
  font-family: var(--font-mono);
  font-size: 13px;
  position: sticky;
  top: 40px;
}
.passport-head {
  padding: 18px 24px 14px;
  border-bottom: 3px double var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 11px;
  color: var(--muted);
}
.passport-head .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--positive-dot); }
.passport-body { padding: 10px 24px 6px; }
.prow {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding-block: 9px;
  border-bottom: 1px dashed var(--line-soft);
}
.prow:last-child { border-bottom: 0; }
.prow .pk { color: var(--muted); }
.prow .pv { color: var(--ink); text-align: right; }
.prow .pv.good { color: var(--positive-dot); }
.passport-foot {
  border-top: 1px solid var(--line);
  padding: 16px 24px 18px;
  color: var(--ink-soft);
  font-size: 12px;
  line-height: 1.6;
  position: relative;
}
/* круглая печать — документный артефакт, с выносом за край листа */
.stamp-seal {
  position: absolute;
  right: -16px;
  bottom: -20px;
  width: 100px;
  height: 100px;
  color: var(--accent);
  opacity: 0.4;
  transform: rotate(-8deg);
  pointer-events: none;
  font-family: var(--font-mono);
}
.passport-foot { padding-right: 92px; }
.passport-foot b { color: var(--ink); font-weight: 500; }
.passport-stamp {
  margin-top: 10px;
  display: inline-block;
  border: 1px solid var(--accent-line);
  color: var(--accent-strong);
  padding: 4px 10px;
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  transform: rotate(-1.2deg);
}

/* ---------- финальный CTA ---------- */
.cta-final { text-align: center; padding-block: clamp(100px, 16vh, 190px); }
.cta-final h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(38px, 5.4vw, 84px);
  letter-spacing: -0.015em;
  line-height: 1.05;
}
.cta-final .lede {
  margin: 22px auto 0;
  max-width: 54ch;
  color: var(--on-petrol-soft);
  font-size: 18px;
  line-height: 1.68;
}
.cta-final .hero-cta { justify-content: center; }
.cta-note {
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--on-petrol-faint);
}

/* ---------- футер ---------- */
.footer { background: var(--petrol-deep); color: var(--on-petrol-soft); border-top: 1px solid var(--petrol-line-soft); }
.footer-row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px 48px;
  justify-content: space-between;
  align-items: flex-start;
  padding-block: 48px 20px;
}
.footer .nav-links { flex-wrap: wrap; }
.footer-meta {
  padding-block: 18px 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 32px;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--on-petrol-faint);
}

/* ---------- страница «Технологии» ---------- */
.subhero {
  background:
    radial-gradient(900px 520px at 85% 0%, oklch(0.36 0.07 210 / 0.5), transparent 60%),
    var(--petrol);
  color: var(--on-petrol);
  padding-top: clamp(130px, 18vh, 190px);
  padding-bottom: clamp(56px, 8vh, 90px);
  position: relative;
  overflow: hidden;
}
.subhero h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(38px, 5vw, 72px);
  letter-spacing: -0.015em;
  line-height: 1.06;
  max-width: 18ch;
}
.subhero .lede { margin-top: 20px; max-width: 60ch; color: var(--on-petrol-soft); font-size: 18px; }
.toc {
  margin-top: 40px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.toc a {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--on-petrol-soft);
  border: 1px solid var(--petrol-line);
  border-radius: 999px;
  padding: 9px 16px;
  transition: all 0.25s var(--ease-out);
}
.toc a:hover { border-color: var(--pulse); color: var(--pulse); }

.tech-section { padding-block: clamp(64px, 9vh, 110px); border-bottom: 1px solid var(--line); }
.tech-section:last-of-type { border-bottom: 0; }
.tech-grid {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(22px, 3.2vw, 56px);
  align-items: start;
}
.tech-num { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.14em; color: var(--accent-strong); padding-top: 10px; }
.tech-copy h2 {
  font-family: var(--font-display);
  font-size: clamp(26px, 2.6vw, 38px);
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.15;
}
.tech-copy .simple-tag, .tech-spec-tag {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  display: block;
  margin: 26px 0 10px;
}
.tech-copy p { color: var(--ink-soft); max-width: 56ch; }
.tech-copy p + p { margin-top: 12px; }
.tech-spec {
  background: var(--surface-sunk);
  border: 1px solid var(--line);
  padding: 22px 24px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--ink-soft);
}
.tech-spec .tech-spec-tag { margin: 0 0 12px; }
.tech-spec ul { list-style: none; display: grid; gap: 9px; }
.tech-spec li { padding-left: 22px; text-indent: -22px; }
.tech-spec li::before { content: "── "; color: var(--accent); }
.tech-spec b { color: var(--ink); font-weight: 500; }
.tech-note { margin-top: 14px; font-size: 11.5px; color: var(--faint); }

/* ---------- разворот «граф знаний» (техстраница) ---------- */
.graph-band { padding-block: clamp(72px, 10vh, 130px); }
.graph-band .kicker { color: var(--sim-bright); }
.graph-band .kicker::before { background: currentColor; }
.graph-band h2 {
  margin-top: 22px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(30px, 3.6vw, 52px);
  line-height: 1.1;
  letter-spacing: -0.014em;
  color: var(--on-petrol);
  max-width: 22ch;
}
.graph-band .lede { margin-top: 16px; max-width: 62ch; color: var(--on-petrol-soft); font-size: 17.5px; }

.graph-stage {
  margin-top: clamp(36px, 5vh, 56px);
  border: 1px solid var(--petrol-line-soft);
  background: oklch(0.255 0.05 220 / 0.85);
  position: relative;
}
.graph-stage-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 14px 22px;
  border-bottom: 1px solid var(--petrol-line-soft);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--on-petrol-faint);
}
.graph-stage svg { display: block; width: 100%; height: auto; }
.graph-divider { stroke: var(--petrol-line-soft); stroke-dasharray: 3 6; }
.gedge {
  stroke: var(--sim-bright);
  stroke-width: 1.1;
  fill: none;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  opacity: 0.55;
  transition: stroke-dashoffset 1.1s var(--ease-out);
  transition-delay: var(--d, 0s);
}
.gedge.strong { stroke-width: 1.8; opacity: 0.8; }
.gedge.weak { stroke: oklch(0.7 0.03 208); opacity: 0.28; }
.in .gedge { stroke-dashoffset: 0; }
.gnode {
  fill: var(--sim-bright);
  transform-box: fill-box;
  transform-origin: center;
  transform: scale(0);
  transition: transform 0.7s var(--ease-out);
  transition-delay: var(--d, 0s);
}
.in .gnode { transform: scale(1); }
.gnode.theme { fill: var(--pulse); }
.gnode.dim { fill: oklch(0.7 0.03 208); opacity: 0.55; }
.glabel { font-family: var(--font-mono); font-size: 9px; letter-spacing: 0.1em; fill: var(--on-petrol-faint); text-transform: uppercase; }
.graph-verdicts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--petrol-line-soft);
}
.gverdict {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-petrol-soft);
}
.gverdict + .gverdict { border-left: 1px solid var(--petrol-line-soft); }
.gverdict .vdot { width: 8px; height: 8px; border-radius: 50%; flex: 0 0 auto; }

/* пайплайн глубокой симуляции */
.pipeline {
  margin-top: clamp(28px, 4vh, 44px);
  display: flex;
  align-items: stretch;
  flex-wrap: wrap;
  gap: 10px;
}
.pipe {
  flex: 1 1 auto;
  border: 1px solid var(--petrol-line);
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--on-petrol-soft);
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 130px;
}
.pipe b { color: var(--on-petrol); font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; font-size: 10.5px; }
.pipe.sim-p { border-color: oklch(0.76 0.095 300 / 0.5); }
.pipe.sim-p b { color: var(--sim-bright); }
.pipe-arrow {
  align-self: center;
  color: var(--on-petrol-faint);
  font-family: var(--font-mono);
  font-size: 14px;
  flex: 0 0 auto;
}
.graph-notes {
  margin-top: clamp(28px, 4vh, 44px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1px;
  background: var(--petrol-line-soft);
  border: 1px solid var(--petrol-line-soft);
}
.gnote { background: oklch(0.265 0.052 219 / 0.92); padding: 18px 20px; }
.gnote b { display: block; font-weight: 600; color: var(--on-petrol); margin-bottom: 6px; font-size: 14.5px; }
.gnote p { color: var(--on-petrol-soft); font-size: 13.5px; line-height: 1.55; }

@media (max-width: 760px) {
  .pipeline { flex-direction: column; }
  .pipe-arrow { transform: rotate(90deg); align-self: flex-start; margin-left: 22px; }
  .graph-verdicts { grid-template-columns: 1fr; }
  .gverdict + .gverdict { border-left: 0; border-top: 1px solid var(--petrol-line-soft); }
}
@media (prefers-reduced-motion: reduce) {
  .gedge, .gnode { transition: none; stroke-dashoffset: 0; transform: none; }
}
html.shot .gedge { stroke-dashoffset: 0; transition: none; }
html.shot .gnode { transform: scale(1); transition: none; }

/* ---------- страница «Прогон»: акты, мокапы платформы, интерактив ---------- */
.acthead {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--line);
  padding-top: 22px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent-strong);
}
.acthead .act-steps { color: var(--faint); letter-spacing: 0.16em; }
.dark .acthead, .subhero .acthead { border-top-color: var(--petrol-line-soft); color: var(--pulse); }
.dark .acthead .act-steps { color: var(--on-petrol-faint); }
.act-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(28px, 3.4vw, 48px);
  line-height: 1.12;
  letter-spacing: -0.014em;
  margin-top: 26px;
  max-width: 21ch;
}
.act-lede { margin-top: 16px; max-width: 62ch; color: var(--ink-soft); font-size: 17.5px; }
.dark .act-lede { color: var(--on-petrol-soft); }

.runstep { padding-block: clamp(56px, 8vh, 96px); }
.runstep-head {
  display: grid;
  grid-template-columns: 108px minmax(0, 1fr);
  gap: clamp(20px, 3vw, 48px);
  margin-bottom: 34px;
}
.runstep-num { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.14em; color: var(--accent-strong); padding-top: 9px; }
.runstep-head h3 {
  font-family: var(--font-display);
  font-size: clamp(24px, 2.4vw, 34px);
  font-weight: 600;
  letter-spacing: -0.011em;
  line-height: 1.16;
}
.runstep-head p { margin-top: 12px; color: var(--ink-soft); max-width: 60ch; }
.runstep-head .stepnote { margin-top: 10px; font-size: 13.5px; color: var(--muted); }

/* рамка приложения: мокап интерфейса платформы (светлая тема «Пульса») */
.appframe {
  border: 1px solid var(--line);
  background: var(--paper);
  box-shadow: 0 18px 44px oklch(0.26 0.017 225 / 0.09);
  color: var(--ink);
  font-size: 13.5px;
  overflow: hidden;
  transition: box-shadow 0.35s var(--ease-out), transform 0.35s var(--ease-out);
}
.appframe:hover { box-shadow: 0 26px 60px oklch(0.26 0.017 225 / 0.13); transform: translateY(-2px); }
.appframe-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-sunk);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.appframe-bar .crumb { color: var(--ink-soft); }
.appframe-body { display: grid; grid-template-columns: 168px minmax(0, 1fr); min-height: 320px; }
.appnav {
  border-right: 1px solid var(--line-soft);
  background: var(--surface);
  padding: 14px 0;
  font-size: 12.5px;
  color: var(--muted);
}
.appnav .an-mark { display: flex; align-items: center; gap: 7px; padding: 2px 16px 12px; color: var(--ink); font-weight: 600; font-size: 13px; }
.appnav a { display: block; padding: 7px 16px; color: inherit; }
.appnav a.on { color: var(--accent-ink); background: var(--accent-soft); }
.appmain { padding: 20px 22px 22px; min-width: 0; }
.appmain h4 { font-size: 15px; font-weight: 600; letter-spacing: -0.005em; margin-bottom: 4px; }
.appmain .app-sub { color: var(--muted); font-size: 12.5px; margin-bottom: 16px; }
.appframe-foot {
  border-top: 1px solid var(--line-soft);
  padding: 9px 16px;
  font-size: 11.5px;
  color: var(--faint);
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

/* элементы внутри мокапов */
.field { border: 1px solid var(--line); background: var(--surface); padding: 12px 14px; }
.field .f-label { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.passgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-top: 12px; }
.passgrid .pg { border: 1px solid var(--line); background: var(--surface); padding: 10px 12px; }
.passgrid .pg b { display: block; font-weight: 600; font-size: 13px; margin-top: 3px; }
.passgrid .pg span { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--accent-line);
  background: var(--accent-soft);
  color: var(--accent-ink);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 5px 10px;
}
.variant-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.variant { border: 1px solid var(--line); background: var(--surface); padding: 14px 16px; }
.variant .v-tag { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.14em; color: var(--accent-strong); margin-bottom: 8px; }
.variant p { font-size: 13.5px; color: var(--ink-soft); }
.docrow { display: flex; justify-content: space-between; gap: 14px; padding: 8px 0; border-bottom: 1px dashed var(--line-soft); font-family: var(--font-mono); font-size: 12px; }
.docrow:last-child { border-bottom: 0; }
.docrow .dk { color: var(--muted); }
.districts { display: grid; gap: 6px; margin-top: 12px; }
.drow { display: grid; grid-template-columns: 128px 1fr 34px; align-items: center; gap: 10px; font-size: 12.5px; color: var(--ink-soft); }
.drow .dbar { height: 6px; background: var(--surface-sunk); position: relative; }
.drow .dbar i { position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--accent); opacity: 0.75; }
.drow .dn { font-family: var(--font-mono); font-size: 11px; color: var(--muted); text-align: right; }
.traffic { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); background: var(--surface); font-weight: 600; }
.traffic .tdot { width: 10px; height: 10px; border-radius: 50%; background: var(--caution-dot); }
.camp { border: 1px solid var(--line); background: var(--surface); color: var(--ink); padding: 12px 14px; }
.camp .c-head { display: flex; justify-content: space-between; gap: 10px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.camp blockquote { font-family: var(--font-display); font-size: 14.5px; line-height: 1.45; color: var(--ink-soft); }
.rec-list { list-style: none; counter-reset: rec; margin: 0; padding: 0; }
.rec-list li {
  counter-increment: rec;
  display: grid;
  grid-template-columns: 30px 1fr;
  gap: 4px 10px;
  padding: 11px 0;
  border-bottom: 1px dashed var(--line-soft);
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-soft);
}
.rec-list li:last-child { border-bottom: 0; padding-bottom: 4px; }
.rec-list li::before {
  content: counter(rec, decimal-leading-zero);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--accent-strong);
  padding-top: 3px;
}
.rec-owner {
  grid-column: 2;
  justify-self: start;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--line);
  padding: 3px 8px;
}
.report-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.report-grid .span2 { grid-column: 1 / -1; }

/* инцидент-карточка (секция «Ранние сигналы») */
.incident {
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 14px 34px oklch(0.26 0.017 225 / 0.07);
}
.incident-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px;
  border-bottom: 3px double var(--line);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.incident-body { padding: 16px 20px; }
.incident-title { font-weight: 600; font-size: 16.5px; letter-spacing: -0.005em; display: flex; align-items: center; gap: 10px; }
.incident-title .idot { width: 8px; height: 8px; border-radius: 50%; background: var(--negative-dot); flex: 0 0 auto; }
.incident-meta { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 8px 18px; font-family: var(--font-mono); font-size: 11px; color: var(--muted); }
.incident-actions { margin-top: 16px; display: flex; gap: 8px; flex-wrap: wrap; }
.incident-foot { border-top: 1px solid var(--line-soft); padding: 10px 20px; font-size: 11.5px; color: var(--faint); }

/* профиль жителя (плавающая карточка в хиро) */
.resident-card {
  position: absolute;
  right: var(--gutter);
  top: 54%;
  transform: translateY(-50%) rotate(1.6deg);
  width: min(30vw, 330px);
  z-index: 3;
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--line);
  box-shadow: 0 30px 70px oklch(0.14 0.035 222 / 0.5);
  font-family: var(--font-mono);
  font-size: 12.5px;
}
.resident-card .rc-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 3px double var(--line);
  font-size: 10.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.resident-card .rc-body { padding: 6px 16px 10px; }
.resident-card .rc-foot { border-top: 1px solid var(--line-soft); padding: 9px 16px; font-size: 10.5px; color: var(--faint); }

/* интерактив порога различимости */
.threshold-lab {
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  padding: clamp(20px, 2.6vw, 32px);
}
.tl-title { font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted); padding-bottom: 12px; border-bottom: 3px double var(--line); margin-bottom: 18px; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.tl-chart { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 56px); align-items: end; height: 190px; margin: 8px auto 0; max-width: 660px; }
.tl-bar { position: relative; height: 100%; }
.tl-bar .fill { position: absolute; bottom: 0; left: 0; right: 0; background: var(--accent); opacity: 0.8; }
.tl-bar .ci { position: absolute; left: 50%; width: 1.5px; background: var(--ink); transform: translateX(-50%); }
.tl-bar .ci::before, .tl-bar .ci::after { content: ""; position: absolute; left: 50%; transform: translateX(-50%); width: 14px; height: 1.5px; background: var(--ink); }
.tl-bar .ci::before { top: 0; }
.tl-bar .ci::after { bottom: 0; }
.tl-bar .tl-val { position: absolute; left: 0; right: 0; text-align: center; font-family: var(--font-mono); font-size: 12px; color: var(--ink); }
.tl-bar .tl-name { position: absolute; top: 100%; left: 0; right: 0; text-align: center; margin-top: 8px; font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.tl-controls { margin-top: 44px; display: grid; gap: 10px; }
.tl-controls label { font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); display: flex; justify-content: space-between; gap: 10px; }
.tl-controls input[type="range"] { width: 100%; accent-color: var(--accent); }
.tl-verdict {
  margin-top: 14px;
  border: 1px solid var(--line);
  background: var(--surface-sunk);
  padding: 12px 14px;
  font-size: 13.5px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.tl-verdict .vdot { width: 9px; height: 9px; border-radius: 50%; background: var(--caution-dot); flex: 0 0 auto; }
.tl-verdict.ok .vdot { background: var(--positive-dot); }
.tl-note { margin-top: 12px; font-size: 12px; color: var(--faint); }
.tl-scalenote {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--faint);
}

/* шаги в тёмном акте */
.dark .runstep-num { color: var(--pulse); }
.dark .runstep-head p { color: var(--on-petrol-soft); }
.dark .runstep-head .stepnote { color: var(--on-petrol-faint); }
.dark .acthead + .act-title { color: var(--on-petrol); }

@media (max-width: 1080px) {
  .resident-card { display: none; }
}
@media (min-width: 1081px) {
  /* не даём чипам шагов уходить под карточку жителя */
  .subhero .toc:has(~ .resident-card) { max-width: calc(100% - min(30vw, 330px) - 32px); }
}
@media (max-width: 760px) {
  .appframe-body { grid-template-columns: 1fr; }
  .appnav { display: none; }
  .variant-grid, .report-grid, .tl-chart { grid-template-columns: 1fr; }
  .tl-chart { height: auto; gap: 52px; }
  .tl-bar { height: 150px; }
  .runstep-head { grid-template-columns: 1fr; gap: 10px; }
}

/* ---------- появление при скролле ---------- */
.reveal { opacity: 0; transform: translateY(18px); }
.in .reveal, .reveal.in {
  opacity: 1;
  transform: none;
  transition: opacity 0.75s var(--ease-out), transform 0.75s var(--ease-out);
  transition-delay: var(--d, 0s);
}
/* элементы hero — каскад при загрузке */
.rise { opacity: 0; transform: translateY(30px); animation: rise 1s var(--ease-out) forwards; animation-delay: var(--d, 0s); }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ---------- ротация слова ---------- */
.rot span.leaving { animation: rot-out 0.5s var(--ease-out) forwards; }
.rot span.entering { animation: rot-in 0.6s var(--ease-out); }
@keyframes rot-out { to { opacity: 0; transform: translateY(-0.55em); filter: blur(3px); } }
@keyframes rot-in { from { opacity: 0; transform: translateY(0.55em); filter: blur(3px); } }

/* ---------- адаптив ---------- */
@media (max-width: 1280px) {
  .porthole-wrap { width: min(30vw, 400px); }
}
@media (max-width: 1080px) {
  .hero-main { padding-top: 130px; }
  .porthole-wrap { display: none; }
  .contours { grid-template-columns: 1fr; }
  .contour { min-height: 0; }
  .tech-grid { grid-template-columns: 64px 1fr; }
  .tech-grid .tech-spec { grid-column: 2; }
  .honesty-grid, .philosophy-grid { grid-template-columns: 1fr; }
  .passport { position: static; }
}
@media (max-width: 760px) {
  .nav-links a:not(.btn) { display: none; }
  .nav .btn { padding: 11px 16px; font-size: 10.5px; letter-spacing: 0.08em; }
  .nav .wm-city { display: none; }
  .nav-row { gap: 12px; }
  .step { grid-template-columns: 1fr; gap: 14px; }
  .step-num { padding: 0; }
  .step-viz { max-width: 420px; }
  .qa-row { grid-template-columns: 1fr; gap: 10px; }
  .qa-num { display: none; }
  .tech-grid { grid-template-columns: 1fr; }
  .tech-num { padding: 0; }
  .stamp-seal { right: 6px; bottom: -12px; width: 82px; height: 82px; }
  .passport-foot { padding-right: 78px; }
  .statbar-row { flex-direction: column; }
  .stat { border-left: 0; border-top: 1px solid var(--petrol-line-soft); justify-content: flex-start; padding: 13px 4px; }
  .stat:first-child { border-top: 0; }
  .hero h1 { max-width: none; }
  .hero h1 .rot { min-width: 0; }
}

/* служебный режим снимков (?shot=) — всё в финальном состоянии, без движения */
html.shot .reveal, html.shot .rise {
  opacity: 1 !important;
  transform: none !important;
  animation: none !important;
  transition: none !important;
}
html.shot { scroll-behavior: auto; }
html.shot .porthole-ring, html.shot .porthole-sweep { animation: none; }

@media (max-width: 400px) {
  .btn { white-space: normal; text-align: center; }
  .nav .btn { white-space: nowrap; padding: 10px 12px; font-size: 10px; }
  .hero h1 { font-size: 36px; }
  .hero h1 .rot { white-space: normal; }
  .wordmark .wm-name { font-size: 19px; }
}

/* ---------- 404 ---------- */
.err-page {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: radial-gradient(1000px 640px at 70% 10%, oklch(0.36 0.07 210 / 0.5), transparent 60%), var(--petrol);
  color: var(--on-petrol);
  padding: 40px var(--gutter);
  position: relative;
  overflow: hidden;
}
.err-code { font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.3em; color: var(--pulse); }
.err-page h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(38px, 6vw, 76px); margin-top: 18px; letter-spacing: -0.015em; }
.err-page p { margin-top: 16px; color: var(--on-petrol-soft); max-width: 46ch; }
.err-page .hero-cta { justify-content: center; }
.err-ecg { width: min(560px, 86vw); margin-top: 40px; }
.err-ecg svg { width: 100%; height: 70px; display: block; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rise, .reveal, .in .reveal { animation: none; transition: none; opacity: 1; transform: none; }
  .porthole-ring { animation: none; }
  .porthole-sweep { animation: none; opacity: 0; }
  .contour::before { transition: none; }
  .rot span.leaving, .rot span.entering { animation: none; }
}
