:root {
  --bg: #f7f8fa;
  --surface: #ffffff;
  --text: #1a1a1a;
  --muted: #6b7280;
  --line: #e5e7eb;
  --accent: #2563eb;
  --accent-soft: #eff6ff;
  --radius: 14px;
  --shadow: 0 1px 3px rgba(0,0,0,.06), 0 8px 24px rgba(0,0,0,.04);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.wrap { width: min(1120px, 92%); margin: 0 auto; }

/* 头部 */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(247,248,250,.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between; height: 60px;
}
.logo {
  display: flex; align-items: center; gap: 8px;
  font-weight: 700; font-size: 17px; color: var(--text); text-decoration: none;
}
.logo-mark { color: var(--accent); font-size: 20px; }
.nav { display: flex; gap: 20px; }
.nav a {
  color: var(--muted); text-decoration: none; font-size: 14px; transition: color .15s;
}
.nav a:hover { color: var(--accent); }

/* Hero */
.hero { padding: 64px 0 32px; }
.hero-kicker {
  font-size: 12px; letter-spacing: .18em; color: var(--accent);
  font-weight: 700; margin-bottom: 14px;
}
.hero h1 {
  font-size: clamp(30px, 5vw, 46px); line-height: 1.15;
  letter-spacing: -.02em; margin-bottom: 20px;
}
.hero-desc {
  max-width: 620px; color: var(--muted); font-size: 15.5px; margin-bottom: 32px;
}

/* 搜索 */
.search {
  display: flex; align-items: center; gap: 10px;
  max-width: 420px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 10px 16px; margin-bottom: 22px;
  transition: border-color .15s, box-shadow .15s;
}
.search:focus-within {
  border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft);
}
.search svg { color: var(--muted); flex-shrink: 0; }
.search input {
  border: 0; outline: 0; background: transparent;
  font-size: 15px; width: 100%; color: var(--text);
}

/* 筛选 */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-btn {
  border: 1px solid var(--line); background: var(--surface);
  color: var(--muted); font-size: 13px; padding: 6px 14px;
  border-radius: 999px; cursor: pointer; transition: all .15s;
  font-family: inherit;
}
.filter-btn:hover { border-color: var(--accent); color: var(--accent); }
.filter-btn.active {
  background: var(--accent); border-color: var(--accent); color: #fff;
}

/* 卡片网格 */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px; padding: 28px 0 56px;
}
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px;
  text-decoration: none; color: inherit;
  display: flex; flex-direction: column;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: #d1d5db;
}
.card-top {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px;
}
.card-avatar {
  width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700; font-size: 18px; color: #fff;
  background: var(--accent);
}
.card-years { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.card h3 { font-size: 18px; margin-bottom: 2px; }
.card-en { font-size: 12.5px; color: var(--muted); margin-bottom: 10px; }
.card-summary {
  font-size: 14px; color: #4b5563; flex: 1; margin-bottom: 16px;
}
.card-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag {
  font-size: 11.5px; padding: 3px 9px;
  border-radius: 999px; background: var(--accent-soft); color: var(--accent);
  white-space: nowrap;
}

.empty { text-align: center; color: var(--muted); padding: 60px 0; font-size: 15px; }

/* 详情页 */
.detail { padding: 48px 0 72px; max-width: 760px; }
.detail-back {
  display: inline-block; font-size: 14px; color: var(--muted);
  text-decoration: none; margin-bottom: 28px;
}
.detail-back:hover { color: var(--accent); }
.detail-header { margin-bottom: 36px; }
.detail-header h1 {
  font-size: clamp(26px, 4vw, 38px); line-height: 1.2; margin-bottom: 6px;
}
.detail-en { font-size: 15px; color: var(--muted); margin-bottom: 16px; }
.detail-meta { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }

.quote {
  border-left: 3px solid var(--accent);
  padding: 4px 0 4px 18px;
  color: #374151; font-style: italic; font-size: 16px;
  margin: 28px 0;
}

.story { margin-bottom: 32px; }
.story h2 {
  font-size: 19px; margin-bottom: 10px;
  display: flex; align-items: center; gap: 10px;
}
.story h2::before {
  content: ""; width: 6px; height: 6px;
  border-radius: 50%; background: var(--accent); flex-shrink: 0;
}
.story p { color: #374151; font-size: 15.5px; }

.detail-nav {
  display: flex; justify-content: space-between; gap: 16px;
  margin-top: 52px; padding-top: 28px; border-top: 1px solid var(--line);
}
.detail-nav a {
  text-decoration: none; color: var(--accent);
  font-size: 14.5px; font-weight: 600;
}
.detail-nav a:hover { text-decoration: underline; }
.detail-nav .disabled { color: #d1d5db; pointer-events: none; }

/* 错误提示 */
.error-box {
  background: #fef2f2; border: 1px solid #fecaca;
  border-radius: var(--radius); padding: 24px;
  color: #991b1b; margin: 40px 0;
}
.error-box h2 { font-size: 18px; margin-bottom: 8px; }
.error-box p { font-size: 14px; line-height: 1.6; }

/* 页脚 */
.site-footer {
  border-top: 1px solid var(--line); padding: 28px 0;
  text-align: center; color: var(--muted); font-size: 13px;
}
.site-footer .fine { font-size: 12px; margin-top: 4px; color: #9ca3af; }
.beian { margin-top: 8px; font-size: 12px; }
.beian a { color: #9ca3af; text-decoration: none; transition: color .15s; }
.beian a:hover { color: var(--accent); text-decoration: underline; }

@media (max-width: 640px) {
  .hero { padding: 40px 0 24px; }
  .grid { grid-template-columns: 1fr; }
  .detail { padding: 32px 0 56px; }
}