:root {
  color-scheme: dark;
  --bg: #030303;
  --bg-soft: #070707;
  --surface: #0b0b0b;
  --surface-2: #111111;
  --surface-3: #171717;
  --fg: #fafafa;
  --fg-soft: #d7d7d7;
  --muted: #8f8f8f;
  --muted-2: #969696;
  --line: rgba(255, 255, 255, .1);
  --line-strong: rgba(255, 255, 255, .18);
  --ink: #070707;
  --danger: #ffb4b4;
  --radius-sm: 8px;
  --radius: 12px;
  --max: 1180px;
  --page: clamp(18px, 4vw, 64px);
  --font-display: "Geist", "Suisse Intl", "Helvetica Neue", Helvetica, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Geist", "Helvetica Neue", Helvetica, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "SFMono-Regular", "IBM Plex Mono", "JetBrains Mono", ui-monospace, Menlo, monospace;
}

* { box-sizing: border-box; }

html {
  min-width: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  min-width: 0;
  overflow-x: clip;
  background: var(--bg);
  color: var(--fg);
  font-size: 17px;
  line-height: 1.58;
  text-rendering: geometricPrecision;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(circle at 50% -16%, rgba(255, 255, 255, .22), transparent 27rem),
    linear-gradient(180deg, #050505 0%, #030303 38rem, #060606 100%);
}

a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
h1, h2, h3, p, pre { margin-top: 0; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--line);
  background: rgba(3, 3, 3, .94);
}

.nav {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
  max-width: var(--max);
  min-height: 72px;
  margin: 0 auto;
  padding: 0 var(--page);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  color: var(--fg);
  font-size: .94rem;
  font-weight: 650;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, #1d1d1d, #0a0a0a);
  color: var(--fg);
  font-family: var(--font-mono);
  font-size: .78rem;
}

.nav-links {
  display: flex;
  justify-content: center;
  gap: clamp(18px, 3vw, 36px);
  color: var(--muted);
  font-size: .88rem;
}

.nav-links a {
  padding: 8px 0;
  transition: color .16s ease;
}

.nav-links a:hover { color: var(--fg); }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  max-width: 100%;
  padding: 0 17px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  font-size: .93rem;
  font-weight: 650;
  line-height: 1;
  white-space: nowrap;
  transition: transform .16s ease, border-color .16s ease, background .16s ease, color .16s ease;
}

.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--fg); color: var(--ink); border-color: var(--fg); }
.button-secondary { background: rgba(255, 255, 255, .045); color: var(--fg); }
.button-secondary:hover { border-color: rgba(255, 255, 255, .32); background: rgba(255, 255, 255, .08); }

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--fg);
  outline-offset: 3px;
}

.hero {
  position: relative;
  overflow: hidden;
  min-height: 820px;
  border-bottom: 1px solid var(--line);
  isolation: isolate;
}

.hero-ray {
  position: absolute;
  left: 50%;
  top: -330px;
  z-index: -1;
  width: min(1160px, 110vw);
  height: 760px;
  transform: translateX(-50%);
  background:
    radial-gradient(circle at center, rgba(255, 255, 255, .38), rgba(255, 255, 255, .11) 33%, transparent 64%);
  filter: blur(18px);
  opacity: .9;
}

.hero-grid {
  position: absolute;
  inset: 0;
  z-index: -2;
  opacity: .44;
  background-image:
    linear-gradient(rgba(255, 255, 255, .09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .09) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at top center, #000 0%, transparent 76%);
}

.hero::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -1px;
  z-index: -1;
  width: min(1120px, 94vw);
  height: 230px;
  transform: translateX(-50%);
  background:
    linear-gradient(90deg, transparent, rgba(255, 255, 255, .16), transparent),
    repeating-linear-gradient(90deg, transparent 0 44px, rgba(255, 255, 255, .12) 45px, transparent 46px);
  mask-image: linear-gradient(180deg, transparent, #000 34%, transparent);
  opacity: .5;
}

.hero-inner {
  position: relative;
  display: grid;
  justify-items: center;
  max-width: 1140px;
  margin: 0 auto;
  padding: clamp(88px, 12vw, 156px) var(--page) 44px;
  text-align: center;
}

.release-link {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  margin-bottom: 28px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, .045);
  color: var(--fg-soft);
  font-size: .86rem;
}

h1 {
  max-width: 1080px;
  margin-bottom: 24px;
  font-size: clamp(3.5rem, 8.2vw, 7.05rem);
  font-weight: 610;
  line-height: .94;
  letter-spacing: 0;
  text-wrap: balance;
}

.hero-copy {
  max-width: 760px;
  margin-bottom: 30px;
  color: var(--muted);
  font-size: clamp(1.1rem, 1.6vw, 1.33rem);
  line-height: 1.56;
  text-wrap: pretty;
}

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

.hero-note {
  max-width: 690px;
  margin: 18px 0 0;
  color: var(--muted-2);
  font-size: .92rem;
  line-height: 1.5;
  text-wrap: pretty;
}

.hero-product {
  position: relative;
  max-width: min(1080px, calc(100% - (var(--page) * 2)));
  margin: clamp(34px, 5vw, 62px) auto 0;
}

.terminal-card {
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .075), transparent 36%),
    #080808;
  box-shadow: 0 34px 90px rgba(0, 0, 0, .62);
}

.terminal-top,
.code-window-top {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  min-height: 48px;
  padding: 0 16px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .78rem;
}

.dots {
  display: flex;
  gap: 6px;
}

.dots span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #383838;
}

.terminal-state {
  color: var(--fg-soft);
}

.terminal-body {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, .62fr);
  min-width: 0;
}

pre {
  min-width: 0;
  overflow: auto;
  margin: 0;
  padding: clamp(22px, 3vw, 34px);
  color: #eeeeea;
  font-family: var(--font-mono);
  font-size: .9rem;
  line-height: 1.75;
  white-space: pre;
}

.response-card {
  display: grid;
  align-content: start;
  gap: 1px;
  min-width: 0;
  border-left: 1px solid var(--line);
  background: var(--line);
}

.mono-label,
.eyebrow {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .77rem;
  font-weight: 760;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.response-card .mono-label {
  padding: 18px 20px 10px;
  background: #0d0d0d;
}

.response-row {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 14px;
  padding: 16px 20px;
  background: #0d0d0d;
}

.response-row span,
.matrix-row span,
.scenario-fields span,
.event-item span {
  color: var(--muted-2);
  font-family: var(--font-mono);
  font-size: .76rem;
  font-weight: 740;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.response-row strong {
  color: var(--fg);
  font-size: .98rem;
  line-height: 1.34;
  overflow-wrap: anywhere;
}

.trusted-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0;
  max-width: var(--max);
  margin: 0 auto;
  padding: 22px var(--page);
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .75rem;
  font-weight: 760;
  letter-spacing: .08em;
  line-height: 1.9;
  text-transform: uppercase;
}

.trusted-strip span:not(:last-child)::after {
  content: "/";
  margin: 0 12px;
  color: var(--muted-2);
}

.section,
.contact-section {
  padding: clamp(78px, 10vw, 146px) var(--page);
  border-top: 1px solid var(--line);
}

.section-header,
.code-lab,
.events-grid,
.control-matrix,
.scenario-shell,
.contact-grid {
  max-width: var(--max);
  margin: 0 auto;
}

.section-header {
  display: grid;
  justify-items: center;
  gap: 18px;
  margin-bottom: clamp(36px, 5vw, 68px);
  text-align: center;
}

.section-header.compact {
  max-width: 900px;
}

.eyebrow {
  margin: 0;
}

h2 {
  max-width: 930px;
  margin-bottom: 0;
  font-size: clamp(2.8rem, 6.2vw, 5.6rem);
  font-weight: 610;
  line-height: .98;
  letter-spacing: 0;
  text-wrap: balance;
}

.section-header > p:not(.eyebrow),
.contact-grid > div > p,
.event-detail > p {
  max-width: 710px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.62;
  text-wrap: pretty;
}

.integrate-section {
  background: linear-gradient(180deg, #030303, #070707);
}

.code-lab {
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
}

.code-tabs {
  display: flex;
  gap: 0;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
}

.code-tab {
  min-height: 54px;
  padding: 0 22px;
  border: 0;
  border-right: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  font-size: .92rem;
  font-weight: 620;
  white-space: nowrap;
}

.code-tab:hover { color: var(--fg); }
.code-tab[aria-pressed="true"] {
  background: var(--fg);
  color: var(--ink);
}

.code-window {
  min-width: 0;
}

.code-window-top {
  grid-template-columns: 1fr auto;
}

.events-section {
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, .08), transparent 28rem),
    var(--bg);
}

.events-grid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(320px, .62fr);
  gap: clamp(22px, 4vw, 54px);
  align-items: stretch;
}

.event-stream,
.event-detail,
.scenario-panel,
.contact-form {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .04), transparent),
    var(--surface);
}

.event-stream {
  overflow: hidden;
}

.event-item {
  position: relative;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 16px;
  padding: 24px;
  border-bottom: 1px solid var(--line);
}

.event-item:last-child { border-bottom: 0; }
.event-item::before {
  content: "";
  position: absolute;
  left: 92px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--line);
}

.event-item.is-active::after {
  content: "";
  position: absolute;
  left: 88px;
  top: 30px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--fg);
}

.event-item strong {
  display: block;
  margin-bottom: 7px;
  color: var(--fg);
  font-size: 1.18rem;
  line-height: 1.25;
}

.event-item p {
  grid-column: 2;
  margin: 0;
  color: var(--muted);
  font-size: .98rem;
  line-height: 1.55;
}

.event-detail {
  display: grid;
  align-content: center;
  gap: 18px;
  min-width: 0;
  padding: clamp(26px, 4vw, 44px);
}

.event-detail h3,
.scenario-panel h3 {
  margin: 0;
  color: var(--fg);
  font-size: clamp(2rem, 3.8vw, 3.9rem);
  font-weight: 610;
  line-height: 1;
  letter-spacing: 0;
  text-wrap: balance;
}

.controls-section {
  background: var(--bg-soft);
}

.limits-section {
  background: linear-gradient(180deg, #050505, #030303);
}

.control-matrix {
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--line);
}

.matrix-row {
  display: grid;
  grid-template-columns: 130px minmax(220px, .48fr) minmax(0, 1fr);
  gap: clamp(18px, 3vw, 42px);
  align-items: start;
  padding: clamp(24px, 3.4vw, 40px);
  background: var(--surface);
}

.matrix-row + .matrix-row {
  border-top: 1px solid var(--line);
}

.matrix-row strong {
  color: var(--fg);
  font-size: clamp(1.3rem, 2.2vw, 2rem);
  font-weight: 610;
  line-height: 1.14;
}

.matrix-row p {
  margin: 0;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.58;
}

.limits-panel {
  display: grid;
  max-width: var(--max);
  margin: 0 auto;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--line);
}

.limit-row {
  display: grid;
  grid-template-columns: 74px minmax(220px, .46fr) minmax(0, 1fr);
  gap: clamp(18px, 3vw, 42px);
  align-items: start;
  padding: clamp(24px, 3.2vw, 38px);
  background: #080808;
}

.limit-row + .limit-row {
  border-top: 1px solid var(--line);
}

.limit-row span {
  color: var(--muted-2);
  font-family: var(--font-mono);
  font-size: .76rem;
  font-weight: 740;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.limit-row strong {
  color: var(--fg);
  font-size: clamp(1.22rem, 2vw, 1.82rem);
  font-weight: 610;
  line-height: 1.14;
}

.limit-row p {
  margin: 0;
  color: var(--muted);
  font-size: 1.02rem;
  line-height: 1.58;
}

.scenario-section {
  background:
    radial-gradient(circle at 50% 15%, rgba(255, 255, 255, .08), transparent 25rem),
    var(--bg);
}

.scenario-shell {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 16px;
}

.scenario-tabs {
  display: grid;
  align-content: start;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
}

.scenario-option {
  width: 100%;
  min-height: 56px;
  padding: 0 18px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--muted);
  text-align: left;
  font-size: .96rem;
  font-weight: 620;
}

.scenario-option:last-child { border-bottom: 0; }
.scenario-option:hover { color: var(--fg); }
.scenario-option[aria-pressed="true"] {
  background: var(--fg);
  color: var(--ink);
}

.scenario-panel {
  min-width: 0;
  padding: clamp(26px, 4vw, 46px);
}

.scenario-panel > p {
  max-width: 760px;
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 1.1rem;
  line-height: 1.6;
}

.scenario-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin-top: 34px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--line);
}

.scenario-fields div {
  min-width: 0;
  padding: 20px;
  background: #0f0f0f;
}

.scenario-fields span {
  display: block;
  margin-bottom: 12px;
}

.scenario-fields strong {
  display: block;
  color: var(--fg);
  font-size: 1.08rem;
  line-height: 1.38;
  overflow-wrap: anywhere;
}

.contact-section {
  border-bottom: 1px solid var(--line);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, .88fr) minmax(340px, .62fr);
  gap: clamp(32px, 5vw, 76px);
  align-items: start;
}

.contact-grid h2 {
  max-width: 780px;
}

.contact-form {
  display: grid;
  gap: 16px;
  min-width: 0;
  padding: clamp(20px, 3vw, 30px);
}

.field {
  display: grid;
  gap: 8px;
  min-width: 0;
}

label {
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: .76rem;
  font-weight: 760;
  letter-spacing: .08em;
  text-transform: uppercase;
}

input,
select,
textarea {
  width: 100%;
  min-width: 0;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #070707;
  color: var(--fg);
  padding: 12px 14px;
  outline: none;
}

input::placeholder,
textarea::placeholder { color: #8f8f8f; }
input:focus,
select:focus,
textarea:focus { border-color: rgba(255, 255, 255, .45); }
[aria-invalid="true"] { border-color: var(--danger); }

.form-status {
  min-height: 44px;
  margin: 0;
  color: var(--muted);
  font-size: .93rem;
  line-height: 1.5;
}

.form-status.is-error {
  color: var(--danger);
}

.form-status.is-success {
  color: var(--fg-soft);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 26px var(--page);
  color: var(--muted-2);
  font-size: .84rem;
}

@media (max-width: 1060px) {
  .terminal-body,
  .events-grid,
  .scenario-shell,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .response-card {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .matrix-row {
    grid-template-columns: 110px minmax(0, 1fr);
  }

  .matrix-row p,
  .limit-row p {
    grid-column: 2;
  }

  .limit-row {
    grid-template-columns: 74px minmax(0, 1fr);
  }

  .scenario-fields {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 860px) {
  .nav {
    grid-template-columns: auto auto;
    justify-content: space-between;
    gap: 10px 18px;
    padding-block: 10px;
  }

  .nav-links {
    display: flex;
    grid-column: 1 / -1;
    justify-content: flex-start;
    gap: 18px;
    min-width: 0;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .nav-links::-webkit-scrollbar {
    display: none;
  }

  .hero {
    min-height: auto;
  }

  .event-item,
  .matrix-row,
  .limit-row {
    grid-template-columns: 1fr;
  }

  .event-item::before,
  .event-item.is-active::after {
    display: none;
  }

  .event-item p,
  .matrix-row p,
  .limit-row p {
    grid-column: auto;
  }
}

@media (max-width: 620px) {
  body {
    font-size: 16px;
  }

  .brand span:last-child {
    display: none;
  }

  .nav {
    min-height: 66px;
  }

  .nav-cta {
    min-height: 44px;
    padding-inline: 13px;
  }

  .hero-inner {
    justify-items: start;
    padding-top: 72px;
    text-align: left;
  }

  h1 {
    font-size: clamp(3rem, 15vw, 4.6rem);
  }

  h2 {
    font-size: clamp(2.35rem, 12vw, 3.4rem);
  }

  .hero-actions,
  .hero-actions .button {
    width: 100%;
  }

  .release-link {
    border-radius: var(--radius-sm);
    line-height: 1.35;
    padding-block: 8px;
  }

  .terminal-top {
    grid-template-columns: auto 1fr;
  }

  .terminal-state {
    display: none;
  }

  .hero-product {
    max-width: calc(100% - 24px);
  }

  pre {
    font-size: .78rem;
  }

  .response-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .code-tab {
    min-height: 50px;
    padding-inline: 16px;
  }

  .footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
