/* 小知汪：奶油白底、雾蓝、淡紫和星星黄。放在现有组件样式之后。 */
:root {
  --bg-deep: #f8f9fb;
  --bg-mid: #eef3f9;
  --text: #34445f;
  --text-dim: #69778d;
  --panel: #ffffff;
  --line: #dce4ee;
  --gold: #657fa9;
  --accent-a: #95add0;
  --accent-b: #d9e3f2;
  --glow: rgba(116, 142, 183, .13);
  --radius: 20px;
  --display: "Noto Sans SC", sans-serif;
}
body, body[data-stage="primary"], body[data-stage="junior"], body[data-stage="senior"] {
  --accent-a: #95add0;
  --accent-b: #d9e3f2;
  --glow: rgba(116, 142, 183, .13);
  background: #f8f9fb;
  color: var(--text);
}
body { line-height: 1.55; }
.backdrop { background: radial-gradient(circle at 92% 4%, #edf2fa 0, transparent 32%), radial-gradient(circle at 4% 80%, #f9f2eb 0, transparent 34%), #f8f9fb; }
.aurora, .stars, .orb, .vignette, .symbols { display: none; }
.shell { width: min(1140px, calc(100% - 40px)); padding: 24px 0 130px; }
.topbar { margin-bottom: 38px; padding: 8px 4px 16px; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; box-shadow: none; backdrop-filter: none; }
.brand { gap: 11px; }
.logo { width: 48px; height: 48px; flex: none; overflow: hidden; border: 1px solid #e5e8ef; border-radius: 50%; background: #fff; box-shadow: 0 3px 12px #9aabc22b; }
.logo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 27%; transform: scale(1.4); }
.brand h1 { font-family: var(--display); font-size: 20px; font-weight: 700; letter-spacing: .02em; color: #617da6; }
.brand p { margin-top: 0; font-size: 11px; color: var(--text-dim); }
.badge { padding: 8px 13px; border: 1px solid var(--line); background: #fff; color: #5f779d; font-size: 12px; font-weight: 700; }
.badge:hover { border-color: #a7b9d5; background: #f1f5fb; }
.hero { text-align: left; }
.hero h2 { font-family: var(--display); color: var(--text); background: none; filter: none; letter-spacing: 0; }
.hero p { max-width: none; margin: 0; color: var(--text-dim); }
.hero-chip, .section-kicker { border: 0; background: none; color: #718bb3; letter-spacing: .08em; font-weight: 700; }
.pet-welcome { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(270px, .8fr); align-items: center; gap: 22px; min-height: 330px; padding: 36px 46px; border: 1px solid #e5e9f0; border-radius: 26px; background: linear-gradient(115deg, #fff 10%, #f7f8fc 66%, #f1f3fa); overflow: hidden; }
.pet-welcome-copy { position: relative; z-index: 1; }
.pet-welcome .hero-chip { padding: 0; margin-bottom: 12px; }
.pet-welcome h2 { max-width: 10em; font-size: clamp(32px, 4vw, 48px); line-height: 1.25; }
.pet-welcome p { max-width: 30em; line-height: 1.8; }
.pet-welcome img { display: block; justify-self: center; align-self: end; width: min(88%, 270px); height: 295px; object-fit: cover; object-position: center 25%; border-radius: 140px 140px 18px 18px; mix-blend-mode: multiply; }
.pet-welcome-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; margin-top: 23px; }
.pet-welcome-actions button { min-height: 44px; padding: 0 18px; border: 0; border-radius: 12px; background: #56749f; color: white; font: 700 14px var(--display); cursor: pointer; }
.pet-welcome-actions button:hover { background: #617eaa; }
.pet-welcome-actions span { color: #8390a5; font-size: 12px; }
.stage-grid { gap: 14px; margin: 26px 0 48px; }
.stage-card, .grade-card, .placeholder { border: 1px solid var(--line); background: #fff; box-shadow: 0 4px 16px #8ba0bb0b; }
.stage-card { border-radius: 18px; font: inherit; }
.stage-card[data-stage="primary"] { --card-a: #a4b9da; --card-b: #e9eff8; }
.stage-card[data-stage="junior"] { --card-a: #b8b8dd; --card-b: #f0edf9; }
.stage-card[data-stage="senior"] { --card-a: #e3c8ae; --card-b: #faf2e8; }
.stage-card:hover, .stage-card.is-active, .grade-card:hover { transform: translateY(-3px); border-color: #a8b9d3; box-shadow: 0 10px 22px #849cbb1c; }
.stage-art, .frame-corner, .category-art { display: none; }
.stage-body { padding: 24px; }
.stage-icon { position: static; margin: 0 0 15px; width: 42px; height: 42px; border-radius: 12px; background: var(--card-b); box-shadow: none; color: #728aaf; font-size: 22px; }
.stage-card h3 { font-family: var(--display); font-size: 20px; letter-spacing: 0; }
.stage-card p { color: var(--text-dim); font-size: 13px; margin-bottom: 14px; }
.stage-meta { border: 0; background: #f3f6fb; color: #7085a7; }
.section-head { align-items: center; margin-bottom: 18px; }
.section-head h2 { font-family: var(--display); font-size: 27px; letter-spacing: 0; }
.section-head p { color: var(--text-dim); }
.grade-grid { gap: 14px; }
.grade-card { min-height: 185px; padding: 22px; border-radius: 18px; transition: transform .2s, box-shadow .2s, border-color .2s; }
.grade-card::before { display: none; }
.grade-index { width: 40px; height: 40px; margin-bottom: 16px; border: 0; border-radius: 11px; background: #edf2fa; box-shadow: none; color: #6682aa; font-size: 14px; }
.grade-card h3 { font-family: var(--display); font-size: 21px; letter-spacing: 0; }
.grade-card p { font-size: 13px; line-height: 1.65; }
.enter, .primary-link { min-height: 40px; border: 1px solid #dce5f0; border-radius: 11px; background: #eef3fa; box-shadow: none; color: #637fa9; font-size: 13px; letter-spacing: 0; }
.enter { margin-top: 20px; align-self: flex-start; }
.catalog-trail { margin: -8px 0 26px; color: var(--text-dim); }
.catalog-trail a { color: #6c83a7; }
.catalog-trail a:hover, .catalog-trail [aria-current="page"] { color: #4f6e9c; }
.book-card { min-height: 230px; }
.edition { border-color: #dce5f0; background: #f0f4fa; color: #6984ac; }
.category-card { padding: 22px; }
.category-card h3, .category-card p, .category-card .enter { margin-left: 0; margin-right: 0; }
.category-order { margin: 0 0 14px; color: #8b83ac; }
.category-card .enter { margin-top: 22px; }
.unit-empty { background: #fff; }
.placeholder { margin-top: 36px; border-radius: 20px; }
.mark-ring { border-color: #b7c8e0; }
.mark { background: #e9eff8; box-shadow: none; color: #6a83aa; }
.placeholder .crumb { color: #7089b0; }
.placeholder h2 { font-family: var(--display); font-size: 35px; letter-spacing: 0; }
.lesson-picker button, .shade-picks button, .circ-group button, .circ-btn, .circ-paths button, .area-steps button, .area-btn, .area-seg button { background: #fff; color: var(--text); }
.lesson-picker button[aria-selected="true"], .shade-picks button[aria-selected="true"], .circ-group button[aria-pressed="true"], .circ-paths button[aria-pressed="true"], .area-steps button.is-current, .area-btn-primary, .area-seg button.is-current { border-color: #a4b9d8; background: #e9eff9; box-shadow: none; color: #42638d; }
.area-steps button.is-current span { background: #8da8cd; color: #fff; }
.circ-head h2, .area-head h2 { font-family: var(--display); font-size: 34px; letter-spacing: 0; }
.circ-stage, .circ-reason, .circ-table-wrap, .area-stage, .area-insight, .area-formula { border-color: var(--line); background: #fff; box-shadow: none; }
.hot-card { border-color: #dce6f0; background: #f5f8fc; }
.hot-card h4, .hot-card #hotNote { color: var(--text); }
.hot-card p:first-child, .area-step-no { color: #6e86ad; }
.hot-value, .area-formula strong { color: #536f9d; }
.area-insight h3 { font-family: var(--display); letter-spacing: 0; }
.area-insight p, .area-head p:last-child, .circ-head p:last-child { color: var(--text-dim); }
.area-stage .disk { fill: #d8e4f6; }
.area-stage text, .area-stage .center-label { fill: #526d98; }
.area-stage .dim-label rect { fill: #f5f8fc; stroke: #8ea9ce; }
.area-stage .dim-label.is-on rect { fill: #cbd9ee; }
.area-stage .dim-label.is-on text { fill: #344b6e; }
.lc-game { --lc-mint: #607fa9; --lc-muted: #6f7d91; --lc-border: #dce4ef; --lc-panel: #fff; }
.lc-hero, .lc-question-card, .lc-help, .lc-result, .lc-review-item, .lc-level, .kp-question-card, .kp-review-item { border-color: var(--lc-border); background: #fff; box-shadow: 0 4px 18px #8399b00d; }
.lc-hero { background: linear-gradient(115deg, #fff, #f3f6fb); }
.lc-hero h2 span, .lc-result-score { color: #6984ad; }
.lc-tags span { color: #5e718d; background: #fff; }
.lc-btn { background: #fff; color: var(--text); }
.lc-btn:hover:not(:disabled) { background: #f0f4fa; }
.lc-btn.lc-primary { border-color: #56749f; background: #56749f; color: #fff; box-shadow: none; }
.lc-btn.lc-primary:hover:not(:disabled) { background: #6f8db7; }
.lc-unit-orbit b, .lc-mixed-orbits b, .lc-ladder b { border-color: #d7e2f1; background: #edf3fa; color: #52709e; }
.lc-level.is-recommended { border-color: #97afd0; background: #eff4fb; }
.lc-level.is-locked { background: #f5f6f8; }
.lc-level.is-locked .lc-level-number, .lc-level.is-locked .lc-level-footer, .lc-level.is-locked > strong { color: #8895a8; }
.lc-level-badge { background: #f1f4f8; }
.lc-level-footer { border-color: #e7ecf3; }
.lc-progress, .lc-progress::-webkit-progress-bar { background: #e8edf4; }
.lc-dot { box-shadow: none; }
.lc-stars { color: #d8deea; }
.lc-stars .is-earned { color: #d9ae63; }
.lc-option { background: #fff; border-color: #d7e0ec; }
.lc-option:hover:not(:disabled) { background: #f5f8fc; }
.lc-option-letter { background: #eff3f9; color: #60789e; }
.lc-option.is-correct { background: #e9f6ef; color: #2d704b; border-color: #9bcdb2; }
.lc-option.is-wrong { background: #fff0ef; color: #a45253; border-color: #dfb5b3; }
.lc-blank, .op-blank { border-color: #9aafd0; color: #5978a5; background: #f5f8fd; }
.lc-feedback { background: #f5f7fb; color: #66758b; }
.lc-feedback strong { color: #4f779f; }
.lc-feedback p, .lc-review-item > p:not(.lc-kicker), .op-step { color: #53647f; }
.lc-feedback.is-wrong strong, .lc-review-item > p.lc-your-answer { color: #a6555c; }
.lc-perfect-note { background: #eef5fc; }
.op-hero-art { color: #8ea5c7; }
.op-hero-art strong { color: #6d83a7; border-color: #b9cce4; box-shadow: none; }
.op-answer-field input { background: #fff; color: var(--text); border-color: #b7c9e1; }
.op-answer-field input:focus { border-color: #748fb9; box-shadow: 0 0 0 3px #cddbf0; }
.op-submitted { border-color: #b7c9e1; }
.kp-hero, .kp-question-card, .kp-review-item { border-color: var(--lc-border); }
.kp-hero-count { background: #edf3fa; border-color: #bbcae0; color: #5e79a2; }
.kp-choice { background: #fff; color: var(--text); border-color: #d8e2ed; }
.kp-choice:hover, .kp-choice.is-selected { background: #edf3fa; color: #46658e; border-color: #93abc9; }
.kp-choice > span { background: #dfe9f6; color: #53709a; }
.knowledge-topics .category-card { border-color: var(--line); background: #fff; }
.knowledge-topics .category-card .enter { color: #6480aa; }
.pet-companion { position: fixed; right: max(22px, env(safe-area-inset-right)); bottom: max(20px, env(safe-area-inset-bottom)); z-index: 120; font-family: var(--display); }
.pet-toggle { display: flex; align-items: center; gap: 10px; padding: 4px 16px 4px 4px; border: 1px solid #d6e0ed; border-radius: 999px; background: #fff; box-shadow: 0 8px 28px #7089ae2a; color: #49688f; font: 700 13px var(--display); cursor: pointer; }
.pet-toggle img { display: block; width: 54px; height: 54px; object-fit: cover; object-position: center 30%; border-radius: 50%; }
.pet-toggle b { color: #d5ad68; }
.pet-toggle:hover { transform: translateY(-2px); box-shadow: 0 12px 32px #7089ae36; }
.pet-chat { position: absolute; right: 0; bottom: 76px; width: min(360px, calc(100vw - 30px)); max-height: min(550px, calc(100dvh - 112px)); display: flex; flex-direction: column; border: 1px solid #d9e2ef; border-radius: 20px; overflow: hidden; background: #fff; box-shadow: 0 18px 50px #7188a63b; }
.pet-chat[hidden] { display: none; }
.pet-chat-head { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-bottom: 1px solid #e7edf4; background: #f7f9fc; }
.pet-chat-avatar { display: block; width: 44px; height: 44px; border-radius: 50%; overflow: hidden; background: white; }
.pet-chat-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 27%; transform: scale(1.4); }
.pet-chat-head strong, .pet-chat-head small { display: block; }
.pet-chat-head strong { font-size: 14px; }
.pet-chat-head small { color: #8290a3; font-size: 11px; }
.pet-chat-close { margin-left: auto; width: 30px; height: 30px; border: 0; border-radius: 8px; background: transparent; color: #7586a2; font-size: 23px; cursor: pointer; }
.pet-chat-close:hover { background: #e9eef6; }
.pet-chat-messages { display: flex; flex-direction: column; align-items: flex-start; gap: 9px; min-height: 140px; max-height: 260px; padding: 16px; overflow-y: auto; }
.pet-message { max-width: 88%; margin: 0; padding: 10px 12px; border-radius: 13px 13px 13px 4px; background: #f0f4fa; color: #455d80; font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
.pet-message.is-user { align-self: flex-end; border-radius: 13px 13px 4px 13px; background: #56749f; color: #fff; }
.pet-topics { display: flex; flex-wrap: wrap; gap: 7px; padding: 0 14px 12px; }
.pet-topics button { padding: 6px 9px; border: 1px solid #dce5f0; border-radius: 999px; background: #fff; color: #627da5; font: 12px var(--display); cursor: pointer; }
.pet-topics button:hover { background: #f1f5fa; }
.pet-chat-form { display: flex; gap: 7px; padding: 12px 14px 6px; border-top: 1px solid #ebeff5; }
.pet-chat-form input { min-width: 0; flex: 1; min-height: 40px; padding: 8px 10px; border: 1px solid #d7e1ee; border-radius: 10px; outline: none; background: #fff; color: var(--text); font: 13px var(--display); }
.pet-chat-form input:focus { border-color: #849fc4; box-shadow: 0 0 0 2px #dfe8f5; }
.pet-chat-form button { padding: 0 13px; border: 0; border-radius: 10px; background: #56749f; color: #fff; font: 700 12px var(--display); cursor: pointer; }
.pet-chat-disclosure { margin: 2px 14px 10px; color: #94a0b0; font-size: 10px; }
.pet-companion button:focus-visible, .pet-welcome button:focus-visible, .stage-card:focus-visible, .grade-card:focus-visible, .badge:focus-visible { outline: 3px solid #9db4d7; outline-offset: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
@media (max-width: 760px) {
  .pet-welcome { grid-template-columns: 1fr 200px; padding: 26px; min-height: 250px; }
  .pet-welcome img { width: 200px; height: 230px; }
}
@media (max-width: 560px) {
  .shell { width: min(100% - 28px, 1140px); padding-top: 14px; }
  .topbar { margin-bottom: 24px; }
  .brand h1 { font-size: 16px; }
  .brand p { font-size: 10px; }
  .logo { width: 40px; height: 40px; }
  .badge { padding: 7px 10px; white-space: nowrap; font-size: 11px; }
  .pet-welcome { display: flex; flex-direction: column-reverse; gap: 6px; padding: 18px 22px 26px; align-items: stretch; }
  .pet-welcome img { align-self: center; width: 175px; height: 190px; border-radius: 90px 90px 12px 12px; }
  .pet-welcome h2 { font-size: 31px; }
  .section-head h2 { font-size: 24px; white-space: normal; }
  .stage-grid { margin: 16px 0 38px; }
  .grade-card { min-height: 160px; }
  .pet-companion { right: 14px; bottom: 14px; }
  .pet-toggle { padding-right: 8px; }
  .pet-toggle img { width: 48px; height: 48px; }
  .pet-toggle span { max-width: 0; opacity: 0; overflow: hidden; white-space: nowrap; }
  .pet-chat { bottom: 66px; max-height: calc(100dvh - 96px); }
}
@media (prefers-reduced-motion: reduce) { .pet-toggle, .stage-card, .grade-card { transition: none; } }
/* 教学演示的图形也采用同一组低饱和度颜色。 */
.circ-stats div { background: #f8fafd; border-color: var(--line); }
.circ-btn-primary { border-color: #a4b9d8; background: #e9eff9; color: #42638d; box-shadow: none; }
.circ-btn-primary:disabled { color: #6d86aa; }
.circ-table th, .circ-table td { border-color: #e4eaf2; }
.circ-table tr.is-ready th, .circ-table tr.is-ready td { color: #5374a4; }
.circ-card { border-color: #e6e2df; background: #fcf9f5; }
.circ-formula { color: #526d9a; }
#circDisk { fill: #cfdbed; stroke: #7994ba; }
#circRim line { stroke: #8ca4c5; }
#circTrace { stroke: #d19caa; }
#circOrigin, #circMarker { fill: #d8b573; }
#circRadiusLine { stroke: #6f91bd; }
#circLive { fill: #58759f; }
.circ-stage .radius-label { fill: #fff; stroke: #506d98; }
.area-stage .ring { stroke: #7895bc; }
.area-stage .guide-line, .area-stage .dim-line, .area-stage .dim-tick { stroke: #7895bc; }
.area-stage .shape-outline { stroke: #7895bc; }
.area-stage .slice.is-hot, .area-stage #refRed.is-hot, .area-stage #refBlue.is-hot { stroke: #637fa9; }
.shade-lesson .shade { fill: #b8cbea; stroke: #fff; }
.shade-lesson .board { fill: #edf3fa; stroke: #8da5c5; }
.shade-lesson .paper { fill: #fff; stroke: #9fb3cf; }
.shade-lesson .ink { stroke: #6784ab; }
.shade-lesson .ghost { stroke: #a5b6cf; }
.shade-lesson .label { fill: #536f9a; }
