@import url('https://fonts.googleapis.com/css2?family=Geist:wght@200;300;400;500;600&family=Geist+Mono:wght@400;500&family=Newsreader:ital,wght@1,300;1,400&display=swap');

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

html { scroll-behavior: smooth; }

html, body, #root {
  background: #000;
  color: #EDEDED;
  font-family: 'Geist', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
}

body { overflow-x: hidden; }

.app { position: relative; width: 100%; }

.mono { font-family: 'Geist Mono', ui-monospace, monospace; }

.serif-italic { font-family: 'Newsreader', Georgia, serif; font-style: italic; font-weight: 300; }

/* ---- Nav ---- */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding: 22px 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 0.5px solid transparent;
  transition: background 0.25s ease, backdrop-filter 0.25s ease, -webkit-backdrop-filter 0.25s ease, border-color 0.25s ease;
}

.nav-scrolled {
  background: rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom-color: rgba(237, 237, 237, 0.08);
}

.nav-mark {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: #EDEDED;
  text-decoration: none;
  cursor: pointer;
  transition: opacity 0.2s;
}

.nav-mark:hover { opacity: 0.7; }

.nav-right {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-link {
  font-size: 13px;
  font-weight: 500;
  color: rgba(237, 237, 237, 0.65);
  letter-spacing: 0.01em;
  text-decoration: none;
  transition: color 0.2s;
}

.nav-link:hover {
  color: #EDEDED;
}

.nav-cta-filled {
  display: inline-flex;
  align-items: center;
  font-size: 13px;
  padding: 9px 18px;
  border-radius: 999px;
  background: #EDEDED;
  color: #000;
  text-decoration: none;
  border: 0.5px solid #EDEDED;
  transition: background 0.2s, color 0.2s;
  letter-spacing: 0.01em;
  font-weight: 500;
}

.nav-cta-filled:hover {
  background: transparent;
  color: #EDEDED;
}

.nav-cta-ghost {
  display: inline-flex;
  align-items: center;
  font-size: 13px;
  padding: 9px 18px;
  border-radius: 999px;
  background: transparent;
  color: #EDEDED;
  text-decoration: none;
  border: 0.5px solid rgba(237, 237, 237, 0.35);
  transition: background 0.2s, color 0.2s, border-color 0.2s;
  letter-spacing: 0.01em;
  font-weight: 500;
}

.nav-cta-ghost:hover {
  background: #EDEDED;
  color: #000;
  border-color: #EDEDED;
}

.nav-cta-icon {
  padding: 8px 14px;
}

.nav-cta-icon svg { display: block; }

.nav-icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(237, 237, 237, 0.85);
  text-decoration: none;
  transition: color 0.2s;
}

.nav-icon-link:hover { color: #EDEDED; }

.nav-icon-link svg { display: block; }

.nav-links { display: flex; gap: 30px; font-size: 12px; color: rgba(237,237,237,0.55); letter-spacing: 0.04em; }

.nav-links a { color: inherit; text-decoration: none; transition: color 0.2s; cursor: pointer; }

.nav-links a:hover { color: #EDEDED; }

.nav-cta {
  font-size: 12px; padding: 7px 14px;
  border: 0.5px solid rgba(237,237,237,0.3); border-radius: 999px;
  cursor: pointer; transition: all 0.2s; color: #EDEDED;
  background: transparent; font-family: inherit;
}

.nav-cta:hover { background: #EDEDED; color: #000; border-color: #EDEDED; }

/* ---- Scene base ---- */

.scene { position: relative; min-height: 100vh; width: 100%; overflow: hidden; }

.scene-label {
  position: absolute; top: 110px; left: 40px; z-index: 5;
  font-family: 'Geist Mono', monospace; font-size: 10px;
  letter-spacing: 0.22em; color: rgba(237,237,237,0.45);
}

/* ---- Hero ---- */

.hero-scene { position: relative; }

.hero-content {
  position: relative; z-index: 5; height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 0 24px;
  pointer-events: none;
}

.hero-content > * { pointer-events: auto; }

/* ---- HUD overlay (research-instrument styling) ---- */

.hud {
  position: absolute; inset: 0; pointer-events: none; z-index: 3;
  font-family: 'Geist Mono', monospace; font-size: 10px;
  letter-spacing: 0.12em; color: rgba(237, 237, 237, 0.55);
}

/* Corner crosshairs - small L-shaped marks at each corner */

.hud-corner {
  position: absolute; width: 18px; height: 18px;
  border-color: rgba(237, 237, 237, 0.35);
}

.hud-tl { top: 92px; left: 36px; border-top: 0.5px solid; border-left: 0.5px solid; }

.hud-tr { top: 92px; right: 36px; border-top: 0.5px solid; border-right: 0.5px solid; }

.hud-bl { bottom: 92px; left: 36px; border-bottom: 0.5px solid; border-left: 0.5px solid; }

.hud-br { bottom: 92px; right: 36px; border-bottom: 0.5px solid; border-right: 0.5px solid; }

/* Top-right readout */

.hud-readout {
  position: absolute; top: 110px; right: 64px;
  display: flex; flex-direction: column; gap: 4px;
  font-size: 10px; line-height: 1.4;
  min-width: 140px;
}

.hud-line {
  display: flex; justify-content: space-between; gap: 14px;
}

.hud-key { color: rgba(237, 237, 237, 0.4); }

.hud-val { color: rgba(237, 237, 237, 0.78); font-variant-numeric: tabular-nums; }

/* Status indicator with pulsing dot */

.hud-status {
  position: absolute; bottom: 42px; right: 100px;
  display: flex; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: 0.18em;
  color: rgba(237, 237, 237, 0.7);
}

.hud-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #EDEDED;
  box-shadow: 0 0 8px rgba(237, 237, 237, 0.5);
  animation: hudpulse 1.6s ease-in-out infinite;
}

@keyframes hudpulse {
  0%, 100% { opacity: 0.5; transform: scale(0.85); }
  50% { opacity: 1; transform: scale(1); }
}

/* Sweeping scan line */

.hud-scan {
  position: absolute; top: 70px; bottom: 70px; width: 1px;
  background: linear-gradient(
    to bottom,
    transparent 0%,
    rgba(237, 237, 237, 0.1) 20%,
    rgba(237, 237, 237, 0.35) 50%,
    rgba(237, 237, 237, 0.1) 80%,
    transparent 100%
  );
  box-shadow: 0 0 12px rgba(237, 237, 237, 0.18);
  pointer-events: none;
}

.hero-axis {
  font-family: 'Geist Mono', monospace; font-size: 10px;
  letter-spacing: 0.28em; color: rgba(237,237,237,0.55);
  margin-bottom: 36px;
}

.hero-headline {
  font-size: clamp(44px, 6.2vw, 78px); font-weight: 300;
  line-height: 1.04; letter-spacing: -0.025em; color: #EDEDED;
  max-width: 900px;
}

.em {
  font-family: 'Newsreader', Georgia, serif;
  font-style: italic;
  font-weight: 300;
  color: #EDEDED;
}

/* ---- Footer ---- */

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 36px 80px 44px;
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.18em;
  color: rgba(237, 237, 237, 0.42);
  text-transform: uppercase;
  position: relative;
  z-index: 5;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.footer-sep {
  color: rgba(237, 237, 237, 0.25);
}

.footer-email {
  color: rgba(237, 237, 237, 0.55);
  text-decoration: none;
  transition: color 0.2s;
  /* Email is lowercase by convention - override the footer's
     all-caps treatment for this one element. */
  text-transform: none;
  letter-spacing: 0.04em;
  font-size: 12px;
}

.footer-email:hover {
  color: #EDEDED;
}

.footer-right {
  display: flex;
  gap: 28px;
}

.footer-right a {
  color: rgba(237, 237, 237, 0.55);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-right a:hover {
  color: #EDEDED;
}

.footer-github {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.footer-github svg { display: block; }

/* Per-character spans inside the ScrambleText component */

.scramble-locked {
  color: #EDEDED;
  transition: opacity 180ms ease-out;
  opacity: 1;
}

.scramble-cycling {
  /* Same off-white, dimmer - the wavefront becomes visible as
     a brightness gradient. Characters brighten as they lock. */
  color: rgba(237, 237, 237, 0.55);
  transition: opacity 180ms ease-out;
}

.hero-sub {
  margin-top: 32px; max-width: 540px;
  color: rgba(237,237,237,0.6); font-size: 16px; line-height: 1.65;
}

.hero-ctas { margin-top: 44px; display: flex; gap: 12px; }

.btn-primary {
  background: #EDEDED; color: #000; padding: 11px 22px;
  border-radius: 999px; font-size: 13px; font-weight: 500;
  cursor: pointer; transition: all 0.2s; border: none; font-family: inherit;
}

.btn-primary:hover { background: #fff; transform: translateY(-1px); }

.btn-ghost {
  border: 0.5px solid rgba(237,237,237,0.4); color: #EDEDED;
  padding: 11px 22px; border-radius: 999px; font-size: 13px;
  cursor: pointer; background: transparent; transition: all 0.2s; font-family: inherit;
}

.btn-ghost:hover { background: rgba(237,237,237,0.06); border-color: rgba(237,237,237,0.7); }

.pills {
  position: absolute; bottom: 36px; left: 40px;
  display: flex; gap: 8px;
  font-family: 'Geist Mono', monospace; font-size: 10px;
  letter-spacing: 0.12em; z-index: 6;
}

.pill {
  border: 0.5px solid rgba(237,237,237,0.22); padding: 6px 12px;
  border-radius: 999px; color: rgba(237,237,237,0.7);
  font-variant-numeric: tabular-nums;
}

.scroll-cue {
  position: absolute; bottom: 36px; right: 40px;
  font-family: 'Geist Mono', monospace; font-size: 10px;
  letter-spacing: 0.22em; color: rgba(237,237,237,0.5); z-index: 6;
}

/* ---- Marquee ---- */

.marquee {
  overflow: hidden; padding: 28px 0;
  border-top: 0.5px solid rgba(237,237,237,0.08);
  border-bottom: 0.5px solid rgba(237,237,237,0.08);
}

.marquee-track {
  display: inline-flex; gap: 48px; white-space: nowrap;
  font-family: 'Geist Mono', monospace; font-size: 12px;
  letter-spacing: 0.2em; color: rgba(237,237,237,0.5);
  will-change: transform;
}

.marquee-track > span::after { content: '·'; margin-left: 48px; color: rgba(237,237,237,0.22); }

/* ---- Products (scene 02) ---- */

.products-scene {
  padding: 200px 80px 160px;
  display: flex; flex-direction: column; gap: 80px;
  min-height: 100vh;
}

.products-head {
  max-width: 720px;
}

.products-head h2 {
  font-size: clamp(40px, 4.8vw, 64px);
  font-weight: 300; line-height: 1.05; letter-spacing: -0.02em;
}

.products-head p {
  margin-top: 24px;
  font-size: 17px; line-height: 1.65;
  color: rgba(237, 237, 237, 0.65);
  max-width: 520px;
}

.products-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  width: 100%;
}

/* ---- About page (route /about) ---- */

.comet-bg {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
}

.about-page {
  position: relative;
  z-index: 2;
  min-height: 100vh;
  padding: 100px 80px 100px 120px;
  display: flex;
  align-items: flex-start;
  justify-content: flex-start;
}

.about-content {
  max-width: 760px;
  width: 100%;
}

.about-eyebrow {
  font-family: 'Geist Mono', monospace;
  font-size: 11px;
  letter-spacing: 0.28em;
  color: rgba(237, 237, 237, 0.5);
  text-transform: uppercase;
  margin-bottom: 32px;
}

.about-lede {
  font-size: clamp(34px, 3.6vw, 52px);
  /* Extra-light + tight letter-spacing gives the lede a geometric,
     architectural feel - closer to xAI's display type without
     swapping the font. The weight 200 makes the strokes thin
     and modern; the negative letter-spacing tightens the
     character relationships. */
  font-weight: 200;
  line-height: 1.12;
  letter-spacing: -0.028em;
  color: #EDEDED;
}

/* Hairline section divider - quietly tells the eye "new beat" */

.about-divider {
  height: 0.5px;
  background: rgba(237, 237, 237, 0.14);
  margin: 40px 0;
  width: 100%;
  max-width: 480px;
}

.about-body {
  max-width: 640px;
}

.about-body p {
  font-size: 17px;
  line-height: 1.72;
  color: rgba(237, 237, 237, 0.78);
  margin-bottom: 28px;
}

.about-body p:last-child {
  margin-bottom: 0;
}

.about-body .em {
  /* Italic Newsreader emphasis on "Yocto is one answer." etc. */
  font-size: 1.06em;
  color: #EDEDED;
}

.about-closing {
  font-size: clamp(36px, 3.8vw, 56px);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: -0.02em;
  color: #EDEDED;
}

.product-card {
  display: block;
  background: rgba(255, 255, 255, 0.018);
  border: 0.5px solid rgba(237, 237, 237, 0.12);
  border-radius: 14px;
  padding: 40px 44px;
  transition: border-color 0.4s, background 0.4s, transform 0.4s;
  position: relative;
  overflow: hidden;
}

.product-card:hover {
  border-color: rgba(237, 237, 237, 0.32);
  background: rgba(255, 255, 255, 0.028);
}

.product-name {
  font-size: 14px;
  font-family: 'Geist Mono', monospace;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(237, 237, 237, 0.55);
  margin-bottom: 16px;
}

/* Top metadata line - replaces the old stat+label combo.
   Reads as a sentence, mono caps, low contrast. */

.product-meta {
  font-family: 'Geist Mono', monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: rgba(237, 237, 237, 0.6);
  line-height: 1.5;
  margin-bottom: 40px;
}

/* Tagline is the visual hero of the card - large italic serif */

.product-tagline {
  font-size: clamp(34px, 3.4vw, 52px);
  font-weight: 300;
  line-height: 1.1;
  letter-spacing: -0.022em;
  color: #EDEDED;
  font-family: 'Newsreader', Georgia, serif;
  font-style: italic;
  margin-bottom: 28px;
}

.product-desc {
  font-size: 15px;
  line-height: 1.65;
  color: rgba(237, 237, 237, 0.65);
  max-width: 460px;
  margin-bottom: 40px;
}

.product-ctas {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.product-card a {
  text-decoration: none;
}

.product-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 13px;
  text-decoration: none;
  transition: background 0.25s, color 0.25s, border-color 0.25s;
  cursor: pointer;
}

.product-cta-primary {
  background: #EDEDED;
  color: #000;
  border: 0.5px solid #EDEDED;
}

.product-cta-primary:hover {
  background: transparent;
  color: #EDEDED;
}

.product-cta-ghost {
  background: transparent;
  color: rgba(237, 237, 237, 0.85);
  border: 0.5px solid rgba(237, 237, 237, 0.35);
}

.product-cta-ghost:hover {
  border-color: #EDEDED;
  color: #EDEDED;
}

.product-cta .arrow { font-size: 12px; }

.product-cta-icon {
  padding: 10px 14px;
}

.product-cta-icon svg { display: block; }

/* ---- Yocto ---- */

.yocto { padding: 200px 80px 160px; min-height: 100vh; }

.yocto-head { margin-bottom: 56px; max-width: 1100px; }

/* Parameter budget comparison */

.param-budget {
  margin-bottom: 80px;
  display: flex; flex-direction: column; gap: 14px;
  max-width: 720px;
  font-family: 'Geist Mono', monospace;
}

.budget-row {
  display: grid;
  grid-template-columns: 200px 1fr 60px;
  align-items: center;
  gap: 18px;
}

.budget-label {
  font-size: 10px; letter-spacing: 0.18em;
  color: rgba(237, 237, 237, 0.45);
  text-align: right;
}

.budget-label-active { color: rgba(237, 237, 237, 0.85); }

.budget-bar {
  height: 8px;
  display: flex;
  background: rgba(237, 237, 237, 0.04);
  border: 0.5px solid rgba(237, 237, 237, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.budget-fill { height: 100%; }

.budget-attention { background: #EDEDED; }

.budget-other { background: rgba(237, 237, 237, 0.18); }

.budget-pct {
  font-size: 11px; color: rgba(237, 237, 237, 0.5);
  font-variant-numeric: tabular-nums;
  text-align: left;
}

.budget-pct-active { color: #EDEDED; }

.budget-legend {
  display: flex; gap: 24px;
  font-size: 9px; letter-spacing: 0.18em;
  color: rgba(237, 237, 237, 0.4);
  margin-top: 8px;
  padding-left: 218px; /* align with bars */
}

.legend-swatch {
  display: inline-block;
  width: 8px; height: 8px;
  margin-right: 6px;
  vertical-align: -1px;
  border-radius: 1px;
}

.swatch-attention { background: #EDEDED; }

.swatch-other { background: rgba(237, 237, 237, 0.18); }

.yocto-head h2 {
  font-size: clamp(40px, 4.8vw, 64px); font-weight: 300;
  line-height: 1.05; letter-spacing: -0.02em; max-width: 800px;
}

.yocto-head .axis {
  font-family: 'Geist Mono', monospace; font-size: 10px;
  letter-spacing: 0.22em; color: rgba(237,237,237,0.55);
  margin-bottom: 24px;
}

.yocto-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 80px; align-items: center; }

.yocto-viz { position: relative; aspect-ratio: 4/3; width: 100%; }

.yocto-stats { display: flex; flex-direction: column; gap: 12px; }

.stat { padding: 28px 0; border-top: 0.5px solid rgba(237,237,237,0.18); }

.stat .num {
  font-size: clamp(40px, 4vw, 56px); font-weight: 300;
  letter-spacing: -0.02em; line-height: 1;
}

.stat .num .em-num { font-family: 'Newsreader', Georgia, serif; font-style: italic; font-weight: 300; }

.stat .label {
  margin-top: 12px; font-family: 'Geist Mono', monospace;
  font-size: 11px; letter-spacing: 0.12em; color: rgba(237,237,237,0.55);
}

.stat .desc {
  margin-top: 10px; color: rgba(237,237,237,0.7); font-size: 14px;
  line-height: 1.55; max-width: 400px;
}

/* ---- Responsive ---- */

@media (max-width: 1024px) {
  .nav { padding: 18px 28px; }
  .products-scene { padding: 160px 40px 120px; gap: 56px; }
  .yocto { padding: 160px 40px 120px; }
  .yocto-grid { grid-template-columns: 1fr; gap: 56px; }
  .about-page { padding: 100px 40px 80px; }
  .site-footer { padding: 32px 40px 36px; }
  .hud-readout { right: 36px; }
  .hud-status { right: 60px; }
}

@media (max-width: 768px) {
  .nav { padding: 14px 20px; }
  .nav-right { gap: 16px; }
  .nav-link { font-size: 12px; }
  .nav-cta-filled { font-size: 12px; padding: 8px 14px; }

  .scene-label { top: 90px; left: 20px; }

  .hero-content { padding: 0 20px; }
  .hero-headline { font-size: clamp(36px, 9vw, 56px); }
  .hero-sub { margin-top: 24px; font-size: 15px; }
  .hero-ctas { margin-top: 32px; flex-wrap: wrap; justify-content: center; }

  .hud-tl, .hud-tr { top: 76px; }
  .hud-tl, .hud-bl { left: 18px; }
  .hud-tr, .hud-br { right: 18px; }
  .hud-bl, .hud-br { bottom: 76px; }
  .hud-readout {
    top: 90px; right: 20px; min-width: 110px;
    font-size: 9px;
  }
  .hud-status { bottom: 30px; right: 20px; font-size: 9px; }
  .hud-scan { display: none; }

  .pills { left: 20px; bottom: 24px; flex-wrap: wrap; max-width: calc(100% - 140px); }
  .scroll-cue { right: 20px; bottom: 24px; }

  .marquee { padding: 20px 0; }
  .marquee-track { gap: 32px; font-size: 11px; }
  .marquee-track > span::after { margin-left: 32px; }

  .products-scene { padding: 120px 20px 80px; gap: 40px; }
  .products-head p { font-size: 15px; }
  .products-grid { grid-template-columns: 1fr; gap: 20px; }
  .product-card { padding: 28px 24px; }
  .product-tagline { font-size: clamp(28px, 7vw, 40px); }
  .product-desc { font-size: 14px; margin-bottom: 28px; }
  .product-ctas { gap: 10px; }
  .product-cta { padding: 10px 18px; font-size: 12px; }

  .yocto { padding: 120px 20px 80px; }
  .yocto-head { margin-bottom: 40px; }
  .yocto-grid { gap: 40px; }
  .stat { padding: 22px 0; }
  .stat .desc { font-size: 13px; }

  .param-budget { margin-bottom: 56px; }
  .budget-row {
    grid-template-columns: 110px 1fr 44px;
    gap: 12px;
  }
  .budget-label { font-size: 9px; letter-spacing: 0.12em; }
  .budget-pct { font-size: 10px; }
  .budget-legend {
    padding-left: 0;
    flex-wrap: wrap;
    gap: 14px;
    font-size: 8px;
  }

  .about-page { padding: 100px 20px 60px; }
  .about-eyebrow { margin-bottom: 24px; }
  .about-divider { margin: 32px 0; }
  .about-body p { font-size: 15px; line-height: 1.7; margin-bottom: 22px; }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    padding: 28px 20px 32px;
    font-size: 10px;
  }
  .footer-left {
    flex-wrap: wrap;
    gap: 8px 12px;
    max-width: 100%;
    white-space: nowrap;
  }
  .footer-email { font-size: 11px; }
  .footer-right { gap: 20px; flex-wrap: wrap; }
}

@media (max-width: 480px) {
  .nav-right { gap: 12px; }
  .nav-link { font-size: 11px; }
  .nav-cta-filled { font-size: 11px; padding: 7px 12px; }
  .hero-ctas .btn-primary,
  .hero-ctas .btn-ghost { width: 100%; text-align: center; }
  .hero-ctas { flex-direction: column; width: 100%; max-width: 280px; }
  .pills { display: none; }
  .product-ctas { flex-direction: column; align-items: stretch; }
  .product-cta { justify-content: center; }
}
