/* 学生端日夜外观；颜色变化不参与计时、作答或提交。 */
:root { color-scheme: dark; }
:root[data-student-theme="light"] {
  color-scheme: light;
  --bg: #f3f5fa;
  --surface: #ffffff;
  --card: #f0f2f9;
  --border: #d7dcec;
  --text: #252d3e;
  --muted: #5d687d;
  --accent: #6250c6;
  --accent-light: #6552bc;
  --green: #08795f;
  --gold: #866109;
  --red: #b53743;
  --blue: #216cac;
}
.student-theme-panel { margin-top: 20px; width: 100%; }
.student-theme-controls { display: flex; gap: 6px; width: 100%; }
.student-theme-controls button {
  flex: 1;
  min-width: 0;
  min-height: 44px;
  padding: 9px 7px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.student-theme-controls button[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.student-theme-controls button:focus-visible {
  outline: 2px solid var(--accent-light);
  outline-offset: 3px;
}
.student-theme-status {
  min-height: 20px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}
.top-bar button[aria-label="设置"] { min-width: 44px; min-height: 44px; }
.alumni-page > .student-theme-panel { margin: 0 0 16px; }

/* 实心按钮与选中状态保留明确的文字对比。普通内容中的白字由兼容层转换。 */
:root[data-student-theme="light"] :is(
  .login-btn, .login-attempt-card button, .rank-toggle button.active,
  .arena-subtabs button.active, .arena-open-btn, .arena-hall-card button,
  .arena-board-tabs button.active, .feedback-submit-btn, .buddy-btn.primary,
  .vocab-primary-btn, .vocab-choice-btn.checking, .vocab-question-action-btn.checking,
  .reading-mode-tabs button.active, .sim-btn, .guide-btn,
  .spend-option button, .shop-tabs button.active, .shop-item button,
  .streak-makeup-panel button, .exam-review-submit-action,
  .ccs-primary, .ccs-reveal, .cct-primary, .cs-primary, .cs-entry-action.is-primary,
  .cs-history-modes button[aria-pressed="true"], .cps-shell button.cps-primary,
  .cps-term-nav > button.is-active, .cps-shell .cps-switch-activity,
  .cps-shell .cps-choice-options button.is-selected,
  .cps-shell .cps-answer-issue-btn.is-active, .cps-shell .cps-answer-issue-btn:hover,
  .cps-shell .cps-answer-issue-types button.is-selected
) { background: var(--accent); color: #fff; }
:root[data-student-theme="light"] :is(
  .vocab-choice-btn.correct, .vocab-question-action-btn.correct
) { background: var(--green); color: #fff; }
:root[data-student-theme="light"] :is(
  .vocab-choice-btn.wrong, .vocab-question-action-btn.wrong,
  .nav-badge, .feedback-reply-dot, .feedback-remove-image, .exam-review-upload-remove
) { background: var(--red); color: #fff; }
:root[data-student-theme="light"] :is(
  .para-num, .word-span.reading-current, .word-phonetic .wp-eudic, .tier-tag.current
) { background: var(--accent); color: #fff; }
:root[data-student-theme="light"] .reading-mode-tabs button.active .arena-tab-help { color: #fff; }
:root[data-student-theme="light"] .cs-segment.is-selected span,
:root[data-student-theme="light"] .cs-segment:has(input:checked) span { color: var(--text); }
:root[data-student-theme="light"] .cps-detail > header {
  background: linear-gradient(135deg, #e6f4ee, #eaf2fb);
  color: var(--text);
}
:root[data-student-theme="light"] .cps-detail > header :is(span, p) { color: var(--muted); }

/* 少量旧入口直接写了实心按钮颜色，内联声明需要明确保留白字。 */
:root[data-student-theme="light"] :is(
  #placementBtn, #arenaOfficialBtn, #essaySubmitLink,
  #singleStudentTabBlocker button[onclick="retrySingleStudentTabGuard()"],
  button[onclick^="respondArenaChallenge("][onclick*="accept"]
) { color: #fff !important; }

:root[data-student-theme="dark"] :is(
  .cps-shell button.cps-primary, .cps-term-nav > button.is-active,
  .cps-shell .cps-switch-activity, .cps-shell .cps-choice-options button.is-selected,
  .cps-shell .cps-answer-issue-btn.is-active, .cps-shell .cps-answer-issue-btn:hover,
  .cps-shell .cps-answer-issue-types button.is-selected
) { background: #167153; color: #fff; border-color: #3f9477; }
