> Seniority, bonuses, equity vesting, resume damage
Relatively minor. Most senior people I know who leave with bad blood end up with equally senior roles, and often "fail upwards" to even more senior roles in another company.
Bonuses/Vesting: Very common to get good vesting at a new company to make up for what you're losing. Of the people I know who've moved, it's the exception that didn't get decent replacement for vesting.
Resume damage: What? Person spent 4 years at a company and left. What resume damage? Your experience still counts.
Contrast with a PhD who leaves in the middle of a program: The years he spent are 0. Generally, the experience/knowledge accumulated is not factored into it when he applies elsewhere for a PhD - unless he has some fantastic publication.
Still, this is the good outcome - I've often seen students leave an advisor or school and succeed elsewhere. The real danger is when you get your PhD and the advisor will not write letters of recommendation. Unless you've made some really special connections, it means your academic career is over. You won't get a post doc. You won't get an academic position. You won't get into a national lab. And depending on your field, you won't get a research position in industry either.
In the industry, no boss has that power.