/* ============================================
   CUZ BRAND WEED — Coming Soon
   Palette derived from brand logo: warm tan,
   denim blue overalls, leaf green, banner brown
   ============================================ */

:root,
[data-theme='light'] {
  --color-bg: #f1e2bd;
  --color-surface: #f7ecd2;
  --color-surface-2: #fbf5e4;
  --color-surface-offset: #e8d5a8;
  --color-border: #c9ac74;
  --color-divider: #d8bf8c;

  --color-text: #2c2013;
  --color-text-muted: #5b4a30;
  --color-text-faint: #8a7852;
  --color-text-inverse: #f7ecd2;

  --color-primary: #3f6b8a;      /* denim overalls blue */
  --color-primary-hover: #2f5470;
  --color-primary-active: #234058;
  --color-primary-highlight: #cddce6;

  --color-accent: #4c7a3a;       /* leaf green */
  --color-accent-hover: #3b602c;

  --color-wood: #5c3d24;         /* banner brown */
  --color-wood-hover: #472e1b;

  --radius-sm: 0.375rem;
  --radius-md: 0.65rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px rgba(30, 20, 5, 0.16);
  --shadow-md: 0 6px 18px rgba(30, 20, 5, 0.22);
  --shadow-lg: 0 16px 40px rgba(20, 14, 4, 0.34);

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

  --font-display: 'Lilita One', 'Georgia', serif;
  --font-body: 'Archivo', 'Helvetica Neue', sans-serif;

  --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.15rem);
  --text-lg: clamp(1.15rem, 1rem + 0.75vw, 1.5rem);
  --text-xl: clamp(1.5rem, 1.2rem + 1.25vw, 2.25rem);
  --text-2xl: clamp(2rem, 1.2rem + 3vw, 3.75rem);
  --text-hero: clamp(2.75rem, 1rem + 6vw, 6.5rem);

  --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;
}

[data-theme='dark'] {
  --color-bg: #1a140b;
  --color-surface: #21190f;
  --color-surface-2: #271e12;
  --color-surface-offset: #2c2213;
  --color-border: #4a3a22;
  --color-divider: #3a2d1a;

  --color-text: #f1e6cc;
  --color-text-muted: #c3b18a;
  --color-text-faint: #8d7a56;
  --color-text-inverse: #1a140b;

  --color-primary: #6f9ebd;
  --color-primary-hover: #8ab2ce;
  --color-primary-active: #a4c3da;
  --color-primary-highlight: #2a3a44;

  --color-accent: #7cad63;
  --color-accent-hover: #92c279;

  --color-wood: #caa876;
  --color-wood-hover: #dcbf90;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 6px 18px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.6);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

body {
  min-height: 100dvh;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-bg);
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border-width: 0;
}

:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

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

/* ---------- Layout ---------- */
main {
  position: relative;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  isolation: isolate;
}

.hero-bg {
  position: fixed;
  inset: 0;
  background-image: url('assets/hero-bg.jpg');
  background-size: cover;
  background-position: center 60%;
  z-index: -3;
}

.hero-scrim {
  position: fixed;
  inset: 0;
  background: linear-gradient(
    to bottom,
    color-mix(in oklab, var(--color-bg) 78%, transparent) 0%,
    color-mix(in oklab, var(--color-bg) 55%, transparent) 35%,
    color-mix(in oklab, var(--color-bg) 82%, transparent) 78%,
    color-mix(in oklab, var(--color-bg) 94%, transparent) 100%
  );
  z-index: -2;
  transition: background var(--transition-interactive);
}

.grain {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.hero-content {
  position: relative;
  z-index: 1;
  width: min(720px, 92vw);
  padding: clamp(var(--space-6), 4vh, var(--space-10)) var(--space-6) var(--space-4);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--space-2);
}

/* ---------- Theme toggle ---------- */
.theme-toggle {
  position: fixed;
  top: var(--space-5);
  right: var(--space-5);
  z-index: 10;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-full);
  background: color-mix(in oklab, var(--color-surface) 82%, transparent);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  backdrop-filter: blur(8px);
  cursor: pointer;
  transition: transform var(--transition-interactive), background var(--transition-interactive);
}
.theme-toggle:hover { transform: scale(1.06); background: var(--color-surface-2); }

/* ---------- Logo ---------- */
.logo {
  width: clamp(68px, 8vw, 88px);
  height: auto;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  border: 3px solid var(--color-surface);
  margin-bottom: 0;
}

/* ---------- Eyebrow / Headline ---------- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: var(--text-xs);
  color: var(--color-accent);
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--color-accent);
  box-shadow: 0 0 0 0 color-mix(in oklab, var(--color-accent) 60%, transparent);
  animation: pulse-dot 1.8s ease-out infinite;
}

@keyframes pulse-dot {
  0% { box-shadow: 0 0 0 0 color-mix(in oklab, var(--color-accent) 55%, transparent); }
  70% { box-shadow: 0 0 0 8px color-mix(in oklab, var(--color-accent) 0%, transparent); }
  100% { box-shadow: 0 0 0 0 color-mix(in oklab, var(--color-accent) 0%, transparent); }
}

h1 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.05;
  font-size: clamp(2.25rem, 1rem + 5vw, 5.25rem);
  color: var(--color-text);
  text-wrap: balance;
  text-shadow: 0 2px 0 color-mix(in oklab, var(--color-bg) 60%, transparent);
}

h1 span {
  display: block;
  font-size: clamp(1.5rem, 1rem + 3vw, 3rem);
  color: var(--color-primary);
  margin-top: var(--space-1);
}

.tagline {
  max-width: 46ch;
  font-size: var(--text-base);
  color: var(--color-text-muted);
  margin-top: var(--space-1);
}

/* ---------- Featured scene ---------- */
.scene {
  width: min(420px, 82vw);
  margin: var(--space-2) auto var(--space-1);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 5px solid var(--color-surface);
  box-shadow: var(--shadow-lg);
}

.scene-frames {
  position: relative;
  width: 100%;
  aspect-ratio: 1400 / 1050;
  overflow: hidden;
  background: var(--color-surface-offset);
}

.scene-frame {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 0.55s ease;
  display: block;
}

.scene-frame.is-active {
  opacity: 1;
}

.scene-flash {
  position: absolute;
  inset: 0;
  z-index: 5;
  background: #fffef2;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.16s ease;
}

.scene-flash.is-flashing {
  opacity: 0.92;
  transition: opacity 0.06s ease;
}

.scene-caption {
  margin-top: var(--space-2);
  min-height: 1.4em;
  text-align: center;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.01em;
  color: var(--color-wood);
  opacity: 1;
  transition: opacity 0.22s ease;
}

[data-theme='dark'] .scene-caption {
  color: var(--color-wood);
}

.scene-caption.is-changing {
  opacity: 0;
}

@media (prefers-reduced-motion: reduce) {
  .scene-frame { transition: none; }
  .scene-caption { transition: none; }
}

.launch-date {
  margin-top: var(--space-1);
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  font-weight: 500;
}

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  z-index: 1;
  width: 100%;
  text-align: center;
  padding: var(--space-4) var(--space-5) var(--space-6);
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.site-footer .disclaimer {
  max-width: 56ch;
  margin-inline: auto;
}

/* ---------- Responsive ---------- */
@media (max-width: 480px) {
  .scene { width: min(340px, 90vw); }
}
