/* ==========================================================================
   seo-paul.ru — дизайн-система

   Основа — стиль Cursor из библиотеки Refero Styles
   («тёплый пергамент, освещённый углями»):

     • холст — тёплый пергамент, а не чистый белый;
     • заголовки НИКОГДА не жирные: вес 400 и тем плотнее трекинг,
       чем крупнее кегль — авторитет берётся сдержанностью, а не насыщенностью;
     • острые углы 4px вместо скруглений;
     • поверхности плоские, глубина — от волосяных рамок 1px;
     • акцент тратится скупо: янтарь на действиях, искра на акцентах.

   Палитра адаптирована: сохранён тёплый золотистый акцент,
   ради которого сайт и делался.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Токены
   -------------------------------------------------------------------------- */
:root {
  /* Поверхности */
  --canvas:        #f7f7f4;   /* холст страницы */
  --surface:       #ffffff;   /* приподнятая поверхность */
  --surface-alt:   #f2f1ed;   /* карточки, блоки */
  --surface-deep:  #e9e8e3;   /* вложенные блоки */
  --surface-ink:   #26251e;   /* тёмные секции */

  /* Линии */
  --line:          #cdcdc9;   /* волосяная рамка */
  --line-soft:     #e2e1dc;
  --line-ink:      #3a382f;

  /* Текст */
  --ink:           #26251e;   /* тёплый почти-чёрный, никогда не #000 */
  --ink-2:         #44403b;
  --text:          #4a4841;
  --muted:         #84847e;
  --dim:           #a1a19f;
  --on-ink:        #f2f1ed;

  /* Акценты */
  --amber:         #c08532;   /* действие: кнопки, ссылки */
  --amber-deep:    #9c6821;
  --amber-bright:  #d9a441;
  --amber-tint:    #f4ead7;
  --ember:         #d9531e;   /* редкая искра */
  --forest:        #34785c;
  --crimson:       #b03a2e;

  /* Типографика */
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-serif: 'EB Garamond', Iowan Old Style, Palatino, Georgia, serif;
  --font-mono: ui-monospace, SFMono-Regular, 'SF Mono', Menlo, Consolas, monospace;

  /* Геометрия */
  --r: 4px;
  --r-sm: 3px;
  --container: 1200px;
  --gutter: 24px;

  /* Ритм */
  --sp-1: 4px;  --sp-2: 8px;  --sp-3: 12px; --sp-4: 16px;
  --sp-5: 24px; --sp-6: 32px; --sp-7: 48px; --sp-8: 64px; --sp-9: 96px;

  /* Тени — почти незаметные, тёплые */
  --shadow-1: 0 1px 2px rgba(38, 37, 30, .04);
  --shadow-2: 0 2px 8px rgba(38, 37, 30, .06);
  --shadow-3: 0 12px 32px rgba(38, 37, 30, .10);

  /* Движение */
  --ease: cubic-bezier(.2, .7, .3, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --t-fast: .16s var(--ease);
  --t: .28s var(--ease);
  --t-slow: .6s var(--ease-out);
}

/* --------------------------------------------------------------------------
   2. Сброс
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 96px;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--canvas);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'kern' 1, 'liga' 1, 'calt' 1;
}

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

a { color: var(--amber-deep); text-decoration: none; transition: color var(--t-fast); }
a:hover { color: var(--amber-bright); }

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }

ul, ol { margin: 0 0 1em; padding-left: 1.25em; }

hr { border: 0; border-top: 1px solid var(--line); margin: var(--sp-7) 0; }

::selection { background: var(--amber-tint); color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--amber);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

.visually-hidden {
  position: absolute !important;
  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: -9999px;
  top: 0;
  z-index: 1000;
  padding: 12px 20px;
  background: var(--ink);
  color: var(--on-ink);
  font-size: 14px;
  border-radius: 0 0 var(--r) 0;
}
.skip-link:focus { left: 0; color: var(--on-ink); }

/* --------------------------------------------------------------------------
   3. Типографика — подпись системы

   Заголовки в весе 400. Жирность не используется: крупный кегль
   компенсируется отрицательным трекингом, который растёт вместе с размером.
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 var(--sp-4);
  color: var(--ink);
  font-weight: 400;
  line-height: 1.2;
  text-transform: none;
}

h1, .display {
  font-size: clamp(34px, 5.2vw, 64px);
  line-height: 1.06;
  letter-spacing: -.032em;
}

h2 {
  font-size: clamp(26px, 3.4vw, 40px);
  line-height: 1.14;
  letter-spacing: -.026em;
}

h3 {
  font-size: clamp(20px, 2vw, 26px);
  line-height: 1.25;
  letter-spacing: -.014em;
}

h4 {
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.3;
  letter-spacing: -.006em;
  font-weight: 500;
}

h5, h6 {
  font-size: 16px;
  line-height: 1.4;
  letter-spacing: 0;
  font-weight: 500;
}

p { margin: 0 0 var(--sp-4); }

strong, b { font-weight: 600; color: var(--ink); }

/* Надзаголовок: мелкая прописная метка с разрядкой */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  margin: 0 0 var(--sp-4);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow::before {
  content: "";
  width: 18px;
  height: 1px;
  background: var(--amber);
}

.lede {
  max-width: 60ch;
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.55;
  color: var(--ink-2);
}

/* --------------------------------------------------------------------------
   4. Сетка и секции
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section { padding: clamp(48px, 7vw, 96px) 0; }
.section--tight { padding: clamp(32px, 4vw, 56px) 0; }
.section--alt { background: var(--surface-alt); border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); }
.section--ink { background: var(--surface-ink); color: var(--on-ink); }
.section--ink h1, .section--ink h2, .section--ink h3, .section--ink h4 { color: var(--on-ink); }
.section--ink .lede { color: #c9c7bd; }
.section--ink a { color: var(--amber-bright); }

.section__head { max-width: 68ch; margin: 0 0 clamp(28px, 4vw, 48px); }

/* --------------------------------------------------------------------------
   5. Шапка
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background var(--t), border-color var(--t), backdrop-filter var(--t);
}

/* При прокрутке шапка «проявляется»: фон, размытие и волосяная линия */
.site-header.is-scrolled {
  background: rgba(247, 247, 244, .82);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
          backdrop-filter: saturate(180%) blur(14px);
  border-bottom-color: var(--line);
}
.site-header.is-over-ink.is-scrolled {
  background: rgba(38, 37, 30, .82);
  border-bottom-color: var(--line-ink);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  min-height: 76px;
}

.site-header__logo { flex: 0 0 auto; }
.site-header__logo a { display: block; }
.site-header__logo img { width: 176px; height: auto; transition: transform var(--t); }
.site-header__logo a:hover img { transform: translateY(-1px); }

/* --- Меню --- */
.main-nav { margin-left: auto; }

.main-nav ul {
  display: flex;
  align-items: center;
  gap: var(--sp-5);
  margin: 0;
  padding: 0;
  list-style: none;
}

.main-nav a {
  position: relative;
  display: block;
  padding: 6px 0;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
  letter-spacing: -.005em;
  transition: color var(--t-fast);
}

/* Подчёркивание растёт слева при наведении — вместо простой смены цвета */
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--t);
}
.main-nav a:hover::after,
.main-nav .is-active > a::after { transform: scaleX(1); }
.main-nav a:hover { color: var(--ink); }
.main-nav .is-active > a { color: var(--ink); }

.main-nav .has-children > a::before {
  content: "";
  display: inline-block;
  margin-left: 6px;
  vertical-align: 2px;
  border: 4px solid transparent;
  border-top-color: currentColor;
  opacity: .45;
}

.main-nav .submenu {
  position: absolute;
  top: calc(100% + 10px);
  left: -14px;
  z-index: 30;
  min-width: 240px;
  padding: var(--sp-2) 0;
  margin: 0;
  list-style: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--shadow-3);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity var(--t), transform var(--t), visibility var(--t);
}
.main-nav .has-children:hover .submenu,
.main-nav .has-children:focus-within .submenu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.main-nav .submenu a { padding: 9px 18px; font-size: 15px; }
.main-nav .submenu a::after { display: none; }
.main-nav .submenu a:hover { background: var(--surface-alt); color: var(--ink); }

/* --- Правый блок --- */
.site-header__contacts {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  margin-left: auto;
}

.site-header__phone {
  margin: 0;
  font-size: 16px;
  font-weight: 500;
  letter-spacing: -.01em;
  color: var(--ink);
  white-space: nowrap;
}
.site-header__phone a { color: var(--ink); }
.site-header__phone a:hover { color: var(--amber-deep); }

.site-header__social { display: flex; gap: 6px; }

.social-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border: 1px solid transparent;
  border-radius: var(--r);
  transition: background var(--t), border-color var(--t), transform var(--t);
}
.social-icon svg { width: 19px; height: 19px; fill: var(--ink-2); transition: fill var(--t-fast); }
.social-icon:hover {
  background: var(--surface-alt);
  border-color: var(--line);
  transform: translateY(-2px);
}
.social-icon:hover svg { fill: var(--amber-deep); }

.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 9px 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
}
.nav-toggle__bars { position: relative; display: block; width: 16px; height: 1px; background: currentColor; }
.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: ""; position: absolute; left: 0; width: 16px; height: 1px; background: currentColor;
  transition: transform var(--t);
}
.nav-toggle__bars::before { top: -5px; }
.nav-toggle__bars::after { top: 5px; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-5px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   6. Кнопки
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: 48px;
  padding: 13px 26px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -.005em;
  text-align: center;
  color: #fff;
  background: var(--amber);
  border: 1px solid var(--amber);
  border-radius: var(--r);
  transition: background var(--t), border-color var(--t), transform var(--t), box-shadow var(--t);
}
.btn:hover {
  background: var(--amber-deep);
  border-color: var(--amber-deep);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(192, 133, 50, .28);
}
.btn:active { transform: translateY(0); box-shadow: none; }

.btn--ghost { color: var(--ink); background: transparent; border-color: var(--line); }
.btn--ghost:hover { background: var(--surface); border-color: var(--ink); color: var(--ink); box-shadow: var(--shadow-2); }

.btn--ink { background: var(--ink); border-color: var(--ink); }
.btn--ink:hover { background: #3a382f; border-color: #3a382f; box-shadow: 0 6px 18px rgba(38,37,30,.22); }

.btn__arrow { transition: transform var(--t); }
.btn:hover .btn__arrow { transform: translateX(4px); }

/* --------------------------------------------------------------------------
   7. Хлебные крошки
   -------------------------------------------------------------------------- */
.breadcrumbs { padding: var(--sp-4) 0 0; font-size: 13px; color: var(--dim); }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin: 0; padding: 0; list-style: none; }
.breadcrumbs li + li::before { content: "/"; margin-right: var(--sp-2); color: var(--line); }
.breadcrumbs a { color: var(--muted); }
.breadcrumbs a:hover { color: var(--amber-deep); }
.breadcrumbs [aria-current="page"] { color: var(--ink-2); }

/* --------------------------------------------------------------------------
   8. Герой
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  padding: clamp(56px, 8vw, 112px) 0 clamp(48px, 6vw, 88px);
  overflow: hidden;
}

/* Тёплое свечение за заголовком: даёт глубину без картинок */
.hero::before {
  content: "";
  position: absolute;
  top: -30%;
  right: -10%;
  width: 720px;
  height: 720px;
  background: radial-gradient(circle, rgba(192, 133, 50, .16) 0%, rgba(217, 164, 65, .06) 42%, transparent 70%);
  pointer-events: none;
}
/* Мелкая сетка на фоне — отсылка к «бумаге в клетку» */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(38, 37, 30, .035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(38, 37, 30, .035) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 90% 60% at 50% 30%, #000 20%, transparent 78%);
          mask-image: radial-gradient(ellipse 90% 60% at 50% 30%, #000 20%, transparent 78%);
  pointer-events: none;
}

.hero > .container { position: relative; z-index: 1; }
.hero h1 { max-width: 20ch; margin-bottom: var(--sp-5); }
.hero .lede { max-width: 54ch; margin-bottom: var(--sp-6); }

.hero__actions { display: flex; flex-wrap: wrap; gap: var(--sp-3); margin-bottom: var(--sp-7); }

.hero__facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3) var(--sp-5);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
  color: var(--muted);
}
.hero__facts li { display: flex; align-items: center; gap: var(--sp-2); }
.hero__facts li::before { content: ""; width: 5px; height: 5px; background: var(--amber); border-radius: 50%; }

/* --------------------------------------------------------------------------
   9. Показатели со счётчиками
   -------------------------------------------------------------------------- */
.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
}

.stat { padding: var(--sp-6) var(--sp-5); background: var(--canvas); transition: background var(--t); }
.stat:hover { background: var(--surface); }

.stat__value {
  display: block;
  margin: 0 0 var(--sp-2);
  font-size: clamp(30px, 3.6vw, 44px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -.03em;
  color: var(--ink);
  /* Цифры одной ширины: счётчик не «дёргает» вёрстку при анимации */
  font-variant-numeric: tabular-nums;
  font-feature-settings: 'tnum' 1;
}
.stat__value .stat__suffix { font-size: .55em; color: var(--muted); margin-left: 2px; }
.stat__label { font-size: 14px; line-height: 1.45; color: var(--muted); }

/* --------------------------------------------------------------------------
   10. Карточки
   -------------------------------------------------------------------------- */
.grid { display: grid; gap: var(--sp-5); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(272px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: var(--sp-6);
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: border-color var(--t), background var(--t), transform var(--t), box-shadow var(--t);
}
.card:hover {
  background: var(--surface);
  border-color: var(--ink);
  transform: translateY(-4px);
  box-shadow: var(--shadow-3);
}

.card h3 { margin-bottom: var(--sp-3); }

.card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin-bottom: var(--sp-4);
  background: var(--amber-tint);
  border-radius: var(--r-sm);
  transition: background var(--t), transform var(--t);
}
.card__icon svg { width: 20px; height: 20px; fill: var(--amber-deep); transition: fill var(--t); }
.card:hover .card__icon { background: var(--amber); transform: rotate(-4deg) scale(1.06); }
.card:hover .card__icon svg { fill: #fff; }

.card__link { margin-top: auto; padding-top: var(--sp-4); font-size: 15px; font-weight: 500; color: var(--amber-deep); }
.card__link::after { content: "→"; display: inline-block; margin-left: 6px; transition: transform var(--t); }
.card:hover .card__link::after { transform: translateX(5px); }

.chips { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin: 0; padding: 0; list-style: none; }
.chips li {
  padding: 9px 16px;
  font-size: 15px;
  color: var(--ink-2);
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: border-color var(--t), background var(--t), color var(--t);
}
.chips li:hover { border-color: var(--amber); background: var(--amber-tint); color: var(--ink); }

/* --------------------------------------------------------------------------
   11. Таблицы тарифов
   -------------------------------------------------------------------------- */
.prices { margin: var(--sp-6) 0 0; }
.prices__scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--r); }

.prices table {
  width: 100%;
  min-width: 700px;
  border-collapse: collapse;
  background: var(--canvas);
  font-size: 15px;
}

.prices th, .prices td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--line-soft);
  text-align: center;
  vertical-align: middle;
}
.prices thead th {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--surface-alt);
  border-bottom-color: var(--line);
}
.prices tbody th { font-weight: 400; text-align: left; font-size: 15px; color: var(--ink-2); }
.prices tbody tr { transition: background var(--t-fast); }
.prices tbody tr:hover { background: var(--surface-alt); }
.prices tbody tr:last-child th,
.prices tbody tr:last-child td { border-bottom: 0; }

.prices__group th {
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--amber-deep);
  text-align: left;
  background: var(--amber-tint);
  border-bottom: 1px solid var(--line);
}
.prices table caption { text-align: left; }
.prices tfoot th { text-align: left; text-transform: none; font-weight: 400; }
.prices__total th,
.prices__total td {
  font-size: 18px;
  font-weight: 600;
  color: var(--ink);
  background: var(--surface-alt);
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.mark-yes::before, .mark-no::before { display: block; font-size: 17px; line-height: 1; }
.mark-yes::before { content: "\2713"; color: var(--amber); }
.mark-no::before  { content: "\2014"; color: var(--line); }

/* --------------------------------------------------------------------------
   12. Цитата
   -------------------------------------------------------------------------- */
.quote { padding: clamp(40px, 5vw, 72px) 0; }
.quote blockquote {
  max-width: 46ch;
  margin: 0 auto;
  padding: 0;
  font-family: var(--font-serif);
  font-size: clamp(21px, 2.4vw, 30px);
  font-style: italic;
  line-height: 1.4;
  letter-spacing: -.01em;
  color: var(--ink);
  text-align: center;
  border: 0;
}
.quote blockquote::before {
  content: "";
  display: block;
  width: 32px;
  height: 1px;
  margin: 0 auto var(--sp-5);
  background: var(--amber);
}
.quote p:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------------------
   13. Контент страниц и статей
   -------------------------------------------------------------------------- */
.content { padding: clamp(24px, 3vw, 40px) 0 clamp(40px, 5vw, 64px); }
.content h2 { margin-top: 1.6em; }
.content h3 { margin-top: 1.3em; }
.content h2:first-child, .content h3:first-child { margin-top: 0; }
.content p, .content li { font-size: 17px; line-height: 1.65; }
.content > p, .content > ul, .content > ol, .content > blockquote, .content > h2, .content > h3, .content > h4 { max-width: 74ch; }

.content ul, .content ol { padding-left: 1.4em; }
.content li { margin-bottom: .45em; }
.content li::marker { color: var(--amber); }

.content img { margin: var(--sp-6) 0; border: 1px solid var(--line); border-radius: var(--r); }
.content figure { margin: var(--sp-6) 0; }
.content figcaption { margin-top: var(--sp-3); font-size: 14px; color: var(--muted); text-align: center; }

.content blockquote {
  margin: var(--sp-6) 0;
  padding: var(--sp-5) var(--sp-6);
  font-family: var(--font-serif);
  font-size: 19px;
  font-style: italic;
  color: var(--ink-2);
  background: var(--surface-alt);
  border-left: 2px solid var(--amber);
  border-radius: 0 var(--r) var(--r) 0;
}
.content blockquote p { font-size: inherit; }

.content table { width: 100%; margin: var(--sp-6) 0; border: 1px solid var(--line); border-collapse: collapse; font-size: 15px; }
.content table th, .content table td { padding: 11px 14px; border-bottom: 1px solid var(--line-soft); text-align: left; }
.content table th {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--surface-alt);
}

.article-meta { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-5); margin: 0 0 var(--sp-6); font-size: 14px; color: var(--muted); }
.article-meta a { color: var(--muted); }
.article-meta a:hover { color: var(--amber-deep); }

.related {
  max-width: 74ch;
  margin: var(--sp-7) 0 0;
  padding: var(--sp-6);
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: var(--r);
}
.related h2 { font-size: 20px; margin-bottom: var(--sp-4); }
.related ul { margin: 0; padding-left: 1.2em; }
.related li { margin-bottom: var(--sp-2); }

/* --------------------------------------------------------------------------
   14. Список статей
   -------------------------------------------------------------------------- */
.post-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
}

.post-card { display: flex; flex-direction: column; padding: var(--sp-6); background: var(--canvas); transition: background var(--t); }
.post-card:hover { background: var(--surface); }

.post-card h3 { margin: 0 0 var(--sp-3); font-size: 19px; line-height: 1.3; letter-spacing: -.01em; }
.post-card h3 a { color: var(--ink); }
.post-card h3 a:hover { color: var(--amber-deep); }

.post-card time, .post-card__meta {
  display: block;
  margin: 0 0 var(--sp-3);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--dim);
}
.post-card p { margin: 0 0 var(--sp-4); font-size: 15px; color: var(--muted); }
.post-card__more { margin-top: auto; font-size: 14px; font-weight: 500; color: var(--amber-deep); }
.post-card__more::after { content: "→"; display: inline-block; margin-left: 5px; transition: transform var(--t); }
.post-card:hover .post-card__more::after { transform: translateX(5px); }

/* --------------------------------------------------------------------------
   15. Подвал
   -------------------------------------------------------------------------- */
.site-footer {
  margin-top: clamp(48px, 6vw, 88px);
  padding: clamp(40px, 5vw, 64px) 0 var(--sp-6);
  background: var(--surface-ink);
  color: #b6b4aa;
}
.site-footer h2, .site-footer h3 { color: var(--on-ink); }
.site-footer a { color: #d9d7cd; }
.site-footer a:hover { color: var(--amber-bright); }

.site-footer__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: var(--sp-6); }
/* Светлая версия логотипа подключается файлом logo-light.png,
   поэтому фильтр не нужен: он убивал бы янтарный акцент. */
.site-footer__logo { width: 176px; margin-bottom: var(--sp-4); opacity: .92; }
.site-footer p { margin: 0 0 var(--sp-2); font-size: 15px; }
.site-footer .small { font-size: 13px; color: #8b897f; }

.site-footer__social { display: flex; gap: 6px; margin-bottom: var(--sp-4); }
.site-footer .social-icon { border-color: var(--line-ink); }
.site-footer .social-icon svg { fill: #b6b4aa; }
.site-footer .social-icon:hover { background: #33322a; border-color: #4a4840; }
.site-footer .social-icon:hover svg { fill: var(--amber-bright); }

.site-footer__legal { margin: var(--sp-6) 0 0; padding-top: var(--sp-5); border-top: 1px solid var(--line-ink); font-size: 13px; }
.site-footer__legal .cookie-btn--link { padding: 0; font-size: 13px; color: #d9d7cd; vertical-align: baseline; }
.site-footer__legal .cookie-btn--link:hover { color: var(--amber-bright); }

/* --------------------------------------------------------------------------
   16. Форма и модальное окно
   -------------------------------------------------------------------------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-4);
  background: rgba(38, 37, 30, .58);
  -webkit-backdrop-filter: blur(3px);
          backdrop-filter: blur(3px);
  animation: fade-in .22s var(--ease-out);
}
.modal[hidden] { display: none; }

.modal__dialog {
  width: 100%;
  max-width: 520px;
  max-height: 92vh;
  overflow-y: auto;
  padding: clamp(24px, 3vw, 36px);
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--r);
  box-shadow: var(--shadow-3);
  animation: rise-in .3s var(--ease-out);
}

.modal__close {
  float: right;
  width: 40px;
  height: 40px;
  margin: -6px -6px 0 0;
  font-size: 22px;
  line-height: 1;
  color: var(--muted);
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--r);
  transition: background var(--t), color var(--t), border-color var(--t);
}
.modal__close:hover { color: var(--ink); background: var(--surface-alt); border-color: var(--line); }

.field { margin-bottom: var(--sp-4); }
.field label { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 500; color: var(--ink); }

.field input, .field select, .field textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  font-size: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.field textarea { min-height: 96px; resize: vertical; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--dim); }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(192, 133, 50, .15);
  outline: none;
}

.field__hint { margin: 5px 0 0; font-size: 13px; color: var(--muted); }
.req { color: var(--crimson); }

.consent { display: flex; align-items: flex-start; gap: 11px; margin: var(--sp-5) 0; font-size: 14px; line-height: 1.5; }
.consent input[type="checkbox"] { flex: 0 0 auto; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--amber-deep); }
.consent label { margin: 0; font-size: 14px; font-weight: 400; color: var(--text); }
.consent a { text-decoration: underline; text-underline-offset: 2px; }

.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

.form-status { margin-top: var(--sp-4); font-size: 14px; }
.form-status--error { color: var(--crimson); }
.form-status--ok { color: var(--forest); }
.form-footer { margin-top: var(--sp-4); font-size: 13px; line-height: 1.5; color: var(--muted); }

.btn-callback {
  min-height: 44px;
  padding: 11px 20px;
  font-size: 14px;
  font-weight: 500;
  color: #fff;
  background: var(--amber);
  border: 1px solid var(--amber);
  border-radius: var(--r);
  transition: background var(--t), transform var(--t), box-shadow var(--t);
}
.btn-callback:hover {
  background: var(--amber-deep);
  border-color: var(--amber-deep);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(192, 133, 50, .28);
}

/* --------------------------------------------------------------------------
   17. Плашка cookie
   -------------------------------------------------------------------------- */
.cookie-banner {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 300;
  padding: var(--sp-4) 0;
  background: var(--canvas);
  border-top: 1px solid var(--line);
  box-shadow: 0 -8px 32px rgba(38, 37, 30, .10);
  animation: slide-up .32s var(--ease-out);
}
.cookie-banner[hidden] { display: none; }

.cookie-banner__inner { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-3) var(--sp-5); }
.cookie-banner__text { flex: 1 1 420px; margin: 0; font-size: 13px; line-height: 1.55; color: var(--muted); }
.cookie-banner__text strong { color: var(--ink); }
.cookie-banner__actions { display: flex; flex-wrap: wrap; gap: var(--sp-2); }

.cookie-btn {
  min-height: 42px;
  padding: 10px 18px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: background var(--t), border-color var(--t), color var(--t);
}
.cookie-btn:hover { background: var(--surface-alt); border-color: var(--dim); }
.cookie-btn--accept { color: #fff; background: var(--amber); border-color: var(--amber); }
.cookie-btn--accept:hover { background: var(--amber-deep); border-color: var(--amber-deep); color: #fff; }
.cookie-btn--link { border: 0; background: none; text-decoration: underline; padding: 10px 0; }

.cookie-banner__options { flex: 1 1 100%; margin-top: var(--sp-2); }
.cookie-option { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 var(--sp-2); font-size: 13px; line-height: 1.45; color: var(--muted); }
.cookie-option input { flex: 0 0 auto; width: 17px; height: 17px; margin: 2px 0 0; accent-color: var(--amber-deep); }

/* --------------------------------------------------------------------------
   18. Калькулятор воронки
   -------------------------------------------------------------------------- */
.calc { margin: var(--sp-6) 0; }
.calc__row { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: var(--sp-4); margin-bottom: var(--sp-4); }
.calc__field { min-width: 0; }
.calc__field label { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 500; color: var(--ink); }
.calc__field input, .calc__field select {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.calc__field input:focus { border-color: var(--amber); box-shadow: 0 0 0 3px rgba(192,133,50,.15); outline: none; }
.calc__field--action { display: flex; align-items: flex-end; }

.calc__result {
  margin-top: var(--sp-5);
  padding: var(--sp-6);
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: var(--r);
}
.calc__result h2 { font-size: 20px; margin-bottom: var(--sp-4); }
.calc__result dl { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: var(--sp-5); margin: 0; }
.calc__result dt { margin-bottom: 6px; font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.calc__result dd {
  margin: 0;
  font-size: clamp(22px, 2.4vw, 30px);
  font-weight: 400;
  letter-spacing: -.02em;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.calc__note {
  margin: var(--sp-5) 0 0;
  padding: var(--sp-4) var(--sp-5);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-2);
  background: var(--canvas);
  border-left: 2px solid var(--amber);
  border-radius: 0 var(--r) var(--r) 0;
}

/* --------------------------------------------------------------------------
   19. Анимации

   Прогрессивное улучшение: содержимое видно всегда. Состояние «скрыто до
   появления» включается только при наличии класса .js на <html>, который
   ставит скрипт. Если JS не сработал — страница просто статична, а не пуста.
   Это важно и для поисковых роботов.
   -------------------------------------------------------------------------- */

@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes rise-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes slide-up { from { opacity: 0; transform: translateY(100%); } to { opacity: 1; transform: none; } }

.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--ease-out), transform .7s var(--ease-out);
  transition-delay: var(--reveal-delay, 0s);
  will-change: opacity, transform;
}
.js .reveal.is-visible { opacity: 1; transform: none; will-change: auto; }

.js .stagger > * {
  opacity: 0;
  transform: translateY(18px);
  animation: rise-in .8s var(--ease-out) forwards;
}
.js .stagger > *:nth-child(1) { animation-delay: .05s; }
.js .stagger > *:nth-child(2) { animation-delay: .16s; }
.js .stagger > *:nth-child(3) { animation-delay: .27s; }
.js .stagger > *:nth-child(4) { animation-delay: .38s; }
.js .stagger > *:nth-child(5) { animation-delay: .49s; }
.js .stagger > *:nth-child(6) { animation-delay: .60s; }

/* --------------------------------------------------------------------------
   20. Утилиты
   -------------------------------------------------------------------------- */
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.nowrap { white-space: nowrap; }
.muted { color: var(--muted); }
.stack > * + * { margin-top: var(--sp-4); }

/* --------------------------------------------------------------------------
   21. Адаптивность
   -------------------------------------------------------------------------- */
@media (max-width: 1080px) {
  .site-header__logo img { width: 156px; }
  .main-nav ul { gap: var(--sp-4); }
  .main-nav a { font-size: 14px; }
}

@media (max-width: 920px) {
  :root { --gutter: 20px; }

  /* Без переноса строк шапка не помещается на телефоне и даёт
     горизонтальную прокрутку. Раскладка в две строки:
     логотип + кнопка меню, ниже — телефон и кнопка звонка. */
  .site-header__inner { flex-wrap: wrap; min-height: 0; padding-top: 12px; padding-bottom: 12px; }

  .site-header__logo { order: 1; }
  .nav-toggle { display: inline-flex; order: 2; margin-left: auto; }

  .main-nav { order: 4; flex: 1 0 100%; max-height: 0; overflow: hidden; transition: max-height .35s var(--ease); }
  .main-nav.is-open { max-height: 620px; }
  .main-nav ul { flex-direction: column; align-items: stretch; gap: 0; padding: var(--sp-2) 0 var(--sp-4); }
  .main-nav a { padding: 14px 2px; font-size: 16px; border-bottom: 1px solid var(--line-soft); }
  .main-nav a::after { display: none; }
  .main-nav .has-children > a::before { float: right; margin-top: 7px; }
  .main-nav .submenu {
    position: static;
    opacity: 1; visibility: visible; transform: none;
    box-shadow: none; border: 0; border-radius: 0;
    padding: 0 0 0 var(--sp-4);
    min-width: 0;
  }
  .main-nav .submenu a { border-bottom: 0; padding: 10px 2px; font-size: 15px; color: var(--muted); }

  /* Контакты уходят на отдельную строку целиком */
  .site-header__contacts {
    order: 3;
    flex: 1 0 100%;
    margin-left: 0;
    justify-content: space-between;
    gap: var(--sp-3);
  }
  .site-header__social { display: none; }
  .site-header__phone { white-space: normal; }

  .hero__actions { flex-direction: column; align-items: stretch; }
  .hero__actions .btn { width: 100%; }
}

@media (max-width: 640px) {
  :root { --gutter: 16px; }

  body { font-size: 15px; }
  .content p, .content li { font-size: 16px; }

  .site-header__logo img { width: 132px; }
  .site-header__phone { font-size: 15px; }
  .btn-callback { padding: 10px 14px; font-size: 13px; }

  .site-footer__grid { grid-template-columns: 1fr; }
  .cookie-banner__inner { flex-direction: column; align-items: stretch; }
  .cookie-banner__actions { justify-content: stretch; }
  .cookie-btn { flex: 1 1 auto; }

  .stats { grid-template-columns: 1fr; }
  .calc__result dl { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 420px) {
  .site-header__contacts { width: 100%; justify-content: space-between; }
  .calc__result dl { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   22. Печать и предпочтения пользователя
   -------------------------------------------------------------------------- */
@media print {
  .site-header, .nav-toggle, .cookie-banner, .modal, .site-footer__social, .btn, .btn-callback { display: none !important; }
  body { font-size: 12pt; color: #000; background: #fff; }
  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 90%; color: #555; }
  .js .reveal, .js .stagger > * { opacity: 1 !important; transform: none !important; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .js .reveal { opacity: 1; transform: none; }
  .js .stagger > * { opacity: 1; transform: none; }
  .card:hover, .btn:hover, .social-icon:hover { transform: none; }
}
