Why is Islam opposed to homosexuality when it “harms no one”?
I disagree, consider this, it was stated that man is born to desire. Separating ourselves from desires brings us closer to Allah. A man born with the interest to murder is different than a homosexual. A homosexual isn't taking anyones life whereas a psychopath is hurting others. I think intention is very important. If ur intent isn't to harm others you aren't immoral. Ur denying people love. A man desiring a woman is still desire and he shouldn't do that either. The mere act of life is desire
The argument that “no one is being harmed” is false on two counts:
1. Homosexual relationships lead to “hookup cultures”, which lead to the disintegration of traditional marriage and family relations, as discussed in this essay. Understanding these harms requires thinking in terms of generations and centuries rather than individual lifetimes, which is something that most people cannot do unfortunately.
2. If God exists and if He does not approve of homosexual relationships, then engaging in this lifestyle and promoting it does the greatest possible harm, because it may doom its adherents to the Hellfire for eternity. What greater harm is possible? Unless you are a materialist who only thinks the present world exists, you must take account of both the present life and the afterlife in determining the harms or benefits of things.
As for your statement “If [your] intent isn’t to harm others you aren’t immoral”, that has no basis in moral philosophy. An action can lead to harm and to immoral results regardless of the intention of the person.