North Carolina and the U.S. government locked horns over anti-transgender legislation Monday.

Leaders in the Tar Heel State defiantly sued the federal government to uphold HB2, a law passed by the state legislature in March. The law strips bathroom choice from transgender people by requiring individuals to use a bathroom that corresponds to the sex on their birth certificate. The law also forbid municipalities from enacting their own LGBT protections.

After issuing a warning on Wednesday, the Justice Department also filed suit against North Carolina Gov. Pat McCrory and other state officials for violating the civil rights of North Carolinians. In a press conference, Attorney General Loretta Lynch said HB2's anti-transgender restroom provisions violate Title VII of the U.S. Civil Rights Act, which prohibits employment discrimination based on gender; Title IX, which protects against sex-based discrimination in publicly funded education programs; and transgender discrimination prohibitions in the Violence Against Women Act.

Evan Vucci/AP

Lynch, who hails from North Carolina, invoked the state's history of segregation under Jim Crow and its and opposition to same-sex marriage. She said that the Justice Department had to act to protect transgender individuals "who simply seek to engage in the most private of functions [...] that most of us take for granted."

"We have seen bill after bill taking aim at the LGBT community," Lynch said in reference laws that have cropped up in Republican-controlled state legislatures in recent months. "What we must never do is turn on our neighbors, our family members and our fellow Americans."

In a statement just hours before, McCrory accused the Obama administration of "bypassing Congress" by attempting to rewrite the law and set restroom policies for public and private employers across the country, not just North Carolina.

The governor added that it was Congress' job — not his — to "bring clarity" to anti-discrimination laws.

Ironically, this is the same point made by LGBT-rights advocates. Activists around the country have asked a "do nothing" Congress to expand existing federal civil rights protections to include anti-discrimination protections for transgender individuals and other queer-identified people in the workplace and in housing. Congress' lack of action, they said, perpetuated legal vulnerabilities that have been exploited by states like North Carolina.

North Carolina Gov. Pat McCrory makes a statement about his decision to sue the federal government. Gerry Broome/AP

"I think there's been an evolution in the interpretation of our federal laws, when it comes to transgender rights," said Kristen Clarke, president and executive director of the Lawyer's Committee for Civil Rights Under Law, in a phone interview Monday. "When the courts hear this issue, they will be doing so against the backdrop of a trend."

North Carolina is the latest battleground for LGBT rights. Clarke pointed to rulings in federal courts and a directive issued by the Obama administration that show a trend toward federal support of transgender rights. Here are three examples suggesting that McCrory and North Carolina's lawsuit to uphold transgender discrimination may not work:

Presidential Executive Order 13672

In July 2014, President Obama signed an executive order that prohibited the federal government from discriminating based on gender identity in federal employment and government contracting. The directive followed an order issued by the U.S. Department of Labor that same year.

Macy v. Holderacy Ruling

In April 2012, the Equal Employment Opportunity Commission found that discriminating on the basis of gender identity is tantamount to discrimination on the basis of sex. Such discrimination is already prohibited under the Civil Rights Act.

The Supreme Court's Oncale v. Sundowner Offshore Services Ruling

In a 1998 case concerning Title VII of the Civil Rights Act, the court ruled that, while federal law should must be interpreted according to its plain text, prohibitions meant to protect people from "principal evil" can be reasonably applied to cover "comparable evils." In other words, gender identity discrimination can be considered sex discrimination.

Toby Talbot/AP

Several LGBTQ civil rights organizations, including the Human Rights Campaign, Equality NC, the American Civil Liberties Union and Lambda Legal, joined in a chorus of condemnation for the state's bill.

"The lawsuit that was filed today is just another tactic to delay a decision," Chris Sgro, Equality NC's executive director said in a statement. "And is a continued waste of taxpayer dollars when it is already very clear that the only option is a full repeal of HB2."