:root {
  --bg: #f4f5f7;
  --surface: #ffffff;
  --text: #111827;
  --muted: #5b6472;
  --line: #e5e7eb;
  --accent: #0f172a;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.7 -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei',
    sans-serif;
}

.container {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  background: rgba(255, 255, 255, 0.86);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.nav-wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
}

.brand {
  color: var(--accent);
  text-decoration: none;
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-cn {
  font-weight: 700;
  letter-spacing: 0.04em;
}

.brand-en {
  font-size: 12px;
  color: #6b7280;
}

.top-nav {
  display: flex;
  gap: 16px;
}

.top-nav a {
  text-decoration: none;
  color: #374151;
  font-weight: 600;
}

main {
  padding: 28px 0 48px;
}

.section-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 6px 30px rgba(15, 23, 42, 0.04);
}

.hero {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 20px;
  margin-bottom: 28px;
  background: linear-gradient(130deg, #0f172a 0%, #111827 55%, #1f2937 100%);
  color: #f9fafb;
  border: 1px solid #1f2937;
}

.hero .muted {
  color: #cbd5e1;
}

.hero-main {
  flex: 1;
}

.hero-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.update-badge {
  margin: 0;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
  font-size: 12px;
  color: #e2e8f0;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(120px, 1fr));
  gap: 10px;
  margin-top: 18px;
}

.stat-item {
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 12px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.04);
}

.stat-item strong {
  display: block;
  font-size: 22px;
  line-height: 1.2;
}

.stat-label {
  display: block;
  font-size: 12px;
  color: #cbd5e1;
}

.hero-actions {
  display: grid;
  gap: 10px;
}

.filter-btn {
  cursor: pointer;
  font: inherit;
}

h1,
h2,
h3 {
  margin: 0 0 10px;
  line-height: 1.3;
}

.eyebrow {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #6b7280;
  font-size: 12px;
}

.muted {
  color: var(--muted);
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 20px 0 12px;
}

.head-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.inline-hint {
  color: #6b7280;
  font-size: 13px;
}

.filter-row {
  margin: 12px 0 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.filter-row input[type='date'] {
  border: 1px solid #d1d5db;
  border-radius: 8px;
  background: #fff;
  color: #111827;
  padding: 6px 10px;
  font: inherit;
}

.grid {
  display: grid;
  gap: 14px;
}

.cols-4 {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.cols-3 {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.cols-2 {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.card,
.category-box,
.related-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  text-decoration: none;
  color: inherit;
  display: block;
}

.compact-card .muted {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.meta {
  margin: 0 0 8px;
  font-size: 12px;
  color: #6b7280;
}

.pin-tag {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 8px;
  border-radius: 999px;
  border: 1px solid #f59e0b;
  background: #fffbeb;
  color: #92400e;
  font-size: 11px;
  font-weight: 700;
}

.updated-time {
  margin: 8px 0;
  color: #4b5563;
  font-size: 13px;
}

.card-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.text-link {
  color: #1f2937;
  text-decoration: none;
  font-weight: 600;
}

.btn {
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 10px;
  white-space: nowrap;
  font-weight: 600;
}

.btn-secondary {
  background: #eef2ff;
  color: #1e3a8a;
  border: 1px solid #c7d2fe;
}

.article-toolbar {
  margin-bottom: 12px;
}

.article-footer-links {
  margin-top: 18px;
}

.pager-nav {
  margin-top: 14px;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pager-link {
  text-decoration: none;
  color: inherit;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  background: #fafafa;
  font-weight: 600;
  line-height: 1.5;
}

.pager-link span {
  font-size: 13px;
  color: #4b5563;
}

.pager-link.disabled {
  color: #9ca3af;
  background: #f9fafb;
  border-style: dashed;
}

.info-block {
  border-radius: 12px;
  padding: 14px 16px;
  margin: 18px 0;
  border: 1px solid var(--line);
}

.info-block h2 {
  margin-bottom: 6px;
}

.info-block p {
  margin: 0 0 8px;
}

.info-block p:last-child {
  margin-bottom: 0;
}

.info-actions {
  margin-top: 10px;
}

.info-source {
  background: #f9fafb;
  border-color: #d1d5db;
}

.info-important {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.info-risk {
  background: #fff7ed;
  border-color: #fdba74;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}

.chip {
  border: 1px solid var(--line);
  background: #fff;
  color: #374151;
  padding: 6px 12px;
  border-radius: 999px;
  text-decoration: none;
  cursor: pointer;
}

.chip.active {
  background: #111827;
  color: #fff;
  border-color: #111827;
}

.archive-list {
  display: grid;
  gap: 14px;
}

.archive-day {
  padding: 20px;
}

.archive-day-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.article-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 18px;
  align-items: start;
}

.article-layout--single {
  grid-template-columns: minmax(0, 1fr);
}

.stack {
  display: grid;
  gap: 10px;
}

#article-detail {
  height: auto;
  min-height: 0;
  max-height: none;
  overflow: visible;
}

#article-detail h2 {
  margin-top: 24px;
  margin-bottom: 10px;
}

#article-detail p {
  margin: 0 0 14px;
  font-size: 17px;
  line-height: 1.9;
}

#article-detail .summary.lead {
  font-size: 18px;
  line-height: 1.85;
  margin-bottom: 18px;
}

#article-detail .info-block p {
  margin-bottom: 10px;
  font-size: 16px;
  line-height: 1.8;
}

#article-detail .article-content {
  white-space: pre-wrap;
  word-break: break-word;
}

.article-aside {
  height: auto;
  min-height: 0;
  max-height: none;
  overflow: visible;
}

.article-aside.is-empty {
  padding-bottom: 18px;
}

.lead {
  font-size: 17px;
}

.site-footer {
  border-top: 1px solid var(--line);
  color: #6b7280;
  font-size: 13px;
  padding: 18px 0 28px;
}

@media (max-width: 1100px) {
  .container {
    width: min(980px, calc(100% - 36px));
  }

  #article-detail {
    padding: 28px;
  }

  #article-detail p {
    font-size: 18px;
    line-height: 1.95;
  }

  #article-detail .summary.lead {
    font-size: 20px;
    line-height: 1.9;
  }

  #article-detail .info-block p {
    font-size: 17px;
  }
}

@media (max-width: 960px) {
  .article-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
}

@media (max-width: 860px) {
  .article-layout {
    grid-template-columns: 1fr;
  }

  .hero {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-topline {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .pager-nav {
    grid-template-columns: 1fr;
  }
}
