added some transitions when the modal opens and closes