/* Art direction: Luxury painting company → Refined, authoritative, premium
   Palette: Warm dark charcoal + cream, accent: muted gold (#c9a86c) for luxury without flash
   Typography: Cormorant Garamond (display serif) + DM Sans (body sans) — elegant + modern clarity
   Density: Spacious — editorial luxury, generous whitespace */

/* ═══════════════════════════════════════
   TYPE SCALE
   ═══════════════════════════════════════ */
:root {
  --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(3rem,     0.5rem  + 7vw,    8rem);

  /* SPACING (4px base) */
  --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;

  /* FONTS */
  --font-display: 'Cormorant Garamond', 'Georgia', serif;
  --font-body: 'DM Sans', 'Helvetica Neue', sans-serif;

  /* RADIUS */
  --radius-sm: 0.25rem;
  --radius-md: 0.375rem;
  --radius-lg: 0.5rem;
  --radius-xl: 0.75rem;
  --radius-full: 9999px;

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

  /* CONTENT WIDTHS */
  --content-narrow: 640px;
  --content-default: 960px;
  --content-wide: 1200px;
  --content-full: 100%;
}

/* ═══════════════════════════════════════
   LIGHT MODE (warm cream dominant)
   ═══════════════════════════════════════ */
:root, [data-theme="light"] {
  /* Surfaces — warm cream hierarchy */
  --color-bg:               #f5f0e8;
  --color-surface:          #faf7f2;
  --color-surface-2:        #ffffff;
  --color-surface-offset:   #ede8df;
  --color-surface-offset-2: #e5e0d6;
  --color-surface-dynamic:  #ddd8ce;
  --color-divider:          #d4cfc5;
  --color-border:           #c9c4b9;

  /* Text — warm charcoal hierarchy */
  --color-text:           #1a1a1a;
  --color-text-muted:     #6b6560;
  --color-text-faint:     #a09a93;
  --color-text-inverse:   #f5f0e8;

  /* Accent — muted gold */
  --color-accent:         #c9a86c;
  --color-accent-hover:   #b8944f;
  --color-accent-active:  #a07d3a;
  --color-accent-highlight: rgba(201, 168, 108, 0.12);

  /* Semantic */
  --color-success:        #4a7c3a;
  --color-error:          #b03a3a;

  /* Shadows — warm tinted */
  --shadow-sm: 0 1px 2px oklch(0.2 0.02 60 / 0.06);
  --shadow-md: 0 4px 12px oklch(0.2 0.02 60 / 0.08);
  --shadow-lg: 0 12px 32px oklch(0.2 0.02 60 / 0.12);
}

/* ═══════════════════════════════════════
   DARK MODE (charcoal dominant, luxurious)
   ═══════════════════════════════════════ */
[data-theme="dark"] {
  /* Surfaces — deep charcoal hierarchy */
  --color-bg:               #111111;
  --color-surface:          #1a1a1a;
  --color-surface-2:        #222222;
  --color-surface-offset:   #181818;
  --color-surface-offset-2: #252525;
  --color-surface-dynamic:  #2d2d2d;
  --color-divider:          #333333;
  --color-border:           #3d3d3d;

  /* Text — warm light hierarchy */
  --color-text:           #ece7df;
  --color-text-muted:     #9c9690;
  --color-text-faint:     #6b6560;
  --color-text-inverse:   #1a1a1a;

  /* Accent — warm gold, slightly brighter for dark mode */
  --color-accent:         #d4b477;
  --color-accent-hover:   #e0c48d;
  --color-accent-active:  #c9a86c;
  --color-accent-highlight: rgba(212, 180, 119, 0.15);

  /* Semantic */
  --color-success:        #6daa45;
  --color-error:          #dd6974;

  /* Shadows — darker */
  --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
  --shadow-md: 0 4px 12px oklch(0 0 0 / 0.4);
  --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.5);
}

/* System preference fallback */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --color-bg:               #111111;
    --color-surface:          #1a1a1a;
    --color-surface-2:        #222222;
    --color-surface-offset:   #181818;
    --color-surface-offset-2: #252525;
    --color-surface-dynamic:  #2d2d2d;
    --color-divider:          #333333;
    --color-border:           #3d3d3d;
    --color-text:           #ece7df;
    --color-text-muted:     #9c9690;
    --color-text-faint:     #6b6560;
    --color-text-inverse:   #1a1a1a;
    --color-accent:         #d4b477;
    --color-accent-hover:   #e0c48d;
    --color-accent-active:  #c9a86c;
    --color-accent-highlight: rgba(212, 180, 119, 0.15);
    --color-success:        #6daa45;
    --color-error:          #dd6974;
    --shadow-sm: 0 1px 2px oklch(0 0 0 / 0.3);
    --shadow-md: 0 4px 12px oklch(0 0 0 / 0.4);
    --shadow-lg: 0 12px 32px oklch(0 0 0 / 0.5);
  }
}
