/* Today — shared stylesheet (extends sapplify-bold.html DNA) */

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

:root {
  --black: #0a0a0a;
  --cream: #f0ede6;
  --hot-pink: #ff2d6f;
  --electric-blue: #2d4fff;
  --deep-violet: #6b2dff;
  --grain-opacity: 0.035;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: var(--hot-pink) var(--black);
}

body {
  font-family: 'Syne', sans-serif;
  background: var(--black);
  color: var(--cream);
  overflow-x: hidden;
  cursor: none;
  min-height: 100vh;
}

/* Custom cursor */
.cursor {
  position: fixed; width: 20px; height: 20px;
  border: 2px solid var(--hot-pink); border-radius: 50%;
  pointer-events: none; z-index: 10000;
  transition: transform 0.15s ease, background 0.2s ease, width 0.2s ease, height 0.2s ease;
  transform: translate(-50%, -50%);
  mix-blend-mode: difference;
}
.cursor.hovering { width: 50px; height: 50px; background: var(--hot-pink) }
.cursor-dot {
  position: fixed; width: 5px; height: 5px;
  background: var(--cream); border-radius: 50%;
  pointer-events: none; z-index: 10001;
  transform: translate(-50%, -50%);
}

/* Grain overlay — fixed-position layer, cheap to composite once promoted. */
.grain {
  position: fixed; top: -50%; left: -50%;
  width: 200%; height: 200%;
  pointer-events: none; z-index: 9999;
  opacity: var(--grain-opacity);
  will-change: transform;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  animation: grainShift 0.5s steps(1) infinite;
}
@keyframes grainShift {
  0% { transform: translate(0,0) } 25% { transform: translate(-5%,-5%) }
  50% { transform: translate(5%,0) } 75% { transform: translate(-2%,5%) }
  100% { transform: translate(0,0) }
}

/* Orbs — blur(80px) is expensive; promote to its own layer so transforms
   don't trigger composite-wide repaints. */
.orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.3; pointer-events: none; z-index: 0; will-change: transform }
.orb-1 { width: 400px; height: 400px; background: var(--deep-violet); top: 10%; left: -5%; animation: orbFloat1 15s ease-in-out infinite }
.orb-2 { width: 300px; height: 300px; background: var(--hot-pink); top: 50%; right: -5%; animation: orbFloat2 12s ease-in-out infinite }
.orb-3 { width: 250px; height: 250px; background: var(--electric-blue); bottom: 10%; left: 30%; animation: orbFloat3 18s ease-in-out infinite }
@keyframes orbFloat1 { 0%,100% { transform: translate(0,0) scale(1) } 33% { transform: translate(50px,30px) scale(1.1) } 66% { transform: translate(-20px,-40px) scale(0.95) } }
@keyframes orbFloat2 { 0%,100% { transform: translate(0,0) scale(1) } 50% { transform: translate(-60px,-30px) scale(1.15) } }
@keyframes orbFloat3 { 0%,100% { transform: translate(0,0) } 50% { transform: translate(40px,-50px) } }

/* Primary navigation — only the top-level <nav> that lives directly under
   <body>. Scoped so the accessibility-pass <nav aria-label="Footer"> inside
   <footer> doesn't inherit `position: fixed; top: 0` and render as a second
   fixed bar above the header. */
body > nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 1.5rem 3rem;
  display: flex; justify-content: space-between; align-items: center;
  mix-blend-mode: difference;
}
.nav-logo {
  font-family: 'Syne', sans-serif; font-weight: 800;
  font-size: 1.4rem; letter-spacing: -0.03em;
  color: var(--cream); text-decoration: none;
}
.nav-logo span { color: var(--hot-pink) }
.nav-links { display: flex; gap: 2.5rem; list-style: none }
.nav-links a {
  font-family: 'DM Mono', monospace; font-size: 0.75rem; font-weight: 300;
  color: var(--cream); text-decoration: none;
  text-transform: uppercase; letter-spacing: 0.15em;
  position: relative; padding-bottom: 2px;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 1px;
  background: var(--hot-pink);
  transition: width 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.nav-links a:hover::after { width: 100% }

/* Reveal */
.reveal {
  opacity: 0; transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
.reveal.visible { opacity: 1; transform: translateY(0) }
.reveal-delay-1 { transition-delay: 0.1s }
.reveal-delay-2 { transition-delay: 0.2s }
.reveal-delay-3 { transition-delay: 0.3s }

/* Hero */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column; justify-content: center; align-items: center;
  position: relative; overflow: hidden; padding: 6rem 3rem;
}
.hero-content { text-align: center; z-index: 2; position: relative; max-width: 900px }
.hero-eyebrow {
  font-family: 'DM Mono', monospace; font-size: 0.75rem; font-weight: 300;
  letter-spacing: 0.3em; text-transform: uppercase; color: var(--hot-pink);
  margin-bottom: 2rem; opacity: 0;
  animation: fadeUp 0.8s 0.3s forwards;
}
.hero-title {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(5rem, 15vw, 12rem);
  font-weight: 400; line-height: 0.9; letter-spacing: -0.04em;
  margin-bottom: 1.5rem; opacity: 0;
  animation: fadeUp 0.8s 0.5s forwards;
}
.hero-title em { font-style: italic; color: var(--hot-pink) }
.hero-subtitle {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(1.5rem, 3.5vw, 2.5rem);
  font-style: italic; font-weight: 400;
  color: rgba(240, 237, 230, 0.75);
  margin-bottom: 1.5rem; opacity: 0;
  animation: fadeUp 0.8s 0.7s forwards;
}
.hero-byline {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: rgba(240, 237, 230, 0.35);
  opacity: 0; animation: fadeUp 0.8s 0.9s forwards;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px) }
  to { opacity: 1; transform: translateY(0) }
}

/* Scenes */
.scenes { padding: 8rem 3rem; max-width: 900px; margin: 0 auto; position: relative; z-index: 2 }
.scene { margin-bottom: 6rem; padding-top: 3rem; border-top: 1px solid rgba(240, 237, 230, 0.08) }
.scene-time {
  font-family: 'DM Mono', monospace; font-size: 0.7rem;
  letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--hot-pink); margin-bottom: 2rem;
}
.scene-body {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  line-height: 1.5; color: rgba(240, 237, 230, 0.9);
}
.scene-body blockquote {
  margin: 1.5rem 0; padding-left: 1.5rem;
  border-left: 2px solid var(--hot-pink);
  font-style: italic; color: var(--cream);
}
.scene-body .closed {
  font-family: 'DM Mono', monospace; font-size: 0.75rem; font-weight: 300;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: rgba(240, 237, 230, 0.4);
  margin-top: 1.5rem; display: block;
}
.scene-body code {
  font-family: 'DM Mono', monospace; font-size: 0.85em;
  background: rgba(255, 45, 111, 0.08); padding: 0.2em 0.5em;
  border-radius: 3px; color: var(--cream); font-style: normal;
}

/* Closing */
.closing { padding: 10rem 3rem; text-align: center; position: relative; z-index: 2 }
.closing h2 {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400; line-height: 1.2; letter-spacing: -0.02em;
  max-width: 800px; margin: 0 auto 1.5rem;
}
.closing h2 em { font-style: italic; color: var(--hot-pink) }
.closing p {
  font-family: 'DM Mono', monospace; font-size: 0.85rem;
  color: rgba(240, 237, 230, 0.5);
  max-width: 500px; margin: 0 auto 3rem; line-height: 1.7;
}

/* Beta form */
.beta { padding: 6rem 3rem 10rem; text-align: center; position: relative; z-index: 2 }
.beta h3 {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 400; font-style: italic; margin-bottom: 2rem;
}
.beta form { display: flex; flex-direction: column; gap: 1rem; max-width: 420px; margin: 0 auto }
.beta input[type="text"], .beta input[type="email"] {
  background: transparent; border: none;
  border-bottom: 1px solid rgba(240, 237, 230, 0.25);
  color: var(--cream);
  font-family: 'DM Mono', monospace; font-size: 0.95rem;
  padding: 0.8rem 0.2rem; width: 100%;
  outline: none; transition: border-color 0.3s;
}
.beta input:focus { border-bottom-color: var(--hot-pink) }
.beta input::placeholder { color: rgba(240, 237, 230, 0.3) }
.beta button {
  margin-top: 1rem; padding: 1rem 2.5rem;
  background: var(--hot-pink); color: var(--black);
  font-family: 'Syne', sans-serif; font-weight: 700;
  font-size: 0.9rem; letter-spacing: 0.05em;
  border: none; border-radius: 100px;
  cursor: none;
  transition: transform 0.3s, box-shadow 0.3s;
}
.beta button:hover { transform: scale(1.03); box-shadow: 0 0 60px rgba(255, 45, 111, 0.3) }
.beta .subcopy {
  font-family: 'DM Mono', monospace; font-size: 0.7rem;
  color: rgba(240, 237, 230, 0.35); margin-top: 1.5rem; letter-spacing: 0.05em;
}

/* Footer */
footer { padding: 4rem 3rem 3rem; border-top: 1px solid rgba(240, 237, 230, 0.06); position: relative; z-index: 2 }
.footer-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; flex-direction: column; gap: 2rem;
}
/* Tier 1 — logo + product nav. The visible "how do I get around" row. */
.footer-top {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1.5rem;
}
/* Tier 2 — legal + copyright. Quieter, muted. */
.footer-legal {
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 1rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(240, 237, 230, 0.04);
}
.footer-left {
  font-family: 'Syne', sans-serif; font-weight: 800;
  font-size: 1.2rem; letter-spacing: -0.03em;
}
.footer-left span { color: var(--hot-pink) }
.footer-links { display: flex; gap: 2rem; list-style: none; flex-wrap: wrap }
.footer-links a {
  font-family: 'DM Mono', monospace; font-size: 0.75rem;
  color: rgba(240, 237, 230, 0.55); text-decoration: none;
  letter-spacing: 0.1em; text-transform: uppercase;
  transition: color 0.3s;
}
.footer-links a:hover { color: var(--hot-pink) }
.footer-links-legal { display: flex; gap: 1.5rem; list-style: none; flex-wrap: wrap }
.footer-links-legal a {
  font-family: 'DM Mono', monospace; font-size: 0.65rem;
  color: rgba(240, 237, 230, 0.35); text-decoration: none;
  letter-spacing: 0.1em; text-transform: uppercase;
  transition: color 0.3s;
}
.footer-links-legal a:hover { color: var(--hot-pink) }
.footer-right {
  font-family: 'DM Mono', monospace; font-size: 0.65rem;
  color: rgba(240, 237, 230, 0.3); letter-spacing: 0.1em;
}

/* Document / legal pages */
.doc { max-width: 720px; margin: 0 auto; padding: 10rem 2rem 6rem; position: relative; z-index: 2 }
.doc h1 {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 400; letter-spacing: -0.03em; line-height: 1; margin-bottom: 0.5rem;
}
.doc h1 em { font-style: italic; color: var(--hot-pink) }
.doc .doc-meta {
  font-family: 'DM Mono', monospace; font-size: 0.7rem;
  letter-spacing: 0.2em; text-transform: uppercase;
  color: rgba(240, 237, 230, 0.4); margin-bottom: 3rem;
}
.doc h2 {
  font-family: 'Syne', sans-serif; font-weight: 700;
  font-size: 1.4rem; letter-spacing: -0.02em;
  margin-top: 3rem; margin-bottom: 1rem; color: var(--cream);
}
.doc p, .doc li {
  font-family: 'DM Mono', monospace; font-size: 0.9rem; font-weight: 300;
  line-height: 1.9; color: rgba(240, 237, 230, 0.75); margin-bottom: 1rem;
}
.doc ul, .doc ol { margin-bottom: 1.5rem; padding-left: 1.5rem }
.doc li { margin-bottom: 0.5rem }
.doc a {
  color: var(--hot-pink); text-decoration: none;
  border-bottom: 1px solid rgba(255, 45, 111, 0.4);
  transition: border-color 0.3s;
}
.doc a:hover { border-bottom-color: var(--hot-pink) }
.doc .review-flag {
  background: rgba(255, 45, 111, 0.08);
  border-left: 2px solid var(--hot-pink);
  padding: 1rem 1.5rem; margin: 2rem 0;
  font-family: 'DM Mono', monospace; font-size: 0.75rem;
  color: rgba(255, 45, 111, 0.9); letter-spacing: 0.05em;
}

/* How-it-works page */
.how { max-width: 820px; margin: 0 auto; padding: 10rem 2rem 6rem; position: relative; z-index: 2 }
.how-intro {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.5; font-style: italic;
  color: rgba(240, 237, 230, 0.75);
  margin-bottom: 5rem; padding-bottom: 3rem;
  border-bottom: 1px solid rgba(240, 237, 230, 0.08);
}
.how-closing { margin-top: 8rem; padding-top: 4rem; border-top: 1px solid rgba(240, 237, 230, 0.08); text-align: center }
.how-closing h3 {
  font-family: 'Syne', sans-serif; font-weight: 800;
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  letter-spacing: -0.01em; line-height: 1.4;
  color: var(--cream); margin-bottom: 1.5rem;
}
.how-closing h3 em { font-style: italic; color: var(--hot-pink) }
.how-closing p {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  font-style: italic;
  color: rgba(240, 237, 230, 0.8);
  max-width: 620px; margin: 0 auto; line-height: 1.5;
}

/* Thanks page */
.thanks {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  padding: 3rem; text-align: center; position: relative;
}
.thanks h1 {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 400; font-style: italic;
  line-height: 1.1; margin-bottom: 1.5rem;
  max-width: 700px; position: relative; z-index: 2;
}
.thanks p {
  font-family: 'DM Mono', monospace; font-size: 0.8rem;
  letter-spacing: 0.15em; text-transform: uppercase;
  color: rgba(240, 237, 230, 0.4);
  position: relative; z-index: 2;
}
.thanks a {
  color: var(--hot-pink); text-decoration: none;
  margin-top: 3rem; display: inline-block;
  font-family: 'DM Mono', monospace; font-size: 0.75rem;
  letter-spacing: 0.2em; text-transform: uppercase;
  border-bottom: 1px solid rgba(255, 45, 111, 0.4);
  padding-bottom: 2px;
}

/* Responsive */
@media (max-width: 900px) {
  nav { padding: 1.2rem 1.5rem }
  .nav-links { gap: 1.5rem }
  .hero { padding: 5rem 1.5rem }
  .scenes, .closing, .beta, .doc, .how { padding-left: 1.5rem; padding-right: 1.5rem }
  .footer-inner { flex-direction: column; text-align: center; gap: 1.5rem }
  .footer-links { justify-content: center }
}
@media (max-width: 600px) {
  body { cursor: auto }
  .cursor, .cursor-dot { display: none }
  /* Keep nav visible on mobile — tighten the spacing and size so the 3
     links + logo fit on a 360px-wide screen without wrapping. */
  body > nav { padding: 1rem 1.25rem }
  .nav-links { gap: 1rem }
  .nav-links a { font-size: 0.65rem; letter-spacing: 0.12em }
  .nav-logo { font-size: 1.15rem }
  .scene { margin-bottom: 4rem; padding-top: 2rem }
}

/* ─── Accessibility ──────────────────────────────────────────────────── */

/* Keyboard focus — must be clearly visible against the dark background.
   We use :focus-visible so mouse users don't see an outline on click. */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--hot-pink);
  outline-offset: 3px;
  border-radius: 2px;
}

/* Skip link — hidden until focused, so keyboard users can jump past the nav
   straight into main content. */
.skip-link {
  position: absolute;
  top: -9999px;
  left: 0;
  background: var(--hot-pink);
  color: var(--black);
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  padding: 0.75rem 1.25rem;
  text-decoration: none;
  z-index: 10002;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  top: 0;
}

/* Restore native cursor when the user needs it — keyboard focus, reduced
   motion, or for buttons that declare cursor:none. */
button:focus-visible,
input:focus-visible,
a:focus-visible { cursor: auto }

/* Visually-hidden utility for sr-only form labels and section labels. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Honour the user's OS preference for reduced motion. Disables the custom
   cursor, orbs, grain, reveal transitions, and hero fade-ups; restores the
   native cursor everywhere. */
@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;
  }
  body { cursor: auto }
  .cursor, .cursor-dot, .grain { display: none }
  .orb { display: none }
  .reveal { opacity: 1; transform: none }
  .hero-eyebrow, .hero-title, .hero-subtitle, .hero-byline { opacity: 1 }
  .beta button { cursor: pointer }
}

/* Honour forced-colours mode (Windows High Contrast / similar). */
@media (forced-colors: active) {
  .cursor, .cursor-dot, .grain, .orb { display: none }
  a, button { forced-color-adjust: none }
}
