/* ============================================================
   Cork & Cruise — Okanagan Lake wine cruises
   Design tokens + global styles
   ============================================================ */

/* ---- Theme: Bright & Airy (default) ---- */
:root,
[data-theme="bright"] {
  --paper:        oklch(0.992 0.008 225);
  --paper-2:      oklch(0.965 0.014 228);
  --surface:      oklch(1 0 0);
  --ink:          oklch(0.28 0.045 250);
  --ink-soft:     oklch(0.44 0.035 250);
  --muted:        oklch(0.58 0.028 250);
  --hairline:     oklch(0.90 0.012 235);

  --lake:         oklch(0.56 0.135 242);
  --lake-deep:    oklch(0.43 0.125 248);
  --lake-ink:     oklch(0.30 0.09 250);
  --sky:          oklch(0.93 0.042 232);
  --sky-2:        oklch(0.88 0.06 230);

  --sun:          oklch(0.83 0.135 82);
  --sun-deep:     oklch(0.74 0.145 70);
  --sun-ink:      oklch(0.46 0.10 66);

  --wine:         oklch(0.43 0.13 18);

  --on-lake:      oklch(0.99 0.01 230);
  --on-sun:       oklch(0.30 0.07 66);

  --shadow-sm: 0 1px 2px oklch(0.45 0.08 245 / 0.08), 0 2px 6px oklch(0.45 0.08 245 / 0.06);
  --shadow-md: 0 4px 14px oklch(0.45 0.09 245 / 0.10), 0 12px 30px oklch(0.45 0.09 245 / 0.10);
  --shadow-lg: 0 10px 30px oklch(0.40 0.10 245 / 0.16), 0 30px 60px oklch(0.40 0.10 245 / 0.16);

  --glow-sun: 0 0 0 0 transparent;
}

/* ---- Theme: Golden Hour ---- */
[data-theme="golden"] {
  --paper:        oklch(0.975 0.018 78);
  --paper-2:      oklch(0.95 0.03 72);
  --surface:      oklch(0.995 0.008 80);
  --ink:          oklch(0.29 0.045 252);
  --ink-soft:     oklch(0.42 0.04 250);
  --muted:        oklch(0.55 0.035 70);
  --hairline:     oklch(0.89 0.024 70);

  --lake:         oklch(0.47 0.115 248);
  --lake-deep:    oklch(0.37 0.10 250);
  --lake-ink:     oklch(0.28 0.07 250);
  --sky:          oklch(0.92 0.05 62);
  --sky-2:        oklch(0.86 0.075 56);

  --sun:          oklch(0.74 0.155 52);
  --sun-deep:     oklch(0.66 0.165 42);
  --sun-ink:      oklch(0.42 0.12 40);

  --wine:         oklch(0.41 0.14 22);

  --on-lake:      oklch(0.99 0.012 80);
  --on-sun:       oklch(0.27 0.08 44);

  --shadow-sm: 0 1px 2px oklch(0.40 0.08 60 / 0.10), 0 2px 6px oklch(0.40 0.08 60 / 0.08);
  --shadow-md: 0 4px 14px oklch(0.40 0.09 55 / 0.12), 0 12px 30px oklch(0.40 0.09 55 / 0.12);
  --shadow-lg: 0 10px 30px oklch(0.36 0.10 50 / 0.18), 0 30px 60px oklch(0.36 0.10 50 / 0.18);
}

/* ---- Font pairings (display var swapped by tweak) ---- */
:root {
  --font-body: "Hanken Grotesk", ui-sans-serif, system-ui, sans-serif;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --display-weight: 600;
  --display-tracking: -0.005em;

  --maxw: 1180px;
  --gutter: clamp(20px, 5vw, 64px);
  --radius: 18px;
  --radius-sm: 12px;
  --radius-lg: 28px;
}
[data-display="marcellus"] {
  --font-display: "Marcellus", Georgia, serif;
  --display-weight: 400;
  --display-tracking: 0.004em;
}
[data-display="bricolage"] {
  --font-display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --display-weight: 600;
  --display-tracking: -0.02em;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  letter-spacing: var(--display-tracking);
  line-height: 1.04;
  margin: 0;
  color: var(--ink);
}

p { margin: 0; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }

/* ---- Typographic scale ---- */
.display-xl { font-size: clamp(2.9rem, 9vw, 5.6rem); line-height: 0.98; }
.display-lg { font-size: clamp(2.3rem, 6.5vw, 4rem); }
.display-md { font-size: clamp(1.9rem, 5vw, 3rem); }
.display-sm { font-size: clamp(1.5rem, 4vw, 2.1rem); }

.overline {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  font-weight: 500;
  color: var(--lake-deep);
}
[data-theme="golden"] .overline { color: var(--sun-deep); }

.lead { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: var(--ink-soft); line-height: 1.5; }
.fine { font-size: 0.86rem; color: var(--muted); }

/* ---- Layout helpers ---- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(64px, 11vw, 130px); position: relative; }
.section-tight { padding-block: clamp(44px, 8vw, 90px); }
.stack { display: flex; flex-direction: column; }
.center { text-align: center; }

.eyebrow-row { display: flex; align-items: center; gap: 14px; }
.eyebrow-row::after { content: ""; height: 1px; flex: 1; background: var(--hairline); }
.eyebrow-row.center { justify-content: center; }
.eyebrow-row.center::before, .eyebrow-row.center::after { content: ""; height: 1px; width: 48px; background: var(--hairline); flex: none; }

/* ---- Buttons ---- */
.btn {
  --btn-bg: var(--lake);
  --btn-fg: var(--on-lake);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-family: var(--font-body); font-weight: 600; font-size: 1rem;
  letter-spacing: 0.005em;
  padding: 15px 26px; border: none; border-radius: 999px;
  background: var(--btn-bg); color: var(--btn-fg);
  transition: transform .18s cubic-bezier(.2,.8,.2,1), box-shadow .22s ease, background .2s ease, filter .2s ease;
  box-shadow: var(--shadow-sm);
  -webkit-tap-highlight-color: transparent;
  min-height: 52px;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); filter: brightness(1.04); }
.btn:active { transform: translateY(0); }
.btn-sun { --btn-bg: var(--sun); --btn-fg: var(--on-sun); }
.btn-deep { --btn-bg: var(--lake-deep); }
.btn-ghost {
  --btn-bg: transparent; --btn-fg: var(--ink);
  box-shadow: inset 0 0 0 1.5px var(--hairline);
}
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--lake); filter: none; }
.btn-light {
  --btn-bg: var(--surface); --btn-fg: var(--lake-deep);
  box-shadow: var(--shadow-md);
}
.btn-block { width: 100%; }
.btn-lg { padding: 18px 32px; font-size: 1.08rem; min-height: 58px; }
.btn[disabled] { opacity: .5; pointer-events: none; }

/* ---- Cards ---- */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  border: 1px solid color-mix(in oklab, var(--hairline) 60%, transparent);
}

/* ---- Image placeholder slots ---- */
image-slot {
  --slot-bg: var(--sky);
  background: var(--slot-bg);
  border-radius: var(--radius);
  overflow: hidden;
}

/* ---- Pills / chips ---- */
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 15px; border-radius: 999px;
  background: color-mix(in oklab, var(--lake) 12%, var(--surface));
  color: var(--lake-deep); font-weight: 600; font-size: 0.85rem;
  border: 1px solid color-mix(in oklab, var(--lake) 22%, transparent);
}
.chip-sun {
  background: color-mix(in oklab, var(--sun) 22%, var(--surface));
  color: var(--sun-ink);
  border-color: color-mix(in oklab, var(--sun) 40%, transparent);
}

/* ---- Decorative sun ---- */
.sun-orb {
  position: absolute; border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, var(--sun) 0%, color-mix(in oklab, var(--sun) 50%, transparent) 45%, transparent 72%);
  filter: blur(2px); pointer-events: none; z-index: 0;
}

/* ---- Animated waterline ---- */
.waterline { position: relative; }
.wave-divider { display: block; width: 100%; height: clamp(40px, 7vw, 90px); }

/* entrance disabled for reliability — content is always visible.
   (Animations pause at their first frame in backgrounded tabs, and React
   re-renders drop JS-added classes; a visible base state avoids both traps.) */
[data-reveal] { opacity: 1; transform: none; }
