css3 animation add js events