Added proper error handling for IllegalArgumentException for Color.web.