/* IYKYDK Maps 教學頁共用樣式：螢幕上是深色底上的一張白色 A4 紙，列印時只印紙張本身。
   鐵則：字級不小於 11px、無陰影、無圓角、不用 Emoji。 */
:root {
  --base: #0D0D0D; --border: #2E2E2E; --border-lt: #3A3A3A; --text-1: #E8E4DC; --text-2: #A0998E;
  --ink: #141414; --ink-2: #4a4a4a; --rule: #c9c9c9; --paper: #ffffff; --tint: #f3f1ea;
  --brown: #a4662e; --blue: #1f5fbf; --water: #4f8dbe; --accent: #C0392B;
  --serif: 'Noto Serif TC', Georgia, serif;
  --sans: 'Noto Sans TC', 'Microsoft JhengHei', 'PingFang TC', sans-serif;
  --mono: 'IBM Plex Mono', Consolas, 'Courier New', monospace;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }
body { background: var(--base); color: var(--text-1); font-family: var(--sans); line-height: 1.6; -webkit-font-smoothing: antialiased; }

.bar { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 56px; padding: 0 1rem; background: var(--base); border-bottom: 1px solid var(--border); }
.bar__brand { display: flex; align-items: baseline; gap: 0.6rem; color: inherit; text-decoration: none; white-space: nowrap; }
.bar__mark { font-family: var(--serif); font-weight: 600; font-size: 1.2rem; letter-spacing: 0.04em; }
.bar__x { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.12em; color: var(--text-2); }
.bar__nav { display: flex; gap: 0.4rem; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; justify-content: center; height: 32px; padding: 0 0.8rem; background: transparent; border: 1px solid var(--border-lt); color: var(--text-1); font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; text-decoration: none; cursor: pointer; white-space: nowrap; }
.btn:hover { border-color: #BCBCBC; background: #1F1F1F; }
.btn[aria-current="page"] { background: var(--text-1); color: var(--base); }

.sheet { width: 210mm; max-width: 100%; min-height: 297mm; margin: 1.5rem auto; padding: 13mm 14mm 12mm; background: var(--paper); color: var(--ink); }
.sheet + .sheet { margin-top: 1.5rem; }
.sheet h1 { font-family: var(--sans); font-weight: 700; font-size: 1.35rem; letter-spacing: 0.02em; line-height: 1.3; }
.sheet .kicker { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; color: var(--ink-2); margin-bottom: 0.3rem; }
.sheet .lead { font-size: 0.86rem; color: var(--ink-2); margin-top: 0.4rem; max-width: 46em; }
.sheet h2 { font-family: var(--mono); font-weight: 500; font-size: 0.74rem; letter-spacing: 0.14em; color: var(--ink); margin: 1.1rem 0 0.5rem; padding-bottom: 0.25rem; border-bottom: 1px solid var(--ink); }
.sheet h3 { font-size: 0.86rem; font-weight: 700; margin: 0.7rem 0 0.2rem; }
.sheet p, .sheet li { font-size: 0.8rem; line-height: 1.7; }
.sheet ul, .sheet ol { padding-left: 1.3em; }
.sheet li + li { margin-top: 0.15rem; }
.sheet b { font-weight: 700; }
.sheet code { font-family: var(--mono); font-size: 0.76rem; background: var(--tint); padding: 0 0.25em; }
.sheet .mono { font-family: var(--mono); }
.sheet table { width: 100%; border-collapse: collapse; font-size: 0.76rem; margin-top: 0.4rem; }
.sheet th, .sheet td { text-align: left; padding: 0.3rem 0.5rem; border-bottom: 1px solid var(--rule); vertical-align: top; }
.sheet th { font-family: var(--mono); font-weight: 500; font-size: 0.7rem; letter-spacing: 0.08em; color: var(--ink-2); border-bottom: 1px solid var(--ink); }
.sheet .note { font-size: 0.74rem; color: var(--ink-2); margin-top: 0.4rem; }
.sheet .foot { margin-top: 1.1rem; padding-top: 0.5rem; border-top: 1px solid var(--rule); font-size: 0.7rem; color: var(--ink-2); display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.cols2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 9mm; }
.cols3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0 7mm; }
.box { border: 1px solid var(--ink); padding: 0.55rem 0.7rem; margin-top: 0.5rem; }
.box--tint { background: var(--tint); border-color: var(--rule); }
figure { margin-top: 0.4rem; }
figure svg { display: block; width: 100%; height: auto; }
figcaption { font-size: 0.72rem; color: var(--ink-2); margin-top: 0.25rem; line-height: 1.55; }

/* 圖例列 */
.lg { display: grid; grid-template-columns: 22mm 1fr; align-items: center; gap: 0 3mm; min-height: 6.4mm; }
.lg svg, .lg canvas { display: block; width: 22mm; height: 5.6mm; }
.lg span { font-size: 0.76rem; line-height: 1.35; }
.lg small { color: var(--ink-2); font-size: 0.7rem; }

@media (max-width: 720px) {
  .sheet { padding: 1.2rem 1rem; margin: 0; min-height: 0; }
  .cols2, .cols3 { grid-template-columns: 1fr; }
  .bar { height: auto; padding: 0.6rem 0.8rem; flex-wrap: wrap; }
}
@page { size: A4; margin: 0; }
@media print {
  body { background: #fff; }
  .bar { display: none; }
  .sheet { margin: 0; width: 210mm; min-height: 0; height: 297mm; overflow: hidden; break-after: page; }
  .sheet:last-of-type { break-after: auto; }
  a { color: inherit; text-decoration: none; }
}
.sheet h2.mt0 { margin-top: 0; }
