In the face of economic pressure, North Carolina lawmakers voted March 30 to repeal and replace the state's controversial bathroom law. Here's what you need to know. (Monica Akhtar/The Washington Post)

North Carolina lawmakers retreated from the state’s controversial law that restricted which public restrooms transgender people can use, repealing it Thursday in the face of economic pressure in favor of a new bill that gay rights groups attacked as discriminatory.

The legislature approved the bill Thursday and Gov. Roy Cooper (D) signed it, reversing a law that required transgender people to use public bathrooms matching the gender on their birth certificates. The new law drew intense opposition from civil rights advocates because it bans local governments from passing measures to protect LGBT people. Cooper defended the new measure as an imperfect compromise and said it was not his “preferred solution.”

The votes and anger Thursday marked the latest eruption in the fight over North Carolina’s so-called “bathroom bill,” which has embroiled state politics and came to define the state’s public image since lawmakers introduced and hastily signed it a year ago. Since then, North Carolina has been buffeted by economic boycotts, job losses and public criticism, as sports leagues have relocated games, companies have canceled expansions and some tourists decided to spend their money elsewhere.

Those forces collided this week, as lawmakers scrambled to agree on a repeal measure to accommodate an ultimatum from the NCAA, the collegiate sports behemoth that relocated some high-profile contests and threatened to withhold others due to the law. The NCAA’s threat had added emotional heft this week, as the University of North Carolina’s basketball team is getting ready to play in the Final Four, one of the country’s premier sporting events.

NCAA President Mark Emmert told reporters Thursday that the organization’s board of governors will have to meet to discuss whether North Carolina’s actions are a “sufficient” enough change to schedule events in the state going forward. Emmert said he hoped the NCAA would announce its decision next week.

Under the compromise announced late Wednesday and approved Thursday, lawmakers repealed the bathroom law, also known as House Bill 2 (or “H.B. 2”). In addition to its transgender bathroom restrictions, the law also reversed local ordinances expanding protections for LGBT people and limited some minimum-wage standards.

In the new law, legislators imposed a three-year ban on local governments enacting nondiscrimination ordinances — extending it until after North Carolina’s next gubernatorial election. The bill — just a half-page long — also includes a measure stating that “no local government in this state may enact or amend an ordinance regulating private employment practices or regulating public accommodations.”

Local school boards and government agencies were also barred from regulating “multiple occupancy bathrooms, showers or changing facilities,” with that left up to state legislators. State Senate Leader Phil Berger (R) and House Speaker Tim Moore (R), who backed the bill, said it would implement until December 2020 “a temporary moratorium” on nondiscrimination ordinances like the one Charlotte passed last year, which prompted state lawmakers to pass the original bathroom bill.

Berger said in a statement that while “compromise is difficult for both sides,” he was “pleased this proposal fully protects safety and privacy by keeping men out of women’s bathrooms.”

Gay rights organizations and civil rights groups assailed the compromise as a “fake repeal” and called it a betrayal, vowing political repercussions for lawmakers who supported it and calling on sports leagues, businesses and entertainers to continue their economic boycotts.

“This new law does not repeal H.B. 2,” Chad Griffin, president of the Human Rights Campaign, said in a statement. “Instead, it institutes a statewide prohibition on equality by banning nondiscrimination protections across North Carolina and fuels the flames of anti-transgender hate. Each and every lawmaker who supported this bill has betrayed the LGBTQ community.”

Mara Keisling, executive director of the National Center for Transgender Equality, said that the bill and similar measures “are based on the vicious lie that trans people represent some type of danger to others.”

For some in the state, the new law created new uncertainty. Ashley and Matthew Nurkin, whose 8-year-old transgender daughter is a second grader in the Charlotte-Mecklenburg School District, said they don’t know what the new bill means for her. The school district was in the process of expanding protections for LGBTQ students when H.B. 2 was passed, but the new law bars local school officials from regulating bathrooms. Their daughter’s school was also ready to allow her to use the girl’s bathroom, but had to reverse course last year because of the state law.

“I think everybody’s trying to piece through and find out practically what that means in everyday life for a student like our daughter,” said Matthew Nurkin. He said his daughter is “embarrassed and sad” that she has to use a bathroom in the central office instead of one used by other students.

North Carolina’s abrupt flip-flop on the bathroom legislation caught many in the state by surprise and prompted criticism from both ends of the political spectrum.

The bill’s passage was an important milestone for Cooper, a first-term governor who narrowly won office in November, ousting incumbent Pat McCrory, the Republican who signed H.B. 2 last year. The bill played an outsize role in the campaign: Exit polls showed that two-thirds of voters opposed the bathroom law, and Cooper won the support of most of those voters. The new bill Thursday also offered a notable moment of bipartisanship in a state that has recently seen fractious political disputes, with Republican lawmakers seeking to limit some of Cooper’s powers in office and feuding with him through the H.B. 2 repeal discussions.

Despite Cooper’s backing, Democrats expressed concerns with the repeal measure, with some sounding uneasy about supporting it and others outright refusing to back the bill.

“We would rather suffer H.B. 2 than to have this body one more time deny us the full and unfettered protection of the law,” Democratic Rep. Deb Butler, one of two openly LGBT lawmakers, said during the House’s debate.

Republican lawmakers who backed the repeal said it would help the state move on to other things. Rep. Scott Stone (R) said that “the time has come for us to get out from under the national spotlight for negative things.”

Conservative groups also offered some criticism of the bill Thursday, with Family Research Council President Tony Perkins saying in a statement that “it does signal that elected officials are ultimately willing to surrender to the courts and the NCAA on matters of safety and public policy.”

The bill passed through the state’s Senate on a vote of 32 to 16. It then moved to the state’s House of Representatives, where lawmakers debated it for 90 minutes before it was approved by a vote of 70 to 48.

State lawmakers have previously flirted with repealing H.B. 2, most notably last December when they held a special session specifically for that purpose. That session was called after Charlotte abandoned its nondiscrimination ordinance, which had expanded new LGBT protections. Charlotte’s decision to scrap those protections was aimed specifically at clearing the path for state legislators to then repeal H.B. 2, after Republicans said that city’s ordinance was the reason the statewide law was needed.

After a marathon session in which Republicans sparred over whether to fully or partially repeal the bill and Democrats accused them of abandoning their pledge to eliminate the measure entirely, the legislators wound up leaving the bill in place. During that debate, Democrats rejected a version that would have included a six-month moratorium on cities passing nondiscrimination ordinances to protect gay and transgender people, a period that has been significantly extended in the new bill.

Possible repeal efforts gained new steam this week in the face of the NCAA’s deadline. The potential loss of all of those collegiate events would add to the already sizable damage North Carolina has faced since enacting the bathroom bill. Companies such as PayPal and Deutsche Bank have abandoned expansions in the state, the NBA and the NCAA already have moved marquee events elsewhere, and entertainers have canceled concerts and other shows.

These moves have taken a toll: A new estimate from the Associated Press this week said that over a 12-year period following enactment of the law, H.B. 2 would cost the state at least $3.7 billion due to these losses.

Kirk Ross in Raleigh and Moriah Balingit and Susan Svrluga in Washington contributed to this report.

Content from Allstate This content is paid for by an advertiser and published by WP BrandStudio. The Washington Post newsroom was not involved in the creation of this content. Learn more about WP BrandStudio.