I came up with an entire language system for D&D with the goals of making it so everyone doesn't speak Common, there is interesting linguistic diversity, and yet PCs who want to can reasonably expect to learn enough languages to get a lot of use out of them. Note that this is a multiverse campaign where we visit various worlds and planes, so it has to encompass all of D&D (2e lore at least).
1) Common tongues (of which "Common" is the best known) are simplified trade tongues spoken as a second language by (typically) travelers, innkeepers, merchants, and aristocrats. So in most places you actually can speak to the people you have to to get quests and accomodations, but if you don't speak the regional tongue, you'll have a hard time communicating with most people. Common tongues are typically based on an original or "high" tongue, which is a regional language. If you speak it you can understand Common.
2) There are species tongues, and for functionality I rarely make dialects of them significant. I keep linguistic diversity as primarily a human feature. Non-humans typically speak the Common tongue under the same situation as humans. So those goblin leaders speak Common, but the villagers and most warriors probably don't.
3) There are, in the multiverse, many root tongues. For example, there are about 23 human root tongues. There are also planar species root tongues (Aasimon is the root tongue of angels, and Celestial is its Common variety, also known as Upper Planar Trade), and mortal species root tongues (Elvish, etc).
3) "Variants" are what I call basically the same root language with a different name and accent. So the root "high" language that Common is based on in Faerun is Chondathan, which is basically the same language as Ergot from Krynn and Oeridian from Oerth, which is also Planar, the language of Sigil and environs, and is typically known to multiverse scholars as Imperial, due to often arising from the most recent empire on a world.
4) Root tongues also have what I call "dialects" which are basically slightly different languages that aren't initially mutually intellgible, but can be picked up much easier than learning a new language (and in my system, without using character build resources).
5) Root tongues typically have multiversal origins, and are spoken in many worlds, even if not directly related to those sources. So, the root language of the Norse pantheon is Asgardian, and most Norse-inspired cultures speak a variant or dialect of it, even if the Norse pantheon isn't known on their world. In Faerun, Illuskan is a variant of Asgardian. I leaned into making most languages variants so they could be more easily understood, but some worlds more heavy on dialects. For example Krynn has some really weird mix and match real world inspirations, so I used dialects heavily, and communication traditionally was supposed to be difficult in Ravenloft so most (maybe all) of their human tongues ended up being dialects.
6) There are also root tongues for certain kinds of species, like an Avian tongue, of which the languages of most bird-people are dialects of. Going through a giant list of monsters and species from 2e, I assigned every language as either a variant, dialect, or its own root. Due to the diversity of monsters, I ended up with over 200 roots, even though I tried to minimize them.
7) For many of the more widespread languages I expanded them a bit from 5e standards, without going all the way into the old "everything speaks its own language" explosion. So, there is a High Draconic spoken by true dragons, and Low Draconic spoken by lizardfolk and kobolds, and all those other species listed as speaking Draconic. There is also a Giant typically spoken mostly by true giants, and a Giantish spoken by ogres and other giant-like species.
8) I made heavy use of previous edition lore regarding the human languages spoken in different settings, and fit it into this scheme of variants and dialects of the 23 human root languages.
9) I also made various aphabets and assigned a most frequently used one to each root language, though variants and dialects could use different ones. At the start of the main campaign, the characters were all magically brought together from different worlds and found they could speak the same Common tongue, but the Forgotten Realms version was written in a different alphabet, because Chondathan is written in the Thorass script (which is known as Tuathan in the multiverse, and is the alphabet the Celtic pantheon uses), while the Imperial/Common script is the Damaran script.
10) I did a good deal of real world research when designing human root tongues and dialects but didn't feel any need to be accurate when it worked better not to be. It's a fantasy multiverse and research was inspiration.
The payoff for all of this is that wherever we go and whatever we meet in the multiverse, I know what languages they speak, what script it is written in (if any) and know who in the party can speak or read it, and how easy they can figure it out and pick it up if they want to. Yes, this has been an enormous amount of work that wouldn't be worth it for the more story-focused style that is currently popular. It makes more sense from the exploration-focused style of D&D I prefer.