/* Reading pages: report archive, guides, about and policy pages. Builds on home.css tokens. */
.doc-page .topbar { color: var(--ink); background: color-mix(in srgb, var(--page) 86%, transparent); border-bottom-color: var(--line); }
.doc-page .nav { display: flex; }
.doc-page .nav a[aria-current="page"] { opacity: 1; background: color-mix(in srgb, currentColor 10%, transparent); }
.doc { width: min(1080px, 100%); margin-inline: auto; padding: clamp(28px, 5vw, 56px) var(--gutter) clamp(56px, 8vw, 96px); }
.doc > * { max-width: 760px; }
.doc > .wide, .doc > .table-scroll, .doc > .doc-head, .doc > .crumbs, .doc > .pager, .doc > .hub-grid { max-width: none; }

.crumbs { font-size: 13px; color: var(--muted); margin-bottom: clamp(20px, 3vw, 32px); }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; }
.crumbs li + li::before { content: "/"; margin-right: 8px; color: var(--dim); }
.crumbs a { color: inherit; text-decoration: none; display: inline-flex; align-items: center; min-height: 32px; }
.crumbs a:hover { color: var(--blue); }

.doc-head { margin-bottom: clamp(28px, 4vw, 44px); }
.doc-kicker { font: 600 13px var(--body); color: var(--blue); letter-spacing: .02em; margin-bottom: 12px; }
.doc h1 { font: 700 clamp(32px, 4.6vw, 54px)/1.06 var(--display); letter-spacing: -0.035em; max-width: 880px; }
html[lang="zh-Hant"] .doc h1 { line-height: 1.2; letter-spacing: -0.01em; }
.doc-lede { font-size: clamp(18px, 1.9vw, 21px); line-height: 1.55; color: var(--muted); margin-top: 16px; max-width: 760px; }
.asof { margin-top: 20px; font-size: 14px; line-height: 1.6; color: var(--muted); max-width: 760px; }
.asof b { color: var(--ink); font-weight: 600; }

.doc h2 { font: 700 clamp(23px, 2.6vw, 30px)/1.2 var(--display); letter-spacing: -0.02em; margin-top: clamp(44px, 6vw, 64px); margin-bottom: 14px; }
.doc h3 { font: 700 19px/1.3 var(--display); letter-spacing: -0.01em; margin-top: 32px; margin-bottom: 8px; }
html[lang="zh-Hant"] .doc h2, html[lang="zh-Hant"] .doc h3 { letter-spacing: 0; }
.doc p, .doc li { font-size: 17px; line-height: 1.72; }
.doc p + p, .doc p + ul, .doc p + ol, .doc ul + p, .doc ol + p { margin-top: 14px; }
.doc ul, .doc ol { padding-left: 22px; margin: 0; }
.doc li + li { margin-top: 6px; }
.doc a { color: var(--blue); text-underline-offset: 3px; }
.doc .note { color: var(--muted); font-size: 15px; line-height: 1.65; }
.doc .formula { font: 500 15px/1.7 var(--mono); color: var(--ink); background: var(--surface-2); border-radius: 10px; padding: 14px 16px; margin-top: 14px; overflow-x: auto; white-space: pre; }
.up { color: var(--up); }
.down { color: var(--down); }

/* Key figures: plain numbers on the page, no cards */
.figures { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px 32px; margin: 0; padding: 20px 0; border-block: 1px solid var(--line); }
.figures div { min-width: 0; }
.figures dt { font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.figures dd { margin: 0; font: 700 clamp(22px, 2.4vw, 28px)/1.15 var(--display); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.figures dd small { display: block; font: 400 13px/1.4 var(--body); color: var(--muted); letter-spacing: 0; margin-top: 4px; }

.table-scroll { overflow-x: auto; margin-top: 16px; -webkit-overflow-scrolling: touch; }
.data { width: 100%; border-collapse: collapse; font-size: 15px; font-variant-numeric: tabular-nums; }
.data caption { text-align: left; font-size: 13px; color: var(--muted); padding-bottom: 8px; caption-side: top; }
.data th, .data td { padding: 9px 14px 9px 0; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); }
.data th:first-child, .data td:first-child, .data .text { text-align: left; }
.data th:last-child, .data td:last-child { padding-right: 0; }
.data thead th { font-weight: 600; font-size: 13px; color: var(--muted); border-bottom-color: var(--ink); vertical-align: bottom; }
.data tbody th { font-weight: 600; }
.data .name { color: var(--muted); font-weight: 400; white-space: normal; min-width: 140px; }
.data a { color: inherit; text-decoration: none; }
.data a:hover { color: var(--blue); text-decoration: underline; }

.pager { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; margin-top: clamp(40px, 6vw, 64px); padding-top: 20px; border-top: 1px solid var(--line); font-size: 15px; }
.pager a { color: var(--blue); text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.pager a:hover { text-decoration: underline; }

.hub-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 40px; margin-top: 8px; }
.hub-grid h2 { margin-top: 0; font-size: 22px; }
.hub-grid ul { list-style: none; padding: 0; }
.hub-grid li { border-bottom: 1px solid var(--line); margin: 0; }
.hub-grid li a { display: flex; justify-content: space-between; gap: 12px; padding: 11px 0; text-decoration: none; color: var(--ink); font-size: 15px; font-variant-numeric: tabular-nums; }
.hub-grid li a:hover { color: var(--blue); }
.hub-grid li span { color: var(--muted); }
.hub-more { display: inline-block; margin-top: 14px; font-size: 15px; }

.link-list { list-style: none; padding: 0; }
.link-list li { padding: 18px 0; border-bottom: 1px solid var(--line); margin: 0; }
.link-list a { font: 700 20px/1.3 var(--display); text-decoration: none; }
.link-list a:hover { text-decoration: underline; }
.link-list p { color: var(--muted); font-size: 16px; margin-top: 6px; }

.glossary dt { font: 700 18px/1.3 var(--display); margin-top: 26px; }
.glossary dd { margin: 6px 0 0; font-size: 17px; line-height: 1.7; }

.disclaimer { margin-top: clamp(40px, 6vw, 64px); font-size: 14px; line-height: 1.65; color: var(--muted); }

.doc-footer { border-top: 1px solid var(--line); padding-block: 48px 32px; }
.doc-footer-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.doc-footer h2 { font: 600 13px var(--body); color: var(--muted); margin-bottom: 10px; }
.doc-footer nav { display: flex; flex-direction: column; gap: 2px; }
.doc-footer nav a { color: var(--ink); text-decoration: none; font-size: 15px; display: inline-flex; align-items: center; min-height: 36px; }
.doc-footer nav a:hover { color: var(--blue); }
.doc-footer .footer-base { margin-top: 40px; }

@media (max-width: 900px) {
  .doc-page .nav { display: none; }
  .figures { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hub-grid { grid-template-columns: 1fr; }
  .doc-footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .doc-footer nav a { min-height: 44px; }
}
