:root {
  --ink: #14170f;
  --ink-2: #1c2116;
  --panel: #252b1d;
  --line: #4a533c;
  --paper: #e8dfcc;
  --paper-dim: #c6bca7;
  --brass: #c4893a;
  --brass-2: #e0b060;
  --signal: #d5e39a;
  --danger: #c46a45;
  --font-sans: "Inter", ui-sans-serif, system-ui, sans-serif;
  --font-serif: "Newsreader", Georgia, "Times New Roman", serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --max: 68rem;
  --gutter: 1.25rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { color-scheme: dark; }
html, body {
  margin: 0;
  padding: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
button, input, textarea { font: inherit; color: inherit; }
a { color: var(--brass-2); text-underline-offset: 0.18em; }
a:hover { color: var(--signal); }
:focus-visible { outline: 2px solid var(--brass-2); outline-offset: 3px; }

.skip {
  position: absolute;
  left: -999px;
  top: 0;
}
.skip:focus {
  left: var(--gutter);
  top: 0.5rem;
  z-index: 20;
  background: var(--ink-2);
  color: var(--paper);
  padding: 0.4rem 0.7rem;
}

.mast {
  border-bottom: 1px solid var(--line);
  background: var(--ink-2);
}
.mast-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.85rem var(--gutter);
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}
.brand {
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--paper);
  font-size: 0.92rem;
}
.brand:hover { color: var(--brass-2); }
.mast-kicker {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--paper-dim);
}

#main {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.25rem var(--gutter) 4rem;
}

.eyebrow {
  margin: 0 0 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brass);
}
h1 {
  margin: 0 0 1rem;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--paper);
}
h2 {
  margin: 2.6rem 0 0.85rem;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: clamp(1.4rem, 2.4vw, 1.7rem);
  letter-spacing: -0.02em;
  line-height: 1.2;
  text-wrap: balance;
}
h3 {
  margin: 1.7rem 0 0.5rem;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: -0.01em;
}
.dossier p, .legal-body p {
  margin: 0 0 1rem;
  max-width: 66ch;
  color: var(--paper);
  text-wrap: pretty;
}
.dossier p:first-of-type { font-size: 1.2rem; }

.stage {
  position: relative;
  width: 100%;
  height: min(70svh, 36rem);
  min-height: 24rem;
  background: var(--ink-2);
  border: 1px solid var(--line);
  overflow: hidden;
}
.stage iframe,
.cover,
.loader {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.stage iframe { border: 0; background: var(--ink); }

/* 引擎用 hidden 切换封面 / 加载层 / iframe，样式不能把 hidden 盖掉 */
.cover[hidden],
.loader[hidden],
.stage iframe[hidden] { display: none !important; }

.cover { display: grid; }
.cover-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cover-shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20,23,15,0.15) 20%, rgba(20,23,15,0.78) 100%);
}
.cover-copy {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1.4rem 1.2rem 1.6rem;
  text-align: center;
}
.cover-kicker {
  margin: 0 0 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brass-2);
}
.cover-line {
  margin: 0 0 1rem;
  font-size: clamp(1.15rem, 3vw, 1.6rem);
  line-height: 1.25;
}

.play {
  appearance: none;
  border: 0;
  cursor: pointer;
  background: var(--brass);
  color: var(--ink);
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.85rem 1.5rem;
  min-height: 3rem;
  min-width: 12rem;
}
.play:hover { background: var(--brass-2); }
.play-small { min-width: 0; font-size: 0.9rem; padding: 0.6rem 1rem; min-height: 2.6rem; }

.loader {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  background: var(--ink-2);
}
.radar {
  position: relative;
  width: 8.5rem;
  height: 8.5rem;
}
.ring {
  position: absolute;
  inset: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
}
.ring-a { inset: 18%; }
.ring-b { inset: 36%; }
.ring-c {
  inset: 0;
  border-color: var(--brass);
  animation: pulse 1.6s ease-out infinite;
}
.sweep {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 50%;
  height: 2px;
  background: linear-gradient(90deg, var(--signal), transparent);
  transform-origin: left center;
  animation: sweep 1.8s linear infinite;
}
.loader-text {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--signal);
}
@keyframes sweep { to { transform: rotate(360deg); } }
@keyframes pulse {
  0% { transform: scale(0.86); opacity: 1; }
  100% { transform: scale(1.08); opacity: 0.15; }
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0.85rem 0 0;
  align-items: center;
}
.chip {
  appearance: none;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.6rem 0.85rem;
  min-height: 2.75rem;
  cursor: pointer;
  transition: border-color 160ms ease, color 160ms ease, background-color 160ms ease;
}
.chip:hover { border-color: var(--brass); color: var(--brass-2); }
.chip[data-gf-like] { border-color: var(--brass); color: var(--brass-2); }
.chip[data-gf-like]:hover { background: #2a2316; }
.chip[data-gf-liked],
.chip[aria-pressed="true"] {
  border-color: var(--brass);
  background: #2a2316;
  color: var(--brass-2);
}
.share-msg { margin: 0; font-family: var(--font-mono); font-size: 0.75rem; color: var(--signal); }

.dossier ul, .legal-body ul, .dossier ol { margin: 0 0 1.1rem; padding-left: 1.2rem; }
.dossier li, .legal-body li { margin: 0 0 0.35rem; }

/* 28 个角色名这类长名单：按名册排成多栏，不再是竖排文字墙 */
.dossier ul:has(> li:nth-child(12)) {
  list-style: none;
  padding: 0.9rem 0 0.7rem;
  margin: 0 0 1.4rem;
  columns: 3;
  column-gap: 1.5rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.dossier ul:has(> li:nth-child(12)) > li {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  color: var(--paper-dim);
  break-inside: avoid;
  padding: 0.16rem 0;
}
.dossier ul:has(> li:nth-child(12)) > li:first-child,
.dossier ul:has(> li:nth-child(12)) > li:nth-child(12) {
  color: var(--brass-2);
}
.shot { margin: 1.6rem 0; border: 1px solid var(--line); }
.shot img { width: 100%; }
.shot figcaption {
  margin: 0;
  padding: 0.55rem 0.8rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--paper-dim);
}

.roster {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0 0 1.4rem;
  padding: 0;
  list-style: none;
}
.roster li {
  margin: 0;
  border: 1px solid var(--line);
  padding: 0.3rem 0.55rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.04em;
}

.class-grid {
  display: grid;
  gap: 0.75rem;
  margin: 0 0 1.4rem;
}
@media (min-width: 700px) {
  .class-grid { grid-template-columns: repeat(2, 1fr); }
}
.class-card {
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 0.9rem 1rem;
}
.class-card h3 { margin: 0 0 0.35rem; color: var(--brass-2); font-size: 1rem; letter-spacing: 0.06em; text-transform: uppercase; font-family: var(--font-mono); }
.class-card p { margin: 0; font-size: 1rem; color: var(--paper-dim); }

.faq-list { margin: 0; }
.faq-item {
  border-top: 1px solid var(--line);
  padding: 1rem 0;
}
.faq-item:last-child { border-bottom: 1px solid var(--line); }
.faq-item dt {
  font-family: var(--font-sans);
  font-weight: 700;
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
}
.faq-item dd { margin: 0; color: var(--paper-dim); }

.talk { margin-top: 2.5rem; }
.talk-lead { color: var(--paper-dim); }
.talk-form {
  display: grid;
  gap: 0.8rem;
  margin: 0 0 1.4rem;
  padding: 1rem;
  border: 1px solid var(--line);
  background: var(--panel);
}
.field { display: grid; gap: 0.3rem; }
.field span {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--paper-dim);
}
.field input,
.field textarea {
  background: var(--ink);
  border: 1px solid var(--line);
  padding: 0.6rem 0.7rem;
  width: 100%;
}
.talk-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
}
.talk-form[data-gf-replying] { border-color: var(--brass); }
.text-btn {
  appearance: none;
  background: none;
  border: 0;
  padding: 0;
  color: var(--brass-2);
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.form-msg { margin: 0; font-size: 0.9rem; color: var(--signal); }

.comments[data-gf-empty]::before {
  content: "No comments yet. What Legend did the quiz give you, and do you agree?";
  display: block;
  color: var(--paper-dim);
  font-style: italic;
  margin-bottom: 0.8rem;
}
.comments[data-gf-off]::before {
  content: "Comments are closed.";
  display: block;
  color: var(--paper-dim);
}
.comment {
  border-top: 1px solid var(--line);
  padding: 0.9rem 0;
}
.comment[data-gf-owner] { background: #2a2316; padding: 0.9rem; }
.comment-head {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 0.8rem;
  align-items: baseline;
  font-family: var(--font-mono);
  font-size: 0.78rem;
}
.comment-head time, .to { color: var(--paper-dim); }
.owner-tag { display: none; color: var(--brass-2); }
.comment[data-gf-owner] .owner-tag { display: inline; }
.comment-reply { margin-left: 1rem; padding-left: 0.8rem; border-left: 2px solid var(--line); }

.colophon {
  border-top: 1px solid var(--line);
  background: var(--ink-2);
  padding: 2rem var(--gutter);
}
.colophon-inner { max-width: var(--max); margin: 0 auto; }
.colophon-brand {
  margin: 0 0 0.6rem;
  font-family: var(--font-sans);
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.colophon-note {
  margin: 0 0 1rem;
  color: var(--paper-dim);
  font-size: 0.95rem;
  max-width: 46rem;
}
.colophon-nav { display: flex; gap: 1rem; margin-bottom: 0.8rem; }
.colophon-copy {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--paper-dim);
}

.legal { padding-top: 0.5rem; }
.legal-body { max-width: 42rem; }

@media (max-width: 639px) {
  html, body { font-size: 1.0625rem; }
  h1 { font-size: clamp(1.5rem, 6.6vw, 1.95rem); }
  .mast-kicker { display: none; }
  .stage { height: min(68svh, 30rem); min-height: 20rem; }
  .cover-copy { padding: 1rem 0.9rem 1.2rem; }
  .loader-text { font-size: 0.72rem; }
  .chip { flex: 1 1 auto; min-height: 2.75rem; }
  .dossier ul:has(> li:nth-child(12)) { columns: 2; column-gap: 1rem; }
}
@media (prefers-reduced-motion: reduce) {
  .sweep, .ring-c { animation: none; }
}


/* 层序修正：封面在上、加载层垫底、iframe 最高。
   默认两者都在 DOM 里，靠层序保证首屏看到的是封面和开始按钮，不是一个空的扫描框。 */
.stage { position: relative; }
.cover { z-index: 2; }
.loader { z-index: 1; }
.stage iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
}


/* 封面改造：封面海报本身就印着标题和职业按钮，所以不再往图上叠第二份文案；
   图片完整显示（手机端不再把两侧的职业标签裁掉），开始按钮单独占一条底栏。 */
.cover {
  display: grid;
  grid-template-rows: 1fr auto;
  background: var(--ink-2);
  overflow: hidden;
}
.cover-image {
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: contain;
  object-position: center;
  background: var(--ink-2);
}
.cover-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  padding: 0.9rem 1.1rem;
  border-top: 1px solid var(--line);
  background: var(--ink-2);
  text-align: left;
  position: relative;
  z-index: 4;
}
.cover-meta {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--paper-dim);
}
/* 点赞 / 分享 / 全屏是辅助动作，降成文字链接，别和开始按钮抢眼 */
.actions { margin-top: 1rem; align-items: baseline; }
.actions .chip {
  border: 0;
  background: none;
  color: var(--paper-dim);
  padding: 0.5rem 0.15rem;
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-underline-offset: 0.3em;
}
.actions .chip:hover {
  color: var(--brass-2);
  text-decoration-color: var(--brass);
}
.actions .chip[data-gf-like] { border: 0; color: var(--brass-2); }
.actions .share-msg {
  flex: 1 0 100%;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--signal);
}
.actions .share-msg:empty { display: none; }
.actions .share-msg[data-state="error"] {
  color: var(--danger);
  overflow-wrap: anywhere;
}
@media (max-width: 639px) {
  .cover-bar { padding: 0.8rem 0.9rem; }
  .cover-bar .play { width: 100%; }
  .stage { height: min(60svh, 26rem); }
}


/* 正文改用无衬线（Inter），Newsreader 只留给导语，避免整页掉回默认衬线感 */
body { font-family: var(--font-sans); }
.dossier p:first-of-type {
  font-family: var(--font-sans);
  font-size: 1.12rem;
  line-height: 1.65;
  color: var(--paper);
}
/* 28 个名字：拉开栏间距与行高，读起来像名册而不是文字墙 */
.dossier ul:has(> li:nth-child(12)) { column-gap: 2rem; }
.dossier ul:has(> li:nth-child(12)) > li {
  line-height: 1.9;
  border-bottom: 1px solid color-mix(in srgb, var(--paper) 9%, transparent);
}
@media (max-width: 639px) {
  .actions { gap: 0.2rem 0.9rem; }
  .actions .chip { font-size: 0.9rem; }
  .cover-bar .play { width: auto; min-width: 62%; margin-inline: auto; }
  .dossier ul:has(> li:nth-child(12)) { column-gap: 1.2rem; }
}



/* ==== 问答区改版：简报式评论表单 + 档案式问答列表 ==== */
.talk { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.talk h2 { margin-top: 0; }
.talk-lead { margin: 0 0 1.3rem; font-size: .95rem; color: var(--paper-dim); }
.talk-lead [data-gf-comment-count] { font-family: var(--font-mono); font-size: .85rem; color: var(--brass-2); }

.talk-form {
  display: grid;
  gap: .95rem;
  margin: 0 0 1.8rem;
  padding: 1.05rem 1.15rem 1.15rem;
  border: 1px solid var(--line);
  border-left: 3px solid var(--brass);
  background: var(--ink-2);
}
.talk-form-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: .25rem .8rem;
  margin: 0;
  padding-bottom: .7rem;
  border-bottom: 1px solid var(--line);
}
.talk-form-kicker { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--brass); }
.talk-form-note { font-family: var(--font-mono); font-size: .7rem; letter-spacing: .04em; color: var(--paper-dim); }

.talk-fields { display: grid; gap: .9rem; }
.field { display: grid; gap: .35rem; }
.field > span { font-family: var(--font-mono); font-size: .68rem; letter-spacing: .12em; text-transform: uppercase; color: var(--paper-dim); }
.field input,
.field textarea {
  width: 100%;
  background: var(--ink);
  border: 1px solid var(--line);
  border-radius: 0;
  padding: .62rem .72rem;
  color: var(--paper);
  font-size: 1rem;
  line-height: 1.55;
  transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}
.field input::placeholder,
.field textarea::placeholder { color: var(--paper-dim); opacity: .8; }
.field input:hover,
.field textarea:hover { border-color: color-mix(in srgb, var(--brass) 45%, var(--line)); }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--brass);
  background: color-mix(in srgb, var(--brass) 6%, var(--ink));
  box-shadow: inset 0 0 0 1px var(--brass);
}
.field textarea { min-height: 8.5rem; resize: vertical; }
.field-name { max-width: 21rem; }

.talk-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .6rem .9rem;
  margin-top: .15rem;
  padding-top: .9rem;
  border-top: 1px solid var(--line);
}
.reply-to { margin: 0; font-family: var(--font-mono); font-size: .72rem; letter-spacing: .03em; color: var(--signal); }
.reply-to:empty { display: none; }
.talk-form:not([data-gf-replying]) [data-gf-reply-cancel] { display: none; }
.talk-form[data-gf-replying] { border-left-color: var(--signal); }

.post-btn {
  appearance: none;
  margin-left: auto;
  cursor: pointer;
  border: 1px solid var(--brass);
  background: transparent;
  color: var(--brass-2);
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .01em;
  padding: 0 1rem;
  min-height: 2.75rem;
  transition: background-color 160ms ease, color 160ms ease, border-color 160ms ease;
}
.post-btn:hover { background: var(--brass); color: var(--ink); border-color: var(--brass-2); }
.post-btn:disabled { opacity: .5; cursor: default; }

.form-msg { margin: 0; font-family: var(--font-mono); font-size: .78rem; letter-spacing: .03em; color: var(--signal); }
.form-msg:empty { display: none; }

.comments[data-gf-empty]::before {
  content: "No comments yet. What Legend did the quiz give you, and do you agree?";
  display: block;
  margin: 0 0 1.2rem;
  padding: .85rem 1rem;
  border: 1px dashed var(--line);
  color: var(--paper-dim);
  font-size: .95rem;
  font-style: normal;
  background: transparent;
}
.comment { border-top: 1px solid var(--line); padding: 1.05rem 0; }
.comment:last-child { border-bottom: 1px solid var(--line); }
.comment-head { gap: .35rem .7rem; align-items: baseline; }
.comment-head strong { font-family: var(--font-sans); font-size: .95rem; font-weight: 600; letter-spacing: 0; }
.comment-head time { font-size: .72rem; letter-spacing: .04em; }
.comment p { margin: .45rem 0 .6rem; max-width: 68ch; font-size: 1rem; }
.comment-reply { margin-left: 0; padding-left: 1rem; border-left: 2px solid var(--line); }
.comment[data-gf-owner] { border-left: 3px solid var(--brass); padding-left: .95rem; background: transparent; }

.faq-list { margin: 0; counter-reset: faq; border-top: 1px solid var(--line); }
.faq-item {
  position: relative;
  counter-increment: faq;
  border-top: 0;
  border-bottom: 1px solid var(--line);
  padding: 1.1rem 0 1.1rem 2.3rem;
}
.faq-item::before {
  content: counter(faq, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1.25rem;
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .06em;
  color: var(--brass);
}
.faq-item dt { font-weight: 600; font-size: 1.02rem; letter-spacing: -0.01em; margin-bottom: .3rem; }
.faq-item dd { color: var(--paper-dim); max-width: 68ch; font-size: 1rem; }

@media (max-width: 699px) { .field-name { max-width: none; } }
@media (max-width: 639px) {
  .talk-form { padding: .9rem .95rem 1rem; }
  .post-btn { width: 100%; margin-left: 0; }
  .faq-item { padding-left: 2rem; }
  .comment-reply { padding-left: .8rem; }
}



/* 手机端把封面底欄的元信息压到一行，别让 no download 掉下去 */
@media (max-width: 639px) {
  .cover-meta { font-size: .63rem; letter-spacing: .04em; }
  .cover-bar { gap: .5rem .6rem; }
  .stage { height: min(56svh, 24rem); }
}



/* 字体系收口：个别段落别掉回衬线，移动端与桌面一致 */
html,
body,
.dossier,
.dossier p,
.dossier li,
.dossier dd,
.dossier dt,
.talk,
.talk p,
.faq-item dt,
.faq-item dd { font-family: var(--font-sans); }
.dossier p,
.dossier li { font-size: 1.02rem; line-height: 1.75; }

/* 28 人名单：分隔线加深、行距拉开，三列不糊在一起 */
.dossier ul:has(> li:nth-child(12)) { gap: 0 1.4rem; }
.dossier ul:has(> li:nth-child(12)) > li {
  line-height: 1.7;
  padding-block: .3rem;
  border-bottom: 1px solid color-mix(in srgb, var(--paper) 20%, transparent);
}

@media (max-width: 639px) {
  .actions { gap: .4rem .55rem; }
  .chip { letter-spacing: .08em; }
}



/* 审稿第二轮的意见：移动端封面底栏字太小、正文行距偏紧、手机开始按钮过宽、宽屏名册留白过多。
   放在文件末尾覆盖前面的同名规则。 */
.dossier p, .legal-body p {
  line-height: 1.72;
  margin-bottom: 1.15rem;
}
.dossier p + p { margin-top: 0; }

@media (max-width: 639px) {
  body { font-size: 1rem; }
  .cover-meta {
    font-size: 0.7rem;
    letter-spacing: 0.12em;
    line-height: 1.5;
  }
  .cover-bar .play {
    width: 100%;
    max-width: 21rem;
    margin-inline: auto;
    font-size: 1rem;
    min-height: 3rem;
  }
  .dossier p:first-of-type {
    font-size: 1.05rem;
    line-height: 1.62;
  }
  .actions { gap: 0.15rem 0.85rem; }
  .actions .chip { font-size: 0.82rem; }
}

@media (min-width: 1080px) {
  .dossier ul:has(> li:nth-child(12)) {
    columns: 4;
    column-gap: 2.4rem;
    max-width: 58rem;
  }
}

.actions .chip:hover { text-decoration-color: var(--brass-2); }



/* 审稿第三轮：手机底栏与动作区的呼吸、正文明确用 Inter、名册加行分隔线。 */
.dossier p, .legal-body p, .faq-item dd, .class-card p {
  font-family: var(--font-sans);
  letter-spacing: 0.005em;
}
.dossier p { line-height: 1.72; }

/* 名册：每行一条极细分隔，扫视时不容易串行 */
.dossier ul:has(> li:nth-child(12)) > li {
  padding: 0.55rem 0;
  border-bottom: 1px solid color-mix(in srgb, var(--paper) 14%, transparent);
}
.dossier ul:has(> li:nth-child(12)) > li:last-child { border-bottom: 0; }

@media (max-width: 639px) {
  .cover-bar { gap: 1rem; }
  .cover-meta {
    flex: 1 0 100%;
    text-align: center;
    margin-bottom: 0.15rem;
  }
  .actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 0.5rem;
    margin-top: 1.15rem;
  }
  .actions .chip {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    padding: 0.5rem 0.7rem;
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    text-decoration: none;
    min-height: 2.5rem;
  }
  .actions .chip:hover { border-color: var(--brass); }
  .actions .share-msg { flex: 1 0 100%; }
}



/* 名册分隔线和手机底栏元信息的最后一轮微调（审稿第三轮）。 */
.dossier ul:has(> li:nth-child(12)) > li {
  border-bottom-color: color-mix(in srgb, var(--paper) 26%, transparent);
  padding: 0.6rem 0;
}
.dossier ul:has(> li:nth-child(12)) > li > * { overflow-wrap: anywhere; }

@media (max-width: 639px) {
  .cover-meta {
    font-size: 0.68rem;
    letter-spacing: 0.08em;
    white-space: nowrap;
    text-align: center;
  }
  .cover-bar .play { min-height: 3.25rem; }
  .actions .chip { font-size: 0.7rem; padding: 0.45rem 0.6rem; }
}



/* Playing: make the stage tall enough that the quiz fits without scrolling
   the iframe (MainFinder calls window.scrollTo after each answer). Size the
   iframe to the stage exactly — making it larger was clipping the quiz and
   showing a horizontal scrollbar. */
.stage { overflow: hidden; max-width: 100%; scrollbar-width: none; }
.stage iframe {
  inset: 0 !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none;
  max-height: none;
  border: 0;
}
.stage:has(iframe:not([hidden])) {
  height: clamp(42rem, 86svh, 56rem);
  min-height: 42rem;
}
@media (max-width: 639px) {
  .stage:has(iframe:not([hidden])) {
    height: clamp(36rem, 90svh, 52rem);
    min-height: 36rem;
  }
}
/* Inner scrollbars flash during MainFinder's question wipe/scale;
   they sit on .quiz-panel-slot and cannot be styled from here, so cover
   the tracks. pointer-events none keeps clicks on answers and Back. */
.stage:has(iframe:not([hidden]))::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  box-shadow: inset -18px 0 0 0 #07080a, inset 0 -18px 0 0 #07080a;
}

/* the page's own scrollbars, dark and thin */
html {
  scrollbar-color: #4a533c #14170f;
  scrollbar-width: thin;
}
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: #14170f; }
::-webkit-scrollbar-thumb { background: #3d4632; border-radius: 999px; }
::-webkit-scrollbar-thumb:hover { background: #4a533c; }
body { overflow-x: hidden; }

/* share row: feedback has to be visible, not hidden behind an attribute */
.actions { flex-wrap: wrap; }
.actions .share-msg {
  flex-basis: 100%;
  margin: 0.55rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--paper-dim);
  overflow-wrap: anywhere;
}
.actions .share-msg[data-state="ok"] { color: var(--signal); }
.actions .share-msg[data-state="error"] { color: var(--danger); }


/* ---------- main navigation ---------- */
.mast-inner { flex-wrap: wrap; row-gap: 0.4rem; }
.mast-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.15rem;
  font-family: var(--font-sans);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.mast-nav a {
  color: var(--paper-dim);
  text-decoration: none;
  padding: 0.1rem 0;
  border-bottom: 1px solid transparent;
  transition: color 150ms ease, border-color 150ms ease;
}
.mast-nav a:hover { color: var(--paper); border-bottom-color: var(--brass); }

/* ---------- content pages ---------- */
.doc {
  max-width: var(--max);
  margin: 0 auto;
  padding: 3.25rem var(--gutter) 4rem;
}
.doc > * { max-width: 42rem; }
.doc > .tbl-wrap, .doc > figure, .doc > table, .doc > .related { max-width: 100%; }
.doc .eyebrow { margin-bottom: 0.5rem; }
.doc h1 {
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  text-wrap: balance;
  margin: 0 0 1rem;
}
.doc-lead {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--paper-dim);
  margin: 0 0 2.25rem;
  text-wrap: pretty;
}
.doc h2 {
  font-family: var(--font-sans);
  font-size: 1.22rem;
  line-height: 1.3;
  letter-spacing: -0.005em;
  margin: 2.75rem 0 0.7rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgb(74 83 60 / 0.5);
}
.doc h2:first-of-type { border-top: none; padding-top: 0; }
.doc h3 { font-family: var(--font-sans); font-size: 1.02rem; margin: 1.9rem 0 0.5rem; }
.doc p { text-wrap: pretty; margin: 0 0 1.05rem; }
.doc ul, .doc ol { margin: 0 0 1.35rem; padding-left: 1.5rem; }
.doc li { margin: 0.55rem 0; line-height: 1.65; }
.doc li::marker { color: var(--brass); }
.doc strong { color: #f2ebdb; font-weight: 600; }
.doc a { color: var(--brass-2); }

/* ---------- tables ---------- */
.tbl-wrap {
  overflow-x: auto;
  margin: 0 0 1.75rem;
  border: 1px solid var(--line);
  background: var(--ink-2);
}
.tbl {
  width: 100%;
  min-width: 30rem;
  border-collapse: collapse;
  font-family: var(--font-sans);
  font-size: 0.9rem;
}
.tbl caption {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brass);
  padding: 0.7rem 0.95rem;
  border-bottom: 1px solid var(--line);
}
.tbl th, .tbl td {
  text-align: left;
  padding: 0.5rem 0.95rem;
  border-bottom: 1px solid rgb(74 83 60 / 0.4);
  vertical-align: top;
}
.tbl thead th {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--paper-dim);
  font-weight: 500;
  white-space: nowrap;
}
.tbl tbody tr:last-child td { border-bottom: none; }
.tbl tbody tr:hover { background: rgb(196 137 58 / 0.07); }
.tbl .tbl-group th {
  background: var(--panel);
  color: var(--brass-2);
  font-size: 0.7rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  padding: 0.35rem 0.95rem;
  font-weight: 600;
}
.tbl td:first-child { color: #f2ebdb; font-weight: 600; }

/* markdown tables in content pages */
.doc table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--font-sans);
  font-size: 0.88rem;
  margin: 0 0 1.75rem;
  border: 1px solid var(--line);
  background: var(--ink-2);
}
.doc table th, .doc table td {
  text-align: left;
  padding: 0.7rem 0.85rem;
  border-bottom: 1px solid rgb(74 83 60 / 0.4);
  vertical-align: top;
  line-height: 1.5;
}
.doc table th {
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--paper-dim);
  font-weight: 500;
}
.doc table tr:last-child td { border-bottom: none; }

/* ---------- related links ---------- */
.related {
  margin-top: 3.25rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
.related h2 {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brass);
  margin: 0 0 0.6rem;
  border: none;
  padding: 0;
}
.related ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.related li {
  display: grid;
  gap: 0.15rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid rgb(74 83 60 / 0.4);
}
.related li:last-child { border-bottom: none; }
.related li a {
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--brass-2);
  text-decoration: none;
}
.related li a:hover { color: var(--signal); text-decoration: underline; }
.related li span { color: var(--paper-dim); font-size: 0.92rem; line-height: 1.5; }

/* ---------- footer ---------- */
.colophon-brand-block p { margin: 0 0 0.35rem; }
.colophon-brand-block p:last-child { margin-bottom: 0; }
.colophon-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.1rem;
  font-family: var(--font-sans);
  font-size: 0.82rem;
}

/* ---------- small screens ---------- */
@media (max-width: 640px) {
  .mast-inner { display: block; }
  .mast-nav {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    white-space: nowrap;
    margin-top: 0.5rem;
    max-width: 100%;
    font-size: 0.72rem;
    gap: 0.95rem;
    padding-bottom: 0.2rem;
    scrollbar-width: none;
  }
  .mast-nav::-webkit-scrollbar { display: none; }
  .doc { padding: 2rem var(--gutter) 3rem; }
  .doc h1 { font-size: 1.5rem; line-height: 1.2; letter-spacing: -0.01em; }
  .doc-lead { font-size: 1rem; line-height: 1.6; margin-bottom: 1.6rem; }
  .doc p { line-height: 1.68; margin-bottom: 0.95rem; }
  .doc h2 { margin-top: 2rem; }
  .doc table { table-layout: fixed; width: 100%; font-size: 0.8rem; }
  .doc table th, .doc table td { padding: 0.5rem 0.45rem; overflow-wrap: anywhere; }
  .tbl { font-size: 0.84rem; min-width: 24rem; }
  .tbl th, .tbl td { padding: 0.45rem 0.6rem; }
}



/* ——— 设计审稿第二轮修正：手机顶栏溢出 / 封面过高挤掉 CTA / 表格行距过密 ——— */

/* 顶栏导航：补齐样式（原来只有文档里没有规则），手机端两行 + 可横向滑，不再截断 BEGINNERS */
.mast-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 0.95rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.mast-nav a { text-decoration: none; color: var(--paper); }
.mast-nav a:hover { color: var(--brass-2); }

@media (max-width: 639px) {
  .mast-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.75rem var(--gutter);
  }
  /* 自动换行而不是横向滑动：7 个链接在手机上分两三行全露出来，没有截断也没有横向溢出 */
  .mast-nav {
    width: 100%;
    max-width: 100%;
    flex-wrap: wrap;
    overflow: visible;
    gap: 0.25rem 0.8rem;
    font-size: 0.74rem;
    letter-spacing: 0.05em;
    line-height: 1.9;
  }
  .mast-nav a { flex: 0 0 auto; white-space: nowrap; }
  body { overflow-x: hidden; }
  .brand { font-size: 0.86rem; }
}

/* 首屏封面矮一截：1440×900 下开始按钮不再被顶到屏幕最底边 */
.stage { height: min(62svh, 30rem); }
@media (max-width: 639px) {
  .stage { height: min(52svh, 22rem); min-height: 17rem; }
}

/* 角色表：加行距和分隔线，字号抬到可读区间，不再是 11px 密密麻麻一片 */
.tbl { border-collapse: collapse; width: 100%; }
.tbl td, .tbl th { padding: 0.55rem 0.6rem; font-size: 0.95rem; line-height: 1.45; }
.tbl tbody tr + tr { border-top: 1px solid color-mix(in srgb, var(--paper) 8%, transparent); }
.tbl tbody td:first-child a { font-weight: 600; }
/* 表头抬字号、加字距，28 行扫读时有清楚的列标题 */
.tbl thead th {
  font-size: 0.8rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--paper-dim);
  border-bottom: 1px solid var(--line);
}
/* 斑马纹：一长串角色名不至于看得眼花 */
.tbl tbody tr:nth-child(even) { background: color-mix(in srgb, var(--paper) 3%, transparent); }
.tbl tbody tr.tbl-group { background: none; }
.tbl-group th {
  padding-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brass-2);
}
.tbl a { color: var(--brass-2); }
.tbl a:hover { color: var(--signal); }
@media (max-width: 639px) {
  .tbl td, .tbl th { padding: 0.5rem 0.45rem; font-size: 0.86rem; }
}

/* 长文段落：手机上给行高和段间距一点呼吸 */
.dossier p { line-height: 1.72; }
@media (max-width: 639px) {
  /* 手机正文：字号降一档、行高放到 1.75，密排长文不再压在屏幕边上 */
  html, body { font-size: 1rem; }
  .dossier p { font-size: 1rem; line-height: 1.75; margin-bottom: 1.15rem; }
  .dossier p:first-of-type { font-size: 1.06rem; line-height: 1.7; }
  h2 { margin-top: 2.1rem; }
}



/* ——— 设计审稿（7.5 分）修正：手机动作区对齐、首页名单表密度、正文行宽与节奏 ——— */

/* 1) 手机端点赞/分享一排：改成等宽三列网格，不再长短不一地散落 */
@media (max-width: 639px) {
  .actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.4rem;
    align-items: stretch;
  }
  .actions .chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 0 0.25rem;
    min-height: 2.4rem;
    font-size: 0.64rem;
    letter-spacing: 0.06em;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  .actions .share-msg { grid-column: 1 / -1; }
  /* 封面高度收一点，让开始按钮回到手机首屏内 */
  .stage { height: min(52svh, 22rem); min-height: 18rem; }
}

/* 2) 名单表：斑马行 + 宽松行距，名字不再是一满屏下划线 */
.tbl th, .tbl td { padding: 0.62rem 0.95rem; }
.tbl tbody tr:nth-child(even):not(.tbl-group) {
  background: color-mix(in srgb, var(--paper) 4%, transparent);
}
.tbl tbody tr:hover { background: color-mix(in srgb, var(--brass) 9%, transparent); }
.tbl td a, .doc table a {
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--brass) 35%, transparent);
  padding-bottom: 1px;
}
.tbl td a:hover, .doc table a:hover {
  color: var(--signal);
  border-bottom-color: var(--signal);
}
@media (min-width: 700px) {
  .tbl th, .tbl td { padding: 0.72rem 0.95rem; }
}

/* 3) 正文：行宽收到 70ch，标题之间的间隙拉开一档 */
.doc p { max-width: 70ch; }
.doc h2 { margin-top: 3.1rem; }
.doc h2:first-of-type { margin-top: 0; }


/* 审稿修正（第二版）：首页正文区实际是 .dossier 容器 + 纯 table，按真实结构覆盖 */
.dossier table {
  width: 100%;
  border-collapse: collapse;
}
.dossier th, .dossier td { padding: 0.62rem 0.9rem; }
@media (min-width: 700px) {
  .dossier th, .dossier td { padding: 0.74rem 1rem; }
}
.dossier tbody tr:nth-child(even) {
  background: color-mix(in srgb, var(--paper) 4%, transparent);
}
.dossier tbody tr:hover {
  background: color-mix(in srgb, var(--brass) 9%, transparent);
}
.dossier table a {
  text-decoration: none;
  border-bottom: 1px solid color-mix(in srgb, var(--brass) 35%, transparent);
  padding-bottom: 1px;
}
.dossier table a:hover {
  color: var(--signal);
  border-bottom-color: var(--signal);
}
.dossier p { max-width: 70ch; }
.dossier h2 { margin-top: 3.1rem; }
.dossier h2:first-of-type { margin-top: 0; }


/* 审稿第三轮修正：手机导航不换行、动作栏可读性、表格首列与大标题对齐 */
@media (max-width: 767px) {
  .mast-inner { gap: 0.6rem; }
  .mast-nav {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.9rem;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 2px;
  }
  .mast-nav::-webkit-scrollbar { display: none; }
  .mast-nav a { flex: 0 0 auto; white-space: nowrap; }
  .hero .eyebrow { margin-bottom: 0.85rem; }
}

@media (min-width: 768px) {
  .actions { gap: 0.55rem; }
  .actions .chip {
    font-size: 0.72rem;
    letter-spacing: 0.07em;
    color: var(--paper);
    padding: 0.5rem 0.85rem;
  }
}

/* 表格首列去掉内缩，和大标题对齐到同一条左线 */
.dossier th:first-child, .dossier td:first-child {
  padding-left: 0;
}
.dossier table { margin-left: 0; }

.home-native-ad {
  width: 100%;
  min-width: 0;
  margin: 2rem 0;
}
.home-native-ad-label {
  margin: 0 0 0.5rem;
  color: var(--paper-dim);
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-align: center;
}
.home-native-ad-slot {
  width: 100%;
  min-width: 0;
  min-height: 100px;
  aspect-ratio: 4 / 1;
}
.home-native-ad-slot > div {
  width: 100%;
  max-width: 100%;
}
