Large scale democracies only work when people are willing to live together. If you play democracy as a winner-take-all game, it's going to fail sooner or later.
I'm not convinced that anything works at the national scale, at least not over the long term. I suspect that the US, as one of the oldest-and-largest democracies, is demonstrating a path that others will eventually follow.
The American founding fathers were mostly of the opinion that political parties are bad and should be avoided if republic is to stand. Yet they found themselves organizing into parties before the ink was dry.
So the best we can do in practice is engineer the political system such that the damage from party groupthink is minimal.
I'm not sure as to solutions but I don't think they're impossible - something like an inoculation of the entire political class against the memeset that prioritizes winning over serving the constituents. Then if an unofficial party tries to seize power in a system that officially disallows them, the majority is already primed to respond in an organized way.