:root {
  --ink: #08080A;
  --surface: #121014;
  --surface-hi: #17141A;
  --gold: #D9B25F;
  --gold-bright: #E6C878;
  --gold-line: rgba(217, 178, 95, .20);
  --on-gold: #17120A;
  --text: #F2EEE6;
  --text-dim: #928B7C;
  --ok: #34C759;
  --warn: #FF9500;
  --err: #FF3B30;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --wrap: 1080px;
  --gap: 24px;
  --radius: 14px;
}

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

html { color-scheme: dark; }

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

img, svg { max-width: 100%; height: auto; }

a { color: var(--gold); text-decoration: none; }
a:hover { color: var(--gold-bright); text-decoration: underline; }

:focus-visible { outline: 2px solid var(--gold-bright); outline-offset: 3px; border-radius: 4px; }

.skip {
  position: absolute; left: -9999px; top: 0;
  background: var(--gold); color: var(--on-gold); padding: 10px 16px; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; z-index: 10; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }

/* Фирменная деталь Ноктюрна: мелкие заглавные золотые лейблы */
.label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 12px;
}

h1, h2, h3 { line-height: 1.2; text-wrap: balance; margin: 0 0 16px; }
h1 { font-size: clamp(32px, 5vw, 52px); font-weight: 700; letter-spacing: -.02em; }
h2 { font-size: clamp(24px, 3.4vw, 34px); font-weight: 650; }
h3 { font-size: 20px; font-weight: 600; }

p { margin: 0 0 16px; max-width: 68ch; }
.lead { font-size: clamp(18px, 2.2vw, 21px); color: var(--text-dim); }

section { padding: 72px 0; }
section + section { border-top: 1px solid var(--gold-line); }

.grid { display: grid; gap: var(--gap); grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

.card {
  background: var(--surface);
  border: 1px solid var(--gold-line);
  border-radius: var(--radius);
  padding: 24px;
}
.card h3 { margin-bottom: 8px; }
.card p { margin-bottom: 0; color: var(--text-dim); }

.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--gold); color: var(--on-gold);
  font-weight: 600; font-size: 16px;
  padding: 13px 26px; border-radius: 999px; border: 1px solid var(--gold);
  transition: background .2s ease-out, transform .2s ease-out;
}
.btn:hover { background: var(--gold-bright); color: var(--on-gold); text-decoration: none; }
.btn-ghost { background: transparent; color: var(--gold); }
.btn-ghost:hover { background: rgba(217, 178, 95, .10); color: var(--gold-bright); }

.steps { counter-reset: step; list-style: none; padding: 0; display: grid; gap: var(--gap); }
.steps li { counter-increment: step; padding-left: 52px; position: relative; }
.steps li::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  width: 36px; height: 36px; display: grid; place-items: center;
  border: 1px solid var(--gold-line); border-radius: 50%;
  color: var(--gold); font-family: var(--mono); font-size: 15px;
}

.table-scroll { overflow-x: auto; }
.compare { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 560px; }
.compare th, .compare td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--gold-line); vertical-align: top; }
.compare thead th { color: var(--gold); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.compare .num { font-family: var(--mono); font-variant-numeric: tabular-nums; }

.answers dt { font-weight: 600; margin-top: 16px; }
.answers dd { margin: 6px 0 0; color: var(--text-dim); max-width: 68ch; }

.faq { display: grid; gap: 12px; }
.faq details {
  background: var(--surface); border: 1px solid var(--gold-line);
  border-radius: var(--radius); padding: 16px 20px;
}
.faq summary { cursor: pointer; font-weight: 600; }
.faq details[open] summary { color: var(--gold); margin-bottom: 10px; }

.note {
  background: var(--surface-hi); border-left: 2px solid var(--gold);
  border-radius: 0 8px 8px 0; padding: 14px 18px; color: var(--text-dim); font-size: 15px;
}

/* Мокапы под будущие скриншоты — геометрия контейнера фиксирована заранее. */
.shot { border: 1px solid var(--gold-line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.shot-desktop { aspect-ratio: 16 / 10; }
.shot-phone { aspect-ratio: 9 / 19.5; max-width: 260px; }
.shot-mock { width: 100%; height: 100%; display: grid; place-items: center; gap: 10px; padding: 20px; color: var(--text-dim); }
.shot-mock .label { margin: 0; }

/* Утилиты вместо inline-стилей: CSP запрещает style="..." в разметке. */
.mt-lg { margin-top: 32px; }
.checksum {
  font-family: var(--mono); font-size: 13px; word-break: break-all;
  color: var(--text-dim); font-variant-numeric: tabular-nums;
}

.prose h2 { margin-top: 40px; }
.prose ul, .prose ol { max-width: 68ch; color: var(--text); }
.prose li { margin-bottom: 8px; }
.prose code { font-family: var(--mono); font-size: .92em; color: var(--gold); }

.site-head { border-bottom: 1px solid var(--gold-line); position: sticky; top: 0; background: rgba(8, 8, 10, .92); backdrop-filter: blur(8px); z-index: 5; }
.head-inner { display: flex; align-items: center; gap: 20px; min-height: 64px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 650; }
.brand:hover { text-decoration: none; color: var(--gold-bright); }
.site-nav { display: flex; gap: 18px; flex: 1; flex-wrap: wrap; font-size: 15px; }
.site-nav a { color: var(--text-dim); }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--gold); text-decoration: none; }
.lang-switch { font-size: 14px; border: 1px solid var(--gold-line); border-radius: 999px; padding: 6px 14px; color: var(--text-dim); }
.lang-switch:hover { color: var(--gold); border-color: var(--gold); text-decoration: none; }

.site-foot { border-top: 1px solid var(--gold-line); padding: 32px 0; margin-top: 40px; }
.foot-inner { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; align-items: center; }
.foot-brand { color: var(--text-dim); font-size: 15px; margin: 0; }
.foot-nav { display: flex; gap: 18px; flex-wrap: wrap; font-size: 14px; }
.foot-nav a { color: var(--text-dim); }
.foot-nav a:hover { color: var(--gold); }

@media (max-width: 640px) {
  body { font-size: 16px; }
  section { padding: 48px 0; }
  .head-inner { min-height: 56px; }
  .site-nav { order: 3; width: 100%; gap: 14px; padding-bottom: 10px; }
}

.hero { padding: 88px 0 72px; }
.hero-inner { display: grid; gap: 48px; grid-template-columns: 1fr 1fr; align-items: center; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }

.hero-demo {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--gold-line);
  border-radius: var(--radius);
  padding: 28px;
  display: grid;
  gap: 20px;
}
.hero-line p { margin: 0; }
.hero-demo .raw { color: var(--text-dim); font-style: italic; min-height: 3em; }
.hero-demo .clean { color: var(--text); font-weight: 600; min-height: 1.6em; }
.hero-demo .raw.typing::after,
.hero-demo .clean.appear::after {
  content: ''; display: inline-block; width: 2px; height: 1em;
  background: var(--gold); margin-left: 2px; vertical-align: -.15em;
  animation: caret .9s step-end infinite;
}
@keyframes caret { 50% { opacity: 0; } }

.pulse { position: relative; width: 64px; height: 64px; display: grid; place-items: center; }
.pulse .ring {
  position: absolute; inset: 0; border: 1px solid var(--gold); border-radius: 50%;
  opacity: 0; animation: pulse 2.4s ease-out infinite;
}
.pulse .ring:nth-child(3) { animation-delay: .8s; }
.pulse .ring:nth-child(4) { animation-delay: 1.6s; }
@keyframes pulse {
  0%   { transform: scale(1);   opacity: .55; }
  100% { transform: scale(2.1); opacity: 0; }
}

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; gap: 32px; }
  .hero { padding: 56px 0 48px; }
}

.compare tr[data-winner="us"] th[scope="row"] { border-left: 2px solid var(--gold); padding-left: 12px; }
.compare tr[data-winner="them"] th[scope="row"] { border-left: 2px solid var(--text-dim); padding-left: 12px; }
.compare tr[data-winner="tie"] th[scope="row"] { border-left: 2px solid transparent; padding-left: 12px; }

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