/*
Name: Jack Venberg
Date: 04.08.18
Section: CSE 154 AH

This is the gallery.css page for my creative project #3 in which I have created
a short contact information site with a gallery. This style modifies the
gallery.html page of the website.
*/

header {
  margin-top: 30px;
} 

header, p {
  text-align: center;
}

p {
  font-style: italic;
}

div, a, img {
  box-sizing: border-box;
}

/*
  Implimentation of responsive gallery from W3Schools
  Link: https://www.w3schools.com/css/tryit.asp?filename=trycss3_flexbox_image_gallery
*/

#img-main {
  display: flex;
  flex-wrap: wrap;
  margin: 10px 0;
  padding: 0 10px;
  min-height: 1000px;
}

.col {
  padding: 0 10px;
  flex: 25%;
  max-width: 25%;
}

.col img {
  margin-top: 10px;
  width: 100%;
}

@media (max-width: 1100px) {
  .col {
    flex: 50%;
    max-width: 50%;
  }
}

@media (max-width: 800px) {
  .col {
    flex: 100%;
    max-width: 100%;
  }
}

#lightbox {
  position: fixed;
  top: 0; 
  left: 0; 
  width: 100%; 
  height: 100%; 
  background-color: rgba(0, 0, 0, 0.2);
  z-index: 2;
  text-align: center;
  animation: fadeIn 1s ease-in-out;
}

#lightbox img {
  margin-top: 20%;
  box-shadow: 0 0 25px rgba(0, 0, 0, 0.2);
  transform: scale(2);
}

.visible {
  visibility: visible;
  opacity: 1;
  transition: opacity 0.3s linear;
}

.hidden {
  visibility: hidden;
  opacity: 0;
  transition: visibility 0s 0.3s, opacity 0.3s linear;
}
