/* Constantia draws Latin text; numerals retain Noto Serif SC with optical size matching. */
@font-face {
  font-family: "Site Constantia Text";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: local("Constantia"), local("Palatino Linotype"), local("Book Antiqua"), local("Georgia");
  size-adjust: 110.87%;
  ascent-override: 103.82%;
  descent-override: 25.80%;
  line-gap-override: 0%;
  unicode-range: U+0020-002F, U+003A-00B1, U+00B4-00B8, U+00BA-00BB, U+00BF-02FF, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+FB00-FB06;
}

@font-face {
  font-family: "Site Constantia Text";
  font-style: normal;
  font-weight: 600 900;
  font-display: swap;
  src: local("Constantia Bold"), local("Palatino Linotype Bold"), local("Book Antiqua Bold"), local("Georgia Bold");
  size-adjust: 104.35%;
  ascent-override: 110.30%;
  descent-override: 27.41%;
  line-gap-override: 0%;
  unicode-range: U+0020-002F, U+003A-00B1, U+00B4-00B8, U+00BA-00BB, U+00BF-02FF, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+FB00-FB06;
}

@font-face {
  font-family: "Site Constantia Text";
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
  src: local("Constantia Italic"), local("Palatino Linotype Italic"), local("Book Antiqua Italic"), local("Georgia Italic");
  size-adjust: 110.87%;
  ascent-override: 103.82%;
  descent-override: 25.80%;
  line-gap-override: 0%;
  unicode-range: U+0020-002F, U+003A-00B1, U+00B4-00B8, U+00BA-00BB, U+00BF-02FF, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+FB00-FB06;
}

@font-face {
  font-family: "Site Constantia Text";
  font-style: italic;
  font-weight: 600 900;
  font-display: swap;
  src: local("Constantia Bold Italic"), local("Palatino Linotype Bold Italic"), local("Book Antiqua Bold Italic"), local("Georgia Bold Italic");
  size-adjust: 104.35%;
  ascent-override: 110.30%;
  descent-override: 27.41%;
  line-gap-override: 0%;
  unicode-range: U+0020-002F, U+003A-00B1, U+00B4-00B8, U+00BA-00BB, U+00BF-02FF, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+FB00-FB06;
}

/* The award labels already used Constantia, so their letters need no size compensation. */
@font-face {
  font-family: "Site Constantia Native";
  font-style: normal;
  font-weight: 400 500;
  font-display: swap;
  src: local("Constantia"), local("Palatino Linotype"), local("Book Antiqua"), local("Georgia");
  unicode-range: U+0020-002F, U+003A-00B1, U+00B4-00B8, U+00BA-00BB, U+00BF-02FF, U+0300-036F, U+1E00-1EFF, U+2000-206F, U+20AC, U+2122, U+FB00-FB06;
}

/* Preserve the original 500-800 weight mapping and baseline metrics for decimal digits. */
@font-face {
  font-family: "Site Noto Numerals";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: local("Noto Serif SC Medium"), local("Noto Serif SC"), url("/assets/fonts/noto-serif-sc-latin-vf.woff2?v=20260829") format("woff2");
  size-adjust: 103%;
  ascent-override: 111.75%;
  descent-override: 27.77%;
  line-gap-override: 0%;
  unicode-range: U+0030-0039;
}

@font-face {
  font-family: "Site Noto Numerals";
  font-style: normal;
  font-weight: 600 800;
  font-display: swap;
  src: local("Noto Serif SC Medium"), local("Noto Serif SC"), url("/assets/fonts/noto-serif-sc-latin-vf.woff2?v=20260829") format("woff2");
  size-adjust: 96%;
  ascent-override: 119.90%;
  descent-override: 29.79%;
  line-gap-override: 0%;
  unicode-range: U+0030-0039;
}

:root {
  --site-text-font-family: "Site Constantia Text", "Site Noto Numerals", "Noto Serif SC", "Source Han Serif SC", "Songti SC", serif;
  --site-original-numeral-family: "Site Constantia Text", "Noto Serif SC", "Source Han Serif SC", "Songti SC", serif;
  --site-native-constantia-family: "Site Constantia Native", "Noto Serif SC", "Source Han Serif SC", "Songti SC", serif;
}

/* Keep icon exclusions from changing the existing text rule's specificity. */
html,
body,
body *:not(.katex):not(.katex *):where(:not(.fa):not(.fas):not(.far):not(.fab):not(.ai)) {
  font-family: var(--site-text-font-family) !important;
}

/* These sizes are intentional, or already compensated independently of body text. */
.presentation__date,
.presentation__date *,
.visitor-bar__value,
.badge__year,
sup:not(.katex *),
sub:not(.katex *),
pre,
pre *,
code,
code *,
kbd,
kbd *,
samp,
samp *,
math:not(.katex *),
math *:not(.katex *) {
  font-family: var(--site-original-numeral-family) !important;
}
