WASHINGTON -- For 22 hours a day, Alejandro Cortez-Reyna, who is transgender, was confined to a 5-by-9-foot cell in immigration custody. Eventually the time out of the cell was reduced to about 45 minutes.

When Cortez-Reyna once asked why dayroom time for gay or transgender immigrants at the Theo Lacy facility in California was cut to less than two hours, a guard responded, "Because you need to learn not to be a faggot."

The guard's response is part of a civil rights complaint filed Wednesday on behalf of Cortez-Reyna and 12 others. It alleges systemic abuse and neglect of gay and transgender immigrants while in custody at facilities owned or contracted by Immigration and Customs Enforcement. Chicago-based Heartland Alliance National Immigrant Justice Center filed the action with the Department of Homeland Security's Office of Civil Rights and Civil Liberties and Inspector General's Office.

Alliance leaders said the allegations go beyond mistreatment by a few guards. They include blanket policies against the immigrants such as the rule at Theo Lacey that keeps all gay and transgender immigrants confined to their cells for 22 hours and the practice at a Santa Ana, Calif., jail that denies hormone treatments to transgender immigrants. The complaints were filed on behalf of men and women currently or recently detained in Arizona, California, Florida, Illinois, Louisiana, New Mexico, Pennsylvania and Wisconsin. Some have been granted asylum or have been released to pursue asylum appeals.

"It has become clear that the Department of Homeland Security is incapable of ensuring safe and nonpunitive conditions for sexual minorities," said Mary Meg McCarthy, executive director of Heartland Alliance.

McCarthy says Heartland wants the Obama administration to investigate the allegations along with two pending complaints it filed alleging sexual assault against two detainees. One of those complaints goes back nine months.

A spokeswoman for Immigration and Customs Enforcement, Gillian Christensen, said the agency plans to review and investigate and address any claims.

"U.S. Immigration and Customs Enforcement takes any allegations of mistreatment or abuse very seriously," she said.

The agency has discussed detention reforms previously with Heartland Alliance and other groups it meets with regularly, Christensen said. As a result, the agency last month issued guidelines for the housing and care of "vulnerable and special needs populations," she said.

Cortez-Reyna, who wants to be considered a woman goes by the name Alexis, said she and other gay and transgender immigrants were stripped to their underwear and searched in front of other immigrants who were not gay. Cortez-Reyna's complaint says an officer frequently threatened Cortez-Reyna and other immigrants. Many kept silent about mistreatment because they feared retaliation or that it would affect their immigration cases, the complaint says.

"As a human, it really got to be really depressing. I didn't choose to be homosexual, that's who I am. They did not treat us like human beings," Cortez-Reyna said in a phone interview.

In another case, a transgender detainee whose name was redacted from an affidavit released by Heartland Alliance was held in a McHenry, Ill., facility for nine months, an experience the immigrant called "living in hell." The detainee was isolated except for officers who were verbally and physically abusive, the complaint said.

"I am treated very poorly compared to other prisoners ... I am not allowed to leave my cell ... the officers say the detainees can only talk to members of the same gender and say that I am not any gender," the complaint says.

One of the Obama administration's immigration initiatives has been to improve conditions at detention facilities. Early in Obama's term, Immigration and Customs Enforcement promised to monitor and enforce contract performance standards. Advocates say the administration has fallen short of its promises.

The Homeland Security Department owns and operates its own immigration centers, which are privately run, and contracts with local law enforcement for another 33,000 beds. The administration planned to replace private contractors with Immigration and Customs Enforcement officers at 52 facilities where about 80 percent of the immigrant detention policy is housed.