/* ============================================
   BRAND BOOK — Design Tokens
   All CSS custom properties live here.
   Overridden at runtime by brand-loader.js
   ============================================ */

:root {
  /* ---- Brand Palette ---- */
  --brand-primary: #2c2c2c;
  --brand-secondary: #f5f1e8;
  --brand-accent: #c4735b;

  /* ---- Surfaces ---- */
  --surface-page: #FFFFFF;
  --surface-subtle: #F9FAFB;
  --surface-muted: #F3F4F6;
  --surface-card: #FFFFFF;
  --surface-dark: #111111;
  --surface-overlay: rgba(0, 0, 0, 0.6);

  /* ---- Text ---- */
  --text-primary: #111111;
  --text-secondary: #4B5563;
  --text-muted: #9CA3AF;
  --text-inverse: #FFFFFF;
  --text-accent: var(--brand-accent);

  /* ---- Borders ---- */
  --border-default: #E5E7EB;
  --border-subtle: #F3F4F6;
  --border-strong: #D1D5DB;

  /* ---- Typography ---- */
  --font-heading: 'Cormorant Garamond', serif;
  --font-body: 'Montserrat', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Fluid type scale — min @ 375px, max @ 1600px */
  --text-xs: clamp(0.6875rem, 0.65rem + 0.15vw, 0.75rem);       /* 11–12 */
  --text-sm: clamp(0.8125rem, 0.775rem + 0.15vw, 0.875rem);     /* 13–14 */
  --text-base: clamp(0.9375rem, 0.89rem + 0.2vw, 1.0625rem);    /* 15–17 */
  --text-lg: clamp(1.0625rem, 0.99rem + 0.3vw, 1.25rem);        /* 17–20 */
  --text-xl: clamp(1.25rem, 1.12rem + 0.55vw, 1.5rem);          /* 20–24 */
  --text-2xl: clamp(1.5rem, 1.3rem + 0.85vw, 2rem);             /* 24–32 */
  --text-3xl: clamp(2rem, 1.6rem + 1.65vw, 3rem);               /* 32–48 */
  --text-4xl: clamp(2.5rem, 1.85rem + 2.7vw, 4rem);             /* 40–64 */
  --text-5xl: clamp(3rem, 2rem + 4.1vw, 5.5rem);                /* 48–88 */
  --text-display: clamp(3.5rem, 2.2rem + 5.3vw, 7rem);          /* 56–112 */

  /* ---- Font Weights ---- */
  --weight-light: 300;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-semibold: 600;
  --weight-bold: 700;

  /* ---- Line Heights ---- */
  --leading-none: 1;
  --leading-tight: 1.15;
  --leading-snug: 1.3;
  --leading-normal: 1.6;
  --leading-relaxed: 1.75;

  /* ---- Letter Spacing ---- */
  --tracking-tight: -0.02em;
  --tracking-normal: 0;
  --tracking-wide: 0.04em;
  --tracking-wider: 0.08em;
  --tracking-widest: 0.14em;

  /* ---- Spacing (4px base) ---- */
  --space-1: 0.25rem;    /*  4 */
  --space-2: 0.5rem;     /*  8 */
  --space-3: 0.75rem;    /* 12 */
  --space-4: 1rem;       /* 16 */
  --space-5: 1.25rem;    /* 20 */
  --space-6: 1.5rem;     /* 24 */
  --space-8: 2rem;       /* 32 */
  --space-10: 2.5rem;    /* 40 */
  --space-12: 3rem;      /* 48 */
  --space-16: 4rem;      /* 64 */
  --space-20: 5rem;      /* 80 */
  --space-24: 6rem;      /* 96 */
  --space-32: 8rem;      /* 128 */
  --space-40: 10rem;     /* 160 */

  /* ---- Layout ---- */
  --content-width: 72rem;       /* 1152px */
  --content-narrow: 48rem;      /* 768px */
  --page-gutter: clamp(1.5rem, 4vw, 4rem);
  --section-gap: clamp(4rem, 8vw, 8rem);

  /* ---- Radius ---- */
  --ui-radius: 0px;
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* ---- Shadows ---- */
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.05), 0 2px 4px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.06), 0 4px 6px rgba(0, 0, 0, 0.04);
  --shadow-xl: 0 20px 25px rgba(0, 0, 0, 0.08), 0 8px 10px rgba(0, 0, 0, 0.04);

  /* ---- Transitions ---- */
  --ease-default: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-in: cubic-bezier(0.4, 0, 1, 1);
  --ease-out: cubic-bezier(0, 0, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast: 150ms;
  --duration-normal: 250ms;
  --duration-slow: 400ms;
  --duration-slower: 600ms;

  /* ---- Z-Index Scale ---- */
  --z-base: 1;
  --z-dropdown: 10;
  --z-sticky: 20;
  --z-overlay: 30;
  --z-modal: 40;
  --z-lightbox: 45;
  --z-toast: 50;

  /* ---- Status ---- */
  --color-success: #16A34A;
  --color-error: #DC2626;
  --color-warning: #D97706;
  --color-info: #2563EB;
}
