@import url("https://fonts.cdnfonts.com/css/mitr");

body {
  font-family: "Mitr", sans-serif;
  font-weight: 500;
  font-size: 1.1rem;
  margin-top: -25px;
  text-align: center;
  background-color: #6e5c62;
  color: #fafaff;
}

#titulo {
  font-weight: 600;
  margin-bottom: 0;
}

#quadro {
  width: 400px;
  height: 450px;
  margin: 0 auto;
  margin-top: 3px;
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: center;
}

.bloco {
  box-sizing: border-box;
  border: 6px solid #4c4347;
  width: calc((100% - 16px) / 5);
  aspect-ratio: 1 / 1;
  margin: 0px;
  border-radius: 10%;
  cursor: pointer;
  overflow: hidden;
  line-height: 1;

  color: #fafaff;
  font-weight: 600;
  font-size: 3rem;
  display: flex;
  justify-content: center;
  align-items: center;
}

.bloco[data-row="ativo"] {
  background-color: transparent;
}

.bloco:not([data-row="ativo"]):not(.correto):not(.presente):not(.ausente) {
  background-color: #615458 !important;
  border-color: #615458;
}

.correto {
  background-color: #3aa394 !important;
  border-color: #3aa394;
  opacity: 1;
}

.presente {
  background-color: #d3ad69 !important;
  border-color: #d3ad69;
  opacity: 1;
}

.ausente {
  background-color: #302a2c !important;
  border-color: #302a2c;
  opacity: 1;
}

.linha_teclado {
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: 4px;
  flex-wrap: nowrap;
}

.tecla {
  background-color: #4d4347;
  width: 60px;
  height: 70px;
  margin: 2px;
  margin-top: 5px;
  border-radius: 8%;
  box-sizing: border-box;

  color: #fafaff;
  font-size: 26px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.tecla[data-tecla="ENTER"] {
  width: 150px;
  margin-left: 10px;
}

.tecla[data-tecla="⌫"] {
  margin-left: 30px;
}

#toast-notification {
  position: fixed;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #009afe;
  color: #fafaff;
  padding: 0.2em 1em;
  border-radius: 0.4em;
  z-index: 20000;
  transition: top 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  font-weight: 400;
  font-size: 2.5vh;
  text-align: center;
}
#toast-notification.show {
  top: 50px;
}
.cursor {
  box-shadow: inset 0 -0.15em 0 #4c4347;
  cursor: pointer;
}

@keyframes pop {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

.pop {
  animation: pop 0.15s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes flip {
  0% {
    transform: perspective(400px) rotateY(0);
  }
  50% {
    transform: perspective(400px) rotateY(90deg);
  }
  50.1% {
    transform: perspective(400px) rotateY(270deg);
  }
  100% {
    transform: perspective(400px) rotateY(360deg);
  }
}

.flip {
  animation: flip 0.45s ease-in-out;
}

@keyframes shake {
  0% {
    transform: translateX(0);
  }
  10% {
    transform: translateX(-10px);
  }
  20% {
    transform: translateX(10px);
  }
  30% {
    transform: translateX(-10px);
  }
  40% {
    transform: translateX(10px);
  }
  50% {
    transform: translateX(-6px);
  }
  60% {
    transform: translateX(6px);
  }
  70% {
    transform: translateX(-3px);
  }
  80% {
    transform: translateX(3px);
  }
  100% {
    transform: translateX(0);
  }
}

.shake {
  animation: shake 0.8s cubic-bezier(0.25, 0.8, 0.5, 1);
}

@media (max-width: 768px) {
  body {
    margin-top: -15px;
    font-size: 1rem;
  }

  #titulo {
    font-size: 2rem;
    margin-top: 10px;
  }

  #quadro {
    width: 90vw;
    max-width: 350px;
    height: auto;
    gap: 3px;
  }

  .ausente {
    background-color: #302a2c !important;
    border-color: #302a2c;
    opacity: 1;
  }

  .bloco.correto,
  .bloco.presente,
  .bloco.ausente {
    border-style: solid !important;
  }

  .bloco.correto {
    border-color: #3aa394 !important;
  }
  .bloco.presente {
    border-color: #d3ad69 !important;
  }
  .bloco.ausente {
    border-color: #302a2c !important;
  }
  .bloco {
    border: 5px solid #4d4347;
    font-size: 32px;
  }

  .linha_teclado {
    gap: 3px;
    margin-bottom: 5px;
  }

  .tecla {
    width: 50px;
    height: 55px;
    margin: 1px;
    margin-top: 3px;
    font-size: 20px;
    border-radius: 6%;
  }

  .tecla[data-tecla="ENTER"] {
    width: 120px;
    margin-left: 5px;
  }

  .tecla[data-tecla="⌫"] {
    margin-left: 20px;
  }
}

@media (max-width: 480px) {
  body {
    margin-top: -10px;
    font-size: 0.95rem;
  }

  .bloco.correto,
  .bloco.presente,
  .bloco.ausente {
    border-width: 4px !important;
  }

  #titulo {
    font-size: 1.6rem;
    margin-top: 8px;
  }

  #quadro {
    width: 95vw;
    max-width: 300px;
    gap: 4 px;
  }

  .bloco {
    border: 4px solid #4d4347;
    font-size: 28px;
  }

  .linha_teclado {
    gap: 2px;
    margin-bottom: 4px;
  }

  .tecla {
    width: 38px;
    height: 45px;
    margin: 1px;
    margin-top: 2px;
    font-size: 16px;
    border-radius: 10%;
    padding: 0;
  }

  .tecla[data-tecla="ENTER"] {
    width: 90px;
    margin-left: 3px;
    font-size: 14px;
  }

  .tecla[data-tecla="⌫"] {
    width: 45px;
    margin-left: 3px;
  }
}
