/* Hallmark · theme: Manifesto (by request) · genre: editorial · copy: verbatim · signature: full-colour film posters against a warm-black title spread. */
/* Critique: The original centred opening delays the first large image. The new spread puts the title and poster in view together. */
:root {
  --paper: #f5f1e8;
  --ink: #1d2e28;
  --muted: #495b51;
  --line: #bcc7bc;
  --blue: #275346;
  --lime: #ead7a1;
  --stage: #142521;
  --mat: #e0e7dc;
  --stock: #fdf9f0;
  --shell: clamp(1.1rem, 5vw, 5rem);
  --chapter: clamp(3.4rem, 7vw, 7rem);
  --editorial: "Songti TC", "Noto Serif CJK TC", "PMingLiU", "SimSun", serif;
  --latin: "Iowan Old Style", "Baskerville", Georgia, serif;
}
:root:lang(en) { --editorial: var(--latin); }

body { line-height: 1.65; }
.wrap { width: min(1440px, calc(100% - 2 * var(--shell))); }
.wrap > main { padding-bottom: clamp(1.5rem, 3.5vw, 2.75rem); }

.wrap > .masthead, .intro {
  position: relative;
  background: var(--stage);
  color: var(--paper);
}
.wrap > .masthead {
  z-index: 6;
  min-height: 65px;
  border-color: #587066;
}
.wrap > .masthead::before, .intro {
  box-shadow: 0 0 0 100vmax var(--stage);
  clip-path: inset(0 -100vmax);
}
.wrap > .masthead::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: var(--stage);
}
.brand { font-family: var(--editorial); font-weight: 550; letter-spacing: .07em; }
.masthead nav { align-items: center; }
.masthead nav > a:hover, .masthead .brand:hover { color: var(--lime); }
.masthead :focus-visible { outline-color: var(--lime); }
.locale-options { background: var(--stage); color: var(--paper); border-color: #587066; }
.locale-options a:hover, .locale-options a[aria-current="true"] {
  background: #2a4338;
  color: var(--paper);
}
.locale-options a[aria-current="true"] { box-shadow: inset 2px 0 var(--lime); }

.intro {
  margin: 0 0 var(--chapter);
  text-align: center;
  padding: clamp(2.4rem, 5vw, 4.6rem) 0 clamp(1.8rem, 3.2vw, 3rem);
}
.intro-copy { margin-bottom: clamp(1rem, 3vw, 2.4rem); }
.intro-period {
  color: var(--lime);
  font-weight: 550;
  letter-spacing: .12em;
}
.intro-copy h1 {
  margin-top: .75rem;
  font: 500 clamp(2.4rem, 6.5vw, 6.5rem)/1.15 var(--editorial);
  letter-spacing: .035em;
  text-wrap: balance;
}
.intro-copy h1 span { display: inline; white-space: normal; }
:lang(en) .intro-copy h1 { letter-spacing: -.038em; }
.intro-translation {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: .75rem;
  margin-top: .72rem;
  color: #cfdbd1;
  font: 400 clamp(1.05rem, 2vw, 1.6rem)/1.4 var(--latin);
}
.intro-translation::before, .intro-translation::after {
  content: "";
  width: clamp(1.2rem, 4vw, 3.25rem);
  height: 1px;
  background: #8a805c;
}
.intro-art { background: transparent; padding: 0; }
.intro-frame { --art-height: clamp(16rem, 34vw, 32rem); background: transparent; }
.intro-slide { width: min(56%, 48rem); }
.intro-slide .source-image {
  width: min(94%, calc((var(--art-height) - 1.15rem) * var(--ratio)));
  box-shadow: 0 0 0 1px #f5f1e844, 0 12px 30px #08140c90;
}
.intro-slide[data-position="previous"] { opacity: .58; transform: translateX(-119%) scale(.72); }
.intro-slide[data-position="next"] { opacity: .58; transform: translateX(19%) scale(.72); }
.intro-slide:is([data-position="previous"], [data-position="next"]):hover { opacity: .86; }
.carousel-controls button:hover { color: var(--lime); background: transparent; }
.carousel-dots button::after { border: 1px solid #c1d1c5; background: transparent; }
.carousel-dots button[aria-pressed="true"]::after { background: var(--lime); border-color: var(--lime); }
#intro-art figcaption strong { font: 500 clamp(1.3rem, 2.5vw, 2rem)/1.3 var(--editorial); }
.carousel-hint, .carousel-material, #intro-art figcaption .image-credit { color: #cbd7ce; }

.timeline-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding: 0 0 1.7rem; }
.timeline-heading > div { display: contents; }
.timeline-range { order: 1; font: 400 clamp(1.25rem, 3.6vw, 3.45rem)/1 var(--latin); white-space: nowrap; }
#film-picker h2, .section h2, .feature h2, .exhibit-header h2 {
  font: 500 clamp(1.75rem, 4vw, 3.65rem)/1.16 var(--editorial);
  letter-spacing: 0;
  text-wrap: balance;
}
.timeline-years { scrollbar-color: #728879 transparent; }
.timeline-node button { font: 400 clamp(1.2rem, 1.9vw, 1.75rem)/1 var(--latin); }
.timeline-node button::before { background: #82978b; }
.timeline-node:last-child button::after { border-color: #82978b; }
.timeline-node button[aria-pressed="true"] i { box-shadow: 0 0 0 3px var(--mat); }
.film-rail { border: 0; border-block: 1px solid var(--line); background: var(--stock); }
.film-context { background: var(--stage); }
#film-context-meta { color: #cfdbd1; }
.film-rail-links a { color: var(--muted); font-weight: 580; }

.profile-heading { border-bottom: 1px solid var(--line); padding-block: clamp(2.8rem, 6vw, 5.4rem) 1.65rem; }
.profile-heading h2 { font: 500 clamp(2.6rem, 6.5vw, 5.7rem)/1.04 var(--editorial); letter-spacing: .005em; }
.profile-english { font: 400 clamp(1.15rem, 2.6vw, 2rem)/1.2 var(--latin); }
.profile-meta time { font: 400 clamp(1.75rem, 4.1vw, 3.9rem)/1 var(--latin); }
.profile-cover { grid-template-columns: minmax(0, 1fr) minmax(0, .9fr); gap: clamp(1.3rem, 6vw, 5.8rem); }
.profile-matte { background: var(--stage); }
.profile-matte .source-image { box-shadow: 0 8px 20px #08140c90; }
.profile-summary > p { max-width: 61ch; }
.profile-panels {
  border: 0;
  border-top: 1px solid var(--line);
  background: none;
  gap: clamp(.8rem, 2.8vw, 2.1rem);
}
.profile-panel { background: none; padding: clamp(1.1rem, 2.8vw, 2.2rem) 0; }
.profile-panel + .profile-panel { padding-inline-start: .8rem; border-inline-start: 1px solid var(--line); }
.profile-panel h3, .profile-summary h3, .profile-routes h3, .ticket-prompts h3,
.film-heading h2, .compare-copy h3, .quiz-header h3, .archive-task h3, .archive-supplement h3 {
  font-family: var(--editorial);
  font-weight: 500;
}
.profile-routes { background: var(--mat); color: var(--ink); }
.profile-routes dt { color: var(--blue); }
.profile-routes dd, .profile-routes .profile-reference a { color: var(--ink); }

.ticket-station {
  margin-block: var(--chapter);
  padding-inline: clamp(1rem, 3.2vw, 3rem);
  border: 0;
  background: var(--mat);
}
.ticket-options-list button { background: var(--stock); border-color: #a9b6a8; }
.ticket-stub, .ticket-reading:not(:empty) { background: var(--stock); }
.ticket-stub { border-inline-start-color: #779185; }
.ticket-copy, .ticket-picks div, .ticket-result { background: var(--mat); }
.film-media.section {
  margin-block: var(--chapter);
  padding: clamp(1.05rem, 4vw, 3.25rem);
  background: var(--stage);
  color: var(--paper);
  --line: #52685d;
  --blue: var(--lime);
  --muted: #cbd7ce;
}
.film-media .section-head { padding-top: 0; border: 0; }
#media-heading, .film-media #screen-notes h3 { font-family: var(--editorial); font-weight: 500; color: var(--paper); }
.film-media .section-head p, .film-media .screen-still figcaption, .film-media .media-caption { color: var(--muted); }
.media-feature { background: #20372e; }
.media-player, .media-play { background: #0d1b17; }
.media-resources h3 { border-color: var(--line); }
.film-media .outline { color: var(--paper); border-color: var(--muted); }
.film-media .outline:hover:not(:disabled) { color: var(--ink); background: var(--paper); }
.solid:hover:not(:disabled) { background: #1a3d31; }

.exhibit { border: 0; }
.exhibit-header {
  background: none;
  border: 0;
  border-top: 1px solid var(--line);
  padding: 1.5rem 0 0;
  margin-bottom: 1.35rem;
}
.exhibit-grid { border: 1px solid var(--line); }
.viewer, .viewer-controls, .explorer { background: var(--stock); border-color: var(--line); }
.stage { background: radial-gradient(ellipse at 50% 50%, #304d40, transparent 74%), var(--stage); }
.stage[data-mode="exploded"] { background: var(--mat); }
.layer-buttons { gap: 0; border-top: 1px solid var(--line); }
.layer-button { border-width: 0 0 1px; min-height: 44px; }
.layer-button[aria-pressed="true"] { background: var(--mat); }
.spatial-plane.current-plane::before { border-color: #3463538c; }
.spatial-piece.selected img, .orbit-scene:not(.dragging) .spatial-piece:hover img { filter: drop-shadow(0 0 1.5px #285445bb); }

#compare, #encounter, #film-quiz, #archive { margin-block: var(--chapter); }
.section-head { border-color: var(--line); }
.feature, .pair-stage, .quiz-figure img, .quiz-feedback:not(:empty), .quiz-options button:hover:not(:disabled),
.archive-task { background: var(--mat); }
#compare .compare-card, .pair-extraction, .film-quiz, .archive-options button,
.archive-feedback, .archive-result, .records-grid article { background: var(--stock); }
.film-quiz, .archive-task { border: 0; border-top: 1px solid var(--line); }
.archive-options button, .archive-result { border-color: var(--line); }
.archive-options button[aria-pressed="true"] { border-color: var(--blue); }
.repair-track li { background: var(--blue); }
.repair-track li.repair-junction { color: var(--blue); border-color: #81968a; }

@media (max-width: 900px) {
  .profile-panel + .profile-panel { padding-inline-start: 0; border-inline-start: 0; }
}
@media (max-width: 670px) {
  .profile-cover { grid-template-columns: minmax(0, 1fr); }
  .profile-figure { width: min(100%, 32rem); margin-inline: auto; }
  .profile-matte { min-height: 0; }
  .timeline-heading { align-items: center; }
}
@media (max-width: 540px) {
  .brand { gap: .45rem; letter-spacing: .025em; white-space: normal; }
  .masthead nav { gap: .45rem; flex-wrap: nowrap; }
  .intro-frame { --art-height: clamp(14rem, 65vw, 18.5rem); }
  .intro-slide { width: 86%; }
  .intro-slide[data-position="previous"] { transform: translateX(-113%) scale(.55); }
  .intro-slide[data-position="next"] { transform: translateX(13%) scale(.55); }
  .intro-slide[data-position="current"] .source-image { max-width: 86%; }
}
@media (max-width: 470px) {
  .profile-panel + .profile-panel { border-top: 1px solid var(--line); }
}

/* Programme typography and mounted exhibition surfaces. */
@font-face {
  font-family: "Instrument Serif";
  src: url("fonts/instrument-serif.woff") format("woff");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
:root {
  --latin: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --display: system-ui, "PingFang TC", "Microsoft JhengHei", sans-serif;
  --motion-ease-out: cubic-bezier(.22, .8, .24, 1);
  --chapter: clamp(3.6rem, 8vw, 8.5rem);
}
.wrap > .masthead { border: 0; }
.masthead nav {
  align-self: center;
  gap: .9rem;
  padding-inline: 1rem .28rem;
  border: 1px solid #546d61;
  border-radius: 2rem;
  background: #1d342c;
}
.intro { padding-block-start: clamp(2.3rem, 4.3vw, 4rem); }
:lang(en) .intro-copy h1 {
  font-size: clamp(3.4rem, 8.1vw, 8.4rem);
  line-height: .93;
  letter-spacing: -.025em;
}
.intro-translation:lang(zh) {
  font-family: "Songti TC", "Noto Serif CJK TC", "PMingLiU", serif;
}
.intro-copy h1 { max-inline-size: 24ch; margin-inline: auto; }
.intro-translation { font-size: clamp(1.25rem, 2.3vw, 2rem); }
.intro-slide .source-image {
  box-shadow: 0 0 0 1px #ece5d65c, 0 .45rem 1.7rem #0a19175e;
}
.timeline-heading { padding-block-end: clamp(1.4rem, 4vw, 3.3rem); }
.timeline-node button { font-size: clamp(1.35rem, 2.3vw, 2.1rem); }
.timeline-node-films a[aria-current="true"] {
  background: var(--mat);
  color: var(--ink);
  text-underline-offset: .25em;
}
.film-rail {
  top: .5rem;
  border: 1px solid #aebdb0;
  border-radius: .55rem;
}
.film-context { border-radius: .45rem 0 0 .45rem; }
.film-rail-links { padding-inline-start: 1.15rem; }
.profile-heading h2 { max-inline-size: 19ch; text-wrap: balance; }
.profile-cover { align-items: center; }
.profile-matte {
  border: .5rem solid var(--mat);
  outline: 1px solid #bcc8bc;
  outline-offset: -1px;
}
.profile-facts div { padding-block: .52rem; }
.profile-summary > p:not(.profile-reference) { font-size: clamp(1rem, 1.35vw, 1.18rem); }
.ticket-stub { outline: 1px solid #bbc6b9; outline-offset: -.35rem; padding: 1.35rem; }
.media-feature { padding: .4rem; }
.media-caption { padding-block: .85rem; }
.exhibit-grid { padding: clamp(.3rem, .75vw, .65rem); background: var(--mat); }
.exhibit-grid .explorer { min-inline-size: 0; }
.programme-forward .solid { padding: .65rem 1.25rem; border-radius: 2rem; }
:is(#film-story, #ticket, #media, #after-ticket, #exhibit, #compare, #encounter, #film-quiz, #archive) {
  scroll-margin-top: 5.6rem;
}

@keyframes exhibition-entry {
  from { opacity: .75; transform: translateY(.85rem); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: no-preference) {
  .intro-copy { animation: exhibition-entry .64s var(--motion-ease-out) both; }
  #intro-art[data-fade] .intro-slide {
    transition: transform .54s var(--motion-ease-out), opacity .36s var(--motion-ease-out);
  }
  :is(.carousel-controls button, .timeline-node button i, .programme-forward .solid,
      .ticket-options-list button, .layer-button) {
    transition: transform .28s var(--motion-ease-out), background-color .24s var(--motion-ease-out);
  }
  :is(.carousel-controls button, .programme-forward .solid, .ticket-options-list button,
      .layer-button):active:not(:disabled) { transform: scale(.98); }
  .timeline-node button[aria-pressed="true"] i { transform: scale(1.17); }
  @supports (animation-timeline: view()) {
    :is(.timeline-heading, .profile-heading, .exhibit-header, #archive > .section-head) {
      animation: exhibition-entry 1s var(--motion-ease-out) both;
      animation-timeline: view();
      animation-range: entry 0% entry 100%;
    }
  }
}
@media (max-width: 760px) {
  .masthead nav { gap: .35rem; padding-inline-start: .65rem; }
  .film-rail { top: .25rem; }
  .film-context { border-radius: .45rem .45rem 0 0; }
  .film-rail-links { padding-inline-start: .65rem; }
  :is(#film-story, #ticket, #media, #after-ticket, #exhibit, #compare, #encounter, #film-quiz, #archive) {
    scroll-margin-top: 6.5rem;
  }
}

/* Manifesto exhibition */
@font-face {
  font-family: Anton;
  src: url("fonts/anton.ttf") format("truetype");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}
:root {
  --chapter-rule: clamp(.42rem, .72vw, .7rem);
  --subsection-rule: clamp(.25rem, .4vw, .4rem);
  --chapter-inset: clamp(1.6rem, 3.8vw, 3.5rem);
  --chapter: clamp(2.5rem, 5vw, 4.5rem);
  --paper: #eee8da;
  --ink: #211813;
  --muted: #625247;
  --line: #b8aa97;
  --blue: #9f211a;
  --lime: #ff7667;
  --stage: #160f0c;
  --mat: #e1d6c4;
  --stock: #fcf5e7;
  --stage-soft: #251b16;
  --stage-deep: #100b09;
  --stage-line: #79665a;
  --stage-muted: #c9bcad;
  --red-dark: #7b1711;
  --shadow-deep: #0b0604b0;
  --body-face: "Public Sans", "PingFang TC", "Microsoft JhengHei", "Noto Sans CJK TC", system-ui, sans-serif;
  --headline-latin: Anton, "Arial Narrow", Impact, sans-serif;
  --headline-cjk: "PingFang TC", "Noto Sans CJK TC", "Microsoft JhengHei", system-ui, sans-serif;
  --print-head: var(--headline-cjk);
}
:root:lang(en) { --print-head: var(--headline-latin); }

html, body { overflow-x: clip; }
body { font-family: var(--body-face); }
button:disabled { cursor: not-allowed; }
button, input[type="range"] { accent-color: var(--blue); }
:is(button, a, input, textarea, select, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}

.wrap > .masthead {
  min-height: 4.2rem;
  border-bottom: 0;
}
.wrap > .masthead::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: var(--subsection-rule);
  background: var(--paper);
  box-shadow: 0 0 0 100vmax var(--paper);
  clip-path: inset(0 -100vmax);
  pointer-events: none;
}
.brand { font: 750 .95rem/1.25 var(--body-face); letter-spacing: normal; }
.masthead nav {
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.masthead nav > a { text-decoration: underline; text-underline-offset: .27em; }
.masthead :focus-visible, .intro :focus-visible, .film-media :focus-visible { outline-color: var(--lime); }
.locale-options { border-color: var(--stage-line); }
.locale-options a:hover, .locale-options a[aria-current="true"] { background: var(--stage-soft); }

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(2rem, 4.8vw, 5.25rem);
  text-align: center;
  padding-block: clamp(2.6rem, 5.5vw, 5.8rem) clamp(2.15rem, 4.6vw, 4.5rem);
}
.intro-copy { margin: 0; }
.intro-period {
  color: var(--stage-muted);
  font: 650 .94rem/1.4 var(--body-face);
  letter-spacing: normal;
}
.intro-period span { margin-inline-start: .4rem; }
.intro-copy h1, :lang(en) .intro-copy h1 {
  min-width: 0;
  max-inline-size: none;
  margin: .25em 0 .18em;
  font: 900 clamp(2.8rem, 6.45vw, 7.3rem)/1.03 var(--print-head);
  letter-spacing: -.045em;
  text-wrap: initial;
  overflow-wrap: break-word;
}
:lang(en) .intro-copy h1 {
  font-weight: 400;
  font-size: clamp(3.9rem, 7.55vw, 8.45rem);
  letter-spacing: -.015em;
  line-height: 1.03;
}
.intro-copy h1 span { display: inline; }
.intro-translation, .intro-translation:lang(zh) {
  display: block;
  margin: 0;
  color: var(--paper);
  font: 500 clamp(1.02rem, 1.7vw, 1.5rem)/1.4 var(--body-face);
  letter-spacing: normal;
}
.intro-translation, .intro-translation:lang(zh) {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(.55rem, 1.2vw, 1.2rem);
}
.intro-translation::before, .intro-translation::after { background: var(--stage-line); }
.intro-art { min-width: 0; color: var(--paper); }
#intro-art { margin: 0; }
.intro-frame {
  --art-height: clamp(20rem, 41vw, 37rem);
  --poster-top: .45rem;
  --main-poster-width: 55%;
  --side-poster-width: 21%;
  --side-offset: 39%;
  --side-drop: clamp(1.4rem, 4vw, 4.2rem);
  background: transparent;
}
.intro-frame:has([data-poster="youth"][data-position="current"]) {
  --art-height: clamp(19rem, 35vw, 35rem);
}
.intro-frame:empty {
  background: url("assets/youth-poster.jpg") center / contain no-repeat;
}
.intro-slide { width: 100%; }
.intro-slide .poster-link {
  align-items: start;
  padding-block-start: var(--poster-top);
}
.intro-slide .source-image {
  width: min(var(--main-poster-width), calc((var(--art-height) - 2 * var(--poster-top)) * var(--ratio)));
  box-shadow: 0 0 0 1px var(--stage-line), 0 .8rem 2rem var(--shadow-deep);
}
.intro-slide[data-position="current"] .source-image { box-shadow: 0 0 0 1px var(--lime); }
.intro-slide:is([data-position="previous"], [data-position="next"]) .poster-link {
  padding-block-start: calc(var(--poster-top) + var(--side-drop));
}
.intro-slide:is([data-position="previous"], [data-position="next"]) .source-image {
  width: min(var(--side-poster-width), calc((var(--art-height) - var(--side-drop) - 2 * var(--poster-top)) * var(--ratio)));
}
.intro-slide[data-position="previous"] { transform: translateX(calc(-50% - var(--side-offset))); opacity: .5; }
.intro-slide[data-position="next"] { transform: translateX(calc(-50% + var(--side-offset))); opacity: .5; }
.carousel-controls { margin: 0; border-bottom: 1px solid var(--stage-line); }
.carousel-controls button, #intro-art figcaption { color: var(--paper); }
.carousel-dots button::after { border-color: var(--stage-muted); }
#intro-art figcaption {
  grid-template-columns: max-content minmax(0, 1fr);
  justify-items: start;
  align-items: baseline;
  column-gap: .75rem;
  padding-block: .65rem .15rem;
  text-align: start;
}
#intro-art figcaption strong { font: 800 clamp(1.16rem, 2.1vw, 1.65rem)/1.2 var(--body-face); }
#intro-art figcaption :is(.carousel-hint, .image-credit) { grid-column: 1 / -1; }
#intro-art figcaption :is(.carousel-hint, .carousel-material, .image-credit) { color: var(--stage-muted); }

.timeline-heading {
  padding-block: 0 clamp(1.5rem, 3.4vw, 2.75rem);
}
.timeline-range { color: var(--blue); font-family: var(--headline-latin); letter-spacing: .015em; }
.section h2, #film-picker h2, .exhibit-header h2, .feature h2, .profile-heading h2 {
  min-width: 0;
  font: 850 clamp(1.9rem, 4.15vw, 4.1rem)/1.12 var(--print-head);
  letter-spacing: -.025em;
  overflow-wrap: break-word;
}
:lang(en) :is(.section h2, #film-picker h2, .exhibit-header h2, .feature h2, .profile-heading h2) { font-weight: 400; }
.timeline-years { scrollbar-color: var(--line) transparent; }
.timeline-node button { font-family: var(--headline-latin); font-weight: 400; }
.timeline-node button::before { background: var(--line); }
.timeline-node:last-child button::after { border-color: var(--line); }
.timeline-node button[aria-pressed="true"] i { box-shadow: 0 0 0 2px var(--mat); }
.timeline-node-films a[aria-current="true"] { color: var(--blue); background: transparent; }

.film-rail { border-radius: 0; border-color: var(--line); top: 0; }
.film-context { border-radius: 0; border-inline-start: .28rem solid var(--blue); color: var(--paper); }
#film-context-meta { color: var(--stage-muted); }
.film-rail-links a { color: var(--ink); }
.profile-heading { border-bottom: var(--subsection-rule) solid var(--ink); }
.profile-heading h2 { max-inline-size: 19ch; font-size: clamp(2.5rem, 7vw, 6.25rem); }
.profile-english { font-family: var(--body-face); }
.profile-meta time { font-family: var(--headline-latin); }
.profile-cover {
  grid-template-columns: minmax(0, .72fr) minmax(0, 1.15fr);
  gap: clamp(1.5rem, 6vw, 6.3rem);
  align-items: start;
}
.profile-matte { border: 0; outline: 0; background: var(--stage-soft); }
.profile-matte .source-image { box-shadow: 0 .5rem 1.2rem var(--shadow-deep); }
.profile-summary { border-top: 1px solid var(--line); padding-top: 1rem; }
.profile-panels { gap: clamp(.75rem, 2.5vw, 2.25rem); }
.profile-panel + .profile-panel { border-inline-start-color: var(--line); }
.profile-panel h3, .profile-summary h3, .profile-routes h3, .ticket-prompts h3,
.film-heading h2, .quiz-header h3, .archive-task h3, .archive-supplement h3 {
  font-family: var(--body-face);
  font-weight: 800;
}
.profile-routes { border-top: 1px solid var(--line); }

.ticket-station {
  background: transparent;
  border-top: var(--subsection-rule) solid var(--ink);
  padding-block-start: var(--chapter-inset);
  padding-inline: 0;
}
.ticket-options-list button, .ticket-stub { border-color: var(--line); }
.ticket-stub { outline-color: var(--line); }
#film-picker { margin-bottom: var(--chapter); }
.programme { margin-bottom: var(--chapter); }
.ticket-station, .film-media.section { margin-block: var(--chapter) 0; }
.programme-forward { margin-top: clamp(1rem, 2vw, 1.5rem); }
#after-ticket + .programme-forward { margin-block-start: .75rem; }
.programme-forward .solid { border-radius: 0; }
.film-media.section {
  --line: var(--stage-line);
  --blue: var(--lime);
  --muted: var(--stage-muted);
  border-top: var(--chapter-rule) solid var(--lime);
}
#media-heading, .film-media #screen-notes h3 { font-family: var(--print-head); }
.media-feature { background: var(--stage-soft); }
.media-player, .media-play { background: var(--stage-deep); }
.media-play:hover .media-play-label { background: var(--stock); }
.solid:hover:not(:disabled) { background: var(--red-dark); color: var(--stock); }

.exhibit-header {
  border-top: var(--chapter-rule) solid var(--ink);
  padding-top: var(--chapter-inset);
  margin-bottom: clamp(1.65rem, 3.6vw, 3.2rem);
}
.exhibit-grid { padding: 0; }
.stage { background: var(--stage); }
.stage[data-mode="exploded"] { background: var(--mat); }
.explorer { border-inline-start: 1px solid var(--line); }
.layer-button { border-color: var(--line); }
.layer-button[aria-pressed="true"] { background: var(--mat); box-shadow: inset .22rem 0 var(--blue); }
.spatial-plane.current-plane::before { border-color: var(--blue); }
.spatial-piece.selected img, .orbit-scene:not(.dragging) .spatial-piece:hover img { filter: drop-shadow(0 0 1.5px var(--muted)); }
#encounter, #archive > .section-head {
  border-top: var(--chapter-rule) solid var(--ink);
  padding-top: var(--chapter-inset);
}
#encounter h2 { max-width: none; }

@media (min-width: 761px) {
  #encounter {
    --encounter-inset: clamp(1.25rem, 3.5vw, 3.25rem);
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 0;
  }
  #encounter h2 { padding-inline-end: var(--encounter-inset); }
  #historic {
    border-inline-start: 1px solid var(--line);
    padding-inline-start: var(--encounter-inset);
  }
}
#film-quiz {
  border-top: var(--subsection-rule) solid var(--ink);
  padding: clamp(1.35rem, 4.2vw, 3.5rem);
}

@media (min-width: 980px) {
  :root { --shell: clamp(4rem, 6.2vw, 7rem); }
  .wrap { width: min(1320px, calc(100% - 2 * var(--shell))); }
}

@media (max-width: 840px) {
  .intro { padding-block: 2.35rem 2.5rem; }
  .intro-copy h1, :lang(en) .intro-copy h1 { font-size: clamp(2.6rem, 8.2vw, 5rem); }
  .intro-frame { --art-height: clamp(14rem, 52vw, 26rem); }
  .intro-frame:has([data-poster="youth"][data-position="current"]) {
    --art-height: clamp(10rem, 38vw, 20rem);
  }
  .explorer { border-inline-start: 0; border-top: 1px solid var(--line); }
}
@media (max-width: 670px) {
  .intro-copy h1 span { display: block; }
  .intro-frame {
    --main-poster-width: 64%;
    --side-poster-width: 15%;
    --side-offset: 42%;
  }
  .timeline-heading { align-items: start; }
  .timeline-range { font-size: clamp(1rem, 4vw, 1.4rem); line-height: 1.6; }
  .profile-cover { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 430px) {
  #intro-art figcaption { grid-template-columns: minmax(0, 1fr); row-gap: .12rem; }
  #film-picker h2 { font-size: clamp(1.4rem, 6vw, 1.9rem); }
}
@media (prefers-reduced-motion: reduce) {
  .intro-copy { animation: none; }
  #intro-art[data-fade] .intro-slide { transition: none; }
}

/* Keep the chapter tabs on the same visual plane as the film name. */
.film-rail-links {
  align-items: stretch;
  gap: .12rem;
  padding: 0 .3rem;
}
.film-rail-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-block-size: 2.85rem;
  padding-inline: .68rem;
  font-weight: 500;
  background-color: transparent;
}
@media (hover: hover) {
  .film-rail-links a:hover {
    color: var(--ink);
    background-color: color-mix(in srgb, var(--mat) 78%, var(--blue));
    text-decoration: none;
  }
  .film-rail-links a[aria-current="location"]:hover {
    background-color: color-mix(in srgb, var(--mat) 88%, var(--blue));
  }
}
.film-rail-links a[aria-current="location"] {
  color: var(--ink);
  background-color: var(--mat);
  box-shadow: inset 3px 0 var(--blue);
  font-weight: 800;
  text-decoration: none;
}
@media (prefers-reduced-motion: no-preference) {
  .film-rail-links a { transition: background-color .24s ease, color .24s ease, box-shadow .24s ease; }
}
#intro-art figcaption {
  grid-template-columns: minmax(0, 1fr);
  text-align: center;
  justify-items: center;
}
.carousel-controls { gap: .3rem; }
.carousel-controls button:focus-visible { outline-offset: -3px; }
.carousel-controls [data-carousel-step]:is(:hover, :focus-visible) {
  background: var(--stage-soft);
  color: var(--lime);
}

#archive { margin-bottom: 0; }
.exhibition-tail {
  margin: clamp(1.5rem, 3.5vw, 2.75rem) 0 0;
  color: var(--muted);
  text-align: center;
  font-size: .875rem;
}
.exhibition-tail a { display: inline-block; padding: .55rem .65rem; }

/* Version 31 palette on the version 30 layout. */
:root {
  color-scheme: dark;
  --paper: #171210;
  --stock: #211915;
  --mat: #30251f;
  --stage: #100c0a;
  --ink: #faf1e5;
  --text: #e2d5c7;
  --muted: #bfb0a2;
  --line: #6c584b;
  --blue: #ff8172;
  --lime: var(--blue);
  --red-dark: #8b211a;
  --red-fill: #a52b23;
  --red-ink: #fff7ee;
  --stage-soft: var(--stock);
  --stage-deep: var(--stage);
  --stage-line: var(--line);
  --stage-muted: var(--muted);
  --art-mount: #dfd3c1;
  --art-ink: #221913;
  --art-muted: #544236;
  --art-line: #826e5e;
  --dialog-scrim: #0c0907be;
}

body { color: var(--text); }
:is(h1, h2, h3, h4, strong) { color: var(--ink); }
::selection { color: var(--red-ink); background-color: var(--red-fill); }

.wrap > .masthead, .intro, .locale-options, .intro-translation,
.intro-translation:lang(zh), .intro-art, .carousel-controls button,
#intro-art figcaption, .film-context { color: var(--ink); }
.wrap > .masthead::after {
  background-color: var(--ink);
  box-shadow: 0 0 0 100vmax var(--ink);
}
.locale-options { background-color: var(--stock); }
.locale-options a:is(:hover, [aria-current="true"]) { color: var(--blue); background-color: var(--mat); }
.carousel-controls button:hover { background-color: var(--mat); }
.carousel-dots button::after { border-color: var(--muted); }
.film-context { background-color: var(--mat); }
.film-rail-links a { color: var(--text); }
.profile-matte { background-color: var(--stage); }
.profile-english { color: var(--text); }
.profile-meta time { color: var(--ink); }
.profile-routes { background-color: var(--stock); }
.profile-routes dd, .profile-routes .profile-reference a { color: var(--text); }

.film-media.section { color: var(--text); background-color: var(--stock); }
#media-heading, .film-media #screen-notes h3, .film-media .outline { color: var(--ink); }
.film-media .outline:hover:not(:disabled) { color: var(--paper); background-color: var(--ink); }
.media-feature { background-color: var(--stage); }
.media-play-label { color: var(--paper); background-color: var(--ink); }
.media-play:hover .media-play-label { background-color: var(--blue); }
:is(.annotation p, .feature-copy > p, .section-head p, .decisions p, .records-grid p) { color: var(--text); }

.ticket-options-list button, #layer-return button, .ticket-stub button,
.ticket-detail-option, .ticket-stub, .ticket-reading:not(:empty) {
  color: var(--ink);
  background-color: var(--stock);
}
.ticket-detail-option:has(input:checked) { background-color: var(--mat); }
.ticket-options-list button[aria-pressed="true"], .solid {
  color: var(--red-ink);
  background-color: var(--red-fill);
  border-color: var(--red-fill);
}
.solid:hover:not(:disabled) {
  color: var(--red-ink);
  background-color: var(--red-dark);
  border-color: var(--red-dark);
}

.stage[data-mode="exploded"] {
  --ink: var(--art-ink);
  --muted: var(--art-muted);
  --line: var(--art-line);
  --blue: var(--red-fill);
  --lime: var(--art-ink);
  background-color: var(--art-mount);
}
.stage[data-mode="exploded"] :is(.target-choice button[aria-pressed="true"], .orbit-actions button:hover:not(:disabled)) {
  color: var(--art-mount);
}
.view-switch button[aria-pressed="true"] { background-color: var(--mat); color: var(--ink); }
.hotspot:is(:hover, :focus-visible), .wipe-rule span, .rhythm-target[aria-pressed="true"] span { color: var(--paper); }
.versions-grid figcaption { color: var(--text); }

.film-quiz, .archive-task { background-color: var(--stock); }
.quiz-figure img { background-color: var(--stage); }
.quiz-options button, .archive-options button, .archive-result { background-color: var(--paper); border-color: var(--line); }
.quiz-options button:hover:not(:disabled), .archive-options button:hover { background-color: var(--mat); }
.quiz-options .correct-answer:disabled, .quiz-options .chosen-answer:disabled,
.quiz-feedback:not(:empty), .archive-feedback, .records-grid article, .decisions { background-color: var(--mat); }
.quiz-options .correct-answer:disabled { border-color: var(--muted); }
.quiz-options .chosen-answer:disabled { border-color: var(--blue); }
.archive-options button[aria-pressed="true"] { color: var(--ink); background-color: var(--mat); border-color: var(--blue); }
.repair-track li { color: var(--ink); background-color: var(--mat); }
.repair-track li.repair-junction { color: var(--text); border-color: var(--muted); }
.repair-track[data-joined="true"] .repair-junction { color: var(--ink); background-color: var(--mat); border-color: var(--blue); }
dialog { border-color: var(--line); }
dialog::backdrop { background-color: var(--dialog-scrim); }
.zoom-frame { background-color: var(--stage); }
.zoom-frame[data-ink] { background-color: var(--art-mount); }

.quiz-nav { justify-content: center; align-items: center; }

#after-ticket { padding-block-end: 0; grid-template-columns: minmax(0, 1fr); gap: 1.5rem; }
#after-ticket > h2 { max-inline-size: none; }
#after-ticket #post { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
#post .ticket-reading:empty { display: none; }
@media (min-width: 48rem) {
  #post .ticket-prompts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto auto 1fr;
    column-gap: clamp(1.5rem, 4vw, 4rem);
    align-items: start;
  }
  #post-question, #postopts, #post .ticket-reading { grid-column: 1; }
  #post-question { grid-row: 1; }
  #postopts { grid-row: 2; }
  #post .ticket-reading { grid-row: 3; }
  #post .ticket-details { grid-column: 2; grid-row: 1 / 4; margin: 0; }
  #post .ticket-details legend { font-size: clamp(1.05rem, 1.75vw, 1.35rem); line-height: 1.45; }
  #post .ticket-stub { display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
  #post .ticket-stub dl { flex: 1 1 14rem; margin: 0; }
  #post .ticket-stub-links { margin: 0; }
}
