If I want a bus or a train to be right in front of my house any time I need one and I also want that bus/train to drive me exactly where I want to go, obviously the cost will be ridiculously high.
You are likely trying to compare the USA car-centric suburbs and frankly that choice makes distances larger but that’s life. USA has a tremendous disadvantage due to the car-centric nature.
Yet even that can be changed, it will be costly, but there is no technical issue. It is all about politics. As long as taking a bus is seen as for “poor people” it will be an uphill battle.
If you need some biking or walking just to reach public transport, then wait, then travel through the network then there is always a level of inconvenience that you may not face if you use individual private transport instead.
Even in Europe most people live is suburbs. Even if they are not car-centric (and they are in most cases) that increases inconvenience and cost of public transport.
Only if you assume that individual private transport can get you door-to-door. Which is a rather unfair comparison. "cars are better because unlike public transport, you can drive up to basically any building and park there" is only true if you build roads and parkings to basically every building.
I did mention the caveat that sometimes private transport (which includes bikes) may be inconvenient. That includes issues with parking space.
I'd argue that making private transport very impractical is not the same as making public transport "so good it becomes the first choice"... it's making private transport bad enough that it becomes more inconvenient than public transport...
Being able to get places with cars requires a lot of things: roads, parking, traffic measures (signs, crossings, stoplights, onways, offramps, freeways, more parking at destination, etc etc etc). If you only build for public transport, bikes, and walking, the savings in both space used and money spent become ridiculous.
Basically: the world looks a lot different without every building having a huge car park. In my view: a lot better.