Senate votes to terminate Trump national emergency as 12 Republicans join Democrats in rebuke to the president