House passes defense bill after GOP adopts abortion and transgender surgery amendments