* {
  box-sizing: border-box;
}

.grid_works {
  padding: 2em;
  overflow: auto;
}

.grid_item {
  width: 100%;
  background: url(img/back.png);
  padding: 10px;
  float: left;
  position: relative;
}
.grid_item:nth-child(n) {
  margin-bottom: 10%;
  margin-left: 1%;
  margin-right: 1%;
}
.grid_item:nth-child(1n) {
  margin-bottom: 2%;
}

@media (min-width: 600px) {
  .grid_item {
    width: 47.5%;
  }
}
@media (min-width: 800px) {
  .grid_item {
    width: 30.997%;
  }
  .grid_item:nth-child(n) {
    margin-bottom: 2%;
  }
}

.grid_item img {
  max-width: 100%;
  background: #ccc;
  width: 100%;
}
.grid_item::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1;
  font-size: .875em;
  padding: 1.5em;
}
.grid_item h8 {
  text-align: middle;
  font-size: .975em;
}

.hover-effect .mask {
   opacity: 0;
   overflow:visible;
   border:100px solid rgba(0,0,0,0.7);
   box-sizing:border-box;
   transition: all 0.4s ease-in-out;
}

.hover-effect a.info {
   position:relative;
   top:-10px; /* Center the link */
   opacity: 0;
   transition: opacity 0.5s 0s ease-in-out;
}

.hover-effect:hover .mask {
   opacity: 1;
   border:100px solid rgba(0,0,0,0.7);
}

.hover-effect:hover a.info {
   opacity:1;
   transition-delay: 0.3s;
}


#mainwrapper .box:hover .simple-caption {
    -moz-transform: translateY(-100%);
    -o-transform: translateY(-100%);
    -webkit-transform: translateY(-100%);
    transform: translateY(-100%);
}
