In an astounding upset, Democrat Doug Jones defeated Republican Roy Moore in the Alabama special election to the U.S. Senate. It was the seat that Attorney General Jeff Sessions won in 2014 running unopposed with over 97 percent of the vote — and a state President Trump won by nearly 28 points.

That they could bobble perhaps the easiest lay-up election imaginable testifies to the profound political and intellectual rot that is consuming the GOP, and the political difficulties they are facing in trying to govern in a democracy.

Contrast the modern Republican Party, which enjoys a highly unusual level of political dominance, with that of the Democratic Party of the mid-1930s, which was even more dominant. The Democrats of Franklin D. Roosevelt's day had their share of problems (most notably having to rely on racist conservative Dixiecrats as part of the coalition) but fundamentally, the New Deal Democrats were a functioning political party. They catered to a large majority of the population and their policies did redound to the benefit of that population, creating enthusiastic support for the party.

Modern Republicans, by contrast, are barely even pretending that their policies are going to be widely popular and successful. Speaker of the House Paul Ryan and Senate Majority Leader Mitch McConnell occasionally produce some half-hearted lies about turbocharged economic growth, but their words are belied by their actions. In both the failed attempt at ObamaCare repeal and the tax bill that is on the verge of passage, Republicans have made a mockery of legislative procedure — holding almost no hearings or markups, and in the case of the tax bill, literally scribbling in the margins of the draft in the middle of the night. They are doing this because those bills are wildly unpopular (indeed, they would cause untold misery and death), and they want to ram them through before the public gets wind of what's going on.

New Dealers, by contrast, had no need of making an end run around the democratic legislative process, because they weren't lying through their teeth about what their bills would do — and so did not fear the public. On the contrary, they trumpeted the benefits their new programs and reforms would provide.

It's hard to say just what is going through the brains of such pathologically dishonest people, but it seems Republicans are resting their political fortunes on some combination of: hoping bigotry and knee-jerk partisanship will preserve their support among the party base, hoping that cheating through gerrymandering and voter ID will keep liberals (especially blacks) from voting, and getting high on their own propaganda supply.

This strategy utterly failed in Alabama. Democrats, especially black ones (Jones won black women by an eye-popping 98-2, according to exit polls), surged into voting booths while Republicans stayed home.

In retrospect, this outcome almost seems predictable. Even before the accusations from multiple women that Moore had harassed and assaulted them when they were as young as 14, and he was a 30-something district attorney, he was a wildly unqualified candidate for Senate. This is a birther conspiracy theorist, a man who was removed from the Alabama Supreme Court twice for directly disobeying federal court orders, who has argued that Muslims should not be allowed to serve in Congress, has said homosexuality should be illegal, and thinks there is Sharia law in the United States.

The Republican leadership tried to keep Moore out of the general election, pushing Luther Strange instead in the primary, but the Fox News and Breitbart-crazed Republican base would have none of it, and Moore won easily. It wasn't the first time political good sense went down before base-driven lunacy.

The Republican Party is on the one hand completely at the mercy of their base of "riled-up kooks," who have been mainlining pure Fox News identity politics grievances for so long most of them have gone permanently cross-eyed, and on the other hand is busily feeding the bottom 99 percent (including nearly all of those same kooks) into the Wall Street economic wood chipper.

That fundamental contradiction is now exposed due to total GOP control of the federal government. When it comes to constantly fulminating against the first black president, when one doesn't have to actually accomplish anything, their political formula works pretty well. But what we see today is that when they are forced to actually put up candidates and govern — that is, deliver policy that improves the lives of the citizenry — Republicans are a comprehensive disaster. If they can lose in Alabama in an off-year election, it bodes very ill indeed for the party's fortunes in 2018.