/* =========================================
   ENSTACKED DESIGN TOKENS v2
   Single Source of Truth for ALL design variables.
   Loaded first — before any other stylesheet.
   ========================================= */

:root {

  /* ── Brand Colors ──────────────────────── */
  --brand-50:  #FFF3EE;
  --brand-100: #FFE4D6;
  --brand-200: #FFC4A3;
  --brand-300: #FF9D6B;
  --brand-400: #F47340;
  --brand-500: #E85D20;   /* primary accent  */
  --brand-600: #C94B14;   /* hover state     */
  --brand-700: #A33A0D;
  --brand-800: #7A2B09;
  --brand-900: #4F1C05;

  --accent-color: var(--brand-500);
  --accent-hover: var(--brand-600);
  --accent-subtle: var(--brand-50);

  /* ── Backward-Compat Aliases ───────────── */
  --primary-color: var(--brand-500);
  --light-bg-primary-color: var(--brand-50);

  /* ── Neutrals ─────────────────────────── */
  --gray-0:   #FFFFFF;
  --gray-50:  #FAFAF8;
  --gray-100: #F4F2EE;
  --gray-200: #E9E5DE;
  --gray-300: #D5CFC5;
  --gray-400: #B0A898;
  --gray-500: #8A8177;
  --gray-600: #635D55;
  --gray-700: #433F39;
  --gray-800: #2A2723;
  --gray-900: #161410;

  /* ── Semantic Text ────────────────────── */
  --text-color: #121212;
  --text-heading:  var(--gray-900);
  --text-body:     var(--gray-700);
  --text-muted:    var(--gray-500);
  --text-disabled: var(--gray-400);
  --text-inverse:  var(--gray-0);
  --description-text-color: #595959;

  /* ── Semantic Surface ─────────────────── */
  --bg-page:       var(--gray-50);
  --bg-surface:    var(--gray-0);
  --bg-raised:     var(--gray-0);
  --bg-sunken:     var(--gray-100);

  /* ── Borders ──────────────────────────── */
  --border-subtle:  var(--gray-200);
  --border-default: var(--gray-300);
  --border-strong:  var(--gray-400);

  /* ── Status ───────────────────────────── */
  --success-bg:   #ECFDF3;
  --success-text: #166534;
  --warning-bg:   #FFFBEB;
  --warning-text: #92400E;
  --error-bg:     #FEF2F2;
  --error-text:   #991B1B;

  /* ── Typography ────────────────────────── */
  --font-display: "Plus Jakarta Sans", sans-serif;
  --font-body:    "Plus Jakarta Sans", "Plus Jakarta Sans Fallback", sans-serif;
  --font-mono:    "JetBrains Mono", monospace;

  --text-xs:   0.75rem;    /* 12px */
  --text-sm:   0.875rem;   /* 14px */
  --text-base: 1rem;       /* 16px */
  --text-md:   1.125rem;   /* 18px */
  --text-lg:   1.25rem;    /* 20px */
  --text-xl:   1.5rem;     /* 24px */
  --text-2xl:  1.875rem;   /* 30px */
  --text-3xl:  clamp(1.875rem, 3vw, 2.25rem);   /* 30-36px */
  --text-4xl:  clamp(2.25rem,  4vw, 3rem);       /* 36-48px */
  --text-5xl:  clamp(2.75rem,  5vw, 4rem);       /* 44-64px */
  --text-hero: clamp(3.25rem,  6.5vw, 5rem);     /* 52-80px */

  /* ── Border Radius ────────────────────── */
  --radius-xs:   4px;
  --radius-sm:   8px;
  --radius-md:  12px;
  --radius-lg:  16px;
  --radius-xl:  24px;
  --radius-2xl: 32px;
  --radius-full: 9999px;

  /* ── Spacing ───────────────────────────── */
  --space-1:  4px;
  --space-2:  8px;
  --space-3:  12px;
  --space-4:  16px;
  --space-5:  24px;
  --space-6:  32px;
  --space-7:  48px;
  --space-8:  64px;

  /* ── Shadows ───────────────────────────── */
  --shadow-xs:
    0 1px 2px rgba(0,0,0,0.04);
  --shadow-sm:
    0 1px 2px rgba(0,0,0,0.04),
    0 4px 12px rgba(0,0,0,0.05);
  --shadow-md:
    0 1px 3px rgba(0,0,0,0.04),
    0 8px 24px rgba(0,0,0,0.07);
  --shadow-lg:
    0 2px 4px rgba(0,0,0,0.04),
    0 16px 40px rgba(0,0,0,0.10);
  --shadow-brand:
    0 8px 32px rgba(232, 93, 32, 0.22);

  /* ── Transitions ───────────────────────── */
  --ease-out:   cubic-bezier(0.0, 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;
}
