It started with a kiss. Not the exuberant embrace that US Marine sergeant Brandon Morgan gave his partner, Dalan Wells, on returning from a six-month deployment in Afghanistan. That homecoming, snapped by a friend, has become a global phenomenon, posted on Facebook, with more than 40,000 clicking the "like" button and very few expressing homophobic views.

The kiss that marks an even more profound change is that which over the past few years has been shared in moments of sporting glory by heterosexual males on the football pitch. Such behaviour from a sport noted for its vicious anti-gay sentiments is having a far wider impact as Eric Anderson, a university lecturer in sociology, discovered when he interviewed 145 university students. The vast majority said they were happy to kiss another man on the lips in friendship – an attitude reflected in research in the US and in other cities in the UK.

That finding has now been taken further by Anderson's former PhD student, Mark McCormack, a sociologist at Brunel University in London. He spent a year in three diverse secondary schools, including a faith school, for his book The Declining Significance of Homophobia, published next month. In the book, he charts how prejudice and discrimination have markedly declined among young people, replaced by genuine affection and respect between pupils whether gay or straight. "Many young people see 'gay' as normal," Dr McCormack says. "It's the politicians and institutions who are slower to change."

The speed of acceptance is remarkable. Only four years ago, the campaigning charity Stonewall commissioned a YouGov poll that indicated that homophobic bullying was more prevalent than 10 years earlier, with the school playground the most entrenched bastion of all for prejudice. So what has expedited the change?

Legislation has obviously played a part. Most recently, for instance, the 2010 Equality Act, which bans discrimination of any kind, came into force. Civil partnerships have also helped as has a celebrity culture that allows no personal secrets. Previously, gay performers were mainly comedians who were often gay caricatures. Now, gay and lesbians are "out" and prominent in every sphere. Some, such as Elton John and Mary Portas, have become national treasures. Social networking sites have also played a part in reducing isolation and, as the closet has become more sparsely populated, everyone knows someone who is gay or bisexual.

While there are caveats – some religions and cultures remain fiercely homophobic – Dr McCormack points out that this is good news for masculinity. "Teenage boys," he says, "are redefining what it means to be heterosexual. They are more open with their feelings, more tactile, less afraid of showing love and fear." One Direction, the straight boyband, he adds, is the modern model of masculinity. The lack of an uber-macho image to defend also means there is less need for "real" men to find a gay victim to "prove" their toughness; a virtuous circle is developing.

Dr McCormack's next piece of work examines the experience of bisexual men. Those who are in their thirties and older have experienced "massive homophobia"; again, younger people report very little discrimination. The trajectory is heartening: difference is clearly becoming the norm.