/* Страница «Разбор аудитории» на дизайн-системе banka.bot.
   Токены перенесены один в один из лендинга banka.bot (landing/src/styles/tokens.css):
   фон #0A0A0A, акцент розовый #FB61B2, радиус всегда 0, Inter и JetBrains Mono.
   Правила системы: заголовки прописными с плотным трекингом, над заголовками
   ничего не ставим, подпись к цифре под цифрой, значки только SVG,
   модули стыкуются встык линией в 1 пиксель. */

:root {
  --bg: #0a0a0a;
  --fg: #fafafa;
  --mid: #b2b2b7;
  --mid-dim: #8c8c93;
  --mid-dim-700: #5c5c62;
  --line: #1f1f22;
  --surface: #141417;
  --surface-line: #3a3a3f;
  --surface-deep: #0d0d0f;
  --surface-hi: #1a1a1e;

  --accent: #fb61b2;
  --accent-hover: #ff7cc1;
  --accent-bg: rgba(251, 97, 178, 0.1);
  --accent-line: rgba(251, 97, 178, 0.35);

  --success: #22c55e;
  --success-bg: rgba(34, 197, 94, 0.12);
  --success-line: rgba(34, 197, 94, 0.35);
  --danger: #ff3b5c;

  --fs-lead: clamp(1rem, 2vw, 1.125rem);
  --fs-h2: clamp(1.75rem, 3.6vw, 2.75rem);
  --fs-h1: clamp(2.125rem, 4.6vw, 3.5rem);

  --font-sans: "Inter", "Inter Fallback", ui-sans-serif, system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  --header-h: 77px;
  --pad: 40px;
  --content-max: 1400px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 200ms;
  --dur-base: 300ms;

  /* Старые имена, на которые ссылаются шаблоны в app.js */
  --ink: var(--fg);
  --ink2: var(--fg);
  --muted: var(--mid);
  --dim: var(--mid-dim);
  --pink: var(--accent);
  --pink2: var(--accent-hover);
  --good: var(--success);
  --panel: var(--surface);
  --panel2: var(--surface-hi);
  --line2: var(--surface-line);

  color-scheme: dark;
}

/* Запасной шрифт с метриками Inter: пока Inter грузится, текст занимает столько же места,
   и при подмене шрифта вёрстка не прыгает */
@font-face { font-family: "Inter Fallback"; src: local("Arial"), local("Helvetica"), local("Liberation Sans"); size-adjust: 107%; ascent-override: 90%; descent-override: 22.4%; line-gap-override: 0%; }

/* ---------- основа ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.5 var(--font-sans);
  -webkit-font-smoothing: antialiased;
  font-synthesis-weight: none;
  overflow-x: hidden;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; touch-action: manipulation; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, dl, dd { margin: 0; }
img, svg { display: block; max-width: 100%; }
p { color: var(--mid); }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.wrap {
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: max(var(--pad), env(safe-area-inset-left, 0px));
  padding-right: max(var(--pad), env(safe-area-inset-right, 0px));
}
.pink, .dot { color: var(--accent); }
h2 .ln { display: block; }
.num-tab { font-variant-numeric: tabular-nums; }

h1, h2 {
  text-wrap: balance;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -0.04em;
  line-height: 1.04;
}
h3, h4 { font-weight: 600; letter-spacing: -0.01em; line-height: 1.25; }

/* Служебная метка: моно 11 пикселей. Ставится только под цифрой или внутри модуля, не над заголовком */
.tag, .rlabel, .mlabel, .jobs small, .psy small, .ladder small {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mid-dim);
}

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 56px;
  padding: 0 32px;
  border: 1px solid transparent;
  border-radius: 0;
  background: var(--accent);
  color: #000;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: opacity var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.btn:hover { opacity: 0.9; }
.btn:active { transform: scale(0.985); }
.btn:disabled { opacity: 0.5; cursor: wait; }
.btn.sm { min-height: 44px; padding: 0 20px; font-size: 13px; }
.btn.ghost { background: transparent; color: var(--fg); border-color: var(--surface-line); }
.btn.ghost:hover { opacity: 1; border-color: rgba(255, 255, 255, 0.4); }
.linkbtn {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-underline-offset: 4px;
  font-weight: 500;
}
.linkbtn:hover { color: var(--accent); }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border: 1px solid var(--surface-line);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--mid);
  white-space: nowrap;
}
.chip.p { border-color: var(--accent-line); color: var(--accent); background: var(--accent-bg); }
.chip.g { border-color: var(--success-line); color: var(--success); background: var(--success-bg); }

/* Подсказка по наведению и по нажатию */
.tip {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin-left: 6px;
  border: 1px solid var(--surface-line);
  font: 500 11px/1 var(--font-mono);
  color: var(--mid-dim);
  vertical-align: 1px;
  cursor: help;
}
.tip::after {
  content: attr(data-tip);
  position: absolute;
  left: -1px;
  bottom: calc(100% + 8px);
  z-index: 20;
  width: max-content;
  max-width: min(280px, 72vw);
  padding: 10px 12px;
  background: var(--surface-hi);
  border: 1px solid var(--surface-line);
  font: 400 13px/1.45 var(--font-sans);
  letter-spacing: 0;
  text-transform: none;
  color: var(--fg);
  text-align: left;
  white-space: normal;
  /* Скрытая подсказка не должна занимать место: иначе страница шире экрана */
  display: none;
  pointer-events: none;
}
.tip:hover, .tip:focus-visible { color: var(--fg); border-color: var(--mid-dim); }
.tip:hover::after, .tip:focus::after { display: block; }
/* У ползунков подсказка открывается на ширину строки и не выходит за экран */
.ctrl label { position: relative; }
.ctrl .tip { position: static; }
.ctrl .tip::after { left: 0; max-width: 100%; }

/* Сетка модулей встык: шов рисует каждый модуль тенью, пустая ячейка не светится */
.icp, .how3, .grow, .ladder, .clusters, .segs, .jobs, .rgrid, .slinks {
  gap: 1px;
  box-shadow: 0 0 0 1px var(--line);
}
.icp > *, .how3 > *, .grow > *, .ladder > *, .clusters > *, .segs > *, .jobs > *, .rgrid > *, .calc > *, .slinks > * {
  border: 0;
  box-shadow: 0 0 0 1px var(--line);
}

/* ---------- секции ---------- */
section { position: relative; }
.sec { padding: 96px 0; border-top: 1px solid var(--line); }
.sec-head { display: flex; flex-direction: column; gap: 16px; margin-bottom: 48px; max-width: 860px; }
.sec-head h2 { font-size: var(--fs-h2); max-width: 24ch; }
.sec-head p { font-size: var(--fs-lead); max-width: 60ch; }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 0;
  transition: border-color var(--dur-fast) var(--ease-out);
}

/* ---------- шапка как на banka.bot: лого, «Меню» с колонками, кнопка справа ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top, 0px);
}
.header-inner { position: relative; display: flex; align-items: center; gap: 12px; padding-block: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; flex: none; }
.brand img { width: 32px; height: 32px; }
.brand-name { font-size: 18px; font-weight: 700; text-transform: uppercase; letter-spacing: -0.02em; white-space: nowrap; }
.cta { margin-left: auto; }
/* Выпадающее меню привязано к ширине шапки, а не к кнопке: так оно не вылезает за край на планшете */
.menu { position: static; flex: none; }
.menu summary { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding-inline: 12px; border: 1px solid var(--surface-line); color: var(--fg); cursor: pointer; list-style: none; font-size: 14px; font-weight: 500; transition: border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out); }
.menu summary::-webkit-details-marker { display: none; }
.menu summary:hover { border-color: rgba(255, 255, 255, 0.4); }
.menu[open] summary { border-color: var(--accent); background: var(--accent-bg); color: var(--accent); }
.menu .ic-close, .menu[open] .ic-open { display: none; }
.menu[open] .ic-close { display: block; }
.menu-label { display: none; }
.mega { position: fixed; left: 0; right: 0; top: var(--header-h); max-height: calc(100dvh - var(--header-h)); overflow-y: auto; display: grid; gap: 1px; background: #000; border-bottom: 1px solid var(--surface-line); padding: 24px var(--pad) 40px; }
.mega-col { display: flex; flex-direction: column; gap: 4px; padding-block: 8px; }
.mega-title { margin-bottom: 12px; font: 500 11px/1 var(--font-mono); letter-spacing: 0.25em; text-transform: uppercase; color: var(--mid-dim); }
.mega-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.mega-link { display: flex; align-items: center; min-height: 44px; font-size: 15px; font-weight: 500; letter-spacing: -0.01em; color: var(--fg); border-bottom: 1px solid var(--line); transition: color var(--dur-fast) var(--ease-out); }
.mega-link:hover { color: var(--accent); }
.mega-promo { display: none; }
@media (min-width: 900px) {
  .menu-label { display: inline; }
  .mega { position: absolute; left: var(--pad); right: auto; top: calc(100% - 4px); width: min(920px, calc(100% - var(--pad) * 2)); max-height: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.15fr); gap: 0; padding: 0; border: 1px solid var(--surface-line); box-shadow: 0 24px 60px -20px rgba(0, 0, 0, 0.7); }
  .mega-col { padding: 24px; border-right: 1px solid var(--line); }
  .mega-link { min-height: 40px; border-bottom: 0; }
  .mega-promo { position: relative; display: block; overflow: hidden; background: var(--surface); text-align: left; min-height: 280px; }
  .mega-promo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; mix-blend-mode: screen; transition: transform 500ms var(--ease-out); }
  .mega-promo:hover img { transform: scale(1.03); }
  .promo-text { position: absolute; left: 0; right: 0; bottom: 0; display: flex; flex-direction: column; gap: 4px; padding: 20px; background: linear-gradient(to top, rgba(0, 0, 0, 0.9), rgba(0, 0, 0, 0)); }
  .promo-text b { font-size: 15px; font-weight: 700; text-transform: uppercase; letter-spacing: -0.02em; }
  .promo-text span { font-size: 13px; line-height: 1.4; color: var(--mid); }
}
@media (max-width: 899px) { .site-header { background: var(--bg); backdrop-filter: none; -webkit-backdrop-filter: none; } }
@media (max-width: 479px) { .brand-name { display: none; } }

/* ---------- первый экран ---------- */
.hero { padding: 72px 0 80px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 64px; align-items: center; }
.hero-grid > div:first-child { align-self: center; }
.hero h1 { font-size: var(--fs-h1); max-width: 18ch; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lead { font-size: var(--fs-lead); margin-top: 20px; max-width: 54ch; }
.hero .lead b { color: var(--fg); font-weight: 600; }
.hero .lead { font-size: clamp(1.0625rem, 2vw, 1.25rem); max-width: 46ch; }

.analyzer { margin-top: 32px; max-width: 600px; }
.plat { display: inline-flex; gap: 8px; margin-bottom: 12px; }
.plat button { display: flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px; border: 1px solid var(--surface-line); font-size: 13px; font-weight: 600; color: var(--mid); transition: color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out); }
.plat button[aria-pressed=true] { background: var(--fg); border-color: var(--fg); color: #000; }
.plat svg { width: 14px; height: 14px; }
.inrow { display: flex; gap: 8px; }
.inrow input {
  flex: 1;
  min-width: 0;
  height: 56px;
  border: 1px solid var(--surface-line);
  border-radius: 0;
  background: var(--surface-deep);
  padding: 0 16px;
  font-size: 16px;
  outline: none;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.inrow input:focus { border-color: var(--accent); }
.inrow input::placeholder { color: var(--mid-dim); }
.inrow .btn { height: 56px; }
.err { color: var(--danger); font-size: 14px; margin-top: 8px; }
.err:empty { display: none; }
.hero-alt { margin-top: 24px; font-size: 15px; }

/* Превью: профиль Instagram, рядом карточки разбора. Окно Instagram скруглено:
   это имитация чужого интерфейса, единственное исключение из радиуса 0 */
.mock { position: relative; display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); align-items: center; gap: 0; }
.ig { grid-column: 1; grid-row: 1 / span 3; background: #000; border: 1px solid var(--surface-line); border-radius: 28px; padding: 16px 14px 14px; box-shadow: 0 40px 80px -30px rgba(251, 97, 178, 0.25); }
.ig-top { display: flex; align-items: center; justify-content: space-between; padding: 0 4px 12px; font-size: 16px; }
.ig-head { display: flex; align-items: center; gap: 12px; padding: 0 4px; }
.ig-ava { position: relative; flex: none; width: 76px; height: 76px; border-radius: 50%; padding: 3px; background: conic-gradient(var(--accent), #ffb3d9, var(--accent)); }
.ig-ava img { width: 100%; height: 100%; border-radius: 50%; border: 3px solid #000; object-fit: cover; }
.ig-stats { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); text-align: center; }
.ig-stats b { display: block; font-size: 16px; font-weight: 700; }
.ig-stats span { display: block; font-size: 11px; letter-spacing: -0.01em; color: var(--mid); }
.ig-bio { display: flex; flex-direction: column; gap: 2px; padding: 12px 4px 0; font-size: 13px; color: var(--fg); }
.ig-bio b { font-size: 14px; }
.ig-bio span:last-child { color: var(--accent); }
.ig-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 12px 4px 0; }
.ig-btns span { display: grid; place-items: center; height: 32px; border-radius: 8px; background: var(--surface-hi); font-size: 13px; font-weight: 600; }
.ig-btns .on { background: var(--accent); color: #000; }
.ig-hl { display: flex; gap: 14px; padding: 14px 4px 12px; }
.ig-hl div { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 60px; }
.ig-hl i { width: 58px; height: 58px; border-radius: 50%; border: 1px solid var(--surface-line); padding: 3px; }
.ig-hl img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.ig-ava img, .ig-hl img { height: 100%; }
.ig-hl span { font-size: 11px; color: var(--fg); white-space: nowrap; }
.ig-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; margin: 0 -14px -14px; border-top: 1px solid var(--line); padding-top: 2px; border-radius: 0 0 27px 27px; overflow: hidden; }
.ig-grid img { width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.mcard { position: relative; z-index: 2; min-width: 0; background: var(--surface); border: 1px solid var(--surface-line); padding: 20px; box-shadow: 0 28px 56px -20px rgba(0, 0, 0, 0.9); margin-left: -28px; }
.mcard > b { display: block; font-size: clamp(24px, 2.2vw, 32px); font-weight: 700; letter-spacing: -0.03em; line-height: 1; white-space: nowrap; font-variant-numeric: tabular-nums; }
.mcard > span { display: block; margin-top: 8px; font-size: 14px; color: var(--mid); }
.mcard .track { margin-top: 14px; height: 6px; }
.m1 { grid-column: 2; grid-row: 1; align-self: end; margin-bottom: 16px; margin-left: 16px; animation: float 8s ease-in-out -2s infinite; }
.m2 { grid-column: 2; grid-row: 2; margin-left: 32px; animation: float 9s ease-in-out -4s infinite; }
.m3 { grid-column: 2; grid-row: 3; align-self: start; margin-top: 16px; border-color: var(--accent); animation: float 7s ease-in-out -1s infinite; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
.ava {
  position: relative;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  overflow: hidden;
  background: var(--accent-bg);
  border: 1px solid var(--accent-line);
  color: var(--accent);
  font: 500 15px/1 var(--font-mono);
}
.ava img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.track { display: block; height: 4px; background: var(--surface-line); overflow: hidden; }
.track i { display: block; height: 100%; background: var(--accent); }
.mcard > b.mprod, .mprod { display: block; font-size: 17px; font-weight: 600; letter-spacing: -0.01em; line-height: 1.3; white-space: normal; }
.mrow { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-top: 14px; }
.mrow .price { font-size: 28px; }
.mrow .ok { font-size: 14px; color: var(--success); white-space: nowrap; }
.mcap { display: block; margin-top: 4px; font-size: 14px; color: var(--mid); }
.price { font-weight: 700; color: var(--accent); font-size: 18px; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* Шкала «70 из 100» в разборе: квадратный индикатор вместо кольца */
.ring {
  --v: 70;
  position: relative;
  display: block;
  min-width: 96px;
  padding-bottom: 12px;
  flex-shrink: 0;
}
.ring::before, .ring::after { content: ""; position: absolute; left: 0; bottom: 0; height: 4px; }
.ring::before { right: 0; background: var(--surface-line); }
.ring::after { width: calc(var(--v) * 1%); background: var(--accent); }
.ring > div { font-size: 44px; font-weight: 700; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.ring small { display: block; margin-top: 6px; font-size: 13px; color: var(--mid); }

/* ---------- кому подходит ---------- */
.icp { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.icard { padding: 28px; display: flex; flex-direction: column; gap: 16px; background: var(--surface); }
.icard .art, .hs .art { width: 112px; height: 112px; margin: -8px 0 4px -8px; mix-blend-mode: screen; }
.icard h3 { font-size: 19px; }
.pain { font-size: 15px; color: var(--fg); padding-left: 14px; border-left: 2px solid var(--accent); }
.icard .get { font-size: 14px; margin-top: auto; }
.icard .get b { color: var(--fg); font-weight: 600; }

/* ---------- калькулятор ---------- */
/* Слева ползунки строкой «подпись, ползунок, значение», справа итог. Итог держится у верха экрана,
   поэтому общей рамки у калькулятора нет. На узком экране ползунок встаёт под подпись,
   а сумма висит плашкой сверху панели, пока видны ползунки */
.calc {
  /* Серый второго ряда темнее подписей: так розовый и серый различимы и при нарушениях цветового зрения */
  --c-partner: #74747a;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 1px;
  align-items: start;
}
.calc > .card { border: 0; }
.cpanel { padding: 24px; }
.cmini { display: none; }
.tabs { display: flex; border: 1px solid var(--surface-line); margin-bottom: 20px; }
.tabs button { flex: 1; min-height: 44px; padding: 0 8px; font-size: 13px; font-weight: 600; color: var(--mid); white-space: nowrap; transition: color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out); }
.tabs button + button { border-left: 1px solid var(--surface-line); }
.tabs button[aria-selected=true] { background: var(--accent); color: #000; }
.cgroup + .cgroup { margin-top: 12px; padding-top: 16px; border-top: 1px solid var(--line); }
.cgroup h3 { font-size: 15px; margin-bottom: 4px; }
.ctrl {
  position: relative;
  display: grid;
  grid-template-columns: 10.5rem minmax(0, 1fr) 8rem;
  grid-template-areas: "lab rng val";
  align-items: center;
  column-gap: 16px;
  min-height: 40px;
}
.clab { grid-area: lab; display: flex; align-items: center; min-width: 0; font-size: 14px; color: var(--mid); }
.clab label { cursor: pointer; }
.ctrl input[type=range] { grid-area: rng; }
.ctrl output { grid-area: val; justify-self: end; font-size: 17px; font-weight: 700; line-height: 1.3; color: var(--fg); font-variant-numeric: tabular-nums; white-space: nowrap; }
.cfmt .seg { grid-column: 2 / 4; }
input[type=range] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 24px;
  background: transparent;
  outline: none;
  margin: 0;
}
input[type=range]::-webkit-slider-runnable-track { height: 4px; background: linear-gradient(90deg, var(--accent) var(--p, 50%), var(--surface-line) var(--p, 50%)); }
input[type=range]::-moz-range-track { height: 4px; background: linear-gradient(90deg, var(--accent) var(--p, 50%), var(--surface-line) var(--p, 50%)); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: -8px; background: var(--fg); border: 4px solid var(--accent); border-radius: 0; cursor: grab; }
input[type=range]::-moz-range-thumb { width: 12px; height: 12px; background: var(--fg); border: 4px solid var(--accent); border-radius: 0; cursor: grab; }
input[type=range]:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.seg { display: flex; border: 1px solid var(--surface-line); }
.seg button { flex: 1; min-height: 40px; padding: 0 8px; font-size: 13px; font-weight: 600; color: var(--mid); white-space: nowrap; }
.seg button + button { border-left: 1px solid var(--surface-line); }
.seg button[aria-pressed=true] { background: var(--accent-bg); color: var(--fg); box-shadow: inset 0 0 0 1px var(--accent); }

.cres { padding: 24px; position: sticky; top: calc(var(--header-h) + 16px); align-self: start; }
/* Сумма и столбики по месяцам в одну строку; если сумма длинная, столбики уходят под неё */
.ctop { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 24px; }
.csum { min-width: 0; }
.cres .big { font-size: clamp(2.5rem, 4.2vw, 3.5rem); font-weight: 700; letter-spacing: -0.04em; line-height: 1; color: var(--accent); font-variant-numeric: tabular-nums; white-space: nowrap; }
.cres .big.long { font-size: clamp(1.875rem, 3vw, 2.5rem); }
.cres .per { position: relative; margin-top: 8px; font-size: 14px; }
.cres .per .tip { position: static; }
/* Подсказка у суммы открывается вниз, чтобы не закрывать саму сумму */
.cres .per .tip::after { left: 0; top: calc(100% + 8px); bottom: auto; max-width: 100%; }
.cren { margin-top: 4px; font-size: 13px; color: var(--success); }
.cren b { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.chart { flex: 1 1 160px; max-width: 240px; display: flex; flex-direction: column; gap: 6px; }
.cbars { display: flex; align-items: flex-end; gap: 4px; height: 64px; border-bottom: 1px solid var(--surface-line); }
.col { flex: 1; display: flex; flex-direction: column-reverse; height: 100%; }
.col i { display: block; width: 100%; transition: height var(--dur-base) var(--ease-out); }
.col i.o { background: var(--accent); }
/* Зазор в 2 пикселя между своим продуктом и партнёрками, чтобы части столбика не сливались */
.col i.p { background: var(--c-partner); border-bottom: 2px solid transparent; background-clip: padding-box; }
.cax { display: flex; justify-content: space-between; font: 500 11px/1 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--mid-dim); }
/* Строки итога: цветной квадрат у строки заменяет легенду столбиков */
.lines { margin-top: 20px; display: grid; gap: 8px; }
.line { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: 14px; color: var(--mid); }
.line span { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.line i { width: 10px; height: 10px; flex: none; }
.line .lo { background: var(--accent); }
.line .lp { background: var(--c-partner); }
.line b { font-size: 15px; font-weight: 600; color: var(--fg); font-variant-numeric: tabular-nums; white-space: nowrap; }
.line.sub { padding-left: 18px; font-size: 13px; color: var(--mid-dim); }
.line.sub b { font-size: 13px; font-weight: 500; color: var(--mid); }
.line.tot { margin-top: 4px; padding-top: 12px; border-top: 1px solid var(--surface-line); font-size: 15px; color: var(--fg); }
.line.tot b { font-size: 20px; font-weight: 700; }
.cres .btn { width: 100%; margin-top: 20px; }

/* Ноутбук: панели с ползунками больше места, иначе ползунок короткий */
@media (min-width: 1021px) and (max-width: 1240px) {
  .calc { grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.7fr); }
}
@media (max-width: 1020px) {
  .cres { position: static; }
  /* Пока видны ползунки, итог висит сверху панели */
  .cmini {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    position: sticky;
    top: var(--header-h);
    z-index: 5;
    margin: -24px -24px 16px;
    padding: 10px 24px;
    background: var(--surface-deep);
    border-bottom: 1px solid var(--line);
    font-size: 13px;
    color: var(--mid);
  }
  .cmini b { font-size: 22px; font-weight: 700; color: var(--accent); font-variant-numeric: tabular-nums; white-space: nowrap; }
}
@media (max-width: 680px) {
  .cpanel, .cres { padding: 16px; }
  .cmini { margin: -16px -16px 12px; padding: 10px 16px; }
  .tabs { margin-bottom: 16px; }
  .tabs button { padding: 0 4px; }
  .cgroup + .cgroup { margin-top: 8px; padding-top: 12px; }
  .chart { flex-basis: 100%; max-width: none; }
  .cbars { height: 48px; }
  .lines { margin-top: 16px; }
  .cres .btn { margin-top: 16px; }
}
/* Узкая панель: подпись и значение строкой, ползунок под ними */
@media (max-width: 520px) {
  .ctrl { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "lab val" "rng rng"; min-height: 0; padding: 2px 0 0; }
  .cfmt { grid-template-columns: minmax(0, 1fr); grid-template-areas: "rng"; padding: 4px 0 8px; }
  .cfmt .seg { grid-column: 1; }
  /* Слово «Формат» видно только экранному диктору: кнопки сами говорят, что выбираешь */
  .cfmt .clab { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}

details.how, .qa, .objs details { --plus: var(--accent); }
details.how { margin-top: 16px; font-size: 13px; }
details.how summary { cursor: pointer; color: var(--fg); list-style: none; display: inline-flex; align-items: center; gap: 10px; }
details.how summary::-webkit-details-marker, .qa summary::-webkit-details-marker, .objs summary::-webkit-details-marker { display: none; }
details.how p { font-size: 13px; margin-top: 10px; line-height: 1.6; }

/* Плюс, который становится минусом: два отрезка вместо символа */
.pm-ico { position: relative; width: 12px; height: 12px; flex-shrink: 0; }
.pm-ico::before, .pm-ico::after { content: ""; position: absolute; background: var(--plus); }
.pm-ico::before { left: 0; right: 0; top: 50%; height: 2px; margin-top: -1px; }
.pm-ico::after { top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; transition: transform var(--dur-fast) var(--ease-out); }
details[open] > summary .pm-ico::after { transform: scaleY(0); }

/* ---------- партнёрская сеть и каталог ---------- */
.filters { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 24px; }
.filters button { min-height: 36px; padding: 0 14px; border: 1px solid var(--surface-line); font-size: 13px; font-weight: 500; color: var(--mid); white-space: nowrap; transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out); }
.filters button:hover { color: var(--fg); border-color: var(--mid-dim); }
.filters button[aria-pressed=true] { background: var(--fg); color: #000; border-color: var(--fg); }
/* Карточки каталога: отдельные модули с воздухом, аватар, условия плашкой,
   цифры в своих ячейках, действие отдельной кнопкой */
.offers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.oc { min-width: 0; padding: 24px; display: flex; flex-direction: column; gap: 16px; text-align: left; background: var(--surface); border: 1px solid var(--line); transition: border-color var(--dur-fast) var(--ease-out), background var(--dur-fast) var(--ease-out); }
button.oc { cursor: pointer; }
button.oc:hover { border-color: var(--accent-line); background: var(--surface-hi); }
.oc-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
.oc-top .ava { width: 48px; height: 48px; font-size: 16px; border-color: var(--surface-line); }
.oc-who { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.oc-who b { font-size: 14px; font-weight: 600; line-height: 1.3; color: var(--fg); }
.oc-who span { font-size: 13px; line-height: 1.3; color: var(--mid); }
.match { align-self: flex-start; padding: 4px 6px; border: 1px solid var(--surface-line); font: 500 10px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--mid-dim); white-space: nowrap; }
.oc h3 { font-size: 18px; font-weight: 600; line-height: 1.3; letter-spacing: -0.01em; }
.oc .aud { font-size: 14px; color: var(--mid); margin-top: -8px; }
.oc-terms { align-self: flex-start; padding: 6px 10px; background: var(--accent-bg); color: var(--accent); font-size: 13px; font-weight: 500; line-height: 1.35; }
.oc-nums { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.oc-nums.three { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr) minmax(0, 1fr); }
.oc-nums.three div { padding: 10px 8px; font-size: 11px; letter-spacing: -0.01em; }
.oc-nums.three b { font-size: 15px; white-space: normal; }
.oc-nums .hot { grid-column: 1 / -1; display: flex; align-items: baseline; gap: 8px; background: var(--accent-bg); border-color: var(--accent-line); }
.oc-nums .hot b { margin-bottom: 0; font-size: 18px; }
.oc-nums div { min-width: 0; padding: 12px; background: var(--surface-deep); border: 1px solid var(--line); font-size: 12px; line-height: 1.3; color: var(--mid); }
.oc-nums b { display: block; margin-bottom: 6px; font-size: 17px; font-weight: 700; color: var(--fg); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.oc-nums .hot b { color: var(--accent); }
.oc-foot { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: auto; min-height: 44px; border: 1px solid var(--surface-line); font-size: 13px; font-weight: 600; text-transform: uppercase; color: var(--fg); transition: border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out); }
button.oc:hover .oc-foot { border-color: var(--accent); color: var(--accent); }
.oc-foot.muted { justify-content: flex-start; min-height: 0; border: 0; font-size: 13px; font-weight: 400; text-transform: none; color: var(--mid-dim); }
/* Заглушки на время загрузки каталога: держат место, чтобы страница не прыгала */
.oc.skel { min-height: 340px; border-color: var(--line); background: linear-gradient(90deg, var(--surface) 0%, var(--surface-hi) 50%, var(--surface) 100%); background-size: 200% 100%; animation: shimmer 1.4s linear infinite; }
#filters:empty { min-height: 36px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.ig-grid img, .ig-ava img, .ig-hl img { background: var(--surface); }
.more-row { display: flex; justify-content: center; margin-top: 24px; }
.owner { margin-top: 24px; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 24px 28px; }
.owner h3 { font-size: 17px; }
.owner p { font-size: 14px; margin-top: 6px; max-width: 64ch; }
.owner .btns { display: flex; gap: 8px; flex-wrap: wrap; flex-shrink: 0; }

/* ---------- автопилот ---------- */
.engine { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 64px; align-items: center; }
.engine .sec-head { margin-bottom: 32px; }
.feats { display: grid; border-top: 1px solid var(--line); }
.feat { display: flex; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.feat .ic { display: grid; place-items: center; width: 40px; height: 40px; flex-shrink: 0; background: var(--accent-bg); border: 1px solid var(--accent-line); color: var(--accent); }
.feat .ic svg, .ev .e svg { width: 20px; height: 20px; }
.feat b { display: block; font-size: 15px; font-weight: 600; }
.feat p { font-size: 14px; margin-top: 2px; }
/* Окно бота: имитация Telegram, единственное место со скруглениями */
.phone { max-width: 420px; width: 100%; margin-left: auto; padding: 12px; background: var(--surface-deep); border: 1px solid var(--surface-line); border-radius: 12px; }
.phone-top { display: flex; align-items: center; gap: 10px; padding: 6px 6px 12px; border-bottom: 1px solid var(--line); }
.phone-top .mark-img { width: 34px; height: 34px; }
.phone-top b { font-size: 14px; display: block; }
.phone-top span { font-size: 12px; color: var(--mid-dim); }
.feed { height: 360px; overflow: hidden; padding: 12px 0 0; display: flex; flex-direction: column; gap: 8px; mask-image: linear-gradient(#000 72%, transparent); -webkit-mask-image: linear-gradient(#000 72%, transparent); }
.ev { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border-radius: 10px; background: var(--surface-hi); animation: pop var(--dur-base) var(--ease-out); }
.ev .e { display: grid; place-items: center; width: 30px; height: 30px; flex-shrink: 0; border-radius: 8px; background: var(--surface-line); color: var(--fg); }
.ev .e svg { width: 16px; height: 16px; }
.ev b { display: block; font-size: 13px; font-weight: 600; }
.ev p { font-size: 12px; margin-top: 2px; }
.ev time { margin-left: auto; font: 500 11px/1 var(--font-mono); color: var(--mid-dim); flex-shrink: 0; }
.ev.money .e { background: var(--success-bg); color: var(--success); }
.ev.money b span { color: var(--success); }
@keyframes pop { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: none; } }
.today { display: flex; justify-content: space-between; gap: 12px; padding: 12px 6px 4px; font-size: 12px; color: var(--mid); border-top: 1px solid var(--line); margin-top: 6px; }
.today b { color: var(--fg); font-variant-numeric: tabular-nums; }

/* ---------- как это работает ---------- */
.how3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.hs { padding: 28px; display: flex; flex-direction: column; gap: 10px; background: var(--surface); }
.hs h3 { font-size: 19px; display: flex; align-items: baseline; gap: 12px; }
.hs .n { font: 500 13px/1 var(--font-mono); color: var(--accent); }
.hs p { font-size: 14px; }
.hs .t { margin-top: auto; align-self: flex-start; }
.prices { margin-top: 24px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border: 1px solid var(--line); }
.prices div { padding: 20px 24px; }
.prices div + div { border-left: 1px solid var(--line); }
.prices b { display: block; font-size: 24px; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.prices span { display: block; margin-top: 4px; font-size: 13px; color: var(--mid); }

/* ---------- вопросы ---------- */
.faq { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 64px; }
.faq h2 { font-size: var(--fs-h2); }
.faq > div:last-child { border-top: 1px solid var(--line); }
.qa { border-bottom: 1px solid var(--line); }
.qa summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 20px 0; font-size: 17px; font-weight: 600; }
.qa summary:hover { color: var(--accent); }
.qa p { font-size: 15px; padding: 0 40px 20px 0; line-height: 1.6; }

/* ---------- финал и подвал ---------- */
.final-sec { padding-top: 0; border-top: 0; }
.final { padding: 64px 40px; background: var(--surface); border: 1px solid var(--line); border-top: 2px solid var(--accent); text-align: center; }
.final h2 { font-size: var(--fs-h2); max-width: 22ch; margin: 0 auto; }
.final p { font-size: var(--fs-lead); max-width: 52ch; margin: 16px auto 0; }
.final .analyzer { margin: 32px auto 0; text-align: left; }

/* ---------- подвал как на banka.bot ---------- */
.site-footer { border-top: 1px solid var(--line); }
.footer-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; padding-block: 64px 40px; }
.footer-brand { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; }
.footer-brand img { width: 36px; height: 36px; }
.footer-wordmark { font-size: 20px; font-weight: 700; text-transform: uppercase; letter-spacing: -0.02em; }
.footer-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.foot-note, .foot-title { font: 500 11px/1.4 var(--font-mono); letter-spacing: 0.25em; text-transform: uppercase; color: var(--mid-dim); }
.footer-links { display: grid; gap: 32px; padding-top: 40px; padding-bottom: 48px; border-top: 1px solid var(--line); }
.footer-col { display: flex; flex-direction: column; gap: 4px; }
.foot-title { margin-bottom: 16px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.footer-col a { display: inline-flex; align-items: center; min-height: 40px; font-size: 14px; line-height: 1.35; color: var(--mid); transition: color var(--dur-fast) var(--ease-out); }
.footer-col a:hover { color: var(--accent); }
.footer-bottom { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; padding-block: 24px; border-top: 1px solid var(--line); }
.footer-bottom .foot-note { letter-spacing: 0.12em; max-width: 70ch; }
.footer-side { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; }
.footer-social { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding-inline: 8px; color: var(--mid); font: 500 11px/1 var(--font-mono); letter-spacing: 0.25em; text-transform: uppercase; transition: color var(--dur-fast) var(--ease-out); }
.footer-social:hover { color: var(--accent); }
.to-top { width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid var(--surface-line); color: var(--mid); transition: border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out); }
.to-top:hover { border-color: var(--accent); color: var(--accent); }
@media (min-width: 640px) { .footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 24px; } }
@media (min-width: 1024px) { .footer-links { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- окна ---------- */
dialog {
  border: 1px solid var(--surface-line);
  border-radius: 0;
  background: var(--surface);
  color: var(--fg);
  padding: 0;
  width: calc(100% - 32px);
  max-width: 560px;
  max-height: 90dvh;
}
dialog::backdrop { background: rgba(0, 0, 0, 0.72); }
.mb { padding: 32px; }
.mtop { display: flex; justify-content: flex-end; margin: -12px -12px 4px 0; }
.x { display: grid; place-items: center; width: 40px; height: 40px; border: 1px solid var(--surface-line); color: var(--mid); }
.x:hover { color: var(--fg); border-color: var(--mid-dim); }
.x svg { width: 16px; height: 16px; }
.mb h2 { font-size: 24px; text-transform: none; letter-spacing: -0.02em; line-height: 1.2; }
.mb > p { font-size: 15px; margin-top: 10px; }
.kv { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; margin-top: 20px; box-shadow: 0 0 0 1px var(--line); }
.kv div { padding: 14px 16px; background: var(--surface-deep); box-shadow: 0 0 0 1px var(--line); font-size: 12px; color: var(--mid-dim); }
.kv b { display: block; margin-bottom: 4px; font-size: 17px; font-weight: 700; color: var(--fg); font-variant-numeric: tabular-nums; }
.kv .hot b { color: var(--accent); }
.kit { margin-top: 14px; display: grid; gap: 8px; }
.kit div { position: relative; padding-left: 22px; font-size: 14px; color: var(--fg); }
.kit div::before { content: ""; position: absolute; left: 2px; top: 4px; width: 6px; height: 10px; border: solid var(--accent); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.handoff { margin-top: 12px; display: grid; gap: 1px; box-shadow: 0 0 0 1px var(--line); }
.handoff div { display: flex; justify-content: space-between; gap: 12px; padding: 12px 14px; background: var(--surface-deep); box-shadow: 0 0 0 1px var(--line); font-size: 13px; color: var(--mid); }
.handoff b { color: var(--fg); font-weight: 600; text-align: right; }
.mnote { font-size: 13px; color: var(--mid-dim); margin-top: 14px; }
.modal-label { margin-top: 24px; }

/* ---------- разбор ---------- */
#report { padding: 64px 0 32px; border-top: 1px solid var(--line); }
.scan { max-width: 640px; margin: 0 auto; padding: 32px; }
.scan h3 { font-size: 22px; }
.scan .handle { color: var(--accent); }
.scan > p { font-size: 14px; margin-top: 8px; }
.progress { height: 4px; background: var(--surface-line); margin: 24px 0 20px; overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; background: var(--accent); transition: width 0.5s var(--ease-out); }
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.steps li { display: flex; gap: 12px; align-items: center; font-size: 14px; color: var(--mid-dim); transition: color var(--dur-base); }
.steps li .st { position: relative; width: 16px; height: 16px; border: 1px solid var(--surface-line); flex-shrink: 0; }
.steps li.on { color: var(--fg); }
.steps li.on .st { border-color: var(--accent); animation: blink 0.8s ease-in-out infinite alternate; }
.steps li.done { color: var(--fg); }
.steps li.done .st { border-color: var(--accent); background: var(--accent); }
.steps li.done .st::after { content: ""; position: absolute; left: 4px; top: 1px; width: 5px; height: 9px; border: solid #000; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.steps li .cnt { margin-left: auto; font: 500 12px/1 var(--font-mono); color: var(--mid-dim); }
@keyframes blink { to { background: var(--accent-bg); } }
.wait-cta { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 24px; padding: 16px; background: var(--accent-bg); border: 1px solid var(--accent-line); opacity: 0; animation: rise 0.5s var(--ease-out) 2.2s forwards; }
.wait-cta p { font-size: 14px; color: var(--fg); }
.fail-btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 20px; }

.demo-note { margin-bottom: 16px; padding: 14px 18px; border: 1px solid var(--line); border-left: 2px solid var(--accent); font-size: 14px; color: var(--mid); }
.demo-note b { color: var(--fg); }
.snav {
  position: sticky;
  top: var(--header-h);
  z-index: 6;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 10px var(--pad);
  margin: 0 calc(var(--pad) * -1) 16px;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  scrollbar-width: none;
}
.snav::-webkit-scrollbar { display: none; }
.snav a { flex: none; padding: 8px 12px; border: 1px solid var(--surface-line); font-size: 13px; color: var(--mid); transition: color var(--dur-fast), border-color var(--dur-fast); }
.snav a:hover { color: var(--fg); border-color: var(--accent); }
.rc[id] { scroll-margin-top: calc(var(--header-h) + 72px); }

.rgrid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); }
.rgrid > *, .calc > *, .engine > *, .hero-grid > *, .icp > *, .how3 > * { min-width: 0; }
.rc { padding: 28px; background: var(--surface); opacity: 0; transform: translateY(10px); animation: rise 0.5s var(--ease-out) forwards; }
@keyframes rise { to { opacity: 1; transform: none; } }
.s12 { grid-column: span 12; } .s8 { grid-column: span 8; } .s7 { grid-column: span 7; } .s6 { grid-column: span 6; } .s5 { grid-column: span 5; } .s4 { grid-column: span 4; }
.rc h3 { font-size: 19px; }
.rc .sub { font-size: 14px; margin: -8px 0 16px; }
/* Заголовок модуля разбора: обычный заголовок карточки, не надпись над ним */
.rlabel { display: block; margin-bottom: 16px; font-family: var(--font-sans); font-size: 17px; font-weight: 600; letter-spacing: -0.01em; text-transform: none; color: var(--fg); }
.rlabel.sm { margin: 24px 0 12px; font-size: 14px; color: var(--mid); }
.rhead { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; padding: 24px 28px; }
.rhead .ava { width: 52px; height: 52px; font-size: 20px; }
.rhead h3 { font-size: 22px; }
.rhead .who { flex: 1; min-width: 220px; }
.rhead .meta { font-size: 14px; color: var(--mid); margin-top: 4px; }
.stats { display: flex; gap: 32px; flex-wrap: wrap; }
.stat b { display: block; font-size: 22px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.stat span { font-size: 12px; color: var(--mid-dim); }

.score { display: flex; gap: 24px; align-items: flex-end; }
.score .ring > div { font-size: 64px; }
.score h3 { font-size: 19px; }
.verdict { font-size: 15px; color: var(--mid); margin-top: 8px; }
.loss { margin-top: 24px; padding: 16px 18px; background: var(--accent-bg); border-left: 2px solid var(--accent); }
.loss p { font-size: 16px; color: var(--fg); }

.persona { font-size: 16px; color: var(--fg); line-height: 1.6; }
.fine { font-size: 12px; color: var(--mid-dim); margin-top: 12px; }
.bars { display: grid; gap: 14px; margin-top: 24px; }
.bar { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; font-size: 14px; color: var(--mid); align-items: center; }
.bar .track { grid-column: 1 / -1; }
.bar b { color: var(--fg); text-align: right; font-variant-numeric: tabular-nums; }

.jobs, .segs, .clusters, .grow, .ladder, .slinks { display: grid; }
.jobs { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 0; }
.jobs div, .psy div { padding: 16px; background: var(--surface-deep); font-size: 14px; color: var(--fg); }
.jobs small, .psy small, .ladder small { display: block; margin-bottom: 8px; }
.psy { display: grid; gap: 1px; box-shadow: 0 0 0 1px var(--line); }
.psy > div { box-shadow: 0 0 0 1px var(--line); }
.segs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.seg-c { padding: 20px; background: var(--surface-deep); display: grid; gap: 8px; align-content: start; font-size: 14px; }
.seg-c h4 { font-size: 16px; }
.seg-c > span { color: var(--mid); }
.seg-c dl { display: grid; grid-template-columns: auto 1fr; gap: 8px 16px; margin-top: 8px; }
.seg-c dt { font-size: 12px; color: var(--mid-dim); padding-top: 1px; }
.seg-c dd { color: var(--fg); }

.clusters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cl { padding: 18px; background: var(--surface-deep); display: flex; flex-direction: column; }
.cl-top { display: flex; align-items: baseline; gap: 10px; }
.cl-top b { font-size: 15px; font-weight: 600; }
.cl-pct { margin-left: auto; font-weight: 700; color: var(--accent); font-variant-numeric: tabular-nums; }
.cl .track { margin: 10px 0 12px; }
.cl q { display: block; quotes: none; font-size: 13px; color: var(--mid); padding: 8px 12px; border-left: 2px solid var(--surface-line); }
.cl q + q { margin-top: 6px; }
.cl q:nth-of-type(n+3) { display: none; }
.cl .to { margin-top: auto; padding-top: 12px; font-size: 13px; color: var(--accent); }

.objs { display: grid; border-top: 1px solid var(--line); }
.objs details { border-bottom: 1px solid var(--line); }
.objs summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 0; font-size: 14px; font-weight: 600; }
.objs p { padding: 0 0 12px; font-size: 13px; }

.fmt { display: grid; gap: 12px; }
.fm { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; font-size: 14px; color: var(--fg); }
.fm .track { grid-column: 1 / -1; }
.fm b { font-variant-numeric: tabular-nums; }
.fm.bad .track i { background: var(--mid-dim-700); }
.fm.bad b { color: var(--danger); }
.fm.good b { color: var(--success); }
.fmt-h { margin: 16px 0 4px; font: 500 11px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--mid-dim); }
.fmt-h:first-child { margin-top: 0; }

.slinks { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sl { padding: 18px; background: var(--surface-deep); }
.sl-flow { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; color: var(--fg); }
.sl-kw { font: 500 12px/1.3 var(--font-mono); color: var(--accent); padding: 4px 8px; background: var(--accent-bg); }
.sl-num { display: flex; align-items: baseline; gap: 10px; margin-top: 12px; }
.sl-num b { font-size: 26px; font-weight: 700; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.sl-num span { font-size: 13px; color: var(--mid); }
.sl p { font-size: 13px; margin-top: 8px; }

.grow { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.gi { padding: 18px; background: var(--surface-deep); }
.gi b { display: flex; gap: 10px; align-items: baseline; margin-bottom: 6px; font-size: 15px; font-weight: 600; }
.gi .n { font: 500 13px/1 var(--font-mono); color: var(--accent); }
.gi p { font-size: 13px; }

.offer-box { padding: 24px; background: var(--accent-bg); border: 1px solid var(--accent-line); }
.offer-box h4 { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.2; }
.offer-box .inside { font-size: 14px; margin-top: 8px; }
.offer-row { display: flex; align-items: center; gap: 12px; margin-top: 16px; flex-wrap: wrap; }
.offer-row .price { font-size: 32px; margin-right: auto; }
.promise { margin-top: 16px; font-size: 15px; color: var(--fg); padding-left: 12px; border-left: 2px solid var(--accent); }
.why { margin-top: 12px; font-size: 13px; }
.why b { color: var(--fg); font-weight: 600; }
.ladder { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ladder div { padding: 14px; background: var(--surface-deep); font-size: 13px; color: var(--fg); display: flex; flex-direction: column; }
.ladder div.main { box-shadow: 0 0 0 1px var(--accent); z-index: 1; }
.ladder b { display: block; color: var(--accent); margin-top: 6px; font-size: 14px; font-variant-numeric: tabular-nums; }
.ladder small { margin: 8px 0 0; }

.pmini { display: grid; border-top: 1px solid var(--line); }
.pm { display: flex; gap: 12px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); text-align: left; width: 100%; }
.pm:hover b { color: var(--accent); }
.pm .ava { width: 36px; height: 36px; font-size: 14px; }
.pm > div { flex: 1; min-width: 0; }
.pm b { display: block; font-size: 14px; font-weight: 600; transition: color var(--dur-fast); }
.pm span { font-size: 12px; color: var(--mid); }
.pm .earn { text-align: right; flex: none; }
.pm .earn b { color: var(--accent); font-size: 16px; font-weight: 700; white-space: nowrap; }
.r-more { display: inline-block; margin-top: 16px; font-size: 14px; }

.fc { display: grid; gap: 12px; }
.fc-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 12px; border-bottom: 1px solid var(--line); font-size: 14px; color: var(--mid); }
.fc-row b { font-size: 18px; font-weight: 700; color: var(--fg); white-space: nowrap; font-variant-numeric: tabular-nums; }
.fc-total { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; font-size: 15px; color: var(--fg); }
.fc-total b { font-size: clamp(1.75rem, 3.2vw, 2.5rem); font-weight: 700; letter-spacing: -0.03em; color: var(--accent); white-space: nowrap; font-variant-numeric: tabular-nums; }
.rc .btn.ghost.sm { margin-top: 16px; }

.rcta { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 32px; background: var(--accent-bg); box-shadow: 0 0 0 1px var(--accent-line) !important; z-index: 1; }
.rcta h3 { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; }
.rcta p { margin-top: 8px; font-size: 15px; }
.rcta .btns { display: flex; gap: 8px; flex-wrap: wrap; flex-shrink: 0; }

.mcta { display: none; }
.toast { position: fixed; left: 50%; bottom: 24px; z-index: 99; padding: 12px 18px; background: var(--fg); color: #000; font-size: 14px; font-weight: 600; opacity: 0; transform: translateX(-50%) translateY(16px); transition: opacity var(--dur-base), transform var(--dur-base); pointer-events: none; }
.toast.on { opacity: 1; transform: translateX(-50%); }

/* ---------- адаптив ---------- */
@media (max-width: 1140px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 48px; }
  .mock { max-width: 640px; }
  .offers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero h1 { max-width: 22ch; }
}

@media (max-width: 1020px) {
  :root { --pad: 24px; }
  .s7, .s5, .s6, .s4, .s8 { grid-column: span 12; }
  .icp, .how3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .offers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .clusters, .grow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .calc, .engine { grid-template-columns: minmax(0, 1fr); }
  .engine { gap: 40px; }
  .phone { margin: 0 auto; }
  .faq { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .prices { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .prices div + div { border-left: 0; }
  .prices div:nth-child(even) { border-left: 1px solid var(--line); }
  .prices div:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* Карусели: на узком экране карточки листаются вбок */
@media (max-width: 760px) {
  .icp, #bcards, .how3 {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: 84%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    box-shadow: none;
    padding: 1px;
    margin: 0 calc(var(--pad) * -1 + 1px);
    padding-left: calc(var(--pad) - 1px);
    padding-right: calc(var(--pad) - 1px);
    scroll-padding-left: calc(var(--pad) - 1px);
  }
  .icp::-webkit-scrollbar, #bcards::-webkit-scrollbar, .how3::-webkit-scrollbar { display: none; }
  .icp > *, #bcards > *, .how3 > * { scroll-snap-align: start; }
}

@media (max-width: 680px) {
  :root { --pad: 16px; --header-h: 65px; }
  .sec { padding: 56px 0; }
  .sec-head { margin-bottom: 28px; gap: 12px; }
  .cta { min-height: 40px; padding: 0 14px; font-size: 12px; }
  .header-inner { padding-block: 10px; }
  .hero { padding: 32px 0 48px; }
  /* Профиль Instagram во всю ширину, под ним одна строка постов, карточки разбора заходят на неё снизу */
  .mock { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; margin-top: 8px; }
  .ig { grid-column: 1 / -1; grid-row: auto; }
  .ig-grid img:nth-child(n+4) { display: none; }
  .mcard { margin-left: 0; padding: 16px; }
  .mcard > b { font-size: clamp(20px, 6vw, 24px); }
  .mcard > span { font-size: 13px; }
  .m1 { grid-column: 1; grid-row: auto; align-self: stretch; margin: -64px 0 0 10px; }
  .m2 { grid-column: 2; grid-row: auto; align-self: stretch; margin: -64px 10px 0 0; }
  .m3 { grid-column: 1 / -1; grid-row: auto; margin: 0; }
  .mcard > b.mprod { font-size: 15px; }
  .mrow .price { font-size: 24px; }
  .inrow { flex-direction: column; }
  .inrow input { flex: none; width: 100%; border-right: 1px solid var(--surface-line); border-bottom: 0; }
  .inrow input:focus { border-bottom: 0; }
  .inrow .btn { width: 100%; }
  .plat { display: flex; }
  .plat button { flex: 1; justify-content: center; }
  .icard, .hs { padding: 20px; }
  .offers { grid-template-columns: minmax(0, 1fr); }
  .filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 calc(var(--pad) * -1) 16px; padding: 0 var(--pad); }
  .filters::-webkit-scrollbar { display: none; }
  .oc { padding: 18px; gap: 12px; }
  .owner { flex-direction: column; align-items: stretch; padding: 20px; gap: 16px; }
  .owner .btns { flex-direction: column; }
  .owner .btn, .owner .btns .btn { width: 100%; }
  .feat { padding: 12px 0; gap: 12px; }
  .feat .ic { width: 32px; height: 32px; }
  .feat .ic svg { width: 16px; height: 16px; }
  .feed { height: 250px; }
  .prices div { padding: 16px; }
  .prices b { font-size: 20px; }
  .qa summary { font-size: 16px; padding: 16px 0; }
  .qa p { padding-right: 0; }
  .final { padding: 40px 20px; }
  .mb { padding: 24px; }
  .kv { grid-template-columns: 1fr 1fr; }

  #report { padding-top: 40px; }
  .snav { padding: 8px var(--pad); margin-bottom: 12px; }
  .rc { padding: 20px; }
  .rhead { padding: 20px; gap: 14px; }
  .rhead .who { min-width: 0; }
  .rhead h3 { font-size: 19px; }
  .stats { gap: 16px 24px; }
  .stat b { font-size: 18px; }
  .score { flex-direction: column; align-items: flex-start; gap: 16px; }
  .score .ring > div { font-size: 52px; }
  .jobs, .segs, .clusters, .grow, .ladder, .slinks { grid-template-columns: minmax(0, 1fr); }
  .cl q:nth-of-type(n+2) { display: none; }
  .seg-c { padding: 16px; }
  .rcta { flex-direction: column; align-items: stretch; padding: 20px; }
  .rcta .btns { flex-direction: column; }
  .rcta .btns .btn { width: 100%; }
  .wait-cta { flex-direction: column; align-items: stretch; }
  .offer-row .price { font-size: 28px; }
  body.has-report .mcta {
    display: flex;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 25;
    padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(10px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
    background: var(--bg);
    border-top: 1px solid var(--line);
    transform: translateY(110%);
    transition: transform var(--dur-base) var(--ease-out);
  }
  body.has-report .mcta.on { transform: none; }
  body.has-report .mcta .btn { flex: 1; min-height: 48px; }
  body.has-report .site-footer { padding-bottom: 96px; }
}

@media (max-width: 380px) {
  .ig-stats span { font-size: 10px; }
  .stats { gap: 12px 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .rc, .wait-cta { opacity: 1; transform: none; }
}
