:root {
  --bg-primary: #05070C;
  --bg-elevated: #0A0D14;
  --bg-secondary: #0C0F16;
  --bg-card: #10141C;
  --bg-card-hover: #151A25;
  --border: #161C2B;
  --border-bright: #232D40;
  --hairline: rgba(232, 236, 242, 0.12);
  --text-primary: #E8ECF2;
  --text-secondary: #B5BFD0;
  --text-muted: #8793A8;
  --text-whisper: #5E6678;
  --accent-mint: #6EE7B7;
  --accent-mint-dim: #4AD4A0;
  --accent-mint-deep: #0D6B5E;
  --accent-ice: #7DD3FC;
  --accent-ice-dim: #38BDF8;
  --accent-rose: #F9A8D4;
  --glow-mint: rgba(110, 231, 183, 0.10);
  --glow-mint-strong: rgba(110, 231, 183, 0.18);
  --glow-ice: rgba(125, 211, 252, 0.10);
  --glow-ice-strong: rgba(125, 211, 252, 0.18);
  --font-body: 'Instrument Sans', system-ui, -apple-system, sans-serif;
  --font-mono: 'IBM Plex Mono', 'Menlo', monospace;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
/* Luxury materiality layers */
.ambient-glow, .vignette, .grain {
  position: fixed; inset: 0; pointer-events: none;
}
.ambient-glow {
  z-index: 0;
  background:
    radial-gradient(ellipse 70% 50% at 50% 30%, rgba(110, 231, 183, 0.04) 0%, transparent 55%),
    radial-gradient(ellipse 80% 60% at 50% 95%, rgba(125, 211, 252, 0.025) 0%, transparent 60%);
}
.vignette {
  z-index: 1;
  background: radial-gradient(ellipse at center, transparent 40%, rgba(0, 0, 0, 0.45) 100%);
}
.grain {
  z-index: 2;
  opacity: 0.05; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.5 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}
nav, main, section, header, footer, .container { position: relative; z-index: 10; }
.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; position: relative; z-index: 10; }
.badge {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--accent-mint); background: var(--glow-mint);
  border: 1px solid rgba(110,231,183,0.2); border-radius: 100px;
  padding: 6px 14px; letter-spacing: 0.05em; text-transform: uppercase;
}
.badge::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent-mint); animation: pulse-dot 2s infinite;
}
.badge.ice {
  color: var(--accent-ice); background: var(--glow-ice);
  border-color: rgba(125,211,252,0.2);
}
.badge.ice::before { background: var(--accent-ice); }
@keyframes pulse-dot { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }
.btn-primary {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 28px; border-radius: 8px; font-size: 15px; font-weight: 600;
  background: var(--accent-mint); color: #080A0F; border: none; cursor: pointer;
  font-family: var(--font-body); transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1); text-decoration: none;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 30px rgba(110,231,183,0.25); background: #8CF0CC; }
.btn-ghost {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 14px 28px; border-radius: 8px; font-size: 15px; font-weight: 500;
  background: transparent; color: var(--text-primary); cursor: pointer;
  font-family: var(--font-body); transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  border: 1px solid var(--border-bright); text-decoration: none;
}
.btn-ghost:hover { border-color: var(--accent-mint); color: var(--accent-mint); background: var(--glow-mint); }

/* NAV */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100; padding: 14px 0;
  background: rgba(8, 10, 15, 0.88);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--hairline);
}
nav .container { display: flex; align-items: center; justify-content: space-between; }
.nav-logo { display: flex; align-items: center; text-decoration: none; }
.nav-logo svg { height: 32px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a { font-size: 14px; font-weight: 500; color: var(--text-secondary); text-decoration: none; transition: color 0.35s cubic-bezier(0.22, 1, 0.36, 1); }
.nav-links a:hover { color: var(--text-primary); }
.nav-links a.active { color: var(--accent-mint); }
.nav-cta { display: flex; align-items: center; gap: 12px; }
.nav-cta .btn-primary { padding: 9px 20px; font-size: 13px; }
.nav-cta .btn-ghost { padding: 9px 20px; font-size: 13px; }
@media (max-width: 768px) { .nav-links { display: none; } }

/* PAGE HERO */
.page-hero {
  padding: 160px 0 80px; position: relative; overflow: hidden;
}
.page-hero-gradient {
  position: absolute; top: -200px; left: 50%; transform: translateX(-50%);
  width: 900px; height: 900px; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(110,231,183,0.05) 0%, rgba(125,211,252,0.03) 40%, transparent 65%);
  pointer-events: none;
}
.page-hero-content { position: relative; z-index: 2; max-width: 720px; }
.page-hero-content h1 {
  font-size: clamp(40px, 6.2vw, 68px); font-weight: 500; letter-spacing: -0.035em;
  line-height: 1.08; margin: 20px 0 28px;
}
h1 em, .page-hero-content h1 em {
  font-family: 'Fraunces', 'Instrument Sans', serif;
  font-style: italic;
  font-weight: 400;
  letter-spacing: -0.015em;
  background: linear-gradient(135deg, var(--accent-mint, #6EE7B7) 0%, var(--accent-ice, #7DD3FC) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.page-hero-content p {
  font-size: 18px; color: var(--text-secondary); line-height: 1.65; max-width: 580px;
}

/* SECTIONS */
.section { padding: 80px 0; position: relative; }
.section-alt { background: linear-gradient(180deg, var(--bg-primary) 0%, var(--bg-secondary) 50%, var(--bg-primary) 100%); }
.section-header { max-width: 660px; margin: 0 auto 56px; text-align: center; }
.section-header h2 {
  font-size: clamp(30px, 4.2vw, 44px); font-weight: 500; letter-spacing: -0.03em;
  line-height: 1.12; margin-bottom: 18px;
}
.section-header p { font-size: 17px; color: var(--text-secondary); line-height: 1.6; }

/* CONTENT BLOCKS */
.content-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: start;
}
@media (max-width: 768px) { .content-grid { grid-template-columns: 1fr; gap: 40px; } }
.content-block h3 {
  font-size: 22px; font-weight: 700; letter-spacing: -0.02em; margin-bottom: 12px; line-height: 1.25;
}
.content-block p { font-size: 15px; color: var(--text-secondary); line-height: 1.7; margin-bottom: 16px; }
.content-block p strong { color: var(--text-primary); font-weight: 600; }

/* FEATURE CARDS */
.features-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 1px;
  background: var(--border); border-radius: 16px; overflow: hidden;
}
.feature-card {
  background: var(--bg-secondary); padding: 36px 28px; transition: background 0.3s ease;
}
.feature-card:hover { background: var(--bg-card-hover); }
.feature-icon {
  width: 42px; height: 42px; border-radius: 9px; margin-bottom: 18px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--border-bright); background: var(--bg-card);
}
.feature-icon.mint { border-color: rgba(110,231,183,0.25); background: var(--glow-mint); }
.feature-icon.ice { border-color: rgba(125,211,252,0.25); background: var(--glow-ice); }
.feature-icon svg { width: 20px; height: 20px; }
.feature-card h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; letter-spacing: -0.01em; }
.feature-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.65; }

/* CODE BLOCKS */
.code-block {
  background: var(--bg-primary); border: 1px solid var(--border); border-radius: 10px;
  padding: 24px; font-family: var(--font-mono); font-size: 12px; line-height: 1.8;
  color: var(--text-secondary); overflow-x: auto;
}
.code-block .kw { color: var(--accent-mint); }
.code-block .fn { color: var(--accent-ice); }
.code-block .str { color: #C4B5FD; }
.code-block .cm { color: var(--text-muted); }
.code-block .num { color: var(--accent-rose); }

/* INFO CARDS (stacked content + visual) */
.info-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2px; min-height: 260px;
}
@media (max-width: 768px) { .info-row { grid-template-columns: 1fr; } }
.info-text {
  padding: 44px 36px; display: flex; flex-direction: column; justify-content: center;
  background: var(--bg-secondary);
}
.info-text .badge { margin-bottom: 14px; }
.info-text h3 {
  font-size: clamp(20px, 3vw, 26px); font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 10px; line-height: 1.2;
}
.info-text p { font-size: 15px; color: var(--text-secondary); line-height: 1.65; max-width: 440px; }
.info-visual {
  background: var(--bg-card); display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden; padding: 28px;
}

/* PIPELINE / STEP LIST */
.step-list { display: flex; flex-direction: column; gap: 0; }
.step-item {
  display: flex; align-items: flex-start; gap: 16px;
  padding: 20px 22px; border-left: 2px solid var(--border-bright); position: relative;
}
.step-item::before {
  content: ''; position: absolute; left: -5px; top: 28px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent-mint); border: 2px solid var(--bg-primary);
}
.step-item h4 { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.step-item p { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }
.step-item .meta {
  font-family: var(--font-mono); font-size: 11px; color: var(--accent-ice);
  margin-top: 4px;
}

/* ARCH DIAGRAM */
.arch-visual {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 16px;
  padding: 48px; position: relative; overflow: hidden;
}
.arch-visual::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent-mint), var(--accent-ice), transparent);
}
.arch-diagram { display: flex; flex-direction: column; align-items: center; gap: 24px; }
.arch-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.arch-node {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 18px; border-radius: 8px; font-size: 13px; font-weight: 500;
  font-family: var(--font-mono);
}
.arch-node.client { background: var(--glow-ice); border: 1px solid rgba(125,211,252,0.3); color: var(--accent-ice); }
.arch-node.orchestrator { background: var(--glow-mint); border: 1px solid rgba(110,231,183,0.3); color: var(--accent-mint); }
.arch-node.agent { background: rgba(110,231,183,0.06); border: 1px solid rgba(110,231,183,0.2); color: var(--accent-mint-dim); }
.arch-node.infra { background: var(--bg-secondary); border: 1px solid var(--border-bright); color: var(--text-secondary); }
.arch-connector { width: 2px; height: 24px; background: linear-gradient(180deg, var(--accent-mint), transparent); }
.arch-label {
  font-family: var(--font-mono); font-size: 11px; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.08em;
}

/* STAT GRID */
.stat-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1px;
  background: var(--border); border-radius: 16px; overflow: hidden;
}
.stat-card {
  background: var(--bg-secondary); padding: 36px 28px; text-align: center;
  transition: background 0.3s;
}
.stat-card:hover { background: var(--bg-card-hover); }
.stat-value {
  font-size: clamp(28px, 4vw, 42px); font-weight: 700; letter-spacing: -0.04em; margin-bottom: 6px;
  background: linear-gradient(135deg, var(--accent-mint), var(--accent-ice));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.stat-label { font-size: 14px; color: var(--text-secondary); font-weight: 500; }
.stat-sub { font-size: 12px; color: var(--text-muted); margin-top: 3px; }

/* TABLE-LIKE CARDS */
.tier-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: var(--border); border-radius: 16px; overflow: hidden;
}
@media (max-width: 768px) { .tier-grid { grid-template-columns: 1fr; } }
.tier-card {
  background: var(--bg-secondary); padding: 32px 28px; transition: background 0.3s;
}
.tier-card:hover { background: var(--bg-card-hover); }
.tier-card h4 {
  font-size: 16px; font-weight: 700; margin-bottom: 4px;
  background: linear-gradient(135deg, var(--accent-mint), var(--accent-ice));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.tier-card .tier-range { font-family: var(--font-mono); font-size: 12px; color: var(--accent-ice); margin-bottom: 12px; }
.tier-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }

/* BRAND VISUAL */
.brand-visual {
  display: flex; align-items: center; justify-content: center;
  position: relative; min-height: 320px;
}
.brand-visual > svg { width: 220px; height: 220px; position: relative; z-index: 1; }
.brand-visual .orbital-ring {
  position: absolute; top: 50%; left: 50%; border-radius: 50%;
  border: 1px dashed; opacity: 0.15;
}
.brand-visual .orbital-ring.ring-1 {
  width: 300px; height: 300px; border-color: var(--accent-mint);
  animation: orbitalSpin 40s linear infinite;
}
.brand-visual .orbital-ring.ring-2 {
  width: 220px; height: 220px; border-color: var(--accent-ice);
  animation: orbitalSpin 25s linear infinite reverse;
}
@keyframes orbitalSpin { from { transform: translate(-50%, -50%) rotate(0deg); } to { transform: translate(-50%, -50%) rotate(360deg); } }

/* CTA */
.cta-section { padding: 100px 0; text-align: center; position: relative; overflow: hidden; }
.cta-section::before {
  content: ''; position: absolute; bottom: -100px; left: 50%; transform: translateX(-50%);
  width: 700px; height: 700px; border-radius: 50%;
  background: radial-gradient(ellipse, rgba(110,231,183,0.08) 0%, rgba(125,211,252,0.04) 40%, transparent 70%);
  pointer-events: none;
}
.cta-section h2 {
  font-size: clamp(30px, 4.2vw, 48px); font-weight: 500; letter-spacing: -0.03em;
  line-height: 1.1; margin-bottom: 18px; position: relative;
}
.cta-section p {
  font-size: 17px; color: var(--text-secondary); margin-bottom: 36px;
  max-width: 480px; margin-left: auto; margin-right: auto; position: relative;
}
.cta-buttons { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; position: relative; }

/* FOOTER */
footer { padding: 48px 0; border-top: 1px solid var(--border); }
.footer-inner {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px;
}
.footer-left { display: flex; align-items: center; gap: 16px; }
.footer-left svg { height: 24px; width: auto; }
.footer-copy { font-size: 13px; color: var(--text-muted); }
.footer-links { display: flex; gap: 24px; }
.footer-links a { font-size: 13px; color: var(--text-secondary); text-decoration: none; transition: color 0.35s cubic-bezier(0.22, 1, 0.36, 1); }
.footer-links a:hover { color: var(--accent-mint); }

/* SCROLL */
.reveal { opacity: 0; transform: translateY(28px); transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1); }
.reveal.visible { opacity: 1; transform: translateY(0); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: translateY(0); } }
.animate-up { animation: fadeUp 0.8s ease forwards; opacity: 0; }
.animate-up-d1 { animation-delay: 0.1s; }
.animate-up-d2 { animation-delay: 0.2s; }

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--bg-primary); }
::-webkit-scrollbar-thumb { background: var(--border-bright); border-radius: 4px; }

/* ── LIGHT MODE ── */
body.light {
  --bg-primary: #F7F8FA;
  --bg-secondary: #EEF0F4;
  --bg-card: rgba(255,255,255,0.82);
  --bg-card-hover: rgba(248,249,251,0.9);
  --border: #DDE1E8;
  --border-bright: #C8CDD6;
  --text-primary: #111827;
  --text-secondary: #4B5563;
  --text-muted: #9CA3AF;
  --accent-mint: #059669;
  --accent-mint-dim: #047857;
  --accent-ice: #0284C7;
  --accent-ice-dim: #0369A1;
  --accent-rose: #DB2777;
  --glow-mint: rgba(5,150,105,0.08);
  --glow-mint-strong: rgba(5,150,105,0.14);
  --glow-ice: rgba(2,132,199,0.08);
  --glow-ice-strong: rgba(2,132,199,0.14);
}
body.light nav { background: rgba(247,248,250,0.92); }
body.light .btn-primary { background: #059669; color: #fff; }
body.light .btn-primary:hover { background: #047857; box-shadow: 0 8px 30px rgba(5,150,105,0.2); }
body.light .btn-ghost { color: #111827; border-color: #C8CDD6; }
body.light .btn-ghost:hover { border-color: #059669; color: #059669; background: rgba(5,150,105,0.06); }
body.light .badge { color: #059669; background: rgba(5,150,105,0.08); border-color: rgba(5,150,105,0.2); }
body.light .badge::before { background: #059669; }
body.light .badge.ice { color: #0284C7; background: rgba(2,132,199,0.08); border-color: rgba(2,132,199,0.2); }
body.light .badge.ice::before { background: #0284C7; }
body.light .nav-logo text { fill: #111827; }
body.light .footer-left text { fill: #111827; }
body.light .page-hero-gradient { background: radial-gradient(ellipse, rgba(5,150,105,0.06) 0%, rgba(2,132,199,0.03) 40%, transparent 65%); }
/* Theme toggle */
.theme-toggle{position:relative;display:inline-block;width:44px;height:24px;border-radius:24px;background:rgba(255,255,255,0.06);border:1px solid rgba(255,255,255,0.12);cursor:pointer;padding:0;vertical-align:middle;transition:background 0.3s ease, border-color 0.3s ease}
.theme-toggle:hover{border-color:rgba(110,231,183,0.4);background:rgba(255,255,255,0.08)}
.theme-toggle-thumb{position:absolute;top:1px;left:1px;width:20px;height:20px;border-radius:50%;background:#E8ECF2;display:flex;align-items:center;justify-content:center;color:#080A0F;box-shadow:0 1px 3px rgba(0,0,0,0.2);transition:transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), background 0.3s ease}
body.light .theme-toggle{background:rgba(0,0,0,0.04);border-color:rgba(0,0,0,0.1)}
body.light .theme-toggle:hover{background:rgba(0,0,0,0.06);border-color:rgba(5,150,105,0.4)}
body.light .theme-toggle-thumb{transform:translateX(20px);background:#059669;color:#fff}

/* — converted from inline style attributes — */
.badge-row { display:flex; flex-wrap:wrap; gap:10px; justify-content:center; max-width:880px; margin:0 auto 28px; }
.note-block { max-width:640px; margin:0 auto; text-align:center; }
.note-text { font-size:15px; color:var(--text-secondary); line-height:1.7; }
.features-grid-narrow { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
