/* 吃瓜网 16 — 深色资讯仪表盘，响应式 */
:root {
  --sg-bg: #0c0f14;
  --sg-panel: #141a22;
  --sg-panel2: #1a222d;
  --sg-line: #2a3442;
  --sg-text: #e6e9ef;
  --sg-muted: #8b95a8;
  --sg-amber: #f0b429;
  --sg-amber-d: #c9920f;
  --sg-mint: #3ecf8e;
  --sg-danger: #ff6b6b;
  --sg-max: 1100px;
  --sg-r: 14px;
  --sg-font: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--sg-font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--sg-text);
  background: var(--sg-bg);
}

a {
  color: #ffd78a;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
}

.sg-shell {
  width: min(100% - 24px, var(--sg-max));
  margin-inline: auto;
}

/* 顶栏：玻璃条 + 竖线分隔导航 */
.sg-bar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(12, 15, 20, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--sg-line);
}

.sg-bar-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 0;
}

.sg-title-block {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sg-mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--sg-amber), #ff8c42);
  color: #1a1206;
  font-weight: 900;
  font-size: 13px;
  display: grid;
  place-items: center;
}

.sg-title-block h1 {
  margin: 0;
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.sg-title-block small {
  display: block;
  font-size: 0.72rem;
  color: var(--sg-muted);
  font-weight: 500;
  margin-top: 2px;
}

.sg-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}

.sg-menu a {
  padding: 8px 12px;
  font-size: 0.82rem;
  color: var(--sg-text);
  border-radius: 8px;
  text-decoration: none;
}
.sg-menu a:hover {
  background: var(--sg-panel2);
  text-decoration: none;
}
.sg-menu a.on {
  background: var(--sg-amber);
  color: #1a1206;
  font-weight: 700;
}

/* 首屏：斜向渐变带 + 三指标 */
.sg-hero {
  padding: 28px 0 8px;
  background: linear-gradient(165deg, rgba(240, 180, 41, 0.12) 0%, transparent 45%),
    radial-gradient(ellipse 70% 50% at 100% 0%, rgba(62, 207, 142, 0.08), transparent);
}

.sg-hero h2 {
  margin: 0 0 10px;
  font-size: clamp(1.35rem, 4vw, 1.85rem);
  font-weight: 800;
  line-height: 1.25;
}

.sg-hero .sg-lead {
  margin: 0 0 20px;
  color: var(--sg-muted);
  font-size: 0.94rem;
  max-width: 52ch;
}

.sg-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 22px;
}

.sg-metric {
  background: var(--sg-panel);
  border: 1px solid var(--sg-line);
  border-radius: var(--sg-r);
  padding: 12px;
  text-align: center;
}
.sg-metric strong {
  display: block;
  font-size: 1.05rem;
  color: var(--sg-amber);
}
.sg-metric span {
  font-size: 0.7rem;
  color: var(--sg-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

@media (max-width: 480px) {
  .sg-metrics {
    grid-template-columns: 1fr;
  }
}

/* 主区：左主列 + 右时间轴（桌面） */
.sg-body {
  padding: 10px 0 40px;
}

.sg-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

@media (min-width: 900px) {
  .sg-layout {
    grid-template-columns: minmax(0, 1fr) 260px;
    align-items: start;
  }
}

.sg-main {
  min-width: 0;
}

.sg-shot {
  border-radius: var(--sg-r);
  overflow: hidden;
  border: 1px solid var(--sg-line);
  margin-bottom: 20px;
  background: var(--sg-panel);
}

.sg-shot img {
  border-radius: 0;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.sg-shot figcaption {
  padding: 10px 14px;
  font-size: 0.78rem;
  color: var(--sg-muted);
  border-top: 1px solid var(--sg-line);
}

.sg-k {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--sg-mint);
  margin-bottom: 8px;
}

.sg-main h3 {
  margin: 0 0 12px;
  font-size: 1.2rem;
}

.sg-prose {
  background: var(--sg-panel);
  border: 1px solid var(--sg-line);
  border-radius: var(--sg-r);
  padding: 20px 18px 22px;
  font-size: 0.94rem;
  color: #c9ced8;
}

.sg-prose p {
  margin: 0 0 1em;
  text-align: justify;
  text-justify: inter-ideograph;
}

.sg-prose p:last-child {
  margin-bottom: 0;
}

.sg-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.sg-chips span {
  font-size: 0.74rem;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--sg-panel2);
  border: 1px solid var(--sg-line);
  color: var(--sg-muted);
}

/* 右侧时间轴 */
.sg-rail {
  position: sticky;
  top: 64px;
}

.sg-rail h4 {
  margin: 0 0 12px;
  font-size: 0.85rem;
  color: var(--sg-muted);
  font-weight: 700;
}

.sg-tl {
  border-left: 2px solid var(--sg-line);
  padding-left: 14px;
  margin: 0;
}

.sg-tl li {
  list-style: none;
  margin-bottom: 14px;
  position: relative;
}

.sg-tl li::before {
  content: "";
  position: absolute;
  left: -19px;
  top: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--sg-amber);
}

.sg-tl a {
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--sg-text);
}
.sg-tl small {
  display: block;
  font-size: 0.75rem;
  color: var(--sg-muted);
  margin-top: 2px;
}

/* 区块标题 */
.sg-block {
  margin-top: 32px;
}

.sg-block h2 {
  margin: 0 0 8px;
  font-size: 1.1rem;
}

.sg-block .sg-sub {
  margin: 0 0 14px;
  color: var(--sg-muted);
  font-size: 0.88rem;
}

/* 卡片栅格 */
.sg-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 560px) {
  .sg-grid.g2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 860px) {
  .sg-grid.g3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.sg-card {
  background: var(--sg-panel);
  border: 1px solid var(--sg-line);
  border-radius: var(--sg-r);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: border-color 0.2s;
}
.sg-card:hover {
  border-color: rgba(240, 180, 41, 0.4);
}

.sg-card a {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.sg-card a:hover h3 {
  color: var(--sg-amber);
}

.sg-card img {
  border-radius: 0;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  width: 100%;
}

.sg-card .bd {
  padding: 12px 14px 16px;
  flex: 1;
}

.sg-card h3 {
  margin: 0 0 6px;
  font-size: 0.95rem;
}

.sg-card p {
  margin: 0;
  font-size: 0.82rem;
  color: var(--sg-muted);
}

.sg-tag {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 3px 7px;
  border-radius: 4px;
  background: rgba(240, 180, 41, 0.15);
  color: var(--sg-amber);
  margin-bottom: 6px;
}

/* 内页列表 */
.sg-crumb {
  font-size: 0.84rem;
  color: var(--sg-muted);
  padding: 18px 0 6px;
}

.sg-page-h1 {
  margin: 0 0 10px;
  font-size: clamp(1.25rem, 3vw, 1.65rem);
}

.sg-sum {
  color: var(--sg-muted);
  font-size: 0.92rem;
  margin: 0 0 18px;
}

.sg-table {
  border: 1px solid var(--sg-line);
  border-radius: var(--sg-r);
  overflow: hidden;
  background: var(--sg-panel);
}

.sg-tr {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--sg-line);
}

@media (min-width: 620px) {
  .sg-tr {
    grid-template-columns: 1fr auto auto;
    align-items: center;
  }
}

.sg-tr:last-child {
  border-bottom: 0;
}

.sg-tr a.lk {
  font-weight: 700;
  color: var(--sg-text);
  text-decoration: none;
}
.sg-tr a.lk:hover {
  color: var(--sg-amber);
}

.sg-tr .meta {
  font-size: 0.82rem;
  color: var(--sg-muted);
}

.sg-tr .flag {
  font-size: 0.76rem;
  color: var(--sg-mint);
  font-weight: 700;
  white-space: nowrap;
}

/* 文章双栏 */
.sg-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  padding-bottom: 36px;
}

@media (min-width: 720px) {
  .sg-split.cols {
    grid-template-columns: minmax(0, 300px) 1fr;
  }
}

.sg-aside {
  background: var(--sg-panel);
  border: 1px solid var(--sg-line);
  border-radius: var(--sg-r);
  padding: 16px;
  font-size: 0.88rem;
  color: var(--sg-muted);
}

.sg-aside h2 {
  margin: 0 0 10px;
  font-size: 0.9rem;
  color: var(--sg-amber);
}

.sg-aside ul {
  margin: 0;
  padding-left: 1.1em;
}

.sg-foot {
  border-top: 1px solid var(--sg-line);
  padding: 22px 0;
  background: #080a0d;
}

.sg-foot p {
  margin: 0;
  text-align: center;
  font-size: 0.8rem;
  color: var(--sg-muted);
}

.sg-skip {
  position: absolute;
  left: -9999px;
  background: var(--sg-amber);
  color: #1a1206;
  padding: 8px 12px;
  z-index: 100;
}
.sg-skip:focus {
  left: 10px;
  top: 10px;
}
