:root {
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --secondary: #64748b;
  --accent: #f59e0b;
  --page-bg: #f1f5f9;
  --light-bg: #f8fafc;
  --text: #1e293b;
  --muted: #64748b;
  --border: #e2e8f0;
  --card: #ffffff;
  --shadow: 0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,.1), 0 4px 6px -2px rgba(0,0,0,.05);
  --radius: 0.75rem;
  --radius-sm: 0.5rem;
  --ok: #16a34a;
  --danger: #dc2626;
  --x2wb: #0284c7;
  --wb2x: #db2777;
  --both: #7c3aed;
  --font: "PingFang SC", "Noto Sans SC", "HarmonyOS Sans SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  --mono: "SF Mono", "JetBrains Mono", ui-monospace, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body {
  margin: 0; padding: 0;
  background: var(--page-bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.55;
  min-height: 100%;
}
a { color: var(--primary); text-decoration: none; transition: color .15s; }
a:hover { color: var(--primary-dark); }

.container {
  max-width: 920px;
  margin: 0 auto;
  padding: 20px 18px 64px;
}

/* —— Site header (blue gradient) + white nav —— */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}
.site-header-inner {
  max-width: 920px; margin: 0 auto;
  padding: 14px 18px 12px;
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.site-title {
  margin: 0; font-size: 1.35rem; font-weight: 750;
  color: #fff !important; letter-spacing: 0.02em;
  text-decoration: none;
}
.site-title:hover { color: #fff !important; opacity: 0.92; }
.site-tagline {
  font-size: 0.78rem; font-weight: 500;
  color: rgba(255,255,255,0.85); letter-spacing: 0.04em;
}

.nav {
  background: transparent;
  border: 0;
  margin: -6px 0 0;
  position: relative; z-index: 40;
}
.nav-inner {
  max-width: 920px; margin: 0 auto;
  padding: 0 18px 14px;
}
.nav-links {
  display: flex; align-items: center; gap: 6px; flex-wrap: wrap;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 8px 10px;
}
.nav-links a, .nav-links button {
  color: var(--text); background: transparent; border: 0; cursor: pointer;
  font-size: 0.9rem; padding: 8px 14px; border-radius: 999px;
  font-family: inherit; font-weight: 550; transition: .15s;
}
.nav-links a.active {
  color: var(--primary);
  background: rgba(37, 99, 235, 0.1);
}
.nav-links a:hover, .nav-links button:hover {
  color: var(--primary);
  background: var(--light-bg);
}
.nav-links .user-chip {
  color: var(--muted); font-size: 0.82rem;
  padding: 6px 12px; border-radius: 999px;
  border: 1px solid var(--border); background: var(--light-bg);
  margin-left: auto;
}

/* legacy brand aliases */
.brand { display: flex; flex-direction: column; gap: 1px; }
.brand-mark { font-size: 1.12rem; font-weight: 700; color: #fff; }
.brand-tag { font-size: 0.68rem; color: rgba(255,255,255,.8); }

/* —— Cards —— */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
  position: relative;
  transition: transform .15s, box-shadow .15s, border-color .15s;
}
.card.gap-card {
  padding: 1.5rem 1.75rem;
  margin-bottom: 1.5rem !important;
  scroll-margin-top: 16px;
}
.card.gap-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  border-color: #cbd5e1;
}

/* Article-list row (thumb + body) */
.article-row {
  display: flex; gap: 1.1rem; align-items: flex-start;
}
.article-thumb {
  flex: 0 0 auto;
  width: 200px; height: 140px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--light-bg);
  border: 1px solid var(--border);
}
.article-thumb-ph {
  width: 200px; height: 140px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, #dbeafe, #f1f5f9);
  border: 1px solid var(--border);
  flex: 0 0 auto;
  display: flex; align-items: center; justify-content: center;
  color: #64748b; font-size: 0.78rem; font-weight: 650;
}
.article-thumb-ph::after { content: "封面"; }
.article-body { min-width: 0; flex: 1; }
.article-summary {
  margin: 0.4rem 0 0;
  color: var(--muted); font-size: 0.9rem; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}
.article-meta {
  margin-top: 0.55rem;
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center;
  font-size: 0.78rem; color: var(--muted);
}
.article-meta a { color: var(--primary); font-weight: 550; }

/* —— Feed hero —— */
.feed-hero {
  margin: 4px 0 1.25rem;
  padding: 1.35rem 1.5rem;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.feed-hero-top {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 12px; flex-wrap: wrap; margin-bottom: 10px;
}
.feed-hero h1 {
  margin: 0 0 6px; font-size: 1.4rem; font-weight: 750;
  color: var(--text);
}
.feed-hero .tagline {
  margin: 0; color: var(--muted); font-size: 0.92rem;
}
.meta-bar { display: flex; flex-wrap: wrap; gap: 8px; }
.meta-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 999px;
  font-size: 0.8rem; color: var(--muted);
  background: var(--light-bg);
  border: 1px solid var(--border);
}
.meta-pill strong { color: var(--primary); font-weight: 650; }

.section-label {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: 1.25rem 0 1rem !important;
}
.section-label h2 {
  margin: 0; font-size: 1.05rem; font-weight: 700;
  color: var(--text);
}
.section-label span { font-size: 0.78rem; color: var(--muted); }

.featured-head {
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 0.65rem !important;
}
.featured-title-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}

/* —— 最后更新徽章 —— */
.updated-badge {
  display: inline-flex; align-items: baseline; gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: #fffbeb;
  border: 1px solid #fcd34d;
  color: #92400e;
  line-height: 1.2;
  box-shadow: 0 1px 0 rgba(245, 158, 11, 0.16);
}
.updated-kicker {
  font-size: 0.68rem; font-weight: 750; letter-spacing: 0.12em;
  text-transform: none; color: #b45309;
}
.updated-badge strong {
  font-size: 0.95rem; font-weight: 750; color: #78350f;
  font-variant-numeric: tabular-nums;
}
.updated-badge-nav {
  margin-left: auto;
  background: rgba(255, 251, 235, 0.95);
  border-color: rgba(253, 224, 71, 0.85);
  padding: 6px 12px;
}
.updated-badge-hero {
  padding: 10px 16px;
  background: linear-gradient(180deg, #fffbeb 0%, #fef3c7 100%);
  border-color: #fbbf24;
}
.updated-badge-hero .updated-kicker { font-size: 0.72rem; }
.updated-badge-hero strong { font-size: 1.12rem; }
.updated-badge-inline {
  padding: 5px 12px;
}
.updated-badge-inline strong { font-size: 0.86rem; }

/* —— 精选流向选项卡 —— */
.feed-tabs {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin: 0 0 1.1rem;
  padding: 6px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  box-shadow: var(--shadow);
  width: fit-content;
  max-width: 100%;
}
.feed-tab {
  appearance: none; border: 0; cursor: pointer;
  font-family: inherit; font-weight: 650; font-size: 0.9rem;
  padding: 9px 16px; border-radius: 999px;
  color: var(--muted); background: transparent;
  display: inline-flex; align-items: center; gap: 8px;
  transition: background .15s, color .15s, box-shadow .15s;
}
.feed-tab em {
  font-style: normal; font-size: 0.74rem; font-weight: 750;
  min-width: 1.4em; padding: 1px 7px; border-radius: 999px;
  background: var(--light-bg); color: var(--muted);
  border: 1px solid var(--border);
}
.feed-tab:hover { color: var(--primary); background: var(--light-bg); }
.feed-tab.active {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.28);
}
.feed-tab.active em {
  background: rgba(255,255,255,0.18);
  color: #fff;
  border-color: transparent;
}
.feed-tab[data-feed-tab="wb2x"].active {
  background: linear-gradient(135deg, #db2777, #be185d);
  box-shadow: 0 2px 8px rgba(219, 39, 119, 0.28);
}
.gap-card[hidden] { display: none !important; }

/* —— Badges / pills —— */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 11px; border-radius: 999px;
  font-size: 0.74rem; font-weight: 650; letter-spacing: 0.01em;
  background: var(--light-bg); color: var(--muted);
  border: 1px solid var(--border);
}
.badge.x2wb {
  background: #e0f2fe; color: var(--x2wb);
  border-color: #bae6fd;
}
.badge.wb2x {
  background: #fce7f3; color: var(--wb2x);
  border-color: #fbcfe8;
}
.badge.both {
  background: #ede9fe; color: var(--both);
  border-color: #ddd6fe;
}
.badge.level {
  background: #fffbeb; color: #b45309;
  border-color: #fde68a;
}
.badge.ctype.image {
  background: #eff6ff; color: var(--primary);
  border-color: #bfdbfe;
}
.badge.ctype.video {
  background: #ecfeff; color: #0891b2;
  border-color: #a5f3fc;
}
.badge.ctype.mixed {
  background: #f5f3ff; color: var(--both);
  border-color: #ddd6fe;
}

.gap-head { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 8px; }
.gap-title {
  margin: 0 0 0.5rem; font-size: 1.12rem; line-height: 1.4;
  font-weight: 700; color: var(--text);
}
.gap-card .gap-title { margin-bottom: 0.35rem; }
.label-mini {
  color: var(--muted); font-size: 0.72rem; margin-bottom: 6px;
  letter-spacing: 0.06em; font-weight: 650;
}
.gap-reason, .ai-draft {
  margin: 0 0 14px; padding: 12px 14px; border-radius: var(--radius-sm);
  background: var(--light-bg);
  border: 1px solid var(--border);
  color: var(--text); font-size: 0.92rem; line-height: 1.6;
}
.ai-draft {
  border-left: 3px solid var(--primary);
  background: #eff6ff;
  border-color: #bfdbfe;
  white-space: pre-wrap;
  font-size: 0.94rem;
}

/* —— 犀利观点（浅色资讯风醒目金句块） —— */
.sharp-block {
  margin: 1rem 0 0.5rem;
  padding: 12px 14px 12px;
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, #fff7ed 0%, #fffbeb 100%);
  border: 1px solid #fcd34d;
  box-shadow: 0 1px 0 rgba(245, 158, 11, 0.12);
}
.sharp-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; margin-bottom: 8px;
}
.sharp-head .label-mini {
  margin-bottom: 0;
  color: #b45309;
  letter-spacing: 0.12em;
  font-weight: 750;
}
.sharp-head .label-mini::before {
  content: "✦ ";
  color: var(--accent);
}
.sharp-copy {
  padding: 4px 12px; font-size: 0.72rem;
  color: #92400e !important;
  border-color: #fbbf24 !important;
  background: #fff !important;
}
.sharp-copy:hover {
  color: #78350f !important;
  border-color: #f59e0b !important;
  background: #fef3c7 !important;
}
.sharp-take {
  margin: 0;
  padding: 4px 2px 2px 36px;
  position: relative;
  border: 0;
  background: transparent;
  color: #1c1917;
  font-size: 1.05rem; font-weight: 700; line-height: 1.7;
  quotes: none;
}
.sharp-take::before {
  content: "“";
  position: absolute; left: 2px; top: -6px;
  font-size: 2rem; line-height: 1;
  color: #f59e0b; font-weight: 700;
  font-family: Georgia, "Songti SC", serif;
}
.source {
  font-size: 0.82rem; color: var(--muted); margin: 0 0 4px;
}
.actions {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px;
}

/* —— Buttons —— */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: 999px; padding: 10px 16px; cursor: pointer;
  font-size: 0.88rem; font-weight: 650; font-family: inherit;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.28);
  transition: transform .12s, filter .12s, box-shadow .12s;
}
.btn:hover { filter: brightness(1.05); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn.block { width: 100%; margin-top: 18px; padding: 13px; border-radius: 12px; }
.btn.ghost {
  background: var(--card); color: var(--text);
  border: 1px solid var(--border);
  box-shadow: none;
}
.btn.ghost:hover {
  color: var(--primary); border-color: #bfdbfe;
  background: #eff6ff;
}
.btn.ok {
  background: linear-gradient(135deg, #22c55e, var(--ok));
  color: #fff; box-shadow: 0 2px 8px rgba(22, 163, 74, 0.28);
}
.btn.sm { padding: 8px 13px; font-size: 0.8rem; }
.btn.primary-cta { padding: 9px 16px; }
.btn.is-loading, .btn:disabled {
  opacity: 0.72; cursor: wait; filter: none; transform: none;
}

/* —— 对照榜 —— */
.trends-secondary {
  margin: 8px 0 1.75rem;
  padding: 1.15rem 1.25rem 1.25rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--card);
  box-shadow: var(--shadow);
}
.trends-secondary .trends-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 12px;
}
.trends-secondary .trends-head h3 {
  margin: 0; font-size: 0.95rem; font-weight: 700;
  color: var(--text);
}
.trends {
  display: grid; grid-template-columns: 1fr 1fr; gap: 1rem !important;
}
.trends .mini-panel {
  margin: 0; padding: 12px 12px 14px;
  background: var(--light-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
}
.trends .mini-panel h4 {
  margin: 0 0 10px; font-size: 0.82rem; color: var(--muted); font-weight: 650;
}
.trend-list {
  list-style: none;
  margin: 0; padding: 0;
  display: flex; flex-direction: column; gap: 12px;
  color: var(--muted); font-size: 0.82rem;
}
.trend-row {
  display: flex; align-items: flex-start; gap: 10px;
  margin: 0 !important;
  padding: 12px !important;
  line-height: 1.4;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--card);
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
  transition: transform .12s, box-shadow .12s;
}
.trend-row:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}
.trend-row .rank {
  flex: 0 0 auto;
  min-width: 1.6em; width: 1.6em;
  font-family: var(--mono);
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  color: var(--primary);
  text-align: right;
}
.trend-row a, .trend-row .trend-title {
  flex: 1 1 auto; min-width: 0; color: var(--text);
}
.trend-row a:hover { color: var(--primary); }
.trend-row.muted { color: var(--muted); padding-left: calc(1.6em + 8px); }
.trend-body { flex: 1 1 auto; min-width: 0; }
.trend-title-line { line-height: 1.35; }
.trend-topic { color: var(--text); font-weight: 650; display: inline; }
span.trend-topic { cursor: default; }
a.trend-topic:hover { color: var(--primary); }
.trend-orig {
  display: block;
  margin-top: 3px;
  font-size: .75rem;
  line-height: 1.3;
  color: var(--muted);
  font-weight: 500;
}
.gap-legend { color: #dc2626; font-style: normal; font-weight: 700; }
.trend-row.is-gap {
  border-color: #fecaca;
  background: #fff5f5;
  box-shadow: 0 0 0 1px rgba(220, 38, 38, .08);
}
.trend-row.is-gap .rank,
.trend-row.is-gap .trend-topic {
  color: #dc2626;
}
.trend-row.is-gap a.trend-topic:hover { color: #b91c1c; }
.trend-gap-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 999px;
  border: 1px solid #fecaca;
  background: #fee2e2;
  color: #dc2626;
  font-size: .68rem;
  font-weight: 700;
  vertical-align: middle;
  letter-spacing: .02em;
  text-decoration: none;
}
a.trend-gap-tag:hover { color: #b91c1c; background: #fecaca; }

/* —— Auth —— */
.auth-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  background: var(--page-bg);
}
.auth-hero {
  position: relative;
  padding: 48px 40px;
  display: flex; flex-direction: column; justify-content: center;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: #fff;
  overflow: hidden;
}
.auth-hero::after {
  content: "";
  position: absolute; inset: auto -20% -30% 20%;
  height: 60%;
  background: radial-gradient(ellipse, rgba(255,255,255,0.12), transparent 70%);
  pointer-events: none;
}
.auth-kicker {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border-radius: 999px; width: fit-content;
  font-size: 0.75rem; color: #fff;
  border: 1px solid rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.12);
  margin-bottom: 18px; letter-spacing: 0.04em;
}
.auth-hero h1 {
  margin: 0 0 12px; font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 750; line-height: 1.2; color: #fff;
}
.auth-hero h1 em {
  font-style: normal;
  color: #fde68a;
}
.auth-hero p.lead {
  margin: 0 0 28px; color: rgba(255,255,255,0.9); font-size: 1.02rem;
  max-width: 420px; line-height: 1.65;
}
.auth-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.auth-points li {
  display: flex; gap: 10px; align-items: flex-start;
  color: rgba(255,255,255,0.88); font-size: 0.9rem;
}
.auth-points li::before {
  content: "";
  width: 8px; height: 8px; margin-top: 7px; flex-shrink: 0;
  border-radius: 50%;
  background: #fbbf24;
  box-shadow: 0 0 0 3px rgba(251, 191, 36, 0.25);
}
.auth-panel {
  display: flex; align-items: center; justify-content: center;
  padding: 36px 28px;
  background: var(--page-bg);
}
.auth-box {
  width: 100%; max-width: 400px;
  padding: 28px 26px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
}
.auth-box h2 {
  margin: 0 0 6px; font-size: 1.35rem; font-weight: 700; color: var(--text);
}
.auth-box p.sub {
  margin: 0 0 20px; color: var(--muted); font-size: 0.9rem;
}
label {
  display: block; margin: 14px 0 7px;
  color: var(--muted); font-size: 0.82rem; font-weight: 550;
}
input {
  width: 100%; padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--card); color: var(--text);
  font-size: 1rem; font-family: inherit;
  transition: border-color .15s, box-shadow .15s;
}
input::placeholder { color: #94a3b8; }
input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.18);
}
.msg { margin-top: 12px; color: var(--danger); font-size: 0.88rem; min-height: 1.2em; }
.auth-foot {
  margin-top: 18px; font-size: 0.88rem; color: var(--muted); text-align: center;
}

/* —— Misc —— */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(8px);
  background: var(--text); color: #fff; padding: 11px 18px; border-radius: 999px;
  border: 0; opacity: 0; pointer-events: none;
  transition: .22s; z-index: 80; font-size: 0.88rem;
  box-shadow: var(--shadow-lg);
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.empty {
  text-align: center; color: var(--muted);
  padding: 48px 16px; font-size: 0.95rem;
}

/* —— Card media —— */
.gap-media {
  position: relative;
  margin: 0 0 14px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--light-bg);
  aspect-ratio: 16 / 9;
}
.gap-media.is-video { aspect-ratio: 4 / 5; max-height: 420px; }
.gap-media.is-image { max-height: 220px; }
@media (min-width: 640px) {
  .gap-media.is-video { aspect-ratio: 16 / 9; max-height: none; }
}
.gap-cover {
  display: block; width: 100%; height: 100%;
  object-fit: cover; background: var(--light-bg);
  max-height: 220px;
}
.gap-cover-fallback {
  width: 100%; height: 100%; min-height: 120px;
  background: linear-gradient(135deg, #dbeafe, #f1f5f9);
  display: flex; align-items: center; justify-content: center;
  color: #64748b; font-size: 0.82rem; font-weight: 650;
}
.gap-cover-fallback::after { content: "封面"; }
.media-play {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  background: linear-gradient(180deg, rgba(15,23,42,0.05), rgba(15,23,42,0.45));
  color: #fff; font-weight: 700; font-size: 0.95rem;
  text-decoration: none; letter-spacing: 0.04em;
  transition: background .15s;
}
.media-play:hover { color: #fff; background: rgba(15,23,42,0.5); }
.play-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff; font-size: 1rem; padding-left: 3px;
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.35);
}
.format-hint {
  margin: -6px 0 12px;
  font-size: 0.8rem; color: var(--primary);
}

.trends-top { margin: 0 0 1.25rem; }

.pw-field {
  position: relative;
  display: flex; align-items: center;
}
.pw-field input { padding-right: 64px; }
.pw-toggle {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  border: 0; background: transparent; color: var(--muted);
  font-size: 0.78rem; font-family: inherit; cursor: pointer;
  padding: 6px 8px; border-radius: 8px;
}
.pw-toggle:hover { color: var(--primary); background: rgba(37, 99, 235, 0.08); }

/* —— Hot posts / samples —— */
.sample-block {
  margin: 1rem 0 1.15rem !important;
  padding: 0.9rem !important;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--light-bg);
}
.sample-label { opacity: 0.9; margin-bottom: 0.35rem !important; }
.sample-list {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: 12px !important;
}
.sample-post {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 12px !important;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--card);
}
.sample-post.is-collapsed { display: none; }
.sample-thumb {
  width: 80px; height: 80px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  flex: 0 0 auto;
  background: var(--light-bg);
  border: 1px solid var(--border);
}
.sample-post.is-compact .sample-thumb,
.trend-sample .sample-thumb {
  width: 56px; height: 56px;
}
.sample-thumb-ph {
  background: linear-gradient(135deg, #dbeafe, #f1f5f9);
  display: flex; align-items: center; justify-content: center;
  color: #64748b; font-size: 0.68rem; font-weight: 650;
}
.sample-thumb-ph::after { content: "封面"; }
.sample-main { min-width: 0; flex: 1; }
.sample-author {
  font-size: 0.78rem; font-weight: 650; color: var(--primary);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  margin-bottom: 2px;
}
.sample-post.is-compact .sample-author { font-size: 0.68rem; }
.sample-snippet {
  font-size: 0.82rem; line-height: 1.4; color: var(--muted);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical;
  overflow: hidden;
}
.sample-post.is-compact .sample-snippet {
  font-size: 0.7rem; -webkit-line-clamp: 2;
}
.sample-link {
  display: inline-block; margin-top: 4px;
  font-size: 0.72rem; color: var(--primary); text-decoration: none;
}
.sample-link:hover { text-decoration: underline; }
.sample-more {
  margin-top: 6px;
  border: 0; background: transparent;
  color: var(--muted); font: inherit; font-size: 0.74rem;
  cursor: pointer; padding: 4px 2px;
}
.sample-more:hover { color: var(--primary); }
.sample-more-mini { font-size: 0.68rem; margin-top: 2px; }
.trend-sample { margin-top: 10px; }
.trend-sample-list { gap: 10px; }
.img-broken {
  /* Keep the slot. A single load failure must not collapse the card. */
  opacity: 1;
  background: linear-gradient(135deg, #e2e8f0, #f8fafc);
}
.img-fallback {
  object-fit: cover;
  background: linear-gradient(135deg, #dbeafe, #f1f5f9);
}

.top-posts { list-style: none; margin: .4rem 0 .8rem; padding: 0; display: grid; gap: .55rem; }
.top-post { border: 1px solid var(--border); border-radius: 10px; padding: .55rem .7rem; background: var(--light-bg); }
.top-post-meta { display: flex; justify-content: space-between; gap: .5rem; font-size: .78rem; margin-bottom: .25rem; }
.top-post-snippet { font-size: .86rem; line-height: 1.45; color: var(--text); white-space: pre-wrap; }
.top-post-thumb { display: none; }

.trend-posts {
  list-style: none; margin: 12px 0 0 !important; padding: 0;
  display: grid; gap: 10px !important;
}
.trend-post {
  display: flex; gap: 8px; align-items: flex-start;
  padding: 10px !important; margin: 0;
  border-radius: var(--radius-sm);
  background: var(--light-bg);
  border: 1px solid var(--border);
}
.trend-post-thumb {
  width: 36px; height: 36px; border-radius: 6px;
  object-fit: cover; flex: 0 0 auto;
  background: var(--light-bg);
}
.trend-post-main { min-width: 0; flex: 1; }
.trend-post-author {
  font-size: 0.68rem; color: var(--primary); font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.trend-post-snippet {
  font-size: 0.7rem; color: var(--muted); line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden;
}

.gap-card .sample-block { opacity: 1; }

@media (max-width: 860px) {
  .auth-page { grid-template-columns: 1fr; }
  .auth-hero {
    padding: 32px 22px 24px;
    min-height: auto;
  }
  .auth-hero h1 { font-size: 1.65rem; }
  .auth-points { display: none; }
  .auth-panel { padding: 24px 18px 40px; }
  .trends { grid-template-columns: 1fr; }
  .container { padding: 16px 14px 56px; }
  .feed-hero { padding: 1.1rem 1rem; }
  .feed-hero h1 { font-size: 1.25rem; }
  .card.gap-card { padding: 1.15rem 1rem; margin-bottom: 1.25rem !important; }
  .article-row { flex-direction: column; }
  .article-thumb, .article-thumb-ph {
    width: 100%; height: auto; aspect-ratio: 16 / 10; max-height: 200px;
  }
  .site-tagline { display: none; }
  .nav-links .user-chip { margin-left: 0; }
  .updated-badge-nav {
    margin-left: 0; width: 100%;
    justify-content: space-between;
  }
  .updated-badge-hero {
    width: 100%;
    justify-content: space-between;
  }
  .updated-badge-hero strong { font-size: 1rem; }
  .feed-tabs {
    width: 100%;
    border-radius: var(--radius);
  }
  .feed-tab { flex: 1; justify-content: center; }
}
