/* Shared by the application and standalone pilgrim documents.
 * Keep this unlayered: page-level font-medium/font-semibold utilities must not
 * make main headings lighter. Only weight changes; theme, size, font family
 * and accessibility spacing keep their existing rules. */
:root :is(h1, h2, [role="heading"][aria-level="1"], [role="heading"][aria-level="2"]) {
  font-weight: 700;
  /* Retain deliberately heavier Tailwind or display headings. */
  font-weight: max(700, var(--tw-font-weight, 700), var(--heading-weight, 700));
}

/* Card/dialog typography also styles spans. Heading copy, including translated
 * text and emphasized words, must keep the heading's weight instead of 450. */
:root
  :is(h1, h2, [role="heading"][aria-level="1"], [role="heading"][aria-level="2"])
  :where(span, em, strong, b, i, a):not(:where(.font-extrabold, .font-black, .heading-3d-gold)) {
  font-weight: inherit;
}
