/* Интент, редакция по макету Figma (октябрь 2026).
   Шрифты: Inter Tight — интерфейс и заголовки, Merriweather italic — акценты.
   Оба лежат в assets/fonts: CSP сайта разрешает только собственный источник.
   Цвета — пять токенов макета, остальные оттенки выводятся из них. */
@font-face {
  font-family: "Inter Tight";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../../assets/fonts/intertight.woff2") format("woff2");
}
@font-face {
  font-family: Merriweather;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../../assets/fonts/merriweather.woff2") format("woff2");
}
@font-face {
  font-family: Merriweather;
  font-style: italic;
  font-weight: 300 500;
  font-display: swap;
  src: url("../../assets/fonts/merriweather-italic.woff2") format("woff2");
}
@font-face {
  font-family: Merriweather;
  font-style: italic;
  font-weight: 600 800;
  font-display: swap;
  src: url("../../assets/fonts/merriweather-semibold-italic.woff2") format("woff2");
}

:root {
  --yellow: #f9cd45;
  --black: #202224;
  --gray: #7f868e;
  --light: #edeff5;
  --white: #fff;
  --ink: var(--black);
  --muted: var(--gray);
  --line: #e3e6ee;
  --body: #45494e;
  --yellow-soft: #fdf0c4;
  --dark-2: #2a2d30;
  --dark-line: #3a3d41;
  --dark-muted: #9aa0a7;
  --sans: "Inter Tight", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  --serif: Merriweather, Georgia, "Times New Roman", serif;
  --radius: 20px;
  --radius-lg: 32px;
  --shadow: 0 0 24px rgb(13 13 13 / 12%);
  --shadow-sm: 0 0 12px rgb(13 13 13 / 12%);
  --wrap: 1200px;
  --gutter: 24px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--white);
  color: var(--ink);
  font: 400 18px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg, video { max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; }

/* Заголовки: гротеск + курсивный акцент антиквой */
h1, h2, h3 { font-family: var(--sans); font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; }
/* Курсив антиквой — только в главных заголовках: первый экран и заголовки блоков (решение владельца 22.10.2026) */
h3 em { font-style: normal; }
h1 em, h2 em {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 600;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(40px, 5.2vw, 71px); line-height: 1.15; }
h1 em { line-height: 1.1; }
h2 { font-size: clamp(30px, 3.4vw, 48px); line-height: 1.2; }
h3 { font-size: 20px; line-height: 1.3; letter-spacing: -0.01em; }

.container { width: min(var(--wrap), calc(100% - 2 * var(--gutter))); margin-inline: auto; }
.section { padding: 60px 0; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  padding: 10px 16px; border-radius: 999px; background: var(--black); color: var(--white); text-decoration: none;
}
.skip-link:focus { top: 12px; }
:focus-visible { outline: 2px solid var(--black); outline-offset: 3px; border-radius: 6px; }

/* Шапка секции: заголовок и подзаголовок по центру, как в макете */
.rs-head { max-width: 860px; margin: 0 auto 56px; text-align: center; }
.rs-head .rs-lead, .rs-lead { margin-top: 16px; color: var(--muted); font-size: 18px; line-height: 1.4; }
.rs-head .rs-lead { margin-inline: auto; max-width: 640px; }
/* Надзаголовков в макете нет — оставляем их только для скринридеров */
.rs-eyebrow, .eyebrow { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Кнопки */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 62px; padding: 0 36px;
  border: 1px solid transparent; border-radius: 60px;
  font: 500 18px/1.4 var(--sans); text-decoration: none; text-align: center;
  cursor: pointer; transition: background-color .15s, border-color .15s, color .15s, transform .15s;
}
.button-primary { background: var(--yellow); color: var(--black); }
.button-primary:hover { background: #f4c22a; }
.button-secondary { background: transparent; border-color: var(--yellow); color: var(--black); }
.button-secondary:hover { background: var(--yellow-soft); }
.button-small { min-height: 42px; padding: 0 22px; font-size: 15px; }
.button-block { display: flex; width: 100%; }
.button[aria-disabled="true"] { pointer-events: none; }

/* Общие карточки и подписи, которыми пользуются секции */
.rs-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); }
.rs-muted { color: var(--muted); }
.rs-label { display: block; color: var(--muted); font-size: 13px; }
.rs-chip {
  display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 12px;
  border-radius: 999px; background: var(--light); color: var(--black); font-size: 13px; font-weight: 500;
}

/* Шапка сайта */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgb(255 255 255 / 92%); backdrop-filter: blur(10px);
}
.header-inner { display: flex; align-items: center; gap: 32px; height: 78px; }
.brand { display: inline-flex; align-items: center; flex: none; text-decoration: none; }
.brand img { display: block; width: 148px; height: 38px; }
.main-nav { display: flex; gap: 40px; margin-inline: auto; font-size: 14px; font-weight: 500; }
.main-nav a { text-decoration: none; }
.main-nav a:hover { color: var(--muted); }
.header-actions { display: flex; align-items: center; gap: 28px; }
.login-link { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; text-decoration: none; }
.login-link img { width: 16px; height: 16px; }
.header-actions .button-small { min-height: 38px; padding: 0 28px; font-size: 13px; }
.menu-toggle {
  display: none; width: 44px; height: 44px; margin-left: auto; padding: 0;
  border: 0; border-radius: 12px; background: var(--light); cursor: pointer;
}
.menu-toggle span:not(.sr-only) { display: block; width: 18px; height: 2px; margin: 4px auto; border-radius: 2px; background: var(--black); transition: transform .2s, opacity .2s; }
.menu-toggle[aria-expanded="true"] span:nth-of-type(2) { transform: translateY(6px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-of-type(3) { transform: translateY(-6px) rotate(-45deg); }

/* Первый экран */
.hero { position: relative; overflow: hidden; padding: 72px 0 60px; text-align: center; }
/* Фон по макету (Figma 66:198): серые волны 1372×865 от 84px сверху */
.hero::before {
  content: ""; position: absolute; top: 84px; left: 50%; z-index: -1;
  width: min(1372px, 100%); aspect-ratio: 1372 / 865; transform: translateX(-50%);
  background: url("../../assets/intent/hero-bg.jpg") center / contain no-repeat;
}
.hero-copy h1 { max-width: 1100px; margin-inline: auto; }
.hero-copy h1 em { display: inline-block; }
.hero-copy .lead { max-width: 640px; margin: 24px auto 0; color: var(--muted); font-size: 20px; line-height: 1.4; text-wrap: balance; }
/* Переносы из админки в подзаголовке не используем: строки задаёт ширина, как в макете (две строки) */
.hero-copy .lead br { display: none; }
.hero-actions { display: flex; justify-content: center; gap: 20px; margin-top: 40px; }
.hero-actions .button { min-width: 285px; }

.hero-stage { position: relative; width: min(1200px, calc(100% - 2 * var(--gutter))); margin: 72px auto 0; }
.hero-laptop { position: relative; width: min(996px, 100%); margin-inline: auto; aspect-ratio: 996 / 624; }
.hero-screen {
  position: absolute; left: 7.43%; top: 1.12%; width: 85.44%; height: 82.6%;
  overflow: hidden; border-radius: 6px 6px 0 0; background: var(--light);
}
.hero-screen { container-type: inline-size; }
/* Лента в ноутбуке слегка размыта: внимание — на карточках сигналов вокруг (вариант A, 23.10.2026) */
.hero-screen .feed { filter: blur(1.6px); }

/* Лента сигналов на экране ноутбука: вёрстка в стиле кабинета, размеры
   в долях ширины экрана (cqw), чтобы картинка масштабировалась целиком */
.feed { display: flex; height: 100%; background: var(--light); color: var(--ink); text-align: left; }
.feed-side {
  display: flex; flex-direction: column; align-items: center; gap: 2.2cqw;
  width: 7.5cqw; padding: 2cqw 0; background: var(--white); border-right: 1px solid var(--line);
}
.feed-side img { width: 3.4cqw; height: auto; object-fit: cover; object-position: left; aspect-ratio: 1; }
.feed-side i { width: 2.6cqw; height: 2.6cqw; border-radius: .8cqw; background: var(--light); }
.feed-side i.is-on { background: var(--yellow); }
.feed-main { flex: 1; min-width: 0; padding: 2.4cqw 2.8cqw; }
.feed-top { display: flex; align-items: baseline; gap: 1.2cqw; font-size: 1.5cqw; }
.feed-top b { font: 600 2.1cqw/1.2 var(--sans); }
.feed-top span { color: var(--muted); }
.feed-top .feed-count { margin-left: auto; }
.feed-top mark { padding: .2cqw .8cqw; border-radius: 99px; background: var(--yellow); color: var(--ink); }
.feed-tabs { display: flex; gap: .8cqw; margin: 1.6cqw 0 1.8cqw; font-size: 1.35cqw; }
.feed-tabs span { padding: .55cqw 1.4cqw; border-radius: 99px; background: var(--white); color: var(--body); }
.feed-tabs .is-on { background: var(--black); color: var(--white); }
.feed-list { display: grid; gap: 1cqw; list-style: none; }
.feed-row {
  display: flex; align-items: center; gap: 1.6cqw; padding: 1.25cqw 1.6cqw;
  border-radius: 1.6cqw; background: var(--white);
}
.feed-ic { display: grid; place-items: center; flex: none; width: 4.4cqw; height: 4.4cqw; border-radius: 1.3cqw; }
.feed-ic img { width: 2.2cqw; height: 2.2cqw; }
.feed-ic-y { background: var(--yellow); }
.feed-ic-l { background: var(--light); }
.feed-ic-d { background: var(--black); }
.feed-text { display: grid; gap: .25cqw; min-width: 0; }
.feed-text b { font-size: 1.6cqw; font-weight: 600; line-height: 1.25; }
.feed-text span, .feed-text small { overflow: hidden; color: var(--muted); font-size: 1.3cqw; line-height: 1.3; white-space: nowrap; text-overflow: ellipsis; }
.feed-text em { color: var(--ink); font-style: normal; font-weight: 500; }
.feed-text small { font-size: 1.15cqw; color: #a5abb2; }
.feed-score {
  display: grid; place-items: center; flex: none; width: 4.2cqw; height: 4.2cqw; margin-left: auto;
  border: 1px solid var(--yellow); border-radius: 1.3cqw; font: 400 1.75cqw/1 var(--sans);
}
.hero-frame { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.hero-signal {
  position: absolute; z-index: 2; display: flex; align-items: center; gap: 12px;
  padding: 10px; border-radius: 20px; background: var(--white); box-shadow: var(--shadow-sm); text-align: left;
}
.hero-signal-ic { display: grid; place-items: center; flex: none; width: 42px; height: 42px; border-radius: 14px; background: var(--yellow); }
.hero-signal-ic img { width: 20px; height: 20px; }
.hero-signal-text { display: grid; gap: 4px; min-width: 0; }
.hero-signal-text strong { font: 400 14px/1.2 var(--sans); white-space: nowrap; }
.hero-signal-text span { color: var(--muted); font-size: 12px; line-height: 1.4; white-space: nowrap; }
.hero-signal-text b { font-weight: 500; }
.hero-signal-score {
  display: grid; place-items: center; flex: none; width: 42px; height: 42px; margin-left: 48px;
  border: 1px solid var(--yellow); border-radius: 14px; font: 400 16px/1 var(--sans);
}
/* Карточки-показатели вокруг ноутбука (Figma 73:258, 66:174) */
.hero-kpi {
  position: absolute; z-index: 2; display: grid; gap: 14px; padding: 16px 20px;
  border-radius: 20px; background: var(--white); box-shadow: var(--shadow-sm); text-align: left;
}
.hero-kpi small { display: block; margin-top: 4px; color: var(--muted); font-size: 12px; line-height: 1.4; }
.hero-kpi-sales { left: 8.8%; top: 29.6%; width: 300px; }
.hero-kpi-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.hero-kpi-head strong { font: 600 18px/1.2 var(--sans); }
.hero-kpi-head > b { font: 600 18px/1.2 var(--sans); white-space: nowrap; }
.hero-kpi-head i { color: var(--yellow); font-style: normal; }
.hero-kpi-bar { display: block; height: 4px; border-radius: 4px; background: var(--light); }
.hero-kpi-bar span { display: block; width: 78%; height: 100%; border-radius: 4px; background: var(--yellow); }
.hero-kpi-revenue { left: 65.3%; top: 66.5%; display: flex; align-items: center; gap: 16px; width: 300px; }
.hero-kpi-revenue b { font: 600 22px/1.2 var(--sans); white-space: nowrap; }
.hero-kpi-chart { flex: 1; min-width: 0; height: auto; }
.hero-signal-1 { left: 0; top: 14%; }
.hero-signal-2 { right: 3%; top: 30%; }
.hero-signal-3 { right: 0; top: 45%; }
.hero-signal-4 { left: 2%; top: 64%; }

/* Подвал: тёмная плашка шириной с контент, как в макете */
.site-footer {
  width: min(var(--wrap), calc(100% - 2 * var(--gutter)));
  margin: 60px auto 24px; padding: 28px 40px 22px;
  border-radius: var(--radius-lg); background: var(--black); color: var(--white); font-size: 14px;
}
.site-footer .container { width: 100%; }
.footer-top { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.footer-top .brand img { width: 128px; height: 33px; }
.footer-top nav { display: flex; gap: 32px; flex-wrap: wrap; }
.footer-top nav a { color: #e3e6ea; text-decoration: none; }
.footer-top nav a:hover { color: var(--yellow); }
.footer-top .button { min-height: 38px; padding: 0 24px; font-size: 13px; }
.footer-bottom {
  display: flex; justify-content: center; flex-wrap: wrap; gap: 8px 28px;
  margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--dark-line); font-size: 12.5px;
}
.footer-bottom a { color: var(--dark-muted); }
.footer-bottom a:hover { color: var(--white); }
.footer-bottom i { display: none; }

/* Уведомление о cookie */
.cookie-notice {
  position: fixed; left: 50%; bottom: 20px; z-index: 60; transform: translateX(-50%);
  display: flex; align-items: center; gap: 20px; width: min(880px, calc(100% - 32px));
  padding: 18px 20px; border-radius: var(--radius); background: var(--black); color: #e3e6ea;
  box-shadow: 0 12px 40px rgb(0 0 0 / 22%); font-size: 14.5px; line-height: 1.45;
}
.cookie-notice[hidden] { display: none; }
.cookie-notice a { color: var(--yellow); }
.cookie-actions { display: flex; gap: 10px; flex: none; }
.cookie-actions .button { min-height: 42px; padding: 0 20px; font-size: 14.5px; }
.cookie-actions .button-secondary { color: var(--white); border-color: var(--dark-line); }
.cookie-actions .button-secondary:hover { background: var(--dark-2); }


/* Сообщения формы */
.form-status { min-height: 1.2em; font-size: 14px; }
.form-status.error { color: #e0573d; }
.form-status.success { color: #2f7a4a; }

@media (max-width: 1100px) {
  .main-nav { gap: 24px; }
  .header-actions { gap: 16px; }
  .hero-signal-2, .hero-signal-3 { right: 0; }
}
@media (max-width: 960px) {
  .header-inner { height: 64px; }
  .menu-toggle { display: block; }
  .main-nav, .header-actions { display: none; }
  .main-nav.open {
    position: absolute; left: 0; right: 0; top: 64px; display: flex; flex-direction: column; gap: 0;
    padding: 8px var(--gutter) 20px; background: var(--white); box-shadow: 0 12px 24px rgb(0 0 0 / 8%); font-size: 18px;
  }
  .main-nav.open a { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .site-header:has(.main-nav.open) .header-actions {
    position: absolute; left: 0; right: 0; top: calc(64px + 4 * 55px + 28px);
    display: flex; flex-direction: column; align-items: stretch; gap: 12px;
    padding: 0 var(--gutter) 24px; background: var(--white);
  }
  .site-header:has(.main-nav.open) .header-actions .button-small { min-height: 52px; font-size: 16px; }
  .section { padding: 48px 0; }
  .hero-signal { transform: scale(.82); transform-origin: left center; }
  .hero-signal-2, .hero-signal-3 { transform-origin: right center; }
  .hero-signal-score { margin-left: 20px; }
}
@media (max-width: 640px) {
  :root { --gutter: 16px; }
  body { font-size: 17px; }
  .section { padding: 40px 0; }
  .rs-head { margin-bottom: 36px; }
  .hero { padding-top: 40px; }
  .hero-copy br { display: none; }
  .hero-copy .lead { font-size: 17px; }
  .hero-actions { flex-direction: column; align-items: stretch; gap: 12px; margin-top: 28px; }
  .hero-actions .button { min-width: 0; min-height: 56px; }
  .hero-stage { margin-top: 40px; }
  .hero-signal { position: static; transform: none; margin-top: 10px; }
  .hero-signal-score { margin-left: auto; }
  .hero-signal-text strong, .hero-signal-text span { white-space: normal; }
  .site-footer { padding: 24px 20px 18px; border-radius: 24px; }
  .footer-top nav { display: none; }
  .cookie-notice { flex-direction: column; align-items: stretch; bottom: 12px; }
  .cookie-actions { flex-direction: column; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Скрытые владельцем блоки (атрибут hidden) не возвращает ни одно правило секций */
[hidden] { display: none !important; }
@media (max-width: 640px) {
  .hero { padding-bottom: 40px; }
  .site-footer { margin-top: 40px; }
}
@media (max-width: 640px) { .hero-signal-3, .hero-signal-4 { display: none; } }
@media (max-width: 960px) { .hero-kpi { display: none; } }

/* Линии-волны в подвале (Figma 143:26): вектор 1200×513, начинается на 169px выше плашки */
.site-footer { position: relative; overflow: hidden; isolation: isolate; }
.site-footer::before {
  content: ""; position: absolute; z-index: -1; top: -169px; left: 0;
  width: 100%; min-width: 900px; aspect-ratio: 1200 / 513;
  background: url("../../assets/intent/lines/footer-waves.svg") center / 100% 100% no-repeat; pointer-events: none;
}
