:root {
  --theme-page-light: #f2f3f7;
  --theme-surface-light: #ffffff;
  --theme-surface-soft-light: #f8f9fc;
  --theme-surface-muted-light: #eef1f5;
  --theme-line-light: #d9dfe8;
  --theme-line-soft-light: #e8ecf2;
  --theme-text-light: #1a1a2e;
  --theme-muted-light: #687386;
  --theme-muted-2-light: #98a2b3;
  --theme-red-light: #e33b3b;
  --theme-red-soft-light: #fff0f0;
  --theme-green-light: #0f9568;
  --theme-green-soft-light: #eaf8f3;
  --theme-amber-light: #d87809;
  --theme-amber-soft-light: #fff6e8;
  --theme-blue-light: #3b72c4;
  --theme-blue-soft-light: #edf4ff;
}

.theme-switcher {
  min-width: max-content;
  height: 32px;
  display: inline-grid;
  grid-template-columns: auto auto auto;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--line, #273342);
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted, #93a3b5);
  font-size: 12px;
  line-height: 1;
}

.theme-switcher-label {
  padding: 0 7px 0 5px;
  font-weight: 700;
}

.theme-switcher button {
  min-width: 42px;
  height: 24px;
  margin: 0;
  padding: 0 8px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.theme-switcher button:hover {
  color: var(--text, #eef4fb);
  background: rgba(255, 255, 255, 0.07);
}

.theme-switcher button.active {
  color: #fff;
  background: var(--red, #ff514d);
  box-shadow: 0 2px 8px rgba(227, 59, 59, 0.22);
}

.app-header {
  grid-template-columns: auto minmax(360px, 1fr) auto auto;
}

body > .topbar,
.app-shell > .topbar {
  grid-template-columns: auto minmax(360px, 1fr) auto auto;
}

.topbar .theme-switcher {
  margin-left: auto;
}

.topbar .theme-switcher + .top-status,
.topbar .theme-switcher + .status,
.topbar .theme-switcher + .topbar-note {
  margin-left: 0;
}

html[data-theme="light"] {
  color-scheme: light;
  --bg: var(--theme-page-light);
  --bg-soft: #eceff4;
  --bar: var(--theme-surface-light);
  --surface: var(--theme-surface-light);
  --surface-2: var(--theme-surface-soft-light);
  --surface-3: var(--theme-surface-muted-light);
  --panel: var(--theme-surface-light);
  --panel-2: var(--theme-surface-soft-light);
  --panel-3: var(--theme-surface-muted-light);
  --line: var(--theme-line-light);
  --line-soft: var(--theme-line-soft-light);
  --text: var(--theme-text-light);
  --muted: var(--theme-muted-light);
  --muted-2: var(--theme-muted-2-light);
  --red: var(--theme-red-light);
  --red-soft: var(--theme-red-soft-light);
  --red-bg: #ffe8e8;
  --green: var(--theme-green-light);
  --green-soft: var(--theme-green-soft-light);
  --green-bg: #dff5ed;
  --amber: var(--theme-amber-light);
  --amber-soft: var(--theme-amber-soft-light);
  --amber-bg: #ffedcf;
  --blue: var(--theme-blue-light);
  --blue-soft: var(--theme-blue-soft-light);
  --cyan: #168a9b;
  --shadow: 0 10px 26px rgba(33, 43, 54, 0.08);
}

html[data-theme="light"] body {
  color: var(--text);
  background: var(--bg) !important;
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}

html[data-theme="light"] .event-page,
html[data-theme="light"] .home-page,
html[data-theme="light"] .detail-page,
html[data-theme="light"] .app-shell,
html[data-theme="light"] .page {
  background: var(--bg);
}

html[data-theme="light"] .app-header,
html[data-theme="light"] .topbar {
  background: #fff !important;
  border-color: var(--line) !important;
  box-shadow: 0 1px 0 rgba(28, 39, 49, 0.03);
}

html[data-theme="light"] .brand-mark {
  border-color: rgba(227, 59, 59, 0.38) !important;
  background: linear-gradient(145deg, #fff0f0, #f8fbff) !important;
}

html[data-theme="light"] .header-nav a,
html[data-theme="light"] .topnav a,
html[data-theme="light"] .nav button {
  color: #536174;
}

html[data-theme="light"] .nav button {
  border-color: var(--line) !important;
  background: #f7f8fa !important;
}

html[data-theme="light"] .header-nav a:hover,
html[data-theme="light"] .header-nav a.active,
html[data-theme="light"] .topnav a:hover,
html[data-theme="light"] .topnav a.active,
html[data-theme="light"] .nav button:hover,
html[data-theme="light"] .nav button.active {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .theme-switcher {
  border-color: #d7dde6;
  background: #f4f6f9;
  color: #667386;
}

html[data-theme="light"] .theme-switcher button:hover {
  color: var(--text);
  background: #e7ebf1;
}

html[data-theme="light"] .theme-switcher button.active {
  color: #fff;
  background: var(--red);
}

html[data-theme="light"] button,
html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea {
  color: var(--text);
  border-color: var(--line);
}

html[data-theme="light"] input,
html[data-theme="light"] select,
html[data-theme="light"] textarea {
  background: #fff !important;
}

html[data-theme="light"] option,
html[data-theme="light"] optgroup {
  color: var(--text);
  background: #fff;
}

html[data-theme="light"] ::-webkit-scrollbar-track {
  background: #edf0f4;
}

html[data-theme="light"] ::-webkit-scrollbar-thumb {
  background: #b9c2cf;
  border-color: #edf0f4;
}

/* 首页、榜单和异动页 */
html[data-theme="light"] .home-topbar,
html[data-theme="light"] .event-toolbar,
html[data-theme="light"] .detail-bar,
html[data-theme="light"] .metric-strip,
html[data-theme="light"] .holdings-panel,
html[data-theme="light"] .rank-card,
html[data-theme="light"] .home-detail,
html[data-theme="light"] .home-rank-card,
html[data-theme="light"] .home-detail-card,
html[data-theme="light"] .event-stream-panel,
html[data-theme="light"] .event-evidence-panel,
html[data-theme="light"] .board-matrix-panel,
html[data-theme="light"] .rank-detail-panel,
html[data-theme="light"] .constituent-detail-panel,
html[data-theme="light"] .alert-trend-panel,
html[data-theme="light"] .alert-history-panel,
html[data-theme="light"] .panel,
html[data-theme="light"] .panel-card {
  color: var(--text);
  border-color: var(--line) !important;
  background: #fff !important;
  box-shadow: 0 4px 14px rgba(35, 44, 55, 0.045);
}

html[data-theme="light"] .rank-card,
html[data-theme="light"] .home-detail {
  background-color: #fff !important;
  background-image: none !important;
}

html[data-theme="light"] .home-topbar {
  background: linear-gradient(180deg, #fff, #fafbfc) !important;
}

html[data-theme="light"] .seg-group button,
html[data-theme="light"] .refresh-btn,
html[data-theme="light"] .stream-actions button,
html[data-theme="light"] .detail-bar a,
html[data-theme="light"] .panel-link,
html[data-theme="light"] .holding-chip,
html[data-theme="light"] .holdings-actions button,
html[data-theme="light"] .tab-btn,
html[data-theme="light"] .window-btn {
  color: #5f6c7d;
  border-color: var(--line);
  background: #f7f8fa !important;
}

html[data-theme="light"] .seg-group button.active,
html[data-theme="light"] .tab-btn.active,
html[data-theme="light"] .window-btn.active,
html[data-theme="light"] .refresh-btn:hover,
html[data-theme="light"] .panel-link:hover {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .window-tabs button {
  color: #5f6c7d !important;
  border-color: var(--line) !important;
  background: #f7f8fa !important;
}

html[data-theme="light"] .window-tabs button.active {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .window-record-row .yesterday-total {
  color: #496f96 !important;
}

html[data-theme="light"] .window-record-row .yesterday {
  color: #5f7083 !important;
}

html[data-theme="light"] .window-record-row .today {
  color: #9b6b0c !important;
}

html[data-theme="light"] .metric-card,
html[data-theme="light"] .status-card,
html[data-theme="light"] .summary-card,
html[data-theme="light"] .home-detail .metric,
html[data-theme="light"] .home-detail-card .metric,
html[data-theme="light"] .board-summary > div {
  border-color: var(--line-soft) !important;
  background: #fafbfc !important;
}

html[data-theme="light"] .rank-row,
html[data-theme="light"] .constituent-row,
html[data-theme="light"] .event-row,
html[data-theme="light"] .stock-window-row,
html[data-theme="light"] .history-row,
html[data-theme="light"] .matrix-row {
  border-color: var(--line-soft) !important;
  background: transparent;
}

html[data-theme="light"] .rank-row:hover,
html[data-theme="light"] .rank-row.selected,
html[data-theme="light"] .constituent-row:hover,
html[data-theme="light"] .constituent-row.selected,
html[data-theme="light"] .event-row:hover,
html[data-theme="light"] .event-row.selected,
html[data-theme="light"] .matrix-row:hover {
  background: #f4f7fb !important;
}

html[data-theme="light"] .rank-row.selected,
html[data-theme="light"] .constituent-row.selected,
html[data-theme="light"] .event-row.selected {
  box-shadow: inset 3px 0 var(--red);
}

html[data-theme="light"] .holding-chip,
html[data-theme="light"] .holding-item {
  background: #f7f9fb !important;
}

html[data-theme="light"] .holding-chip.linked,
html[data-theme="light"] .holding-item.linked {
  border-color: #e7c07a !important;
  background: #fff8ea !important;
}

html[data-theme="light"] .toast,
html[data-theme="light"] dialog {
  color: var(--text);
  border-color: var(--line);
  background: #fff !important;
  box-shadow: 0 18px 50px rgba(28, 39, 49, 0.18);
}

html[data-theme="light"] dialog::backdrop {
  background: rgba(32, 42, 54, 0.35) !important;
}

/* 股票选股器 */
html[data-theme="light"] .workbar,
html[data-theme="light"] .rule-panel,
html[data-theme="light"] .result-panel,
html[data-theme="light"] .result-summary,
html[data-theme="light"] .coverage-strip,
html[data-theme="light"] .result-table,
html[data-theme="light"] .table-head,
html[data-theme="light"] .result-footer,
html[data-theme="light"] .panel-section,
html[data-theme="light"] .data-state,
html[data-theme="light"] .snapshot-control,
html[data-theme="light"] .official-entry,
html[data-theme="light"] .vip-score-card {
  border-color: var(--line) !important;
}

html[data-theme="light"] .workbar,
html[data-theme="light"] .result-summary,
html[data-theme="light"] .coverage-strip,
html[data-theme="light"] .result-footer {
  background: #fff !important;
}

html[data-theme="light"] .rule-panel,
html[data-theme="light"] .result-panel,
html[data-theme="light"] .result-table {
  background: var(--bg) !important;
}

html[data-theme="light"] .panel-section,
html[data-theme="light"] .table-head {
  background: #f8fafc !important;
}

html[data-theme="light"] .official-entry.free {
  background: #fff1f1 !important;
}

html[data-theme="light"] .official-entry.vip {
  background: #fff8e8 !important;
}

html[data-theme="light"] .data-state,
html[data-theme="light"] .snapshot-control,
html[data-theme="light"] .vip-score-card,
html[data-theme="light"] .rule-group,
html[data-theme="light"] .factor-example-section,
html[data-theme="light"] .guide-case,
html[data-theme="light"] .guide-steps,
html[data-theme="light"] .guide-result,
html[data-theme="light"] .strategy-setup,
html[data-theme="light"] .strategy-result {
  background: #fff !important;
}

html[data-theme="light"] .panel-section h2,
html[data-theme="light"] .panel-section h3,
html[data-theme="light"] .data-state strong,
html[data-theme="light"] .snapshot-control strong,
html[data-theme="light"] .result-summary strong,
html[data-theme="light"] .strategy-heading h2,
html[data-theme="light"] .strategy-heading strong,
html[data-theme="light"] .summary-rules strong,
html[data-theme="light"] .current-rules strong {
  color: var(--text) !important;
}

html[data-theme="light"] .icon-btn,
html[data-theme="light"] .text-btn,
html[data-theme="light"] .small-btn,
html[data-theme="light"] .segmented button,
html[data-theme="light"] .quick-excludes button,
html[data-theme="light"] .column-btn {
  color: #536174;
  border-color: var(--line);
  background: #f7f8fa !important;
}

html[data-theme="light"] .segmented button.active,
html[data-theme="light"] .quick-excludes button:hover,
html[data-theme="light"] .column-btn:hover {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .factor-settings-btn {
  color: #175270 !important;
  border-color: #9bc5dd !important;
  background: #e9f5fb !important;
}

html[data-theme="light"] .factor-settings-btn:hover,
html[data-theme="light"] .factor-settings-btn:focus-visible {
  color: #fff !important;
  border-color: #3182aa !important;
  background: #3182aa !important;
}

html[data-theme="light"] .reset-settings-btn {
  color: #a52d35 !important;
  border-color: #e7a5aa !important;
  background: #fff0f1 !important;
}

html[data-theme="light"] .reset-settings-btn:hover,
html[data-theme="light"] .reset-settings-btn:focus-visible {
  color: #fff !important;
  border-color: #d2444d !important;
  background: #d2444d !important;
}

html[data-theme="light"] .settings-shortcuts .small-btn::after {
  color: #f6f9fc !important;
  border-color: #354c61 !important;
  background: #203140 !important;
}

html[data-theme="light"] .factor-template-control select {
  color: #175270 !important;
  border-color: #9bc5dd !important;
  background: #e9f5fb !important;
}

html[data-theme="light"] .virtual-row {
  color: var(--text);
  border-color: var(--line-soft);
  background: #fff !important;
}

html[data-theme="light"] .virtual-row.row-even {
  background: #f8fafc !important;
}

html[data-theme="light"] .virtual-row:hover {
  background: #eef4fb !important;
}

html[data-theme="light"] .virtual-row.top-ranked {
  background: #fff9ea !important;
}

html[data-theme="light"] .result-cell--sticky-stock {
  background: inherit !important;
  box-shadow: 1px 0 0 #d5dde6, 8px 0 14px rgba(51, 72, 94, .08);
}

html[data-theme="light"] .table-head .result-cell--sticky-stock {
  background: #f3f5f8 !important;
}

html[data-theme="light"] .result-tool-btn.active,
html[data-theme="light"] .result-tool-btn[aria-pressed="true"] {
  color: #137153 !important;
  border-color: #9bd2bf !important;
  background: #eaf8f2 !important;
}

html[data-theme="light"] .coverage-item:hover,
html[data-theme="light"] .coverage-item:focus-visible {
  border-color: #c4d3e0 !important;
  background: #eef4fb !important;
}

html[data-theme="light"] .holding-add-btn {
  color: #b4232c !important;
  border-color: #e6a7ac !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .holding-add-btn:hover {
  color: #fff !important;
  border-color: #d9444c !important;
  background: #d9444c !important;
}

html[data-theme="light"] .holding-add-btn.added,
html[data-theme="light"] .holding-add-btn:disabled {
  color: #147252 !important;
  border-color: #9dd7c3 !important;
  background: #eaf8f2 !important;
}

html[data-theme="light"] .virtual-row .stock-name,
html[data-theme="light"] .empty-state strong,
html[data-theme="light"] .guide-rule-demo b,
html[data-theme="light"] .guide-table-demo strong {
  color: var(--text) !important;
}

html[data-theme="light"] .catalog-row,
html[data-theme="light"] .filter-manager-row,
html[data-theme="light"] .guide-table-demo > div,
html[data-theme="light"] .strategy-result-table > div {
  border-color: var(--line-soft) !important;
  background: #fff !important;
}

html[data-theme="light"] .error-dialog,
html[data-theme="light"] .holding-success-dialog {
  background: #fff !important;
}

html[data-theme="light"] .factor-picker-trigger,
html[data-theme="light"] .factor-picker-toolbar,
html[data-theme="light"] .factor-picker-list,
html[data-theme="light"] .factor-picker-detail,
html[data-theme="light"] .custom-factor-dialog,
html[data-theme="light"] .custom-factor-toolbar,
html[data-theme="light"] .custom-factor-columns,
html[data-theme="light"] .custom-factor-column > header,
html[data-theme="light"] .coverage-detail-dialog {
  color: var(--text) !important;
  border-color: var(--line) !important;
  background: #fff !important;
}

html[data-theme="light"] .custom-factor-hover-help {
  border-color: #cbd9e5 !important;
  background: #eef6fb !important;
}

html[data-theme="light"] .custom-factor-hover-help > span,
html[data-theme="light"] .custom-factor-hover-help > p { color: #52748e !important; }
html[data-theme="light"] .custom-factor-hover-help > strong { color: #17384e !important; }

html[data-theme="light"] .custom-factor-tier-tabs button {
  color: #52677a !important;
  border-color: #c5d2de !important;
  background: #f5f8fa !important;
}

html[data-theme="light"] .custom-factor-tier-tabs button.active {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] #manageCustomFactorsBtn {
  color: #175270 !important;
  border-color: #9bc5dd !important;
  background: #e9f5fb !important;
}

html[data-theme="light"] #manageCustomFactorsBtn:hover,
html[data-theme="light"] #manageCustomFactorsBtn:focus-visible {
  color: #fff !important;
  border-color: #3182aa !important;
  background: #3182aa !important;
}

html[data-theme="light"] .rule-card {
  color: var(--text) !important;
  border-color: #ccd8e3 !important;
  background: #fff !important;
}

html[data-theme="light"] .rule-card:hover { border-color: #93a9bc !important; }
html[data-theme="light"] .rule-factor-meta { color: #657b8e !important; }

html[data-theme="light"] .rule-human-summary {
  border-left-color: #4c84a8 !important;
  background: #eef6fb !important;
  color: #355b73 !important;
}

html[data-theme="light"] .rule-card.context-exclude .rule-human-summary {
  border-left-color: #c65b63 !important;
  background: #fff1f2 !important;
  color: #7e343b !important;
}

html[data-theme="light"] .number-input-shell {
  border-color: #c7d3df !important;
  background: #fff !important;
}

html[data-theme="light"] .number-input-shell input { background: transparent !important; }
html[data-theme="light"] .inline-unit { border-color: #d8e1e9 !important; color: #9a6200 !important; }

html[data-theme="light"] .factor-picker-item,
html[data-theme="light"] .custom-factor-item {
  color: var(--text) !important;
  border-color: var(--line-soft) !important;
  background: #fff !important;
}

html[data-theme="light"] .selected-column .custom-factor-item { background: #fafbfc !important; }

html[data-theme="light"] .factor-picker-item:hover,
html[data-theme="light"] .custom-factor-item:hover {
  background: #eef4fb !important;
}

html[data-theme="light"] .factor-picker-item.active,
html[data-theme="light"] .factor-detail-example {
  background: #fff1f1 !important;
}

html[data-theme="light"] .factor-use-summary {
  border-color: #bdd3e4 !important;
  background: #eef6fb !important;
}

html[data-theme="light"] .factor-use-summary span,
html[data-theme="light"] .factor-use-summary p { color: #52748e !important; }
html[data-theme="light"] .factor-use-summary strong { color: #17384e !important; }

html[data-theme="light"] .factor-picker-detail dd,
html[data-theme="light"] .factor-detail-title > strong,
html[data-theme="light"] .factor-detail-example strong {
  color: var(--text) !important;
}

html[data-theme="light"] .custom-factor-action {
  border-color: #b9cad9 !important;
  background: #f2f6fa !important;
  color: #23445f !important;
}

html[data-theme="light"] .custom-factor-action:hover {
  border-color: #e45a63 !important;
  background: #fff1f1 !important;
  color: #a62933 !important;
}

html[data-theme="light"] .coverage-detail-row {
  border-color: var(--line-soft) !important;
}

/* 个股资金证据列表和详情 */
html[data-theme="light"] .toolbar,
html[data-theme="light"] .stock-strip {
  background: #f7f8fb !important;
  border-color: var(--line) !important;
}

html[data-theme="light"] .control-group,
html[data-theme="light"] .freshness {
  border-color: var(--line) !important;
}

html[data-theme="light"] .panel-head,
html[data-theme="light"] .stock-grid,
html[data-theme="light"] .table-head {
  color: #596779 !important;
  border-color: var(--line) !important;
  background: #f3f5f8 !important;
}

html[data-theme="light"] .panel-head strong,
html[data-theme="light"] .panel-head h2,
html[data-theme="light"] .panel-head h3,
html[data-theme="light"] .panel-title strong {
  color: var(--text) !important;
}

html[data-theme="light"] .panel-foot,
html[data-theme="light"] .source-foot {
  color: var(--muted) !important;
  border-color: var(--line) !important;
  background: #f8fafc !important;
}

html[data-theme="light"] .ghost-btn,
html[data-theme="light"] .chip,
html[data-theme="light"] .icon-btn,
html[data-theme="light"] .period-btn,
html[data-theme="light"] .sorts button {
  color: #596779;
  border-color: var(--line);
  background: #f8fafc !important;
}

html[data-theme="light"] .chip.active,
html[data-theme="light"] .period-btn.active,
html[data-theme="light"] .sorts button.active {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .rows-container,
html[data-theme="light"] .detail-pane,
html[data-theme="light"] .chart,
html[data-theme="light"] .mini-chart,
html[data-theme="light"] .signal-list,
html[data-theme="light"] .evidence {
  background: #fff !important;
}

html[data-theme="light"] .detail-head {
  color: var(--text) !important;
  border-color: var(--line) !important;
  background: #fff !important;
}

html[data-theme="light"] .detail-toolbar,
html[data-theme="light"] .history-grid,
html[data-theme="light"] .detail-foot {
  color: var(--muted) !important;
  border-color: var(--line) !important;
  background: #f3f5f8 !important;
}

html[data-theme="light"] .stock-row,
html[data-theme="light"] .evidence-row,
html[data-theme="light"] .signal-item,
html[data-theme="light"] .detail-day {
  border-color: var(--line-soft) !important;
  background: #fff !important;
}

html[data-theme="light"] .stock-row:nth-child(even),
html[data-theme="light"] .evidence-row:nth-child(even),
html[data-theme="light"] .detail-day:nth-child(even) {
  background: #f8fafc !important;
}

html[data-theme="light"] .stock-row:hover,
html[data-theme="light"] .stock-row.active,
html[data-theme="light"] .evidence-row:hover,
html[data-theme="light"] .detail-day:hover {
  background: #eef4fb !important;
}

html[data-theme="light"] .summary-band > div,
html[data-theme="light"] .stock-id,
html[data-theme="light"] .source,
html[data-theme="light"] .data-dates,
html[data-theme="light"] .detail-metric,
html[data-theme="light"] .signal-item {
  border-color: var(--line-soft) !important;
  background: #f8fafc !important;
}

html[data-theme="light"] .svg-host svg text {
  fill: #667386;
}

html[data-theme="light"] .stock-name strong,
html[data-theme="light"] .detail-heading h1,
html[data-theme="light"] .stock-id h1,
html[data-theme="light"] .summary-item strong,
html[data-theme="light"] .mini-title strong,
html[data-theme="light"] .signal-main strong {
  color: var(--text) !important;
}

/* 官方策略库与策略详情 */
html[data-theme="light"] .page-head,
html[data-theme="light"] .detail-head,
html[data-theme="light"] .strategy-card,
html[data-theme="light"] .hero-metrics,
html[data-theme="light"] .chart-card,
html[data-theme="light"] .trade-card {
  border-color: var(--line) !important;
}

html[data-theme="light"] .strategy-card,
html[data-theme="light"] .hero-metrics,
html[data-theme="light"] .chart-card,
html[data-theme="light"] .trade-card {
  background: #fff !important;
  box-shadow: 0 4px 14px rgba(35, 44, 55, 0.045);
}

html[data-theme="light"] .strategy-card:hover {
  border-color: #b9c4d1 !important;
  box-shadow: 0 10px 24px rgba(35, 44, 55, 0.09);
}

html[data-theme="light"] .tier-tabs button,
html[data-theme="light"] .year-tabs button,
html[data-theme="light"] .back-link,
html[data-theme="light"] .secondary-btn {
  color: #536174;
  border-color: var(--line);
  background: #f8fafc !important;
}

html[data-theme="light"] .primary-btn {
  color: #fff !important;
  border-color: #c92f37 !important;
  background: var(--red) !important;
}

html[data-theme="light"] .primary-btn:hover {
  background: #c92f37 !important;
}

html[data-theme="light"] .tier-tabs button.active,
html[data-theme="light"] .year-tabs button.active {
  color: #a8232a !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .strategy-tags span,
html[data-theme="light"] .status-chip {
  border-color: var(--line);
  background: #f7f9fb !important;
}

html[data-theme="light"] .strategy-card-head > span:first-child {
  color: #a46a08 !important;
  border-color: #e6c783 !important;
  background: #fff7df !important;
}

html[data-theme="light"] .strategy-card.free .strategy-card-head > span:first-child {
  color: #bd3038 !important;
  border-color: #efb4b7 !important;
  background: #fff0f0 !important;
}

html[data-theme="light"] .metric-grid > div,
html[data-theme="light"] .hero-metrics > div {
  border-color: var(--line-soft) !important;
}

html[data-theme="light"] .backtest-disclosure {
  color: #6b7788 !important;
  border-color: var(--line-soft) !important;
  background: #f7f9fb !important;
}

html[data-theme="light"] .strategy-read-btn {
  color: #245f94;
  border-color: #a9c8e0;
  background: #edf6fc !important;
}

/* White theme destructive actions need a light surface and a dark enough label. */
html[data-theme="light"] .tutorial-btn,
html[data-theme="light"] .remove-btn,
html[data-theme="light"] .delete-filter-btn,
html[data-theme="light"] .danger-btn {
  color: #a8232a !important;
  border-color: #e6a8ae !important;
  background: #fff0f1 !important;
}

html[data-theme="light"] .tutorial-btn > span {
  color: #a8232a !important;
  border-color: #d76a73 !important;
}

html[data-theme="light"] .tutorial-btn:hover,
html[data-theme="light"] .tutorial-btn:focus-visible,
html[data-theme="light"] .remove-btn:hover,
html[data-theme="light"] .remove-btn:focus-visible,
html[data-theme="light"] .delete-filter-btn:not(:disabled):hover,
html[data-theme="light"] .delete-filter-btn:not(:disabled):focus-visible,
html[data-theme="light"] .danger-btn:hover,
html[data-theme="light"] .danger-btn:focus-visible {
  color: #7f1d24 !important;
  border-color: #c64a54 !important;
  background: #ffe1e4 !important;
}

html[data-theme="light"] .tutorial-btn:focus-visible,
html[data-theme="light"] .remove-btn:focus-visible,
html[data-theme="light"] .delete-filter-btn:focus-visible,
html[data-theme="light"] .danger-btn:focus-visible {
  outline: 2px solid rgba(198, 74, 84, .38);
  outline-offset: 2px;
}

html[data-theme="light"] .trade-scroll {
  border-color: var(--line) !important;
  background: #fff !important;
}

html[data-theme="light"] .trade-table {
  color: #17212d;
  background: #fff;
}

html[data-theme="light"] .trade-table th {
  color: #304050;
  background: #eef2f7;
}

html[data-theme="light"] .trade-table td {
  border-color: #dbe2eb;
}

html[data-theme="light"] .trade-table tbody tr:nth-child(even) {
  background: #f8fafc;
}

html[data-theme="light"] .trade-table tbody tr:hover {
  background: #eaf2fc;
}

@media (max-width: 1320px) {
  .theme-switcher-label {
    display: none;
  }

  .theme-switcher button {
    min-width: 40px;
  }
}

/* 股票选股器白底视觉系统：结构和业务逻辑与黑底共用。 */
html[data-theme="light"][data-theme-scope="screener"] {
  --theme-page-light: #f2f5f8;
  --theme-surface-soft-light: #f7f9fc;
  --theme-surface-muted-light: #edf2f6;
  --theme-line-light: #d8e1ea;
  --theme-line-soft-light: #e6edf3;
  --theme-text-light: #142033;
  --theme-muted-light: #63758a;
  --theme-muted-2-light: #8798aa;
  --theme-red-light: #d94b4b;
  --theme-green-light: #159a76;
  --theme-amber-light: #b88624;
  --theme-blue-light: #3978c5;
  --theme-blue-soft-light: #eaf3fb;
}

html[data-theme="light"][data-theme-scope="screener"] .topbar {
  color: #eef5fb !important;
  border-color: #263b51 !important;
  background: #142033 !important;
  box-shadow: none;
}

html[data-theme="light"][data-theme-scope="screener"] .brand,
html[data-theme="light"][data-theme-scope="screener"] .brand strong,
html[data-theme="light"][data-theme-scope="screener"] .top-status strong {
  color: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .brand small,
html[data-theme="light"][data-theme-scope="screener"] .top-status {
  color: #aebed0 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .brand-mark {
  color: #ff6a6a !important;
  border-color: #cf5454 !important;
  background: #263247 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .topnav a {
  color: #c5d1df !important;
}

html[data-theme="light"][data-theme-scope="screener"] .topnav a:hover {
  color: #fff !important;
  background: #22334a !important;
}

html[data-theme="light"][data-theme-scope="screener"] .topnav a.active {
  color: #c9363e !important;
  border-color: #fff !important;
  border-bottom-color: #d94b4b !important;
  background: #fff !important;
  box-shadow: inset 0 -3px 0 #d94b4b;
}

html[data-theme="light"][data-theme-scope="screener"] .theme-switcher {
  color: #d4deea;
  border-color: #42566e;
  background: #223047;
}

html[data-theme="light"][data-theme-scope="screener"] .theme-switcher button:hover {
  color: #fff;
  background: #34465e;
}

html[data-theme="light"][data-theme-scope="screener"] .theme-switcher button.active {
  color: #fff;
  background: #d94b4b;
}

html[data-theme="light"][data-theme-scope="screener"] .workbar {
  border-color: #d6e0e9 !important;
  background: #f7f9fc !important;
}

html[data-theme="light"][data-theme-scope="screener"] .snapshot-control,
html[data-theme="light"][data-theme-scope="screener"] .data-state {
  border-color: #cfdbe6 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry {
  border-width: 2px !important;
  box-shadow: none;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.free {
  color: #c9363e !important;
  border-color: #e06a70 !important;
  background: #fff0f1 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.free:hover {
  border-color: #c9363e !important;
  background: #ffe5e7 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.vip {
  color: #9b6b0e !important;
  border-color: #d0a244 !important;
  background: #fff7e5 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.vip:hover {
  border-color: #ae7b17 !important;
  background: #ffefcc !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry small {
  color: #6f7d8d !important;
}

html[data-theme="light"][data-theme-scope="screener"] select,
html[data-theme="light"][data-theme-scope="screener"] .factor-picker-trigger {
  color: #1d3148 !important;
  border-color: #8fa8c0 !important;
  border-width: 1.5px !important;
  background-color: #fff !important;
  box-shadow: inset 0 0 0 1px rgba(57, 120, 197, .05);
}

html[data-theme="light"][data-theme-scope="screener"] select:hover,
html[data-theme="light"][data-theme-scope="screener"] .factor-picker-trigger:hover {
  border-color: #3978c5 !important;
  background-color: #f5f9ff !important;
}

html[data-theme="light"][data-theme-scope="screener"] select:focus-visible,
html[data-theme="light"][data-theme-scope="screener"] .factor-picker-trigger:focus-visible {
  outline: 2px solid rgba(57, 120, 197, .22);
  outline-offset: 1px;
  border-color: #3978c5 !important;
  background-color: #f5f9ff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-panel {
  padding: 8px;
  border-right-color: #cfd9e3 !important;
  background: #eef3f7 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .panel-section {
  margin-bottom: 8px;
  padding: 14px;
  border: 1px solid #d6e0e9 !important;
  border-radius: 5px;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .strategy-section {
  border-left: 4px solid #3978c5 !important;
  background: #f7faff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .scope-section {
  border-left: 4px solid #4a70a8 !important;
  background: #f8fbff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .include-section {
  border-left: 4px solid #168f8a !important;
  background: #f7fcfb !important;
}

html[data-theme="light"][data-theme-scope="screener"] .exclude-section {
  border-left: 4px solid #d97745 !important;
  background: #fffaf6 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .sort-section {
  border-left: 4px solid #4f5f98 !important;
  background: #f8f9fd !important;
}

html[data-theme="light"][data-theme-scope="screener"] .panel-section h2 {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #142033 !important;
  font-size: 16px;
  font-weight: 900;
}

html[data-theme="light"][data-theme-scope="screener"] .panel-section h2::before {
  content: "";
  width: 9px;
  height: 9px;
  flex: 0 0 9px;
  border-radius: 2px;
  background: #3978c5;
}

html[data-theme="light"][data-theme-scope="screener"] .include-section h2::before { background: #168f8a; }
html[data-theme="light"][data-theme-scope="screener"] .exclude-section h2::before { background: #d97745; }
html[data-theme="light"][data-theme-scope="screener"] .sort-section h2::before { background: #4f5f98; }

html[data-theme="light"][data-theme-scope="screener"] .panel-section p,
html[data-theme="light"][data-theme-scope="screener"] .field-label,
html[data-theme="light"][data-theme-scope="screener"] .summary-label {
  color: #63758a !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-card {
  border-color: #c8d6e2 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-card-head {
  padding-bottom: 7px;
  border-bottom: 1px solid #e2e9ef;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-factor-meta {
  color: #637a8f !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-human-summary {
  border-left-width: 3px !important;
  border-left-color: #3978c5 !important;
  background: #eaf3fb !important;
  color: #315a78 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-card.context-exclude .rule-human-summary {
  border-left-color: #d35e55 !important;
  background: #fff0ef !important;
  color: #803b38 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-summary {
  gap: 8px;
  border-color: #d3dde7 !important;
  background: #f8fafc !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-summary > .summary-stat,
html[data-theme="light"][data-theme-scope="screener"] .result-summary > .summary-rules {
  min-height: 58px;
  padding: 9px 10px 7px !important;
  border: 1px solid #d9e2ea !important;
  border-left-width: 4px !important;
  border-radius: 5px;
  background: #fff;
}

html[data-theme="light"][data-theme-scope="screener"] .summary-match { border-left-color: #3978c5 !important; }
html[data-theme="light"][data-theme-scope="screener"] .summary-scope { border-left-color: #6657c8 !important; }
html[data-theme="light"][data-theme-scope="screener"] .summary-include { border-left-color: #168f8a !important; }
html[data-theme="light"][data-theme-scope="screener"] .summary-exclude { border-left-color: #d97745 !important; }
html[data-theme="light"][data-theme-scope="screener"] .result-summary strong { color: #142033 !important; }

html[data-theme="light"][data-theme-scope="screener"] .result-action-group {
  border-color: #cad7e2;
  box-shadow: none;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-help {
  border-color: #b8d1e6;
  background: #eaf3fb;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-view {
  border-color: #b9d8d7;
  background: #edf8f7;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-data {
  border-color: #c8d3de;
  background: #eef2f6;
}

html[data-theme="light"][data-theme-scope="screener"] .action-group-label {
  color: #345672;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group button {
  color: #27435d !important;
  border-color: #aebfd0 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group button:hover,
html[data-theme="light"][data-theme-scope="screener"] .result-action-group button:focus-visible {
  color: #174d75 !important;
  border-color: #5f96bf !important;
  background: #f5faff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group .tutorial-btn {
  color: #1c5d8b !important;
  border-color: #79a8ca !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group .tutorial-btn > span {
  color: #3978c5 !important;
  border-color: #3978c5 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .coverage-strip {
  border-color: #d4dee8 !important;
  background: #f4f7fa !important;
}

html[data-theme="light"][data-theme-scope="screener"] .table-head {
  color: #dce7f1 !important;
  border-color: #314960 !important;
  background: #20364d !important;
}

html[data-theme="light"][data-theme-scope="screener"] .table-head .result-cell--sticky-stock {
  background: #20364d !important;
  box-shadow: 1px 0 0 #50667b, 8px 0 14px rgba(20, 32, 51, .14);
}

html[data-theme="light"][data-theme-scope="screener"] .virtual-row.top-ranked {
  border-bottom-color: #edcf87 !important;
  background: #fff3d6 !important;
  box-shadow: inset 4px 0 0 #c99524 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .virtual-row.top-ranked:hover {
  background: #ffedc2 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rank-no1-badge {
  color: #fff !important;
  border-color: #b47a10 !important;
  background: #c88a17 !important;
  box-shadow: none !important;
}

html[data-theme="light"][data-theme-scope="screener"] .table-viewport {
  scrollbar-color: #9aaabd #e8edf2;
}

@media (max-width: 1480px) {
  .result-action-group {
    padding-inline: 5px;
    gap: 4px;
  }

  .result-action-group .tutorial-btn,
  .result-action-group .text-btn {
    padding-inline: 7px;
    font-size: 12px;
  }
}

/* The strategy library reuses dark-theme semantic classes. Keep secondary
   information readable without weakening the red/green performance colors. */
html[data-theme="light"][data-theme-scope="screener"] .strategy-summary,
html[data-theme="light"][data-theme-scope="screener"] .strategy-card h2 small,
html[data-theme="light"][data-theme-scope="screener"] .strategy-tags span {
  color: #516579 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .strategy-tags span {
  border-color: #c7d4df !important;
  background: #f4f7fa !important;
}

html[data-theme="light"][data-theme-scope="screener"] .metric-grid span,
html[data-theme="light"][data-theme-scope="screener"] .hero-metrics span {
  color: #5d6f82 !important;
  font-weight: 600;
}

html[data-theme="light"][data-theme-scope="screener"] .metric-grid .neutral,
html[data-theme="light"][data-theme-scope="screener"] .hero-metrics .neutral {
  color: #24384d !important;
}

html[data-theme="light"][data-theme-scope="screener"] .status-chip {
  color: #08795a !important;
  border-color: #9fd6c6 !important;
  background: #edf9f5 !important;
}

/* White screener visual alignment v3. The selectors stay inside the screener
   theme scope so the dark theme and the rest of the site keep their styling. */
html[data-theme="light"][data-theme-scope="screener"] {
  --theme-page-light: #f4f7fa;
  --theme-surface-soft-light: #f8fafc;
  --theme-line-light: #c8d5e2;
  --theme-line-soft-light: #dce5ed;
  --theme-text-light: #13263c;
  --theme-muted-light: #5f7389;
  --theme-blue-light: #246fbd;
}

html[data-theme="light"][data-theme-scope="screener"] .topbar {
  border-color: #163653 !important;
  background: #0b2340 !important;
  box-shadow: 0 2px 8px rgba(16, 43, 70, .16);
}

html[data-theme="light"][data-theme-scope="screener"] .workbar {
  border-color: #c7d5e2 !important;
  background: #f6f9fc !important;
  box-shadow: inset 0 -1px 0 #e2e9f0;
}

html[data-theme="light"][data-theme-scope="screener"] .snapshot-control {
  border: 1px solid #b8cadb !important;
  background: #fff !important;
  box-shadow: 0 1px 3px rgba(37, 70, 105, .06);
}

html[data-theme="light"][data-theme-scope="screener"] .snapshot-control label {
  padding-right: 8px;
  border-right: 1px solid #e0e8ef;
}

html[data-theme="light"][data-theme-scope="screener"] .snapshot-control label:last-of-type {
  border-right: 0;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry {
  border-width: 1.5px !important;
  box-shadow: 0 2px 7px rgba(40, 63, 87, .08);
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.free {
  color: #db2632 !important;
  border-color: #f04b54 !important;
  background: #fff5f5 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.free .entry-icon {
  color: #db2632 !important;
  border-color: #f04b54 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.vip {
  color: #b47600 !important;
  border-color: #e5a21b !important;
  background: #fff9ea !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry.vip .entry-icon {
  color: #a96f00 !important;
  border-color: #e5a21b !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .official-entry strong {
  font-weight: 900;
}

html[data-theme="light"][data-theme-scope="screener"] .data-state {
  position: relative;
  overflow: hidden;
  border: 1px solid #b8d9d0 !important;
  background: #fff !important;
  box-shadow: 0 1px 3px rgba(31, 105, 84, .06);
}

html[data-theme="light"][data-theme-scope="screener"] .data-state::after {
  content: "";
  position: absolute;
  right: 10px;
  bottom: 5px;
  left: 10px;
  height: 3px;
  border-radius: 2px;
  background: #16a579;
}

html[data-theme="light"][data-theme-scope="screener"] .data-state small {
  color: #64788c !important;
}

html[data-theme="light"][data-theme-scope="screener"] .data-state strong {
  color: #173148 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .primary-btn {
  color: #fff !important;
  border-color: #c91824 !important;
  background: #df202b !important;
  box-shadow: 0 4px 10px rgba(203, 30, 42, .17);
}

html[data-theme="light"][data-theme-scope="screener"] .primary-btn:hover,
html[data-theme="light"][data-theme-scope="screener"] .primary-btn:focus-visible {
  border-color: #a9111a !important;
  background: #c91924 !important;
}

html[data-theme="light"][data-theme-scope="screener"] select,
html[data-theme="light"][data-theme-scope="screener"] input[type="text"],
html[data-theme="light"][data-theme-scope="screener"] input[type="number"],
html[data-theme="light"][data-theme-scope="screener"] textarea,
html[data-theme="light"][data-theme-scope="screener"] .factor-picker-trigger {
  color: #17324d !important;
  border-color: #8faec9 !important;
  background-color: #fff !important;
  box-shadow: inset 0 0 0 1px rgba(52, 116, 178, .04);
}

html[data-theme="light"][data-theme-scope="screener"] select:hover,
html[data-theme="light"][data-theme-scope="screener"] input[type="text"]:hover,
html[data-theme="light"][data-theme-scope="screener"] input[type="number"]:hover,
html[data-theme="light"][data-theme-scope="screener"] textarea:hover,
html[data-theme="light"][data-theme-scope="screener"] .factor-picker-trigger:hover {
  border-color: #397fbe !important;
  background-color: #f7fbff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .text-btn,
html[data-theme="light"][data-theme-scope="screener"] .small-btn,
html[data-theme="light"][data-theme-scope="screener"] .quick-excludes button {
  color: #294967 !important;
  border-color: #aebfd0 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .text-btn:hover,
html[data-theme="light"][data-theme-scope="screener"] .small-btn:hover,
html[data-theme="light"][data-theme-scope="screener"] .quick-excludes button:hover {
  color: #15588b !important;
  border-color: #5f94be !important;
  background: #f2f8fd !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-panel {
  border-right-color: #b9cad9 !important;
  background: #edf3f7 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .panel-section {
  border-color: #cbd8e3 !important;
  box-shadow: 0 1px 3px rgba(26, 54, 82, .04);
}

html[data-theme="light"][data-theme-scope="screener"] .strategy-section,
html[data-theme="light"][data-theme-scope="screener"] .scope-section {
  border-left-color: #2475c7 !important;
  background: #f7fbff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .include-section {
  border-left-color: #12967d !important;
  background: #f7fcfb !important;
}

html[data-theme="light"][data-theme-scope="screener"] .exclude-section {
  border-left-color: #ef7b23 !important;
  background: #fffaf5 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .sort-section {
  border-left-color: #5147a3 !important;
  background: #f8f8fd !important;
}

html[data-theme="light"][data-theme-scope="screener"] .panel-section h2 {
  gap: 9px;
  color: #102b45 !important;
  font-size: 16px;
}

html[data-theme="light"][data-theme-scope="screener"] .panel-section h2::before {
  content: "策";
  width: 27px;
  height: 27px;
  flex: 0 0 27px;
  display: grid;
  place-items: center;
  border-radius: 4px;
  color: #fff;
  background: #2475c7;
  font-size: 13px;
  font-weight: 900;
  line-height: 1;
}

html[data-theme="light"][data-theme-scope="screener"] .scope-section h2::before {
  content: "股";
  background: #2475c7;
}

html[data-theme="light"][data-theme-scope="screener"] .include-section h2::before {
  content: "纳";
  background: #12967d;
}

html[data-theme="light"][data-theme-scope="screener"] .exclude-section h2::before {
  content: "排";
  background: #ef7b23;
}

html[data-theme="light"][data-theme-scope="screener"] .sort-section h2::before {
  content: "序";
  background: #5147a3;
}

html[data-theme="light"][data-theme-scope="screener"] .advanced-section h2::before {
  content: "高";
  background: #5a6b7e;
}

html[data-theme="light"][data-theme-scope="screener"] .factor-settings-btn {
  color: #fff !important;
  border-color: #1468bd !important;
  background: #1d73c9 !important;
  box-shadow: 0 2px 5px rgba(29, 115, 201, .16);
}

html[data-theme="light"][data-theme-scope="screener"] .factor-settings-btn:hover,
html[data-theme="light"][data-theme-scope="screener"] .factor-settings-btn:focus-visible {
  color: #fff !important;
  border-color: #0e579d !important;
  background: #155fae !important;
}

html[data-theme="light"][data-theme-scope="screener"] .reset-settings-btn {
  color: #b72f3b !important;
  border-color: #df9299 !important;
  background: #fff2f3 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .reset-settings-btn:hover,
html[data-theme="light"][data-theme-scope="screener"] .reset-settings-btn:focus-visible {
  color: #98232e !important;
  border-color: #c95f69 !important;
  background: #ffe7e9 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .include-section .heading-actions .small-btn {
  color: #087763 !important;
  border-color: #78b9ad !important;
  background: #effaf7 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .exclude-section .heading-actions .small-btn,
html[data-theme="light"][data-theme-scope="screener"] .quick-excludes button {
  color: #a95718 !important;
  border-color: #efb382 !important;
  background: #fff7ef !important;
}

html[data-theme="light"][data-theme-scope="screener"] .sort-section .small-btn {
  color: #4b438f !important;
  border-color: #9d96cd !important;
  background: #f4f3fc !important;
}

html[data-theme="light"][data-theme-scope="screener"] .segmented button {
  color: #31516e !important;
  border-color: #b6c7d6 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .segmented button.active {
  color: #c72934 !important;
  border-color: #e15a63 !important;
  background: #fff1f2 !important;
  box-shadow: inset 0 0 0 1px rgba(199, 41, 52, .08);
}

html[data-theme="light"][data-theme-scope="screener"] .rule-card {
  border-color: #b9cada !important;
  box-shadow: 0 1px 3px rgba(29, 58, 86, .05);
}

html[data-theme="light"][data-theme-scope="screener"] .rule-card-head {
  border-bottom-color: #d9e3eb !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-human-summary {
  border-left-color: #287ec0 !important;
  background: #e8f3fb !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rule-card.context-exclude .rule-human-summary {
  border-left-color: #d64e4e !important;
  background: #fff0f0 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-panel {
  background: #f4f7fa !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-summary {
  border-color: #c6d4e0 !important;
  background: #f8fafc !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-summary > .summary-stat,
html[data-theme="light"][data-theme-scope="screener"] .result-summary > .summary-rules {
  border-color: #cbd8e3 !important;
  background: #fff !important;
  box-shadow: 0 1px 4px rgba(29, 57, 84, .05);
}

html[data-theme="light"][data-theme-scope="screener"] .summary-match {
  border-left-color: #2475c7 !important;
  background: #f7fbff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .summary-scope {
  border-left-color: #6656cb !important;
  background: #faf9ff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .summary-include {
  border-left-color: #12967d !important;
  background: #f5fcfa !important;
}

html[data-theme="light"][data-theme-scope="screener"] .summary-exclude {
  border-left-color: #ef7b23 !important;
  background: #fffaf5 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .summary-rules {
  border-left-color: #476987 !important;
  background: #f8fbfd !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group {
  border-width: 1.5px;
  box-shadow: 0 1px 4px rgba(31, 63, 92, .05);
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-help {
  border-color: #92badc;
  background: #eaf4fd;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-view {
  border-color: #82c5c8;
  background: #ebf9f9;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-data {
  border-color: #acbdcc;
  background: #f0f4f8;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-help .action-group-label {
  color: #246ca6;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-view .action-group-label {
  color: #14757a;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group.action-data .action-group-label {
  color: #526c82;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group button {
  color: #274966 !important;
  border-color: #91aac0 !important;
  background: #fff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .result-action-group .column-btn {
  color: #155f91 !important;
  border-color: #4f91bd !important;
  background: #f1f9ff !important;
}

html[data-theme="light"][data-theme-scope="screener"] .coverage-strip {
  color: #60758a !important;
  border-color: #cbd8e3 !important;
  background: #f5f8fb !important;
}

html[data-theme="light"][data-theme-scope="screener"] .table-head,
html[data-theme="light"][data-theme-scope="screener"] .table-head .result-cell--sticky-stock {
  color: #eef6fd !important;
  border-color: #2c5577 !important;
  background: #153a5b !important;
}

html[data-theme="light"][data-theme-scope="screener"] .virtual-row.top-ranked {
  border-color: #e3b74c !important;
  background: #fff5df !important;
  box-shadow: inset 4px 0 0 #d79b15 !important;
}

html[data-theme="light"][data-theme-scope="screener"] .rank-no1-badge {
  border-color: #b47700 !important;
  background: #d89405 !important;
  box-shadow: 0 2px 5px rgba(194, 127, 0, .18) !important;
}
