SAN FRANCISCO - California's supreme court backed a ban on gay marriage on Tuesday, upholding a voter-approved proposition defining marriage as between a man and a woman, but said the marriages last year of 18,000 same-sex couples were still legal.

The court, which last year unexpectedly opened the door to same-sex unions in the most populous U.S. state, bowed to the majority of California voters who passed the ban known as Proposition 8 last November.

The argument continued in San Francisco streets, where gay marriage backers vowed to continue the fight at the ballot box in 2010.

We will not be moved. Repeal Prop 8! shouted seated protesters who blocked off an intersection in a show of civil disobedience. Police began arresting them one by one.

DeWitt Hoard, 65, a black man who legally married another man in California last year, compared the gay rights fight to one for racial equality. I've been on this road for a while, he said at the courthouse. Now we can't marry? Yes we will, it will happen.

Social conservatives, too, vowed to fight. If marriage were between two men society could not go on. It's not fear, it's just the way it should be, said college student Mike Choban, 18.

The court said the roughly 18,000 marriages that took place in the state between June and November last year remained valid since the ban was not retroactive. That leaves the state of 37 million people with a tiny group of married same-sex couples that cannot grow.

Gay rights advocates in the case had argued that a simple majority cannot be allowed to strip rights from a minority without undermining civil rights, but Proposition 8 supporters said the populist state constitution gave the majority the right to make fundamental changes through direct vote.

Chief Justice Ronald George characterized the gay rights advocates' position as it is just too easy to amend the Constitution through the initiative process and then responded that, like it or not, that was the law. It is not a proper function of this court to curtail that process, he wrote.

Moreover, Proposition 8 did not end broad protections for same-sex couples to form families, he concluded.

OTHER STATES

Before the California court's move, a flurry of pro-gay marriage rulings and votes in Iowa and New England this year had appeared to reverse a trend toward banning them in the United States.

Forty-two U.S. states explicitly prohibit same-sex marriage, including 29 with constitutional amendments, according to Human Rights Campaign, a gay rights advocacy group. Gay couples can get married in Massachusetts, Connecticut and Iowa, and several states provide for same-sex unions that grant many of the same rights as marriage.

Tuesday's ruling was unlikely to be the last move in what is seen as a pivotal state in U.S. culture wars.

In Los Angeles, gay advocates said they would try to change the state constitution again -- to affirm gay marriage -- in a vote as early as November 2010.

There is a smear on our constitution and the only way to get around it is through the ballot box, Kate Kendell, executive director of the National Center for Lesbian Rights, told supporters.

The passage of Proposition 8 by a 52 percent majority last year, in the same election that put Democrat Barack Obama in the White House, bucked California's reputation as a liberal trendsetter. It spurred nationwide protests by gay advocates and drew praise from social conservatives.

'SHAME ON YOU'

Gay rights advocates on the courthouse steps in San Francisco began shouting Shame on you on Tuesday as soon as the decision was made public.

Governor Arnold Schwarzenegger asked for peaceful and lawful protests in a statement. He predicted same-sex marriage would eventually prevail in California.

Tony Perkins, president of the conservative Family Research Council, predicted continued success for his group, which has prevailed against gay marriage in every state where the question has been put to a popular vote.

This is not an issue that is going to go away, he said.

The California court on Tuesday did not back away from its sweeping decision last year, which held that same-sex couples had fundamental constitutional rights and deserved special legal protections as a minority class. Proposition 8 was put to voters as a result of that court decision.

Proposition 8 reasonably must be interpreted in a limited fashion as eliminating only the right of same-sex couples to equal access to the designation of marriage, and as not otherwise affecting the constitutional right of those couples to establish an officially recognized family relationship, Chief Justice George wrote.

Because of the limited scope of the measure, he concluded, the constitution could be amended by a simple majority vote rather than requiring a more complex form of changing the constitution called a revision.

George, a Republican who wrote last year's opinion in support of same-sex marriage, distanced himself from voters' views. Our task in the present proceeding is not to determine whether the provision at issue is wise or sound, he wrote in the opinion released on Tuesday.