:root {
  color-scheme: light;
  --paper: #f7faff;
  --surface: #ffffff;
  --surface-2: #f0f5fb;
  --ink: #08111f;
  --muted: #526174;
  --line: rgba(8, 17, 31, 0.12);
  --red: #f81018;
  --yellow: #ffd619;
  --green: #00b559;
  --blue: #0a7fbe;
  --registry: #7b4dff;
  --cluster: #00b559;
  --observable: #1268f3;
  --accent: var(--cluster);
  --accent-soft: rgba(0, 181, 89, 0.13);
  --warning: #f59e0b;
  --shadow: 0 24px 70px rgba(8, 17, 31, 0.12);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #06101c;
  --surface: #0b1726;
  --surface-2: #102235;
  --ink: #eef6ff;
  --muted: #9badc2;
  --line: rgba(230, 241, 255, 0.15);
  --shadow: 0 28px 86px rgba(0, 0, 0, 0.42);
}

:root[data-product="registry"] { --accent: var(--registry); --accent-soft: rgba(123, 77, 255, 0.15); }
:root[data-product="cluster"] { --accent: var(--cluster); --accent-soft: rgba(0, 181, 89, 0.15); }
:root[data-product="observable"] { --accent: var(--observable); --accent-soft: rgba(18, 104, 243, 0.15); }

* { box-sizing: border-box; }
html { background: var(--paper); color: var(--ink); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; line-height: 1.5; text-size-adjust: 100%; }
body { margin: 0; overflow-x: clip; }
a { color: inherit; }
button, input, select { font: inherit; }
button:focus-visible, a:focus-visible, select:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 70%, white); outline-offset: 3px; }

.shell { min-height: 100svh; overflow-x: clip; }
.topbar { background: color-mix(in srgb, var(--surface) 88%, transparent); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; backdrop-filter: blur(18px); }
.nav { align-items: center; display: flex; gap: 18px; justify-content: space-between; margin: 0 auto; max-width: 1240px; min-height: 70px; padding: 0 clamp(16px, 4vw, 32px); }
.brand { align-items: center; display: inline-flex; gap: 11px; min-width: 0; text-decoration: none; }
.brand img { border-radius: 7px; height: 36px; width: 36px; }
.brand strong { font-size: 16px; font-weight: 950; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-links { align-items: center; display: flex; gap: 24px; margin-left: auto; }
.nav-links a { color: var(--muted); font-size: 13px; font-weight: 850; text-decoration: none; }
.nav-actions { align-items: center; display: flex; gap: 10px; }
.language { background: var(--surface); border: 1px solid var(--line); border-radius: 7px; color: var(--ink); min-height: 40px; max-width: 210px; padding: 0 10px; }
.icon-button { align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; color: var(--ink); cursor: pointer; display: inline-flex; height: 42px; justify-content: center; padding: 0; position: relative; width: 42px; }
.icon-button svg { height: 21px; stroke-width: 2; width: 21px; }
.icon-button:hover { border-color: var(--accent); color: var(--accent); }
.icon-button::after { background: var(--ink); border-radius: 6px; color: var(--surface); content: attr(data-tooltip); font-size: 11px; font-weight: 800; opacity: 0; padding: 6px 8px; pointer-events: none; position: absolute; right: 0; top: calc(100% + 8px); transform: translateY(-3px); transition: opacity .16s ease, transform .16s ease; white-space: nowrap; }
.icon-button:hover::after, .icon-button:focus-visible::after { opacity: 1; transform: translateY(0); }
.button { align-items: center; border: 1px solid var(--line); border-radius: 8px; display: inline-flex; font-size: 14px; font-weight: 900; gap: 8px; justify-content: center; min-height: 46px; padding: 0 17px; text-decoration: none; white-space: nowrap; }
.button svg { height: 19px; stroke-width: 2; width: 19px; }
.button.primary { background: var(--accent); border-color: color-mix(in srgb, var(--accent) 84%, black); color: white; box-shadow: 0 12px 30px color-mix(in srgb, var(--accent) 28%, transparent); }
.button.secondary { background: color-mix(in srgb, var(--surface) 78%, transparent); color: var(--ink); }
.button:hover { transform: translateY(-1px); }

.hero { background: radial-gradient(circle at 14% 8%, color-mix(in srgb, var(--accent) 20%, transparent), transparent 34%), radial-gradient(circle at 88% 16%, rgba(10, 127, 190, 0.15), transparent 35%), linear-gradient(120deg, rgba(248, 16, 24, 0.05), rgba(255, 214, 25, 0.06) 30%, rgba(0, 181, 89, 0.08) 64%, rgba(10, 127, 190, 0.08)), var(--paper); border-bottom: 1px solid var(--line); overflow: hidden; position: relative; }
.hero::before { background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px); background-size: 54px 54px; content: ""; inset: 0; opacity: .22; position: absolute; }
.brand-strip { background: linear-gradient(90deg, var(--red), var(--yellow) 32%, var(--green) 64%, var(--blue)); height: 6px; position: relative; z-index: 1; }
.hero-inner { display: grid; gap: clamp(32px, 5vw, 68px); grid-template-columns: minmax(0, .86fr) minmax(380px, 1.14fr); margin: 0 auto; max-width: 1240px; min-height: calc(100svh - 76px); padding: clamp(54px, 7vw, 92px) clamp(16px, 4vw, 32px) clamp(42px, 5vw, 68px); position: relative; z-index: 1; }
.hero-copy { align-self: center; min-width: 0; }
.eyebrow { align-items: center; background: color-mix(in srgb, var(--accent) 12%, var(--surface)); border: 1px solid color-mix(in srgb, var(--accent) 34%, var(--line)); border-radius: 8px; color: var(--accent); display: inline-flex; font-size: 12px; font-weight: 950; gap: 8px; letter-spacing: .12em; margin: 0 0 18px; padding: 8px 10px; text-transform: uppercase; }
.eyebrow img { border-radius: 5px; height: 20px; width: 20px; }
h1 { font-size: clamp(48px, 7vw, 92px); line-height: .93; margin: 0; max-width: 760px; overflow-wrap: anywhere; }
h1 strong { color: var(--accent); }
.hero-title-note { color: color-mix(in srgb, var(--ink) 86%, var(--muted)); font-size: clamp(22px, 3vw, 36px); font-weight: 900; line-height: 1.15; margin: 18px 0 0; max-width: 760px; }
.copy { color: var(--muted); font-size: clamp(16px, 1.35vw, 18px); line-height: 1.75; margin: 18px 0 0; max-width: 720px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.simulation-stage { align-self: center; position: relative; }
.simulation-card { background: color-mix(in srgb, var(--surface) 86%, transparent); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow); min-height: 560px; overflow: hidden; position: relative; }
.simulation-canvas { display: block; height: 100%; inset: 0; min-height: 560px; position: absolute; width: 100%; z-index: 2; }
.simulation-fallback { display: grid; gap: 14px; inset: 0; place-content: center; padding: 30px; position: absolute; z-index: 1; }
.fallback-step { align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; color: var(--ink); display: flex; font-weight: 900; gap: 10px; min-height: 52px; padding: 12px 14px; }
.fallback-step i { background: var(--accent); border-radius: 999px; box-shadow: 0 0 24px var(--accent); height: 10px; width: 10px; }
.simulation-ready .simulation-fallback { opacity: 0; }

.section { background: var(--paper); padding: clamp(48px, 6vw, 82px) clamp(16px, 4vw, 32px); }
.section.white { background: var(--surface); border-bottom: 1px solid var(--line); }
.wrap { margin: 0 auto; max-width: 1240px; }
.section-head { display: grid; gap: 12px; margin-bottom: 28px; max-width: 840px; }
.section-head h2 { font-size: clamp(30px, 4.4vw, 56px); line-height: 1.02; margin: 0; }
.section-head p { color: var(--muted); font-size: 16px; line-height: 1.75; margin: 0; }
.metrics-row { display: grid; gap: 14px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.metric-card, .proof-card, .workflow-card, .live-cta { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; min-width: 0; }
.metric-card { background: color-mix(in srgb, var(--surface-2) 80%, var(--surface)); padding: 20px; }
.metric-card small { color: var(--muted); display: block; font-size: 11px; font-weight: 950; letter-spacing: .1em; text-transform: uppercase; }
.metric-card strong { display: block; font-size: clamp(34px, 5vw, 58px); line-height: 1; margin-top: 10px; overflow-wrap: anywhere; }
.metric-card span { color: var(--muted); display: block; font-size: 13px; line-height: 1.55; margin-top: 10px; }
.workflow-card { background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 8%, var(--surface)), var(--surface)); box-shadow: var(--shadow); overflow: hidden; padding: clamp(18px, 3vw, 26px); }
.workflow-card header { align-items: center; display: flex; gap: 12px; justify-content: space-between; margin-bottom: 16px; }
.workflow-card h3 { font-size: 20px; margin: 0; }
.status-pill { align-items: center; border: 1px solid color-mix(in srgb, var(--accent) 40%, var(--line)); border-radius: 999px; color: var(--accent); display: inline-flex; font-size: 12px; font-weight: 900; gap: 8px; padding: 7px 10px; }
.status-pill i { background: currentColor; border-radius: 999px; box-shadow: 0 0 14px currentColor; height: 8px; width: 8px; }
.workflow-visual { min-height: 330px; position: relative; }
.proof-grid { display: grid; gap: 18px; grid-template-columns: minmax(0, .9fr) minmax(280px, .55fr); }
.proof-card { padding: 24px; }
.proof-card h3 { font-size: clamp(24px, 3vw, 36px); line-height: 1.08; margin: 0; }
.proof-card p { color: var(--muted); line-height: 1.75; margin: 14px 0 0; }
.mini-proof { align-content: center; display: grid; gap: 14px; }
.ring { aspect-ratio: 1; display: grid; max-width: 220px; place-items: center; position: relative; width: 100%; }
.ring svg { height: 100%; transform: rotate(-90deg); width: 100%; }
.ring circle { fill: none; stroke-width: 12; }
.ring .track { stroke: var(--surface-2); }
.ring .value { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset .5s ease; }
.ring strong { font-size: 34px; position: absolute; }
.trend { height: 160px; width: 100%; }
.layer-system { display: grid; gap: 24px; grid-template-columns: minmax(0, .78fr) minmax(360px, 1fr); align-items: center; }
.layer-copy { display: grid; gap: 16px; }
.layer-copy h2 { font-size: clamp(30px, 4.4vw, 56px); line-height: 1.02; margin: 0; }
.layer-copy p { color: var(--muted); line-height: 1.75; margin: 0; max-width: 680px; }
.layer-pills { display: flex; flex-wrap: wrap; gap: 10px; }
.layer-pill { align-items: center; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); display: inline-flex; font-size: 12px; font-weight: 900; gap: 8px; padding: 8px 11px; }
.layer-pill.active { border-color: color-mix(in srgb, var(--accent) 48%, var(--line)); color: var(--accent); }
.layer-pill i { background: currentColor; border-radius: 999px; height: 8px; width: 8px; }
.stack-visual { background: radial-gradient(circle at 50% 18%, color-mix(in srgb, var(--accent) 16%, transparent), transparent 42%), color-mix(in srgb, var(--surface) 88%, transparent); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow); min-height: 460px; overflow: hidden; position: relative; }
.stack-canvas { display: block; height: 100%; inset: 0; position: absolute; width: 100%; z-index: 2; }
.stack-fallback { inset: 0; padding: 28px; position: absolute; z-index: 1; }
.fallback-layers { display: grid; gap: 16px; height: 100%; place-content: center; }
.fallback-layer { background: color-mix(in srgb, var(--layer-color) 18%, var(--surface)); border: 1px solid color-mix(in srgb, var(--layer-color) 46%, var(--line)); border-radius: 8px; color: var(--ink); font-weight: 950; min-width: 260px; opacity: .58; padding: 18px; text-align: center; transform: perspective(520px) rotateX(54deg); }
.fallback-layer.active { box-shadow: 0 18px 60px color-mix(in srgb, var(--layer-color) 32%, transparent); opacity: 1; }
.stack-ready .stack-fallback { opacity: 0; }
.stack-caption { bottom: 16px; display: flex; flex-wrap: wrap; gap: 9px; left: 16px; position: absolute; right: 16px; z-index: 3; }
.stack-badge { align-items: center; background: color-mix(in srgb, var(--surface) 82%, transparent); border: 1px solid var(--line); border-radius: 8px; display: inline-flex; flex: 1 1 150px; gap: 9px; min-width: 0; padding: 10px; }
.stack-badge i { background: var(--badge-color); border-radius: 999px; box-shadow: 0 0 18px var(--badge-color); height: 10px; width: 10px; }
.stack-badge strong { font-size: 13px; }
.stack-badge span { color: var(--muted); font-size: 11px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.live-cta { align-items: center; background: #07101c; color: #fff; display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr) auto; overflow: hidden; padding: 26px; position: relative; }
.live-cta::after { background: radial-gradient(circle, color-mix(in srgb, var(--accent) 54%, transparent), transparent 60%); content: ""; height: 260px; opacity: .45; position: absolute; right: -80px; top: -110px; width: 260px; }
.live-cta h2 { font-size: clamp(26px, 4vw, 44px); margin: 0; position: relative; z-index: 1; }
.live-cta p { color: rgba(255, 255, 255, .74); margin: 8px 0 0; max-width: 680px; position: relative; z-index: 1; }
.live-cta .button { position: relative; z-index: 1; }
.footer { background: #07101c; color: rgba(255,255,255,.78); padding: 28px clamp(16px, 4vw, 32px); }
.footer .wrap { align-items: center; display: flex; flex-wrap: wrap; gap: 18px; justify-content: space-between; }
.footer strong { color: #fff; }
.product-network { display: flex; flex-wrap: wrap; gap: 9px; }
.product-network a { border: 1px solid rgba(255,255,255,.18); border-radius: 7px; color: #fff; font-size: 12px; font-weight: 900; padding: 8px 10px; text-decoration: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; transition-duration: .001ms !important; }
}

@media (max-width: 980px) {
  .nav-links { display: none; }
  .hero-inner { grid-template-columns: 1fr; min-height: auto; }
  .simulation-card, .simulation-canvas { min-height: 430px; }
  .metrics-row, .proof-grid, .layer-system { grid-template-columns: 1fr; }
  .stack-visual { min-height: 410px; }
  .live-cta { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .nav { padding: 0 14px; }
  .brand strong { max-width: 150px; }
  .language { max-width: 128px; }
  .nav-actions .button { display: none; }
  .hero-inner { padding-inline: 14px; }
  .simulation-card, .simulation-canvas { min-height: 380px; }
  .footer .wrap { align-items: flex-start; flex-direction: column; }
}
