Justices side with Catholic schools