Back in my Navy days, Gillian, I was lucky enough to have a buddy like you describe. We were both “geographic bachelors” (my first wife [USN] was stationed in Guam, Sally-Ann’s hubs [Royal Navy] was on a destroyer homeported in the UK) posted as instructors in Newport, RI, at the same time. Most of the staff in our age group was married, neither of us was into the singles scene, both loved our respective spouses dearly, so we hung with the married couples as a couple. When something was happening on a weekend or after work, one of us would pick up the other, we’d have a nice time, we’d go to our respective homes after. We had someone we could talk to about missing our spouses, where we saw our careers going, and so on.
I think I got a hug when I got transferred to another department, and I might have gotten a hug and a peck on the check when I mustered out and we saw each other for the last time.
My wife never squawked (and my first wife was the jealous type). I met Mark when he visited (and okay, while not Chris Hemsworth or even Richard Gere, he was certainly much better at portraying the Dashing Navy Officer than I was) and he thanked me for being a friend to his wife.
Anyway, point is, heterosexual female/male friendships can work well. Something I look back on fondly.