Petitioning to come to the United States as a foreign national is complicated. There’s visa paperwork, quotas in many cases, and lengthy wait times. One misstep could mean a lengthy separation from your loved ones.

And that's just for straight people.

As pro-reform interest groups prepare to fight for their specific priorities in pending immigration reform legislation, LGBT activists aren’t standing on the sidelines.

“There is a shared struggle among the immigrant and the LGBT communities,” said Steve Ralls of Immigration Equality, an organization that offers legal aid to LGBT immigrants. “There is a growing recognition that if we can get fair immigration reform through Congress we can work on a lot of issues together moving forward.”

Gay rights activists say there are several fronts in the immigration fight -- from specific provisions for gay Americans and permanent residents seeking to bring a non-citizen partner to the country, to protections for undocumented LGBT individuals, to a broader call for equal rights.

“We’re investing in immigration reform because it is a social justice issue and we have a responsibility to advocate for the kind of world we want to live in,” said Maya Rupert, policy director for the National Center for Lesbian Rights. “But beyond that, there are LGBT people who are going to be directly impacted by every provision in the ultimate legislation, so we have to make sure that it’s being done in a way that is inclusive and conscious of their needs.”

Border security has become one of the most contentious and difficult issues that lawmakers must resolve for a comprehensive immigration deal to be struck. USA Today's Alan Gomez discusses.

That means both legal and undocumented immigrants, Rupert said.

The number of LGBT immigrants is difficult to count, but researcher Dr. Gary Gates of UCLA’s Williams Institute used existing Census, Gallup and Pew Research Center data to calculate it. Gates estimates that about 900,000 LGBT immigrants live in the United States. About two-thirds of those are documented -- meaning that they are naturalized citizens, legal permanent residents or holders of a temporary visa. One-third -- about 267,000 -- are undocumented according to the estimate.

For documented LGBT immigrants, a key provision that activists have focused on is the inclusion of legislation called the Uniting American Families Act (UAFA) in a final comprehensive reform bill.

Currently, a U.S. citizen or permanent legal resident can petition for a visa for a foreign-born spouse -- but only if the spouse is of the opposite sex. That applies even if the same-sex couple is legally married in another country or in a U.S. state that recognizes gay marriage.

UAFA would make same-sex spouses or permanent partners of U.S. citizens eligible to petition for a family-based visa.

(If the Supreme Court finds the Defense of Marriage Act unconstitutional this summer, same-sex binational married couples will likely be able to apply for visas based on their relationship, regardless of where they reside.)

Activists point to an ally in Senate Judiciary Committee Chairman Patrick Leahy, an original Senate sponsor of the UAFA legislation and the head of the panel that will first review a draft immigration bill. The White House also specifically included the provision for same-sex immigrant permanent partners in a January fact sheet outlining the president’s priorities for reform.

A path to citizenship for undocumented immigrants is also getting heavy support from LGBT groups, who note that a significant portion of undocumented LGBT people in the United States may be here because they faced discrimination in their country of origin.

“You can imagine the fear that an undocumented person faces with the uncertainty in current law if their deportation would mean the return to a home country where they cannot be out, where they cannot have a relationship or they would be subject to intense persecution,” says Ralls. “So a path to citizenship is critical for all undocumented people, and for undocumented LGBT people it is in many cases a critical safety issue for them.”

Public opinion shifting

Since 1994, the U.S. has classified persecution on the basis of sexual orientation as grounds to seek asylum. But the process can be arduous and confusing, and asylum-seekers have to offer rigorous documentation of hardship. Those whose claims are denied risk deportation.

Although many Latino groups heavily involved in the immigration reform movement -- including the League of United Latin American Citizens, the National Council de la Raza and the Congressional Hispanic Caucus -- have offered support for the inclusion of LGBT protections in any final legislation, there’s opposition within the Latino community as well as from outside groups.

Susan Walsh / AP In this March 12, 2013 file photo, Sen. Marco Rubio, R-Fla. speaks on Capitol Hill in Washington.

In February, Sen. Marco Rubio -- a key player in the Senate Gang of Eight -- said that the inclusion of LGBT protections could hamper passage of the legislation. (Arizona’s Sen. John McCain has echoed that concern as well.)

"I think if that issue becomes a central issue in the debate it's going to become harder to get it done because there will be strong feelings on both sides,” Rubio said at an event sponsored by Buzzfeed.

As recently as a decade ago, the Hispanic and LGBT communities could have been considered quite the opposite of allies.

In 2006, a Pew Research Center study found that just 31 percent of Hispanics favored allowing gay marriage, compared to 56 percent who opposed it.

But in 2012, those numbers were almost a mirror image, with 52 percent of Hispanics backing gay marriage and about a third saying they are not in favor of legal marriage for gays and lesbians.

Amid the legal complications and the data, and regardless of how any final legislation reads, those involved in the issue say that the debate is raising awareness about a long-ignored population.

“Having a number that indicates that this is a sizable group -- more than 250,000 LGBT undocumented, nearly a million LGBT immigrants -- it’s not so much the overall number that’s important, it’s the fact that there is an estimate,” says Dr. Gates of the Williams Institute. “Unless you’re counted, you tend not to count.”

Related:

Religious groups, pro-reform organizations brace for family-based visa fight

This story was originally published on