As I said, I don’t think there’s one cause.
The biological explanation has to do with epigenetics, not with heredity as it’s usually understood.
I’m not an expert in any of that, but I do know that experiences and environment inside the womb can predispose people to homosexuality.
I know nothing about epigenetics. I don’t have time right now to research it. I’ll gladly read any explanatory links you can provide about possible epigenetic reasons for homosexuality, hopefully containing an explainer on epigenetics.