The Old Ones build continent-sized bunker complexes to protect themselves from the enemy, which followed through the cosmic ocean. The Hunter succeeded easily despite their efforts and their corpses were entombed in the deepest vaults by their corrupted servants, so their masters may continue to dream in death. The vaults were later settled and expanded by the Dwarfs, yet their empires were destroyed as well. Now only the stupid, greedy and desperate enter the Underdark.
The bunkers are all roughly funnel-shaped cave systems, with radii between 500 and 1000 kilometers. Their ceilings have been waterproofed, yet they have become leaky over the last seven million years. While the magical superstructure is quite strong, continental drift and earthquakes have taken their toll. The water which flows together at the bottom of every bunker, where it is dispersed back to the surface via teleportation. The Underdark only begins at a depth of one to three kilometers. It is separated from the upper-world. Only few, mostly dwarven access shafts lead down. Underdark dwellers are adapted to the atmosphere down there. Upperworlders can handle it as well, but need acclimatization and can't handle it in the long run.
The Underdark has forests of gigantic, phosphorescent mushrooms, whose light is so weak that surface dwellers must spend at least a day in total darkness to see it. Dwellers of the depths can use it almost as well as daylight. Normal mushrooms are quite diverse down there. The Dwarfs use many species to get food, fibers, leather, and wood. Many species in the Underdark are phosphorescent, providing at least some light in habitable regions. Where the old Dwarfs installed sunstones, woods of ferns dominate. The significantly higher concentration of carbon dioxide in the local air helps them a great deal. The seas and lakes have matts of chemosynthetic, endemic species. They use methane, hydrogen sulfite and ammonia, which are significantly more common in the Underdark. Nutrients are provided by the water, which flows into the underground. All these plants provide food for the horrific beasts of the world below and the Tiefling, Mindflayer and Dwarf-civilisations down there.
While such undergrounds aren't uncommon in fantasy, I want to ground this thing in reality. I think that the Movile Cave makes a good blueprint for such an ecosystem.
The air in the cave is very different from the outer atmosphere. The level of oxygen is only a third to half of the concentration found in open air (7–10% O2 in the cave atmosphere, compared to 21% O2 in air), and about one hundred times more carbon dioxide (2–3.5% CO2 in the cave atmosphere, versus 0.03% CO2 in air). It also contains 1–2% methane (CH4) and both the air and waters of the cave contain high concentrations of hydrogen sulfide (H2S) and ammonia (NH3). The cave is known to contain 48 species, among them leeches, spiders and a water scorpion. Of these, 33 are endemic. The food chain is based on chemosynthesis in the form of methane- and sulfur-oxidizing bacteria, which in turn release nutrients for fungi and other bacteria. This forms microbial mats on the cave walls and the surface of lakes and ponds which are grazed on by some of the animals. The grazers are then preyed on by predatory species. Nepa anophthalma is the only known cave-adapted water scorpion in the world. While animals have lived in the cave for 5.5 million years, not all of them arrived simultaneously. The most recent animal recorded is the cave's only species of snail, which has inhabited the cave for slightly more than 2 million years.
Is the Underdarks ecosystem plausible, given the existence of the Movile Caves one? The Underdark would probably have a bit less CO2 and more oxygen, due to the existence of the fern forests and slightly better ventilation. Would decomposition be enough to explain the ammonia, methane and hydrogen sulfite or are other sources required? Why is phosphorescence so widespread, dspite it being a waste of energy at first glance?