(CNN)In the United States, you could count the number of mosques like Masjid al-Rabia on two hands. It's a small community built on "five pillars of inclusivity," including pledges to be "women-centered," anti-racist LGBTQ-affirming and welcoming to a variety of Islamic traditions.
In a survey of American Muslims, 0% identified as lesbian or gay. Here's the story behind that statistic
Mahdia Lynn, a transgender woman, helped found the mosque in Chicago in 2016.
For several years, Lynn attended a mosque in a small conservative Muslim community in Oklahoma, where people believed she was a straight, cisgender woman.
"There was always the risk of being outed," said Lynn, a Shiite Muslim. "But at the time, I just wanted to focus on my faith."
There are a few mosques like Masjid al-Rabia around the world, notably in Berlin and Toronto. But the number of LGBT-affirming mosques and Islamic centers in the United States remains small.
Muslims for Progressive Values has eight "inclusive communities" in the United States, from Atlanta to San Francisco. Berkeley's Qal-bu Maryam Women's Mosque, which calls itself "America's first all-inclusive mosque," opened in 2017. Other like-minded mosques have struggled to find consistent congregants in recent years and closed down.
Imam Daiyiee Abdullah, 65, is one of the few openly gay Muslim clerics. For four years, he labored to build a mosque for LGBT Muslims in Washington, DC.
Frustrated, tired and running out of money, Abdullah gave up and moved to the mountains of Colorado, where the nearest inclusive mosque is an eight-hour drive away.
Liberal Muslims say there are hints of change. The percentage of American Muslims who said society should accept homosexuality has doubled in the last decade, to 52%, and is even higher among Millennials.
Still, for many LGBT Muslims, coming out of the closet to their families and religious communities can be a fraught decision.
Ani Zonneveld says she receives calls regularly from young gay and lesbian Muslims who have been threatened by their family or are afraid to reveal their sexual identity.
"I tell them that, unless you have a fantastic relationship with your parents, keep it in the closet until you finish high school and can leave the house," said Zonneveld, who heads Muslims for Progressive Values.
Religious spaces can be just as alienating, Zonneveld said. "What we have seen is that LGBT Muslims are not comfortable going to a mosque, and if they do, they definitely keep closeted."
They may even be reluctant to tell anonymous pollsters. According to a recent survey of more than 800 American Muslims, 0% identified as gay or lesbian.
Muslims in the United States are among the most diverse religious communities in the world. While 82% are American citizens, nearly a third have been in the country for less than two decades. A plurality (41%) are white, but no racial or ethnic group makes up a majority of Muslim American adults.
That diversity also applies to attitudes towards gay, lesbian and transgender people. According to a recent survey by the Institute for Social Policy and Understanding, 31% of Muslim-Americans said they hold a favorable opinion of LGBT people, 23% said "unfavorable" and 45% said they had "no opinion."
Among the Catholics, Jews and Protestants polled, only white evangelicals held less favorable views of LGBT people, the survey found.
Some Muslims have, like Lynn, hidden aspects of their identity for fear of being alienated or even endangered. But she said bigotry is no worse among American Muslims than in society at large.
"To act as if discrimination is unique to American Muslims is to buy into the Islamophobic narrative pushed by the right wing in this country, which is ironic, because it's the right wing that is systematically erasing transgender people's rights."
Lynn transitioned as a teenager, and converted to Islam later on, during a particularly painful period. Islam's spiritual regimens and rules for living offered a scaffolding on which to rebuild her life, the 31-year-old said.
"Islam saved my life, so I made the decision to give my life over to Islam."
She founded Masjid al-Rabia with two other Muslims in 2016.
"Part of our role as a community center is to create a space for those healing from spiritual violence," Lynn said.
This year, it's celebrating its first Ramadan as a fully operational community center.
Lynn described her community as both idealistic and incremental. It's small -- Friday prayers draw about a dozen worshipers to its downtown Chicago space -- but its very existence makes a radical statement.
While pushing for greater inclusivity in American mosques, she said it also provides a hospitable space where Muslims can practice their faith openly, regardless of race, gender, sect or sexual identity.
"We believe that everyone has a right to come to Islam as they are. Islam is too important to leave anyone behind."
Muslims disagree on how to interpret the Pew survey that showed an increasing acceptance of homosexuality.
Some said it signals growing support for LGBT political rights, but not in religious spaces like mosques and Islamic centers.
LGBT activists have broadly supported Muslim-Americans, rallying to their side in recent years to protest Trump administration policies. Prominent Muslim activists have argued that they need all the political allies they can muster.
"I will fight for anyone who fights for our community," activist Linda Sarsour said during a contentious panel discussion at an Islamic convention last year.
"And everybody is created by Allah and deserves to be treated with dignity and respect. That is how we Muslims have to show up in these United States of America."
But Yasir Qadhi, an influential scholar and dean of academic affairs at the new Islamic Seminary of America in Dallas, said pro-LGBT-rights political activists are confusing young Muslims.
"You are sending a mixed message," he said at the Islamic conference. "Because at the end of the day, we do not believe that it is morally healthy to engage in intercourse outside of the bonds of marriage."
In a recent interview, Qadhi said that he is grateful for LGBT Americans' political support. While he hasn't changed his theological views, he said he has softened his rhetoric.
"I will be the first to admit that we were overly harsh and perhaps we did marginalize people and make them feel as if they were not human or worthy of love," the scholar said.
Now, Qadhi often prefaces his remarks about homosexuality by noting that "feelings and inclinations" are not themselves sinful, and that homosexual acts should not be singled out for special condemnation.
LGBTQ Muslims should be welcomed at mosques, he said, but should not push for changes in Islamic theology or practice on mosque grounds.
"Whatever anyone does in their private life is not our business," Qadhi said. "I am never going to single out anyone in sermons for any sinful conduct. At the same time, in the mosque I am a part of, there is a clear red line: They cannot preach onto others that this is part of Islam, the same way I would not let a person sell liquor on our property."
The Fiqh Council of North America, a body of scholars who issue legal opinions based on Islamic texts, will take up transgenderism this year, said Qadhi, a council-member. Sexual reassignment surgery is permitted in Shiite Islam, but not among Sunnis, who comprise the majority American Muslims.
In most mosques, the genders are separated, and there have been conflicts about where Muslims in the process of gender transition should sit, Qadhi said. "Gender identity issues will be the big questions for the next several years."
But external and internal tensions can make it hard for Muslim-Americans to directly address contentious questions, said Dalia Mogahed, director of research for the Institute for Social Policy and Understanding.
"This is a huge source of division in the community right now," she said. "There are a lot of different opinions and, frankly, there is a lack of space to discuss it."
"When you have a community that is so under the microscope and being subjected to litmus tests for civility and tolerance, people become afraid and self-censoring"
Mogahed herself came under attack several years ago after a Gallup survey showed that no British Muslims -- as in, 0% -- said homosexuality was morally acceptable. Right wing provocateurs such as Milo Yiannopoulos seized on the survey to portray Muslims as a threat to gays and lesbians.
But Muslims in the United States and Britain have not mounted political or social campaigns against the LGBT community, Mogahed said.
"To conflate a religious belief with one community being a threat to another is unfair."
Like a lot of pro-LGBT Muslims, Imam Abdullah has migrated to online projects. He now runs the Mecca Institute, an Internet-based program to train a new generation of likeminded clerics. The program has three part-time students.
Because of media attention on his life and work, he said he draws attention when he visits American mosques.
"Sometimes people make derogatory remarks, like: There's that gay imam," Abdullah said.
"I've been asked in different parts of the country to leave the mosque, which is fine. I'm not going in to any mosque to try to change them. I am going there to pray."
In Washington, DC, weeks would go by without anyone showing up at his former mosque. Some closeted LGBT Muslims feared of being associated with "the gay mosque," he said.
"The personal trauma that so many went through made it hard for them to be public about their identity," Abdullah said.
The ISPU survey provides statistical backing for that sentiment. Of the 804 American Muslims polled, not one identified as gay or lesbian. Four percent identified as bisexual, 2% said they were "something else" and another 2% refused to answer the question.
Asked about the 0% statistic, Mogahed offered a nuanced interpretation. If 92% of American Muslims identified as straight, she said, then the remaining 8% may be lesbian or gay, even if they're reluctant say so.
"The fact that there is a segment of Muslims who identify as something other than straight means that, even though they may not be acting on that inclination or orientation, they have negotiated a space where they can still be Muslim," Mogahed said.
"There is enough space within the theology to be able to do that."