@font-face {
  font-family: "Hubei Serif";
  src: url("./assets/fonts/hubei-serif-variable.ttf?v=20260904-1") format("truetype");
  font-style: normal;
  font-weight: 400 700;
  font-display: block;
}

@font-face {
  font-family: "Hubei Sans";
  src: url("./assets/fonts/hubei-sans-variable.ttf?v=20260904-1") format("truetype");
  font-style: normal;
  font-weight: 400 700;
  font-display: block;
}

:root {
  --lacquer: #9c3029;
  --lacquer-dark: #6e211d;
  --river: #155c68;
  --river-deep: #0f4651;
  --bronze: #a67c43;
  --gold: #c19a5b;
  --ink: #24353a;
  --muted: #6d7a7d;
  --paper: #f6f1e7;
  --paper-light: #fcfaf5;
  --white: #fffdf8;
  --chapter-color: var(--river);
  --chapter-color-deep: var(--river-deep);
  --chapter-color-rgb: 21, 92, 104;
  --active-chapter-color: var(--lacquer);
  --active-chapter-deep: var(--lacquer-dark);
  --active-chapter-rgb: 156, 48, 41;
  --line: rgba(36, 53, 58, 0.14);
  --shadow: 0 24px 70px rgba(27, 48, 53, 0.12);
  --shell: min(1240px, calc(100vw - 64px));
  --serif: "Hubei Serif", "Songti SC", "STSong", "Noto Serif SC", serif;
  --sans: "Hubei Sans", "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; color: var(--ink); background: radial-gradient(circle at 12% 8%, rgba(179,58,48,.06), transparent 28%), radial-gradient(circle at 88% 34%, rgba(15,120,128,.07), transparent 30%), linear-gradient(135deg, #fffaf1, #f2eee4 52%, #edf2ed); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
body.drawer-open, body.chapter-menu-open, body.qr-preview-open { overflow: hidden; }
button, input { font: inherit; }
button, a { color: inherit; }
a { text-decoration: none; }
button { -webkit-tap-highlight-color: transparent; }
.page-shell { width: var(--shell); margin: 0 auto; }

body.cover-active .topbar,
body.cover-active .floating-directory,
body.cover-active main > section:not(.hero),
body.cover-active .footer { display: none; }
body.cover-active .page-scroll { overflow: hidden !important; }
body.cover-active .hero,
body.cover-active .hero-inner { height: 100svh; min-height: 100svh; }
body.cover-active .hero-inner { padding-top: 4vh; padding-bottom: 10vh; }

.topbar {
  height: 72px;
  position: sticky;
  z-index: 60;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 max(32px, calc((100vw - 1240px) / 2));
  border-bottom: 1px solid rgba(36, 53, 58, 0.1);
  background: rgba(252, 250, 245, 0.94);
  backdrop-filter: blur(18px);
}
.topbar::after { content: ""; position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; background: linear-gradient(90deg, var(--lacquer) 0 21%, var(--bronze) 21% 39%, var(--river) 39% 72%, #345f9b 72% 100%); opacity: .72; }

.brand { display: flex; align-items: center; gap: 13px; }
.brand-mark {
  width: 39px;
  height: 39px;
  display: grid;
  place-items: center;
  position: relative;
  color: var(--lacquer);
  border: 1px solid var(--lacquer);
  font: 700 20px/1 var(--serif);
}
.brand-mark::after { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(156, 48, 41, 0.28); }
.brand-copy { display: flex; flex-direction: column; gap: 3px; }
.brand-copy strong { font: 400 14px/1.2 var(--serif); letter-spacing: .06em; }
.brand-copy small { color: #809093; font: 7px/1.2 var(--serif); letter-spacing: .13em; }
.topnav { display: flex; align-items: center; gap: 30px; font-size: 12px; }
.topnav > a { position: relative; padding: 27px 0; color: #657579; }
.topnav > a::after { content: ""; position: absolute; right: 50%; bottom: 17px; left: 50%; height: 1px; background: var(--lacquer); transition: .2s ease; }
.topnav > a:hover::after { right: 0; left: 0; }
.open-directory { border: 0; cursor: pointer; }
.topnav .open-directory { display: flex; align-items: center; gap: 9px; padding: 10px 14px; color: white; background: var(--river); }
.menu-lines { width: 15px; display: grid; gap: 3px; }
.menu-lines i { width: 100%; height: 1px; background: currentColor; }
.menu-lines i:nth-child(2) { width: 10px; }

.hero {
  min-height: calc(100vh - 72px);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: #f4eee2;
}
.hero::before { display: none; }
.hero-art { position: absolute; z-index: -3; inset: 0; background: url("./assets/visuals/hubei-hero-v2.jpg") center / cover no-repeat; }
.hero-wash { position: absolute; z-index: -2; inset: 0; background: linear-gradient(90deg, rgba(249, 245, 236, .99) 0%, rgba(249, 245, 236, .96) 31%, rgba(249, 245, 236, .55) 51%, rgba(249, 245, 236, 0) 70%); }
.hero-wash::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 70%, rgba(22, 77, 88, .08)); }
.hero-inner { width: var(--shell); min-height: calc(100vh - 72px); display: flex; align-items: center; margin: 0 auto; padding: 62px 0 110px; }
.hero-copy { width: min(650px, 54vw); position: relative; z-index: 3; }
.eyebrow { display: flex; align-items: center; gap: 13px; margin-bottom: 20px; color: var(--lacquer); }
.eyebrow b { font: 30px/1 var(--serif); }
.eyebrow i { width: 42px; height: 1px; background: var(--lacquer); }
.eyebrow span { font-size: 11px; font-weight: 600; letter-spacing: .18em; }
.hero-kicker { margin: 0 0 12px; color: var(--river); font-size: 15px; font-weight: 600; letter-spacing: .2em; }
.hero h1 { margin: 0; font-family: var(--serif); line-height: 1.08; }
.hero h1 span { display: block; font-size: clamp(39px, 4vw, 60px); font-weight: 400; letter-spacing: .05em; }
.hero h1 strong { display: block; margin-top: 3px; color: var(--lacquer); font-size: clamp(76px, 8vw, 118px); font-weight: 500; letter-spacing: .13em; }
.hero-lead { max-width: 520px; margin: 24px 0 28px; color: #59696d; font-size: 15px; line-height: 2; }
.hero-actions { display: flex; align-items: center; gap: 24px; margin-top: clamp(20px, 2.2vh, 28px); }
.primary-button { min-width: 210px; min-height: 58px; display: inline-flex; align-items: center; justify-content: space-between; gap: 48px; padding: 0 25px; color: #fff; background: var(--lacquer); box-shadow: 0 12px 28px rgba(110,33,29,.16); font-size: 16px; transition: .2s ease; }
.primary-button:hover { transform: translateY(-2px); background: var(--lacquer-dark); box-shadow: 0 10px 30px rgba(110, 33, 29, .18); }
.text-button { padding: 10px 0; color: var(--river); border-bottom: 1px solid rgba(21, 92, 104, .4); font-size: 12px; }
.hero-stats { display: flex; gap: 0; margin: 34px 0 0; }
.hero-stats div { min-width: 105px; padding: 0 20px; border-left: 1px solid rgba(36, 53, 58, .13); }
.hero-stats div:first-child { padding-left: 0; border-left: 0; }
.hero-stats dt { color: var(--river); font: 30px/1 var(--serif); }
.hero-stats dd { margin: 7px 0 0; color: var(--muted); font-size: 10px; letter-spacing: .08em; }
.hero-caption { position: absolute; right: 4.8vw; bottom: 36px; display: flex; align-items: center; gap: 10px; color: rgba(255, 253, 248, .85); font: 10px/1 var(--serif); letter-spacing: .18em; }
.hero-caption i { width: 22px; height: 1px; background: currentColor; opacity: .6; }
.scroll-cue { position: absolute; bottom: 25px; left: 50%; display: flex; flex-direction: column; align-items: center; gap: 8px; transform: translateX(-50%); color: var(--river); font-size: 9px; letter-spacing: .2em; }
.scroll-cue i { width: 1px; height: 28px; background: linear-gradient(var(--river), transparent); animation: scrollPulse 1.8s infinite; }
@keyframes scrollPulse { 0%,100% { transform: scaleY(.45); transform-origin: top; opacity: .4; } 50% { transform: scaleY(1); opacity: 1; } }

.foreword { position: relative; isolation: isolate; overflow: hidden; padding: 112px 0 124px; background: linear-gradient(126deg, rgba(255,250,241,.98), rgba(242,238,228,.94) 46%, rgba(233,242,237,.92)); }
.foreword::before { content: ""; position: absolute; z-index: -2; inset: 0; background: url("./assets/visuals/hubei-page-pattern.svg") center top / cover no-repeat; opacity: .76; pointer-events: none; }
.foreword::after { content: ""; position: absolute; z-index: -1; right: -5%; bottom: -20px; left: -5%; height: 430px; background: url("./assets/visuals/hubei-river-landmarks.svg") center bottom / cover no-repeat; filter: sepia(.2) saturate(.65); opacity: .055; pointer-events: none; }
.foreword-layout { display: grid; grid-template-columns: 270px minmax(0, 1fr); gap: 92px; align-items: start; }
.section-heading > span { color: var(--lacquer); font: 10px/1.2 var(--serif); letter-spacing: .18em; }
.section-heading h2 { margin: 15px 0 16px; font: 400 clamp(42px, 5vw, 68px)/1 var(--serif); letter-spacing: .08em; }
.section-heading > p, .section-heading > div > p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.85; }
.sticky-heading { position: sticky; top: 108px; }
.sticky-heading::before { content: "序"; position: absolute; z-index: -1; top: 30px; left: -32px; color: rgba(156, 48, 41, .045); font: 170px/1 var(--serif); }
.foreword-paper { position: relative; overflow: hidden; padding: 58px 66px 64px; border: 1px solid rgba(166, 124, 67, .22); background: linear-gradient(145deg, rgba(255,253,248,.97), rgba(255,253,248,.91) 72%, rgba(15,120,128,.07)); box-shadow: 0 24px 70px rgba(27, 48, 53, .09); }
.foreword-paper::before { content: ""; position: absolute; inset: 11px; pointer-events: none; border: 1px solid rgba(166, 124, 67, .13); }
.foreword-paper::after { content: ""; position: absolute; right: -86px; bottom: -92px; width: 250px; height: 250px; border: 1px solid rgba(15,120,128,.12); border-radius: 50%; box-shadow: inset 0 0 0 46px rgba(15,120,128,.025), inset 0 0 0 92px rgba(179,58,48,.022); pointer-events: none; }
.foreword-paper p { position: relative; margin: 0 0 25px; color: #526267; font-size: 15px; line-height: 2.1; text-align: justify; }
.foreword-paper p.lead { color: var(--lacquer); font-family: var(--serif); font-size: 18px; font-weight: 600; }
.foreword-paper h3 { display: flex; align-items: center; gap: 14px; position: relative; margin: 37px 0 13px; color: var(--river); font: 400 21px/1.4 var(--serif); }
.foreword-paper h3 span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--river); font: 11px/1 var(--serif); }

.catalog { height: calc(100svh - 72px); min-height: 640px; display: flex; align-items: stretch; position: relative; isolation: isolate; overflow: hidden; padding: 14px 0 20px; background: linear-gradient(128deg, #fff9ef 0%, #f6ecdc 36%, #edf2ed 68%, #f7efe2 100%); }
.catalog::before { content: ""; position: absolute; z-index: -2; inset: 0; opacity: .12; background: url("./assets/visuals/catalog-pattern.svg") center / cover no-repeat; pointer-events: none; }
.catalog::after { content: ""; position: absolute; z-index: -1; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 14% 18%, rgba(179,58,48,.1), transparent 28%), radial-gradient(ellipse at 88% 12%, rgba(52,95,155,.09), transparent 30%), radial-gradient(ellipse at 78% 84%, rgba(39,116,93,.08), transparent 30%), linear-gradient(180deg, rgba(255,253,248,.5), rgba(255,253,248,.72)); }
.catalog > .page-shell { height: 100%; min-height: 0; display: flex; flex-direction: column; position: relative; z-index: 1; }
.catalog-heading { flex: 0 0 auto; display: flex; align-items: center; justify-content: center; gap: 0; margin-bottom: 4px; }
.catalog-heading h2 { flex: 0 0 auto; display: flex; align-items: center; gap: 18px; margin: 0; color: #263d42; font: 400 44px/1.05 var(--serif); letter-spacing: .16em; text-indent: .16em; text-shadow: 0 2px 0 rgba(255,255,255,.82), 0 7px 18px rgba(36,53,58,.08); }
.catalog-heading h2::before, .catalog-heading h2::after { content: ""; width: 72px; height: 2px; background: linear-gradient(90deg, transparent, var(--lacquer)); }
.catalog-heading h2::after { transform: scaleX(-1); }
.catalog-heading > span { display: none; }
.search-panel { max-width: 880px; position: relative; margin: 0 0 44px 362px; z-index: 10; }
.search-panel label { height: 58px; display: grid; grid-template-columns: 38px 1fr auto; align-items: center; gap: 8px; padding: 0 17px; border: 1px solid rgba(21, 92, 104, .22); background: rgba(255, 253, 248, .92); box-shadow: 0 12px 34px rgba(27, 48, 53, .06); }
.search-panel label > span { color: var(--river); font: 24px/1 var(--serif); }
.search-panel input { width: 100%; border: 0; outline: 0; color: var(--ink); background: none; font-size: 14px; }
.search-panel input::placeholder { color: #96a09f; }
.search-panel kbd { padding: 6px 9px; border: 0; border-radius: 2px; color: #8b9798; background: #eeeae1; font: 10px/1 var(--sans); }
.search-results { position: absolute; top: 66px; right: 0; left: 0; max-height: 440px; overflow-y: auto; border: 1px solid rgba(36, 53, 58, .12); background: var(--white); box-shadow: var(--shadow); }
.search-results header { display: flex; justify-content: space-between; padding: 15px 19px; color: var(--muted); border-bottom: 1px solid var(--line); font-size: 11px; }
.search-result-link { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: 14px 19px; border-bottom: 1px solid rgba(36, 53, 58, .08); text-align: left; background: transparent; cursor: pointer; }
.search-result-link:hover { background: rgba(21, 92, 104, .05); }
.search-result-link span { display: flex; flex-direction: column; gap: 4px; }
.search-result-link small { color: var(--muted); font-size: 10px; }
.search-result-link strong { font-size: 13px; }
.search-result-link i { color: var(--lacquer); font-style: normal; }
.search-results > p { margin: 0; padding: 28px; color: var(--muted); text-align: center; font-size: 13px; }
.chapter-grid { flex: 1 1 auto; min-height: 0; display: block; }
.chapter-card { min-height: 236px; position: relative; overflow: hidden; border: 1px solid rgba(var(--chapter-color-rgb), .42); background: linear-gradient(135deg, rgba(var(--chapter-color-rgb), .28) 0%, rgba(var(--chapter-color-rgb), .12) 28%, rgba(255, 253, 248, .9) 58%), linear-gradient(180deg, rgba(255,255,255,.26), rgba(var(--chapter-color-rgb), .08)); box-shadow: 0 14px 34px rgba(31, 44, 48, .075); transition: .22s ease; }
.chapter-card::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 5px; background: linear-gradient(180deg, var(--chapter-color), rgba(var(--chapter-color-rgb), .56)); transition: .22s ease; }
.chapter-card::after { content: ""; position: absolute; right: -38px; bottom: -46px; width: 148px; height: 148px; border: 1px solid rgba(var(--chapter-color-rgb), .26); border-radius: 50%; box-shadow: inset 0 0 0 32px rgba(var(--chapter-color-rgb), .055), inset 0 0 0 63px rgba(255,255,255,.18); }
.chapter-card:hover, .chapter-card.active { transform: translateY(-3px); border-color: rgba(var(--chapter-color-rgb), .68); background: linear-gradient(135deg, rgba(var(--chapter-color-rgb), .34) 0%, rgba(var(--chapter-color-rgb), .16) 35%, rgba(255, 253, 248, .92) 70%); box-shadow: 0 18px 42px rgba(var(--chapter-color-rgb), .18); }
.chapter-card:hover::before, .chapter-card.active::before { width: 6px; }
.chapter-card-entry { width: 100%; height: 116px; position: relative; z-index: 1; padding: 18px 22px; overflow: hidden; border: 0; border-bottom: 1px solid rgba(var(--chapter-color-rgb), .16); text-align: left; background: none; cursor: pointer; }
.chapter-card-entry::before { content: ""; position: absolute; top: 14px; right: 18px; width: 74px; height: 38px; opacity: .28; background: repeating-linear-gradient(135deg, rgba(var(--chapter-color-rgb), .8) 0 1px, transparent 1px 9px); mask-image: linear-gradient(90deg, transparent, black 28%, black 70%, transparent); }
.chapter-card-entry::after { content: ""; position: absolute; right: 62px; bottom: 24px; width: 42%; height: 1px; background: linear-gradient(90deg, transparent, rgba(var(--chapter-color-rgb), .28), transparent); }
.chapter-meta { display: inline-flex; align-items: center; gap: 7px; position: absolute; left: 22px; top: 20px; color: var(--chapter-color); white-space: nowrap; line-height: 1; }
.chapter-meta i { font: normal 12px/1 var(--serif); letter-spacing: .05em; }
.chapter-meta b { font-size: 8px; font-weight: 500; letter-spacing: .16em; }
.chapter-mark { position: absolute; top: -14px; right: 14px; color: rgba(var(--chapter-color-rgb), .105); font: 112px/1 var(--serif); }
.chapter-card h3 { position: absolute; left: 22px; bottom: 17px; max-width: calc(100% - 76px); margin: 0; font: 600 27px/1.15 var(--serif); letter-spacing: .07em; overflow-wrap: break-word; }
.chapter-arrow { width: 32px; height: 32px; display: grid; place-items: center; position: absolute; right: 18px; bottom: 18px; color: var(--chapter-color); border: 1px solid rgba(var(--chapter-color-rgb), .44); background: rgba(255,255,255,.62); transition: .2s ease; }
.chapter-arrow svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.chapter-card:hover .chapter-arrow { color: white; background: var(--chapter-color); transform: translateX(2px); }
.chapter-category-list { position: relative; z-index: 2; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; padding: 12px 14px 15px; }
.chapter-category-list button { min-height: 36px; display: grid; grid-template-columns: 21px minmax(0, 1fr); align-items: center; gap: 7px; padding: 6px 8px; border: 1px solid rgba(var(--chapter-color-rgb), .15); border-radius: 5px; color: var(--ink); text-align: left; background: rgba(255, 253, 248, .62); cursor: pointer; transition: .18s ease; }
.chapter-category-list button:hover { color: var(--chapter-color); border-color: rgba(var(--chapter-color-rgb), .38); background: rgba(var(--chapter-color-rgb), .1); transform: translateY(-1px); }
.chapter-category-list i { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--chapter-color); font: normal 7px/1 var(--serif); }
.chapter-category-list span { min-width: 0; font-size: 10px; font-weight: 600; line-height: 1.35; overflow-wrap: break-word; }
.chapter-category-more { display: none; }
.chapter-card { display: none; }
.mobile-chapter-flow { width: 100%; height: 100%; min-height: 0; display: flex; flex-direction: column; justify-content: center; position: relative; margin: 0 auto; }
.mobile-flow-item { flex: 0 0 auto; min-height: 0; position: relative; overflow: visible; }
.mobile-flow-item:nth-of-type(2) { margin-top: -16px; }
.mobile-flow-item:nth-of-type(n + 3) { margin-top: -20px; }
.mobile-flow-step { width: 111px; position: relative; z-index: 3; left: calc(50% + 21px); display: block; padding: 0; border: 0; line-height: 0; background: transparent; transform: translateX(-50%); cursor: pointer; transition: transform .18s ease; }
.mobile-flow-item:nth-of-type(2) .mobile-flow-step { left: calc(50% - 31px); }
.mobile-flow-item:nth-of-type(3) .mobile-flow-step { left: calc(50% + 25px); }
.mobile-flow-item:nth-of-type(4) .mobile-flow-step { left: calc(50% - 29px); }
.mobile-flow-item:nth-of-type(5) .mobile-flow-step { left: calc(50% + 25px); }
.mobile-flow-item:nth-of-type(6) .mobile-flow-step { width: 82px; left: calc(50% - 41px); }
.mobile-flow-step:hover { transform: translateX(-50%) scale(.97); }
.mobile-flow-step img { width: 100%; height: auto; display: block; pointer-events: none; }
.mobile-flow-item:nth-of-type(1) .mobile-flow-step img { filter: hue-rotate(182deg) saturate(.8); }
.mobile-flow-item:nth-of-type(2) .mobile-flow-step img { filter: hue-rotate(104deg) saturate(.72); }
.mobile-flow-item:nth-of-type(3) .mobile-flow-step img { filter: hue-rotate(37deg) saturate(.62); }
.mobile-flow-item:nth-of-type(4) .mobile-flow-step img { filter: hue-rotate(180deg) saturate(.72); }
.mobile-flow-item:nth-of-type(5) .mobile-flow-step img { filter: hue-rotate(204deg) saturate(.68); }
.mobile-flow-item:nth-of-type(6) .mobile-flow-step img { filter: grayscale(1) saturate(0) brightness(.82); }
.mobile-flow-copy { width: max-content; max-width: min(280px, calc(50% - 84px)); min-width: 0; position: absolute; z-index: 2; top: 50%; right: calc(50% + 78px); left: auto; text-align: left; transform: translateY(-50%); }
.mobile-flow-item:nth-of-type(even) .mobile-flow-copy { right: auto; left: calc(50% + 78px); }
.mobile-flow-item.is-dense .mobile-flow-copy { transform: translateY(-50%) translateY(-8px); }
.mobile-flow-title { max-width: 100%; display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; color: var(--chapter-color); background: transparent; cursor: pointer; }
.mobile-flow-title i { width: 23px; height: 23px; display: grid; place-items: center; flex: 0 0 auto; color: var(--chapter-color); }
.mobile-flow-title i svg { width: 100%; height: 100%; display: block; overflow: visible; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.mobile-flow-title strong { font: 700 18px/1.1 var(--sans); letter-spacing: 0; white-space: nowrap; }
.mobile-flow-categories { width: max-content; max-width: calc(100% - 31px); display: grid; grid-template-columns: max-content max-content; justify-content: start; gap: 2px 9px; margin-top: 6px; padding-left: 31px; }
.mobile-flow-categories button { min-width: 0; padding: 0; border: 0; color: #5f6c70; text-align: left; background: transparent; cursor: pointer; }
.mobile-flow-categories button.is-long { grid-column: 1 / -1; }
.mobile-flow-categories button i { display: none; }
.mobile-flow-categories button span { display: block; min-width: 0; font-size: 10px; line-height: 1.4; white-space: nowrap; }
.mobile-flow-item.is-dense .mobile-flow-categories { row-gap: 0; margin-top: 3px; }
.mobile-flow-item.is-dense .mobile-flow-categories button span { font-size: 9px; line-height: 1.22; }
.mobile-flow-categories button:hover span { color: var(--chapter-color); }
.mobile-flow-more { display: none; }

.reader { position: relative; isolation: isolate; overflow: hidden; background: linear-gradient(140deg, #fffaf1 0%, #f4efe5 33%, #eef3ee 66%, #faf3e9 100%); }
.reader::before { content: ""; position: absolute; z-index: -2; inset: 0; background: url("./assets/visuals/hubei-page-pattern.svg") center top / 100% auto repeat-y; opacity: .88; pointer-events: none; }
.reader::after { content: ""; position: absolute; z-index: -1; top: 520px; right: -220px; width: 520px; height: 520px; border: 78px solid rgba(52,95,155,.045); border-radius: 50%; box-shadow: 0 0 0 54px rgba(15,120,128,.025), 0 0 0 110px rgba(179,58,48,.018); pointer-events: none; }
.reader-head { position: relative; overflow: hidden; color: white; background: var(--chapter-color-deep); transition: background-color .28s ease; }
.reader-head::before { content: ""; position: absolute; top: -190px; right: -90px; width: 500px; height: 500px; border: 74px solid rgba(255,255,255,.045); border-radius: 50%; box-shadow: 0 0 0 52px rgba(255,255,255,.023); }
.reader-head::after { content: ""; position: absolute; inset: -8% 0 -24%; opacity: .13; background: linear-gradient(90deg, transparent 0 35%, rgba(255,255,255,.08)), url("./assets/visuals/hubei-river-landmarks.svg") center 58% / cover no-repeat; filter: invert(1); mask-image: linear-gradient(90deg, transparent 18%, black 55%); }
.reader-head-inner { min-height: 255px; position: relative; z-index: 2; display: flex; align-items: center; justify-content: space-between; }
.reader-head-inner > div:first-child > span { color: rgba(255,255,255,.76); font: 10px/1 var(--serif); letter-spacing: .18em; }
.reader-head h2 { margin: 12px 0 8px; font: 400 58px/1.1 var(--serif); letter-spacing: .1em; }
.reader-head p { margin: 0; color: rgba(255,255,255,.58); font-size: 12px; letter-spacing: .07em; }
.reader-head-actions { display: flex; gap: 10px; }
.reader-head-actions button { padding: 11px 16px; border: 1px solid rgba(255,255,255,.28); color: white; background: rgba(255,255,255,.05); cursor: pointer; font-size: 11px; }
.mobile-directory-button { display: none; }
.reading-layout { display: grid; grid-template-columns: 248px minmax(0, 1fr); gap: 62px; align-items: start; position: relative; z-index: 1; padding-top: 70px; }
.reading-layout::before { content: ""; position: absolute; z-index: -1; top: 42px; bottom: 84px; left: -32px; width: 280px; border: 1px solid rgba(var(--chapter-color-rgb), .08); background: linear-gradient(180deg, rgba(255,253,248,.58), rgba(var(--chapter-color-rgb), .025)); box-shadow: 0 20px 65px rgba(27,48,53,.035); }
.sidebar-sticky { position: sticky; top: 100px; max-height: calc(100vh - 125px); overflow-y: auto; scrollbar-width: thin; }
.sidebar-label { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 18px; padding-bottom: 13px; border-bottom: 1px solid var(--ink); }
.sidebar-label span { font: 400 20px/1 var(--serif); }
.sidebar-label small { color: var(--muted); font-size: 9px; letter-spacing: .1em; }
.sidebar-group { margin-bottom: 15px; }
.category-link { display: grid; grid-template-columns: 29px 1fr auto; align-items: center; gap: 7px; padding: 8px 4px; }
.category-link i { color: var(--chapter-color); font: normal 10px/1 var(--serif); }
.category-link strong { font-size: 12px; }
.category-link small { min-width: 21px; height: 21px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); background: #ece8df; font-size: 9px; }
.sidebar-group > div { display: grid; gap: 2px; padding-left: 36px; }
.item-link { position: relative; padding: 5px 8px; color: #788588; font-size: 10px; line-height: 1.45; transition: .2s ease; }
.item-link::before { content: ""; position: absolute; top: 50%; left: -36px; width: 0; height: 1px; background: var(--chapter-color); transition: .2s ease; }
.item-link:hover, .item-link.active { color: var(--chapter-color); background: rgba(var(--chapter-color-rgb), .055); }
.item-link.active::before { width: 27px; }
.sidebar-progress { height: 2px; margin: 20px 0 15px; overflow: hidden; background: rgba(36, 53, 58, .1); }
.sidebar-progress i { width: 100%; height: 100%; display: block; transform: scaleX(0); transform-origin: left; background: var(--chapter-color); }
.all-directory-button { width: 100%; display: flex; justify-content: space-between; padding: 11px 12px; border: 1px solid rgba(var(--chapter-color-rgb), .24); color: var(--chapter-color); background: transparent; cursor: pointer; font-size: 10px; }
.reading-content { min-width: 0; padding-bottom: 74px; }
.category-section { scroll-margin-top: 94px; position: relative; isolation: isolate; margin-bottom: 82px; }
.category-section::before { content: ""; position: absolute; z-index: -1; top: 84px; right: -86px; width: 220px; height: 220px; border: 1px solid rgba(var(--chapter-color-rgb), .11); border-radius: 50%; box-shadow: inset 0 0 0 42px rgba(var(--chapter-color-rgb), .022), inset 0 0 0 78px rgba(var(--chapter-color-rgb), .018); }
.category-section::after { content: ""; position: absolute; z-index: -1; top: 18px; right: -54px; width: 145px; height: 64px; opacity: .34; background: repeating-linear-gradient(135deg, rgba(var(--chapter-color-rgb), .3) 0 1px, transparent 1px 10px); mask-image: linear-gradient(90deg, transparent, black 30%, black); }
.category-heading { display: grid; grid-template-columns: 58px 1fr auto; align-items: center; gap: 20px; margin-bottom: 22px; }
.category-heading > div:first-child { width: 58px; height: 58px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: white; background: var(--chapter-color); }
.category-heading > div:first-child span { font: 19px/1 var(--serif); }
.category-heading > div:first-child small { margin-top: 5px; font-size: 6px; letter-spacing: .12em; }
.category-heading p { margin: 0 0 3px; color: var(--chapter-color); font-size: 9px; letter-spacing: .12em; }
.category-heading h3 { margin: 0; font: 400 32px/1.2 var(--serif); letter-spacing: .08em; }
.category-heading > b { color: var(--muted); font-size: 10px; font-weight: 400; }
.item-overview { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: 16px; }
.item-overview a { min-height: 52px; display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 10px; padding: 10px 13px; border: 1px solid rgba(var(--chapter-color-rgb), .14); background: linear-gradient(105deg, rgba(255,253,248,.76), rgba(var(--chapter-color-rgb), .075)); box-shadow: 0 8px 22px rgba(27,48,53,.035); transition: .2s ease; }
.item-overview a:hover { border-color: rgba(var(--chapter-color-rgb), .34); background: var(--white); transform: translateY(-1px); }
.item-overview i { color: var(--chapter-color); font: normal 10px/1 var(--serif); }
.item-overview span { font-size: 11px; line-height: 1.4; }
.item-overview b { color: var(--bronze); font-size: 12px; font-weight: 400; }
.service-list { display: grid; gap: 18px; }
.service-item { scroll-margin-top: 94px; position: relative; overflow: hidden; border: 1px solid rgba(var(--chapter-color-rgb), .14); background: linear-gradient(112deg, rgba(255,253,248,.98) 0 72%, rgba(var(--chapter-color-rgb), .075)); box-shadow: 0 18px 48px rgba(27, 48, 53, .07); }
.service-item:nth-child(even) { background: linear-gradient(248deg, rgba(255,253,248,.98) 0 72%, rgba(var(--chapter-color-rgb), .06)); }
.service-item::before { content: ""; position: absolute; top: 0; right: 0; width: 86px; height: 86px; background: linear-gradient(135deg, transparent 0 49%, rgba(var(--chapter-color-rgb), .09) 50% 70%, rgba(var(--chapter-color-rgb), .15) 71% 100%); clip-path: polygon(26% 0, 100% 0, 100% 74%); pointer-events: none; }
.service-item::after { content: ""; position: absolute; right: 20px; bottom: 17px; width: 58px; height: 36px; opacity: .3; background: radial-gradient(circle, rgba(var(--chapter-color-rgb), .38) 1px, transparent 1.5px) 0 0 / 12px 12px; pointer-events: none; }
.service-item > * { position: relative; z-index: 1; }
.service-item > header { min-height: 92px; display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 17px; padding: 19px 26px; border-bottom: 1px solid rgba(var(--chapter-color-rgb), .1); background: rgba(255,253,248,.36); }
.service-item > header > span { height: 48px; display: grid; place-items: center; color: var(--chapter-color); border-right: 1px solid rgba(var(--chapter-color-rgb), .26); font: 16px/1 var(--serif); }
.service-item > header small { color: var(--chapter-color); font: 8px/1.2 var(--serif); letter-spacing: .13em; }
.service-item > header h4 { margin: 6px 0 0; font: 400 23px/1.35 var(--serif); }
.service-item > header > i { padding: 6px 9px; color: var(--chapter-color); background: rgba(var(--chapter-color-rgb), .07); font-size: 9px; font-style: normal; font-weight: 500; }
.service-body { padding: 27px 30px 31px; }
.service-body > p, .callout-content > p { margin: 0 0 17px; color: #536368; font-size: 14px; line-height: 2; text-align: justify; white-space: pre-line; }
.resource-link { width: 100%; min-height: 62px; display: grid; grid-template-columns: 35px 1fr auto; align-items: center; gap: 14px; margin-top: 9px; padding: 11px 14px; border: 1px solid rgba(var(--chapter-color-rgb), .2); text-align: left; background: rgba(var(--chapter-color-rgb), .04); transition: .2s ease; }
a.resource-link:hover, button.resource-link:hover { border-color: var(--chapter-color); background: rgba(var(--chapter-color-rgb), .08); }
.resource-link > i { width: 34px; height: 34px; display: grid; place-items: center; border: 1px solid rgba(var(--chapter-color-rgb), .48); border-radius: 2px; color: var(--chapter-color); background: rgba(255,255,255,.58); font-style: normal; }
.resource-link > i svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.resource-link > i svg rect { fill: none; }
.video-link > i svg path { fill: currentColor; stroke: none; }
.resource-link > span { display: flex; flex-direction: column; gap: 4px; }
.resource-link small { color: var(--muted); font-size: 8px; letter-spacing: .12em; }
.resource-link strong { font-size: 12px; font-weight: 600; line-height: 1.4; }
.resource-link > b { color: var(--chapter-color); font-size: 9px; font-weight: 500; }
button.resource-link { cursor: pointer; }
.incomplete-link { border-style: dashed; opacity: .68; }
.incomplete-link > i { color: #8e8170; border-color: rgba(142,129,112,.45); background: rgba(255,255,255,.58); }
.video-resource { margin: 20px 0 2px; overflow: hidden; border: 1px solid rgba(var(--chapter-color-rgb), .28); background: #10262b; box-shadow: 0 18px 38px rgba(20,38,43,.14); }
.video-resource.is-portrait { width: min(100%, 360px); margin-right: auto; margin-left: auto; }
.video-stage { position: relative; overflow: hidden; aspect-ratio: 16 / 9; background: #0b171a; }
.video-resource.is-portrait .video-stage { aspect-ratio: 9 / 16; max-height: min(68dvh, 640px); }
.video-resource video { width: 100%; height: 100%; display: block; object-fit: contain; background: #0b171a; }
.video-poster-button { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 9px; border: 0; color: white; background: linear-gradient(180deg, rgba(8,22,26,.04), rgba(8,22,26,.38)); cursor: pointer; transition: opacity .22s ease, visibility .22s ease; }
.video-poster-button::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at center, transparent 0 24%, rgba(4,14,16,.12) 68%, rgba(4,14,16,.34) 100%); }
.video-poster-button > span { width: 58px; height: 58px; position: relative; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.76); border-radius: 50%; background: rgba(var(--chapter-color-rgb), .9); box-shadow: 0 12px 30px rgba(0,0,0,.22); transition: transform .2s ease; }
.video-poster-button:hover > span { transform: scale(1.06); }
.video-poster-button svg { width: 24px; height: 24px; margin-left: 3px; fill: white; }
.video-poster-button small { position: relative; font-size: 10px; letter-spacing: .12em; text-shadow: 0 1px 5px rgba(0,0,0,.6); }
.video-resource.has-started .video-poster-button { visibility: hidden; opacity: 0; pointer-events: none; }
.video-resource figcaption { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px; padding: 13px 15px 14px; color: white; }
.video-resource figcaption span { color: #d9b46d; font: 8px/1.2 var(--serif); letter-spacing: .1em; }
.video-resource figcaption strong { min-width: 0; overflow: hidden; font: 500 12px/1.4 var(--sans); text-overflow: ellipsis; white-space: nowrap; }
.video-resource figcaption small { color: rgba(255,255,255,.56); font-size: 8px; }
.qr-resource { width: 178px; margin: 20px 0 4px; padding: 12px; border: 1px solid rgba(36,53,58,.13); background: white; }
.qr-resource img { width: 100%; display: block; }
.qr-resource figcaption { margin-top: 9px; color: var(--muted); font-size: 9px; line-height: 1.5; text-align: center; }
.mini-program-qr { width: min(100%, 250px); margin: 22px auto 5px; padding: 14px 14px 16px; border: 1px solid rgba(var(--chapter-color-rgb), .22); background: #fff; box-shadow: 0 15px 34px rgba(24, 43, 47, .09); }
.mini-program-qr-heading { display: flex; align-items: center; gap: 8px; margin-bottom: 11px; color: var(--chapter-color); }
.mini-program-qr-heading span, .mini-program-qr-heading small { flex: 0 0 auto; font-size: 7px; letter-spacing: .12em; }
.mini-program-qr-heading i { width: 100%; height: 1px; background: linear-gradient(90deg, rgba(var(--chapter-color-rgb), .45), transparent); }
.mini-program-qr-image { width: 100%; max-height: 246px; display: block; object-fit: contain; background: #fff; cursor: zoom-in; -webkit-touch-callout: default; user-select: auto; }
.mini-program-qr-image:focus-visible { outline: 2px solid var(--chapter-color); outline-offset: 3px; }
.mini-program-qr figcaption { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 11px 5px 0; text-align: center; }
.mini-program-qr figcaption strong { color: var(--ink); font: 600 14px/1.45 var(--serif); }
.mini-program-qr figcaption span { color: var(--chapter-color); font-size: 9px; letter-spacing: .04em; }
.mini-program-qr figcaption small { color: var(--muted); font-size: 8px; }
.editorial-callout { position: relative; overflow: hidden; margin: 26px 0 0; padding: 25px; border-left: 3px solid var(--chapter-color); background: linear-gradient(120deg, rgba(var(--chapter-color-rgb), .11), rgba(245,238,229,.92) 48%, rgba(255,253,248,.74)); }
.editorial-callout::before { content: ""; position: absolute; top: 0; right: 0; left: 0; height: 1px; background: linear-gradient(90deg, var(--chapter-color), rgba(var(--chapter-color-rgb), .18), transparent); }
.editorial-callout::after { content: ""; position: absolute; right: -48px; bottom: -52px; width: 150px; height: 150px; border: 1px solid rgba(var(--chapter-color-rgb), .12); border-radius: 50%; box-shadow: inset 0 0 0 28px rgba(var(--chapter-color-rgb), .025), inset 0 0 0 57px rgba(var(--chapter-color-rgb), .018); }
.callout-title { display: flex; align-items: center; gap: 13px; position: relative; z-index: 1; margin-bottom: 14px; }
.callout-title > span { padding: 5px 8px; color: white; background: var(--chapter-color); font-size: 8px; letter-spacing: .12em; }
.callout-title h4 { margin: 0; font: 400 17px/1.4 var(--serif); }
.callout-content { position: relative; z-index: 1; }
.callout-content > p { font-size: 12px; line-height: 1.9; }
.callout-content .resource-link { background: rgba(255,255,255,.62); }
.chapter-pager { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; padding-bottom: 100px; }
.chapter-pager button { min-height: 84px; display: flex; flex-direction: column; justify-content: center; gap: 7px; padding: 15px 21px; border: 1px solid rgba(var(--chapter-color-rgb), .22); text-align: left; background: var(--white); cursor: pointer; }
.chapter-pager button:last-child { text-align: right; }
.chapter-pager button:hover:not(:disabled) { color: white; border-color: var(--chapter-color); background: var(--chapter-color); }
.chapter-pager button:disabled { cursor: default; opacity: .45; }
.chapter-pager small { color: var(--muted); font-size: 9px; letter-spacing: .08em; }
.chapter-pager strong { font: 400 18px/1.2 var(--serif); }

.footer { position: relative; overflow: hidden; padding: 34px 0; color: rgba(255,255,255,.72); background: linear-gradient(105deg, #173d45, #1b4c53 54%, #28445c); }
.footer::before { content: ""; position: absolute; inset: -120px -40px -160px 34%; background: url("./assets/visuals/hubei-river-landmarks.svg") center / cover no-repeat; filter: invert(1); opacity: .055; pointer-events: none; }
.footer .page-shell { position: relative; z-index: 1; }
.footer .page-shell { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.footer div > div { display: flex; flex-direction: column; gap: 5px; }
.footer strong { color: white; font: 600 13px/1.3 var(--serif); }
.footer span, .footer p { margin: 0; font-size: 9px; letter-spacing: .08em; }
.footer a { color: rgba(255,255,255,.72); font-size: 9px; letter-spacing: .08em; text-decoration: none; }
.footer a:hover { color: white; text-decoration: underline; }

.drawer-backdrop { position: fixed; z-index: 90; inset: 0; opacity: 0; background: rgba(15, 35, 40, .45); backdrop-filter: blur(4px); transition: .25s ease; }
.drawer-backdrop.show { opacity: 1; }
.directory-drawer { width: min(520px, 94vw); position: fixed; z-index: 100; top: 0; right: 0; bottom: 0; display: flex; flex-direction: column; padding: 31px 36px; transform: translateX(102%); background: var(--paper-light); box-shadow: -25px 0 70px rgba(15,35,40,.18); transition: .28s ease; }
.directory-drawer.open { transform: translateX(0); }
.directory-drawer > header { display: flex; align-items: flex-start; justify-content: space-between; padding-bottom: 17px; border-bottom: 1px solid var(--ink); }
.directory-drawer > header span { color: var(--lacquer); font: 8px/1 var(--serif); letter-spacing: .16em; }
.directory-drawer > header h2 { margin: 7px 0 0; font: 400 31px/1 var(--serif); }
.close-directory { width: 40px; height: 40px; border: 1px solid var(--line); background: transparent; cursor: pointer; font-size: 25px; font-weight: 200; }
.drawer-search { min-height: 48px; display: grid; grid-template-columns: 28px 1fr; align-items: center; gap: 7px; margin: 20px 0; padding: 0 12px; border: 1px solid rgba(21,92,104,.18); background: white; }
.drawer-search span { color: var(--river); font: 20px/1 var(--serif); }
.drawer-search input { width: 100%; border: 0; outline: 0; background: transparent; font-size: 12px; }
#directoryNav { min-height: 0; overflow-y: auto; padding-right: 7px; }
.drawer-chapter { margin-bottom: 27px; }
.drawer-chapter > header { display: grid; grid-template-columns: 38px 1fr; align-items: center; gap: 11px; margin-bottom: 12px; }
.drawer-chapter > header > span { width: 38px; height: 38px; display: grid; place-items: center; color: white; background: var(--chapter-color); font: 12px/1 var(--serif); transition: .2s ease; }
.drawer-chapter.active > header > span { box-shadow: 0 0 0 4px rgba(var(--chapter-color-rgb), .13); transform: scale(1.04); }
.drawer-chapter > header small { color: var(--chapter-color); font-size: 8px; letter-spacing: .09em; }
.drawer-chapter > header h3 { margin: 3px 0 0; font: 400 21px/1.2 var(--serif); }
.drawer-category { margin-left: 49px; border-top: 1px solid rgba(36,53,58,.1); }
.drawer-category-link { width: 100%; display: flex; align-items: center; justify-content: space-between; padding: 11px 0; text-align: left; background: none; cursor: pointer; }
.drawer-category-link span { font-size: 12px; font-weight: 600; }
.drawer-category-link small { min-width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); background: #eeeae2; font-size: 9px; }
.drawer-category > div { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px 12px; padding: 0 0 12px; }
.drawer-item-link { display: flex; justify-content: space-between; gap: 7px; padding: 5px 0; color: var(--muted); text-align: left; background: none; cursor: pointer; font-size: 9px; line-height: 1.4; }
.drawer-item-link:hover { color: var(--chapter-color); }
.drawer-category > div i { color: var(--chapter-color); font-style: normal; }
.empty-search { padding: 40px 10px; color: var(--muted); text-align: center; font-size: 12px; }
.chapter-menu-backdrop { position: fixed; z-index: 105; inset: 0; opacity: 0; background: rgba(23, 36, 39, .55); backdrop-filter: blur(3px); transition: opacity .22s ease; }
.chapter-menu-backdrop.show { opacity: 1; }
.chapter-menu-modal { width: min(430px, calc(100vw - 44px)); position: fixed; z-index: 110; top: 50%; left: 50%; opacity: 0; pointer-events: none; transform: translate(-50%, -46%) scale(.96); transition: opacity .22s ease, transform .22s ease; }
.chapter-menu-modal.open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.qr-preview-backdrop { position: fixed; z-index: 125; inset: 0; opacity: 0; background: rgba(13, 27, 30, .76); backdrop-filter: blur(6px); transition: opacity .22s ease; }
.qr-preview-backdrop.show { opacity: 1; }
.qr-preview-modal { width: min(440px, calc(100vw - 36px)); position: fixed; z-index: 130; top: 50%; left: 50%; opacity: 0; pointer-events: none; transform: translate(-50%, -46%) scale(.96); transition: opacity .22s ease, transform .22s ease; }
.qr-preview-modal.open { opacity: 1; pointer-events: auto; transform: translate(-50%, -50%) scale(1); }
.qr-preview-card { padding: 27px 28px 25px; border-top: 3px solid var(--active-chapter-color); text-align: center; background: #fffdf8; box-shadow: 0 28px 80px rgba(0,0,0,.3); }
.qr-preview-card > small { display: block; margin-bottom: 15px; color: var(--active-chapter-color); font: 8px/1 var(--serif); letter-spacing: .16em; }
.qr-preview-card img { width: 100%; max-height: min(54dvh, 410px); display: block; object-fit: contain; background: white; -webkit-touch-callout: default; user-select: auto; }
.qr-preview-card h2 { margin: 16px 0 6px; color: var(--ink); font: 400 21px/1.35 var(--serif); }
.qr-preview-card p { margin: 0; color: var(--muted); font-size: 10px; line-height: 1.7; }
.close-qr-preview { width: 42px; height: 42px; position: absolute; top: -17px; right: -17px; z-index: 1; border: 1px solid rgba(36,53,58,.13); border-radius: 50%; color: #536165; background: #fffdf8; box-shadow: 0 8px 22px rgba(11,28,32,.22); cursor: pointer; font-size: 25px; font-weight: 200; line-height: 1; }
.chapter-menu-card { position: relative; padding: 0 18px 20px; border: 1px solid rgba(var(--chapter-color-rgb), .2); border-radius: 9px; background: var(--white); box-shadow: 0 24px 70px rgba(11, 28, 32, .24); }
.chapter-menu-card > header { width: max-content; min-width: 174px; position: relative; margin: -20px auto 0; padding: 9px 25px 10px; color: white; text-align: center; background: var(--chapter-color); box-shadow: 0 8px 20px rgba(var(--chapter-color-rgb), .22); }
.chapter-menu-card > header small { display: block; margin-bottom: 3px; color: rgba(255,255,255,.72); font: 7px/1 var(--serif); letter-spacing: .16em; }
.chapter-menu-card > header h2 { margin: 0; font: 400 23px/1.15 var(--serif); letter-spacing: .08em; }
.chapter-menu-content { padding-top: 25px; }
.chapter-menu-heading { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; color: var(--chapter-color); }
.chapter-menu-heading span { flex: 0 0 auto; font: 400 14px/1 var(--serif); }
.chapter-menu-heading i { width: 100%; height: 1px; background: linear-gradient(90deg, rgba(var(--chapter-color-rgb), .5), transparent); }
.chapter-menu-heading small { flex: 0 0 auto; color: var(--muted); font-size: 9px; }
#chapterMenuNav { max-height: min(460px, 62dvh); overflow-y: auto; scroll-behavior: smooth; scrollbar-width: thin; scrollbar-color: rgba(55,73,77,.25) transparent; }
.chapter-menu-group { padding: 4px 4px 18px; border-bottom: 1px solid rgba(36,53,58,.09); scroll-margin-top: 8px; }
.chapter-menu-group + .chapter-menu-group { padding-top: 17px; }
.chapter-menu-group:last-child { padding-bottom: 4px; border-bottom: 0; }
.chapter-menu-group > header { display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 10px; margin-bottom: 10px; }
.chapter-menu-group > header b { width: 34px; height: 34px; display: grid; place-items: center; color: white; background: var(--chapter-color); font: 11px/1 var(--serif); }
.chapter-menu-group > header small { display: block; margin-bottom: 2px; color: var(--chapter-color); font-size: 7px; letter-spacing: .08em; }
.chapter-menu-group > header h3 { margin: 0; font: 400 17px/1.2 var(--serif); }
.chapter-menu-group > header em { padding: 4px 7px; border-radius: 10px; color: var(--chapter-color); background: rgba(var(--chapter-color-rgb), .11); font-size: 8px; font-style: normal; }
.chapter-menu-group.active { margin: 0 1px; padding-right: 8px; padding-left: 8px; border-radius: 7px; background: rgba(var(--chapter-color-rgb), .045); box-shadow: inset 3px 0 0 var(--chapter-color); }
.chapter-menu-categories { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.chapter-menu-category { min-height: 39px; display: grid; grid-template-columns: 21px 1fr; align-items: center; gap: 7px; padding: 6px 8px; border: 1px solid rgba(var(--chapter-color-rgb), .13); border-radius: 6px; color: var(--ink); text-align: left; background: rgba(var(--chapter-color-rgb), .055); cursor: pointer; transition: .18s ease; }
.chapter-menu-category:hover, .chapter-menu-category.current { border-color: rgba(var(--chapter-color-rgb), .42); color: var(--chapter-color); background: rgba(var(--chapter-color-rgb), .13); }
.chapter-menu-category i { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--chapter-color); font: normal 7px/1 var(--serif); }
.chapter-menu-category span { font-size: 10px; font-weight: 600; line-height: 1.35; }
.close-chapter-menu { width: 42px; height: 42px; display: block; margin: 16px auto 0; border: 1px solid rgba(255,255,255,.78); border-radius: 50%; color: #536165; background: rgba(255,253,248,.96); box-shadow: 0 8px 24px rgba(11,28,32,.18); cursor: pointer; font-size: 25px; font-weight: 200; line-height: 1; }
.floating-directory { position: fixed; z-index: 50; top: 50%; right: 0; bottom: auto; width: 46px; height: 70px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; border: 1px solid rgba(255,255,255,.68); border-right: 0; border-radius: 10px 0 0 10px; color: white; background: var(--active-chapter-color); box-shadow: -6px 10px 24px rgba(var(--active-chapter-rgb), .22); transform: translateY(-50%); transition: background-color .25s ease, transform .2s ease; }
.floating-directory:hover { transform: translate(-2px, -50%); }
.floating-directory span { font-size: 15px; }
.floating-directory b { font-size: 8px; font-weight: 500; letter-spacing: .08em; }
.toast { position: fixed; z-index: 120; bottom: 28px; left: 50%; max-width: min(430px, calc(100vw - 40px)); padding: 12px 18px; opacity: 0; pointer-events: none; transform: translate(-50%, 20px); color: white; background: #263c41; box-shadow: var(--shadow); font-size: 12px; line-height: 1.5; transition: .22s ease; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }

@media (max-width: 1040px) {
  :root { --shell: min(920px, calc(100vw - 48px)); }
  .topbar { padding: 0 24px; }
  .hero-copy { width: 61vw; }
  .hero-art { background-position: 43% center; }
  .foreword-layout, .catalog-heading { grid-template-columns: 210px 1fr; gap: 52px; }
  .search-panel { margin-left: 262px; }
  .chapter-grid { grid-template-columns: repeat(2, 1fr); }
  .reading-layout { grid-template-columns: 215px minmax(0, 1fr); gap: 35px; }
}

/* 桌面端按可用高度同步收紧，避免宽屏笔记本或浏览器缩放后首页内容相互挤压。 */
@media (min-width: 761px) and (max-height: 820px) {
  body.cover-active .hero-inner {
    padding-top: clamp(18px, 3vh, 28px);
    padding-bottom: clamp(44px, 7vh, 64px);
  }
  .eyebrow { margin-bottom: clamp(12px, 2vh, 16px); }
  .eyebrow b { font-size: clamp(24px, 3.6vh, 28px); }
  .hero h1 span { font-size: clamp(36px, min(4vw, 6.4vh), 56px); }
  .hero h1 strong { font-size: clamp(68px, min(8vw, 13vh), 104px); }
  .hero-actions { margin-top: clamp(14px, 2.2vh, 20px); }
  .primary-button { min-height: 54px; }
  .hero-stats { margin-top: clamp(20px, 3.2vh, 26px); }
}

@media (max-width: 760px) {
  :root { --shell: calc(100vw - 32px); }
  html { scroll-padding-top: 66px; }
  html.wechat-toolbar-persistent,
  html.wechat-toolbar-persistent body { height: 100%; overflow: hidden; }
  html.wechat-toolbar-booting .page-scroll { opacity: 0; }
  html.wechat-toolbar-persistent .page-scroll {
    height: var(--wechat-visible-height, 100%);
    overflow-x: hidden;
    overflow-y: auto;
    overscroll-behavior-y: contain;
    scroll-behavior: smooth;
    scroll-padding-top: 66px;
    -webkit-overflow-scrolling: touch;
    transition: opacity .15s ease;
  }
  html.wechat-toolbar-persistent .hero,
  html.wechat-toolbar-persistent .hero-inner {
    min-height: calc(var(--wechat-visible-height, 100svh) - 62px);
  }
  html.wechat-toolbar-persistent .catalog {
    height: calc(var(--wechat-visible-height, 100svh) - 62px);
    min-height: 480px;
    overflow: hidden;
  }
  html.wechat-toolbar-persistent body.cover-active .hero,
  html.wechat-toolbar-persistent body.cover-active .hero-inner {
    height: var(--wechat-visible-height, 100svh);
    min-height: var(--wechat-visible-height, 100svh);
  }
  html.wechat-toolbar-persistent body.drawer-open .page-scroll,
  html.wechat-toolbar-persistent body.chapter-menu-open .page-scroll,
  html.wechat-toolbar-persistent body.qr-preview-open .page-scroll { overflow: hidden; }
  .topbar { height: 62px; gap: 10px; padding: 0 16px; }
  .brand { min-width: 0; flex: 1 1 auto; }
  .brand-mark { width: 34px; height: 34px; flex: 0 0 34px; font-size: 18px; }
  .brand-copy { min-width: 0; }
  .brand-copy strong { max-width: 190px; overflow: hidden; font-size: 12px; line-height: 1.2; white-space: nowrap; text-overflow: ellipsis; }
  .brand-copy small, .topnav > a { display: none; }
  .topnav { flex: 0 0 auto; gap: 0; }
  .topnav .open-directory { flex: 0 0 auto; padding: 9px 11px; font-size: 10px; white-space: nowrap; }
  .hero { min-height: calc(100svh - 62px); }
  .hero-art { background-position: 66% center; }
  .hero-wash { background: linear-gradient(180deg, rgba(249,245,236,.97) 0%, rgba(249,245,236,.92) 52%, rgba(249,245,236,.15) 82%, rgba(15,70,81,.14) 100%); }
  .hero-inner { min-height: calc(100svh - 62px); align-items: center; padding: 24px 0 155px; }
  body.cover-active .hero-inner { align-items: center; padding: 2vh 0 12vh; }
  .hero-copy { width: 100%; }
  .eyebrow { margin-bottom: 16px; }
  .eyebrow b { font-size: 24px; }
  .hero h1 span { font-size: clamp(31px, 9.3vw, 44px); }
  .hero h1 strong { font-size: clamp(61px, 18vw, 86px); }
  .hero-actions { margin-top: 20px; }
  .primary-button { min-width: 208px; min-height: 58px; gap: 38px; padding: 0 23px; font-size: 16px; }
  .hero-stats { margin-top: 27px; }
  .hero-stats div { min-width: 0; flex: 1; padding: 0 8px; }
  .hero-stats dt { font-size: 22px; }
  .hero-stats dd { font-size: 8px; }
  .scroll-cue { display: none; }
  .foreword { padding: 70px 0 78px; }
  .foreword::before { background-position: 52% top; background-size: auto 100%; opacity: .62; }
  .foreword::after { right: -42%; bottom: -6px; left: -42%; height: 250px; opacity: .04; }
  .foreword-layout { display: block; }
  .sticky-heading { position: static; margin-bottom: 27px; }
  .section-heading h2 {
    font-family: var(--serif);
    font-size: 44px;
    font-weight: 400;
  }
  .foreword-paper { padding: 33px 25px 38px; }
  .foreword-paper,
  .reading-content { margin-right: 28px; }
  .foreword-paper::before { inset: 7px; }
  .foreword-paper p { font-size: 13px; line-height: 2; }
  .foreword-paper p.lead { font-size: 15px; }
  .foreword-paper h3 { font-size: 18px; }
  .catalog { height: calc(100dvh - 62px); min-height: 480px; align-items: stretch; overflow: hidden; padding: 10px 0 12px; }
  .catalog > .page-shell { height: 100%; min-height: 0; }
  .catalog::before { background-position: 57% center; background-size: auto 100%; }
  .catalog-heading { flex: 0 0 auto; justify-content: center; gap: 0; margin-bottom: 5px; }
  .catalog-heading > span { display: none; }
  .catalog-heading h2 { display: flex; align-items: center; gap: 15px; font-size: 38px; line-height: 1; letter-spacing: .16em; }
  .catalog-heading h2::before, .catalog-heading h2::after { content: ""; width: 54px; height: 2px; background: linear-gradient(90deg, transparent, var(--lacquer)); }
  .catalog-heading h2::after { transform: scaleX(-1); }
  .search-panel { flex: 0 0 auto; margin: 0 0 7px; }
  .search-panel label { height: 38px; grid-template-columns: 24px 1fr; padding: 0 10px; box-shadow: 0 7px 18px rgba(27, 48, 53, .05); }
  .search-panel label > span { font-size: 19px; }
  .search-panel kbd { display: none; }
  /* iOS Safari/微信会在聚焦小于 16px 的输入框时自动放大页面。 */
  .search-panel input,
  .drawer-search input { font-size: 16px; }
  .chapter-grid { flex: 1 1 auto; min-height: 0; display: block; }
  .chapter-card { display: none; }
  .mobile-chapter-flow { width: 100%; height: 100%; min-height: 0; display: flex; flex-direction: column; justify-content: center; position: relative; margin: 0; padding: 1px 0; }
  .mobile-flow-item:nth-of-type(2) { margin-top: -18px; }
  .mobile-flow-item:nth-of-type(n + 3) { margin-top: -23px; }
  .mobile-flow-step { width: 122px; left: calc(50% + 23px); }
  .mobile-flow-item:nth-of-type(2) .mobile-flow-step { left: calc(50% - 34px); }
  .mobile-flow-item:nth-of-type(3) .mobile-flow-step { left: calc(50% + 27px); }
  .mobile-flow-item:nth-of-type(4) .mobile-flow-step { left: calc(50% - 32px); }
  .mobile-flow-item:nth-of-type(5) .mobile-flow-step { left: calc(50% + 27px); }
  .mobile-flow-item:nth-of-type(6) .mobile-flow-step { width: 90px; left: calc(50% - 45px); }
  .mobile-flow-copy { width: max-content; max-width: calc(50% - 54px); right: calc(50% + 52px); left: auto; }
  .mobile-flow-item:nth-of-type(even) .mobile-flow-copy { right: auto; left: calc(50% + 52px); }
  .mobile-flow-item.is-dense .mobile-flow-copy { transform: translateY(-50%) translateY(-11px); }
  .mobile-flow-title { gap: 5px; }
  .mobile-flow-title i { width: 20px; height: 20px; }
  .mobile-flow-title strong { font-size: 17px; letter-spacing: 0; }
  .mobile-flow-categories { max-width: calc(100% - 23px); gap: 1px 8px; margin-top: 3px; padding-left: 23px; }
  .mobile-flow-categories button span { font-size: clamp(8px, 2.3vw, 9px); line-height: 1.35; }
  .mobile-flow-item.is-dense .mobile-flow-categories button span { font-size: clamp(7.5px, 2.1vw, 8.5px); line-height: 1.22; }
  html.wechat-viewport-compact .catalog { padding-top: 6px; padding-bottom: 8px; }
  html.wechat-viewport-compact .catalog-heading { margin-bottom: 2px; }
  html.wechat-viewport-compact .catalog-heading h2 { gap: 12px; font-size: 33px; }
  html.wechat-viewport-compact .catalog-heading h2::before,
  html.wechat-viewport-compact .catalog-heading h2::after { width: 42px; }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(2) { margin-top: -15px; }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(n + 3) { margin-top: -19px; }
  html.wechat-viewport-compact .mobile-flow-step { width: 104px; left: calc(50% + 20px); }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(2) .mobile-flow-step { left: calc(50% - 29px); }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(3) .mobile-flow-step { left: calc(50% + 23px); }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(4) .mobile-flow-step { left: calc(50% - 27px); }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(5) .mobile-flow-step { left: calc(50% + 23px); }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(6) .mobile-flow-step { width: 78px; left: calc(50% - 39px); }
  html.wechat-viewport-compact .mobile-flow-copy { max-width: calc(50% - 48px); right: calc(50% + 46px); }
  html.wechat-viewport-compact .mobile-flow-item:nth-of-type(even) .mobile-flow-copy { right: auto; left: calc(50% + 46px); }
  html.wechat-viewport-compact .mobile-flow-item.is-dense .mobile-flow-copy { transform: translateY(-50%) translateY(-7px); }
  html.wechat-viewport-compact .mobile-flow-title { gap: 4px; }
  html.wechat-viewport-compact .mobile-flow-title i { width: 18px; height: 18px; }
  html.wechat-viewport-compact .mobile-flow-title strong { font-size: 15px; }
  html.wechat-viewport-compact .mobile-flow-categories { max-width: calc(100% - 20px); gap: 0 7px; margin-top: 2px; padding-left: 20px; }
  html.wechat-viewport-compact .mobile-flow-categories button span { font-size: clamp(7.3px, 2vw, 8.3px); line-height: 1.25; }
  html.wechat-viewport-compact .mobile-flow-item.is-dense .mobile-flow-categories button span { font-size: clamp(7px, 1.9vw, 7.8px); line-height: 1.16; }
  html.wechat-viewport-tight .catalog-heading h2 { font-size: 30px; }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(2) { margin-top: -13px; }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(n + 3) { margin-top: -17px; }
  html.wechat-viewport-tight .mobile-flow-step { width: 94px; left: calc(50% + 18px); }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(2) .mobile-flow-step { left: calc(50% - 26px); }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(3) .mobile-flow-step { left: calc(50% + 21px); }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(4) .mobile-flow-step { left: calc(50% - 24px); }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(5) .mobile-flow-step { left: calc(50% + 21px); }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(6) .mobile-flow-step { width: 70px; left: calc(50% - 35px); }
  html.wechat-viewport-tight .mobile-flow-copy { max-width: calc(50% - 44px); right: calc(50% + 42px); }
  html.wechat-viewport-tight .mobile-flow-item:nth-of-type(even) .mobile-flow-copy { right: auto; left: calc(50% + 42px); }
  html.wechat-viewport-tight .mobile-flow-title i { width: 17px; height: 17px; }
  html.wechat-viewport-tight .mobile-flow-title strong { font-size: 14px; }
  html.wechat-viewport-tight .mobile-flow-categories { max-width: calc(100% - 18px); gap: 0 6px; padding-left: 18px; }
  html.wechat-viewport-tight .mobile-flow-categories button span { font-size: clamp(6.8px, 1.9vw, 7.7px); line-height: 1.18; }
  html.wechat-viewport-tight .mobile-flow-item.is-dense .mobile-flow-categories button span { font-size: clamp(6.6px, 1.8vw, 7.3px); line-height: 1.12; }
  .reader-head-inner { min-height: 192px; }
  .reader::before { background-position: 56% top; background-size: auto 1280px; opacity: .7; }
  .reader::after { top: 390px; right: -178px; width: 320px; height: 320px; border-width: 48px; box-shadow: 0 0 0 34px rgba(15,120,128,.022), 0 0 0 70px rgba(179,58,48,.016); }
  .reader-head::before { top: -104px; right: -98px; width: 310px; height: 310px; border-width: 45px; }
  .reader-head::after { inset: 0 -34% -8% -30%; opacity: .1; background-size: auto 220px; background-position: 64% 72%; mask-image: linear-gradient(90deg, transparent 8%, black 54%); }
  .reader-head h2 {
    font-family: var(--serif);
    font-size: 43px;
    font-weight: 400;
  }
  .reader-head-actions { flex-direction: column; }
  .reader-search-button { display: none; }
  .mobile-directory-button { display: block; }
  .reading-layout { display: block; padding-top: 40px; }
  .reading-layout::before { display: none; }
  .reading-sidebar { display: none; }
  .category-section { margin-bottom: 58px; scroll-margin-top: 75px; }
  .category-section::before { top: 62px; right: -88px; width: 178px; height: 178px; }
  .category-section::after { top: 10px; right: -26px; width: 96px; height: 48px; opacity: .28; }
  .category-heading { grid-template-columns: 48px 1fr auto; gap: 12px; }
  .category-heading > div:first-child { width: 48px; height: 48px; }
  .category-heading h3 { font-size: 26px; }
  .item-overview { grid-template-columns: 1fr; }
  .item-overview a { min-height: 48px; }
  .service-item { scroll-margin-top: 75px; }
  .service-item::before { width: 66px; height: 66px; opacity: .82; }
  .service-item::after { right: 12px; bottom: 12px; width: 42px; height: 30px; opacity: .22; }
  .service-item > header { min-height: 78px; grid-template-columns: 37px 1fr; gap: 12px; padding: 14px 17px; }
  .service-item > header > span { height: 40px; }
  .service-item > header > i { display: none; }
  .service-item > header h4 { font-size: 19px; }
  .service-body { padding: 21px 18px 24px; }
  .service-body > p, .callout-content > p { font-size: 13px; line-height: 1.9; text-align: left; }
  .resource-link { grid-template-columns: 31px 1fr; gap: 10px; padding: 10px; }
  .resource-link > i { width: 31px; height: 31px; }
  .resource-link > b { display: none; }
  .resource-link strong { font-size: 11px; }
  .video-resource { margin-top: 16px; }
  .video-resource.is-portrait { width: min(100%, 330px); }
  .video-poster-button > span { width: 52px; height: 52px; }
  .video-resource figcaption { grid-template-columns: 1fr; gap: 5px; padding: 11px 12px 12px; }
  .video-resource figcaption strong { font-size: 11px; white-space: normal; }
  .video-resource figcaption small { display: none; }
  .editorial-callout { margin-top: 21px; padding: 19px 16px; }
  .callout-title { align-items: flex-start; }
  .callout-title h4 { font-size: 16px; }
  .qr-resource { width: 160px; }
  .mini-program-qr { width: min(100%, 222px); margin-top: 18px; padding: 12px 12px 14px; }
  .mini-program-qr-image { max-height: 218px; }
  .qr-preview-card { padding: 23px 20px 21px; }
  .qr-preview-card h2 { font-size: 19px; }
  .close-qr-preview { top: -14px; right: -10px; }
  .chapter-pager { gap: 8px; padding-right: 28px; padding-bottom: 70px; }
  .chapter-pager button { min-height: 76px; padding: 12px 14px; }
  .chapter-pager strong { font-size: 15px; }
  .footer .page-shell { display: block; }
  .footer p { margin-top: 15px; line-height: 1.7; }
  .directory-drawer { width: 100%; top: auto; height: min(86dvh, 780px); padding: 25px 20px; transform: translateY(103%); border-radius: 17px 17px 0 0; }
  .directory-drawer.open { transform: translateY(0); }
  .directory-drawer > header h2 { font-size: 27px; }
  .drawer-category { margin-left: 0; }
  .drawer-category > div { grid-template-columns: 1fr; }
  .chapter-menu-modal {
    width: min(360px, calc(100vw - 34px));
    height: min(720px, calc(var(--wechat-visible-height, 100dvh) - 24px - env(safe-area-inset-bottom, 0px)));
    max-height: calc(var(--wechat-visible-height, 100dvh) - 24px - env(safe-area-inset-bottom, 0px));
    display: grid;
    grid-template-rows: minmax(0, 1fr) 42px;
    gap: 10px;
    padding-top: 20px;
  }
  .chapter-menu-card { min-height: 0; display: flex; flex-direction: column; padding: 0 14px 16px; }
  .chapter-menu-card > header { min-width: 158px; padding: 8px 20px 9px; }
  .chapter-menu-card > header h2 { font-size: 21px; }
  .chapter-menu-content { min-height: 0; flex: 1 1 auto; display: flex; flex-direction: column; padding-top: 22px; }
  #chapterMenuNav { min-height: 0; max-height: none; flex: 1 1 auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
  .chapter-menu-group { padding-bottom: 15px; }
  .chapter-menu-group + .chapter-menu-group { padding-top: 14px; }
  #chapterMenuNav button { min-height: 40px; padding: 6px 7px; }
  #chapterMenuNav button span { font-size: 10px; }
  .close-chapter-menu { margin: 0 auto; }
  .floating-directory { top: 50%; right: 0; bottom: auto; width: 43px; height: 68px; }
}

@media (max-width: 760px) and (max-height: 700px) {
  .chapter-menu-modal {
    height: calc(var(--wechat-visible-height, 100dvh) - 16px - env(safe-area-inset-bottom, 0px));
    max-height: calc(var(--wechat-visible-height, 100dvh) - 16px - env(safe-area-inset-bottom, 0px));
    grid-template-rows: minmax(0, 1fr) 38px;
    gap: 7px;
    padding-top: 16px;
  }
  .chapter-menu-card { padding-right: 11px; padding-bottom: 11px; padding-left: 11px; }
  .chapter-menu-card > header { min-width: 146px; margin-top: -16px; padding: 7px 17px 8px; }
  .chapter-menu-card > header h2 { font-size: 19px; }
  .chapter-menu-content { padding-top: 16px; }
  .chapter-menu-heading { margin-bottom: 10px; }
  .chapter-menu-group { padding-bottom: 11px; }
  .chapter-menu-group + .chapter-menu-group { padding-top: 11px; }
  #chapterMenuNav button { min-height: 36px; }
  .close-chapter-menu { width: 38px; height: 38px; font-size: 23px; }
}

/* Reference-led catalog: clear editorial hierarchy with a dedicated illustration zone. */
.catalog {
  height: calc(100svh - 72px);
  min-height: 620px;
  display: block;
  overflow: hidden;
  padding: clamp(20px, 3vh, 34px) 0 clamp(14px, 2.2vh, 26px);
  color: var(--ink);
  background: linear-gradient(160deg, #edf2ed 0%, #f5f1e8 18%, #fbf7ef 54%, #f8f0e4 100%);
}
.catalog::before {
  z-index: 0;
  inset: auto 0 0;
  height: min(56.28vw, 100%);
  opacity: .76;
  filter: saturate(.64) contrast(.86) brightness(1.08);
  background: url("./assets/visuals/catalog-yangtze-bridge-bottom-v6.jpg") 50% 100% / contain no-repeat;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, transparent 42%, rgba(0,0,0,.1) 55%, rgba(0,0,0,.55) 72%, #000 100%);
  mask-image: linear-gradient(180deg, transparent 0%, transparent 42%, rgba(0,0,0,.1) 55%, rgba(0,0,0,.55) 72%, #000 100%);
}
.catalog::after {
  z-index: 0;
  inset: auto 0 0;
  height: 5px;
  background: linear-gradient(90deg, var(--lacquer) 0 21%, var(--bronze) 21% 39%, var(--river) 39% 72%, #5b7faa 72% 100%);
}
.catalog > .page-shell {
  width: min(1040px, calc(100vw - 72px));
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 1;
}
.catalog-heading {
  display: grid;
  position: relative;
  grid-template-columns: 96px minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  margin: 0;
  padding: 0 10px clamp(16px, 2.2vh, 23px);
  border-bottom: 1px solid rgba(36, 53, 58, .24);
  text-align: left;
}
.catalog-heading::after {
  content: "";
  width: 78px;
  height: 3px;
  position: absolute;
  left: 0;
  bottom: -2px;
  background: var(--lacquer);
}
.catalog-heading-mark {
  width: 70px;
  height: 70px;
  position: relative;
  border: 11px solid rgba(15, 100, 105, .98);
  border-top-color: transparent;
  border-radius: 50%;
  transform: rotate(-42deg);
}
.catalog-heading-mark::before {
  content: "";
  width: 28px;
  height: 28px;
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  background: #faf6ee;
  transform: translate(-50%, -50%);
}
.catalog-heading-mark::after {
  content: "";
  width: 10px;
  height: 24px;
  position: absolute;
  top: -10px;
  left: 50%;
  background: var(--lacquer);
  transform: translateX(-50%);
}
.catalog-heading-mark i {
  display: none;
}
.catalog-heading-copy { align-self: center; }
.catalog-heading .catalog-heading-copy h2 {
  display: block;
  margin: 0;
  color: var(--ink);
  font: 400 52px/.98 var(--serif);
  letter-spacing: .18em;
  text-indent: 0;
  text-shadow: 0 2px 0 rgba(255, 253, 248, .86), 0 8px 24px rgba(36, 53, 58, .12);
}
.catalog-heading .catalog-heading-copy h2::before,
.catalog-heading .catalog-heading-copy h2::after { display: none; }
.catalog-heading-meta {
  display: flex;
  align-items: center;
  gap: 34px;
}
.catalog-heading-meta span {
  display: grid;
  grid-template-columns: auto auto;
  align-items: center;
  gap: 9px;
  color: rgba(36, 53, 58, .86);
}
.catalog-heading-meta b {
  color: var(--lacquer);
  font: 500 35px/1 var(--serif);
  letter-spacing: -.04em;
}
.catalog-heading-meta em {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font: 700 12px/1 var(--serif);
  font-style: normal;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}
.catalog-heading-meta small {
  color: rgba(36, 53, 58, .58);
  font: 600 8px/1 var(--serif);
  letter-spacing: .06em;
}
.catalog .chapter-grid {
  flex: 1 1 auto;
  min-height: 0;
  display: block;
}
.catalog-directory {
  --catalog-row-line-1: 29.333%;
  --catalog-row-line-2: 65.333%;
  height: 100%;
  display: grid;
  position: relative;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: minmax(0, .88fr) minmax(0, 1.08fr) minmax(0, 1.04fr);
  column-gap: 0;
  border-top: 0;
  background:
    linear-gradient(180deg, transparent 0%, rgba(36, 53, 58, .035) 12%, rgba(36, 53, 58, .095) 48%, rgba(36, 53, 58, .055) 82%, transparent 100%) 50% 0 / 1px 100% no-repeat,
    linear-gradient(90deg, transparent 0%, rgba(36, 53, 58, .035) 8%, rgba(36, 53, 58, .085) 48%, rgba(36, 53, 58, .045) 88%, transparent 100%) 0 var(--catalog-row-line-1) / 100% 1px no-repeat,
    linear-gradient(90deg, transparent 0%, rgba(36, 53, 58, .035) 8%, rgba(36, 53, 58, .085) 48%, rgba(36, 53, 58, .045) 88%, transparent 100%) 0 var(--catalog-row-line-2) / 100% 1px no-repeat;
}
.catalog-directory-item {
  width: 100%;
  min-width: 0;
  display: block;
  margin: 0;
  padding: clamp(14px, 2vh, 22px) 34px clamp(14px, 2vh, 22px);
  border-top: 0;
  background: transparent;
}
.catalog-directory-item:nth-child(1) { grid-area: 1 / 1; border-top: 0; }
.catalog-directory-item:nth-child(2) { grid-area: 2 / 1; }
.catalog-directory-item:nth-child(3) { grid-area: 3 / 1; }
.catalog-directory-item:nth-child(4) { grid-area: 1 / 2; border-top: 0; border-left: 0; }
.catalog-directory-item:nth-child(5) { grid-area: 2 / 2; border-left: 0; }
.catalog-directory-item:nth-child(6) { grid-area: 3 / 2; border-left: 0; }
.catalog-directory-item:nth-child(-n + 3) { padding-left: 20px; }
.catalog-directory-item:nth-child(n + 4) { padding-right: 20px; }
.catalog-directory-item:nth-child(1),
.catalog-directory-item:nth-child(4) {
  border-top: 0;
}
.catalog-chapter-link {
  width: 100%;
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr) 32px;
  align-items: center;
  gap: 14px;
  padding: 0;
  border: 0;
  color: var(--ink);
  text-align: left;
  background: transparent;
  cursor: pointer;
}
.catalog-chapter-index {
  color: var(--chapter-color);
  font: 500 34px/1 var(--serif);
  letter-spacing: -.02em;
  transition: color .2s ease;
}
.catalog-chapter-title { display: block; }
.catalog-chapter-title strong {
  color: var(--chapter-color);
  font: 400 28px/1.12 var(--serif);
  letter-spacing: .08em;
}
.catalog-chapter-arrow {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(var(--chapter-color-rgb), .72);
  border-radius: 50%;
  color: var(--chapter-color);
  font-size: 13px;
  transition: .2s ease;
}
.catalog-chapter-arrow svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.catalog-chapter-link:hover .catalog-chapter-index { color: var(--chapter-color-deep); }
.catalog-chapter-link:hover .catalog-chapter-arrow {
  color: #fff;
  background: var(--chapter-color);
  transform: translateX(2px);
}
.catalog-chapter-body {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  align-items: start;
  gap: 24px;
  margin-top: 14px;
}
.catalog-chapter-icon {
  width: 78px;
  height: 78px;
  display: grid;
  place-items: center;
  margin-top: 2px;
  border: 1px solid rgba(var(--chapter-color-rgb), .08);
  border-radius: 50%;
  color: var(--chapter-color);
  background: rgba(var(--chapter-color-rgb), .08);
}
.catalog-chapter-icon svg {
  width: 42px;
  height: 42px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.catalog-subentries {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  margin: 0;
}
.catalog-subentry {
  min-height: 24px;
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr);
  align-items: start;
  gap: 7px;
  padding: 1px 0;
  border: 0;
  color: #27383c;
  font: 400 13px/1.2 var(--serif);
  text-align: left;
  background: transparent;
  cursor: pointer;
  transition: .18s ease;
}
.catalog-subentry i {
  width: 3px;
  height: 3px;
  margin-top: calc(.6em - 1.5px);
  border-radius: 50%;
  background: var(--chapter-color);
  box-shadow: none;
}
.catalog-subentry span {
  min-width: 0;
  font: inherit;
  letter-spacing: .02em;
}
.catalog-subentry small { display: none; }
.catalog-subentry:hover {
  padding-left: 4px;
  color: var(--chapter-color-deep);
  background: linear-gradient(90deg, rgba(var(--chapter-color-rgb), .09), transparent);
}

@media (max-width: 1040px) {
  .catalog > .page-shell { width: min(940px, calc(100vw - 44px)); }
  .catalog-heading { grid-template-columns: 78px minmax(0, 1fr) auto; gap: 18px; }
  .catalog-heading-meta { gap: 16px; }
  .catalog-directory-item { padding-right: 22px; }
  .catalog-directory-item:nth-child(-n + 3) { padding-left: 12px; }
  .catalog-directory-item:nth-child(n + 4) { padding-right: 12px; padding-left: 22px; }
  .catalog-chapter-body { grid-template-columns: 68px minmax(0, 1fr); gap: 18px; }
  .catalog-chapter-icon { width: 64px; height: 64px; }
  .catalog-chapter-icon svg { width: 35px; height: 35px; }
}

@media (min-width: 761px) and (max-height: 900px) {
  .catalog { padding: 12px 0 14px; }
  .catalog-heading {
    grid-template-columns: 72px minmax(0, 1fr) auto;
    gap: 16px;
    margin-bottom: 7px;
    padding-bottom: 10px;
  }
  .catalog-heading-mark { width: 60px; height: 60px; border-width: 10px; }
  .catalog-heading-mark::before { width: 25px; height: 25px; }
  .catalog-heading-mark::after { width: 9px; height: 20px; top: -9px; }
  .catalog-heading-mark i { right: -18px; bottom: -9px; height: 34px; }
  .catalog-heading .catalog-heading-copy h2 { font-size: 46px; }
  .catalog-heading-meta { gap: 18px; }
  .catalog-heading-meta b { font-size: 28px; }
  .catalog-directory-item { padding-top: 8px; padding-bottom: 9px; }
  .catalog-chapter-link { grid-template-columns: 48px minmax(0, 1fr) 26px; gap: 10px; }
  .catalog-chapter-index { font-size: 27px; }
  .catalog-chapter-title strong { font-size: 24px; }
  .catalog-chapter-body { grid-template-columns: 58px minmax(0, 1fr); gap: 12px; margin-top: 8px; }
  .catalog-chapter-icon { width: 54px; height: 54px; }
  .catalog-chapter-icon svg { width: 30px; height: 30px; }
  .catalog-subentry { min-height: 19px; font-size: 11.5px; line-height: 1.12; }
  .catalog-subentry i { margin-top: calc(.56em - 1.5px); }
}

@media (max-width: 760px) {
  .catalog {
    height: calc(100dvh - 62px);
    min-height: 0;
    overflow: hidden;
    padding: clamp(11px, 1.7dvh, 16px) 0 max(7px, env(safe-area-inset-bottom, 0px));
  }
  .catalog::before {
    inset: 0;
    height: 100%;
    opacity: .78;
    filter: saturate(.62) contrast(.84) brightness(1.09);
    background: url("./assets/visuals/catalog-yangtze-bridge-mobile-v4.jpg") 50% 100% / 100% auto no-repeat;
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, transparent 55%, rgba(0,0,0,.08) 67%, rgba(0,0,0,.62) 82%, #000 100%);
    mask-image: linear-gradient(180deg, transparent 0%, transparent 55%, rgba(0,0,0,.08) 67%, rgba(0,0,0,.62) 82%, #000 100%);
  }
  html.wechat-toolbar-persistent .catalog {
    height: calc(var(--wechat-visible-height, 100svh) - 62px);
    min-height: 0;
  }
  .catalog > .page-shell {
    width: calc(100vw - 30px);
    height: 100%;
    display: grid;
    grid-template-rows: clamp(84px, 13.5dvh, 98px) minmax(0, 1fr) clamp(34px, 5dvh, 46px);
  }
  .catalog > .page-shell::after { content: ""; display: block; }
  .catalog-heading {
    min-height: 0;
    grid-template-columns: 44px minmax(82px, 1fr) minmax(136px, auto);
    align-items: center;
    gap: 10px;
    margin-bottom: 0;
    padding: 9px 1px 15px;
  }
  .catalog-heading-mark {
    width: 42px;
    height: 42px;
    border-width: 7px;
  }
  .catalog-heading-mark::before { width: 17px; height: 17px; }
  .catalog-heading-mark::after { width: 7px; height: 15px; top: -7px; }
  .catalog-heading .catalog-heading-copy h2 {
    display: block;
    font-family: var(--serif);
    font-size: clamp(32px, 9.2vw, 37px);
    font-weight: 400;
    letter-spacing: .14em;
  }
  .catalog-heading-meta {
    grid-column: auto;
    flex-direction: row;
    justify-content: flex-end;
    gap: clamp(6px, 2.4vw, 11px);
    padding: 0;
    border: 0;
  }
  .catalog-heading-meta span { display: grid; grid-template-columns: auto 1fr; gap: 3px; }
  .catalog-heading-meta b { font-size: clamp(15px, 4.4vw, 18px); }
  .catalog-heading-meta em { gap: 1px; font-size: 6px; }
  .catalog-heading-meta small { font-size: 4.5px; letter-spacing: 0; }
  .catalog .chapter-grid { min-height: 0; display: block; }
  .catalog-directory {
    --catalog-row-line-2: 64.667%;
    height: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: minmax(0, .88fr) minmax(0, 1.06fr) minmax(0, 1.06fr);
    column-gap: 0;
  }
  .catalog-directory::before { display: none; }
  .catalog-directory-item {
    width: 100%;
    height: auto;
    display: block;
    position: relative;
    z-index: 1;
    min-height: 0;
    padding: clamp(7px, 1.2vh, 10px) 8px;
  }
  .catalog-directory-item:nth-child(-n + 3) { padding-left: 1px; }
  .catalog-directory-item:nth-child(n + 4) { padding-right: 1px; padding-left: 9px; }
  .catalog-chapter-link { grid-template-columns: 27px minmax(0, 1fr) 19px; gap: 5px; }
  .catalog-chapter-index { font-size: clamp(16px, 2.5vh, 18px); }
  .catalog-chapter-title strong { font-size: clamp(16px, 2.55vh, 18px); letter-spacing: .05em; white-space: nowrap; }
  .catalog-chapter-arrow { width: 19px; height: 19px; }
  .catalog-chapter-arrow svg { width: 11px; height: 11px; }
  .catalog-chapter-body { grid-template-columns: 39px minmax(0, 1fr); gap: 7px; margin-top: 6px; }
  .catalog-chapter-icon { width: 37px; height: 37px; margin-top: 2px; }
  .catalog-chapter-icon svg { width: 22px; height: 22px; stroke-width: 1.8; }
  .catalog-subentries { row-gap: clamp(.5px, .12dvh, 1.5px); }
  .catalog-subentry { min-height: clamp(17px, 2.35dvh, 20px); grid-template-columns: 4px minmax(0, 1fr); gap: 5px; padding: 1px 0; font-size: clamp(9.4px, 1.42dvh, 10.6px); line-height: 1.24; }
  .catalog-subentry i { width: 3px; height: 3px; margin-top: calc(.62em - 1.5px); box-shadow: none; }
  .catalog-subentry span { overflow-wrap: anywhere; letter-spacing: 0; }
  .catalog-subentry small { display: none; }
}

@media (max-width: 760px) and (max-height: 700px) {
  .catalog { padding-top: 9px; padding-bottom: 6px; }
  .catalog > .page-shell { grid-template-rows: clamp(74px, 12.5dvh, 84px) minmax(0, 1fr) clamp(24px, 4.5dvh, 32px); }
  .catalog-heading { padding-top: 7px; padding-bottom: 13px; }
  .catalog-heading-mark { width: 40px; height: 40px; border-width: 7px; }
  .catalog-heading .catalog-heading-copy h2 { font-size: 32px; }
  .catalog-heading-meta b { font-size: 15px; }
  .catalog-heading-meta { gap: 6px; }
  .catalog-directory-item { padding-top: 4px; padding-bottom: 4px; }
  .catalog-chapter-title strong { font-size: 16px; }
  .catalog-chapter-index { font-size: 16px; }
  .catalog-chapter-body { grid-template-columns: 35px minmax(0, 1fr); gap: 6px; margin-top: 4px; }
  .catalog-chapter-icon { width: 33px; height: 33px; }
  .catalog-chapter-icon svg { width: 20px; height: 20px; }
  .catalog-subentries { row-gap: 0; }
  .catalog-subentry { min-height: 13.5px; padding-block: .5px; font-size: 9px; line-height: 1.16; }
  .catalog-subentry i { margin-top: calc(.58em - 1.5px); }
}

/* 窄屏手机：为品牌、目录标题和统计信息分别保留独立空间，避免字体外扩后相互覆盖。 */
@media (max-width: 400px) {
  .topbar { gap: 8px; padding-inline: 10px; }
  .brand { gap: 8px; }
  .brand-mark { width: 32px; height: 32px; flex-basis: 32px; font-size: 17px; }
  .brand-copy strong { max-width: none; font-size: clamp(10px, 2.9vw, 11.2px); letter-spacing: .02em; }
  .topnav .open-directory { gap: 7px; padding: 9px 9px; }

  .catalog > .page-shell { width: calc(100vw - 20px); }
  .catalog-heading {
    grid-template-columns: 38px minmax(68px, 82px) minmax(0, 1fr);
    gap: 7px;
    padding-inline: 0;
  }
  .catalog-heading-mark { width: 38px; height: 38px; border-width: 6px; }
  .catalog-heading-mark::before { width: 16px; height: 16px; }
  .catalog-heading-mark::after { width: 6px; height: 14px; top: -6px; }
  .catalog-heading-copy { min-width: 0; }
  .catalog-heading .catalog-heading-copy h2 {
    max-width: 100%;
    font-size: clamp(27px, 8vw, 31px);
    line-height: 1;
    letter-spacing: .1em;
    white-space: nowrap;
  }
  .catalog-heading-meta { min-width: 0; gap: clamp(4px, 1.4vw, 7px); }
  .catalog-heading-meta span { min-width: 0; grid-template-columns: auto minmax(0, 1fr); gap: 2px; }
  .catalog-heading-meta b { font-size: clamp(13px, 4vw, 16px); }
  .catalog-heading-meta em { min-width: 0; font-size: 5.5px; }
  .catalog-heading-meta small { font-size: 4px; }

  .catalog-directory-item:nth-child(n + 4) { padding-left: 7px; }
  .catalog-chapter-link { grid-template-columns: 25px minmax(0, 1fr) 18px; gap: 4px; }
  .catalog-chapter-index { font-size: clamp(15px, 2.35vh, 17px); }
  .catalog-chapter-title strong { font-size: clamp(15px, 2.4vh, 17px); letter-spacing: .025em; }
  .catalog-chapter-arrow { width: 18px; height: 18px; }
  .catalog-chapter-body { grid-template-columns: 35px minmax(0, 1fr); gap: 6px; }
  .catalog-chapter-icon { width: 34px; height: 34px; }
  .catalog-chapter-icon svg { width: 20px; height: 20px; }
}

/* 中等高度手机适当收紧；高屏手机保留更舒展的二级标题节奏。 */
@media (max-width: 760px) and (min-height: 701px) and (max-height: 819px) {
  .catalog-subentries { row-gap: clamp(.5px, .12dvh, 1px); }
  .catalog-subentry { min-height: clamp(16px, 2.25dvh, 19px); padding-block: .7px; font-size: clamp(9px, 1.35dvh, 10px); line-height: 1.19; }
  .catalog-subentry i { margin-top: calc(.595em - 1.5px); }
}

@media (max-width: 760px) and (min-height: 820px) {
  .catalog-subentries { row-gap: clamp(1px, .16dvh, 2px); }
  .catalog-subentry { min-height: clamp(19px, 2.45dvh, 22px); padding-block: 1.2px; line-height: 1.27; }
  .catalog-subentry i { margin-top: calc(.635em - 1.5px); }
}

@media (max-width: 360px) {
  .catalog > .page-shell { width: calc(100vw - 16px); }
  .catalog-heading { grid-template-columns: 35px minmax(62px, 72px) minmax(0, 1fr); gap: 6px; }
  .catalog-heading-mark { width: 35px; height: 35px; }
  .catalog-heading .catalog-heading-copy h2 { font-size: clamp(25px, 7.8vw, 28px); letter-spacing: .08em; }
  .catalog-heading-meta { gap: 3px; }
  .catalog-heading-meta b { font-size: 13px; }
  .catalog-heading-meta em { font-size: 5px; }
  .catalog-heading-meta small { font-size: 3.7px; }
  .catalog-subentry { gap: 4px; }
}

@media (max-width: 760px) {
  html.wechat-viewport-compact .catalog {
    padding-top: 8px;
    padding-bottom: max(6px, env(safe-area-inset-bottom, 0px));
  }
  html.wechat-viewport-compact .catalog > .page-shell {
    grid-template-rows: clamp(74px, 12.5dvh, 84px) minmax(0, 1fr) clamp(20px, 3.5dvh, 28px);
  }
  html.wechat-viewport-tight .catalog {
    padding-top: 6px;
    padding-bottom: max(5px, env(safe-area-inset-bottom, 0px));
  }
  html.wechat-viewport-tight .catalog > .page-shell {
    grid-template-rows: clamp(66px, 12dvh, 74px) minmax(0, 1fr) clamp(18px, 3.8dvh, 24px);
  }
  html.wechat-viewport-tight .catalog-heading {
    padding-top: 5px;
    padding-bottom: 9px;
  }
  html.wechat-viewport-tight .catalog-heading-mark {
    width: 36px;
    height: 36px;
    border-width: 6px;
  }
  html.wechat-viewport-tight .catalog-heading .catalog-heading-copy h2 { font-size: 28px; }
  html.wechat-viewport-tight .catalog-directory-item { padding-top: 3px; padding-bottom: 3px; }
  html.wechat-viewport-tight .catalog-chapter-body { margin-top: 3px; }
  html.wechat-viewport-tight .catalog-subentries { row-gap: 0; }
  html.wechat-viewport-tight .catalog-subentry { min-height: 12.8px; padding-block: .4px; font-size: 8.7px; line-height: 1.14; }
  html.wechat-viewport-tight .catalog-subentry i { margin-top: calc(.57em - 1.5px); }
}

@media (max-width: 340px) and (max-height: 620px) {
  .catalog-subentry { min-height: 12.5px; font-size: 8.6px; line-height: 1.12; }
  .catalog-subentry i { margin-top: calc(.56em - 1.5px); }
}

/* 手机横屏时宽度会超过竖屏断点：统一切回紧凑顶栏，并让整页自然滚动。 */
@media (max-width: 980px) and (max-height: 500px) and (orientation: landscape) {
  html { scroll-padding-top: 66px; }
  .topbar { height: 62px; padding: 0 16px; }
  .brand-mark { width: 34px; height: 34px; font-size: 18px; }
  .brand-copy strong { max-width: 230px; font-size: 12px; }
  .brand-copy small,
  .topnav > a { display: none; }
  .topnav { gap: 0; }
  .topnav .open-directory { padding: 9px 11px; font-size: 10px; }
  .catalog,
  html.wechat-toolbar-persistent .catalog {
    height: auto;
    min-height: calc(var(--wechat-visible-height, 100dvh) - 62px);
    overflow: visible;
  }
  .catalog > .page-shell,
  html.wechat-viewport-compact .catalog > .page-shell,
  html.wechat-viewport-tight .catalog > .page-shell {
    width: calc(100vw - 30px);
    height: auto;
    grid-template-rows: auto auto 18px;
  }
  .catalog > .page-shell::after { content: ""; display: block; }
  .catalog-heading {
    min-height: 72px;
    grid-template-columns: 54px minmax(100px, 1fr) auto;
    gap: 12px;
    padding: 5px 1px 12px;
  }
  .catalog-heading-mark { width: 46px; height: 46px; border-width: 8px; }
  .catalog-heading .catalog-heading-copy h2 { font-size: 36px; }
  .catalog-heading-meta { gap: 12px; }
  .catalog-heading-meta b { font-size: 21px; }
  .catalog-directory {
    height: auto;
    grid-template-rows: repeat(3, auto);
  }
  .catalog-directory-item { min-height: 0; padding-top: 8px; padding-bottom: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* 电子版阅读文字上调一级；封面大标题与展示数字维持原版比例。 */
.hero h1 span { letter-spacing: .065em; }
.hero h1 strong {
  margin-top: 12px;
  letter-spacing: .15em;
}
.hero-actions { margin-top: 30px; }
.foreword-paper p {
  margin-bottom: 28px;
  font-size: 16px;
  line-height: 2.16;
}
.foreword-paper p.lead {
  font-size: 19px;
  line-height: 2;
}
.catalog-subentry {
  min-height: 26px;
  font-size: 14px;
  line-height: 1.3;
}
.reader-head p,
.reader-head-actions button { font-size: 13px; }
.sidebar-label span { font-size: 21px; }
.sidebar-label small { font-size: 10px; }
.category-link i { font-size: 11px; }
.category-link strong { font-size: 13px; }
.category-link small { font-size: 10px; }
.item-link {
  padding-block: 6px;
  font-size: 11px;
  line-height: 1.55;
}
.all-directory-button { font-size: 11px; }
.category-heading > div:first-child span { font-size: 22px; }
.category-heading > div:first-child small { font-size: 9px; }
.category-heading p { font-size: 12px; }
.category-heading h3 { font-size: 35px; }
.category-heading > b { font-size: 13px; }
.item-overview a {
  min-height: 64px;
  grid-template-columns: 30px 1fr auto;
  gap: 12px;
  padding: 13px 16px;
}
.item-overview i { font-size: 14px; }
.item-overview span {
  font-size: 15px;
  line-height: 1.55;
}
.item-overview b { font-size: 16px; }
.service-item > header h4 { font-size: 24px; }
.service-body > p,
.callout-content > p {
  margin-bottom: 20px;
  font-size: 15px;
  line-height: 2.08;
}
.resource-link small { font-size: 9px; }
.resource-link strong {
  font-size: 13px;
  line-height: 1.5;
}
.resource-link > b { font-size: 10px; }
.drawer-category-link span { font-size: 13px; }
.drawer-item-link {
  padding-block: 6px;
  font-size: 10px;
  line-height: 1.55;
}
.chapter-menu-category span {
  font-size: 11px;
  line-height: 1.45;
}

@media (min-width: 761px) and (max-height: 900px) {
  .catalog-subentry {
    min-height: 21px;
    font-size: 12.5px;
    line-height: 1.2;
  }
}

@media (max-width: 760px) {
  .hero h1 span { letter-spacing: .065em; }
  .hero h1 strong { margin-top: 8px; }
  .hero-actions { margin-top: 24px; }
  .category-heading h3 { font-size: 29px; }
  .item-overview a { min-height: 60px; }
  .foreword-paper p {
    margin-bottom: 28px;
    font-size: 14px;
    line-height: 2.12;
  }
  .foreword-paper p.lead {
    font-size: 16px;
    line-height: 2.06;
  }
  .catalog-subentry {
    min-height: clamp(18px, 2.48dvh, 21px);
    font-size: clamp(10.4px, calc(1.42dvh + 1px), 11.6px);
    line-height: 1.3;
  }
  .reader-head p,
  .reader-head-actions button { font-size: 13px; }
  .service-item > header h4 { font-size: 20px; }
  .service-body > p,
  .callout-content > p {
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 2.02;
  }
  .resource-link strong {
    font-size: 12px;
    line-height: 1.55;
  }
}

@media (max-width: 760px) and (max-height: 700px) {
  .catalog-subentry {
    min-height: 14.5px;
    font-size: 10px;
    line-height: 1.22;
  }
}

@media (max-width: 760px) and (min-height: 701px) and (max-height: 819px) {
  .catalog-subentry {
    min-height: clamp(17px, 2.38dvh, 20px);
    font-size: clamp(10px, calc(1.35dvh + 1px), 11px);
    line-height: 1.26;
  }
}

@media (max-width: 760px) {
  html.wechat-viewport-tight .catalog-subentry {
    min-height: 13.8px;
    font-size: 9.7px;
    line-height: 1.2;
  }
}

@media (max-width: 340px) and (max-height: 620px) {
  .catalog-subentry {
    min-height: 13.5px;
    font-size: 9.6px;
    line-height: 1.18;
  }
}
