Donald Trump’s upset victory dealt a devastating blow to LGBT rights on Tuesday night. The CEO, who lost in the popular vote but prevailed in the Electoral College tally, has promised to appoint judges that would repeal the Supreme Court’s 2015 decision on marriage equality.

His vice president-elect, Mike Pence, passed one of the nation’s harshest pieces of anti-LGBT legislation as the governor of Indiana: The Religious Freedom Restoration Act, which was signed into law in 2015, gave businesses the right to refuse service to customers based on their “sincerely held religious beliefs.”

Advertisement:

But at least one piece of discriminatory legislation would appear to be on the way out. North Carolina’s House Bill 2, which restricts what public restrooms trans people are able to use, is in jeopardy after Democrat Roy Cooper declared victory over his opponent, the incumbent Pat McCrory, in the state’s gubernatorial race on Tuesday night. With 100 percent of precincts having reported, Cooper leads by 5,000 votes.

The race isn’t over yet. Because of the extremely narrow margin between the two politicians' votes, McCrory is insisting the Tar Heel State every single vote be tallied, including provisional ballots that he claims have yet to be added to the total. Voters won’t know who the next governor is until Nov. 18, when the votes are scheduled to be canvassed. If Cooper’s lead holds, it would serve as a clear referendum on HB2, which has been widely unpopular in the state after being pushed through an emergency session of the General Assembly in March.

HB 2’s path to repeal may be more fraught, however, in a state that remains dominated by Republicans. North Carolina might be known as one of America’s purplest states, but the law faces a wall of red that may be insurmountable.

Advertisement:

McCrory should have won in a landslide. Trump, who was expected to lose North Carolina in early tracking, was handed a decisive 4-point victory in a state that voted for Barack Obama in 2008. Although poll averages from RealClearPolitics showed that Cooper had led by as many as 6.3 percentage points during a bitterly fought contest, McCrory decisively closed the gap in recent weeks. Behind his rising numbers was his handling of disaster relief following Hurricane Matthew, which made him look like a capable, competent leader in the eyes of voters.

Exit polls from Election Day, though, show that his candidacy has been unable to overcome the widespread hatred of HB2 — with two-thirds of voters stating that passage of the law was bad for North Carolina. This matches earlier reports from Monmouth University showing that just 36 percent of residents approve of the law.

That shouldn’t be a shock to anyone. The anti-LGBT law, which prohibits transgender people from using public restrooms that correspond with their gender identity, has caused a widespread state of financial panic in what was once America’s fastest growing economy. After the bill was made law, more than 200 companies spoke out against HB 2, including Apple, Microsoft and Google. Companies like PayPal and Deutsche Bank relocated planned expansions in North Carolina to other states viewed as more friendly to LGBT employees. Recently, the real estate research firm CoStar Group pulled a planned investment of $250 million from Charlotte.

Advertisement:

It wasn’t just corporate America that had a problem with the law. The NBA moved next year’s All-Star Game from the state in protest of the anti-LGBT law, which dealt an estimated $100 million blow to the state’s ailing economy. This was followed by similar moves from collegiate sporting leagues like the NCAA and ACC, which nixed several scheduled championship games in North Carolina.

The Williams Institute, a think tank housed by UCLA, estimates that HB 2 will cost the state $5 billion in investments every year it remains the law.

Advertisement:

Cooper, the state’s sitting attorney general, ran his campaign on public sentiment against HB 2. The Democrat refused to defend the law in court after groups like Equality North Carolina and the American Civil Liberties Union challenged its legality, an issue that will likely be decided by the Supreme Court but for now remains in limbo following the death of former justice Antonin Scalia earlier this year. President-elect Trump, who will appoint his replacement, has vowed to pick a justice in his extreme far-right mold, which is bad news for LGBT activists.

McCrory, however, has continued to defend the law — which he has claimed would protect women and young children from the threat of “bathroom predators” — despite widespread evidence showing that this simply isn’t necessary. More than 200 state and local municipalities have nondiscrimination laws allowing trans people equal access in public accommodations, including restrooms. Not one has seen a surge in sexual violence as a result.

That stubborn support has led to high unfavorable ratings for the sitting governor, as well as an about-face from voters who had backed him in the 2012 race. Four years ago voters in Mecklenburg County approved of McCrory over his Democratic opponent, Walter Dalton, by a 3,000-vote margin. This time he lost Mecklenburg by 125,000 votes. That’s a notable defeat for the Republican incumbent. Mecklenburg is home to Charlotte, the state’s largest city, where McCrory served as mayor before ascending to North Carolina’s highest office.

Advertisement:

If a vote for Cooper amounted to a vote against HB 2, this doesn’t mean that the state will see the end of the legislation anytime soon. Quite the opposite, actually.

Aside from the still-contested gubernatorial race, it was a bad night for Democrats in North Carolina. The state’s General Assembly remains controlled by the exact same Republican legislators who pushed the bill through in March. Although some conservatives have urged the legislation’s repeal in the face of economic backlash, not enough lawmakers have turned against it to realistically sound the death knell for HB 2. Any attempt to repeal the law will likely be blocked by Republican obstruction in a state where Cooper will be one of the few Democrats in power.

HB 2 faces a more devastating fate. Instead of a swift, decisive repudiation of transphobia in the Tar Heel State, conservatives are likely to cling to the law for as long as possible — until they have no financial option but to drop it. In the weeks leading up to the election, McCrory had been towing the party line by insisting that the job rate was continuing to grow in North Carolina, despite all evidence to the contrary. He called it the “Carolina comeback.”

Advertisement:

North Carolina is facing the same fate as the rest of the country. Although an increasing majority of Americans favor LGBT rights across the board, the political party that was given the mandate to lead on Tuesday night continues to oppose equality at every level. Unfortunately, only one of those voices will be heard in Trump’s America.