How do intend to reset it smoothly. i ask because i imagine when you reset somehow the change will be visible to user. Instead you could try to define inner boxs with relative postion. When animation plays check if the bottom for first item has reach the top border and then move it to the bottom this way you could have a continous animation.