People protest the Wisconsin legislature's lame-duck session during the official Christmas tree lighting ceremony at the state capitol in Madison on Tuesday. (Mark Hoffman/Milwaukee Journal-Sentinel/AP)
Ari Melber, an attorney, is MSNBC's chief legal correspondent and host of "The Beat with Ari Melber."

Our nation is reeling from sustained, public attacks on the rule of law. Voters are openly encouraged to question the legitimacy of elections. And a prerequisite for any democracy — the peaceful transfer of power — is in doubt.

These problems are hitting a fever pitch in the United States, and not because of President Trump. The culprits are Republican politicians in Wisconsin, where the GOP just lost races for governor and attorney general.

Republican lawmakers reacted to their defeat by pushing unusual laws to dilute the authority of the offices their party lost. The effort is brazen: use the dwindling powers of a lame-duck legislative session to sabotage the people taking over.

This is not normal. It is not part of a “cycle of partisan warfare.” It is not “another round” of political payback that pundits can debate through the narrow lens of clever strategy. It is antithetical to democracy.

Worse, the maneuvers playing out in Wisconsin are more consequential than a single state's local politics. We are witnessing a blatant ploy to undercut a core premise of our constitutional democracy — that the people (and party) leaving office have an obligation to transfer their powers peacefully and professionally. Period.

Wisconsin Republicans are not staging a physical coup. But there is more than one way to steal power. They are exploiting the democratic legislative process to attack democracy itself.

Some defenders argue that the legislature has the technical power to reform the offices in question, and to limit their future actions. That may be technically accurate, but it misses the point. Of course a legislature has powers to decide how the government operates. The issue is whether explicitly legislating to undermine election results is an abuse of those powers.

The playbook in Wisconsin echoes the North Carolina GOP, which called a “special session” after losing the 2016 governor’s race for the purpose of sabotaging the incoming Democratic governor. Republicans eliminated 75 percent of the posts the governor could appoint, added a partisan category to judicial races and limited voting access, among other things.

Such efforts to impede voting are not restricted to post-election payback; they are now a common feature of GOP state platforms. This tactic animated huge political and legal brawls in North Carolina and Wisconsin, long before Republicans lost ground in those states.

Are these ploys even legal?

It depends. Courts do defer to many decisions reached by state legislatures. Courts also have a rule against taking cases that would turn them into a forum to “break ties” on controversies that are essentially political questions. (It’s literally called the “Political Question Doctrine.”)

On the other hand, there are also clear precedents that courts do have an obligation to intervene when one branch is abusing its power to thwart the functioning of democracy itself. That precedent enabled courts to step in and trim some of the extremes in North Carolina. It may ultimately be applied to beat back some of these new actions in Wisconsin.

The courts have also, over time, thwarted other GOP attacks on democracy in some of these same states. Apart from these efforts to kneecap a political office on the way out, Republicans in Wisconsin and North Carolina also deployed gerrymandering to rig and undercut the outcomes of their elections.

More Wisconsin voters backed Democrats in their state assembly races last month, but Republicans were still able to “win” control of 64 percent of the district seats. North Carolina’s congressional gerrymandering was so extreme, meanwhile, its 2011 maps were thrown out by the courts as unconstitutional discrimination.

So the courts are a partial backstop. It would be a mistake, however, to count solely on the courts, waiting to see which moves are so extreme that judges declare them illegal. That posture only rewards the more shameless politicians, who are willing to cross lines to test which attacks on democracy are so brazen that judges rein them in.

As a practical matter, not every democratic norm is accompanied by a legal chaperone. Some of our most vital ideas about modern democracy are not even in the Constitution, such as the now-widely accepted belief that each citizen deserves a vote, or that you win an election by winning more votes. (The second idea has come to define majority rule but is not a requirement in the electoral college.)

Today’s schemes to dilute an office before handing it to the opposing party or deploy computer modeling to make voting districts as undemocratic as possible may use tricks that the Founders did not specifically anticipate. They are animated by a temptation, however, that the Constitution does try to combat: the tendency of politicians to put their own power above the public interest, and for factions to treat government as a tool of aggrandizement.

Legal scholars such as Mark Tushnet and Jack Balkin call this kind of power grab “constitutional hardball.” Balkin argues that the disruptive nature of these ploys are the whole point — they feature politicians stoking fights that are “high-stakes and designed to alter the existing order’s power relations.”

If you put ethics and democratic norms to the side, perhaps it is not surprising that a party that struggles to achieve national electoral majorities — Republicans won fewer votes than Democrats in six of the past seven presidential races — is the party pushing risky confrontations to cement power that cannot be won at the ballot box. To protect democracy over the long term, that kind of approach must not only lose in the courts and in public opinion. It must also be punished by judges and voters so aggressively that it is no longer considered a legitimate option in the first place.