/* =========================================================
   AOE — landing page
   Synthwave-leaning, flat (zero radius), electric accent,
   pixel typography as identity. Dark, high-contrast.
   ========================================================= */

:root {
  --bg: #05060a;
  --bg-2: #0a0c14;
  --ink: #eef2fb;
  --muted: #9aa4bd;
  --dim: #626a82;
  --line: rgba(238, 242, 251, 0.09);

  /* Electric accent — cyan primary, plasma violet secondary (AI / sci-fi) */
  --hot: #22e0ff;      /* electric cyan */
  --hot-2: #5cc8ff;    /* soft cyan tint */
  --amber: #7c5cff;    /* plasma violet highlight */

  --maxw: 1260px;
  --pad: clamp(1.35rem, 5vw, 4rem);

  --sans: "Space Grotesk", system-ui, -apple-system, sans-serif;
  --body: "Inter", system-ui, -apple-system, sans-serif;
  --pixel: "Silkscreen", ui-monospace, monospace;
}

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

html { -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-weight: 300;
  font-size: 1.02rem;
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Subtle synthwave grid behind the black sections (hero scene covers it) */
body::before {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(34, 224, 255, 0.10) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 92, 255, 0.10) 1px, transparent 1px);
  background-size: 58px 58px;
  -webkit-mask-image: radial-gradient(130% 120% at 50% 40%, #000 42%, transparent 88%);
  mask-image: radial-gradient(130% 120% at 50% 40%, #000 42%, transparent 88%);
}

/* CRT scanlines — no blend mode (cheaper compositing while scrolling) */
body::after {
  content: ""; position: fixed; inset: 0; z-index: 60; pointer-events: none;
  background: repeating-linear-gradient(to bottom, transparent 0, transparent 2px, rgba(0,0,0,0.09) 3px);
  opacity: 0.28;
}

::selection { background: rgba(34, 224, 255, 0.32); color: #fff; }
a { color: inherit; text-decoration: none; }

.nav, main, .footer { position: relative; z-index: 2; }

/* ---------- Layout primitives ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad); }
.section { padding-block: clamp(5rem, 11vw, 8.5rem); position: relative; }
.section:not(.hero) {
  content-visibility: auto;
  contain-intrinsic-size: auto 520px;
}

/* Pixel identity label */
.kicker, .eyebrow {
  font-family: var(--pixel);
  font-size: clamp(0.7rem, 0.95vw, 0.82rem);
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--hot);
  text-shadow: 0 0 14px rgba(34,224,255,0.5);
}
.kicker { display: block; margin-bottom: 1.7rem; }

.display {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(2rem, 4.2vw, 3.25rem);
  line-height: 1.06;
  letter-spacing: -0.02em;
}

.lede {
  color: var(--muted);
  font-size: clamp(1.06rem, 1.35vw, 1.2rem);
  line-height: 1.7;
  max-width: 58ch;
  margin-top: 1.6rem;
}
.lede a, .prose a { color: var(--hot-2); border-bottom: 1px solid rgba(92,200,255,0.4); padding-bottom: 1px; }
.lede a:hover, .prose a:hover { color: #fff; }

.prose { max-width: 64ch; margin-top: 2rem; display: flex; flex-direction: column; gap: 1.3rem; }
.prose p { color: var(--muted); font-size: clamp(1.05rem, 1.25vw, 1.16rem); line-height: 1.78; }

/* ---------- Buttons (flat, pixel, sharp) ---------- */
.pill {
  display: inline-flex; align-items: center; gap: 0.6rem;
  font-family: var(--pixel);
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  padding: 1.05rem 1.6rem;
  border-radius: 0;
  transition: transform .18s ease, background .2s, color .2s, box-shadow .2s;
}
.pill-solid { background: var(--hot); color: #04121a; }
.pill-solid:hover { background: #4fe8ff; transform: translate(0, -2px); box-shadow: 0 6px 24px rgba(34,224,255,0.35), -3px 5px 0 rgba(124,92,255,0.35); }
.pill-ghost { color: var(--ink); box-shadow: inset 0 0 0 1px rgba(247,243,246,0.22); }
.pill-ghost:hover { color: #fff; box-shadow: inset 0 0 0 1px var(--hot); }
.pill .ar { transition: transform .2s; }
.pill:hover .ar { transform: translateX(4px); }

/* ---------- Nav ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.1rem var(--pad);
  transition: background .4s, backdrop-filter .4s, padding .4s;
}
.nav.scrolled { background: rgba(5,6,10,0.72); backdrop-filter: blur(14px); padding-block: 0.7rem; box-shadow: 0 1px 0 rgba(34,224,255,0.10); }
.brand-word { font-family: var(--pixel); font-weight: 700; font-size: 1.4rem; letter-spacing: 0.02em; }
.nav-links { display: flex; gap: 2.2rem; }
.nav-links a {
  font-family: var(--pixel); font-size: 0.72rem; letter-spacing: 0.03em; text-transform: uppercase;
  color: var(--muted); position: relative; transition: color .25s;
}
.nav-links a::after { content: ""; position: absolute; left: 0; bottom: -7px; width: 0; height: 2px; background: var(--hot); transition: width .25s; }
.nav-links a:hover { color: var(--ink); }
.nav-links a:hover::after { width: 100%; }
.nav-cta { padding: 0.75rem 1.25rem; }
.nav-toggle { display: none; }

.mobile-menu {
  position: fixed; inset: 0; z-index: 45;
  background: rgba(5,6,10,0.97); backdrop-filter: blur(22px);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1.5rem;
  opacity: 0; visibility: hidden; transition: opacity .4s;
}
.mobile-menu.open { opacity: 1; visibility: visible; }
.mobile-menu a { font-family: var(--pixel); font-size: 1.4rem; color: var(--muted); text-transform: uppercase; transition: color .3s; }
.mobile-menu a:hover { color: var(--hot); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding: 7rem 0 4rem;
  overflow: hidden;
  contain: layout paint style;
}
#scene {
  position: absolute; inset: 0; z-index: 0;
  width: 100%; height: 100%; display: block; pointer-events: none;
  contain: strict;
}
.hero-scrim {
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(135% 105% at 8% 44%, rgba(5,6,10,0.97) 0%, rgba(5,6,10,0.86) 34%, rgba(5,6,10,0.38) 60%, transparent 80%),
    linear-gradient(0deg, var(--bg) 0%, rgba(5,6,10,0.5) 12%, transparent 34%);
}
.hero-inner {
  position: relative; z-index: 2;
  width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--pad);
}
.hero-copy { max-width: 720px; }

.eyebrow { display: inline-block; margin-bottom: 1.6rem; color: var(--hot); }

.hero-title {
  font-family: var(--sans);
  font-weight: 600;
  font-size: clamp(2.4rem, 5vw, 3.9rem);
  line-height: 1.03;
  letter-spacing: -0.03em;
  /* subtle chromatic aberration (cyan/violet) + legibility shadow */
  text-shadow: 1.5px 0 rgba(124, 92, 255, 0.45), -1.5px 0 rgba(34, 224, 255, 0.35), 0 2px 30px rgba(0, 0, 0, 0.7);
}
.hero-title .accent {
  color: var(--hot);
  text-shadow: 0 0 24px rgba(34, 224, 255, 0.45);
}

.hero-sub {
  color: #cabfc5;
  font-size: clamp(1.08rem, 1.4vw, 1.24rem);
  line-height: 1.68;
  max-width: 50ch;
  margin-top: 1.7rem;
  text-shadow: 0 1px 20px rgba(0, 0, 0, 0.6);
}
.hero-cta { display: flex; gap: 0.9rem; flex-wrap: wrap; margin-top: 2.4rem; }

/* ---------- Premise trio ---------- */
.trio {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: clamp(1.6rem, 4vw, 3rem);
  margin-top: clamp(3rem, 6vw, 4.5rem);
}
.trio-item h3 { font-family: var(--sans); font-weight: 600; font-size: 1.2rem; margin-bottom: 0.55rem; }
.trio-item p { color: var(--muted); font-size: 1rem; line-height: 1.6; }

/* ---------- HUD panels (trio / skills / pipeline) ---------- */
.trio-item, .skill, .pipe-step {
  position: relative;
  padding: 1.6rem 1.5rem;
  background: linear-gradient(155deg, rgba(34,224,255,0.055), rgba(124,92,255,0.022) 62%, transparent);
  border: 1px solid var(--line);
  transition: transform .28s cubic-bezier(.2,.7,.2,1), border-color .28s, box-shadow .28s, background .28s;
}
/* top accent bar */
.trio-item::before, .skill::before, .pipe-step::before {
  content: ""; position: absolute; top: -1px; left: -1px; width: 36px; height: 2px;
  background: var(--hot); box-shadow: 0 0 12px var(--hot);
}
/* bottom-right HUD corner tick (reveals on hover) */
.trio-item::after, .skill::after, .pipe-step::after {
  content: ""; position: absolute; right: 0; bottom: 0; width: 11px; height: 11px;
  border-right: 1px solid rgba(34,224,255,0.55); border-bottom: 1px solid rgba(34,224,255,0.55);
  opacity: 0; transition: opacity .28s;
}
.trio-item:hover, .skill:hover, .pipe-step:hover {
  transform: translateY(-4px);
  border-color: rgba(34,224,255,0.42);
  background: linear-gradient(155deg, rgba(34,224,255,0.10), rgba(124,92,255,0.04) 62%, transparent);
  box-shadow: 0 20px 55px -22px rgba(34,224,255,0.55), inset 0 0 34px -20px rgba(34,224,255,0.7);
}
.trio-item:hover::after, .skill:hover::after, .pipe-step:hover::after { opacity: 1; }

/* ---------- Build (session/signature/cohort) ---------- */
.build { list-style: none; margin-top: clamp(2.2rem, 5vw, 3.5rem); }
.build-row {
  display: grid; grid-template-columns: 200px 1fr;
  gap: clamp(1rem, 4vw, 3rem); padding: 2rem 1rem;
  transition: background .28s, box-shadow .28s;
}
.build-row + .build-row { border-top: 1px solid var(--line); }
.build-row:hover {
  background: linear-gradient(90deg, rgba(34,224,255,0.07), rgba(124,92,255,0.02) 45%, transparent 70%);
  box-shadow: inset 3px 0 0 var(--hot);
}
.build-num { font-family: var(--pixel); font-size: 0.85rem; color: var(--hot); padding-top: 0.5rem; text-shadow: 0 0 12px rgba(34,224,255,0.5); }
.build-body h3 { font-family: var(--sans); font-weight: 600; font-size: clamp(1.3rem, 2.2vw, 1.8rem); margin-bottom: 0.55rem; }
.build-body p { color: var(--muted); font-size: 1.1rem; line-height: 1.65; max-width: 58ch; }

/* ---------- Skills (no scores) ---------- */
.skills {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(1.8rem, 4vw, 2.8rem) clamp(2.5rem, 5vw, 4.5rem);
  margin-top: clamp(2.5rem, 5vw, 4rem);
}
.skill h3 { font-family: var(--sans); font-weight: 600; font-size: 1.28rem; margin-bottom: 0.45rem; }
.skill p { color: var(--muted); font-size: 0.98rem; line-height: 1.6; }

/* ---------- Approach pipeline ---------- */
.pipe {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(225px, 1fr));
  gap: clamp(2rem, 4vw, 2.8rem) clamp(2rem, 4vw, 3.2rem);
  margin-top: clamp(2.5rem, 5vw, 4rem);
}
.pipe-n { font-family: var(--pixel); font-size: 0.85rem; color: var(--hot); text-shadow: 0 0 12px rgba(34,224,255,0.5); }
.pipe-step h3 { font-family: var(--sans); font-weight: 600; font-size: 1.35rem; margin: 0.6rem 0 0.5rem; }
.pipe-step p { color: var(--muted); font-size: 1.02rem; line-height: 1.6; max-width: 34ch; }

/* ---------- Contact ---------- */
.contact { text-align: center; }
.contact .kicker { display: inline-block; }
.contact-title { margin-inline: auto; }
.contact .lede { margin-inline: auto; }
.mail {
  display: inline-block; margin-top: 2.2rem;
  font-family: var(--sans); font-weight: 600;
  font-size: clamp(1.6rem, 4vw, 2.6rem);
  color: var(--hot);
  text-shadow: 0 0 26px rgba(34,224,255,0.45);
  transition: transform .2s, color .2s, text-shadow .2s;
}
.mail:hover { transform: translateY(-2px); color: #fff; text-shadow: 0 0 34px rgba(34,224,255,0.8); }

/* ---------- Footer ---------- */
.footer { padding-top: clamp(3.5rem, 7vw, 5.5rem); overflow: hidden; }
.footer-meta {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.8rem 2rem;
  font-family: var(--pixel); font-size: 0.68rem; letter-spacing: 0.02em; color: var(--dim);
}
.footer-meta a:hover { color: var(--hot); }
.footer-word {
  font-family: var(--pixel); font-weight: 700; text-align: center;
  font-size: clamp(5rem, 26vw, 19rem); line-height: 0.9; margin-top: 1.5rem; letter-spacing: 0.02em;
  background: linear-gradient(180deg, rgba(34,224,255,0.20), rgba(5,6,10,0) 78%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  user-select: none;
}

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .9s cubic-bezier(.2,.7,.2,1), transform .9s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .nav-links, .nav-cta { display: none; }
  .nav-toggle {
    display: inline-flex; flex-direction: column; gap: 5px;
    background: none; border: none; cursor: pointer; padding: 6px; z-index: 60;
  }
  .nav-toggle span { width: 25px; height: 2px; background: var(--ink); transition: transform .35s, opacity .35s; }
  .nav-toggle.open span:first-child { transform: translateY(7px) rotate(45deg); }
  .nav-toggle.open span:last-child { transform: translateY(-7px) rotate(-45deg); }

  .trio { grid-template-columns: 1fr; }
  .build-row { grid-template-columns: 1fr; gap: 0.4rem; }
  .build-num { padding-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}
