BUENOS AIRES, Argentina — There were rose petals and rice on the ground in front of the civil registry in Buenos Aires. But in the end they weren't for Alex Freyre and Jose Maria Di Bello, the gay couple hoping to achieve Latin America's first same-sex marriage.

On the eve of their wedding day last week, a national judge overturned a city court decision to issue them a marriage license. The couple came to the registry anyway, vowing not to leave until they were wed.

Protesters quietly mingled among the crowd of supporters. Roxanna Olivera, 33, wore a tie-dye rainbow shirt that said, "Jesus is Your Alternative." "What will we tell our children," she said watching the gay rights supporters waving flags and chanting for Alex and Jose. "There's a law of God we need to follow."

Tim Thomas, host of the gay radio program "Tal Como Somos," politely interrupted Olivera. "It's not just about children. We don't have the same rights that you do. It's a question of civil rights."

The issue of gay marriage is being discussed all over Argentina lately with the prospective wedding of Freyre and Di Bello. So how is it that Argentina — a country that strongly identifies with the Catholic Church and machismo culture — continues to lead Latin America in the push for gay rights?

"We historically come from European countries here," Thomas said. "There's so many Spanish, so many Italians. It's a total mix of Europe and that might make Argentina more progressive than other places."

That's a common refrain. Argentines, and the portenos of Buenos Aires in particular, are proud of their European roots. Spain is one of only seven countries in the world to allow gay marriage, but Italy with strong ties to the Catholic Church does not.

The other six countries to legalize same sex marriage include European countries such as Sweden, Norway, the Netherlands and Belgium, as well as Canada and South Africa.

In 2002, Buenos Aires legalized same-sex civil unions. Four other Argentine cities, Mexico City and parts of Brazil soon followed. Uruguay legalized civil unions nationwide, but Buenos Aires was still the first city in Latin America ready to take the first step.

"Buenos Aires is a gay-friendly city," said groom-to be Di Bello, holding Freyre's hand. A few days before the planned wedding the couple held court with the press at the Axel Hotel, Latin America's first luxury hotel built exclusively for gay clientele. The hotel, along with gay wine shops, gay tango clubs, gay friendly shops and restaurants, and even hosting the Gay World Cup in 2007 have helped the city promote this reputation.

But Andrea Lopez says that reputation doesn't hold true for the average Argentine. "It's all a show for tourists," the 46-year-old said while waiting with family to support DiBello and Freyre at the civil registry. Lopez says Argentina's gay culture is not as open as Brazil's. Lopez's girlfriend and most people she knows are only openly gay to a select few. "It doesn't matter if tourists are seen, but Argentines have to worry about losing their jobs."

Yet despite the remaining stigma, there are a few cracks in traditional Argentine culture that may help in the struggle for equality.

The majority of the country — 92 percent — is nominally Roman Catholic, but only 20 percent practice, according to the CIA Factbook.

And while the cowboys of the pampas and strong-man caudillo politics in the 19th century give Argentina a reputation for machismo — a male-dominated culture intolerant of homosexuality — in practice gender and power roles are more complex. Today, Argentina has a female president and ranks highest among Latin American countries in gender empowerment, according to the United Nations Human Development Index.

And traditional culture aside, parts of Argentine history help explain what makes the country so special when it comes to the gay rights movement. During the military dictatorship, between 1976 and 1983, being openly gay was an invitation for arrest or harassment. But a strong cultural respect for human rights developed in the years following the violence.

"Those political experiences strengthened the organizations and the social movements," said Maria Rashid, president of the Argentine Federation of Lesbians, Gays, Bisexuals and Transsexuals (LGBT)." It's allowed us to go further in our struggles for rights. Not only for the gay, lesbian and transsexual movement but for other movements too."

The near-success of Freyre and Di Bello speaks to the strength of civil society in Argentina. Freyre and Di Bello secretly planned their legal strategy for more than two years along with Rashid and other couples in the Argentine Federation of LGBT. Each couple pursued a different legal approach through the courts as part of an orchestrated campaign to pressure the judiciary and convince lawmakers to change the civil code.

And Freyre and Di Bello have come the closest. After being denied a marriage license, the couple sued the city of Buenos Aires for denying them their constitutional rights. Last month a city judge ruled in their favor. At the time, the mayor of Buenos Aires said he wouldn't appeal. But after a second federal judge opposed the license, the mayor opted to wait and let the Supreme Court decide.

So instead of a wedding march last week, protest songs broke out at the civil registry. The rose petals on the streets became covered in fliers. And Freyre and Di Bello led a protest, bouquets in hand, to the mayor's office.

"We're going to continue fighting," Rashid said visibly saddened by the mayor's decision. Rashid and her partner were the first couple to bring a lawsuit for marriage rights to the Supreme Court. Her case is among seven cases in various stages of litigation. Nobody is sure exactly which judge has jurisdiction over Freyre and Di Bello's case, but Rashid is sure of one thing: "We'll fight them all — each case — right through the justice system."