/* ==========================================================================
   FLUID-EX — слой TOKENS
   Единственный источник значений. Источник истины: 04_DESIGN/brand/BRAND_BOOK.md
   и 04_DESIGN/design_system/tokens.css (D-029). В компонентах — только var(--fx-*).
   ========================================================================== */

:root {
  color-scheme: light;

  /* --- Цвет: бренд (по логотипу заказчика, D-030: чёрный + янтарный) --- */
  --fx-primary: #101010;
  --fx-primary-hover: #000000;
  --fx-ink: #101010;
  --fx-accent: #F0B000;
  --fx-accent-hover: #D99A00;
  --fx-accent-text: #8A6200;      /* янтарный ТЕКСТ на белом: AA 5.0:1, сам #F0B000 для текста не годится */
  --fx-muted: #5C5C5C;
  --fx-bg: #F7F7F5;
  --fx-line: #E3E3DE;

  /* --- Цвет: производные --- */
  --fx-white: #FFFFFF;
  --fx-bg-card: #FFFFFF;
  --fx-bg-soft: #F1F1EE;
  --fx-bg-accent-soft: #FFF6DF;
  --fx-ink-80: #3A3A3A;
  --fx-border: var(--fx-line);
  --fx-border-strong: #C8C8C2;

  /* --- Статусы --- */
  --fx-ok: #1F7A4D;
  --fx-ok-bg: #E7F5EC;
  --fx-warn: #8A5A00;
  --fx-warn-bg: #FDF3D7;
  --fx-err: #B42318;
  --fx-err-bg: #FEECEB;

  /* --- Типографика --- */
  --fx-font-display: "Golos Text", "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --fx-font-text: "Inter", "PT Sans", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --fx-font-mono: "JetBrains Mono", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --fx-text-xs: 0.8125rem;   /* 13px */
  --fx-text-sm: 0.875rem;    /* 14px */
  --fx-text-base: 1rem;      /* 16px */
  --fx-text-md: 1.125rem;    /* 18px */
  --fx-text-lg: 1.25rem;     /* 20px */
  --fx-text-h3: 1.375rem;    /* 22px */
  --fx-text-h2: 1.75rem;     /* 28px */
  --fx-text-h1: 2rem;        /* 32px */
  --fx-text-hero: 2.5rem;    /* 40px */

  --fx-lh-tight: 1.2;
  --fx-lh-snug: 1.35;
  --fx-lh-base: 1.55;

  --fx-weight-regular: 400;
  --fx-weight-medium: 500;
  --fx-weight-semibold: 600;
  --fx-weight-bold: 700;

  /* --- Отступы (ритм 4/8) --- */
  --fx-space-1: 4px;
  --fx-space-2: 8px;
  --fx-space-3: 12px;
  --fx-space-4: 16px;
  --fx-space-5: 24px;
  --fx-space-6: 32px;
  --fx-space-7: 40px;
  --fx-space-8: 48px;
  --fx-space-9: 64px;
  --fx-space-10: 80px;

  /* --- Сетка и радиусы --- */
  --fx-container: 1240px;
  --fx-gutter: 16px;
  --fx-radius-sm: 4px;
  --fx-radius: 8px;
  --fx-radius-lg: 12px;
  --fx-radius-pill: 999px;

  /* --- Тап-зоны (WCAG AA) --- */
  --fx-tap-min: 44px;

  /* --- Тени, только для оверлеев --- */
  --fx-shadow-overlay: 0 12px 32px rgba(14, 34, 51, 0.16);
  --fx-shadow-card: 0 1px 2px rgba(14, 34, 51, 0.06);

  /* --- Фокус --- */
  --fx-focus-color: var(--fx-accent);
  --fx-focus-width: 3px;

  /* --- Z-index --- */
  --fx-z-header: 100;
  --fx-z-drawer: 200;
  --fx-z-overlay: 190;
}

/* Учёт предпочтения уменьшенной анимации. */
@media (prefers-reduced-motion: reduce) {
  :root {
    --fx-motion: 0ms;
  }
}

:root {
  --fx-motion: 160ms;
}
