/*
 * Locally bundled editorial faces.
 * Source Serif 4 and Manrope remain the Latin editorial/UI faces.
 * Locale-specific Noto Serif variable fonts are bundled under SIL OFL 1.1.
 */
@font-face {
  font-family: "OM Noto Serif KR";
  src: url("/fonts/NotoSerifKR-Variable.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

/* Locale-specific aliases keep script routing explicit and auditable. */
@font-face {
  font-family: "OM Noto Serif JP";
  src: url("/media/fonts/NotoSerifCJKjp-VF.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "OM Noto Serif SC";
  src: url("/media/fonts/NotoSerifCJKsc-VF.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "OM Noto Serif TC";
  src: url("/media/fonts/NotoSerifCJKtc-VF.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "OM Noto Serif Thai";
  src: url("/fonts/NotoSerifThai-Variable.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: "OM Noto Serif Devanagari";
  src: url("/fonts/NotoSerifDevanagari-Variable.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:where(.reader-ko) { --reader-serif: "OM Noto Serif KR", "Noto Serif KR", serif; }
:where(.reader-ja) { --reader-serif: "OM Noto Serif JP", "Noto Serif CJK JP", "Yu Mincho", serif; }
:where(.reader-zh-cn) { --reader-serif: "OM Noto Serif SC", "Noto Serif CJK SC", "Microsoft YaHei", serif; }
:where(.reader-zh-tw) { --reader-serif: "OM Noto Serif TC", "Noto Serif CJK TC", "Microsoft JhengHei", serif; }
:where(.reader-th) { --reader-serif: "OM Noto Serif Thai", "Noto Serif Thai", "Leelawadee UI", Tahoma, serif; }
:where(.reader-hi) { --reader-serif: "OM Noto Serif Devanagari", "Noto Serif Devanagari", "Nirmala UI", Mangal, serif; }
:where(.reader-en, .reader-es) { --reader-serif: SourceSerif, Georgia, serif; }

.reader-ko :is(.identity h1,.original,.translation p,.prose p),
.reader-ja :is(.identity h1,.original,.translation p,.prose p),
.reader-zh-cn :is(.identity h1,.original,.translation p,.prose p),
.reader-zh-tw :is(.identity h1,.original,.translation p,.prose p),
.reader-th :is(.identity h1,.original,.translation p,.prose p),
.reader-hi :is(.identity h1,.original,.translation p,.prose p),
.reader-en :is(.identity h1,.original,.translation p,.prose p),
.reader-es :is(.identity h1,.original,.translation p,.prose p) {
  font-family: var(--reader-serif);
}

.reader-ko :is(.translation p,.prose p) { line-height: 2; }
.reader-ja :is(.translation p,.prose p),
.reader-zh-cn :is(.translation p,.prose p),
.reader-zh-tw :is(.translation p,.prose p) {
  line-height: 2;
  line-break: strict;
  word-break: normal;
}
.reader-th :is(.identity h1,.translation p,.prose p),
.reader-hi :is(.identity h1,.translation p,.prose p) {
  line-height: 2.05;
  word-break: normal;
  overflow-wrap: break-word;
}

