The conservative-majority U.S. Supreme Court ruled on Monday that the U.S. Civil Rights Act’s ban on sex discrimination includes discrimination based on sexual orientation and transgender status.

If that was a surprise, so was the author of the court’s opinion—Justice Neil Gorsuch, President Donald Trump’s first pick to add conservatives to the court.