/* Основа: ресет, типография, контейнер, бутони. Само var(--...) от tokens.css. */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
section[id], aside[id] { scroll-margin-top: var(--hd-h); }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font-text); font-size: var(--fs-1); line-height: var(--lh-text); font-weight: var(--w-text); -webkit-font-smoothing: antialiased; overflow-x: clip; }
img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--font-display); font-weight: var(--w-display); letter-spacing: var(--track-display); line-height: var(--lh-display); margin: 0; text-wrap: balance; }
h1 { font-size: var(--fs-4); }
h2 { font-size: var(--fs-3); }
h3 { font-size: var(--fs-2); letter-spacing: -0.02em; line-height: 1.15; }
p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
p { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--sun); outline-offset: 3px; }
::selection { background: var(--sun); color: var(--on-sun); }
:root { accent-color: var(--sun); }
input, textarea, select { caret-color: var(--sun); }

:root { --pad-l: max(var(--gutter), env(safe-area-inset-left)); --pad-r: max(var(--gutter), env(safe-area-inset-right)); }
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad-l) var(--pad-r); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Бутон: 52px, глагол в текста, на един ред */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: 3.25rem; padding: 0 1.6rem; border: 1px solid transparent; border-radius: var(--radius-btn); font: inherit; font-weight: 600; line-height: 1.1; text-decoration: none; white-space: nowrap; cursor: pointer; }
.btn svg { flex: none; }
.btn--sun { background: var(--sun); color: var(--on-sun); }
.btn--night { background: var(--night); color: var(--on-night); }
.btn--line { background: transparent; color: var(--on-night); border-color: var(--line-on-night-strong); }
.btn:active { transform: scale(0.97); }
@media (hover: hover) {
  .btn--sun:hover { background: var(--sun-press); }
  .btn--night:hover { background: var(--night-2); }
  .btn--line:hover { border-color: var(--on-night); }
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
  .btn { transition: transform var(--dur-fast) var(--ease), background-color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease); }
}

a, button, input, select, textarea, label { touch-action: manipulation; }
