/* PettaFab one-page site, v3. Brand: graphite, petrol, the four-squares mark.
   The stage (hero + film) is always dark; the body follows light/dark. */

:root {
  --ui: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", system-ui, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI Variable Display", "Segoe UI", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;
  --ease: cubic-bezier(0.2, 0, 0, 1);

  /* stage: always dark */
  --st-bg: oklch(0.155 0.008 235);
  --st-ink: oklch(0.97 0.004 90);
  --st-ink-2: oklch(0.78 0.01 250);
  --st-line: oklch(0.95 0.005 255 / 0.12);
  --petrol: oklch(0.78 0.1 200);
  --petrol-deep: oklch(0.5 0.095 200);

  /* body: light */
  color-scheme: light dark;
  --bg: oklch(0.985 0.003 90);
  --ink: oklch(0.22 0.012 255);
  --ink-2: oklch(0.44 0.012 255);
  --ink-3: oklch(0.52 0.01 255);
  --line: oklch(0.24 0.01 255 / 0.12);
  --accent: oklch(0.47 0.095 200);
  --accent-soft: oklch(0.5 0.095 200 / 0.12);
  --on-accent: oklch(0.99 0.003 90);
  --focus: oklch(0.55 0.17 250);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: oklch(0.185 0.007 250);
    --ink: oklch(0.96 0.004 90);
    --ink-2: oklch(0.8 0.008 255);
    --ink-3: oklch(0.7 0.008 255);
    --line: oklch(0.95 0.005 255 / 0.11);
    --accent: oklch(0.78 0.1 200);
    --accent-soft: oklch(0.78 0.1 200 / 0.14);
    --on-accent: oklch(0.17 0.02 210);
    --focus: oklch(0.76 0.14 250);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.6 var(--ui); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg { display: block; max-width: 100%; }
figure, h1, h2, h3, p, ol { margin: 0; padding: 0; }
h1, h2, h3 { font-family: var(--display); text-wrap: balance; }
p { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; border-radius: 6px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 10; padding: 10px 14px; border-radius: 8px; background: var(--st-ink); color: var(--st-bg); font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }

/* ---- Stage ------------------------------------------------------------ */
.stage {
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--st-bg); color: var(--st-ink);
  padding: 0 clamp(16px, 4vw, 48px) clamp(64px, 9vw, 120px);
  --focus: oklch(0.76 0.14 250);
}
.stage::before { /* petrol light behind the film */
  content: ""; position: absolute; z-index: -1; left: 50%; top: 62%;
  width: min(1400px, 140vw); height: 900px; transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, oklch(0.55 0.1 200 / 0.38), oklch(0.4 0.07 210 / 0.12) 55%, transparent 75%);
}
.stage::after { /* fine graticule, fading out */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: linear-gradient(oklch(0.78 0.1 200 / 0.06) 1px, transparent 1px), linear-gradient(90deg, oklch(0.78 0.1 200 / 0.06) 1px, transparent 1px);
  background-size: 56px 56px; background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 70% 55% at 50% 0%, #000 20%, transparent 75%);
          mask-image: radial-gradient(ellipse 70% 55% at 50% 0%, #000 20%, transparent 75%);
}

.bar { max-width: 1180px; margin: 0 auto; height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.wordmark { display: inline-flex; align-items: center; gap: 0.38em; color: var(--st-ink); text-decoration: none; font: 650 20px/1 var(--display); letter-spacing: -0.02em; }
.wordmark svg { width: 1em; height: 1em; color: var(--petrol); }
.pill { font: 600 11px/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--st-ink-2); padding: 8px 12px; border: 1px solid var(--st-line); border-radius: 999px; }

.intro { max-width: 1180px; margin: clamp(8px, 2vw, 24px) auto 0; text-align: center; }
.intro h1 { font-size: clamp(30px, 4.4vw, 60px); line-height: 1.05; font-weight: 700; letter-spacing: -0.035em; }
.intro h1 span { display: inline; background: linear-gradient(90deg, var(--petrol), oklch(0.9 0.06 190)); -webkit-background-clip: text; background-clip: text; color: transparent; padding-bottom: 0.06em; }
.lede { max-width: 600px; margin: 28px auto 0; color: var(--st-ink-2); font-size: clamp(17px, 1.7vw, 20px); line-height: 1.55; }

.film { width: min(100%, 1440px, calc((100svh - 190px) * 16 / 9)); margin: clamp(18px, 2.6vw, 32px) auto 0; }
.screen {
  position: relative; aspect-ratio: 16 / 9; border-radius: clamp(14px, 2vw, 24px); overflow: hidden;
  background: #0d0f11;
  box-shadow: 0 0 0 1px oklch(0.95 0.005 255 / 0.14), 0 50px 140px -20px oklch(0 0 0 / 0.7), 0 0 120px -30px oklch(0.6 0.1 200 / 0.5);
}
.poster, .screen video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.screen video { background: #000; }
.play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: inline-flex; align-items: center; gap: 14px; padding: 8px 22px 8px 8px;
  border: 1px solid oklch(0.97 0.004 90 / 0.24); border-radius: 999px;
  background: oklch(0.2 0.01 240 / 0.55); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  color: var(--st-ink); font: 600 16px/1 var(--ui); cursor: pointer;
  transition: transform 220ms var(--ease), background 220ms var(--ease);
}
.play[hidden] { display: none; }
.play:hover { background: oklch(0.25 0.012 240 / 0.7); transform: translate(-50%, -50%) scale(1.03); }
.disc { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--st-ink); color: var(--st-bg); }
.disc svg { width: 18px; height: 18px; margin-left: 3px; }
.soon {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  display: inline-flex; align-items: center; gap: 10px; padding: 12px 18px;
  border: 1px solid oklch(0.97 0.004 90 / 0.18); border-radius: 999px;
  background: oklch(0.2 0.01 240 / 0.5); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  font: 600 12px/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--st-ink-2); white-space: nowrap;
}
.soon[hidden] { display: none; }
.soon .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--petrol); box-shadow: 0 0 0 4px oklch(0.78 0.1 200 / 0.2); }

/* ---- Pillars ------------------------------------------------------------ */
.pillars { padding: clamp(72px, 10vw, 136px) clamp(16px, 4vw, 48px); }
.grid { list-style: none; max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.pillar { padding: 36px 28px 8px 0; display: flex; flex-direction: column; gap: 12px; }
.pillar + .pillar { padding-left: 28px; border-left: 1px solid var(--line); }
.glyph { width: 34px; height: 34px; margin-bottom: 14px; }
.glyph rect { fill: none; stroke: var(--ink-3); stroke-width: 1.3; }
.p1 .glyph .s1, .p2 .glyph .s2, .p3 .glyph .s3, .p4 .glyph .s4 { fill: var(--accent); stroke: var(--accent); }
.kicker { font: 600 11.5px/1.2 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
.pillar h3 { font-size: clamp(20px, 1.9vw, 24px); line-height: 1.15; letter-spacing: -0.025em; font-weight: 650; }
.pillar p { color: var(--ink-2); font-size: 16px; line-height: 1.55; }

/* ---- Join ------------------------------------------------------------------ */
.join { text-align: center; padding: clamp(24px, 4vw, 48px) clamp(16px, 4vw, 48px) clamp(96px, 12vw, 160px); display: flex; flex-direction: column; align-items: center; gap: 28px; }
.bigmark { width: 64px; height: 64px; }
.bigmark rect { fill: none; stroke: var(--ink-3); stroke-width: 1.2; }
.bigmark .s4 { fill: var(--accent); stroke: var(--accent); }
.join h2 { font-size: clamp(34px, 5.4vw, 68px); line-height: 1.02; letter-spacing: -0.04em; font-weight: 700; }
.cta {
  display: inline-flex; align-items: center; gap: 12px; min-height: 60px; padding: 0 34px;
  border-radius: 999px; background: var(--accent); color: var(--on-accent);
  font: 650 18px/1 var(--ui); letter-spacing: -0.01em; text-decoration: none;
  box-shadow: 0 10px 40px -10px oklch(0.5 0.095 200 / 0.6);
  transition: transform 220ms var(--ease), box-shadow 220ms var(--ease);
}
.cta svg { width: 18px; height: 18px; transition: transform 220ms var(--ease); }
.cta:hover { transform: translateY(-2px); box-shadow: 0 16px 50px -10px oklch(0.5 0.095 200 / 0.7); }
.cta:hover svg { transform: translateX(3px); }

/* ---- Footer ---------------------------------------------------------- */
.foot { width: min(1180px, 100% - 2 * clamp(16px, 4vw, 48px)); margin: 0 auto; padding: 24px 0 40px; display: flex; justify-content: space-between; gap: 8px 24px; flex-wrap: wrap; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--ink-3); }

/* ---- Motion: one orchestrated entrance, only if allowed -------------------- */
@media (prefers-reduced-motion: no-preference) {
  .bar, .intro h1, .lede, .film { animation: rise 900ms var(--ease) both; }
  .intro h1 { animation-delay: 80ms; }
  .lede { animation-delay: 180ms; }
  .film { animation-delay: 300ms; animation-duration: 1100ms; }
  .bigmark .s1, .bigmark .s2, .bigmark .s3, .bigmark .s4 { animation: cycle 6s var(--ease) infinite; }
  .bigmark .s1 { animation-delay: 0s; } .bigmark .s2 { animation-delay: 1.5s; } .bigmark .s3 { animation-delay: 3s; } .bigmark .s4 { animation-delay: 4.5s; }
  @keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
  @keyframes cycle { 0%, 30% { fill: var(--accent); stroke: var(--accent); } 25%, 100% { fill: transparent; stroke: var(--ink-3); } }
}

/* ---- Responsive -------------------------------------------------------- */
@media (max-width: 960px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pillar:nth-child(3) { padding-left: 0; border-left: 0; }
  .pillar:nth-child(n+3) { border-top: 1px solid var(--line); }
  .pillar { padding-bottom: 32px; }
}
@media (max-width: 600px) {
  body { font-size: 16px; }
  .bar { height: 64px; }
  .pill { font-size: 10px; padding: 7px 10px; }
  .grid { grid-template-columns: 1fr; }
  .pillar, .pillar + .pillar { padding: 28px 0; border-left: 0; }
  .pillar + .pillar { border-top: 1px solid var(--line); }
  .play { padding: 6px; top: 80%; }
  .play-label { display: none; }
  .disc { width: 44px; height: 44px; }
  .soon { top: 82%; font-size: 10px; padding: 9px 13px; }
  .cta { width: 100%; justify-content: center; }
  .foot { flex-direction: column; }
}

/* Film-first hero (owner, 2026-11-28): short headline, film fills the first screen. */
.stage { padding-bottom: clamp(40px, 6vw, 80px); }
.play { font-size: 18px; padding: 10px 26px 10px 10px; }
@media (max-width: 640px) { .film { width: 100%; } .play-label { font-size: 15px; } }

/* ---- Header nav (2026-11-28) -------------------------------------------- */
.nav { display: flex; align-items: center; gap: clamp(10px, 2vw, 22px); }
.nav-link { color: var(--st-ink-2); text-decoration: none; font: 550 15px/1 var(--ui); padding: 8px 2px; }
.nav-link:hover, .nav-link[aria-current="page"] { color: var(--st-ink); }
.nav-cta { display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border-radius: 999px; background: var(--petrol); color: oklch(0.17 0.02 210); font: 650 15px/1 var(--ui); text-decoration: none; white-space: nowrap; transition: background 200ms var(--ease); }
.nav-cta:hover { background: oklch(0.84 0.09 200); }

/* ---- Early contributors -------------------------------------------------- */
.early { padding: 0 clamp(16px, 4vw, 48px) clamp(72px, 9vw, 120px); }
.early-in { max-width: 860px; margin: 0 auto; padding: clamp(36px, 5vw, 64px) clamp(22px, 5vw, 64px); border: 1px solid var(--line); border-radius: clamp(18px, 2.4vw, 28px); background: linear-gradient(180deg, var(--accent-soft), transparent 70%); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 18px; }
.early h2 { font-size: clamp(30px, 4vw, 48px); line-height: 1.05; letter-spacing: -0.035em; font-weight: 700; }
.early-copy { max-width: 640px; color: var(--ink-2); font-size: clamp(16px, 1.5vw, 18px); line-height: 1.6; }
.steps { list-style: none; width: 100%; margin-top: 10px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; position: relative; }
.steps::before { content: ""; position: absolute; top: 17px; left: 16.6%; right: 16.6%; height: 1px; background: var(--line); }
.steps li { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 0 10px; font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--ink); position: relative; }
.glyph.sm { width: 34px; height: 34px; margin: 0; padding: 0; background: var(--bg); box-shadow: 0 0 0 8px var(--bg); border-radius: 6px; }
.e1 .glyph .s1 { fill: var(--accent); stroke: var(--accent); }
.e2 .glyph .s1, .e2 .glyph .s2 { fill: var(--accent); stroke: var(--accent); }
.e3 .glyph rect { fill: var(--accent); stroke: var(--accent); }
.cta.ghost { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); min-height: 52px; font-size: 16px; padding: 0 26px; margin-top: 6px; }
.cta.ghost:hover { background: var(--accent-soft); box-shadow: inset 0 0 0 1.5px var(--accent); }
.join { padding-top: 0; }

@media (max-width: 600px) {
  .nav { gap: 12px; }
  .nav-link { font-size: 14px; }
  .nav-cta { min-height: 36px; padding: 0 14px; font-size: 14px; }
  .wordmark { font-size: 18px; }
  .steps { grid-template-columns: 1fr; gap: 18px; text-align: left; }
  .steps::before { display: none; }
  .steps li { flex-direction: row; justify-content: flex-start; }
  .cta.ghost { width: 100%; justify-content: center; }
}
@media (max-width: 359px) { .nav-link { display: none; } }
.soon { top: 78%; }
.steps .glyph.sm { flex: none; }
.play { top: 80%; }
