/*
   New Perspectives on HTML and CSS
   Tutorial 6
   Case Problem 1

   Comment Form Style Sheet
   Author: 
   Date:   

   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 {
display: block;
float: right;
font-size: 0.9em;
width: 55%;
margin-left: 10px;
margin-right: 10px;
}

textarea {
display: block;
float: right;
font-size: 0.9em;
width: 55%;
margin-left: 10px;
margin-right: 10px;
height: 150px;
}

button {
   display: block;
   clear: both;
   width: 200px;
   height: 30px;
   margin-top: 5px;
   margin-bottom: 5px;
   margin-left: auto;
   margin-right: auto;
}


input:focus {
background-color: rgb(225,225,240);
}

textarea:focus {
background-color: rgb(225,225,240);
}

input:focus:valid {
background-color: rgb(225,240,225);
background-image: url('go.png');
background-repeat: no-repeat;
background-position: right 8px center;
background-size: 20px 20px;
}

input:focus:invalid {
background-color: rgb(240,225,225);
background-image: url('stop.png');
background-repeat: no-repeat;  
background-position: right 8px center;
background-size: 20px 20px;
}