/*
 * jonna.dev styles: the landing page and the sign-in page.
 * Dark is the reference look; the light theme follows the system setting.
 */

@font-face {
  font-family: "Instrument Sans";
  src: url("/fonts/InstrumentSans-Variable.woff2") format("woff2");
  font-weight: 400 700;
  font-stretch: 75% 100%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/fonts/JetBrainsMono-Variable.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --font-ui: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, "SF Pro Text", Inter, Ubuntu, "Noto Sans", sans-serif;
  --font-display: "Instrument Sans", "Segoe UI Variable Display", "Segoe UI", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "JetBrains Mono", "Cascadia Code", "SF Mono", Menlo, Consolas, monospace;

  --page-max: 1180px;
  --gutter: 20px;
  --header-h: 64px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 24px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);

  --bg: #08080a;
  --bg-raised: #111114;
  --bg-sunken: #050506;
  --surface: linear-gradient(180deg, rgb(255 255 255 / 0.055), rgb(255 255 255 / 0.018));
  --surface-solid: #101013;
  --bg-input: rgb(255 255 255 / 0.04);
  --bg-hover: rgb(255 255 255 / 0.06);
  --fg: #f5f5f6;
  --fg-muted: #a3a3ad;
  --fg-subtle: #7d7d88;
  --border: rgb(255 255 255 / 0.08);
  --border-strong: rgb(255 255 255 / 0.16);
  --hairline: rgb(255 255 255 / 0.06);
  --accent: #4d8dff;
  --success: #4cc38a;
  --danger: #f27474;
  --wash: #12141c;
  --title-dim: #85858f;
  --btn-shadow: 0 1px 0 rgb(255 255 255 / 0.5) inset, 0 8px 24px -8px rgb(255 255 255 / 0.25);
  --shot-shadow: 0 0 0 1px rgb(0 0 0 / 0.7), 0 50px 120px -30px rgb(0 0 0 / 0.9);
  --card-shadow: 0 1px 0 rgb(255 255 255 / 0.05) inset, 0 20px 40px -24px rgb(0 0 0 / 0.8);
  --autofill-bg: #17171b;
  --word: rgb(255 255 255 / 0.08);
  --logo-filter: none;
  --shot-dark: block;
  --shot-light: none;
}

/* Light: when the system is light (unless the toggle says dark), or when the toggle says light. */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    color-scheme: light;
    --bg: #fbfbfa;
    --bg-raised: #ffffff;
    --bg-sunken: #f1f1ef;
    --surface: linear-gradient(180deg, #ffffff, #fafaf8);
    --surface-solid: #ffffff;
    --bg-input: #ffffff;
    --bg-hover: rgb(0 0 0 / 0.04);
    --fg: #121214;
    --fg-muted: #55555e;
    --fg-subtle: #6c6c76;
    --border: rgb(0 0 0 / 0.09);
    --border-strong: rgb(0 0 0 / 0.18);
    --hairline: rgb(0 0 0 / 0.07);
    --accent: #2b6fd1;
    --success: #18794a;
    --danger: #be3333;
    --wash: #edf0f7;
      --title-dim: #8a8a94;
    --btn-shadow: 0 8px 24px -10px rgb(0 0 0 / 0.45);
    --shot-shadow: 0 0 0 1px rgb(0 0 0 / 0.08), 0 50px 100px -30px rgb(20 30 60 / 0.3);
    --card-shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 16px 32px -24px rgb(20 30 60 / 0.25);
    --shot-dark: none;
    --shot-light: block;
    --autofill-bg: #ffffff;
    --word: rgb(0 0 0 / 0.07);
    --logo-filter: invert(0.9);
  }
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #fbfbfa;
  --bg-raised: #ffffff;
  --bg-sunken: #f1f1ef;
  --surface: linear-gradient(180deg, #ffffff, #fafaf8);
  --surface-solid: #ffffff;
  --bg-input: #ffffff;
  --bg-hover: rgb(0 0 0 / 0.04);
  --fg: #121214;
  --fg-muted: #55555e;
  --fg-subtle: #6c6c76;
  --border: rgb(0 0 0 / 0.09);
  --border-strong: rgb(0 0 0 / 0.18);
  --hairline: rgb(0 0 0 / 0.07);
  --accent: #2b6fd1;
  --success: #18794a;
  --danger: #be3333;
  --wash: #edf0f7;
  --title-dim: #8a8a94;
  --btn-shadow: 0 8px 24px -10px rgb(0 0 0 / 0.45);
  --shot-shadow: 0 0 0 1px rgb(0 0 0 / 0.08), 0 50px 100px -30px rgb(20 30 60 / 0.3);
  --card-shadow: 0 1px 2px rgb(0 0 0 / 0.04), 0 16px 32px -24px rgb(20 30 60 / 0.25);
  --shot-dark: none;
  --shot-light: block;
  --autofill-bg: #ffffff;
  --word: rgb(0 0 0 / 0.07);
  --logo-filter: invert(0.9);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 24px); }
body {
  position: relative;
  margin: 0;
  overflow-x: clip;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: inherit; }
img { max-width: 100%; }
[hidden] { display: none !important; }
h1, h2, h3, p { margin: 0; }
::selection { background: rgb(77 141 255 / 0.35); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

.container { max-width: var(--page-max); margin: 0 auto; padding: 0 var(--gutter); }
@media (min-width: 768px) { :root { --gutter: 32px; } }

/* A soft linear wash behind the top of the page. */
.backdrop {
  position: absolute;
  inset: 0 0 auto 0;
  height: 760px;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(180deg, var(--wash), var(--bg));
}

/* ---------------------------------------------------------------- header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
  backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid var(--hairline);
}
.site-header .container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 19px;
  letter-spacing: -0.02em;
  text-decoration: none;
}
.brand img { width: 26px; height: 26px; }
/* The mark is drawn light; on the light theme it is inverted to read on a pale page. */
.brand img, img.mark { filter: var(--logo-filter); }
.header-left { display: flex; align-items: center; gap: 28px; min-width: 0; }
.header-nav { display: flex; align-items: center; gap: 22px; }
.nav-link[aria-current="page"] { color: var(--fg); }
/* A small dropdown in the header (the Legal menu). Works without JavaScript; home.js closes it
   on an outside click or Escape. */
.menu { position: relative; }
.menu summary { display: inline-flex; align-items: center; gap: 4px; list-style: none; cursor: pointer; user-select: none; }
.menu summary::-webkit-details-marker { display: none; }
.menu summary svg { width: 12px; height: 12px; transition: transform 150ms var(--ease); }
.menu[open] summary { color: var(--fg); }
.menu[open] summary svg { transform: rotate(180deg); }
.menu-list {
  position: absolute;
  top: calc(100% + 14px);
  left: -14px;
  display: grid;
  min-width: 190px;
  padding: 6px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface-solid);
  box-shadow: 0 20px 44px -16px rgb(0 0 0 / 0.55), 0 0 0 1px var(--hairline);
}
.menu-list a {
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--fg-muted);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: color 120ms var(--ease), background 120ms var(--ease);
}
.menu-list a:hover, .menu-list a:focus-visible { background: var(--bg-hover); color: var(--fg); }
.menu-list a[aria-current="page"] { color: var(--fg); }
.header-actions { display: flex; align-items: center; gap: 18px; min-height: 34px; }
.nav-link { color: var(--fg-muted); font-size: 14px; font-weight: 500; text-decoration: none; transition: color 150ms var(--ease); }
.nav-link:hover { color: var(--fg); }

.account-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 14px 0 5px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-input);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  max-width: 220px;
  transition: border-color 150ms var(--ease), background 150ms var(--ease);
}
.account-chip:hover { border-color: var(--border-strong); background: var(--bg-hover); }
.account-chip span.name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar {
  width: 24px;
  height: 24px;
  flex: none;
  border-radius: 50%;
  object-fit: cover;
  display: grid;
  place-items: center;
  background: var(--border-strong);
  font-size: 12px;
  font-weight: 600;
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.icon-btn {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-input);
  color: var(--fg-muted);
  transition: color 150ms var(--ease), border-color 150ms var(--ease), background 150ms var(--ease);
}
.icon-btn svg { width: 16px; height: 16px; }
a.icon-btn:hover { color: var(--fg); border-color: var(--border-strong); background: var(--bg-hover); }
.icon-btn.is-soon { opacity: 0.55; cursor: default; }
.theme-toggle {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-input);
  color: var(--fg-muted);
  cursor: pointer;
  transition: color 150ms var(--ease), border-color 150ms var(--ease), background 150ms var(--ease);
}
.theme-toggle:hover { color: var(--fg); border-color: var(--border-strong); background: var(--bg-hover); }
.theme-toggle svg { display: none; width: 16px; height: 16px; }
.theme-toggle[data-mode="system"] .i-system,
.theme-toggle[data-mode="dark"] .i-dark,
.theme-toggle[data-mode="light"] .i-light { display: block; }
@media (max-width: 600px) { .hide-sm { display: none; } }
@media (max-width: 480px) {
  .header-left { gap: 14px; }
  .header-nav { gap: 12px; }
  .nav-link { font-size: 13.5px; }
  .brand { gap: 8px; font-size: 17px; }
  .header-actions { gap: 10px; }
  .account-chip span.name { display: none; }
  .account-chip { padding: 0 5px; }
}

/* ---------------------------------------------------------------- buttons */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 38px;
  padding: 0 18px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-input);
  color: var(--fg);
  font: inherit;
  font-size: 14px;
  font-weight: 550;
  letter-spacing: -0.005em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 150ms var(--ease), background 150ms var(--ease), border-color 150ms var(--ease), box-shadow 150ms var(--ease), opacity 150ms var(--ease);
}
.btn:hover { border-color: var(--border-strong); background: var(--bg-hover); }
.btn:active { transform: translateY(1px); }
.btn svg { width: 16px; height: 16px; flex: none; }
.btn-sm { height: 32px; padding: 0 14px; font-size: 13.5px; }
.btn-lg { height: 50px; padding: 0 26px; font-size: 16px; }
.btn-primary { background: var(--fg); border-color: transparent; color: var(--bg); box-shadow: var(--btn-shadow); }
.btn-primary:hover { background: var(--fg); border-color: transparent; transform: translateY(-1px); }
.btn-primary:active { transform: translateY(0); }
.btn-ghost { background: transparent; }
.btn-block { width: 100%; height: 46px; font-size: 15px; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; box-shadow: none; }
.btn[disabled]:hover { transform: none; }

.link {
  background: none;
  border: 0;
  padding: 0;
  color: var(--fg-muted);
  font: inherit;
  font-size: 14px;
  text-decoration: underline;
  text-decoration-color: var(--border-strong);
  text-underline-offset: 4px;
  cursor: pointer;
  transition: color 150ms var(--ease);
}
.link:hover { color: var(--fg); }

/* ---------------------------------------------------------------- hero */

.hero { padding: clamp(64px, 10vw, 128px) 0 0; text-align: center; }
/* Headlines: the first line in the text color, the second line (a span) dimmer. */
.display {
  font-family: var(--font-display);
  font-weight: 500;
  text-wrap: balance;
  color: var(--fg);
}
.display span { display: block; color: var(--title-dim); }
.hero-title {
  font-size: clamp(42px, 7.2vw, 92px);
  line-height: 1;
  letter-spacing: -0.05em;
  padding-bottom: 0.08em; /* room for descenders under the clipped gradient */
}
.hero-sub {
  max-width: 36em;
  margin: 28px auto 0;
  color: var(--fg-muted);
  font-size: clamp(17px, 1.6vw, 20px);
  line-height: 1.6;
  text-wrap: balance;
}
.cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 36px; }
.fineprint { margin-top: 22px; color: var(--fg-subtle); font-size: 13.5px; }

.tags { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 0 0 28px; padding: 0; list-style: none; }
.tags li {
  padding: 4px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-input);
  color: var(--fg-muted);
  font-family: var(--font-mono);
  font-size: 12.5px;
  line-height: 20px;
  letter-spacing: 0.01em;
}

/* A product screenshot in a thin bezel, lit from behind. */
.shot { position: relative; margin: clamp(48px, 7vw, 88px) auto 0; }
.bezel {
  padding: clamp(4px, 0.8vw, 10px);
  border: 1px solid var(--border);
  border-radius: clamp(14px, 2vw, 26px);
  background: linear-gradient(180deg, rgb(255 255 255 / 0.07), rgb(255 255 255 / 0.02));
  box-shadow: var(--shot-shadow);
}
.bezel img {
  width: 100%;
  height: auto;
  border-radius: clamp(10px, 1.4vw, 18px);
  border: 1px solid var(--hairline);
}
.for-dark { display: var(--shot-dark); }
.for-light { display: var(--shot-light); }

/* ---------------------------------------------------------------- sections */

.section { padding: clamp(96px, 12vw, 168px) 0 0; }
.sec-head { max-width: 780px; margin: 0 auto; text-align: center; }
.kicker {
  display: inline-block;
  margin-bottom: 18px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.sec-title {
  font-size: clamp(32px, 4.6vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.04em;
  padding-bottom: 0.08em;
}
.sec-sub {
  max-width: 34em;
  margin: 22px auto 0;
  color: var(--fg-muted);
  font-size: clamp(16px, 1.5vw, 19px);
  text-wrap: balance;
}

/* cards */
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 56px; }
.card {
  position: relative;
  padding: 32px;
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--card-shadow);
  overflow: hidden;
  min-width: 0;
  transition: border-color 200ms var(--ease), transform 200ms var(--ease);
}
.card:hover { border-color: var(--border-strong); transform: translateY(-2px); }
.card > * { position: relative; }
.card .icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 22px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg-input);
  color: var(--fg);
  box-shadow: 0 1px 0 rgb(255 255 255 / 0.06) inset;
}
.card .icon svg { width: 20px; height: 20px; }
.card .label {
  display: block;
  margin-bottom: 10px;
  color: var(--fg-subtle);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.card h3 { font-family: var(--font-display); font-size: 22px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.25; }
.card p { margin-top: 10px; color: var(--fg-muted); font-size: 15.5px; line-height: 1.65; }

.stackline {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-top: 40px;
  color: var(--fg-subtle);
  font-family: var(--font-mono);
  font-size: 13px;
}
.stackline i { width: 4px; height: 4px; border-radius: 50%; background: var(--border-strong); }

/* The diagram sits directly on the page. */
.diagram { margin-top: clamp(40px, 6vw, 72px); }

/* ---------- screenshot switcher ---------- */
.switch { display: flex; justify-content: center; margin-top: 40px; }
.switch-bar {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--bg-input);
  max-width: 100%;
  overflow-x: auto;
}
.switch-bar button {
  height: 36px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--fg-muted);
  font: inherit;
  font-size: 14px;
  font-weight: 550;
  white-space: nowrap;
  cursor: pointer;
  transition: color 150ms var(--ease), background 150ms var(--ease);
}
.switch-bar button:hover { color: var(--fg); }
.switch-bar button[aria-selected="true"] { background: var(--fg); color: var(--bg); }
.switch-caption { min-height: 1.6em; margin-top: 18px; color: var(--fg-muted); font-size: 15px; text-align: center; }
.shot--switch { margin-top: 28px; }
.shot--switch .pane[hidden] { display: none; }

/* ---------- logo marquee ---------- */
.strip { padding-top: clamp(56px, 7vw, 96px); }
.marquee-label { margin-bottom: 26px; color: var(--fg-subtle); font-size: 14px; text-align: center; }
.marquee {
  display: flex;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee + .marquee { margin-top: 12px; }
.marquee-track {
  display: flex;
  flex: none;
  gap: 12px;
  margin: 0;
  padding: 0 12px 0 0;
  list-style: none;
  animation: marquee 70s linear infinite;
}
.marquee--reverse .marquee-track { animation-direction: reverse; animation-duration: 80s; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track li {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 9px;
  height: 44px;
  padding: 0 20px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface);
  color: var(--fg-muted);
  font-size: 14px;
  font-weight: 550;
  white-space: nowrap;
}
.logo-mark { display: inline-grid; place-items: center; flex: none; }
.marquee-track .logo-mark, .marquee-track .logo-mark svg { width: 18px; height: 18px; }
@keyframes marquee { to { transform: translateX(-100%); } }

/* ---------- command diagram ---------- */
.cmd-diagram {
  --c-sky: #5aa2ff;
  --c-mint: #4cc38a;
  position: relative;
  display: grid;
  grid-template-columns: 22% 16% 24% 16% 22%;
  aspect-ratio: 1000 / 400;
  width: 100%;
}
.cmd-wires { position: absolute; inset: 0; width: 100%; height: 100%; fill: none; }
.cmd-wires .wire { stroke: var(--border-strong); stroke-width: 1.5; }
.pulse { stroke-width: 7; stroke-linecap: round; stroke-dasharray: 0.4 99.6; stroke-dashoffset: 100; opacity: 0; }
.pulses--in .pulse { stroke: var(--c-sky); }
.pulses--out .pulse { stroke: var(--c-mint); }
.is-playing .pulse { opacity: 1; animation: travel 2.6s linear infinite; }
.is-playing .pulses--out .pulse { animation-delay: 1.3s; }
.is-playing .pulse:nth-child(2) { animation-duration: 3.1s; }
.is-playing .pulse:nth-child(3) { animation-duration: 2.2s; }
.is-playing .pulse:nth-child(4) { animation-duration: 3.4s; }
.is-playing .pulse:nth-child(5) { animation-duration: 2.8s; }
.is-playing .pulse:nth-child(6) { animation-duration: 2.4s; }
@keyframes travel { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }
.cmd-col {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  margin: 0;
  padding: 0;
  list-style: none;
}
.cmd-sources { grid-column: 1; }
.cmd-targets { grid-column: 5; }
.cmd-col li {
  display: grid;
  place-items: center;
  height: clamp(32px, 4.2vw, 46px);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--surface-solid);
  box-shadow: 0 1px 0 rgb(255 255 255 / 0.05) inset;
  font-size: 14px;
  font-weight: 550;
}
.cmd-hub {
  position: relative;
  grid-column: 3;
  align-self: center;
  display: grid;
  gap: 10px;
  padding: 26px 22px;
  border: 1px solid rgb(255 255 255 / 0.18);
  border-radius: var(--r-xl);
  background: #2b6fd1;
  box-shadow: 0 1px 0 rgb(255 255 255 / 0.25) inset, 0 16px 32px -16px rgb(0 0 0 / 0.6);
  color: #fff;
  text-align: center;
}
.cmd-hub-label { color: rgb(255 255 255 / 0.8); font-size: 13px; font-weight: 600; line-height: 1; }
.cmd-hub strong { font: 500 22px / 1.2 var(--font-display); letter-spacing: -0.02em; }
.cmd-ticker { margin: 0; padding: 0; list-style: none; }
.cmd-ticker li + li { display: none; }
.fx-ready .cmd-ticker li { display: none; }
.fx-ready .cmd-ticker li.is-active { display: block; animation: tick-in 0.35s var(--ease); }
@keyframes tick-in { from { opacity: 0; transform: translateY(6px); } }
.cmd-ticker code {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--r-sm);
  background: rgb(0 0 0 / 0.28);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 13px;
}
.cmd-checks { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.cmd-checks span {
  padding: 2px 9px;
  border: 1px solid rgb(255 255 255 / 0.3);
  border-radius: var(--r-sm);
  color: rgb(255 255 255 / 0.85);
  font-size: 12px;
}

/* ---------------------------------------------------------------- closing + footer */

.closing {
  position: relative;
  margin-top: clamp(96px, 12vw, 168px);
  padding: clamp(56px, 9vw, 120px) clamp(20px, 5vw, 64px);
  border: 1px solid var(--border);
  border-radius: clamp(20px, 3vw, 32px);
  background: linear-gradient(180deg, var(--wash), transparent), var(--surface);
  box-shadow: var(--card-shadow);
  text-align: center;
  overflow: hidden;
}
.closing img.mark { width: 56px; height: 56px; margin-bottom: 28px; }
.closing p { max-width: 30em; margin: 22px auto 0; color: var(--fg-muted); font-size: clamp(16px, 1.5vw, 19px); text-wrap: balance; }

.site-footer { margin-top: clamp(72px, 9vw, 120px); border-top: 1px solid var(--hairline); color: var(--fg-subtle); font-size: 14px; overflow: hidden; }
.site-footer .container { padding-top: 56px; padding-bottom: 36px; }
.site-footer a { color: var(--fg-muted); text-decoration: none; transition: color 150ms var(--ease); }
.site-footer a:hover { color: var(--fg); }
.footer-top { display: grid; grid-template-columns: 1.7fr repeat(3, 1fr); gap: 40px 32px; }
.footer-pitch .brand { font-size: 17px; color: var(--fg); }
.footer-pitch .brand img { width: 22px; height: 22px; }
.footer-pitch p { max-width: 20em; margin-top: 12px; color: var(--fg-subtle); font-size: 14.5px; }
.footer-col h4 { margin: 0 0 14px; color: var(--fg); font-size: 13.5px; font-weight: 600; }
.footer-col ul { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.footer-col .soon { color: var(--fg-subtle); }
/* The name, very large, fading into the page. */
.footer-word {
  margin: 56px 0 0;
  font-family: var(--font-display);
  font-size: clamp(96px, 24vw, 300px);
  font-weight: 600;
  line-height: 0.82;
  letter-spacing: -0.06em;
  text-align: center;
  background: linear-gradient(180deg, var(--word), transparent 92%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  user-select: none;
}
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  margin-top: 8px;
  padding-top: 24px;
  border-top: 1px solid var(--hairline);
  font-size: 13px;
}
@media (max-width: 760px) {
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-pitch { grid-column: 1 / -1; }
}

/* ---------------------------------------------------------------- text pages */

.page { padding-top: clamp(48px, 7vw, 96px); }
.narrow { max-width: 800px; }
.subnav { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 40px; }
.subnav a {
  padding: 5px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--fg-muted);
  font-size: 13.5px;
  font-weight: 550;
  text-decoration: none;
  transition: color 150ms var(--ease), border-color 150ms var(--ease), background 150ms var(--ease);
}
.subnav a:hover { color: var(--fg); border-color: var(--border-strong); }
.subnav a[aria-current="page"] { background: var(--fg); border-color: transparent; color: var(--bg); }
.page-title { font-size: clamp(36px, 5.2vw, 60px); line-height: 1.05; letter-spacing: -0.04em; padding-bottom: 0.08em; }
.page-lead { max-width: 34em; margin-top: 16px; color: var(--fg-muted); font-size: clamp(17px, 1.6vw, 20px); }
.updated { margin-top: 18px; color: var(--fg-subtle); font-family: var(--font-mono); font-size: 12.5px; letter-spacing: 0.02em; }
.prose { margin-top: 44px; padding-top: 8px; border-top: 1px solid var(--hairline); color: var(--fg-muted); font-size: 16.5px; line-height: 1.75; }
.prose h2 { margin: 44px 0 12px; color: var(--fg); font-family: var(--font-display); font-size: 24px; font-weight: 600; line-height: 1.25; letter-spacing: -0.02em; }
.prose p { margin-top: 14px; }
.prose ul { margin: 14px 0 0; padding-left: 22px; }
.prose li + li { margin-top: 8px; }
.prose li::marker { color: var(--fg-subtle); }
.prose strong { color: var(--fg); font-weight: 600; }
.prose a { color: var(--fg); text-decoration: underline; text-decoration-color: var(--border-strong); text-underline-offset: 4px; }
.prose a:hover { text-decoration-color: currentColor; }
.prose code { padding: 2px 6px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg-input); color: var(--fg); font-family: var(--font-mono); font-size: 0.88em; }
.prose .note { margin-top: 44px; padding-top: 20px; border-top: 1px solid var(--hairline); color: var(--fg-subtle); font-size: 14.5px; }
.table-scroll { margin-top: 18px; overflow-x: auto; }
table.rights { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 15.5px; line-height: 1.5; }
table.rights th, table.rights td { padding: 14px 16px 14px 0; border-bottom: 1px solid var(--hairline); text-align: left; vertical-align: top; }
table.rights thead th { color: var(--fg-subtle); font-size: 13px; font-weight: 600; }
table.rights tbody th { color: var(--fg); font-weight: 500; }
table.rights td { width: 44%; padding-right: 0; }
table.rights td.yes { color: var(--success); }
table.rights td.no { color: var(--fg); font-weight: 600; }

/* ---------------------------------------------------------------- motion */

.fx-ready .reveal { opacity: 0; transform: translateY(18px); transition: opacity 700ms var(--ease), transform 700ms var(--ease); }
.fx-ready .reveal.in { opacity: 1; transform: none; }
.fx-ready .reveal.d1 { transition-delay: 80ms; }
.fx-ready .reveal.d2 { transition-delay: 160ms; }
.fx-ready .reveal.d3 { transition-delay: 240ms; }

@media (max-width: 900px) {
  .grid { grid-template-columns: 1fr; }
  .card { padding: 26px; }
  /* The diagram stacks: callers, the dispatcher, then what it drives. */
  .cmd-diagram { display: flex; flex-direction: column; gap: 24px; aspect-ratio: auto; }
  .cmd-wires { display: none; }
  .cmd-col { flex-direction: row; flex-wrap: wrap; justify-content: center; gap: 6px; }
  .cmd-col li { height: 36px; padding: 0 16px; }
  .cmd-hub { align-self: stretch; }
  .cmd-hub::before, .cmd-hub::after {
    content: "";
    position: absolute;
    left: 50%;
    width: 2px;
    height: 24px;
    background: var(--border-strong);
  }
  .cmd-hub::before { bottom: 100%; }
  .cmd-hub::after { top: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .marquee-track, .is-playing .pulse { animation: none; }
  .is-playing .pulse { opacity: 0; }
  .marquee { flex-wrap: wrap; -webkit-mask-image: none; mask-image: none; }
  .marquee-track { flex: 1 1 100%; flex-wrap: wrap; justify-content: center; padding: 0; }
  .marquee-track[aria-hidden="true"] { display: none; }
  .btn, .card { transition: none; }
}

/* ---------------------------------------------------------------- download */

.os-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: clamp(48px, 6vw, 72px); text-align: left; }
.os-card {
  display: flex;
  flex-direction: column;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--card-shadow);
  min-width: 0;
}
.os-card.is-yours { border-color: var(--border-strong); }
.os-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.os-card .icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg-input);
  color: var(--fg);
}
.os-card .icon svg { width: 22px; height: 22px; }
.os-card h2 { margin-top: 24px; font-family: var(--font-display); font-size: 26px; font-weight: 600; letter-spacing: -0.025em; line-height: 1.2; }
.os-card p { margin-top: 6px; color: var(--fg-muted); font-size: 15px; }
.os-card p.yours { color: var(--success); font-size: 13.5px; }
.os-card .btn { margin-top: 26px; }
.os-card .btn[aria-disabled="true"] { background: transparent; color: var(--fg-muted); opacity: 1; cursor: default; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 900px) { .os-cards, .grid-3 { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- pricing */

.hero--page { padding-top: clamp(56px, 8vw, 104px); }
.hero--page .hero-title { font-size: clamp(40px, 6vw, 76px); }
.plans { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: clamp(48px, 6vw, 72px); text-align: left; }
.plan {
  display: flex;
  flex-direction: column;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--card-shadow);
  min-width: 0;
}
.plan--now { border-color: var(--border-strong); }
.plan-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.plan h2 { font-family: var(--font-display); font-size: 20px; font-weight: 600; letter-spacing: -0.02em; }
.badge {
  padding: 2px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--fg-subtle);
  font-size: 12px;
  font-weight: 550;
  line-height: 20px;
  white-space: nowrap;
}
.badge--now { border-color: color-mix(in srgb, var(--success) 40%, transparent); color: var(--success); }
.plan-price {
  margin-top: 22px;
  color: var(--fg);
  font-family: var(--font-display);
  font-size: 46px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.04em;
}
.plan-price small { margin-left: 6px; color: var(--fg-muted); font-family: var(--font-ui); font-size: 15px; font-weight: 400; letter-spacing: 0; }
.plan-note { margin-top: 10px; color: var(--fg-muted); font-size: 14.5px; }
.plan .btn { margin-top: 24px; }
.plan .btn[aria-disabled="true"] { background: transparent; color: var(--fg-muted); opacity: 1; cursor: default; }
.plan-intro { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--hairline); color: var(--fg); font-size: 14px; font-weight: 600; }
.plan ul { display: grid; gap: 10px; margin: 14px 0 0; padding: 0; list-style: none; color: var(--fg-muted); font-size: 14.5px; line-height: 1.5; }
.plan li { position: relative; padding-left: 24px; }
.plan li::before { content: "✓"; position: absolute; left: 0; color: var(--success); font-weight: 600; }

/* The commercial license: its own card, under the plans. */
.license-card {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  align-items: center;
  gap: 40px clamp(40px, 6vw, 88px);
  margin-top: 16px;
  padding: clamp(32px, 5vw, 64px);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--card-shadow);
  text-align: left;
}
.license-card .kicker {
  display: block;
  margin-bottom: 16px;
  color: var(--fg-subtle);
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.license-card h2 { font-family: var(--font-display); font-size: clamp(28px, 3.4vw, 42px); font-weight: 500; line-height: 1.08; letter-spacing: -0.035em; text-wrap: balance; }
.license-main > p { max-width: 30em; margin-top: 16px; color: var(--fg-muted); font-size: 17px; line-height: 1.6; }
.license-price { display: flex; align-items: center; gap: 20px; margin-top: 32px; padding-top: 28px; border-top: 1px solid var(--hairline); }
.license-price .plan-price { margin: 0; font-size: 40px; }
.license-price span:last-child { max-width: 24em; color: var(--fg-muted); font-size: 14.5px; line-height: 1.5; }
.license-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; margin-top: 32px; }

.license-card .license-list { display: block; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--hairline); }
.license-card .license-list li {
  position: relative;
  padding: 24px 0 24px 44px;
  border-bottom: 1px solid var(--hairline);
}
.license-card .license-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 24px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid color-mix(in srgb, var(--success) 40%, transparent);
  border-radius: 50%;
  color: var(--success);
  font-size: 13px;
  font-weight: 600;
}
.license-list strong { display: block; color: var(--fg); font-family: var(--font-display); font-size: 19px; font-weight: 600; letter-spacing: -0.015em; line-height: 1.3; }
.license-list span { display: block; margin-top: 4px; color: var(--fg-muted); font-size: 15px; line-height: 1.55; }

.matrix-wrap { margin-top: 48px; }
table.matrix { width: 100%; min-width: 760px; border-collapse: collapse; font-size: 14.5px; line-height: 1.45; }
table.matrix th, table.matrix td { padding: 14px 12px; border-bottom: 1px solid var(--hairline); vertical-align: middle; }
table.matrix tbody th { width: 34%; padding-left: 0; color: var(--fg-muted); font-weight: 400; text-align: left; }
table.matrix td { color: var(--fg-muted); text-align: center; }
table.matrix thead th { padding-bottom: 18px; border-bottom-color: var(--border-strong); text-align: center; vertical-align: bottom; }
.matrix-name { display: block; color: var(--fg); font-family: var(--font-display); font-size: 17px; font-weight: 600; }
.matrix-price { display: block; margin-top: 2px; color: var(--fg-subtle); font-size: 13px; font-weight: 400; }
table.matrix tr.matrix-group th {
  padding: 30px 0 10px;
  color: var(--fg);
  font-size: 13px;
  font-weight: 600;
  text-align: left;
}
.tick { color: var(--success); font-weight: 600; }
.dash { color: var(--fg-subtle); }

.faq { margin-top: 40px; border-top: 1px solid var(--hairline); }
.faq details { border-bottom: 1px solid var(--hairline); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  color: var(--fg);
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -0.015em;
  list-style: none;
  cursor: pointer;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; color: var(--fg-subtle); font-family: var(--font-ui); font-size: 22px; font-weight: 400; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq p { max-width: 44em; padding-bottom: 22px; color: var(--fg-muted); font-size: 16px; line-height: 1.7; }
.faq a { color: var(--fg); text-decoration: underline; text-decoration-color: var(--border-strong); text-underline-offset: 4px; }

@media (max-width: 1040px) {
  .plans { grid-template-columns: repeat(2, 1fr); }
  .license-card { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .plans { grid-template-columns: 1fr; }
  .license-price { flex-direction: column; align-items: flex-start; gap: 10px; }
}

/* ---------------------------------------------------------------- sign-in page */

.auth-body { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
.auth-top { display: flex; align-items: center; justify-content: space-between; padding: 16px var(--gutter); }
.auth-page { flex: 1; display: grid; place-items: center; padding: 16px var(--gutter) 88px; }
.auth-card { width: 100%; max-width: 380px; }
.card-head { margin-bottom: 32px; text-align: center; }
.card-head img.mark { width: 52px; height: 52px; margin-bottom: 22px; }
.card-head h1 {
  font-family: var(--font-display);
  font-size: clamp(30px, 4vw, 38px);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.04em;
}
.card-head p { margin-top: 8px; color: var(--fg-muted); font-size: 15px; }

.stack { display: grid; gap: 10px; }
.divider { display: flex; align-items: center; gap: 12px; margin: 22px 0; color: var(--fg-subtle); font-size: 13px; }
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }

label { display: grid; gap: 7px; color: var(--fg-muted); font-size: 14px; font-weight: 500; }
input[type="text"], input[type="email"], input[type="password"] {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg-input);
  color: var(--fg);
  font: inherit;
  font-size: 15px;
  transition: border-color 150ms var(--ease), box-shadow 150ms var(--ease);
}
input:hover { border-color: var(--border-strong); }
input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px rgb(77 141 255 / 0.18); }
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--fg);
  caret-color: var(--fg);
  box-shadow: 0 0 0 1000px var(--autofill-bg) inset;
  transition: background-color 99999s ease-out;
}
input:-webkit-autofill:focus { box-shadow: 0 0 0 1000px var(--autofill-bg) inset, 0 0 0 4px rgb(77 141 255 / 0.18); }
input:autofill { background: var(--autofill-bg); color: var(--fg); }
.row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 6px; }
.center { text-align: center; }
.mt { margin-top: 20px; }
.muted { color: var(--fg-muted); font-size: 14px; }

.msg { margin: 16px 0 0; min-height: 22px; font-size: 14px; line-height: 22px; }
.msg.error { color: var(--danger); }
.msg.ok { color: var(--success); }

.who {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
  margin-bottom: 16px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg-input);
  text-align: left;
}
.who .avatar { width: 40px; height: 40px; font-size: 16px; }
.who strong { display: block; font-weight: 600; line-height: 1.3; }
.who span.email { color: var(--fg-muted); font-size: 14px; word-break: break-all; }

.spinner {
  width: 22px;
  height: 22px;
  margin: 12px auto;
  border: 2px solid var(--border-strong);
  border-top-color: var(--fg);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 2.4s; } }
