html {
    box-sizing: border-box;
  }
  
  *,
  *:before,
  *:after {
    box-sizing: inherit;
  }
  
  body {
    margin: 0;
    min-height: 100vh;
    font-size: 1rem;
    line-height: 1.25;
    animation: color-fade-in 2s forwards ease-in-out;
  }

  @keyframes color-fade-in {
    0%{
        background-color: #3586ff;
    }
    100%{
      background-color: #18222d;
    }
  }
  
  .grid {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  
    display: flex;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    flex-direction: row;
    flex-wrap: wrap;
  }
  
  @media only screen and (max-height: 10000px) {
    .grid{
      width: 50%;
    }
  }

  @media only screen and (max-height: 1080px) {    
    .grid {
      width: 50%;
    }
  }
  
  @media only screen and (max-height: 720px) {    
    .grid {
      width: 50%;
    }
  }

  @media only screen and (max-width: 1170px) and (max-height: 2532px){
    .grid{
      width: 100%;
    }
  }
  
  .grid-block {
    width: 50%;
    min-height: 11.25rem;
    padding: 1rem;
  }


  .image-grid {
    -webkit-transform: rotateX(45deg) rotateZ(45deg);
    transform: rotateX(45deg) rotateZ(45deg);
    -webkit-perspective: 1000px;
    perspective: 1000px;
  }

  @media only screen and (max-width: 1170px) and (max-height: 2532px){
    .grid{
      margin-top: 10%;
    }
    
    .image-grid {
      -webkit-transform: rotateX(0deg) rotateZ(0deg);
      transform: rotateX(0deg) rotateZ(0deg);
      -webkit-perspective: 1000px;
      perspective: 1000px;
    }  
  }
  
  .image-grid .tile-link:hover .tile-img {
    top: -1rem;
    left: -1rem;
  }
  
  .image-grid .tile-img {
    position: relative;
    top: 0;
    left: 0;
    -webkit-transition-property: opacity, top, left, box-shadow;
    transition-property: opacity, top, left, box-shadow;
  }
  
  .tile-link {
    display: block;
  }
  
  .tile-link:hover .tile-img {
    opacity: 1;
  }
  
  .tile-link:hover .tile-img-link {
    display: block;
  }
  
  .tile-link:hover .tile-img-link:hover .tile-img {
    opacity: 0.5;
  }
  
  .tile-img {
    display: block;
    width: 100%;
    height: auto;
    opacity: 1;
    -webkit-transition-property: opacity;
    transition-property: opacity;
    -webkit-transition-duration: 0.125s;
    transition-duration: 0.125s;
    -webkit-transition-timing-function: ease-in;
    transition-timing-function: ease-in;
    animation: panel-fades 1s forwards ease-in-out;
  }

  @keyframes panel-fades{
    0%{
      scale: 0;
    }
    100%{
      scale: 1;
    }
  }
  
  .tile-link:hover .tile-img1 {
    box-shadow: 5px 5px rgba(244, 170, 200, 0.4),
      10px 10px rgba(244, 170, 200, 0.3), 15px 15px rgba(244, 170, 200, 0.2),
      20px 20px rgba(244, 170, 200, 0.1), 25px 25px rgba(244, 170, 200, 0.05);
  }
  
  .tile-link:hover .tile-img2 {
    box-shadow: 5px 5px rgba(45, 186, 233, 0.4), 10px 10px rgba(45, 186, 233, 0.3),
      15px 15px rgba(45, 186, 233, 0.2), 20px 20px rgba(45, 186, 233, 0.1),
      25px 25px rgba(45, 186, 233, 0.05);
  }
  
  .tile-link:hover .tile-img3 {
    box-shadow: 5px 5px rgba(214, 221, 244, 0.4),
      10px 10px rgba(214, 221, 244, 0.3), 15px 15px rgba(214, 221, 244, 0.2),
      20px 20px rgba(214, 221, 244, 0.1), 25px 25px rgba(214, 221, 244, 0.05);
  }
  
  .tile-link:hover .tile-img4 {
    box-shadow: 5px 5px rgba(82, 119, 192, 0.4), 10px 10px rgba(82, 119, 192, 0.3),
      15px 15px rgba(82, 119, 192, 0.2), 20px 20px rgba(82, 119, 192, 0.1),
      25px 25px rgba(82, 119, 192, 0.05);
  }
  
  .tile-link:hover .tile-img5 {
    box-shadow: 5px 5px rgba(138, 218, 245, 0.4),
      10px 10px rgba(138, 218, 245, 0.3), 15px 15px rgba(138, 218, 245, 0.2),
      20px 20px rgba(138, 218, 245, 0.1), 25px 25px rgba(138, 218, 245, 0.05);
  }
  
  .tile-link:hover .tile-img6 {
    box-shadow: 5px 5px rgba(203, 215, 193, 0.4),
      10px 10px rgba(203, 215, 193, 0.3), 15px 15px rgba(203, 215, 193, 0.2),
      20px 20px rgba(203, 215, 193, 0.1), 25px 25px rgba(203, 215, 193, 0.05);
  }
  
  .tile-link:hover .tile-img7 {
    box-shadow: 5px 5px rgba(91, 209, 250, 0.4), 10px 10px rgba(91, 209, 250, 0.3),
      15px 15px rgba(91, 209, 250, 0.2), 20px 20px rgba(91, 209, 250, 0.1),
      25px 25px rgba(91, 209, 250, 0.05);
  }
  
  .tile-link:hover .tile-img8 {
    box-shadow: 5px 5px rgba(145, 156, 196, 0.4),
      10px 10px rgba(145, 156, 196, 0.3), 15px 15px rgba(145, 156, 196, 0.2),
      20px 20px rgba(145, 156, 196, 0.1), 25px 25px rgba(145, 156, 196, 0.05);
  }
  
  .panel {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 30px;
    background-color: rgba(255, 255, 255, 0.95);
    overflow-y: scroll;
    z-index: 9999;
    cursor: pointer;
  }
  
  .panel h2 {
    margin-top: 0;
  }
  
  .panel iframe,
  .panel img {
    display: block;
    max-width: 100%;
    margin: 20px 0;
  }
  
  