changed css look and added timeout to the for loop