Refactor basic structure to implement annimation