Transitions not working right