The other side to that is that people in tech who know they're good come to the Valley because they can get 2-5x the pay. It doesn't hurt that California is beautiful and has a lot of other nice qualities (weather, being the epicenter of the tech scene, close to the ocean and the mountains). Sure, it's true that we don't have a monopoly on good engineers, but for many, once they realize that they're undervalued in their current position (so, a "good deal" for companies), they might try to get a huge raise, get denied, then move to the valley. That's generally how it works, and it works pretty well. Despite the stupidly high cost of living and salaries, companies in the valley still manage to do alright. For employees, layoffs at one company aren't really a problem, since every other company is always hiring. It only becomes a problem when the whole sector is in trouble, which we haven't seen in a while. Hopefully things are diversified enough by now that e.g. AdTech failing wouldn't mean layoffs like the dot-com bust. Given how many areas rely on technology and the internet these days, I see another dot-com bust as decreasingly likely -- not that it couldn't happen, but I think it's more tied to the overall economy vs one sector in the corner. If biotech runs into trouble, VR/AR probably wouldn't be affected much. If payment tech gets disrupted, silicon design shouldn't dip much, etc etc.
Your first point rings extremely true from my own experience. It's of course the case that there are bright, talented, and experienced engineers in places other than the Bay Area, but it's hard to counter the brain drain that occurs. The best engineers who remain become comparatively rarer and so it becomes progressively more difficult to build a team of seasoned engineers as opposed to having a single veteran try and mentor six or seven inexperienced coworkers.
And in that scenario, you're extremely vulnerable to that senior employee getting burnt out from spending most of their time doing code reviews and putting out fires rather than building things themselves. You're also vulnerable to that person getting an enticing offer from a big-name company in the valley or an exciting-sounding startup in SF. Many of these opportunities are even remote, so this can happen even when your best employees don't have any desire to move.
So yeah, it's possible to find good talent in other locales. But there's a lot more competition for that talent, it's hard to build a critical mass of it when the best employees are constantly moving away, and there are a ton of challenges you have to deal with as a result.