/* enrichit — швейцарская типографика: сетка, один шрифт, один красный */

@font-face {
  font-family: "Onest";
  src: url("/fonts/onest-cyrillic.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Onest";
  src: url("/fonts/onest-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2190-2199, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Oswald";
  src: url("/fonts/oswald-cyrillic.woff2") format("woff2");
  font-weight: 200 700;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Oswald";
  src: url("/fonts/oswald-latin.woff2") format("woff2");
  font-weight: 200 700;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2190-2199, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --paper: #fafaf8;
  --ink: #000;
  --muted: #66665f;
  --rule: #d9d9d3;
  --red: #f0321a;
  --grid: rgba(240, 50, 26, .16);
  --gutter: clamp(16px, 2.2vw, 32px);
  --side: clamp(16px, 4vw, 56px);
  --max: 1440px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Onest", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.5;
  font-feature-settings: "ss01";
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
::selection { background: var(--red); color: #fff; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 var(--side); }
.grid { display: grid; grid-template-columns: repeat(12, 1fr); column-gap: var(--gutter); }

/* ---------- шапка ---------- */
.top { position: sticky; top: 0; z-index: 10; background: var(--paper); border-bottom: 1px solid var(--ink); }
.top .wrap { display: flex; align-items: center; gap: 28px; height: 60px; }
.logo { font-weight: 800; font-size: 21px; letter-spacing: -.04em; text-decoration: none; margin-right: auto; }
.logo sup { color: var(--red); font-size: .7em; margin-left: 1px; }
.nav { display: flex; gap: 24px; }
.nav a { text-decoration: none; font-size: 15px; }
.nav a:hover { color: var(--red); }

.tg {
  display: inline-block; background: var(--ink); color: var(--paper);
  text-decoration: none; font-weight: 600; font-size: 15px;
  padding: 10px 18px; border-radius: 999px; white-space: nowrap;
}
.tg:hover { background: var(--red); }
.tg--big { font-size: 19px; padding: 16px 28px; }

/* ---------- первый экран: видимая сетка ---------- */
.hero { position: relative; border-bottom: 1px solid var(--ink); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  max-width: var(--max); margin: 0 auto;
  background:
    linear-gradient(var(--grid) 1px, transparent 1px) 0 0 / 100% 48px;
}
.hero .cols {
  position: absolute; inset: 0; pointer-events: none;
}
.hero .cols .grid { height: 100%; }
.hero .cols span { border-left: 1px solid var(--grid); border-right: 1px solid var(--grid); }
.hero .wrap { position: relative; padding-top: clamp(40px, 6vw, 88px); padding-bottom: clamp(40px, 5vw, 72px); }
.hero h1 {
  grid-column: 1 / -1;
  margin: 0;
  font-weight: 800;
  font-size: clamp(42px, 8.1vw, 124px);
  line-height: .9;
  letter-spacing: -.055em;
}
.hero h1 .l { display: block; }
.hero h1 .l2 { padding-left: calc((100% + var(--gutter)) / 12 * 3); }
.hero h1 .l3 { padding-left: calc((100% + var(--gutter)) / 12 * 1); }
.hero h1 .l4 { padding-left: 0; }
.hero .lead { grid-column: 7 / span 6; margin-top: clamp(36px, 5vw, 64px); }
.hero .lead p { font-size: clamp(19px, 1.7vw, 24px); line-height: 1.35; margin: 0 0 28px; max-width: 30ch; }
.hero .note { display: block; margin-top: 12px; font-size: 14px; color: var(--muted); }

/* ---------- секции ---------- */
.sec { border-bottom: 1px solid var(--ink); padding: clamp(56px, 8vw, 112px) 0; }
.sec-head { grid-column: 1 / span 4; }
.sec-head h2 {
  margin: 0; font-weight: 800; font-size: clamp(34px, 4.4vw, 64px);
  line-height: .95; letter-spacing: -.045em;
}
.sec-head p { margin: 18px 0 0; color: var(--muted); max-width: 32ch; }
.sec-body { grid-column: 5 / -1; }

/* каталог-оглавление */
.toc { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.toc li { border-bottom: 1px solid var(--rule); padding: 26px 0 28px; display: grid; grid-template-columns: 1fr auto; column-gap: var(--gutter); }
.toc h3 { margin: 0; font-size: clamp(26px, 2.6vw, 38px); font-weight: 700; letter-spacing: -.035em; line-height: 1.05; }
.toc .price { font-size: clamp(18px, 1.6vw, 22px); font-weight: 600; white-space: nowrap; align-self: baseline; text-align: right; }
.toc .price.ask { color: var(--muted); font-weight: 400; }
.toc .what { grid-column: 1 / -1; margin: 8px 0 12px; font-size: 19px; max-width: 46ch; }
.toc ul { grid-column: 1 / -1; margin: 0; padding: 0; list-style: none; color: var(--muted); columns: 2; column-gap: var(--gutter); }
.toc ul li { display: block; border: 0; padding: 0 0 6px 18px; position: relative; break-inside: avoid; }
.toc ul li::before { content: "–"; position: absolute; left: 0; }

.auto { color: var(--red); font-weight: 700; text-decoration: none; }
.footnote { margin: 22px 0 0; font-size: 14px; color: var(--muted); }
.footnote .auto { margin-right: 4px; }

/* услуги-таблица */
.svc { width: 100%; border-collapse: collapse; border-top: 1px solid var(--ink); }
.svc th, .svc td { text-align: left; vertical-align: top; padding: 22px var(--gutter) 24px 0; border-bottom: 1px solid var(--rule); }
.svc thead th { font-size: 14px; font-weight: 400; color: var(--muted); padding-top: 14px; padding-bottom: 14px; }
.svc tbody th { font-size: clamp(22px, 2vw, 28px); font-weight: 700; letter-spacing: -.03em; line-height: 1.1; width: 30%; }
.svc td { font-size: 17px; }
.svc td:last-child { padding-right: 0; }
.aside { margin: 26px 0 0; font-size: 19px; max-width: 48ch; }

/* шаги */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); column-gap: var(--gutter); counter-reset: s; border-top: 1px solid var(--ink); }
.steps li { counter-increment: s; padding-top: 18px; }
.steps li::before { content: counter(s); display: block; font-size: 64px; font-weight: 800; letter-spacing: -.05em; line-height: 1; margin-bottom: 18px; color: var(--red); }
.steps b { display: block; font-size: 20px; letter-spacing: -.02em; margin-bottom: 6px; }
.steps span { color: var(--muted); }

/* кейсы — огромные цифры */
.cases { display: grid; grid-template-columns: repeat(2, 1fr); column-gap: var(--gutter); border-top: 1px solid var(--ink); }
.case { padding: 26px 0 40px; border-bottom: 1px solid var(--rule); }
.case:nth-child(odd) { padding-right: var(--gutter); border-right: 1px solid var(--rule); }
.case .num { display: block; font-weight: 800; font-size: clamp(64px, 8.4vw, 132px); line-height: .9; letter-spacing: -.06em; margin-bottom: 18px; }
.case .num small { font-size: .42em; letter-spacing: -.03em; margin-left: .08em; }
.case p { margin: 0; max-width: 40ch; }
.case p + p { color: var(--muted); margin-top: 8px; font-size: 15px; }

/* подход */
.rules { display: grid; grid-template-columns: repeat(2, 1fr); gap: 36px var(--gutter); }
.rules h3 { margin: 0 0 8px; font-size: 22px; letter-spacing: -.025em; }
.rules p { margin: 0; color: var(--muted); max-width: 40ch; }

/* блог-список */
.posts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.posts li { border-bottom: 1px solid var(--rule); }
.posts a { display: grid; grid-template-columns: 1fr auto; gap: 6px var(--gutter); padding: 22px 0; text-decoration: none; }
.posts a:hover h3 { color: var(--red); }
.posts h3 { margin: 0; font-size: clamp(22px, 2.2vw, 30px); letter-spacing: -.03em; line-height: 1.15; font-weight: 700; max-width: 30ch; }
.posts .meta { color: var(--muted); font-size: 15px; white-space: nowrap; }
.posts .ex { grid-column: 1 / -1; color: var(--muted); margin: 0; max-width: 60ch; }
.more { display: inline-block; margin-top: 24px; font-weight: 600; }

/* финал */
.final .wrap { padding-top: clamp(64px, 10vw, 140px); padding-bottom: clamp(64px, 10vw, 140px); }
.final h2 { grid-column: 1 / span 10; margin: 0; font-weight: 800; font-size: clamp(42px, 7.6vw, 116px); line-height: .92; letter-spacing: -.055em; }
.final p { grid-column: 1 / span 6; font-size: 21px; margin: 32px 0 32px; max-width: 34ch; }
.final .act { grid-column: 1 / -1; }

/* подвал */
.foot { padding: 28px 0 36px; font-size: 15px; }
.foot .wrap { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: baseline; }
.foot .logo { font-size: 17px; }
.foot span { color: var(--muted); margin-left: auto; }

/* ---------- статьи ---------- */
.page-head { border-bottom: 1px solid var(--ink); padding: clamp(48px, 7vw, 96px) 0 clamp(32px, 4vw, 56px); }
.page-head h1 { grid-column: 1 / span 10; margin: 0; font-weight: 800; font-size: clamp(40px, 6.4vw, 96px); line-height: .95; letter-spacing: -.05em; }
.page-head p { grid-column: 1 / span 6; margin: 22px 0 0; color: var(--muted); font-size: 19px; }

.article { padding: clamp(40px, 6vw, 80px) 0; }
.article .byline { grid-column: 1 / span 3; font-size: 15px; color: var(--muted); }
.article .byline b { display: block; color: var(--ink); font-size: 17px; }
.prose { grid-column: 4 / span 7; font-size: 19px; line-height: 1.6; }
.prose p { margin: 0 0 1.1em; max-width: 64ch; }
.prose h2 { font-size: 30px; letter-spacing: -.035em; line-height: 1.1; margin: 1.8em 0 .6em; }
.prose ul { padding-left: 1.1em; margin: 0 0 1.1em; }
.prose li { margin-bottom: .3em; }
.prose blockquote { margin: 1.4em 0; padding-left: 20px; border-left: 3px solid var(--red); font-size: 22px; line-height: 1.35; letter-spacing: -.015em; }
.author { grid-column: 4 / span 7; border-top: 1px solid var(--ink); margin-top: 40px; padding-top: 22px; display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: baseline; justify-content: space-between; }
.author p { margin: 0; max-width: 44ch; }

/* скрытые материалы */
.files { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.files li { display: grid; grid-template-columns: 1fr auto; gap: 4px var(--gutter); padding: 22px 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.files h3 { margin: 0; font-size: 24px; letter-spacing: -.03em; }
.files p { grid-column: 1; margin: 0; color: var(--muted); }
.files a { grid-row: 1 / span 2; grid-column: 2; font-weight: 600; }

/* ---------- адаптив ---------- */
@media (max-width: 960px) {
  .nav { display: none; }
  .sec-head, .sec-body { grid-column: 1 / -1; }
  .sec-head { margin-bottom: 36px; }
  .hero .lead { grid-column: 1 / span 11; }
  .hero h1 .l { padding-left: 0; }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .final h2, .final p { grid-column: 1 / -1; }
  .article .byline { grid-column: 1 / -1; margin-bottom: 28px; }
  .prose, .author { grid-column: 1 / -1; }
  .page-head h1, .page-head p { grid-column: 1 / -1; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .top .wrap { gap: 12px; }
  .tg { padding: 9px 14px; font-size: 14px; }
  .tg--big { font-size: 17px; padding: 14px 22px; }
  .hero .cols .grid span:nth-child(n+5) { display: none; }
  .hero .cols .grid { grid-template-columns: repeat(4, 1fr); }
  .toc ul { columns: 1; }
  .cases { grid-template-columns: 1fr; }
  .case:nth-child(odd) { border-right: 0; padding-right: 0; }
  .rules { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .svc thead { display: none; }
  .svc, .svc tbody, .svc tr, .svc th, .svc td { display: block; width: 100%; }
  .svc tr { border-bottom: 1px solid var(--rule); padding: 20px 0; }
  .svc th, .svc td { border: 0; padding: 0 0 8px; }
  .svc td::before { content: attr(data-l); display: block; font-size: 13px; color: var(--muted); }
  .posts a { grid-template-columns: 1fr; }
  .foot span { margin-left: 0; width: 100%; }
}
@media (prefers-reduced-motion: no-preference) {
  .hero h1 { animation: rise .9s cubic-bezier(.2, .7, .1, 1) both; }
  @keyframes rise { from { opacity: 0; transform: translateY(.18em); } }
}

/* вторая кнопка и блок обучения */
.acts { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.ghost {
  display: inline-block; text-decoration: none; font-weight: 600; font-size: 19px;
  padding: 15px 27px; border: 1px solid var(--ink); border-radius: 999px; white-space: nowrap;
}
.ghost:hover { border-color: var(--red); color: var(--red); }
.learn { display: grid; grid-template-columns: repeat(3, 1fr); column-gap: var(--gutter); border-top: 1px solid var(--ink); }
.learn > div { padding: 24px var(--gutter) 8px 0; }
.learn > div + div { border-left: 1px solid var(--rule); padding-left: var(--gutter); }
.learn h3 { margin: 0 0 4px; font-size: clamp(24px, 2.2vw, 30px); letter-spacing: -.035em; line-height: 1.1; }
.learn .fmt { display: block; color: var(--red); font-weight: 600; font-size: 15px; margin-bottom: 14px; }
.learn p { margin: 0 0 10px; color: var(--muted); }
.learn-cta { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; }
.learn-cta p { margin: 0; font-size: 19px; max-width: 40ch; }
@media (max-width: 640px) {
  .ghost { font-size: 17px; padding: 13px 21px; }
  .learn { grid-template-columns: 1fr; }
  .learn > div + div { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); }
}
.hero .cols .wrap { padding-top: 0; padding-bottom: 0; height: 100%; }
[id] { scroll-margin-top: 72px; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
.svc tbody th .auto, .toc h3 .auto { white-space: nowrap; }
.case:last-child:nth-child(odd) { grid-column: 1 / -1; border-right: 0; }
.foot .logo { margin-right: 12px; }
@media (max-width: 640px) {
  .steps { row-gap: 22px; }
  .steps li { display: grid; grid-template-columns: 52px 1fr; padding-top: 16px; }
  .steps li::before { font-size: 40px; margin: 0; grid-row: span 2; }
}

/* ---------- заголовки: Oswald, капс (как у 2W и в референсе) ---------- */
:root { --display: "Oswald", "Arial Narrow", sans-serif; }
.hero h1, .sec-head h2, .final h2, .page-head h1, .prose h2,
.toc h3, .svc tbody th, .learn h3, .case .num, .steps li::before {
  font-family: var(--display);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: -.005em;
}
.hero h1 { font-size: clamp(46px, 10.6vw, 170px); line-height: .9; }
.sec-head h2 { font-size: clamp(38px, 4.8vw, 72px); line-height: .95; }
.final h2 { font-size: clamp(46px, 8.4vw, 132px); line-height: .92; }
.page-head h1 { font-size: clamp(42px, 6.6vw, 104px); line-height: .95; }
.prose h2 { font-size: 34px; line-height: 1; }
.toc h3 { font-size: clamp(28px, 2.9vw, 44px); font-weight: 500; line-height: 1; }
.svc tbody th { font-size: clamp(24px, 2.2vw, 32px); font-weight: 500; line-height: 1; }
.learn h3 { font-size: clamp(26px, 2.4vw, 34px); font-weight: 500; line-height: 1; }
.case .num { font-size: clamp(80px, 10vw, 164px); line-height: .85; }
.case .num small { font-size: .4em; letter-spacing: 0; margin-left: .06em; }
.steps li::before { font-size: 72px; font-weight: 500; }
@media (max-width: 640px) { .steps li::before { font-size: 44px; } }
.hero h1 { font-size: clamp(40px, 7.9vw, 128px); }
.hero h1 .l2 { padding-left: calc((100% + var(--gutter)) / 12 * 2); }
.final h2 { grid-column: 1 / -1; font-size: clamp(42px, 7vw, 112px); }
@media (max-width: 960px) { .hero h1 .l { padding-left: 0; } }
@media (max-width: 640px) { .hero h1 { font-size: 46px; } }

/* ---------- цвета под логотип «маркетинговое» ---------- */
:root {
  --paper: #f8f7fc;
  --ink: #0b1023;
  --muted: #5d6072;
  --rule: #dcdbe8;
  --lav: #9e8df7;       /* заливка логотипа */
  --red: #5b47d9;       /* акцент для мелкого текста: тёмная лаванда, читается на светлом */
  --grid: rgba(158, 141, 247, .3);
}
::selection { background: var(--lav); color: var(--ink); }
.logo img { display: block; height: 26px; width: auto; }
.foot .logo img { height: 22px; }
.tg:hover { background: var(--lav); color: var(--ink); }
.ghost:hover { border-color: var(--ink); background: var(--lav); color: var(--ink); }
.nav a:hover, .posts a:hover h3 { color: var(--red); }
/* крупные цифры — как буквы логотипа: лавандовая заливка и тёмный контур */
.case .num, .steps li::before {
  color: var(--lav);
  -webkit-text-stroke: 2px var(--ink);
  paint-order: stroke fill;
}
.case .num small { -webkit-text-stroke-width: 1.5px; }
.prose blockquote { border-left-color: var(--lav); }
@media (max-width: 640px) { .logo img { height: 22px; } }

/* заголовки как логотип: лаванда + тёмный контур, одна буква чёрная */
.hero h1, .sec-head h2, .final h2, .page-head h1 {
  color: var(--lav);
  -webkit-text-stroke: .028em var(--ink);
  paint-order: stroke fill;
}
.sec-head h2, .page-head h1 { -webkit-text-stroke-width: .035em; }
.hero h1 .k, .sec-head h2 .k, .final h2 .k, .page-head h1 .k { color: var(--ink); }
.flow-title { margin: 44px 0 0; font-size: 15px; font-weight: 600; color: var(--muted); }
.flow { list-style: none; margin: 12px 0 0; padding: 0; counter-reset: f; display: grid; grid-template-columns: repeat(5, 1fr); column-gap: var(--gutter); border-top: 1px solid var(--ink); }
.flow li { counter-increment: f; padding-top: 14px; font-size: 16px; line-height: 1.4; }
.flow li::before { content: counter(f); display: block; font-family: var(--display); font-weight: 600; font-size: 34px; line-height: 1; margin-bottom: 10px; color: var(--lav); -webkit-text-stroke: 1.5px var(--ink); paint-order: stroke fill; }
@media (max-width: 960px) { .flow { grid-template-columns: repeat(2, 1fr); row-gap: 20px; } }
@media (max-width: 640px) {
  .flow { grid-template-columns: 1fr; row-gap: 14px; }
  .flow li { display: grid; grid-template-columns: 40px 1fr; align-items: baseline; }
  .flow li::before { font-size: 28px; margin: 0; }
}
.sec-head h2 { font-size: clamp(34px, 4.1vw, 60px); }

/* без обводки: лавандовая заливка, одна чёрная буква */
.hero h1, .sec-head h2, .final h2, .page-head h1,
.case .num, .case .num small, .steps li::before, .flow li::before {
  -webkit-text-stroke: 0;
  color: var(--lav-text);
}
:root { --lav-text: #8b78f3; } /* чуть плотнее лаванды логотипа, чтобы читалось на светлом фоне */

/* первый экран: подпись в скобках на уровне второй строки */
.hero h1 { --h1: clamp(40px, 7.9vw, 128px); font-size: var(--h1); }
.hero h1 .l2 { position: relative; }
.hero-note {
  position: absolute; left: 0; top: calc(var(--h1) * .14);
  width: calc((100% + var(--gutter)) / 12 * 2 - var(--gutter) * 1.5);
  font-family: "Onest", system-ui, sans-serif; font-size: clamp(15px, 1.25vw, 19px);
  font-weight: 400; line-height: 1.3; letter-spacing: 0; text-transform: none;
  color: var(--ink);
}
.final .act { margin-top: 40px; }
@media (max-width: 1200px) {
  .learn { grid-template-columns: 1fr; }
  .learn > div { padding-right: 0; }
  .learn > div + div { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); }
}
@media (max-width: 960px) {
  .hero-note { position: static; display: block; width: auto; max-width: 30ch; margin: .5em 0 .6em; font-size: 16px; }
}
@media (max-width: 640px) { .hero h1 { --h1: clamp(34px, 13.2vw, 52px); } }
@media (max-width: 960px) { .hero h1 .l2 { display: flex; flex-direction: column-reverse; } }
.hero h1 .l2 { padding-left: calc((100% + var(--gutter)) / 12 * 3); }
.hero-note {
  top: calc(var(--h1) * .1);
  width: calc((100% + var(--gutter)) / 12 * 3 - var(--gutter) * 1.5);
  font-size: clamp(16px, 1.4vw, 21px);
}
@media (max-width: 1200px) {
  .hero h1 .l2 { padding-left: 0; display: flex; flex-direction: column-reverse; }
  .hero-note { position: static; display: block; width: auto; max-width: 34ch; margin: .45em 0 .7em; }
}
.hero-note { font-size: clamp(17px, 1.7vw, 24px); line-height: 1.25; top: calc(var(--h1) * .125); }
@media (max-width: 1200px) { .hero-note { font-size: clamp(16px, 2.2vw, 20px); } }

/* скобка справа от «b2b-маркетинга», по верхней линии букв */
@media (min-width: 1201px) {
  .hero h1 .l2 {
    display: flex; align-items: flex-start; gap: var(--gutter);
    padding-left: calc((100% + var(--gutter)) / 12 * 1);
  }
  .hero h1 .l2 .k { order: 1; white-space: nowrap; }
  .hero-note {
    order: 2; position: static; width: auto; max-width: 15ch;
    margin-top: calc(var(--h1) * .125);
  }
}
@media (min-width: 1201px) { .hero-note { max-width: 21ch; } }

/* типографика: без висячих строк */
p, li, td, .what, .ex, .fmt, .hero-note { text-wrap: pretty; }
h1, h2, h3 { text-wrap: balance; }
.hero h1 { text-wrap: wrap; }
@media (max-width: 640px) { .hero h1 { --h1: clamp(30px, 11.6vw, 50px); } }
@media (max-width: 380px) {
  .top .wrap { gap: 8px; }
  .logo img { height: 18px; }
  .top .tg { padding: 8px 12px; font-size: 13px; }
}

/* финальные правки переносов */
@media (max-width: 1200px) { .hero h1 .l2 { flex-direction: column; } }
@media (max-width: 960px) {
  .hero h1 { --h1: calc((100vw - 2 * var(--side)) / 10.7); }
  .hero h1 .l { white-space: nowrap; }
  .hero h1 .hero-note { white-space: normal; }
}
@media (max-width: 640px) {
  .toc li { grid-template-columns: 1fr; }
  .toc .price { text-align: left; margin-top: 6px; }
}

/* широкие колонки вместо узких: без строк из одного слова */
.hero h1 { --h1: clamp(40px, 7.9vw, 122px); }
.steps { grid-template-columns: repeat(2, 1fr); row-gap: 28px; }
.steps li { display: grid; grid-template-columns: 64px 1fr; column-gap: 12px; }
.steps li::before { grid-row: span 2; font-size: 56px; margin: 0; }
.flow { grid-template-columns: repeat(2, 1fr); row-gap: 14px; }
.flow li { display: grid; grid-template-columns: 40px 1fr; align-items: baseline; }
.flow li::before { margin: 0; font-size: 30px; }
@media (min-width: 1201px) {
  .learn { grid-template-columns: 1fr; }
  .learn > div { display: grid; grid-template-columns: 5fr 7fr; column-gap: var(--gutter); padding: 22px 0; }
  .learn > div + div { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); }
  .learn h3, .learn .fmt { grid-column: 1; }
  .learn p { grid-column: 2; grid-row: 1 / span 2; margin: 0; }
}
@media (max-width: 1100px) {
  .svc thead { display: none; }
  .svc, .svc tbody, .svc tr, .svc th, .svc td { display: block; width: 100%; }
  .svc tr { border-bottom: 1px solid var(--rule); padding: 20px 0; }
  .svc th, .svc td { border: 0; padding: 0 0 8px; }
  .svc td::before { content: attr(data-l); display: block; font-size: 13px; color: var(--muted); }
}
@media (max-width: 640px) {
  .steps, .flow { grid-template-columns: 1fr; }
  .steps li { grid-template-columns: 48px 1fr; }
  .steps li::before { font-size: 40px; }
  .final h2 { font-size: clamp(32px, 10.5vw, 46px); }
  .page-head h1 { font-size: clamp(30px, 9.6vw, 44px); }
  .sec-head h2 { font-size: clamp(32px, 10vw, 44px); }
}
@media (max-width: 960px) { .hero h1 { --h1: calc((100vw - 2 * var(--side)) / 10.7); } }

/* страница «видео на поток» */
.page-acts { grid-column: 1 / -1; margin-top: 32px; }
.reels { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px var(--gutter); border-top: 1px solid var(--ink); padding-top: 24px; }
.reel { margin: 0; }
.reel video { display: block; width: 100%; aspect-ratio: 9 / 16; object-fit: cover; background: #e9e7f4; border-radius: 14px; }
.reel figcaption { margin-top: 10px; font-size: 15px; color: var(--muted); text-wrap: pretty; }
.toc-link { text-decoration: none; }
.toc-link:hover { color: var(--red); }
.toc h3 .toc-link::after { content: "↗"; font-family: "Onest", sans-serif; font-size: .5em; vertical-align: super; margin-left: .15em; color: var(--red); }
@media (max-width: 1200px) { .reels { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) { .reels { grid-template-columns: repeat(2, 1fr); gap: 20px 12px; } .reel figcaption { font-size: 14px; } }

/* ---------- стеклянное плавающее меню ---------- */
.top {
  position: fixed; top: 12px; left: 0; right: 0; z-index: 50;
  background: none; border: 0; padding: 0 var(--side); pointer-events: none;
}
.bar {
  pointer-events: auto; position: relative;
  max-width: calc(var(--max) - 2 * var(--side)); margin: 0 auto; height: 60px;
  display: flex; align-items: center; gap: 24px; padding: 0 10px 0 22px;
  border-radius: 999px;
  background: rgba(248, 247, 252, .55);
  -webkit-backdrop-filter: blur(18px) saturate(1.5); backdrop-filter: blur(18px) saturate(1.5);
  border: 1px solid rgba(11, 16, 35, .08);
  transition: background .2s;
}
.top.scrolled .bar { background: rgba(248, 247, 252, .72); }
.bar .logo { margin-right: auto; }
.bar .logo img { height: 24px; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav-link, .dd-btn {
  font: inherit; font-size: 15px; color: var(--ink); background: none; border: 0; cursor: pointer;
  text-decoration: none; padding: 8px 12px; border-radius: 999px;
}
.nav-link:hover, .dd-btn:hover, .dd.open .dd-btn { background: rgba(158, 141, 247, .22); color: var(--ink); }
.dd { position: relative; }
.dd-btn::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-3px) rotate(45deg); transition: transform .2s; }
.dd.open .dd-btn::after { transform: translateY(0) rotate(225deg); }
.dd-panel {
  display: none; position: absolute; top: calc(100% + 14px); left: -8px; min-width: 250px; padding: 8px;
  border-radius: 20px; background: rgba(248, 247, 252, .82);
  -webkit-backdrop-filter: blur(18px) saturate(1.5); backdrop-filter: blur(18px) saturate(1.5);
  border: 1px solid rgba(11, 16, 35, .08);
}
.dd-panel::before { content: ""; position: absolute; left: 0; right: 0; top: -16px; height: 16px; }
.dd-panel a { display: block; padding: 10px 14px; border-radius: 12px; text-decoration: none; font-size: 15px; white-space: nowrap; }
.dd-panel a:hover { background: rgba(158, 141, 247, .22); }
.dd.open .dd-panel { display: block; }
@media (hover: hover) and (min-width: 961px) { .dd:hover .dd-panel { display: block; } .dd:hover .dd-btn { background: rgba(158, 141, 247, .22); } }
.nav-tg, .burger { display: none; }
.burger { font: inherit; font-size: 15px; font-weight: 600; background: rgba(158, 141, 247, .25); border: 0; border-radius: 999px; padding: 10px 16px; cursor: pointer; color: var(--ink); }

/* под плавающее меню */
.hero .wrap { padding-top: calc(clamp(40px, 6vw, 88px) + 72px); }
.hero .cols .wrap { padding-top: 0; }
.page-head { padding-top: calc(clamp(48px, 7vw, 96px) + 72px); }
[id] { scroll-margin-top: 96px; }

@media (max-width: 960px) {
  .bar { gap: 10px; padding: 0 8px 0 18px; height: 56px; }
  .burger { display: block; }
  .nav {
    display: none; position: absolute; top: calc(100% + 8px); left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 2px; padding: 10px;
    border-radius: 24px; background: rgba(248, 247, 252, .9);
    -webkit-backdrop-filter: blur(18px) saturate(1.5); backdrop-filter: blur(18px) saturate(1.5);
    border: 1px solid rgba(11, 16, 35, .08);
    max-height: calc(100vh - 100px); overflow-y: auto;
  }
  .top.menu-open .nav { display: flex; }
  .nav-link, .dd-btn { display: block; width: 100%; text-align: left; font-size: 17px; padding: 12px 14px; border-radius: 14px; }
  .dd-panel { position: static; min-width: 0; padding: 0 0 6px 10px; background: none; border: 0; -webkit-backdrop-filter: none; backdrop-filter: none; border-radius: 0; }
  .dd-panel::before { display: none; }
  .dd-panel a { white-space: normal; font-size: 16px; color: var(--muted); }
  .nav-tg { display: block; text-align: center; margin-top: 8px; padding: 14px; font-size: 16px; }
}
@media (max-width: 520px) { .bar-tg { display: none; } }

/* ---------- скобка всегда сбоку от «b2b-маркетинга» ---------- */
.hero h1 .l2 { display: flex !important; flex-direction: row !important; align-items: flex-start; gap: var(--gutter); }
.hero h1 .l2 .k { order: 1; white-space: nowrap; }
.hero-note { order: 2; position: static !important; width: auto !important; margin: calc(var(--h1) * .125) 0 0 !important; }
@media (max-width: 1200px) { .hero h1 .l2 { padding-left: 0; } .hero-note { max-width: 24ch; } }
@media (max-width: 960px) { .hero-note { font-size: clamp(12px, 2.6vw, 18px) !important; max-width: none; flex: 1; min-width: 0; margin-top: calc(var(--h1) * .1) !important; } }
@media (max-width: 960px) { .hero-note { font-size: clamp(13px, 2vw, 16px) !important; } }
@media (max-width: 640px) {
  .hero h1 .l2 { flex-direction: column !important; gap: 0; }
  .hero-note { font-size: 16px !important; margin: .35em 0 .55em !important; max-width: 30ch; }
}
.reel figcaption { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (min-width: 1201px) { .hero-note { max-width: 27ch; } }
@media (min-width: 1700px) { .hero h1 .l2 { padding-left: 0; } }

/* ================= скругления вместо линий ================= */
:root { --card: #efedf9; --r: 24px; }
.hero, .sec, .top { border-bottom: 0; }
.sec { padding: clamp(40px, 6vw, 88px) 0; }
.toc, .svc, .steps, .cases, .posts, .files, .flow, .learn, .reels { border-top: 0; }
.toc > li { background: var(--card); border: 0; border-radius: var(--r); padding: 24px 28px 26px; margin-bottom: 12px; }
.toc ul li { background: none; border-radius: 0; padding: 0 0 6px 18px; margin: 0; }
.footnote { margin-top: 14px; }
.svc, .svc tbody { display: block; width: 100%; }
.svc thead { display: none; }
.svc tr { display: grid; grid-template-columns: 1.1fr 1fr 1fr; gap: 6px var(--gutter); background: var(--card); border-radius: var(--r); padding: 24px 28px; margin-bottom: 12px; border: 0; }
.svc th, .svc td { display: block; width: auto; border: 0; padding: 0; }
.svc td::before { content: attr(data-l); display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.cases { gap: 12px; }
.case, .case:nth-child(odd) { background: var(--card); border: 0; border-radius: var(--r); padding: 26px 28px 30px; }
.learn { gap: 12px; }
.learn > div, .learn > div + div { background: var(--card); border: 0 !important; border-radius: var(--r); padding: 24px 28px !important; }
.steps, .flow { gap: 12px; }
.steps li, .flow li { background: var(--card); border-radius: var(--r); padding: 20px 24px; }
.rules { gap: 12px; }
.rules > div { background: var(--card); border-radius: var(--r); padding: 24px 28px; }
.posts li, .files li { background: var(--card); border: 0; border-radius: var(--r); margin-bottom: 12px; }
.posts a { padding: 24px 28px; }
.files li { padding: 22px 28px; }
.author { border-top: 0; background: var(--card); border-radius: var(--r); padding: 24px 28px; }
.page-head { border-bottom: 0; }
.reels { padding-top: 0; }
.dd-panel { min-width: 320px; }
.dd-panel a b { display: block; font-weight: 600; font-size: 15px; white-space: normal; }
.dd-panel a small { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }
.dd-panel a { white-space: normal; }
@media (max-width: 960px) {
  .svc tr { grid-template-columns: 1fr; }
  .dd-panel a b { font-size: 16px; color: var(--ink); }
}
@media (max-width: 640px) {
  .toc > li, .svc tr, .case, .learn > div, .rules > div, .posts a, .files li, .author { padding: 20px 20px 22px !important; border-radius: 20px; }
  .steps li, .flow li { padding: 16px 18px; border-radius: 18px; }
}

/* ================= первый экран: телефонная раскладка ================= */
.hero h1 .mob { display: none; }
@media (max-width: 640px) {
  .hero h1 .dsk { display: none; }
  .hero h1 .mob { display: block; }
  .hero h1 { --h1: calc((100vw - 2 * var(--side)) / 7.6); }
  .hero h1 .mob .l { display: block; white-space: nowrap; padding: 0; }
  .hero h1 .mob .hero-note { display: block; font-size: 13px !important; margin: .2em 0 .35em !important; max-width: 34ch; position: static !important; }
  .hero .lead p { font-size: 17px; }
  .hero .lead { margin-top: 28px; }
  /* сетка на фоне реже и бледнее */
  .hero .cols .grid { grid-template-columns: repeat(2, 1fr); }
  .hero .cols .grid span:nth-child(n+3) { display: none; }
  .hero::before { background-size: 100% 96px; opacity: .6; }
  .hero .cols span { border-color: rgba(158, 141, 247, .18); }
  .tg--big, .ghost { font-size: 16px; padding: 13px 22px; }
}
@media (max-width: 960px) and (min-width: 641px) { .hero-note { font-size: clamp(12px, 1.6vw, 15px) !important; margin-top: calc(var(--h1) * .1) !important; } }
@media (min-width: 1600px) { .hero h1 .l2 { padding-left: 0; } }

.svc tbody th { width: auto; }

/* карточки: колонки пошире */
.svc tr { grid-template-columns: 1fr 1fr; }
.svc tbody th { grid-column: 1 / -1; margin-bottom: 8px; }
.steps li > *, .flow li > * { min-width: 0; }
@media (max-width: 1200px) { .toc ul { columns: 1; } }
@media (max-width: 1100px) { .rules { grid-template-columns: 1fr; } }
@media (max-width: 860px) { .steps, .flow { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .svc tr { grid-template-columns: 1fr; } }
.svc td + td { margin-top: 10px; } @media (min-width: 641px) { .svc td + td { margin-top: 0; } }
@media (max-width: 1100px) { .steps { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .toc h3 { font-size: clamp(19px, 6vw, 26px); white-space: nowrap; } }
@media (max-width: 960px) { .nav { background: rgba(248, 247, 252, .97); } }

/* ================= v2: плавные переходы ================= */
/* сетка первого экрана растворяется книзу */
.hero::before, .hero .cols {
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 100%);
          mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 100%);
}
/* и так же мягко проявляется в финальном блоке — страница начинается и заканчивается сеткой */
.final { position: relative; overflow: hidden; }
.final::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(var(--grid) 1px, transparent 1px) 0 0 / 100% 48px,
    linear-gradient(90deg, var(--grid) 1px, transparent 1px) 0 0 / calc(100% / 12) 100%;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 60%);
          mask-image: linear-gradient(to bottom, transparent 0%, #000 60%);
  opacity: .8;
}
.final .wrap { position: relative; }
@media (max-width: 640px) {
  .final::before { background-size: 100% 96px, 50% 100%; opacity: .6; }
}

/* ================= v2: больше воздуха на компьютере ================= */
@media (min-width: 961px) {
  body { line-height: 1.6; }
  .sec { padding: clamp(72px, 8.5vw, 132px) 0; }
  .sec-head p { margin-top: 22px; line-height: 1.55; }
  .hero .lead p { line-height: 1.45; margin-bottom: 34px; }
  .cases, .learn, .rules, .steps, .flow { gap: 16px; }
  .toc > li { padding: 32px 36px 34px; margin-bottom: 16px; }
  .toc .what { margin: 14px 0 18px; line-height: 1.45; }
  .toc .price { margin-top: 4px; }
  .toc ul li { padding-bottom: 10px; line-height: 1.5; }
  .footnote { margin-top: 20px; }
  .svc tr { padding: 30px 36px; row-gap: 10px; margin-bottom: 16px; }
  .svc tbody th { margin-bottom: 12px; }
  .svc td::before { margin-bottom: 6px; }
  .case, .case:nth-child(odd) { padding: 32px 36px 36px; }
  .case .num { margin-bottom: 24px; }
  .case p + p { margin-top: 12px; }
  .learn > div, .learn > div + div { padding: 30px 36px !important; }
  .learn .fmt { margin-bottom: 16px; }
  .learn p { line-height: 1.55; }
  .flow-title { margin-top: 56px; }
  .flow { margin-top: 16px; }
  .steps li, .flow li { padding: 26px 30px; }
  .steps b { margin-bottom: 8px; }
  .rules > div { padding: 30px 36px; }
  .rules h3 { margin-bottom: 12px; }
  .posts li { margin-bottom: 16px; }
  .posts a { padding: 30px 36px; row-gap: 10px; }
  .learn-cta { margin-top: 44px; }
  .final p, .final .act { margin-top: 44px; }
  .prose p { margin-bottom: 1.3em; }
  .reels { gap: 36px var(--gutter); }
  .reel figcaption { margin-top: 14px; }
}
@media (max-width: 1100px) { .flow { grid-template-columns: 1fr; } }

/* ================= v2: меню единым окном ================= */
.mm-btn {
  font: inherit; font-size: 15px; color: var(--ink); background: none; border: 0; cursor: pointer;
  padding: 8px 12px; border-radius: 999px;
}
.mm-btn::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-3px) rotate(45deg); transition: transform .2s; }
.mm-btn:hover, .mm-btn.on { background: rgba(158, 141, 247, .22); }
.mm-btn.on::after { transform: translateY(0) rotate(225deg); }
.mega {
  pointer-events: auto; display: none;
  max-width: calc(var(--max) - 2 * var(--side)); margin: 8px auto 0;
  background: #fbfaff; border: 1px solid rgba(11, 16, 35, .08); border-radius: 28px;
  padding: 28px; box-shadow: 0 24px 60px -28px rgba(11, 16, 35, .28);
}
.top.mega-open .mega { display: block; }
.mega-cols { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 12px 24px; }
.mcol { padding: 6px; border-radius: 20px; transition: background .15s; }
.mcol.on { background: var(--card); }
.mhead { margin: 6px 12px 10px; font-family: var(--display); text-transform: uppercase; font-weight: 600; font-size: 20px; color: var(--lav-text); letter-spacing: 0; }
.mcol a { display: block; padding: 11px 12px; border-radius: 14px; text-decoration: none; }
.mcol a:hover { background: rgba(158, 141, 247, .22); }
.mcol a b { display: block; font-weight: 600; font-size: 16px; line-height: 1.3; }
.mcol a small { display: block; font-size: 14px; color: var(--muted); margin-top: 3px; }
.mega-foot { display: none; }
@media (max-width: 960px) {
  .nav { display: none !important; }
  .mega { position: absolute; left: var(--side); right: var(--side); top: calc(100% + 0px); margin-top: 8px; padding: 14px; max-height: calc(100vh - 96px); overflow-y: auto; border-radius: 24px; }
  .mega-cols { grid-template-columns: 1fr; gap: 4px; }
  .mcol { padding: 4px 0; }
  .mcol.on { background: none; }
  .mhead { margin: 12px 12px 4px; font-size: 18px; }
  .mega-foot { display: flex; flex-wrap: wrap; gap: 6px; padding: 12px 12px 4px; border-top: 0; }
  .mega-foot a { text-decoration: none; padding: 10px 14px; border-radius: 999px; background: var(--card); font-size: 16px; }
  .mega-foot a.tg { background: var(--ink); color: var(--paper); flex: 1 0 100%; text-align: center; margin-top: 6px; }
}
@media (min-width: 961px) {
  .mcol a b, .mcol a small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}
@media (min-width: 961px) and (max-width: 1150px) { .mega { padding: 20px; } .mega-cols { gap: 8px 12px; } .mcol a { padding: 10px; } .mcol a b { font-size: 15px; } .mcol a small { font-size: 13px; } }
@media (max-width: 400px) { .mcol a small { font-size: 13px; } }

.hero .lead p.cost { font-size: clamp(15px, 1.15vw, 17px); color: var(--muted); margin: -18px 0 30px; max-width: 34ch; }
@media (max-width: 640px) { .hero .lead p.cost { font-size: 15px; margin: -14px 0 24px; } }
@media (max-width: 345px) { .hero .lead p { font-size: 15px; } .hero .lead p.cost { font-size: 14px; } }
