/* Chinese editorial typography — loaded only as an override when the locale is zh-CN. */
@font-face {
  font-family: "Kyra CJK Serif";
  src: local("Noto Serif SC"), local("Source Han Serif SC"), local("Songti SC"), local("STSong"), local("SimSun");
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  unicode-range: U+2E80-2EFF, U+3000-303F, U+31C0-31EF, U+3400-4DBF, U+4E00-9FFF, U+F900-FAFF, U+FF00-FFEF;
}

@font-face {
  font-family: "Kyra CJK Sans";
  src: local("Noto Sans SC"), local("Source Han Sans SC"), local("PingFang SC"), local("Microsoft YaHei UI"), local("Microsoft YaHei");
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  unicode-range: U+2E80-2EFF, U+3000-303F, U+31C0-31EF, U+3400-4DBF, U+4E00-9FFF, U+F900-FAFF, U+FF00-FFEF;
}

html[lang="zh-CN"] {
  --kyra-zh-serif: "Kyra CJK Serif", "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --kyra-zh-sans: "Kyra CJK Sans", "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

html[lang="zh-CN"] body {
  font-family: var(--kyra-zh-sans);
  overflow-x: clip;
  font-kerning: normal;
}

html[lang="zh-CN"] :is(p, li, blockquote, figcaption, dd) {
  font-family: var(--kyra-zh-sans);
  line-height: 1.82;
  letter-spacing: 0.018em;
  line-break: strict;
}

html[lang="zh-CN"] :is(h1, h2, h3, h4, .display, [class*="title"]) {
  font-weight: 500;
  letter-spacing: 0.035em;
  line-height: 1.16;
  line-break: strict;
  text-wrap: balance;
  overflow-wrap: break-word;
}

html[lang="zh-CN"] body.portfolio-home :is(h1, h2, h3, h4, .display, [class*="title"]),
html[lang="zh-CN"] body.project-tonights-table :is(h1, h2, h3, h4, .display, [class*="title"]) {
  font-family: "Kyra CJK Serif", "Cormorant Garamond", "Fraunces", Georgia, serif;
}

html[lang="zh-CN"] body.project-romano :is(h1, h2, h3, h4, .display, [class*="title"]) {
  font-family: "Kyra CJK Serif", "Bodoni Moda", "Instrument Serif", Georgia, serif;
}

html[lang="zh-CN"] body.project-petever :is(h1, h2, h3, h4, .display, [class*="title"]) {
  font-family: "Kyra CJK Serif", "Newsreader", Georgia, serif;
}

html[lang="zh-CN"] body.project-gogo :is(h1, h2, h3, h4, .display, [class*="title"]) {
  font-family: "Kyra CJK Sans", "Space Grotesk", "Chakra Petch", Arial, sans-serif;
  font-weight: 500;
  letter-spacing: 0.045em;
}

html[lang="zh-CN"] body.project-anemo :is(h1, h2, h3, h4, .display, [class*="title"]) {
  font-family: "Kyra CJK Serif", "Instrument Serif", Georgia, serif;
}

html[lang="zh-CN"] :is([class*="eyebrow"], [class*="kicker"], [class*="overline"], [class*="label"], [class*="meta"], [class*="caption"]) {
  font-family: var(--kyra-zh-sans);
  text-transform: none;
  letter-spacing: 0.1em;
  line-height: 1.55;
}

html[lang="zh-CN"] .kyra-zh-title-hero {
  font-size: clamp(3rem, 5.2vw, 5.15rem) !important;
  line-height: 1.12 !important;
  letter-spacing: 0.025em !important;
}

html[lang="zh-CN"] .kyra-zh-title-large {
  font-size: clamp(2.35rem, 4.2vw, 4rem) !important;
  line-height: 1.16 !important;
}

html[lang="zh-CN"] .kyra-zh-title-medium {
  font-size: clamp(1.95rem, 3.45vw, 3.25rem) !important;
  line-height: 1.2 !important;
}

html[lang="zh-CN"] body.project-tonights-table .tt-kit-side-note :is(h3, p),
html[lang="zh-CN"] body.project-romano .flow-step :is(h3, p),
html[lang="zh-CN"] body.project-petever .sense-card :is(h3, p),
html[lang="zh-CN"] body.project-gogo .state-card :is(h3, p),
html[lang="zh-CN"] body.project-anemo .material-card :is(h3, p) {
  max-width: 28em;
}

@media (max-width: 700px) {
  html[lang="zh-CN"] :is(p, li, blockquote, figcaption, dd) {
    line-height: 1.75;
  }

  html[lang="zh-CN"] .kyra-zh-title-hero {
    font-size: clamp(2.6rem, 12vw, 4.5rem) !important;
  }

  html[lang="zh-CN"] .kyra-zh-title-large {
    font-size: clamp(2.15rem, 9.6vw, 3.6rem) !important;
  }

  html[lang="zh-CN"] .kyra-zh-title-medium {
    font-size: clamp(1.8rem, 7.8vw, 3rem) !important;
  }
}

/* Romano translated-layout containment: preserve animated strips without horizontal page drift. */
html[lang="zh-CN"] body.project-romano :is(.ad, .mq, .engwrap, .namescene, .unified-project-end) {
  max-width: 100vw;
  overflow-x: clip;
}
html[lang="zh-CN"] body.project-romano :is(.project-end__top, .project-end__title, .project-end__bottom) {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  max-width: 100%;
}
@media (max-width: 700px) {
  html[lang="zh-CN"] body.project-romano .adgrid :is(.word, small) {
    min-width: 0;
    max-width: 100%;
    white-space: normal;
  }
}
html[lang="zh-CN"] body.project-romano .project-end__top a { white-space: normal; text-align: right; }
