The Roman Catholic Church on Sunday criticized a ruling effectively legalizing same-sex marriage in mostly Catholic Mexico.

The ruling, handed down earlier this month by Mexico's highest court, declares state bans unconstitutional but falls short of striking them down. However, district judges are now obligated to grant injunctions to gay couples who are denied a marriage license.

(Related: Mexico Supreme Court strikes gay marriage bans; Chihuahua joins equality states.)

“Without a doubt, gay marriage is legal everywhere,” Estefania Vela Barba, an associate law professor at Mexico City's CIDE University, told The New York Times. “If a same-sex couple comes along and the [state] code says marriage is between a man and a woman and for the purposes of reproduction, the court says, 'Ignore it, marriage is for two people.'”

An important roadblock to equality is money. According to the Times, it can cost $1,000 or more and take months to appeal to the courts.

“A couple with resources can get married. A couple without resources can't,” said Jose Luis Caballero, a constitutional scholar at the Iberoamerican University in Mexico City.

The Roman Catholic Church criticized the ruling in a statement given to the Times.

“We reiterate our conviction, based on scientific, anthropological, philosophical, social and religious reasons, that the family, cell of society is founded on the marriage of a man and a woman,” said Msgr. Eugenio Lira Rugarcia, secretary general of the Mexican bishops' conference.

The church's position, he added, is “stated in the millennia of Western legal tradition, collected and deepened throughout our history by legislators and judges from very different schools of thought and ideologies.”