/* ==========================================================================
   DESERT SHIELD INSURANCE — DESIGN TOKENS
   Brand: navy #1B3557 (authority, trust) + sand tan #E3C08C (Arizona desert,
   warmth) on warm ivory surfaces. Bold industrial type mirrors the approved
   ad campaign. No burnt orange in primary UI (dropped from approved logo).
   ========================================================================== */

:root {
  /* ---- Type scale (fluid clamp, 12px floor) ---- */
  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.875rem);
  --text-sm: clamp(0.875rem, 0.8rem + 0.35vw, 1rem);
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 2.5vw, 3.5rem);
  --text-3xl: clamp(2.5rem, 1rem + 4vw, 5rem);
  --text-hero: clamp(2.75rem, 1.2rem + 6vw, 6.5rem);

  /* ---- 4px spacing system ---- */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  --space-32: 8rem;

  /* ---- Radius ---- */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.875rem;
  --radius-xl: 1.25rem;
  --radius-full: 9999px;

  /* ---- Transitions ---- */
  --transition-interactive: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* ---- Content widths ---- */
  --content-narrow: 640px;
  --content-default: 1000px;
  --content-wide: 1280px;
  --content-full: 100%;

  /* ---- Fonts ---- */
  --font-display: 'Clash Grotesk', 'Arial Narrow', sans-serif;
  --font-body: 'Satoshi', 'Helvetica Neue', sans-serif;

  /* ---- Fixed brand colors (do NOT invert with theme) ----
     Used for the navy chrome elements that carry brand identity
     across both light and dark mode: utility bar, hero scrims,
     CTA bands, sidebar CTA card, and the footer. */
  --brand-navy: #1b3557;
  --brand-navy-deep: #12233b;
  --brand-tan: #e3c08c;
  --brand-gold: #d9a94f;
  --on-navy: #f7f2e6;
  --on-navy-muted: #c3cddb;
}

/* ================= LIGHT MODE (default) ================= */
:root,
[data-theme='light'] {
  /* Surfaces — warm ivory/sand family */
  --color-bg: #faf6ee;
  --color-surface: #ffffff;
  --color-surface-2: #f6f1e6;
  --color-surface-offset: #efe6d3;
  --color-surface-offset-2: #e7dac0;
  --color-surface-dynamic: #ddcda8;
  --color-divider: #e5dac3;
  --color-border: #d9c9a8;

  /* Text */
  --color-text: #1c2733;
  --color-text-muted: #5b6572;
  --color-text-faint: #98a0aa;
  --color-text-inverse: #faf6ee;

  /* Primary — Desert Shield Navy */
  --color-primary: #1b3557;
  --color-primary-hover: #142943;
  --color-primary-active: #0f1f34;
  --color-primary-highlight: #dbe3ec;

  /* Accent — Sand Tan / Gold */
  --color-accent: #b9873f;
  --color-accent-hover: #9c7134;
  --color-accent-active: #7f5c2a;
  --color-accent-highlight: #f3e6cc;
  --color-tan-soft: #e3c08c;

  /* Warning */
  --color-warning: #964219;
  --color-warning-hover: #713417;
  --color-warning-active: #4b2614;
  --color-warning-highlight: #ddcfc6;

  /* Error */
  --color-error: #a12c2c;
  --color-error-hover: #7d1e1e;
  --color-error-active: #561717;
  --color-error-highlight: #e3d0cd;

  /* Success */
  --color-success: #3f6b2e;
  --color-success-hover: #2e5220;
  --color-success-active: #1e3814;
  --color-success-highlight: #d6ddcc;

  /* Shadows */
  --shadow-sm: 0 1px 2px oklch(0.2 0.03 250 / 0.08);
  --shadow-md: 0 6px 16px oklch(0.2 0.03 250 / 0.12);
  --shadow-lg: 0 16px 40px oklch(0.2 0.03 250 / 0.18);
}

/* ================= DARK MODE ================= */
[data-theme='dark'] {
  --color-bg: #0e1826;
  --color-surface: #14202e;
  --color-surface-2: #182636;
  --color-surface-offset: #1c2a3b;
  --color-surface-offset-2: #223347;
  --color-surface-dynamic: #2a3d54;
  --color-divider: #223145;
  --color-border: #2e4258;

  --color-text: #eae2ce;
  --color-text-muted: #a3aebb;
  --color-text-faint: #6b7887;
  --color-text-inverse: #14202e;

  --color-primary: #d8c39a;
  --color-primary-hover: #e8d5ab;
  --color-primary-active: #f1e2bd;
  --color-primary-highlight: #33455c;

  --color-accent: #e3c08c;
  --color-accent-hover: #edd3a8;
  --color-accent-active: #f4e2c1;
  --color-accent-highlight: #3d3320;
  --color-tan-soft: #e3c08c;

  --color-warning: #d98a52;
  --color-warning-hover: #e6a877;
  --color-warning-active: #f0c29c;
  --color-warning-highlight: #4a3a2c;

  --color-error: #d97a7a;
  --color-error-hover: #e39898;
  --color-error-active: #edb6b6;
  --color-error-highlight: #4a3030;

  --color-success: #8fbf76;
  --color-success-hover: #a8d192;
  --color-success-active: #c1e3af;
  --color-success-highlight: #2e3d27;

  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
  --shadow-md: 0 6px 16px oklch(0 0 0 / 0.35);
  --shadow-lg: 0 16px 40px oklch(0 0 0 / 0.45);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg: #0e1826;
    --color-surface: #14202e;
    --color-surface-2: #182636;
    --color-surface-offset: #1c2a3b;
    --color-surface-offset-2: #223347;
    --color-surface-dynamic: #2a3d54;
    --color-divider: #223145;
    --color-border: #2e4258;
    --color-text: #eae2ce;
    --color-text-muted: #a3aebb;
    --color-text-faint: #6b7887;
    --color-text-inverse: #14202e;
    --color-primary: #d8c39a;
    --color-primary-hover: #e8d5ab;
    --color-primary-active: #f1e2bd;
    --color-primary-highlight: #33455c;
    --color-accent: #e3c08c;
    --color-accent-hover: #edd3a8;
    --color-accent-active: #f4e2c1;
    --color-accent-highlight: #3d3320;
    --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
    --shadow-md: 0 6px 16px oklch(0 0 0 / 0.35);
    --shadow-lg: 0 16px 40px oklch(0 0 0 / 0.45);
  }
}
