/* =========================================================
   国学经典 · 共享阅读样式
   ========================================================= */

:root {
  --paper: #f4f6f2;
  --card: #ffffff;
  --ink: #233c34;
  --ink-soft: #5e6f67;
  --line: #dce5de;
  --brand: #285b48;
  --brand-deep: #234b3d;
  --green: #4a8a5c; /* 生 / 食神 */
  --red: #c0504d; /* 克 / 七杀 / 凶 */
  --gold: #b8893b; /* 比肩 */
  --purple: #7a5ea8; /* 印绶 */
  --blue: #3a6ea5; /* 财 */
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.06), 0 6px 18px rgba(0, 0, 0, 0.05);
  --radius: 14px;
  --maxw: 1160px;
  --serif: "Songti SC", "STSong", "SimSun", "Noto Serif SC", serif;
  --sans:
    "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Noto Sans SC",
    -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  font-family: var(--sans);
  color: var(--ink);
  background:
    radial-gradient(circle at 7% 10%, rgba(75,126,101,.09), transparent 30rem),
    radial-gradient(circle at 94% 32%, rgba(184,137,59,.08), transparent 28rem),
    var(--paper);
  line-height: 1.8;
  font-size: 16.5px;
  -webkit-font-smoothing: antialiased;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: var(--brand);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* ---------- 顶部导航 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.brand {
  font-family: var(--serif);
  font-weight: 700;
  font-size: 20px;
  color: var(--brand-deep);
  letter-spacing: 1px;
  margin-right: auto;
}
.brand small {
  font-family: var(--sans);
  font-weight: 400;
  font-size: 12px;
  color: var(--ink-soft);
  display: block;
  letter-spacing: 0;
  margin-top: 1px;
}
.nav a.navlink {
  color: var(--ink-soft);
  font-size: 14.5px;
  padding: 6px 4px;
}
.nav a.navlink:hover {
  color: var(--brand);
  text-decoration: none;
}
.nav a.navlink.active {
  color: var(--brand);
  font-weight: 600;
}
.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 15px;
  cursor: pointer;
  color: var(--ink);
}

/* ---------- 容器 ---------- */
.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 18px;
}
section {
  padding: 34px 0;
}
.section-title {
  font-family: var(--serif);
  font-size: 26px;
  color: var(--brand-deep);
  margin: 0 0 6px;
  font-weight: 700;
}
.section-sub {
  color: var(--ink-soft);
  margin: 0 0 22px;
  font-size: 15px;
}

/* ---------- 作者与资料信息 ---------- */
.editorial-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin: 18px 0 22px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink-soft);
  font-size: 13.5px;
}
.editorial-meta div {
  display: inline-flex;
  gap: 7px;
  align-items: baseline;
}
.editorial-meta strong {
  color: var(--ink);
  font-weight: 700;
}
.editorial-meta a {
  color: var(--brand);
}
.editorial-note {
  margin: 18px 0 26px;
  padding: 16px 18px;
  border-left: 3px solid var(--gold);
  border-radius: 0 10px 10px 0;
  background: #fbf8ef;
  color: var(--ink-soft);
}
.editorial-note strong {
  color: var(--brand-deep);
}
.editorial-note p {
  margin: 5px 0 0;
}
.editorial-note .editorial-link {
  font-size: 14px;
}
.editorial-list {
  margin: 0;
  padding-left: 1.4em;
}
.editorial-list li + li {
  margin-top: 8px;
}
.author-expansion {
  margin: 28px 0 24px;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(135deg, #fffdf8, #f7faf6);
  box-shadow: var(--shadow);
}
.author-expansion h2,
.author-expansion h3 {
  font-family: var(--serif);
  color: var(--brand-deep);
  margin: 0 0 8px;
}
.author-expansion h2 {
  font-size: 22px;
}
.author-expansion h3 {
  font-size: 17px;
  margin-top: 18px;
}
.author-expansion p {
  margin: 0;
  color: var(--ink);
}

/* ---------- 面包屑 ---------- */
.crumb {
  font-size: 13px;
  color: var(--ink-soft);
  padding: 16px 0 0;
}
.crumb a {
  color: var(--ink-soft);
}
.crumb span {
  margin: 0 6px;
}

/* ---------- Hero ---------- */
.hero {
  background:
    linear-gradient(
      90deg,
      rgba(247, 249, 244, 0.97),
      rgba(247, 249, 244, 0.6) 55%,
      rgba(247, 249, 244, 0.05)
    ),
    url("../images/ink-landscape.jpg") center/cover;
  border-bottom: 1px solid var(--line);
}
.hero-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 54px 18px 46px;
}
.hero h1 {
  font-family: var(--serif);
  font-size: 38px;
  line-height: 1.25;
  color: var(--brand-deep);
  margin: 0 0 14px;
  font-weight: 700;
}
.hero p.lead {
  font-size: 18px;
  color: var(--ink-soft);
  max-width: 680px;
  margin: 0 0 22px;
}
.hero .cta {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  padding: 12px 26px;
  border-radius: 30px;
  font-weight: 600;
  font-size: 16px;
}
.hero .cta:hover {
  background: var(--brand-deep);
  text-decoration: none;
}
.hero .ghost {
  display: inline-block;
  margin-left: 12px;
  color: var(--brand);
  border: 1px solid var(--brand);
  padding: 11px 22px;
  border-radius: 30px;
  font-weight: 600;
  font-size: 15px;
}
.hero .ghost:hover {
  background: rgba(44, 93, 124, 0.07);
  text-decoration: none;
}

/* ---------- 模块卡片网格（首页） ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.mod-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 20px;
  box-shadow: var(--shadow);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
  display: flex;
  flex-direction: column;
}
.mod-card:hover {
  transform: translateY(-3px);
  box-shadow:
    0 4px 10px rgba(0, 0, 0, 0.08),
    0 14px 30px rgba(0, 0, 0, 0.07);
}
.mod-card .num {
  font-family: var(--serif);
  font-size: 14px;
  color: var(--brand);
  font-weight: 700;
  letter-spacing: 1px;
}
.mod-card h3 {
  font-family: var(--serif);
  font-size: 21px;
  margin: 6px 0 8px;
  color: var(--ink);
}
.mod-card p {
  color: var(--ink-soft);
  font-size: 14.5px;
  margin: 0 0 14px;
  flex: 1;
}
.mod-card .more {
  font-size: 14px;
  color: var(--brand);
  font-weight: 600;
}
.mod-card .more::after {
  content: " →";
}

/* ---------- 内容卡片（概念卡） ---------- */
.panel-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  margin: 18px 0;
  position: relative;
  overflow: hidden;
}
.panel-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(var(--brand), #b8893b);
}
.panel-card h3 {
  font-family: var(--serif);
  font-size: 22px;
  color: var(--brand-deep);
  margin: 0 0 4px;
}
.panel-card .kicker {
  color: var(--brand);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 8px;
}
.plain {
  color: var(--ink);
}
.plain p {
  margin: 0 0 14px;
}
.lead-in {
  font-size: 17px;
  color: var(--ink);
}

/* ---------- 标签 ---------- */
.tag {
  display: inline-block;
  font-size: 12.5px;
  padding: 3px 10px;
  border-radius: 20px;
  margin: 0 6px 6px 0;
  font-weight: 600;
  background: #eef2f4;
  color: var(--brand);
}
.tag.blue {
  background: #e8f0f7;
  color: var(--blue);
}
.tag.green {
  background: #e9f3ec;
  color: var(--green);
}
.tag.red {
  background: #fbecec;
  color: var(--red);
}
.tag.gold {
  background: #f6efdd;
  color: #7a5a1e;
}
.tag.purple {
  background: #efeaf6;
  color: var(--purple);
}

/* ---------- Tabs ---------- */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 18px;
}
.tab {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
  padding: 8px 16px;
  border-radius: 24px;
  cursor: pointer;
  font-size: 14.5px;
  font-weight: 600;
  transition: all 0.12s ease;
}
.tab:hover {
  border-color: var(--brand);
  color: var(--brand);
}
.tab.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}
.panels .panel {
  display: none;
  animation: fade 0.25s ease;
}
.panels .panel.active {
  display: block;
}
@keyframes fade {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* ---------- 图 ---------- */
figure.svgfig {
  margin: 18px 0;
  background: #fcfbf8;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px;
  text-align: center;
}
figure.svgfig svg {
  width: 100%;
  height: auto;
  max-width: 560px;
  margin: 0 auto;
}
figure.svgfig figcaption {
  font-size: 13px;
  color: var(--ink-soft);
  margin-top: 10px;
}

figure.shensha-portrait {
  margin: 18px 0;
  padding: 18px;
  background: linear-gradient(145deg, #fbfcf8, #f1f5ef);
  border: 1px solid var(--line);
  border-radius: 16px;
  text-align: center;
}
figure.shensha-portrait img {
  display: block;
  width: min(100%, 360px);
  height: auto;
  max-height: 360px;
  margin: 0 auto;
  object-fit: contain;
}
figure.shensha-portrait figcaption {
  margin-top: 8px;
  color: var(--ink-soft);
  font-size: 13px;
}

/* ---------- 分寸 / 提示框 ---------- */
.note {
  border-left: 4px solid var(--brand);
  background: #eef3f6;
  padding: 14px 18px;
  border-radius: 0 10px 10px 0;
  margin: 16px 0;
  color: var(--ink);
}
.note.warn {
  border-left-color: var(--red);
  background: #fbecec;
}
.note.good {
  border-left-color: var(--green);
  background: #e9f3ec;
}
.note b {
  color: var(--brand-deep);
}

/* ---------- 引文（古籍原文） ---------- */
.quote {
  border-left: 4px solid var(--gold);
  background: #faf6ec;
  padding: 12px 18px;
  border-radius: 0 10px 10px 0;
  color: #6b5a38;
  font-family: var(--serif);
  margin: 14px 0;
}
.quote .src {
  display: block;
  font-family: var(--sans);
  font-size: 12.5px;
  color: var(--ink-soft);
  margin-top: 6px;
}

/* ---------- 上下篇导航 ---------- */
.pager {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 30px 0 6px;
  flex-wrap: wrap;
}
.pager a {
  flex: 1;
  min-width: 200px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 18px;
  color: var(--ink);
  box-shadow: var(--shadow);
}
.pager a:hover {
  text-decoration: none;
  border-color: var(--brand);
}
.pager .dir {
  font-size: 12px;
  color: var(--ink-soft);
}
.pager .ttl {
  font-family: var(--serif);
  font-size: 17px;
  color: var(--brand-deep);
  font-weight: 700;
}

/* ---------- 广告位（AdSense 占位） ---------- */
.adslot {
  margin: 26px 0;
  text-align: center;
  background: #f1efe9;
  border: 1px dashed #cfc8ba;
  border-radius: 10px;
  color: #9a9384;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 90px;
  padding: 10px;
}
.adslot.large {
  min-height: 250px;
}
.adslot::before {
  content: "广告位 · AdSense（接入后展示）";
}

/* ---------- 页脚 ---------- */
.site-footer {
  background: #23323b;
  color: #cdd6db;
  margin-top: 30px;
  padding: 34px 0 26px;
  font-size: 14px;
}
.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  justify-content: space-between;
}
.site-footer h4 {
  color: #fff;
  font-size: 15px;
  margin: 0 0 10px;
  font-family: var(--sans);
}
.site-footer a {
  color: #aec4d2;
  display: block;
  margin: 4px 0;
}
.site-footer a:hover {
  color: #fff;
}
.site-footer .copy {
  width: 100%;
  border-top: 1px solid #36474f;
  margin-top: 18px;
  padding-top: 14px;
  color: #8fa0a8;
  font-size: 12.5px;
  line-height: 1.7;
}

/* ---------- 概念页（自动生成） ---------- */
.post-title {
  font-family: var(--serif);
  font-size: 32px;
  color: var(--brand-deep);
  margin: 6px 0 2px;
  font-weight: 700;
  line-height: 1.3;
}
.post-sub {
  color: var(--brand);
  font-size: 15px;
  margin: 0 0 18px;
  font-weight: 600;
}
.lead.callout {
  background: #eef3f6;
  border-left: 4px solid var(--brand);
  padding: 16px 20px;
  border-radius: 0 12px 12px 0;
  font-size: 18px;
  color: var(--ink);
  margin: 0 0 22px;
}
.book {
  background: #faf6ec;
  border-left: 4px solid var(--gold);
  padding: 14px 20px;
  border-radius: 0 12px 12px 0;
  color: #6b5a38;
  font-family: var(--serif);
}
.points {
  margin: 0 0 8px;
  padding-left: 22px;
}
.points li {
  margin: 0 0 10px;
}
.mistake {
  background: #fbecec;
  border-left: 4px solid var(--red);
  padding: 14px 20px;
  border-radius: 0 12px 12px 0;
  color: #8a3b39;
}
.kicker {
  color: var(--brand);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 8px;
}
.relbox {
  margin: 24px 0;
  padding: 16px 18px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.relbox .rel {
  display: inline-block;
  background: #eef2f4;
  color: var(--brand);
  padding: 6px 14px;
  border-radius: 20px;
  margin: 4px 6px 4px 0;
  font-size: 14px;
  font-weight: 600;
}
.relbox .rel:hover {
  background: var(--brand);
  color: #fff;
  text-decoration: none;
}
.pager .pbtn.disabled {
  background: #f1efe9 !important;
  color: #b3ada0 !important;
  border-color: var(--line) !important;
  box-shadow: none !important;
  cursor: default;
}

/* ---------- 分类 hub ---------- */
.hubgrid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 22px 0;
}
.hubcard {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px 18px;
  box-shadow: var(--shadow);
  display: block;
  color: var(--ink);
}
.hubcard:hover {
  text-decoration: none;
  border-color: var(--brand);
  transform: translateY(-2px);
  transition: 0.15s;
}
.hubcard h3 {
  font-family: var(--serif);
  font-size: 19px;
  margin: 0 0 6px;
  color: var(--brand-deep);
}
.hubcard p {
  color: var(--ink-soft);
  font-size: 13.5px;
  margin: 0;
}
.gods-grid .hubcard {
  min-height: 210px;
  padding-right: 112px;
}
.deity-portrait {
  float: right;
  width: 280px;
  height: 280px;
  margin: -74px 0 22px 34px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(145deg, #fff, #eef4ed);
  overflow: hidden;
}
.deity-portrait img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
@media (max-width: 720px) {
  .deity-portrait {
    float: none;
    width: min(100%, 320px);
    height: auto;
    aspect-ratio: 1;
    margin: 16px auto 22px;
  }
}
.god-icon {
  position: absolute;
  right: 12px;
  top: 12px;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: contain;
  background-color: #f1f5ed;
  box-shadow: 0 8px 20px rgba(35,60,52,.11);
}
@media (max-width: 640px) {
  .gods-grid .hubcard { min-height: 170px; padding-right: 92px; }
  .god-icon { width: 76px; height: 76px; }
}

/* ---------- 六十甲子 / 纳音 表格 ---------- */
.grid60 {
  display: grid;
  grid-template-columns: repeat(10, 1fr);
  gap: 4px;
  margin: 10px 0;
}
.grid60 span {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 0;
  text-align: center;
  font-family: var(--serif);
  font-size: 14px;
  color: var(--ink);
}
.na-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px 18px;
  margin: 10px 0;
}
.nrow {
  display: flex;
  justify-content: space-between;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 14px;
}
.nrow b {
  color: var(--brand-deep);
  font-family: var(--serif);
}
.nrow span {
  color: var(--gold);
  font-weight: 600;
}

/* ---------- 响应式（新增） ---------- */
@media (max-width: 860px) {
  .hubgrid {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid60 {
    grid-template-columns: repeat(6, 1fr);
  }
}
@media (max-width: 620px) {
  .hubgrid {
    grid-template-columns: 1fr;
  }
  .grid60 {
    grid-template-columns: repeat(5, 1fr);
  }
  .na-list {
    grid-template-columns: 1fr;
  }
  .post-title {
    font-size: 26px;
  }
}

/* ---------- 响应式 ---------- */
@media (max-width: 860px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .hero h1 {
    font-size: 30px;
  }
  .hero p.lead {
    font-size: 16px;
  }
}
@media (max-width: 620px) {
  .card-grid {
    grid-template-columns: 1fr;
  }
  .nav-toggle {
    display: inline-block;
  }
  .nav .links {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 2px;
    margin-top: 8px;
  }
  .nav .links.open {
    display: flex;
  }
  .nav a.navlink {
    padding: 8px 4px;
    border-bottom: 1px solid var(--line);
  }
  body {
    font-size: 16px;
  }
  .hero h1 {
    font-size: 26px;
  }
  .section-title {
    font-size: 22px;
  }
  .panel-card {
    padding: 18px;
  }
}

/* Website shell shared with the chart application. */
.wrap,
.nav,
.hero-inner {
  width: calc(100% - 48px);
  max-width: var(--maxw);
  padding-left: 0;
  padding-right: 0;
}
.site-header {
  position: relative;
  z-index: 10;
  background: #fff;
  backdrop-filter: none;
}
.nav {
  min-height: 76px;
  padding-top: 0;
  padding-bottom: 0;
  flex-wrap: nowrap;
  justify-content: space-between;
  gap: 32px;
}
.brand {
  font-size: 25px;
  line-height: 1.2;
  letter-spacing: 2px;
  color: var(--brand);
  flex-shrink: 0;
}
.brand small {
  font-size: 11px;
  letter-spacing: 1px;
  margin-top: 5px;
  line-height: 1.6;
}
.nav .links {
  display: flex;
  gap: 28px;
  align-items: center;
}
.nav a.navlink {
  white-space: nowrap;
  padding: 24px 0;
  font-size: 14px;
}
.nav a.navlink.active {
  box-shadow: inset 0 -2px var(--brand);
}
.topic-nav {
  display: flex;
  gap: 28px;
  overflow-x: auto;
  white-space: nowrap;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.topic-nav .navlink {
  color: var(--ink-soft);
}
.topic-nav .active {
  color: var(--brand);
  font-weight: 600;
}
.hero {
  width: calc(100% - 48px);
  max-width: var(--maxw);
  margin: 24px auto 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 0;
  overflow: hidden;
}
.hero-inner {
  width: auto;
  padding: 44px 40px;
  max-width: none;
}
.hero h1 {
  font-size: 36px;
  line-height: 1.5;
  max-width: 780px;
}
.hero p.lead {
  font-size: 16px;
  max-width: 650px;
  line-height: 1.9;
}
.hero .cta,
.hero .ghost {
  border-radius: 8px;
  font-size: 14px;
  padding: 10px 20px;
  white-space: nowrap;
}
.hero .ghost {
  background: rgba(255, 255, 255, 0.7);
}
.card-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
.mod-card,
.panel-card,
.hubcard {
  box-shadow: none;
}
.mod-card {
  padding: 26px;
  transition:
    background 0.15s,
    border-color 0.15s;
}
.mod-card:hover {
  transform: none;
  box-shadow: none;
  background: #f0f5f0;
  border-color: #a9c0af;
}
.mod-card h3 {
  font-size: 23px;
}
.mod-card p {
  font-size: 15px;
  line-height: 1.9;
}
.hubgrid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.hubcard {
  padding: 24px;
}
.hubcard p {
  font-size: 14px;
}
.is-article section > .wrap {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 36px 48px;
}
.is-article section > .wrap > p,
.is-article section > .wrap > ul {
  max-width: 82ch;
}
.is-article h2 {
  font-family: var(--serif);
  font-size: 24px;
  line-height: 1.5;
  margin-top: 32px;
}
.post-title {
  font-size: 34px;
  margin-bottom: 8px;
}
.post-sub {
  font-weight: 400;
}
.book {
  font-family: var(--sans);
  background: #f4f6ef;
  color: var(--ink-soft);
  border-left-color: #8caa91;
  line-height: 1.9;
}
.lead.callout {
  background: #edf3ee;
  border-left-color: var(--brand);
  line-height: 1.9;
}
figure.svgfig {
  background: #fafbf8;
  overflow-x: auto;
}
.site-footer {
  background: transparent;
  color: var(--ink-soft);
  margin: 36px 0 0;
  padding: 0 0 28px;
}
.site-footer > .wrap {
  padding-top: 28px;
  border-top: 1px solid var(--line);
  align-items: center;
  gap: 16px;
}
.site-footer h4 {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  margin-bottom: 4px;
}
.site-footer p {
  font-size: 13px;
  margin: 0;
}
.site-footer .footer-links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.site-footer a {
  color: var(--brand);
  font-size: 13px;
  margin: 0;
}
.site-footer a:hover {
  color: var(--brand-deep);
}
.site-footer .copy {
  border: 0;
  margin: 0;
  padding-top: 4px;
  color: var(--ink-soft);
  font-size: 12px;
}
a:focus-visible,
button:focus-visible {
  outline: 3px solid #72a78b;
  outline-offset: 4px;
}
@media (max-width: 1023px) {
  .nav {
    gap: 18px;
  }
  .nav .links {
    gap: 18px;
  }
  .hubgrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .is-article section > .wrap {
    padding: 28px;
  }
}
@media (max-width: 767px) {
  .wrap,
  .nav,
  .hero {
    width: calc(100% - 32px);
  }
  .nav {
    min-height: 68px;
    padding-top: 12px;
    padding-bottom: 12px;
    flex-wrap: wrap;
    gap: 12px;
  }
  .brand {
    font-size: 23px;
  }
  .nav-toggle {
    display: inline-block;
    font: 13px/1.5 var(--sans);
    padding: 8px 12px;
    background: #fff;
  }
  .nav .links {
    display: none;
    width: 100%;
    margin-top: 0;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0;
  }
  .nav .links.open {
    display: flex;
  }
  .nav a.navlink {
    width: 50%;
    padding: 12px 0;
    border: 0;
    font-size: 14px;
  }
  .nav a.navlink.active {
    box-shadow: none;
  }
  .topic-nav {
    gap: 22px;
    padding: 12px 0;
    font-size: 12px;
  }
  .hero {
    margin-top: 18px;
  }
  .hero-inner {
    width: auto;
    padding: 28px 22px;
  }
  .hero h1 {
    font-size: 28px;
  }
  .hero p.lead {
    font-size: 14px;
  }
  .hero .cta,
  .hero .ghost {
    margin: 4px 8px 4px 0;
    padding: 9px 14px;
    font-size: 13px;
  }
  section {
    padding: 24px 0;
  }
  .card-grid,
  .hubgrid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .mod-card,
  .hubcard {
    padding: 22px;
  }
  .mod-card h3 {
    font-size: 22px;
  }
  .is-article section > .wrap {
    padding: 24px 20px;
  }
  .post-title {
    font-size: 27px;
  }
  .is-article h2 {
    font-size: 22px;
  }
  .lead.callout {
    font-size: 16px;
    padding: 14px 16px;
  }
  .panel-card {
    padding: 18px;
  }
  .pager a {
    min-width: 0;
    flex-basis: 100%;
  }
  .site-footer > .wrap {
    align-items: flex-start;
  }
  .site-footer .footer-links {
    gap: 18px;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* 十神角色卡：置于文件末尾，避免旧版兼容样式覆盖。 */
.gods-grid .hubcard {
  position: relative;
  min-height: 210px;
  padding: 24px 112px 24px 24px;
  overflow: hidden;
}
@media (max-width: 640px) {
  .gods-grid .hubcard {
    min-height: 170px;
    padding: 22px 92px 22px 20px;
  }
}
