<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<style>
		input:required {
			border-color: blue;
		}

		input:invalid {
			background-color: pink;
		}

		input:valid {
			background-color: lightgreen;
		}
	</style>
</head>
<body>
	<form name="tele">
		<label for="name">Name</label>
		<input name="name" type="text" placeholder="John Wayne" required>
		<label for="phone">Phone</label>
		<input name="phone" type="tel" placeholder="XXX-XXX-XXXX" pattern="\d{3}\-\d{3}\-\d{4}" required>
		<input