@font-face {
  font-family: "Barlow Condensed";
  src: url("assets/fonts/barlow-condensed-700.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "Barlow Condensed";
  src: url("assets/fonts/barlow-condensed-800-italic.woff2") format("woff2");
  font-style: italic;
  font-weight: 800;
  font-display: swap;
}
:root {
  color-scheme: dark;
  --paper: #100d14;
  --panel: #19151e;
  --raised: #221a25;
  --ink: #f9eee8;
  --muted: #c4b7bf;
  --line: #42333f;
  --red: #ff7885;
  --cta: #a9273a;
  --gold: #efbf8c;
  --green: #aae0bd;
  --sans: "Segoe UI", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --display: "Barlow Condensed", "Arial Narrow", "PingFang SC", "Microsoft YaHei", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 1rem; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.65 var(--sans); }
a { color: inherit; text-underline-offset: .23em; }
button, select { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
h1, h2, h3, h4, p, figure, dl, dd { margin: 0; }
img { display: block; width: 100%; height: auto; }
.wrap { width: min(100% - 4rem, 73.5rem); margin-inline: auto; }
.skip { position: fixed; inset: .65rem auto auto .65rem; z-index: 5; padding: .5rem .8rem; transform: translateY(-160%); background: var(--ink); color: var(--paper); }
.skip:focus { transform: none; }

.masthead { background: #0c0910; border-bottom: 1px solid #392530; }
.masthead-inner, .masthead nav, .masthead-links, .footer { display: flex; align-items: center; }
.masthead-inner { min-height: 3.8rem; justify-content: space-between; gap: 1rem; }
.wordmark { text-decoration: none; white-space: nowrap; font: italic 800 1.85rem/.95 var(--display); text-transform: uppercase; letter-spacing: .025em; }
.wordmark span { color: var(--red); }
.masthead nav, .masthead-links { gap: clamp(.85rem, 2vw, 1.85rem); }
.masthead nav a, .masthead-links a, .footer > a:last-child { color: var(--muted); font-size: .9rem; text-decoration: none; }
.masthead a:hover, .footer a:hover { color: var(--ink); }
.language { padding: .25rem .52rem; border: 1px solid var(--line); background: transparent; font-size: .88rem; white-space: nowrap; }
.language:hover { border-color: var(--gold); }

.hero { --hero-height: max(calc(100svh - 3.8rem), 42vw); overflow: hidden; border-bottom: 1px solid var(--line); background: #140d19; }
.hero-stage { position: relative; height: var(--hero-height); overflow: hidden; border-bottom: 1px solid #9a624d; }
.hero-frame { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); width: max(100%, calc(var(--hero-height) * 2.10035)); container-type: inline-size; }
.hero-titleplate { position: absolute; inset: 80% 34.2% 2% 33.3%; display: grid; place-items: center; }
.hero-titleplate::before { content: ""; position: absolute; inset: 0; background: radial-gradient(ellipse at 49% 10%, #352325, #150e13 74%); mask-image: linear-gradient(90deg, transparent, #000 7%, #000 94%, transparent); border-block: 1px solid #95644f63; }
.hero-copy { padding: 1.5rem .25rem 1.55rem; text-align: center; container-type: inline-size; }
.hero h1 { position: relative; font: italic 800 8.3cqw/.85 var(--display); letter-spacing: .025em; text-transform: uppercase; white-space: nowrap; padding: .05em .1em .09em; }
.hero h1 span { color: #ff806f; }
@supports (background-clip: text) {
  .hero h1 {
    background: linear-gradient(180deg, #fff7e8 15%, #ffe3c8 63%, #c88c69 100%);
    background-clip: text;
    color: transparent;
  }
  .hero h1 span {
    background: linear-gradient(180deg, #ffb8a3 17%, #ff7b6c 62%, #e44a60 100%);
    background-clip: text;
    color: transparent;
  }
}
.hero-deck { margin-inline: auto; color: var(--ink); font: 700 clamp(.5rem, 3.25cqi, 1.8rem)/1.25 var(--display); white-space: nowrap; }
main :is(h2, h3, h4, .hero-deck strong, .criteria dt, .scoring-example figcaption strong, .reasoning-panel dt, .frame-clues dt, .case-explanation dt)::before {
  content: "";
  display: inline-block;
  width: min(.9em, 2.65rem);
  height: min(.9em, 2.65rem);
  margin-inline-end: .32em;
  vertical-align: -.08em;
  background: url("assets/mascot/guide.webp") center / contain no-repeat;
}
.paper-authors, .paper-affiliations { display: flex; flex-wrap: wrap; justify-content: center; align-items: baseline; gap: .2rem 1.25rem; }
.paper-authors { margin-top: 1rem; font-weight: 650; }
.paper-authors > span { white-space: nowrap; }
.paper-authors a { text-decoration-color: var(--line); }
.paper-authors a:hover { text-decoration-color: var(--gold); }
.paper-authors sup, .paper-affiliations sup, .author-note sup { color: var(--gold); }
.paper-affiliations, .author-note { margin-top: .35rem; color: var(--muted); font-size: .9rem; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: .48rem; margin-top: .95rem; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 2.55rem; padding: .55rem .9rem; border: 1px solid transparent; border-radius: .14rem; font-size: .9rem; font-weight: 680; line-height: 1.25; text-decoration: none; }
.primary { background: var(--cta); border-color: #d1505e; color: #fff5ef; }
.primary:hover { background: #c13a50; }
.secondary { background: #1b131d; border-color: var(--line); }
.secondary:hover { border-color: var(--gold); }
.counts { display: grid; grid-template-columns: .8fr .9fr 1.15fr 1.45fr; border-top: 1px solid #664956; }
.counts > div { display: flex; align-items: baseline; flex-direction: row-reverse; justify-content: center; gap: .58rem; min-width: 0; padding: .78rem .65rem; border-left: 1px solid #533a49; }
.counts > div:first-child { border-left: 0; }
.counts dd { color: var(--gold); font: 700 clamp(1.85rem, 3.8vw, 2.85rem)/.95 var(--display); font-variant-numeric: tabular-nums; white-space: nowrap; }
.counts dt { color: var(--muted); font-size: .9rem; line-height: 1.35; }

.leaderboard, .playtest, .research, .release { padding-block: clamp(2.5rem, 6vw, 4.8rem); }
.section-heading { display: grid; gap: .45rem; margin-bottom: 1.35rem; }
.section-heading h2 { font: 700 clamp(2.4rem, 5.9vw, 4.6rem)/.98 var(--display); letter-spacing: .008em; text-transform: uppercase; }
.section-heading > p { max-width: 66ch; color: var(--muted); line-height: 1.55; }
[lang="zh-CN"] .section-heading h2 { font-family: var(--sans); font-size: clamp(1.95rem, 4.9vw, 3.25rem); line-height: 1.13; letter-spacing: -.04em; }
.abstract-text { max-width: 80ch; line-height: 1.75; text-align: justify; }
#abstract .figure-link { margin-top: .85rem; }
.citation-heading { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; }
.citation-block { margin: 0; padding: 1rem 1.25rem; border: 1px solid var(--line); background: var(--panel); white-space: pre-wrap; overflow-wrap: anywhere; font-size: .9rem; }
.citation-status:not(:empty) { margin-top: .5rem; color: var(--gold); }
.protocol-layout { display: grid; grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr); align-items: start; gap: clamp(1rem, 4vw, 3.5rem); }
.criteria { border-top: 1px solid var(--line); }
.criteria > div { display: grid; grid-template-columns: minmax(7.4rem, .85fr) minmax(0, 2.15fr); gap: .7rem; padding: .9rem 0; border-bottom: 1px solid var(--line); }
.criteria dt { color: var(--gold); font-weight: 720; line-height: 1.4; }
.criteria dd { color: var(--muted); font-size: .96rem; line-height: 1.55; }
.protocol-scale { margin-top: .75rem; color: var(--muted); font-size: .86rem; }
.protocol-layout .figure-link { margin-top: .85rem; }
.figure-link { display: inline-block; color: var(--gold); font-size: .9rem; }
.figure-link:hover { color: var(--ink); }
.scoring-example { border: 1px solid #604350; background: var(--panel); }
.example-frames { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--line); }
.example-frames a { display: block; background: #100d14; color: var(--gold); text-decoration: none; }
.example-frames a:hover span { text-decoration: underline; }
.example-frames span { display: block; padding: .42rem .55rem; font-size: .8rem; line-height: 1.35; }
.scoring-example img { aspect-ratio: 16 / 9; object-fit: contain; background: #100d14; }
.scoring-example figcaption { padding: .86rem 1rem; border-top: 1px solid var(--line); }
.scoring-example figcaption strong { color: var(--ink); font-size: 1.06rem; }
.scoring-example figcaption p { margin-top: .35rem; color: var(--muted); font-size: .94rem; line-height: 1.55; }
.research + .research, .leaderboard { border-top: 1px solid var(--line); }
.paper-figure > a { display: block; border: 1px solid var(--line); }
.paper-figure > a:hover { border-color: var(--gold); }
.paper-figure figcaption { display: flex; flex-wrap: wrap; align-items: baseline; gap: .4rem 1rem; padding-top: .6rem; color: var(--muted); font-size: .9rem; }

.playtest { border-block: 1px solid var(--line); background: radial-gradient(ellipse at 50% -40%, #331929 0%, #17111b 57%); }
.case-picker { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: .6rem; margin-bottom: 1.15rem; }
.case-option { display: grid; grid-template-rows: auto 1fr; text-align: left; padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: .14rem; background: var(--panel); }
.case-option:hover { border-color: var(--gold); }
.case-option[aria-pressed="true"] { border-color: var(--red); box-shadow: 0 0 0 1px var(--red); }
.case-option img { aspect-ratio: 2 / 3; object-fit: cover; }
.case-option span { display: block; padding: .38rem .48rem .5rem; border-top: 1px solid var(--line); font-size: .88rem; font-weight: 650; line-height: 1.2; }
.case-option[aria-pressed="true"] span { border-top-color: #9e4251; background: #452231; color: #fff1e9; }
.player { min-width: 0; border: 1px solid #59404f; background: #15121b; }
.player-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; padding: clamp(.8rem, 2vw, 1.35rem); border-bottom: 1px solid var(--line); }
.case-game { color: var(--gold); font-size: .87rem; font-weight: 680; }
.case-game-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: .3rem .75rem; }
.case-game-line a { color: var(--muted); font-size: .85rem; }
#case-title { margin-block: .18rem .33rem; font: 700 clamp(1.75rem, 3.3vw, 2.8rem)/1.04 var(--display); }
[lang="zh-CN"] #case-title { font: 700 clamp(1.4rem, 3vw, 2.3rem)/1.17 var(--sans); }
.case-goal, .player-note { color: var(--muted); }
.step-picker { display: flex; flex-shrink: 0; gap: .35rem; }
.step-button { min-width: 2.38rem; min-height: 2.38rem; border: 1px solid var(--line); border-radius: .15rem; background: transparent; font-size: .9rem; }
.step-button:hover, .step-button[aria-pressed="true"] { border-color: var(--gold); }
.step-button[aria-pressed="true"] { background: #382531; color: var(--gold); }
.player-body { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
.case-evidence { min-width: 0; background: #0e0c13; border-right: 1px solid var(--line); }
.game-frame { min-width: 0; padding: clamp(.7rem, 2vw, 1.25rem); }
.frame-image { display: grid; align-items: center; aspect-ratio: 16 / 9; background: #090910; overflow: hidden; }
.frame-image img { width: 100%; height: 100%; object-fit: contain; }
.game-frame figcaption { display: flex; justify-content: space-between; gap: .65rem; padding-top: .55rem; color: var(--muted); font-size: .85rem; }
.frame-actions { display: flex; align-items: baseline; justify-content: flex-end; flex-wrap: wrap; gap: .15rem .7rem; text-align: right; }
.frame-actions .text-button { padding: 0; font-size: inherit; }
.decision { min-width: 0; padding: clamp(.85rem, 2.2vw, 1.35rem); }
.reasoning-panel { margin-bottom: 1.05rem; padding: .65rem .85rem .9rem; background: #211825; border: 1px solid #634351; }
.reasoning-heading { border-bottom: 1px solid #573b49; padding-bottom: .5rem; margin-bottom: .65rem; }
.reasoning-heading h4 { color: var(--ink); font-size: 1.06rem; }
.reasoning-panel .reasoning-heading h4 { margin: 0; }
.reasoning-panel dl, .frame-clues { display: grid; gap: .7rem; }
.frame-clues { padding: .95rem clamp(.7rem, 2vw, 1.25rem) 1.15rem; background: #17121b; border-top: 1px solid var(--line); }
.reasoning-panel dt, .frame-clues dt { color: var(--gold); font-size: .86rem; font-weight: 690; }
.reasoning-panel dd, .frame-clues dd { margin-top: .15rem; color: var(--muted); font-size: .94rem; line-height: 1.53; }
#hint-text { white-space: pre-line; }
.decision h4 { margin-bottom: .48rem; line-height: 1.35; }
.choices { display: grid; gap: .4rem; }
.choice { display: flex; align-items: baseline; gap: .58rem; min-height: 2.48rem; padding: .52rem .66rem; text-align: left; line-height: 1.37; border: 1px solid var(--line); border-radius: .15rem; background: var(--panel); font-size: .94rem; }
.choice[aria-disabled="false"]:hover { border-color: var(--gold); }
.choice[aria-disabled="true"] { cursor: default; }
.choice span:first-child { color: var(--gold); font-size: .82rem; font-weight: 680; }
.choice[data-state="right"] { border-color: #5f997b; background: #173127; color: var(--green); }
.choice[data-state="wrong"] { border-color: #a75764; background: #3b212b; color: #f6a8ae; }
.feedback:not(:empty) { margin-top: .65rem; font-size: .93rem; }
.feedback[data-state="right"] { color: var(--green); }
.feedback[data-state="wrong"] { color: #f6a8ae; }
.case-explanation { margin-top: .58rem; padding: .62rem .75rem; border-left: 2px solid var(--gold); background: var(--raised); }
.case-explanation dt { color: var(--gold); font-size: .87rem; font-weight: 700; }
.case-explanation dd { color: var(--muted); font-size: .93rem; line-height: 1.5; }
.case-explanation dd + dd { margin-top: .42rem; }
.case-explanation dl > div + div { margin-top: .5rem; }
.decision-actions { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .65rem; margin-top: .7rem; }
.text-button { border: 0; padding: .12rem 0; background: transparent; color: var(--gold); text-decoration: underline; text-underline-offset: .23em; font-size: .9rem; }
.text-button:hover { color: var(--ink); }
.player-note { padding: .65rem clamp(.75rem, 2.2vw, 1.35rem); border-top: 1px solid var(--line); font-size: .88rem; }
.player-note a { margin-left: .42rem; }

.rank-panel { border: 1px solid var(--line); background: var(--panel); }
.rank-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .7rem; padding: .7rem .85rem; border-bottom: 1px solid var(--line); }
.rank-views { display: flex; gap: .3rem; }
.rank-views button { padding: .35rem .55rem; border: 1px solid var(--line); border-radius: .15rem; background: var(--paper); font-size: .88rem; }
.rank-views [aria-pressed="true"] { color: var(--ink); background: #572633; border-color: var(--red); }
.rank-views button:hover { border-color: var(--gold); }
.rank-scroll { max-height: 31rem; overflow: auto; }
.rank-table { width: 100%; border-collapse: separate; border-spacing: 0; text-align: left; font-size: .92rem; font-variant-numeric: tabular-nums; }
.rank-table thead th { position: sticky; top: 0; z-index: 1; background: #261c28; }
.rank-table th, .rank-table td { padding: .54rem .78rem; border-bottom: 1px solid var(--line); white-space: nowrap; }
.rank-table th[scope="row"] { font-weight: 620; }
.rank-table td:nth-child(n+3), .rank-table th:nth-child(n+3) { text-align: right; }
.rank-table th button { padding: 0; border: 0; background: transparent; font-weight: 650; }
.rank-table th button:hover { color: var(--gold); text-decoration: underline; }
.rank-table th[aria-sort="descending"] button::after { content: " ↓"; color: var(--gold); }
.rank-table th[aria-sort="ascending"] button::after { content: " ↑"; color: var(--gold); }
.rank-note { padding: .68rem .85rem; color: var(--muted); font-size: .88rem; }
.rank-note a { color: var(--gold); margin-left: .4rem; }
.release { border-block: 1px solid var(--line); background: #18121b; }
.resource-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.resource-list li { display: flex; justify-content: space-between; gap: .75rem 1rem; padding: .65rem 0; border-bottom: 1px solid var(--line); }
.resource-list li > span:last-child { color: var(--muted); font-size: .88rem; text-align: right; }
.footer { justify-content: space-between; gap: .9rem; min-height: 4.5rem; }

@media (max-aspect-ratio: 4/3) {
  .hero h1 { font-size: min(8.3cqw, 18vw); }
}
@media (max-width: 64rem) {
  .wrap { width: calc(100% - 2.5rem); }
  .case-picker { grid-template-columns: repeat(9, clamp(7rem, 20%, 9rem)); overflow-x: auto; scroll-snap-type: x proximity; padding: 4px 4px .45rem; }
  .case-option { scroll-snap-align: start; }
}
@media (max-width: 48rem) {
  .protocol-layout, .player-body { grid-template-columns: 1fr; }
  .case-evidence { border-right: 0; border-bottom: 1px solid var(--line); }
  .counts > div { flex-direction: column-reverse; align-items: center; text-align: center; gap: .3rem; }
}
@media (max-width: 37rem) {
  .wrap { width: calc(100% - 1.5rem); }
  .masthead-inner { flex-wrap: wrap; gap: .38rem; padding-top: .54rem; }
  .masthead nav { order: 2; width: 100%; gap: .55rem 1rem; flex-wrap: wrap; padding-bottom: .46rem; }
  .masthead nav a, .masthead-links a { font-size: .84rem; }
  .masthead-links { gap: .65rem; }
  .hero { --hero-height: calc(100svh - 4.7rem); }
  .hero-copy { padding-bottom: 1rem; }
  .hero-actions .button { font-size: .82rem; min-height: 2.3rem; padding: .45rem .62rem; }
  .counts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .counts > div:nth-child(odd) { border-left: 0; }
  .counts > div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .counts dt { font-size: .85rem; }
  .criteria > div { grid-template-columns: 1fr; gap: .32rem; padding-block: .66rem; }
  .case-picker { grid-template-columns: repeat(9, minmax(5.3rem, 28%)); gap: .45rem; }
  .case-option span { font-size: .78rem; }
  .player-head { align-items: start; flex-direction: column; gap: .65rem; }
}
