update to use pageYOffset; cleanup instantiation