/* Reynard. Токены и основа. Значения из брендбука (разделы 06–10, 15). */

:root {
  --fox: #F05A1A;
  --fox-ink: #B3420E;
  --fox-soft: #FDE6DA;
  --on-fox: #15120F;

  --ink: #15120F;
  --ink-muted: #6B635B;
  --bg: #F4F1ED;
  --raised: #FFFFFF;
  --sunken: #EDE9E4;
  --line: #E1DBD4;
  --line-strong: #8C837A;
  --track: #DCD6CF;

  --success: #1B7553;
  --danger: #C0244A;
  --info: #2A5BCC;
  --success-soft: #DCEFE6;
  --info-soft: #E2EAFA;
  --on-success: #FFFFFF;

  --inverse: #15120F;
  --on-inverse: #FFFFFF;
  --glass: rgba(255, 255, 255, .58);
  --glass-line: rgba(255, 255, 255, .8);
  --scrim: rgba(21, 18, 15, .34);

  --shadow-sm: 0 1px 2px rgba(21, 18, 15, .04), 0 8px 24px -10px rgba(21, 18, 15, .10);
  --shadow-md: 0 2px 6px rgba(21, 18, 15, .05), 0 24px 48px -16px rgba(21, 18, 15, .22);
  --shadow-warm: 0 12px 32px -10px rgba(240, 90, 26, .38);

  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 18px;
  --r-xl: 24px;
  --r-2xl: 32px;
  --r-full: 999px;

  --ease: cubic-bezier(.22, .61, .36, 1);
  --t-fast: 200ms;
  --t-panel: 300ms;

  --font: 'Manrope', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-brand: 'Unbounded', 'Manrope', sans-serif;

  --page-x: 32px;
  --gap: 20px;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --fox-ink: #FF7D45;
  --fox-soft: #3B1E10;
  --on-fox: #15120F;

  --ink: #F4F1ED;
  --ink-muted: #A9A097;
  --bg: #15120F;
  --raised: #1F1B18;
  --sunken: #0D0B09;
  --line: #342E28;
  --line-strong: #776E64;
  --track: #3A332C;

  --success: #4CC38A;
  --danger: #FF6E8C;
  --info: #82A8FF;
  --success-soft: #133325;
  --info-soft: #1A2642;
  --on-success: #15120F;

  --inverse: #F4F1ED;
  --on-inverse: #15120F;
  --glass: rgba(31, 27, 24, .62);
  --glass-line: rgba(255, 255, 255, .12);
  --scrim: rgba(0, 0, 0, .55);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px -10px rgba(0, 0, 0, .5);
  --shadow-md: 0 2px 6px rgba(0, 0, 0, .3), 0 24px 48px -16px rgba(0, 0, 0, .7);
  --shadow-warm: 0 12px 32px -10px rgba(240, 90, 26, .45);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 24px;
  font-weight: 400;
  font-feature-settings: 'tnum' 1;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color var(--t-panel) var(--ease), color var(--t-panel) var(--ease);
}

h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
input, textarea, select { font: inherit; color: inherit; }
img, svg { display: block; }
table { border-collapse: separate; border-spacing: 0; }
::selection { background: var(--fox-soft); color: var(--ink); }

:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

/* Шкала текста. Крупное лёгкое, мелкое плотнее. */
.t-display { font-size: 64px; line-height: 68px; font-weight: 300; letter-spacing: -.035em; }
.t-headline { font-size: 44px; line-height: 50px; font-weight: 300; letter-spacing: -.03em; }
.t-metric { font-size: 56px; line-height: 60px; font-weight: 300; letter-spacing: -.035em; }
.t-title { font-size: 28px; line-height: 34px; font-weight: 400; letter-spacing: -.015em; }
.t-subtitle { font-size: 20px; line-height: 28px; font-weight: 500; letter-spacing: -.01em; }
.t-body { font-size: 16px; line-height: 24px; font-weight: 400; }
.t-label { font-size: 14px; line-height: 20px; font-weight: 600; }
.t-caption { font-size: 12px; line-height: 16px; font-weight: 500; }
.t-small { font-size: 14px; line-height: 20px; font-weight: 400; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  line-height: 16px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--fox-ink);
}
.eyebrow::before {
  content: '';
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--fox);
  flex: none;
}

.accent { color: var(--fox); }
.muted { color: var(--ink-muted); }
.ink { color: var(--ink); }
.success-text { color: var(--success); }
.danger-text { color: var(--danger); }
.info-text { color: var(--info); }
.fox-text { color: var(--fox-ink); }
.nowrap { white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; }
.brand-type { font-family: var(--font-brand); font-weight: 800; letter-spacing: -.01em; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* Движение. 200 мс ease-out на отклик, 300 мс и 8 px снизу на панели. */
@keyframes rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
@keyframes fade {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes grow-y {
  from { transform: scaleY(0); }
  to { transform: scaleY(1); }
}
/* Шкала и кольцо: от пустой дуги (--len) до значения из атрибута stroke-dashoffset. */
@keyframes arc-fill {
  from { stroke-dashoffset: var(--len); }
}
@keyframes grow-x {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}
@keyframes typing-dot {
  0%, 60%, 100% { opacity: .35; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-2px); }
}
@keyframes leave {
  to { opacity: 0; transform: translateY(-6px) scale(.98); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0s !important;
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0s !important;
    scroll-behavior: auto !important;
  }
}

/* Служебный режим для снимков экранов: ?noanim в адресе. */
.no-anim *, .no-anim *::before, .no-anim *::after { animation: none !important; transition: none !important; }
