/* 首屏：采用已确认的自然高度与三联设置窗。 */
.hero { position:relative; overflow:hidden; overflow-x:clip; background:linear-gradient(180deg,var(--bg) 0%,var(--bg) 22%,var(--bg-panel) 100%); color:var(--text) }
.hero-atmo { position:absolute; inset:0; pointer-events:none }
.hero-grid-wrap {
  position:absolute; left:0; right:0; bottom:0; height:600px; overflow:hidden;
  -webkit-mask-image:radial-gradient(ellipse 58% 92% at 50% 100%,var(--ink) 30%,var(--clear) 100%);
  mask-image:radial-gradient(ellipse 58% 92% at 50% 100%,var(--ink) 30%,var(--clear) 100%);
}
.hero-grid {
  position:absolute; left:50%; bottom:0; width:2400px; height:1200px; margin-left:-1200px;
  background-image:linear-gradient(to right,var(--grid-line) 1px,var(--clear) 1px),linear-gradient(to bottom,var(--grid-line) 1px,var(--clear) 1px);
  background-size:60px 60px; background-position:center bottom;
  transform-origin:50% 100%; transform:perspective(760px) rotateX(66deg);
}
.hero-in { position:relative; z-index:1; padding-top:60px; padding-bottom:52px; text-align:center }
.eyebrow {
  display:inline-flex; align-items:center; gap:9px; min-height:30px; margin:0;
  padding:4px 14px 4px 12px; max-width:100%; font-size:13px; font-weight:500;
  background:var(--surface); color:var(--text); border:1px solid var(--border);
  border-radius:var(--r-pill); box-shadow:var(--shadow-hair);
}
.pulse { position:relative; width:7px; height:7px; border-radius:var(--r-round); background:var(--accent); flex-shrink:0 }
.pulse::after { content:""; position:absolute; inset:-5px; border-radius:var(--r-round); background:var(--accent-ring); animation:breathe 2.6s ease-in-out infinite }
@keyframes breathe { 0%,100% { transform:scale(.45); opacity:0 } 50% { transform:scale(1); opacity:1 } }
.hero-title { margin:22px auto 0; font-size:var(--size-h1); line-height:1.1; letter-spacing:-.02em; font-weight:800 }
.hero-title .ln { display:block }
.lede { max-width:760px; margin:16px auto 0; font-size:17px; line-height:1.6; color:var(--text-muted) }
.lede strong { color:var(--text); font-weight:600 }
.cta-row { margin-top:28px; display:flex; justify-content:center; gap:12px; flex-wrap:wrap }
.os-row { list-style:none; margin:20px 0 0; padding:0; display:flex; justify-content:center; align-items:center; gap:6px 26px; flex-wrap:wrap }
.os-row li { display:flex }
.os-link { display:inline-flex; align-items:center; gap:7px; min-height:24px; font-size:13.5px; font-weight:500; color:var(--text-muted) }
.os-link:hover { color:var(--text) }
.os-link svg { width:15px; height:15px }
.os-lead { font-family:var(--font-mono); font-size:11.5px; letter-spacing:.02em; color:var(--text-muted) }
.gloss-trio { margin-top:54px; display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:20px; text-align:left }
.gloss-trio>* { min-width:0 }
.gloss-card {
  --card-h:248px; --win-top:-14px; --win-h:170px; --win-w:204px; --win-right:18px; --note-inset:24px; --tag-h:28px;
  position:relative; display:block; height:var(--card-h); padding:24px;
  background:var(--bg-panel); color:var(--text); border:1px solid var(--border);
  border-radius:var(--r-card); transition:transform .28s ease;
}
.gloss-card::after { content:""; position:absolute; inset:-1px; border-radius:var(--r-card); box-shadow:var(--shadow-card-lift); opacity:0; pointer-events:none; transition:opacity .28s ease }
.gloss-card:hover { transform:translateY(-2px) }
.gloss-card:hover::after { opacity:1 }
.gloss-copy { display:flex; flex-direction:column; width:calc(100% - var(--win-w) - var(--win-right) - 14px + 24px); max-width:100% }
.gloss-name { display:inline-flex; align-items:center; gap:7px; font-family:var(--font-display); font-weight:800; font-size:20px; line-height:1.3; letter-spacing:-.025em }
.gloss-name svg { width:14px; height:14px; color:var(--text-muted) }
.gloss-plat { margin-top:6px; font-family:var(--font-mono); font-size:11.5px; line-height:1.4; letter-spacing:.01em; color:var(--text-muted) }
.gloss-desc { margin-top:12px; font-size:13.5px; line-height:1.58; color:var(--text-muted) }
.setwin {
  position:absolute; z-index:2; top:var(--win-top); right:var(--win-right);
  width:var(--win-w); height:var(--win-h); display:flex; flex-direction:column;
  background:var(--surface); color:var(--text); border:1px solid var(--border); border-radius:var(--r-pop); box-shadow:var(--shadow-pop);
}
.setwin::after { content:""; position:absolute; inset:-1px; z-index:-1; border-radius:var(--r-pop); box-shadow:var(--shadow-pop-lift); opacity:0; transition:opacity .28s ease }
.gloss-card:hover .setwin::after { opacity:1 }
.setwin-bar { flex-shrink:0; display:flex; align-items:center; gap:4px; height:26px; padding:0 10px; background:var(--bg-panel); color:var(--text-muted); border-bottom:1px solid var(--border); border-radius:var(--r-pop) var(--r-pop) 0 0 }
.setwin-bar i { width:7px; height:7px; flex-shrink:0; border-radius:var(--r-round); background:var(--bg-panel-2); border:1px solid var(--border-strong) }
.setwin-bar span { margin-left:7px; font-size:11px; font-weight:500; white-space:nowrap }
.setwin-body { flex:1; display:flex; flex-direction:column; justify-content:flex-end; padding:8px 10px 10px; min-width:0 }
.set-label { padding:0 6px; font-size:10.5px; font-weight:600; letter-spacing:.02em; line-height:18px; color:var(--text-muted) }
.set-row { display:flex; align-items:center; gap:8px; min-height:30px; padding:0 6px; font-size:12.5px; font-weight:500; color:var(--text); border-radius:var(--r-row) }
.set-row.is-noted { background:var(--bg-panel); color:var(--text) }
.grow { flex:1; min-width:0 }
.set-sep { height:1px; margin:4px 6px; background:var(--border) }
.set-sub { display:block; font-size:10.5px; font-weight:400; line-height:1.35; color:var(--text-muted) }
.set-two { min-height:42px }
.set-select { display:flex; align-items:center; gap:6px; min-height:28px; margin-bottom:2px; padding:4px 8px; font-size:11.5px; font-weight:500; color:var(--text); background:var(--surface); border:1px solid var(--border); border-radius:var(--r-row) }
.set-select.is-noted { background:var(--bg-panel); color:var(--text); border-color:var(--border-strong) }
.set-gap { height:6px }
.sw { position:relative; flex-shrink:0; width:26px; height:15px; border-radius:var(--r-pill); background:var(--bg-panel-2); border:1px solid var(--border-strong) }
.sw::after { content:""; position:absolute; top:1px; left:1px; width:11px; height:11px; border-radius:var(--r-round); background:var(--surface); box-shadow:var(--shadow-knob) }
.sw.is-on { background:var(--accent); border-color:var(--accent) }
.sw.is-on::after { transform:translateX(11px) }
.rd { position:relative; flex-shrink:0; width:12px; height:12px; border-radius:var(--r-round); border:1.5px solid var(--border-strong); background:var(--surface) }
.is-on .rd { border-color:var(--accent) }
.is-on .rd::after { content:""; position:absolute; inset:2px; border-radius:var(--r-round); background:var(--accent) }
.plain-note { position:absolute; z-index:3; left:var(--note-inset); bottom:var(--note-inset); right:calc(var(--win-right) + var(--win-w) - 44px); display:flex; align-items:flex-end }
.plain-tag { flex-shrink:0; display:inline-flex; align-items:center; min-height:var(--tag-h); padding:4px 12px; font-size:12px; font-weight:500; letter-spacing:.01em; color:var(--on-ink); background:var(--ink); border-radius:var(--r-pill); box-shadow:var(--shadow-note); transform:rotate(-1.2deg) }
.plain-wire { position:relative; flex:1; min-width:24px; height:calc(var(--card-h) - var(--note-inset) - var(--tag-h)/2 - var(--win-top) - var(--win-h)); margin-bottom:calc(var(--tag-h)/2); border-right:1px dashed var(--accent); border-bottom:1px dashed var(--accent); border-bottom-right-radius:var(--r-ctl) }
.plain-wire::before { content:""; position:absolute; top:-3px; right:-3.5px; width:6px; height:6px; border-radius:var(--r-round); background:var(--accent); box-shadow:0 0 0 2px var(--surface) }
.trio-foot { margin:26px 0 0; font-size:14.5px; color:var(--text-muted) }
.trio-foot a { color:var(--accent); font-weight:600; text-decoration:underline; text-underline-offset:4px }
.demo-band,.trust-band { background:var(--ink); color:var(--on-ink); overflow-x:clip }
.demo-band .muted,.trust-band .muted { color:var(--on-ink-muted) }
.statusbar-row { border-bottom:1px solid var(--ink-line) }
.statusbar { min-height:44px; display:flex; align-items:center; gap:28px; font-family:var(--font-mono); font-size:11.5px; letter-spacing:.01em; color:var(--on-ink-muted); flex-wrap:wrap; padding-block:10px }
.sb-item { display:inline-flex; align-items:center; gap:8px }
.sb-item b { font-weight:500; color:var(--on-ink) }
.sb-dot { width:6px; height:6px; flex-shrink:0; border-radius:var(--r-round); background:var(--success) }
.sb-end { margin-left:auto }
.dl-head { padding-top:72px; padding-bottom:72px; text-align:center }
.dl-head h2 { margin:0; font-size:32px; letter-spacing:-.03em; line-height:1.15 }
.dl-head p { margin:12px 0 28px; color:var(--on-ink-muted) }
/* Tab 控件与术语对照台 */
.tab-set { min-width:0 }
.switch-tabs { display:flex; align-items:stretch; gap:6px; flex-wrap:wrap; border-bottom:1px solid var(--border); margin-bottom:24px }
.switch-tab {
  position:relative; min-height:46px; padding:10px 18px; border:0; border-bottom:3px solid var(--clear);
  background:var(--clear); color:var(--text-muted); font-weight:600; border-radius:var(--r-ctl) var(--r-ctl) 0 0;
}
.switch-tab:hover { background:var(--bg-panel); color:var(--text) }
.switch-tab[aria-selected="true"] { color:var(--text); border-bottom-color:var(--accent) }
.tab-panel { min-width:0 }
.term-desk { display:grid; grid-template-columns:260px minmax(0,1fr); gap:32px }
.term-tabs { display:flex; flex-direction:column; align-items:stretch; gap:6px; border:0; margin:0 }
.term-tabs .switch-tab { text-align:left; border-bottom:0; border-left:3px solid var(--clear); border-radius:0 var(--r-ctl) var(--r-ctl) 0; padding:14px 18px }
.term-tabs .switch-tab[aria-selected="true"] { border-left-color:var(--accent); background:var(--bg-panel); color:var(--text) }
.term-tabs strong { display:block; font-family:var(--font-mono); font-size:14px }
.term-tabs small { display:block; margin-top:4px; font-weight:400; color:var(--text-muted) }
.term-detail { padding:32px; background:var(--bg-panel); color:var(--text); border:1px solid var(--border); border-radius:var(--r-card) }
.code-window { min-width:0; background:var(--ink); color:var(--on-ink); border-radius:var(--r-pop); overflow:hidden }
.code-chrome { display:flex; align-items:center; gap:6px; padding:10px 14px; border-bottom:1px solid var(--ink-line); font-family:var(--font-mono); font-size:11px; color:var(--on-ink-muted) }
.code-chrome i { width:6px; height:6px; flex-shrink:0; border-radius:var(--r-round); background:var(--on-ink-muted) }
.code-chrome span { margin-left:8px }
.code-window pre { margin:0; border-radius:0 }
.menu-path { display:inline-block; max-width:100%; margin-top:16px; padding:5px 10px; background:var(--surface); color:var(--text-muted); border:1px solid var(--border); border-radius:var(--r-pill); font-size:12px; overflow-wrap:anywhere }
.toc { position:sticky; top:16px; z-index:5; padding:12px; background:var(--surface); color:var(--text); border:1px solid var(--border); border-radius:var(--r-pop); box-shadow:var(--shadow-hair); margin-bottom:32px }
.toc ul { display:flex; flex-wrap:wrap; gap:6px; margin:0; padding:0; list-style:none }
.toc a { display:block; padding:8px 12px; font-size:13px; border-radius:var(--r-ctl) }
.toc a:hover,.toc [aria-current] { background:var(--bg-panel); color:var(--text) }
.faq-item { border-bottom:1px solid var(--border); background:var(--bg); color:var(--text) }
.faq-item summary { position:relative; list-style:none; cursor:pointer; min-height:56px; padding:18px 36px 18px 0; font-weight:600 }
.faq-item summary::-webkit-details-marker { display:none }
.faq-item summary::after { content:"+"; position:absolute; right:8px; top:16px; color:var(--text-muted) }
.faq-item[open] summary::after { content:"−" }
.faq-answer { padding-bottom:18px; color:var(--text-muted) }
.faq-answer p:last-child { margin-bottom:0 }
.term-card { padding:24px; border:1px solid var(--border); border-radius:var(--r-card); background:var(--bg-panel); color:var(--text) }
.term-card dt { font-family:var(--font-mono); font-weight:700; margin-bottom:10px }
.term-card dd { margin:0; color:var(--text-muted) }
.client-card { padding:28px; border:1px solid var(--border); border-radius:var(--r-card); background:var(--surface); color:var(--text); box-shadow:var(--shadow-hair) }
.client-card-head { display:flex; align-items:flex-start; justify-content:space-between; flex-wrap:wrap; gap:12px; margin-bottom:16px }
.client-card-head h3 { margin:0 }
.client-card p { color:var(--text-muted) }
.client-actions { display:flex; gap:10px; flex-wrap:wrap; margin-top:24px }
.client-actions>* { min-width:0; max-width:100% }
.badge,.tag { display:inline-block; max-width:100%; padding:4px 9px; border:1px solid var(--border); border-radius:var(--r-pill); font-size:11px; font-weight:600; line-height:1.5; overflow:hidden; overflow-wrap:anywhere; vertical-align:middle; background:var(--bg-panel); color:var(--text-muted) }
.badge-primary { background:var(--ink); color:var(--on-ink); border-color:var(--ink) }
.badge-recommended { background:var(--bg-panel-2); color:var(--text); border-color:var(--border-strong) }
.badge-retired { background:var(--bg-panel); color:var(--text-muted); border-style:dashed }
.article-card { display:flex; flex-direction:column; padding:24px; border:1px solid var(--border); border-radius:var(--r-card); background:var(--bg-panel); color:var(--text); transition:transform var(--ease),box-shadow var(--ease) }
.article-card:hover { transform:translateY(-2px); box-shadow:var(--shadow-card-lift) }
.article-meta { display:flex; align-items:center; flex-wrap:wrap; gap:12px; color:var(--text-muted); font-size:12px; margin-bottom:20px }
.article-card h3 { margin-bottom:12px }
.article-card p { color:var(--text-muted); font-size:14px }
.article-more { margin-top:auto; padding-top:16px; font-size:13px; color:var(--accent); font-weight:600 }
.callout { margin:24px 0; padding:20px 24px; border:1px solid var(--border); border-left:3px solid var(--accent); border-radius:var(--r-pop); background:var(--bg-panel); color:var(--text) }
.callout p:last-child { margin-bottom:0 }
.callout-warning { border-left-color:var(--warn) }
.callout-error { border-left-color:var(--error) }
.callout-success { border-left-color:var(--success) }
.table-scroll { overflow-x:auto; max-width:100%; min-width:0; overscroll-behavior-inline:contain; -webkit-overflow-scrolling:touch; border:1px solid var(--border); border-radius:var(--r-pop) }
.data-table { width:100%; border-collapse:collapse; font-size:14px; background:var(--surface); color:var(--text) }
.data-table th,.data-table td,.prose table th,.prose table td,.article-body table th,.article-body table td { min-width:7em; padding:14px 18px; text-align:left; vertical-align:top; 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 }
.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-inline:contain; background:var(--surface); color:var(--text) }
.data-table td code,.prose table code,.article-body table code { overflow-wrap:anywhere }
.article-download { display:flex; align-items:center; justify-content:space-between; flex-wrap:wrap; gap:24px; margin-top:40px; padding:28px; border:1px solid var(--border); border-radius:var(--r-card); background:var(--bg-panel); color:var(--text) }
.article-download-copy { flex:1 1 220px; min-width:0 }
.article-download h2 { margin:0 0 8px; font-size:24px }
.article-download p { margin:0; color:var(--text-muted) }
.dl-fab { position:fixed; z-index:var(--z-fab); right:24px; bottom:24px; display:flex; align-items:center; gap:12px; max-width:calc(100% - 32px); padding:14px 18px; border:1px solid var(--border); border-radius:var(--r-pop); background:var(--surface); color:var(--text); box-shadow:var(--shadow-pop) }
.dl-fab svg { width:22px; height:22px; color:var(--accent); flex-shrink:0 }
.dl-fab strong { display:block; font-size:13px }
.dl-fab small { display:block; color:var(--text-muted); font-size:11px }
.dl-fab:hover { box-shadow:var(--shadow-pop-lift) }
/* 仅设计预览使用的令牌展示。 */
.palette-grid { display:grid; grid-template-columns:repeat(auto-fit,minmax(180px,1fr)); gap:12px }
.swatch { padding:10px; border:1px solid var(--border); border-radius:var(--r-card); background:var(--surface); color:var(--text); font-family:var(--font-mono); font-size:11px }
.swatch-chip { height:58px; margin-bottom:9px; border:1px solid var(--border); border-radius:var(--r-ctl) }
.sw-bg { background:var(--bg); color:var(--text) }
.sw-panel { background:var(--bg-panel); color:var(--text) }
.sw-panel2 { background:var(--bg-panel-2); color:var(--text) }
.sw-surface { background:var(--surface); color:var(--text) }
.sw-border { background:var(--border); color:var(--text) }
.sw-border-strong { background:var(--border-strong); color:var(--text) }
.sw-accent { background:var(--accent); color:var(--on-ink) }
.sw-accent-dark { background:var(--accent-dark); color:var(--on-ink) }
.sw-ring { background:var(--accent-ring); color:var(--text) }
.sw-text { background:var(--text); color:var(--on-ink) }
.sw-muted { background:var(--text-muted); color:var(--on-ink) }
.sw-faint { background:var(--text-faint); color:var(--text) }
.sw-ink { background:var(--ink); color:var(--on-ink) }
.sw-ink-line { background:var(--ink-line); color:var(--text) }
.sw-on-ink { background:var(--on-ink); color:var(--text) }
.sw-on-ink-muted { background:var(--on-ink-muted); color:var(--text) }
.sw-success { background:var(--success); color:var(--text) }
.sw-warn { background:var(--warn); color:var(--text) }
.sw-error { background:var(--error); color:var(--on-ink) }
.sw-grid { background:var(--grid-line); color:var(--text) }
.sw-veil { background:var(--veil); color:var(--text) }
.sw-clear { background:var(--clear); color:var(--text) }
.preview-divider { border-top:1px solid var(--border) }
@media (max-width:1180px) {
  .gloss-trio { grid-template-columns:minmax(0,1fr); max-width:620px; margin-inline:auto; gap:36px }
  .sb-end { display:none }
}
@media (max-width:768px) {
  .hero-in { padding-top:36px; padding-bottom:40px }
  .hero-title { line-height:1.15 }
  .lede { font-size:15px }
  .cta-row { gap:10px }
  .btn-main,.btn-line { min-height:44px; padding-inline:18px }
  .os-row { gap:6px 18px }
  .gloss-trio { margin-top:32px; gap:16px }
  .gloss-card { height:auto; padding:20px }
  .gloss-copy { width:auto }
  .setwin { position:relative; top:auto; right:auto; width:auto; height:auto; margin-top:16px }
  .setwin-body { justify-content:flex-start }
  .plain-note { position:relative; left:auto; right:auto; bottom:auto; margin-top:14px }
  .plain-wire { display:none }
  .plain-tag { max-width:100%; white-space:normal }
  .term-desk { grid-template-columns:minmax(0,1fr); gap:20px }
  .term-tabs { flex-direction:row; flex-wrap:wrap; gap:6px }
  .term-tabs .switch-tab { flex:1 1 130px; border-left:0; border-bottom:3px solid var(--clear); border-radius:var(--r-ctl) }
  .term-tabs .switch-tab[aria-selected="true"] { border-left:0; border-bottom-color:var(--accent) }
  .term-detail { padding:20px }
  .dl-head h2 { font-size:24px }
}
@media (max-width:640px) {
  .switch-tab { padding-inline:12px }
  .dl-fab { right:16px; bottom:16px; padding:12px 14px }
  .client-card { padding:20px }
  .toc { position:static }
  .statusbar { gap:12px 20px }
}
@media (prefers-reduced-motion:reduce) {
  .gloss-card:hover,.article-card:hover { transform:none }
}