When Bob Tobin met Hitoshi Ohashi in Japan more than 30 years ago, it would have been unthinkable for either man even to publicly state they were romantically involved.

But in the past few years, attitudes have changed dramatically. And that’s lucky for the couple, because now they’re married.

“Things are much better now,” says Tobin, an author, consultant and keynote speaker who is originally from Boston. “Now, it’s no big deal for a lot of people.”

So much so that a client gave the couple a wedding gift on their big day – something Tobin says would have been unheard of even just a few years earlier.

But if members of the LBGTI (lesbian, bisexual, gay, transgender, intersex) community are more likely to be open about their sexuality in some industries, many still prefer to lay low in others.

“Foreign companies and companies in the creative space in the big cities are the most accepting today, while trading companies and Japanese banks are less so,” says Tobin.

Even so, he is confident attitudes will continue to evolve – much as they have in India where the Supreme Court this month overturned a colonial-era law against gay sex.

What’s it like being a gay student in Japan?

“It was harder to live openly and honestly 30 years ago, when I first got here, so very few people at work knew that I was gay,” he recalls. “But now it’s much easier to say that I am gay and people leave it at that.

“But that’s not true for everyone; some choose not to come out and that is their choice; young Japanese people come out and that’s not a big deal.

“Gays are more integrated and accepted these days, with no fuss, and many junior and senior high schools have information on LGBTI issues readily available.”

Even when politicians say “outlandish things” – like in July when Mio Sugita, a politician in the ruling Liberal Democratic Party, told a magazine same-sex couples should not receive state support because they did not have children and had “no productivity” – they are quickly taken to task, Tobin says.

In Sugita’s case, tens of thousands of people staged a protest rally outside the LDP’s headquarters and a petition with more than 26,000 signatures was submitted to the party.

‘Boys for Sale’: the dark world of Japan’s gay prostitution

“Japan is behind many other Asian countries, such as Taiwan, on LGBTI issues, but it is still safe here and there is no bashing but a live-and-let-live attitude,” Tobin says.

There are references to homosexuality in Japanese culture in ancient times and several surviving Heian-era diaries, from the 11th century, contain references to homosexual acts. Some even mention emperors involved in homosexual relationships with “handsome boys”.

Similar relationships were not uncommon between older priests and young acolytes in Buddhist monasteries.

Same-sex love spread to Japan’s legendary samurai warriors and the world of “kabuki” theatre, while relationships between men – often physical – had even become the subject of works of fiction and salacious “ukiyo-e” woodblock prints in the 1800s.

With the advent of the Meiji era, however, attitudes changed as Japan sought to emerge from being an isolated, feudal state and to reinvent itself as a modern and Westernised nation. Homosexuality was considered incompatible with that aim and the promotion of “bushido” and the growth of the military’s power over society in the years leading up to the second world war meant same-sex relationships were frowned upon.

Pink Dot: Singapore’s rare gem for LGBT community shines brighter

In the years after the war, Japanese society tended to look the other way whenever the issue cropped up and gay men and lesbian women often concealed their sexuality out of fear of ostracism or public ridicule.

Within the last decade, however, things have begun to change.

Today, there are no laws against homosexual activity and some legal protections exist for gay and transgender individuals. Some local governments have enacted laws that protect people from discrimination based on their sexual orientation and the cause of the LGBTI community has been assisted by a number of politicians coming out.

In 2003, Aya Kamikawa became the first openly transgender person to be elected to a political role after she took a seat in Tokyo’s Setagaya Ward assembly. Three years later, Kanako Otsuji, a member of the Osaka city assembly, came out as a lesbian.

In March last year, Tomoya Hosoda was elected to the city council of Iruma and says his victory was a “marker” for the rights of transgender people in Japan.

Born a girl, Hosoda, 26, underwent sexual reassignment surgery in 2014 and he emphasised in his successful election campaign that he wants to increase public acceptance of all forms of diversity in Japanese society.

“I think Japan has gradually become better in its attitude towards sexual minorities,” Hosoda says. “But while many people now know the term LGBTI, we still have not yet reached full understanding of what this means.

“Today, we are slowly making progress on areas such as legal recognition of homosexual partnerships and I truly believe that this is going to continue to improve.”