For indispensable reporting on the coronavirus crisis, the election, and more, subscribe to the Mother Jones Daily newsletter.

Democrats have recently brought legal challenges to gerrymanders that have locked them out of power in states from Pennsylvania to North Carolina, hoping that the courts would give them victories by striking down GOP-friendly maps. But in Maryland, progressive groups and some Democratic lawmakers see a different sort of opportunity: They can win by losing.

After Republicans were swept into power across the country in the wave election in 2010, they redrew political maps to favor their party, entrenching Republican power in Washington. Maryland, a blue state, was an exception. The Democrats who controlled the state’s government had the opportunity to make the state’s congressional delegation bluer. They targeted the state’s 6th District, a largely rural, Appalachian district bordering West Virginia, represented for nearly 20 years by a Republican.

Democrats added a strange-looking appendage to the district, reaching all the way down into the affluent Washington, DC, suburbs to scoop up Democratic voters. More than 360,000 people were moved out of the district, and nearly as many were moved in. It went from solidly Republican to reliably Democratic; the Cook Political Report identified it as the biggest district swing in the country. From then on, Maryland would send seven Democrats and just one Republican to Congress, even though the state has a sizable Republican minority and, currently, a Republican governor.

On Wednesday, the US Supreme Court will hear a legal challenge to Maryland’s 6th District. The case was brought by a handful of Republican voters in the state, but it’s being argued by a Democratic lawyer, and some left-leaning lawmakers and groups believe that a Republican victory would be the best outcome. If Maryland’s 6th District falls, Democrats would lose a reliable seat in Congress—but they could take the same legal argument that triumphed in Maryland to other states around the country where Republican-friendly gerrymanders are hamstringing Democratic success.

“This is a key moment in the fight against partisan gerrymandering, and it’s a key bipartisan moment,” Michael Li, an election law expert at the Brennan Center for Justice, told reporters on a conference call last week. “Maryland is a stark warning to Republicans. That’s a warning because it is a prime example that Democrats, where they have the levers of power, are just as tempted to gerrymander as Republicans have been.”

“This is a key moment in the fight against partisan gerrymandering, and it’s a key bipartisan moment.”

Some high-profile Republicans are urging the Supreme Court to place limits on partisan gerrymandering in this case, including current and former members of Congress, former California Gov. Arnold Schwarzenegger, and Ohio Gov. John Kasich. The bipartisan pushback against gerrymandering isn’t unique to this case: Sen. John McCain of Arizona partnered with Democratic Sen. Sheldon Whitehouse of Rhode Island to submit a brief in another partisan gerrymandering case the Supreme Court will decide this year. In that case, concerning Wisconsin’s congressional map, the two senators asked the court to limit gerrymandering, which they said “undermines our democracy.”

“As the court is considering partisan gerrymandering, you have leading officials, members, statesmen from both parties saying that partisan gerrymandering is a cancer on our democracy and the court should correct abuses by the state, such as we have in Wisconsin and now in Maryland,” says David Gans, an attorney at the liberal Constitution Accountability Center, which submitted a brief on behalf of a bipartisan group of members of Congress urging the court to rule against gerrymandering in the Maryland case. Not all Maryland Democrats are vocally cheering the fall of the 6th District, but none have filed briefs in support of the current map. Even former Democratic Gov. Martin O’Malley, who signed Maryland’s map into law, announced his support last year for nonpartisan redistricting commissions, saying that the kind of partisan gerrymandering he undertook in 2011 is not “good for our country as a whole.”

Thus far, the Supreme Court has declined to limit partisan gerrymandering. The court has long said that using race to draw district lines is unconstitutional, but it has refrained from limiting the use of party affiliation or voting behavior to shape maps, prompting states to take advantage of it. In North Carolina, after the Supreme Court struck down the state’s congressional map as an illegal racial gerrymander, the legislature drew another map equally biased to favor Republicans, but this time using partisan data to achieve the same results. A challenge to that map is currently being appealed to the Supreme Court, which has not yet decided whether to take the case.

As technology and voter data become more advanced, the ability to draw maps to permanently entrench one party in the majority is making gerrymandering more powerful than ever before. In order to take back the House of Representatives in the 2018 midterm elections this November, Democrats will need to beat Republicans by twice the nationwide margin they managed in 2006, the last time they wrested the House from Republican control. That year, they did it with a popular vote margin of less than 6 percent; in November, a new report finds, they would need to hit 11 percent. The next round of redistricting will come after the 2020 census, and if the Supreme Court doesn’t step in, the imbalance between the popular vote and congressional representation could grow even larger.

“If the Supreme Court does not get involved, it’s only going to get worse,” says Li. “That’s because the technology that enables gerrymandering is only getting better. What would have seemed like fantasy in 2011 will seem like child’s play in 2021.”

The Maryland and Wisconsin cases tackle the problem from slightly different perspectives. In the Wisconsin case, which the Supreme Court heard in the fall and will likely rule on in conjunction with the Maryland case by the end of June, the plaintiffs challenged a Republican-drawn statewide map for the state legislature. In Maryland, the plaintiffs are challenging a single district’s lines, hoping to create a new tool whereby individual districts can be challenged for disadvantaging either party. Both cases are expected to come down to the vote of swing justice Anthony Kennedy, who has expressed interest in limiting partisan gerrymandering on First Amendment grounds. As a result, plaintiffs in both cases have raised First Amendment-specific issues.

The Maryland case appears particularly crafted to appeal to Kennedy. The plaintiffs’ argument is based on a First Amendment strain of jurisprudence known as “retaliation,” which prohibits the government from punishing people based on their past political behavior or viewpoints. In this case, the plaintiffs argue, the Maryland legislature retaliated against Republicans in the 6th District, based on their past support for Republicans, by diluting their votes. In two previous cases, according to Michael Kimberly, the attorney for the plaintiffs, “this is the approach that Justice Kennedy indicated he had interest in.”

Despite differences in the cases, it’s the big picture that preoccupies voting rights advocates. “The fundamental question is, will the court make clear that states cannot use their authority to draw district lines to entrench a party in power, and will the courts intervene to correct abuses of state authority?” says Gans. If the answer is yes, then the next question is how the court goes about limiting gerrymandering. If the answer is no, then the next decade could see partisan gerrymandering at an unprecedented level.