:root {
  --bg: #0d0d1a;
  --bg-surface: #141427;
  --bg-card: #1a1a32;
  --fg: #f0f0f5;
  --fg-muted: #8888aa;
  --accent: #ff5c35;
  --accent-dim: rgba(255, 92, 53, 0.15);
  --border: rgba(255,255,255,0.08);
  --terminal-green: #4ade80;
  --terminal-info: #60a5fa;
  --terminal-warn: #fbbf24;
  --terminal-dim: #555577;
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
}

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

html { font-size: 16px; scroll-behavior: smooth; }


body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* NAVBAR */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(13,13,26,0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nav-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--fg);
  letter-spacing: -0.02em;
}
.nav-tagline {
  font-size: 0.8rem;
  color: var(--fg-muted);
  font-family: var(--font-body);
}

/* HERO */
.hero {
  max-width: 1100px;
  margin: 0 auto;
  padding: 5rem 2rem 4rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}
.hero-eyebrow {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 1.25rem;
  font-family: var(--font-body);
}
.hero-headline {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 5vw, 3.8rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 1.5rem;
}
.hero-sub {
  font-size: 1.05rem;
  color: var(--fg-muted);
  max-width: 440px;
  line-height: 1.7;
}

/* TERMINAL */
.terminal {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 24px 48px rgba(0,0,0,0.4), 0 0 0 1px rgba(255,92,53,0.1);
}
.terminal-header {
  background: var(--bg-card);
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-bottom: 1px solid var(--border);
}
.dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.red { background: #ff5f57; }
.dot.yellow { background: #febc2e; }
.dot.green { background: #28c840; }
.terminal-title {
  font-size: 0.7rem;
  color: var(--fg-muted);
  margin-left: auto;
  font-family: 'SF Mono', 'Fira Code', monospace;
}
.terminal-body {
  padding: 1.25rem 1.25rem 1.5rem;
  font-family: 'SF Mono', 'Fira Code', 'Courier New', monospace;
  font-size: 0.78rem;
  line-height: 1.8;
}
.t-line { margin-bottom: 0.1rem; }
.t-info { color: var(--terminal-info); }
.t-ok { color: var(--terminal-green); }
.t-wait { color: var(--terminal-warn); }
.t-cursor {
  color: var(--accent);
  animation: blink 1.1s step-end infinite;
  margin-top: 0.25rem;
}
@keyframes blink { 0%, 100% { opacity:1; } 50% { opacity:0; } }

/* HOW IT WORKS */
.howitworks {
  max-width: 1100px;
  margin: 0 auto;
  padding: 5rem 2rem;
  border-top: 1px solid var(--border);
}
.section-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 1.25rem;
}
.section-headline {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 4rem;
  line-height: 1.1;
}
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}
.step-num {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--accent-dim);
  line-height: 1;
  margin-bottom: 0.75rem;
  letter-spacing: -0.04em;
}
.step h3 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 0.5rem;
}
.step p {
  font-size: 0.9rem;
  color: var(--fg-muted);
  line-height: 1.65;
}

/* FEATURES */
.features {
  max-width: 1100px;
  margin: 0 auto;
  padding: 5rem 2rem;
  border-top: 1px solid var(--border);
}
.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.feature-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.75rem;
  transition: border-color 0.2s;
}
.feature-card:hover { border-color: var(--accent); }
.feature-icon {
  color: var(--accent);
  margin-bottom: 1rem;
}
.feature-card h3 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 0.5rem;
}
.feature-card p {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.65;
}

/* OUTCOMES */
.outcomes {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 5rem 2rem;
}
.outcomes-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.outcomes-headline {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--fg);
  line-height: 1.1;
  margin-bottom: 3.5rem;
}
.outcomes-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}
.stat { border-left: 2px solid var(--accent); padding-left: 1.5rem; }
.stat-val {
  font-family: var(--font-display);
  font-size: 2.8rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.04em;
  line-height: 1;
  margin-bottom: 0.5rem;
}
.stat-label {
  font-size: 0.875rem;
  color: var(--fg-muted);
  line-height: 1.4;
}

/* CLOSING */
.closing {
  max-width: 1100px;
  margin: 0 auto;
  padding: 6rem 2rem 5rem;
  text-align: center;
}
.closing-headline {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
  font-weight: 800;
  color: var(--fg);
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
  line-height: 1.15;
}
.closing-sub {
  font-size: 1rem;
  color: var(--fg-muted);
  max-width: 560px;
  margin: 0 auto;
  line-height: 1.75;
}

/* FOOTER */
footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 2rem;
}
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.footer-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--fg);
}
.footer-copy {
  font-size: 0.8rem;
  color: var(--fg-muted);
  max-width: 380px;
  text-align: right;
}

/* NAV LINKS */
.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}
.nav-link {
  font-size: 0.875rem;
  color: var(--fg-muted);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.15s;
}
.nav-link:hover { color: var(--fg); }
.nav-link--accent {
  color: var(--accent);
  border: 1px solid var(--accent);
  padding: 0.35rem 0.9rem;
  border-radius: 6px;
  font-weight: 600;
}
.nav-link--accent:hover {
  background: var(--accent-dim);
  color: var(--accent);
}

/* RESEARCH PAGE */
.research-hero {
  max-width: 1100px;
  margin: 0 auto;
  padding: 5rem 2rem 3.5rem;
  border-bottom: 1px solid var(--border);
}
.research-hero-inner { max-width: 720px; }
.research-eyebrow {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 1.25rem;
}
.research-headline {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: var(--fg);
  margin-bottom: 1rem;
}
.research-sub {
  font-size: 1rem;
  color: var(--fg-muted);
  line-height: 1.75;
  margin-bottom: 2.5rem;
}
.icp-form { display: flex; flex-direction: column; gap: 1rem; }
.icp-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.icp-field { display: flex; flex-direction: column; gap: 0.4rem; }
.icp-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--fg-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.icp-input {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.7rem 1rem;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.15s;
}
.icp-input:focus { border-color: var(--accent); }
.icp-input::placeholder { color: var(--fg-muted); opacity: 0.6; }
.icp-btn {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 0.8rem 1.75rem;
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  align-self: flex-start;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: opacity 0.15s;
}
.icp-btn:hover { opacity: 0.88; }
.icp-btn:disabled { opacity: 0.5; cursor: not-allowed; }
.icp-spinner {
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* RESULTS */
.results-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 3rem 2rem 5rem;
}
.results-inner { max-width: 720px; }
.results-header {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 2rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border);
}
.results-title {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--fg);
}
.results-meta {
  font-size: 0.8rem;
  color: var(--fg-muted);
}
.results-list { display: flex; flex-direction: column; gap: 0.75rem; }
.result-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 1.25rem;
  transition: border-color 0.15s;
}
.result-card:hover { border-color: rgba(255,92,53,0.3); }
.result-rank {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--accent);
  opacity: 0.6;
  min-width: 28px;
  line-height: 1.3;
}
.result-body { flex: 1; min-width: 0; }
.result-name {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--fg);
  margin-bottom: 0.2rem;
}
.result-site {
  font-size: 0.8rem;
  color: var(--terminal-info);
  text-decoration: none;
  display: block;
  margin-bottom: 0.4rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.result-site:hover { text-decoration: underline; }
.result-reason {
  font-size: 0.85rem;
  color: var(--fg-muted);
  line-height: 1.5;
}

/* ERROR */
.error-msg {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 2rem 3rem;
}
.error-inner {
  background: rgba(239,68,68,0.1);
  border: 1px solid rgba(239,68,68,0.3);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  color: #fca5a5;
  font-size: 0.875rem;
}

/* MOBILE */
@media (max-width: 768px) {
  .hero { grid-template-columns: 1fr; padding: 3rem 1.5rem 2.5rem; gap: 2.5rem; }
  .hero-headline { font-size: 2.4rem; }
  .steps { grid-template-columns: 1fr 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .outcomes-stats { grid-template-columns: 1fr; gap: 1.5rem; }
  .footer-inner { flex-direction: column; gap: 1rem; text-align: center; }
  .footer-copy { text-align: center; }
  .section-headline { font-size: 2rem; }
  .howitworks, .features, .closing { padding: 3.5rem 1.5rem; }
  .outcomes { padding: 3.5rem 1.5rem; }
}
@media (max-width: 480px) {
  .steps { grid-template-columns: 1fr; }
}