Last June, a federal judge in New York upheld a $380,000 award for a gay police officer harassed by his fellow cops. In August, the New Jersey Supreme Court handed down a milestone ruling forbidding the Boy Scouts from discriminating based on sexual orientation. In recent years, four states have begun allowing gay couples to adopt children jointly, and half a dozen have overturned sodomy laws that targeted homosexual acts. Meanwhile, scores of states, cities and private employers have extended health insurance and other spousal benefits to "domestic partners."

From workplace discrimination to child custody, a clear and distinct pattern is emerging as courts, spurred by cultural and political changes across the country, apply the principles of equality to sexual orientation. Just as homosexuality has moved from the fringe to the mainstream of American culture in recent years, gay rights has become a flourishing area of the law.

Proceeding in fits and starts, the changes in how the law treats gay men and lesbians have been less the result of a single court ruling or piece of legislation than scattered responses to the shift in public attitudes about homosexuality. Polls show an increased acceptance of gays nationwide; movies and television are portraying more gay characters; and advertisers have begun openly appealing to gay customers, as in a Budweiser beer ad that shows two men holding hands. In this political season, Democratic candidates are actively ministering to the gay vote, while some leading Republicans have tried to temper their party's anti-gay image.

"The cultural shift has been amazing," said Robert Knight, senior director of cultural studies at the Family Research Council, which opposes homosexual "activism." "The avalanche of pro-gay publicity on TV sitcoms, in schools, in the media, has persuaded even the courts that homosexuality will eventually be declared a civil right."

Many legal observers had predicted that the Supreme Court's 1996 ruling in Romer v. Evans--finding government bias against homosexuals was unconstitutional--would set a dramatic precedent in gay rights law, galvanizing a host of changes in how the courts treated gays.

"In Romer, the court turned an important corner and recognized that gay men and lesbians in this country have legitimate claims for equality," said Mary Bonauto, civil rights director of the Boston-based Gay and Lesbian Advocates and Defenders. "That's an important tone to set for the Congress, state legislatures and courts around the country."

Still, while the decision had an impact on some discrimination cases--particularly in the workplace--its actual legal reasoning was narrow and its influence, ultimately, limited.

As a result, changes in laws affecting gays have largely responded to the shift in public attitudes rather than driving it. For example, despite major shifts in areas such as employment, custody and domestic partnership, there have been fewer gains in other areas where gay rights advocates had hoped to make substantial progress, particularly after the Romer ruling. The Pentagon's "don't ask, don't tell" policy, for example, under which homosexuals can serve only as long as their sexual orientation is not discovered, has been repeatedly upheld by courts. Further, the number of discharged gay soldiers has actually risen since the "don't ask, don't tell" policy was adopted five years ago.

And while courts in Vermont and Hawaii are scheduled to rule any day on the legality of same-sex marriages, 29 states have adopted laws against them, and Congress cleared the Defense of Marriage Act, intended to let states ignore same-sex marriages from other locales.

"Overall, there's been some acceleration of legal rights," says Yale University law professor William Eskridge, who has written extensively on gay law. "But differences exist across the country. In urban America, particularly the Northeast, there have been enormous strides toward equality. But in a big chunk of the country, particularly the Deep South and West, people can still label us 'degenerates' and 'sex perverts.' "

The prevailing national sentiment, say Eskridge and other legal observers, is one of tolerance toward sexual variation, but opposition to anything that could be viewed as promoting homosexuality.

Democratic pollster Geoff Garin agreed: "The public strongly rejects discrimination and intolerance . . . but where the politics of gay rights becomes more complicated is when the public perceives that the government is putting its seal of approval on a group."

A Washington Post/Kaiser Family Foundation/Harvard University poll last year supported that thesis, finding that while 57 percent of the people said homosexuality was unacceptable, 87 percent of those surveyed said homosexuals should have equal rights in terms of job opportunities. And, following the Supreme Court's 1996 Romer ruling, that is the area where gay men and lesbians have seen some of the most significant advances.

A leading example is the case of James Quinn, the Nassau County, N.Y., police officer who was for years tormented by colleagues with pornographic pictures and pranks that included putting rocks in his hubcaps so criminals would hear his rackety approach. When Quinn's supervisors did nothing to stop the harassment--in some cases actually joining in--Quinn sued for discrimination under federal civil rights law and won a $380,000 jury verdict. The police department appealed, and in June a federal judge upheld the award, taking a page from Romer to criticize the police department's conduct as "motivated by irrational fear and prejudice toward homosexuals."

Quinn, who retired from the force after being injured in the line of duty, said things have changed dramatically for people who come out of the closet. "When I was a kid, anyone who was thought to be gay was treated differently," he said. "I have nieces and nephews in junior high and high school, and they say they've had friends who are gay and that they are accepted."

Quinn's attorney, Fredric Ostrove, credits that shift in attitudes with the success of Quinn's suit, saying it represents "the different political and legal environment we're in now."

Only a limited number of job discrimination cases even reach the nation's courts, but in recent years, gay workers have been winning in greater numbers. Last year, for example, a federal judge in Utah ruled in favor of a high school volleyball coach who had been dismissed after acknowledging to students that she was a lesbian. Referring to Romer and other cases, the judge said government employers--excepting the military--can be held responsible for discrimination motivated by irrational fear and prejudice toward homosexuals.

When the New Jersey Supreme Court became the first state high court to forbid the Boy Scouts from discriminating based on sexual orientation last summer, the judges never mentioned Romer by name but they certainly echoed its sentiment. One of the panel's judges wrote in that ruling: "a lesbian or gay person, merely because he or she is homosexual, is not more or less likely to be moral than a person who is heterosexual."

Legal experts note that change has come more slowly when the subject involves family matters that invoke religious beliefs about marriage, parenting and sexuality. Still, in those areas, too, gays have made inroads in recent years.

Three years ago, for example, when Michael Galluccio and Jon Holden first tried to adopt a child, New Jersey officials said no. It took a battery of lawyers, a court ruling and a landmark change in New Jersey policy to make it happen. When they tried to adopt a second child earlier this year, it took them only a few months of the usual paperwork that any couple might face.

"Things are definitely better," Galluccio said recently, taking a break from his early evening routine of playing games and watching "Rugrats" with son Adam, 4, and daughter Madison, 2. "With Madison, from the time that we filed to adopt her until when the papers were signed, it was like a blink of an eye. It wasn't even two months."

Opportunities for gay men and lesbians to become parents have increased substantially in the past few years, experts say, in part as a result of the burgeoning business of surrogate mothers and sperm banks, as well as more permissive adoption rules.

Yet most gay people become "parents" by adopting the child of a partner who happens to be a biological parent. Judges across the country have been increasingly willing to approve adoptions with two "mothers" or "fathers," giving full parental rights to the non-biological parent, as they have long done for heterosexual stepparents. Such adoptions are no longer rare for gay couples in the District and about 20 states.

But in this area, too, it's not just the rules that are changing, said Galluccio. "In 1997, when we finally got Adam, our family was an oddity to people. There was a look of bewilderment in people's eyes," he said. "But now, we've become more ordinary."

Staff researcher Madonna Lebling contributed to this report.

CAPTION: Michael Galluccio, right, and Jon Holden battled three years ago to adopt Adam, left. This year, it was easier to adopt daughter Madison.