error handling and css changes