the opinion was written by justice Gorsuch. mind you, justice Gorsuch straight up made fun of the court for its gay marriage decision in one of his first scotus opinions, so he's not the legislate from the bench type that tom fitton is decrying.
anons should read justice Gorsuch's opinion and the dissents before themselves shouting about a decision that does not fit personal policy preferences (this is what justice Scalia said to do before shouting at him for deciding a case in a way you didn't like). you may not like the outcome of the case, but if you react in a knee-jerk way based on outcomes and not the law and the facts, then you're acting just like libs who invent law from the court.
does discrimination "because of .. sex" include firing a woman who acts in a masculine way, or a man who is effete? how is this different than discriminating against a woman who is attracted to women? I agree with justice Gorsuch, although as a policy matter I think justice Alito correctly lays out the problems that the decision will portend (sports, bathrooms, etc.).
the solution is simple: congress needs to change the legislation to discrimination based on "biological gender" – because the term "sex" is quite broad, no pun intended.