/* ── TOKENS ─────────────────────────────────── */
:root {
  --bg:        #050810;
  --bg2:       #080d1a;
  --bg3:       #0c1228;
  --cyan:      #00f5ff;
  --cyan-dim:  #00b8c4;
  --cyan-glow: rgba(0, 245, 255, 0.15);
  --violet:    #7c3aed;
  --violet-glow: rgba(124, 58, 237, 0.2);
  --green:     #00ff88;
  --red:       #ff3355;
  --text:      #c8d8e8;
  --text-dim:  #5a7080;
  --border:    rgba(0, 245, 255, 0.12);
  --border-strong: rgba(0, 245, 255, 0.3);
  --font-mono: 'Share Tech Mono', monospace;
  --font-disp: 'Rajdhani', sans-serif;
  --font-body: 'Inter', sans-serif;
}

/* ── RESET ──────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }

/* ── OVERLAYS ───────────────────────────────── */
.scanlines {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: repeating-linear-gradient(
    0deg,
    transparent,
    transparent 2px,
    rgba(0,0,0,0.04) 2px,
    rgba(0,0,0,0.04) 4px
  );
}
.noise {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 998;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ── NAV ────────────────────────────────────── */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
  background: rgba(5, 8, 16, 0.85);
  backdrop-filter: blur(12px);
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.logo {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  letter-spacing: 0.2em;
}
.logo-bracket { color: var(--cyan); }
.logo-text { color: white; margin: 0 2px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.nav-links a { color: var(--text-dim); transition: color 0.2s; }
.nav-links a:hover { color: var(--cyan); }
.nav-cta {
  color: var(--cyan) !important;
  border: 1px solid var(--border-strong);
  padding: 0.4rem 1rem;
  border-radius: 2px;
  transition: background 0.2s !important;
}
.nav-cta:hover { background: var(--cyan-glow) !important; }

/* ── SHARED SECTION TOKENS ──────────────────── */
.section-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--cyan);
  letter-spacing: 0.25em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}
.section-title {
  font-family: var(--font-disp);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: white;
  line-height: 1.1;
  margin-bottom: 1rem;
}
.section-sub {
  color: var(--text-dim);
  font-size: 1rem;
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 3rem;
}
.accent { color: var(--cyan); }

/* ── BUTTONS ────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--cyan);
  color: var(--bg);
  font-family: var(--font-disp);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.75rem 1.75rem;
  border: none;
  cursor: pointer;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
  transition: all 0.2s;
  position: relative;
}
.btn-primary:hover {
  background: white;
  box-shadow: 0 0 30px var(--cyan-glow);
}
.btn-full { width: 100%; justify-content: center; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text);
  font-family: var(--font-disp);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.75rem 1.75rem;
  border: 1px solid var(--border);
  transition: all 0.2s;
}
.btn-ghost:hover {
  border-color: var(--border-strong);
  color: var(--cyan);
}

/* ── DOTS ───────────────────────────────────── */
.dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--cyan);
}
.dot.green { background: var(--green); }
.dot.pulse {
  animation: pulse-dot 2s ease-in-out infinite;
}
.dot.green.pulse {
  animation: pulse-green 2s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%,100% { box-shadow: 0 0 0 0 rgba(0,245,255,0.6); }
  50%      { box-shadow: 0 0 0 6px rgba(0,245,255,0); }
}
@keyframes pulse-green {
  0%,100% { box-shadow: 0 0 0 0 rgba(0,255,136,0.6); }
  50%      { box-shadow: 0 0 0 6px rgba(0,255,136,0); }
}

/* ── HERO ───────────────────────────────────── */
.hero {
  min-height: 100vh;
  padding: 120px 2rem 80px;
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
}

.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
  pointer-events: none;
}

.hero-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--cyan);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-family: var(--font-disp);
  font-size: clamp(2.8rem, 5vw, 5rem);
  font-weight: 700;
  color: white;
  line-height: 1.0;
  margin-bottom: 1.5rem;
}

/* GLITCH EFFECT */
.glitch {
  position: relative;
  color: var(--cyan);
}
.glitch::before,
.glitch::after {
  content: attr(data-text);
  position: absolute;
  top: 0; left: 0;
  width: 100%;
}
.glitch::before {
  color: var(--violet);
  animation: glitch-1 3.5s infinite;
  clip-path: polygon(0 30%, 100% 30%, 100% 50%, 0 50%);
  transform: translate(-3px, 0);
}
.glitch::after {
  color: var(--cyan-dim);
  animation: glitch-2 3.5s infinite;
  clip-path: polygon(0 60%, 100% 60%, 100% 80%, 0 80%);
  transform: translate(3px, 0);
}
@keyframes glitch-1 {
  0%,90%,100% { opacity: 0; transform: translate(-3px,0); }
  92% { opacity: 1; transform: translate(-3px, -2px); }
  95% { opacity: 1; transform: translate(3px, 2px); }
}
@keyframes glitch-2 {
  0%,88%,100% { opacity: 0; transform: translate(3px,0); }
  90% { opacity: 1; transform: translate(3px, 2px); }
  93% { opacity: 1; transform: translate(-3px, -2px); }
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--text-dim);
  line-height: 1.75;
  max-width: 480px;
  margin-bottom: 2rem;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.hero-stats {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border);
}
.stat-num {
  display: block;
  font-family: var(--font-mono);
  font-size: 1.8rem;
  color: var(--cyan);
  line-height: 1;
  margin-bottom: 0.2rem;
}
.stat-label {
  font-size: 0.75rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.stat-divider {
  width: 1px;
  height: 40px;
  background: var(--border);
}

/* ── HERO VISUAL / ORBIT ────────────────────── */
.hero-visual {
  position: relative;
  width: 420px;
  height: 420px;
  margin: 0 auto;
}

.orbit-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid var(--border);
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  animation: spin linear infinite;
}
.ring-1 { width: 320px; height: 320px; animation-duration: 20s; border-color: rgba(0,245,255,0.15); }
.ring-2 { width: 240px; height: 240px; animation-duration: 15s; border-color: rgba(124,58,237,0.2); animation-direction: reverse; }
.ring-3 { width: 160px; height: 160px; animation-duration: 10s; border-color: rgba(0,245,255,0.1); }

@keyframes spin { from { transform: translate(-50%,-50%) rotate(0deg); } to { transform: translate(-50%,-50%) rotate(360deg); } }

.chief-core {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 110px; height: 110px;
  background: radial-gradient(circle, rgba(0,245,255,0.15) 0%, rgba(5,8,16,0.9) 70%);
  border: 2px solid var(--cyan);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 40px rgba(0,245,255,0.3), inset 0 0 20px rgba(0,245,255,0.1);
  animation: chief-pulse 4s ease-in-out infinite;
}
@keyframes chief-pulse {
  0%,100% { box-shadow: 0 0 40px rgba(0,245,255,0.3), inset 0 0 20px rgba(0,245,255,0.1); }
  50%      { box-shadow: 0 0 60px rgba(0,245,255,0.5), inset 0 0 30px rgba(0,245,255,0.2); }
}
.chief-inner { text-align: center; }
.chief-label {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--cyan);
  letter-spacing: 0.2em;
}
.chief-sub {
  font-family: var(--font-mono);
  font-size: 0.45rem;
  color: var(--text-dim);
  letter-spacing: 0.15em;
  margin-top: 2px;
}

/* Orbit agents */
.orbit-agent {
  position: absolute;
  top: 50%; left: 50%;
  width: 44px; height: 44px;
  margin: -22px;
  background: var(--bg2);
  border: 1px solid var(--border-strong);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  animation: orbit-move 20s linear infinite;
  animation-delay: calc((var(--angle, 0deg) / 360deg) * -20s);
  box-shadow: 0 0 12px rgba(0,245,255,0.1);
  transform:
    rotate(var(--angle))
    translateX(160px)
    rotate(calc(-1 * var(--angle)));
}
@keyframes orbit-move {
  from {
    transform:
      rotate(var(--angle))
      translateX(160px)
      rotate(calc(-1 * var(--angle)));
  }
  to {
    transform:
      rotate(calc(var(--angle) + 360deg))
      translateX(160px)
      rotate(calc(-1 * (var(--angle) + 360deg)));
  }
}

/* ── AGENTS SECTION ─────────────────────────── */
.agents {
  padding: 100px 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

/* ── MISSION SIMULATOR ──────────────────────── */
.mission-simulator {
  background: var(--bg2);
  border: 1px solid var(--border);
  margin-bottom: 3rem;
  overflow: hidden;
}

.sim-header {
  padding: 0.9rem 1.5rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bg3);
}
.sim-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--cyan);
  letter-spacing: 0.2em;
}
.sim-hint {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  color: var(--text-dim);
}

.mission-tabs {
  display: flex;
  border-bottom: 1px solid var(--border);
  overflow-x: auto;
  scrollbar-width: none;
}
.mission-tabs::-webkit-scrollbar { display: none; }

.mission-tab {
  background: none;
  border: none;
  border-right: 1px solid var(--border);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  padding: 0.75rem 1.25rem;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
  position: relative;
}
.mission-tab:hover { color: var(--cyan); background: var(--cyan-glow); }
.mission-tab.active {
  color: var(--cyan);
  background: var(--cyan-glow);
}
.mission-tab.active::after {
  content: '';
  position: absolute;
  bottom: -1px; left: 0; right: 0;
  height: 2px;
  background: var(--cyan);
}

.sim-terminal {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid var(--border);
  min-height: 90px;
}
.term-line {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text);
  line-height: 1.8;
}
.term-prompt { color: var(--cyan); margin-right: 0.5rem; }
.term-dim { color: var(--text-dim); }
.term-success { color: var(--green); }
.term-spawn-line {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--violet);
  line-height: 1.7;
  opacity: 0;
  transform: translateX(-8px);
  transition: opacity 0.3s, transform 0.3s;
}
.term-spawn-line.visible { opacity: 1; transform: translateX(0); }

.spawned-agents {
  padding: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  min-height: 80px;
}

.spawned-chip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg3);
  border: 1px solid var(--border-strong);
  padding: 0.5rem 0.9rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--cyan);
  letter-spacing: 0.05em;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity 0.35s, transform 0.35s;
  position: relative;
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 8px 100%, 0 calc(100% - 8px));
}
.spawned-chip.visible { opacity: 1; transform: scale(1); }
.spawned-chip .chip-icon { font-size: 1rem; }
.spawned-chip .chip-status {
  display: inline-block;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--green);
  animation: pulse-green 2s infinite;
  margin-left: 0.3rem;
}

/* ── INFINITE CALLOUT ───────────────────────── */
.infinite-callout {
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto;
  gap: 0 2rem;
  border: 1px solid var(--border);
  padding: 2.5rem;
  background: var(--bg2);
  position: relative;
  overflow: hidden;
}
.infinite-callout::before {
  content: '';
  position: absolute;
  top: -60px; right: -60px;
  width: 200px; height: 200px;
  background: radial-gradient(circle, var(--violet-glow) 0%, transparent 70%);
  pointer-events: none;
}
.inf-icon {
  font-family: var(--font-mono);
  font-size: 3.5rem;
  color: var(--cyan);
  line-height: 1;
  grid-row: 1;
  align-self: center;
  text-shadow: 0 0 20px rgba(0,245,255,0.5);
}
.inf-content {
  grid-column: 2;
  grid-row: 1;
}
.inf-content h3 {
  font-family: var(--font-disp);
  font-size: 1.4rem;
  font-weight: 700;
  color: white;
  margin-bottom: 0.5rem;
}
.inf-content p {
  font-size: 0.92rem;
  color: var(--text-dim);
  line-height: 1.7;
}
.inf-content em { color: var(--cyan); font-style: normal; }
.inf-tags {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.75rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
}
.inf-tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-dim);
  border: 1px solid var(--border);
  padding: 0.3rem 0.75rem;
  letter-spacing: 0.05em;
  transition: all 0.2s;
  cursor: default;
}
.inf-tag:hover { color: var(--cyan); border-color: var(--border-strong); background: var(--cyan-glow); }
.inf-tag.add-more { color: var(--violet); border-color: rgba(124,58,237,0.3); }

/* ── HOW IT WORKS ───────────────────────────── */
.how {
  padding: 100px 2rem;
  max-width: 860px;
  margin: 0 auto;
}

.protocol-steps {
  display: flex;
  flex-direction: column;
  gap: 0;
}
.protocol-step {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 1.5rem;
  padding: 2rem 0;
  border-bottom: 1px solid var(--border);
  position: relative;
  align-items: start;
}
.protocol-step:last-child { border-bottom: none; }
.step-line {
  position: absolute;
  left: 28px;
  top: 3.5rem;
  width: 2px;
  height: calc(100% - 1.5rem);
  background: linear-gradient(to bottom, var(--cyan), transparent);
}
.step-num {
  font-family: var(--font-mono);
  font-size: 2rem;
  color: var(--border-strong);
  line-height: 1;
  padding-top: 0.1rem;
}
.step-content h3 {
  font-family: var(--font-disp);
  font-size: 1.3rem;
  font-weight: 700;
  color: white;
  margin-bottom: 0.5rem;
}
.step-content p {
  color: var(--text-dim);
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ── WAITLIST ───────────────────────────────── */
.waitlist {
  padding: 100px 2rem;
  position: relative;
  text-align: center;
  overflow: hidden;
}
.waitlist-glow {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 600px; height: 400px;
  background: radial-gradient(ellipse, var(--violet-glow) 0%, transparent 70%);
  pointer-events: none;
}
.waitlist-content {
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}
.waitlist-content .section-sub {
  margin: 0 auto 2.5rem;
}

.waitlist-form {
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: 2.5rem;
  text-align: left;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.form-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.form-field label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--cyan);
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
.required { color: var(--red); }
.form-field input {
  background: var(--bg);
  border: 1px solid var(--border);
  color: white;
  font-family: var(--font-body);
  font-size: 0.95rem;
  padding: 0.7rem 0.9rem;
  outline: none;
  transition: border-color 0.2s;
  border-radius: 0;
}
.form-field input:focus {
  border-color: var(--cyan);
  box-shadow: 0 0 0 2px var(--cyan-glow);
}
.form-field input::placeholder { color: var(--text-dim); }

.form-message {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.05em;
  border-left: 2px solid var(--cyan);
  background: var(--cyan-glow);
  color: var(--cyan);
}
.form-message.error {
  border-left-color: var(--red);
  background: rgba(255,51,85,0.1);
  color: var(--red);
}
.form-message.hidden { display: none; }

.form-note {
  margin-top: 1rem;
  font-size: 0.78rem;
  color: var(--text-dim);
  text-align: center;
}

/* Loader spinner */
.loader {
  width: 16px; height: 16px;
  border: 2px solid rgba(5,8,16,0.3);
  border-top-color: var(--bg);
  border-radius: 50%;
  animation: spin-loader 0.7s linear infinite;
}
.loader.hidden { display: none; }
@keyframes spin-loader { to { transform: rotate(360deg); } }

/* ── FOOTER ─────────────────────────────────── */
.footer {
  border-top: 1px solid var(--border);
  padding: 2rem;
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.footer-copy {
  font-size: 0.8rem;
  color: var(--text-dim);
}
.footer-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--green);
  letter-spacing: 0.1em;
}

/* ── RESPONSIVE ─────────────────────────────── */
@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 100px;
    text-align: center;
  }
  .hero-eyebrow, .hero-actions, .hero-stats { justify-content: center; }
  .hero-sub { margin: 0 auto 2rem; }
  .hero-visual { display: none; }
  .form-row { grid-template-columns: 1fr; }
  .footer-inner { justify-content: center; text-align: center; }
  .nav-links a:not(.nav-cta) { display: none; }
}
@media (max-width: 600px) {
  .hero-actions { flex-direction: column; align-items: center; }
  .btn-primary, .btn-ghost { width: 100%; justify-content: center; }
  .agent-grid { grid-template-columns: 1fr; }
}
