improve animations for modal