/*
  gss-site.css - оболочка сайта студии (GSS-167).

  Тема по решению Igor 14.11.2026: чёрный фон, неоновый зелёный, волны.
  Цвета сняты с макета Igor (gss-site-docs/gss-site-mockup-new.png, замер
  14.11.2026): фон #001912, неон кнопки #6DE738. Подвал - тёмно-зелёный.

  Шрифты - свободные (OFL), файлами с нашего сайта (assets/fonts/), без
  Google: Newsreader в заголовках, Inter в тексте (выбор Igor 14.11.2026,
  23:06, после двух проб).

  Все страницы берут шапку, меню, подвал, кнопки отсюда; шапка и подвал -
  одинаковый HTML в каждой странице, одинаковость ловит tools/check-shell.js.
*/

/* ---------- Шрифты ----------
   Выбор Igor 14.11.2026, 23:06 (вторая проба): Newsreader + Inter.
   Newsreader - экранный шрифт с засечками и переменной оптической высотой
   (opsz 6-72): малый заголовок берёт текстовое начертание, крупный -
   заголовочное. Вес закреплён на 560 при урезании (файл 132 -> 61 КБ,
   tools: fontTools varLib.instancer), поэтому font-weight у заголовков
   не меняется. Первая проба (DM Serif Display, Playfair) отклонена: буквы
   в заголовках слипались. */
@font-face { font-family: "Newsreader"; src: url("fonts/newsreader.woff2") format("woff2"); font-weight: 560; font-style: normal; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("fonts/newsreader-italic.woff2") format("woff2"); font-weight: 560; font-style: italic; font-display: swap; }
@font-face { font-family: "Inter"; src: url("fonts/inter-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("fonts/inter-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }

/* ---------- Цвета и размеры ----------
   МАСШТАБ ПО ОКНУ. Все размеры оболочки - в rem; базовый кегль растёт с
   окном: 16 точек до 1280, около 21 на 2560 (монитор 27"). Без этого на 27"
   страница выходила мелким островком (снимок 2560 первой пробы). Поле
   страницы на 27" - около 10% с каждой стороны, как в лобби приложений
   линейки по числам Igor (`HubLayout`, 24.09.2026). */
html { font-size: clamp(16px, calc(10.67px + 0.4167vw), 22px); }

:root {
  --bg: #001912;
  --bg-raise: #052418;
  --neon: #6DE738;
  --neon-soft: rgba(109, 231, 56, 0.35);
  --snow: #CFE3EE;
  --text: #EEF3EF;
  --muted: #A8B9AF;
  --line: rgba(109, 231, 56, 0.22);
  --footer: #08321F;

  --font-head: "Newsreader", Georgia, serif;
  --font-text: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --head-weight: 560;
  --small-weight: 560;
  /* Разрядка не отрицательная: буквы не сжимаются (ответ Igor 22:58, п. 2). */
  --head-track: .005em;

  /* Поля: телефон 16 точек, дальше 5% окна; ширина блока - до 96rem
     (на 2560 это около 2050 точек, поля около 10%). */
  --pad: max(16px, 5vw);
  --max: 96rem;
  /* Воздух между блоками - больше макетного (решение Igor 14.11.2026). */
  /* Компактнее, чем в первой раскладке (Igor 23:32, п. 3; 00:08, п. 4). */
  --block-gap: clamp(2.5rem, 4.5vw, 4.5rem);
}

/* ---------- Основа ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-text);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--neon); }
/* Оптическая высота - по кеглю (font-optical-sizing: auto): малый заголовок
   берёт текстовое начертание Newsreader, крупный - заголовочное. */
h1, h2, h3 { font-family: var(--font-head); font-weight: var(--head-weight); letter-spacing: var(--head-track);
             line-height: 1.12; margin: 0; font-optical-sizing: auto; }
h3 { font-weight: var(--small-weight); line-height: 1.25; }
.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--pad)); margin: 0 auto; padding: 0 var(--pad); }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Шапка ----------
   ЗАКРЕПЛЕНА (Igor 14.11.2026, 23:32): при прокрутке остаётся вверху. Вверху
   страницы прозрачна - на главной под ней панорама; после прокрутки
   получает фон, чтобы меню читалось поверх содержимого (класс .scrolled
   ставит gss-site.js). Линии под шапкой нет.
   Высота шапки - --header-h: на неё сдвинуто содержимое страниц, кроме
   главной, где первый экран начинается под прозрачной шапкой. */
:root { --header-h: calc(clamp(1rem, 1.8vw, 2rem) + 2.9rem + .75rem); }
body { padding-top: var(--header-h); }
body.home { padding-top: 0; }
header.site {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  transition: background-color .25s ease, box-shadow .25s ease, -webkit-backdrop-filter .25s ease, backdrop-filter .25s ease;
}
header.site.scrolled {
  background: rgba(0, 25, 18, .94);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 var(--line), 0 8px 24px rgba(0, 0, 0, .35);
}
header.site .bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; padding-top: clamp(1rem, 1.8vw, 2rem); padding-bottom: .75rem;
}
/* Логотип - 800×188 точек: чёткий на Retina до высоты 94 точки. На 27"
   логотип и меню не теряются рядом с заголовком (Igor 23:32, п. 8): логотип
   2,9rem (около 62 точек на 2560), меню - кегль 1rem. */
header.site .logo { display: block; line-height: 0; }
header.site .logo img { height: 2.9rem; width: auto; }
header.site nav { display: flex; gap: 2.2rem; }
header.site nav a {
  color: var(--text); text-decoration: none; font-size: 1rem;
  padding: .375rem 0; border-bottom: 2px solid transparent;
  transition: color .2s ease, border-color .2s ease;
}
header.site nav a:hover { color: var(--neon); }
/* Вверху главной меню лежит поверх светлых гор панорамы - лёгкая тень
   держит буквы читаемыми; на фоне прокрученной шапки она не нужна. */
header.site:not(.scrolled) nav a { text-shadow: 0 1px 6px rgba(0, 20, 14, .85); }
header.site nav a[aria-current="page"] { color: var(--neon); border-bottom-color: var(--neon); }

header.site .burger {
  display: none; width: 44px; height: 44px; align-items: center; justify-content: center;
  flex-direction: column; gap: 5px; background: none; border: 0; padding: 0; cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
header.site .burger span {
  display: block; width: 24px; height: 2px; background: var(--text); border-radius: 2px;
  transition: transform .2s ease, opacity .2s ease, background .2s ease;
}
header.site .burger.open span { background: var(--neon); }
header.site .burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
header.site .burger.open span:nth-child(2) { opacity: 0; }
header.site .burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Телефон: меню за бургером, створкой под шапкой. */
@media (max-width: 760px) {
  :root { --header-h: calc(1rem + 2.25rem + .75rem); }
  header.site .logo img { height: 2.25rem; }
  header.site .bar { position: relative; }
  header.site .burger { display: flex; }
  header.site nav {
    display: none; position: absolute; top: calc(100% + 4px); right: 0; min-width: 220px;
    flex-direction: column; gap: 0; padding: 6px 0;
    background: var(--bg-raise); border: 1px solid var(--line); border-radius: 12px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, .45);
  }
  header.site nav.open { display: flex; }
  header.site nav a { padding: 12px 20px; border-bottom: 0; font-size: 16px; }
  header.site nav a[aria-current="page"] { border-bottom: 0; }
}

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6rem; min-height: 3rem;
  padding: 0 1.5rem; border-radius: 999px; font: 600 1rem/1 var(--font-text);
  text-decoration: none; cursor: pointer; transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn:active { transform: scale(.97); }
.btn-neon { background: var(--neon); color: #052010; box-shadow: 0 0 1.5rem var(--neon-soft); }
.btn-neon:hover { box-shadow: 0 0 2.25rem var(--neon-soft); }
.btn-line { background: transparent; color: var(--text); border: 1.5px solid var(--neon); }
.btn-line:hover { background: rgba(109, 231, 56, .08); }
.btn svg { width: 1.25rem; height: 1.25rem; flex: none; }

.eyebrow {
  font: 600 .75rem/1.4 var(--font-text); letter-spacing: .22em; text-transform: uppercase; color: var(--muted);
}
.eyebrow.neon { color: var(--neon); }

/* ---------- Подвал, тёмно-зелёный ---------- */
footer.site { background: var(--footer); margin-top: var(--block-gap); }
footer.site .cols {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start;
  gap: 1.5rem 3rem; padding-top: 2.25rem; padding-bottom: 2.25rem; font-size: .875rem;
}
footer.site nav { display: flex; flex-wrap: wrap; gap: .6rem 1.75rem; }
footer.site a { color: var(--text); text-decoration: none; }
footer.site a:hover { color: var(--neon); }
footer.site .legal { display: flex; flex-wrap: wrap; gap: .6rem 1.75rem; color: var(--muted); }
footer.site .legal a { color: var(--muted); }

/* ---------- Полоса «Have an idea?» ----------
   Последний блок главной и страниц Apps, Web & Services, About (шаг 4):
   общая, поэтому в оболочке. */
/* Как на макете (Igor 00:08): фон - вертикальный переход макета (#00361F
   вверху, #001910 внизу), по краям - волны, вырезанные из макета
   (home-idea-left/right.webp, внутренний край гаснет в прозрачность; правая
   вырезана правее кнопки макета - Igor 00:28, п. 1).
   Волны во всю высоту полосы, ширина - по их пропорции. */
.idea { position: relative; overflow: hidden; margin-top: var(--block-gap); border-top: 1px solid var(--line);
        background: linear-gradient(to bottom, #00361f, #001910); }
.idea::before, .idea::after { content: ""; position: absolute; top: 0; bottom: 0; height: 100%; pointer-events: none;
                              background-repeat: no-repeat; background-size: 100% 100%; }
.idea::before { left: 0; aspect-ratio: 215 / 109; background-image: url("img/home-idea-left.webp"); }
.idea::after { right: 0; aspect-ratio: 213 / 109; background-image: url("img/home-idea-right.webp"); }
/* Текст и кнопка - между волнами, как на макете: поля полосы не уже волн
   (высота полосы около 6rem: левая волна около 12rem шириной, правая -
   около 11,7rem). Замер 15.11.2026: при полях страницы волны ложились на
   заголовок и на кнопку. */
.idea .wrap { position: relative; z-index: 1; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2.5rem;
              padding-top: 1.5rem; padding-bottom: 1.5rem;
              padding-left: max(var(--pad), 12.5rem); padding-right: max(var(--pad), 12.5rem); }
.idea h2 { font-size: clamp(1.7rem, 2.3vw, 2.3rem); }
.idea p { margin: 0; font-size: 1rem; flex: 1 1 18rem; }
/* Полоса - последним блоком, подвал сразу под ней. */
main:has(> .idea:last-child) + footer.site { margin-top: 0; }
/* До 1100: полосе между волнами тесно, строки переносятся и полоса растёт -
   волны только в нижних углах, высотой 4rem, приглушённые; поля - обычные. */
@media (max-width: 1100px) {
  .idea::before, .idea::after { top: auto; height: 3.5rem; opacity: .7; }
  /* Нижнее поле - высотой с волну: волны под текстом, а не на нём. */
  .idea .wrap { padding-left: var(--pad); padding-right: var(--pad); padding-bottom: 3.75rem; }
}
