JQuery script to manage CSS animations on reveal