@import url('https://fonts.googleapis.com/css?family=Anton|Roboto');

.word {
  font-family: 'Anton', sans-serif;
  perspective: 1000px; 
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;  
  margin-top: 50px;
}

.word span {
  cursor: pointer;
  display: inline-block;
  font-size: 120px;
  user-select: none;
  line-height: .10;
}

.word span:nth-child(1).active {
    animation: shrinkjump 2s ease-out;
    transform-origin: bottom center;
  }

@keyframes balance {
  0%, 100% {
    transform: rotate(0deg);
  }
  
  30%, 60% {
    transform: rotate(-45deg);
  }
}

.word span:nth-child(2).active {
  animation: shrinkjump 1s ease-in-out;
  transform-origin: bottom center;
}

@keyframes shrinkjump {
  10%, 35% {
    transform: scale(2, .2) translate(0, 0);
  }
  
  45%, 50% {
    transform: scale(1) translate(0, -150px);
  }
  
  80% {
    transform: scale(1) translate(0, 0);
  }
}

.word span:nth-child(3).active {
  animation: falling 2s ease-out;
  transform-origin: bottom center;
}

@keyframes falling {
  12% {
    transform: rotateX(240deg);
  }
  
  24% {
    transform: rotateX(150deg);
  }
  
  36% {
    transform: rotateX(200deg);
  }
  
  48% {
    transform: rotateX(175deg);
  }
  
  60%, 85% {
    transform: rotateX(180deg);
  }
  
  100% {
    transform: rotateX(0deg);
  }
}

.word span:nth-child(4).active {
  animation: rotate 1s ease-out;
}

@keyframes rotate {
  20%, 80% {
    transform: rotateY(180deg);
  }
  
  100% {
    transform: rotateY(360deg);
  }
}

.word span:nth-child(5).active {
  animation: toplong 1.5s linear;
}

@keyframes toplong {
  10%, 40% {
    transform: translateY(-48vh) scaleY(1);
  }
  
  90% {
    transform: translateY(-48vh) scaleY(4);
  }
}


.word span:nth-child(6).active {
    animation: balance 1.5s ease-out;
    transform-origin: bottom left;
  }

  .word span:nth-child(7).active {
    animation: toplong 1.5s ease-out;
    transform-origin: bottom left;
  }

  .word span:nth-child(8).active {
    animation: rotate 1s ease-out;
  }

  .word span:nth-child(9).active {
    animation: falling 2s ease-out;
    transform-origin: bottom center;
  }

  .word span:nth-child(10).active {
    animation: shrinkjump 2s ease-out;
    transform-origin: bottom center;
  }

  .word span:nth-child(11).active {
    animation: rotate 2s ease-out;
    transform-origin: bottom center;
  }

  .word span:nth-child(12).active {
    animation: shrinkjump 2s ease-out;
    transform-origin: bottom center;
  }

  .word span:nth-child(13).active {
    animation: balance 1.5s ease-out;
    transform-origin: bottom left;
  }

  .word span:nth-child(14).active {
    animation: rotate 1.5s ease-out;
    transform-origin: bottom left;
  }


/* Other styles */
body {
  background-color: #000;
  color: #fff;
  font-family: 'Roboto', sans-serif;
}

.mainstyle {
    width: 100%;
    height: 50vh; 
    display: flex;
    justify-content: center;
    flex-direction: column;
    align-items: center; 
    text-align: center; 
}


.texttag {
    margin: 50px;
    color: white;
    font: 700 normal 2.5em 'tahoma';
    text-shadow: 5px 2px #222324, 2px 4px #222324, 3px 5px #222324;
  }