MATANZAS, Cuba — For decades belonging to a religion and being anything but heterosexual was stigmatized in Communist-ruled, macho Cuba, making the Mass held by three transgender pastors in the western Cuban city of Matanzas all the more groundbreaking.

Rainbow flags decorated the chapel, while the pastors, who had flown in from Brazil, Canada and the United States, wore stoles in the trans hues of light blue, pink and white and the congregation swayed to Caribbean beats.

Trans pastors Cindy Bourgeois from Canada (center) and Alexya Salvador from Brazil (left) listen to trans Baptist reverend Allyson Robinson from the U.S. during a mass in Matanzas, Cuba, on May 5, 2017. Alexandre Meneghini / Reuters

Friday was the first time a trans pastor held a Holy Communion in Cuba, highlighting how much the island nation has changed since both religious believers and gays went to "correctional" labor camps in the early years after the 1959 revolution.

"Tonight has been a night of celebration of equality between all people, marking a new era for Cuba," said Alexya Salvador, a Brazilian trans pastor wearing a black dress with a white clerical collar and lacy sleeves she made herself.

"God's love is radically inclusive."

The Mass on Friday was the highlight of a three-day conference on gender identity and theology organized by the Matanzas-based Cuban branch of the international Metropolitan Community Church.

The Morning Rundown Get a head start on the morning's top stories. This site is protected by recaptcha

"This is not only a first of its kind event for Cuba, but certainly one of the very first ever to be held anywhere in the world," said Allyson Robinson, a trans Baptist reverend from Washington.

Alexya Salvador (center), a Brazilian trans pastor, walks during a mass in a church in Matanzas, Cuba, on May 5, 2017. Picture taken on May 5, 2017. Alexandre Meneghini / Reuters

The conference took place ahead of the 10th anniversary, next weekend, of Cuba celebrating the global day against homophobia, and included a raucous "transformist" party as well as a variety of panels on theology and personal experiences.

In one, Salvador argued God was transgender, given the Holy Trinity was made up of the Holy Spirit, which she views as feminine, the Father and the Son.

Elaine Saralegui, a lesbian pastor who founded the Cuban branch of the MCC nearly two years ago, said she hoped the conference would foster greater inclusion of trans people and prove that being trans and Christian were not incompatible.

"I leave with having learnt a lot of things I can share with other trans," said one participant, a 26-year-old Cuban trans woman called Malu Duardo, "in particular that there is a God for everyone."

Related: Transgender Advocate Creates Safe Space for LGBTQ Homeless

Saralegui's congregation numbers around 35, but she said she also gets asked to hold Mass at LGBTQ activist events around the rest of the island nation of 11 million inhabitants.

"Nearly always they ask me to hold a liturgy there, so we have to improvise wine, bread and hold a (Lord's) supper anywhere," she said.

The trans pastors said they were impressed by Cuba's progressiveness in some respects, for example providing state-financed sex reassignment.

The country was clearly lagging the rest of the Americas in other ways though, they said. Same-sex couples may not marry or adopt children and a promised update to Cuba's family code has been slow to materialize.

"Everyone should have the right to have a family," said Salvador, who has adopted two children, including a trans girl. "I believe this touch of God will also happen in the Cuban community."

Follow NBC Out on Twitter, Facebook and Instagram