.card {
  width: 320px;
  height: 446px;
  background-color: #211799;
  background-image: url(https://images.pokemontcg.io/xy2/12_hires.png);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center;
  border-radius: 15px;
  box-shadow: -3px -3px 3px 0 rgba(#26e6f7, 0.3), 3px 3px 3px 0 rgba(#f759e4, 0.3), 0 0 6px 2px rgba(#ffe759, 0.3),
    0 35px 25px -15px rgba(0, 0, 0, 0.3);
  position: relative;
  overflow: hidden;
  display: inline-block;
  vertical-align: middle;
  margin: 20px 10px;
  animation: holoCard 15s ease infinite;
}

.card > span {
  position: relative;
  top: 45%;
}

.card:before,
.card:after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  top: 0;
  background-image: linear-gradient(
    115deg,
    transparent 0%,
    rgb(0, 231, 255) 30%,
    rgb(255, 0, 231) 70%,
    transparent 100%
  );
  background-position: 0% 0%;
  background-repeat: no-repeat;
  background-size: 300% 300%;
  mix-blend-mode: color-dodge;
  opacity: 0.2;
  z-index: 1;
  animation: holoGradient 15s ease infinite;
}
.card:after {
  background-image: url("https://s3-us-west-2.amazonaws.com/s.cdpn.io/13471/sparkles.gif");
  background-position: center;
  background-size: 180%;
  mix-blend-mode: color-dodge;
  opacity: 1;
  z-index: 2;
  animation: holoSparkle 15s ease infinite;
}

.card.active:before {
  opacity: 1;
  animation: none;
  transition: none;
  background-image: linear-gradient(
    115deg,
    transparent 0%,
    transparent 25%,
    rgba(0, 231, 255,0.7) 45%,
    rgba(255, 0, 231,0.7) 55%,
    transparent 70%,
    transparent 100%
  );
}

.card.active:before,
.card.active:after {
  animation: none;  
}

.card:nth-of-type(1),
.card:nth-of-type(2),
.card:nth-of-type(3) {
  width: 160px;
  height: 226px;
  box-shadow: 0 0 1px 1px rgba(white,0.4), 0 25px 15px -10px rgba(0, 0, 0, 0.5);
}

.card:nth-of-type(1),
.card:nth-of-type(2),
.card:nth-of-type(3) {
  &:before, &:after {
    animation: none;
    opacity: 1;
  } 
}
.card:nth-of-type(1) {
  &:before, &:after { display: none; }
}
.card:nth-of-type(2) {
  background: none;
  &:before { display: none; }
}
.card:nth-of-type(3) {
  background: none;
  &:before { background-position: center; }
  &:after { display: none; }
}

.operator {
  display: inline-block;
  vertical-align: middle;
  font-size: 45px;
}
@keyframes holoSparkle {
  0%, 5% {
    opacity: 0.1;
  }
  20% {
    opacity: 1;
  }
  100% {
    opacity: 0.1;
  }
}

@keyframes holoGradient {
  0%, 100% {
    opacity: 0;
    background-position: 0% 0%;
  }
  8% {
    opacity: 0;
  }
  10% {
    background-position: 0% 0%;
  }
  19% {
    background-position: 100% 100%;
    opacity: 0.5;
  }
  35% {
    background-position: 100% 100%;
  }
  55% {
    background-position: 0% 0%;
    opacity: 0.3;
  }
  75% {
    opacity: 0;
  }
}

@keyframes holoCard {
  0%, 100% {
    transform: none;
  }
  25% {
    transform: rotateZ(-3deg) rotateX(-7deg) rotateY(6deg);
  }
  66% {
    transform: rotateZ(3deg) rotateX(7deg) rotateY(-6deg);
  }
}

body {
  color: white;
  background: #333844;
  font-family: "Heebo", sans-serif;
  display: flex;
  justify-content: center;
  vertical-align: middle;
  height: 100%;
  text-align: center;
}
html {
  height: 100%;
}

h1 {
  display: block;
  margin-top: 30px;
  margin-bottom: 5px;
}

p {
  margin-top: 5px;
  font-weight: 200;
}
#app {
  position: relative;
  perspective: 1000px;
}