/* ============================================================
   base.css — общие стили обеих страниц (лендинг и политика).
   Подключается ПЕРЕД инлайн <style> каждой страницы, чтобы
   постраничные правила могли перебивать общие каскадом.
   Пути к ассетам — относительно этого файла (assets/css/).
   ============================================================ */

/* ============ Шрифты (self-hosted, кириллица + латиница) ============ */
@font-face {
  font-family: "Russo One"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/russo-one-v18-cyrillic_latin-regular.woff2") format("woff2");
}
@font-face {
  font-family: "Golos Text"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/golos-text-v7-cyrillic_latin-regular.woff2") format("woff2");
}
@font-face {
  font-family: "Golos Text"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/golos-text-v7-cyrillic_latin-500.woff2") format("woff2");
}
@font-face {
  font-family: "Golos Text"; font-style: normal; font-weight: 600; font-display: swap;
  src: url("../fonts/golos-text-v7-cyrillic_latin-600.woff2") format("woff2");
}

/* ============ Токены ============ */
:root {
  --bg: #f6f1e6;            /* песочно-белый: тепло и чистота */
  --bg-deep: #ece4d2;       /* песок тоном ниже */
  --band: #e7dfc9;          /* глубокий песок: полоса фактов, подложка фото */
  --band-line: #c9bea1;     /* разделители на глубоком песке */
  --ink: #1d1a15;           /* тёплый почти-чёрный */
  --ink-soft: #4a443a;
  --ink-mute: #67604f;
  --line: #d6ccb5;          /* песочный hairline */
  --graphite: #211d18;      /* тёплый уголь: секции «Дожиг», «Оффер» и карточка патента */
  --graphite-line: #3a332a;
  --on-graphite: #f3ecdd;
  --on-graphite-soft: #c2b8a4;
  --accent: #c1281f;        /* сигнальный красный с ручек печи */
  --accent-down: #a02019;
  --on-accent: #f6f2f1;     /* светлый текст/глиф поверх акцентного красного */
  --display: "Russo One", "Arial Black", sans-serif;
  --body: "Golos Text", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  /* шкала скруглений: s — кнопки и поля, m — плашки и карточки, l — фото и крупные контейнеры */
  --r-s: 8px;
  --r-m: 12px;
  --r-l: 18px;
  --header-h: 64px;         /* высота липкой шапки: база для мобильного меню и hero-calc */
  /* z-scale: 10 — шапка, 60 — зерно поверх всего. Других слоёв нет. */
  /* motion: сильный ease-out для входа/reveal (первый экран без анимаций) */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --dur-reveal: 0.55s;
  /* единый фото-фильтр: приглушённый тёплый тон карточек и постеров */
  --photo-filter: saturate(0.96) contrast(1.03) sepia(0.06);
  /* глиф пламени для буллетов героя: заливка через mask → цвет = --accent */
  --flame: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M8 16c3.314 0 6-2 6-5.5 0-1.5-.5-4-2.5-6 .25 1.5-1.25 2-1.25 2C11 4 9 .5 6 0c.357 2 .5 4-2 6-1.25 1-2 2.729-2 4.5C2 14 4.686 16 8 16Zm0-1c-1.657 0-3-1-3-2.75 0-.75.25-2 1.25-3C6.125 10 7 10.5 7 10.5c-.375-1.25.5-3.25 2-3.5-.179 1-.25 2 1 3 .625.5 1 1.364 1 2.25C11 14 9.657 15 8 15Z'/%3E%3C/svg%3E");
}

* { margin: 0; padding: 0; box-sizing: border-box; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

html, body { overflow-x: clip; }

body {
  font-family: var(--body);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

/* зерно по всей странице: только fixed + pointer-events none (не перерисовывается при скролле) */
body::after {
  content: "";
  position: fixed; inset: 0; z-index: 60;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
  opacity: 0.11;
  mix-blend-mode: multiply;
}

.wrap { max-width: 1240px; margin-inline: auto; padding-inline: 20px; }
@media (min-width: 768px) { .wrap { padding-inline: 48px; } }

a { color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ============ Заголовки: общая типографика (размеры и интерлиньяж — постранично) ============ */
h1, h2, h3 {
  font-family: var(--display);
  font-weight: 400;
  text-transform: uppercase;
  text-wrap: balance;
}

/* ============ Шапка (контейнер и вордмарк — общее) ============ */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: var(--header-h);
}
.wordmark {
  font-family: var(--display);
  font-weight: 400; font-size: 1.02rem;
  text-transform: uppercase; letter-spacing: 0.03em;
  text-decoration: none;
}

/* ============================================================
   Подвал — общий для обеих страниц (графитовая полоса-фундамент).
   Одна строка во всю ширину: реквизиты и копирайт слева,
   кредит разработчика и «наверх» справа. На мобилке — переносится.
   ============================================================ */
.site-footer {
  background: var(--graphite);
  color: var(--on-graphite);
}
.site-footer .wrap { padding-block: 28px; }

.footer-bottom {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: 12px 28px;
}
.footer-bottom p { max-width: none; font-size: 0.86rem; color: var(--on-graphite-soft); }
.footer-legal { margin-right: auto; }               /* толкает правую группу к краю */
/* кредит и «наверх» — единый блок справа, выровнены между собой по центру */
.footer-end { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 8px 22px; }
.site-footer .policy-link {
  color: var(--on-graphite-soft);
  text-decoration: underline; text-underline-offset: 3px;
}
.site-footer .policy-link:hover { color: var(--on-graphite); }
.site-footer a.up { font-size: 0.86rem; color: var(--on-graphite-soft); text-decoration: none; }
.site-footer a.up:hover { color: var(--on-graphite); }
/* кредит разработчика: логотип-знак в фирменном оранжевом, текст в тоне подвала */
.site-footer .credit-link {
  display: inline-flex; align-items: center; gap: 6px;
  vertical-align: middle;
  color: var(--on-graphite-soft);
  text-decoration: underline; text-underline-offset: 3px;
  white-space: nowrap;
}
.site-footer .credit-link:hover { color: var(--on-graphite); }
.site-footer .credit-logo { width: 16px; height: 16px; flex-shrink: 0; }
