Broke apart some of the browser-specific logic for CSS handling.