Senate Majority Leader Mitch McConnell and the Republican establishment had a terrible day on Tuesday. First, Senate Republicans’ latest effort to repeal and replace the Affordable Care Act was shelved. Then Republican Sen. Bob Corker of Tennessee announced he wouldn’t run for re-election in 2018. And finally, on Tuesday night, ex-Alabama Supreme Court Chief Justice Roy Moore defeated McConnell-endorsed Sen. Luther Strange in Alabama’s Republican Senate runoff.

None of these outcomes were particularly surprising, yet all three point in the same direction: The GOP establishment finds itself in a particularly uncertain moment — in control of all three branches of government but unable to get anything done or control the forces that helped elect President Trump.

While it’s true that Trump also endorsed Strange, it’s best to look at the race as a referendum on McConnell and the establishment in general. Moore made an issue of Strange’s appointment to the seat by then-Gov. Robert Bentley, who had to resign his post after a sex scandal. Moore argued that McConnell needed to be replaced as majority leader and that Trump was disconnected from the base that elected him. Voters indicated that McConnell’s backing made them less likely to cast a ballot for Strange.

Trump, who has had several run-ins with McConnell, is still well liked by Republican voters. National polls show his approval rating with Republicans at around 80 percent. Polls of Alabama Republicans showed something similar. Despite Trump’s endorsement, Strange was defeated. Why?

Moore won, in large part, because he was the more Trumpian candidate in this race. Like Trump, Moore has a history of taking on the establishment; he ran against an incumbent Republican governor in 2006, for example. Moore also has a history of making controversial and racially tinged statements, and he was backed by a number of the most pro-Trump elements of the Republican Party, including Steve Bannon and Sarah Palin.

Trump made a last-minute campaign stop in Alabama on Friday, which provided some hope for Strange — perhaps the president’s personal touch could move the race in Strange’s direction. But if anything, it seemed to move voters in Moore’s direction. Some voters may have felt that Trump gave them permission to pull the lever for Moore when he said he may have “made a mistake” in endorsing the senator. Polls showed that despite Trump backing his opponent, Moore generally polled best among those who approved most of Trump.

Strange’s defeat and Corker’s departure earlier in the day were just the latest signs that more mainstream conservatives have a problem among Republican voters. Of course, Trump won the GOP nomination last year despite resistance from many elected Republicans. But even before that, a number of high-profile Republicans were either defeated in primaries, like former House Majority Leader Eric Cantor, or came close to being defeated, like Corker’s colleague from Tennessee, Sen. Lamar Alexander. Polls showed that Corker himself might have run into trouble in a 2018 primary. Trump had called out Corker on Twitter, and Trump-friendly voters may have taken him out as they did Strange on Tuesday. It could be really bad for McConnell and Senate Republicans if other Republican senators see what happened to Strange and that kicks off a wave of retirements.

The question for Alabama now, though, is whether the pro-Trump forces that still represent a majority among Republicans also represent a majority among voters at large. Moore is the Republican nominee, but he still needs to win the general election against Democrat and former U.S. Attorney Doug Jones in December. Alabama is, of course, a very red state. Trump won it by 28 percentage points against Hillary Clinton in 2016, and no Democrat has won a Senate race in the state since 1992.

Still, Democrats are probably hoping that Moore’s candidacy gives Jones a chance. They can point to polling that has, at times, found Moore with only a single-digit lead over Jones. Additionally, Moore won his last statewide election in 2012 for the state supreme court by less than 4 percentage points, even as Republican Mitt Romney was winning over Democrat Barack Obama by over 20 points. Don’t be surprised if Jones receives a fundraising boost from Democrats nationwide looking to beat Trump, and expect some Democrats with potential presidential aspirations, like Joe Biden, to campaign for Jones in the fall.

But let’s not mince words: Alabama is solid GOP territory. Moore’s victory on Tuesday puts him on the verge of winning a U.S. Senate seat. Not bad for a guy who got defeated in two previous Republican primaries for governor. Moore’s win, along with Graham-Cassidy’s defeat and Corker’s retirement, just shows how weak the Republican establishment is right now.