.mfp-with-fade .mfp-content,
.mfp-with-fade .mfp-arrow, .mfp-with-fade.mfp-bg {
  opacity: 0;
  -webkit-backface-visibility: hidden;
  -webkit-transition: opacity 0.3s ease-out;
  -moz-transition: opacity 0.3s ease-out;
  -o-transition: opacity 0.3s ease-out;
  transition: opacity 0.3s ease-out;
}
.mfp-with-fade.mfp-ready .mfp-content,
.mfp-with-fade.mfp-ready .mfp-arrow {
  opacity: 1;
}
.mfp-with-fade.mfp-ready.mfp-bg {
  opacity: 0.8;
}
.mfp-with-fade.mfp-removing .mfp-content,
.mfp-with-fade.mfp-removing .mfp-arrow, .mfp-with-fade.mfp-removing.mfp-bg {
  opacity: 0;
}


/* aligns caption to center */

.image-source-link {
  color: #DDD;
}

.mfp-content figcaption {width:100%}

.white-popup {
  position: relative;
  background: transparent;
  width:auto;
  max-width: 500px;
  margin: 20px auto;
}

/* CSS-based preloader */
.mfp-preloader {
  width: 30px;
  height: 30px;
  background-color: #FFF;
  opacity: 0.65;
  margin: 0 auto;
  animation: rotateplane 1.2s infinite ease-in-out;
}

@keyframes rotateplane {
  0% {
    transform: perspective(120px) rotateX(0deg) rotateY(0deg);
  }

  50% {
    transform: perspective(120px) rotateX(-180.1deg) rotateY(0deg);
  }

  100% {
    transform: perspective(120px) rotateX(-180deg) rotateY(-179.9deg);
  }
}


