/* LookatStudy landing — the app's night-sky world, six semantic roles, demo-led.
   Roles: brand #58cc02 (progress) · accent #1cb0f6 (interact) · gold #ffc800 (mastery)
          warning #ff4b4b (error) · review #ff7a1a · exam #a855f7 (boss). */

:root {
  --night-0: #0b0f1a;
  --night-1: #101828;
  --panel: #131c2e;
  --panel-2: #0f1626;
  --line: #232d42;
  --line-soft: #1b2438;
  --fg: #e8edf6;
  --sub: #96a3ba;
  --faint: #6f7e97;

  --brand: #58cc02;
  --brand-dark: #46a302;
  --brand-deep: #2f4d1a;
  --accent: #1cb0f6;
  --accent-dark: #1585bc;
  --gold: #ffc800;
  --warn: #ff4b4b;
  --review: #ff7a1a;
  --exam: #a855f7;

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --radius: 18px;
  --shadow-panel: 0 24px 60px -24px rgba(0, 0, 0, 0.65), 0 4px 16px -8px rgba(0, 0, 0, 0.5);
}

* { box-sizing: border-box; }

@media (prefers-reduced-motion: reduce) { #appScroll { scroll-behavior: auto; } }

html, body { height: 100%; }
body {
  margin: 0;
  background: var(--night-0);
  color: var(--fg);
  overflow: hidden;
  font-family: "Nunito", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  font-size: 16px;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* browser chrome carries the design too */
::selection { background: rgba(88, 204, 2, 0.35); color: #fff; }
html { color-scheme: dark; scrollbar-color: #2a3550 var(--night-0); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: #2a3550; border-radius: 5px; }
::-webkit-scrollbar-track { background: var(--night-0); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
button, input { caret-color: var(--accent); font: inherit; }

#appScroll {
  position: fixed; inset: 0; z-index: 10;
  overflow-y: auto; overflow-x: hidden;
  scroll-behavior: smooth;
}
#railSky { position: fixed; inset: 0; z-index: 0; width: 100%; height: 100%; }
#railOrbs { position: fixed; inset: 0; z-index: 20; width: 100%; height: 100%; pointer-events: none; }

img { max-width: 100%; height: auto; display: block; }
h1, h2, h3 { line-height: 1.16; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h1:lang(en), h2:lang(en), h3:lang(en) { letter-spacing: -0.025em; }
h1 { font-weight: 900; }
h2 { font-weight: 900; font-size: clamp(1.9rem, 3.2vw, 2.6rem); text-wrap: balance; }
.cc-pct, .mastery-val, #examTimer, .sign-num { font-variant-numeric: tabular-nums; }
h3 { font-weight: 800; font-size: 1.08rem; }
p { margin: 0 0 1em; }
em { font-style: normal; color: var(--brand); }
strong { color: var(--fg); }

.container { max-width: 1140px; margin: 0 auto; padding: 0 28px; }
.section-sub { color: var(--sub); font-size: 1.1rem; max-width: 620px; margin-bottom: 2.4rem; }

.skip { position: absolute; left: -9999px; top: 0; background: var(--brand); color: #fff; padding: 10px 18px; border-radius: 0 0 10px 0; z-index: 100; }
.skip:focus { left: 0; }

.bot { width: 32px; height: 32px; }

/* ============ buttons: the app's 3D push-down ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 22px;
  border-radius: 14px;
  border: 0;
  border-bottom: 4px solid transparent;
  font-weight: 800; font-size: 0.9rem; letter-spacing: 0.4px; text-transform: uppercase;
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: filter 0.15s ease, transform 0.06s ease, border-bottom-width 0.06s ease;
}
.btn:active { transform: translateY(2px); border-bottom-width: 2px; }
.btn-lg { padding: 15px 28px; font-size: 0.98rem; border-radius: 16px; }
.btn-sm { padding: 7px 14px; font-size: 0.78rem; border-radius: 10px; }
.btn-brand { background: var(--brand); color: #fff; border-bottom-color: var(--brand-dark); }
.btn-brand:hover { filter: brightness(1.07); }
.btn-ghost { background: transparent; color: var(--accent); border: 2px solid var(--line); border-bottom-width: 4px; }
.btn-ghost:hover { border-color: var(--accent); }
.btn-ghost svg { width: 18px; height: 18px; fill: currentColor; }

/* ============ nav ============ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(11, 15, 26, 0.82);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--line-soft);
}
.nav-inner { display: flex; align-items: center; gap: 26px; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 900; font-size: 1.12rem; letter-spacing: -0.02em; color: var(--fg); text-decoration: none; }
.nav-links { display: flex; gap: 22px; margin-left: 8px; }
.nav-links a { color: var(--sub); text-decoration: none; font-weight: 700; font-size: 0.9rem; letter-spacing: 0.3px; text-transform: uppercase; }
.nav-links a:hover { color: var(--brand); }
.nav-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.lang-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: 2px solid var(--line); border-radius: 10px;
  color: var(--sub); font-weight: 700; font-size: 0.85rem;
  padding: 6px 12px; cursor: pointer;
}
.lang-toggle:hover { color: var(--accent); border-color: var(--accent); }
.lang-toggle svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.8; }

/* ============ sky ============ */
.sky {
  position: absolute; inset: 0; pointer-events: none; overflow: hidden;
  background:
    radial-gradient(1.6px 1.6px at 12% 22%, rgba(255,255,255,0.7), transparent 60%),
    radial-gradient(1px 1px at 28% 68%, rgba(255,255,255,0.45), transparent 60%),
    radial-gradient(1.4px 1.4px at 44% 12%, rgba(255,255,255,0.6), transparent 60%),
    radial-gradient(1px 1px at 58% 44%, rgba(255,255,255,0.4), transparent 60%),
    radial-gradient(1.6px 1.6px at 71% 76%, rgba(255,255,255,0.65), transparent 60%),
    radial-gradient(1px 1px at 84% 26%, rgba(255,255,255,0.5), transparent 60%),
    radial-gradient(1.2px 1.2px at 92% 58%, rgba(255,255,255,0.55), transparent 60%),
    radial-gradient(1px 1px at 8% 84%, rgba(255,255,255,0.45), transparent 60%),
    radial-gradient(1.3px 1.3px at 36% 40%, rgba(255,255,255,0.5), transparent 60%),
    radial-gradient(1px 1px at 66% 10%, rgba(255,255,255,0.45), transparent 60%);
  animation: twinkle 7s ease-in-out infinite alternate;
}
@keyframes twinkle { from { opacity: 0.75; } to { opacity: 1; } }

/* ============ hero ============ */
.hero { position: relative; padding: 84px 0 40px; }
.hero-grid {
  position: relative;
  display: grid; grid-template-columns: 11fr 9fr; gap: 56px; align-items: center;
}
.hero-copy h1 { font-size: clamp(2.3rem, 4.6vw, 3.4rem); margin-bottom: 0.45em; }
.hero-sub { color: var(--sub); font-size: 1.14rem; max-width: 34em; margin-bottom: 1.8rem; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-pills { list-style: none; display: flex; gap: 9px; flex-wrap: wrap; padding: 0; margin: 26px 0 0; }
.hero-pills li { background: rgba(255,255,255,0.05); border: 1px solid var(--line-soft); color: var(--sub); border-radius: 999px; padding: 4px 13px; font-size: 0.82rem; font-weight: 600; }

/* ---- panels (shared demo chrome) ---- */
.panel {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-panel);
}
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 14px 18px 0; }
.panel-title { font-size: 0.78rem; font-weight: 800; letter-spacing: 0.8px; text-transform: uppercase; color: var(--faint); }
.panel-course { font-size: 0.78rem; color: var(--sub); }

/* ---- demo 屏:左文右图(统一) ---- */
.screen-demo .stage {
  display: flex; flex-direction: row; align-items: center;
  gap: 3vw; padding: 96px 3.5vw 24px;
}
.side-copy, .world-copy {
  position: relative;
  width: 30%; min-width: 300px; max-width: 440px; height: fit-content;
  padding: 30px 32px;
  background: linear-gradient(165deg, rgba(11,15,26,.94), rgba(11,15,26,.82));
  border: 1px solid var(--line); border-bottom: 7px solid #0c1322;
  border-radius: 20px;
  box-shadow: 0 18px 44px rgba(4,8,16,.5), inset 0 1px 0 rgba(255,255,255,0.07);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.side-copy::after, .world-copy::after {
  content: ""; position: absolute; left: 12px; right: 12px; bottom: 7px;
  height: 1px; background: rgba(255,255,255,0.06);
}
/* 头像币:伙伴压在卡角,卡=伙伴说的话 */
.card-bot {
  position: absolute; top: -28px; left: -24px; width: 62px; height: 62px;
  border-radius: 999px;
  background: linear-gradient(180deg, #101826, #0b111c);
  border: 3px solid #354263;
  box-shadow: 0 12px 24px rgba(4,8,16,.55), inset 0 2px 0 rgba(255,255,255,0.09);
  display: flex; align-items: flex-end; justify-content: center;
  overflow: hidden; pointer-events: none; z-index: 2;
}
.card-bot img { width: 92%; height: auto; margin-bottom: -9%; }
/* 气泡尾巴:指向头像币 */
.side-copy h2 { margin: 0 0 14px; font-size: clamp(1.7rem, 1.3vw + 1.1rem, 2.35rem); line-height: 1.32; text-wrap: balance; }
.hero-side h1 { margin: 0 0 16px; font-size: clamp(2rem, 1.6vw + 1.15rem, 2.75rem); line-height: 1.24; text-wrap: balance; }
.hero-side .hero-sub { font-size: 1.04rem; max-width: 24em; margin-bottom: 1.6rem; }
.hero-side .hero-pills { margin-top: 20px; gap: 8px; }
.hero-side .hero-pills li { background: rgba(29,37,56,0.55); border-color: rgba(255,255,255,0.12); }
.platform-line { margin: 16px 0 0; font-size: 0.85rem; font-weight: 700; color: var(--faint); letter-spacing: 0.02em; }
/* 卡入场:跟随所在屏的滚动进度 .seen(导入屏是首屏,常显) */
#map .world-copy, [data-screen="chat"] .side-copy,
[data-screen="read"] .side-copy, [data-screen="companion"] .side-copy {
  opacity: 0; transform: translateY(16px);
  transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
}
#map .world-copy.seen, [data-screen="chat"] .side-copy.seen,
[data-screen="read"] .side-copy.seen, [data-screen="companion"] .side-copy.seen {
  opacity: 1; transform: none;
}
.side-copy .side-sub { margin: 0; font-size: 1.02rem; line-height: 1.75; color: var(--sub); }
.demo-area { flex: 1; min-width: 0; display: flex; justify-content: center; }
.screen-demo .panel { width: min(100%, 760px); padding: 28px 30px 26px; overflow: hidden; }

/* ── 屏 1:全屏导入大管线(源 → bot → 课程卡) ── */
.pipe-big {
  width: min(100%, 980px);
  display: flex; align-items: center; gap: 3.5vw;
}
.pipe-sources { display: flex; flex-direction: column; gap: 18px; flex: 1; }
.pipe-sources span {
  display: flex; align-items: center; justify-content: center; gap: 12px;
  padding: 18px 24px; border-radius: 16px;
  background: rgba(29,37,56,0.72); border: 1px solid var(--line);
  font-size: 1.18rem; font-weight: 800; color: var(--fg);
  transition: border-color 0.25s ease, background-color 0.25s ease, opacity 0.25s ease, transform 0.2s ease;
  opacity: 0.85;
  will-change: transform, opacity;
}
.pipe-sources span svg { width: 24px; height: 24px; flex: none; color: var(--accent); }
.pipe-sources span.marching { border-color: rgba(88,204,2,0.6); background: rgba(88,204,2,0.14); opacity: 1; }
.pipe-sources span.marching svg { color: var(--brand); }
.pipe-big .pipe-hub { flex: 0 0 auto; width: 150px; display: flex; justify-content: center; }
.pipe-big .pipe-hub .bot { width: 130px; height: auto; }
.pipe-big .pipe-hub.pulse img.bot { animation: hub-pulse 0.5s var(--ease-out); }
@keyframes hub-pulse { 40% { transform: scale(1.14); } }
.charge-card {
  flex: 1.15; padding: 26px 28px;
  background: linear-gradient(165deg, rgba(11,15,26,.94), rgba(11,15,26,.80));
  border: 1px solid var(--line); border-radius: 18px;
  box-shadow: 0 18px 40px rgba(4,8,16,.45);
  transition: border-color 0.4s ease, box-shadow 0.4s ease;
}
.charge-card.done { border-color: rgba(88,204,2,0.55); box-shadow: 0 18px 44px rgba(88,204,2,0.14); }
.charge-label { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.02rem; margin-bottom: 16px; }
.charge-dot { width: 9px; height: 9px; border-radius: 999px; background: var(--accent); animation: charge-blink 1.1s ease-in-out infinite; }
.charge-card.done .charge-dot { background: var(--brand); animation: none; }
@keyframes charge-blink { 50% { opacity: 0.25; } }
.charge-bar { height: 14px; border-radius: 999px; background: rgba(255,255,255,0.07); border: 1px solid rgba(255,255,255,0.12); overflow: hidden; }
.charge-bar i {
  display: block; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, #46A302, #58cc02 60%, #7ED957);
  transform-origin: left center; transform: scaleX(0);
  box-shadow: 0 0 14px rgba(88,204,2,0.45);
}
.charge-card.done .charge-bar i { box-shadow: 0 0 20px rgba(88,204,2,0.6); }
.cc-meta { display: flex; align-items: baseline; gap: 12px; color: var(--sub); font-size: 0.92rem; margin-top: 14px; }
.charge-card .cc-meta span:last-child { opacity: 0; transition: opacity 0.4s ease; }
.charge-card.done .cc-meta span:last-child { opacity: 1; }
.cc-pct { font-weight: 900; font-size: 1.7rem; color: var(--brand); }

/* ── 屏 1:文案卡下的导入条(一切→课程→技能地图) ── */
.import-strip { margin-top: 18px; pointer-events: none; }
.import-strip .pipe { padding: 0; }
.import-strip .pipe-in span, .import-strip .lesson-chip { font-size: 0.72rem; }
.import-strip .pipe-hub img.bot { width: 40px; }

/* ── 屏 2:导师出题 quiz-mini ── */
.quiz-mini { margin: 14px 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: 14px; background: rgba(29,37,56,0.5); }
.js .quiz-mini { opacity: 0; transform: translateY(10px); transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out); }
.js .quiz-mini.in { opacity: 1; transform: none; }
.quiz-q { margin: 0 0 10px; font-weight: 800; font-size: 1.02rem; }
.quiz-opts { display: flex; flex-direction: column; gap: 7px; }
.quiz-opts span { padding: 9px 13px; border-radius: 10px; border: 1px solid var(--line); font-size: 0.94rem; color: var(--sub); opacity: 0.75; transition: opacity 0.3s ease, border-color 0.3s ease, color 0.3s ease; }
.quiz-opts span.ok.picked, .quiz-mini.on .quiz-opts span.ok { border-color: rgba(88,204,2,0.55); color: var(--fg); background: rgba(88,204,2,0.12); opacity: 1; }
.quiz-ok { margin-top: 10px; font-weight: 800; color: var(--brand); font-size: 0.92rem; opacity: 0; transform: translateY(4px); transition: opacity 0.35s ease, transform 0.35s ease; }
.quiz-mini.on .quiz-ok { opacity: 1; transform: none; }

/* ── 屏 3:讲解+黑板双栏 ── */
.nb-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 22px; align-items: stretch; }
.note-chip { margin-top: 12px; display: inline-block; white-space: nowrap; padding: 6px 12px; border-radius: 10px; background: rgba(255,200,0,0.14); border: 1px solid rgba(255,200,0,0.4); color: #ffe294; font-size: 0.85rem; font-weight: 700; opacity: 0; transform: translateY(6px); transition: opacity 0.35s ease, transform 0.35s ease; }
.note-chip.in { opacity: 1; transform: none; }
.read-text span.noted { background: rgba(255,200,0,0.16); box-decoration-break: clone; -webkit-box-decoration-break: clone; border-bottom: 2px solid rgba(255,200,0,0.75); }
.concept-mini { display: flex; flex-direction: column; }
.cm-title { font-weight: 800; font-size: 0.92rem; color: var(--sub); margin-bottom: 8px; }
.cm-formula {
  margin-bottom: 10px; padding: 9px 12px; text-align: center;
  font-family: Georgia, "Times New Roman", serif; font-style: italic; font-size: 1.08rem;
  color: #9BE8FF; background: rgba(155,232,255,0.05);
  border: 1px dashed rgba(155,232,255,0.35); border-radius: 10px;
}
.cm-formula sup, .cm-formula sub, .read-text sup, .read-text sub { font-size: 0.68em; }
.concept-map { width: 100%; height: auto; background: rgba(16,24,40,0.6); border: 1px solid var(--line); border-radius: 14px; flex: 1; }
.cm-node circle { fill: rgba(28,176,246,0.14); stroke: var(--accent); stroke-width: 1.5; }
.cm-node text { fill: var(--fg); font-size: 13px; font-weight: 700; text-anchor: middle; }
.cm-node { opacity: 0; transform: scale(0.6); transform-origin: center; transform-box: fill-box; transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out); }
.cm-node.on { opacity: 1; transform: none; }
.cm-edge { stroke: rgba(163,177,204,0.6); stroke-width: 2; fill: none; stroke-dasharray: 220; stroke-dashoffset: 220; }

/* ── 屏 4:伴学系统 ── */
.companion-stage { display: flex; align-items: center; gap: 5vw; width: min(100%, 900px); }
.companion-hero { flex: 0 0 auto; width: min(38%, 300px); display: flex; justify-content: center; }
.companion-hero { display: flex; justify-content: center; }
.comp-live { position: relative; width: min(64%, 250px); cursor: pointer; user-select: none; -webkit-user-select: none; touch-action: manipulation; }
.comp-mount { display: flex; justify-content: center; filter: drop-shadow(0 16px 22px rgba(0,0,0,0.5)); }
.comp-bubble {
  position: absolute; left: 50%; bottom: calc(100% + 14px); transform: translateX(-50%) translateY(6px);
  max-width: 300px; width: max-content; padding: 10px 16px;
  background: linear-gradient(165deg, rgba(11,15,26,.96), rgba(11,15,26,.86));
  border: 1px solid var(--line); border-radius: 14px; border-bottom-left-radius: 4px;
  color: var(--fg); font-size: 0.98rem; font-weight: 700; line-height: 1.5; white-space: nowrap;
  opacity: 0; transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out);
  pointer-events: none;
}
.comp-bubble.in { opacity: 1; transform: translateX(-50%) translateY(0); }

.companion-cards { flex: 1; display: flex; flex-direction: column; gap: 16px; }
.comp-card { padding: 20px 24px; opacity: 0; transform: translateX(28px); transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-out); }
.comp-card.in { opacity: 1; transform: none; }
.comp-card h4 { margin: 0 0 5px; font-size: 1.18rem; }
.comp-card p { margin: 0; color: var(--sub); font-size: 0.98rem; }

/* ---- live map demo: faithful MapRail replica (values from the app's index.css) ---- */
/* demo 屏标题:恒暗 chip,白天浅色天空下文字仍可读(与文案卡同语言) */
.screen-head {
  background: rgba(11,15,26,.82); border: 1px solid var(--line);
  border-radius: 16px; padding: 16px 30px;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}

/* ---- live map demo: faithful MapRail replica (values from the app's index.css) ---- */
/* ---- Scroll-Driven 分屏:每屏 = sticky 舞台 + 高滚动预算,滚动推进该屏演示 ---- */
.screen { position: relative; }
.screen-world { height: 360vh; }
.screen-demo { height: 300vh; }
.screen > .stage {
  position: sticky; top: 0; height: 100vh; overflow: hidden;
}

/* 屏 1:左 1/3 文案卡 + 右 2/3 技能地图 */
.screen-world .stage {
  display: flex; align-items: stretch; gap: 2.2vw;
  padding: 86px 3vw 12px;
}
.world-copy {
  width: 31%; min-width: 330px; max-width: 470px;
  align-self: center;
  pointer-events: none;
  /* 盒样式(恒暗底/3D 厚底边/头像币)由上方 .side-copy,.world-copy 合并规则提供 */
}
  -webkit-backdrop-filter: blur(6px);
}
.world-copy a, .world-copy button { pointer-events: auto; }
.world-copy h2 { margin: 0 0 12px; font-size: clamp(1.7rem, 1.3vw + 1.1rem, 2.4rem); text-wrap: balance; }
.world-copy .side-sub { margin: 0; font-size: 1.04rem; line-height: 1.6; color: var(--sub); }
.world-copy .hero-sub { max-width: 30em; font-size: 1.04rem; }
.world-copy .hero-pills { gap: 8px; }
.world-copy .hero-pills li { background: rgba(29,37,56,0.55); border-color: rgba(255,255,255,0.12); }

.map-facts { width: 27%; flex: none; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.fact-card {
  padding: 18px 22px;
  background: linear-gradient(165deg, rgba(11,15,26,.94), rgba(11,15,26,.80));
  border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 12px 28px rgba(4,8,16,.4);
  font-size: 1.22rem; font-weight: 800; line-height: 1.5; color: var(--fg);
  opacity: 0; transform: translateX(30px);
  transition: opacity 0.45s var(--ease-out), transform 0.45s var(--ease-out);
}
.fact-card.in { opacity: 1; transform: none; }
.fact-card.fact-exam { border-color: rgba(168,85,247,0.5); }
.fact-exam.in { box-shadow: 0 12px 28px rgba(168,85,247,0.16); }
.world-map {
  width: 40%; flex: 1; height: 100%;
  display: flex; gap: 2.5%;
  margin: 0; position: relative; z-index: 5;
}
.rail-section { width: 100%; margin: 0; position: relative; }
.screen-world .map-signpost { width: 100%; }
.world-hint {
  position: sticky; bottom: 24px; z-index: 30;
  width: fit-content; margin: 18px auto 0;
  background: rgba(11,15,26,0.7); border: 1px solid var(--line);
  backdrop-filter: blur(8px); border-radius: 999px;
  padding: 7px 18px; font-size: 0.85rem; font-weight: 700; color: var(--sub);
  pointer-events: none;
}

/* hint 在 flex row 的 stage 里必须绝对定位,否则被 stretch 拉成整列高色块 */
.screen-world .world-hint {
  position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%);
  margin: 0;
}
.screen-demo .world-hint { display: none; }

.weather-dock {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  display: flex; flex-direction: column; gap: 8px;
  background: rgba(11,15,26,0.72); border: 1px solid var(--line);
  backdrop-filter: blur(10px); border-radius: 16px; padding: 8px;
}
.weather-dock button {
  width: 38px; height: 38px; border-radius: 11px;
  background: rgba(255,255,255,0.05); border: 1px solid transparent;
  color: var(--sub); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.weather-dock button:hover { color: var(--fg); background: rgba(255,255,255,0.1); }
.weather-dock button.on { color: var(--brand); background: rgba(88,204,2,0.14); border-color: rgba(88,204,2,0.3); }
.weather-dock svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }

.map-signpost {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 10px; border-radius: 8px; margin-bottom: 8px;
  background: rgba(14, 20, 32, 0.55);
  backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px);
  border: 1px solid rgba(255,200,0,0.18); border-top-color: rgba(255,200,0,0.35);
  box-shadow: 0 2px 8px rgba(0,0,0,0.35), inset 0 1px 0 rgba(255,255,255,0.06);
}
.sign-num { width: 24px; height: 24px; border-radius: 999px; background: var(--gold); color: #141a26; font-size: 0.75rem; font-weight: 800; display: flex; align-items: center; justify-content: center; flex: none; box-shadow: 0 0 0 2px rgba(255,200,0,0.4); }
.sign-title { font-size: 0.83rem; font-weight: 700; color: #fff; }

.rail-world { position: relative; width: 100%; }
.rail-ropes { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.rope { fill: none; stroke: rgba(163, 177, 204, 0.5); stroke-width: 2.5; stroke-dasharray: 3 7; stroke-linecap: round; }
.rope.done { stroke: var(--brand); stroke-opacity: 0.6; stroke-width: 4; stroke-dasharray: none; }

/* 节点球:app 的 lesson-bubble 3D 渐变;位置/形变由物理岛每帧直写(transform) */
.rail-ball {
  position: absolute; left: 0; top: 0;
  width: 88px; height: 88px; margin: -44px 0 0 -44px;
  border-radius: 999px;
  display: flex; align-items: center; justify-content: center;
  background-position: 30% 25%;
  cursor: grab;
}
.rail-ball:active { cursor: grabbing; }
.rail-ball::before {
  content: ""; position: absolute; top: 12%; left: 22%; width: 38%; height: 28%;
  border-radius: 50%; pointer-events: none; z-index: 1;
  background: radial-gradient(ellipse at center, rgba(255,255,255,0.35) 0%, rgba(255,255,255,0) 70%);
}
.rail-ball .bb { font-size: 2rem; line-height: 1; z-index: 2; filter: drop-shadow(0 1px 2px rgba(0,0,0,0.4)); }
.rail-ball .bb-book { width: 24px; height: 24px; fill: none; stroke: #fff; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 1px 2px rgba(0,0,0,0.4)); }

.bubble-locked {
  background: radial-gradient(circle at 35% 30%, #2A2B2E 0%, #1A1A1D 60%, #111114 100%);
  box-shadow: inset 0 3px 6px rgba(0,0,0,0.5), inset 0 -2px 4px rgba(255,255,255,0.04), 0 2px 4px rgba(0,0,0,0.3);
}
.bubble-locked::before { background: radial-gradient(ellipse at center, rgba(255,255,255,0.12) 0%, rgba(255,255,255,0) 70%); }
.bubble-locked .bb { opacity: 0.5; }

.bubble-available {
  background: radial-gradient(circle at 32% 28%, #7ED957 0%, #58cc02 45%, #46A302 100%);
  box-shadow: 0 0 0 4px rgba(88,204,1,0.15), 0 0 16px rgba(88,204,1,0.35), 0 4px 10px rgba(0,0,0,0.25);
}

.bubble-current {
  background: radial-gradient(circle at 32% 28%, #65C6FF 0%, #1cb0f6 45%, #098CDC 100%);
  box-shadow: 0 0 0 4px rgba(29,176,246,0.15), 0 0 14px rgba(29,176,246,0.3), 0 4px 10px rgba(0,0,0,0.25);
}

.bubble-mastered {
  background: radial-gradient(circle at 32% 28%, #FFE294 0%, #ffc800 45%, #D59800 100%);
  box-shadow: 0 0 0 4px rgba(255,200,1,0.2), 0 0 22px rgba(255,200,1,0.45), 0 0 40px rgba(255,200,1,0.15), 0 4px 12px rgba(0,0,0,0.25);
}
.bubble-mastered::before { background: radial-gradient(ellipse at center, rgba(255,255,255,0.7) 0%, rgba(255,255,255,0) 70%); }

.bubble-exam-locked {
  background: radial-gradient(circle at 35% 30%, #524569 0%, #3a3247 60%, #111114 100%);
  box-shadow: inset 0 3px 6px rgba(0,0,0,0.5), inset 0 -2px 4px rgba(255,255,255,0.04), 0 2px 4px rgba(0,0,0,0.3);
}
/* 章节考试解锁(剧本:boss 球激活)与通过(结算星满) */
.bubble-exam {
  background: radial-gradient(circle at 35% 30%, #c084fc 0%, #a855f7 45%, #7e22ce 100%);
  box-shadow: 0 0 0 4px rgba(168,85,247,0.18), 0 0 16px rgba(168,85,247,0.4), 0 4px 10px rgba(0,0,0,0.3);
}
.bubble-exam-passed {
  background: radial-gradient(circle at 35% 30%, #d8b4fe 0%, #a855f7 45%, #7e22ce 100%);
  box-shadow: 0 0 0 4px rgba(255,200,0,0.35), 0 0 20px rgba(192,132,252,0.55), 0 4px 10px rgba(0,0,0,0.3);
}

.rail-ball .bb-book { width: 34px; height: 34px; }
.rail-ball .ring { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; }

.rail-ball .due {
  position: absolute; top: -5px; right: -5px; z-index: 3;
  width: 18px; height: 18px; border-radius: 999px;
  background: var(--review); color: #fff;
  font-size: 0.7rem; font-weight: 800; font-style: normal;
  display: flex; align-items: center; justify-content: center;
  border: 2px solid #0e1420;
}

.rail-ball-stars { position: fixed; transform: translate(-50%, 0); display: flex; gap: 2px; font-size: 0.75rem; font-style: normal; color: rgba(255,255,255,0.25); z-index: 4; }
.rail-ball-stars i { font-style: normal; }
.rail-ball-stars i.lit { color: #ffc800; text-shadow: 0 0 8px rgba(255,200,0,0.55); }

.rail-ball.next-cue::after {
  content: ""; position: absolute; inset: -7px; border-radius: 9999px;
  border: 2.5px dashed var(--gold); pointer-events: none;
  animation: cue-pulse 1.6s ease-in-out infinite;
}
@keyframes cue-pulse { 0%, 100% { opacity: 0.55; transform: scale(1); } 50% { opacity: 1; transform: scale(1.08); } }

.rail-label {
  position: fixed; z-index: 4; transform: translate(-50%, 0);
  max-width: 130px; padding: 2px 7px; border-radius: 6px;
  background: rgba(88, 204, 2, 0.92); color: #fff;
  font-size: 0.72rem; font-weight: 700; text-align: center; line-height: 1.35;
  box-shadow: 0 1px 2px rgba(0,0,0,0.4);
  transition: left 0.8s var(--ease-out), top 0.8s var(--ease-out);
}

/* 真身伴学(ember.svg,app 组件静态导出) */
.rail-bot {
  position: fixed; z-index: 30; width: 84px; margin: -42px 0 0 -42px;
  cursor: grab; touch-action: none;
  transition: left 0.9s var(--ease-out), top 0.9s var(--ease-out);
  filter: drop-shadow(0 10px 14px rgba(0,0,0,0.5));
}
.rail-bot.dragging { cursor: grabbing; transition: none; z-index: 30; }
.rail-bot.phys { transition: none; }
.rail-bot img { width: 100%; height: auto; display: block; pointer-events: none; animation: bot-hover 2.8s ease-in-out infinite; }
@keyframes bot-hover { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
.rail-bot.poke img { animation: bot-poke 0.55s var(--ease-out); }
@keyframes bot-poke {
  0% { transform: translateY(0) rotate(0); }
  30% { transform: translateY(-16px) rotate(-14deg) scale(1.06); }
  60% { transform: translateY(0) rotate(12deg); }
  100% { transform: none; }
}

.burst { position: absolute; width: 6px; height: 6px; border-radius: 50%; pointer-events: none; z-index: 20; }

/* ============ demos bento ============ */
.demos { padding: 96px 0 84px; background: var(--night-0); }
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: 22px; }
.bento .panel { padding: 26px 26px 24px; overflow: hidden; }
.demo-sub { color: var(--sub); font-size: 0.94rem; margin-bottom: 1.4rem; }
.demo-tutor { grid-column: span 7; grid-row: span 2; display: flex; flex-direction: column; }
.demo-read { grid-column: span 5; }
.demo-exam { grid-column: span 5; }
.demo-import { grid-column: 1 / -1; }

/* ---- tutor demo ---- */
.chat-mini { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 12px; }
.chat-style { display: flex; gap: 6px; }
.chat-style .pill { font-size: 0.72rem; font-weight: 700; color: var(--faint); border: 1px solid var(--line); border-radius: 999px; padding: 2px 10px; }
.chat-style .pill.on { color: var(--accent); border-color: var(--accent-dark); background: rgba(28, 176, 246, 0.08); }

.bubble {
  max-width: 88%; padding: 9px 14px; border-radius: 14px;
  font-size: 0.92rem; line-height: 1.55;
}
.js .bubble { opacity: 0; transform: translateY(8px); transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out); }
.js .bubble.in { opacity: 1; transform: none; }
.bubble.user { align-self: flex-end; background: rgba(28, 176, 246, 0.12); border: 1px solid rgba(28, 176, 246, 0.25); border-bottom-right-radius: 4px; }
.bubble.ai { align-self: flex-start; background: var(--panel-2); border: 1px solid var(--line); border-bottom-left-radius: 4px; min-height: 20px; min-width: 56px; max-width: 94%; }
.bubble.ai.typing::after { content: ""; display: inline-block; width: 2px; height: 1em; margin-left: 2px; background: var(--accent); vertical-align: text-bottom; animation: caret 0.8s steps(2) infinite; }
@keyframes caret { 50% { opacity: 0; } }

.proposal {
  display: flex; align-items: center; gap: 12px;
  background: var(--panel-2); border: 1px solid var(--gold); border-radius: 14px;
  padding: 12px 14px;
}
.js .proposal { opacity: 0; transform: translateY(10px); transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out); }
.js .proposal.in { opacity: 1; transform: none; }
.js .proposal.applied { animation: proposal-glow 0.9s var(--ease-out); }
@keyframes proposal-glow {
  0% { transform: scale(0.97); box-shadow: 0 0 0 0 rgba(255, 200, 0, 0.4); }
  60% { box-shadow: 0 0 0 12px rgba(255, 200, 0, 0); }
  100% { transform: none; box-shadow: 0 0 0 0 rgba(255, 200, 0, 0); }
}
.js .proposal.used #chatApply { opacity: 0.55; transform: scale(0.96); }
.proposal > svg { width: 20px; height: 20px; flex: none; fill: none; stroke: var(--gold); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.proposal-text { flex: 1; min-width: 0; }
.proposal-text strong { display: block; font-size: 0.88rem; line-height: 1.35; }
.proposal-note { display: block; font-size: 0.76rem; color: var(--faint); margin-top: 2px; }

.toast-mini {
  align-self: flex-start; margin-top: 2px;
  background: rgba(88, 204, 2, 0.12); border: 1px solid var(--brand-dark);
  color: var(--brand); border-radius: 999px; padding: 4px 14px;
  font-size: 0.8rem; font-weight: 700;
}
.js .toast-mini { opacity: 0; transform: translateY(6px); transition: opacity 0.3s var(--ease-out), transform 0.3s var(--ease-out); }
.js .toast-mini.in { opacity: 1; transform: none; }

.mastery { padding-top: 22px; display: grid; gap: 10px; }
.mastery-row { display: grid; grid-template-columns: 76px 1fr 44px; align-items: center; gap: 12px; }
.mastery-kc { font-size: 0.82rem; font-weight: 700; color: var(--sub); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mastery-bar { height: 10px; border-radius: 5px; background: #232d42; overflow: hidden; }
.mastery-fill { display: block; height: 100%; width: 100%; border-radius: 5px; background: var(--accent); transform-origin: left; transition: transform 1.2s var(--ease-out); }
.mastery-fill.hi { background: var(--brand); }
.mastery-val { font-size: 0.82rem; font-weight: 800; text-align: right; font-variant-numeric: tabular-nums; }

/* ---- read-aloud demo ---- */
.read-stage { display: grid; grid-template-columns: 56px 1fr; gap: 16px; align-items: start; }
.read-bot { position: relative; text-align: center; }
.read-bot .bot { width: 44px; height: 44px; animation: bot-hover 2.8s ease-in-out infinite; filter: drop-shadow(0 6px 10px rgba(0,0,0,0.45)); }
.read-bars { display: inline-flex; gap: 3px; align-items: flex-end; height: 14px; margin-top: 6px; }
.read-bars i { width: 4px; border-radius: 2px; background: var(--accent); height: 100%; transform: scaleY(0.3); transform-origin: bottom; }
.demo-read.playing .read-bars i { animation: bars 0.9s ease-in-out infinite; }
.read-bars i:nth-child(1) { animation-delay: 0s; }
.read-bars i:nth-child(2) { animation-delay: 0.15s; }
.read-bars i:nth-child(3) { animation-delay: 0.3s; }
.read-bars i:nth-child(4) { animation-delay: 0.45s; }
@keyframes bars { 0%, 100% { transform: scaleY(0.3); } 50% { transform: scaleY(1); } }
.read-text { margin: 0; font-size: 1.05rem; line-height: 1.9; color: var(--sub); }
#screen-read .panel { width: min(100%, 840px); }
.read-text span { border-radius: 4px; padding: 1px 3px; margin: 0 -1px; transition: background-color 0.4s ease, color 0.4s ease; }
.read-text span.on { background: rgba(28, 176, 246, 0.22); color: var(--fg); }

/* ---- exam demo ---- */
.exam-mini { display: flex; flex-direction: column; gap: 12px; }
.exam-head { display: flex; justify-content: space-between; align-items: center; }
.exam-name { font-size: 0.8rem; font-weight: 800; color: var(--exam); letter-spacing: 0.4px; text-transform: uppercase; }
.exam-timer { font-size: 0.9rem; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--sub); }
.exam-q { margin: 0; font-size: 0.95rem; font-weight: 600; }
.exam-opts { display: grid; gap: 8px; }
.exam-opts button {
  text-align: left; background: var(--panel-2); color: var(--sub);
  border: 1px solid var(--line); border-radius: 12px;
  padding: 9px 13px; font-size: 0.86rem; line-height: 1.45; cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}
.exam-opts button:hover { border-color: var(--faint); }
.exam-opts button.picked { border-color: var(--brand); background: rgba(88, 204, 2, 0.1); color: var(--fg); }
.exam-result { display: flex; align-items: center; gap: 14px; }
.js .exam-result { display: none; }
.js .exam-result.in { display: flex; }
.stars { display: inline-flex; gap: 4px; }
.stars i { width: 20px; height: 20px; background: #2a3550; clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); }
.js .exam-result.in .stars i { transform: scale(0); animation: star-pop 0.4s var(--ease-out) forwards; }
.js .exam-result.in .stars i:nth-child(1) { animation-delay: 0.05s; background: var(--gold); }
.js .exam-result.in .stars i:nth-child(2) { animation-delay: 0.25s; background: var(--gold); }
.js .exam-result.in .stars i:nth-child(3) { animation-delay: 0.45s; }
@keyframes star-pop { to { transform: scale(1); } }
.exam-kcs { font-size: 0.84rem; font-weight: 700; color: var(--brand); }

/* ---- import pipeline ---- */
.pipe { position: relative; display: grid; grid-template-columns: 1fr auto 1fr; gap: 28px; align-items: center; min-height: 190px; max-width: 900px; margin: 0 auto; }
.pipe-in, .pipe-out { display: flex; flex-direction: column; gap: 9px; }
.pipe-in span {
  border: 1px dashed var(--line); border-radius: 10px; padding: 7px 13px;
  font-size: 0.85rem; font-weight: 600; color: var(--sub);
  background: var(--panel-2); width: fit-content; min-width: 128px;
}
.pipe-in span.marching { border-style: solid; border-color: var(--accent-dark); color: var(--accent); }
.pipe-hub {
  width: 88px; height: 88px; border-radius: 24px;
  background: var(--panel-2); border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 14px 34px -16px rgba(0, 0, 0, 0.7);
  transition: transform 0.25s var(--ease-out), border-color 0.25s ease;
}
.pipe-hub .bot { width: 48px; height: 48px; }
.pipe-hub.pulse { transform: scale(1.1); border-color: var(--accent); }
.pipe-out { align-items: flex-end; }
.lesson-chip {
  display: inline-flex; align-items: center; gap: 6px;
  border: 1px solid var(--brand-deep); border-radius: 10px; padding: 7px 13px;
  font-size: 0.85rem; font-weight: 700; color: var(--brand);
  background: rgba(88, 204, 2, 0.07); width: fit-content; min-width: 138px; justify-content: center;
}
.js .lesson-chip { opacity: 0.25; transform: scale(0.92); transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out); }
.js .lesson-chip.in { opacity: 1; transform: none; }
.lesson-chip.gold { border-color: var(--gold); color: var(--gold); background: rgba(255, 200, 0, 0.07); }
.fly {
  position: absolute; z-index: 5; pointer-events: none;
  border: 1px solid var(--accent); border-radius: 10px; padding: 7px 13px;
  font-size: 0.85rem; font-weight: 600; color: var(--accent);
  background: var(--panel);
  white-space: nowrap;
}

/* ============ formats marquee ============ */
.formats { padding: 10px 0 30px; background: var(--night-0); }
.marquee {
  overflow: hidden; white-space: nowrap;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee-track { display: inline-flex; gap: 10px; padding-right: 10px; animation: marquee 40s linear infinite; will-change: transform; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span {
  font-family: ui-monospace, SFMono-Regular, Consolas, "Cascadia Mono", Menlo, monospace;
  font-size: 0.84rem; font-weight: 600; color: var(--faint);
  border: 1px solid var(--line-soft); border-radius: 8px; padding: 4px 12px;
}
@keyframes marquee { to { transform: translateX(-50%); } }

/* ============ screenshots ============ */
.shots { padding: 84px 0 60px; background: var(--night-0); }
.shot { margin: 0 0 26px; }
.shot img {
  border-radius: 16px; border: 1px solid var(--line);
  box-shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.8), 0 8px 24px -12px rgba(0, 0, 0, 0.6);
}
.shot-duo { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.shot-duo .shot { margin: 0; }
.shot figcaption { margin-top: 12px; text-align: center; color: var(--sub); font-size: 0.9rem; font-weight: 600; }

/* ============ why ============ */
.why { padding: 84px 0; border-top: 1px solid var(--line-soft); border-bottom: 1px solid var(--line-soft); background: var(--night-1); }
.why-inner { max-width: 760px; }
.why-pull { font-size: clamp(1.35rem, 2.4vw, 1.8rem); font-weight: 800; line-height: 1.4; letter-spacing: -0.02em; margin: 0 0 1em; color: var(--fg); }
.why-body { color: var(--sub); font-size: 1.06rem; line-height: 1.8; margin: 0; }
.why-body strong { color: var(--brand); font-weight: 800; }

/* ============ get started ============ */
.start { padding: 96px 0; background: var(--night-0); }
.start-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.start-card { padding: 30px 28px 24px; }
.start-card > p { color: var(--sub); }
.dl-buttons { display: flex; gap: 12px; flex-wrap: wrap; margin: 18px 0 4px; }
.start-note { font-size: 0.84rem; color: var(--faint); margin-top: 16px; }
.code-row { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; }
.code {
  flex: 1; min-width: 0;
  background: var(--night-0); border: 1px solid var(--line-soft); border-radius: 12px;
  padding: 16px 18px; margin: 0;
  font-size: 0.84rem; line-height: 1.7; overflow-x: auto;
}
.code code { font-family: ui-monospace, SFMono-Regular, Consolas, "Cascadia Mono", Menlo, monospace; color: #c4d3ec; }
.code-row .btn { flex: none; }

/* ============ footer ============ */
.footer { padding: 44px 0 42px; border-top: 1px solid var(--line-soft); background: var(--night-0); }
.footer-inner { display: flex; gap: 36px; align-items: flex-start; flex-wrap: wrap; }
.footer-brand { display: flex; gap: 14px; align-items: flex-start; max-width: 470px; }
.footer-brand p { margin: 0; font-size: 0.92rem; color: var(--sub); }
.footer-links { margin-left: auto; display: flex; gap: 22px; flex-wrap: wrap; padding-top: 6px; }
.footer-links a { color: var(--sub); text-decoration: none; font-weight: 600; font-size: 0.9rem; }
.footer-links a:hover { color: var(--fg); }

/* ============ responsive ============ */
@media (max-width: 1020px) {
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .map-world { width: min(64%, 320px); }
  .demo-tutor { grid-column: 1 / -1; grid-row: auto; }
  .demo-read, .demo-exam { grid-column: span 6; }
  .demo-import { grid-column: 1 / -1; }
}
@media (max-width: 860px) {
  .container { padding: 0 20px; }
  .nav-links { display: none; }
  .hero { padding-top: 56px; }
  .screen-world { height: 320vh; }
  .screen-demo { height: 240vh; }
  .screen-world .stage { flex-direction: column; padding: 78px 14px 8px; gap: 10px; }
  .world-copy { width: auto; max-width: none; margin: 0; padding: 20px 20px 22px; }
  .world-copy .hero-sub { font-size: 0.95rem; }
  .world-copy .hero-pills { display: none; }
  .world-map { width: 100%; gap: 3%; }
  .screen-demo .stage { padding: 80px 16px 16px; }
  .screen-demo .panel { width: 100%; padding: 20px 18px 18px; }
  .nb-grid { grid-template-columns: 1fr; }
  .screen-demo .stage { flex-direction: column; align-items: stretch; padding: 78px 14px 16px; gap: 16px; }
  .side-copy { width: auto; min-width: 0; max-width: none; margin: 0; padding: 20px 20px 22px; }
  .companion-stage { flex-direction: column; gap: 20px; }
  .companion-hero img.bot { max-width: 150px; }
  .quiz-opts span { font-size: 0.88rem; }
  .pipe-big { flex-direction: column; gap: 18px; }
  .pipe-sources span { font-size: 1rem; padding: 14px 18px; }
  .weather-dock { display: none !important; }
  #railBot { display: none !important; }
  .rail-label { display: none; }
  .hero-side .hero-cta, .hero-side .hero-pills { display: none; }
  .hero-side h1 { font-size: clamp(1.6rem, 6.5vw + 0.4rem, 2.05rem); }
  .hero-side { padding: 16px 18px 18px; }
  .hero-side .hero-sub { margin-bottom: 0; }
  .pipe-big { gap: 10px; }
  .pipe-sources { gap: 10px; }
  .pipe-sources span { font-size: 0.95rem; padding: 12px 16px; }
  .pipe-big .pipe-hub { width: 84px; }
  .pipe-big .pipe-hub .bot { width: 72px; }
  .course-card { padding: 18px 20px; }
  .cc-name { font-size: 1rem; margin-bottom: 12px; }
  .charge-card { padding: 16px 18px; }
  .charge-label { font-size: 0.92rem; margin-bottom: 10px; }
  .charge-bar { height: 11px; }
  .cc-pct { font-size: 1.25rem; }
  .map-facts { width: 100%; }
  .fact-card { font-size: 1.02rem; padding: 14px 18px; }
  .comp-live { width: min(52%, 170px); }
  .comp-bubble { white-space: normal; width: max-content; max-width: 78vw; font-size: 0.88rem; }
  .demos, .start { padding: 72px 0; }
  .shots { padding: 64px 0 48px; }
  .why { padding: 64px 0; }
  .bento .panel, .demo-read, .demo-exam { grid-column: 1 / -1; }
  .shot-duo { grid-template-columns: 1fr; }
  .start-grid { grid-template-columns: 1fr; }
  .pipe { grid-template-columns: 1fr; justify-items: center; gap: 18px; }
  .pipe-in, .pipe-out { flex-direction: row; flex-wrap: wrap; justify-content: center; }
  .pipe-in span, .lesson-chip { min-width: 0; }
  .nav-github span { display: none; }
}
@media (max-width: 560px) {
  h1 { font-size: 2.05rem; }
  .mastery-row { grid-template-columns: 64px 1fr 40px; }
  .map-world { width: 88%; }
}

/* ============ reduced motion: static mid-story frames, no loops ============ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .bubble, .js .proposal, .js .quiz-mini, .js .toast-mini, .js .lesson-chip { opacity: 1; transform: none; }
  .js .exam-result { display: flex; }
  .js .exam-opts button:nth-child(2) { border-color: var(--brand); background: rgba(88, 204, 2, 0.1); color: var(--fg); }
  .stars i { transform: scale(1); }
  .js .exam-result.in .stars i:nth-child(-n+2) { background: var(--gold); }
  .js .read-text span:nth-child(2) { background: rgba(28, 176, 246, 0.22); color: var(--fg); }
  .js .mastery-fill { transform: scaleX(0.78); }
  .js .lesson-chip:nth-child(-n+2) { opacity: 1; }
}

/* ── 补遗:吸收态芯片(伴学样式在 companion.css,来自 app) ── */
.pipe-sources span.absorbed { opacity: 0.22; border-style: dashed; }
.pipe-sources span.absorbed svg { opacity: 0.5; }
