Poor pay is often a result of a downward spiral of dysfunctional/failing organization. Your manager gets paid poorly, your coworkers, other teams. Best people leave first and new good people don't want to join. Demotivated teams lacking any talent produce bad product. Poor product looses customers, which forces management into freezing/cutting salaries. Everything compounds. After certain threshold there is no way back, but it is surprising how long can organizations with no hope stick around, and just keep people miserable.
Interesting how it's easier to have talented people eat microwave ramen for a year while you're energized building something new. Once the salaries go up, then drop, you start to spiral down the drain.
Isn't the "building something new" job somewhat of a gamble though? To get in on the ground floor of something big for a bigger payday down the line? The same can't be said for a struggling company cutting salaries.