body {
  margin-left: 3%;
  margin-right: 3%;
  background-color: white;
  font-family: 'Roboto', sans-serif;
  height: 100%;
}

h1 {
 color: orange;
 font-size: 1rem;
 margin-top: 1rem;
 margin-bottom: 1rem;
text-align: center;
}

h2 {
  font-family: 'Oswald', sans-serif;
  font-size: 1rem;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

p {
  font-size: 0.7rem;
  color: darkgray;
  font-weight: 300;
  margin-top: 0.5rem;
  /* margin-bottom: 0.5rem; */
}

#searchbar {
  margin-top: 0rem;
  margin-bottom: 1.5rem;
  border: lightgray 1px solid;
  border-radius: 5px; 
  height: 1.5rem;
  width: 50%;
  font-size: 0.7rem;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.email {
  font-style: italic;
  color: orange;
}

.email:hover {
  cursor: pointer;
}

.grid-container {
  display: grid;
  grid-template-columns: 100%;
  grid-template-rows: auto;
  grid-gap: 20px;
}

.card {
  border: lightgray 1px solid;
  background-color: white;
  align-items: center;
  border-radius: 5px; 
  display: flex;
}

.card:hover {
  cursor: pointer;
}

.img {
  width: 30%;
  border-radius: 50%;
  width: 5rem;
  height: 5rem;
  padding: 1rem 1rem 1rem 1rem;
}

.text-container {
  min-width: 0;
  padding-right: 1rem;
}

.text-container p {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

@keyframes fadeIn {
  0%{
    opacity: 0;
  }
  100%{
    opacity: 1;
  }
}

.overlay {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  bottom: 0;
  background: rgba(100,100,100,0.5);
  animation: fadeIn ease-in-out .25s;
}

.img-modal {
 border-radius: 50%;
}

hr {
  margin-top:1.5rem;
  margin-bottom:1.5rem;
}

.modal {
  width: 14rem;
  margin: 10% auto auto;
  position: relative;
  text-align: center;
  background-color: white;
  border-radius: 5px;
  padding: 30px 20px;
}

.modal-close {
  position: absolute;
  right: 5px;
  top: 5px;
  cursor: pointer;
  border: none;
  background-color: white;
  color: darkgray;
  outline: none;
  transition: color .5s ;
}

.modal-back {
  position: absolute;
  left: 5px;
  top: 50%;
  cursor: pointer;
  border: none;
  background-color: white;
  color: darkgray;
  outline: none;
  transition: color .5s ;
}

.modal-forth {
  position: absolute;
  right: 5px;
  top: 50%;
  cursor: pointer;
  border: none;
  background-color: white;
  color: darkgray;
  outline: none;
  transition: color .5s ;
}

.modal-back:hover{
  cursor: pointer;
  color: orange;
}

.modal-forth:hover {
  cursor: pointer;
  color: orange;
}

.modal-close:hover {
 cursor: pointer;
 color: orange;
}


@keyframes fadeOut {
  0%{
    opacity: 1;
  }
  80%{
    opacity: 0;
  }
}

.hidden {
  display: none;
}

.fadehidden {
  animation: fadeOut .3s ease;
}

@media(min-width:768px) {

  h1 {
    font-size: 1.3rem;
   }
   
   h2 {
     font-size: 1.2rem;
   }
   
   p {
     font-size: 0.8rem;
   }

   #searchbar {
    margin-top: 2rem;
    margin-bottom: 2.7rem;
    border: lightgray 1px solid;
    border-radius: 5px; 
    height: 1.5rem;
    width: 30%;
    font-size: 0.7rem;
    display: block;
    margin-left: auto;
    margin-right: auto;
  }

   .card {
     height: 8rem;
   }

   .img {
    width: 30%;
    border-radius: 50%;
    width: 5rem;
    height: 5rem;
    padding: 1.2rem 1.2rem 1.2rem 1.2rem;
  }

  .grid-container {
  grid-template-columns: 1fr 1fr;
   } 

   .modal  {
     width: 15rem;
   }
}

@media(min-width:1024px) {

   .card {
     height: 9rem;
   }

   .img {
    width: 30%;
    border-radius: 50%;
    width: 6.5rem;
    height: 6.5rem;
    padding: 1.5rem 1.5rem 1.5rem 1.5rem;
  }

  .img-modal {
    width: 10rem;
    height: 10rem;
    margin-top: 1.5rem;
    margin-bottom: 2rem;
   }

  .grid-container {
    grid-template-columns: repeat(3, minmax(300px, 1fr));
  } 

  .modal  {
    width: 17rem;
  }
}
