* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

:root {
  --primary: #1a73e8;
  --primary-dark: #1557b0;
  --bg: #f2f3f7;
  --header-bg: #1e293b;
  --card-bg: #ffffff;
  --text: #1f2937;
  --text-light: #6b7280;
  --border: #ececf0;
  --danger: #dc2626;
  --success: #16a34a;
  --post: #2563eb;
  --comment: #7c3aed;
  --tabbar-h: 54px;
}

@media (prefers-color-scheme: dark) {
  :root { --bg: #111827; --header-bg: #020617; --card-bg: #1f2937; --text: #f3f4f6; --text-light: #cbd5e1; --border: #374151; }
  body { background: #020617; }
  .tabs { background: #374151; }
  .tab.active, .btn { background: #273449; color: var(--text); }
  .form-row input[type="text"], .form-row input[type="number"], .form-row input[type="url"], .form-row input[type="password"], .form-row input[type="time"], .form-row select, .search-box input, .search-box select { background: #111827; color: var(--text); border-color: var(--border); }
  .feed-item.unread { background: #1e3a5f; }
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #d3d7de;
  color: var(--text);
  display: flex;
  justify-content: center;
}

/* 手机容器：PC 上居中显示为手机屏幕，手机上占满全屏 */
.phone {
  position: relative; /* 作为内部覆盖层的定位基准 */
  width: 100%;
  max-width: 430px;
  height: 100vh;
  height: 100dvh; /* 移动端浏览器地址栏收起/展开时高度更准确 */
  background: var(--bg);
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 40px rgba(0, 0, 0, .18);
  overflow: hidden;
}

@media (min-width: 520px) {
  body { padding: 24px 0; align-items: center; }
  .phone { height: calc(100vh - 48px); height: calc(100dvh - 48px); border-radius: 28px; }
}

/* 顶部导航 */
.app-header {
  background: var(--header-bg);
  color: #fff;
  padding: calc(14px + env(safe-area-inset-top)) 16px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.header-left { display: flex; align-items: center; gap: 10px; }
.logo-icon {
  width: 34px; height: 34px; border-radius: 9px;
  background: linear-gradient(135deg, #3b82f6, #8b5cf6);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 700; color: #fff;
}
.header-title { font-size: 16px; font-weight: 600; }
.header-right { display: flex; align-items: center; gap: 10px; }

/* 未读角标 */
.badge {
  min-width: 20px; height: 20px; padding: 0 6px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .15);
  color: #fff; font-size: 12px; font-weight: 600;
  display: flex; align-items: center; justify-content: center;
}
.badge:empty { display: none; }
.badge.has-unread { background: #ef4444; }

/* 头部小按钮（深色背景上） */
.btn-header { background: rgba(255,255,255,.12); border-color: transparent; color: #fff; }
.btn-header:hover { background: rgba(255,255,255,.22); }

/* 内容区 */
.main { flex: 1; overflow-y: auto; overscroll-behavior: contain; }
.page { padding: 16px 16px 24px; }
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.page-header h2 { font-size: 18px; }
.feed-hero { padding:18px; margin:-2px 0 18px; border-radius:18px; color:#fff; background:radial-gradient(circle at 88% 10%,#7558f6 0,transparent 38%),linear-gradient(135deg,#172a55,#31227c); box-shadow:0 12px 28px rgba(49,34,124,.25); }
.feed-hero-top { display:flex; justify-content:space-between; align-items:center; }.eyebrow { font-size:10px; letter-spacing:1.4px; opacity:.72; font-weight:700; }.feed-hero h2 { margin:14px 0 5px; font-size:23px; }.feed-hero p { font-size:12px; opacity:.78; }
.icon-action { width:30px; height:30px; border:1px solid rgba(255,255,255,.25); border-radius:9px; color:#fff; background:rgba(255,255,255,.1); cursor:pointer; }
.feed-stats { display:grid; grid-template-columns:repeat(3,1fr); margin:18px 0 14px; padding:12px 0; border-top:1px solid rgba(255,255,255,.14); border-bottom:1px solid rgba(255,255,255,.14); }.feed-stats div { padding-left:10px; border-left:1px solid rgba(255,255,255,.15); }.feed-stats div:first-child { padding-left:0; border-left:0; }.feed-stats b { display:block; font-size:20px; }.feed-stats span { font-size:10px; opacity:.7; }
.feed-primary { width:100%; border:0; border-radius:10px; padding:10px; background:linear-gradient(90deg,#7058ff,#3c7bff); color:#fff; font-weight:700; cursor:pointer; }.feed-primary span { float:right; }.feed-section-heading { margin:4px 0 10px; }
.brief-hero { padding:15px 16px; margin:0 0 14px; border-radius:15px; background:linear-gradient(135deg,#171d36,#242052); color:#fff; }.brief-hero h3 { margin:7px 0 3px; font-size:18px; }.brief-hero p { font-size:11px; opacity:.78; }.brief-hero div { display:flex; align-items:baseline; gap:7px; margin-top:13px; }.brief-hero b { font-size:19px; }.brief-hero span { font-size:10px; opacity:.76; margin-right:10px; }

/* 深色主题对比度：所有辅助文字至少使用可读的冷灰，卡片与输入框拉开层级。 */
@media (prefers-color-scheme: dark) {
  .phone, .main { background:#101722; }
  .card, .feed-item, .follow-item, .watch-item, .flash-item, .hot-item { background:#1b2533; box-shadow:0 1px 0 rgba(255,255,255,.06); }
  .card-hint, .field-hint, .feed-meta, .f-item-meta, .flash-time, .hint { color:#b7c4d9 !important; }
  .feed-content, .flash-content, .feed-reply { color:#d0d9e8; }
  .btn { border-color:#52627a; background:#263449; color:#f5f8ff; }
  .btn:hover { background:#344664; }
  .tab { color:#c2cee0; }.tab.active { background:#344664; color:#fff; }
  .search-box input, .form-row input, .form-row select { color:#f6f8fc !important; background:#111a27 !important; border-color:#52627a !important; }
}

/* Tab 筛选 */
.tabs {
  display: flex; gap: 6px;
  background: #e8e9ee; padding: 3px; border-radius: 10px;
  margin-bottom: 14px;
}
.tab {
  flex: 1; padding: 8px 0; border: none; border-radius: 8px;
  background: transparent; font-size: 13px; cursor: pointer; color: var(--text-light);
}
.tab.active { background: #fff; color: var(--text); font-weight: 600; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.tabs-scroll { flex-wrap: wrap; }
.tabs-scroll .tab { flex: none; padding: 8px 12px; white-space: nowrap; }
.settings-tabs { position: sticky; top: -16px; z-index: 2; }

/* 卡片 */
.card {
  background: var(--card-bg); border-radius: 12px;
  padding: 16px; margin-bottom: 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.card-title { font-size: 15px; font-weight: 600; margin-bottom: 14px; }
.card-hint { font-size: 12px; color: #888; margin-top: 12px; line-height: 1.6; }

/* 设备信息卡 */
.device-info { display: flex; flex-direction: column; gap: 9px; }
.di-row {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; font-size: 13px;
}
.di-row span { color: var(--text-light); flex-shrink: 0; }
.di-row b { font-weight: 600; text-align: right; word-break: break-all; }

/* 表单（手机风格：label 在上、输入框在下） */
.form-row { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.form-row > label { font-size: 13px; color: var(--text-light); }
.form-row input[type="text"], .form-row input[type="number"], .form-row input[type="url"],
.form-row input[type="password"], .form-row input[type="time"], .form-row select {
  width: 100%;
  padding: 10px 12px; border: 1px solid var(--border); border-radius: 8px;
  font-size: 14px; background: #fafafa;
  box-sizing: border-box;
}
.form-row input:focus, .form-row select:focus { outline: none; border-color: var(--primary); background: #fff; }
.form-row .field-hint { width: 100%; font-size: 12px; color: #999; margin-top: 4px; }
.form-row .quota-value { font-weight: 600; color: var(--primary); line-height: 38px; }
.sd-llm-quota { margin-left: 8px; font-size: 12px; color: #999; }
.sd-llm-quota.exhausted { color: #e45649; }
.form-row.switch-row { flex-direction: row; align-items: center; justify-content: space-between; }
.form-actions { display: flex; gap: 10px; margin-top: 12px; }
.form-actions .btn { flex: 1; }

/* 推送开关（checkbox 形式） */
.checkbox { display: inline-flex; align-items: center; cursor: pointer; flex-shrink: 0; }
.checkbox input { position: absolute; opacity: 0; width: 0; height: 0; }
.checkmark {
  position: relative; width: 48px; height: 28px; border-radius: 14px;
  background: #d1d5db; transition: .2s; box-sizing: border-box;
}
.checkmark::after {
  content: ""; position: absolute; left: 3px; top: 3px;
  width: 22px; height: 22px; border-radius: 50%;
  background: #fff; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.checkbox input:checked + .checkmark { background: var(--success); }
.checkbox input:checked + .checkmark::after { left: 23px; }
.checkbox input:focus-visible + .checkmark { outline: 2px solid var(--primary); outline-offset: 2px; }

/* 点击通知跳转（radio 组，胶囊样式） */
.radio-group { display: flex; flex-wrap: wrap; gap: 8px; }
.radio { display: inline-flex; align-items: center; cursor: pointer; }
.radio input { position: absolute; opacity: 0; width: 0; height: 0; }
.radio span {
  padding: 7px 14px; font-size: 13px; border-radius: 16px;
  border: 1px solid var(--border); background: #fafafa; color: var(--text-light);
  transition: all .2s;
}
.radio input:checked + span {
  background: #e8f3ff; border-color: var(--primary); color: var(--primary);
  font-weight: 600;
}
.radio input:focus-visible + span { outline: 2px solid var(--primary); outline-offset: 2px; }

/* 按钮 */
.btn {
  padding: 9px 16px; border: 1px solid var(--border); border-radius: 8px;
  background: #fff; font-size: 14px; cursor: pointer; transition: all .2s; color: var(--text);
}
.btn:hover { background: #f3f4f6; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-danger { color: var(--danger); border-color: var(--danger); }
.btn-danger:hover { background: #fef2f2; }

/* 搜索 */
.search-box { display: flex; gap: 8px; margin-bottom: 14px; }
.search-box input {
  flex: 1; padding: 10px 12px; border: 1px solid var(--border);
  border-radius: 8px; font-size: 13px; background: #fafafa;
}
.search-box input:focus { outline: none; border-color: var(--primary); background: #fff; }
.search-box select {
  padding: 9px 10px; border: 1px solid var(--border); border-radius: 8px;
  font-size: 13px; background: #fafafa; color: var(--text); flex: none;
  max-width: 40%;
}
.search-box select:focus { outline: none; border-color: var(--primary); background: #fff; }

/* 解析结果 */
.resolve-card {
  background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 10px;
  padding: 12px 14px; margin-bottom: 14px; display: flex; align-items: center; gap: 12px;
}
.resolve-card img { width: 42px; height: 42px; border-radius: 50%; background: #dbeafe; }
.resolve-card .r-info { flex: 1; min-width: 0; }
.resolve-card .r-name { font-weight: 600; font-size: 14px; }
.resolve-card .tag-exact {
  display: inline-block; font-size: 11px; font-weight: 500; color: #fff;
  background: var(--primary); border-radius: 10px; padding: 1px 8px; margin-left: 6px;
  vertical-align: 1px;
}
.resolve-card .r-meta { font-size: 12px; color: var(--text-light); margin-top: 3px; word-break: break-all; }

/* 列表 */
.section-title { font-size: 14px; font-weight: 600; margin: 4px 0 12px; color: var(--text); }
.feed-list { display: flex; flex-direction: column; gap: 10px; }
.feed-item {
  background: var(--card-bg); border-radius: 12px; padding: 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.04); cursor: pointer;
  border-left: 3px solid transparent; transition: all .15s;
}
.feed-item.type-post { border-left-color: var(--post); }
.feed-item.type-comment { border-left-color: var(--comment); }
.feed-item.unread { background: #f0f6ff; }
.feed-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.feed-avatar { width: 28px; height: 28px; border-radius: 50%; background: #e5e7eb; flex-shrink: 0; }
.feed-user { font-weight: 600; font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed-tag { font-size: 11px; padding: 2px 8px; border-radius: 20px; font-weight: 500; flex-shrink: 0; }
.feed-tag.post { background: #dbeafe; color: var(--post); }
.feed-tag.comment { background: #ede9fe; color: var(--comment); }
.feed-tag.unread-dot { background: #f59e0b; color: #fff; }
.feed-title { font-size: 15px; font-weight: 600; margin-bottom: 6px; color: var(--text); }
.feed-content {
  font-size: 13px; color: var(--text-light); line-height: 1.6;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.content-type { font-weight: 600; }
.content-type.post { color: var(--post); }
.content-type.comment { color: var(--comment); }
.feed-meta { margin-top: 8px; font-size: 12px; color: #9ca3af; display: flex; gap: 10px; flex-wrap: wrap; }
.feed-time { margin-left: auto; flex-shrink: 0; }
.feed-source { color: var(--primary); text-decoration: none; }
.feed-source:hover { text-decoration: underline; }

/* 关注列表 */
.follow-list { display: flex; flex-direction: column; gap: 10px; }
.follow-item {
  background: var(--card-bg); border-radius: 12px; padding: 12px 14px;
  display: flex; align-items: center; gap: 12px; box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.follow-item img { width: 40px; height: 40px; border-radius: 50%; background: #e5e7eb; flex-shrink: 0; }
.f-item-info { flex: 1; min-width: 0; }
.f-item-name { font-weight: 600; font-size: 14px; }
.f-item-meta { font-size: 12px; color: var(--text-light); margin-top: 3px; word-break: break-all; }

/* 日志 */
.push-logs { max-height: 260px; overflow-y: auto; }
.log-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 0; border-bottom: 1px solid var(--border); font-size: 13px;
}
.log-item:last-child { border-bottom: none; }
.log-status { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.log-status.ok { background: var(--success); }
.log-status.fail { background: var(--danger); }
.log-msg { color: var(--text); flex: 1; min-width: 0; word-break: break-all; }
.log-time { color: #9ca3af; font-size: 12px; flex-shrink: 0; }

/* 空状态 */
.empty { text-align: center; padding: 60px 20px; color: var(--text-light); }
.empty p { font-size: 15px; }
.empty .hint { font-size: 12px; margin-top: 8px; color: #9ca3af; }

/* 提示条 */
.toast {
  position: fixed; top: calc(16px + env(safe-area-inset-top)); left: 50%; transform: translateX(-50%);
  z-index: 100; padding: 10px 18px; border-radius: 10px; color: #fff; font-size: 13px;
  box-shadow: 0 4px 12px rgba(0,0,0,.2); animation: slideDown .3s; white-space: nowrap; max-width: 90vw;
}
.toast.success { background: var(--success); }
.toast.error { background: var(--danger); }
.toast.info { background: var(--primary); }
@keyframes slideDown { from { transform: translateX(-50%) translateY(-12px); opacity: 0; } to { transform: translateX(-50%) translateY(0); opacity: 1; } }

/* 登录页 */
.login-mask {
  position: fixed; inset: 0; z-index: 200;
  background: linear-gradient(160deg, #f5f7fa 0%, #e8edf3 100%);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.login-card {
  width: 100%; max-width: 360px;
  background: #fff; border-radius: 20px;
  padding: 36px 28px 28px;
  box-shadow: 0 12px 40px rgba(31, 45, 61, .12);
  text-align: center;
  animation: popIn .25s ease;
}
.login-logo {
  width: 56px; height: 56px; margin: 0 auto 16px;
  background: var(--primary); color: #fff;
  border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; font-weight: 700;
  box-shadow: 0 6px 16px rgba(24, 60, 242, .3);
}
.login-title { font-size: 20px; font-weight: 700; color: var(--text); }
.login-sub { font-size: 13px; color: var(--text-light); margin: 6px 0 24px; }
.login-card input {
  width: 100%; box-sizing: border-box;
  padding: 12px 14px; margin-bottom: 12px;
  border: 1px solid var(--border); border-radius: 12px;
  font-size: 15px; outline: none; transition: border-color .2s;
}
.login-card input:focus { border-color: var(--primary); }
.login-btn {
  width: 100%; padding: 13px; margin-top: 4px;
  border-radius: 12px; font-size: 15px; font-weight: 600;
}
.login-error { color: var(--danger); font-size: 13px; min-height: 18px; margin: 4px 0 8px; }
.login-switch { text-align: center; font-size: 13px; color: var(--text-light); margin-top: 16px; }
.login-switch a { color: var(--primary); text-decoration: none; font-weight: 500; }
.code-row { display: flex; gap: 8px; }
.code-row input { flex: 1; }
.code-row .btn { flex-shrink: 0; align-self: flex-start; white-space: nowrap; margin-bottom: 12px; }

/* 加载中 */
.loading { text-align: center; padding: 40px; color: var(--text-light); }
.spinner {
  width: 28px; height: 28px; border: 3px solid var(--border);
  border-top-color: var(--primary); border-radius: 50%;
  margin: 0 auto 10px; animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* 底部 Tab 栏 */
.tab-bar {
  flex-shrink: 0;
  background: #fff; border-top: 1px solid var(--border);
  display: flex;
  height: calc(var(--tabbar-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
}
/* 动态详情弹窗（居中显示） */
.sheet-mask {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(0, 0, 0, .45);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
  animation: fadeIn .2s;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.sheet {
  width: 100%; max-width: 400px;
  max-height: 80vh;
  background: #fff;
  border-radius: 16px;
  display: flex; flex-direction: column;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .25);
  animation: popIn .22s ease;
}
@keyframes popIn { from { transform: scale(.92); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.sheet-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.sheet-user { display: flex; align-items: center; gap: 10px; min-width: 0; }
.sheet-user img { width: 40px; height: 40px; border-radius: 50%; background: #e5e7eb; flex-shrink: 0; }
.sheet-name { font-weight: 600; font-size: 14px; }
.sheet-meta { font-size: 12px; color: var(--text-light); margin-top: 3px; display: flex; align-items: center; gap: 6px; }
.sheet-body {
  padding: 16px; overflow-y: auto;
  display: flex; flex-direction: column; gap: 12px;
}
.sheet-title { font-size: 17px; font-weight: 700; line-height: 1.5; color: var(--text); }
.sheet-content {
  font-size: 14px; line-height: 1.75; color: var(--text);
  white-space: pre-wrap; word-break: break-word;
}
.sheet-quote {
  font-size: 13px; color: var(--text-light); line-height: 1.6;
  padding: 10px 12px; background: #f5f5f7; border-radius: 10px;
  word-break: break-word;
}
.sheet-link { display: block; text-align: center; text-decoration: none; }
.sheet-origin { color: var(--primary); background: rgba(37, 99, 235, .06); }
.sheet-reply { background: #f0fdf4; border-left: 3px solid #22c55e; }
.reply-head { font-size: 12px; color: #16a34a; font-weight: 600; margin-bottom: 4px; }
.reply-text { white-space: pre-wrap; word-break: break-word; }
.sheet-url { font-size: 12px; color: var(--text-light); word-break: break-all; }
.sheet-url a { color: var(--primary); text-decoration: none; }
.sheet-actions { display: flex; gap: 10px; margin-top: 2px; }
.sheet-actions .btn { flex: 1; justify-content: center; }
.feed-reply {
  margin-top: 8px; font-size: 12px; color: #16a34a; line-height: 1.5;
  padding: 6px 10px; background: #f0fdf4; border-radius: 8px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

.tab-bar .nav-item {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  border: none; background: transparent; cursor: pointer;
  font-size: 11px; color: #9ca3af;
}
.tab-bar .nav-item .tab-icon { font-size: 20px; line-height: 1; }
.tab-bar .nav-item.active { color: var(--primary); font-weight: 600; }

/* ---------- 屏幕尺寸分级兼容 ----------
   由 device.js 检测设备后设置 html[data-screen]（small/normal/large），
   小屏压缩间距、大屏加大间距与字号，保证不同尺寸手机显示均衡。 */
html[data-screen="small"] .page { padding: 12px 12px 20px; }
html[data-screen="small"] .card { padding: 14px; }
html[data-screen="small"] .page-header h2 { font-size: 16px; }
html[data-screen="small"] .header-title { font-size: 15px; }
html[data-screen="small"] .feed-title { font-size: 14px; }
html[data-screen="small"] .sheet-body { padding: 14px; }

html[data-screen="large"] .page { padding: 20px 20px 28px; }
html[data-screen="large"] .card { padding: 18px; }
html[data-screen="large"] .feed-title { font-size: 16px; }
html[data-screen="large"] .sheet-title { font-size: 18px; }

/* ---------- 自选股管理（需求4） ---------- */
.watch-list { display: flex; flex-direction: column; gap: 8px; }
.watch-empty {
  font-size: 13px; color: #adb5bd; text-align: center;
  padding: 12px 0; background: #f8f9fa; border-radius: 10px;
}
.watch-item {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px;
  background: #f8f9fa; border-radius: 10px; padding: 10px 12px;
}
.watch-main { flex: 1 1 100%; min-width: 0; display: flex; align-items: center; gap: 6px; }
.watch-code {
  flex-shrink: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px; font-weight: 600; color: var(--text);
}
.watch-name {
  flex: 1 1 auto; min-width: 0;
  font-size: 13px; color: #495057; line-height: 1.5;
  white-space: normal; word-break: break-all;
}
.watch-note { flex-shrink: 0; font-size: 11px; color: #adb5bd; max-width: 100%; line-height: 1.5; white-space: normal; word-break: break-all; }
.watch-quote { flex-shrink: 0; display: flex; align-items: baseline; gap: 6px; }
.watch-price { font-size: 13px; font-weight: 600; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.watch-pct { font-size: 12px; font-weight: 600; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.watch-pct.up { color: #e03131; }
.watch-pct.down { color: #2f9e44; }
.watch-pct:not(.up):not(.down) { color: #868e96; }
#card-watch .btn-sm { padding: 4px 10px; font-size: 12px; }
.watch-alert-on {
  font-size: 11px; font-weight: 600; color: #f76707;
  background: #fff4e6; border: 1px solid #ffd8a8;
  border-radius: 20px; padding: 1px 7px; white-space: nowrap;
}
.watch-alert-off {
  font-size: 12px; color: #ced4da; white-space: nowrap;
}

/* ---------- 预警记录 + 阈值编辑（todo#4） ---------- */
.header-actions { display: flex; align-items: center; gap: 8px; }
.alert-badge {
  display: inline-block; min-width: 18px; height: 18px; line-height: 18px;
  padding: 0 5px; margin-left: 4px; border-radius: 10px;
  background: #e03131; color: #fff; font-size: 11px; font-weight: 600;
  text-align: center; vertical-align: middle;
}
/* 预警记录弹窗：与主页（.phone 手机容器）同宽居中，非全屏 */
.alert-sheet {
  position: relative;
  max-width: 430px;
  width: 100%;
}
.alert-list { padding: 12px; overflow-y: auto; flex: 1; }
.alert-item {
  background: #fff; border-radius: 12px; padding: 12px 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06); margin-bottom: 10px;
  border-left: 3px solid transparent;
}
.alert-item.alert-unread { border-left-color: #f76707; background: #fff8f0; }
.alert-main {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 6px;
}
.alert-name { font-size: 15px; font-weight: 700; }
.alert-code { font-size: 12px; color: #868e96; }
.alert-dir { font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: 20px; }
.alert-dir.up { color: #e03131; background: #fff0f0; }
.alert-dir.down { color: #2f9e44; background: #ebfbee; }
.alert-info {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  font-size: 13px; color: #495057; margin-bottom: 4px;
}
.alert-info .pct { font-weight: 600; }
.alert-msg { font-size: 13px; color: #495057; line-height: 1.5; margin-bottom: 6px; }
.alert-time { font-size: 11px; color: #adb5bd; }

/* ---------- 管理员：LLM 状态 + 用户管理 ---------- */
.admin-user-list { display: flex; flex-direction: column; gap: 8px; }
.admin-user-item {
  display: flex; flex-direction: column; gap: 4px;
  background: #f8f9fa; border-radius: 10px; padding: 10px 12px;
}
.au-main { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.au-main b { font-size: 14px; }
.au-id { font-size: 12px; color: #868e96; }
.au-role {
  font-size: 11px; font-weight: 600; color: #1971c2;
  background: #e7f5ff; border-radius: 20px; padding: 1px 8px;
}
.au-sub { display: flex; gap: 12px; font-size: 12px; color: #adb5bd; }

/* ---------- 市场快讯（需求4） ---------- */
.flash-item {
  background: #fff;
  border-radius: 12px;
  padding: 12px 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
  font-size: 14px;
  line-height: 1.55;
}
.flash-head {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 6px; flex-wrap: wrap;
}
.flash-src {
  font-size: 11px; font-weight: 600;
  padding: 2px 8px; border-radius: 10px; color: #fff;
}
.flash-src.cls { background: #e03131; }        /* 财联社红 */
.flash-src.sina { background: #f08c00; }       /* 新浪橙 */
.flash-level {
  font-size: 11px; font-weight: 600;
  padding: 1px 7px; border-radius: 10px;
  color: #e03131; background: #fff5f5; border: 1px solid #ffc9c9;
}
.flash-senti {
  font-size: 11px; font-weight: 600;
  padding: 1px 7px; border-radius: 10px;
}
.flash-senti.up { color: #e03131; background: #fff5f5; }
.flash-senti.down { color: #2f9e44; background: #ebfbee; }
.flash-senti.neutral { color: #868e96; background: #f1f3f5; }
.flash-senti.mixed { color: #6741d9; background: #f3f0ff; }
.flash-time {
  margin-left: auto; font-size: 11px; color: #adb5bd;
}
.flash-title { font-weight: 600; margin-bottom: 4px; }
.flash-content { color: #495057; }
.flash-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.flash-chip {
  font-size: 11px; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  padding: 1px 7px; border-radius: 4px;
  color: #495057; background: #f1f3f5;
}
.flash-chip.flash-chip-hit {
  color: #e03131; background: #fff5f5;
  border: 1px solid #ffc9c9; font-weight: 600;
}
#flash-more { text-align: center; margin-top: 14px; }
#flash-more .btn { width: 100%; }

/* ---------- 行情分析：舆情排行 + AI日报（需求1/2） ---------- */
#market-updated { font-size: 11px; color: #adb5bd; font-weight: 400; }

/* 舆情排行 */
#page-market [id^="pane-"] .search-box { margin-top: 2px; }
#pane-hotrank .search-box { margin-top: 14px; }
.hot-item {
  display: flex; gap: 10px;
  background: #fff; border-radius: 12px; padding: 12px 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
  cursor: pointer; transition: transform .12s;
}
.hot-item:hover { transform: translateY(-1px); }
.hot-rank-badge {
  flex: none; width: 24px; height: 24px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700; color: #868e96; background: #f1f3f5;
}
.hot-rank-badge.rank-top1 { background: #fff4e6; color: #e8590c; }
.hot-rank-badge.rank-top2 { background: #fff9db; color: #f59f00; }
.hot-rank-badge.rank-top3 { background: #fff5f5; color: #e03131; }
.hot-body { flex: 1; min-width: 0; }
.hot-head {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  margin-bottom: 5px;
}
.hot-name { font-size: 14px; font-weight: 600; color: var(--text); }
.hot-code { font-size: 11px; color: #adb5bd; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.hot-industry {
  font-size: 11px; padding: 0 6px; border-radius: 4px;
  color: #1971c2; background: #e7f5ff;
}
.hot-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; }
.hot-price { font-size: 15px; font-weight: 700; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.hot-pct { font-weight: 600; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.hot-pct.up { color: #e03131; }
.hot-pct.down { color: #2f9e44; }
.hot-news { color: #868e96; }
.hot-heat { display: inline-flex; align-items: center; gap: 3px; color: #868e96; }
.heat-num { font-weight: 700; color: #f08c00; font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.heat-bar {
  flex: none; display: inline-block; width: 56px; height: 5px;
  border-radius: 3px; background: #f1f3f5; overflow: hidden; vertical-align: middle;
}
.heat-bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, #ffd43b, #f08c00); }
.hot-anno {
  font-size: 10px; font-weight: 600; padding: 0 5px; border-radius: 4px;
  color: #6741d9; background: #f3f0ff;
}
.hot-anno.rule { color: #868e96; background: #f1f3f5; }
.hot-titles { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 3px; }
.hot-title {
  font-size: 12px; color: #495057; line-height: 1.5;
  padding-left: 10px; position: relative;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.hot-title::before { content: ""; position: absolute; left: 0; top: 7px; width: 4px; height: 4px; border-radius: 50%; background: #ced4da; }

/* AI日报 Markdown */
.report-body {
  background: #fff; border-radius: 12px; padding: 16px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
  font-size: 13.5px; line-height: 1.7; color: #343a40;
  word-break: break-word;
}
.report-body h1 { font-size: 17px; font-weight: 700; margin: 6px 0 10px; color: var(--text); }
.report-body h2 {
  font-size: 15px; font-weight: 700; margin: 16px 0 8px; color: var(--text);
  padding-left: 8px; border-left: 3px solid var(--primary);
}
.report-body h3 { font-size: 14px; font-weight: 600; margin: 12px 0 6px; }
.report-body p { margin: 6px 0; }
.report-body ul, .report-body ol { margin: 6px 0 6px 2px; padding-left: 20px; }
.report-body li { margin: 3px 0; }
.report-body strong { color: var(--text); font-weight: 600; }
.report-body blockquote {
  margin: 8px 0; padding: 6px 12px; color: #495057;
  background: #f8f9fa; border-left: 3px solid #dee2e6; border-radius: 0 8px 8px 0;
}
.report-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px; background: #f1f3f5; padding: 1px 5px; border-radius: 4px;
  color: #c92a2a;
}
.report-body a { color: var(--primary); text-decoration: underline; }
.report-body hr { border: none; border-top: 1px solid #dee2e6; margin: 12px 0; }

/* ---------- 个股行情详情 ---------- */
.stock-detail {
  position: absolute; top: 0; left: 0; right: 0; bottom: 0;
  background: var(--bg); z-index: 120;
  display: flex; flex-direction: column;
  animation: sdSlideIn .22s ease;
}
@keyframes sdSlideIn {
  from { transform: translateX(100%); }
  to { transform: translateX(0); }
}
.sd-head {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 12px 10px;
  background: #fff; border-bottom: 1px solid var(--border);
}
.sd-title { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.sd-name { font-size: 17px; font-weight: 700; color: var(--text); }
.sd-code { font-size: 12px; color: var(--text-light); }
.sd-price-box { text-align: right; }
.sd-price { font-size: 20px; font-weight: 700; }
.sd-pct { font-size: 13px; display: block; }
.sd-metrics {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 1px;
  background: #eee; padding: 1px;
}
.sd-metric {
  background: #fff; padding: 8px 6px; text-align: center;
  display: flex; flex-direction: column; gap: 3px;
}
.sd-metric span { font-size: 11px; color: var(--text-light); }
.sd-metric b { font-size: 12.5px; color: var(--text); font-weight: 600; }
.sd-tabs {
  display: flex; background: #fff; border-bottom: 1px solid var(--border);
}
.sd-tabs .tab { flex: 1; }
.sd-body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sd-pane { padding: 10px 12px 24px; }
.sd-chart-wrap {
  background: #fff; border-radius: 12px; padding: 8px 6px 4px;
  margin-bottom: 10px; box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.sd-chart-wrap canvas { display: block; width: 100%; }
.sd-legend {
  display: flex; gap: 14px; align-items: center;
  padding: 6px 8px 8px; font-size: 12px; color: var(--text-light);
}
.sd-legend .lg { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.sd-legend .square { width: 10px; height: 10px; display: inline-block; border-radius: 2px; }
.sd-legend .square.up { background: #e53935; }
.sd-legend .square.down { background: #089981; }
.sd-periods { display: flex; gap: 8px; margin-bottom: 10px; }
.sd-periods .mini {
  flex: 1; padding: 8px 0; border: 1px solid var(--border); border-radius: 8px;
  background: #fff; color: var(--text-light); font-size: 13px; cursor: pointer;
}
.sd-periods .mini.active { border-color: var(--primary); color: var(--primary); background: rgba(26,115,232,.06); font-weight: 600; }
.sd-loading {
  position: absolute; inset: 0; background: rgba(242,243,247,.85);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px; z-index: 5; font-size: 13px; color: var(--text-light);
}
.sd-fund-list { margin-top: 4px; }
.sd-fund-head, .sd-fund-row {
  display: grid; grid-template-columns: 1.2fr repeat(5, 1fr); gap: 4px;
  font-size: 11px; padding: 7px 4px; align-items: center; text-align: right;
}
.sd-fund-head {
  color: var(--text-light); font-weight: 600;
  background: #fff; border-radius: 8px 8px 0 0; border-bottom: 1px solid var(--border);
}
.sd-fund-row { border-bottom: 1px solid #f0f0f0; }
.sd-fund-row span:first-child { text-align: left; color: var(--text-light); }
.sd-fund-row .up { color: #e53935; }
.sd-fund-row .down { color: #089981; }
.sd-rzrq-table {
  background: #fff; border-radius: 12px; overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.sd-rzrq-head, .sd-rzrq-row {
  display: grid; grid-template-columns: 1.1fr 1fr 1fr 1fr 1fr 1.2fr;
  gap: 2px; font-size: 11px; padding: 8px 6px; align-items: center; text-align: right;
}
.sd-rzrq-head {
  color: var(--text-light); font-weight: 600;
  background: #f8f9fa; border-bottom: 1px solid var(--border);
  position: sticky; top: 0;
}
.sd-rzrq-row span:first-child { text-align: left; color: var(--text-light); }
.sd-rzrq-row .up { color: #e53935; }
.sd-rzrq-row .down { color: #089981; }
.sd-pane-rzrq-wrap { max-height: 60vh; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.sd-senti-card {
  background: #fff; border-radius: 12px; padding: 12px;
  display: flex; flex-direction: column; gap: 6px;
  box-shadow: 0 1px 4px rgba(0,0,0,.05);
}
.sd-senti-sum { font-size: 13.5px; color: var(--text); line-height: 1.6; }
.sd-news-group { margin-top: 14px; }
.sd-news-title { font-size: 14px; font-weight: 700; margin-bottom: 8px; }
.sd-news-item {
  display: flex; gap: 8px; padding: 10px 4px;
  border-bottom: 1px solid #f0f0f0; text-decoration: none;
  background: #fff; border-radius: 4px;
}
.sd-news-date { color: var(--text-light); font-size: 11px; white-space: nowrap; padding-top: 2px; }
.sd-news-text { color: var(--text); font-size: 13.5px; line-height: 1.5; flex: 1; }

/* 智能体分析 */
.sd-agents-empty { padding: 32px 16px; text-align: center; display: flex; flex-direction: column; gap: 12px; }
.sd-agents-empty .btn { margin: 0 auto; }
.sd-agents-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.sd-agents-verdict {
  background: #fff; border-radius: 12px; padding: 14px;
  box-shadow: 0 1px 4px rgba(0,0,0,.05); margin-bottom: 14px;
}
.sd-agents-verdict-main { display: flex; gap: 12px; align-items: flex-start; }
.sd-agents-verdict-main .flash-senti.big { font-size: 18px; padding: 8px 16px; flex-shrink: 0; }
.sd-agents-conf { font-size: 12.5px; color: var(--text-light); margin-bottom: 6px; }
.sd-agents-rationale { font-size: 13.5px; color: var(--text); line-height: 1.6; }
.sd-agents-reflection {
  margin-top: 12px; padding: 10px 12px; border-radius: 10px;
  background: #f6f8ff; border: 1px solid #e3e9ff;
}
.sd-agents-reflection b { font-size: 13px; color: #4a66e0; }
.sd-agents-reflection p { font-size: 13px; color: var(--text); line-height: 1.6; margin-top: 4px; }
.sd-agents-section-title { font-size: 14px; font-weight: 700; margin: 16px 0 8px; }
.sd-ana-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sd-ana-card { background: #fff; border-radius: 10px; padding: 10px; box-shadow: 0 1px 4px rgba(0,0,0,.05); }
.sd-ana-head { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.sd-ana-head b { font-size: 13px; flex: 1; }
.sd-ana-pts { margin: 0; padding-left: 18px; font-size: 12.5px; color: var(--text); line-height: 1.6; }
.sd-ana-sum { margin-top: 6px; font-size: 12px; color: var(--text-light); line-height: 1.5; }
.sd-debate-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sd-debate-card { border-radius: 10px; padding: 10px; font-size: 13px; line-height: 1.6; }
.sd-debate-card b { display: block; margin-bottom: 4px; font-size: 13px; }
.sd-debate-card ul { margin: 0; padding-left: 16px; }
.sd-debate-card.bull { background: #fff5f5; border: 1px solid #ffdcdc; }
.sd-debate-card.bull b { color: #e04141; }
.sd-debate-card.bear { background: #f0f7f0; border: 1px solid #d5e8d5; }
.sd-debate-card.bear b { color: #2e9e4f; }
.sd-consensus {
  margin-top: 8px; padding: 10px 12px; border-radius: 10px;
  background: #fafafa; border: 1px solid #eee; font-size: 13px; line-height: 1.6;
}
.sd-agents-targets { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 10px; font-size: 13px; }
.sd-agents-targets span { background: #fff; border: 1px solid #eee; border-radius: 8px; padding: 6px 10px; }
.sd-agents-targets b { color: var(--primary, #4a66e0); }
.sd-mem-list { display: flex; flex-direction: column; gap: 6px; }
.sd-mem-item { display: flex; align-items: center; gap: 8px; background: #fff; border-radius: 8px; padding: 8px 10px; font-size: 12.5px; box-shadow: 0 1px 3px rgba(0,0,0,.04); }
.sd-mem-date { color: var(--text-light); white-space: nowrap; }

/* 必须放在文件末尾：覆盖早期基础样式，确保深色模式中的导航与操作始终高对比。 */
@media (prefers-color-scheme: dark) {
  .tabs, .settings-tabs, .sd-tabs { background:#0b1220 !important; border:1px solid #40516b; }
  .tab, .tabs .tab, .settings-tabs .tab, .sd-tabs .tab { color:#e5edf9 !important; background:transparent !important; font-weight:600; }
  .tab.active, .tabs .tab.active, .settings-tabs .tab.active, .sd-tabs .tab.active { color:#fff !important; background:#635bdf !important; box-shadow:0 2px 8px rgba(99,91,223,.5) !important; }
  .btn, .btn-header { color:#f8fbff !important; background:#24344d !important; border-color:#7186a5 !important; font-weight:600; }
  .btn-primary { background:#5b55da !important; border-color:#817bff !important; color:#fff !important; }
  .btn-danger { color:#fff !important; background:#9b2c45 !important; border-color:#ff8298 !important; }
  .header-actions .card-hint, .alert-badge { color:#fff !important; }
  .alert-badge { background:#dc3545 !important; border:1px solid #ffb0bb; }
  .page-header h2, .section-title, .card-title { color:#fff; }
  .card, .feed-item, .follow-item, .watch-item, .flash-item, .hot-item { border:1px solid #354863; }

  /* 动态详情：弹层、正文、引用和链接全部采用深底亮字，避免二级页沿用浅色样式。 */
  .sheet-mask { background:rgba(2, 6, 23, .78); }
  .sheet { background:#151f2e; border:1px solid #5a708f; box-shadow:0 20px 56px rgba(0, 0, 0, .55); }
  .sheet-head { border-bottom-color:#435874; }
  .sheet-name, .sheet-title, .sheet-content, .reply-text { color:#f8fbff; }
  .sheet-meta, .sheet-url { color:#c8d6e9; }
  .sheet-quote { color:#edf4ff; background:#24344c; border:1px solid #4f6684; }
  .sheet-origin { color:#e1edff; background:#203c65; border-left:3px solid #7eb0ff; }
  .sheet-reply { color:#effff3; background:#173d32; border-color:#397d62; border-left:3px solid #63d69a; }
  .reply-head { color:#a8f5c6; }
  .sheet-url a { color:#b9caff; text-decoration:underline; text-underline-offset:2px; }
  .sheet .feed-tag.post { color:#dceaff; background:#1d4f8f; }
  .sheet .feed-tag.comment { color:#ebddff; background:#5a3a8e; }

  /* 全页组件审计：清除固定浅底造成的弱对比，统一使用深色表面 + 亮色文字。 */
  .tab-bar, .sd-head, .sd-metric, .sd-chart-wrap, .sd-fund-head, .sd-rzrq-table,
  .sd-senti-card, .sd-news-item, .sd-agents-verdict, .sd-ana-card, .sd-mem-item,
  .sd-agents-targets span, .report-body, .login-card, .alert-item, .admin-user-item,
  .watch-item, .flash-item, .hot-item { background:#172334; border-color:#405775; }
  .watch-empty, .flash-chip, .flash-senti.neutral, .hot-rank-badge, .hot-anno.rule,
  .heat-bar, .report-body blockquote, .report-body code, .sd-rzrq-head, .sd-consensus {
    background:#223248; border-color:#4d6686; color:#e8f0fc;
  }
  .resolve-card { background:#153455; border-color:#4e91dc; color:#edf6ff; }
  .resolve-card .r-name, .resolve-card .r-meta { color:#edf6ff; }
  .login-mask { background:linear-gradient(160deg, #09111e 0%, #17263a 100%); }
  .login-title, .login-card input { color:#f8fbff; }
  .login-card input { background:#101a29; border-color:#5b7190; }
  .login-sub, .login-switch { color:#c7d5e8; }
  .radio span { background:#182536; border-color:#5a718f; color:#e7effc; }
  .radio input:checked + span { background:#263f6b; border-color:#82b1ff; color:#fff; }
  .di-row span, .watch-name, .alert-info, .alert-msg, .flash-content, .hot-title,
  .report-body, .report-body blockquote, .sd-senti-sum, .sd-agents-rationale,
  .sd-agents-reflection p, .sd-ana-pts, .sd-debate-card, .sd-news-text { color:#edf4ff; }
  .watch-note, .watch-alert-off, .alert-code, .alert-time, .au-id, .au-sub,
  .flash-time, #market-updated, .hot-code, .hot-news, .hot-heat, .sd-legend,
  .sd-fund-head, .sd-fund-row span:first-child, .sd-rzrq-head, .sd-rzrq-row span:first-child,
  .sd-news-date, .sd-agents-conf, .sd-ana-sum, .sd-mem-date, .log-time { color:#c5d3e6; }
  .watch-alert-on { background:#533a13; border-color:#c48625; color:#ffe0a1; }
  .alert-item.alert-unread { background:#3b2c1a; border-left-color:#ffc166; }
  .alert-dir.up, .flash-level, .flash-senti.up, .flash-chip.flash-chip-hit {
    color:#ffd0d0; background:#552a35; border-color:#bd6575;
  }
  .alert-dir.down, .flash-senti.down { color:#bcf4d1; background:#1c4938; border-color:#4d9b76; }
  .flash-senti.mixed, .hot-anno { color:#e5d7ff; background:#46346f; }
  .hot-rank-badge.rank-top1 { background:#5a3b16; color:#ffe0a0; }
  .hot-rank-badge.rank-top2 { background:#514115; color:#ffe58e; }
  .hot-rank-badge.rank-top3 { background:#5a2934; color:#ffc6d0; }
  .hot-industry, .au-role { color:#d6e8ff; background:#1f4b78; }
  .hot-title::before { background:#91a8c6; }
  .heat-num { color:#ffd07a; }
  .report-body h1, .report-body h2, .report-body h3, .report-body strong { color:#fff; }
  .report-body hr { border-top-color:#4c6380; }

  /* 行情详情及其二级标签页。 */
  .stock-detail { background:#101722; }
  .sd-head, .sd-tabs { background:#172334; border-color:#405775; }
  .sd-metrics { background:#405775; }
  .sd-metric { background:#172334; }
  .sd-metric span, .sd-code { color:#c5d3e6; }
  .sd-metric b, .sd-name, .sd-news-title, .sd-ana-head b { color:#f7fbff; }
  .sd-periods .mini { background:#1a283b; border-color:#59708f; color:#dce8f8; }
  .sd-periods .mini.active { color:#fff; background:#304b79; border-color:#8cb8ff; }
  .sd-loading { background:rgba(10, 18, 31, .9); color:#eaf2ff; }
  .sd-fund-row, .sd-news-item { border-bottom-color:#405775; }
  .sd-rzrq-head { border-bottom-color:#526b8c; }
  .sd-agents-reflection { background:#1d3153; border-color:#516f9b; }
  .sd-agents-reflection b { color:#b9c9ff; }
  .sd-debate-card.bull { background:#4b2832; border-color:#9f596a; color:#ffe8ec; }
  .sd-debate-card.bull b { color:#ffbdc8; }
  .sd-debate-card.bear { background:#1d4637; border-color:#4e9073; color:#dcffe9; }
  .sd-debate-card.bear b { color:#a8f0c6; }
  .sd-agents-targets span { color:#eaf2ff; }

  /* 深色表面上的语义色须偏亮，避免红绿橙紫仍按浅色页面的色阶显示。 */
  .content-type.post { color:#a9caff; }
  .content-type.comment { color:#d8bdff; }
  .feed-tag.post { color:#dceaff; background:#1d4f8f; }
  .feed-tag.comment { color:#ebddff; background:#5a3a8e; }
  .feed-reply { color:#d9ffea; background:#1b4939; border:1px solid #4b9b77; }
  .flash-src.cls { background:#b82b3d; }
  .flash-src.sina { background:#9a5006; }
  .watch-pct.up, .hot-pct.up, .sd-fund-row .up, .sd-rzrq-row .up { color:#ff9da9; }
  .watch-pct.down, .hot-pct.down, .sd-fund-row .down, .sd-rzrq-row .down { color:#82e8b5; }
  .report-body a { color:#9cc7ff; }

  /* 原生下拉控件：行情榜单、主力资金、板块资金及设置页共用。 */
  .search-box select, .form-row select {
    color-scheme:dark;
    background-color:#111a27 !important;
    color:#f6f9ff !important;
    border-color:#7186a5 !important;
  }
  .search-box select:focus, .form-row select:focus {
    background-color:#16243a !important;
    border-color:#9ec5ff !important;
    box-shadow:0 0 0 3px rgba(126, 176, 255, .22);
  }
  .search-box select option, .form-row select option, .search-box select optgroup, .form-row select optgroup {
    background:#111a27;
    color:#f6f9ff;
  }
  .search-box select option:checked, .form-row select option:checked {
    background:#425d91;
    color:#fff;
  }
}

/* ICP 备案信息底部栏 */
.icp-footer {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  text-align: center;
  padding: 4px 8px;
  font-size: 11px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.55);
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 50;
  pointer-events: auto;
}
.icp-footer a {
  color: rgba(255, 255, 255, 0.85);
  text-decoration: none;
  margin: 0 4px;
}
.icp-footer a:hover {
  text-decoration: underline;
}
/* 给主内容区底部留出空间避免被遮挡 */
.phone { margin-bottom: 28px; }
@media (max-width: 480px) {
  .icp-footer { font-size: 10px; padding: 3px 6px; }
  .phone { margin-bottom: 22px; }
}
