:root {
  color-scheme: light;
  --bg: #fff;
  --panel: #fff;
  --text: #20242b;
  --muted: #626a76;
  --line: #e8eaee;
  --soft: #f7f8fa;
  --code: #f7f8fa;
  --blue: #1768cc;
  --teal: #137d80;
  --purple: #9823c0;
  --orange: #b94c0d;
  --bs-body-font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  --bs-body-color: var(--text);
  --bs-body-bg: var(--bg);
  font-size: 16px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #14171c;
  --panel: #191d24;
  --text: #f1f3f6;
  --muted: #aab3c0;
  --line: #303640;
  --soft: #1c2129;
  --code: #1b2028;
  --blue: #7ab3ff;
  --teal: #6ad3d0;
  --purple: #d9a0f6;
  --orange: #f2ab7c;
}
* {
  box-sizing: border-box;
}
html {
  scroll-padding-top: 104px;
}
body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family: var(--bs-body-font-family);
  font-size: 1rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-decoration: none;
  text-underline-offset: 0.2em;
}
a:hover {
  color: var(--blue);
}
p {
  margin: 0 0 1.3rem;
}
h1,
h2,
h3,
h4 {
  color: var(--text);
  line-height: 1.2;
  letter-spacing: -0.035em;
  font-weight: 600;
}
h1 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  margin-bottom: 1.6rem;
  overflow-wrap: anywhere;
}
h2 {
  font-size: 1.7rem;
  margin: 3.5rem 0 1.15rem;
}
h3 {
  font-size: 1.15rem;
  margin: 1.75rem 0 0.8rem;
}
strong,
b {
  font-weight: 600;
}
small {
  font-size: 0.875rem;
}
code,
pre,
kbd,
.install-command {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}
code {
  color: var(--text);
  font-size: 0.88em;
}
p code,
li code,
dd code {
  background: var(--soft);
  border-radius: 4px;
  padding: 0.12em 0.3em;
  overflow-wrap: anywhere;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
[hidden] {
  display: none !important;
}
:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 4px;
}
.btn {
  --bs-btn-padding-x: 1.1rem;
  --bs-btn-padding-y: 0.65rem;
  --bs-btn-border-radius: 0.5rem;
  font-size: 0.9rem;
  font-weight: 550;
  line-height: 1.4;
}
.btn-outline-secondary {
  --bs-btn-color: var(--text);
  --bs-btn-border-color: #d6dbe2;
  --bs-btn-hover-color: var(--text);
  --bs-btn-hover-bg: var(--soft);
  --bs-btn-hover-border-color: #a4adba;
  --bs-btn-active-color: var(--text);
  --bs-btn-active-bg: var(--soft);
  --bs-btn-active-border-color: #a4adba;
  background: var(--panel);
}
.btn-dark,
.button.primary {
  color: #fff;
  background: #20242b;
  border-color: #20242b;
}
.btn-dark:hover,
.button.primary:hover {
  color: #fff;
  background: #363d48;
  border-color: #363d48;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 550;
  padding: 0.75rem 1.15rem;
  border: 1px solid #d6dbe2;
  border-radius: 0.5rem;
  background: var(--panel);
}
.form-control,
.form-select {
  color: var(--text);
  background-color: var(--panel);
  border-color: #cfd5de;
  border-radius: 0.5rem;
  padding: 0.7rem 0.8rem;
  font-size: 1rem;
}
.form-control:focus,
.form-select:focus {
  color: var(--text);
  background-color: var(--panel);
  border-color: var(--blue);
  box-shadow: 0 0 0 3px #1768cc14;
}
.form-check-input {
  flex: 0 0 auto;
  width: 1.1em;
  height: 1.1em;
  margin: 0;
}
.form-control[aria-invalid="true"] {
  border-color: #be3535;
}
.btn:disabled {
  opacity: 0.5;
}
.skip {
  position: fixed;
  z-index: 2000;
  top: -80px;
  left: 20px;
  background: var(--text);
  color: var(--bg);
  padding: 12px 20px;
  border-radius: 6px;
}
.skip:focus {
  top: 12px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.2rem;
  font-weight: 650;
  letter-spacing: -0.04em;
  white-space: nowrap;
  color: var(--text);
}
.logo {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  color: #fff;
  background: #20242b;
  border-radius: 8px;
  font-size: 1.2rem;
  font-weight: 650;
}
.eyebrow,
.crumb,
.sample-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--muted);
}
.eyebrow {
  margin-bottom: 1.25rem;
}
.muted,
.field-hint {
  color: var(--muted);
  font-size: 0.875rem;
}
.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}
.text-link {
  color: var(--blue);
  font-size: 0.9rem;
  font-weight: 550;
}
.text-link:hover {
  text-decoration: underline;
}
.tag {
  display: inline-flex;
  align-items: center;
  font-size: 0.78rem;
  color: var(--muted);
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 3px 9px;
}
/* Home: real behavior, generous space, purposeful color. */
.landing-page {
  background: #fff;
}
.landing-nav {
  position: sticky;
  z-index: 100;
  top: 0;
  width: 100%;
  min-height: 80px;
  padding: 0 max(28px, calc((100vw - 1200px) / 2));
  display: flex;
  flex-wrap: nowrap;
  gap: 40px;
  background: #ffffffed;
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
.landing-links {
  display: flex;
  gap: 28px;
  margin-left: auto;
  align-items: center;
}
.landing-links a,
.landing-github {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--muted);
}
.landing-nav-actions {
  display: flex;
  gap: 28px;
  align-items: center;
}
.landing-docs-link {
  padding: 0.62rem 0.9rem;
  font-size: 0.85rem;
}
.landing-shell {
  width: min(1200px, calc(100% - 64px));
  margin: 0 auto;
}
.home-hero {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  align-items: center;
  gap: clamp(40px, 7vw, 110px);
  padding: 110px 0 120px;
}
.hero-copy,
.hero-example {
  min-width: 0;
}
.home-hero h1 {
  font-size: clamp(3.4rem, 5.9vw, 5.2rem);
  font-weight: 550;
  line-height: 1.06;
  letter-spacing: -0.065em;
  margin: 0 0 2rem;
  overflow-wrap: normal;
}
.home-hero h1 span {
  color: var(--blue);
}
.hero-description {
  font-size: 1.28rem;
  line-height: 1.65;
  max-width: 30rem;
  margin-bottom: 1.1rem;
}
.hero-detail {
  color: var(--muted);
  line-height: 1.8;
  margin-bottom: 2rem;
  max-width: 29rem;
}
.landing-install {
  display: flex;
  align-items: center;
  gap: 20px;
  width: fit-content;
  max-width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  padding: 7px 8px 7px 16px;
  margin-top: 1.5rem;
}
.install-command {
  font-size: 0.875rem;
  white-space: nowrap;
}
.landing-install button {
  color: var(--muted);
  font-size: 0.8rem;
  padding: 7px 12px;
  border: 1px solid var(--line);
  background: #fff;
}
.hero-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin-top: 1.5rem;
  color: var(--muted);
  font-size: 0.8rem;
}
.hero-example {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 32px;
  background: linear-gradient(145deg, #fafbfc, #fff 70%);
  box-shadow: 0 16px 48px #20242b05;
}
.example-intro .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 0.75rem;
}
.example-intro h2 {
  font-size: 1.5rem;
  margin: 0 0 0.7rem;
}
.example-intro p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.75;
  margin-bottom: 1.7rem;
}
.hero-example .demo {
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
}
.hero-example .demo-body {
  padding: 24px;
}
.hero-example-caption {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.7;
}
.landing-section {
  padding: 100px 0;
  border-top: 1px solid var(--line);
}
.section-heading {
  max-width: 660px;
  margin-bottom: 52px;
}
.section-heading h2 {
  font-size: clamp(2.1rem, 4vw, 3.1rem);
  line-height: 1.14;
  letter-spacing: -0.05em;
  margin: 0 0 1.4rem;
  font-weight: 550;
}
.section-heading p:not(.eyebrow) {
  color: var(--muted);
  max-width: 38rem;
  line-height: 1.8;
}
.benefit-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
}
.benefit-item {
  color: var(--text);
}
.benefit-item h3 {
  margin: 24px 0 14px;
  font-size: 1.05rem;
  line-height: 1.45;
  letter-spacing: -0.02em;
}
.benefit-item p {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.8;
}
.benefit-mark {
  display: block;
  width: 28px;
  height: 4px;
  background: var(--blue);
  border-radius: 2px;
}
.color-purple .benefit-mark {
  background: var(--purple);
}
.color-teal .benefit-mark {
  background: var(--teal);
}
.color-orange .benefit-mark {
  background: var(--orange);
}
.home-experiment {
  display: grid;
  grid-template-columns: 0.72fr 1.35fr;
  gap: 72px;
  align-items: start;
  padding: 48px 0;
  border-bottom: 1px solid var(--line);
}
.home-experiment:first-child {
  padding-top: 0;
}
.home-experiment:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}
.home-experiment > div {
  min-width: 0;
}
.home-experiment > div > code {
  color: var(--blue);
  font-size: 0.875rem;
}
.home-experiment h3 {
  font-size: 1.4rem;
  margin: 0.8rem 0 1rem;
}
.home-experiment p {
  color: var(--muted);
  font-size: 0.95rem;
}
.cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 24px 0 32px;
}
.card {
  display: flex;
  flex-direction: column;
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 26px;
  border-radius: 9px;
  min-width: 0;
  transition: border-color 0.15s ease;
}
.card:hover {
  border-color: #9eabbc;
  color: var(--text);
}
.card h2,
.card h3,
.card strong {
  margin: 0.8rem 0;
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.5;
  letter-spacing: -0.02em;
}
.card p,
.card small {
  color: var(--muted);
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
}
.card code {
  color: var(--blue);
  font-size: 0.8rem;
}
.card .card-number,
.card .card-index {
  display: none;
}
.card .eyebrow {
  font-size: 0.75rem;
  margin-bottom: 0;
}
.card .tag {
  align-self: start;
  margin-top: 10px;
}
.home-primitives {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.start-steps {
  display: grid;
  grid-template-columns: 0.8fr 1.3fr 1fr;
  gap: 42px;
}
.start-steps article {
  min-width: 0;
}
.start-steps h3 {
  font-size: 1.15rem;
  margin: 0.8rem 0 1rem;
}
.start-steps p {
  color: var(--muted);
  font-size: 0.9rem;
}
.step-label {
  color: var(--blue);
  font-size: 0.8rem;
  font-weight: 600;
}
.start-steps pre {
  font-size: 0.76rem;
  padding: 18px;
}
.framework-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
}
.framework-grid a {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 26px 20px 26px 0;
  border-bottom: 1px solid var(--line);
}
.framework-grid a strong {
  font-size: 1rem;
}
.framework-grid a span {
  color: var(--muted);
  font-size: 0.875rem;
}
.code-section {
  max-width: 860px;
}
.landing-cta {
  padding: 100px 0;
  border-top: 1px solid var(--line);
}
.landing-cta h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin: 0 0 20px;
  max-width: 600px;
}
.landing-cta > p {
  color: var(--muted);
  max-width: 560px;
}
.landing-footer {
  width: min(1200px, calc(100% - 64px));
  margin: 0 auto;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 32px;
  padding: 42px 0;
}
.landing-footer p,
.landing-footer small {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 12px;
}
.landing-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  max-width: 520px;
  font-size: 0.85rem;
  color: var(--muted);
}
/* Documentation: a single reading column and lightweight, task-based navigation. */
.docs-page > header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: 72px;
  padding: 0 32px;
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.version {
  font-size: 0.75rem;
  color: var(--muted);
  margin-right: auto;
}
.search-trigger {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 280px;
  text-align: left;
  color: var(--muted);
  background: var(--soft) !important;
  border-color: var(--line) !important;
}
.search-trigger-label {
  font-size: 0.85rem;
  flex: 1;
}
kbd {
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
  font-size: 0.7rem;
  padding: 1px 5px;
  border-radius: 4px;
}
.theme-toggle {
  display: grid;
  place-items: center;
  min-height: 40px;
  width: 40px;
  padding: 8px;
  border-color: var(--line) !important;
}
.mobile-nav,
#sidebar-close {
  display: none;
}
.layout {
  width: min(1540px, 100%);
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 180px;
  gap: 48px;
  margin: auto;
  padding: 0 32px;
}
.sidebar {
  position: sticky;
  top: 72px;
  height: calc(100dvh - 72px);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 32px 18px 60px 0;
  border-right: 1px solid var(--line);
  scrollbar-width: thin;
  scrollbar-color: #d8dce2 transparent;
}
.sidebar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0 10px 18px;
}
.sidebar-search {
  width: calc(100% - 10px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--muted);
  margin: 0 0 20px 5px;
  background: var(--soft) !important;
  border-color: var(--line) !important;
}
.nav-group {
  margin-bottom: 12px;
}
.nav-group summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 8px;
  padding: 12px 10px;
  border-radius: 5px;
}
.nav-group summary::-webkit-details-marker {
  display: none;
}
.nav-group summary:hover {
  background: var(--soft);
}
.nav-summary-copy {
  min-width: 0;
}
.nav-group-title {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.5;
}
.nav-group-description {
  display: block;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.65;
  margin-top: 5px;
}
.nav-chevron {
  font-size: 0.85rem;
  color: var(--muted);
  transition: transform 0.15s;
}
.nav-group[open] .nav-chevron {
  transform: rotate(180deg);
}
.nav-items {
  display: grid;
  gap: 3px;
  margin: 3px 0 12px 10px;
  padding-left: 10px;
  border-left: 1px solid var(--line);
}
.nav-items a {
  display: flex;
  flex-direction: column;
  gap: 3px;
  border-radius: 5px;
  padding: 10px 12px;
}
.nav-items a:hover {
  background: var(--soft);
}
.nav-items a[aria-current] {
  color: var(--blue);
  background: #1768cc0a;
  box-shadow: -11px 0 0 -9px var(--blue);
}
.nav-link-title {
  font-size: 0.85rem;
  line-height: 1.5;
}
.nav-items code,
.nav-link-description {
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.5;
}
.docs-page main {
  width: 100%;
  max-width: 860px;
  min-width: 0;
  margin: 0 auto;
  padding: 56px 0 64px;
}
.crumb {
  font-size: 0.75rem;
  margin-bottom: 20px;
}
.docs-page main > p,
.docs-page main > ul,
.docs-page main > ol {
  color: var(--muted);
}
.docs-page main > p a,
.docs-page main li a {
  color: var(--blue);
  text-decoration: underline;
}
.docs-page .lede {
  font-size: 1.12rem;
  line-height: 1.8;
  margin-bottom: 24px;
  color: var(--muted);
}
.meta {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 32px;
}
.improvement {
  border-left: 2px solid var(--teal);
  padding: 4px 0 4px 20px;
  margin: 34px 0 48px;
}
.improvement > span {
  color: var(--teal);
  font-weight: 600;
  font-size: 0.8rem;
}
.improvement p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}
.desktop-note {
  display: block;
  padding: 14px 18px;
  border-radius: 6px;
  background: var(--soft);
  font-size: 0.875rem;
  color: var(--muted);
}
.desktop-note strong {
  color: var(--text);
}
.implementation-steps {
  padding-left: 22px;
  margin-bottom: 32px;
}
.implementation-steps li {
  padding: 0 0 14px 8px;
}
.implementation-steps strong {
  color: var(--text);
}
.implementation-note,
.code-caption {
  color: var(--muted);
  font-size: 0.875rem;
  line-height: 1.8;
}
.code-caption {
  margin: 28px 0 12px;
  font-weight: 500;
}
.section-context {
  color: var(--muted);
}
.reference-panel {
  border-top: 1px solid var(--line);
  margin-top: 24px;
}
.reference-panel > div {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 24px;
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}
.reference-panel dt {
  font-size: 0.875rem;
  font-weight: 600;
}
.reference-panel dd {
  color: var(--muted);
  font-size: 0.9rem;
  margin: 0;
}
.reference-panel code {
  white-space: normal;
  line-height: 1.8;
}
.safety-panel {
  padding: 0;
  color: var(--muted);
}
.safety-panel h3 {
  font-size: 1rem;
  margin-top: 24px;
}
.safety-panel p {
  font-size: 0.95rem;
}
.doc-source {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
  margin: 48px 0;
}
.doc-source summary {
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
}
.doc-source .codebox {
  margin-top: 20px;
}
.toc {
  position: sticky;
  top: 120px;
  align-self: start;
  padding-top: 54px;
  font-size: 0.8rem;
}
.toc > b {
  font-weight: 600;
}
#toc-links {
  display: grid;
  gap: 13px;
  margin-top: 20px;
}
#toc-links a {
  color: var(--muted);
  line-height: 1.6;
}
#toc-links a[aria-current] {
  color: var(--blue);
}
.foot {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  justify-content: space-between;
  margin: 64px 0 0;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 0.75rem;
  color: var(--muted);
}
.task-section {
  padding: 40px 0 0;
}
.task-section-heading .eyebrow {
  color: var(--text);
  font-size: 0.9rem;
  letter-spacing: 0;
  text-transform: none;
  font-weight: 600;
}
.task-section-heading p {
  color: var(--muted);
  font-size: 0.95rem;
}
.catalogue-filter {
  max-width: 100%;
  margin-top: 8px;
}
.catalogue-status {
  margin: 12px 0 24px;
}
.playground-group {
  margin-top: 60px;
}
.playground-group > p {
  color: var(--muted);
}
.playground-item {
  padding: 36px 0 48px;
  border-bottom: 1px solid var(--line);
}
.playground-item-heading {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.playground-item-heading h3 {
  margin: 0;
  font-size: 1.3rem;
}
.playground-item-heading code {
  color: var(--blue);
  font-size: 0.85rem;
}
.playground-item > p {
  color: var(--muted);
  margin-top: 18px;
}
table {
  display: block;
  overflow-x: auto;
  width: 100%;
  font-size: 0.875rem;
  margin: 24px 0 40px;
}
td,
th {
  min-width: 130px;
  vertical-align: top;
  padding: 14px;
  border: 1px solid var(--line);
}
tr:first-child {
  font-weight: 600;
  background: var(--soft);
}
/* Bootstrap tabs sit directly beside the actual, copyable example source. */
.example-block {
  margin: 24px 0 32px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  overflow: clip;
}
.example-tabs {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
  padding: 0 16px;
  gap: 12px;
}
.example-tabs .nav-tabs {
  border: 0;
  gap: 18px;
  flex-wrap: nowrap;
}
.example-tabs .nav-link {
  padding: 15px 2px 13px;
  border: 0;
  border-radius: 0;
  margin: 0;
  background: transparent;
  color: var(--muted);
  font-size: 0.8rem;
  border-bottom: 2px solid transparent;
}
.example-tabs .nav-link.active {
  background: transparent;
  color: var(--text);
  border-bottom-color: var(--text);
}
.example-kind {
  color: var(--muted);
  font-size: 0.75rem;
  white-space: nowrap;
}
.tab-pane {
  outline-offset: -3px;
}
.tab-pane > .codebox {
  margin: 0;
  border: 0;
  border-radius: 0;
}
.demo-body {
  padding: 36px;
  min-height: 220px;
}
.demo-body > :last-child {
  margin-bottom: 0;
}
.demo-body label {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  margin-bottom: 18px;
}
.demo-body .check-label {
  flex-direction: row;
  align-items: center;
  font-weight: 400;
  font-size: 0.85rem;
  margin-top: 20px;
}
.demo-body input:not([type="checkbox"]),
.demo-body textarea,
.demo-body select {
  width: 100%;
  min-width: 0;
}
.demo-body .form-select {
  padding-right: 36px;
}
.demo-body button {
  font-size: 0.85rem;
}
.demo-status {
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.7;
  margin: 22px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  min-height: 2.5rem;
}
.demo-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin: 18px 0;
}
.demo-row label {
  margin: 0;
}
.sample-form {
  width: min(100%, 400px);
  margin: 0 auto;
}
.sample-label {
  font-size: 0.72rem;
  margin-bottom: 20px;
}
.field-hint {
  font-size: 0.8rem;
  margin: -8px 0 12px;
}
.field-error {
  color: #ba3535;
  font-size: 0.8rem;
  margin: -4px 0 12px;
  min-height: 1.5em;
}
.data-preview {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
  margin: 18px 0;
  background: var(--panel);
}
.data-preview strong {
  font-size: 1.1rem;
}
.data-preview p {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
}
.data-preview output {
  font-family: monospace;
  overflow-wrap: anywhere;
}
.demo-metrics {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  margin: 24px 0;
}
.demo-metrics > span {
  display: flex;
  flex-direction: column;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--muted);
}
.demo-metrics strong {
  color: var(--text);
  font-size: 0.9rem;
}
.result-list {
  list-style: none;
  margin: 20px 0 0;
  padding: 0;
}
.result-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.875rem;
}
.article-preview {
  display: flex;
  align-items: start;
  gap: 18px;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 24px;
}
.sample-art {
  display: block;
  flex: 0 0 52px;
  width: 52px;
  height: 66px;
  border: 1px solid #1768cc15;
  border-radius: 5px;
  background: linear-gradient(135deg, #e8effc, #e8f5f5 70%, #f3e8f9);
}
.article-preview > div {
  flex: 1;
  min-width: 160px;
}
.article-preview strong {
  display: block;
  font-size: 1rem;
  margin-top: 5px;
}
.article-preview p {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 8px 0 0;
}
.article-preview button {
  margin-top: 8px;
}
.article-preview [aria-pressed="true"] {
  color: var(--blue);
  background: #1768cc0a;
  border-color: #1768cc55;
}
.task-preview {
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 24px;
}
.task-preview > div {
  flex: 1;
}
.task-preview strong {
  display: block;
  font-size: 0.9rem;
}
.task-preview small {
  display: block;
  font-size: 0.75rem;
  color: var(--muted);
}
.task-checkbox {
  display: inline-block;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  border: 1px solid #bec7d3;
  border-radius: 50%;
}
.empty-task {
  padding: 26px;
  border: 1px dashed var(--line);
  color: var(--muted);
  font-size: 0.9rem;
  border-radius: 8px;
  text-align: center;
}
.editor-state {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
  font-size: 0.8rem;
  color: var(--muted);
}
.editor-state [data-dirty="true"] {
  color: var(--orange);
}
.demo-toolbar {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  border: 1px solid var(--line);
  border-radius: 7px;
  width: fit-content;
  padding: 5px;
}
.demo-toolbar button {
  border-color: transparent;
}
.demo-toolbar [aria-pressed="true"] {
  background: #1768cc0d;
  color: var(--blue);
}
.hint-wrap {
  position: relative;
}
.hint-wrap [role="tooltip"] {
  position: absolute;
  z-index: 2;
  background: var(--text);
  color: var(--bg);
  border-radius: 5px;
  padding: 7px 10px;
  font-size: 0.75rem;
  width: max-content;
  max-width: 180px;
  top: calc(100% + 8px);
  left: 0;
  pointer-events: none;
}
.sample-document {
  padding: 28px;
  background: var(--soft);
  border-radius: 6px;
  margin: 24px 0;
  font-size: 1rem;
}
.destination-list {
  display: grid;
  gap: 6px;
  width: min(100%, 340px);
}
.destination-list button {
  text-align: left;
  border-color: var(--line);
}
.input-device {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 32px;
  margin-bottom: 24px;
  background: var(--soft);
  border-radius: 8px;
}
.device-symbol {
  color: var(--blue);
  font-size: 2rem;
}
.drag-track {
  display: grid;
  place-items: center;
  min-height: 180px;
  border: 1px dashed #cbd3df;
  background: var(--soft);
  border-radius: 8px;
  overflow: hidden;
}
.drag-handle {
  touch-action: none;
  user-select: none;
  background: var(--panel);
  box-shadow: 0 4px 16px #20242b08;
}
.drag-handle span {
  color: var(--muted);
  margin-right: 10px;
}
.motion-stage {
  background: var(--soft);
  padding: 30px 22px;
  border-radius: 8px;
  margin-bottom: 22px;
  min-height: 96px;
}
.motion-box {
  width: 25%;
  height: 30px;
  border-radius: 5px;
  background: var(--blue);
}
.motion-dot {
  display: block;
  background: var(--teal);
  border-radius: 50%;
  width: 32px;
  height: 32px;
}
.list-demo {
  max-height: 230px;
  overflow: auto;
  overscroll-behavior: contain;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.list-demo > div {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border-bottom: 1px solid var(--line);
  font-size: 0.85rem;
}
.list-demo .muted {
  font-size: 0.75rem;
  margin-left: auto;
}
.basket-count {
  display: flex;
  justify-content: space-between;
  font-size: 0.875rem;
  padding-top: 20px;
}
.report-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 24px;
}
.report-bars {
  display: flex;
  align-items: end;
  gap: 12px;
  height: 80px;
  margin-top: 16px;
}
.report-bars i {
  flex: 1;
  background: #1768cc25;
  height: 45%;
  border-radius: 3px 3px 0 0;
}
.report-bars i:nth-child(2n) {
  height: 75%;
  background: #1768cc45;
}
.report-bars i:nth-child(3n) {
  height: 100%;
}
.spinner {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid var(--line);
  border-top-color: var(--blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.deferred-scroll {
  max-height: 270px;
  overflow: auto;
  border: 1px solid var(--line);
  padding: 24px;
  border-radius: 8px;
  overscroll-behavior: contain;
}
.deferred-intro {
  min-height: 350px;
}
.deferred-intro p {
  margin-top: 10px;
  font-size: 0.85rem;
  color: var(--muted);
}
.scroll-cue {
  display: block;
  font-size: 2rem;
  text-align: center;
  margin-top: 70px;
  color: var(--muted);
}
.prefetch-preview a {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
}
.prefetch-preview a span {
  font-size: 0.85rem;
  color: var(--muted);
}
.filter-popover {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
  margin-top: 14px;
  max-width: 320px;
  box-shadow: 0 12px 32px #20242b08;
}
.project-trigger {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  width: 100%;
  text-align: left;
}
.project-trigger .muted {
  font-size: 0.75rem;
}
.project-preview {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 22px;
  margin-top: 14px;
}
.project-preview .sample-art {
  width: 100%;
  height: 70px;
  margin-bottom: 18px;
}
.project-preview p {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 10px 0;
}
.menu-demo {
  display: grid;
  grid-template-columns: minmax(120px, 0.85fr) minmax(0, 1.3fr);
  gap: 16px;
}
.triggers {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.triggers button {
  text-align: left;
  width: 100%;
  display: flex;
  justify-content: space-between;
  padding: 11px 12px;
  border-color: transparent;
}
.triggers button[aria-expanded="true"] {
  color: var(--blue);
  background: #1768cc0a;
  border-color: #1768cc20;
}
.menu-panel {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  min-width: 0;
}
.menu-panel b {
  padding: 0 0 10px;
  font-size: 0.8rem;
}
.menu-panel a {
  font-size: 0.8rem;
  padding: 7px 0;
}
.demo-dialog {
  max-width: min(460px, calc(100vw - 32px));
  width: 100%;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 12px;
  color: var(--text);
  background: var(--panel);
}
.demo-dialog::backdrop {
  background: #151a2470;
  backdrop-filter: blur(3px);
}
.demo-dialog h3 {
  margin: 0 0 18px;
  font-size: 1.5rem;
}
.demo-dialog p {
  color: var(--muted);
}
.demo-dialog label {
  display: block;
  font-size: 0.85rem;
  margin-bottom: 20px;
}
.demo-dialog input {
  margin-top: 8px;
}
.floating-stage {
  position: relative;
  min-height: 180px;
  display: grid;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: 8px;
}
.floating-panel {
  z-index: 10;
  width: min(290px, calc(100vw - 48px));
  overflow: auto;
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 12px 30px #20242b18;
}
.floating-panel-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}
.floating-panel-heading button {
  padding: 1px 7px;
  border: 0;
  font-size: 1.5rem;
}
.floating-panel p {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 16px 0;
}
.floating-panel > button {
  display: block;
  width: 100%;
  margin-top: 8px;
}
.floating-placement {
  margin-top: 22px;
}
/* Build-time syntax highlighting preserves the source and language semantics. */
.codebox {
  margin: 24px 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--code);
  overflow: hidden;
}
.codehead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.75rem;
}
.copy-button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: 0.75rem;
  padding: 4px 8px;
  border-radius: 4px;
}
.copy-button:hover {
  color: var(--text);
  background: var(--panel);
}
pre {
  margin: 0;
  color: var(--text);
  background: transparent;
  font-size: 0.8rem;
  line-height: 1.9;
  tab-size: 2;
  overflow: auto;
  white-space: pre;
  padding: 24px;
  max-height: 600px;
}
pre code {
  color: inherit;
  background: transparent;
  font-size: inherit;
  padding: 0;
}
.tok-keyword {
  color: var(--orange);
}
.tok-declaration {
  color: var(--purple);
}
.tok-string {
  color: var(--teal);
}
.tok-function {
  color: var(--blue);
}
.tok-comment {
  color: var(--muted);
}
/* Native search dialog keeps focus out of the background while open. */
.search-dialog {
  width: min(660px, calc(100vw - 32px));
  max-height: min(680px, 85dvh);
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--panel);
  color: var(--text);
  margin-top: 12dvh;
  box-shadow: 0 24px 90px #10172025;
}
.search-dialog::backdrop {
  background: #20242b60;
  backdrop-filter: blur(3px);
}
.search-input-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
}
.search-input-row input {
  border: 0;
  box-shadow: none;
  background: transparent;
  padding: 4px 0;
  min-width: 0;
  font-size: 1rem;
}
.search-input-row input:focus {
  box-shadow: none;
}
.search-input-row button {
  font-size: 0.7rem;
  padding: 5px 7px;
}
.search-status {
  color: var(--muted);
  font-size: 0.75rem;
  padding: 16px 20px 8px;
}
#search-results {
  padding: 0 10px 12px;
  overflow: auto;
  max-height: 430px;
}
.search-result {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 12px;
  border-radius: 6px;
}
.search-result:hover,
.search-result.is-active {
  background: var(--soft);
  color: var(--text);
}
.search-result-copy {
  display: grid;
  gap: 5px;
}
.search-result strong {
  font-size: 0.9rem;
}
.search-result small {
  font-size: 0.8rem;
  color: var(--muted);
}
.search-result-category {
  font-size: 0.7rem;
  color: var(--muted);
  white-space: nowrap;
}
.search-help {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  padding: 12px 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.7rem;
}
.search-help kbd {
  margin-right: 4px;
}
.search-empty {
  display: grid;
  gap: 10px;
  padding: 32px 20px;
  font-size: 0.9rem;
}
.search-empty span {
  color: var(--muted);
}
.nav-backdrop {
  position: fixed;
  z-index: 110;
  inset: 72px 0 0;
  border: 0;
  background: #20242b66;
  border-radius: 0;
}
@media (min-width: 1400px) {
  .layout {
    gap: 64px;
  }
}
@media (max-width: 1180px) {
  .layout {
    grid-template-columns: 250px minmax(0, 1fr);
    gap: 40px;
  }
  .toc {
    display: none;
  }
  .landing-links {
    gap: 18px;
  }
  .landing-nav {
    gap: 24px;
  }
  .home-hero {
    gap: 44px;
  }
  .benefit-grid {
    gap: 26px;
  }
  .start-steps {
    grid-template-columns: 1fr 1.2fr;
    gap: 32px;
  }
  .start-steps article:last-child {
    grid-column: 1/-1;
    max-width: 540px;
  }
}
@media (max-width: 960px) {
  .landing-links {
    display: none;
  }
  .landing-nav-actions {
    margin-left: auto;
  }
  .home-hero {
    grid-template-columns: 1fr;
    padding: 72px 0 80px;
    gap: 48px;
  }
  .hero-copy {
    max-width: 650px;
  }
  .home-hero h1 {
    font-size: 4.5rem;
  }
  .hero-example {
    max-width: 620px;
  }
  .benefit-grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
  }
  .home-experiment {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .home-primitives {
    grid-template-columns: 1fr 1fr;
  }
  .framework-grid {
    grid-template-columns: 1fr 1fr;
  }
  .landing-footer {
    flex-wrap: wrap;
  }
}
@media (max-width: 820px) {
  .docs-page > header {
    height: 64px;
    padding: 0 20px;
    gap: 12px;
  }
  .docs-page > header .brand {
    font-size: 1.05rem;
  }
  .version {
    display: none;
  }
  .mobile-nav {
    display: grid;
    place-items: center;
    padding: 7px;
    width: 38px;
    height: 38px;
    border-color: var(--line);
  }
  .search-trigger {
    width: 38px;
    height: 38px;
    margin-left: auto;
    padding: 8px;
  }
  .search-trigger-label,
  .search-trigger kbd {
    display: none;
  }
  .theme-toggle {
    min-height: 38px;
    width: 38px;
  }
  .layout {
    display: block;
    padding: 0 24px;
  }
  .docs-page main {
    padding: 40px 0;
  }
  .sidebar {
    display: none;
    position: fixed;
    z-index: 120;
    left: 0;
    top: 64px;
    bottom: 0;
    width: min(360px, 90vw);
    height: calc(100dvh - 64px);
    padding: 24px 20px 60px;
    background: var(--bg);
    border-right: 1px solid var(--line);
  }
  .sidebar.open {
    display: block;
  }
  .sidebar-top {
    padding: 0 5px 18px;
  }
  #sidebar-close {
    display: block;
    border: 0;
    padding: 0 10px;
    font-size: 1.5rem;
    background: transparent;
  }
  .nav-backdrop {
    top: 64px;
  }
  .nav-open {
    overflow: hidden;
  }
  .docs-page h1 {
    font-size: clamp(1.8rem, 5.8vw, 2.6rem);
    overflow-wrap: break-word;
  }
  .toc {
    display: none;
  }
}
@media (max-width: 600px) {
  .landing-nav {
    min-height: 68px;
    padding: 0 22px;
    gap: 16px;
  }
  .landing-github {
    display: none;
  }
  .landing-docs-link {
    font-size: 0.8rem;
    padding: 0.6rem 0.75rem;
  }
  .landing-shell,
  .landing-footer {
    width: calc(100% - 44px);
  }
  .home-hero {
    padding: 54px 0 64px;
    gap: 36px;
  }
  .home-hero .eyebrow {
    font-size: 0.7rem;
    letter-spacing: 0.04em;
  }
  .home-hero h1 {
    font-size: clamp(2.8rem, 12.2vw, 4.2rem);
    margin-bottom: 24px;
  }
  .hero-description {
    font-size: 1.13rem;
  }
  .hero-detail {
    font-size: 0.95rem;
  }
  .hero-facts {
    font-size: 0.75rem;
  }
  .hero-example {
    padding: 22px;
  }
  .hero-example .demo-body {
    padding: 20px;
  }
  .hero-example-caption {
    font-size: 0.75rem;
  }
  .example-intro h2 {
    font-size: 1.35rem;
  }
  .landing-section {
    padding: 64px 0;
  }
  .section-heading {
    margin-bottom: 32px;
  }
  .section-heading h2 {
    font-size: 2.05rem;
  }
  .section-heading p:not(.eyebrow) {
    font-size: 0.95rem;
  }
  .benefit-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .benefit-item {
    display: block;
    border-bottom: 1px solid var(--line);
    padding-bottom: 28px;
  }
  .benefit-item:last-child {
    border-bottom: 0;
  }
  .benefit-item h3 {
    margin-top: 18px;
  }
  .home-experiment {
    padding: 32px 0;
  }
  .home-primitives,
  .cards {
    grid-template-columns: 1fr;
  }
  .card {
    padding: 22px;
  }
  .start-steps {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .start-steps article:last-child {
    grid-column: auto;
  }
  .framework-grid {
    grid-template-columns: 1fr;
  }
  .framework-grid a {
    padding: 20px 0;
  }
  .landing-cta {
    padding: 64px 0;
  }
  .landing-footer {
    padding: 32px 0;
    display: grid;
    gap: 24px;
  }
  .landing-footer nav {
    gap: 14px 24px;
  }
  .landing-footer small {
    margin: 0;
  }
  .demo-body {
    padding: 24px 20px;
  }
  .example-tabs {
    padding: 0 12px;
  }
  .example-tabs .nav-tabs {
    gap: 18px;
  }
  .example-kind {
    display: none;
  }
  .menu-demo {
    gap: 8px;
    grid-template-columns: minmax(95px, 0.9fr) minmax(0, 1.3fr);
  }
  .menu-panel {
    padding: 15px 12px;
  }
  .triggers button {
    padding: 10px 7px;
    font-size: 0.75rem;
  }
  .menu-panel a {
    font-size: 0.75rem;
  }
  .demo-row {
    gap: 8px;
  }
  .demo-row button {
    padding: 10px 12px;
    font-size: 0.78rem;
  }
  .task-preview {
    padding: 16px;
    gap: 10px;
    flex-wrap: wrap;
  }
  .task-preview .tag {
    display: none;
  }
  .demo-metrics {
    gap: 20px;
  }
  .project-trigger {
    flex-direction: column;
    align-items: start;
    gap: 5px;
  }
  .article-preview {
    padding: 20px;
  }
  .article-preview > div {
    min-width: 130px;
  }
  .reference-panel > div {
    grid-template-columns: 1fr;
    gap: 10px;
  }
  pre {
    font-size: 0.75rem;
    padding: 20px;
  }
  .codehead {
    padding: 8px 14px;
  }
  .code-caption {
    margin-top: 24px;
  }
  .search-result {
    flex-direction: column;
    gap: 5px;
  }
  .search-help {
    display: none;
  }
  .search-dialog {
    margin-top: 7dvh;
    max-height: 85dvh;
  }
  .deferred-scroll {
    padding: 18px;
  }
  .list-demo .muted {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
