/*
   New Perspectives on HTML and CSS
   Tutorial 6
   Case Problem 1

   Comment Form Style Sheet
   Author: JJ Cales Velez
   Date: 9/24/2025  

   Filename:         comments.css
   Supporting Files: go.png, stop.png

*/

fieldset {
  background-color: rgb(245,245,255);
  margin-top: 15px;
  margin-bottom: 15px;
  margin-left: auto;
  margin-right: auto;
  padding: 5px;
  width: 90%;
}

label {

display: block;
float: left;
clear: left;
font-size: 0.9em;
width:100%;
margin-top: 5px;
margin-bottom: 5px;
}

input, text area{

display: block;
float: right;
font-size: 0.9em;
width: 55%;
margin-left: 10px;
margin-right: 10px;
}

textarea{ 
height: 150px;
float: right;
width: 57%;
 }

button
{
display: block;
clear: both;
width: 200px;
height: 30px;
margin-top: 5px;
margin-bottom: 5px;
margin-left: auto;
margin-right: auto;
float: none;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus{
background-color: rgb(225, 255, 240);
}

input[type="text"]:focus:valid,
input[type="email"]:focus:valid,
input[type="password"]:focus:valid {
background-color: rgb(225, 240, 225);
background-image: url('go.png');
background-repeat: no-repeat;
background-position: bottom right;
background-size: contain;
}

input[type="text"]:focus:invalid,
input[type="email"]:focus:invalid,
input[type="password"]:focus:invalid {
background-color: rgb(240, 225, 255);
background-image: url('stop.png');
background-repeat: no-repeat;
background-position: bottom right;
background-size: contain;
}
