/* ==========================================================================
   OMNISTASH — styles.css
   Palette + type come from the logo kit.
   Sections: 0 tokens · 1 base · 2 nav · 3 hero · 4 story · 5 stash · 6 request · 7 footer · 8 motion
   ========================================================================== */

/* ---------- 0. Tokens ---------- */
:root {
  --bg: #0a0a0a;
  --bg-2: #101010;
  --ink: #f2f2f2;
  --ink-2: #b9b9b9;
  --mute: #7d7d7d;
  --line: rgba(255, 255, 255, 0.08);
  --gold: #c9a24a;
  --gold-2: #e2c273;
  --gold-dim: rgba(201, 162, 74, 0.18);

  --font-head: "Space Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --w: min(1240px, 92vw);
  --r: 22px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

@font-face { font-family: "Space Grotesk"; src: url(../fonts/space-grotesk-latin-700-normal.woff2) format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url(../fonts/space-grotesk-latin-500-normal.woff2) format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url(../fonts/inter-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url(../fonts/inter-latin-500-normal.woff2) format("woff2"); font-weight: 500; font-display: swap; }

/* ---------- 1. Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: auto; -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 700; letter-spacing: -0.02em; line-height: 1.02; margin: 0; }
p { margin: 0; }
.wrap { width: var(--w); margin: 0 auto; }
.eyebrow {
  font-family: var(--font-head); font-weight: 500; font-size: 12px; letter-spacing: 0.28em;
  text-transform: uppercase; color: var(--mute); display: flex; align-items: center; gap: 14px;
}
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--gold); }
.gold { color: var(--gold); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 16px 26px; border-radius: 999px;
  font-family: var(--font-head); font-weight: 500; font-size: 15px; letter-spacing: 0.02em;
  transition: transform 0.5s var(--ease), background 0.3s, color 0.3s, border-color 0.3s;
  will-change: transform;
}
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: #0a0a0a; }
.btn-gold:hover { background: var(--gold-2); }
.btn-ghost { border: 1px solid rgba(255,255,255,0.18); color: var(--ink); }
.btn-ghost:hover { border-color: var(--gold); color: var(--gold); }
.btn .arrow { width: 16px; height: 16px; transition: transform 0.5s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }

/* Ambient background: grain + gold glow, fixed behind everything */
.ambient { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.ambient .glow {
  position: absolute; width: 70vmax; height: 70vmax; border-radius: 50%;
  background: radial-gradient(circle, rgba(201,162,74,0.16) 0%, rgba(201,162,74,0) 60%);
  top: -25vmax; right: -20vmax; filter: blur(20px);
}
.ambient .grain {
  position: absolute; inset: -50%; opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%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");
  animation: grain 1.2s steps(4) infinite;
}
@keyframes grain { 0%{transform:translate(0,0)} 25%{transform:translate(-3%,2%)} 50%{transform:translate(2%,-3%)} 75%{transform:translate(-1%,-1%)} 100%{transform:translate(0,0)} }
main, header, footer { position: relative; z-index: 1; }

/* ---------- 2. Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  transition: background 0.4s, border-color 0.4s, backdrop-filter 0.4s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled { background: rgba(10,10,10,0.72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-color: var(--line); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 76px; }
.brand { display: flex; align-items: center; gap: 12px; font-family: var(--font-head); font-weight: 700; letter-spacing: 0.16em; font-size: 14px; }
.brand img { width: 30px; height: auto; }
.brand b { color: var(--gold); font-weight: 700; }
.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a { font-family: var(--font-head); font-weight: 500; font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-2); transition: color 0.3s; }
.nav-links a:hover { color: var(--gold); }
.nav-links .btn { padding: 11px 18px; font-size: 13px; }
.nav-links .btn-gold { color: #0a0a0a; }
.nav-links .btn-gold:hover { color: #0a0a0a; }

/* ---------- 3. Hero ---------- */
.hero {
  min-height: 100svh; display: grid; align-items: center; padding: 120px 0 80px;
  position: relative; perspective: 1200px; overflow: hidden;
}
.hero .wrap { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 48px; align-items: center; }
.hero-logo { width: min(100%, 560px); position: relative; }
.logo-svg { width: 100%; height: auto; overflow: visible; }
.lg-stroke { fill: none; stroke: var(--ink); stroke-width: 6; stroke-linejoin: round; stroke-linecap: round; }
.lg-floor { fill: var(--ink); stroke: var(--ink); stroke-width: 6; stroke-linejoin: round; transform-origin: 200px 260px; }
.lg-omni { fill: var(--ink); }
.lg-stash { fill: var(--gold); }
.lg-shadow { fill: var(--ink); opacity: 0.18; }
.lg-dot { fill: var(--gold); transform-origin: 160px 276px; }

.hero-copy h1 { font-size: clamp(38px, 4.6vw, 64px); max-width: 12ch; }
.hero-copy .lead { margin-top: 24px; color: var(--ink-2); font-size: 18px; max-width: 46ch; }
.hero-copy .cta { margin-top: 36px; display: flex; gap: 14px; flex-wrap: wrap; }
.hero-copy .eyebrow { margin-bottom: 22px; }

/* Backdrop product photo — big, faded, drifts on scroll */
.hero-bg {
  position: absolute; top: -8%; right: -6%; width: 58vw; max-width: 900px; height: 116%; z-index: 0;
  opacity: 0.48; pointer-events: none;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 60% 45%, #000 20%, transparent 72%);
  mask-image: radial-gradient(ellipse 70% 70% at 60% 45%, #000 20%, transparent 72%);
}
.hero-bg img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.85) contrast(1.05); }
.hero .wrap { position: relative; z-index: 1; }

/* 3D floor grid — perspective plane that drifts on scroll */
.floor {
  position: absolute; left: 50%; bottom: -4vh; width: 220vw; height: 70vh; z-index: 0;
  transform: translateX(-50%) perspective(700px) rotateX(64deg);
  transform-origin: 50% 100%;
  background-image:
    linear-gradient(rgba(201,162,74,0.16) 1px, transparent 1px),
    linear-gradient(90deg, rgba(201,162,74,0.16) 1px, transparent 1px);
  background-size: 80px 80px;
  -webkit-mask-image: linear-gradient(to top, rgba(0,0,0,0.9), transparent 85%);
  mask-image: linear-gradient(to top, rgba(0,0,0,0.9), transparent 85%);
  pointer-events: none;
}

.scroll-cue {
  position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%);
  font-family: var(--font-head); font-size: 11px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--mute);
  display: flex; flex-direction: column; align-items: center; gap: 10px;
}
.scroll-cue span { width: 1px; height: 40px; background: linear-gradient(var(--gold), transparent); animation: cue 1.8s var(--ease) infinite; }
@keyframes cue { 0%{transform:scaleY(0);transform-origin:top} 50%{transform:scaleY(1);transform-origin:top} 51%{transform-origin:bottom} 100%{transform:scaleY(0);transform-origin:bottom} }

/* Marquee strip */
.strip { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 18px 0; overflow: hidden; background: rgba(255,255,255,0.015); }
.strip-track { display: flex; gap: 0; width: max-content; animation: marquee 34s linear infinite; }
.strip-track span { font-family: var(--font-head); font-weight: 500; font-size: 13px; letter-spacing: 0.3em; text-transform: uppercase; color: var(--mute); padding: 0 34px; display: inline-flex; align-items: center; gap: 34px; white-space: nowrap; }
.strip-track span::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- 4. Story ---------- */
.story { padding: 140px 0; }
.story .wrap { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 64px; align-items: start; }
.story h2 { font-size: clamp(34px, 3.8vw, 54px); margin-top: 22px; }
.story .body { display: grid; gap: 24px; font-size: 19px; color: var(--ink-2); max-width: 56ch; padding-top: 58px; }
.story .body strong { color: var(--ink); font-weight: 500; }
.story .body .pull { font-family: var(--font-head); font-size: clamp(22px, 2.2vw, 30px); color: var(--ink); line-height: 1.25; letter-spacing: -0.01em; border-left: 2px solid var(--gold); padding-left: 22px; }
.principles { margin-top: 44px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.principle { border: 1px solid var(--line); border-radius: 16px; padding: 22px; background: rgba(255,255,255,0.02); transform-style: preserve-3d; }
.principle .n { font-family: var(--font-head); font-size: 12px; letter-spacing: 0.24em; color: var(--gold); }
.principle h3 { font-size: 18px; margin-top: 10px; }
.principle p { color: var(--mute); font-size: 14px; margin-top: 8px; }

/* Split words (for the line-by-line reveal) */
.split .line { display: block; overflow: hidden; }
.split .line > span { display: block; transform: translateY(110%); }

/* ---------- 5. The Stash ---------- */
.stash { padding: 40px 0 160px; perspective: 1400px; }
.stash-head { display: flex; align-items: end; justify-content: space-between; gap: 32px; margin-bottom: 56px; }
.stash-head h2 { font-size: clamp(34px, 3.8vw, 54px); margin-top: 22px; }
.stash-head p { color: var(--mute); max-width: 36ch; font-size: 15px; }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; transform-style: preserve-3d; }
.card {
  opacity: 0; position: relative; border-radius: var(--r); border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.012));
  padding: 14px 14px 22px; transform-style: preserve-3d; will-change: transform;
  transition: border-color 0.4s;
}
.card:hover { border-color: rgba(201,162,74,0.45); }
.card .media { position: relative; border-radius: 14px; overflow: hidden; aspect-ratio: 4/5; background: #141414; transform: translateZ(18px); }
.card .media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.card:hover .media img { transform: scale(1.06); }
.card .glare {
  position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.4s;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), rgba(255,255,255,0.16), transparent 45%);
  mix-blend-mode: soft-light;
}
.card:hover .glare { opacity: 1; }
.card .idx { position: absolute; top: 26px; left: 26px; font-family: var(--font-head); font-size: 11px; letter-spacing: 0.26em; color: var(--ink); background: rgba(10,10,10,0.55); backdrop-filter: blur(8px); padding: 7px 10px; border-radius: 999px; transform: translateZ(40px); }
.card .meta { padding: 20px 10px 0; transform: translateZ(28px); }
.card h3 { font-size: 22px; letter-spacing: -0.01em; }
.card .tag { color: var(--gold); font-family: var(--font-head); font-weight: 500; font-size: 13px; letter-spacing: 0.04em; margin-top: 6px; }
.card .desc { color: var(--ink-2); font-size: 14.5px; margin-top: 12px; min-height: 3.2em; }
.card .want {
  margin-top: 18px; display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-weight: 500; font-size: 14px; color: var(--ink);
  padding: 12px 18px; border-radius: 999px; border: 1px solid rgba(255,255,255,0.16);
  transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.5s var(--ease);
}
.card .want:hover { background: var(--gold); color: #0a0a0a; border-color: var(--gold); transform: translateY(-2px); }
.card .want .arrow { width: 14px; height: 14px; }

/* ---------- 6. Request ---------- */
.request { padding: 120px 0 140px; border-top: 1px solid var(--line); background: linear-gradient(180deg, rgba(201,162,74,0.05), transparent 40%); }
.request .wrap { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 64px; align-items: start; }
.request h2 { font-size: clamp(34px, 3.8vw, 54px); margin-top: 22px; }
.request .how { margin-top: 26px; color: var(--ink-2); font-size: 17px; max-width: 40ch; }
.steps { margin-top: 36px; display: grid; gap: 14px; }
.step { display: grid; grid-template-columns: 44px 1fr; gap: 14px; align-items: start; }
.step .n { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-family: var(--font-head); font-size: 12px; letter-spacing: 0.1em; color: var(--gold); }
.step h3 { font-size: 16px; }
.step p { color: var(--mute); font-size: 14px; margin-top: 4px; }

.form-shell {
  position: relative; border: 1px solid var(--line); border-radius: var(--r); padding: 34px;
  background: rgba(255,255,255,0.02); transform-style: preserve-3d; overflow: hidden;
}
.form-shell::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; padding: 1px; background: linear-gradient(140deg, rgba(201,162,74,0.5), transparent 40%, transparent 60%, rgba(201,162,74,0.25)); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; pointer-events: none; }
.field { display: grid; gap: 8px; margin-bottom: 18px; }
.field label { font-family: var(--font-head); font-weight: 500; font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--mute); }
.field input, .field select, .field textarea {
  width: 100%; background: #0d0d0d; border: 1px solid rgba(255,255,255,0.1); border-radius: 12px;
  color: var(--ink); padding: 15px 16px; font: inherit; font-size: 16px; outline: none;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.field textarea { min-height: 120px; resize: vertical; }
.field select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23c9a24a' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; padding-right: 44px; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 4px var(--gold-dim); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 6px; flex-wrap: wrap; }
.form-foot small { color: var(--mute); font-size: 12.5px; max-width: 30ch; }
.btn[disabled] { opacity: 0.6; cursor: wait; transform: none; }
.form-error { display: none; margin-top: 16px; color: #ff9f9f; font-size: 14px; }
.form-error.show { display: block; }
.form-error a { color: var(--gold); }
.hp { position: absolute; left: -9999px; opacity: 0; }

/* Thank-you screen replaces the form */
.thanks { display: none; text-align: center; padding: 30px 10px 14px; }
.thanks.show { display: block; }
.thanks img { width: 130px; margin: 0 auto 26px; }
.thanks h3 { font-size: clamp(24px, 2.4vw, 32px); }
.thanks p { color: var(--ink-2); margin-top: 14px; font-size: 17px; }
.thanks .tick { width: 64px; height: 64px; border-radius: 50%; border: 1px solid var(--gold); display: grid; place-items: center; margin: 0 auto 24px; color: var(--gold); }
.thanks .tick svg { width: 26px; height: 26px; }
.thanks .again { margin-top: 26px; color: var(--mute); font-size: 13px; }
.thanks .again button { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- 7. Footer ---------- */
.footer { border-top: 1px solid var(--line); padding: 44px 0; }
.footer .wrap { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer .brand img { width: 34px; }
.footer .links { display: flex; gap: 22px; flex-wrap: wrap; }
.footer .links a { color: var(--mute); font-size: 13px; transition: color 0.3s; }
.footer .links a:hover { color: var(--gold); }
.footer .credit { color: var(--mute); font-size: 12.5px; letter-spacing: 0.04em; }
.footer .credit a { color: var(--ink-2); border-bottom: 1px solid var(--line); transition: color 0.3s, border-color 0.3s; }
.footer .credit a:hover { color: var(--gold); border-color: var(--gold); }

/* ---------- 8. Motion helpers ---------- */
.rv { opacity: 0; transform: translateY(28px); }
[data-tilt] { transform-style: preserve-3d; transition: transform 0.6s var(--ease); }
[data-tilt].is-tilting { transition: transform 0.08s linear; }

/* Preloader curtain */
.curtain { position: fixed; inset: 0; z-index: 100; background: var(--bg); display: grid; place-items: center; }
.curtain img { width: 44px; opacity: 0.9; }
.curtain.hide { pointer-events: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 28px; }
  .hero-logo { width: min(100%, 420px); }
  .hero-bg { width: 120vw; right: -30%; opacity: 0.3; }
  .scroll-cue { display: none; }
  .story .wrap, .request .wrap { grid-template-columns: 1fr; gap: 36px; }
  .story .body { padding-top: 0; }
  .principles { grid-template-columns: 1fr; }
  .grid { grid-template-columns: repeat(2, 1fr); }
  .stash-head { flex-direction: column; align-items: start; }
}
@media (max-width: 640px) {
  .nav .wrap { height: 66px; }
  .nav-links a:not(.btn) { display: none; }
  .hero { padding: 100px 0 60px; }
  .hero-copy h1 { font-size: 36px; }
  .grid { grid-template-columns: 1fr; }
  .row2 { grid-template-columns: 1fr; }
  .form-shell { padding: 22px; }
  .story, .stash, .request { padding-top: 80px; padding-bottom: 90px; }
  .floor { height: 40vh; }
}
@media (prefers-reduced-motion: reduce) {
  .rv, .card { opacity: 1; transform: none; }
  .split .line > span { transform: none; }
  .strip-track, .ambient .grain, .scroll-cue span { animation: none; }
  [data-tilt] { transition: none; }
}

/* ---------- 9. Legal pages (privacy / terms) ---------- */
.legal { padding: 140px 0 100px; }
.legal .wrap { max-width: 760px; }
.legal h1 { font-size: clamp(34px, 4vw, 52px); margin-top: 22px; }
.legal .updated { color: var(--mute); font-size: 13px; margin-top: 14px; }
.legal h2 { font-size: 20px; margin-top: 44px; margin-bottom: 10px; }
.legal p, .legal li { color: var(--ink-2); font-size: 16px; }
.legal p { margin-top: 12px; }
.legal ul { margin: 12px 0 0; padding-left: 20px; }
.legal li { margin-top: 6px; }
.legal a { color: var(--gold); }
.legal .back { display: inline-flex; gap: 10px; align-items: center; margin-top: 48px; font-family: var(--font-head); font-weight: 500; font-size: 14px; color: var(--ink); }
.legal .back:hover { color: var(--gold); }
.legal ol { margin: 8px 0 0; padding-left: 22px; }
.legal strong { color: var(--ink); font-weight: 500; }

/* Footer legal row */
.footer .legal-row { display: flex; align-items: center; justify-content: flex-start; gap: 26px; flex-wrap: wrap; margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--line); }
.footer .legal-label { font-family: var(--font-head); font-weight: 500; font-size: 11px; letter-spacing: 0.26em; text-transform: uppercase; color: var(--gold); }
.footer .legal-row a { color: var(--ink-2); font-size: 13px; transition: color 0.3s; }
.footer .legal-row a:hover { color: var(--gold); }
