In most states, it's legal for an employer to fire workers simply because they are gay, lesbian, bisexual, or transgender.

The cause isn't a religious freedom law, like the one that sparked a major battle over LGBTQ rights in Indiana in 2015. Instead, most states' civil rights laws don't explicitly protect LGBTQ people from discrimination in the workplace, housing, or restaurants and other places that serve the general public.

"If there's a 'license to discriminate,'" Robin Wilson, a law professor at the University of Illinois who helped write Utah's nondiscrimination law, said, "it's the fact that the state hasn't said this is an unacceptable basis for saying no to people."

Anti-LGBTQ discrimination is scarily common

After working at Red Robin since 2006, Brian Stone was fired from his management position in New York — and he claimed it was because of his sexual orientation. Stone said his boss, Louis Tsourovakas, had mocked him for going to a gay pride parade in Miami, told him in June 2014 "that he should look for a new job," and placed him on a probationary "performance improvement plan." And even though Tsourovakas allegedly acknowledged Stone was doing his job well, Stone was fired anyway.

Surveys show that Stone's experience isn't the norm among LGBTQ Americans, but it's still fairly common. A 2011 review of the research by the Williams Institute, a think tank focused on LGBTQ issues, found that between 2003 and 2007, about 9.2 percent of openly gay, lesbian, and bisexual people reportedly lost a job, and 38.2 percent were harassed at work, due to their sexual orientation.

38.2 percent of open LGB people were harassed on the job due to their sexual orientation

The numbers were worse for transgender people, according to the Williams Institute review. In 2011, 78 percent of trans people reported at least one form of harassment or mistreatment at work because of their gender identity, and 47 percent were reportedly discriminated against in hiring, promotion, or job retention.

Discrimination has been found in randomized experiments, as well. In a 2013 study, researchers for the US Department of Housing and Urban Development sent out two types of emails to landlords inquiring about housing opportunities — one came from a heterosexual couple, and the other from a gay or lesbian couple. The gay and lesbian couples were less likely to receive favorable responses, the study found.

There's also been a spate of media reports on businesses that deny service to LGBTQ people because of their sexual orientation or gender identity. In Colorado, Masterpiece Cakeshop refused to make a cake for a gay couple's wedding reception. In Indiana, a pizzeria gained national publicity after the owners said they would not cater a same-sex wedding. In Michigan, an auto shop announced it would not serve gay or lesbian people, sparking a local protest.

What's worse, this type of discrimination is totally legal under most states' laws.

30 states don't ban discrimination against sexual orientation and gender identity in the workplace

Most states don't ban discrimination based on sexual orientation and gender identity in the workplace, housing, or public accommodations (hotels, restaurants, and other places that serve the general public).

As a result, more than half of LGBTQ Americans, according to the LGBTQ advocacy group Movement Advancement Project, live in a state where, under state law, an employer can legally fire someone because he's gay, a landlord can legally evict someone because she's lesbian, and a hotel manager can legally deny service to someone who's transgender — for no reason other than the person's sexual orientation or gender identity.

Currently, 20 states ban at least some forms of discrimination based on sexual orientation and gender identity, while two additional states ban discrimination based on sexual orientation. Some other states protect public but not private employees from discrimination. Many municipalities have nondiscrimination laws that only apply within their local borders, even in states that don't have such laws. And some companies prohibit discrimination in their own policies.

The protections can vary from state to state. Utah's protections for sexual orientation and gender identity don't apply to public accommodations. Some states also include exemptions for discrimination based on religious grounds. Enforcement varies, as well: Depending on the state, private lawsuits, fines, and jail time are all possible forms of punishment for discrimination.

36 states don't ban discrimination against all LGBTQ people in education

Other civil right laws also protect students from harassment and discrimination in K-12 public schools — but these are typically separate from measures that ban discrimination in the workplace, housing, and public accommodations.

Fourteen states have education laws that ban discrimination based on sexual orientation and gender identity, while Wisconsin protects students from discrimination based on sexual orientation but not gender identity. So in a majority of states, LGBTQ students have no explicit legal protections in schools.

Protections for LGBTQ people build on landmark civil rights laws

Nondiscrimination protections for LGBTQ people build on existing federal and state laws — most notably the Civil Rights Act of 1964 and Fair Housing Act, which protect people from discrimination based on their race, color, national origin, religion, and sex.

"The whole point was to say that black people ought to be able to drive to Mississippi from New York and have a place to stay or get a meal at a restaurant," Wilson of the University of Illinois said of the landmark federal laws. "Over time, we added protected classes to that — people with disabilities in some states, for example."

Some LGBTQ advocates argue that legal prohibitions against sex discrimination already protect LGBTQ people. But that interpretation hasn't been affirmed by all the higher courts, casting uncertainty over whether it would hold up in a legal dispute.

The uncertainty is why advocates want explicit legal protections for LGBTQ people: New state or federal laws that add sexual orientation and gender identity to nondiscrimination protections would remove any doubt about the reach of laws like the Civil Rights Act, Fair Housing Act, Title IX, and state statutes that prohibit sex discrimination in their public accommodations protections. (Federal public accommodations laws don't shield against sex discrimination — only discrimination based on race, color, national origin, and religion.)

"There's no substitute for being explicitly listed in the law," Ian Thompson, LGBTQ legislative director at the American Civil Liberties Union, said. "I also think it's a very powerful statement to see that it is the law of the land that discrimination against individuals because of their sexual orientation or gender identity is wrong and illegal."

Studies show civil rights laws reduce discrimination

The research on nondiscrimination protections is limited, but a 2013 series of studies by Laura Barron of the US Air Force Management Policy Division and Michelle Hebl of Rice University found laws that ban workplace discrimination appear to decrease discrimination based on sexual orientation.

Researchers conducted three studies. The first looked at awareness of civil rights laws. The second looked at discrimination toward gay or lesbian job applicants in neighboring cities with and without nondiscrimination protections. And the third placed people in mock interviews to see if they were less likely to discriminate against a gay or lesbian applicant if they thought local laws banned it.

CIVIL RIGHTS LAWS AUTHORITATIVELY SET THE MORALS OF A COMMUNITY

Across the board, the studies found nondiscrimination laws reduce signs of prejudice. People in places with existing nondiscrimination laws were more likely to be aware of the protections, and they were less likely to discriminate. Among the 229 participants in the mock interviews, those who believed a local law prohibited discrimination were also less likely to discriminate, based on metrics that gauged negativity toward gay and lesbian people.

The reason civil rights laws are effective, Barron and Hebl suggested, isn't necessarily that people fear the punishment of the law — but rather that civil rights laws authoritatively set the morals of a community. "[T]hese effects occur because anti-discrimination legislation can create social norms that govern what is acceptable and unacceptable behaviors to display toward stigmatized individuals," the researchers wrote.

While Barron and Hebl's studies may be the best research to date, it has some gaps. The researchers only looked at workplace discrimination, not housing or public accommodations, and sexual orientation, not gender identity. The authors also didn't look at the effect of punishments attached to nondiscrimination laws — for example, whether tougher fines or the threat of jail time could further reduce discrimination.

Most Americans think LGBTQ people are already protected under the law

Surveys show that most Americans widely support nondiscrimination protections, but a major hurdle to getting the laws passed may be that Americans already think they're in place.

In a 2014 poll from YouGov and the Huffington Post, 62 percent of respondents said it was already illegal under federal law to fire someone for being gay or lesbian, 14 percent said it was legal, and 25 percent weren't sure. The same poll found most Americans — 76 percent — said it should be illegal to fire someone for being gay or lesbian, while just 12 percent said it should be legal.

The YouGov and Huffington Post poll isn't the first to find strong support for civil rights protections for LGBTQ people. A 2014 survey commissioned by HRC, an LGBTQ advocacy group, found 63 percent of US voters favored a federal law that protects LGBTQ people from employment discrimination, while just 25 percent opposed it.

Another poll from Reuters, conducted in April 2015, found 54 percent of Americans said it's wrong for businesses to refuse service to people based on religious beliefs, while 28 percent said businesses should have that right — suggesting that most Americans would disapprove of businesses discriminating against LGBTQ people on such grounds.

For LGBTQ advocates, the overall results present a tricky situation: Most Americans support nondiscrimination protections for LGBTQ people, but they don't appear to know that these protections aren't currently explicit under the law.

"When people already think these protections are in place," Thompson of the ACLU said, "it can be difficult to work up the motivation that's necessary to push for them."

Can religious freedom laws overturn nondiscrimination protections? Courts will likely decide.

Indiana sparked a national controversy in March 2015 when it passed a religious freedom law, which prohibits the government from breaching people's religious rights without a compelling interest. Critics said the law would enable discrimination against LGBTQ people.

The concern wasn't that Indiana's Religious Freedom Restoration Act (RFRA) would allow blanket discrimination across the state. In most of Indiana, an employer can already fire a gay person solely because of his sexual orientation without any religious justification, because sexual orientation isn't included in the state's nondiscrimination laws.

Instead, the concern was that people would use the state's RFRA to bypass local nondiscrimination laws. So an employer in Indianapolis, which protects LGBTQ people in its local nondiscrimination law, could try to say that the local civil rights law illegally violates his RFRA-protected right to discriminate against LGBTQ people, and therefore justify firing an employee over his sexual orientation.

But many legal experts at the time said the laws shouldn't and couldn't be used to discriminate against LGBTQ people, arguing that governments have a compelling interest to protect people from discrimination and, therefore, can violate some people's religious freedoms through nondiscrimination statutes.

There were decades of legal precedent to support the claim. RFRAs had never been successfully used in their decades-long existence to allow discrimination, including in cases in New Mexico and Washington state that involved businesses refusing service to same-sex couples, according to Douglas Laycock, a law professor at the University of Virginia.

But in August 2016, a federal court in Michigan ruled that the federal RFRA can be used to bypass, to some extent, nondiscrimination protections for a fired transgender employee — suggesting that RFRAs can be used to allow discrimination against LGBTQ people. Specifically, the court ruled that the government should take some steps to accommodate a business owner's religious beliefs, even if the government has a compelling interest to protect LGBTQ people from discrimination. It's not clear if the court's decision will stand on appeals.

States could get ahead of any of these issues by including exemptions for civil rights laws in their RFRAs. Texas's RFRA includes a carve-out for civil rights protections to prevent people from citing their religious beliefs as a license to discriminate. Indiana passed a clarification in April 2015 that included a similar exemption.

Religious freedom battles can raise support and resistance to LGBTQ protections

Even if religious freedom laws don't enable more discrimination, Wilson worries that characterizing LGBTQ rights as fundamentally in conflict with religious rights will make it much more difficult to pass civil rights protections in the future.

That type of conflict, she said, is what led legislators to require religious exemptions in the Utah civil rights law she helped author — and she expects religious exemptions will be necessary to expand nondiscrimination protections in more conservative states that aren't as supportive of same-sex marriage or LGBTQ rights in general.

"The bigger problem is that if you convince people that giving gay folks rights is going to somehow encroach on religion," Wilson said, "it's going to be harder to change that legislative map in the US."