/* 今日热榜接入主站：颜色跟 assets/style.css 的墨色 / 黄铜，不改数据逻辑。 */
:root {
  --bg: #f7f5f2;
  --bg-deep: #efebe6;
  --card: #fcfbfa;
  --soft: #f3f0eb;
  --ink: #1c1814;
  --muted: #6e665c;
  --line: #e4ddd4;
  --accent: #FF6900;
  --accent2: #FF7D26;
  --accent-soft: rgba(255, 105, 0, .10);
  --glow1: transparent;
  --glow2: transparent;
  --dot: transparent;
  --shadow: 0 12px 28px -18px rgba(48, 36, 20, .28);
  --chip: #fffdf8;
}
[data-theme="dark"] {
  --bg: #121110;
  --bg-deep: #0c0b0a;
  --soft: #23211e;
  --ink: #f6f1e7;
  --muted: #b3a898;
  --line: #3d3833;
  --accent: #FF6900;
  --accent2: #FF7D26;
  --accent-soft: rgba(255, 105, 0, .16);
  --shadow: 0 16px 36px -18px rgba(0, 0, 0, .55);
  --card: #24211e;
  --chip: #2c2926;
  color-scheme: dark;
}

body.news-page {
  font-family: var(--font-sans, var(--font-body));
  color: var(--text, var(--ink));
  background:
    radial-gradient(900px 420px at 50% -180px, color-mix(in srgb, var(--brand, var(--accent)) 10%, transparent), transparent 70%),
    var(--bg);
}
body.news-page::before,
body.news-page::after,
body.news-page .heatline,
body.news-page .wm { display: none !important; }

body.news-page > header.topbar {
  display: flex;
  position: sticky;
  top: 0;
  z-index: 80;
  height: calc(var(--bar-h, 64px) + env(safe-area-inset-top, 0px));
  min-height: calc(var(--bar-h, 64px) + env(safe-area-inset-top, 0px));
  padding: env(safe-area-inset-top, 0px) 0 0 !important;
  background: var(--bg-deep);
  border-bottom: 1px solid var(--border, var(--line));
}
[data-theme="dark"] body.news-page > header.topbar {
  background: color-mix(in srgb, #1c1a18 92%, transparent);
  backdrop-filter: saturate(1.08) blur(14px);
  -webkit-backdrop-filter: saturate(1.08) blur(14px);
}
body.news-page .topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  max-width: var(--page, 1280px);
  margin: 0 auto;
  padding: 0 24px;
}
body.news-page .header-home,
body.news-page .header-papers,
body.news-page .header-help {
  padding: 0 12px;
  height: 36px;
}
body.news-page .brand {
  gap: 8px;
  /* 跟主站顶栏同一套：浅色 #3a332c，不要用 --text/#1c1814，否则同字号也会显得更粗更大。 */
  color: #3a332c;
  font-family: var(--font-serif);
  font-weight: 650;
  line-height: 1.2;
  letter-spacing: 0.06em;
}
html[data-theme="dark"] body.news-page .brand {
  color: var(--text);
}
body.news-page .header-news[aria-current="page"] {
  border-color: transparent;
  background: transparent;
}

.news-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 22px;
  padding-bottom: 8px;
}
.news-title-main { min-width: 0; flex: 1 1 auto; }
.news-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  column-gap: 10px;
  row-gap: 8px;
  min-width: 0;
}
.news-title-action {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 100%;
}
.news-title-dot {
  color: var(--muted);
  font-size: 1.35rem;
  font-weight: 650;
  line-height: 1;
}
.news-title h1 {
  margin: 0;
  font-family: var(--font-serif, serif);
  font-size: 1.7rem;
  font-weight: 650;
  letter-spacing: .04em;
  line-height: 1.15;
  color: var(--text, var(--ink));
}
.news-sub {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 13px;
  letter-spacing: .12em;
  white-space: nowrap;
}
.news-title-tools { display: flex; align-items: center; justify-content: flex-end; gap: 12px; flex: none; }
.news-title .clock { text-align: right; }
.news-title .clock .time { font-size: 15px; letter-spacing: 0; }
.news-title .clock .date { margin-top: 2px; letter-spacing: 0; }

body.news-page .wrap { max-width: 1120px; }
body.news-page .card {
  border-radius: 16px;
  background: var(--card);
  border-color: var(--line);
  color: var(--text, var(--ink));
}
body.news-page .pmeta h3,
body.news-page .cat-name,
body.news-page .tk-label,
body.news-page footer .fbrand {
  font-family: var(--font-serif, serif);
  font-weight: 650;
  letter-spacing: .02em;
}
body.news-page .ticker {
  max-width: 1072px;
  margin: 8px auto 0;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
}
body.news-page .controls {
  top: calc(var(--bar-h, 64px) + env(safe-area-inset-top, 0px));
  z-index: 30;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
}
@media (max-width: 720px) {
  body.news-page .ticker { max-width: none; margin: 8px 14px 0; }
  .news-title .clock .date { display: none; }
  /* 桌面顶栏的 space-between / 36px 会漏到窄屏，把第二行五个文字链撑开。
     跟主站其它栏目一样：整组居中，行距 8px，链高 32px，字下短横线仍走 style.css。 */
  body.news-page .topbar-inner {
    justify-content: center;
    row-gap: 8px;
  }
  /* 桌面这条 padding !important 把上下都清成 0。窄屏两行顶栏要跟 LoRA 页一样：上 8px、下 8px。 */
  body.news-page > header.topbar {
    padding-top: calc(8px + env(safe-area-inset-top, 0px)) !important;
    padding-bottom: 8px !important;
  }
  body.news-page .header-nav > .header-home,
  body.news-page .header-nav > .header-papers {
    height: 32px;
  }
  /* 窄屏主站 .brand 是 17px。本页选择器更具体，必须写在这里，避免被桌面 20px 盖住。 */
  body.news-page > header.topbar .brand,
  body.news-page > header.topbar .brand-name {
    font-size: 17px;
    font-weight: 650;
    line-height: 1.2;
    letter-spacing: 0.06em;
  }
}

/* 资讯页专用：主站页脚固定在底部。hot.css 的 footer 规则会居中并给链接加虚线下划线，这里压回去。 */
body.news-page > .site-footer {
  text-align: start;
  line-height: 1.75;
}
body.news-page > .site-footer .footer-notice a,
body.news-page > .site-footer .footer-notice a:link,
body.news-page > .site-footer .footer-notice a:visited,
body.news-page > .site-footer .footer-notice a:hover,
body.news-page > .site-footer .footer-notice a:active {
  color: #0052D9;
  text-decoration: underline;
  text-underline-offset: 2px;
  border-bottom: 0;
}
body.news-page main.wrap {
  padding-bottom: calc(var(--footer-stack, 7.75rem) + env(safe-area-inset-bottom, 0px) + 8px);
}
body.news-page .floats,
body.news-page #toasts {
  bottom: calc(var(--footer-stack, 7.75rem) + env(safe-area-inset-bottom, 0px) + 12px);
}

a.push-bind-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 38px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid #3370FF;
  background: #3370FF;
  color: #fff;
  font: inherit;
  font-size: 13px;
  letter-spacing: .04em;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
}
a.push-bind-btn:hover,
a.push-bind-btn:focus-visible {
  background: #245BE6;
  border-color: #245BE6;
  color: #fff;
}
.push-lead { padding-top: 22px; padding-bottom: 12px; }
.push-back {
  display: inline-block;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
}
.push-back:hover { color: var(--accent); }
.push-lead h1 {
  margin: 0;
  font-family: var(--font-serif, serif);
  font-size: 1.7rem;
  font-weight: 650;
  letter-spacing: .04em;
}
.push-lead p { margin: 6px 0 0; color: var(--muted); font-size: 13px; }
.push-page {
  display: flex;
  min-height: 520px;
  margin-bottom: calc(var(--footer-stack, 7.75rem) + 24px);
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
}
.push-body { display: flex; min-height: 0; flex: 1; }
.push-list {
  width: 210px;
  flex: none;
  margin: 0;
  padding: 8px;
  list-style: none;
  overflow: auto;
  border-right: 1px solid var(--line);
  background: var(--soft);
}
.push-list button {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  text-align: left;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: transparent;
  color: inherit;
  cursor: pointer;
}
.push-list button[aria-current="true"] {
  background: var(--card);
  border-color: var(--line);
}
.push-list button:disabled,
.push-list button[data-available="false"] { color: var(--muted); }
.push-icon {
  width: 28px;
  height: 28px;
  flex: none;
  display: inline-flex;
}
.push-icon svg { width: 28px; height: 28px; display: block; }
.push-detail-title { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.push-detail-title h2 { margin: 0; font-size: 1.15rem; }
.push-detail { flex: 1; min-width: 0; overflow: auto; padding: 18px; }
.push-detail h3 { margin: 0 0 6px; font-size: 1.05rem; }
.push-hint, .push-reason, .push-status { margin: 0 0 14px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.push-reason {
  padding: 12px;
  border-radius: 10px;
  background: var(--soft);
}
.push-form { display: grid; gap: 10px; max-width: 460px; }
.push-form label { display: grid; gap: 4px; font-size: 13px; }
.push-form input,
.push-form select {
  height: 36px;
  padding: 0 10px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: inherit;
  font: inherit;
}
.push-form input[type="number"] { width: 96px; }
.push-checks { display: flex; flex-wrap: wrap; gap: 8px 14px; margin: 0; padding: 0; border: 0; }
.push-checks legend { padding: 0; margin-bottom: 6px; font-size: 13px; }
.push-checks label { display: flex; align-items: center; gap: 6px; }
.push-checks input { width: 16px; height: 16px; padding: 0; }
.push-checks label:has(input:disabled) { color: var(--muted); }
.push-actions { display: flex; gap: 8px; margin-top: 4px; }
.push-actions button, .push-bound button {
  height: 34px;
  padding: 0 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--card);
  color: inherit;
  cursor: pointer;
}
.push-actions button[type="submit"] {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.push-actions button.push-cancel {
  background: var(--card);
  border-color: var(--line);
  color: inherit;
}
.push-error { margin: 0; color: #b42318; font-size: 13px; }
.push-bound { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 8px; }
.push-bound li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg);
}
.push-bound strong { font-weight: 650; }
.push-bound span { color: var(--muted); font-size: 12px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 720px) {
  .push-page { flex-direction: column; min-height: 0; }
  .push-list {
    width: auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    max-height: none;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 10px;
  }
  .push-list li { display: flex; margin: 0; }
  .push-list button {
    width: auto;
    height: 32px;
    padding: 0 10px 0 8px;
    gap: 6px;
    border-radius: 999px;
    border-color: var(--line);
    background: var(--bg);
    font-size: 13px;
    line-height: 1;
  }
  .push-list button::before {
    content: "";
    width: 12px;
    height: 12px;
    border: 1.5px solid currentColor;
    border-radius: 50%;
    flex: none;
    box-sizing: border-box;
  }
  .push-list button[aria-checked="true"] {
    border-color: #3370FF;
    color: #3370FF;
    background: var(--card);
  }
  .push-list button[aria-checked="true"]::before {
    border-color: #3370FF;
    background: radial-gradient(circle, #3370FF 0 4px, transparent 5px);
  }
  .push-list .push-icon,
  .push-list .push-icon svg { width: 18px; height: 18px; }
  a.push-bind-btn { height: 36px; }
}
