/* ========== Tokens ========== */
:root {
  --color-bg: #1a0f0a;
  --color-bg-2: #2b1a12;
  --color-fg: #f5ede0;
  --color-fg-dim: rgba(245, 237, 224, 0.72);
  --color-accent-warm: #c0392b;
  --color-accent-cool: #5fb3a1;
  --font-display: ui-serif, Georgia, "Times New Roman", serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2.5rem;
  --space-6: 4rem;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --maxw: 64rem;
}

* { box-sizing: border-box; }
*::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-fg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, video, canvas { max-width: 100%; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--color-accent-cool); outline-offset: 2px; border-radius: 2px; }

/* ========== Nav ========== */
.site-nav { position: fixed; inset: 0 0 auto 0; z-index: 10; padding: var(--space-3) var(--space-4); }
.site-nav__inner { display: flex; align-items: center; justify-content: space-between; max-width: var(--maxw); margin: 0 auto; }
.site-nav__logo { font-family: var(--font-display); font-size: 1.125rem; text-decoration: none; letter-spacing: 0.02em; }
.site-nav__links a { margin-left: var(--space-4); text-decoration: none; font-size: 0.875rem; opacity: 0.85; }
.site-nav__links a:hover { opacity: 1; }

/* ========== Hero ========== */
.hero { position: relative; height: 500vh; }
.hero__sticky {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  background: linear-gradient(180deg, var(--color-bg) 0%, var(--color-bg-2) 100%);
}
.hero__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 2;
}
/* The <video> is positioned under the canvas. We keep it visible (not
   display:none) so browsers will actually decode frames and honor
   `currentTime` seeks. The opaque canvas covers it; the only thing the
   user ever sees of the video is the frames we paint to the canvas. */
.hero__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  pointer-events: none;
  z-index: 1;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--color-fg);
  text-align: center;
  padding: var(--space-4);
  pointer-events: none;
  z-index: 3;
}
.hero__overlay > * { pointer-events: auto; }
.hero__content { max-width: 48rem; }
.hero__headline {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 6vw, 4.5rem);
  line-height: 1.05;
  margin: 0 0 var(--space-3);
  letter-spacing: -0.01em;
  text-shadow: 0 1px 24px rgba(0,0,0,0.4);
}
.hero__headline em { font-style: italic; color: var(--color-accent-warm); }
.hero__tagline { font-size: clamp(1rem, 1.5vw, 1.25rem); margin: 0 0 var(--space-5); color: var(--color-fg-dim); }

.hero__actions { display: flex; gap: var(--space-3); justify-content: center; flex-wrap: wrap; margin-bottom: var(--space-5); }
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.9375rem;
  transition: transform 200ms var(--ease-out), background 200ms var(--ease-out);
}
.btn--primary { background: var(--color-accent-warm); color: var(--color-fg); }
.btn--primary:hover { transform: translateY(-1px); background: #d04a3a; }
.btn--ghost { background: transparent; border: 1px solid rgba(245,237,224,0.4); color: var(--color-fg); }
.btn--ghost:hover { background: rgba(245,237,224,0.08); }

.hero__social { list-style: none; padding: 0; margin: 0; display: flex; gap: var(--space-3); justify-content: center; }
.hero__social a {
  display: inline-block;
  width: 2.25rem; height: 2.25rem;
  border-radius: 999px;
  border: 1px solid rgba(245,237,224,0.3);
  text-align: center;
  line-height: 2.25rem;
  font-size: 0.6875rem;
  letter-spacing: 0.05em;
  text-decoration: none;
  transition: background 200ms var(--ease-out);
}
.hero__social a:hover { background: rgba(245,237,224,0.1); }

/* ========== Scroll hint ========== */
.hero__scroll-hint {
  position: absolute;
  left: 50%;
  bottom: 2.5rem;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  color: var(--color-fg-dim);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  transition: opacity 400ms var(--ease-out);
}
.hero__scroll-hint.is-fading { opacity: 0; }
.hero__scroll-hint-line {
  display: block;
  width: 1px;
  height: 2.5rem;
  background: var(--color-fg);
  opacity: 0.4;
  animation: scroll-hint 1.8s var(--ease-out) infinite;
}
@keyframes scroll-hint {
  0%   { transform: translateY(-8px); opacity: 0.2; }
  50%  { opacity: 1; }
  100% { transform: translateY(8px); opacity: 0.2; }
}

/* ========== Below the hero ========== */
.site-content { max-width: var(--maxw); margin: 0 auto; padding: var(--space-6) var(--space-4); }
.site-content h2 { font-family: var(--font-display); font-size: 2rem; margin-top: 0; }
.site-footer { padding: var(--space-5) var(--space-4); text-align: center; color: var(--color-fg-dim); border-top: 1px solid rgba(245,237,224,0.1); }
