/* WebChat.si — The Web Chat Lab
   A precise, ledger-like interface: white canvas, midnight ink, one indigo accent,
   whisper-weight Helvetica, hairline rules. Depth only where product UI floats. */

:root {
  --canvas: #ffffff;
  --band: #f6f9fc;
  --frost: #e5edf5;
  --frost-2: #d8e2ee;
  --ink: #061b31;
  --body: #3c4f64;
  --slate: #64748d;
  --smoke: #839bc8;
  --indigo: #533afd;
  --indigo-hover: #4329e6;
  --indigo-soft: #7389ff;
  --lavender: #b9b9f9;
  --lilac: #d6d9fc;
  --wash: #e8e9ff;
  --wash-2: #f3f3ff;
  --navy: #0a2540;
  --navy-2: #0f3057;
  --navy-line: rgba(255, 255, 255, 0.12);
  --on-navy: #ffffff;
  --on-navy-2: #adbdcc;
  --bubble: #eef2f7;
  --error: #c0123c;

  --font: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --container: 1200px;
  --pad: clamp(16px, 4.5vw, 40px);
  --gap: clamp(16px, 2.4vw, 32px);
  --section: clamp(72px, 9vw, 112px);

  --r-btn: 4px;
  --r: 6px;
  --r-ui: 10px;

  --float: 0 50px 100px -20px rgba(50, 50, 93, 0.22), 0 30px 60px -30px rgba(0, 0, 0, 0.26);
  --float-sm: 0 13px 27px -5px rgba(50, 50, 93, 0.2), 0 8px 16px -8px rgba(0, 0, 0, 0.24);

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 92px; }
@media (max-width: 920px) { html { scroll-padding-top: 16px; } }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--canvas);
  color: var(--body);
  font: 400 1.0625rem/1.65 var(--font);
  letter-spacing: -0.004em;
  font-feature-settings: "tnum" 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
h1, h2, h3, h4, p, ul, ol, dl, dd, figure, blockquote { margin: 0; }
ul[class], ol[class] { list-style: none; padding: 0; }
h1, h2, h3, h4 { color: var(--ink); font-weight: 400; text-wrap: balance; }
p, li, dd { text-wrap: pretty; }
img, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
button { cursor: pointer; }
strong, b { font-weight: 500; color: var(--ink); }
a { color: var(--indigo); text-decoration: none; transition: color 150ms ease; }
a:hover { color: var(--ink); }
code { font-family: var(--mono); font-size: 0.86em; background: var(--band); color: var(--ink); padding: 0.12em 0.4em; border-radius: 4px; border: 1px solid var(--frost); }
pre { margin: 0; overflow-x: auto; background: var(--navy); color: #e3ebf4; padding: 20px 22px; border-radius: var(--r); font: 400 0.84rem/1.7 var(--mono); }
pre code { background: none; border: 0; padding: 0; font-size: inherit; color: inherit; }
hr { border: 0; border-top: 1px solid var(--frost); margin: 0; }
::selection { background: var(--wash); color: var(--ink); }

:focus-visible { outline: 2px solid var(--indigo); outline-offset: 2px; border-radius: 4px; }
main:focus { outline: none; }

.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--r-btn); }
.skip-link:focus { top: 12px; color: #fff; }

.container { width: min(100% - 2 * var(--pad), var(--container)); margin-inline: auto; }
.muted { color: var(--slate); }
.small { font-size: 0.9375rem; }
.xs { font-size: 0.8125rem; }

/* ---------- Type ---------- */
.display {
  font-size: clamp(2.9rem, 1.6rem + 4.4vw, 5.25rem);
  line-height: 1;
  letter-spacing: -0.045em;
  font-weight: 700;
}
.title {
  font-size: clamp(1.9rem, 1.4rem + 1.7vw, 2.85rem);
  line-height: 1.08;
  letter-spacing: -0.032em;
  font-weight: 500;
  max-width: 20ch;
}
.title--lg { font-size: clamp(2.3rem, 1.6rem + 2.5vw, 3.5rem); max-width: 18ch; letter-spacing: -0.038em; }
.title .soft, .display .soft { color: #8a9ab0; }
.lead { font-size: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem); line-height: 1.55; letter-spacing: -0.01em; font-weight: 400; color: var(--body); }
.h3 { font-size: clamp(1.35rem, 1.2rem + 0.5vw, 1.625rem); line-height: 1.15; letter-spacing: -0.02em; font-weight: 500; }

/* ---------- Buttons & links ---------- */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 20px;
  border: 1px solid transparent; border-radius: var(--r-btn);
  font: 400 0.9375rem/1 var(--font); letter-spacing: -0.005em;
  white-space: nowrap;
  transition: background-color 150ms ease, color 150ms ease, border-color 150ms ease, transform 160ms var(--ease-out);
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.button:active { transform: scale(0.97); }
.button--primary { background: var(--indigo); color: #fff; }
.button--primary:hover { background: var(--indigo-hover); color: #fff; }
.button--ghost { background: transparent; color: var(--indigo); border-color: var(--lavender); }
.button--ghost:hover { border-color: var(--indigo); color: var(--indigo); background: var(--wash-2); }
.button--light { background: #fff; color: var(--navy); }
.button--light:hover { background: var(--wash); color: var(--navy); }
.button--on-dark { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.35); }
.button--on-dark:hover { border-color: #fff; color: #fff; }
.button--sm { height: 36px; padding: 0 14px; font-size: 0.875rem; }
.button[disabled] { opacity: 0.45; cursor: not-allowed; transform: none; }
.button .chev { font-size: 1.1em; line-height: 1; transform: translateY(-1px); transition: transform 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .button:hover .chev { transform: translate(2px, -1px); } }

.link { display: inline-flex; align-items: center; gap: 4px; font-weight: 400; color: var(--indigo); }
.link::after { content: "\203A"; font-size: 1.15em; line-height: 1; transform: translateY(-1px); transition: transform 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .link:hover::after { transform: translate(3px, -1px); } }
.link:hover { color: var(--ink); }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, 0.96); border-bottom: 1px solid var(--frost); transition: background-color 200ms ease, border-color 200ms ease; }
.site-header__inner { height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { margin: 0; line-height: 1; }
.brand__mark { font-size: 1.3125rem; font-weight: 700; letter-spacing: -0.045em; color: var(--ink); }
.brand__mark:hover { color: var(--ink); }
.brand__tld { color: var(--indigo); }
.site-nav { display: flex; align-items: center; gap: 20px; }
.site-nav__list { display: flex; align-items: center; gap: 2px; }
.site-nav__link { display: block; padding: 9px 13px; border-radius: 6px; font-size: 0.96875rem; font-weight: 500; color: var(--ink); transition: color 150ms ease, background-color 150ms ease; }
.site-nav__link:hover { color: var(--indigo); background: var(--wash-2); }
.site-nav__link[aria-current="page"] { color: var(--indigo); }
.site-nav__cta { height: 38px; font-weight: 500; }
.nav-toggle { display: none; height: 40px; padding: 0 14px; border: 1px solid var(--frost-2); border-radius: 6px; background: #fff; font-size: 0.9375rem; font-weight: 500; color: var(--ink); }

.has-menu { position: relative; }
.menu { position: absolute; left: -12px; top: 100%; padding-top: 10px; width: 340px; visibility: hidden; opacity: 0; transform: translateY(-4px); transition: opacity 150ms ease, transform 180ms var(--ease-out), visibility 0s linear 180ms; }
.menu__list, .menu__all { background: #fff; }
.menu__list { border-radius: 10px 10px 0 0; padding: 8px; box-shadow: 0 0 0 1px var(--frost), var(--float-sm); display: grid; gap: 2px; }
.menu__item { display: block; padding: 10px 12px; border-radius: 6px; color: var(--ink); }
.menu__item b { display: block; font-weight: 500; font-size: 0.9375rem; }
.menu__item span { display: block; font-size: 0.8125rem; color: var(--slate); margin-top: 1px; }
.menu__item:hover, .menu__item[aria-current="page"] { background: var(--wash-2); color: var(--indigo); }
.menu__all { display: block; padding: 12px 20px; border-radius: 0 0 10px 10px; background: var(--band); box-shadow: 0 0 0 1px var(--frost), var(--float-sm); font-size: 0.875rem; font-weight: 500; clip-path: inset(0 -40px -40px -40px); }
@media (hover: hover) and (min-width: 921px) {
  .has-menu:hover .menu { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
}
@media (min-width: 921px) {
  .has-menu:focus-within .menu { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
}

/* Home: the header sits on the gradient until the page scrolls. */
.page-home main { margin-top: -69px; }
.page-home .site-header:not(.is-scrolled):not(.is-open) { background: transparent; border-bottom-color: transparent; }
.page-home .site-header:not(.is-scrolled):not(.is-open) .brand__mark,
.page-home .site-header:not(.is-scrolled):not(.is-open) .site-nav__link { color: #fff; }
.page-home .site-header:not(.is-scrolled):not(.is-open) .brand__tld { color: #ffd8a8; }
.page-home .site-header:not(.is-scrolled):not(.is-open) .site-nav__link:hover { background: rgba(255, 255, 255, 0.14); color: #fff; }
.page-home .site-header:not(.is-scrolled):not(.is-open) .site-nav__cta { background: #fff; color: var(--indigo); }
.page-home .site-header:not(.is-scrolled):not(.is-open) .site-nav__cta:hover { background: var(--wash); }
.page-home .site-header:not(.is-scrolled):not(.is-open) .nav-toggle { background: rgba(255, 255, 255, 0.14); border-color: rgba(255, 255, 255, 0.5); color: #fff; }
.page-home .site-header:not(.is-scrolled):not(.is-open) :focus-visible { outline-color: #fff; }

@media (max-width: 920px) {
  .site-header { position: relative; }
  .page-home .site-header { position: absolute; left: 0; right: 0; }
  .page-home main { margin-top: 0; }
  .nav-toggle { display: inline-flex; align-items: center; }
  .site-header__inner { height: auto; min-height: 64px; flex-wrap: wrap; padding-block: 12px; }
  .site-nav { display: none; width: 100%; flex-direction: column; align-items: stretch; gap: 16px; padding: 8px 0 20px; }
  .site-nav[data-open] { display: flex; }
  .site-nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .site-nav__link { font-size: 1.25rem; padding: 12px 0; border-radius: 0; border-bottom: 1px solid var(--frost); }
  .site-nav__link:hover { background: none; }
  .menu { position: static; width: auto; padding: 0 0 8px; visibility: visible; opacity: 1; transform: none; }
  .menu__list { box-shadow: none; padding: 4px 0 0; background: none; }
  .menu__item { padding: 10px 0 10px 14px; border-left: 2px solid var(--frost); border-radius: 0; }
  .menu__all { display: none; }
  .site-nav__cta { height: 46px; }
}

/* ---------- Sections ---------- */
.section { padding-top: var(--section); }
.section--ruled > .container { border-top: 1px solid var(--frost); padding-top: var(--section); }
.section__head { margin-bottom: clamp(40px, 5vw, 64px); }
.section__head .lead { margin-top: 20px; max-width: 52ch; }
.section__head--split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gap); align-items: end; }
.section__intro { color: var(--slate); font-size: 1.125rem; font-weight: 500; line-height: 1.5; max-width: 40ch; padding-bottom: 6px; }
@media (max-width: 820px) { .section__head--split { grid-template-columns: 1fr; gap: 18px; } }

/* ---------- Chat primitives ---------- */
.chat-log { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; }
.msg { display: flex; flex-direction: column; max-width: 86%; }
.msg--visitor { align-self: flex-end; align-items: flex-end; }
.msg--bot { align-self: flex-start; align-items: flex-start; }
.bubble { padding: 9px 13px; border-radius: 14px; font-size: 0.9375rem; line-height: 1.45; overflow-wrap: anywhere; color: var(--ink); }
.bubble p + p { margin-top: 0.55em; }
.msg--visitor .bubble { background: var(--indigo); color: #fff; border-bottom-right-radius: 4px; }
.msg--bot .bubble { background: var(--bubble); border-bottom-left-radius: 4px; }
.msg__source { display: flex; align-items: center; gap: 6px; margin-top: 6px; padding-left: 2px; font-size: 0.75rem; color: var(--slate); }
.msg__source::before { content: ""; width: 10px; height: 10px; border-radius: 2px; flex: none; background: var(--wash); box-shadow: inset 0 0 0 1px var(--lavender); }
.msg--system { align-self: stretch; max-width: 100%; font-size: 0.75rem; color: var(--slate); display: flex; align-items: center; gap: 10px; padding: 4px 0; text-align: center; }
.msg--system::before, .msg--system::after { content: ""; flex: 1 1 24px; min-width: 16px; height: 1px; background: var(--frost-2); }
.msg--enter { animation: msg-in 260ms var(--ease-out) both; }
@keyframes msg-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Hero ---------- */
.hero { position: relative; isolation: isolate; padding-top: calc(69px + clamp(56px, 7vw, 100px)); padding-bottom: clamp(40px, 5vw, 72px); }
.hero__band {
  position: absolute; z-index: -1; left: 0; right: 0; top: 0; height: var(--band-h, 840px); overflow: hidden;
  clip-path: polygon(0 0, 100% 0, 100% 72%, 0 100%);
  background:
    radial-gradient(60% 70% at 18% 30%, #4a2bd6 0%, transparent 70%),
    radial-gradient(45% 60% at 55% 20%, #d6127f 0%, transparent 70%),
    radial-gradient(40% 55% at 85% 55%, #57c4f5 0%, transparent 70%),
    radial-gradient(40% 45% at 70% 85%, #ffb03a 0%, transparent 70%),
    #6b3bff;
}
.hero__gl { position: absolute; inset: 0; }
.hero__gl canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; opacity: 0; transition: opacity 1s ease; }
.hero__gl.is-ready canvas { opacity: 1; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.hero__title { color: #fff; font-size: clamp(3rem, 1.5rem + 4.9vw, 5.6rem); line-height: 0.98; letter-spacing: -0.048em; font-weight: 700; max-width: 9.2em; text-wrap: balance; }
.hero__lead { margin-top: 28px; max-width: 34ch; color: rgba(255, 255, 255, 0.94); font-size: clamp(1.125rem, 1.04rem + 0.4vw, 1.3125rem); line-height: 1.5; }
.hero__actions { margin-top: 36px; }
.hero__note { margin-top: 18px; font-size: 0.9375rem; color: rgba(255, 255, 255, 0.9); max-width: 34ch; }
.hero__note a { color: #fff; text-decoration: underline; text-decoration-color: rgba(255, 255, 255, 0.5); text-underline-offset: 0.2em; }
.hero__note a:hover { text-decoration-color: #fff; }
.button--white { background: #fff; color: var(--indigo); font-weight: 500; }
.button--white:hover { background: var(--wash); color: var(--indigo-hover); }
.button--glass { background: rgba(255, 255, 255, 0.12); color: #fff; border-color: rgba(255, 255, 255, 0.55); font-weight: 500; }
.button--glass:hover { background: rgba(255, 255, 255, 0.2); border-color: #fff; color: #fff; }
.hero :focus-visible { outline-color: #fff; }
.hero .widget :focus-visible { outline-color: var(--indigo); }

.hero__product { position: relative; height: 680px; margin-top: -16px; }
.widget {
  position: absolute; right: 0; top: 0; width: min(100%, 372px); height: 540px;
  display: flex; flex-direction: column;
  background: #fff; border-radius: 14px; box-shadow: var(--float); overflow: hidden;
}
.widget__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 18px; background: var(--navy); color: #fff; }
.widget__name { font-weight: 500; font-size: 1rem; color: #fff; }
.widget__meta { font-size: 0.78125rem; color: var(--on-navy-2); margin-top: 2px; }
.widget__reset { border: 1px solid rgba(255, 255, 255, 0.3); background: none; padding: 6px 10px; border-radius: 6px; font-size: 0.8125rem; color: #fff; }
.widget__reset:hover { border-color: #fff; }
.widget .widget__log { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 18px 16px; scrollbar-width: thin; }
.widget__foot { padding: 12px 14px 14px; border-top: 1px solid var(--frost); background: #fff; }
.widget__prompt { font-size: 0.8125rem; color: var(--slate); padding: 0 2px 8px; }
.suggest { display: grid; gap: 6px; }
.suggest button, .suggest a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%;
  border: 1px solid var(--lilac); border-radius: 8px; padding: 10px 13px; background: #fff;
  font-size: 0.90625rem; font-weight: 500; text-align: left; line-height: 1.3; color: var(--indigo);
  transition: background-color 150ms ease, border-color 150ms ease, transform 160ms var(--ease-out);
}
.suggest button::after, .suggest a::after { content: "\203A"; font-size: 1.15em; line-height: 1; }
.suggest button:hover, .suggest a:hover { background: var(--wash-2); border-color: var(--lavender); color: var(--indigo); }
.suggest button:active, .suggest a:active { transform: scale(0.985); }

.note {
  position: absolute; right: 150px; top: 556px; width: min(300px, 80%); z-index: 2;
  background: var(--navy); color: var(--on-navy-2); border-radius: 10px; padding: 16px 18px 18px;
  box-shadow: var(--float-sm); font-size: 0.90625rem; line-height: 1.5;
}
.note__title { display: flex; align-items: center; gap: 8px; font-weight: 500; color: #fff; margin-bottom: 4px; }
.note__title::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: #ffb03a; }
.note--swap .note__text, .note--swap .note__title { animation: note-in 240ms var(--ease-out) both; }
@keyframes note-in { from { opacity: 0; filter: blur(2px); } to { opacity: 1; filter: none; } }
.hero__caption { position: absolute; right: 0; bottom: 18px; font-size: 0.8125rem; color: var(--slate); }

@media (max-width: 1000px) {
  .hero { --band-h: 740px; }
  .hero__band {
    clip-path: polygon(0 0, 100% 0, 100% 88%, 0 100%);
    background:
      radial-gradient(70% 60% at 20% 30%, #4a2bd6 0%, transparent 70%),
      radial-gradient(60% 55% at 85% 20%, #b0106f 0%, transparent 70%),
      #5a30f0;
  }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__product { margin: 48px auto 0; width: min(100%, 560px); height: 700px; }
  .widget { left: 0; right: 0; margin-inline: auto; }
  .note { left: 0; right: auto; }
}
@media (max-width: 600px) {
  .hero { --band-h: 800px; padding-top: 112px; }
  .hero__product { height: auto; display: flex; flex-direction: column; gap: 12px; margin-top: 40px; }
  .widget, .note { position: relative; width: 100%; top: auto; right: auto; left: auto; }
  .widget { height: 500px; }
  .hero__caption { position: static; }
}

/* ---------- Lab overview (three tools) ---------- */
.tools { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.tool { display: flex; flex-direction: column; color: var(--body); }
.tool:hover { color: var(--body); }
.tool__visual { height: 208px; border-radius: var(--r); background: var(--band); border: 1px solid var(--frost); padding: 22px; display: flex; flex-direction: column; justify-content: center; overflow: hidden; transition: border-color 200ms ease, background-color 200ms ease; }
.tool:hover .tool__visual { border-color: var(--lilac); background: var(--wash-2); }
.tool h3 { margin-top: 24px; font-size: 1.5rem; font-weight: 500; letter-spacing: -0.02em; line-height: 1.15; }
.tool p { margin-top: 10px; font-size: 0.96875rem; line-height: 1.55; max-width: 36ch; flex: 1; }
.tool .link { margin-top: 16px; }
.tool__visual .chat-log { gap: 7px; }
.tool__visual .bubble { font-size: 0.78125rem; padding: 7px 11px; }
.tool__visual .msg--bot .bubble { background: #fff; border: 1px solid var(--frost); }
.tool__ann { display: grid; gap: 8px; }
.tool__ann p { background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: 8px 10px; font-size: 0.75rem; line-height: 1.4; color: var(--body); }
.tool__ann b { display: block; font-weight: 500; color: var(--indigo); font-size: 0.71875rem; }
.tool__metric { display: grid; gap: 4px; }
.tool__metric b { font-size: 3rem; font-weight: 500; letter-spacing: -0.04em; line-height: 1; color: var(--ink); }
.tool__metric span { font-size: 0.78125rem; color: var(--slate); }
.tool__bars { margin-top: 16px; display: grid; gap: 7px; }
.tool__bars i { display: block; height: 6px; border-radius: 3px; background: var(--frost-2); overflow: hidden; }
.tool__bars i::before { content: ""; display: block; height: 100%; width: 50%; background: var(--indigo); border-radius: inherit; }
.tool__bars i:nth-child(1)::before { width: 34%; background: var(--lavender); }
.tool__bars i:nth-child(2)::before { width: 58%; }
.tool__bars i:nth-child(3)::before { width: 82%; background: var(--indigo-soft); }
@media (max-width: 960px) { .tools { grid-template-columns: 1fr; } }

/* ---------- Scenario cards ---------- */
.cards-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gap); }
.scenario { display: flex; flex-direction: column; height: 100%; color: var(--body); }
.scenario:hover { color: var(--body); }
.scenario__stage { position: relative; height: 232px; padding: 26px 22px; display: flex; flex-direction: column; justify-content: center; border-radius: var(--r); border: 1px solid var(--frost); transition: border-color 200ms ease; }
.scenario:hover .scenario__stage { border-color: var(--lavender); }
.scenario--sand .scenario__stage { background: #fbf6ef; }
.scenario--mist .scenario__stage { background: var(--wash-2); }
.scenario--sage .scenario__stage { background: #f1f7f5; }
.scenario__stage .chat-log { gap: 8px; }
.scenario__stage .msg { max-width: 90%; }
.scenario__stage .bubble { font-size: 0.84375rem; padding: 8px 12px; }
.scenario__stage .msg--bot .bubble { background: #fff; border: 1px solid var(--frost); }
.scenario__body { padding-top: 22px; display: flex; flex-direction: column; flex: 1; }
.scenario__name { font-size: 1.5rem; font-weight: 500; letter-spacing: -0.02em; line-height: 1.15; }
.scenario__type { margin-top: 4px; font-size: 0.875rem; color: var(--slate); }
.scenario__text { margin-top: 12px; font-size: 0.96875rem; line-height: 1.55; flex: 1; }
.scenario__go { margin-top: 16px; }
@media (max-width: 960px) {
  .cards-3 { grid-template-columns: 1fr; }
  .scenario__stage { height: auto; min-height: 190px; }
}

/* ---------- Feature showcases ---------- */
.features { display: grid; gap: clamp(64px, 8vw, 112px); }
.feature { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.feature--flip .feature__text { order: 2; }
.feature__text p { margin-top: 16px; max-width: 40ch; font-size: 1.0625rem; line-height: 1.6; }
.feature__text .link { margin-top: 20px; }
.stage { position: relative; border-radius: var(--r); background: linear-gradient(135deg, var(--band), var(--wash-2)); border: 1px solid var(--frost); padding: clamp(32px, 4.5vw, 64px) clamp(20px, 4vw, 56px) clamp(48px, 5vw, 76px); min-height: 400px; display: flex; align-items: center; justify-content: center; }
.stage__wrap { position: relative; width: min(100%, 420px); }
.stage__card { background: #fff; border-radius: var(--r-ui); box-shadow: var(--float-sm); padding: 18px 16px 20px; }
.stage__card-head { display: flex; justify-content: space-between; align-items: baseline; font-size: 0.8125rem; padding: 0 2px 12px; margin-bottom: 14px; border-bottom: 1px solid var(--frost); }
.stage__card-head b { font-weight: 500; }
.stage__card-head span { color: var(--slate); }
.callout {
  position: absolute; z-index: 2; right: -28px; bottom: -24px; max-width: 250px;
  display: flex; align-items: baseline; gap: 9px;
  background: var(--navy); color: #fff; border-radius: var(--r); padding: 10px 14px;
  font-size: 0.84375rem; line-height: 1.35; box-shadow: var(--float-sm);
}
.callout::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 2px; background: var(--indigo-soft); }
.feature--flip .callout { right: auto; left: -28px; }
@media (max-width: 1100px) {
  .callout { right: -12px; }
  .feature--flip .callout { left: -12px; }
}
@media (max-width: 900px) {
  .feature { grid-template-columns: 1fr; }
  .feature--flip .feature__text { order: 0; }
  .stage { min-height: 0; padding: 24px 16px 44px; }
  .callout, .feature--flip .callout { right: 8px; left: auto; bottom: -22px; max-width: calc(100% - 16px); }
}

/* ---------- Dark band (workload) ---------- */
.band-dark { margin-top: var(--section); padding-block: var(--section); background: var(--navy); color: var(--on-navy-2); }
.band-dark .title { color: #fff; }
.band-dark .title .soft { color: #7d93ad; }
.workload { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(40px, 6vw, 96px); align-items: center; }
.workload__copy p { margin-top: 22px; max-width: 40ch; font-size: 1.0625rem; font-weight: 500; line-height: 1.55; }
.workload__copy .actions { margin-top: 32px; }
.mini-calc { background: var(--navy-2); border-radius: var(--r); padding: clamp(24px, 3.4vw, 40px); border: 1px solid var(--navy-line); }
.mini-calc__result { display: flex; align-items: baseline; gap: 16px; flex-wrap: wrap; padding-bottom: 26px; border-bottom: 1px solid var(--navy-line); }
.mini-calc__num { font-size: clamp(3.4rem, 2.4rem + 3.4vw, 5.25rem); line-height: 0.9; letter-spacing: -0.05em; font-weight: 400; color: #fff; font-variant-numeric: tabular-nums; }
.mini-calc__unit { color: var(--on-navy-2); font-size: 0.96875rem; max-width: 20ch; line-height: 1.35; }
.slider { padding-top: 22px; }
.slider__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: 0.9375rem; }
.slider__row label { color: var(--on-navy-2); }
.slider__row output { color: #fff; font-variant-numeric: tabular-nums; }
.range { --p: 50%; display: block; width: 100%; margin: 12px 0 0; height: 22px; background: transparent; -webkit-appearance: none; appearance: none; cursor: pointer; }
.range:focus-visible { outline-color: #fff; outline-offset: 4px; }
.range::-webkit-slider-runnable-track { height: 3px; border-radius: 3px; background: linear-gradient(to right, var(--indigo-soft) var(--p), rgba(255, 255, 255, 0.16) var(--p)); }
.range::-moz-range-track { height: 3px; border-radius: 3px; background: rgba(255, 255, 255, 0.16); }
.range::-moz-range-progress { height: 3px; border-radius: 3px; background: var(--indigo-soft); }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; margin-top: -7.5px; border-radius: 50%; background: #fff; border: 0; box-shadow: 0 0 0 5px rgba(115, 137, 255, 0.28), 0 2px 6px rgba(0, 0, 0, 0.4); transition: transform 160ms var(--ease-out); }
.range:active::-webkit-slider-thumb { transform: scale(1.12); }
.range::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 0; box-shadow: 0 0 0 5px rgba(115, 137, 255, 0.28), 0 2px 6px rgba(0, 0, 0, 0.4); }
.mini-calc__foot { margin-top: 24px; font-size: 0.8125rem; line-height: 1.5; }
@media (max-width: 900px) { .workload { grid-template-columns: 1fr; } }

/* ---------- Guide cards ---------- */
.guide-cards { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gap); }
.guide-card { display: flex; flex-direction: column; color: var(--body); }
.guide-card:hover { color: var(--body); }
.guide-card__visual { border-radius: var(--r); background: var(--band); border: 1px solid var(--frost); padding: 20px; margin-bottom: 24px; min-height: 196px; display: flex; align-items: stretch; transition: border-color 200ms ease; }
.guide-card:hover .guide-card__visual { border-color: var(--lavender); }
.guide-card h3 { font-size: clamp(1.4rem, 1.2rem + 0.7vw, 1.75rem); line-height: 1.15; letter-spacing: -0.022em; font-weight: 500; max-width: 24ch; }
.guide-card p { margin-top: 12px; font-size: 0.96875rem; max-width: 46ch; flex: 1; }
.guide-card .link { margin-top: 16px; }
.modes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; width: 100%; }
.mode { background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.mode b { font-size: 0.875rem; }
.mode span { font-size: 0.75rem; color: var(--slate); line-height: 1.4; }
.mini { display: flex; flex-direction: column; gap: 5px; margin-bottom: 8px; }
.mini i { display: block; height: 8px; border-radius: 4px; }
.mini__v { width: 44%; align-self: flex-end; background: var(--indigo); }
.mini__b { width: 80%; background: var(--frost); }
.mini__b2 { width: 56%; background: var(--frost); }
.mini__p { width: 72%; background: var(--lilac); }
.mini__p2 { width: 48%; background: var(--lilac); }
.mini .mini__h { height: 8px; width: 100%; border-radius: 0; background: linear-gradient(var(--frost-2), var(--frost-2)) center / 100% 1px no-repeat; position: relative; }
.mini__h::after { content: ""; position: absolute; left: 50%; top: 50%; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 2px; background: var(--indigo); }
.snippet { width: 100%; background: var(--navy); color: #c7d3e0; border-radius: var(--r); padding: 18px; font: 400 0.78125rem/1.75 var(--mono); display: flex; flex-direction: column; justify-content: center; overflow: hidden; }
.snippet .t { color: #fff; }
.snippet .a { color: #a5b4ff; }
.snippet .c { color: #6f86a0; }
@media (max-width: 900px) { .guide-cards { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .modes { grid-template-columns: 1fr; } }

/* ---------- Next step (product recommendation) ---------- */
.next { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.next__lead { margin-top: 20px; font-size: 1.125rem; font-weight: 500; line-height: 1.55; color: var(--slate); max-width: 44ch; }
.next .actions { margin-top: 32px; }
.next__fine { margin-top: 20px; font-size: 0.78125rem; color: var(--slate); max-width: 52ch; }
.checks { display: grid; border-top: 1px solid var(--frost); }
.checks li { padding: 18px 0 18px 30px; border-bottom: 1px solid var(--frost); position: relative; }
.checks li::before { content: ""; position: absolute; left: 2px; top: 23px; width: 12px; height: 6px; border-left: 1.5px solid var(--indigo); border-bottom: 1.5px solid var(--indigo); transform: rotate(-45deg); }
.checks b { display: block; font-weight: 400; color: var(--ink); }
.checks span { display: block; margin-top: 2px; font-size: 0.9375rem; color: var(--slate); }
@media (max-width: 900px) { .next { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { margin-top: var(--section); padding: 64px 0 36px; background: var(--band); border-top: 1px solid var(--frost); }
.site-footer__grid { display: grid; grid-template-columns: minmax(0, 5fr) repeat(3, minmax(0, 2fr)); gap: 40px var(--gap); }
.site-footer__brand p { margin-top: 14px; font-size: 0.9375rem; max-width: 34ch; line-height: 1.55; color: var(--slate); }
.site-footer__head { font-size: 0.875rem; color: var(--ink); margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; display: grid; gap: 10px; font-size: 0.9375rem; }
.site-footer ul a { color: var(--slate); }
.site-footer ul a:hover { color: var(--indigo); }
.site-footer__base { margin-top: 56px; padding-top: 24px; border-top: 1px solid var(--frost); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 0.8125rem; color: var(--slate); }
.site-footer__base a { color: var(--slate); text-decoration: underline; text-decoration-color: var(--frost-2); text-underline-offset: 0.2em; }
@media (max-width: 960px) {
  .site-footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-footer__brand { grid-column: 1 / -1; }
}

/* ---------- Inner page head ---------- */
.page-head { padding-top: clamp(48px, 6vw, 88px); padding-bottom: clamp(32px, 4vw, 56px); }
.page-head .title--lg { max-width: 17ch; }
.page-head .lead { margin-top: 24px; max-width: 50ch; }
.page-head__meta { margin-top: 20px; font-size: 0.875rem; color: var(--slate); }

/* ---------- Shared: cards, tables, disclosure ---------- */
.panel-card { background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: clamp(20px, 2.6vw, 32px); }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; line-height: 1.5; }
.table caption { text-align: left; font-size: 0.8125rem; color: var(--slate); padding-bottom: 12px; }
.table th, .table td { text-align: left; vertical-align: top; padding: 14px 20px 14px 0; border-bottom: 1px solid var(--frost); }
.table thead th { font-weight: 400; font-size: 0.8125rem; color: var(--slate); border-bottom: 1px solid var(--frost-2); padding-top: 0; }
.table tbody th { font-weight: 400; color: var(--ink); }
.table td:last-child, .table th:last-child { padding-right: 0; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.table td p + p { margin-top: 6px; }

.disclosure { border-bottom: 1px solid var(--frost); }
.disclosure > summary { list-style: none; cursor: pointer; padding: 13px 0; display: flex; justify-content: space-between; gap: 16px; align-items: baseline; color: var(--ink); font-size: 0.9375rem; }
.disclosure > summary::-webkit-details-marker { display: none; }
.disclosure > summary::after { content: "+"; color: var(--indigo); font-size: 1.1rem; line-height: 1; }
.disclosure[open] > summary::after { content: "\2212"; }
.disclosure__body { padding: 0 0 16px; font-size: 0.9375rem; }
.disclosure__body p + p { margin-top: 8px; }

/* ============ Demo page ============ */
.demo-head { align-items: end; }
.demo-title { max-width: 21ch; }
.page-head:has(.demo-head) { padding-bottom: clamp(24px, 3vw, 40px); }
.demo-head .lead { margin-top: 18px; }
.mode-note { border: 1px solid var(--frost); border-radius: var(--r); background: var(--band); padding: 16px 18px; font-size: 0.875rem; line-height: 1.5; max-width: 42ch; justify-self: end; }
.mode-note b { display: flex; align-items: center; gap: 8px; color: var(--ink); margin-bottom: 4px; font-size: 0.9375rem; font-weight: 400; }
.mode-note b::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--indigo); }
@media (max-width: 820px) { .mode-note { justify-self: start; } }

.lab { background: linear-gradient(135deg, var(--band), var(--wash-2)); border: 1px solid var(--frost); border-radius: var(--r); padding: clamp(10px, 1.6vw, 20px); }
.lab__bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 2px 2px 14px; }
.lab__env { font-size: 0.8125rem; color: var(--slate); padding-right: 8px; }
.segmented { display: flex; gap: 2px; padding: 3px; background: #fff; border: 1px solid var(--frost); border-radius: 8px; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.segmented__item { display: flex; flex-direction: column; gap: 1px; padding: 8px 16px 9px; border-radius: 5px; color: var(--slate); white-space: nowrap; transition: background-color 180ms ease, color 180ms ease; }
.segmented__item b { font-size: 0.9375rem; font-weight: 400; color: inherit; }
.segmented__item span { font-size: 0.75rem; }
.segmented__item:hover { color: var(--ink); }
.segmented__item[aria-current="true"] { background: var(--wash); color: var(--indigo); }
.segmented__item[aria-current="true"] b { color: var(--indigo); }

.playground { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4.4fr); gap: clamp(10px, 1.4vw, 16px); align-items: start; }
.chat-card { display: flex; flex-direction: column; height: min(640px, 80dvh); min-height: 480px; background: #fff; border-radius: var(--r-ui); box-shadow: var(--float-sm); overflow: hidden; }
.chat-card__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; background: var(--navy); color: #fff; }
.chat-card__name { font-weight: 500; color: #fff; }
.chat-card__meta { font-size: 0.78125rem; color: var(--on-navy-2); margin-top: 2px; }
.chat-card__tools { display: flex; align-items: center; gap: 16px; }
.chat-card__tools .check { color: #fff; }
.chat-card__tools .check input { accent-color: var(--indigo-soft); }
.chat-card__tools .text-button { color: #fff; }
.chat-card__tools .text-button:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.chat-card .chat-card__log { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 18px; gap: 12px; scrollbar-width: thin; }
.chat-card__noscript { padding: 12px 18px; font-size: 0.875rem; border-top: 1px solid var(--frost); }
.composer { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--frost); }
.composer input { flex: 1; min-width: 0; height: 44px; padding: 0 14px; font-size: 1rem; border: 1px solid var(--frost-2); border-radius: var(--r-btn); background: #fff; color: var(--ink); transition: border-color 150ms ease, box-shadow 150ms ease; }
.composer input::placeholder { color: #9aa9bb; }
.composer input:focus { outline: none; border-color: var(--indigo); box-shadow: 0 0 0 3px var(--wash); }
.check { display: inline-flex; align-items: center; gap: 7px; font-size: 0.8125rem; cursor: pointer; user-select: none; }
.check input { width: 15px; height: 15px; margin: 0; accent-color: var(--indigo); }
.text-button { border: 0; background: none; padding: 6px 8px; margin: -6px -8px; border-radius: var(--r-btn); font-size: 0.8125rem; color: var(--indigo); text-align: left; transition: background-color 150ms ease, color 150ms ease; }
.text-button:hover { background: var(--wash-2); }

.options { display: grid; gap: 6px; margin-top: 10px; min-width: min(280px, 100%); }
.option { border: 1px solid var(--lilac); border-radius: var(--r); padding: 9px 12px; background: #fff; color: var(--indigo); font-size: 0.875rem; line-height: 1.3; text-align: left; transition: background-color 150ms ease, border-color 150ms ease, transform 160ms var(--ease-out); }
.option:hover { background: var(--wash-2); border-color: var(--lavender); }
.option:active { transform: scale(0.985); }
.msg__note { margin-top: 8px; max-width: 46ch; padding: 9px 12px; border-radius: var(--r); background: var(--wash-2); border: 1px solid var(--lilac); font-size: 0.8125rem; line-height: 1.45; color: var(--body); }
.msg__note b { color: var(--indigo); font-weight: 500; }
.hide-notes .msg__note { display: none; }
.msg--status { align-self: stretch; max-width: none; }
.status-card { border-radius: var(--r); background: var(--band); border: 1px solid var(--frost); padding: 16px 18px; font-size: 0.9375rem; }
.status-card b { display: block; color: var(--ink); font-weight: 400; margin-bottom: 4px; }
.status-card .actions { margin-top: 14px; }

.after-cta { margin-top: 12px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: 14px 18px; }
.after-cta p { color: var(--ink); }
.after-cta[hidden] { display: none; }
.after-cta:not([hidden]) { animation: msg-in 260ms var(--ease-out) both; }
.playground__privacy { margin: 14px 4px 4px; font-size: 0.8125rem; color: var(--slate); max-width: 70ch; }

.side-card { background: #fff; border: 1px solid var(--frost); border-radius: var(--r-ui); padding: 4px 20px; }
.side-card__section { padding: 16px 0 18px; border-bottom: 1px solid var(--frost); }
.side-card__section:last-child { border-bottom: 0; }
.side-card__section > h2, .side-card__section > summary { font-size: 1rem; font-weight: 400; color: var(--ink); }
.side-card__section > h2 { margin-bottom: 12px; }
.side-card__section > summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.side-card__section > summary::-webkit-details-marker { display: none; }
.side-card__section > summary::after { content: "+"; color: var(--indigo); font-size: 1.1rem; line-height: 1; }
.side-card__section[open] > summary::after { content: "\2212"; }
.side-card__section[open] > summary { margin-bottom: 10px; }
.side-card__section > p, .side-card__section li { font-size: 0.9375rem; line-height: 1.5; }
.side-card .knowledge { margin-top: 6px; border-top: 1px solid var(--frost); }
.side-card .disclosure > summary { font-size: 0.875rem; padding: 11px 0; }
.side-card .disclosure__body { font-size: 0.875rem; }
.try-list { display: grid; gap: 6px; }
.try { display: flex; flex-direction: column; gap: 2px; width: 100%; text-align: left; border: 1px solid var(--lilac); border-radius: var(--r); padding: 10px 12px; background: #fff; transition: background-color 150ms ease, border-color 150ms ease, transform 160ms var(--ease-out); }
.try:hover { background: var(--wash-2); border-color: var(--lavender); }
.try:active { transform: scale(0.985); }
.try__q { font-size: 0.90625rem; color: var(--indigo); line-height: 1.3; }
.try__tests { font-size: 0.75rem; color: var(--slate); }
.side-card__more { margin: 16px 0 4px; font-size: 0.78125rem; color: var(--slate); }
.more-list { display: grid; gap: 4px; list-style: none; padding: 0; margin-top: 8px; }
.more-list .text-button { margin: 0; padding: 3px 0; font-size: 0.875rem; }
.more-list .text-button:hover { background: none; color: var(--ink); }
.dash-list { display: grid; gap: 8px; list-style: none; padding: 0; }
.dash-list li { position: relative; padding-left: 18px; }
.dash-list li::before { content: ""; position: absolute; left: 0; top: 0.55em; width: 8px; height: 8px; border-radius: 2px; background: var(--wash); box-shadow: inset 0 0 0 1px var(--lavender); }
@media (max-width: 960px) {
  .playground { grid-template-columns: 1fr; }
  .chat-card { height: min(600px, 78dvh); min-height: 440px; }
}

.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--gap); border-top: 1px solid var(--frost); }
.fact { padding: 28px 0; border-bottom: 1px solid var(--frost); }
.fact h3 { font-size: 1.25rem; font-weight: 500; letter-spacing: -0.015em; }
.fact p { margin-top: 10px; font-size: 0.96875rem; line-height: 1.6; max-width: 48ch; }
.facts__links { margin-top: 32px; display: flex; flex-wrap: wrap; gap: 14px 32px; }
@media (max-width: 760px) { .facts { grid-template-columns: 1fr; } }
.references { display: grid; gap: var(--gap); }
.reference__name { font-size: 1.375rem; font-weight: 500; letter-spacing: -0.02em; display: flex; flex-wrap: wrap; gap: 10px; align-items: baseline; }
.reference__name span { font-size: 0.875rem; }
.reference__about { margin: 8px 0 24px; color: var(--slate); max-width: 64ch; font-size: 0.9375rem; }
.reference .table th[scope="row"] { width: 28%; }
.reference .table td:nth-child(2) { width: 22%; color: var(--slate); }

.closing { border-top: 1px solid var(--frost); padding-top: var(--section); display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 28px 40px; }
.closing .title { max-width: 18ch; }

/* ============ Examples page ============ */
.index-card { border-top: 1px solid var(--frost); padding-top: 8px; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(24px, 4vw, 64px); }
.example-index li { border-bottom: 1px solid var(--frost); }
.example-index a { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 15px 0; color: var(--ink); }
.example-index a:hover { color: var(--indigo); }
.example-index__t { font-size: 1.0625rem; }
.example-index__m { font-size: 0.875rem; color: var(--slate); white-space: nowrap; }
.legend { display: grid; gap: 10px; align-content: start; padding-top: 12px; font-size: 0.9375rem; }
.legend p { padding: 12px 14px; border-radius: var(--r); background: var(--band); border: 1px solid var(--frost); }
.legend b { display: block; color: var(--ink); font-weight: 400; }
@media (max-width: 860px) {
  .index-card { grid-template-columns: 1fr; }
  .example-index a { flex-direction: column; gap: 2px; }
}
.example { padding-top: var(--section); scroll-margin-top: 16px; }
.example__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(28px, 5vw, 72px); align-items: start; border-top: 1px solid var(--frost); padding-top: clamp(32px, 4vw, 48px); }
.example__head { position: sticky; top: 92px; }
.example__head .title { font-size: clamp(1.75rem, 1.35rem + 1.2vw, 2.4rem); max-width: 14ch; }
.example__meta { margin-top: 22px; display: grid; gap: 12px; font-size: 0.9375rem; color: var(--ink); }
.example__meta dt { color: var(--slate); font-size: 0.8125rem; }
.example__meta dd { margin: 0; }
.example__label { margin-top: 22px; font-size: 0.8125rem; color: var(--slate); max-width: 36ch; line-height: 1.5; }
.example__goal { font-size: clamp(1.125rem, 1.02rem + 0.4vw, 1.3125rem); font-weight: 500; line-height: 1.45; letter-spacing: -0.012em; color: var(--ink); max-width: 44ch; }
.example__links { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 14px 32px; }
@media (max-width: 900px) {
  .example__grid { grid-template-columns: 1fr; }
  .example__head { position: static; }
}
.source-card { margin-top: 24px; background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: 16px 18px 18px; }
.source-card__title { display: flex; align-items: center; gap: 8px; color: var(--ink); font-size: 0.9375rem; }
.source-card__title::before { content: ""; width: 10px; height: 10px; border-radius: 2px; background: var(--wash); box-shadow: inset 0 0 0 1px var(--lavender); }
.source-card__text { margin-top: 8px; font-size: 0.9375rem; line-height: 1.55; }
.source-card__text p + p { margin-top: 6px; }
.source-card__from { margin-top: 12px; font-size: 0.78125rem; color: var(--slate); }
.transcript { margin-top: 20px; background: linear-gradient(135deg, var(--band), var(--wash-2)); border: 1px solid var(--frost); border-radius: var(--r); padding: clamp(16px, 3vw, 32px); }
.at { display: grid; gap: 14px; list-style: none; margin: 0; padding: 0; }
.at__row { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 0 20px; align-items: start; }
.at__msg { display: flex; flex-direction: column; }
.at__msg .msg { max-width: 94%; }
.at__msg .msg--bot .bubble { background: #fff; border: 1px solid var(--frost); }
.at__note { display: grid; gap: 8px; }
.at__note p { background: var(--navy); color: var(--on-navy-2); border-radius: var(--r); padding: 10px 13px; font-size: 0.84375rem; line-height: 1.45; }
.at__note b { display: flex; align-items: center; gap: 8px; color: #fff; font-weight: 400; margin-bottom: 2px; }
.at__note b::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--indigo-soft); }
.at__note .is-avoid b::before { background: #ff8fa3; }
.at__note .is-person b::before { background: transparent; box-shadow: inset 0 0 0 1.5px #fff; }
@media (max-width: 900px) { .at__row { grid-template-columns: 1fr; gap: 8px; } }

/* ============ Calculator ============ */
.calc { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(10px, 1.4vw, 16px); align-items: start; }
@media (max-width: 1000px) { .calc { grid-template-columns: 1fr; } }
.calc__results { display: grid; gap: clamp(10px, 1.4vw, 16px); }
.fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.fieldset + .fieldset { margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--frost); }
.fieldset legend { padding: 0; font-size: 1.0625rem; color: var(--ink); margin-bottom: 14px; }
.fieldset__note { font-size: 0.8125rem; color: var(--slate); margin: -6px 0 14px; line-height: 1.5; }
.field { display: grid; gap: 6px; }
.field + .field { margin-top: 16px; }
.field label { font-size: 0.875rem; color: var(--ink); }
.field__hint { font-size: 0.78125rem; color: var(--slate); line-height: 1.4; }
.field__hint:empty { display: none; }
.field__error { font-size: 0.8125rem; color: var(--error); }
.field__error:empty { display: none; }
.input-unit { display: flex; align-items: stretch; border-radius: var(--r-btn); background: #fff; border: 1px solid var(--frost-2); transition: border-color 150ms ease, box-shadow 150ms ease; }
.input-unit:focus-within { border-color: var(--indigo); box-shadow: 0 0 0 3px var(--wash); }
.input-unit input { flex: 1; min-width: 0; height: 42px; border: 0; background: transparent; padding: 0 12px; font-size: 1rem; color: var(--ink); font-variant-numeric: tabular-nums; }
.input-unit input:focus { outline: none; }
.input-unit__u { display: flex; align-items: center; padding: 0 12px 0 0; color: var(--slate); font-size: 0.8125rem; white-space: nowrap; }
.input-unit__u--pre { padding: 0 0 0 12px; color: var(--body); font-size: 1rem; }
.field--invalid .input-unit { border-color: var(--error); box-shadow: 0 0 0 3px #fde8ed; }
.field select { height: 42px; border: 1px solid var(--frost-2); border-radius: var(--r-btn); padding: 0 40px 0 12px; font-size: 1rem; color: var(--ink); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23533afd' stroke-width='1.5'/%3E%3C/svg%3E") no-repeat right 14px center; appearance: none; cursor: pointer; }
.field select:focus { outline: none; border-color: var(--indigo); box-shadow: 0 0 0 3px var(--wash); }
.triple { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.triple .field + .field { margin-top: 0; }
.triple label { color: var(--slate); font-size: 0.8125rem; }
.triple [data-field="rate"] label { color: var(--indigo); }
.triple [data-field="rate"] .input-unit { border-color: var(--lavender); background: var(--wash-2); }
.triple .input-unit input { padding: 0 6px 0 10px; }
.triple .input-unit__u { padding-right: 10px; }
.calc__defaults { margin-top: 24px; font-size: 0.78125rem; color: var(--slate); line-height: 1.5; }

.results-card { background: var(--navy); color: var(--on-navy-2); border-radius: var(--r); padding: clamp(22px, 3vw, 36px); }
.results-card__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.result { padding: 4px 20px 22px 0; }
.result:nth-child(even) { padding-left: 22px; border-left: 1px solid var(--navy-line); }
.result:nth-child(n+3) { padding-top: 22px; border-top: 1px solid var(--navy-line); }
.result__label { font-size: 0.875rem; }
.result__value { margin-top: 10px; font-size: clamp(2rem, 1.5rem + 1.6vw, 2.9rem); line-height: 1; letter-spacing: -0.04em; font-weight: 400; color: #fff; font-variant-numeric: tabular-nums; }
.result__value.is-negative { color: #ff9db0; }
.result__sub { margin-top: 8px; font-size: 0.78125rem; min-height: 1.2em; }
.results-card__caveat { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--navy-line); color: #fff; }
.results-card__status { margin-top: 6px; font-size: 0.875rem; color: #ffc2cd; min-height: 1.3em; }
.results-card__tools { margin-top: 14px; display: flex; flex-wrap: wrap; gap: 8px; }
.results-card :focus-visible { outline-color: #fff; }
@media (max-width: 560px) {
  .results-card__grid { grid-template-columns: 1fr; }
  .result:nth-child(even) { padding-left: 0; border-left: 0; }
  .result:nth-child(n+2) { padding-top: 20px; border-top: 1px solid var(--navy-line); }
}
.calc__block-title { font-size: 1.125rem; font-weight: 500; margin-bottom: 14px; }
.calc__note { margin-top: 14px; font-size: 0.8125rem; color: var(--slate); }
.is-negative-cell { color: var(--error); }
.calc-cta { background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: 20px 22px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; }
.calc-cta p { color: var(--ink); max-width: 30ch; }

/* ============ Articles and prose ============ */
.article-grid { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 3.4fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.article-aside { position: sticky; top: 92px; display: grid; gap: 16px; }
@media (max-width: 1000px) {
  .article-grid { grid-template-columns: 1fr; }
  .article-aside { position: static; }
}
.aside-card { background: var(--band); border: 1px solid var(--frost); border-radius: var(--r); padding: 22px; display: grid; gap: 10px; justify-items: start; }
.aside-card__title { color: var(--ink); }
.aside-card p { font-size: 0.9375rem; }
.aside-card .link { font-size: 0.9375rem; }
.toc ol { list-style: none; padding: 0; display: grid; gap: 2px; }
.toc a { display: block; padding: 5px 0; font-size: 0.9375rem; color: var(--slate); line-height: 1.35; }
.toc a:hover { color: var(--indigo); }

.prose { max-width: 68ch; font-size: 1.0625rem; line-height: 1.7; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: clamp(1.55rem, 1.3rem + 0.9vw, 2rem); font-weight: 500; line-height: 1.15; letter-spacing: -0.025em; margin-top: 2.4em; }
.prose > h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.25rem; font-weight: 400; line-height: 1.25; letter-spacing: -0.015em; margin-top: 1.9em; }
.prose h2 + *, .prose h3 + * { margin-top: 0.7em; }
.prose a:not(.link):not(.button) { text-decoration: underline; text-decoration-color: var(--lavender); text-underline-offset: 0.2em; }
.prose a:not(.link):not(.button):hover { text-decoration-color: currentColor; }
.prose ul, .prose ol { padding-left: 1.2em; }
.prose li + li { margin-top: 0.45em; }
.prose li::marker { color: var(--indigo); }
.prose dl { display: grid; gap: 4px 0; }
.prose dt { color: var(--ink); margin-top: 12px; }
.prose dt:first-child { margin-top: 0; }
.prose dd { margin: 0; }
.prose .table-wrap, .prose .wide, .prose pre, .prose .callout-box { margin-top: 1.6em; }
.prose .answer { font-size: clamp(1.15rem, 1.05rem + 0.4vw, 1.35rem); font-weight: 500; line-height: 1.55; letter-spacing: -0.012em; color: var(--ink); }
.formula { background: var(--band); border: 1px solid var(--frost); border-radius: var(--r); padding: 4px 20px; font-size: 0.96875rem; line-height: 1.55; }
.formula p { padding: 12px 0; border-bottom: 1px solid var(--frost); }
.formula p:last-child { border-bottom: 0; }
.reviewed { font-size: 0.875rem; color: var(--slate); padding-top: 1em; border-top: 1px solid var(--frost); }
.callout-box { background: var(--wash-2); border: 1px solid var(--lilac); border-radius: var(--r); padding: 18px 20px; font-size: 1rem; line-height: 1.6; }
.callout-box > b:first-child { display: block; margin-bottom: 4px; color: var(--indigo); font-weight: 400; }

/* Reduced motion: keep opacity changes, drop movement. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  .msg--enter { animation: msg-fade 160ms ease both; }
  .button:active, .suggest button:active, .option:active, .try:active { transform: none; }
}
@keyframes msg-fade { from { opacity: 0; } to { opacity: 1; } }

/* Print */
@media print {
  body { background: #fff; }
  .site-header, .site-footer, .skip-link, .no-print, .hero__gl { display: none !important; }
  .lab { background: none; border: 0; padding: 0; }
  .calc { display: block; }
  .results-card { background: #fff; color: #000; border: 1px solid #ccc; }
  .result__label, .result__sub { color: #444; }
  .result__value, .result__value.is-negative { color: #000; }
  .calc-cta, .article-aside, .results-card__tools { display: none !important; }
}

/* ============ Tools ============ */
.tool__name { margin-top: 24px; font-size: 1.5rem; font-weight: 500; letter-spacing: -0.02em; line-height: 1.15; }
.tool__staff { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tool__staff div { background: #fff; border: 1px solid var(--frost); border-radius: var(--r); padding: 16px; }
.tool__staff b { display: block; font-size: 2.5rem; font-weight: 500; letter-spacing: -0.04em; line-height: 1; color: var(--ink); }
.tool__staff div:last-child b { color: var(--indigo); }
.tool__staff span { display: block; margin-top: 6px; font-size: 0.75rem; color: var(--slate); }
.triple--two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.result__value--sm { font-size: clamp(1.4rem, 1.2rem + 0.8vw, 1.9rem); letter-spacing: -0.025em; }
.table tr.is-pick th, .table tr.is-pick td { background: var(--wash-2); color: var(--indigo); }
.table tr.is-pick th:first-child { box-shadow: inset 3px 0 0 var(--indigo); padding-left: 12px; }
.table tr.is-pick td:last-child { padding-right: 8px; }
#st-curve th:first-child { padding-left: 12px; }

.choice { display: flex; gap: 3px; padding: 3px; background: #fff; border: 1px solid var(--frost-2); border-radius: 6px; }
.choice__item { flex: 1; position: relative; }
.choice__item input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice__item span { display: block; text-align: center; padding: 8px 10px; border-radius: 4px; font-size: 0.875rem; color: var(--slate); transition: background-color 150ms ease, color 150ms ease; }
.choice__item input:checked + span { background: var(--wash); color: var(--indigo); }
.choice__item input:focus-visible + span { outline: 2px solid var(--indigo); outline-offset: 1px; }
.choice__item:hover span { color: var(--ink); }

.gen-preview { margin-top: 28px; border-radius: var(--r-ui); overflow: hidden; box-shadow: var(--float-sm); background: #fff; }
.gen-preview__head { display: flex; justify-content: space-between; align-items: baseline; padding: 12px 14px; background: var(--navy); color: #fff; font-size: 0.875rem; }
.gen-preview__head b { color: #fff; }
.gen-preview__head span { color: var(--on-navy-2); font-size: 0.75rem; }
.gen-preview__body { padding: 16px 14px 18px; display: flex; }
.gen-output__bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 8px; }
.gen-output__title { color: var(--ink); font-size: 1.125rem; font-weight: 500; }
.gen-group { padding-top: 18px; }
.gen-group h3 { font-size: 0.9375rem; font-weight: 400; color: var(--ink); margin-bottom: 10px; }
.gen-list { display: grid; gap: 6px; }
.gen-item { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 11px 14px; border-radius: var(--r); background: var(--band); border: 1px solid var(--frost); }
.gen-item__text { font-size: 0.9375rem; color: var(--ink); line-height: 1.45; }
.gen-item__copy { margin: -4px -6px -4px 0; flex: none; }
.plain-list { list-style: none; padding: 0 !important; display: grid; gap: 8px; }
.plain-list li { margin: 0 !important; }
.examples-table th[scope="row"] { width: 22%; }

/* ============ Guides ============ */
.byline { margin-top: 24px; display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: 0.875rem; color: var(--slate); }
.byline b { font-weight: 400; color: var(--ink); }
.disclosure-line { margin-top: 3em !important; font-size: 0.875rem; color: var(--slate); padding-top: 1.2em; border-top: 1px solid var(--frost); }
.crumbs { margin-top: 1.2em !important; font-size: 0.8125rem; color: var(--slate); }
.crumbs ol { list-style: none; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs li { margin: 0 !important; }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--frost-2); }
.crumbs a { color: var(--slate) !important; text-decoration: none !important; }
.crumbs a:hover { color: var(--indigo) !important; }
.guide-end { margin-top: 3em !important; background: var(--band); border: 1px solid var(--frost); border-radius: var(--r); padding: 24px; }
.guide-end__title { font-size: 1.25rem; font-weight: 500; color: var(--ink); }
.guide-end p + p { margin-top: 6px; font-size: 0.96875rem; }
.guide-end .actions { margin-top: 18px; }
.prose .wide { max-width: none; }
.page-guide .prose { max-width: 72ch; }
.platforms td:nth-child(2) { width: 46%; }
.guide-list { border-top: 1px solid var(--frost); }
.guide-list li { border-bottom: 1px solid var(--frost); }
.guide-row { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); grid-template-areas: "q d" "t d" "t l"; gap: 6px var(--gap); padding: 32px 0; color: var(--body); }
.guide-row:hover { color: var(--body); }
.guide-row__q { grid-area: q; font-size: clamp(1.4rem, 1.2rem + 0.8vw, 1.9rem); font-weight: 500; letter-spacing: -0.022em; line-height: 1.15; color: var(--ink); }
.guide-row:hover .guide-row__q { color: var(--indigo); }
.guide-row__t { grid-area: t; font-size: 0.875rem; color: var(--slate); }
.guide-row__d { grid-area: d; font-size: 1rem; line-height: 1.55; }
.guide-row .link { grid-area: l; align-self: end; }
@media (max-width: 760px) { .guide-row { grid-template-columns: 1fr; grid-template-areas: "q" "t" "d" "l"; } }

/* Three-way comparison */
.compare { background: linear-gradient(135deg, var(--band), var(--wash-2)); border: 1px solid var(--frost); border-radius: var(--r); padding: clamp(14px, 2.4vw, 24px); }
.compare__picker { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.compare__q { border: 1px solid var(--lilac); background: #fff; color: var(--indigo); border-radius: var(--r); padding: 8px 12px; font-size: 0.875rem; line-height: 1.3; text-align: left; transition: background-color 150ms ease, border-color 150ms ease; }
.compare__q:hover { border-color: var(--lavender); }
.compare__q[aria-selected="true"] { background: var(--indigo); border-color: var(--indigo); color: #fff; }
.compare__set + .compare__set { margin-top: 32px; }
.compare.is-interactive .compare__set + .compare__set { margin-top: 0; }
.compare.is-interactive .compare__title { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.compare__title { font-size: 1.125rem; font-weight: 400; margin: 0 0 4px !important; }
.compare__context { font-size: 0.875rem; color: var(--slate); margin: 0 0 14px !important; }
.compare__cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.compare__col { display: flex; flex-direction: column; background: #fff; border-radius: var(--r-ui); box-shadow: var(--float-sm); overflow: hidden; }
.compare__mode { margin: 0 !important; padding: 10px 14px; background: var(--navy); color: #fff; font-size: 0.8125rem; }
.compare__col--hybrid .compare__mode { background: var(--indigo); }
.compare__col .chat-log { padding: 14px 12px; gap: 8px; flex: 1; margin: 0 !important; }
.compare__col .bubble { font-size: 0.8125rem; line-height: 1.4; padding: 8px 11px; }
.compare__col .msg { max-width: 94%; }
.compare__col .msg--system { font-size: 0.6875rem; }
.msg--person .bubble { background: var(--wash); }
.msg__who { font-size: 0.6875rem; color: var(--slate); margin: 0 0 4px 2px !important; }
.compare__outcome { margin: 0 !important; padding: 12px 14px 14px; border-top: 1px solid var(--frost); font-size: 0.78125rem; line-height: 1.45; color: var(--slate); }
.compare__outcome b { display: block; font-size: 0.875rem; font-weight: 400; color: var(--ink); }
.compare__foot { margin: 14px 0 0 !important; font-size: 0.9375rem; }
.compare__label { margin: 16px 0 0 !important; font-size: 0.78125rem; color: var(--slate); }
.compare .chat-log li { margin: 0 !important; }
@media (max-width: 860px) { .compare__cols { grid-template-columns: 1fr; } }

/* ============ Navigation aids and info pages ============ */
.crumbs-top { padding-top: 22px; font-size: 0.875rem; color: var(--slate); }
.crumbs-top ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs-top li + li::before { content: "/"; margin-right: 6px; color: var(--frost-2); }
.crumbs-top a { color: var(--indigo); font-weight: 500; }
.crumbs-top a:hover { color: var(--ink); }
.crumbs-top + section .page-head, .crumbs-top + .page-head { padding-top: clamp(24px, 3vw, 44px); }
.prose--page { max-width: 70ch; padding-bottom: 24px; }
.prose--page h2 { margin-top: 2em; }
.contact-card { background: var(--band); border: 1px solid var(--frost); border-radius: 8px; padding: 22px 24px; }
.contact-card__label { font-size: 0.875rem; color: var(--slate); }
.contact-card__value { font-size: 1.5rem; font-weight: 500; letter-spacing: -0.02em; margin-top: 2px !important; }
.contact-card__note { margin-top: 6px !important; font-size: 0.9375rem; }
.not-found { padding-block: clamp(80px, 12vw, 160px); }
.not-found__links { margin-top: 32px; }

/* Commercial disclosure near the top of editorial and tool pages */
.made-by { margin-top: 16px; font-size: 0.875rem; color: var(--slate); max-width: 70ch; }
.made-by a { color: var(--slate); text-decoration: underline; text-decoration-color: var(--frost-2); text-underline-offset: 0.2em; white-space: nowrap; }
.made-by a:hover { color: var(--indigo); text-decoration-color: currentColor; }
.page-head .lead + .made-by, .byline + .made-by { margin-top: 16px; }
.address { font-style: normal; line-height: 1.6; }
.contact-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 640px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-card__value { font-size: 1.1875rem !important; overflow-wrap: anywhere; }
