/* ACSS Overrides — keeps the project's own design on top of Automatic.css.
   This sheet must stay AFTER "ACSS Framework" in the stylesheet list (it is, by creation order).
   Each rule mirrors an ACSS element-level rule with the same specificity and restores the
   pre-ACSS value (our Base value, or revert-layer = the Etch reset/UA value). Classes still win.
   Project tokens live in the :root:root styles (Colors/Typography/Spacing/Layout), which outrank ACSS's :root. */
:root:root {
  --root-font-size: 100%; /* ACSS is set to 62.5% (10px rem); this site's rem values are authored for 16px */
}
:where(body) { overflow-x: revert-layer; text-wrap: revert-layer; transition: revert-layer; }
:where(p) { line-height: inherit; }
body a:where(:not([class*=btn--])) { color: inherit; font-weight: revert-layer; text-decoration: revert-layer; text-underline-offset: revert-layer; transition: revert-layer; }
body a:where(:not([class*=btn--])):hover { color: inherit; }
h1, h2, h3, h4, h5, h6 {
  font-family: var(--heading-font-family);
  font-weight: var(--heading-font-weight);
  line-height: var(--heading-line-height);
  color: inherit;
  text-wrap: balance;
  max-width: revert-layer;
}
h1 { font-size: var(--h1); }
h2 { font-size: var(--h2); }
h3 { font-size: var(--h3); }
h4 { font-size: var(--h4); }
h5, h6 { font-size: revert-layer; }
img { object-fit: revert-layer; object-position: revert-layer; }
:where(section:not(section section)) { padding-block: revert-layer; padding-inline: revert-layer; gap: normal; }
:where(section:not(section section)) > :where(div, ul, ol) { gap: normal; }
:where(body > header), :where(body > footer) { padding-block: revert-layer; padding-inline: revert-layer; }

/* Canvas/body: ACSS sets body{min-block-size:100svh} unlayered; revert to the Etch layered value (reset 100svh on front end, unset in canvas) */
body { min-block-size: revert-layer; }

/* Explicit body rule: ACSS 4 sets body font-size/line-height only in zero-specificity :where(body); pin our values (same as Base). */
body { font-size: var(--text-m); line-height: var(--text-line-height); }

/* Source per-language one-offs (published routes set html lang: th / en-US). */
/* TH only: showcase "Rehabilitation" word is 3vw between 992 and 1280px (source #headline-588 TH). */
@media (992px <= width <= 1280px) {
  :lang(th) #physiotherapy .showcase__word { font-size: 3vw; }
}
/* EN only: review slides 02+ keep 45vw numbers below 992px (source headline-610-15/860-232/875-232). */
@media (width < 992px) {
  :lang(en) .review-slide + .review-slide .review-slide__number { font-size: 45vw; }
}
