Move smooth scrolling function to its own file