updated regex to work with styles too