support popstate (yay back buttons). various UI tweaks to make it look good on a phone