/* ============================================================
   AllDash — лендинг (редакционная вёрстка, 2026)
   Manrope (гротеск) + Playfair Display Italic (акценты)
   Референсы: MORPH/Kimi, DeepSeek Harness, тренды Tilda 2026
   ============================================================ */

/* --- Шрифты (self-host, переменные) --- */
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/static/fonts/manrope-cyrillic-var.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/static/fonts/manrope-latin-var.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Playfair Display';
  font-style: italic;
  font-weight: 400 900;
  font-display: swap;
  src: url('/static/fonts/playfair-italic-cyrillic-var.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Playfair Display';
  font-style: italic;
  font-weight: 400 900;
  font-display: swap;
  src: url('/static/fonts/playfair-italic-latin-var.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --font-d: 'Manrope', Inter, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-a: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-mono: ui-monospace, 'Cascadia Code', Consolas, Menlo, monospace;
  --ease: cubic-bezier(.22, .61, .21, 1);
  --ink: var(--surface-900);
  --accent-2: var(--accent-500);
}

body.landing { /* всегда тёмная: html[data-theme=dark] */
  font-family: var(--font-d);
  font-size: 15.5px;
  line-height: 24px;
  color: var(--ink);
  background: var(--surface-100);
}

/* Курсивные акценты в заголовках */
h1 em, h2 em, .cta em {
  font-family: var(--font-a);
  font-style: italic;
  font-weight: 600;
  letter-spacing: -0.015em;
  /* #113: светлее стартовый стоп — фиолетовый край градиента терял контраст на тёмном */
  background: linear-gradient(100deg, var(--primary-500) 5%, var(--accent-600) 95%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  padding-right: .06em; /* запас под свес курсива */
}
@supports not ((-webkit-background-clip: text) or (background-clip: text)) {
  h1 em, h2 em, .cta em { color: var(--primary-500); }
}

/* --- Кнопки лендинга --- */
.landing .btn { border-radius: 10px; font-weight: 600; letter-spacing: -.005em; }
.landing .btn-lg { padding: 13px 26px; font-size: 15.5px; }
.landing .btn-primary {
  background: linear-gradient(180deg, var(--primary-500), var(--primary-600));
  border: 1px solid var(--primary-700);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 10px 24px -8px rgba(139, 92, 246, .55);
  transition: transform .18s var(--ease), box-shadow .18s var(--ease), filter .18s;
}
.landing .btn-primary:hover {
  background: linear-gradient(180deg, var(--primary-500), var(--primary-600));
  filter: brightness(1.05);
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 14px 30px -8px rgba(139, 92, 246, .6);
}
.landing .btn-primary:active { transform: translateY(0); }
/* цвет явно с элементом a в селекторе: :root[data-theme=dark] a — (0,2,1) и
   без a перекрашивал ссылки-кнопки в #a78bfa, теряя контраст текста
   (находка аудита лендинга 2026-09-30) */
.landing a.btn-primary, .landing a.btn-primary:hover { color: #fff; }
.landing a.btn-invert, .landing a.btn-invert:hover { color: #100f16; }
.landing a.btn-ghost, .landing a.btn-ghost:hover { color: var(--ink); }
.landing .btn-ghost {
  background: rgba(255, 255, 255, .06);
  backdrop-filter: blur(6px);
}
.landing .btn-ghost:hover { background: var(--surface-0); }
.landing .btn .arr { display: inline-block; transition: transform .18s var(--ease); }
.landing .btn:hover .arr { transform: translateX(3px); }

/* ============ Навигация ============ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(24, 23, 37, .92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--surface-200);
}
.nav-inner {
  max-width: 1160px; margin: 0 auto; padding: 0 24px;
  height: 64px; display: flex; align-items: center; gap: 32px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none !important; color: var(--ink); font-weight: 800; font-size: 17px; letter-spacing: -.02em; }
.brand-mark {
  width: 27px; height: 27px; border-radius: 8px;
  background: linear-gradient(135deg, var(--primary-500), var(--primary-700));
  position: relative; flex: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .3), 0 4px 10px -3px rgba(139, 92, 246, .5);
}
.brand-mark::after {
  content: ""; position: absolute; left: 7px; right: 7px; bottom: 6px; height: 13px;
  background:
    linear-gradient(white, white) 0 100%/3.5px 8px no-repeat,
    linear-gradient(white, white) 5.5px 100%/3.5px 12px no-repeat,
    linear-gradient(rgba(255,255,255,.7), rgba(255,255,255,.7)) 11px 100%/3.5px 14px no-repeat;
  border-radius: 1.5px;
}
.nav-links { display: flex; gap: 26px; flex: 1; }
.nav-links a { color: var(--surface-600); font-weight: 600; font-size: 14.5px; text-decoration: none !important; transition: color .15s; }
.nav-links a:hover { color: var(--ink); }
.nav-actions { display: flex; gap: 10px; align-items: center; }
.nav-actions .btn-primary { padding: 9px 16px; font-size: 14px; }
.nav-burger { display: none; }
.nav-burger .ic-close { display: none; }
.nav-burger[aria-expanded="true"] .ic-burger { display: none; }
.nav-burger[aria-expanded="true"] .ic-close { display: block; }

/* Затемнение страницы под открытым меню */
.nav-scrim { display: none; position: fixed; inset: 64px 0 0 0; z-index: 1; background: rgba(10, 9, 18, .55); }
.nav-scrim.visible { display: block; }

.nav-drawer {
  display: none;
  position: absolute; left: 0; right: 0; top: 100%; z-index: 2;
  background: var(--surface-0); border-bottom: 1px solid var(--surface-200);
  box-shadow: var(--shadow-dialog);
  padding: 8px 16px 14px; flex-direction: column; gap: 2px;
  animation: nav-drop .18s var(--ease);
}
@keyframes nav-drop { from { opacity: 0; transform: translateY(-6px); } }
.nav-drawer a {
  padding: 12px 10px; border-radius: var(--radius);
  color: var(--surface-700); font-weight: 600; text-decoration: none !important;
}
.nav-drawer a:hover { background: var(--surface-100); color: var(--ink); }
.nav-drawer a.nav-drawer-cta {
  margin-top: 6px; text-align: center; color: #fff; text-decoration: none;
  background: linear-gradient(180deg, var(--primary-500), var(--primary-600));
  border: 1px solid var(--primary-700);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), 0 10px 24px -8px rgba(139, 92, 246, .55);
}
.nav-drawer .nav-drawer-cta:hover { filter: brightness(1.05); color: #fff; }

/* ============ Hero ============ */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1000px 480px at 82% -12%, rgba(139, 92, 246, .10), transparent 62%),
    radial-gradient(760px 420px at -8% 12%, rgba(34, 211, 238, .08), transparent 55%),
    var(--surface-50);
  border-bottom: 1px solid var(--surface-200);
}
/* Мотив «миллиметровки» — данные. Плавно растворяется маской */
.hero-bg {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(240, 238, 233, .055) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(240, 238, 233, .055) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 95% 78% at 62% -4%, #000 24%, transparent 74%);
  mask-image: radial-gradient(ellipse 95% 78% at 62% -4%, #000 24%, transparent 74%);
}
.hero-bg::after { /* лёгкое зерно, чтобы градиенты не выглядели «пластиково» */
  content: ""; position: absolute; inset: 0; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.hero-inner {
  position: relative;
  max-width: 1160px; margin: 0 auto; padding: 84px 24px 88px;
  display: grid; grid-template-columns: 1fr 1.12fr; gap: 56px; align-items: center;
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 12.5px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase;
  color: var(--surface-500); margin-bottom: 22px;
}
.pulse-dot {
  width: 7px; height: 7px; border-radius: 50%; flex: none;
  background: var(--primary-600);
  box-shadow: 0 0 0 0 rgba(139, 92, 246, .45);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(139, 92, 246, .45); }
  70% { box-shadow: 0 0 0 9px rgba(139, 92, 246, 0); }
  100% { box-shadow: 0 0 0 0 rgba(139, 92, 246, 0); }
}

.hero h1 {
  font-size: clamp(40px, 5.5vw, 66px);
  line-height: 1.04; font-weight: 800; letter-spacing: -.035em;
}
.hero-sub {
  margin-top: 20px; font-size: 17.5px; line-height: 27px;
  color: var(--text-2); max-width: 480px;
}
.hero-cta { display: flex; gap: 12px; margin-top: 32px; }
.hero-note { margin-top: 18px; font-size: 13px; color: var(--surface-500); letter-spacing: .01em; }

/* --- Мок приложения --- */
.hero-mock { position: relative; }
.mock-window {
  background: var(--surface-0); border: 1px solid var(--surface-200);
  border-radius: 16px; overflow: hidden;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, .8) inset,
    0 24px 48px -16px rgba(0, 0, 0, .16),
    0 60px 110px -50px rgba(139, 92, 246, .35);
  transform: rotate(-.5deg);
  transition: transform .4s var(--ease), box-shadow .4s;
}
.hero-mock:hover .mock-window { transform: rotate(0deg); }
.mock-titlebar {
  height: 36px; display: flex; align-items: center; gap: 6px; padding: 0 12px;
  background: var(--surface-50); border-bottom: 1px solid var(--surface-200);
}
.mock-titlebar .dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.r { background: #fca5a5; } .dot.y { background: #fcd34d; } .dot.g { background: #86efac; }
.mock-url {
  margin: 0 auto; padding: 2px 14px; font-size: 11.5px; color: var(--surface-500);
  background: var(--surface-100); border-radius: 999px; font-family: var(--font-mono);
}
.mock-lock {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 9.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: var(--success-700); background: var(--success-50);
  padding: 2px 8px; border-radius: 999px;
}
.mock-body { display: flex; min-height: 336px; }
.mock-side {
  width: 128px; flex: none; padding: 14px 12px; border-right: 1px solid var(--surface-200);
  display: flex; flex-direction: column; gap: 5px; background: var(--surface-50);
}
.mock-side-logo { width: 18px; height: 18px; border-radius: 6px; background: linear-gradient(135deg, var(--primary-500), var(--primary-700)); margin: 0 9px 12px; }
.mock-nav-row {
  display: flex; align-items: center; gap: 7px;
  font-size: 10.5px; font-weight: 700; color: var(--surface-500);
  padding: 6px 9px; border-radius: 7px; white-space: nowrap;
}
.mock-nav-row .mi { width: 9px; height: 9px; border-radius: 3px; background: var(--surface-300); flex: none; }
.mock-nav-row.active { background: var(--primary-50); color: var(--primary-700); }
.mock-nav-row.active .mi { background: var(--primary-600); }
.mock-main { flex: 1; padding: 14px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.mock-prompt {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 12px; border: 1px solid var(--primary-100); background: var(--primary-50);
  border-radius: 10px; font-size: 12.5px; line-height: 16px; color: var(--primary-700); font-weight: 500;
}
.mock-prompt-icon { width: 14px; height: 14px; flex: none; border-radius: 5px; background: var(--primary-600); }
.mock-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.mock-kpi {
  border: 1px solid var(--surface-200); border-radius: 10px; padding: 11px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .04);
  background: var(--surface-0);
}
.mock-kpi-label { font-size: 10px; color: var(--surface-500); font-weight: 600; letter-spacing: .02em; white-space: nowrap; }
.mock-kpi-value { font-size: 15.5px; font-weight: 800; margin-top: 3px; font-variant-numeric: tabular-nums; white-space: nowrap; letter-spacing: -.01em; }
.mock-delta { display: inline-block; margin-top: 5px; font-size: 10px; font-weight: 700; padding: 1px 7px; border-radius: 999px; }
.mock-delta.up { color: var(--success-700); background: var(--success-50); }
.mock-delta.down { color: var(--danger-700); background: var(--danger-50); }
.mock-charts { flex: 1; display: grid; grid-template-columns: 1fr 96px; gap: 10px; min-height: 120px; }
.mock-chart {
  border: 1px solid var(--surface-200); border-radius: 10px;
  padding: 10px; box-shadow: 0 1px 2px rgba(0, 0, 0, .04); min-width: 0;
}
.mock-chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.mock-donut {
  border: 1px solid var(--surface-200); border-radius: 10px; padding: 8px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .04);
}
.mock-donut svg { width: 62px; height: 62px; }
.mock-donut-legend { display: flex; flex-direction: column; gap: 3px; font-size: 9px; color: var(--surface-500); font-weight: 600; }
.mock-donut-legend span { display: flex; align-items: center; gap: 4px; }
.mock-donut-legend i { width: 7px; height: 7px; border-radius: 2px; flex: none; }
.mock-chat {
  width: 150px; flex: none; border-left: 1px solid var(--surface-200);
  padding: 14px; display: flex; flex-direction: column; gap: 8px; background: var(--surface-50);
}
.mock-chat-head { display: flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 800; color: var(--surface-700); letter-spacing: .01em; }
.spark {
  width: 13px; height: 13px; border-radius: 5px; flex: none;
  background: linear-gradient(135deg, var(--primary-500), var(--accent-500));
}
.mock-msg { font-size: 10.5px; line-height: 14px; padding: 7px 9px; border-radius: 10px; max-width: 96%; font-weight: 500; }
.mock-msg.user { background: var(--primary-600); color: #fff; align-self: flex-end; border-bottom-right-radius: 3px; }
.mock-msg.bot { background: var(--surface-0); border: 1px solid var(--surface-200); color: var(--surface-700); align-self: flex-start; border-bottom-left-radius: 3px; }
.mock-input {
  margin-top: auto; font-size: 10.5px; color: var(--surface-400);
  border: 1px solid var(--surface-200); background: var(--surface-0);
  border-radius: 999px; padding: 7px 11px; display: flex; align-items: center; gap: 2px;
}

/* Стеклянные плашки вокруг мока */
.mock-chip {
  position: absolute; z-index: 2;
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 14px; border-radius: 999px;
  background: rgba(24, 23, 37, .92);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: 0 16px 34px -12px rgba(0, 0, 0, .32), 0 2px 6px rgba(0, 0, 0, .06), inset 0 0 0 3px rgba(167, 139, 250, .22);
  font-family: var(--font-mono); font-size: 11px; font-weight: 500; letter-spacing: .01em;
  color: var(--surface-600);
  white-space: nowrap;
}
.mock-chip svg { color: var(--success-700); flex: none; }
.mock-chip.chip-a { top: -15px; right: 34px; animation: float-a 7s ease-in-out infinite; }
.mock-chip.chip-b { left: -14px; bottom: 46px; animation: float-b 8s ease-in-out infinite; }
.mock-chip.chip-b svg { color: var(--primary-600); }
@keyframes float-a { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }
@keyframes float-b { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(6px); } }

/* Анимация графика: линия «рисуется» при появлении.
   Скрытие — только под .io (класс ставится при живом IntersectionObserver),
   чтобы без JS график оставался виден, а не пустым. */
.mock-chart .line-main { stroke-dasharray: 640; }
.io .mock-chart .line-main { stroke-dashoffset: 640; }
.io .in .mock-chart .line-main { animation: draw 1.7s .35s var(--ease) forwards; }
.io .in .mock-chart .area { opacity: 0; animation: fade-in .9s 1.4s ease forwards; }
.io .in .mock-chart .line-prev { opacity: 0; animation: fade-in .8s 1.7s ease forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fade-in { to { opacity: 1; } }

.caret {
  display: inline-block; width: 2px; height: 1.05em; margin-left: 2px;
  background: currentColor; vertical-align: text-bottom;
  animation: blink 1.15s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ============ Секции: общая система ============ */
.section { padding: clamp(76px, 9vw, 124px) 0; }
.section-tint { background: var(--surface-50); border-top: 1px solid var(--surface-200); border-bottom: 1px solid var(--surface-200); }
.section-inner { max-width: 1160px; margin: 0 auto; padding: 0 24px; }

#flow, #chat, #security, #who { scroll-margin-top: 76px; }
html { scroll-behavior: smooth; }

.sec-meta { display: flex; align-items: center; gap: 16px; margin-bottom: 26px; }
.sec-num {
  font-size: 13px; font-weight: 800; letter-spacing: .1em;
  color: var(--primary-600); font-variant-numeric: tabular-nums;
}
.sec-rule { height: 1px; width: 52px; background: var(--surface-300); flex: none; }
.sec-tag {
  font-size: 11.5px; font-weight: 700; letter-spacing: .15em; text-transform: uppercase;
  color: var(--surface-400);
}

.sec-head { max-width: 720px; }
.sec-head h2, .sec-copy h2 {
  font-size: clamp(30px, 3.8vw, 48px);
  line-height: 1.12; font-weight: 800; letter-spacing: -.03em;
}
.sec-lead { margin-top: 18px; font-size: 17px; line-height: 26px; color: var(--text-2); max-width: 520px; }

.sec-split {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 6vw, 88px); align-items: center;
}
.sec-split .sec-copy h2 { max-width: 480px; }

/* --- 01: шаги + SQL --- */
.steps { margin-top: 56px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.step { position: relative; padding-top: 6px; }
.step-ghost {
  font-size: 60px; line-height: 1; font-weight: 800; letter-spacing: -.02em;
  color: transparent; -webkit-text-stroke: 1.4px var(--surface-300);
  margin-bottom: 14px; font-variant-numeric: tabular-nums;
}
.step h3 { font-size: 19px; font-weight: 800; letter-spacing: -.015em; }
.step p { margin-top: 9px; color: var(--text-2); font-size: 15px; line-height: 23px; max-width: 300px; }

.sql-card {
  margin-top: 56px; background: #0c0b12; border-radius: 14px; overflow: hidden;
  box-shadow: 0 44px 90px -34px rgba(0, 0, 0, .55), 0 12px 28px -14px rgba(0, 0, 0, .25);
  border: 1px solid rgba(255, 255, 255, .06);
  transform: rotate(.3deg);
  transition: transform .4s var(--ease);
}
.sql-card:hover { transform: rotate(0deg); }
.sql-head {
  display: flex; align-items: center; gap: 7px; padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
  background: rgba(255, 255, 255, .03);
}
.sql-file { margin-left: 10px; font-family: var(--font-mono); font-size: 12px; color: var(--surface-500); }
.sql-badge {
  margin-left: auto; font-family: var(--font-mono); font-size: 10.5px; font-weight: 700; letter-spacing: .1em;
  color: #86efac; background: rgba(16, 185, 129, .12); border: 1px solid rgba(16, 185, 129, .25);
  padding: 2px 9px; border-radius: 999px;
}
.sql-body {
  padding: 22px 24px; overflow-x: auto;
  font-family: var(--font-mono); font-size: 13.5px; line-height: 1.75;
  color: #e6e3dc;
}
.sql-body .kw { color: #22d3ee; font-weight: 600; }
.sql-body .fn { color: #a78bfa; }
.sql-body .str { color: #86efac; }
.sql-foot {
  display: flex; flex-wrap: wrap; gap: 8px; padding: 13px 16px;
  border-top: 1px solid rgba(255, 255, 255, .08);
}
.sql-chip {
  font-family: var(--font-mono); font-size: 11px; letter-spacing: .02em;
  color: var(--surface-300); background: rgba(255, 255, 255, .06);
  padding: 4px 11px; border-radius: 999px; white-space: nowrap;
}
.sql-chip.ok { color: #86efac; background: rgba(16, 185, 129, .12); }
.sql-chip.ghost { border: 1px dashed rgba(255, 255, 255, .18); background: none; }

/* --- 02: чат + морфинг графика --- */
.sec-visual { position: relative; }
.chat-mock {
  background: var(--surface-0); border: 1px solid var(--surface-200); border-radius: 16px;
  box-shadow: 0 24px 48px -18px rgba(0, 0, 0, .14);
  overflow: hidden; max-width: 480px;
}
.chat-mock-head {
  display: flex; align-items: center; gap: 9px; padding: 15px 20px;
  border-bottom: 1px solid var(--surface-200); font-weight: 800; font-size: 14px;
}
.chat-mock-body { padding: 20px; display: flex; flex-direction: column; gap: 11px; }
.cm-msg {
  max-width: 82%; padding: 10px 14px; border-radius: 14px;
  font-size: 14px; line-height: 20px; font-weight: 500;
}
.cm-msg.user {
  background: var(--primary-600); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px;
  box-shadow: 0 6px 14px -6px rgba(139, 92, 246, .5);
}
.cm-msg.bot {
  background: var(--surface-50); border: 1px solid var(--surface-200); color: var(--surface-700);
  align-self: flex-start; border-bottom-left-radius: 4px;
}
.morph-card {
  margin-top: 18px; padding: 16px 18px 13px;
  background: rgba(24, 23, 37, .95);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--surface-200); border-radius: 13px;
  box-shadow: 0 14px 30px -16px rgba(0, 0, 0, .18);
  max-width: 480px;
}
.morph-title { font-size: 11.5px; font-weight: 800; color: var(--surface-500); letter-spacing: .03em; margin-bottom: 10px; }
.morph-card svg { width: 100%; height: 64px; display: block; }
.morph-legend { display: flex; justify-content: space-between; margin-top: 8px; font-size: 10px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.morph-legend .old { color: var(--surface-500); text-decoration: line-through; text-decoration-thickness: 1px; }
.morph-legend .new { color: var(--primary-500); }
/* перекрёстное затухание: «было» → «стало» */
.mp.a { animation: mp-a 7s ease-in-out infinite; }
.mp.b { animation: mp-b 7s ease-in-out infinite; }
@keyframes mp-a { 0%, 42% { opacity: 1; } 58%, 92% { opacity: .18; } 100% { opacity: 1; } }
@keyframes mp-b { 0%, 42% { opacity: .18; } 58%, 92% { opacity: 1; } 100% { opacity: .18; } }

.tick-list { list-style: none; margin-top: 24px; display: flex; flex-direction: column; gap: 10px; }
.tick-list li {
  position: relative; padding-left: 26px;
  color: var(--surface-700); font-weight: 600; font-size: 15px;
}
.tick-list li::before {
  content: ""; position: absolute; left: 0; top: 5px; width: 15px; height: 15px;
  border-radius: 50%; background: var(--primary-50);
  box-shadow: inset 0 0 0 1.5px var(--primary-100);
}
.tick-list li::after {
  content: ""; position: absolute; left: 4.5px; top: 9.5px; width: 6px; height: 3.5px;
  border-left: 1.8px solid var(--primary-600); border-bottom: 1.8px solid var(--primary-600);
  transform: rotate(-45deg);
}

/* --- 03: спека безопасности --- */
.spec {
  background: var(--surface-0); border: 1px solid var(--surface-200);
  border-radius: 16px; overflow: hidden;
  box-shadow: 0 24px 48px -18px rgba(0, 0, 0, .12);
}
.spec-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 24px;
  padding: 17px 24px; border-top: 1px solid var(--surface-100);
  transition: background .18s, padding-left .18s;
}
.spec-row:first-child { border-top: none; }
.spec-row:hover { background: var(--surface-50); padding-left: 30px; }
.spec-row span { font-size: 15px; color: var(--text-2); font-weight: 500; }
.spec-row b {
  font-family: var(--font-mono); font-size: 13.5px; font-weight: 600;
  color: var(--ink); letter-spacing: .01em; white-space: nowrap;
}
.spec-row:hover b { color: var(--primary-600); }

/* --- Источники: маркиза --- */
.sources { padding: 52px 0 56px; border-bottom: 1px solid var(--surface-200); }
.sources-cap {
  display: flex; align-items: center; gap: 16px;
  font-size: 11.5px; font-weight: 700; letter-spacing: .15em; text-transform: uppercase;
  color: var(--surface-400); margin-bottom: 26px;
}
.sources-cap .sec-rule { flex: 1; width: auto; }
.marquee {
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.marquee-track { display: flex; width: max-content; animation: slide 46s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes slide { to { transform: translateX(-50%); } }
.mq {
  display: inline-flex; align-items: center; gap: 9px;
  margin-right: 12px; /* через margin, а не gap трека: -50% петли без шва */
  padding: 10px 18px; border-radius: 999px;
  border: 1px solid var(--surface-200); background: var(--surface-0);
  font-size: 14.5px; font-weight: 700; color: var(--surface-700); white-space: nowrap;
  letter-spacing: -.005em;
}
.mq i { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.mq.more { border-style: dashed; color: var(--surface-500); background: none; }

/* --- 04: персоны --- */
.who-grid { margin-top: 56px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.who-card {
  position: relative; padding: 30px 28px 26px;
  background: var(--surface-0); border: 1px solid var(--surface-200); border-radius: 16px;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
  display: flex; flex-direction: column; gap: 16px;
}
.who-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary-100);
  box-shadow: 0 20px 44px -18px rgba(139, 92, 246, .22);
}
.who-role {
  font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: var(--surface-400);
}
.who-card blockquote {
  font-family: var(--font-a); font-style: italic; font-weight: 500;
  font-size: 20px; line-height: 29px; letter-spacing: -.01em; color: var(--ink);
}
.who-name { font-size: 14.5px; font-weight: 700; margin-top: auto; }
.who-gets { font-size: 13px; color: var(--surface-500); font-weight: 600; }
.who-card blockquote::before {
  content: "«";
  font-family: var(--font-a); font-style: italic; font-weight: 600;
  font-size: 26px; line-height: 0; vertical-align: -6px;
  margin-right: 2px; color: var(--primary-600);
}

/* ============ Финальный CTA ============ */
.cta {
  position: relative; overflow: hidden; text-align: center;
  background: #0c0b12;
  padding: clamp(84px, 10vw, 136px) 0;
}
.cta-bg {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(720px 380px at 78% -8%, rgba(139, 92, 246, .38), transparent 62%),
    radial-gradient(560px 320px at 8% 110%, rgba(34, 211, 238, .22), transparent 60%);
}
.cta-bg::after {
  content: ""; position: absolute; inset: 0; opacity: .06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
.cta .section-inner { position: relative; }
.cta h2 {
  font-size: clamp(32px, 4.6vw, 56px); line-height: 1.08;
  font-weight: 800; letter-spacing: -.03em; color: #fff;
}
.cta p { margin-top: 18px; color: var(--surface-600); font-size: 17px; }
.cta .btn { margin-top: 32px; }
.cta-note { margin-top: 16px; font-size: 12.5px; color: var(--surface-600); letter-spacing: .04em; }
.btn-invert {
  background: #f0eee9; border-color: #f0eee9; color: #100f16;
  box-shadow: 0 14px 34px -10px rgba(139, 92, 246, .55);
  transition: transform .18s var(--ease), box-shadow .18s;
}
.btn-invert:hover {
  background: #f0eee9; border-color: #f0eee9;
  transform: translateY(-1px);
  box-shadow: 0 18px 40px -10px rgba(139, 92, 246, .65);
}

/* ============ Футер ============ */
.footer { padding: 34px 0; border-top: 1px solid var(--surface-200); }
.footer-inner { display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--surface-500); font-weight: 600; font-size: 14px; text-decoration: none !important; }
.footer-links a:hover { color: var(--ink); }
.footer-copy { margin-left: auto; color: var(--surface-500); font-size: 13px; }

/* ============ Появление при скролле ============ */
.io .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.io .reveal.in { opacity: 1; transform: none; }
.io .reveal.d1 { transition-delay: .08s; } .io .reveal.d2 { transition-delay: .16s; }
.io .reveal.d3 { transition-delay: .26s; }
.reveal-children > .reveal:nth-child(2) { transition-delay: .1s; }
.reveal-children > .reveal:nth-child(3) { transition-delay: .2s; }
/* Страховка: если reveal-механика не сработала (старый iOS, сбой JS) — показать контент */
.io-fallback .reveal { opacity: 1; transform: none; }
.io-fallback .mock-chart .line-main { stroke-dashoffset: 0; }

/* ============ Адаптив ============ */
@media (max-width: 1020px) {
  .hero-inner { grid-template-columns: 1fr; gap: 48px; padding-top: 56px; padding-bottom: 64px; }
  .hero h1 { font-size: clamp(36px, 8vw, 52px); }
  .sec-split { grid-template-columns: 1fr; gap: 48px; }
  .nav-links { display: none; }
  /* nav-links был flex-распоркой, прижимавшей nav-actions вправо:
     без этого бургер «прилипает» к логотипу */
  .nav-actions { margin-left: auto; }
  .nav-burger {
    display: inline-flex; align-items: center; justify-content: center; flex: none;
    width: 44px; height: 44px; border: 1px solid var(--surface-200); border-radius: 10px;
    background: var(--surface-0); color: var(--surface-700); cursor: pointer;
    touch-action: manipulation;
  }
  .nav-burger:hover { background: var(--surface-50); }
  .nav-drawer { display: flex; }
  .nav-drawer.hidden { display: none; }
}

/* Кнопки шапки живут до 640px: на планшете CTA остаётся видимым */
@media (max-width: 640px) {
  .nav-actions .btn { display: none; }
}

@media (max-width: 720px) {
  body.landing { /* всегда тёмная: html[data-theme=dark] */ font-size: 15px; }
  .steps { grid-template-columns: 1fr; gap: 30px; margin-top: 44px; }
  .step-ghost { font-size: 44px; }
  .who-grid { grid-template-columns: 1fr; margin-top: 44px; }
  .mock-chat { display: none; }
  .mock-kpis { grid-template-columns: 1fr 1fr; }
  .mock-charts { grid-template-columns: 1fr; }
  .mock-donut { display: none; }
  .mock-donut-legend { font-size: 10px; }
  .sql-body { font-size: 12px; }
  .chat-mock { max-width: none; }
  .sec-copy h2, .sec-head h2 { max-width: none; }
  .footer-copy { margin-left: 0; }
}

@media (max-width: 480px) {
  .hero-cta { flex-direction: column; align-items: stretch; }
  .hero-cta .btn { width: 100%; }
  .mock-kpis { grid-template-columns: 1fr; }
  .mock-chip.chip-a { right: 6px; top: -14px; }
  .mock-chip.chip-b { left: 6px; }
  .sql-foot { gap: 6px; }
  .spec-row { flex-direction: column; align-items: flex-start; gap: 3px; }
}

/* ============ Доступность: без анимаций ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .io .reveal { opacity: 1; transform: none; transition: none; }
  .mock-chip.chip-a, .mock-chip.chip-b, .morph-card, .mp.a, .mp.b, .pulse-dot, .caret { animation: none; }
  .marquee { overflow-x: auto; }
  .marquee-track { animation: none; }
  .mock-window, .sql-card, .who-card, .landing .btn-primary, .btn-invert { transition: none; }
  .nav-drawer { animation: none; }
  .mock-chart .line-main { stroke-dashoffset: 0; }
  .io .in .mock-chart .area, .io .in .mock-chart .line-prev { opacity: 1; animation: none; }
}
