/* Shared reading layout for the bilingual site. */
body.gilded-theme[data-page] main :is(h1,h2,h3) { text-wrap: balance; }
body.gilded-theme[data-page] :is(.section-intro,.work-lead,.film-logline,.series-logline,.project-tagline) { text-wrap: pretty; }
body.gilded-theme[data-page] :is(.film-card-copy,.project-copy,.series-copy,.work-heading,.prose,.download-card>span) { min-width: 0; }
body.gilded-theme[data-page] .section-heading { gap: 12px; margin-bottom: 40px; }
body.gilded-theme[data-page] .section-heading h2 { margin-top: 10px; line-height: 1.22; }
body.gilded-theme[data-page] .section-intro { max-width: 58ch; margin-top: 22px; line-height: 1.8; }
body.gilded-theme[data-page] .work-heading { max-width: 1000px; margin-bottom: 40px; }
body.gilded-theme[data-page] .work-heading h1 { line-height: 1.16; margin-bottom: 24px; }
body.gilded-theme[data-page] .work-lead { max-width: 58ch; line-height: 1.8; }
body.gilded-theme[data-page]:lang(zh-CN) .work-lead { max-width: 34em; }
body.gilded-theme[data-page] .film-logline { line-height: 1.8; }
body.gilded-theme[data-page] .film-card:not(.film-card-featured) { display: flex; flex-direction: column; }
body.gilded-theme[data-page] .film-card:not(.film-card-featured) .film-card-copy { display: flex; flex-direction: column; flex: 1; }
body.gilded-theme[data-page] .film-card:not(.film-card-featured) .film-actions { margin-top: auto; padding-top: 20px; }
body.gilded-theme[data-page] .hero-actions { column-gap: 24px; row-gap: 14px; }
body.gilded-theme[data-page] .hero-actions :is(a,button) { max-width: 100%; }
body.gilded-theme[data-page] .prose { gap: 26px; }
body.gilded-theme[data-page] .prose p { line-height: 1.9; }
body.gilded-theme[data-page] .notebook-chapter .prose>h3 { margin: 12px 0 0; line-height: 1.4; }
body.gilded-theme[data-page] .notebook-chapter .prose figure { margin: 16px 0 8px; }
body.gilded-theme[data-page] .project-copy .project-lead { display: grid; gap: 14px; margin: 24px 0 28px; }
body.gilded-theme[data-page] .project-structure { font-size: 17px; line-height: 1.5; letter-spacing: .06em; color: var(--gold); }
body.gilded-theme[data-page] .project-tagline { max-width: 24em; font-size: clamp(25px,2.4vw,34px); line-height: 1.5; letter-spacing: 0; }
body.gilded-theme[data-page] .download-card { grid-template-columns: minmax(0,1fr) auto; gap: 12px 18px; align-content: start; padding: 27px; min-height: 145px; }
body.gilded-theme[data-page] .download-card>span { font-size: 24px; line-height: 1.4; text-wrap: balance; }
body.gilded-theme[data-page]:lang(zh-CN) .download-card>span { font-size: 20px; line-height: 1.55; }
body.gilded-theme[data-page] .download-card>small { font-size: 13px; line-height: 1.65; }
body.gilded-theme[data-page] .series-hero { padding-top: 72px; }
html[lang="en"] .series-episodes { display: flex; flex-direction: column; }
html[lang="en"] .series-episodes>.section-heading { order: 0; }
html[lang="en"] .series-episodes>.section-intro { order: 1; }
html[lang="en"] .episode-grid { order: 2; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 12px; margin-top: 26px; }
html[lang="en"] .episode-card { justify-content: center; min-height: 62px; padding: 14px 12px; gap: 0; text-align: center; }
html[lang="en"] .episode-card :is(.episode-number,.episode-state) { display: none; }
html[lang="en"] body.gilded-theme[data-page] .episode-card h3 { font-size: 21px; line-height: 1.3; }
html[lang="en"] .series-viewer { order: 3; margin-top: 24px; }
@media(max-width:700px) {
  body.gilded-theme[data-page] .section-heading { margin-bottom: 28px; }
  body.gilded-theme[data-page] .linebreak { white-space: normal; }
  body.gilded-theme[data-page] .page-hero { padding-top: 58px; padding-bottom: 54px; }
  body.gilded-theme[data-page] .work-hero { padding-top: 54px; }
  body.gilded-theme[data-page] .work-heading { margin-bottom: 30px; }
  body.gilded-theme[data-page] .work-heading h1 { font-size: clamp(34px,8.5vw,43px); line-height: 1.24; }
  body.gilded-theme[data-page]:lang(zh-CN) .work-heading h1 { font-size: clamp(27px,7.5vw,35px); line-height: 1.4; word-break: normal; }
  body.gilded-theme[data-page] .section-intro { font-size: 16px; line-height: 1.8; }
  body.gilded-theme[data-page] .hero-actions { gap: 14px 22px; }
  body.gilded-theme[data-page] .project-copy .project-lead { gap: 12px; margin: 20px 0 24px; }
  body.gilded-theme[data-page] .project-structure { font-size: 15px; }
  body.gilded-theme[data-page] .project-tagline { font-size: 25px; line-height: 1.55; }
  body.gilded-theme[data-page] .download-card { padding: 22px; min-height: 125px; }
  body.gilded-theme[data-page] .download-card>span { font-size: 22px; }
  body.gilded-theme[data-page]:lang(zh-CN) .download-card>span { font-size: 18px; }
  body.gilded-theme[data-page] .series-hero { padding-top: 48px; gap: 26px; }
  body.gilded-theme[data-page]:lang(zh-CN) .series-title { font-size: clamp(28px,7.4vw,34px); line-height: 1.4; }
  html[lang="en"] .episode-grid { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; }
  html[lang="en"] .episode-card { min-height: 54px; padding: 12px 6px; }
  html[lang="en"] body.gilded-theme[data-page] .episode-card h3 { font-size: 18px; }
}

@media(max-width:800px) {
  body.gilded-theme[data-page] .artist-layout { grid-template-columns: minmax(0,1fr); gap: 42px; }
  body.gilded-theme[data-page] .artist-layout>div { min-width: 0; padding: 0; }
  body.gilded-theme[data-page] .artist-layout figure { width: 100%; }
}

/* The English portfolio opens with Beyond the Walls. */
html[lang="en"] .selected-films>.film-card-featured { margin-bottom: 70px; }
@media(max-width:700px) { html[lang="en"] .selected-films>.film-card-featured { margin-bottom: 52px; } }

/* Two selected works lead into the current project and the archive by year. */
body.gilded-theme[data-page="index"] #portfolio>article:last-of-type { margin-bottom: 0; padding-bottom: 0; border-bottom: 0; }
body.gilded-theme[data-page="index"] .archive-year+.archive-year { margin-top: 78px; }
body.gilded-theme[data-page="index"] .archive-year-heading { margin: 0 0 34px; padding-bottom: 18px; border-bottom: 1px solid var(--line); color: var(--gold); font-family: var(--art-letter); font-size: 38px; font-weight: 400; line-height: 1.2; letter-spacing: .04em; }
body.gilded-theme[data-page="index"] .archive-year .poster-archive { grid-template-columns: repeat(3,minmax(0,1fr)); gap: 44px 38px; padding-top: 0; }
body.gilded-theme[data-page="index"] .archive-year figure { min-width: 0; }
body.gilded-theme[data-page="index"] .archive-year figcaption { margin-top: 20px; line-height: 1.45; text-wrap: balance; }
@media(max-width:700px) {
  body.gilded-theme[data-page="index"] .archive-year+.archive-year { margin-top: 52px; }
  body.gilded-theme[data-page="index"] .archive-year-heading { margin-bottom: 26px; padding-bottom: 14px; font-size: 32px; }
  body.gilded-theme[data-page="index"] .archive-year .poster-archive { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 32px 22px; }
  body.gilded-theme[data-page="index"] .archive-year .poster-archive figure>a { padding: 5px; }
  body.gilded-theme[data-page="index"] .archive-year .poster-archive figure>a:before { width: 52px; height: 76px; left: -13px; top: -18px; }
  body.gilded-theme[data-page="index"] .archive-year figcaption { font-size: 18px; margin-top: 14px; }
  body.gilded-theme[data-page="index"]:lang(zh-CN) .archive-year figcaption { font-size: 15px; }
}
