fix css for firefox, clean up styles and code a bit