Added resize & mouse events for animation