JerryB, I think you are right about all of that.
You bring up the economy, and I think that it is a critical issue here. Dave Arneson published his booklet The First Fantasy Campaign in 1977 which is a mess of notes from his original (pre-D&D) Blackmoor game, the thing that inspired D&D. This was a wargame with real-world campaign seasons, with each lord having an income in GP based on land property. Somehow Arneson mined sources from prior wargames and did a bit of amateur research on financing premodern armies to come up with his figures. (He did this kind of research for other areas, such as sailing vessels.)
The dungeon under Blackmoor Castle was introduced as a surprise source of income to finance the wars (hire fighters) against the Egg of Coot, the chief “Baddie” of his multi-year campaign. I think that the scale of character advancement by level, with its link to GP earned, is connected with this wargame system. He had decided how many GP in income each village and settlement earned. He also worked out costs for each bridge, road, temple, fortress, anything a lord could want to build.
Player characters would correspondingly advance more toward a lordly level of command in charge of greater forces with GP to back them. This is the origin of the concept that GP gives access to higher levels, in my view.
To connect this back with the theme under discussion, there was thus an effort to create a “realistic” premodern economy in terms of GP. But that led to dungeon adventures. Soon enough, the dungeon adventures, with the hidden map component of the game, were abstracted from that context and its rationale, making it a game about becoming more powerful through the collection of gold, something that everybody agrees makes little sense by itself (except for those who say that GP are for training), but are willing to overlook because they like it that way. That’s why people are still writing supplements about what to do with that gold between sessions. Arneson had specific items for heroes to spend money on that would help in the war against evil, which was the origin of the campaign (and indeed the word campaign as applied to dungeon adventures).
In a way, the attempt to capture a “medieval” economy was there, in the background, but the shift to dungeoneering deprived the game of its earlier premodern pseudo-historical context even more, and I’d say made it almost irrelevant.
Records of the earliest players (1974, 1975, 1976) indicate that they frequently would run into oddities like bowling alleys, elevators and escalators, telephones, game shows, and other whimsical “modern” weirdness in the dungeons. This was not genre-busting because the genre wasn’t established. Still, this bugged people who pointed out that it was “supposed to be medieval,” as the game books said on the cover.
The term medieval was adopted because the idea was that it wasn’t Napoleonic warfare, which most Midwestern wargamers were interested in then, but an “earlier stage” of technology like that represented in The Lord of the Rings, the basis for the Chainmail rules.