/* Luban project page — dark theme, no external deps */

:root {
  --bg: #0a0e1a;
  --bg-soft: #0e1526;
  --panel: #111827;
  --panel-2: #0f172a;
  --text: #e5e7eb;
  --muted: #94a3b8;
  --dim: #94a3b8;
  --line: rgba(148, 163, 184, .16);
  --cyan: #22d3ee;
  --purple: #a78bfa;
  --orange: #fb923c;
  --green: #4ade80;
  --pink: #f472b6;
  --amber: #fbbf24;
  --blue: #60a5fa;
  --red: #f87171;
  --radius: 14px;
  --maxw: min(1720px, 94vw);
  --header-height: 110px;
}

* { box-sizing: border-box; }
html { scroll-behavior: auto; }

body {
  margin: 0;
  background:
    radial-gradient(1100px 500px at 75% -5%, rgba(167,139,250,.10), transparent 60%),
    radial-gradient(900px 420px at 10% 0%, rgba(34,211,238,.08), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }

/* ---------- draft banner ---------- */
.draft-banner {
  position: sticky; top: 0; z-index: 60;
  background: linear-gradient(90deg, rgba(248,113,113,.16), rgba(251,146,60,.14));
  border-bottom: 1px solid rgba(248,113,113,.35);
  color: #fecaca;
  text-align: center; font-size: 12.5px; padding: 6px 12px;
  backdrop-filter: blur(8px);
}

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 31px; z-index: 50;
  background: rgba(10,14,26,.82);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 10px 24px;
  display: flex; align-items: center; gap: 20px;
}
.brand {
  font-weight: 800; font-size: 16px; color: var(--text); text-decoration: none;
  letter-spacing: .2px; white-space: nowrap;
}
.brand-dot {
  display: inline-block; width: 9px; height: 9px; border-radius: 50%;
  background: var(--cyan); margin-right: 8px;
  box-shadow: 0 0 10px var(--cyan);
}
.nav-links { margin-left: auto; display: flex; flex-wrap: wrap; gap: 2px; }
.nav-links a {
  color: var(--muted); text-decoration: none; font-size: 13px;
  padding: 5px 10px; border-radius: 8px; transition: color .15s, background .15s;
}
.nav-links a:hover { color: var(--text); background: rgba(148,163,184,.1); }
.nav-links a.active { color: var(--cyan); background: rgba(34,211,238,.08); }

/* language toggle */
.lang-toggle {
  margin-left: 4px; display: inline-flex; align-items: center; gap: 5px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 999px;
  padding: 4px 12px; cursor: pointer; font-size: 12.5px; line-height: 1.2;
  color: var(--muted); white-space: nowrap;
  transition: border-color .15s;
}
.lang-toggle:hover { border-color: rgba(34,211,238,.45); }
.lt-sep { color: var(--dim); }
.lt-opt { color: var(--muted); padding: 1px 4px; border-radius: 6px; transition: color .15s, background .15s; }
.lt-opt.active { color: var(--cyan); background: rgba(34,211,238,.1); font-weight: 700; }

/* evaluation direction cards */
.dir-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 14px; margin: 22px 0 12px;
}
.dir-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px;
}
.dir-card.c-green { border-color: rgba(74,222,128,.35); }
.dir-card.c-cyan  { border-color: rgba(34,211,238,.35); }
.dir-card.c-purple{ border-color: rgba(167,139,250,.35); }
.dir-card.c-pink  { border-color: rgba(244,114,182,.35); }
.dir-card.c-amber { border-color: rgba(251,191,36,.35); }
.dir-card.c-blue  { border-color: rgba(96,165,250,.35); }
.dir-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.dir-head h4 { margin: 0; font-size: 16px; }
.dir-card p { margin: 0; font-size: 15px; color: var(--muted); }

/* ---------- hero ---------- */
.hero { padding: 72px 0 40px; text-align: center; }
.venue-badge {
  display: inline-block; font-size: 12.5px; letter-spacing: .4px;
  color: var(--amber); border: 1px solid rgba(251,191,36,.4);
  background: rgba(251,191,36,.07);
  padding: 4px 14px; border-radius: 999px; margin-bottom: 22px;
}
.hero h1 {
  font-size: clamp(40px, 7vw, 64px); margin: 0 0 8px; letter-spacing: .5px;
  background: linear-gradient(92deg, #f8fafc 30%, var(--cyan) 70%, var(--purple));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.subtitle { font-size: clamp(17px, 2.6vw, 22px); color: var(--muted); margin: 0 0 26px; }
.authors { font-size: 15.5px; margin: 4px 0; }
.author-note { color: var(--dim); font-size: 14px; margin-left: 8px; }
.affiliations { color: var(--muted); font-size: 14.5px; margin: 2px 0 26px; }

.link-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 34px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 20px; border-radius: 10px; text-decoration: none;
  font-size: 14.5px; color: var(--text);
  background: var(--panel); border: 1px solid var(--line);
  transition: transform .12s, border-color .15s, background .15s;
}
.btn:hover { transform: translateY(-1px); border-color: rgba(148,163,184,.4); }
.btn-primary { border-color: rgba(34,211,238,.5); background: rgba(34,211,238,.09); }
.btn .soon {
  font-size: 10.5px; color: var(--dim); border: 1px solid var(--line);
  padding: 1px 7px; border-radius: 999px;
}

.stats-row {
  display: flex; justify-content: center; gap: 14px; flex-wrap: nowrap;
}
/* 主视觉区的特点卡：整卡可点击，跳转到对应板块 */
.feature {
  --fc: var(--cyan);
  flex: 1 1 0; min-width: 0; padding: 16px 18px; text-align: left; text-decoration: none;
  display: flex; flex-direction: column; gap: 6px;
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.feature b { font-size: 16px; color: var(--text); display: flex; align-items: center; gap: 8px; }
.feature b::before { content: ''; width: 9px; height: 9px; border-radius: 3px; background: var(--fc); flex: none; }
.feature b::after { content: '→'; margin-left: auto; color: var(--muted); font-weight: 400; transition: transform .2s, color .2s; }
.feature-desc { font-size: 14.5px; color: var(--muted); line-height: 1.5; display: block; overflow-wrap: anywhere; }
.feature:hover, .feature:focus-visible { border-color: var(--fc); box-shadow: 0 10px 26px color-mix(in srgb, var(--fc) 16%, transparent); transform: translateY(-3px); }
.feature:hover b::after, .feature:focus-visible b::after { transform: translateX(3px); color: var(--fc); }
.feature:focus-visible { outline: 2px solid var(--fc); outline-offset: 2px; }
.f-purple { --fc: var(--purple); }
.f-blue { --fc: var(--blue); }
@media (max-width: 640px) {
  .stats-row { flex-wrap: wrap; }
  .feature { flex: 1 1 100%; }
}

/* ---------- sections ---------- */
.section { padding: 56px 0 8px; }
h2 {
  font-size: 26px; margin: 0 0 16px; letter-spacing: .2px;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.section-heading {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-bottom: 16px;
}
.section-heading h2 { margin: 0; }
.collapse-toggle {
  display: inline-flex; align-items: center; gap: 7px; flex: 0 0 auto;
  border: 1px solid var(--line); border-radius: 999px;
  background: rgba(148,163,184,.06); color: var(--muted);
  padding: 5px 11px; font: inherit; font-size: 12px; line-height: 1.35;
  cursor: pointer; transition: color .15s, border-color .15s, background .15s;
}
.collapse-toggle:hover { color: var(--text); border-color: rgba(34,211,238,.5); background: rgba(34,211,238,.08); }
.collapse-icon { display: inline-block; font-size: 15px; line-height: 1; transform: translateY(-1px); transition: transform .18s ease; }
.collapse-toggle[aria-expanded="false"] .collapse-icon { transform: rotate(-90deg) translateX(1px); }
.section-content[hidden] { display: none; }
.section.is-collapsed .section-heading { margin-bottom: 0; }
h2::before {
  content: ""; width: 5px; height: 24px; border-radius: 3px;
  background: linear-gradient(var(--cyan), var(--purple)); display: inline-block;
}
h3 { font-size: 18px; margin: 28px 0 10px; }
.lede { font-size: 17px; color: #cbd5e1; }
p { color: #cbd5e1; }
em { color: var(--text); font-style: italic; }
b { color: #f1f5f9; }
code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: .88em; background: rgba(148,163,184,.12); padding: 1px 6px; border-radius: 6px;
  color: #bae6fd;
}

/* ---------- loop strip ---------- */
.loop-strip {
  display: flex; align-items: stretch; justify-content: center; flex-wrap: wrap;
  gap: 8px; margin: 30px 0 8px;
}
.loop-node {
  flex: 1 1 150px; max-width: 230px; padding: 12px 14px; border-radius: 12px; text-align: center;
  background: var(--panel); border: 1px solid var(--line);
}
.loop-node b { display: block; font-size: 15px; margin-bottom: 3px; }
.loop-node span { font-size: 13.5px; color: var(--muted); display: block; line-height: 1.4; }
.loop-arrow { align-self: center; color: var(--dim); font-size: 20px; }
.loop-return { color: var(--green); }
.c-cyan  { border-color: rgba(34,211,238,.5)!important;  box-shadow: 0 0 18px rgba(34,211,238,.06); }
.c-cyan b { color: var(--cyan); }
.c-purple{ border-color: rgba(167,139,250,.5)!important; box-shadow: 0 0 18px rgba(167,139,250,.06); }
.c-purple b { color: var(--purple); }
.c-orange{ border-color: rgba(251,146,60,.5)!important;  box-shadow: 0 0 18px rgba(251,146,60,.06); }
.c-orange b { color: var(--orange); }
.c-green { border-color: rgba(74,222,128,.5)!important;  box-shadow: 0 0 18px rgba(74,222,128,.06); }
.c-green b { color: var(--green); }
.c-pink  { border-color: rgba(244,114,182,.5)!important; box-shadow: 0 0 18px rgba(244,114,182,.06); }
.c-pink b { color: var(--pink); }
.c-blue  { border-color: rgba(96,165,250,.5)!important;  box-shadow: 0 0 18px rgba(96,165,250,.06); }
.c-blue b { color: var(--blue); }
.c-amber { border-color: rgba(251,191,36,.5)!important;  box-shadow: 0 0 18px rgba(251,191,36,.06); }
.c-amber b { color: var(--amber); }

/* ---------- teaser & figures ---------- */
.teaser { margin: 34px 0 10px; }
.teaser video, .teaser.small video { width: 100%; border-radius: var(--radius); border: 1px solid var(--line); background: #000; }
.teaser.small { max-width: 620px; margin-left: auto; margin-right: auto; }
figcaption {
  margin-top: 10px; font-size: 14.5px; color: var(--muted); line-height: 1.6;
}
.fig-wide { margin: 26px 0 10px; }
.fig-wide svg { width: 100%; height: auto; display: block; background: rgba(15,23,42,.35); border: 1px solid var(--line); border-radius: var(--radius); }
.fig-wide img { width: 100%; height: auto; display: block; background: rgba(15,23,42,.35); border: 1px solid var(--line); border-radius: var(--radius); }

/* placeholder for figures still being drawn */
.fig-placeholder {
  min-height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 8px; border: 1.5px dashed rgba(148,163,184,.35); border-radius: var(--radius);
  background: repeating-linear-gradient(135deg, rgba(148,163,184,.03) 0 14px, transparent 14px 28px);
  padding: 40px 24px; text-align: center;
}
.fp-icon { font-size: 30px; opacity: .8; }
.fp-main { margin: 0; font-size: 16px; font-weight: 600; color: #cbd5e1; }
.fp-sub { margin: 0; font-size: 14px; color: var(--dim); }

/* ---------- cards ---------- */
.card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px 24px; margin: 22px 0;
}
.abstract-card h3 { margin-top: 0; display: flex; align-items: center; gap: 10px; }
.abstract-card p { margin: 0; font-size: 15px; }
.note-card { font-size: 14px; color: var(--muted); }
.note-card b { display: block; margin-bottom: 6px; color: var(--text); font-size: 14.5px; }

.tag {
  font-size: 11px; padding: 2px 10px; border-radius: 999px; font-weight: 600; letter-spacing: .3px;
}
.tag-draft { color: var(--amber); border: 1px solid rgba(251,191,36,.4); background: rgba(251,191,36,.08); }
.tag-wip { color: var(--cyan); border: 1px solid rgba(34,211,238,.4); background: rgba(34,211,238,.08); }

/* ---------- skills grid (expandable category cards) ---------- */
.skills-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 16px; margin: 26px 0;
}
.skill-card {
  background: var(--panel); border-radius: var(--radius); padding: 18px 20px;
  border: 1px solid var(--line); align-self: start;
}
.skills-toolbar { display: flex; align-items: center; gap: 10px; margin: 18px 0 4px; flex-wrap: wrap; }
.btn-small { padding: 6px 14px; font-size: 13px; }
.skills-hint { font-size: 14px; color: var(--dim); }
.skill-card.c-cyan { border-color: rgba(34,211,238,.35); }
.skill-card.c-blue { border-color: rgba(96,165,250,.35); }
.skill-card.c-amber { border-color: rgba(251,191,36,.35); }
.skill-card.c-orange { border-color: rgba(251,146,60,.35); }
.skill-card.c-green { border-color: rgba(74,222,128,.35); }
.skill-card.c-purple { border-color: rgba(167,139,250,.35); }
.skill-card.c-pink { border-color: rgba(244,114,182,.35); }
.skill-card.c-cyan .skill-count { color: var(--cyan); }
.skill-card.c-blue .skill-count { color: var(--blue); }
.skill-card.c-amber .skill-count { color: var(--amber); }
.skill-card.c-orange .skill-count { color: var(--orange); }
.skill-card.c-green .skill-count { color: var(--green); }
.skill-card.c-purple .skill-count { color: var(--purple); }
.skill-card.c-pink .skill-count { color: var(--pink); }
.skill-head {
  display: flex; align-items: baseline; gap: 12px; width: 100%;
  background: none; border: 0; color: inherit; font: inherit; cursor: pointer;
  padding: 0; text-align: left;
}
.skill-count {
  font-size: 22px; font-weight: 800; min-width: 40px; text-align: center; flex: 0 0 auto;
  padding: 2px 8px; border-radius: 10px; background: rgba(148,163,184,.08);
}
.skill-title { font-size: 16.5px; font-weight: 700; color: var(--text); }
.skill-n { margin-left: auto; font-size: 12px; color: var(--dim); white-space: nowrap; }
.skill-chev { color: var(--dim); font-size: 15px; transition: transform .18s ease; }
.skill-card.open .skill-chev { transform: rotate(180deg); color: var(--cyan); }
.skill-card:hover { border-color: rgba(34,211,238,.45); }
.skill-list { display: none; margin-top: 12px; }
.skill-card.open .skill-list { display: block; }
.sk-item {
  display: grid; gap: 3px; padding: 10px 12px; margin-top: 8px;
  border: 1px solid var(--line); border-radius: 10px; background: rgba(148,163,184,.05);
  transition: border-color .15s;
}
.sk-item:hover { border-color: rgba(34,211,238,.5); }
.sk-item code { justify-self: start; font-size: 12px; color: var(--cyan); }
.sk-item b { font-size: 14.5px; }
.sk-item span { font-size: 14.5px; color: var(--muted); line-height: 1.55; }

/* ---------- results ---------- */
.headline-strip {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px; margin: 24px 0;
}
.headline-card {
  min-width: 0;
  padding: 16px 18px; border-radius: var(--radius); background: var(--panel);
  border: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px;
}
.hl-label { font-size: 12px; letter-spacing: .5px; text-transform: uppercase; color: var(--muted); white-space: normal; overflow-wrap: anywhere; }
.hl-nums { font-size: clamp(17px, 1.9vw, 23px); font-weight: 800; color: var(--text); white-space: normal; overflow-wrap: anywhere; }
.hl-nums b { font-size: clamp(19px, 2.2vw, 26px); }
.hl-delta { font-size: 15px; font-weight: 700; color: var(--green); white-space: normal; overflow-wrap: anywhere; }
@media (max-width: 900px) { .headline-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px) { .headline-strip { grid-template-columns: 1fr; } }
.headline-card.c-cyan .hl-nums b { color: var(--cyan); }
.headline-card.c-pink .hl-nums b { color: var(--pink); }
.headline-card.c-green .hl-nums b { color: var(--green); }

.cfg-note { color: var(--dim); font-size: 14px; }
.delta-pos { color: var(--green)!important; }
.delta-neg { color: var(--red)!important; }
.row-base td { color: var(--muted); }
.row-ours td {
  background: rgba(74,222,128,.06);
  border-top: 1px solid rgba(74,222,128,.25);
  border-bottom: 1px solid rgba(74,222,128,.25);
}
.row-ours:first-child td { border-top-color: rgba(74,222,128,.25); }

.ablate-groups {
  display: grid; grid-template-columns: 1fr 1fr; gap: 26px; margin: 14px 0 8px;
}
.ablate-group { display: flex; flex-direction: column; gap: 10px; }
.ag-title { font-size: 14px; font-weight: 700; letter-spacing: .4px; text-transform: uppercase; }
.ag-title.c-cyan { color: var(--cyan); }
.ag-title.c-pink { color: var(--pink); }
.tb-fill-hot { background: linear-gradient(90deg, var(--green), var(--cyan)); }
@media (max-width: 760px) { .ablate-groups { grid-template-columns: 1fr; } }

.table-wrap { overflow-x: auto; margin: 22px 0 10px; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 720px; }
thead th {
  text-align: left; padding: 12px 16px; color: var(--muted); font-size: 12.5px;
  letter-spacing: .4px; text-transform: uppercase; border-bottom: 1px solid var(--line);
  background: rgba(15,23,42,.6);
}
tbody td { padding: 12px 16px; border-bottom: 1px solid rgba(148,163,184,.08); color: #cbd5e1; }
tbody tr:last-child td { border-bottom: none; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.row-ref td { color: var(--muted); background: rgba(148,163,184,.04); }
.ext { color: var(--dim); }

.pill {
  display: inline-block; font-size: 11.5px; padding: 2px 10px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted); white-space: nowrap;
}
.pill-live { color: var(--green); border-color: rgba(74,222,128,.4); background: rgba(74,222,128,.08); }
.pill-hold { color: var(--amber); border-color: rgba(251,191,36,.4); background: rgba(251,191,36,.08); }
.pill-early { color: var(--cyan); border-color: rgba(34,211,238,.4); background: rgba(34,211,238,.08); }
.pill-done { color: var(--dim); }

.table-note { font-size: 14.5px; color: var(--dim); }

.task-bars { margin: 14px 0 6px; display: flex; flex-direction: column; gap: 10px; }
.task-bar { display: grid; grid-template-columns: 190px 1fr 70px; align-items: center; gap: 14px; }
.tb-label { font-size: 15px; color: #cbd5e1; text-align: right; }
.tb-track { height: 14px; border-radius: 7px; background: rgba(148,163,184,.12); overflow: hidden; }
.tb-fill {
  height: 100%; border-radius: 7px;
  background: linear-gradient(90deg, var(--cyan), var(--purple));
}
.tb-val { font-size: 14.5px; color: var(--muted); font-variant-numeric: tabular-nums; }

/* ---------- gallery ---------- */
.gallery-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 18px; margin: 26px 0 10px;
}
.tile {
  margin: 0; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
  transition: border-color .15s, transform .12s;
}
.tile:hover { border-color: rgba(34,211,238,.45); transform: translateY(-2px); }
.tile video { width: 100%; display: block; aspect-ratio: 768/340; object-fit: contain; background: #000; }
.tile figcaption {
  padding: 10px 14px; margin: 0; display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 14.5px; color: var(--muted);
}
.chip {
  font-size: 11px; padding: 1px 9px; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted);
}
.chip-seen { color: var(--cyan); border-color: rgba(34,211,238,.4); }
.chip-unseen { color: var(--pink); border-color: rgba(244,114,182,.4); }
.chip-rec { color: var(--green); border-color: rgba(74,222,128,.4); }

/* ---------- recovery ---------- */
.ladder { display: flex; flex-direction: column; gap: 10px; margin: 22px 0; }
.rung {
  display: flex; gap: 16px; align-items: flex-start;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 13px 18px; font-size: 14px; color: var(--text);
}
.rung-num {
  flex: 0 0 30px; height: 30px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 14px; color: var(--green);
  border: 1px solid rgba(74,222,128,.45); background: rgba(74,222,128,.08);
}
.rung:nth-child(2) .rung-num { color: var(--cyan); border-color: rgba(34,211,238,.45); background: rgba(34,211,238,.08); }
.rung:nth-child(3) .rung-num { color: var(--amber); border-color: rgba(251,191,36,.45); background: rgba(251,191,36,.08); }
.rung:nth-child(4) .rung-num { color: var(--orange); border-color: rgba(251,146,60,.45); background: rgba(251,146,60,.08); }
.rung:nth-child(5) .rung-num { color: var(--purple); border-color: rgba(167,139,250,.45); background: rgba(167,139,250,.08); }

.pair-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 18px 0; }
.pair-grid figure { margin: 0; }
.pair-video { width: 100%; border-radius: 12px; background: #000; display: block; }
.pair-video.ok { border: 1px solid rgba(74,222,128,.5); }
.pair-video.fail { border: 1px solid rgba(248,113,113,.5); }
.mark { font-weight: 700; font-size: 15px; margin-right: 6px; }
.mark-ok { color: var(--green); }
.mark-fail { color: var(--red); }
@media (max-width: 700px) { .pair-grid { grid-template-columns: 1fr; } }

/* ---------- citation ---------- */
pre {
  background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 22px; overflow-x: auto; font-size: 13px; line-height: 1.7;
}
pre code { background: none; padding: 0; color: #bae6fd; }

/* ---------- footer ---------- */
.footer {
  margin-top: 70px; border-top: 1px solid var(--line);
  padding: 28px 0 40px; text-align: center; font-size: 14.5px; color: var(--muted);
}
.footer-dim { color: var(--dim); font-size: 14px; }

/* ---------- reveal ---------- */
.section { opacity: 1; }
@media (prefers-reduced-motion: reduce) {
  .section { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- development tracks ---------- */
.track-grid {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 22px 0 12px;
}
.track-card {
  display: block; text-decoration: none; color: inherit; background: var(--panel);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 17px 19px;
  transition: transform .12s, border-color .15s, background .15s;
}
.track-card:hover { transform: translateY(-2px); border-color: rgba(34,211,238,.55); background: rgba(17,24,39,.9); }
.track-card h3 { margin: 8px 0 6px; font-size: 17px; color: var(--text); }
.track-card p { margin: 0; font-size: 15px; color: var(--muted); }
.track-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.track-sha { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 11px; color: var(--dim); }
.track-status { display: inline-block; font-size: 10.5px; letter-spacing: .25px; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.status-master { color: var(--cyan); border-color: rgba(34,211,238,.42); background: rgba(34,211,238,.08); }
.status-branch { color: var(--purple); border-color: rgba(167,139,250,.42); background: rgba(167,139,250,.08); }
.status-merged { color: var(--green); border-color: rgba(74,222,128,.42); background: rgba(74,222,128,.08); }
.status-ready { color: var(--amber); border-color: rgba(251,191,36,.42); background: rgba(251,191,36,.08); }
.track-core { border-left: 3px solid var(--cyan); }
.track-memory { border-left: 3px solid var(--purple); }
.track-robot { border-left: 3px solid var(--orange); }
.track-task { border-left: 3px solid var(--pink); }
.track-chem { border-left: 3px solid var(--amber); }
.track-bench { border-left: 3px solid var(--green); }
.track-spatial { border-left: 3px solid var(--blue); }
.track-nav { border-left: 3px solid var(--cyan); }

@media (max-width: 760px) {
  .track-grid { grid-template-columns: 1fr; }
}

/* ---------- benchmark and embodiment cards ---------- */
.bench-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 14px; margin: 22px 0 10px;
}
.bench-card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px;
}
.bench-card.c-cyan { border-left: 3px solid var(--cyan); }
.bench-card.c-green { border-left: 3px solid var(--green); }
.bench-card.c-purple { border-left: 3px solid var(--purple); }
.bench-card.c-orange { border-left: 3px solid var(--orange); }
.bench-card.c-amber { border-left: 3px solid var(--amber); }
.bench-card.c-pink { border-left: 3px solid var(--pink); }
.bench-card.c-blue { border-left: 3px solid var(--blue); }
.bench-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bench-head h3 { margin: 0; font-size: 17px; }
.bench-card p { margin: 8px 0 0; font-size: 15px; line-height: 1.7; color: var(--muted); }

/* ---------- evidence explorer / accessible architecture ---------- */
[hidden] { display: none !important; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }
section[id], main[id], article[id] { scroll-margin-top: var(--header-height); }
.skip-link { position: fixed; top: -100px; left: 16px; z-index: 100; background: var(--panel); color: var(--cyan); padding: 12px; }
.skip-link:focus { top: 10px; }
.evolution-hero { padding-bottom: 12px; }
.evolution-hero h1 { font-size: clamp(32px, 5.6vw, 54px); line-height: 1.25; }
.evolution-intro { max-width: none; margin: 0 auto 26px; color: var(--muted); }
.section-heading, .media-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.mode-selector { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 24px 0 16px; }
.mode-button { text-align: left; display: flex; flex-direction: column; gap: 9px; min-height: 100px; font: inherit; font-size: 14px; color: var(--muted); border: 1px solid var(--line); border-radius: 12px; background: var(--panel); padding: 15px; cursor: pointer; }
.mode-button:hover { border-color: var(--purple); }
.mode-button[aria-pressed="true"] { border-color: var(--cyan); color: var(--text); background: linear-gradient(140deg, rgba(34,211,238,.12), rgba(167,139,250,.06)); box-shadow: inset 0 2px var(--cyan); }
.mode-index, .eyebrow { font: 11px/1.5 ui-monospace, monospace; letter-spacing: .8px; color: var(--cyan); }
.mode-panel { display: grid; grid-template-columns: 1.65fr 1fr; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--panel); }
.mode-copy { padding: 26px; }
.mode-copy h3 { margin-top: 14px; font-size: 24px; line-height: 1.35; }
.mode-copy p { font-size: 14px; }
.mode-steps { padding-left: 22px; color: var(--text); font-size: 14px; }
.mode-steps li { padding: 5px 0 5px 6px; }
.mode-steps li::marker { color: var(--cyan); font-variant-numeric: tabular-nums; }
.mode-contract { padding: 26px; border-left: 1px solid var(--line); background: rgba(10,14,26,.5); }
.mode-contract h4 { margin: 0 0 22px; font-size: 14px; }
.mode-contract dt { color: var(--purple); font-size: 13.5px; margin-top: 18px; }
.mode-contract dd { margin: 5px 0 0; color: var(--muted); font-size: 14px; }
.boundary-note { padding: 12px 15px; border-left: 2px solid var(--amber); background: rgba(251,191,36,.04); color: #d4c9ad; font-size: 14.5px; }
.media-heading { margin-top: 18px; }
.media-card { padding: 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); min-width: 0; }
.media-card h4 { margin: 0 0 12px; font-size: 14px; }
.video-slot { position: relative; display: grid; place-items: center; aspect-ratio: 16/9; background: radial-gradient(ellipse at center, rgba(34,211,238,.06), transparent), var(--bg); border: 1px dashed rgba(148,163,184,.28); border-radius: 10px; overflow: hidden; }
.video-slot video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.media-placeholder { padding: 20px; color: var(--muted); text-align: center; font-size: 14px; }
.media-card figcaption { min-height: 48px; }

.media-card input { display: block; width: 100%; font: inherit; font-size: 12px; color: var(--muted); }
.media-card input::file-selector-button { background: var(--panel-2); color: var(--text); border: 1px solid var(--line); border-radius: 6px; padding: 8px; margin-right: 8px; cursor: pointer; }



.example-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.grounding-bar { padding: 20px 24px; border: 1px solid rgba(34,211,238,.3); border-radius: 12px; background: rgba(34,211,238,.04); color: #cbd5e1; font-size: 14px; }
.example-card { border: 1px solid var(--line); border-radius: 12px; background: var(--panel); padding: 22px; }
.example-card h4 { margin: 10px 0; font-size: 16px; }
.example-card p { font-size: 13px; }
.example-evidence { border-top: 1px solid var(--line); padding-top: 14px; }
.example-evidence b { font-size: 12px; color: var(--muted); }
.example-evidence p { margin: 4px 0 12px; color: var(--muted); }
.evolution-page a:not(.brand):not(.btn):not(.nav-links a) { color: var(--cyan); }
.example-evidence a { font-size: 12px; }
.state-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 24px; }
.state-grid article { border-top: 2px solid var(--purple); padding: 16px; background: var(--panel); border-radius: 0 0 12px 12px; }
.state-grid p { font-size: 13px; color: var(--muted); }
.gate-flow { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; padding: 0; list-style: none; counter-reset: gate; }
.gate-flow li { counter-increment: gate; padding: 15px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); font-size: 13px; }
.gate-flow li::before { content: counter(gate, decimal-leading-zero) " →"; display: block; color: var(--cyan); font: 12px/2 ui-monospace, monospace; }
.architecture { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel-2); padding: 24px; }
.arch-runtime { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.arch-runtime span { font-size: 13px; color: var(--muted); }
.arch-flow { font: 13px/1.7 ui-monospace, monospace; color: var(--cyan); padding: 20px 0; overflow-wrap: anywhere; }
.arch-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.arch-grid article { padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); }
.arch-grid h3 { margin: 0 0 8px; font-size: 15px; }
.arch-grid p, .architecture > p { font-size: 13px; color: var(--muted); }
.architecture .grounding-bar { margin-top: 16px; }
.evolution-page .bench-card h4 { margin: 0; }
.evolution-page .card h3:first-child { margin-top: 0; }
@media (max-width: 760px) {
  .nav-inner { flex-wrap: wrap; gap: 8px; padding: 10px 16px; }
  .nav-links { order: 3; flex-basis: 100%; flex-wrap: nowrap; overflow-x: auto; margin-left: 0; }
  .nav-links a { white-space: nowrap; }
  .lang-toggle { margin-left: auto; min-height: 36px; }
  .mode-selector, .state-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .mode-panel, .example-grid, .arch-grid { grid-template-columns: 1fr; }
  .mode-contract { border-left: 0; border-top: 1px solid var(--line); }
  .mode-copy, .mode-contract { padding: 20px; }
  .gate-flow { grid-template-columns: 1fr; }
  .gate-flow li::before { display: inline; margin-right: 12px; }

  .hero { padding-top: 44px; }
  .container { padding: 0 18px; }
  .pill { white-space: normal; }
  .skills-grid, .gallery-grid, .dir-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

/* ---------- theme toggle ---------- */
:root { color-scheme: dark; }
.theme-toggle {
  margin-left: 4px; display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 30px; border-radius: 999px;
  background: var(--panel); border: 1px solid var(--line); cursor: pointer;
  font-size: 14.5px; line-height: 1; transition: border-color .15s;
}
.theme-toggle:hover { border-color: rgba(34,211,238,.45); }
.tt-icon { display: inline-block; }

/* ---------- contracts interactive table ---------- */
.contracts { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; margin: 22px 0; }
.ct-head, .ct-row {
  display: grid; grid-template-columns: minmax(160px, 240px) 1fr 44px;
  align-items: center; gap: 14px; padding: 13px 18px;
}
.ct-head {
  background: rgba(15,23,42,.6); color: var(--muted); font-size: 12.5px;
  text-transform: uppercase; letter-spacing: .4px;
}
.ct-row {
  width: 100%; text-align: left; background: none; border: 0; border-top: 1px solid var(--line);
  color: inherit; font: inherit; cursor: pointer; transition: background .15s;
}
.ct-row:hover { background: rgba(34,211,238,.05); }
.ct-row[aria-expanded="true"] { background: rgba(34,211,238,.06); }
.ct-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ct-name { font-size: 15.5px; color: var(--text); }
.ct-duty { font-size: 13px; color: var(--muted); }
.ct-chev { text-align: center; color: var(--dim); font-size: 16px; transition: transform .18s ease; }
.ct-row[aria-expanded="true"] .ct-chev { transform: rotate(180deg); color: var(--cyan); }
.ct-detail { border-top: 1px dashed var(--line); background: rgba(15,23,42,.35); padding: 14px 18px 14px 32px; }
.ct-detail ul { margin: 0; padding-left: 18px; }
.ct-detail li { font-size: 13.5px; color: #cbd5e1; padding: 3px 0; }
@media (max-width: 700px) {
  .ct-head { display: none; }
  .ct-row { grid-template-columns: 1fr 36px; padding: 12px 14px; }
  .ct-detail { padding: 12px 14px 12px 24px; }
}

/* ---------- back to top ---------- */
.back-top {
  position: fixed; right: 22px; bottom: 26px; z-index: 70;
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--panel); color: var(--cyan);
  font-size: 18px; cursor: pointer;
  box-shadow: 0 6px 18px rgba(2,6,23,.4);
  transition: transform .15s, border-color .15s;
}
.back-top:hover { transform: translateY(-2px); border-color: rgba(34,211,238,.5); }

.chip-nav { color: var(--blue); border-color: rgba(96,165,250,.4); }
.mem-demo { margin-top: 20px; }

/* ---------- light theme ---------- */
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #eef2f9; --bg-soft: #e4eaf4; --panel: #ffffff; --panel-2: #f6f8fc;
  --text: #1c2532; --muted: #4b5870; --dim: #55617a; --line: rgba(15,23,42,.18);
  --cyan: #0e7490; --purple: #6d28d9; --orange: #9a3412; --green: #15803d;
  --pink: #be185d; --amber: #854d0e; --blue: #1d4ed8; --red: #b91c1c;
}
[data-theme="light"] body {
  background:
    radial-gradient(1100px 500px at 75% -5%, rgba(167,139,250,.14), transparent 60%),
    radial-gradient(900px 420px at 10% 0%, rgba(34,211,238,.12), transparent 55%),
    var(--bg);
  color: var(--text);
}
[data-theme="light"] p, [data-theme="light"] .lede { color: #3a465e; }
[data-theme="light"] em, [data-theme="light"] b { color: #101a2a; }
[data-theme="light"] .hero h1 {
  background: linear-gradient(92deg, #0f172a 30%, #0891b2 70%, #7c3aed);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
[data-theme="light"] .draft-banner {
  background: linear-gradient(90deg, rgba(220,38,38,.08), rgba(234,88,12,.08));
  border-bottom-color: rgba(220,38,38,.25); color: #b91c1c;
}
[data-theme="light"] .nav { background: rgba(255,255,255,.86); }
[data-theme="light"] .nav-links a:hover { color: var(--text); background: rgba(15,23,42,.05); }
[data-theme="light"] .nav-links a.active { color: #0e7490; background: rgba(6,182,212,.1); }
[data-theme="light"] .lt-opt.active { color: #0e7490; background: rgba(6,182,212,.12); }
[data-theme="light"] code { background: rgba(15,23,42,.07); color: #0e7490; }
[data-theme="light"] pre code { color: #0e7490; }
[data-theme="light"] .arch-flow { color: #0e7490; }
[data-theme="light"] .arch-runtime span { color: var(--muted); }
[data-theme="light"] .ct-head { background: rgba(15,23,42,.04); }
[data-theme="light"] .ct-detail { background: rgba(15,23,42,.03); }
[data-theme="light"] .ct-detail li { color: #3c4a60; }
[data-theme="light"] thead th { background: rgba(15,23,42,.04); color: var(--muted); }
[data-theme="light"] tbody td { color: #2c3850; }
[data-theme="light"] .row-base td { color: var(--muted); }
[data-theme="light"] .row-ours td { background: rgba(74,222,128,.12); }
[data-theme="light"] .tb-track { background: rgba(15,23,42,.08); }
[data-theme="light"] .skill-count { background: rgba(15,23,42,.06); }
[data-theme="light"] .sk-item { background: rgba(15,23,42,.03); }
[data-theme="light"] .sk-item code { color: #0e7490; }
[data-theme="light"] .sk-item span { color: var(--muted); }
[data-theme="light"] .grounding-bar { background: rgba(6,182,212,.06); color: #294255; }
[data-theme="light"] .fig-wide img, [data-theme="light"] .fig-wide svg { background: #fff; }
[data-theme="light"] .loop-node, [data-theme="light"] .gate-flow li,
[data-theme="light"] .rung, [data-theme="light"] .arch-grid article { background: var(--panel); }
[data-theme="light"] .architecture { background: var(--panel-2); }
[data-theme="light"] .mode-contract { background: rgba(238,242,249,.8); }
[data-theme="light"] .video-slot { background: radial-gradient(ellipse at center, rgba(6,182,212,.08), transparent), var(--bg-soft); }
[data-theme="light"] .tag-wip { color: #0e7490; border-color: rgba(6,182,212,.4); background: rgba(6,182,212,.08); }
[data-theme="light"] .tag-draft { color: #a16207; border-color: rgba(217,119,6,.4); background: rgba(251,191,36,.12); }
[data-theme="light"] .back-top { box-shadow: 0 6px 18px rgba(15,23,42,.15); }
[data-theme="light"] .ct-name, [data-theme="light"] .hl-nums { color: var(--text); }
[data-theme="light"] .boundary-note { color: #4a4433; }


/* ---------- project reading layout ---------- */
body { overflow-wrap: break-word; }
main, figure, article, .card, .section-content, .hero-copy, .hero-media,
.bench-card, .dir-card, .pair-grid > *, .arch-grid > * { min-width: 0; }
figure { max-width: 100%; }
button, input, select { font: inherit; }
a { color: var(--cyan); }
button, summary { cursor: pointer; }
button:disabled { cursor: default; opacity: .55; }
summary:focus-visible, select:focus-visible, [tabindex="0"]:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.nav-inner { gap: 12px; min-height: 64px; }
.nav-links { flex-wrap: nowrap; align-items: center; }
.nav-links a, .nav-more summary { display: block; min-height: 44px; padding: 11px 9px; font-size: 13px; }
.nav-more { position: relative; }
.nav-more summary { color: var(--muted); border-radius: 8px; white-space: nowrap; }
.nav-more summary:hover { background: rgba(148,163,184,.1); }
.nav-dropdown { position: absolute; right: 0; top: calc(100% + 8px); min-width: 220px; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); box-shadow: 0 12px 28px rgba(0,0,0,.16); }
.nav-dropdown a { white-space: nowrap; }
.theme-toggle { width: 44px; height: 44px; flex-shrink: 0; }
.lang-toggle { min-height: 44px; padding: 6px 9px; margin-left: 0; }
.menu-toggle { display: none; color: var(--text); background: var(--panel); border: 1px solid var(--line); border-radius: 9px; padding: 8px 12px; min-height: 44px; }
.hero { padding: 64px 0 40px; }
.hero-grid { display: grid; grid-template-columns: .9fr 1.15fr; gap: 40px; align-items: center; text-align: left; }
.hero h1, [data-theme="light"] .hero h1 { color: var(--text); background: none; letter-spacing: -.04em; line-height: 1.08; }
.hero-copy .subtitle { color: var(--text); font-size: clamp(21px, 2.3vw, 28px); line-height: 1.4; margin-bottom: 20px; }
.hero-copy .venue-badge { border-radius: 7px; padding: 5px 10px; margin-bottom: 18px; }
.hero-copy .link-row { justify-content: flex-start; gap: 10px; margin: 24px 0 0; }
.btn-primary { color: var(--bg); background: var(--cyan); border-color: var(--cyan); font-weight: 600; }
.hero-media { margin: 0; }
.hero-media video { display: block; width: 100%; aspect-ratio: 768/340; object-fit: contain; box-shadow: 0 12px 36px rgba(0,0,0,.12); }
.hero-media figcaption { font-size: 14.5px; margin-top: 14px; }
.resource-pending { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); padding: 7px 3px; font-size: 13px; }
.resource-pending .soon { border: 1px solid var(--line); border-radius: 6px; font-size: 11px; padding: 1px 5px; }
.resource-status { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 12px; }
.stats-row { margin-top: 36px; gap: 16px; }
.feature { padding: 20px; }
.feature b { font-size: 17px; }
.section { padding: 52px 0 24px; border-top: 1px solid var(--line); }
.section h2 { font-size: clamp(24px, 3vw, 30px); letter-spacing: -.02em; }
.section h2::before { display: none; }
.section-heading { margin-bottom: 20px; }
.section-content > p:not(.table-note):not(.filter-status) { max-width: none; }
.collapse-toggle, .btn, .skill-head { min-height: 44px; }
.control-loop { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; list-style: none; padding: 0; margin: 28px 0; }
.control-loop .loop-node { position: relative; max-width: none; padding: 18px 12px; text-align: left; }
/* 步骤间的静态弧线箭头：横向铺满卡片间距，两端顶到相邻卡片边缘；遮罩取形，颜色跟随 --muted 适配深浅主题 */
.control-loop .loop-node:not(:last-child)::after {
  content: '';
  position: absolute;
  right: -20px;
  top: 50%;
  width: 22px;
  height: 13px;
  transform: translateY(-50%);
  background-color: var(--muted);
  -webkit-mask: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 34 20'><path d='M2 15C10 6.5 20 5.5 29 10' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round'/><path d='M22.5 4.5L31 10.25 21.5 14.5' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/></svg>") no-repeat center / 100% 100%;
          mask: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 34 20'><path d='M2 15C10 6.5 20 5.5 29 10' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round'/><path d='M22.5 4.5L31 10.25 21.5 14.5' fill='none' stroke='black' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'/></svg>") no-repeat center / 100% 100%;
  z-index: 1;
}
.control-loop .step-number { color: var(--muted); font: 11px/1.5 ui-monospace, monospace; margin-bottom: 12px; }
.control-loop .loop-node span:not(.step-number) { font-size: 13.5px; }
.disclosure { margin: 24px 0; padding: 16px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.disclosure > summary { min-height: 32px; color: var(--text); font-weight: 600; }
.disclosure[open] > summary { margin-bottom: 18px; }
.disclosure > p { font-size: 16px; line-height: 1.85; }
.gallery-more { padding: 16px 18px; }
.gallery-more .gallery-grid { margin-top: 20px; }
.tile { cursor: default; }
.tile:hover { transform: none; }
.tile figcaption b { overflow-wrap: break-word; word-break: normal; }
.gallery-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.media-error { padding: 12px; color: var(--red); font-size: 13px; }
.skill-filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(180px, .55fr) auto; gap: 16px; align-items: end; margin-top: 24px; }
.skill-filters label { min-width: 0; display: grid; gap: 6px; font-size: 13px; color: var(--muted); }
.skill-filters input, .skill-filters select { width: 100%; min-width: 0; height: 46px; border: 1px solid var(--line); border-radius: 9px; padding: 8px 12px; color: var(--text); background: var(--panel); font-size: 14px; }
.filter-status { color: var(--muted); font-size: 14px; min-height: 1.6em; }
.skills-grid { margin-top: 18px; }
.skill-n { white-space: normal; }
.sk-item code { overflow-wrap: anywhere; }
.table-scroll-hint { color: var(--muted); font-size: 13px; display: none; }
.table-wrap { max-width: 100%; overscroll-behavior-x: contain; }
.task-bar { grid-template-columns: minmax(110px, .8fr) minmax(0, 1fr) 44px; gap: 10px; }
.tb-label { color: var(--muted); font-size: 12px; }
.bench-head, .dir-head { flex-wrap: wrap; }
.ct-row { grid-template-columns: minmax(0, 1fr) 36px; }
.ct-head { display: none; }
.arch-pipeline { margin: 18px 0; border: 1px solid var(--line); border-radius: 10px; padding: 16px; }
.arch-flow { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; padding: 12px 0 0; margin: 0; }
.arch-flow li { border: 1px solid var(--line); background: var(--panel); border-radius: 6px; padding: 6px 10px; }
.arch-flow li:not(:last-child)::after { content: ' →'; color: var(--muted); }
.evolution-hero { padding: 48px 0 32px; }
.evolution-hero h1 { font-size: clamp(30px, 4vw, 46px); }
.evolution-hero .subtitle { margin: 18px auto 14px; max-width: none; }
.evolution-intro { margin-bottom: 16px; }
.pair-controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 18px 0; }
.pair-controls[hidden] { display: none; }
.pair-controls .table-note { flex-basis: 100%; }



.evolution-media .video-slot { border-style: solid; }
.evolution-media:has(#beforeCard[hidden]) { grid-template-columns: minmax(0, 1fr); max-width: 900px; margin-inline: auto; }
.evolution-media .media-card figcaption { min-height: 0; }
.case-evidence { max-width: 620px; margin: 22px auto 0; text-align: left; }
.case-evidence > summary { min-height: 44px; padding-block: 8px; }
.case-evidence > .case-evidence-meta { font-size: 14px; color: var(--muted); }
.case-evidence-events { list-style: none; padding: 0; margin: 20px 0; }
.case-evidence-events li { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.7fr); gap: 16px; padding: 14px 0; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.75; }
.case-evidence-events b { color: var(--cyan); font-weight: 600; }
.case-evidence-events span { color: var(--text); }
.case-evidence > .table-note { font-size: 14px; }
@media (max-width: 480px) {
  .case-evidence-events li { grid-template-columns: minmax(0, 1fr); gap: 4px; }
}
.footer { margin-top: 48px; }
@media (max-width: 1050px) {
  .nav-inner { flex-wrap: wrap; gap: 8px; padding: 8px 18px; }
  .menu-toggle { display: none; margin-left: auto; }
  [data-nav-ready] .menu-toggle { display: inline-flex; }
  .lang-toggle { margin-left: 0; }
  .nav-links { display: flex; order: 5; flex-basis: 100%; margin: 0; padding: 8px 0 12px; flex-direction: column; align-items: stretch; overflow: visible; max-height: calc(100dvh - 145px); overflow-y: auto; }
  [data-nav-ready] .nav-links { display: none; }
  .nav.menu-open .nav-links { display: flex; }
  .nav-links a { white-space: normal; font-size: 14px; padding: 12px; }
  .nav-more { border-top: 1px solid var(--line); }
  .nav-more summary { padding: 12px; }
  .nav-dropdown { position: static; min-width: 0; box-shadow: none; margin: 0 10px; }
  .hero-grid { gap: 24px; }
}
@media (max-width: 760px) {
  .container { padding: 0 18px; }
  .hero { padding: 36px 0 28px; }
  .hero-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero h1 { font-size: 48px; }
  .hero-copy .subtitle { font-size: 23px; }
  .hero-copy .link-row { margin-top: 20px; }
  .stats-row { flex-wrap: wrap; margin-top: 28px; }
  .section { padding: 34px 0 20px; }
  .control-loop { grid-template-columns: 1fr; gap: 10px; }
  .control-loop .loop-node { display: grid; grid-template-columns: 28px 85px 1fr; align-items: center; gap: 8px; padding: 12px; }
  .control-loop .step-number, .control-loop .loop-node b { margin: 0; }
  .control-loop .loop-node:not(:last-child)::after { display: none; }
  .gallery-grid { grid-template-columns: 1fr; gap: 16px; }
  .skill-filters { grid-template-columns: 1fr; gap: 12px; }
  .skill-filters .btn { justify-self: start; }
  .skill-card { padding: 16px; }
  .skill-head { gap: 8px; }
  .skill-title { font-size: 15px; }
  .skill-n { display: none; }
  .table-scroll-hint { display: block; }
  .disclosure, .architecture, .card { padding: 16px; }
  .section-heading { gap: 10px; }
  .collapse-label { display: none; }
  .collapse-toggle { width: 44px; padding: 10px; justify-content: center; }
  .headline-strip { gap: 10px; }
  .headline-card { padding: 14px 16px; }

  .evolution-hero h1 { font-size: 34px; }
  .back-top { width: 44px; height: 44px; right: 14px; bottom: 16px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media (max-width: 420px) {
  .nav-inner { padding: 8px 12px; gap: 6px; }
  .brand { font-size: 14px; }
  .brand-dot { display: none; }
  .menu-toggle { width: 44px; padding: 0; font-size: 0; justify-content: center; align-items: center; }
  .menu-toggle::before { content: '☰'; font-size: 21px; }
  .lang-toggle { padding: 4px; gap: 3px; font-size: 12px; }
}

/* Presentation typography, video explanations and animated architecture. */
.control-loop { gap: 22px; margin: 36px 0; }
.control-loop .loop-node:not(:last-child)::after { width: 26px; height: 15px; right: -24px; }
.control-loop .loop-node { padding: 26px 20px; border-radius: 16px; min-height: 172px; transition: transform .25s, box-shadow .25s; }
.control-loop .loop-node:hover { transform: translateY(-5px); box-shadow: 0 14px 28px rgba(6,182,212,.1); }
.control-loop .step-number { font-size: 20px; margin-bottom: 18px; }
.control-loop .loop-node b { font-size: 23px; line-height: 1.4; margin-bottom: 8px; }
.control-loop .loop-node span:not(.step-number) { font-size: 17px; line-height: 1.6; }
.abstract-card > p { font-size: 18px; line-height: 1.95; }
.gallery-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
.tile { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.tile video { display: block; width: 100%; border-radius: 0; }
.tile figcaption { display: block; padding: 22px 24px 26px; text-align: left; }
.demo-title { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; border-bottom: 1px solid var(--line); padding-bottom: 16px; margin-bottom: 16px; }
.demo-title > b { font-size: 21px; flex: 1 1 100%; }
.demo-explanation p { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 12px; margin: 13px 0 0; font-size: 16px; line-height: 1.8; color: var(--muted); }
.demo-explanation p > b { font-size: 14px; color: var(--cyan); }
.gallery-more { background: none; padding: 20px 0 0; border: 0; }
.hero-media figcaption { font-size: 15px; line-height: 1.85; }
.system-layout { display: grid; grid-template-columns: minmax(290px, .75fr) minmax(0, 1.5fr); gap: 28px; align-items: start; margin-top: 26px; }
.module-list { display: grid; gap: 12px; }
.module-list .ct-group { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--panel); }
.module-list .ct-row { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 24px 20px; border: 0; background: none; color: var(--text); text-align: left; transition: background .2s; }
.module-list .ct-row:hover, .module-list .ct-row[aria-expanded="true"] { background: rgba(6,182,212,.08); }
.ct-main { display: grid; gap: 9px; min-width: 0; }
.ct-name { font-size: 20px; }
.ct-duty { font-size: 14px; line-height: 1.65; color: var(--muted); }
.ct-detail { padding: 0 18px 20px; }
.ct-detail > p { font-size: 14px; line-height: 1.75; margin: 14px 0 0; }
.ct-detail[hidden] { display: none; }
.mini-flow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 0; margin: 0; list-style: none; }
.mini-flow li { position: relative; text-align: center; border: 1px solid rgba(6,182,212,.35); background: var(--panel-2); border-radius: 8px; padding: 14px 5px; color: var(--cyan); font-size: 13px; }
.mini-flow li:not(:last-child)::after { content: '→'; position: absolute; top: 38%; right: -11px; color: var(--cyan); }
.live-diagram { margin: 0; padding: 26px; position: relative; overflow: hidden; background: radial-gradient(ellipse at 60% 30%, rgba(6,182,212,.09), transparent 70%), var(--panel); }
.diagram-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-bottom: 24px; }
.diagram-heading h3 { margin: 0; font-size: 20px; }
.diagram-heading .btn { font-size: 12px; padding: 7px 12px; }
.scene-runtime { display: flex; justify-content: space-between; gap: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 10px; font-size: 15px; }
.live-orbit { color: var(--cyan); animation: signal-glow 2.5s ease-in-out infinite; }
.scene-pipeline { position: relative; margin: 20px 0; border: 1px solid var(--line); border-radius: 12px; padding: 18px 14px 26px; }
.scene-steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; list-style: none; margin: 14px 0 0; padding: 0; }
.scene-steps li { position: relative; text-align: center; font-size: 15px; padding: 15px 2px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); animation: step-glow 6s ease-in-out infinite; animation-delay: calc(var(--step) * 1.2s); }
.signal-track { position: relative; height: 2px; margin: 20px 6px 0; background: linear-gradient(90deg, var(--cyan), var(--purple), var(--cyan)); opacity: .85; }
.signal-track::before { content: ''; position: absolute; width: 10px; height: 10px; top: -4px; left: 0; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 15px var(--cyan); animation: signal-travel 6s linear infinite; }
.return-path { position: absolute; bottom: 5px; right: 14px; color: var(--purple); font-size: 25px; }
.scene-components { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; padding: 10px; border: 1px solid transparent; border-radius: 12px; }
.scene-components > div { display: grid; gap: 6px; border: 1px solid var(--line); border-radius: 10px; padding: 16px 12px; background: var(--panel-2); }
.scene-components b { font-size: 16px; }
.scene-components span { color: var(--muted); font-size: 13px; line-height: 1.6; }
.scene-environment { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; border: 1px solid var(--line); border-radius: 10px; padding: 16px; margin: 20px 0; }
.scene-environment span { color: var(--cyan); font-size: 13px; }
.scene-environment span:first-child::after { content: ' →'; }
.scene-environment span:last-child::before { content: '→ '; }
.scene-knowledge { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.scene-knowledge > div { padding: 16px 12px; border-top: 2px solid var(--purple); border-radius: 6px; background: var(--panel-2); }
.scene-knowledge p { font-size: 13px; line-height: 1.7; color: var(--muted); margin: 8px 0 0; }
.live-diagram > figcaption { margin-top: 20px; font-size: 13px; line-height: 1.75; color: var(--muted); }
[data-module="runtime"] [data-scene="runtime"], [data-module="pipeline"] [data-scene="pipeline"], [data-module="agent"] [data-scene="agent"], [data-module="env"] [data-scene="env"] { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(6,182,212,.1); transition: border-color .2s, box-shadow .2s; }
.result-dataset { display: inline-block; border: 1px solid var(--line); border-radius: 7px; padding: 6px 12px; color: var(--cyan); font-weight: 650; margin: 0 0 14px; }
.result-comparison { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin-top: 30px; }
.result-condition { padding: 28px; border: 1px solid var(--line); border-radius: 16px; background: var(--panel); }
.result-condition h3 { font-size: 22px; margin: 0 0 14px; }
.result-condition > p { font-size: 15px; line-height: 1.8; min-height: 3.6em; color: var(--muted); }
.result-condition dl { margin: 22px 0 0; }
.result-condition dl > div { border-top: 1px solid var(--line); padding-top: 16px; margin-top: 16px; }
.result-condition dt { font-size: 15px; color: var(--muted); }
.result-condition dd { font-size: clamp(38px, 3.5vw, 52px); letter-spacing: -.04em; font-weight: 750; margin: 8px 0 0; font-variant-numeric: tabular-nums; }
.result-condition dd small { font-size: .48em; margin-left: 4px; }
.result-with { border-color: var(--cyan); background: linear-gradient(150deg, rgba(6,182,212,.07), transparent), var(--panel); }
.result-with dd { color: var(--cyan); }
.result-gain { margin-top: 24px; padding: 20px 22px; border-radius: 10px; background: rgba(6,182,212,.08); font-size: 18px; font-weight: 600; color: var(--cyan); }
.pending-result { margin: 24px 0 36px; border: 1px dashed var(--line); border-radius: 12px; padding: 20px; display: flex; gap: 18px; flex-wrap: wrap; }
.pending-result span { color: var(--muted); }
.task-bar { grid-template-columns: minmax(110px, .7fr) minmax(0, 1fr) 66px; margin-bottom: 14px; }
.tb-label { font-size: 15px; }
.tb-val { font-size: 17px; }
.tb-fill { transition: width .8s ease; }
.evolution-loop .loop-node { min-height: 185px; }
.mode-panel h3 { font-size: 26px; }
.mode-steps { font-size: 16px; line-height: 1.8; }
.mode-copy > p { font-size: 16px; line-height: 1.85; }
@keyframes signal-travel { from { left: 0; } to { left: calc(100% - 10px); } }
@keyframes signal-glow { 0%, 100% { opacity: .4; } 50% { opacity: 1; text-shadow: 0 0 14px var(--cyan); } }
@keyframes step-glow { 0%, 22%, 100% { border-color: var(--line); box-shadow: none; } 5%, 17% { border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(6,182,212,.12); } }
[data-motion="paused"] .live-diagram *, [data-motion="paused"] .live-diagram *::before { animation-play-state: paused; }
@media (max-width: 1050px) {
  .system-layout { grid-template-columns: 1fr; }
  .module-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .control-loop .loop-node { padding: 22px 14px; }
  .control-loop .loop-node b { font-size: 20px; }
  .control-loop .loop-node span:not(.step-number) { font-size: 15px; }
  .result-condition { padding: 22px 18px; }
}
@media (max-width: 760px) {
  .control-loop .loop-node { min-height: 0; padding: 20px 16px; grid-template-columns: 36px 85px minmax(0, 1fr); }
  .control-loop .step-number { font-size: 18px; }
  .control-loop .loop-node b { font-size: 21px; }
  .gallery-grid, .module-list, .result-comparison { grid-template-columns: 1fr; }
  .tile figcaption { padding: 20px 18px; }
  .demo-explanation p { grid-template-columns: 65px minmax(0, 1fr); gap: 9px; }
  .demo-title > b { font-size: 20px; }
  .live-diagram { padding: 18px 14px; }
  .scene-steps { gap: 5px; }
  .scene-steps li { font-size: 13px; padding: 13px 0; }
  .scene-components, .scene-knowledge { grid-template-columns: 1fr; }
  .scene-runtime { font-size: 14px; }
  .result-condition > p { min-height: 0; }
  .result-condition dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
  .result-condition dd { font-size: 40px; }
  .result-gain { font-size: 17px; line-height: 1.8; }
  .abstract-card > p { font-size: 17px; }
  .tb-label { font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  .live-diagram *, .live-diagram *::before { animation: none !important; }
  .control-loop .loop-node, .tb-fill { transition: none; }
  .control-loop .loop-node:hover { transform: none; }
}

.draft-banner, [data-theme="light"] .draft-banner { color: var(--muted); background: var(--panel-2); border-bottom: 1px solid var(--line); }
@media (max-width: 420px) {
  .demo-explanation p { grid-template-columns: minmax(0, 1fr); gap: 4px; }
}

/* Readable information flow and staged LIBERO results. */
.mode-contract h4 { font-size: 20px; line-height: 1.5; }
.mode-contract dt { font-size: 16px; font-weight: 650; margin-top: 24px; }
.mode-contract dd { font-size: 18px; line-height: 1.8; margin-top: 8px; }
.libero-results { margin-top: 48px; padding-top: 36px; border-top: 1px solid var(--line); }
.libero-results > h3 { font-size: 26px; margin: 0 0 18px; }
.libero-results > p { font-size: 16px; line-height: 1.85; }
.libero-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin: 26px 0; }
.libero-summary article { padding: 24px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; display: grid; gap: 12px; }
.libero-summary article:last-child { border-color: var(--cyan); background: linear-gradient(135deg, rgba(6,182,212,.08), transparent), var(--panel); }
.libero-summary span { font-size: 15px; line-height: 1.6; color: var(--muted); }
.libero-summary strong { font-size: 46px; font-variant-numeric: tabular-nums; line-height: 1.1; color: var(--text); }
.libero-summary article:last-child strong { color: var(--cyan); }
.libero-summary small { font-size: .5em; }
.libero-table { min-width: 720px; }
.libero-table th, .libero-table td { padding: 16px 12px; font-size: 15px; text-align: center; font-variant-numeric: tabular-nums; }
.libero-table tbody th { text-align: left; color: var(--text); border-bottom: 1px solid var(--line); }
.libero-table thead th { text-transform: none; letter-spacing: 0; }
.libero-table .libero-total th, .libero-table .libero-total td { color: var(--cyan); font-weight: 700; background: rgba(6,182,212,.06); }
@media (max-width: 760px) {
  .libero-summary { grid-template-columns: 1fr; }
  .libero-summary article { grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 12px; }
  .libero-summary article > span:first-child { grid-column: 1; grid-row: 1; }
  .libero-summary article > span:last-child { grid-column: 1; grid-row: 2; }
  .libero-summary strong { grid-column: 2; grid-row: 1 / 3; font-size: 38px; }
}

.libero-table tbody th > span { display: block; font-size: 13px; color: var(--muted); font-weight: 400; margin-top: 6px; }
.libero-results { scroll-margin-top: var(--header-height); }

/* Knowledge and experience join the evolution loop. */
.knowledge-flow { margin: 30px 0; }
.knowledge-flow > h3 { margin: 0 0 24px; font-size: 24px; }
.knowledge-board { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, .9fr); gap: 30px; align-items: center; }
.knowledge-sources { display: grid; gap: 14px; }
.knowledge-source { width: 100%; position: relative; display: flex; gap: 14px; align-items: center; text-align: left; min-height: 85px; padding: 18px; color: var(--text); border: 1px solid var(--line); border-radius: 12px; background: var(--panel); transition: transform .2s, border-color .2s, background .2s; font-size: 19px; font-weight: 650; }
.knowledge-source:hover { transform: translateX(4px); }
.source-glyph { font-size: 28px; color: var(--cyan); }
.source-experience .source-glyph { color: var(--purple); }
.knowledge-source[aria-pressed="true"] { border-color: var(--cyan); background: rgba(6,182,212,.08); }
.source-experience[aria-pressed="true"] { border-color: var(--purple); background: rgba(139,92,246,.08); }
.source-arrow { position: absolute; right: -24px; color: var(--cyan); font-size: 24px; animation: knowledge-pulse 2.4s ease-in-out infinite; }
.source-experience .source-arrow { color: var(--purple); animation-delay: 1.2s; }
.knowledge-planner, .knowledge-feedback { text-align: center; border: 1px solid var(--line); border-radius: 14px; padding: 24px 14px; background: var(--panel-2); display: grid; gap: 14px; }
.knowledge-planner b { font-size: 30px; color: var(--cyan); }
.knowledge-flow[data-source="experience"] .knowledge-planner b { color: var(--purple); }
.knowledge-planner span, .knowledge-feedback span { font-size: 15px; line-height: 1.7; color: var(--muted); }
.knowledge-feedback b { font-size: 20px; }
.knowledge-signal { position: relative; height: 2px; background: linear-gradient(90deg, var(--cyan), var(--purple)); margin: 8px 0; }
.knowledge-signal::before { content: ''; position: absolute; width: 8px; height: 8px; top: -3px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 12px var(--cyan); animation: signal-travel 3s linear infinite; }
.knowledge-flow > p { font-size: 16px; line-height: 1.8; padding-top: 18px; margin: 22px 0 0; border-top: 1px solid var(--line); color: var(--muted); }
.knowledge-flow > p[hidden] { display: none; }
#memory .memory-intro { max-width: none; }
.memory-intro em { display: inline; }
@keyframes knowledge-pulse { 0%,100% { opacity: .35; } 50% { opacity: 1; } }

@media (max-width: 900px) {
  .knowledge-board { grid-template-columns: 1fr; gap: 18px; }
  .knowledge-sources { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
  .source-arrow { display: none; }
  .knowledge-source { font-size: 17px; padding: 14px; }
}
@media (max-width: 420px) { .knowledge-sources { grid-template-columns: 1fr; } }
