You could theoretically have “gay marriage” and religion. At its root marriage has nothing to do with religion.
That being said, you can’t have gay “marriage” because marriage is a breeding contract and gays can’t breed.
Think of it in terms of Romeo and Juliet.
If it’s Romeo and John, it wouldn’t have survived time because all of the conflict of the play disappears. The play is literally meaningless. The two families have no reason to care about their two black sheep weirdos.
The problem with Romeo and Juliet is the children they’re going to have. Then, these two families that hate each other, are genetically tied into becoming one big family with huge internal conflict.