Refactored to re-size images on window resize