/* ============================================================================
   SITE FONT — Google Fonts "Kanit" (Thai + Latin), weights 300/400/500/600/700
   Scope: the whole site (V1 and V2). Layout, sizes, weights and spacing are
   NOT touched — only the font family is replaced.
   Icon fonts (Font Awesome 6, Glyphicons, simple-line-icons …) are explicitly
   excluded so no icon turns into text.
   If Google Fonts is unreachable the stack falls back to the system Thai/
   Latin fonts below, so the page stays readable.
   ========================================================================== */

html {
  --site-font: "Kanit", "Noto Sans Thai", "Sarabun", "Segoe UI", Tahoma,
               "Helvetica Neue", Arial, sans-serif;
}

/* ---- global family (beats the inline `style="font-family:…"` on <body>) --- */
html,
body,
body *:not(i):not(.fa):not(.fas):not(.far):not(.fab):not(.fal):not(.fa-solid):not(.fa-regular):not(.fa-brands):not(.glyphicon):not([class^="icon-"]):not([class*=" icon-"]):not([class^="fa-"]):not([class*=" fa-"]) {
  font-family: var(--site-font) !important;
}

/* ---- semantic containers (kept explicit for clarity / specificity) ------- */
h1, h2, h3, h4, h5, h6,
p, li, dt, dd, blockquote, figcaption,
a, span, strong, b, em, small, label, legend,
input, select, textarea, button, optgroup, option,
table, thead, tbody, tfoot, tr, th, td,
.navbar, .nav, .nav-tabs, .nav-pills, .dropdown, .dropdown-menu, .dropdown-item,
.btn, .badge, .alert, .panel, .card, .modal, .popover, .tooltip, .breadcrumb,
.pagination, .form-control, .form-group, .input-group, .table, .list-group,
.v2-group-label, .v2-group-toggle, .v2-group-link, .v2-dd-list > li > a,
.v2-search input, .v2-langline, .v2-card, .v2-news-head, .m-slide,
.v2-hero-dots button {
  font-family: var(--site-font);
}

/* ---- icon fonts must keep their own family ------------------------------- */
.fa, .fas, .far, .fab, .fal, .fad, .fa-solid, .fa-regular, .fa-brands,
.fa::before, .fas::before, .far::before, .fab::before, .fal::before,
.fa-solid::before, .fa-regular::before, .fa-brands::before,
.fa-sharp, .fa-thin, .fa-light, .fa-duotone,
.glyphicon, .glyphicon::before,
[class^="fa-"], [class*=" fa-"],
[class^="icon-"], [class*=" icon-"],
.simple-line-icons [class^="icon-"], .simple-line-icons [class*=" icon-"] {
  font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands",
               "Font Awesome 5 Free", "Font Awesome 5 Brands",
               "FontAwesome", "Glyphicons Halflings", "simple-line-icons" !important;
}
