javascript and css changes to better support iPad