"It didn't light any fires," said Rudnick, 38, an Obie Award-winning playwright ("Jeffrey") who lives in Manhattan's West Village. "They wanted a story about a gay teacher who got outed on national TV, a concept inspired by the warm tribute Tom Hanks gave his drama teacher from Oakland in the Oscar acceptance speech for 'Philadelphia.'

"But the real-life teacher (Rawley Farnsworth) happily had been out for a long time, and was long retired -- I couldn't see where a comedy about him would lead."

Yet Rudnick wouldn't leave it alone.

"After mulling it over, I had this flash -- what if the teacher was outed on the same week he was going to get married?"

The notion hit with producer Scott Rudin ("Ransom," "The First Wives Club"). Three years later, "In & Out" is enjoying an unusual buzz in advance of opening Friday in 2,100 theaters across the nation.

"I work slowly," said Rudnick, thin, dapper and a chatty conversationalist when he visited San Francisco last week. "It would be normal for me to write a thousand drafts." (Rudnick also wrote "Addams Family Values" for produc er Rudin).

The big trick with "In & Out," he said, was "making a comedy about gayness without having some kind of political agenda."

"I wanted a romantic screwball -- comedy without a hint of political diatribe. The movie aims to be out for a good time. We set it in a small town that has this Capra-like enchanted village or fable quality, and not a single character anybody would hate.

"We assumed a sophistication on the part of audiences, and purposely avoided a feeling of special pleading that says, 'Oh look! Gays are people too.' I hope everybody is way beyond that."

Rudnick, who claims phobias about driving cars, swimming and computers, works in a small home office on an IBM Selectric -- "a beautiful tank whose noise is music to me. I hate computers."

Most days he spends "avoiding writing -- that's the first obligation of every writer," he said.

When not pounding the typewriter between roughly 11 p.m. and 5 a.m. ("after I've eaten everything in the house"), working on a new play or screenplay, he is putting together his popular irreverent movie fan column for Premiere magazine, under the pseudonym Libby Gelman-Waxner.

In the film, Kline plays high school English teacher Howard Brackett in fictional Greenleaf, Ind. A former student (Matt Dillon), inspired to act in Brackett's drama class, wins an Oscar for a war movie role with a gay theme. In his acceptance speech, he outs the teacher. Brackett suddenly is on the defen sive with family, friends, students and, especially, his long-term fiancee, Emily Montgomery (Cusack).

Notoriety spreads and the media descends in the form of a slick entertainment TV reporter named Peter Malloy, played by Selleck.

The film's hottest moment is a long smooch exchanged by Kline and Selleck -- audiences gasped and howled in a nationwide sneak preview that Paramount Pictures said packed theaters everywhere last weekend.

"I love the kiss," said Rudnick. "But I wasn't sure it would work. I wanted it to be a real Hollywood kiss, something romantic and sexy. And with a full choir swelling behind it.

"I think we have to face the fact that often in the most well-intentioned movies, a same-sex kiss becomes a kind of vampire moment, and it can be dreadful. I wanted a kiss with a swoon to it -- Gable and Grant kissing, instead of Gable and Garbo."

Rudnick, on the set during the film's production, said Kline and Selleck did not rehearse their big scene.

"We'd watch them block out the scene, and approach one another, and I'd sit there wondering, 'How is this ever going to work?' But then the cameras rolled and it was epic. I can only say the whole thing surpasses anything I wrote."

IN & OUT: The new film written by playwright Paul Rudnick, starring Kevin Kline, Joan Cusack and Tom Selleck, opens Friday at Bay Area theaters.