/* ============================================================
   Tulum Fashions — Design Tokens 2026
   Phase 3a · branch: redesign-2026-q2
   Source of truth: VISUAL-STYLE-GUIDE.md
   Do not hardcode colors / spacing / motion — reference these.
   ============================================================ */

:root {
  /* ============ COLORS ============ */
  /* Brand — Olive */
  --olive-900: #2F3A1E;
  --olive-700: #4A5A30;
  --olive-500: #6B7D4A;
  --olive-300: #A8B68C;
  --olive-100: #E5E9D8;

  /* Brand — Cream / Background */
  --cream: #F5F0E6;
  --cream-warm: #EFE7D6;

  /* Brand — Accent */
  --terracotta: #C2624A;
  --terracotta-dark: #A04E38;

  /* Brand — Men's / Sportswear / Scrubs */
  --navy-900: #1A2438;
  --navy-700: #2C3A5A;

  /* Grayscale */
  --gray-50:  #F8F7F4;
  --gray-200: #E2DED5;
  --gray-400: #A39E92;
  --gray-600: #6B675E;
  --gray-900: #1F1D1A;

  /* Neutrals */
  --white: #FFFFFF;
  --black-true: #000000;

  /* Semantic aliases */
  --color-bg: var(--cream);
  --color-bg-alt: var(--cream-warm);
  --color-text: var(--gray-900);
  --color-text-secondary: var(--gray-600);
  --color-text-muted: var(--gray-400);
  --color-border: var(--gray-200);
  --color-primary: var(--olive-700);
  --color-primary-hover: var(--olive-500);
  --color-accent: var(--terracotta);
  --color-accent-hover: var(--terracotta-dark);
  --color-focus: var(--terracotta);

  /* ============ TYPOGRAPHY ============ */
  --font-display: 'Cormorant Garamond', 'Times New Roman', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --text-xs:      0.625rem; /* 10px */
  --text-sm:      0.75rem;  /* 12px */
  --text-base-sm: 0.875rem; /* 14px */
  --text-base:    1rem;     /* 16px */
  --text-md:      1.125rem; /* 18px */
  --text-lg:      1.5rem;   /* 24px */
  --text-xl:      2rem;     /* 32px */
  --text-2xl:     3rem;     /* 48px */
  --text-3xl:     4.5rem;   /* 72px */
  --text-4xl:     6rem;     /* 96px */

  --lh-tight: 1.05;
  --lh-snug: 1.15;
  --lh-base: 1.6;
  --lh-loose: 1.7;

  --tracking-tight: -0.02em;
  --tracking-base: 0;
  --tracking-wide: 0.08em;
  --tracking-wider: 0.12em;

  --fw-light: 300;
  --fw-regular: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  /* ============ SPACING ============ */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 16px;
  --space-4: 24px;
  --space-5: 32px;
  --space-6: 48px;
  --space-7: 64px;
  --space-8: 96px;
  --space-9: 128px;

  --section-pad-desktop: 128px;
  --section-pad-tablet: 96px;
  --section-pad-mobile: 64px;

  --gutter-desktop: 24px;
  --gutter-tablet: 16px;
  --gutter-mobile: 12px;

  --container-max: 1440px;
  --container-pad-desktop: 64px;
  --container-pad-tablet: 32px;
  --container-pad-mobile: 20px;

  /* ============ LAYOUT ============ */
  --nav-height-desktop: 80px;
  --nav-height-mobile: 64px;
  --tap-target-min: 44px;

  /* ============ RADIUS ============ */
  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-lg: 8px;
  --radius-pill: 999px;

  /* ============ ANIMATION ============ */
  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out-cubic: cubic-bezier(0.65, 0, 0.35, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);

  --dur-fast: 100ms;
  --dur-base: 200ms;
  --dur-medium: 400ms;
  --dur-slow: 800ms;

  /* Transition shorthands */
  --transition-fast: var(--dur-fast) var(--ease-out-quart);
  --transition-base: var(--dur-base) var(--ease-out-expo);
  --transition-medium: var(--dur-medium) var(--ease-out-expo);
  --transition-slow: var(--dur-slow) var(--ease-out-expo);

  /* ============ Z-INDEX ============ */
  --z-base: 1;
  --z-sticky: 100;
  --z-drawer: 200;
  --z-modal: 300;
  --z-toast: 400;
}

/* ============ Reduced motion ============ */
@media (prefers-reduced-motion: reduce) {
  :root {
    --dur-fast: 0ms;
    --dur-base: 0ms;
    --dur-medium: 0ms;
    --dur-slow: 0ms;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ============ Minimal reset ============ */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body,
h1, h2, h3, h4, h5, h6,
p, figure, blockquote, dl, dd {
  margin: 0;
}

img,
picture,
video,
svg {
  max-width: 100%;
  display: block;
}

/* ============ Base body ============ */
body {
  font-family: var(--font-body);
  font-weight: var(--fw-regular);
  color: var(--color-text);
  line-height: var(--lh-base);
  font-feature-settings: 'tnum' 1, 'kern' 1;
}

/* ============ Helper classes ============ */
.display-xl {
  font-family: var(--font-display);
  font-weight: var(--fw-regular);
  font-size: clamp(3.5rem, 7vw, var(--text-4xl));
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-tight);
}

.display-lg {
  font-family: var(--font-display);
  font-weight: var(--fw-regular);
  font-size: clamp(2.75rem, 5.5vw, var(--text-3xl));
  line-height: 1.1;
  letter-spacing: var(--tracking-tight);
}

.display-md {
  font-family: var(--font-display);
  font-weight: var(--fw-regular);
  font-size: clamp(2rem, 4vw, var(--text-2xl));
  line-height: var(--lh-snug);
  letter-spacing: -0.015em;
}

.display-sm {
  font-family: var(--font-display);
  font-weight: var(--fw-medium);
  font-size: clamp(1.5rem, 2.5vw, var(--text-xl));
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.label,
.eyebrow {
  font-family: var(--font-body);
  font-weight: var(--fw-medium);
  font-size: var(--text-sm);
  line-height: 1.4;
  letter-spacing: var(--tracking-wider);
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.body-lg {
  font-family: var(--font-body);
  font-weight: var(--fw-regular);
  font-size: var(--text-md);
  line-height: var(--lh-loose);
  color: var(--color-text);
}

.body {
  font-family: var(--font-body);
  font-weight: var(--fw-regular);
  font-size: var(--text-base);
  line-height: var(--lh-base);
  color: var(--color-text);
}

.caption {
  font-family: var(--font-body);
  font-weight: var(--fw-regular);
  font-size: var(--text-sm);
  line-height: 1.45;
  letter-spacing: 0.02em;
  color: var(--color-text-secondary);
}

/* Focus ring (per style guide §1) */
:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 2px;
}
