@import url("../../root/root.css");

#title {
  font-family: var(--title-font);
  font-size: var(--title-size);
  font-weight: var(--title-weight);
  background-color: var(--duck-yellow);
  color: var(--duck-charcoal);
  width: fit-content;
  height: auto;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0 auto 0.1rem auto;
  cursor: pointer;
  border-radius: 1.8rem;
  box-shadow: 0 0.4rem 1.6rem rgba(44, 44, 44, 0.12);
  padding: 0 2.2rem;
    margin-bottom: 1.5rem;
}

#title span {
  display: inline-block;
  opacity: 1;
  transform: translateY(0);
  transition: transform 0.3s ease;
}

#title:hover {
  cursor: grab;
}

/* JIGGLE ANIMATION */
/* --------------------------------------------------------------------- */
@keyframes jiggle {
  0% {
    transform: rotate(0deg);
  }
  25% {
    transform: rotate(10deg);
  }
  50% {
    transform: rotate(-10deg);
  }
  75% {
    transform: rotate(5deg);
  }
  100% {
    transform: rotate(0deg);
  }
}

#title:hover span {
  animation: jiggle 0.6s ease-in-out;
}

/* LETTER WAVE ANIMATION */
/* ----------------------------------------------------------------------- */
@keyframes bounce {
  0% {
    transform: translateY(1rem);
  }
  50% {
    transform: translateY(-1rem);
  }
  100% {
    transform: translateY(0);
  }
}

#title span:nth-child(1) {
  animation-delay: 0.1s;
}
#title span:nth-child(2) {
  animation-delay: 0.2s;
}
#title span:nth-child(3) {
  animation-delay: 0.3s;
}
#title span:nth-child(4) {
  animation-delay: 0.4s;
}
#title span:nth-child(5) {
  animation-delay: 0.5s;
}
#title span:nth-child(6) {
  animation-delay: 0.6s;
}
#title span:nth-child(7) {
  animation-delay: 0.7s;
}
#title span:nth-child(8) {
  animation-delay: 0.8s;
}
#title span:nth-child(9) {
  animation-delay: 0.9s;
}
#title span:nth-child(10) {
  animation-delay: 1s;
}

/* Trigger animation */
#title.animate span {
  animation: bounce 0.5s ease-in-out forwards;
}

/* TABLET SIZE 480 -1023 */
/* ---------------------------------------------------------------------------- */
@media (min-width: 480px) and (max-width: 1023px) {
#title {
    font-size: 2.8rem;
        padding: 0 1.2rem;   
    padding: 0 1.2rem;      
    margin: 0 auto 0.7rem auto; 
    border-radius: 1.6rem;        
    min-height: 2.8rem;      
    box-shadow: 0 0.2rem 0.8rem rgba(44,44,44,0.12);    

    margin-bottom: 1rem;
}
}

/* MOBILE SIZE 479 */
/* ---------------------------------------------------------------------------- */
@media (max-width: 479px) {
  #title {
        padding: 0 1.2rem;   
            font-size: 2rem;    
    padding: 0 1.2rem;      
    margin: 0 auto 0.7rem auto; 
    border-radius: 1.5rem;        
    min-height: 2.8rem;      
    box-shadow: 0 0.2rem 0.8rem rgba(44,44,44,0.12);    

    margin-bottom: 0.5rem;
  }

}

