Visiting Vienna some time ago was the first time when I realized that if I ever were to move to another city from the one I'm currently living in (a capital city in Eastern Europe) that city would need to have a decent tramway network, just like Vienna does (trolley-buses also count).
Relying only on cars or Diesel-hungry buses for carrying people around a big city is barbarous. It also counts that I don't like taking the metro, as traveling 45 minutes - 1 hour per day underground doesn't fit my idea of "good travel".
For non-European cities, Seoul is one of my favorites. Extremely extensive subway, though admittedly during rush hour, it's positively insane. But you never have to walk more that 200 meters to get anywhere it seems.
You could buy quite a few solar panels and lease several electric cars for less than it would take to move to NYC.
Manhattan, San Francisco, and Boston aren't where they are because of random chance.
Good harbors used to create economic powerhouses and centers of immigration, which in turn created large dense cities. The sort of large dense cities that people naturally chose to build when unregulated but that modern policies prohibit (or at least pose obstacles to) in places that are not yet that dense.
Similarly, NY and Boston are situated on and partly limited by major rivers, which provided access to the interior in a time when travel by boat was much faster than over land. You'll find the same is the case for almost every major non-coastal city in the US and worldwide. That was less of an issue for SF, which grew in the railroad era.
There are of course many obstacles to attracting people to a NEW city. But specific types of geography that happen to typically be limited by water are no longer crucial to making a city dense. Access to ocean shipping is helpful, but it's now viable to import and export over land to and from a harbor town.
Edited to add: Boston isn't really a peninsula. The reason these cities are dense is largely about developing prior to the car. LA could be nearly as dense as Boston if it weren't so car-dependent. If it had become a major population center prior to the advent of the car it would have had to be by necessity.
People built dense because of limits on how far one could realistically travel on foot or by equine-powered means. That limited the size of a city far more effectively in Boston than geography did (this is also reflected to a degree in LA's older downtown).
New York was able to grow beyond downtown and midtown Manhattan largely because of rapid transit (elevated rail later displaced in favor of subways) but even that has limits that kept the city dense. (One of those limits of course being that it was less likely to get built in areas that weren't yet at least somewhat dense.)
Think how long it would take to ride from an outer LA suburb to its downtown in a mule cart. That density-enforcing function doesn't apply to the same degree when you have an automobile.
BUT there are limits on how long people are willing to travel to get places, be it by foot or by car. Even in LA, we're reaching the limits of car-enabled sprawl.
Neither of which is nearly as good for the environment as simply using less energy. Solar panels and electric vehicles take a lot of energy to make, and are not guarenteed to become carbon neutral during their usable life.
You could be very picky about sourcing food, and put the farmers using cheap but unsustainable methods out of business. Pay the premium for American-made products under American factory emissions regulations, to shut down some cargo ships and Chinese smokestacks. Every 5th American could be a $96k/yr researcher working on environmental problems, etc. We could all telecommute, and have our pay docked by $24k/year to compensate for the lost productivity.
Some increase in per-square-foot prices are natural and expected, just due to right-sizing the environmental costs and benefits, but the very high prices are insane and fixable.
Your "reasonable" housing costs are still double the price for half the space.
A lot of Americans just don't have an extra $1,000/month sitting around to throw towards rent. Even if they ditch their car, they'd still be $800/month short.
To be sure, there are $3000 1-bedroom apartments around as well.
My old Dad was in the Korean War. The soldiers said then that probably everybody would eat in 'mess halls' in the future, because it made so much sense. Of course these were farm kids seeing such things for the first time.
Building codes should reflect proper sound insulation, windows opening up on to areas with clean air (and no exhausts anywhere near), even greenery (possibly an in door garden / atrium).
* something resembling affordable (though it still ain't cheap)
* not auto-dependent.
Maybe you're just surrounding yourself with people who have expressed a preference for low density via their actions?