corrected element fade-in and fade-out