A sharply divided Supreme Court on Wednesday narrowly ruled that the Trump administration must comply with…