Semi-related question, but on Linux how does one get to sane font handling like on MacOS where you can basically completely forget that fonts exist? I've had so many problems getting fonts looking good on Linux that I practically gave up on the problem as it seems completely intractable.
I have stopped using MacOS many years ago, so I do not know if the font handling has improved meanwhile.
When I was still using MacOS, I have not noticed anything special about its font handling. The difference in comparison with Linux or any other free OS was that MacOS included a very good set of high quality fonts, much better than those provided by default in any Linux distribution, not that it had some special font handling. Because of that, even after I have ditched MacOS, I have kept a few of its typefaces. Even today I am still using a couple of them.
On Linux, it should be possible to obtain any complex or weird font matching behavior that might be desired, by editing the fontconfig rules, which should be located in some directory like "/etc/fonts/conf.d/", but the exact place might vary between Linux distributions. However, I have never attempted to do that, beyond establishing nice defaults or replacements for the fonts that might be specified in Web pages, e.g. "serif", "sans-serif", "Arial", "Times New Roman" and so on (i.e. by editing 60-latin.conf, 60-generic.conf, 45-latin.conf, 45-generic.conf and the like).
The main method by which I have ensured that everything is displayed with beautiful typefaces on my Linux computers has been simply by uninstalling all the default fonts and installing other nicer fonts in "/usr/share/fonts/". If you omit to uninstall some ugly font, there would always be some application or Web page that might insist to use that, despite your attempts to suggest better fonts.
Many years ago, I have bought a number of beautiful typefaces from some on-line stores like Linotype, Adobe and others, and I am using mostly those on Linux. Nowadays it is much easier to replace the default fonts with better ones, because, unlike a decade ago, now there are a relatively large number of good fonts that are open-source or at least free of charge.