Preface
1 - Defining the Dungeon
1.2 - Dungeons in Real Life
Breaking my, well, break to say I've been doing a preliminary research on dungon layouts. There's a lot of different types depending on the game, some simulate roguelike combat while others prioritize story.
Maps such as those of Barony, 2d roguelikes like Cogmind owe their structures to procedural generation of rooms and maps. These maps work well for their combat focus and have many rooms connect to each other with hallways and many larger halls where multiple rooms and hallways connect into.
In conversation with my friend, he mentioned Undertale as a possible source of inspiration. Looking at that gave me an extremely different result. Undertale's map building is more linear, one where prioritization of going from one point to the other is key. This linearity lends itself to the progression of the story as well, as you encounter characters the deeper you go into the map, barely needing to turn back. The incentive to move forward is the story, not the exit, in this case.
This sort of cavernous, non-"square" type of dungeon is the Caeldippo Caves of Children of Morta. The sprawling, organic, tendril-like structures branch into stories and little nook-and-cranny shops. It is a great contrast point ot the first type's more square, less maze-like structure, and also into Undertale's more linear "dungeon." Children of Morta mixes environmental story telling and cutscenes amazingly, and it lends it to the structure of its dungeons. While dead ends exist in the first category, you are likely to find a pathway back to a major connecting area.
Finally, I looked into real life dungeons. Dungeons are not a big part of my culture, and so I dug a little bit into real dungeon layouts found on google. One dungeon that appeared is apparently the world's largest dungeon, Church of the Holy Sepulchre, whose layout is composed of many rooms and hallways similar to the first category. I do not deny that I believe more cavernous dungeons exist given that caverns may literally be fashioned into dungeons.

Through my time then and now I have redefined my idea of "dungeon design." It feels reductive for me to call it dungeon design when dungeons are just part of what I want to make, and a few of the references I talked about in the preface might not even technically be a dungeon. In that regard, I would call to define it differently for the purposes of this book, "dungeon" means 2D top down RPG level, ones that can be seen in classic 2000s indie japanese horror RPGs, to Ragnarok Online, and to rogulike games, whose main goal is to go from one point to the other and move on to the next level. This scope is to give more way for the analyses of these structures and how they feel for the players instead of being limited into the genre.
Dungeons in this regard would focus heavily on the second aspect of the definition.
However, what have you noticed on all the examples in the preface? Caves, mines, these are not actual dungeons in terms of architetcture. In fact, only the church is close to the original meaning of it being the basement of a castle. In essence, I can remove the term "dungeon" and replace it heuristically with "RPG level." And at the same time, I can attempt to deconstruct the term through analyzing DnD, Tolkein, western fantasy, medieval romanticism and their roles in the continuous reification of racial biases, cultural darwinism, and the like.
HOWEVER, I will not do that now as what I am making is a classical dungeon and I am not yet going to add another layer of deconstruction, nor dive into a thesis level analysis of this aspect of game design. Instead, I will dive into the definition of dungeon itself and not zoom in too much at this moment.
A prelimenary online search yields a description I really liked: a "dungeon" in gaming as a "catch-all phrase for a complex of rooms" (from quora.) This expands the dungeon into anything with complex rooms. A space-ship, a manor, mall, a temple. However, this still does not answer my puzzlement with how and why this came to be, neither does it give me solace for using that term in my own game development practice.
Wikipedia article on dungeons:
Dungeons as folklore, as metaphors for fear, imprisonment, and power
Dungeons in DnD and other popular media Based off of this, dungeons as metaphors for fears of silence, overwhelming power, slow death, and torture.