If the sole force behind (human) sex were reproduction, why would women still have sex drives after they stop ovulating? Of course there is more to human sexuality than just the urge to directly continue the species.
And this can still be in line with evolutionary theory. Many species do things that do not directly benefit the individual or increase the individual's reproductive capacity, because they will benefit the species as a whole and promote overall propagation of that species' genes (biological altruism). Perhaps gay men and women serve some evolutionary purpose/somehow benefit the entire population's sexual success in ways that are not yet understood.
But even if there's no evolutionary explanation, of course it can still be biological

Infertile people serve no obvious reproductive purpose, yet infertility still naturally occurs.