LGBT people, especially youth, got some support Wednesday from an unexpected source – U.S. Sen. Orrin Hatch of Utah, a conservative Republican and devout Mormon.

“No one should feel less because of their orientation,” Hatch said from the Senate floor, discussing the increase in suicides nationally and the fact that LGBT youth are particularly at risk. “They deserve our unwavering love and support. They deserve our validation and the assurance that not only is there a place for them in this society but that it is far better off because of them. These young people need us and we desperately need them.”

Hatch, who said he timed his speech for LGBT Pride Month, explicitly included transgender people as well as lesbian, gay, and bisexual people in his remarks. “We all have family or loved ones who feel marginalized because of gender identity or sexual orientation, and we need to be there for them,” he said, according to The Salt Lake Tribune. He also said he doesn’t consider gender identity a choice. “these young men and women deserve to feel young, cared for, and accepted for who they are,” he said.

“Regardless of where you stand on the cultural issues of the day, whether you are a religious conservative, a secular liberal, or somewhere in between, we all have a special duty to each other,” Hatch said. “That duty is to treat one another with dignity and respect. It is not simply to tolerate but to love.” He urged his fellow lawmakers to create a national suicide prevention hotline, similar to 911 service, that he has proposed. (Existing hotlines are privately run.)

Hatch, a seven-term senator who is retiring at the end of this year, isn’t known for pro-LGBT views. He was a big supporter of the Defense of Marriage Act, which kept the federal government from recognizing same-sex marriages and said states didn’t have to recognize such marriages from other states. He criticized the 2013 Supreme Court decision that struck down the former portion of DOMA, saying the court “used its own personal opinion” instead of the law. (The 2015 marriage equality decision took care of the rest of DOMA by making same-sex marriage legal in every state.) Hatch did voice support for civil unions and eventually said he considered nationwide marriage equality inevitable.

More recently, he praised the Masterpiece Cakeshop decision, in which the court sided with a baker who had religious objections to providing a wedding cake to a same-sex couple. The court did not create a board right to discriminate and indeed said gay people’s rights should be protected by law, but it contended that the Colorado Civil Rights Commission, which found the baker in violation of the state’s antidiscrimination law, showed insufficient respect for his religious beliefs. “Courts must protect the ability of believers to freely live their faith and to express their religious beliefs openly and honestly,” Hatch said in a news release when the decision came down.

And 30 years ago, the Tribune notes, he called the Democratic Party “the party of homosexuals,” and not as a compliment. He at first denied making the remark, at a private event in Utah, then said he regretted it.

In the past few years, Hatch has taken a somewhat more pro-LGBT turn, supporting protections from discrimination in employment, albeit with exemptions for religious employers, and criticizing Donald Trump’s efforts to bar transgender people from the military.

LGBT rights groups praised Hatch’s Wednesday remarks. “Sen. Hatch’s comments were encouraging,” Troy Williams, executive director of Equality Utah, told the Tribune. “It is heartening to see a leader in the Republican Party speak out for LGBTQ youth. This is not new for the senior senator.” He said pro-LGBT Republicans are particularly needed in the age of Trump, and that obviously the LGBT rights movement has some differences with Hatch, “but every day there are more areas where we agree than disagree.”

Human Rights Campaign government affairs director David Stacy applauded Hatch’s “heartfelt remarks on the challenges LGBTQ youth face around acceptance, depression, and suicide.” He told the Tribune, “Like many Americans, his views have evolved as he has learned more about what it means to be LGBTQ, and we hope more senators reconsider their previous opposition to essential civil rights protections for LGBTQ Americans.”