How to style CSS role

This can be done by using CSS attribute selectors.The CSS Attribute Selector is used to select an element with some specific attribute or attribute value.And we have a way to get the work done.Below is a demo of the problem above:

Example;

div[role=main]