Oh, I could write novels on this.
Best advice: Just don't give a shit. Seriously, be above the people you're dealing with and just not care what happens in the moment. Your goal is to play the long game and be the only one that can see the big picture. Most people are reactionary, and if you can get past that, you can control the situation and ultimately the outcome.
Just as an example, my supervisor was a huge dick. He'd make work hell for everybody, dole out the worst jobs to those he hated, and generally not do a lick of work himself. He was the type of guy that treated the real world like high school and even had his own little clique of cool kids that would make fun of everyone else. It was like Mean Girls every time you went to work, so I figured that if I couldn't beat them, I'd join them. And then beat them. Long story short, I took a lot of shit from him for a few months and did everything necessary to make myself invaluable in both a work-related sense as well as informational. I knew just about everything that went on in that place, so I'd feed key bits of information about people he disliked to him that would piss him off. This guy had a short fuse and I knew I could get him to explode if I just kept at it. So for ten months I played the part of his buddy, all the while helping knock off parts of his clique by sowing general seeds of dissent (telling them someone newer was being paid more, that another worker was getting overtime while their hours were cut, or a group of us shouldn't show up on a certain day to prove how much they need us (t'was my day off), and a whole lot more that requires weeks or months of context) until almost all had either quit or been fired. I acted like I hated the job and was with him until the end, all the while knowing he was one final push away from blowing up, and then finally it happened. He said the stresses of the job over the past year had gotten too much to handle, and with only me being left as someone he could trust, he just couldn't take it anymore and quit. It wasn't as glorious of a sendoff as I'd hoped, but seeing him broken down to practically giving up after starting off as the domineering asshole put a smile on my face.
Everybody there still thinks all of this happened organically, but I'm directly responsible for at least three people leaving that job.