.hero {
  position: relative;
  overflow: hidden;
  background: var(--bg-cream);
  color: var(--text);
  min-height: calc(100vh - var(--nav-h) - var(--peek));
  min-height: calc(100svh - var(--nav-h) - var(--peek));
  display: grid;
  align-content: center;
}
.stage { position: relative; width: 100%; height: 740px; display: grid; place-items: center; }
.lede { position: relative; z-index: 6; width: 100%; max-width: 640px; padding-inline: 20px; text-align: center; }
.hero__title { margin: 0; font-size: clamp(30px, 2.1vw + 18px, 48px); line-height: 1.2; letter-spacing: .012em; }
.hero__line { display: block; }
.hero__desc { max-width: 600px; margin: 24px auto 0; font-size: 17px; line-height: 1.8; color: var(--text-muted); }
.hero__desc strong { color: var(--text); font-weight: 600; }
.cta { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
.platforms { margin-top: 32px; }
.platforms__list { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; list-style: none; }
.platforms__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 36px;
  padding: 6px 15px 6px 13px;
  border: 1px solid var(--line-ink);
  border-radius: var(--r-pill);
  background: var(--clear);
  color: var(--text);
  font-size: 14px;
  text-decoration: none;
  transition: transform var(--time-fast) var(--ease), background-color var(--time-fast) var(--ease), box-shadow var(--time-fast) var(--ease);
}
.platforms__link svg { width: 15px; height: 15px; color: var(--accent-dark); flex: none; }
.platforms__link:hover { background: var(--bg); color: var(--text); border-color: var(--line-soft); box-shadow: var(--shadow-chip); transform: translateY(-2px); }
.rig { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.rig > * { position: absolute; }
.rig__lines { left: calc(50% - 800px); top: 0; width: 1600px; max-width: none; height: 740px; z-index: 4; overflow: visible; }
.wire { fill: none; stroke: var(--apricot); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.wire--dash { stroke-dasharray: 4 5; }
.rivet { fill: var(--bg); stroke: var(--apricot); stroke-width: 1.5; }
.frame { z-index: 2; border-radius: var(--r-frame); overflow: hidden; box-shadow: var(--shadow-frame); }
.frame svg { display: block; width: 100%; height: 100%; }
.frame--desk-a { left: calc(50% - 776px); top: 120px; width: 336px; height: 300px; }
.frame--desk-b { left: calc(50% + 380px); top: 478px; width: 300px; height: 230px; }
.i-sage50 { fill: var(--ill-sage-50); }
.i-sage100 { fill: var(--ill-sage-100); }
.i-sage300 { fill: var(--ill-sage-300); }
.i-sage500 { fill: var(--ill-sage-500); }
.i-ink { fill: var(--ill-ink); }
.i-ink2 { fill: var(--ill-ink-2); }
.i-apr50 { fill: var(--ill-apricot-50); }
.i-apr200 { fill: var(--ill-apricot-200); }
.i-apr400 { fill: var(--ill-apricot-400); }
.i-apr600 { fill: var(--ill-apricot-600); }
.i-panel { fill: var(--bg-panel); }
.i-white { fill: var(--bg); }
.i-accent { fill: var(--accent); }
.st { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.st-ink { stroke: var(--ill-ink); stroke-width: 2; }
.st-hair { stroke: var(--ill-ink); stroke-width: 1.1; opacity: .5; }
.st-arm { stroke: var(--ill-ink); stroke-width: 5; }
.st-stripe { stroke: var(--ill-apricot-600); stroke-width: 3.5; }
.st-tail-a { stroke: var(--ill-apricot-400); stroke-width: 12; }
.st-tail-b { stroke: var(--ill-ink-2); stroke-width: 9; }
.st-keys { stroke: var(--ill-sage-500); stroke-width: 2.4; stroke-dasharray: 7 3; }
.st-mull { stroke: var(--ill-sage-100); stroke-width: 4; }
.st-cream { stroke: var(--ill-apricot-50); stroke-width: 1.4; }
.st-cream-hair { stroke: var(--ill-apricot-50); stroke-width: 1; opacity: .6; }
.st-signal { stroke: var(--ill-apricot-600); stroke-width: 2; }
.st-router { fill: var(--bg); stroke: var(--ill-sage-300); stroke-width: 2; }
.ucard { z-index: 3; background: var(--bg); color: var(--text); border: 1px solid var(--line-soft); border-radius: var(--r-card); box-shadow: var(--shadow-card); }
.ucard__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 18px; }
.ucard__title { font-size: 13.5px; font-weight: 600; line-height: 18px; }
.ucard__file { font-family: var(--font-mono); font-size: 11px; line-height: 18px; padding: 0 8px; border: 1px solid var(--border); border-radius: var(--r-pill); color: var(--text-muted); }
.ucard--mode { left: calc(50% - 220px); top: 14px; width: 250px; height: 96px; padding: 14px 16px; }
.seg { display: flex; margin-top: 12px; padding: 3px; border: 1px solid var(--line-soft); border-radius: var(--r-pill); background: var(--bg-panel); color: var(--text); }
.seg__opt { flex: 1; height: 30px; line-height: 30px; text-align: center; font-size: 13px; color: var(--text-muted); border-radius: var(--r-pill); }
.seg__opt.is-on { background: var(--bg); color: var(--accent-dark); font-weight: 600; box-shadow: var(--shadow-seg); }
.ucard--toggles { left: calc(50% + 290px); top: 20px; width: 290px; padding: 6px 16px; transform: rotate(1.5deg); }
.setrow { display: flex; align-items: center; gap: 12px; padding: 11px 0; }
.setrow + .setrow { border-top: 1px solid var(--border); }
.setrow__ico { display: grid; place-items: center; width: 32px; height: 32px; border-radius: var(--r-icon); background: var(--bg-panel); color: var(--accent-dark); flex: none; }
.setrow__ico svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.setrow__txt { flex: 1; min-width: 0; }
.setrow__name { display: block; font-size: 14px; font-weight: 600; line-height: 20px; }
.setrow__hint { display: block; font-size: 12px; line-height: 17px; color: var(--text-muted); }
.switch { position: relative; width: 38px; height: 22px; border-radius: var(--r-pill); background: var(--accent); color: var(--bg); flex: none; }
.switch::after { content: ""; position: absolute; top: 3px; right: 3px; width: 16px; height: 16px; border-radius: var(--r-circle); background: var(--bg); color: var(--text); box-shadow: var(--shadow-knob); }
.ucard--import { left: calc(50% - 624px); top: 520px; width: 300px; padding: 15px 16px 16px; transform: rotate(-1.2deg); }
.field { display: flex; align-items: center; gap: 8px; margin-top: 12px; padding: 5px 5px 5px 13px; border: 1px solid var(--border); border-radius: var(--r-pill); background: var(--bg-panel); color: var(--text); }
.field__ph { flex: 1; min-width: 0; font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); overflow-wrap: anywhere; }
.field__btn { flex: none; min-height: 28px; display: inline-flex; align-items: center; justify-content: center; padding: 3px 15px; border-radius: var(--r-pill); background: var(--accent); color: var(--bg); font-size: 13px; font-weight: 500; }
.ucard__note { margin-top: 10px; font-size: 12px; line-height: 17px; color: var(--text-muted); }
.ucard--rules { left: calc(50% + 370px); top: 270px; width: 300px; height: 132px; padding: 14px 16px; }
.code { margin: 10px 0 0; padding: 10px 12px; border: 0; border-radius: var(--r-field); background: var(--bg-panel); color: var(--text); font-family: var(--font-mono); font-size: 12.5px; line-height: 19px; white-space: pre; overflow-x: auto; }
.code__type { color: var(--accent-dark); font-weight: 500; }
.code__pol { color: var(--text-muted); }
.tag { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; max-width: 100%; padding: 7px 16px 7px 13px; border-radius: var(--r-pill); background: var(--apricot); color: var(--text); font-size: 14px; font-weight: 500; box-shadow: var(--shadow-tag); overflow-wrap: anywhere; }
.tag svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.rig .tag { z-index: 5; white-space: nowrap; }
.tag--import { left: calc(50% - 520px); top: 392px; }
.tag--mode { left: calc(50% + 180px); top: 104px; }
.tag--rules { left: calc(50% + 320px); top: 452px; }
.after { background: var(--bg); color: var(--text); }
.after__inner { max-width: var(--content-width); margin-inline: auto; padding: 72px var(--gutter) 96px; }
.after__eyebrow, .eyebrow { margin: 0; font-size: 13px; letter-spacing: .08em; color: var(--accent-dark); }
.after__title { margin: 10px 0 0; font-size: 32px; line-height: 1.3; }
.after__text { max-width: 640px; margin: 14px 0 0; color: var(--text-muted); }
.tabset { min-width: 0; }
.tablist, [role="tablist"].tablist { display: flex; gap: 10px; overflow-x: auto; max-width: 100%; padding: 4px 2px 12px; }
.tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-shrink: 0;
  min-height: 46px;
  padding: 10px 20px;
  border: 1px solid var(--border);
  border-radius: var(--r-pill);
  background: var(--bg);
  color: var(--text);
  font-size: 15px;
}
.tab:hover { border-color: var(--accent); }
.tab[aria-selected="true"] { background: var(--bg-panel); color: var(--accent-dark); border-color: var(--line-soft); }
.tab[aria-selected="true"]::before { content: ""; position: absolute; left: 13px; top: 14px; bottom: 14px; width: 3px; border-radius: var(--r-line); background: var(--accent); color: var(--bg); }
.tabpanel { min-width: 0; scroll-margin-top: calc(var(--nav-h) + 24px); }
.tabpanel.is-active { animation: folder-in var(--time-panel) var(--ease); }
@keyframes folder-in { from { opacity: .35; } to { opacity: 1; } }
.feature-browser { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 36px; align-items: start; }
.feature-browser .tablist { flex-direction: column; overflow: visible; }
.feature-browser .tab { justify-content: flex-start; width: 100%; padding-left: 28px; border-color: var(--clear); }
.feature-panel { border: 1px solid var(--line-soft); border-radius: var(--r-frame); background: var(--bg); color: var(--text); padding: 28px; box-shadow: var(--shadow-card); }
.feature-scene { position: relative; overflow: hidden; border-radius: var(--r-frame); background: var(--ill-sage-50); color: var(--text); margin-bottom: 28px; }
.feature-scene > svg { width: 100%; height: 230px; display: block; }
.feature-setting { position: absolute; top: 20px; right: 20px; padding: 14px 18px; border: 1px solid var(--line-soft); border-radius: var(--r-card); background: var(--bg); color: var(--text); box-shadow: var(--shadow-card); font-family: var(--font-mono); font-size: 13px; }
.feature-panel p { line-height: 1.9; color: var(--text-muted); }
.toc { position: sticky; top: var(--nav-h); z-index: 12; display: flex; gap: 10px; overflow-x: auto; max-width: 100%; padding: 12px 0; border-block: 1px solid var(--border); background: var(--bg); color: var(--text); overscroll-behavior-x: contain; }
.toc a { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; min-height: 44px; padding: 9px 18px; border-radius: var(--r-pill); color: var(--text); font-size: 14px; text-decoration: none; }
.toc a:hover { background: var(--bg-panel); color: var(--accent-dark); }
.faq { border-bottom: 1px solid var(--border); padding: 0; }
.faq:first-child { border-top: 1px solid var(--border); }
.faq summary { position: relative; list-style: none; cursor: pointer; min-height: 64px; padding: 20px 42px 20px 0; font-weight: 500; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 8px; top: 18px; font-size: 23px; color: var(--accent-dark); }
.faq[open] summary::after { content: "−"; }
.faq__answer { padding: 0 30px 20px 0; color: var(--text-muted); line-height: 1.85; }
.term-card { padding: 28px; border-radius: var(--r-frame); border: 1px solid var(--border); background: var(--bg-panel); color: var(--text); min-width: 0; }
.term-card__name { font-family: var(--font-display); font-size: 26px; font-weight: 400; margin-bottom: 8px; }
.term-card__alias { display: block; font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); margin-bottom: 18px; overflow-wrap: anywhere; }
.term-card p { line-height: 1.85; }
.client-card { position: relative; padding: 30px; border: 1px solid var(--border); border-radius: var(--r-frame); background: var(--bg); color: var(--text); box-shadow: var(--shadow-card); min-width: 0; }
.client-card--first { border-color: var(--accent); }
.client-card__head { display: flex; align-items: flex-start; flex-wrap: wrap; justify-content: space-between; gap: 14px; }
.client-card h3 { margin: 0; }
.client-card__version { display: inline-block; margin-top: 8px; font-family: var(--font-mono); font-size: 12px; color: var(--text-muted); }
[data-ver]:empty { display: none; }
.client-card__body { margin-top: 20px; color: var(--text-muted); }
.client-card__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.badges { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 8px; }
.badge { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 5px 12px; border: 1px solid var(--border); border-radius: var(--r-pill); background: var(--bg-panel); color: var(--text); font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.badge--first { background: var(--accent); color: var(--bg); border-color: var(--accent); }
.badge--recommended { background: var(--bg-panel); color: var(--accent-dark); border-color: var(--accent); }
.badge--archived { background: var(--bg-panel); color: var(--text-muted); border-color: var(--border); }
.dot { width: 6px; height: 6px; border-radius: var(--r-circle); background: var(--success); color: var(--text); flex: none; }
.post-card { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; padding: 28px; border-top: 1px solid var(--border); background: var(--bg); color: var(--text); }
.post-card__meta { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 20px; font-size: 12px; color: var(--text-muted); }
.post-card h3 { font-size: 25px; margin-bottom: 16px; }
.post-card h3 a { color: var(--text); text-decoration: none; }
.post-card h3 a:hover { text-decoration: underline; }
.post-card p { color: var(--text-muted); line-height: 1.8; }
.post-card__link { margin-top: auto; padding-top: 12px; }
.callout { margin: 28px 0; padding: 24px 28px; border-left: 3px solid var(--accent); border-radius: var(--r-field); background: var(--bg-panel); color: var(--text); }
.callout__title { display: block; margin-bottom: 10px; font-weight: 600; }
.callout p:last-child { margin-bottom: 0; }
.callout--warning { border-left-color: var(--warn); }
.callout--error { border-left-color: var(--error); }
.table-wrap { overflow-x: auto; max-width: 100%; min-width: 0; overscroll-behavior-x: contain; border: 1px solid var(--border); border-radius: var(--r-card); }
.data-table { width: 100%; border-collapse: collapse; background: var(--bg); color: var(--text); font-size: 14px; }
.data-table th, .data-table td, .prose table th, .prose table td, .article-body table th, .article-body table td {
  min-width: 7em;
  padding: 15px 18px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  overflow-wrap: normal;
  word-break: normal;
}
.data-table th, .prose table th, .article-body table th { background: var(--bg-panel); color: var(--text); font-weight: 600; }
.data-table tr:last-child td { border-bottom: 0; }
.prose table, .article-body table {
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  min-width: 0;
  border-collapse: collapse;
  overscroll-behavior-x: contain;
}
.article-body { min-width: 0; max-width: 100%; }
.article-body div, .article-body section { min-width: 0; max-width: 100%; }
.article-download { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 24px; margin-top: 48px; padding: 28px; border-radius: var(--r-frame); border: 1px solid var(--border); background: var(--bg-panel); color: var(--text); }
.article-download__copy { flex: 1 1 250px; min-width: 0; }
.article-download h2 { font-size: 26px; margin: 0 0 10px; }
.article-download p { color: var(--text-muted); margin: 0; }
.dl-fab { position: fixed; right: 24px; bottom: 24px; z-index: 25; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 5px 20px 5px 6px; border: 1px solid var(--line-soft); border-radius: var(--r-pill); background: var(--bg); color: var(--text); font-size: 14px; font-weight: 600; text-decoration: none; box-shadow: var(--shadow-fab); transition: transform var(--time-fast) var(--ease); }
.dl-fab__ico { display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r-circle); background: var(--accent); color: var(--bg); flex: none; }
.dl-fab__ico svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.dl-fab:hover { transform: translateY(-2px); }
.palette-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.swatch { margin: 0; min-width: 0; border: 1px solid var(--border); border-radius: var(--r-card); overflow: hidden; background: var(--bg); color: var(--text); }
.swatch svg { display: block; width: 100%; height: 68px; }
.swatch figcaption { padding: 12px; font-family: var(--font-mono); font-size: 12px; overflow-wrap: anywhere; }
.sw-bg { fill: var(--bg); }
.sw-panel { fill: var(--bg-panel); }
.sw-cream { fill: var(--bg-cream); }
.sw-border { fill: var(--border); }
.sw-accent { fill: var(--accent); }
.sw-accent-dark { fill: var(--accent-dark); }
.sw-link { fill: var(--link); }
.sw-apricot { fill: var(--apricot); }
.sw-text { fill: var(--text); }
.sw-muted { fill: var(--text-muted); }
.sw-success { fill: var(--success); }
.sw-warn { fill: var(--warn); }
.sw-error { fill: var(--error); }
.sw-line-ink { fill: var(--line-ink); }
.sw-line-soft { fill: var(--line-soft); }
.sw-veil { fill: var(--veil); }
.sw-clear { fill: var(--clear); }
.preview-type { margin-top: 24px; }
@media (max-width: 1240px) {
  .ucard--mode, .tag--mode, .wire-1, .rivet-1, .ucard--rules, .tag--rules, .wire-3, .rivet-3 { display: none; }
}
@media (max-width: 1080px) {
  .hero { min-height: 0; display: block; }
  .stage { height: auto; display: flex; flex-direction: column; align-items: center; padding: 48px 20px 56px; }
  .rig { position: relative; inset: auto; width: 100%; max-width: 480px; margin-top: 44px; display: grid; grid-template-columns: 1.05fr 1fr; grid-template-rows: auto auto; gap: 14px; }
  .rig > * { min-width: 0; }
  .rig .frame, .rig .ucard { position: relative; left: auto; top: auto; width: auto; height: auto; }
  .rig__lines, .rig .tag, .rig .ucard--mode, .rig .ucard--rules, .rig .frame--desk-b { display: none; }
  .rig .frame--desk-a { grid-column: 1; grid-row: 1 / span 2; align-self: center; aspect-ratio: 336 / 300; }
  .rig .ucard--toggles { grid-column: 2; grid-row: 1; margin-top: -8px; }
  .rig .ucard--import { grid-column: 2; grid-row: 2; margin-left: -34px; }
  .dl-fab { right: 16px; bottom: 16px; }
}
@media (max-width: 760px) {
  .hero__title { font-size: 28px; }
  .hero__desc { font-size: 15.5px; }
  .platforms__list { gap: 8px; }
  .after__inner { padding-top: 56px; padding-bottom: 80px; }
  .after__title { font-size: 26px; }
  .feature-browser { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .feature-browser .tablist { flex-direction: row; overflow-x: auto; }
  .feature-browser .tab { width: auto; }
  .palette-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .ucard--toggles, .ucard--import { transform: none; }
  .feature-panel { padding: 20px; }
  .feature-setting { top: 14px; right: 14px; padding: 10px; font-size: 12px; }
  .palette-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .callout { padding: 20px; }
  .client-card { padding: 24px; }
  .dl-fab { right: 16px; bottom: max(16px, env(safe-area-inset-bottom)); }
}
@media (max-width: 440px) {
  .setrow__hint, .ucard__note { display: none; }
  .rig .ucard--import { margin-left: -20px; }
  .rig .ucard--toggles { padding-inline: 10px; }
  .setrow { gap: 7px; }
  .setrow__ico { width: 24px; height: 28px; }
  .setrow__name { font-size: 12px; }
  .switch { width: 32px; }
  .field { padding-left: 8px; gap: 4px; }
  .field__btn { padding-inline: 10px; }
}