/* ==========================================================================
   База: сброс, типографика, контейнеры, доступность
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-padding-top: calc(var(--header-h) + 24px);
  scrollbar-color: var(--c-green) var(--s-stone);
  scrollbar-width: thin;
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
html.has-smooth { scroll-behavior: auto; }

body {
  margin: 0;
  font-family: var(--f-sans);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--c-ink);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  font-feature-settings: "kern", "liga", "tnum" 0;
}
@supports (overflow: clip) { body { overflow-x: clip; } }

/* Кастомная нативная полоса (дублируется JS-полосой на десктопе) */
::-webkit-scrollbar { width: 12px; height: 10px; }
::-webkit-scrollbar-track { background: var(--s-stone); }
::-webkit-scrollbar-thumb { background: linear-gradient(var(--c-green), var(--c-blue)); border-radius: 10px; border: 3px solid var(--s-stone); }
::-webkit-scrollbar-thumb:hover { background: var(--c-green-ink); }
::selection { background: var(--s-mint-2); color: var(--c-ink); }

img, svg, video, canvas { display: block; max-width: 100%; }
img { height: auto; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--c-blue); text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--c-blue-ink); text-decoration-thickness: 2px; }

h1, h2, h3, h4 { margin: 0; line-height: var(--lh-head); font-weight: 700; letter-spacing: -0.025em; text-wrap: balance; }
h1 { font-size: var(--fs-h1); line-height: var(--lh-tight); letter-spacing: -0.04em; font-weight: 800; }
h2 { font-size: var(--fs-h2); letter-spacing: -0.035em; font-weight: 800; }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-h4); letter-spacing: -0.015em; }
p { margin: 0 0 1em; text-wrap: pretty; }
p:last-child { margin-bottom: 0; }
ul, ol { margin: 0; padding: 0; }
strong, b { font-weight: 700; }
small { font-size: var(--fs-small); }
table { border-collapse: collapse; }

:focus-visible { outline: 3px solid var(--c-blue); outline-offset: 3px; border-radius: 6px; }

.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: fixed; left: 16px; top: -100px; z-index: 1000; padding: 12px 20px;
  background: var(--c-ink); color: #fff; border-radius: var(--r-sm); text-decoration: none;
}
.skip-link:focus { top: 16px; color: #fff; }

/* Контейнеры */
.wrap { width: 100%; max-width: var(--w-max); margin-inline: auto; padding-inline: var(--gutter); }
.wrap--wide { max-width: 1680px; }
.text { max-width: var(--w-text); }
.text > * + * { margin-top: 1em; }

/* Общие текстовые элементы */
.kicker {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--f-mono); font-size: 14px; font-weight: 500;
  letter-spacing: .12em; text-transform: uppercase; color: var(--c-ink-2);
}
.kicker::before { content: ''; width: 10px; height: 10px; border-radius: 50%; background: currentColor; opacity: .85; flex: 0 0 10px; }
.kicker--green { color: var(--c-green); }
.kicker--blue { color: var(--c-blue); }
.kicker--soil { color: var(--c-soil); }
.kicker--light { color: #d4e6f7; }
.lead { font-size: var(--fs-lead); line-height: 1.45; color: var(--c-ink-2); max-width: 60ch; }
.muted { color: var(--c-ink-3); }
.mono { font-family: var(--f-mono); }
.num { font-variant-numeric: tabular-nums; }
.nowrap { white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
