/* ============================================================
   NeuroAtlas · pages.css
   首页（Hero / 分类 / 精选网络 / 学习路径 / 概念 / 应用）
   与「建设中」占位页样式
   依赖：css/tokens.css、css/base.css、css/components.css
   ============================================================ */

/* ---------------- 首页 · Hero ---------------- */
.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #ffffff 0%, var(--silver-50) 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(560px 280px at 86% -14%, rgba(37, 99, 235, 0.1), transparent 70%),
    linear-gradient(var(--silver-100) 1px, transparent 1px) 0 0 / 44px 44px,
    linear-gradient(90deg, var(--silver-100) 1px, transparent 1px) 0 0 / 44px 44px;
  opacity: 0.75;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 55%, transparent 96%);
  mask-image: linear-gradient(180deg, #000 0%, #000 55%, transparent 96%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(300px, 372px);
  gap: clamp(30px, 5vw, 60px);
  align-items: center;
  padding: clamp(48px, 7vw, 84px) 0 clamp(42px, 6vw, 72px);
}

.hero h1 {
  max-width: 15em;
  margin-top: 16px;
  font-size: clamp(35px, 4.8vw, 57px);
  line-height: 1.14;
  letter-spacing: -0.02em;
}

.hero h1 .accent {
  color: var(--blue-600);
}

.hero-lede {
  max-width: 42em;
  margin-top: 18px;
  color: var(--text-soft);
  font-size: clamp(14.5px, 1.5vw, 16.5px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

/* Hero 右侧概览面板 */
.hero-panel {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.hero-panel__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.hero-panel__head b {
  font-size: 10.5px;
  color: var(--blue-600);
}

.hero-panel__more {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  color: var(--blue-600);
}

.hero-panel__more:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------------- 卡片网格 ---------------- */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.grid-cards--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.grid-cards--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* ---------------- 分类卡片 ---------------- */
.category-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 16px 14px;
  overflow: hidden;
}

.category-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: var(--cat, var(--blue-500));
}

.category-card__en {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cat, var(--blue-600));
}

.category-card h3 {
  font-size: 16.5px;
}

.category-card p {
  flex: 1;
  color: var(--text-soft);
  font-size: 12.5px;
  line-height: 1.65;
}

.category-card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink-400);
}

.category-card__foot span:last-child {
  color: var(--cat, var(--blue-600));
}

/* ---------------- 网络卡片 ---------------- */
.network-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.network-card__glyph {
  display: grid;
  place-items: center;
  height: 96px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-soft);
}

.network-card__glyph svg {
  width: 100%;
  height: 72px;
  color: var(--cat, var(--blue-700));
}

.network-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  gap: 5px;
  padding: 13px 15px 15px;
}

.network-card__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.network-card h3 {
  font-size: 17.5px;
  line-height: 1.3;
}

.network-card__en {
  margin-top: -2px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--ink-400);
}

.network-card p {
  color: var(--text-soft);
  font-size: 12.5px;
  line-height: 1.6;
}

.network-card__more {
  margin-top: auto;
  padding-top: 8px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--blue-600);
}

/* ---------------- 学习路径 ---------------- */
.path-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.path-step {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
}

.path-step__num {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--blue-600);
}

.path-step h3 {
  font-size: 16px;
}

.path-step p {
  flex: 1;
  color: var(--text-soft);
  font-size: 12.5px;
  line-height: 1.65;
}

.path-step__links {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}

/* ---------------- 概念云 ---------------- */
.concept-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

/* ---------------- 应用卡片 ---------------- */
.app-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.app-card {
  display: flex;
  flex-direction: column;
  gap: 7px;
  padding: 18px;
}

.app-card__index {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--blue-600);
}

.app-card h3 {
  font-size: 17px;
}

.app-card__en {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.app-card p {
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.7;
}

.app-card__example {
  padding: 6px 10px;
  border-left: 2px solid var(--line-strong);
  font-size: 12px;
  line-height: 1.65;
  color: var(--ink-400);
}

.app-card__networks {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: auto;
}

/* ---------------- 建设中占位页 ---------------- */
.page-stub {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  max-width: 680px;
  padding: clamp(46px, 8vw, 90px) 0 clamp(60px, 10vw, 120px);
}

.page-stub h1 {
  font-size: clamp(30px, 4.4vw, 44px);
}

.page-stub > p {
  color: var(--text-soft);
  font-size: 15px;
}

.stub-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

.stub-panel {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  width: 100%;
  max-width: 560px;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--line);
}

.stub-panel > div {
  padding: 12px 14px;
  background: var(--surface);
}

.stub-panel b {
  display: block;
  font-family: var(--font-mono);
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--ink-900);
}

.stub-panel span {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--ink-400);
}

.stub-note {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  color: var(--ink-400);
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 1080px) {
  .grid-cards--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .path-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 960px) {
  .grid-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-inner {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .hero-panel {
    max-width: 520px;
  }
}

@media (max-width: 720px) {
  .grid-cards,
  .grid-cards--2,
  .grid-cards--4,
  .path-grid,
  .app-grid {
    grid-template-columns: 1fr;
  }

  .hero h1 {
    font-size: clamp(30px, 8.6vw, 40px);
  }

  .stub-panel {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   历史沿革：视觉化时间线（动态示意图 / 阅读进度 / 渐入动效）
   ============================================================ */

/* ---------------- 顶部阅读进度 ---------------- */
.read-progress {
  position: fixed;
  top: var(--header-h);
  left: 0;
  right: 0;
  z-index: 45;
  height: 2px;
  pointer-events: none;
}

.read-progress__bar {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left;
  background: linear-gradient(90deg, var(--blue-500), var(--blue-700));
  opacity: 0.9;
}

/* ---------------- 首页 · 时间线预览 ---------------- */
.history-preview {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-top: 10px;
  border-top: 1px solid var(--line-strong);
}

.history-node {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 20px 14px 0;
  border-right: 1px dashed var(--line);
}

.history-node:last-child {
  border-right: 0;
}

.history-node::before {
  content: "";
  position: absolute;
  top: -4px;
  left: 14px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--blue-600);
  box-shadow: 0 0 0 3px var(--blue-50);
}

.history-node__year {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--blue-600);
}

.history-node__title {
  font-size: 13px;
  font-weight: 650;
  line-height: 1.4;
  color: var(--ink-800);
}

.history-node__desc {
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--ink-400);
}

.history-node:hover .history-node__title {
  color: var(--blue-700);
}

/* 首页历史区块的渐入 */
html.has-reveal #history .history-node {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

html.has-reveal #history.is-visible .history-node {
  opacity: 1;
  transform: none;
}

html.has-reveal #history .history-node:nth-child(2) { transition-delay: 0.06s; }
html.has-reveal #history .history-node:nth-child(3) { transition-delay: 0.12s; }
html.has-reveal #history .history-node:nth-child(4) { transition-delay: 0.18s; }
html.has-reveal #history .history-node:nth-child(5) { transition-delay: 0.24s; }
html.has-reveal #history .history-node:nth-child(6) { transition-delay: 0.3s; }

/* ---------------- 历史页 Hero ---------------- */
.history-hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #ffffff 0%, var(--silver-50) 100%);
  padding: clamp(44px, 6.5vw, 78px) 0 clamp(26px, 4vw, 38px);
}

.history-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--silver-100) 1px, transparent 1px),
    linear-gradient(90deg, var(--silver-100) 1px, transparent 1px);
  background-size: 40px 40px;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 92%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 92%);
  opacity: 0.85;
  pointer-events: none;
}

.history-hero__canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.9;
}

.history-symbols {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.history-symbol {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.02em;
  color: var(--blue-600);
  opacity: 0.22;
  white-space: nowrap;
  animation: historyFloat 9s ease-in-out infinite;
}

.history-symbol:nth-child(2) { animation-delay: -2s; }
.history-symbol:nth-child(3) { animation-delay: -4s; }
.history-symbol:nth-child(4) { animation-delay: -6s; }
.history-symbol:nth-child(5) { animation-delay: -3s; }
.history-symbol:nth-child(6) { animation-delay: -5s; }

.history-hero .container {
  position: relative;
  z-index: 2;
}

.history-hero h1 {
  max-width: 14em;
  margin-top: 14px;
  font-size: clamp(31px, 4.4vw, 50px);
  line-height: 1.16;
  letter-spacing: -0.02em;
}

.history-hero .lead {
  max-width: 46em;
  margin-top: 14px;
  color: var(--text-soft);
  font-size: 15.5px;
}

.era-index {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 22px;
}

.era-chip {
  padding: 6px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-pill);
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.02em;
  color: var(--ink-500);
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease, transform 0.15s ease;
}

.era-chip:hover {
  border-color: var(--blue-500);
  background: var(--blue-50);
  color: var(--blue-700);
  transform: translateY(-1px);
}

/* ---------------- 时间线主体 ---------------- */
.history-body {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: clamp(28px, 4.5vw, 56px);
  align-items: start;
  padding: clamp(34px, 5vw, 54px) 0 clamp(60px, 8vw, 96px);
}

.era {
  padding-bottom: clamp(30px, 4.2vw, 48px);
  margin-bottom: clamp(30px, 4.2vw, 48px);
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 88px;
}

.era:last-child {
  border-bottom: 0;
  margin-bottom: 0;
}

.era-head {
  max-width: 56em;
}

.era__range {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--blue-600);
}

.era h2 {
  margin-top: 8px;
  font-size: clamp(22px, 2.6vw, 30px);
}

.era-head p {
  margin-top: 8px;
  color: var(--text-soft);
  font-size: 14px;
}

.era-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 392px);
  gap: clamp(22px, 3.5vw, 44px);
  align-items: start;
  margin-top: 20px;
}

.era--flip .era-grid {
  grid-template-columns: minmax(300px, 392px) minmax(0, 1fr);
}

.era--flip .era-figure {
  order: -1;
}

.era-main {
  min-width: 0;
}

.milestones {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
}

.milestone {
  position: relative;
  display: grid;
  grid-template-columns: 86px minmax(0, 1fr);
  padding-bottom: 18px;
}

.milestone::before {
  content: "";
  position: absolute;
  left: 86px;
  top: 7px;
  bottom: -3px;
  width: 1px;
  background: var(--line);
}

.milestone:last-child::before {
  bottom: auto;
  height: 24px;
}

.milestone__year {
  padding-right: 20px;
  padding-top: 1px;
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  text-align: right;
  color: var(--blue-700);
}

.milestone__body {
  position: relative;
  padding-left: 20px;
}

.milestone__body::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 5px;
  width: 9px;
  height: 9px;
  border: 2px solid var(--blue-600);
  border-radius: 50%;
  background: var(--surface);
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.milestone:hover .milestone__body::before {
  background: var(--blue-600);
  box-shadow: 0 0 0 4px var(--blue-50);
}

.milestone h3 {
  font-size: 15.5px;
  line-height: 1.4;
}

.milestone p {
  margin-top: 4px;
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.7;
}

.milestone .pill-list {
  margin-top: 6px;
}

/* 示意图 */
.era-figure {
  position: sticky;
  top: 88px;
  margin: 0;
}

.era-figure__frame {
  overflow: hidden;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, #ffffff, var(--silver-50));
  box-shadow: var(--shadow-sm);
}

.era-figure svg {
  display: block;
  width: 100%;
  height: auto;
}

.era-figure figcaption {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-400);
  text-align: right;
}

/* 右侧时代索引 */
.history-index {
  position: sticky;
  top: 88px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface-soft);
}

.history-index h2 {
  font-size: 16px;
}

.history-index__note {
  margin-top: 6px;
  font-size: 11.5px;
  line-height: 1.65;
  color: var(--ink-400);
}

.history-index__list {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 1px;
}

.history-index__list a {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 7px 9px;
  border-left: 2px solid var(--line);
  border-radius: 0 6px 6px 0;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.history-index__list a:hover,
.history-index__list a.is-active {
  border-color: var(--blue-600);
  background: var(--blue-50);
}

.history-index__range {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.02em;
  color: var(--blue-600);
}

.history-index__title {
  font-size: 12px;
  line-height: 1.4;
  color: var(--ink-700);
}

/* ---------------- 示意图元素与动画 ---------------- */
.era-figure svg {
  font-family: var(--font-mono);
}

.fig-grid {
  stroke: var(--silver-200);
  stroke-width: 1;
  opacity: 0.6;
}

.fig-hair {
  stroke: var(--silver-300);
  stroke-width: 1;
}

.fig-axis {
  stroke: var(--ink-300);
  stroke-width: 1.2;
}

.fig-node {
  fill: var(--surface);
  stroke: var(--blue-600);
  stroke-width: 1.4;
}

.fig-node--big {
  fill: var(--blue-50);
}

.fig-node--small {
  fill: var(--blue-50);
  stroke-width: 1.1;
}

.fig-label {
  font-size: 10px;
  fill: var(--blue-700);
  text-anchor: middle;
  stroke: none;
}

.fig-label--strong {
  font-size: 15px;
}

.fig-note {
  font-size: 8px;
  fill: var(--ink-400);
  stroke: none;
}

.fig-edge {
  stroke: var(--blue-500);
  stroke-width: 1.2;
  opacity: 0.45;
}

.fig-flow {
  stroke-dasharray: 4 7;
  animation: figDash 1.8s linear infinite;
}

.fig-flow--back {
  stroke: var(--blue-700);
  stroke-width: 1.4;
  stroke-dasharray: 4 8;
  opacity: 0.7;
  animation: figDash 2.2s linear infinite;
  animation-direction: reverse;
}

.fig-box {
  fill: var(--surface);
  stroke: var(--blue-600);
  stroke-width: 1.3;
}

.fig-step {
  stroke: var(--blue-700);
  stroke-width: 1.8;
}

.fig-loss {
  stroke: var(--blue-600);
  stroke-width: 1.6;
  stroke-dasharray: 140;
  stroke-dashoffset: 140;
  animation: figDraw 3.4s ease-in-out infinite;
}

.fig-decision {
  stroke: var(--blue-600);
  stroke-width: 1.4;
  stroke-dasharray: 5 5;
  opacity: 0.8;
  animation: figDash 3s linear infinite;
}

.fig-curve {
  stroke: var(--blue-500);
  stroke-width: 1.6;
  stroke-dasharray: 6 6;
  opacity: 0.75;
  animation: figDash 3.6s linear infinite;
}

.fig-point {
  fill: var(--blue-600);
  stroke: none;
}

.fig-point--open {
  fill: var(--surface);
  stroke: var(--blue-600);
  stroke-width: 1.3;
}

.fig-pulse {
  animation: figPulse 2.4s ease-in-out infinite;
}

.fig-kernel {
  fill: rgba(37, 99, 235, 0.1);
  stroke: var(--blue-600);
  stroke-width: 1.6;
  animation: figSlideX 4.6s ease-in-out infinite;
}

.fig-layer {
  fill: rgba(37, 99, 235, 0.08);
  stroke: var(--blue-600);
  stroke-width: 1.2;
  animation: figPulse 3.2s ease-in-out infinite;
}

.fig-cell {
  fill: rgba(37, 99, 235, 0.18);
  stroke: var(--blue-600);
  stroke-width: 0.9;
  animation: figPulse 2.8s ease-in-out infinite;
}

.fig-cell--heat {
  fill: var(--blue-600);
  stroke: var(--blue-700);
}

.fig-row {
  fill: none;
  stroke: var(--blue-600);
  stroke-width: 1.2;
  stroke-dasharray: 3 3;
  opacity: 0.85;
}

/* ---------------- 时间线渐入 ---------------- */
html.has-reveal .era {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s cubic-bezier(0.2, 0.7, 0.2, 1), transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}

html.has-reveal .era.is-visible {
  opacity: 1;
  transform: none;
}

html.has-reveal .era:not(.is-visible) .era-figure svg * {
  animation-play-state: paused;
}

/* ---------------- 关键帧 ---------------- */
@keyframes figDash {
  to {
    stroke-dashoffset: -44;
  }
}

@keyframes figDraw {
  0% {
    stroke-dashoffset: 140;
  }
  60% {
    stroke-dashoffset: 0;
  }
  100% {
    stroke-dashoffset: 0;
  }
}

@keyframes figPulse {
  0%,
  100% {
    opacity: 0.3;
  }
  50% {
    opacity: 1;
  }
}

@keyframes figSlideX {
  0%,
  100% {
    transform: translateX(0);
  }
  50% {
    transform: translateX(42px);
  }
}

@keyframes historyFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-9px);
  }
}

/* ---------------- 响应式 ---------------- */
@media (max-width: 1180px) {
  .history-body {
    grid-template-columns: 1fr;
  }

  .history-index {
    display: none;
  }
}

@media (max-width: 1024px) {
  .era-figure {
    position: static;
  }
}

@media (max-width: 900px) {
  .era-grid,
  .era--flip .era-grid {
    grid-template-columns: 1fr;
  }

  .era-figure {
    order: -1;
  }
}

@media (max-width: 960px) {
  .history-preview {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: 24px;
  }

  .history-node:nth-child(3n) {
    border-right: 0;
  }
}

@media (max-width: 640px) {
  .history-preview {
    grid-template-columns: 1fr;
    border-top: 0;
  }

  .history-node {
    padding: 12px 0 12px 18px;
    border-right: 0;
    border-bottom: 1px dashed var(--line);
  }

  .history-node::before {
    top: 18px;
    left: 0;
  }

  .history-symbols {
    display: none;
  }
}

@media (max-width: 600px) {
  .milestone {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .milestone::before {
    display: none;
  }

  .milestone__year {
    text-align: left;
    padding: 0;
  }

  .milestone__body {
    padding-left: 16px;
  }

  .milestone__body::before {
    left: -1px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html.has-reveal .era {
    opacity: 1;
    transform: none;
  }

  .era-figure svg *,
  .history-symbol,
  .read-progress__bar {
    animation: none !important;
  }

  .history-hero__canvas {
    display: none;
  }
}

/* ---------------- 文献 / 开源项目链接 ---------------- */
.era-refs {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
}

.era-refs__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.01em;
}

.era-refs__label {
  display: block;
  margin-bottom: 6px;
  color: var(--ink-400);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.era-refs__link {
  color: var(--ink-500);
  border-bottom: 1px dotted var(--line-strong);
  transition: color 0.15s ease, border-color 0.15s ease;
}

.era-refs__link:hover {
  color: var(--blue-600);
  border-color: var(--blue-400);
}

.era-refs__arrow {
  display: inline-block;
  margin-left: 3px;
  font-size: 8.5px;
  opacity: 0.6;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.era-refs__link:hover .era-refs__arrow {
  opacity: 1;
  transform: translate(1px, -1px);
}

.era-refs__toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 9.5px;
  color: var(--ink-400);
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease;
}

.era-refs__toggle:hover {
  border-color: var(--blue-400);
  background: var(--blue-50);
  color: var(--blue-600);
}

.era-refs__count {
  color: var(--blue-600);
}

.era-refs__chevron {
  width: 10px;
  height: 10px;
  transition: transform 0.2s ease;
}

.era-refs.is-open .era-refs__chevron {
  transform: rotate(180deg);
}

.era-refs__more {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.3s ease;
}

.era-refs.is-open .era-refs__more {
  grid-template-rows: 1fr;
}

.era-refs__more-inner {
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  padding-top: 8px;
  font-family: var(--font-mono);
  font-size: 10.5px;
}

@media (prefers-reduced-motion: reduce) {
  .era-refs__more {
    transition: none;
  }

  .era-refs__chevron,
  .era-refs__arrow {
    transition: none;
  }
}

/* ============================================================
   首页动态视觉（Hero Canvas / 损失地形 / 搜索建议 / 渐入 / 光晕）
   ============================================================ */

.hero { isolation: isolate; }

.hero-canvas {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero-inner { z-index: 2; }

/* 搜索实时建议 */
.search { position: relative; }

.search-suggest {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  z-index: 60;
  max-height: 330px;
  padding: 6px;
  overflow: auto;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}

.search-suggest[hidden] { display: none; }

.search-suggest__group {
  padding: 8px 9px 4px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-300);
}

.search-suggest__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 9px;
  border-radius: var(--radius-md);
  color: var(--text);
  text-decoration: none;
}

.search-suggest__item:hover,
.search-suggest__item.is-active { background: var(--blue-50); }

.search-suggest__name {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
  font-size: 13.5px;
  font-weight: 600;
}

.search-suggest__en {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--ink-400);
}

.search-suggest__meta {
  margin-left: auto;
  padding: 2px 7px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--ink-400);
}

.search-suggest mark {
  padding: 0 1px;
  border-radius: 3px;
  background: var(--blue-100);
  color: var(--blue-700);
}

.search-suggest__empty {
  padding: 12px 10px;
  font-size: 12.5px;
  color: var(--ink-400);
}

/* 损失地形 */
.loss-section {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.loss-head { max-width: 48em; margin-bottom: 22px; }

.loss-head p:not(.kicker) {
  max-width: 46em;
  margin-top: 12px;
  color: var(--text-soft);
  font-size: 14.5px;
}

.loss-stage {
  position: relative;
  height: clamp(280px, 33vw, 420px);
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(700px 240px at 50% 120%, rgba(37, 99, 235, 0.06), transparent 70%),
    linear-gradient(180deg, #ffffff 0%, var(--silver-50) 100%);
  box-shadow: var(--shadow-md);
}

.loss-stage canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.loss-caption {
  margin-top: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.03em;
  color: var(--ink-400);
}

/* 滚动渐入 */
html.has-reveal .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity 0.62s cubic-bezier(0.2, 0.7, 0.2, 1),
    transform 0.62s cubic-bezier(0.2, 0.7, 0.2, 1);
}

html.has-reveal .reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* 卡片指针跟随光晕 */
.card--glow { position: relative; }

.card--glow::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    240px circle at var(--mx, 50%) var(--my, 50%),
    rgba(37, 99, 235, 0.09),
    transparent 62%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.card--glow:hover::after { opacity: 1; }

/* 数字等宽，滚动时不抖动 */
.stats-grid .stat b { font-variant-numeric: tabular-nums; }

@media (max-width: 720px) {
  .loss-stage { height: 270px; }
  .loss-head p:not(.kicker) { font-size: 13.5px; }
  .hero-canvas { opacity: 0.85; }
}

@media (prefers-reduced-motion: reduce) {
  html.has-reveal .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .card--glow::after { display: none; }
}

/* 搜索建议 · 名称与英文名分行 */
.search-suggest__label { display: block; }

/* 下拉展开时允许溢出 hero，避免被 overflow:hidden 裁剪 */
.hero:has(#home-search-suggest:not([hidden])) { overflow: visible; }
/* ---------- 动态视觉：更平滑的过渡 ---------- */
.card,
.nav-dropdown__item,
.section-more,
.hero-panel__more {
  transition-timing-function: cubic-bezier(0.22, 1, 0.36, 1);
}

.search-suggest { animation: suggestIn 0.18s ease-out; }

@keyframes suggestIn {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .search-suggest { animation: none; }
}

/* ============================================================
   网络图鉴 · 3D 卡片甲板
   ============================================================ */
.atlas-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(46px, 7vw, 88px) 0 clamp(18px, 3vw, 30px);
}

.atlas-hero::before {
  content: "";
  position: absolute;
  inset: -10% -10% 0;
  background:
    radial-gradient(52% 46% at 76% 14%, rgba(37, 99, 235, 0.07), transparent 70%),
    radial-gradient(40% 40% at 8% 64%, rgba(29, 78, 216, 0.05), transparent 72%);
  pointer-events: none;
}

.atlas-hero .container { position: relative; }

.atlas-hero h1 {
  margin: 18px 0 16px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.12;
  letter-spacing: -0.01em;
  max-width: 900px;
}

.atlas-hero__accent {
  color: var(--blue-600);
  background: linear-gradient(180deg, transparent 62%, rgba(37, 99, 235, 0.12) 62%);
}

.atlas-hero .lead {
  max-width: 720px;
  font-size: clamp(14px, 1.4vw, 16px);
  line-height: 1.85;
  color: var(--text-soft);
}

.atlas-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
  margin-top: 22px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-400);
}

.atlas-hero__meta b {
  font-size: 15px;
  color: var(--ink-900);
  font-variant-numeric: tabular-nums;
}

.atlas-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 26px;
}

.atlas-filters .chip { display: inline-flex; align-items: center; gap: 6px; }

.chip__num {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--ink-400);
}

.chip.is-active .chip__num { color: var(--blue-600); }

.atlas-deck-section { padding: clamp(12px, 2vw, 24px) 0 clamp(36px, 6vw, 72px); }

.atlas-deck {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(294px, 348px);
  gap: clamp(22px, 3.6vw, 54px);
  align-items: start;
}

.deck { position: relative; min-width: 0; }

.deck-stage {
  position: relative;
  height: clamp(440px, 47vw, 512px);
  perspective: 1500px;
  perspective-origin: 50% 42%;
  touch-action: pan-y;
  cursor: grab;
  outline-offset: 6px;
}

.deck-stage:active { cursor: grabbing; }

.deck-stage__inner {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  transition: transform 0.55s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.deck-card {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 302px;
  height: 412px;
  margin: 0;
  padding: 20px 22px 18px;
  display: flex;
  flex-direction: column;
  border-radius: 22px;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, #ffffff 0%, #f8fafd 56%, #eef2f8 100%);
  box-shadow: 0 30px 64px -34px rgba(10, 21, 38, 0.3);
  transform-style: preserve-3d;
  backface-visibility: hidden;
  overflow: hidden;
  will-change: transform, opacity;
  transition:
    transform 0.68s cubic-bezier(0.22, 0.61, 0.36, 1),
    opacity 0.5s ease,
    box-shadow 0.5s ease,
    border-color 0.5s ease;
  cursor: pointer;
  outline: none;
}

.deck-card:focus-visible {
  box-shadow: 0 0 0 3px var(--blue-100), 0 30px 64px -34px rgba(10, 21, 38, 0.3);
}

.deck-card__grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(10, 21, 38, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(10, 21, 38, 0.035) 1px, transparent 1px);
  background-size: 26px 26px;
  opacity: 0.75;
  -webkit-mask-image: radial-gradient(85% 72% at 50% 26%, #000 18%, transparent 88%);
  mask-image: radial-gradient(85% 72% at 50% 26%, #000 18%, transparent 88%);
}

.deck-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(120% 70% at 50% -10%, rgba(37, 99, 235, 0.1), transparent 62%);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.deck-card.is-active {
  border-color: var(--cat, var(--blue-500));
  box-shadow:
    0 46px 90px -38px rgba(29, 78, 216, 0.4),
    0 2px 0 rgba(255, 255, 255, 0.9) inset;
  cursor: default;
}

.deck-card.is-active::after { opacity: 1; }

.deck-card__top {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--ink-400);
}

.deck-card__num { color: var(--cat, var(--ink-500)); }

.deck-card__glyph {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 8px 0 6px;
  color: var(--cat, var(--blue-600));
  opacity: 0.95;
}

.deck-card__glyph svg {
  width: 100%;
  height: auto;
  max-height: 154px;
  overflow: visible;
}

.deck-card__glyph svg path {
  stroke-dasharray: 260;
  stroke-dashoffset: 0;
  transition: opacity 0.5s ease;
}

.deck-card.is-active .deck-card__glyph svg path {
  animation: deckTrace 2.8s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

.deck-card__glyph svg circle {
  transform-box: fill-box;
  transform-origin: center;
  animation: deckNode 3.6s ease-in-out infinite;
}

.deck-card.is-active .deck-card__glyph svg circle {
  animation-duration: 1.9s;
}

@keyframes deckTrace {
  0% { stroke-dashoffset: 260; opacity: 0.2; }
  45% { opacity: 0.95; }
  100% { stroke-dashoffset: 0; opacity: 0.6; }
}

@keyframes deckNode {
  0%, 100% { opacity: 0.5; transform: scale(0.88); }
  50% { opacity: 1; transform: scale(1.14); }
}

.deck-card__body {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.deck-card__cat {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.deck-card h2 {
  margin: 0;
  font-size: 23px;
  line-height: 1.2;
  color: var(--ink-900);
}

.deck-card__en {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.deck-card__tagline {
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--ink-500);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.deck-card__foot {
  position: relative;
  z-index: 2;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.deck-card__formula {
  font-family: var(--font-mono);
  font-size: 9.5px;
  line-height: 1.45;
  color: var(--ink-400);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.deck-card__more {
  align-self: flex-end;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--blue-600);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.deck-card.is-active .deck-card__more { opacity: 1; transform: none; }

.deck-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  padding-left: 4px;
}

.deck-arrow {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--ink-700);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.deck-arrow:hover:not(:disabled) {
  border-color: var(--blue-500);
  color: var(--blue-600);
  transform: translateY(-1px);
}

.deck-arrow:disabled { opacity: 0.4; cursor: not-allowed; }

.deck-counter {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-400);
  min-width: 76px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.deck-play {
  margin-left: auto;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 11.5px;
  color: var(--ink-500);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.deck-play:hover { border-color: var(--blue-500); color: var(--blue-600); }

.deck-play[aria-pressed="false"] { color: var(--ink-400); }

.deck-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
  padding-left: 4px;
}

.deck-dot {
  width: 7px;
  height: 7px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: var(--silver-300);
  cursor: pointer;
  transition: width 0.3s cubic-bezier(0.22, 1, 0.36, 1), background 0.3s ease;
}

.deck-dot.is-active {
  width: 22px;
  background: var(--blue-600);
}

.deck-hint {
  margin: 12px 0 0;
  padding-left: 4px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--ink-400);
}

.deck-info {
  position: sticky;
  top: calc(var(--header-h) + 26px);
  min-height: 396px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 24px 24px 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: linear-gradient(170deg, #ffffff 0%, #f8fafd 60%, #eef2f8 100%);
  box-shadow: 0 30px 60px -44px rgba(10, 21, 38, 0.35);
  overflow: hidden;
}

.deck-info::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(10, 21, 38, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(10, 21, 38, 0.03) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.8;
  pointer-events: none;
  -webkit-mask-image: radial-gradient(90% 70% at 30% 0%, #000 12%, transparent 82%);
  mask-image: radial-gradient(90% 70% at 30% 0%, #000 12%, transparent 82%);
}

.deck-info > * { position: relative; z-index: 1; }

.deck-info.is-swapping { animation: deckInfoIn 0.24s ease-out; }

@keyframes deckInfoIn {
  from { opacity: 0.5; transform: translateY(4px); }
  to { opacity: 1; transform: none; }
}

.deck-info__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.deck-info__num {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--ink-400);
}

.deck-info__title {
  margin: 4px 0 0;
  font-size: clamp(24px, 2.6vw, 30px);
  line-height: 1.15;
  color: var(--ink-900);
}

.deck-info__en {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.deck-info__desc {
  margin: 2px 0 0;
  font-size: 13px;
  line-height: 1.75;
  color: var(--text-soft);
}

.deck-info__formula {
  margin-top: 4px;
  padding: 10px 12px;
  border: 1px solid var(--blue-100);
  border-radius: 10px;
  background: var(--blue-50);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.5;
  color: var(--blue-700);
  overflow-wrap: anywhere;
}

.deck-info__chips {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 2px;
}

.deck-info__label {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.deck-info__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.deck-info__count {
  font-family: var(--font-mono);
  font-size: 10.5px;
  color: var(--ink-400);
  font-variant-numeric: tabular-nums;
}

.atlas-footnote {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: clamp(56px, 8vw, 96px);
}

.atlas-footnote p {
  max-width: 660px;
  margin: 0;
  font-size: 13px;
  line-height: 1.8;
  color: var(--ink-400);
}

@media (max-width: 1020px) {
  .atlas-deck { grid-template-columns: minmax(0, 1fr); }
  .deck-info { position: static; min-height: 0; }
}

@media (max-width: 640px) {
  .atlas-hero h1 { font-size: clamp(30px, 9vw, 40px); }
  .deck-stage { height: 440px; perspective: 1200px; }
  .deck-card { width: min(78vw, 296px); height: 402px; padding: 18px 18px 16px; }
  .deck-card h2 { font-size: 21px; }
  .deck-controls { flex-wrap: wrap; }
  .deck-play { margin-left: 0; }
  .deck-info { padding: 20px 18px; }
  .atlas-footnote { flex-direction: column; align-items: flex-start; }
}

@media (prefers-reduced-motion: reduce) {
  .deck-stage__inner { transition: none; }
  .deck-card { transition: none; }
  .deck-card.is-active .deck-card__glyph svg path { animation: none; }
  .deck-card__glyph svg circle { animation: none; }
}

/* ============================================================
   网络详情页
   ============================================================ */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 24px 0 0;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  color: var(--ink-400);
}

.breadcrumb a { color: var(--ink-500); }
.breadcrumb a:hover { color: var(--blue-600); }

.detail-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(250px, 0.7fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  padding: 34px 0 32px;
  border-bottom: 1px solid var(--line);
}

.detail-hero__meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.detail-hero h1 {
  margin: 0 0 4px;
  font-size: clamp(34px, 5vw, 56px);
  line-height: 1.06;
  letter-spacing: -0.01em;
}

.detail-hero__en {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.detail-hero__lede {
  max-width: 640px;
  margin: 16px 0 0;
  font-size: clamp(14.5px, 1.5vw, 16.5px);
  line-height: 1.8;
  color: var(--text-soft);
}

.detail-hero__facts {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 30px;
  margin: 22px 0 0;
}

.fact dt {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.fact dd {
  margin: 2px 0 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink-900);
}

.detail-glyph {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 250px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(86% 80% at 50% 18%, rgba(37, 99, 235, 0.09), transparent 70%),
    linear-gradient(165deg, #ffffff 0%, #f7f9fd 70%, #eef2f8 100%);
  overflow: hidden;
}

.detail-glyph::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(10, 21, 38, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(10, 21, 38, 0.04) 1px, transparent 1px);
  background-size: 24px 24px;
  -webkit-mask-image: radial-gradient(80% 74% at 50% 40%, #000 20%, transparent 88%);
  mask-image: radial-gradient(80% 74% at 50% 40%, #000 20%, transparent 88%);
}

.detail-glyph svg {
  position: relative;
  width: 100%;
  max-width: 360px;
  height: auto;
  color: var(--blue-600);
}

.detail-glyph svg path { stroke-dasharray: 320; animation: detailTrace 3.2s cubic-bezier(0.4, 0, 0.2, 1) infinite; }
.detail-glyph svg circle { transform-box: fill-box; transform-origin: center; animation: deckNode 3.2s ease-in-out infinite; }

@keyframes detailTrace {
  0% { stroke-dashoffset: 320; opacity: 0.18; }
  50% { opacity: 0.85; }
  100% { stroke-dashoffset: 0; opacity: 0.55; }
}

.detail-formula {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  margin-top: 20px;
  padding: 12px 14px;
  border: 1px solid var(--blue-100);
  border-radius: 12px;
  background: var(--blue-50);
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  color: var(--blue-700);
  overflow-wrap: anywhere;
}

.detail-note {
  margin-top: 18px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface-soft);
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--ink-400);
}

.detail-layout {
  display: grid;
  grid-template-columns: 190px minmax(0, 780px);
  gap: clamp(22px, 4vw, 56px);
  justify-content: space-between;
  padding: 38px 0 60px;
}

.toc {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.toc__title {
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.toc a {
  padding: 6px 10px;
  border-left: 2px solid var(--line);
  font-size: 12.5px;
  color: var(--ink-500);
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.toc a:hover { color: var(--blue-600); }

.toc a.is-active {
  border-color: var(--blue-600);
  background: var(--blue-50);
  color: var(--blue-700);
}

.detail-body section {
  padding-bottom: 26px;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--line);
  scroll-margin-top: 92px;
}

.detail-body section:last-child { border-bottom: 0; margin-bottom: 0; }

.detail-body h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 14px;
  font-size: clamp(20px, 2.4vw, 26px);
  line-height: 1.3;
}

.detail-body h2::before {
  content: "";
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--blue-600);
  flex: none;
}

.detail-body p,
.detail-body li {
  font-size: 15px;
  line-height: 1.85;
  color: var(--text-soft);
}

.detail-body p { margin: 0; }

.detail-body ol {
  margin: 0;
  padding-left: 20px;
  display: grid;
  gap: 8px;
}

.pill-list { display: flex; flex-wrap: wrap; gap: 6px; }

.pros-cons {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.panel {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface-soft);
}

.panel--pros { border-color: var(--blue-100); background: var(--blue-50); }

.panel__title {
  margin-bottom: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-500);
}

.panel ul {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-soft);
}

.ref-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ref-list a {
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--blue-700);
  text-decoration: underline;
  text-decoration-color: var(--blue-100);
  text-underline-offset: 4px;
}

.ref-list a:hover { text-decoration-color: var(--blue-600); }

.pager {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  padding: 0 0 80px;
}

.pager a {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.pager a:hover { border-color: var(--blue-500); transform: translateY(-2px); }

.pager span:first-child {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
  color: var(--ink-400);
}

.pager span:last-child {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink-900);
}

.pager .next { text-align: right; }

/* -------- 详情页交互插图 -------- */
.detail-visual {
  padding: 36px 0 6px;
}

.visual-head { max-width: 760px; }

.visual-head .kicker { margin-bottom: 10px; }

.visual-head h2 {
  margin: 0 0 10px;
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.25;
}

.visual-head p {
  margin: 0;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text-soft);
}

.visual-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(250px, 0.85fr);
  gap: 16px;
  margin-top: 20px;
}

.attn-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 168px;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(160deg, #ffffff 0%, #f8fafd 60%, #eef2f8 100%);
  box-shadow: var(--shadow-md);
}

.attn-canvas-wrap {
  position: relative;
  height: clamp(340px, 38vw, 470px);
  min-width: 0;
}

.attn-canvas-wrap canvas {
  display: block;
  width: 100%;
  height: 100%;
}

.attn-tip {
  position: absolute;
  z-index: 3;
  padding: 5px 8px;
  border-radius: 6px;
  background: var(--ink-900);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  pointer-events: none;
  transform: translate(-50%, -135%);
  box-shadow: 0 6px 16px -6px rgba(10, 21, 38, 0.45);
}

.attn-controls {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.ctl-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.ctl-label b {
  font-size: 11px;
  color: var(--blue-700);
  font-variant-numeric: tabular-nums;
}

.attn-heads { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }

.attn-head {
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  font-size: 11px;
  color: var(--ink-500);
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.attn-head.is-active {
  border-color: var(--blue-500);
  background: var(--blue-50);
  color: var(--blue-700);
}

.attn-temp {
  width: 100%;
  margin-top: 8px;
  accent-color: var(--blue-600);
}

.attn-hint {
  margin: 0;
  font-size: 11.5px;
  line-height: 1.65;
  color: var(--ink-400);
}

.attn-legend {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--ink-400);
}

.attn-legend i {
  flex: 1;
  height: 6px;
  border-radius: 3px;
  background: linear-gradient(90deg, #eef2f7, #93b4f5, #1d4ed8);
}

.pe-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.pe-card .kicker { margin: 0; }

.pe-card h3 { margin: 2px 0 0; font-size: 18px; }

.pe-card p { margin: 0; font-size: 12.5px; line-height: 1.7; color: var(--ink-500); }

.pe-canvas {
  display: block;
  width: 100%;
  height: auto;
  margin-top: 2px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--silver-50);
}

.pe-card__formula {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.5;
  color: var(--ink-400);
  overflow-wrap: anywhere;
}

.flow-figure {
  margin: 4px 0 20px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(160deg, #ffffff 0%, #f8fafd 100%);
}

.flow-figure svg { display: block; width: 100%; height: auto; }

.flow-node {
  fill: #ffffff;
  stroke: var(--line-strong);
  stroke-width: 1.2;
}

.flow-node.is-key { fill: var(--blue-50); stroke: var(--blue-100); }

.flow-label {
  font-family: var(--font-body);
  font-size: 10px;
  fill: var(--ink-700);
}

.flow-sub {
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.06em;
  fill: var(--ink-400);
}

.flow-link {
  stroke: var(--line-strong);
  stroke-width: 1.3;
  stroke-dasharray: 5 5;
  animation: flowDash 1.8s linear infinite;
}

.flow-dot { fill: var(--blue-600); }

@keyframes flowDash {
  to { stroke-dashoffset: -20; }
}

@media (max-width: 940px) {
  .detail-hero { grid-template-columns: minmax(0, 1fr); }
  .detail-glyph { min-height: 210px; }
  .detail-layout { grid-template-columns: minmax(0, 1fr); }
  .toc { display: none; }
  .visual-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 720px) {
  .attn-card { grid-template-columns: minmax(0, 1fr); }
  .attn-canvas-wrap { height: 330px; }
  .attn-controls { flex-direction: row; flex-wrap: wrap; align-items: flex-end; }
  .attn-controls > * { flex: 1 1 150px; }
  .attn-legend { flex: 1 1 100%; }
  .pros-cons { grid-template-columns: minmax(0, 1fr); }
  .pager { grid-template-columns: minmax(0, 1fr); }
  .detail-body p, .detail-body li { font-size: 14.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .detail-glyph svg path, .detail-glyph svg circle, .flow-link { animation: none; }
}

/* ============================================================
   模型运用指南 · Model Guide
   ============================================================ */
.guide-backbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0 6px;
}

.guide-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  color: var(--ink-500);
  cursor: pointer;
  transition: color 0.22s ease, border-color 0.22s ease, background 0.22s ease, transform 0.22s ease;
}

.guide-back:hover {
  color: var(--blue-700);
  border-color: var(--blue-100);
  background: var(--blue-50);
  transform: translateX(-2px);
}

.guide-back__arrow { transition: transform 0.22s ease; }
.guide-back:hover .guide-back__arrow { transform: translateX(-3px); }

.guide-breadcrumb { padding: 0; }

.guide-hero { padding: clamp(26px, 4.4vw, 54px) 0 8px; }

.guide-hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(250px, 400px);
  gap: clamp(22px, 4vw, 56px);
  align-items: center;
}

.guide-hero h1 {
  margin: 14px 0 0;
  font-size: clamp(32px, 4.8vw, 58px);
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.guide-hero__accent {
  display: inline-block;
  margin-left: clamp(8px, 1.2vw, 18px);
  font-size: 0.42em;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--ink-400);
  vertical-align: 0.26em;
  white-space: nowrap;
}

.guide-hero__lede {
  max-width: 680px;
  margin: 18px 0 0;
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.75;
  color: var(--ink-700);
}

.guide-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin-top: 22px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.03em;
  color: var(--ink-400);
}

.guide-meta__item b {
  margin-right: 6px;
  font-weight: 600;
  color: var(--blue-600);
}

.guide-hero__detail {
  display: inline-block;
  margin-top: 24px;
  padding-bottom: 3px;
  border-bottom: 1px dotted var(--line-strong);
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-500);
  text-decoration: none;
  transition: color 0.22s ease, border-color 0.22s ease;
}

.guide-hero__detail:hover { color: var(--blue-700); border-color: var(--blue-600); }

.guide-hero__aside {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 220px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background:
    radial-gradient(80% 80% at 50% 18%, rgba(37, 99, 235, 0.08), transparent 70%),
    linear-gradient(165deg, #ffffff 0%, #f7f9fd 70%, #eef2f8 100%);
  overflow: hidden;
}

.guide-hero__aside::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, rgba(10, 21, 38, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(10, 21, 38, 0.04) 1px, transparent 1px);
  background-size: 24px 24px;
  -webkit-mask-image: radial-gradient(80% 74% at 50% 40%, #000 20%, transparent 88%);
  mask-image: radial-gradient(80% 74% at 50% 40%, #000 20%, transparent 88%);
}

.guide-hero__svg {
  position: relative;
  z-index: 1;
  width: 100%;
  max-height: 190px;
  height: auto;
  color: var(--blue-600);
  animation: guideGlyphFloat 7s ease-in-out infinite;
}

@keyframes guideGlyphFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* 管线 */
.guide-pipeline { margin-top: clamp(30px, 4vw, 54px); }

.guide-pipeline__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 16px;
}

.guide-pipeline__head h2 {
  margin: 8px 0 6px;
  font-size: clamp(22px, 2.6vw, 30px);
  line-height: 1.25;
}

.guide-pipeline__head p {
  max-width: 660px;
  margin: 0;
  font-size: 14px;
  line-height: 1.75;
  color: var(--ink-500);
}

.guide-pipeline__hint {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.04em;
  color: var(--ink-400);
  white-space: nowrap;
}

.guide-pipeline__card {
  position: relative;
  padding: 12px 16px 12px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.guide-pipeline__card::before {
  content: "";
  position: absolute;
  inset: -20% 0 auto;
  height: 220px;
  background: radial-gradient(50% 80% at 50% 0%, rgba(37, 99, 235, 0.07), transparent 72%);
  pointer-events: none;
}

.guide-pipeline__card canvas {
  position: relative;
  display: block;
  width: 100%;
  height: 200px;
  cursor: pointer;
}

.guide-run {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 4px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
}

.guide-run__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 1px solid var(--blue-100);
  border-radius: var(--radius-pill);
  background: var(--blue-50);
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.04em;
  color: var(--blue-700);
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.guide-run__btn:hover:not(:disabled) { background: var(--blue-100); transform: translateY(-1px); }
.guide-run__btn:disabled { opacity: 0.6; cursor: default; }

.guide-run__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--blue-600);
  animation: guidePulse 1.5s ease-in-out infinite;
}

.guide-run__btn.is-running .guide-run__dot { animation-duration: 0.7s; }

@keyframes guidePulse {
  0%, 100% { opacity: 0.45; transform: scale(0.8); }
  50% { opacity: 1; transform: scale(1.2); }
}

.guide-run__log {
  flex: 1;
  min-width: 0;
  max-height: 66px;
  overflow: auto;
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.85;
  color: var(--ink-400);
}

.guide-run__line { white-space: pre-wrap; }
.guide-run__line.is-done { color: var(--blue-700); font-weight: 600; }

/* 步骤与侧栏 */
.guide-main {
  display: grid;
  grid-template-columns: minmax(0, 320px) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 56px);
  align-items: start;
  margin-top: clamp(36px, 5vw, 62px);
}

.guide-steps {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  display: grid;
  gap: 9px;
}

.guide-step {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 16px;
  gap: 10px;
  align-items: center;
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  text-align: left;
  cursor: pointer;
  transition: transform 0.28s cubic-bezier(0.22, 0.61, 0.36, 1), border-color 0.28s ease, background 0.28s ease, box-shadow 0.28s ease;
}

.guide-step:hover { transform: translateX(4px); border-color: var(--line-strong); }

.guide-step.is-active {
  border-color: var(--blue-600);
  background: linear-gradient(150deg, #ffffff 0%, var(--blue-50) 100%);
  box-shadow: 0 14px 30px -20px rgba(37, 99, 235, 0.5);
}

.guide-step__num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-400);
  font-variant-numeric: tabular-nums;
}

.guide-step.is-active .guide-step__num { color: var(--blue-600); font-weight: 600; }

.guide-step__body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }

.guide-step__en {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.guide-step.is-active .guide-step__en { color: var(--blue-600); }

.guide-step__title { font-size: 13.5px; font-weight: 600; color: var(--ink-900); }

.guide-step__io {
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--ink-400);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.guide-step__arrow {
  color: var(--ink-300);
  font-size: 13px;
  transition: transform 0.28s ease, color 0.28s ease;
}

.guide-step:hover .guide-step__arrow { transform: translateX(3px); color: var(--blue-600); }

.guide-side {
  position: sticky;
  top: calc(var(--header-h) + 24px);
  padding: clamp(20px, 2.4vw, 28px);
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.guide-side__kicker {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue-600);
}

.guide-side h3 { margin: 8px 0 10px; font-size: clamp(21px, 2.4vw, 27px); line-height: 1.3; }

.guide-side__desc { margin: 0; font-size: 14.5px; line-height: 1.8; color: var(--text-soft); }

.guide-side__io {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-top: 16px;
  padding: 12px 14px;
  border: 1px dashed var(--line-strong);
  border-radius: 12px;
  background: var(--silver-50);
}

.guide-side__io span {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-400);
}

.guide-side__io code { font-family: var(--font-mono); font-size: 11.5px; line-height: 1.6; color: var(--blue-700); }

.guide-sample { margin-top: 20px; }

.guide-sample__title {
  margin: 0 0 8px;
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  color: var(--ink-400);
}

.guide-table-wrap {
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 10px;
}

.guide-table {
  width: 100%;
  min-width: 340px;
  border-collapse: collapse;
  font-size: 11px;
}

.guide-table th {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  background: var(--silver-50);
  font-family: var(--font-mono);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-align: left;
  color: var(--ink-400);
  white-space: nowrap;
}

.guide-table td {
  padding: 8px 10px;
  border-top: 1px solid var(--line);
  color: var(--ink-700);
  white-space: nowrap;
}

.guide-table tbody tr:first-child td { border-top: 0; }

/* 代码 */
.guide-code { margin-top: clamp(46px, 6vw, 76px); }

.guide-code__head { max-width: 720px; }

.guide-code__head h2 { margin: 8px 0 8px; font-size: clamp(22px, 2.6vw, 30px); }

.guide-code__head p { margin: 0; font-size: 14px; line-height: 1.75; color: var(--ink-500); }

.guide-code__card {
  margin-top: 18px;
  border-radius: 18px;
  overflow: hidden;
  background: #0b1526;
  box-shadow: 0 34px 70px -40px rgba(10, 21, 38, 0.55);
}

.guide-code__bar {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
}

.guide-code__lang {
  flex: none;
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #93b4f5;
}

.guide-code__source {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 10px;
  white-space: nowrap;
  text-overflow: ellipsis;
  color: #8fa3c7;
}

.guide-code__source a { color: #a9c0ea; text-decoration: underline dotted; }
.guide-code__source a:hover { color: #ffffff; }

.guide-code__copy {
  flex: none;
  padding: 5px 12px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-pill);
  background: transparent;
  font-family: var(--font-mono);
  font-size: 10px;
  color: #dbe6ff;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.guide-code__copy:hover { background: rgba(255, 255, 255, 0.08); border-color: rgba(255, 255, 255, 0.3); }

.guide-code__pre {
  margin: 0;
  padding: 18px 18px 22px;
  max-height: 520px;
  overflow: auto;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.8;
  color: #dbe6ff;
  tab-size: 2;
}

.guide-code__pre code { font-family: inherit; white-space: pre; }

/* 开源案例 */
.guide-cases { margin-top: clamp(46px, 6vw, 76px); padding-bottom: clamp(60px, 8vw, 100px); }

.guide-cases__head { max-width: 720px; }

.guide-cases__head h2 { margin: 8px 0 8px; font-size: clamp(22px, 2.6vw, 30px); }

.guide-cases__head p { margin: 0; font-size: 14px; line-height: 1.75; color: var(--ink-500); }

.guide-case-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.guide-case {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  text-decoration: none;
  transition: transform 0.32s cubic-bezier(0.22, 0.61, 0.36, 1), border-color 0.32s ease, box-shadow 0.32s ease;
}

.guide-case:hover {
  transform: translateY(-4px);
  border-color: var(--blue-100);
  box-shadow: 0 22px 46px -26px rgba(37, 99, 235, 0.32);
}

.guide-case__tag {
  font-family: var(--font-mono);
  font-size: 8.5px;
  letter-spacing: 0.16em;
  color: var(--blue-600);
}

.guide-case__title {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.4;
  color: var(--ink-900);
}

.guide-case__out {
  flex: none;
  color: var(--ink-300);
  transition: transform 0.32s ease, color 0.32s ease;
}

.guide-case:hover .guide-case__out { transform: translate(3px, -3px); color: var(--blue-600); }

.guide-case__desc { font-size: 13px; line-height: 1.7; color: var(--ink-500); }

.guide-missing { padding: 80px 0 120px; }
.guide-missing h1 { font-size: clamp(28px, 4vw, 40px); }

/* 详情页入口：不显眼的小图标 */
.detail-guide {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 2px;
  padding: 4px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  background: var(--surface);
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.05em;
  color: var(--ink-400);
  text-decoration: none;
  transition: color 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.detail-guide svg { width: 12px; height: 12px; }

.detail-guide:hover {
  color: var(--blue-700);
  border-color: var(--blue-100);
  background: var(--blue-50);
}

.detail-hero__meta { flex-wrap: wrap; }

@media (max-width: 1080px) {
  .guide-hero__grid { grid-template-columns: minmax(0, 1fr) minmax(220px, 300px); }
  .guide-main { grid-template-columns: minmax(0, 1fr); }
  .guide-steps, .guide-side { position: static; }
  .guide-steps {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 780px) {
  .guide-backbar { flex-direction: column; align-items: flex-start; gap: 10px; }
  .guide-hero__grid { grid-template-columns: minmax(0, 1fr); }
  .guide-hero__aside { min-height: 160px; order: -1; }
  .guide-hero__svg { max-height: 140px; }
  .guide-pipeline__head { flex-direction: column; align-items: flex-start; }
  .guide-pipeline__hint { white-space: normal; }
  .guide-pipeline__card canvas { height: 172px; }
  .guide-run { flex-direction: column; align-items: flex-start; gap: 10px; }
  .guide-run__log { max-height: 88px; width: 100%; }
  .guide-case-grid { grid-template-columns: minmax(0, 1fr); }
  .guide-code__pre { font-size: 11.5px; }
  .guide-code__source { display: none; }
}

@media (max-width: 560px) {
  .guide-steps { grid-template-columns: minmax(0, 1fr); }
  .guide-hero h1 { font-size: clamp(30px, 9vw, 40px); }
  .guide-hero__accent { display: block; margin: 6px 0 0; font-size: 0.5em; }
  .guide-side { padding: 18px; }
  .guide-table { font-size: 10.5px; }
}

@media (prefers-reduced-motion: reduce) {
  .guide-step, .guide-case, .guide-back, .guide-run__btn { transition: none; }
  .guide-run__dot { animation: none; }
  .guide-hero__svg { animation: none; }
}
