/**
 * Computes a CSS calc function that betweens a value from
 * A to B over viewport-width A to viewport-width B.
 * Requires a media query to cap the value at B.
 */
.gallery {
  display: grid;
  grid-template-rows: repeat(5, 18vh);
  grid-template-columns: repeat(2, 45vw);
  transition: all 0.3s cubic-bezier(0.5, 0.8, 0.5, 0.2);
  border-radius: 10px;
  padding: 0.25em;
  cursor: zoom-in;
  width: 100%;
}
@media (min-width: 40em) {
  .gallery {
    grid-template-rows: repeat(2, 20vh);
  }
}
@media (min-width: 10em) and (orientation: landscape) {
  .gallery {
    grid-template-columns: repeat(5, 18vw);
    grid-template-rows: repeat(2, 45vh);
  }
}
@media (min-width: 60em) {
  .gallery {
    grid-template-columns: repeat(10, 8vw);
    grid-template-rows: 25vh;
  }
}

.img1 {
  object-fit: cover;
  width: 100%;
  height: 100%;
  left: -12px;
  top: 0;
  transition: all 0.15s cubic-bezier(0.3, 0.1, 0.3, 0.85);
  position: relative;
  box-shadow: 0 0 0 #0000;
  xopacity: 0.67;
  filter: sepia(80%) hue-rotate(180deg);
}
.img1:first-child {
  border-radius: 10px 10px 0 0;
}
.img1:last-child {
  border-radius: 0 0 10px 10px;
}
@media (min-width: 40em) and (max-width: 59.99em) {
  .img1:first-child {
    border-radius: 10px 0 0 0;
  }
  .img1:nth-child(5) {
    border-radius: 0 10px 0 0;
  }
  .img1:nth-child(6) {
    border-radius: 0 0 10px 0;
  }
  .img1:last-child {
    border-radius: 0 0 0 10px;
  }
}
@media (min-width: 60em) {
  .img1:first-child {
    border-radius: 10px 0 0 10px;
  }
  .img1:last-child {
    border-radius: 0 10px 10px 0;
  }
}
.img1:hover {
  opacity: 1;
  z-index: 1;
  box-shadow: 1em 1em 1em #0004;
  transition: all 0.3s cubic-bezier(0.3, 0.1, 0.3, 0.85);
  filter: sepia(0%) hue-rotate(0deg);
  border-radius: 5px;
  width: 200%;
  height: 200%;
  left: 0%;
  top: -100%;
}
@media (min-width: 40em) {
  .img1:hover {
    width: 250%;
    height: 500%;

    top: -200%;
  }
}
@media (min-width: 10em) and (orientation: landscape) {
  .img1:hover {
    width: 250%;
    height: 200%;
  }
}
@media (min-width: 40em) and (orientation: portrait) {
  .img1:hover {
    width: 300%;
    height: 300%;

    top: -100%;
  }
}
@media (min-width: 60em) {
  .img1:hover {
    width: 350%;
    height: 150%;
    left: 0%;
    top: -25%;
  }
  .img1:hover ~ img {

  }
}
@media (min-width: 60em) and (orientation: landscape) {
  .img1:hover {
    width: 200%;
    height: 200%;

    top: -75%;
  }
  .img1:hover ~ img1 {
    left: 100%;
  }
}