Select and style only if the value of the <input> element is "out of range":
The :out-of-range selector selects all elements with a value that is outside a specified range.
Note: The :out-of-range selector only works for elements with range limitations, such as input elements with min and max attributes.
Tip: Use the :in-range selector to select all elements with a value that is within a specified range.
The numbers in the table specifies the first browser version that fully supports the selector.
CSS Selector :in-range