In the week since Justice Anthony M. Kennedy announced his retirement, the future of Roe v. Wade has dominated the conversation among both liberals and conservatives, becoming a flashpoint in the partisan battle over President Donald Trump's pick to fill the seat.

The effect Mr Kennedy's retirement could have on lesbian, gay, bisexual and transgender rights has received less attention. The prospect of a more conservative justice, though, has LGBT rights groups worried about legal challenges from conservative groups that oppose same-sex marriage, who may see an opportunity to challenge rulings that have established its legality.

​LGBT groups have made great advances in recent years thanks largely to a string of Supreme Court decisions written by Kennedy, including cases that legalised gay sex and established a right to same-sex marriage.

"I'd really hate to see the clock turn back after we've made such tremendous strides," said Stacey Long Simmons, advocacy director for the National LGBTQ Task Force.

Opposition to Roe v. Wade has been a driving force in American conservatism for decades. But Obergefell v. Hodges, the 2015 decision that legalised same-sex marriage, is a newer setback for religious conservatives. Many activists said they would welcome the chance to challenge the ruling, but they said it could take years for a case to reach the Supreme Court.

"It is a recent decision," said Tony Perkins, the president of the Family Research Council. "The case is still being built as to why it is problematic."

Conservative activists and LGBT groups agree that religious liberty cases could be the most potent challenges to same-sex marriage and other issues concerning gay and transgender people.

These kinds of challenges could bring Obergefell v. Hodges back into play, said Mathew Staver, chairman of the Liberty Counsel, a conservative Christian litigation group that has represented elected officials who resist same-sex marriage.

Mr Perkins agreed. "If we continue to see the confrontation with religious freedom over the definition of marriage, this issue isn't going to go away," he said.

LGBT groups have successfully challenged equal protection violations in several states, including Wisconsin and Florida, since 2015. But activists worry that a case from the 2018 session, Masterpiece Cakeshop v. Colorado Civil Rights Commission, could be a sign of trouble ahead.

That case, which was narrowly decided, upheld the right of a Christian baker to refuse to create a wedding cake for a gay couple, citing his religious objection to the marriage. But Mr Kennedy, who wrote the majority opinion in that case, also defended gay rights, writing that "these disputes must be resolved with tolerance, without undue disrespect to sincere religious beliefs, and without subjecting gay persons to indignities when they seek goods and services in an open market."

Big Gay Kiss protest - In pictures Show all 8 1 /8 Big Gay Kiss protest - In pictures Big Gay Kiss protest - In pictures LGBT activists embrace at the Big Gay Kiss In Kashmira Gander Big Gay Kiss protest - In pictures A same-sex couple were asked to leave Sainsbury's for holding hands. Kashmira Gander Big Gay Kiss protest - In pictures Josh Bradwell (L) and Thomas Rees embrace outside the Sainsbury's where they were told to leave for holding hands. Kashmira Gander Big Gay Kiss protest - In pictures Protesters tried to raise awareness of LGBT rights, and hope that Sainsbury's will retrain its staff Kashmira Gander Big Gay Kiss protest - In pictures Protesters played music, kissed and danced in store. Kashmira Gander Big Gay Kiss protest - In pictures Protesters kiss at the Sainsbury's in Hackney, East London Kashmira Gander Big Gay Kiss protest - In pictures Drag queen Rodent DeCay dances at the protest. Kashmira Gander Big Gay Kiss protest - In pictures Two men embrace at the Big Gay Kiss-in Kashmira Gander

The Supreme Court could reconsider abortion as early as this next term or the next year, Mr Staver said, because relevant cases are already working their way up the legal pipeline.

But when it comes to a direct challenge to Obergefell, a conservative state, like Kentucky or Alabama, may need to enact legislation that attempts to regulate marriage. That could draw a legal challenge that sets a Supreme Court case in motion, but likely not until at least 2020, he said.

The Alliance Defending Freedom, the conservative legal group that argued the Masterpiece case, is currently litigating cases where free speech, religious freedom and public accommodation laws collide. Earlier this year, it filed a brief with the Kentucky Supreme Court on behalf of a printer who refused to make shirts for a Pride festival. The group is working on similar cases in Arizona and Minnesota.

Activists pointed to state-level restrictions on abortion as a model for how already-established rights, like same-sex marriage, could be undermined. Measures in states like Arkansas and Texas have limited the availability of abortion services despite Roe v. Wade.

"What we've seen is you don't have to go overturn the marquee case in order to make the rights inaccessible to real people," said Rachel Tiven, the president of Lambda Legal, an LGBT legal advocacy group. "The question isn't whether or not the marriage equality decision will be overturned -- the threat is they will be hollowed out from underneath by a combination of religious exemptions and state rejection of equal treatment."

Religious conservatives had been cautious about what cases involving marriage to bring to the court as long as Justice Kennedy was on the bench, concerned that it could establish precedent with a ruling unfavourable to them. Now that Kennedy has retired, the dynamic has shifted, said Mr Staver, and it is gay rights groups who should proceed with caution.

"In the absence of Kennedy, I'd think they'd want to stay as far away from the Supreme Court as possible on any gay rights issue," Mr Staver said. "They are going to have to move their attention to local battles. That is a huge shift."

The top 15 worst countries to be gay in Europe Show all 15 1 /15 The top 15 worst countries to be gay in Europe The top 15 worst countries to be gay in Europe 15. Italy Getty Images The top 15 worst countries to be gay in Europe 14. Macedonia Processed by: Helicon Filter; The top 15 worst countries to be gay in Europe 13. Poland Getty Images The top 15 worst countries to be gay in Europe 12. Liechtenstein The top 15 worst countries to be gay in Europe 11. Lithuania The top 15 worst countries to be gay in Europe 10. Latvia This content is subject to copyright. The top 15 worst countries to be gay in Europe 9. San Marino The top 15 worst countries to be gay in Europe 8. Moldova The top 15 worst countries to be gay in Europe 7. Belarus Getty Images The top 15 worst countries to be gay in Europe 6. Ukraine Getty Images The top 15 worst countries to be gay in Europe 5. Monaco The top 15 worst countries to be gay in Europe 4. Turkey Getty Images The top 15 worst countries to be gay in Europe 3. Armenia The top 15 worst countries to be gay in Europe 2. Russia Getty Images The top 15 worst countries to be gay in Europe 1. Azerbaijan Norway's Mette B. Bjerknaes competes during the Powerboat race on July 6, 2013 in Baku. Baku hosts the second race F2 World Championship 2013. The 2 mile course is designed just in front of the Baku Boulevard facing the Caspian Sea. AFP PHOTO / TOFIK BABAYEV (Photo credit should read TOFIK BABAYEV/AFP/Getty Images) Getty/AFP

Mara Keisling, the executive director of the National Center for Transgender Equality, agreed that LGBT groups may need to reconsider how they think of the court. She was particularly concerned about the list of potential nominees posted to the White House website last fall.

"Potentially, we don't have the Supreme Court as a democratic backstop anymore, or we will not in the future if anyone on this list gets through," she said.