Two thoughts.
First, I'm currently in the process of remodeling my basement. And, it's quite expensive. What I'm spending on remodeling 1500 square feet is approximately the cost of 5 inexpensive cars. Although some of these costs have come from the building supplies, most of the costs have come from labor. Labor in expensive areas is more expensive.
But, then the cost of land is expensive. There are network effects. Upper-middle income people want to live around people like them. Educated people want to live around other educated people. Educated people want to live in nice climates, in places where they can go out into nature, where they can have ready access to nice shops, art galleries, clean cafes, etc. There are not enough of these types of areas to meet the demand.
Alternatively, one can buy an old house in a rust belt city for $25,000. People don't want to move there. It's cold, the people are less educated, there aren't fancy shops around, no good coffee, no hiking, no pleasant strolls around the neighborhood. There are fewer high-paying jobs.
In a rust belt city, you can build a brand new house for less than $90 a sq-ft. Sure, it won't have the nicest fixtures, but you can.
In rural areas, outside of the rust belt, you can buy an acre of land for $1000. You can build a nice place for under $100,000. But, do educated, upper-middle income people want to live there?
Some possible solutions: 1) reduce the costs of building. Services should pop up that import labor from less expensive areas. The rise of more modular housing, 3D printing of houses, etc. should lessen the costs. 2) create more areas where upper-middle income, educated people want to live. This is harder, because there needs to be jobs, first. It's a chicken/egg problem. How do you get employers to set up shop where there aren't any educated workers?