refactored scroll animation into one object