what's probably a little more useful is that headings scale up slower than body text, using different clamp() functions, e.g., https://www.aleksandrhovhannisyan.com/blog/fluid-type-scale-...
Ideally what I want in an accessibility-settings dialog is "minimum font size that I can comfortably read", and a way for UI authors to say "this is normal body text".
Instead what we tend to get is blanket advice like Android's "use sp dimensions for text", which simply scales everything up.
iOS's preferredFontFor textStyle stuff seems like the right approach in principle, but they still seem to have the idea that if I want large body text I must also want huge headings (which is terrible, because if I have large body text I also have less space than usual).
(Or, ideally, "make small text and fiddly diagrams bigger, but leave most images alone", but let's walk before we try to run.)
So maybe "rems for body text, px for headings" is the way to go.