/* Signal. Colours come from config.palette via the custom properties on :root. */
:root {
  --bg: #07080b; --panel: #0d0f14; --ink: #eef1f6; --muted: #8a92a3; --line: rgba(238, 241, 246, 0.09); --accent: #c8f560; --accent2: #5cc8ff;
  --sans: "Geist", system-ui, sans-serif; --mono: "Geist Mono", ui-monospace, monospace;
  --pad: clamp(20px, 4.5vw, 64px); --max: 1200px;
}
body { background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.55; }
::selection { background: var(--accent); color: var(--bg); }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.04em; line-height: 1; }
em { font-style: normal; background: linear-gradient(90deg, var(--accent), var(--accent2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.kicker { margin: 0 0 18px; font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); }
section { position: relative; }

.nav { position: fixed; z-index: 30; inset: 0 0 auto; display: flex; align-items: center; gap: 28px; padding: 16px var(--pad); transition: background 0.3s, border-color 0.3s; border-bottom: 1px solid transparent; }
.nav.is-solid { background: rgba(7, 8, 11, 0.72); backdrop-filter: blur(14px) saturate(1.4); -webkit-backdrop-filter: blur(14px) saturate(1.4); border-color: var(--line); }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 18px; letter-spacing: -0.02em; text-decoration: none; }
.brand i { width: 18px; height: 18px; border-radius: 50%; background: conic-gradient(from 200deg, var(--accent), var(--accent2), var(--accent)); box-shadow: 0 0 18px color-mix(in srgb, var(--accent) 50%, transparent); }
.nav nav { display: flex; gap: 26px; margin-left: 20px; }
.nav nav a, .link { color: var(--muted); text-decoration: none; font-size: 14px; transition: color 0.2s; }
.nav nav a:hover, .link:hover { color: var(--ink); }
.link { margin-left: auto; }
.btn { display: inline-flex; align-items: center; justify-content: center; height: 40px; padding: 0 18px; border-radius: 10px; background: var(--accent); color: #0b0d06; font-size: 14px; font-weight: 600; text-decoration: none; border: 1px solid var(--accent); transition: transform 0.2s, box-shadow 0.2s, background 0.2s; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 30px color-mix(in srgb, var(--accent) 35%, transparent); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--muted); box-shadow: none; }

/* Hero */
.hero { min-height: 100vh; padding: 150px var(--pad) 40px; overflow: hidden; display: flex; flex-direction: column; }
.hero .net { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: radial-gradient(60% 45% at 50% 30%, rgba(7, 8, 11, 0.85), transparent 75%); }
.hero-in { position: relative; z-index: 2; max-width: 860px; margin: 0 auto; text-align: center; }
.badge { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 26px; padding: 6px 14px 6px 8px; border: 1px solid var(--line); border-radius: 99px; background: rgba(255, 255, 255, 0.03); font-size: 13px; color: var(--muted); }
.badge i { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 12px var(--accent); animation: blink 2s ease-in-out infinite; }
@keyframes blink { 50% { opacity: 0.35; } }
.hero h1 { font-size: clamp(46px, 7.4vw, 104px); }
.sub { max-width: 600px; margin: 24px auto 32px; font-size: 18px; color: var(--muted); }
.actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.term { margin: 46px auto 0; max-width: 560px; text-align: left; border: 1px solid var(--line); border-radius: 14px; background: rgba(13, 15, 20, 0.86); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 40px 80px rgba(0, 0, 0, 0.5); overflow: hidden; }
.term-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.term-bar i { width: 10px; height: 10px; border-radius: 50%; background: rgba(238, 241, 246, 0.14); }
.term-bar span { margin-left: auto; margin-right: auto; font-size: 12px; color: var(--muted); transform: translateX(-20px); }
.term pre { margin: 0; padding: 18px 20px 20px; font: 13.5px/1.75 var(--mono); white-space: pre-wrap; min-height: 132px; }
.term .p { color: var(--accent); }
.caret { display: inline-block; width: 8px; height: 16px; vertical-align: -3px; background: var(--ink); animation: blink 1s steps(1) infinite; }
.out span { display: inline-block; color: var(--muted); transition: opacity 0.3s; }
.out span:last-child { color: var(--accent); }
.logos { position: relative; z-index: 2; display: flex; justify-content: center; gap: clamp(24px, 5vw, 64px); flex-wrap: wrap; margin-top: auto; padding-top: 70px; }
.logos span { font-weight: 600; font-size: 19px; letter-spacing: -0.03em; color: rgba(238, 241, 246, 0.32); }

/* Route */
.route { border-top: 1px solid var(--line); }
.route .sticky { display: grid; grid-template-columns: minmax(280px, 0.8fr) 1.2fr; grid-template-rows: auto 1fr; padding: 100px var(--pad) 50px; gap: 0 40px; }
.route-head { grid-column: 1 / -1; margin-bottom: 20px; }
.route-head h2 { font-size: clamp(38px, 4.6vw, 68px); }
.route .net { grid-column: 2; grid-row: 2; width: 100%; height: 100%; min-height: 320px; }
.route-steps { grid-column: 1; grid-row: 2; position: relative; align-self: center; height: 220px; }
.route-steps article { position: absolute; inset: 0; opacity: 0; transform: translateY(16px); transition: opacity 0.45s, transform 0.45s; }
.route-steps article.on { opacity: 1; transform: none; }
.hop { font-family: var(--mono); font-size: 12px; color: var(--accent); letter-spacing: 0.06em; text-transform: uppercase; }
.route-steps h3 { font-size: clamp(28px, 3vw, 40px); margin: 14px 0 12px; }
.route-steps p { color: var(--muted); font-size: 17px; margin: 0; max-width: 380px; }
.clock { position: absolute; right: var(--pad); top: 110px; text-align: right; font-family: var(--mono); }
.clock span { display: block; font-size: clamp(40px, 5vw, 72px); font-weight: 500; letter-spacing: -0.04em; line-height: 1; font-variant-numeric: tabular-nums; }
.clock small { color: var(--muted); font-size: 12px; }

/* Platform */
.platform, .code, .pricing { padding: 140px var(--pad); max-width: var(--max); margin: 0 auto; }
.platform h2, .code h2, .pricing h2 { font-size: clamp(38px, 4.8vw, 72px); max-width: 800px; }
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 60px; }
.card, .plan { position: relative; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); padding: 28px; overflow: hidden; }
.card::before, .plan::before { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.3s; background: radial-gradient(360px circle at var(--mx, 50%) var(--my, 50%), color-mix(in srgb, var(--accent) 12%, transparent), transparent 60%); }
.card:hover::before, .plan:hover::before { opacity: 1; }
.viz { height: 170px; margin-bottom: 26px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); overflow: hidden; position: relative; }
.card h3 { font-size: 22px; letter-spacing: -0.025em; }
.card p { color: var(--muted); margin: 8px 0 0; }
.spark { width: 100%; height: 100%; }
.legend { position: absolute; left: 14px; top: 12px; display: flex; gap: 14px; font: 11px var(--mono); color: var(--muted); }
.legend i { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; }
.legend .a { background: var(--accent); } .legend .b { background: var(--accent2); }
.bars { position: absolute; inset: 0; display: flex; align-items: center; gap: 4px; padding: 0 18px; }
.bars i { flex: 1; height: 44px; border-radius: 3px; background: color-mix(in srgb, var(--accent) 75%, transparent); animation: bar 2.4s ease-in-out infinite; animation-delay: calc(var(--i) * 40ms); }
.bars i.warn { background: #f5b14c; }
@keyframes bar { 50% { opacity: 0.55; } }
.mini { position: absolute; inset: 0; margin: 0; padding: 26px 22px; font: 13px/1.8 var(--mono); color: var(--ink); }
.k { color: #c792ea; } .s { color: var(--accent); }
.cache { position: absolute; inset: 0; padding: 14px 16px; display: grid; gap: 7px; font: 12.5px var(--mono); }
.cache div { display: flex; justify-content: space-between; align-items: center; padding: 7px 10px; border-radius: 8px; background: rgba(255, 255, 255, 0.03); animation: row 3.2s ease-in-out infinite; animation-delay: calc(var(--i) * 0.4s); }
.cache b { font-weight: 500; font-size: 11px; padding: 2px 7px; border-radius: 5px; }
.cache .hit { background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--accent); }
.cache .miss { background: rgba(245, 177, 76, 0.15); color: #f5b14c; }
@keyframes row { 0%, 100% { background: rgba(255, 255, 255, 0.03); } 20% { background: rgba(255, 255, 255, 0.08); } }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 70px 0 0; border-top: 1px solid var(--line); }
.stats div { padding: 30px 0 0; }
.stats dt { font-size: clamp(42px, 5vw, 70px); font-weight: 600; letter-spacing: -0.05em; line-height: 1; font-variant-numeric: tabular-nums; }
.stats dd { margin: 10px 0 0; color: var(--muted); font-size: 14px; }

/* Code */
.code { display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 60px; align-items: center; }
.editor { border: 1px solid var(--line); border-radius: 16px; background: var(--panel); overflow: hidden; box-shadow: 0 40px 80px rgba(0, 0, 0, 0.4); }
.tabs { display: flex; border-bottom: 1px solid var(--line); }
.tabs button { padding: 12px 18px; border: 0; background: none; color: var(--muted); font: 13px var(--mono); border-right: 1px solid var(--line); }
.tabs button[aria-selected="true"] { color: var(--ink); background: rgba(255, 255, 255, 0.03); box-shadow: inset 0 -2px 0 var(--accent); }
.editor pre { margin: 0; padding: 22px 22px 26px; font: 13.5px/1.85 var(--mono); overflow-x: auto; }
.ln { display: inline-block; width: 26px; color: rgba(238, 241, 246, 0.22); user-select: none; }

/* Pricing */
.plans { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 60px; }
.plan h3 { font-size: 18px; letter-spacing: -0.01em; }
.price { margin: 20px 0 6px; display: flex; align-items: baseline; gap: 6px; }
.price strong { font-size: 48px; font-weight: 600; letter-spacing: -0.05em; }
.price span { color: var(--muted); font-size: 14px; }
.plan-text { color: var(--muted); margin: 0 0 22px; }
.plan ul { list-style: none; margin: 0 0 28px; padding: 22px 0 0; border-top: 1px solid var(--line); display: grid; gap: 10px; font-size: 14px; }
.plan li::before { content: "✓"; color: var(--accent); margin-right: 10px; }
.plan .btn { width: 100%; }
.plan.featured { border-color: color-mix(in srgb, var(--accent) 55%, transparent); box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent) 30%, transparent), 0 30px 80px color-mix(in srgb, var(--accent) 10%, transparent); }
.note { color: var(--muted); font-size: 13px; margin: 22px 0 0; }

/* Closing */
.closing { padding: 160px var(--pad); text-align: center; border-top: 1px solid var(--line); background: radial-gradient(50% 60% at 50% 100%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 70%); }
.closing h2 { font-size: clamp(44px, 7vw, 100px); }
.copy { display: inline-flex; align-items: center; gap: 12px; margin: 34px 12px 0; padding: 12px 16px; border-radius: 12px; border: 1px solid var(--line); background: var(--panel); font: 14px var(--mono); }
.copy .p { color: var(--accent); }
.copy small { color: var(--muted); padding-left: 12px; border-left: 1px solid var(--line); }

.foot { display: flex; flex-wrap: wrap; gap: 28px; align-items: center; padding: 34px var(--pad); border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; }
.foot nav { display: flex; gap: 20px; }
.foot nav a { text-decoration: none; }
.foot small { margin-left: auto; }

@media (max-width: 900px) {
  .nav nav, .link { display: none; }
  .nav .btn { margin-left: auto; }
  .route .sticky { grid-template-columns: 1fr; grid-template-rows: auto 1fr auto; padding-top: 90px; }
  .route .net { grid-column: 1; grid-row: 2; }
  .route-steps { grid-column: 1; grid-row: 3; height: 190px; }
  .clock { top: auto; bottom: 28px; }
  .cards, .plans, .code, .stats { grid-template-columns: 1fr; }
  .foot small { margin-left: 0; }
}
