A collection of Republicans in Congress are embracing equal rights for the LGBT community, ignoring grumbling from social conservatives and the risk of drawing a primary challenger to take a position proving increasingly beneficial in political battlegrounds.

This week, three vulnerable senators — Susan Collins of Maine, Cory Gardner of Colorado, and Thom Tillis of North Carolina — were feted at a fundraiser hosted by American Unity Fund, a GOP-aligned group that raises resources for Republicans who support equal rights for the LGBT community. Gardner could face pockets of resistance from social conservatives back home, and so could Tillis, who already is saddled with a primary challenger trying to outflank him on the Right.

Neither Tillis nor Gardner appears concerned.

“I think it probably is the best statement about how I go after policies I care about, and the politics have to work themselves out,” Tillis said Wednesday.

“Same sex marriage is the law of the land, and it is important that we treat everyone with dignity and respect,” Gardner added, in a brief statement to the Washington Examiner.

[Related: Tillis flip-flops his way toward primary challenge]

American Unity Fund, now in its fifth election cycle, partners with Republicans from battleground states and swing districts that support equal rights for the LGBT community, helping them raise critical resources in what are often close contests with Democrats. This week, the group also collected money for Reps. Brian Fitzpatrick of Pennsylvania, and John Katko and Elise Stefanik, both of New York.

Republicans have a hard time garnering support from LGBT voters, but issues of concern to them plays well among many voters in purple America. For instance, according to fresh data from Pew Research Center, 59% of self-identified moderate and liberal Republicans support same-sex marriage. Among independents who said they lean Republican, 56% back gay unions, with that support climbing to 64% for moderate and conservative Democrats.

That’s why it is crucial for Republicans in competitive battlegrounds to support LGBT rights, said Tyler Deaton, a senior adviser to American Unity Fund. He added that he has seen a growing acceptance of granting LGBT Americans the same rights as their straight counterparts in conservative circles since he became active on this issue as a gay Republican nearly a decade ago.

[Related: Dozens of House Republicans object to gay rights language in NAFTA replacement deal]

“The whole world has changed, and the Republican Party has changed,” Deaton said. “Young Republicans are overwhelmingly pro-LGBT. But that’s not the whole story. Every generational cohort [in the party] has a seen a change in public opinion.”

The Supreme Court legalized same-sex marriage nearly four years ago. Now, Americans who are transgender or do not identify as male or female are demanding equal treatment under the law. Social conservatives, who tend to vote Republican and wield influence in GOP primaries, often oppose aspects of the LGBT agenda.

[Opinion: A 21st-century agenda for the LGBT Right]

Notwithstanding Deaton’s rosy assessment of where the GOP is headed on LGBT issues, conservative opposition can spell trouble for Republicans who hold centrist or liberal positions.

“It depends on geography,” said a Republican strategist, who requested anonymity in order to speak candidly. “In the South and the Bible Belt, that’s definitely a potential game changer in a closed GOP primary. It can be a component to be labeled a RINO [Republican In Name Only], or a moderate, in the Midwest. I’d use it against my opponent if I wanted to contrast a moderate versus a conservative.”

Yet when the Washington Examiner inquired with two leading social conservative organizations based in Washington, Family Research Council and Concerned Women for America, both declined to comment for this story. Groups such as this have historically not shied away from criticizing Republicans who stray on their issues.

A Republican operative active in social conservative politics said the movement has largely abandoned the marriage issue in the aftermath of the Supreme Court ruling.

In part, this operative said, that’s because President Trump is delivering for them on appointing like-minded judges to the federal bench, a development that could lead to another major goal: overturning Roe v. Wade and ending the right to an abortion. Trump, who some Republicans, including Deaton, believe is centrist on LGBT issues, has barred transgender individuals from serving in the military, pleasing many social conservatives.

But a GOP consultant with clients on the 2020 ballot said social conservatives might be letting wayward Republicans off the hook because they are focused on the overriding goal of reelecting Trump next year.

“We’re in such a tribal time that voters on both sides accept that their candidates are going to seek wide alliances to try and beat the bad guys,” this consultant said.