/* =============================================================
   AMYTEA — Design Token System
   THE SOURCE OF TRUTH. No hardcoded values anywhere else.
   ============================================================= */

:root {
  /* ── Color: Brand ─────────────────────────────────────────── */
  --color-primary:        #64266F;
  --color-primary-light:  #8B4E98;
  --color-primary-dark:   #3E1747;
  --color-primary-tint:   #F6EAF7;

  --color-accent:         #D95F2B;
  --color-accent-light:   #F08A4B;
  --color-accent-dark:    #A83E18;
  --color-accent-tint:    #FFF0E4;

  /* ── Color: Surface ───────────────────────────────────────── */
  --color-surface:        #FFF9F1;
  --color-surface-raised: #FFFFFF;
  --color-surface-sunken: #F7EBDD;

  /* ── Color: Text ──────────────────────────────────────────── */
  --color-text:           #1A1209;
  --color-text-secondary: #4A3828;
  --color-text-muted:     #9C8A72;
  --color-text-inverse:   #FDF8F2;

  /* ── Color: Category Accents ──────────────────────────────── */
  --color-green:          #2D6A3F;
  --color-green-light:    #E8F5EC;
  --color-black-tea:      #3D2010;
  --color-black-tea-light:#F5ECE4;
  --color-white-tea:      #C4A882;
  --color-white-tea-light:#FAF4EC;
  --color-oolong:         #6B4A1E;
  --color-oolong-light:   #F5EDDE;
  --color-herbal:         #8B5E83;
  --color-herbal-light:   #F5EDF4;
  --color-navy:           #1A2D5B;
  --color-navy-light:     #EEF1F9;

  /* ── Color: UI ────────────────────────────────────────────── */
  --color-border:         rgba(156, 138, 114, 0.25);
  --color-border-light:   rgba(156, 138, 114, 0.12);
  --color-border-strong:  rgba(156, 138, 114, 0.55);
  --color-shadow:         rgba(26, 18, 9, 0.08);
  --color-shadow-lg:      rgba(26, 18, 9, 0.16);
  --color-overlay:        rgba(26, 18, 9, 0.55);
  --color-success:        #2D6A3F;
  --color-success-light:  #E8F5EC;
  --color-error:          #B91C1C;
  --color-error-light:    #FEF2F2;
  --color-warning:        #B45309;

  /* ── Color: Primary at Opacity ────────────────────────────── */
  --color-primary-8:      rgba(100, 38, 111, 0.08);
  --color-primary-10:     rgba(100, 38, 111, 0.10);
  --color-primary-12:     rgba(100, 38, 111, 0.12);
  --color-primary-15:     rgba(100, 38, 111, 0.15);
  --color-primary-22:     rgba(100, 38, 111, 0.22);

  /* ── Color: Inverse at Opacity ────────────────────────────── */
  --color-inverse-50:     rgba(253, 248, 242, 0.50);
  --color-inverse-55:     rgba(253, 248, 242, 0.55);
  --color-inverse-60:     rgba(253, 248, 242, 0.60);
  --color-inverse-75:     rgba(253, 248, 242, 0.75);
  --color-inverse-78:     rgba(253, 248, 242, 0.78);

  /* ── Typography: Fonts ────────────────────────────────────── */
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
  --font-body:    'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  /* ── Typography: Scale (1.25 ratio, 16px base) ────────────── */
  --text-xs:   0.75rem;    /* 12px — captions, badges */
  --text-sm:   0.875rem;   /* 14px — meta, labels */
  --text-base: 1rem;       /* 16px — body */
  --text-lg:   1.125rem;   /* 18px — lead text */
  --text-xl:   1.25rem;    /* 20px — card titles */
  --text-2xl:  1.5rem;     /* 24px — section subheads */
  --text-3xl:  1.875rem;   /* 30px — section heads */
  --text-4xl:  2.25rem;    /* 36px — page titles */
  --text-5xl:  3rem;       /* 48px — hero text */
  --text-6xl:  3.75rem;    /* 60px — display */
  --text-7xl:  4.5rem;     /* 72px — hero display */

  /* ── Typography: Weight ───────────────────────────────────── */
  --weight-light:   300;
  --weight-regular: 400;
  --weight-medium:  500;
  --weight-semibold:600;
  --weight-bold:    700;

  /* ── Typography: Line Height ──────────────────────────────── */
  --leading-tight:  1.2;
  --leading-snug:   1.35;
  --leading-normal: 1.55;
  --leading-relaxed:1.75;

  /* ── Typography: Letter Spacing ───────────────────────────── */
  --tracking-tight:   0;
  --tracking-normal:  0;
  --tracking-wide:    0.05em;
  --tracking-wider:   0.1em;
  --tracking-widest:  0.15em;

  /* ── Spacing: 8px grid ────────────────────────────────────── */
  --space-1:   0.25rem;    /*  4px */
  --space-2:   0.5rem;     /*  8px */
  --space-3:   0.75rem;    /* 12px */
  --space-4:   1rem;       /* 16px */
  --space-5:   1.25rem;    /* 20px */
  --space-6:   1.5rem;     /* 24px */
  --space-8:   2rem;       /* 32px */
  --space-10:  2.5rem;     /* 40px */
  --space-12:  3rem;       /* 48px */
  --space-14:  3.5rem;     /* 56px */
  --space-16:  4rem;       /* 64px */
  --space-20:  5rem;       /* 80px */
  --space-24:  6rem;       /* 96px */
  --space-32:  8rem;       /* 128px */

  /* ── Layout ───────────────────────────────────────────────── */
  --max-width:        1200px;
  --max-width-narrow: 720px;
  --max-width-wide:   1440px;
  --section-pad-y:    var(--space-20);
  --section-pad-x:    var(--space-6);
  --card-gap:         var(--space-6);

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

  /* ── Shadows ──────────────────────────────────────────────── */
  --shadow-sm:   0 1px 3px var(--color-shadow), 0 1px 2px rgba(26,18,9,0.06);
  --shadow-md:   0 4px 12px var(--color-shadow), 0 2px 4px rgba(26,18,9,0.06);
  --shadow-lg:   0 8px 32px var(--color-shadow-lg), 0 4px 8px rgba(26,18,9,0.06);
  --shadow-xl:   0 20px 60px var(--color-shadow-lg);
  --shadow-inner:inset 0 2px 4px rgba(26,18,9,0.06);

  /* ── Motion ───────────────────────────────────────────────── */
  --ease-out:    cubic-bezier(0.0, 0.0, 0.2, 1);
  --ease-in-out: cubic-bezier(0.4, 0.0, 0.2, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --duration-fast:   150ms;
  --duration-normal: 200ms;
  --duration-slow:   300ms;
  --duration-xslow:  500ms;

  /* ── Z-index ──────────────────────────────────────────────── */
  --z-base:      1;
  --z-raised:    10;
  --z-dropdown:  100;
  --z-sticky:    200;
  --z-modal:     500;
  --z-overlay:   400;
  --z-toast:     600;
}

/* ── Reduced Motion ────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  :root {
    --duration-fast:   0ms;
    --duration-normal: 0ms;
    --duration-slow:   0ms;
    --duration-xslow:  0ms;
  }
}
