<html>
<head>
<style>
input:out-of-range {
border: 2px solid red;
background-color: pink;
}
</style>
</head>
<body>
<h1>Demo of :out-of-range</h1>
<p>Input a number between 1 and 10: <input type="number" min="1" max="10" value="17"></p>
<p>Try typing a number within the given range (between 1 and 10), to see the styling disappear.</p>
</body>
</html>