/* =========================================================
   V10 Brand Typography for WordPress Health Hub
   Brand Book:
   - English: Red Hat Display
   - Thai: Prompt
   ========================================================= */

:root {
  --ctl-font-en: "Red Hat Display", "Prompt", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ctl-font-th: "Prompt", "Red Hat Display", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Default site language / English content */
html,
body,
button,
input,
select,
textarea {
  font-family: var(--ctl-font-en) !important;
}

/* Main UI pieces should follow the English brand font by default. */
body.ctl-blog-theme,
body.ctl-blog-theme .site-header,
body.ctl-blog-theme .nav,
body.ctl-blog-theme .btn,
body.ctl-blog-theme .blog-main,
body.ctl-blog-theme .blog-tag,
body.ctl-blog-theme .blog-meta,
body.ctl-blog-theme .blog-card,
body.ctl-blog-theme .blog-featured-copy,
body.ctl-blog-theme .single-blog-article,
body.ctl-blog-theme .single-blog-content,
body.ctl-blog-theme .blog-footer {
  font-family: var(--ctl-font-en) !important;
}

/* Headings / navigation / CTA */
body.ctl-blog-theme h1,
body.ctl-blog-theme h2,
body.ctl-blog-theme h3,
body.ctl-blog-theme h4,
body.ctl-blog-theme h5,
body.ctl-blog-theme h6,
body.ctl-blog-theme .site-header .nav a,
body.ctl-blog-theme .site-header .btn,
body.ctl-blog-theme .blog-featured-copy h1,
body.ctl-blog-theme .blog-card-body h2,
body.ctl-blog-theme .single-blog-header h1 {
  font-family: var(--ctl-font-en) !important;
}

/* Thai language support.
   WordPress will apply this automatically if the site language is Thai,
   or manually when content uses lang="th" / class="thai" / class="text-th". */
html[lang^="th"],
html[lang^="th"] body,
:lang(th),
[lang="th"],
.thai,
.text-th,
body.ctl-blog-theme .thai,
body.ctl-blog-theme .text-th {
  font-family: var(--ctl-font-th) !important;
}

/* Thai headings inside Thai content */
html[lang^="th"] body.ctl-blog-theme h1,
html[lang^="th"] body.ctl-blog-theme h2,
html[lang^="th"] body.ctl-blog-theme h3,
html[lang^="th"] body.ctl-blog-theme h4,
html[lang^="th"] body.ctl-blog-theme h5,
html[lang^="th"] body.ctl-blog-theme h6,
body.ctl-blog-theme :lang(th) h1,
body.ctl-blog-theme :lang(th) h2,
body.ctl-blog-theme :lang(th) h3,
body.ctl-blog-theme :lang(th) h4,
body.ctl-blog-theme :lang(th) h5,
body.ctl-blog-theme :lang(th) h6,
body.ctl-blog-theme .thai h1,
body.ctl-blog-theme .thai h2,
body.ctl-blog-theme .thai h3,
body.ctl-blog-theme .thai h4,
body.ctl-blog-theme .thai h5,
body.ctl-blog-theme .thai h6 {
  font-family: var(--ctl-font-th) !important;
}

/* Keep Thai article body readable when mixed with English UI. */
body.ctl-blog-theme .single-blog-content :lang(th),
body.ctl-blog-theme .blog-card-body :lang(th),
body.ctl-blog-theme .blog-featured-copy :lang(th) {
  font-family: var(--ctl-font-th) !important;
}
