How to create a validation error then email not validated correctly?

I’m trying to add a validation error message, can anyone tell me how? This is the User Story User Story #6: If I enter an email that is not formatted correctly, I will see an HTML5 validation error. And here is the link to the code in Codepen.

Survey Form

If you use email input type, the validation will be done automatically.