/* Nexamation v5 — charcoal + petrol. Spec: docs/superpowers/specs/2026-07-11-nexamation-v5-design.md */
:root {
  --bg: #0E1114;
  --surface: #12161B;
  --border: #22262B;
  --border-soft: #1B2025;
  --text: #EDEEF0;
  --text-muted: #A9ADB2;
  --accent: #2E9E8A;
  --accent-light: #4FBFA8;
  --on-accent: #07110F;
  --glow: rgba(46, 158, 138, 0.09);
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
  --font-display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --wrap: 1100px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.12;
  margin: 0 0 1rem;
}
p { margin: 0 0 1rem; }
a { color: var(--accent-light); text-decoration: none; }
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--accent-light);
  outline-offset: 3px;
  border-radius: 2px;
}

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 1.25rem; }

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

.skip {
  position: absolute; left: 1rem; top: -3rem; z-index: 100;
  background: var(--accent); color: var(--on-accent);
  padding: 0.5rem 1rem; border-radius: 6px; transition: top 0.15s;
}
.skip:focus { top: 1rem; }

.label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-light);
  margin: 0 0 1rem;
}

section { padding: 5rem 0; border-bottom: 1px solid var(--border-soft); }
section h2 { font-size: clamp(1.6rem, 3.5vw, 2.1rem); max-width: 24em; }
.section-intro { color: var(--text-muted); max-width: 38em; }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.5rem;
}
.card h3 { font-size: 1.05rem; margin-bottom: 0.5rem; }
.card p { color: var(--text-muted); font-size: 0.9375rem; margin: 0; }

.btn {
  display: inline-block;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 600;
  font-size: 0.9375rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
}
.btn:hover { background: var(--accent-light); text-decoration: none; }
.btn-ghost {
  display: inline-block;
  background: transparent;
  color: var(--accent-light);
  font-weight: 600;
  font-size: 0.9375rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--accent);
  border-radius: 8px;
}
.btn-ghost:hover { border-color: var(--accent-light); text-decoration: none; }

/* Sticky nav */
.site-head {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-soft);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 4rem; }
.brand { font-family: var(--font-display); font-weight: 700; letter-spacing: 0.06em; color: var(--text); }
.brand:hover { text-decoration: none; }
.nav-links { display: flex; align-items: center; gap: 1.75rem; }
.nav-links a { color: var(--text-muted); font-size: 0.9375rem; font-weight: 500; }
.nav-links a:hover { color: var(--text); text-decoration: none; }
.nav-links .nav-cta { color: var(--on-accent); padding: 0.5rem 1.1rem; }
.nav-toggle { display: none; }
main:focus { outline: none; } /* skip-link lands here (tabindex=-1); no focus ring on a container */

/* Below ~900px the full nav (brand + 4 links + CTA) no longer fits on one row,
   so collapse to a hamburger. The collapse is gated behind .js: with scripting
   off the toggle can't work, so the links stay visible (wrapped) instead. */
@media (max-width: 899px) {
  .js .nav-toggle {
    display: block; background: none; border: 1px solid var(--border);
    border-radius: 6px; padding: 0.55rem 0.7rem; cursor: pointer;
  }
  .bars, .bars::before, .bars::after {
    display: block; content: ""; width: 18px; height: 2px;
    background: var(--text); position: relative;
  }
  .bars::before { position: absolute; top: -6px; }
  .bars::after { position: absolute; top: 6px; }
  .js .nav-links {
    display: none; position: absolute; top: 4rem; left: 0; right: 0;
    flex-direction: column; align-items: flex-start; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--border);
    padding: 0.5rem 1.25rem 1.25rem;
  }
  .js .nav-links.open { display: flex; }
  .js .nav-links a { padding: 0.75rem 0; width: 100%; }
  .js .nav-links .nav-cta { text-align: center; margin-top: 0.5rem; }
  /* No-JS fallback: keep the links reachable, wrapping neatly to the right. */
  html:not(.js) .nav-links { flex-wrap: wrap; justify-content: flex-end; gap: 0.4rem 1rem; }
  html:not(.js) .nav-links a { padding: 0.3rem 0; }
}

/* Reveal animation — motion-safe only; without JS everything stays visible */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s ease, transform 0.5s ease; }
  .js .reveal.in { opacity: 1; transform: none; }
}

.site-foot { padding: 2rem 0; }
.site-foot p { color: var(--text-muted); font-size: 0.8125rem; margin: 0; }

@media (min-width: 720px) {
  section { padding: 7.5rem 0; }
}

/* Hero */
.hero {
  padding: 6.5rem 0 5rem;
  background: radial-gradient(55% 70% at 18% 0%, var(--glow), transparent);
}
.hero h1 { font-size: clamp(2.5rem, 7vw, 4.25rem); max-width: 12em; margin-bottom: 1.25rem; }
.hero-sub { color: var(--text-muted); font-size: 1.125rem; max-width: 34em; margin-bottom: 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 3rem; }
.stats {
  display: flex; flex-wrap: wrap; gap: 2.5rem;
  border-top: 1px solid var(--border);
  padding-top: 1.5rem; margin: 0;
}
.stats dt { font-family: var(--font-display); font-weight: 700; font-size: 1.375rem; }
.stats dd {
  margin: 0.15rem 0 0; color: var(--text-muted);
  font-size: 0.6875rem; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
}
@media (min-width: 720px) { .hero { padding: 9rem 0 7rem; } }

/* Card grids */
.grid-3, .grid-2 { display: grid; gap: 1rem; margin-top: 2.5rem; }
@media (min-width: 720px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
}

/* Method steps */
.steps {
  list-style: none; counter-reset: step;
  margin: 2.5rem 0 0; padding: 0;
  display: grid; gap: 1rem;
}
.steps li {
  counter-increment: step;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 10px; padding: 1.25rem 1.5rem 1.25rem 3.5rem;
  position: relative;
}
.steps li::before {
  content: counter(step);
  position: absolute; left: 1.25rem; top: 1.3rem;
  font-family: var(--font-display); font-weight: 700;
  color: var(--accent-light); font-size: 1rem;
}
.steps h3 { font-size: 1rem; margin-bottom: 0.25rem; }
.steps p { color: var(--text-muted); font-size: 0.9375rem; margin: 0; }
.steps .is-final { border-color: var(--accent); }
@media (min-width: 1024px) { .steps { grid-template-columns: repeat(2, 1fr); } }

/* Ownership */
.ownership { background: linear-gradient(180deg, rgba(46, 158, 138, 0.05), transparent 60%); }
.handover { list-style: none; margin: 2rem 0 0; padding: 0; max-width: 44em; }
.handover li {
  padding: 0.9rem 0 0.9rem 2.1rem; position: relative;
  border-bottom: 1px solid var(--border-soft);
}
.handover li::before {
  content: "✓"; position: absolute; left: 0.25rem;
  color: var(--accent-light); font-weight: 600;
}
.ownership-close { margin-top: 2rem; font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; }

/* Straight answers */
.answers-grid { display: grid; gap: 2.5rem; margin-top: 2.5rem; }
.qa { border-bottom: 1px solid var(--border-soft); padding-bottom: 1.25rem; margin-bottom: 1.25rem; }
.qa h3 { font-size: 1rem; margin-bottom: 0.4rem; }
.qa p { color: var(--text-muted); font-size: 0.9375rem; margin: 0; }
.portrait { margin: 0; }
.portrait-slot {
  aspect-ratio: 4 / 5; max-width: 320px;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface); border: 1px dashed var(--border);
  border-radius: 10px; color: var(--text-muted);
  font-size: 0.75rem; letter-spacing: 0.14em;
}
.portrait figcaption { color: var(--text-muted); font-size: 0.8125rem; margin-top: 0.6rem; }
@media (min-width: 1024px) {
  .answers-grid { grid-template-columns: minmax(0, 74ch); align-items: start; }
}

/* Contact */
.contact { background: radial-gradient(55% 80% at 85% 100%, var(--glow), transparent); border-bottom: none; }
.contact-grid { display: grid; gap: 1.5rem; margin-top: 2.5rem; }
#contact-form { position: relative; }
#contact-form label { display: block; font-size: 0.8125rem; font-weight: 600; margin: 1rem 0 0.35rem; }
#contact-form label:first-of-type { margin-top: 0; }
#contact-form input, #contact-form textarea {
  width: 100%; background: var(--bg); color: var(--text);
  border: 1px solid var(--border); border-radius: 8px;
  padding: 0.65rem 0.8rem; font: inherit; font-size: 0.9375rem;
}
#contact-form input:focus, #contact-form textarea:focus {
  outline: 2px solid var(--accent-light); outline-offset: 1px; border-color: transparent;
}
#contact-form .btn { margin-top: 1.25rem; }
#contact-form .hp { position: absolute; left: -9999px; }
.form-note { margin: 0.9rem 0 0; font-size: 0.875rem; color: var(--accent-light); min-height: 1.2em; }
.direct h3 { font-size: 1rem; }
.direct p { color: var(--text-muted); line-height: 1.9; }
.direct-meta { font-size: 0.8125rem; }
@media (min-width: 1024px) {
  .contact-grid { grid-template-columns: 1.5fr 1fr; align-items: start; }
}
