/* 新生落地指北（src/views/landingGuide.js；quick 261122-ntr 首版，261122-q2d 改成「手册」版式）。
   版式：封面（标题 + 先记住这几个数）→ 左目录右正文、十章全部摊开 → 行李三栏 → 评论区。
   语言是一本印得好的说明书：细线分层、不加底色块、不加阴影；颜色只给「当前位置」和「重点数字」，
   用本校的 --brand-bright（藏青 / 新南黄 / …各校自己的），十个分类不再各配一种颜色。
   入口横幅和标识沿用「决战烂课之巅」的 .wt-*，两场活动看得出是一家的。 */

/* 入口横幅：底色沿用 .wt-entry 那层淡淡的本校主题色；「新生季」小标用本校主题色（烂课之巅那颗是红的），
   字色走 --button-ink —— 新南的主题色是黄的，白字压上去读不出来。 */
.lg-entry-tag {
  background: var(--button-bg, var(--brand));
  color: var(--button-ink, #ffffff);
}

.lg-page {
  --lg-accent: var(--brand-bright, var(--brand));
  --lg-serif: "Songti SC", "Source Han Serif SC", "Noto Serif SC", "SimSun", Georgia, serif;
  --lg-sticky-top: calc(var(--topbar-height, 68px) + 14px);
  display: grid;
  gap: 16px;
  max-width: 1180px;
  margin: 0 auto;
  color: var(--text);
}

/* ── 封面 ─────────────────────────────────────────────────── */
.lg-hero {
  display: grid;
  gap: 22px;
  padding: 20px 28px 0;
  overflow: hidden;
}

.lg-hero-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.lg-edition {
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

.lg-hero-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 28px;
}

.lg-hero-copy {
  display: grid;
  justify-items: start;
  gap: 12px;
}

.lg-title {
  margin: 0;
  font-family: var(--lg-serif);
  font-size: 52px;
  font-weight: 800;
  line-height: 1.04;
  letter-spacing: -0.015em;
}

.lg-title em {
  font-style: normal;
  color: var(--lg-accent);
}

.lg-lede {
  margin: 0;
  max-width: 54ch;
  color: var(--muted);
  font-size: 15px;
  font-weight: 600;
  line-height: 1.7;
}

.lg-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 0;
  margin: 2px 0 0;
  color: var(--muted);
  font-size: 12.5px;
  font-weight: 700;
}

.lg-meta span {
  padding: 0 12px;
  border-left: 1px solid var(--line);
  line-height: 1.2;
}

.lg-meta span:first-child {
  padding-left: 0;
  border-left: 0;
}

.lg-meta b {
  color: var(--text);
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.lg-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.lg-hero-actions .wt-cta,
.lg-hero-actions .wt-ghost {
  min-width: 150px;
}

/* 有封面照片时：左文字、右照片。 */
.lg-hero-main:has(.lg-photo) {
  grid-template-columns: minmax(0, 1fr) minmax(300px, 440px);
  align-items: center;
}

/* ── 照片 ─────────────────────────────────────────────────── */
.lg-photo {
  position: relative;
  min-width: 0;
  margin: 0;
}

.lg-photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 10px;
  background: var(--surface-muted);
}

.lg-photo.is-hero img {
  aspect-ratio: 3 / 2;
  border-radius: 12px;
}

/* 署名压在照片右下角：放在图下面会在章首多占一行，把标题旁边撑出一块空白。 */
.lg-photo figcaption {
  position: absolute;
  right: 6px;
  bottom: 6px;
  max-width: calc(100% - 12px);
  overflow: hidden;
  padding: 2px 7px;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.48);
  color: #ffffff;
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.45;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lg-photo figcaption a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: rgba(255, 255, 255, 0.5);
  text-underline-offset: 2px;
}

.lg-ch-head.has-photo {
  grid-template-columns: minmax(0, 1fr) 260px;
  align-items: start;
  column-gap: 28px;
}

.lg-ch-headtext {
  display: grid;
  align-content: start;
  gap: 6px;
  min-width: 0;
}

@container (max-width: 640px) {
  .lg-ch-head.has-photo {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 14px;
  }

  .lg-ch-head .lg-photo img {
    aspect-ratio: 2 / 1;
  }
}

/* 「先记住这几个数」：封面底部一条规格表。 */
.lg-figures-wrap {
  display: grid;
  gap: 12px;
  margin: 0 -28px;
  padding: 16px 28px 20px;
  border-top: 1px solid var(--line);
  background: var(--surface-muted);
}

.lg-figures-label,
.lg-toc-label,
.lg-sources-label {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.lg-figures {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px 0;
  margin: 0;
}

.lg-fig {
  display: grid;
  align-content: start;
  gap: 6px;
  min-width: 0;
  padding: 0 18px;
  border-left: 1px solid var(--line);
}

.lg-fig:first-child {
  padding-left: 0;
  border-left: 0;
}

.lg-fig dt {
  display: flex;
  align-items: baseline;
  gap: 3px;
  font-size: 30px;
  font-weight: 850;
  line-height: 1.05;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.lg-fig dt small {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

.lg-fig dd {
  display: grid;
  gap: 3px;
  margin: 0;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.45;
}

.lg-fig-src {
  justify-self: start;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--muted) 45%, transparent);
  text-underline-offset: 3px;
}

.lg-fig-src:hover {
  color: var(--text);
}

/* ── 目录 + 正文 ──────────────────────────────────────────── */
.lg-body {
  display: grid;
  grid-template-columns: 208px minmax(0, 1fr);
  align-items: start;
  gap: 22px;
}

.lg-toc {
  position: sticky;
  top: var(--lg-sticky-top);
  display: grid;
  gap: 8px;
  padding-top: 6px;
}

.lg-toc-label {
  padding: 0 10px;
}

.lg-toc ol {
  display: grid;
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lg-toc-item {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 6px;
  width: 100%;
  padding: 7px 10px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 800;
  text-align: left;
  cursor: pointer;
}

.lg-toc-item:hover {
  color: var(--text);
}

.lg-toc-item.is-active {
  background: var(--surface);
  color: var(--text);
  box-shadow: inset 2px 0 0 var(--lg-accent);
}

.lg-toc-n {
  font-size: 11px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  opacity: 0.8;
}

.lg-toc-c {
  font-size: 11px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  opacity: 0.7;
}

.lg-toc-progress {
  display: grid;
  gap: 8px;
  margin-top: 8px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--surface);
  font-size: 12px;
  font-weight: 800;
}

.lg-progress {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

/* 进度条的填充用 currentColor：Dark Reader 只改 color、不解析 currentColor，暗色下不会被压成近黑。 */
.lg-progress-bar {
  position: relative;
  width: 84px;
  height: 5px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--line);
  color: var(--lg-accent);
}

.lg-progress-bar i {
  position: absolute;
  inset: 0 auto 0 0;
  width: calc(var(--p, 0) * 100%);
  border-radius: inherit;
  background: currentColor;
  transition: width 0.25s ease;
}

.lg-progress.is-toc .lg-progress-bar {
  flex: 1 1 auto;
  width: auto;
}

.lg-progress.is-toc {
  display: flex;
}

.lg-progress-n {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.lg-chapters {
  display: grid;
  gap: 16px;
  min-width: 0;
  container-type: inline-size;
}

/* ── 一章 ─────────────────────────────────────────────────── */
.lg-ch {
  display: grid;
  gap: 18px;
  padding: 24px 28px;
  scroll-margin-top: var(--lg-sticky-top);
}

.lg-ch-head {
  display: grid;
  gap: 6px;
}

.lg-ch-num {
  /* 章号用正文色：新南的强调色是黄的，11px 的黄字压白底读不出来。颜色留给圆点和进度。 */
  color: var(--text);
  font-size: 11.5px;
  font-weight: 900;
  letter-spacing: 0.08em;
  font-variant-numeric: tabular-nums;
}

.lg-ch-num i {
  margin: 0 3px;
  color: var(--muted);
  font-style: normal;
  font-weight: 700;
}

.lg-ch-titlerow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.lg-ch-head h2 {
  margin: 0;
  font-family: var(--lg-serif);
  font-size: 27px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

/* 一句话结论：每章最该记住的那句。 */
.lg-ch-tldr {
  margin: 2px 0 0;
  max-width: 66ch;
  color: var(--text);
  font-size: 14.5px;
  font-weight: 650;
  line-height: 1.7;
}

.lg-items {
  margin: 0;
  padding: 0;
  list-style: none;
}

.lg-items > li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  padding: 14px 0 15px;
  border-top: 1px solid var(--line);
  break-inside: avoid;
}

/* 正文够宽就排两栏，按列往下读（编号就是阅读顺序）。 */
@container (min-width: 720px) {
  .lg-items {
    column-count: 2;
    column-gap: 40px;
  }
}

.lg-i-n {
  padding-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.lg-i-text {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.lg-i-text h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 850;
  line-height: 1.5;
}

.lg-i-detail {
  margin: 0;
  color: var(--muted);
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.72;
}

/* 出处上标：小方块里一个数字，点了去官方页。 */
.lg-refs-inline {
  display: inline-flex;
  gap: 2px;
  margin-left: 4px;
  line-height: 0;
  vertical-align: 2px;
}

.lg-ref {
  display: inline-grid;
  place-items: center;
  min-width: 16px;
  height: 16px;
  padding: 0 3px;
  border-radius: 4px;
  background: var(--surface-muted);
  color: var(--muted);
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  text-decoration: none;
}

.lg-ref:hover {
  background: var(--lg-accent);
  color: var(--button-ink, #ffffff);
}

.lg-vol {
  display: inline-block;
  margin-left: 6px;
  padding: 0 6px;
  border: 1px dashed var(--soft, #ccd5e6);
  border-radius: 999px;
  color: var(--muted);
  font-size: 10.5px;
  font-weight: 800;
  line-height: 16px;
  vertical-align: 2px;
  white-space: nowrap;
}

/* 章末来源：编号对应正文里的上标。 */
.lg-sources {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: baseline;
  gap: 8px 14px;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
}

.lg-sources ol {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 6px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: lg-src;
}

.lg-sources li {
  display: grid;
  grid-template-columns: 16px minmax(0, 1fr);
  align-items: baseline;
  min-width: 0;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.45;
  counter-increment: lg-src;
}

.lg-sources li::before {
  content: counter(lg-src);
  min-width: 14px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.lg-sources a {
  /* 正文色 + 下划线，不用学校色：新南的 --brand-bright 是黄的，压在白底上读不出来。 */
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--text) 28%, transparent);
  text-underline-offset: 3px;
}

.lg-sources a:hover {
  text-decoration-color: currentColor;
}

.lg-src-host {
  color: var(--muted);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
}

/* 中文长段落别留一个字孤零零地掉到下一行。 */
.lg-ch-tldr,
.lg-i-detail,
.lg-lede,
.lg-i-text h3 {
  text-wrap: pretty;
}

/* ── 第一章：落地 72 小时（三段时间轴 + 可勾选） ──────────────── */
.lg-phases {
  display: grid;
  gap: 0;
}

.lg-phase {
  position: relative;
  display: grid;
  align-content: start;
  gap: 4px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

/* 时间轴上的节点。currentColor 同进度条，暗色下保持本校亮色。 */
.lg-phase::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  color: var(--lg-accent);
  background: currentColor;
}

.lg-phase-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0 0 2px;
  font-size: 13px;
  font-weight: 900;
}

.lg-phase-head em {
  color: var(--muted);
  font-size: 11.5px;
  font-style: normal;
  font-weight: 700;
}

@container (min-width: 760px) {
  .lg-phases {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    column-gap: 26px;
  }
}

@container (max-width: 759px) {
  .lg-phase + .lg-phase {
    margin-top: 12px;
  }
}

.lg-checks {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lg-checks > li {
  padding-bottom: 2px;
}

.lg-check {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 10px;
  width: 100%;
  padding: 9px 0;
  border: 0;
  background: transparent;
  color: var(--text);
  font-family: inherit;
  text-align: left;
  cursor: pointer;
}

.lg-check strong {
  font-size: 14px;
  font-weight: 850;
  line-height: 1.5;
}

.lg-check .lg-i-detail {
  font-size: 12.5px;
  line-height: 1.65;
}

.lg-box {
  position: relative;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border: 1.5px solid color-mix(in srgb, var(--lg-accent) 60%, var(--text));
  border-radius: 5px;
  /* 勾的底色用 currentColor —— 理由同进度条（见 dark-mode-mechanics）。 */
  color: var(--lg-accent);
}

.lg-check.is-done .lg-box {
  background: currentColor;
  border-color: currentColor;
}

.lg-check.is-done .lg-box::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 4px;
  height: 9px;
  border: solid var(--button-ink, #ffffff);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.lg-check.is-done strong {
  color: var(--muted);
  text-decoration: line-through;
  text-decoration-thickness: 1px;
}

.lg-check:hover strong {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.lg-check.is-done:hover strong {
  text-decoration: line-through;
}

.lg-check-refs {
  display: flex;
  align-items: center;
  margin: -6px 0 6px 32px;
}

.lg-check-refs .lg-refs-inline {
  margin-left: 0;
}

.lg-ch-note {
  margin: -6px 0 0;
  color: var(--muted);
  font-size: 11.5px;
  font-weight: 700;
}

/* ── 行李：三栏 ─────────────────────────────────────────────── */
.lg-list-grid {
  display: grid;
  gap: 18px;
}

@container (min-width: 720px) {
  .lg-list-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
  }

  .lg-list {
    padding: 0 20px;
    border-left: 1px solid var(--line);
  }

  .lg-list:first-child {
    padding-left: 0;
    border-left: 0;
  }

  .lg-list:last-child {
    padding-right: 0;
  }
}

.lg-list {
  --lg-c: #e0567a;
  display: grid;
  align-content: start;
  gap: 10px;
  min-width: 0;
}

.lg-list.is-over {
  --lg-c: #2f8fd8;
}

.lg-list.is-ban {
  --lg-c: #d98a1c;
}

.lg-list-head {
  display: grid;
  gap: 3px;
}

.lg-list-head strong {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 900;
}

.lg-list-head strong::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--lg-c);
}

.lg-list-head span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.lg-list ul {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
}

.lg-list li {
  display: grid;
  gap: 2px;
  padding: 9px 0;
  border-top: 1px solid var(--line);
  font-size: 13.5px;
  line-height: 1.45;
}

.lg-list li strong {
  font-weight: 850;
}

.lg-list li em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 600;
}

/* ── 评论区 ───────────────────────────────────────────────── */
.lg-thread {
  display: grid;
  gap: 14px;
  padding: 24px 28px;
  scroll-margin-top: var(--lg-sticky-top);
}

.lg-thread-empty {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

.lg-create-topic {
  justify-self: start;
}

.lg-comment-form {
  border-color: var(--line);
}

.lg-kind-row,
.lg-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

/* 评论类别胶囊、筛选胶囊、评论里的类别小标：三处同一套「圆点说颜色、字永远是 --text」。 */
.lg-kind-pick,
.lg-filter,
.lg-kind {
  --lg-c: #8a93a6;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid color-mix(in srgb, var(--lg-c) 55%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--lg-c) 10%, transparent);
  color: var(--text);
  font-family: inherit;
  font-weight: 900;
}

.lg-kind-pick,
.lg-filter {
  min-height: 30px;
  padding: 0 12px;
  font-size: 12px;
  cursor: pointer;
}

/* .comment-form button 在 app.css 里是右对齐、最小 110 宽的提交键；这几颗胶囊不是。 */
.comment-form .lg-kind-pick,
.comment-form .lg-open-post {
  justify-self: auto;
  min-width: 0;
}

.lg-kind-pick::before,
.lg-filter::before,
.lg-kind::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--lg-c);
}

.lg-kind-pick.is-regret,
.lg-filter[data-filter="regret"],
.lg-kind.is-regret {
  --lg-c: #e0567a;
}

.lg-kind-pick.is-advice,
.lg-filter[data-filter="advice"],
.lg-kind.is-advice {
  --lg-c: var(--brand-bright, var(--brand));
}

.lg-filter[data-filter="all"] {
  --lg-c: #8a93a6;
}

.lg-kind-pick.is-active,
.lg-filter.is-active {
  border-color: var(--lg-c);
  background: color-mix(in srgb, var(--lg-c) 22%, transparent);
  box-shadow: inset 0 0 0 1px var(--lg-c);
}

.lg-filter small {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.lg-kind {
  margin-right: 6px;
  padding: 0 8px;
  font-size: 11px;
  line-height: 20px;
  vertical-align: 1px;
}

.lg-open-post {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.lg-open-post:hover {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.lg-comments {
  display: grid;
  gap: 8px;
}

/* 筛选只藏不重画（landingGuide.js setLandingThreadFilter）。 */
.lg-thread[data-filter="regret"] .lg-c:not([data-kind="regret"]),
.lg-thread[data-filter="advice"] .lg-c:not([data-kind="advice"]) {
  display: none;
}

.lg-filter-empty {
  display: none;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.lg-thread[data-filter="regret"] .lg-comments:not(:has(.lg-c[data-kind="regret"])) + .lg-filter-empty,
.lg-thread[data-filter="advice"] .lg-comments:not(:has(.lg-c[data-kind="advice"])) + .lg-filter-empty {
  display: block;
}

/* ── 版权页 ───────────────────────────────────────────────── */
.lg-colophon {
  display: grid;
  gap: 6px;
  padding: 6px 4px 18px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.7;
}

.lg-colophon strong {
  color: var(--text);
  font-size: 12.5px;
  font-weight: 900;
}

.lg-colophon p {
  margin: 0;
  max-width: 78ch;
}

/* ── 窄屏：目录变成顶部一条横向滚动的章节条 ────────────────────── */
@media (max-width: 1100px) {
  .lg-body {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .lg-toc {
    z-index: 6;
    top: var(--topbar-height, 68px);
    display: block;
    margin: 0 -2px;
    padding: 8px 2px;
    overflow-x: auto;
    background: var(--canvas);
    scrollbar-width: none;
  }

  .lg-toc::-webkit-scrollbar {
    display: none;
  }

  .lg-toc-label,
  .lg-toc-progress {
    display: none;
  }

  .lg-toc ol {
    display: flex;
    gap: 6px;
    width: max-content;
  }

  .lg-toc-item {
    display: inline-flex;
    gap: 6px;
    width: auto;
    padding: 6px 12px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    white-space: nowrap;
  }

  .lg-toc-item.is-active {
    border-color: var(--lg-accent);
    box-shadow: inset 0 0 0 1px var(--lg-accent);
  }

  .lg-ch,
  .lg-thread {
    scroll-margin-top: calc(var(--topbar-height, 68px) + 56px);
  }
}

@media (max-width: 720px) {
  .lg-hero {
    gap: 18px;
    padding: 16px 16px 0;
  }

  .lg-hero-main {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .lg-hero-actions {
    min-width: 0;
  }

  .lg-title {
    font-size: 38px;
  }

  .lg-lede {
    font-size: 14px;
  }

  .lg-figures-wrap {
    margin: 0 -16px;
    padding: 14px 16px 16px;
  }

  .lg-figures {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
  }

  .lg-fig,
  .lg-fig:first-child {
    padding: 12px 12px 12px 0;
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .lg-fig:nth-child(-n + 2) {
    border-top: 0;
    padding-top: 0;
  }

  .lg-fig:nth-child(even) {
    padding-left: 14px;
    border-left: 1px solid var(--line);
  }

  .lg-fig dt {
    font-size: 26px;
  }

  .lg-ch,
  .lg-thread {
    gap: 14px;
    padding: 18px 16px;
  }

  .lg-ch-head h2 {
    font-size: 23px;
  }

  .lg-ch-tldr {
    font-size: 14px;
  }

  .lg-ch-titlerow {
    flex-wrap: wrap;
  }

  .lg-sources {
    grid-template-columns: minmax(0, 1fr);
  }

  .lg-sources ol {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* 封面照片：窄了放到标题上面，压成宽幅。:has() 那条的特异度比单类名高，这里同样写法才盖得住。 */
@media (max-width: 960px) {
  .lg-hero-main:has(.lg-photo) {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .lg-hero-main .lg-photo.is-hero {
    order: -1;
  }

  .lg-photo.is-hero img {
    aspect-ratio: 16 / 9;
  }
}
