#swiper {
  height: calc(40vh + 20vw);
  aspect-ratio: 2 / 3;
  perspective: 1000px;
  perspective-origin: center 50%;
  transform-style: preserve-3d;
  position: relative;
}

.card {
  width: 100%;
  height: 100%;
  position: absolute;
  border-radius: 20px;
  overflow: hidden;
  transform: translateZ(calc(-30px * var(--i))) translateY(calc(-20px * var(--i))) rotate(calc(-4deg * var(--i)));
  filter: drop-shadow(2px 2px 20px rgba(0, 0, 0, 0.5));
  cursor: pointer;
  user-select: none;
  transition: transform 0.5s;
}

.card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 50%;
}

#like,
#dislike {
  font-size: 16vh;
  border-radius: 50%;
  padding: 20px;
  position: relative;
  z-index: 1;
  animation-name: animation1;
  animation-duration: 1s;
  animation-timing-function: ease-in-out;
  animation-fill-mode: both;
  /* don't run animation at the beginning */
  animation-play-state: paused;
}

#like.trigger,
#dislike.trigger {
  animation-name: animation2;
}

#like {
  color: red;
  background-color: rgba(255, 255, 255, 0.5);
}

#dislike {
  color: #ccc;
  background-color: rgba(0, 0, 0, 0.5);
}

@keyframes animation1 {

  0%,
  100% {
    opacity: 0.2;
  }

  50% {
    opacity: 1;
  }
}

@keyframes animation2 {

  0%,
  100% {
    opacity: 0.2;
  }

  50% {
    opacity: 1;
  }
}

/* SPEECH BUBBLE */

.speech-bubble {
  left: -25%;
  position: absolute;
  margin: 20% auto;
  padding: 1em;
  max-width: 100%;
  min-width: 200px;
  min-height: 50px;
  border-radius: .25em;
  transform: rotate(-4deg) rotateY(15deg) translateZ(100px);
  background: #629bdd;
  font: 3vh  Century Gothic, Verdana, sans-serif;
  text-align: center;
}
.speech-bubble:before, .speech-bubble:after {
  position: absolute;
  z-index: -1;
  content: '';
}
.speech-bubble:after {
  top: 0; right: 0; bottom: 0; left: 0;
  border-radius: inherit;
  transform: rotate(2deg) translate(.35em, -.15em) scale(1.02);
  background: #f4fbfe;
}
.speech-bubble:before {
  border: solid 0 transparent;
  border-right: solid 3.5em #f4fbfe;
  border-bottom: solid .25em #629bdd;
  bottom: .25em; left: 1.25em;
  width: 0; height: 1em;
  transform: rotate(45deg) skewX(75deg);
}

/* SPEECH BUBBLE 2  */

.speech-2bubble {
  top: 60%;
  left: 100%;
  position: absolute;
  margin: 20% auto;
  padding: 0.75em;
  max-width: 100%;
  min-width: 50px;
  min-height: 20px;
  border-radius: .25em;
  transform: rotate(8deg) rotateY(-30deg) translateZ(100px);
  background: rgba(61, 61, 61, 0.5);
  font: 2vh  Century Gothic, Verdana, sans-serif;
  text-align: center;
}

.speech-2bubble:after {
  position: absolute;
  z-index: -1;
  content: '';
  top: 0; right: 0; bottom: 0; left: 0;
  border-radius: inherit;
  transform: rotate(2deg) translate(-.35em, .15em) scale(1.02);
  background: #f4fbfe;
}

/* ANSWER BUBBLE */

.speech-answer {
  top: 70%;
  left: auto;
  position: absolute;
  margin: 20% auto;
  padding: 1em;
  max-width: 100%;
  min-width: 50px;
  min-height: 20px;
  border-radius: .25em;
  transform: rotate(-4deg) rotateY(15deg) translateZ(100px) scale(0);
  background: rgba(77, 109, 189, 0.5);
  font: 2vh  Century Gothic, Verdana, sans-serif;
  text-align: center;
}

.speech-answer:before, .speech-answer:after {
  position: absolute;
  z-index: -1;
  content: '';
}

.speech-answer:after {
  top: 0; right: 0; bottom: 0; left: 0;
  border-radius: inherit;
  transform: rotate(2deg) translate(.35em, -.15em) scale(1.02);
  background: #f4fbfe;
}

/* ANGRY EFFECT*/
.shakeX {
    animation: shakeX 0.2s 5;
}

@keyframes shakeX {
    0% { transform: translateX(0) }
    25% { transform: translateX(15px) }
    50% { transform: translateX(-15px) }
    75% { transform: translateX(15px) }
    100% { transform: translateX(0) }
}

.shakeY {
    animation: shakeY 0.2s 5;
    /*animation-iteration-count: infinite;*/
}

@keyframes shakeY {
    0% { transform: translateY(0) }
    25% { transform: translateY(15px) }
    50% { transform: translateY(-15px) }
    75% { transform: translateY(15px) }
    100% { transform: translateY(0) }
}

/* SURPRISE EFFECT*/
.fadeWhite {
    animation: fade-white 1.8s;
    background-color: white;
}

@keyframes fade-white {
    0% { opacity: 0 }
    25% { opacity: 0.25 }
    50% { opacity: 0.5 }
    75% { opacity: 0.75 }
    100% { opacity: 1 }
}

/* INTRODUCTION EFFECT*/
.shakeIntroduction {
    animation: shake-introduction 7s infinite;
    background-color: white;
}

@keyframes shake-introduction {
    0% { transform: translateX(0) }
    10% { transform: translateX(150px) }
    40% { transform: translateX(150px) }
    50% { transform: translateX(0px) }
    60% { transform: translateX(-150px) }
    90% { transform: translateX(-150px) }
    100% { transform: translateX(0) }
}

/* SURPRISE EFFECT*/
.shakeSlow {
    animation: shake-slow 1.5s infinite;
    background-color: white;
}

@keyframes shake-slow {
    0% { transform: translateX(0) }
    13% { transform: translateX(5px) }
    26% { transform: translateX(-5px) }
    37% { transform: translateX(5px) }
    50% { transform: translateX(0) }
    100% { transform: translateX(0) }
}

/* HUGE SURPRISE EFFECT */
.shakeFast {
    animation: shake-fast 2s infinite;
    background-color: white;
}

@keyframes shake-fast {
    0% { transform: translateX(0px) }
    7% { transform: translateX(20px) }
    13% { transform: translateX(-20px) }
    19% { transform: translateX(20px) }
    26% { transform: translateX(-20px) }
    33% { transform: translateX(20px) }
    40% { transform: translateX(-20px) }
    46% { transform: translateX(20px) }
    51% { transform: translateX(0px) }
    100% { transform: translateX(0px) }
}

/* DEATH EFFECT */
.shakeDeath {
    animation: shake-death 4s forwards;
}

@keyframes shake-death {
    0% { transform: translate(-45%, -50%) }
    5% { transform: translate(-55%, -50%) }
    10% { transform: translate(-45%, -45%) }
    15% { transform: translate(-55%, -45%) }
    20% { transform: translate(-45%, -40%) }
    25% { transform: translate(-55%, -40%) }
    30% { transform: translate(-45%, -35%) }
    35% { transform: translate(-55%, -35%) }
    40% { transform: translate(-45%, -30%) }
    45% { transform: translate(-55%, -30%) }
    50% { transform: translate(-45%, -25%) }
    55% { transform: translate(-55%, -25%) }
    60% { transform: translate(-45%, -20%) }
    65% { transform: translate(-55%, -20%) }
    70% { transform: translate(-45%, -15%) }
    75% { transform: translate(-55%, -15%) }
    80% { transform: translate(-45%, -10%) }
    85% { transform: translate(-55%, -10%) }
    90% { transform: translate(-50%, -5%) }
    95% { transform: translate(-50%, -5%) }
    99% { transform: translate(-50%, 50%) }
    100% { transform: translate(-50%, -50%) }
}

.answer {
  transform: rotate(-4deg) rotateY(15deg) translateZ(100px) scale(1);
  transition: all 0.2s ease-in-out;
}
