:root {
  --bg: #f6f3ec;
  --bg-soft: #fffdf8;
  --card: #ffffff;
  --border: #e6e0d4;
  --border-strong: #d5cdc0;
  --text: #1f2430;
  --text-secondary: #5b6170;
  --muted: #8a8793;
  --accent: #c45c26;
  --accent-soft: rgba(196, 92, 38, 0.08);
  --ai: #1f6f8b;
  --ai-soft: rgba(31, 111, 139, 0.08);
  --pharma: #2f7d4a;
  --pharma-soft: rgba(47, 125, 74, 0.08);
  --women: #a34d7a;
  --women-soft: rgba(163, 77, 122, 0.08);
  --shadow: 0 10px 30px rgba(40, 32, 20, 0.06);
  --radius: 16px;
  --font-sans: "Noto Sans SC", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-serif: "Noto Serif SC", "Songti SC", Georgia, serif;
  --max: 820px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  color: var(--text);
  background:
    radial-gradient(ellipse 70% 40% at 0% 0%, rgba(196, 92, 38, 0.06), transparent 55%),
    radial-gradient(ellipse 50% 35% at 100% 0%, rgba(31, 111, 139, 0.05), transparent 50%),
    var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(246, 243, 236, 0.92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0 0.55rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
  color: inherit;
}

.brand-mark {
  width: 2.35rem;
  height: 2.35rem;
  border-radius: 11px;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, #e28a4f, #c45c26);
  color: #fff;
  font-weight: 700;
  font-size: 1.05rem;
  box-shadow: 0 6px 16px rgba(196, 92, 38, 0.22);
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
}

.brand-text strong {
  font-size: 1.02rem;
  font-weight: 650;
}

.brand-text small {
  color: var(--muted);
  font-size: 0.74rem;
}

.date-picker select {
  appearance: none;
  border: 1px solid var(--border-strong);
  background: var(--card) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%238a8793' d='M1 1l5 5 5-5'/%3E%3C/svg%3E") no-repeat right 0.7rem center;
  color: var(--text);
  border-radius: 999px;
  padding: 0.45rem 2rem 0.45rem 0.9rem;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
}

.topic-tabs {
  display: flex;
  gap: 0.4rem;
  overflow-x: auto;
  padding: 0 0 0.75rem;
  scrollbar-width: none;
}

.topic-tabs::-webkit-scrollbar { display: none; }

.tab {
  flex: 0 0 auto;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-secondary);
  border-radius: 999px;
  padding: 0.5rem 0.95rem;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.tab:hover {
  background: rgba(255,255,255,0.7);
  color: var(--text);
}

.tab.active {
  background: var(--card);
  color: var(--text);
  border-color: var(--border-strong);
  box-shadow: var(--shadow);
}

.tab.active[data-id="ai"] { color: var(--ai); border-color: rgba(31,111,139,0.28); background: var(--ai-soft); }
.tab.active[data-id="pharma"] { color: var(--pharma); border-color: rgba(47,125,74,0.28); background: var(--pharma-soft); }
.tab.active[data-id="women40"] { color: var(--women); border-color: rgba(163,77,122,0.28); background: var(--women-soft); }

.tab .count {
  margin-left: 0.35rem;
  font-size: 0.78rem;
  font-weight: 500;
  opacity: 0.7;
}

.hero {
  padding: 1.8rem 0 1.1rem;
}

.eyebrow {
  margin: 0 0 0.45rem;
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  font-family: var(--font-serif);
  font-size: clamp(1.7rem, 4vw, 2.35rem);
  font-weight: 600;
  line-height: 1.3;
}

.hero-summary {
  margin: 0.75rem 0 0;
  color: var(--text-secondary);
  font-size: 1rem;
  max-width: 44rem;
}

.hero-meta {
  margin: 0.45rem 0 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.status {
  padding: 0.95rem 1.1rem;
  border-radius: 12px;
  background: #fff7e8;
  border: 1px solid #efd7a8;
  color: #7a5a20;
  margin-bottom: 1.2rem;
}

.status.error {
  background: #fff1f0;
  border-color: #f0c2be;
  color: #8a2f2a;
}

.topic-panel {
  padding-bottom: 3rem;
}

.item-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.item {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.25rem 1.3rem 1.15rem;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.85rem 1rem;
}

.item-index {
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  margin-top: 0.1rem;
}

.topic-panel[data-id="ai"] .item-index { color: var(--ai); background: var(--ai-soft); }
.topic-panel[data-id="pharma"] .item-index { color: var(--pharma); background: var(--pharma-soft); }
.topic-panel[data-id="women40"] .item-index { color: var(--women); background: var(--women-soft); }

.item-body { min-width: 0; }

.item-title {
  margin: 0;
  font-size: 1.08rem;
  font-weight: 650;
  line-height: 1.45;
}

.item-summary {
  margin: 0.55rem 0 0;
  color: var(--text-secondary);
  font-size: 0.96rem;
  white-space: pre-wrap;
}

.item-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.75rem;
  margin-top: 0.9rem;
}

.item-date {
  font-size: 0.8rem;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--border);
  padding: 0.18rem 0.6rem;
  border-radius: 999px;
}

.sources {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.source-link {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  color: var(--accent);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 600;
  background: var(--accent-soft);
}

.source-link:hover {
  border-color: rgba(196, 92, 38, 0.45);
  background: rgba(196, 92, 38, 0.14);
}

.source-link::after {
  content: "↗";
  font-size: 0.75em;
  opacity: 0.75;
}

.empty {
  padding: 2rem 1.2rem;
  text-align: center;
  color: var(--muted);
  background: var(--bg-soft);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.4rem 0 2rem;
  color: var(--text-secondary);
  font-size: 0.86rem;
}

.footer-inner p { margin: 0.2rem 0; }
.muted { color: var(--muted); }

.skeleton {
  height: 140px;
  border-radius: var(--radius);
  background: linear-gradient(90deg, #efe9de 25%, #f8f4ea 50%, #efe9de 75%);
  background-size: 200% 100%;
  animation: shimmer 1.3s infinite;
  margin-bottom: 0.9rem;
}

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

@media (max-width: 640px) {
  .item {
    grid-template-columns: 1fr;
    gap: 0.55rem;
  }
  .item-index { width: 1.75rem; height: 1.75rem; font-size: 0.78rem; }
  .brand-text small { display: none; }
  .hero { padding-top: 1.35rem; }
}
