Uncertainty of their own sexuality, fear of others' reactions to it, not just family and friends but strangers, social conditioning, religious belief, all kinds of reasons.
Love and sex do not necessarily come together and I can see how someone can love someone very much and want to be with them regardless of sexuality.
Many people grow up believing it's wrong to be gay and are hit with all kinds of stereotypes. I can see how they would believe that, regardless of their own feelings, they feel they should try and fit into a social stereotype, something they are told they should do, what they see most people doing etc... ie get into a relationship with the opposite sex and start a family.
Things have come on a lot but there is still a lot of prejudice out there.
I know quite a few people who have been physically attacked because of their sexuality.
I have an ex from a very catholic background who really struggled to come to terms with his sexuality, he believed his mother would disown him as it was against her religion. He's not happily married to a man.
I often go to the local Pride celebrations and to get in to the main celebrations you need a wristband. A straight male friend of mine remarked that he felt very selfconscious wearing it in case of reprisals of attacks like have happened to our friends.