/* ============================================================
   TM02 交换星球·顺序自由 —— 太空星空主题样式
   零依赖原生 CSS：星空背景、玻璃拟态卡片、发光效果、动效
   ============================================================ */

:root {
  --bg-deep: #070b1e;
  --bg-mid: #0d1430;
  --glass: rgba(20, 30, 66, 0.72);
  --glass-light: rgba(38, 52, 100, 0.55);
  --border-glow: rgba(120, 160, 255, 0.35);
  --mentor: #5b8cff;
  --mentor-deep: #2c4fa8;
  --commander: #ffb54d;
  --commander-deep: #b06a12;
  --ok: #39d98a;
  --bad: #ff6b7a;
  --gold: #ffd76b;
  --text: #e8edff;
  --text-dim: #9aa7cf;
  --radius: 16px;
  --font: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  color: var(--text);
  background: radial-gradient(ellipse at 50% -10%, #16204d 0%, var(--bg-mid) 45%, var(--bg-deep) 100%);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.75;
  padding-bottom: 140px;
}

/* ---------- 星空背景 ---------- */
.star-layer {
  position: fixed; inset: 0; z-index: -3; pointer-events: none;
  background-repeat: repeat;
}
.stars-a {
  background-image:
    radial-gradient(1.5px 1.5px at 20px 30px, #fff 50%, transparent 51%),
    radial-gradient(1px 1px at 130px 80px, #cfe0ff 50%, transparent 51%),
    radial-gradient(2px 2px at 250px 160px, #ffe9b0 50%, transparent 51%),
    radial-gradient(1px 1px at 330px 40px, #fff 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 70px 220px, #bcd2ff 50%, transparent 51%),
    radial-gradient(1px 1px at 420px 260px, #fff 50%, transparent 51%),
    radial-gradient(2px 2px at 180px 320px, #ffd7f0 50%, transparent 51%);
  background-size: 480px 380px;
  animation: twinkle 5s ease-in-out infinite alternate;
}
.stars-b {
  background-image:
    radial-gradient(1px 1px at 60px 120px, #fff 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 300px 200px, #a8c4ff 50%, transparent 51%),
    radial-gradient(1px 1px at 200px 340px, #fff 50%, transparent 51%),
    radial-gradient(2px 2px at 400px 90px, #c8ffe9 50%, transparent 51%),
    radial-gradient(1px 1px at 100px 260px, #ffe4c8 50%, transparent 51%);
  background-size: 520px 420px;
  animation: twinkle 7s ease-in-out infinite alternate-reverse;
}
@keyframes twinkle { from { opacity: 0.55; } to { opacity: 1; } }

.nebula {
  position: fixed; inset: 0; z-index: -4; pointer-events: none;
  background:
    radial-gradient(circle at 12% 22%, rgba(91, 140, 255, 0.14), transparent 34%),
    radial-gradient(circle at 86% 14%, rgba(255, 122, 200, 0.10), transparent 30%),
    radial-gradient(circle at 78% 82%, rgba(57, 217, 138, 0.08), transparent 32%),
    radial-gradient(circle at 22% 86%, rgba(255, 215, 107, 0.08), transparent 28%);
}

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(9, 13, 34, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-glow);
  padding: 10px 18px 12px;
}
.topbar-row {
  display: flex; flex-wrap: wrap; gap: 10px;
  align-items: center; justify-content: space-between;
  max-width: 1080px; margin: 0 auto;
}
.brand { display: flex; align-items: center; gap: 12px; }
.brand-planet {
  font-size: 2rem;
  filter: drop-shadow(0 0 10px rgba(140, 170, 255, 0.8));
  animation: float 4s ease-in-out infinite;
}
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
.brand-text h1 { font-size: 1.15rem; letter-spacing: 1px; }
.brand-text p { font-size: 0.75rem; color: var(--text-dim); }

.speech-controls { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ctl-btn {
  border: 1px solid var(--border-glow);
  background: var(--glass-light);
  color: var(--text);
  padding: 6px 12px; border-radius: 999px;
  font-size: 0.82rem; cursor: pointer;
  transition: all 0.2s;
}
.ctl-btn:hover { transform: translateY(-1px); box-shadow: 0 0 12px rgba(120,160,255,0.35); }
.ctl-btn.active { background: linear-gradient(135deg, #2c4fa8, #4b7bec); border-color: #7ba0ff; }
.rate-ctl { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; color: var(--text-dim); }
.rate-ctl input[type="range"] { width: 90px; accent-color: #7ba0ff; cursor: pointer; }

.progress-wrap { max-width: 1080px; margin: 8px auto 0; }
.progress-info {
  display: flex; justify-content: space-between;
  font-size: 0.78rem; color: var(--text-dim); margin-bottom: 4px;
}
.progress-track {
  height: 8px; border-radius: 99px;
  background: rgba(255,255,255,0.08);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.06);
}
.progress-fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, #5b8cff, #9d6bff, #ff7ac8);
  border-radius: 99px;
  box-shadow: 0 0 12px rgba(157, 107, 255, 0.8);
  transition: width 0.5s ease;
}
.speech-fallback {
  max-width: 1080px; margin: 8px auto 0;
  font-size: 0.8rem; color: #ffd76b;
  background: rgba(255, 215, 107, 0.08);
  border: 1px solid rgba(255, 215, 107, 0.3);
  border-radius: 10px; padding: 6px 12px;
}

/* ---------- 对话流 ---------- */
.chat-stream {
  max-width: 920px; margin: 26px auto 0; padding: 0 16px;
  display: flex; flex-direction: column; gap: 18px;
}

.msg-row { display: flex; gap: 10px; align-items: flex-start; animation: fadeUp 0.45s ease both; }
.msg-row.mentor { flex-direction: row; }
.msg-row.commander { flex-direction: row-reverse; }

@keyframes fadeUp { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }

.avatar {
  flex: 0 0 46px; width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  border: 2px solid var(--border-glow);
  background: var(--glass);
}
.msg-row.mentor .avatar { box-shadow: 0 0 14px rgba(91, 140, 255, 0.55); }
.msg-row.commander .avatar { box-shadow: 0 0 14px rgba(255, 181, 77, 0.55); }

.bubble {
  max-width: 78%;
  padding: 12px 16px;
  border-radius: var(--radius);
  background: var(--glass);
  border: 1px solid var(--border-glow);
  position: relative;
  white-space: pre-wrap;
  word-break: break-word;
}
.msg-row.mentor .bubble {
  border-left: 3px solid var(--mentor);
  background: linear-gradient(135deg, rgba(44,79,168,0.35), rgba(20,30,66,0.72));
}
.msg-row.commander .bubble {
  border-right: 3px solid var(--commander);
  background: linear-gradient(135deg, rgba(176,106,18,0.30), rgba(20,30,66,0.72));
}
.bubble-head {
  display: flex; align-items: center; gap: 8px;
  margin-bottom: 4px; font-size: 0.78rem; font-weight: 700;
}
.msg-row.mentor .bubble-head { color: #9dbcff; }
.msg-row.commander .bubble-head { color: #ffd09b; }
.btn-speak {
  margin-left: auto;
  border: 1px solid var(--border-glow);
  background: rgba(255,255,255,0.06);
  color: var(--text); border-radius: 999px;
  padding: 2px 10px; font-size: 0.75rem; cursor: pointer;
  transition: all 0.2s;
}
.btn-speak:hover { box-shadow: 0 0 10px rgba(120,160,255,0.5); }
.bubble-text { font-size: 0.98rem; }
.typing-caret { display: inline-block; width: 8px; color: var(--gold); animation: blink 0.7s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* ---------- 通用卡片 ---------- */
.card {
  background: var(--glass);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: 0 6px 26px rgba(0, 0, 0, 0.35);
  animation: fadeUp 0.5s ease both;
}
.card-title {
  font-size: 1.05rem; font-weight: 800; letter-spacing: 0.5px;
  margin-bottom: 12px;
  display: flex; align-items: center; gap: 8px;
}

.section-banner {
  text-align: center;
  padding: 26px 18px;
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(91,140,255,0.22), rgba(157,107,255,0.18), rgba(255,122,200,0.14));
  border: 1px solid var(--border-glow);
  box-shadow: 0 0 30px rgba(120, 140, 255, 0.18) inset, 0 8px 30px rgba(0,0,0,0.4);
  animation: fadeUp 0.5s ease both;
}
.section-banner .sec-icon { font-size: 2.2rem; display: block; margin-bottom: 6px; filter: drop-shadow(0 0 12px rgba(255,255,255,0.5)); }
.section-banner h2 { font-size: 1.35rem; letter-spacing: 2px; }
.section-banner p { color: var(--text-dim); font-size: 0.88rem; margin-top: 4px; }

/* ---------- 总结卡 ---------- */
.summary-card {
  border-left: 4px solid var(--gold);
  background: linear-gradient(135deg, rgba(255, 215, 107, 0.10), rgba(20,30,66,0.72));
  border-radius: 12px;
  padding: 14px 18px;
  animation: fadeUp 0.5s ease both;
}
.summary-card .sum-title { color: var(--gold); font-weight: 800; font-size: 0.92rem; margin-bottom: 4px; }
.summary-card .sum-title.with-speak { display: flex; align-items: center; gap: 8px; }
.summary-card .sum-text { font-size: 0.93rem; color: #f3ecd4; }

/* ---------- 表格 ---------- */
.pretty-table { width: 100%; border-collapse: separate; border-spacing: 0; overflow: hidden; border-radius: 12px; font-size: 0.92rem; }
.pretty-table th, .pretty-table td { padding: 10px 12px; text-align: left; vertical-align: top; }
.pretty-table thead th {
  background: linear-gradient(135deg, #2c4fa8, #4b3a9e);
  color: #fff; letter-spacing: 1px; font-size: 0.88rem;
}
.pretty-table tbody tr:nth-child(odd) { background: rgba(255,255,255,0.045); }
.pretty-table tbody tr:nth-child(even) { background: rgba(255,255,255,0.02); }
.pretty-table tbody tr:hover { background: rgba(120,160,255,0.12); }
.pretty-table td { border-top: 1px solid rgba(255,255,255,0.06); }

.table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid rgba(255,255,255,0.08); }

/* 对照表（错误 vs 正确） */
.compare-table td:first-child { color: #ffb3bc; }
.compare-table td:last-child { color: #a9f0cd; }
.compare-table thead th:first-child { background: linear-gradient(135deg, #8a2b3a, #5c1f2c); }
.compare-table thead th:last-child { background: linear-gradient(135deg, #1f7a4d, #155c39); }

/* ---------- 按钮与选择 ---------- */
.choice-group { display: flex; flex-direction: column; gap: 10px; }
.choice-btn {
  display: block; width: 100%; text-align: left;
  padding: 14px 18px; border-radius: 14px;
  border: 1px solid var(--border-glow);
  background: var(--glass-light);
  color: var(--text); font-size: 1rem; cursor: pointer;
  transition: all 0.22s;
  font-family: var(--font);
}
.choice-btn:hover:not(:disabled) {
  transform: translateX(6px) scale(1.01);
  border-color: #8fb0ff;
  box-shadow: 0 0 18px rgba(120, 160, 255, 0.4);
  background: linear-gradient(135deg, rgba(75,123,236,0.4), rgba(38,52,100,0.6));
}
.choice-btn:disabled { opacity: 0.45; cursor: default; }
.choice-btn.picked {
  border-color: var(--gold);
  background: linear-gradient(135deg, rgba(255,215,107,0.22), rgba(38,52,100,0.6));
  box-shadow: 0 0 16px rgba(255, 215, 107, 0.35);
}

.primary-btn {
  border: none; border-radius: 999px;
  padding: 12px 30px; font-size: 1rem; font-weight: 700;
  color: #101736; cursor: pointer;
  background: linear-gradient(135deg, #ffd76b, #ffb54d);
  box-shadow: 0 4px 18px rgba(255, 181, 77, 0.45);
  transition: all 0.2s;
  font-family: var(--font);
}
.primary-btn:hover:not(:disabled) { transform: translateY(-2px) scale(1.03); box-shadow: 0 6px 24px rgba(255, 181, 77, 0.65); }
.primary-btn:disabled { opacity: 0.5; cursor: default; }

.ghost-btn {
  border: 1px solid var(--border-glow); border-radius: 999px;
  background: rgba(255,255,255,0.05); color: var(--text);
  padding: 8px 18px; font-size: 0.88rem; cursor: pointer;
  transition: all 0.2s; font-family: var(--font);
}
.ghost-btn:hover:not(:disabled) { box-shadow: 0 0 12px rgba(120,160,255,0.4); }
.ghost-btn:disabled { opacity: 0.5; cursor: default; }

.center-row { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 10px; }

/* ---------- 底部导航 ---------- */
.nav-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 60;
  display: flex; justify-content: center; gap: 14px;
  padding: 14px;
  background: linear-gradient(to top, rgba(7,11,30,0.96), rgba(7,11,30,0.0));
}
.nav-btn {
  border-radius: 999px; padding: 13px 34px;
  font-size: 1rem; font-weight: 700; cursor: pointer;
  font-family: var(--font); transition: all 0.2s;
}
.nav-next {
  border: none; color: #101736;
  background: linear-gradient(135deg, #7ba0ff, #9d6bff);
  box-shadow: 0 4px 20px rgba(123, 160, 255, 0.5);
}
.nav-next:hover:not(:disabled) { transform: translateY(-2px) scale(1.04); }
.nav-next:disabled { opacity: 0.35; cursor: default; }
.nav-restart {
  border: 1px solid var(--border-glow);
  background: rgba(255,255,255,0.06); color: var(--text-dim);
}
.nav-restart:hover { color: var(--text); box-shadow: 0 0 12px rgba(120,160,255,0.35); }

/* ---------- 可视化：全景图 ---------- */
.pano-zone {
  border: 1px dashed rgba(255,255,255,0.18);
  border-radius: 12px; padding: 14px; margin: 10px 0;
  background: rgba(255,255,255,0.03);
}
.pano-zone h4 { font-size: 0.95rem; margin-bottom: 8px; }
.pano-flow { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: center; }
.pano-box {
  border: 1px solid var(--border-glow); border-radius: 10px;
  padding: 8px 12px; text-align: center;
  background: rgba(255,255,255,0.05);
  font-size: 0.9rem;
}
.pano-arrow { color: var(--gold); font-size: 1.2rem; }
.warn-banner {
  text-align: center; margin: 12px 0; padding: 10px;
  border-radius: 10px; font-weight: 800; letter-spacing: 1px;
  color: #ffb3bc;
  background: rgba(255, 107, 122, 0.10);
  border: 1px solid rgba(255, 107, 122, 0.45);
  animation: pulseGlow 2s ease-in-out infinite;
}
@keyframes pulseGlow { 0%,100% { box-shadow: 0 0 6px rgba(255,107,122,0.25);} 50% { box-shadow: 0 0 18px rgba(255,107,122,0.55);} }
.planet-row { display: flex; justify-content: space-around; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.planet-chip {
  text-align: center; padding: 10px 16px; border-radius: 14px;
  background: rgba(255,255,255,0.05); border: 1px solid var(--border-glow);
  min-width: 130px;
}
.planet-chip .pl-icon { font-size: 1.6rem; display: block; filter: drop-shadow(0 0 8px rgba(140,170,255,0.7)); }
.planet-chip .pl-name { font-weight: 700; font-size: 0.9rem; }
.planet-chip .pl-expr { font-size: 0.82rem; color: var(--text-dim); font-family: "Consolas", monospace; }

/* ---------- 可视化：糖果碗 ---------- */
.candy-stage { display: flex; flex-direction: column; gap: 16px; }
.candy-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 12px; border-radius: 12px;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
}
.candy-row .row-label { font-size: 0.85rem; color: var(--text-dim); width: 100%; margin-bottom: 2px; }
.candy-pile {
  border-radius: 10px; padding: 8px 12px;
  border: 1px solid var(--border-glow);
  background: rgba(91,140,255,0.12);
  text-align: center; min-width: 96px;
  transition: all 0.4s;
}
.candy-pile .emoji-line { font-size: 1.05rem; letter-spacing: 2px; }
.candy-pile .cnt { font-size: 0.8rem; color: var(--text-dim); }
.candy-bowl {
  margin-left: auto;
  border-radius: 14px; padding: 10px 18px; text-align: center;
  border: 2px solid var(--gold);
  background: radial-gradient(circle at 50% 20%, rgba(255,215,107,0.22), rgba(20,30,66,0.6));
  box-shadow: 0 0 18px rgba(255, 215, 107, 0.3);
  min-width: 130px;
}
.candy-bowl .bowl-emoji { font-size: 1.7rem; }
.candy-bowl .bowl-count { font-size: 1.25rem; font-weight: 800; color: var(--gold); font-variant-numeric: tabular-nums; }
.candy-bowl .bowl-sub { font-size: 0.75rem; color: var(--text-dim); }
.key-conclusion {
  margin-top: 6px; padding: 10px 14px; border-radius: 10px;
  background: rgba(57, 217, 138, 0.10);
  border: 1px solid rgba(57, 217, 138, 0.4);
  color: #b8f4d6; font-size: 0.92rem;
}
.math-expr { font-family: "Consolas", "Courier New", monospace; color: #cfe0ff; }

/* ---------- 可视化：椅子网格 ---------- */
.chair-toggle { display: flex; gap: 8px; justify-content: center; margin-bottom: 12px; flex-wrap: wrap; }
.toggle-btn {
  border: 1px solid var(--border-glow); border-radius: 999px;
  background: rgba(255,255,255,0.05); color: var(--text);
  padding: 6px 16px; cursor: pointer; font-size: 0.9rem;
  transition: all 0.2s; font-family: var(--font);
}
.toggle-btn.active {
  background: linear-gradient(135deg, #2c4fa8, #4b7bec);
  box-shadow: 0 0 12px rgba(120,160,255,0.5);
}
.chair-grid-wrap { display: flex; justify-content: center; }
.chair-grid { display: inline-grid; gap: 5px; padding: 14px; border-radius: 12px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.1); }
.chair-cell {
  width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
  font-size: 1.35rem; border-radius: 8px;
  background: rgba(91,140,255,0.10);
  border: 1px solid rgba(120,160,255,0.25);
  animation: popIn 0.3s ease both;
}
@keyframes popIn { from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.chair-count { text-align: center; margin-top: 10px; font-size: 1.05rem; }
.chair-count b { color: var(--gold); font-size: 1.3rem; font-variant-numeric: tabular-nums; }

/* ---------- 可视化：数轴 ---------- */
.numb-axis { width: 100%; }
.numb-block { margin: 8px 0 16px; }
.numb-block .nb-label { font-size: 0.9rem; margin-bottom: 4px; color: #cfe0ff; }
.numb-svg { width: 100%; height: auto; display: block; }

/* ---------- 错误 / 正确 对照面板 ---------- */
.err-panel { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.err-col { border-radius: 12px; padding: 14px; }
.err-col.wrong { background: rgba(255,107,122,0.08); border: 1px solid rgba(255,107,122,0.4); }
.err-col.right { background: rgba(57,217,138,0.08); border: 1px solid rgba(57,217,138,0.4); }
.err-col h4 { margin-bottom: 6px; font-size: 0.95rem; }
.err-col.wrong h4 { color: #ffb3bc; }
.err-col.right h4 { color: #a9f0cd; }
@media (max-width: 640px) { .err-panel { grid-template-columns: 1fr; } }

.verify-list { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.verify-item {
  display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  padding: 8px 12px; border-radius: 8px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.07);
  font-family: "Consolas", monospace; font-size: 0.9rem;
}
.verify-item .v-ok { color: var(--ok); font-weight: 700; }
.verify-item .v-no { color: var(--bad); font-weight: 700; }

.candy-groups { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.candy-group-line {
  padding: 8px 12px; border-radius: 8px;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.07);
}
.candy-group-line .g-emoji { letter-spacing: 3px; font-size: 1rem; }
.candy-group-line .g-calc { font-size: 0.82rem; color: var(--text-dim); }

/* ---------- 五步法流程条 ---------- */
.steps-flow { display: flex; gap: 8px; flex-wrap: wrap; align-items: stretch; }
.step-node {
  flex: 1 1 150px; min-width: 140px;
  border-radius: 12px; padding: 12px;
  background: linear-gradient(160deg, rgba(75,123,236,0.25), rgba(20,30,66,0.7));
  border: 1px solid var(--border-glow);
  position: relative;
}
.step-node .s-num {
  display: inline-flex; width: 26px; height: 26px; border-radius: 50%;
  align-items: center; justify-content: center;
  background: linear-gradient(135deg, #ffd76b, #ffb54d);
  color: #101736; font-weight: 800; font-size: 0.85rem;
  margin-bottom: 6px;
}
.step-node .s-name { font-weight: 800; margin-bottom: 2px; }
.step-node .s-desc { font-size: 0.82rem; color: var(--text-dim); }

/* ---------- 时间线 ---------- */
.timeline { position: relative; padding-left: 26px; }
.timeline::before {
  content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px;
  width: 3px; border-radius: 3px;
  background: linear-gradient(180deg, #5b8cff, #9d6bff, #ff7ac8, #ffd76b);
  box-shadow: 0 0 10px rgba(157,107,255,0.6);
}
.tl-item { position: relative; margin-bottom: 16px; }
.tl-item::before {
  content: ""; position: absolute; left: -24px; top: 6px;
  width: 13px; height: 13px; border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 10px rgba(255, 215, 107, 0.8);
}
.tl-item .tl-stage { font-weight: 800; color: #ffd09b; }
.tl-item .tl-body { font-size: 0.9rem; color: var(--text); }
.tl-item .tl-tag { font-size: 0.78rem; color: var(--text-dim); }

/* ---------- 三级求助 ---------- */
.help-level { margin-bottom: 10px; }
.help-head {
  width: 100%; text-align: left; cursor: pointer;
  border: 1px solid var(--border-glow); border-radius: 12px;
  background: var(--glass-light); color: var(--text);
  padding: 12px 16px; font-size: 0.95rem; font-weight: 700;
  display: flex; align-items: center; gap: 10px;
  transition: all 0.2s; font-family: var(--font);
}
.help-head:hover:not(:disabled) { box-shadow: 0 0 12px rgba(120,160,255,0.4); }
.help-head:disabled { opacity: 0.55; cursor: default; }
.help-body {
  margin-top: 6px; padding: 12px 16px; border-radius: 10px;
  background: rgba(255,255,255,0.04);
  border-left: 3px solid var(--gold);
  animation: fadeUp 0.35s ease both;
  font-size: 0.92rem;
}
.mantra-box {
  margin-top: 12px; text-align: center; padding: 14px;
  border-radius: 12px; font-weight: 800; letter-spacing: 1px;
  background: linear-gradient(135deg, rgba(255,215,107,0.15), rgba(157,107,255,0.15));
  border: 1px solid rgba(255, 215, 107, 0.4);
  color: var(--gold);
}

/* ---------- 挑战卡 ---------- */
.challenge-card { border: 1px solid rgba(157,107,255,0.45); }
.challenge-card .card-title { color: #cbb2ff; }
.hint-box {
  margin-top: 10px; padding: 12px 14px; border-radius: 10px;
  background: rgba(157, 107, 255, 0.10);
  border: 1px dashed rgba(157, 107, 255, 0.5);
  font-size: 0.9rem;
  animation: fadeUp 0.35s ease both;
}

/* ---------- 输入卡 ---------- */
.input-row { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 8px; }
.text-input {
  flex: 1 1 240px;
  border-radius: 12px; border: 1px solid var(--border-glow);
  background: rgba(255,255,255,0.06); color: var(--text);
  padding: 12px 16px; font-size: 0.95rem; font-family: var(--font);
  outline: none; min-height: 48px; resize: vertical;
}
.text-input:focus { border-color: #8fb0ff; box-shadow: 0 0 12px rgba(120,160,255,0.4); }
.saved-note { margin-top: 8px; font-size: 0.85rem; color: var(--ok); }
.saved-show {
  margin-top: 10px; padding: 12px 14px; border-radius: 10px;
  background: rgba(57,217,138,0.08); border: 1px solid rgba(57,217,138,0.35);
  font-size: 0.92rem; white-space: pre-wrap;
}

/* ---------- 模型卡 / 战报 / 金句 ---------- */
.model-rule {
  padding: 12px 14px; border-radius: 12px; margin-bottom: 10px;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.09);
}
.model-rule .mr-title { font-weight: 800; color: #cfe0ff; }
.model-rule .mr-formula { font-family: "Consolas", monospace; color: var(--gold); font-size: 1.05rem; margin: 2px 0; }
.model-rule .mr-life { font-size: 0.85rem; color: var(--text-dim); }

.report-item {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 10px 12px; border-radius: 10px; margin-bottom: 8px;
  background: rgba(57,217,138,0.07); border: 1px solid rgba(57,217,138,0.3);
}
.report-item .r-check { color: var(--ok); font-size: 1.1rem; }
.badge-hero {
  text-align: center; margin-top: 14px; padding: 18px;
  border-radius: 16px;
  background: radial-gradient(circle at 50% 0%, rgba(255,215,107,0.3), rgba(20,30,66,0.6));
  border: 2px solid var(--gold);
  box-shadow: 0 0 26px rgba(255, 215, 107, 0.4);
  animation: pulseGlow 2.4s ease-in-out infinite;
}
.badge-hero .b-icon { font-size: 2.6rem; display: block; filter: drop-shadow(0 0 14px rgba(255,215,107,0.9)); }
.badge-hero .b-title { font-size: 1.25rem; font-weight: 900; color: var(--gold); letter-spacing: 2px; }

.quote-item {
  padding: 14px 16px; border-radius: 12px; margin-bottom: 10px;
  background: linear-gradient(135deg, rgba(91,140,255,0.14), rgba(157,107,255,0.10));
  border: 1px solid var(--border-glow);
}
.quote-item .q-main { font-weight: 800; margin-bottom: 2px; }
.quote-item .q-formula { font-family: "Consolas", monospace; color: var(--gold); font-size: 0.92rem; }

/* ---------- 签约徽章 ---------- */
.contract-badge {
  display: none;
  text-align: center; margin-top: 14px; padding: 18px;
  border-radius: 16px;
  background: radial-gradient(circle at 50% 0%, rgba(91,140,255,0.3), rgba(20,30,66,0.6));
  border: 2px solid #7ba0ff;
}
.contract-badge.show { display: block; animation: badgeIn 0.8s cubic-bezier(0.2, 1.6, 0.4, 1) both; }
@keyframes badgeIn { from { transform: scale(0) rotate(-30deg); opacity: 0; } to { transform: scale(1) rotate(0); opacity: 1; } }
.contract-badge .cb-icon { font-size: 3rem; display: block; filter: drop-shadow(0 0 16px rgba(123,160,255,0.9)); }
.contract-badge .cb-title { font-weight: 900; letter-spacing: 2px; color: #9dbcff; }

/* ---------- 星空夜话轨道 ---------- */
.orbit-lock {
  text-align: center; padding: 16px; border-radius: 14px;
  border: 1px dashed rgba(255, 215, 107, 0.5);
  background: rgba(255, 215, 107, 0.05);
  color: var(--gold); cursor: pointer;
  transition: all 0.2s;
}
.orbit-lock:hover { box-shadow: 0 0 16px rgba(255,215,107,0.35); }
.orbit-body { animation: fadeUp 0.5s ease both; }
.scene-card { margin: 12px 0; }
.diff { color: var(--gold); font-size: 0.8rem; letter-spacing: 2px; }

/* ---------- 自评表 ---------- */
.eval-check { cursor: pointer; width: 20px; height: 20px; accent-color: #39d98a; }

/* ---------- 通用工具 ---------- */
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; }
.dim { color: var(--text-dim); font-size: 0.85rem; }
.hidden { display: none !important; }

@media (max-width: 720px) {
  .bubble { max-width: 88%; }
  .brand-text h1 { font-size: 1rem; }
  .chair-cell { width: 32px; height: 32px; font-size: 1.1rem; }
  .nav-btn { padding: 12px 22px; font-size: 0.92rem; }
}
