

.animation-box {
  width: 400px;
  height: 200px;
  background-color:oldlace;
  margin: -240px 10px 10px 500px;
  overflow: hidden;
  position: relative;
  box-shadow: 2px 2px 8px;
  border-radius: 10px;
  padding: 20px;
}




@keyframes topFadeOut {
  0% {
    position: absolute;
    top: -3rem;
    opacity: 0;
  }

  75% {
    position: absolute;
    top: 25%;
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

@keyframes bottomFadeOut {
  0% {
    position: absolute;
    bottom: -5rem;
    opacity: 0;
  }

  75% {
    position: absolute;
    bottom: 25%;
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
  
}

@keyframes topFadeOutVertical {
  0% {
    position: absolute;
    top: -3rem;
    opacity: 0;
  }

  75% {
    position: absolute;
    top: 45%;
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

@keyframes rightFadeInOut {
  0% {
    position: absolute;
    right: -3rem;
    opacity: 0;
  }

  75% {
    position: absolute;
    right: 10rem;
    opacity: 1;
  }

  100% {
    opacity: 0;
    right: 10rem;
  }
}

@keyframes fadeInOut {
  0% {
    opacity: 0;
  }

  45% {
    opacity: 1;
  }

  100% {
    opacity: 0%;
  }
}

.first-text {
  font-size: 2.4rem;
  position: absolute;
  left: 2.5rem;
  top: 3rem;
  opacity: 0;
  animation-name: topFadeOut;
  animation-duration: 15s;
  color: olive;
  animation-iteration-count: infinite;
  
}

.second-text {
  font-size: 1.4rem;
  position: absolute;
  top: 3.5rem;
  opacity: 0;
  animation-name: rightFadeInOut;
  animation-delay: 13s;
  animation-duration: 16s;
  color: #FFA500;
  animation-iteration-count: infinite;
}

.third-text {
  transform: rotate(-90deg);
  font-size: 0.8rem;
  position: absolute;
  left: 65%;
  top: 45%;
  opacity: 0;
  animation-name: topFadeOutVertical;
  animation-delay: 7.5s;
  animation-duration: 6s;
  color: #A3DDF0;
  white-space: nowrap;
  animation-iteration-count: infinite;
}

.fourth-text {
  font-size: 1.4rem;
  position: absolute;
  top: 10.5rem;
  left: 10%;
  opacity: 0;
  color: #F0A3BE;
  animation-name: fadeInOut;
  animation-delay: 8.5s;
  animation-duration: 9s;
  animation-iteration-count: infinite;
}

.fifth-text {
  font-size: 2rem;
  position: absolute;
  left: 5%;
  bottom: 25%;
  opacity: 0;
  color: #BAAD76;
  animation-name: bottomFadeOut;
  animation-delay: 10s;
  animation-duration: 9s;
  animation-iteration-count: infinite;
}
.six-text{ transform: rotate(-90deg);
  font-size: 0.7rem;
  position: absolute;
  left: 70%;
  top: 45%;
  opacity: 0;
  animation-name: topFadeOutVertical;
  animation-delay: 7.5s;
  animation-duration: 16s;
  color: #8B6914;
  white-space: nowrap;
  animation-iteration-count: infinite;}
  
  .eig-text {
  font-size: 1.4rem;
  position: absolute;
  top: 20.5rem;
  left: 50%;
  opacity: 0;
  color: #BAAD76;
  animation-name: fadeInOut;
  animation-delay: 5.5s;
  animation-duration: 9s;
  animation-iteration-count: infinite;
}

.seven-text {
  font-size: 1.4rem;
  position: absolute;
  top: 5.5rem;
  left: 50%;
  opacity: 0;
  color: #A52A2A;
  animation-name: fadeInOut;
  animation-delay: 8.5s;
  animation-duration: 9s;
  animation-iteration-count: infinite;
  text-shadow: 1px 1px 1px;
}