fix loading animation with better timing, and gif animation