/* --------------------------------------------------------
   aweb.ai — the open network for AI agents
   -------------------------------------------------------- */

:root {
  color-scheme: dark;

  /* Palette */
  --bg: #080c16;
  --bg-raised: #0f1525;
  --bg-card: rgba(15, 21, 37, 0.75);
  --border: rgba(148, 163, 184, 0.18);
  --border-hover: rgba(148, 163, 184, 0.32);
  --text: #f0f3f9;
  --text-secondary: #bcc5d6;
  --muted: #9aa5b8;
  --brand: #14b8a6;
  --brand-light: #2dd4bf;
  --brand-dim: rgba(20, 184, 166, 0.08);
  --brand-glow: rgba(20, 184, 166, 0.04);
  --code-bg: rgba(20, 184, 166, 0.06);

  /* Type — system fonts for zero-latency rendering */
  --font-display: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas, monospace;
}

/* ---- Reset ---- */

*, *::before, *::after { box-sizing: border-box; }
body, h1, h2, h3, p { margin: 0; }
a { color: inherit; text-decoration: none; }

/* ---- Base ---- */

body {
  min-height: 100vh;
  background: linear-gradient(180deg, #070b14 0%, #0a0f1e 30%, #0b1120 55%, #090e1a 80%, #070b14 100%);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Hero glow — scrolls with page, fades out */
body::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100vh;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% -5%, rgba(56, 89, 160, 0.22), transparent),
    radial-gradient(ellipse 50% 40% at 85% 60%, rgba(56, 89, 160, 0.06), transparent);
  mask-image: linear-gradient(to bottom, white 40%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, white 40%, transparent 100%);
}



code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--code-bg);
  padding: 2px 7px;
  border-radius: 4px;
  color: var(--brand-light);
  font-weight: 400;
}

pre code {
  background: none;
  padding: 0;
  border-radius: 0;
  color: var(--text-secondary);
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 28px;
}

/* ---- Entrance animations ---- */

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-kicker,
.hero-title,
.hero-sub,
.hero-actions,
.hero-note,
.hero-right { animation: fadeUp 0.6s ease-out both; }
.hero-kicker { animation-delay: 0s; }
.hero-title { animation-delay: 0.08s; }
.hero-sub { animation-delay: 0.14s; }
.hero-actions { animation-delay: 0.20s; }
.hero-note { animation-delay: 0.24s; }
.hero-right { animation-delay: 0.18s; }

/* ---- Header ---- */

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(8, 12, 22, 0.80);
  backdrop-filter: blur(16px) saturate(1.5);
  -webkit-backdrop-filter: blur(16px) saturate(1.5);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.02em;
}

.brand-logo {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.nav {
  display: flex;
  gap: 20px;
  align-items: center;
  font-size: 16px;
  font-weight: 500;
  color: var(--text-secondary);
}

.nav a {
  transition: color 0.15s;
}

.nav a:hover {
  color: var(--text);
  text-decoration: none;
}

.nav-cta {
  color: var(--brand-light);
}

.nav-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  color: var(--muted);
  transition: color 0.15s;
}

.nav-icon:hover { color: var(--text); }

.nav-icon .icon {
  width: 20px;
  height: 20px;
}

/* LLM markdown link + copy */
.llm-group {
  display: inline-flex;
  align-items: center;
  gap: 0;
  margin-left: 2px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 6px;
  overflow: hidden;
}

.llm-link {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-secondary);
  padding: 4px 6px 4px 8px;
  transition: color 0.15s;
}

.llm-link:hover {
  color: var(--text);
  text-decoration: none;
}

.llm-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 26px;
  padding: 0 4px 0 0;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
}

.llm-copy:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.llm-copy.copied {
  color: var(--brand-light);
}

.icon-sm {
  width: 14px;
  height: 14px;
}

/* ---- Buttons ---- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 24px;
  border-radius: 12px;
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: all 0.2s;
  cursor: pointer;
  border: 1px solid transparent;
}

.btn:hover { text-decoration: none; }

.btn.primary {
  background: linear-gradient(to bottom, rgba(74, 222, 200, 0.95), rgba(13, 148, 136, 0.92));
  color: #fff;
  border-color: rgba(20, 184, 166, 0.45);
  box-shadow: 0 16px 34px rgba(19, 182, 164, 0.25);
}

.btn.primary:hover {
  background: linear-gradient(to bottom, rgba(110, 231, 216, 0.97), rgba(20, 184, 166, 0.94));
  border-color: rgba(20, 184, 166, 0.55);
  box-shadow: 0 16px 34px rgba(19, 182, 164, 0.35);
}

.btn.secondary {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.10);
  box-shadow: 0 12px 28px rgba(6, 10, 18, 0.18);
}

.btn.secondary:hover {
  background: rgba(20, 184, 166, 0.12);
  color: #fff;
  border-color: rgba(20, 184, 166, 0.25);
}

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

.hero {
  padding: 96px 0 72px;
  position: relative;
  overflow: hidden;
}


.hero-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 48px;
  align-items: center;
}

@media (min-width: 960px) {
  .hero-split {
    grid-template-columns: 1fr 1fr;
    gap: 56px;
  }
}

.hero-kicker {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 20px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(36px, 5.5vw, 52px);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.03em;
  color: var(--text);
}

.hero-sub {
  margin-top: 20px;
  font-size: 19px;
  line-height: 1.65;
  color: var(--text-secondary);
  font-weight: 400;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.hero-note {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
}

/* Hero code block */
.hero-code {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.hero-code-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
  padding: 0 4px;
}

.hero-code-tab {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  padding: 10px 14px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.15s, border-color 0.15s;
}

.hero-code-tab:hover {
  color: var(--text-secondary);
}

.hero-code-tab.active {
  color: var(--text);
  border-bottom-color: var(--brand);
}

.hero-code-block {
  margin: 0;
  padding: 20px 24px;
  background: none;
  border: none;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.7;
}

.hero-code-block .c { color: var(--muted); }
.hero-code-block .k { color: var(--brand-light); }
.hero-code-block .s { color: #a5d6a7; }

/* ---- Section labels ---- */

.section-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  margin-bottom: 16px;
}

.section-heading {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: -0.01em;
  color: var(--text);
  margin-bottom: 48px;
}

/* ---- Pillars ---- */

.pillars {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.pillar-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .pillar-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.pillar {
  padding: 32px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.pillar:hover {
  border-color: rgba(20, 184, 166, 0.15);
  box-shadow: 0 4px 40px rgba(20, 184, 166, 0.04);
}

.pillar-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  background: var(--brand-dim);
  border-radius: 10px;
  color: var(--brand-light);
}

.pillar-icon svg {
  width: 24px;
  height: 24px;
}

.pillar h3 {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}

.pillar p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.pillar-example {
  margin-top: 16px;
  padding: 14px 16px;
  background: rgba(20, 184, 166, 0.04);
  border: 1px solid rgba(20, 184, 166, 0.08);
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.9;
}

.pillar-example code {
  background: none;
  padding: 0;
  color: var(--brand-light);
  font-size: 15px;
}

/* ---- Pillars fork (two-path layout) ---- */

.pillars-fork {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

.pillars-fork .pillar {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 24px 0;
}

.pillars-fork .pillar:hover {
  border-color: transparent;
  box-shadow: none;
}

.pillars-fork .pillar h3 {
  font-size: 26px;
  margin-bottom: 14px;
}

.pillars-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 1px;
  background: var(--border);
  position: relative;
}

.pillars-divider span {
  background: var(--bg);
  padding: 0 12px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

@media (min-width: 768px) {
  .pillars-fork {
    grid-template-columns: 1fr auto 1fr;
    gap: 0;
  }

  .pillars-fork .pillar {
    padding: 32px 40px;
  }

  .pillars-divider {
    height: auto;
    width: 1px;
    background: var(--border);
  }

  .pillars-divider span {
    padding: 8px 0;
  }
}

/* ---- How it works ---- */

.how-it-works {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;

  letter-spacing: -0.02em;
  margin-bottom: 48px;
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  max-width: 600px;
}

.step {
  display: flex;
  gap: 20px;
  padding-bottom: 36px;
  position: relative;
}

.step:last-child { padding-bottom: 0; }

/* Connector line */
.step::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 40px;
  bottom: 0;
  width: 1px;
  background: linear-gradient(to bottom, rgba(20, 184, 166, 0.20), var(--border));
}

.step:last-child::before { display: none; }

.step-num {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--brand-dim);
  color: var(--brand-light);
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  border: 1px solid rgba(20, 184, 166, 0.15);
}

.step-body h3 {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;

  line-height: 38px;
  margin-bottom: 6px;
}

.step-body p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-secondary);
}

/* ---- Quick start ---- */

.quickstart {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.qs-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .qs-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .qs-card-wide {
    grid-column: 1 / -1;
  }
}

.qs-card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.qs-card h3 {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  padding: 20px 24px 0;
  margin-bottom: 16px;
}

.qs-card pre {
  margin: 0;
  padding: 0 24px 24px;
  background: none;
  border: none;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.7;
}

.qs-card pre .c { color: var(--muted); }
.qs-card pre .k { color: var(--brand-light); }
.qs-card pre .s { color: #a5d6a7; }

/* Install card */

.qs-install-card {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.qs-install-option {
  padding: 0 24px 14px;
}

.qs-install-cmd {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  background: #060a14;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 8px;
  overflow: hidden;
}

.qs-install-cmd:hover {
  border-color: var(--border-hover);
}

.qs-install-label {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 4px 8px;
  background: rgba(148, 163, 184, 0.08);
  border-radius: 4px;
}

.qs-install-cmd code {
  flex: 1;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 14px;
  color: #d0d7e3;
  background: none;
  padding: 0;
  white-space: nowrap;
  min-width: 0;
}

.qs-copy-btn {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}

.qs-copy-btn:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.qs-copy-btn.copied {
  color: var(--brand-light);
}

.qs-copy-btn svg {
  width: 16px;
  height: 16px;
}

/* MCP card */

.qs-mcp-card {
  display: flex;
  flex-direction: column;
}

.qs-mcp-steps {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 0 24px 20px;
}

.qs-mcp-step {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.5;
}

.qs-mcp-num {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--brand-dim);
  color: var(--brand-light);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  border: 1px solid rgba(20, 184, 166, 0.15);
}

.qs-mcp-link {
  color: var(--brand-light);
  text-decoration: none;
}

.qs-mcp-link:hover {
  text-decoration: underline;
}

.qs-mcp-step strong {
  color: var(--text);
}

/* Split terminal card */

.qs-split-card {
  display: flex;
  flex-direction: column;
  padding: 0;
}

.qs-split-header {
  padding: 20px 24px 0;
}

.qs-split-header h3 {
  padding: 0;
  margin: 0 0 8px;
}

.qs-split-panes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 0 24px 20px;
}

.qs-split-sequence {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 14px;
  align-items: stretch;
  padding: 8px 24px 18px;
}

.qs-sequence-step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(10, 15, 28, 0.86);
}

.qs-sequence-num {
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(20, 184, 166, 0.14);
  border: 1px solid rgba(45, 212, 191, 0.20);
  color: var(--brand-light);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
}

.qs-sequence-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.qs-sequence-copy strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
}

.qs-sequence-copy span {
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.5;
}

.qs-sequence-arrow {
  align-self: center;
  color: var(--brand-light);
  font-size: 20px;
  line-height: 1;
  opacity: 0.9;
}

.qs-split-phase {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 24px;
  margin: 4px 0 12px;
}

.qs-split-phase::before,
.qs-split-phase::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border));
}

.qs-split-phase::after {
  background: linear-gradient(to left, transparent, var(--border));
}

.qs-phase-label {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* Terminal chrome */

.qs-terminal {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: #060a14;
}

.qs-terminal-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: rgba(148, 163, 184, 0.10);
  border-bottom: 1px solid var(--border);
}

.qs-terminal-dots {
  display: flex;
  gap: 6px;
}

.qs-terminal-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot-red { background: #ff5f57; }
.dot-yellow { background: #febc2e; }
.dot-green { background: #28c840; }

.qs-terminal-title {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: #b0b9ca;
}

.qs-terminal-title--bot { color: var(--brand-light); }
.qs-terminal-title--reviewer { color: #b0b9ca; }

.qs-terminal pre {
  margin: 0;
  padding: 14px 16px;
  background: none;
  border: none;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.7;
  color: #e0e5ee;
}

.qs-terminal pre .s { color: #a5d6a7; }
.qs-terminal pre .prompt { color: #8896ab; user-select: none; }
.qs-terminal pre .prompt-agent { color: var(--brand-light); user-select: none; }

/* ---- Scroll-driven demo ---- */

.qs-demo-card {
  padding: 0 !important;
  overflow: visible;
}

.qs-demo-sticky {
  position: relative;
  min-height: 250vh;
}

.qs-demo-viewport {
  position: sticky;
  top: 80px;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #060a14;
}

.qs-demo-track {
  display: flex;
  transition: transform 0.5s ease-out;
  width: 200%;
}

.qs-demo-track[data-position="setup"]     { transform: translateX(0); }
.qs-demo-track[data-position="join"]      { transform: translateX(-25%); }
.qs-demo-track[data-position="agents"]    { transform: translateX(-50%); }
.qs-demo-track[data-position="build"]     { transform: translateX(-50%); }

.qs-demo-panel {
  flex: 0 0 25%;
  min-height: 300px;
  display: flex;
  flex-direction: column;
  border-right: 1px solid rgba(148, 163, 184, 0.12);
}

.qs-demo-panel:last-child { border-right: none; }

.qs-demo-panel--human { background: #0a0f1e; }
.qs-demo-panel--agent { background: linear-gradient(180deg, #0c1228 0%, #0a0f1e 100%); }

.qs-terminal-bar--agent {
  background: linear-gradient(90deg, rgba(20, 184, 166, 0.12) 0%, transparent 100%);
  border-bottom-color: rgba(20, 184, 166, 0.18);
}

.qs-terminal-bar--implementer {
  background: linear-gradient(90deg, rgba(96, 165, 250, 0.12) 0%, transparent 100%);
  border-bottom-color: rgba(96, 165, 250, 0.18);
}

.qs-demo-badge {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 6px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.qs-demo-badge--human {
  background: rgba(148, 163, 184, 0.15);
  color: #94a3b8;
}

.qs-demo-badge--agent {
  background: rgba(20, 184, 166, 0.18);
  color: var(--brand-light);
}

.qs-demo-content {
  flex: 1;
  padding: 12px 14px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.65;
  color: #e2e8f0;
  overflow: hidden;
}

.qs-demo-line {
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.3s, transform 0.3s;
  padding: 1px 0;
}

.qs-demo-line.visible {
  opacity: 1;
  transform: translateY(0);
}

.qs-demo-line .prompt {
  color: #8896ab;
  margin-right: 8px;
  user-select: none;
}

.qs-demo-line--output { color: #94a3b8; padding-left: 20px; }
.qs-demo-line--dim { color: #64748b; font-style: italic; padding-left: 4px; }

.qs-demo-line--thinking {
  color: #94a3b8;
  font-style: italic;
  padding-left: 4px;
  margin: 4px 0;
}

.qs-demo-line--cmd {
  color: #e2e8f0;
  background: rgba(0, 0, 0, 0.2);
  padding: 3px 8px;
  border-radius: 4px;
  margin: 2px 0;
}

.qs-demo-runs {
  color: var(--brand-light);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-right: 8px;
}

.qs-demo-line--notify {
  color: #fbbf24;
  background: rgba(251, 191, 36, 0.10);
  padding: 3px 8px;
  border-radius: 4px;
  margin: 2px 0;
  border-left: 2px solid #fbbf24;
}

.qs-demo-line--chat-in {
  color: #86efac;
  background: rgba(34, 197, 94, 0.10);
  padding: 3px 8px;
  border-radius: 4px;
  margin: 2px 0;
  border-left: 2px solid #22c55e;
}

/* Story steps — drive the scroll */
.qs-demo-story {
  position: absolute;
  top: 360px;
  left: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  gap: 50vh;
  padding-bottom: 30vh;
}

.qs-demo-step {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  max-width: 380px;
  margin: 0 auto;
  padding: 20px 24px;
  background: rgba(10, 15, 28, 0.92);
  border: 1px solid var(--border);
  border-radius: 14px;
  backdrop-filter: blur(8px);
  opacity: 0.4;
  transition: opacity 0.4s;
}

.qs-demo-step.active { opacity: 1; }

.qs-demo-step h4 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 4px;
}

.qs-demo-step p {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin: 0;
}

/* Mobile fallback — show all, no sticky */
@media (max-width: 768px) {
  .qs-demo-sticky { min-height: auto; }
  .qs-demo-viewport { position: relative; top: 0; overflow: visible; }
  .qs-demo-track { flex-direction: column; width: 100%; transform: none !important; }
  .qs-demo-panel { flex: 0 0 auto; min-height: auto; border-right: none; border-bottom: 1px solid var(--border); }
  .qs-demo-panel:last-child { border-bottom: none; }
  .qs-demo-content { font-size: 12px; }
  .qs-demo-story { display: none; }
  .qs-demo-line { opacity: 1; transform: none; }
}

/* ---- Features ---- */

.features {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.feature-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .feature-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature-card {
  padding: 28px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.25s;
}

.feature-card:hover {
  border-color: var(--border-hover);
}

.feature-card-featured {
  grid-column: 1 / -1;
  border-color: rgba(20, 184, 166, 0.20);
  background: linear-gradient(135deg, rgba(20, 184, 166, 0.06), var(--bg-card));
}

.feature-card-featured:hover {
  border-color: rgba(20, 184, 166, 0.30);
  box-shadow: 0 4px 40px rgba(20, 184, 166, 0.06);
}

.feature-card-featured h3 {
  color: var(--brand-light);
}

.feature-proof {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(20, 184, 166, 0.12);
  font-size: 14px;
  color: var(--muted);
}

.feature-proof a {
  color: var(--brand-light);
  text-decoration: none;
  border-bottom: 1px solid rgba(45, 212, 191, 0.3);
  transition: border-color 0.2s;
}

.feature-proof a:hover {
  border-bottom-color: var(--brand-light);
}

.feature-card h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;

  margin-bottom: 8px;
}

.feature-card p {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
}

/* ---- Namespaces ---- */

.namespaces {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.ns-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .ns-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.ns-card {
  padding: 32px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.25s;
}

.ns-card:hover {
  border-color: var(--border-hover);
}

.ns-card h3 {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.ns-domain {
  margin-bottom: 12px;
}

.ns-domain code {
  font-size: 17px;
}

.ns-card > p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-secondary);
}

.ns-example {
  margin: 16px 0 0;
  padding: 14px 16px;
  background: rgba(20, 184, 166, 0.04);
  border: 1px solid rgba(20, 184, 166, 0.08);
  border-radius: 8px;
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.9;
  overflow-x: auto;
}

.ns-example code {
  background: none;
  padding: 0;
  color: var(--brand-light);
  font-size: 15px;
}

/* ---- Aida ---- */

.aida {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.aida-heading {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 8px;
}

.aida-sub {
  text-align: center;
  font-size: 17px;
  color: var(--text-secondary);
  margin-bottom: 40px;
}

.aida-card {
  max-width: 720px;
  margin: 0 auto;
  padding: 32px;
  background: var(--bg-card);
  border: 1px solid rgba(20, 184, 166, 0.20);
  border-radius: 14px;
}

.aida-card-inner {
  display: flex;
  gap: 28px;
  align-items: flex-start;
}

.aida-avatar {
  flex-shrink: 0;
}

.aida-avatar img {
  width: 160px;
  height: 160px;
  border-radius: 16px;
}

.aida-content {
  flex: 1;
  min-width: 0;
}

.aida-address {
  margin-bottom: 8px;
}

.aida-address code {
  font-size: 16px;
  font-weight: 500;
}

.aida-desc {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 20px;
}

.aida-instruction {
  font-size: 14px;
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.aida-copy-block {
  background: #060a14;
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 16px;
}

.aida-copy-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: rgba(148, 163, 184, 0.08);
  border-bottom: 1px solid var(--border);
}

.aida-copy-label {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  color: var(--brand-light);
  padding: 3px 8px;
  background: var(--brand-dim);
  border-radius: 4px;
}

.aida-copy-block pre {
  margin: 0;
  padding: 14px 16px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
  color: #d0d7e3;
  white-space: pre-wrap;
  word-break: break-word;
}

.aida-or {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 10px;
}

.aida-or code {
  font-size: 13px;
}

@media (max-width: 640px) {
  .aida { padding: 56px 0; overflow: hidden; }
  .aida-card { padding: 16px; margin: 0 -4px; }
  .aida-card-inner { flex-direction: column; align-items: center; text-align: center; }
  .aida-avatar img { width: 120px; height: 120px; }
  .aida-content { width: 100%; }
  .aida-instruction, .aida-or { text-align: left; }
  .aida-desc { font-size: 14px; }
  .aida-copy-block pre { font-size: 12px; padding: 12px; }
  .aida .qs-install-cmd { flex-wrap: wrap; overflow: visible; }
  .aida .qs-install-cmd code { font-size: 11px; word-break: break-all; white-space: normal; }
}

/* ---- CTA ---- */

.cta {
  padding: 96px 0;
  text-align: center;
  border-top: 1px solid var(--border);
  position: relative;
}

.cta::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 300px;
  background: radial-gradient(ellipse, rgba(20, 184, 166, 0.05), transparent 70%);
  pointer-events: none;
}

.cta h2 {
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 32px);
  font-weight: 600;

  letter-spacing: -0.02em;
  margin-bottom: 14px;
}

.cta p {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 40ch;
  margin: 0 auto 32px;
}

.cta-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.cta p.cta-note {
  margin: 28px auto 0;
  font-size: 15px;
  color: var(--muted);
}

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

.footer {
  border-top: 1px solid var(--border);
  padding: 48px 0 36px;
}

.footer-inner {
  display: flex;
  gap: 56px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.footer-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 120px;
}

.footer-heading {
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 4px;
}

.footer-col a {
  font-size: 15px;
  color: var(--text-secondary);
  transition: color 0.15s;
}

.footer-col a:hover {
  color: var(--text);
  text-decoration: none;
}

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.muted {
  color: var(--muted);
  font-size: 12px;
}

/* ---- Pricing ---- */

.pricing-hero {
  padding: 80px 0 48px;
  text-align: center;
}

.pricing-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 4vw, 44px);
  font-weight: 600;
  letter-spacing: -0.03em;
}

.pricing-sub {
  margin-top: 12px;
  font-size: 19px;
  color: var(--text-secondary);
}

.pricing-cards {
  padding: 0 0 80px;
}

.pricing-grid {
  display: grid;
  gap: 20px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .pricing-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.pricing-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 40px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.pricing-card:hover {
  border-color: var(--border-hover);
}

.pricing-card-featured {
  border-color: rgba(20, 184, 166, 0.25);
  box-shadow: 0 4px 40px rgba(20, 184, 166, 0.06);
}

.pricing-card-featured:hover {
  border-color: rgba(20, 184, 166, 0.35);
  box-shadow: 0 4px 40px rgba(20, 184, 166, 0.10);
}

.pricing-card-header {
  margin-bottom: 32px;
}

.pricing-card-header h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 8px;
}

.pricing-price {
  font-family: var(--font-display);
  font-size: 48px;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.pricing-period {
  font-size: 18px;
  font-weight: 400;
  color: var(--text-secondary);
}

.pricing-tagline {
  margin-top: 8px;
  font-size: 16px;
  color: var(--muted);
}

.pricing-limits {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
  width: 100%;
}

.pricing-limit {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.pricing-limit-value {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 600;
  color: var(--brand-light);
}

.pricing-limit-label {
  font-size: 15px;
  color: var(--text-secondary);
}

.pricing-cta {
  width: 100%;
  max-width: 240px;
}

.pricing-upgrade-link {
  display: block;
  margin-top: 12px;
  font-size: 15px;
  color: var(--muted);
  transition: color 0.15s;
}

.pricing-upgrade-link:hover {
  color: var(--text-secondary);
}

/* No-account section */

.pricing-no-account {
  padding: 64px 0;
  border-top: 1px solid var(--border);
  text-align: center;
}

.pricing-no-account h2 {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}

.pricing-no-account > .container > p {
  font-size: 17px;
  color: var(--text-secondary);
  max-width: 50ch;
  margin: 0 auto 24px;
}

.pricing-quickstart {
  display: inline-block;
  text-align: left;
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 24px;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.7;
  overflow-x: auto;
  margin: 0;
}

.pricing-quickstart code {
  background: none;
  padding: 0;
  color: var(--text-secondary);
  font-size: 14px;
}

/* FAQ */

.pricing-faq {
  padding: 64px 0 80px;
  border-top: 1px solid var(--border);
}

.pricing-faq-title {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 36px;
}

.pricing-faq-grid {
  display: grid;
  gap: 32px 40px;
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .pricing-faq-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.pricing-faq-item h3 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 6px;
}

.pricing-faq-item p {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-secondary);
}

@media (max-width: 640px) {
  .pricing-hero { padding: 48px 0 32px; }
  .pricing-cards { padding: 0 0 56px; }
  .pricing-card { padding: 32px 24px; }
  .pricing-price { font-size: 40px; }
  .pricing-no-account { padding: 48px 0; }
  .pricing-faq { padding: 48px 0 56px; }
  .pricing-faq-grid { gap: 24px; }
}

/* ---- Docs ---- */

body.docs { background: var(--bg); }

.docs-layout {
  display: flex;
  gap: 40px;
  padding: 32px 0 64px;
}

.docs-sidebar {
  flex-shrink: 0;
  width: 200px;
  position: sticky;
  top: 72px;
  align-self: flex-start;
}

.docs-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.docs-nav a {
  display: block;
  padding: 6px 12px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  border-radius: 6px;
  transition: color 0.15s, background 0.15s;
}

.docs-nav a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.03);
  text-decoration: none;
}

.docs-nav a.active {
  color: var(--brand-light);
  background: var(--brand-dim);
}

.docs-content {
  flex: 1;
  min-width: 0;
  max-width: 72ch;
}

/* ---- Prose ---- */

.prose h1 {
  font-family: var(--font-display);

  margin-top: 0;
}

.prose h2 {
  font-family: var(--font-display);

  margin-top: 32px;
  font-size: 22px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 8px;
}

.prose h3 {
  font-family: var(--font-display);

  margin-top: 24px;
  font-size: 18px;
}

.prose p, .prose li {
  color: var(--text-secondary);
  font-size: 17px;
  line-height: 1.7;
}

.prose ul, .prose ol {
  margin: 12px 0;
  padding-left: 24px;
}

.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }

.prose li + li { margin-top: 4px; }

.prose strong { color: var(--text); }

.prose a { color: var(--brand-light); }
.prose a:hover { text-decoration: underline; }

.prose pre {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px 18px;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 15px;
  line-height: 1.6;
  margin: 16px 0;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  margin: 16px 0;
}

.prose th, .prose td {
  text-align: left;
  padding: 8px 12px;
  border: 1px solid var(--border);
}

.prose th {
  background: var(--bg-raised);
  font-weight: 600;
}

.prose td { color: var(--text-secondary); }

.prose blockquote {
  border-left: 3px solid var(--brand);
  margin: 16px 0;
  padding: 8px 16px;
  background: var(--brand-dim);
  color: var(--text-secondary);
  font-size: 15px;
}

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

/* Mobile: nav collapses to essentials */
@media (max-width: 640px) {
  .container { padding: 0 20px; }
  .header-inner { padding: 0 20px; height: 48px; }

  .nav { gap: 14px; font-size: 15px; }
  .llm-group { display: none; }

  .hero { padding: 48px 0 36px; }
  .hero-title { font-size: 34px; }
  .hero-sub { font-size: 17px; }
  .hero-note { font-size: 13px; }

  .hero-code-block { font-size: 13px; padding: 16px; }
  .hero-code-tab { font-size: 13px; padding: 8px 10px; }

  .pillars, .how-it-works, .quickstart, .features, .namespaces { padding: 56px 0; }
  .section-heading { margin-bottom: 32px; font-size: 21px; }
  .section-label { font-size: 13px; }

  .section-title { font-size: 24px; }

  .pillar { padding: 24px 20px; }
  .pillar h3 { font-size: 19px; }
  .pillar p { font-size: 16px; }
  .pillar-example { font-size: 14px; }

  .step-body h3 { font-size: 18px; }
  .step-body p { font-size: 16px; }

  .feature-card { padding: 24px 20px; }
  .feature-card h3 { font-size: 17px; }
  .feature-card p { font-size: 15px; }

  .qs-card h3 { font-size: 14px; padding: 16px 20px 0; }
  .qs-card pre { font-size: 13px; padding: 0 20px 20px; }

  .qs-split-sequence {
    grid-template-columns: 1fr;
    padding: 8px 20px 16px;
  }
  .qs-sequence-arrow {
    display: none;
  }
  .qs-split-panes { grid-template-columns: 1fr; padding: 0 20px 16px; }
  .qs-terminal pre { font-size: 13px; }

  .ns-card { padding: 24px 20px; }
  .ns-card h3 { font-size: 19px; }
  .ns-example { font-size: 14px; }

  .cta { padding: 64px 0; }
  .cta h2 { font-size: 24px; }
  .cta p { font-size: 17px; }

  .footer-inner { gap: 32px; }
  .footer-heading { font-size: 13px; }
  .footer-col a { font-size: 14px; }

  .docs-layout {
    flex-direction: column;
    gap: 16px;
  }
  .docs-sidebar {
    width: 100%;
    position: static;
  }
  .prose p, .prose li { font-size: 16px; }
  .prose pre { font-size: 14px; }
}
