add closing animations to modal