/* base.css : reset + design tokens */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; }
img, picture, video { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; }
h1, h2, h3, h4 { overflow-wrap: break-word; }

:root {
  /* type scale (fluid) */
  --text-xs: clamp(0.75rem, 0.72rem + 0.15vw, 0.8125rem);
  --text-sm: clamp(0.875rem, 0.85rem + 0.2vw, 0.9375rem);
  --text-base: clamp(1rem, 0.96rem + 0.25vw, 1.125rem);
  --text-lg: clamp(1.125rem, 1.05rem + 0.5vw, 1.375rem);
  --text-xl: clamp(1.5rem, 1.3rem + 1vw, 2.125rem);
  --text-2xl: clamp(2rem, 1.6rem + 2vw, 3.25rem);
  --text-hero: clamp(2.5rem, 1.8rem + 4.5vw, 5.5rem);

  /* spacing (4px base) */
  --space-1: 0.25rem; --space-2: 0.5rem; --space-3: 0.75rem;
  --space-4: 1rem; --space-6: 1.5rem; --space-8: 2rem;
  --space-12: 3rem; --space-16: 4rem; --space-24: 6rem; --space-32: 8rem;

  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, sans-serif;

  /* Mrs. Stuffins brand : light */
  --bg: #FAF4E6;
  --surface: #F3EAD5;
  --surface-2: #EFE3C8;
  --border: #D9C9A8;
  --text: #33261B;
  --muted: #6E5B49;
  --brick: #7E2A1A;
  --brick-deep: #5E1F13;
  --gold: #B98A2F;
  --gold-soft: #EED9B7;
  --on-brick: #FAF4E6;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px -12px rgba(51, 38, 27, 0.28);
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="dark"] {
  --bg: #221A12;
  --surface: #2B2117;
  --surface-2: #33271B;
  --border: #4A3A28;
  --text: #F0E6D2;
  --muted: #C0AB8E;
  --brick: #A8452E;
  --brick-deep: #7E2A1A;
  --gold: #D2A44B;
  --gold-soft: #4A3A28;
  --on-brick: #FAF4E6;
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.5);
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background 0.4s var(--ease), color 0.4s var(--ease);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
}
