While I can't prove it, I always thought this change is because of the proliferation of many different types of battery power tools nowadays (drill, jigsaw, circular saw, light, impact drill, saber saw, vacuum cleaner etc.).
Back when battery power tools were basically just drills, the neck type batteries fitted them well because the handle would hold some extra battery cells. Other tools may not have well suitable handle for such a battery, while the cuboid format is pretty universal for attaching to tools.
Apart from that: if you can't get a suitable replacement battery, you can still:
For example, I used a broken spare battery pack for my Milwaukee 28 V tools to "add a cord" to them. This allows me to power them directly off 2×12 V car batteries while living off the grid, and for much longer than with mobile battery packs.