@font-face {
  font-family: Archivo;
  src: url("../fonts/archivo-var.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "Plex Mono";
  src: url("../fonts/plex-mono-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Plex Mono";
  src: url("../fonts/plex-mono-500.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

/* ==========================================================================
   MistSpan 实验室统一视觉变量（暖纸白 + 深杉绿，保留深色主题）
   ========================================================================== */
:root {
  color-scheme: light;
  --rock: #f5f3ed;
  --paper: #edeae0;
  --surface: #e6e4d8;
  --ink: #182720;
  --ink-2: #122019;
  --forest: #21372c;
  --forest-3: #3b634f;
  --mist: #7c8d82;
  --mist-2: #97a79d;
  --moss: #7a9886;
  --signal: #b8cca4;

  --bg: var(--rock);
  --fg: #1e3127;
  --fg-2: #546158;
  --rule: #d1d0c5;
  --rule-strong: #9fa69b;
  --accent: #2c5530;

  --font-brand: Archivo, "Segoe UI", sans-serif;
  --font-serif: Georgia, "Songti SC", "Noto Serif CJK SC", "Source Han Serif SC", SimSun, serif;
  --font-mono: "Plex Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  --font-body: system-ui, -apple-system, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;

  --gutter: clamp(18px, 4.4vw, 80px);
  --space-section: clamp(56px, 7vw, 108px);
  --ease: cubic-bezier(.2, .7, .2, 1);
  --step--1: .8125rem;
  --step-1: 1.15rem;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #13211b;
  --fg: #e6eae1;
  --fg-2: #a5b4aa;
  --rule: #31453b;
  --rule-strong: #50675c;
  --surface: #1b2e26;
  --accent: #b8cca4;
}

/* ==========================================================================
   基础排版与重置
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 24px; }
body, h1, h2, h3, h4, p, ol, ul, dl, dd, figure, pre { margin: 0; }
body {
  background: var(--bg);
  color: var(--fg);
  font: 400 1rem/1.72 var(--font-body);
  -webkit-text-size-adjust: 100%;
}
h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 400;
  line-height: 1.2;
}
ul, ol { padding: 0; list-style: none; }
a { text-decoration: none; color: inherit; }
img, canvas, svg { display: block; max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
main:focus { outline: none; }
code { font: .88em var(--font-mono); overflow-wrap: anywhere; }
pre code { overflow-wrap: normal; }

/* 区块色阶 */
.t-paper { --bg: var(--paper); }
:root[data-theme="dark"] .t-paper { --bg: #172821; }

.t-ink, .t-forest {
  color-scheme: dark;
  --bg: var(--ink);
  --fg: #eaece5;
  --fg-2: #a8b5ac;
  --rule: #32463c;
  --rule-strong: #536a5e;
  --surface: #1f3229;
  --accent: var(--signal);
}
.t-forest {
  --bg: var(--forest);
  --surface: #284235;
  --fg-2: #b8c5bc;
  --rule: #3d5649;
  --rule-strong: #5f7a6c;
}
.t-paper, .t-ink, .t-forest { background-color: var(--bg); color: var(--fg); }

.wrap { width: min(100% - var(--gutter) * 2, 1360px); margin-inline: auto; }
.section { padding-block: var(--space-section); }
.section + .section { border-top: 1px solid var(--rule); }
.section.t-paper + .section,
.section.t-ink + .section,
.section.t-forest + .section,
.section + .section.t-paper,
.section + .section.t-ink,
.section + .section.t-forest { border-top: 0; }

.label {
  color: var(--fg-2);
  font-family: var(--font-mono), var(--font-body);
  font-size: .78rem;
  line-height: 1.5;
}
.muted, .note { color: var(--fg-2); }
.note { font-size: .84rem; line-height: 1.65; }
.sr-only, .skip-link:not(:focus) {
  position: absolute; width: 1px; height: 1px; padding: 0;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.skip-link:focus {
  position: absolute; top: 16px; left: 16px; z-index: 9;
  background: var(--rock); color: var(--ink); padding: 8px 16px;
}

/* ==========================================================================
   页眉与导航
   ========================================================================== */
.site-header {
  position: relative;
  z-index: 2;
  background: var(--bg);
  border-bottom: 1px solid var(--rule);
}
.header-row {
  min-height: 70px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: max-content;
  font-family: var(--font-serif);
  font-size: 1.3rem;
  line-height: 1;
  font-weight: 400;
  letter-spacing: -.02em;
}
.logo svg { width: 20px; height: 20px; }
.nav {
  display: flex;
  align-items: center;
  gap: clamp(16px, 3vw, 44px);
  font-size: .88rem;
  font-weight: 450;
}
.nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--fg-2); }
.nav a:hover, .nav a[aria-current="page"] {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: .4em;
  text-decoration-thickness: 1px;
}
.header-actions { display: flex; align-items: center; gap: 8px; justify-self: end; }
.theme-btn {
  min-width: 66px; min-height: 38px;
  display: inline-flex; justify-content: center; align-items: center; gap: 7px;
  background: transparent; border: 1px solid var(--rule);
  font-size: .78rem; color: var(--fg-2); white-space: nowrap;
}
.theme-btn span[aria-hidden] {
  width: 10px; height: 10px; border: 1px solid currentColor;
  border-radius: 50%; box-shadow: inset 4px 0 currentColor;
}
.theme-btn:hover { background: var(--surface); color: var(--fg); }
.menu-btn {
  display: none; min-height: 40px;
  border: 1px solid var(--rule-strong); padding: 0 12px;
  background: transparent; font-size: .85rem;
}
.menu-btn span { margin-left: .35em; font-size: 1rem; }
.menu-btn[aria-expanded="true"] span { display: inline-block; transform: rotate(45deg); }

/* ==========================================================================
   按钮、链接与状态标识
   ========================================================================== */
.action, .link-arrow, .btn, .text-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 42px;
  width: fit-content;
  font-size: .875rem;
  line-height: 1.3;
  font-weight: 550;
  transition: color 160ms var(--ease), background-color 160ms var(--ease), border-color 160ms var(--ease);
}
.action, .btn {
  background: var(--fg);
  color: var(--bg);
  padding: 0 16px;
  border: 1px solid var(--fg);
}
.action:hover, .btn:hover {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
}
.btn:disabled { opacity: .55; cursor: progress; }
.btn--ghost {
  background: transparent;
  color: var(--fg);
  border-color: var(--rule-strong);
}
.btn--ghost:hover {
  background: var(--fg);
  border-color: var(--fg);
  color: var(--bg);
}
.btn--sm { min-height: 38px; padding-inline: 12px; font-size: .8125rem; }

.link-arrow, .text-link {
  border-bottom: 1px solid var(--rule-strong);
  padding-bottom: 2px;
  min-height: 36px;
}
.link-arrow:hover, .text-link:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  max-width: 100%;
  color: var(--fg-2);
  font-family: var(--font-mono), var(--font-body);
  font-size: .74rem;
  font-weight: 500;
  line-height: 1.35;
}
.status::before {
  content: "";
  width: .55rem;
  height: .55rem;
  border: 1px solid currentColor;
  flex: none;
}
.status[data-status="live"] { color: var(--accent); }
.status[data-status="live"]::before { background: currentColor; }
.status[data-status="dev"]::before { border-left-width: 4px; }

/* ==========================================================================
   首页：封面、研究档案、三层结构、实验室与笔记
   ========================================================================== */
.opening { padding-block: clamp(18px, 2.5vw, 32px) clamp(44px, 5vw, 72px); }
.landscape {
  position: relative;
  height: clamp(320px, 34vw, 520px);
  background: #e7e8e3;
  isolation: isolate;
  overflow: hidden;
  border: 1px solid var(--rule);
}
.ridge {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 62%;
}
.landscape h1 {
  position: absolute;
  left: 3.2%;
  top: 5%;
  font: 400 clamp(58px, 9.5vw, 148px)/.98 var(--font-serif);
  color: #21362a;
  letter-spacing: -.04em;
}
.opening-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, .85fr);
  gap: clamp(20px, 4vw, 56px);
  align-items: start;
  padding-top: clamp(22px, 3vw, 36px);
  border-bottom: 1px solid var(--rule);
  padding-bottom: clamp(28px, 3.5vw, 44px);
}
.opening-lead {
  font-family: var(--font-serif);
  font-size: clamp(1.3rem, 2.1vw, 1.85rem);
  line-height: 1.42;
  color: var(--fg);
  max-width: 30em;
}
.opening-sub {
  margin-top: 12px;
  color: var(--fg-2);
  font-size: .95rem;
  max-width: 42em;
}
.opening-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 22px;
}
.opening-meta {
  border-left: 1px solid var(--rule);
  padding-left: clamp(16px, 2.5vw, 28px);
  display: grid;
  gap: 10px;
}
.opening-meta div {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--rule);
  font-size: .84rem;
}
.opening-meta div:last-child { border-bottom: 0; padding-bottom: 0; }
.opening-meta dt { color: var(--fg-2); }
.opening-meta dd {
  font-family: var(--font-mono), var(--font-body);
  font-size: .8rem;
  text-align: right;
  color: var(--fg);
}

/* 通用分栏标题 */
.editorial-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .9fr);
  align-items: end;
  gap: 24px;
  margin-bottom: clamp(28px, 3.6vw, 48px);
}
.editorial-heading h2,
.detail-layout h2,
.section-head h2 {
  font-size: clamp(1.75rem, 3.1vw, 2.85rem);
  letter-spacing: -.025em;
}
.editorial-heading > p {
  color: var(--fg-2);
  line-height: 1.7;
  max-width: 34em;
  justify-self: end;
}

/* 首页：研究方向与原型列表 */
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--rule-strong);
}
.project-card {
  display: flex;
  flex-direction: column;
  padding: clamp(20px, 2.5vw, 32px);
  border-right: 1px solid var(--rule-strong);
  background: var(--bg);
}
.project-card:last-child { border-right: 0; }
.project-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.project-card h3 {
  font-size: clamp(1.55rem, 2.2vw, 2.15rem);
  letter-spacing: -.02em;
  margin-bottom: 10px;
}
.project-card .project-summary {
  color: var(--fg);
  font-size: .95rem;
  line-height: 1.65;
  margin-bottom: 18px;
}
.project-points {
  margin-top: auto;
  border-top: 1px solid var(--rule);
  padding-top: 14px;
  display: grid;
  gap: 10px;
  font-size: .85rem;
}
.project-points div {
  display: grid;
  gap: 2px;
}
.project-points dt {
  color: var(--fg-2);
  font-family: var(--font-mono), var(--font-body);
  font-size: .74rem;
}
.project-points dd { color: var(--fg); }
.project-card-foot {
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid var(--rule);
}

/* 首页：三层计算剖面区 */
.arch-layout {
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
  gap: clamp(28px, 4.5vw, 68px);
  align-items: start;
}
.arch-copy p {
  margin-top: 14px;
  color: var(--fg-2);
  font-size: .95rem;
  max-width: 34em;
}
.arch-notes {
  margin-top: 22px;
  border-top: 1px solid var(--rule);
}
.arch-notes li {
  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
  font-size: .88rem;
  color: var(--fg-2);
}
.arch-notes strong {
  display: block;
  color: var(--fg);
  font-weight: 600;
  margin-bottom: 3px;
}

.system-figure {
  --board-fill: #1b2f26;
  --board-active: #254235;
  --board-grid: #335043;
  --board-edge: #668174;
  --board-dark: #20372d;
  --board-signal: #b8cca4;
  display: grid;
  min-width: 0;
  border: 1px solid #354c41;
  background: #14241d;
  color: #eaece5;
}
.system-figure-heading {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 16px;
  border-bottom: 1px solid #354c41;
  color: #a8b5ac;
  font-size: .76rem;
}
.system-figure > svg {
  width: 100%;
  height: clamp(270px, 30vw, 440px);
  aspect-ratio: 720 / 520;
  overflow: visible;
}
.board-surface, .board-side, .board-tile, .board-inset, .board-pin, .board-line, .board-tick,
.board-guide, .board-route, .board-branch, .board-leader, .board-via {
  stroke: var(--board-edge); stroke-width: 1; fill: none;
}
.board-surface { fill: var(--board-fill); }
.board-line { stroke: var(--board-grid); stroke-width: .52; }
.board-tick { stroke: var(--board-edge); stroke-width: .62; }
.board-guide { stroke: #446254; stroke-width: .8; stroke-dasharray: 3 5; }
.board-tile { fill: var(--board-dark); }
.board-inset, .board-pin { stroke: #769287; stroke-width: .65; }
.board-branch { stroke: #769287; stroke-width: 1; }
.board-route, .board-via { stroke: #9ab28c; stroke-width: 1.7; }
.board-via { stroke-dasharray: 3 5; }
.board-terminal { fill: #9ab28c; }
.board-number { fill: #a9bdb1; font-family: var(--font-mono); font-size: 13px; }
.board-layer :is(.board-route, .board-surface, .board-terminal) {
  transition: stroke 180ms var(--ease), fill 180ms var(--ease);
}
[data-active="workflow"] [data-board-layer="workflow"],
[data-active="models"] [data-board-layer="models"],
[data-active="compute"] [data-board-layer="compute"] {
  --board-fill: var(--board-active);
  --board-edge: #86a194;
  --board-grid: #446858;
}
[data-active="workflow"] [data-board-layer="workflow"] .board-route,
[data-active="models"] [data-board-layer="models"] .board-route,
[data-active="compute"] [data-board-layer="compute"] .board-route {
  stroke: var(--board-signal); stroke-width: 2.6;
}
[data-active="workflow"] [data-board-layer="workflow"] :is(.board-terminal, .board-number),
[data-active="models"] [data-board-layer="models"] :is(.board-terminal, .board-number),
[data-active="compute"] [data-board-layer="compute"] :is(.board-terminal, .board-number) {
  fill: var(--board-signal);
}
.system-caption {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  border-top: 1px solid #354c41;
}
.system-caption p { font-size: .78rem; color: #b8c5bc; padding: 8px 14px; }
.system-select { display: flex; }
.system-select button {
  min-height: 42px;
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  border: 0; border-right: 1px solid #354c41;
  background: transparent; color: #eaece5;
  padding: 0 12px; font-size: .8rem; white-space: nowrap;
}
.system-select button small { font-family: var(--font-mono); font-size: .68rem; opacity: .75; }
.system-select button:hover { background: #1e352a; }
.system-select button[aria-pressed="true"] { color: #b8cca4; background: #264235; }

/* 首页：在线实验与地形寻路 */
.study { background: var(--surface); padding-block: var(--space-section); }
.study-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: start;
  gap: clamp(28px, 5vw, 72px);
}
.study-photo img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border: 1px solid var(--rule);
}
.study-photo figcaption {
  margin-top: 10px;
  font-size: .78rem;
  color: var(--fg-2);
}
.study-copy h2 {
  margin: 10px 0 14px;
  font-size: clamp(1.75rem, 3vw, 2.7rem);
  letter-spacing: -.025em;
}
.study-copy p { color: var(--fg-2); font-size: .95rem; max-width: 34em; }
.lab-tool-list {
  margin: 22px 0;
  border-top: 1px solid var(--rule-strong);
}
.lab-tool-list a {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--rule);
  font-size: .9rem;
}
.lab-tool-list a span:last-child {
  color: var(--fg-2);
  font-size: .8rem;
  text-align: right;
}
.lab-tool-list a:hover strong {
  text-decoration: underline;
  text-underline-offset: .25em;
}

/* 首页：实验室笔记与记录 */
.bench {
  display: grid;
  grid-template-columns: minmax(0, .65fr) minmax(0, 1.35fr);
  gap: clamp(24px, 5vw, 72px);
  padding-block: var(--space-section);
}
.bench-intro p {
  margin-top: 12px;
  color: var(--fg-2);
  font-size: .92rem;
  max-width: 24em;
}
.bench-intro .text-link { margin-top: 16px; }
.log-list { border-top: 1px solid var(--rule-strong); }
.log-item {
  display: grid;
  grid-template-columns: 6.5em minmax(0, 1fr);
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
}
.log-date {
  font-family: var(--font-mono);
  font-size: .78rem;
  color: var(--fg-2);
  padding-top: 3px;
}
.log-body h3 {
  font-size: 1.15rem;
  margin-bottom: 6px;
}
.log-body a:hover h3 {
  text-decoration: underline;
  text-underline-offset: .2em;
}
.log-body p {
  color: var(--fg-2);
  font-size: .88rem;
  line-height: 1.68;
}
.bench-foot {
  margin-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
}

/* ==========================================================================
   产品页与详情页
   ========================================================================== */
.product-hero { padding-block: clamp(48px, 6.5vw, 96px); }
.product-spread, .compute-spread {
  display: grid;
  grid-template-columns: minmax(0, 1.04fr) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 80px);
  align-items: center;
}
.product-copy { display: grid; justify-items: start; }
.product-copy .label { margin-bottom: 12px; }
.product-copy h1 {
  font: 400 clamp(2.8rem, 6.4vw, 5.8rem)/1.02 var(--font-serif);
  letter-spacing: -.035em;
}
.product-lead {
  font-family: var(--font-serif);
  font-size: clamp(1.3rem, 2.4vw, 2.2rem);
  line-height: 1.32;
  letter-spacing: -.02em;
}
.product-copy .product-lead { margin-top: 16px; }
.product-copy > p:not([class]) { color: var(--fg-2); margin-top: 14px; max-width: 30em; }
.product-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; margin-top: 22px; }

.agent-board { padding: 14px; border: 1px solid var(--rule-strong); color: var(--fg-2); }
.agent-board svg { width: 100%; }
.agent-board figcaption, .gateway-board figcaption, .compute-photo figcaption {
  padding-top: 10px; color: var(--fg-2); font-size: .76rem;
}
.agent-board figcaption { border-top: 1px solid var(--rule); }

.gateway-hero { background: var(--paper); }
:root[data-theme="dark"] .gateway-hero { background: #172821; }
.gateway-board { padding: clamp(16px, 2.8vw, 36px); border: 1px solid var(--rule-strong); background: var(--bg); }
.gateway-board-title {
  color: var(--fg-2); display: flex; justify-content: space-between;
  font-size: .78rem; gap: 10px; border-bottom: 1px solid var(--rule); padding-bottom: 10px;
}
.gateway-diagram {
  display: grid; grid-template-columns: auto 1fr auto;
  align-items: center; padding: 20px 0; color: var(--fg);
}
.gateway-diagram > div { display: flex; flex-direction: column; gap: 12px; }
.gateway-diagram strong, .gateway-diagram span {
  font-size: clamp(.82rem, 1.15vw, .98rem);
  font-weight: 550; border: 1px solid var(--rule-strong);
  padding: 8px 12px; text-align: center;
}
.gateway-diagram strong {
  color: var(--bg); background: var(--fg); border-color: var(--fg);
}
.gateway-diagram svg { width: 100%; max-width: none; height: 112px; }
.gateway-board figcaption { border-top: 1px solid var(--rule); }

.compute-spread { grid-template-columns: minmax(0, 1fr) minmax(0, .92fr); }
.compute-photo img { width: 100%; aspect-ratio: 5 / 4; object-fit: cover; border: 1px solid var(--rule); }

.detail-layout {
  display: grid;
  grid-template-columns: minmax(0, .65fr) minmax(0, 1fr);
  gap: clamp(24px, 6vw, 84px);
  align-items: start;
}
.detail-layout > div { min-width: 0; }
.detail-layout p { max-width: 40em; color: var(--fg-2); }
.detail-layout .link-arrow, .detail-note { margin-top: 14px; }

/* 项目简报三栏 */
.brief-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 36px);
  border-top: 1px solid var(--rule-strong);
  padding-top: 24px;
}
.brief-col h3 {
  font-size: 1.2rem;
  margin-bottom: 10px;
}
.brief-col p, .brief-col li {
  color: var(--fg-2);
  font-size: .9rem;
  line-height: 1.72;
}
.brief-col ul {
  display: grid;
  gap: 8px;
}
.brief-col li {
  padding-left: 14px;
  position: relative;
}
.brief-col li::before {
  content: "–";
  position: absolute;
  left: 0;
  color: var(--rule-strong);
}

.facts { border-top: 1px solid var(--rule-strong); }
.facts > div {
  display: grid;
  grid-template-columns: minmax(0, .55fr) minmax(0, 1.45fr);
  align-items: start;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--rule);
}
.facts dt { font-weight: 560; font-size: .88rem; }
.facts dd { color: var(--fg-2); font-size: .88rem; overflow-wrap: anywhere; }
.experiment-heading .label { margin-bottom: 10px; }

/* ==========================================================================
   关于页与工程笔记
   ========================================================================== */
.about-intro h1 {
  font: 400 clamp(2.8rem, 6.5vw, 5.6rem)/1.02 var(--font-serif);
  letter-spacing: -.035em;
}
.about-blurb { align-self: end; display: grid; gap: 14px; }
.about-blurb .product-lead { color: var(--fg); }

.essay-list { border-top: 1px solid var(--rule-strong); }
.essay-item { border-bottom: 1px solid var(--rule); }
.essay-item summary {
  cursor: pointer;
  list-style: none;
  display: grid;
  grid-template-columns: 6em minmax(0, 1fr) auto;
  gap: 14px;
  align-items: baseline;
  padding: 18px 0;
}
.essay-item summary::-webkit-details-marker { display: none; }
.essay-item .essay-date {
  font-family: var(--font-mono);
  font-size: .78rem;
  color: var(--fg-2);
}
.essay-item .essay-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: var(--fg);
}
.essay-item .essay-toggle {
  font-family: var(--font-mono);
  font-size: .9rem;
  color: var(--fg-2);
}
.essay-item[open] .essay-toggle::after { content: "−"; }
.essay-item:not([open]) .essay-toggle::after { content: "+"; }
.essay-body {
  padding: 0 0 24px calc(6em + 14px);
  display: grid;
  gap: 12px;
  max-width: 48em;
}
.essay-body p { color: var(--fg-2); font-size: .92rem; line-height: 1.8; }
.essay-body a { color: var(--fg); text-decoration: underline; text-underline-offset: .3em; }

.resource-links { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 20px; }
.contact-address {
  display: inline-block;
  margin: 12px 0 18px;
  color: var(--fg);
  font-family: var(--font-mono);
  font-size: clamp(1rem, 2vw, 1.5rem);
  text-decoration: underline;
  text-underline-offset: .3em;
  overflow-wrap: anywhere;
}
.not-found { display: grid; gap: 18px; min-height: 56vh; align-content: center; }
.not-found h1 { font-size: clamp(2.2rem, 5vw, 4.5rem); letter-spacing: -.03em; }

/* ==========================================================================
   实验室与交互仪器组件
   ========================================================================== */
.lab-surface { padding-block: clamp(36px, 4.8vw, 72px) clamp(55px, 6.7vw, 104px); }
.lab-intro {
  display: flex; justify-content: space-between; align-items: end;
  gap: 20px; border-bottom: 1px solid var(--rule-strong);
  padding-bottom: clamp(26px, 3.5vw, 46px);
}
.lab-intro h1 { font-size: clamp(2.8rem, 5.5vw, 5.2rem); letter-spacing: -.035em; line-height: 1; }
.lab-intro p { max-width: 34em; margin-top: 14px; color: var(--fg-2); }
.lab-layout {
  display: grid;
  grid-template-columns: minmax(150px, .42fr) minmax(0, 1.82fr);
  gap: clamp(24px, 5vw, 80px);
  align-items: start;
  padding-top: 32px;
}
.lab-nav { position: sticky; top: 24px; display: grid; }
.lab-nav a {
  color: var(--fg-2); font-size: .875rem;
  display: flex; justify-content: space-between; gap: 8px; align-items: center;
  min-height: 44px; border-bottom: 1px solid var(--rule);
}
.lab-nav a:hover, .lab-nav a[aria-current="location"] {
  color: var(--accent); border-color: var(--accent);
}
.lab-exp + .lab-exp {
  margin-top: clamp(48px, 7vw, 96px);
  padding-top: clamp(24px, 3.5vw, 48px);
  border-top: 1px solid var(--rule);
}
.lab-exp-head {
  display: grid;
  grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr);
  gap: 12px 20px;
  align-items: end;
  margin-bottom: 20px;
}
.lab-exp-head h2 { font-size: clamp(1.55rem, 3vw, 2.4rem); letter-spacing: -.025em; }
.lab-exp-head p { color: var(--fg-2); font-size: .9rem; }

.instrument { border: 1px solid var(--rule-strong); background: var(--bg); }
.instrument-bar {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 12px; min-height: 42px; padding: 6px 14px;
  border-bottom: 1px solid var(--rule);
}
.instrument-body { padding: clamp(16px, 2vw, 24px); }
.readouts {
  display: grid;
  grid-template-columns: repeat(var(--cols, 3), minmax(0, 1fr));
  border-top: 1px solid var(--rule);
}
.readouts > div { padding: 12px 14px; border-right: 1px solid var(--rule); }
.readouts > div:last-child { border-right: 0; }
.readouts dt { font-family: var(--font-body); font-size: .74rem; color: var(--fg-2); }
.readouts dd {
  margin-top: 4px;
  font-family: var(--font-mono), var(--font-body);
  font-size: clamp(.82rem, 1.6vw, 1.02rem);
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.range { display: grid; gap: 8px; }
.range-head { display: flex; justify-content: space-between; gap: 12px; }
input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 24px; background: transparent;
}
input[type="range"]::-webkit-slider-runnable-track { height: 1px; background: var(--rule-strong); }
input[type="range"]::-moz-range-track { height: 1px; background: var(--rule-strong); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px;
  margin-top: -7px; background: var(--fg); border: 0;
}
input[type="range"]::-moz-range-thumb { width: 14px; height: 14px; background: var(--fg); border: 0; border-radius: 0; }

.field {
  width: 100%; min-width: 0; padding: 11px 14px;
  background: var(--surface); border: 1px solid var(--rule);
  border-radius: 0; font-family: var(--font-body); font-size: .92rem; line-height: 1.6;
}
.field:focus { outline: none; border-color: var(--fg); }
.field:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
select.field {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 18px) 55%, calc(100% - 13px) 55%;
  background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px;
}

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 36px; padding: 7px 12px;
  border: 1px solid var(--rule); background: transparent;
  font-size: .8125rem; line-height: 1.4; text-align: left;
  transition: border-color 160ms var(--ease), background-color 160ms var(--ease);
}
.chip:hover { border-color: var(--fg); background: var(--surface); }

.code-block {
  position: relative;
  border: 1px solid var(--rule-strong);
  background: var(--ink);
  color: #eaece5;
}
.code-block .instrument-bar { border-color: rgba(234, 236, 229, .14); }
.code-block .instrument-bar .label { color: #a8b5ac; }
.code-block pre {
  margin: 0; padding: 18px 20px 22px; overflow-x: auto;
  font-family: var(--font-mono); font-size: .8125rem; line-height: 1.7; tab-size: 2;
}
.code-block .btn--sm { border-color: rgba(234, 236, 229, .45); color: #eaece5; background: transparent; }
.code-block .btn--sm:hover { background: #eaece5; color: var(--ink); }

/* Agent 审批原型 */
.trace { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.trace-steps { border-right: 1px solid var(--rule); }
.trace-steps li { border-bottom: 1px solid var(--rule); }
.trace-steps ol button {
  width: 100%; display: grid; grid-template-columns: 2.4em 1fr auto;
  gap: 10px; align-items: center; padding: 12px 14px;
  text-align: left; background: transparent; border: 0;
  font-size: .92rem; line-height: 1.4;
}
.trace-steps ol button:disabled { cursor: default; color: var(--fg-2); opacity: .5; }
.trace-steps ol button[aria-current="step"] { background: var(--fg); color: var(--bg); }
.trace-steps .k, .trace-steps .t { font-family: var(--font-mono); font-size: .6875rem; }
.trace-steps .t { opacity: .8; }
.trace-detail { padding: 18px 20px; display: grid; gap: 16px; align-content: start; min-height: 340px; }
.trace-detail h3 { font-size: var(--step-1); font-family: var(--font-body); font-weight: 600; }
.trace-detail pre {
  margin: 0; padding: 14px 16px; background: var(--surface); border: 1px solid var(--rule);
  font-family: var(--font-mono); font-size: .78rem; line-height: 1.65;
  white-space: pre-wrap; word-break: break-word;
}
.trace-detail .flag { border-left: 3px solid var(--accent); padding-left: 12px; font-size: .92rem; }
.trace-controls { display: flex; flex-wrap: wrap; gap: 10px; padding: 14px; border-top: 1px solid var(--rule); }

/* Gateway 并行对比 */
.compare-form { display: grid; gap: 14px; }
.compare-models { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.check { display: inline-flex; align-items: center; gap: 8px; font-size: .875rem; cursor: pointer; }
.check input { width: 16px; height: 16px; accent-color: var(--forest); }
.compare-out { display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); border-top: 1px solid var(--rule); }
.compare-col { border-right: 1px solid var(--rule); min-width: 0; display: flex; flex-direction: column; }
.compare-col:last-child { border-right: 0; }
.compare-col header { padding: 12px 14px; border-bottom: 1px solid var(--rule); }
.compare-col header strong { display: block; font-family: var(--font-mono); font-size: .8rem; font-weight: 500; overflow-wrap: anywhere; }
.compare-col .metrics { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 6px; font-family: var(--font-mono); font-size: .7rem; color: var(--fg-2); font-variant-numeric: tabular-nums; }
.compare-col .out { padding: 14px; font-size: .88rem; line-height: 1.7; white-space: pre-wrap; word-break: break-word; min-height: 180px; max-height: 360px; overflow-y: auto; }

/* Compute 调度模拟 */
.sim-layout { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); }
.sim-canvas-wrap { position: relative; aspect-ratio: 16 / 10; border-right: 1px solid var(--rule); background: var(--ink-2); }
.sim-canvas-wrap canvas { width: 100%; height: 100%; }
.sim-controls { padding: 18px; display: grid; gap: 20px; align-content: start; }

/* Lab：对话、生图、地球、测速、解剖、地形 */
.chat-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--rule); }
.chat-toolbar select.field { width: auto; min-width: 0; max-width: 100%; padding-block: 8px; }
.chat-log { height: clamp(200px, 30vh, 360px); overflow-y: auto; padding: 18px 16px; display: grid; gap: 16px; align-content: start; scroll-behavior: smooth; }
.msg { max-width: 46em; }
.msg-head { font-family: var(--font-mono); font-size: .7rem; color: var(--fg-2); margin-bottom: 4px; }
.msg-body { font-size: .92rem; line-height: 1.75; white-space: pre-wrap; word-break: break-word; }
.msg--user { justify-self: end; text-align: left; padding: 10px 14px; background: var(--surface); border: 1px solid var(--rule); }
.msg--user .msg-head { text-align: right; }
.chat-composer { display: grid; grid-template-columns: 1fr auto; border-top: 1px solid var(--rule); }
.chat-composer .field { border: 0; background: transparent; padding: 14px 16px; }
.chat-composer .btn { min-height: 100%; border-width: 0 0 0 1px; }
.chat-chips { padding: 12px 14px; border-top: 1px solid var(--rule); }

.imagine { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.imagine-controls { padding: 18px; display: grid; gap: 14px; align-content: start; border-right: 1px solid var(--rule); }
.imagine-stage { position: relative; aspect-ratio: 5 / 4; background: var(--surface); display: grid; place-items: center; }
.imagine-stage img { width: 100%; height: 100%; object-fit: contain; }
.imagine-empty { padding: 24px; max-width: 26em; text-align: center; color: var(--fg-2); font-size: .92rem; }
.imagine-stage.is-busy .imagine-empty::after {
  content: ""; display: block; margin: 18px auto 0; width: 120px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--fg), transparent);
  background-size: 50% 100%; background-repeat: no-repeat; animation: scan 1.4s linear infinite;
}
@keyframes scan { from { background-position: -100% 0; } to { background-position: 200% 0; } }
.imagine-meta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-top: 1px solid var(--rule); }

.edge-layout { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.globe-panel { min-width: 0; border-right: 1px solid var(--rule); }
.globe-wrap { position: relative; display: grid; place-items: center; padding: 16px; cursor: grab; touch-action: none; }
.globe-wrap:active { cursor: grabbing; }
.globe-wrap canvas { width: min(100%, 520px); aspect-ratio: 1; }
.globe-controls { display: flex; justify-content: center; gap: 8px; padding: 0 12px 14px; }
.globe-controls button { min-width: 44px; }
.edge-side { display: grid; align-content: start; }
.edge-side .facts { border-top: 0; }
.edge-side .facts > div { padding: 11px 14px; grid-template-columns: minmax(0, .85fr) minmax(0, 1fr); }
.edge-side .facts dd { font-family: var(--font-mono); font-size: .8125rem; word-break: break-word; }

.probe { border-top: 1px solid var(--rule-strong); padding: 16px; display: grid; gap: 14px; }
.probe .readouts { border-bottom: 1px solid var(--rule); }
.probe-bars { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; height: 110px; align-items: end; }
.probe-bar { position: relative; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; gap: 6px; }
.probe-bar i { display: block; height: 4%; background: var(--fg); transition: height 420ms var(--ease); }
.probe-bar span { font-family: var(--font-mono); font-size: .7rem; color: var(--fg-2); text-align: center; font-variant-numeric: tabular-nums; }

.anatomy-bar { display: flex; height: 34px; border: 1px solid var(--rule); margin: 6px 0 4px; background: var(--surface); }
.anatomy-bar span { display: block; height: 100%; min-width: 0; }
.anatomy-bar span:nth-child(1) { background: var(--mist-2); }
.anatomy-bar span:nth-child(2) { background: var(--moss); }
.anatomy-bar span:nth-child(3) { background: var(--forest-3); }
.anatomy-bar span:nth-child(4) { background: var(--signal); }
.anatomy-bar span:nth-child(5) { background: var(--rock); }
.anatomy-legend { display: flex; flex-wrap: wrap; gap: 8px 20px; font-family: var(--font-mono); font-size: .75rem; color: var(--fg-2); }
.anatomy-legend i { display: inline-block; width: 10px; height: 10px; margin-right: 6px; vertical-align: -1px; }
.headers-table { width: 100%; border-collapse: collapse; font-family: var(--font-mono); font-size: .78rem; }
.headers-table th, .headers-table td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--rule); vertical-align: top; word-break: break-all; }
.headers-table th { width: 30%; color: var(--fg-2); font-weight: 500; }

.span-canvas-wrap { position: relative; aspect-ratio: 16 / 10; background: var(--paper); cursor: crosshair; touch-action: manipulation; }
.span-canvas-wrap canvas { width: 100%; height: 100%; }
.span-hint { position: absolute; bottom: 8px; left: 8px; padding: 3px 8px; background: var(--paper); color: var(--ink); pointer-events: none; font-size: .72rem; border: 1px solid var(--rule); }
.terrain-controls { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 18px; padding: 14px; border-top: 1px solid var(--rule); }

/* ==========================================================================
   页脚
   ========================================================================== */
.site-footer {
  padding: clamp(44px, 5vw, 68px) 0 24px;
  border-top: 1px solid var(--rule);
}
.footer-main { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 16px 40px; }
.footer-main p { margin-top: 10px; color: var(--fg-2); font-size: .875rem; }
.footer-main nav { display: flex; gap: 28px; flex-wrap: wrap; font-size: .875rem; }
.footer-main nav a { display: flex; align-items: center; min-height: 44px; }
.footer-base {
  border-top: 1px solid var(--rule); margin-top: 30px; padding-top: 14px;
  display: flex; justify-content: space-between; flex-wrap: wrap;
  gap: 8px 18px; color: var(--fg-2); font-size: .78rem;
}
.footer-main a:hover, .footer-base a:hover { text-decoration: underline; text-underline-offset: .3em; }

/* ==========================================================================
   响应式适配
   ========================================================================== */
@media (max-width: 1020px) {
  .project-grid, .brief-grid { grid-template-columns: 1fr; }
  .project-card { border-right: 0; border-bottom: 1px solid var(--rule-strong); }
  .project-card:last-child { border-bottom: 0; }
  .arch-layout { grid-template-columns: 1fr; }
  .system-caption { grid-template-columns: 1fr; }
  .system-select { border-bottom: 1px solid #354c41; }
  .system-select button { flex: 1; }
  .system-select button:last-child { border-right: 0; }
}

@media (max-width: 860px) {
  .trace, .compare-out, .sim-layout, .imagine, .edge-layout { grid-template-columns: 1fr; }
  .trace-steps, .compare-col, .sim-canvas-wrap, .imagine-controls, .globe-panel {
    border-right: 0; border-bottom: 1px solid var(--rule);
  }
  .trace-detail { min-height: 0; }
  .sim-canvas-wrap { aspect-ratio: 4 / 3; }
}

@media (max-width: 760px) {
  .header-row { display: flex; justify-content: space-between; min-height: 60px; }
  .nav { width: 100%; padding-bottom: 12px; gap: 4px 18px; flex-wrap: wrap; }
  .js-nav .menu-btn { display: block; }
  .js-nav .nav:not(.is-open) { display: none; }
  .js-nav .nav.is-open {
    position: absolute; top: 100%; left: 0; flex-direction: column; align-items: stretch;
    background: var(--bg); padding: 10px var(--gutter) 20px; border-bottom: 1px solid var(--rule-strong);
  }
  .js-nav .nav a { border-bottom: 1px solid var(--rule); }

  .landscape { height: clamp(240px, 68vw, 380px); }
  .landscape h1 { font-size: clamp(54px, 16vw, 104px); left: 4%; top: 6%; }
  .opening-grid, .editorial-heading, .product-spread, .compute-spread,
  .detail-layout, .study-layout, .bench, .lab-layout, .lab-exp-head {
    grid-template-columns: 1fr;
  }
  .opening-meta { border-left: 0; border-top: 1px solid var(--rule); padding-left: 0; padding-top: 16px; }
  .editorial-heading > p { justify-self: start; }
  .lab-intro { flex-direction: column; align-items: flex-start; }
  .lab-nav { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
  .log-item, .essay-item summary { grid-template-columns: 1fr; gap: 6px; }
  .essay-body { padding-left: 0; }
  .essay-item .essay-toggle { display: none; }
}

@media (max-width: 440px) {
  .readouts > div { padding: 9px 8px; }
  .terrain-controls, .resource-links { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}
