/* One shared typeface for every game UI surface, including controls,
   date HUD, modal notices, story text, character panels, save screens and setup.
   The image-based title art remains unchanged.
   Noto Serif SC is the web-distributed Simplified Chinese counterpart of
   Noto Serif CJK SC. The local full-CJK family remains a fallback. */
:root {
 --game-text-font:'Noto Serif SC','Noto Serif CJK SC','Source Han Serif SC',
                  'Songti SC','STSong','SimSun',serif;
 --text-scale:1;
 --font-note:calc(clamp(15px,1.3cqw,18px) * var(--text-scale));
 --font-body:calc(clamp(17px,1.55cqw,21px) * var(--text-scale));
 --font-section:calc(clamp(19px,1.7cqw,23px) * var(--text-scale));
 --font-heading:calc(clamp(21px,2cqw,28px) * var(--text-scale));
 --font-story:calc(clamp(19px,1.55cqw,22px) * var(--text-scale));
}
:root[data-text-size='small'] {--text-scale:.9;}
:root[data-text-size='large'] {--text-scale:1.15;}
html[data-mobile-device='true'] {
 --font-note:calc(14px * var(--text-scale));
 --font-body:calc(16px * var(--text-scale));
 --font-section:calc(18px * var(--text-scale));
 --font-heading:calc(20px * var(--text-scale));
 --font-story:calc(16px * var(--text-scale));
}
body:is(.game-shell,.frame-opening) main {font-size:var(--font-body);}
main :is(p,small,li,dd,button,summary) {text-wrap:pretty;line-break:strict;}
main :is(input,textarea,select) {line-height:1.5;}
main small {font-size:var(--font-note);}
/* Keep the UI consistent even when older component rules specify local fonts. */
html body,
html body * {
 font-family:var(--game-text-font)!important;
}
