/*red usar sempre background red pra mostrar posicionamentos!!! red*/


/* imports */

@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,300;0,400;0,500;0,600;1,400&display=swap');

/* resets */

* {
  box-sizing: border-box; /* inclui o preenchimento e a borda ao valor de altura e largura setado no seu elemento */
  font-family: 'Poppins', sans-serif; /* baixar em https://fonts.google.com/specimen/Poppins?preview.size=33&query=po */ 
  font-size: 10px; /* ensinar truque de uma boa referência pro rem */
  margin: 0; /* explicar importância de resetar margin e padding */
  padding: 0;
  list-style: none;
  /* text-decoration: none; --> explicar outros resets possiveis */
}

/* viewport */

body {
  min-height: 100vh; /* o body sempre terá altura total da janela de visualização, em qualquer dispositivo, todos os itens dentro desse elemento ficam em linha ocupando o espaço necessário dentro do container */
  width: 100%;
  background-color: #ff9ff370; /* jiggly puff - https://flatuicolors.com/palette/ca */
  display: flex;
  justify-content: center;
  align-items: center;
}

/* red Criar essa parte somente quando nestiver criando o JavaScript red */
.erro {
  animation: alerta .3s linear;
}

@keyframes alerta {
  0% {
    border: solid 1px #ee5253;
    background-color: #ff6b6b50;
  }
  25% {
    border: solid 1px #c8d6e5;
  }
  50% {
    border: solid 1px #ee5253;
  }
  75% {
    border: solid 1px #c8d6e5;
  }
  100% {
    border: solid 1px #ee5253;
    background-color: #ff6b6b50;
  }
}

.checked:before { /* acrescentar durante a construção do script.js */
  content: "🟣"!important;
}

/* container principal */

.container_principal {
  background-color: #f3f3f3;
  min-width: 40rem;
  max-height: 60vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2.5rem;
  border-radius: 1rem;
  box-shadow: 2px 4px 10px #57657450;
}

.titulo_lista {
  margin: 2rem 0 3rem;
  font-size: 2.5rem;
  color: #2e86de;
}

/* formulário */

.form_add {
  display: flex;
  justify-content: center;
  margin-bottom: 3rem;
  width: 95%;
}

.input_add {
  width: 30rem;
  height: 100%;
  padding: 1.2rem 1rem;
  background-color: #c8d6e5;
  outline: none; /* explicar */
  border: solid 1px #c8d6e5; /* explicar pq não usar border: none */
  border-radius: .8rem 0 0 .8rem; /* explicar */
  font-size: 1.4rem;
}

.input_add:focus { /* explicar */
  border: solid 1px #00d2d3;
  border-right: none;
}

.button_add {
  background-color: #54a0ff;
  color: #f3f3f3;
  padding: 0 1rem;
  font-size: 1.5rem;
  border-radius: 0 .8rem .8rem 0; /* explicar */
  border: none;
  cursor: pointer;
  transition: linear 0.3s;
}

.button_add:hover {
  background-color: #2e86de;
  transition: linear 0.3s;
}

/* container de tarefas */

.container_tarefas {
  width: 95%;
  min-height: 10rem;
  border-radius: .5rem;
  padding: 1rem 0; 
  overflow-y: auto;
  display: none;
}

.lista_tarefas {
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
}

li {
  display: flex;
  justify-content: space-between;
  color: #222f3e;
  padding: .8rem .5rem;
}

li > p, li > span {
  font-size: 1.4rem;
}

li > p {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 80%;
}

li > p:before {
  content: "🔘";
  font-size: 1.2rem;
  margin-right: .5rem;;
}

/* modelo de amostra red criar somente depois da primeira parte completa */

.modelo {
  width: 95%;
  min-height: 10rem;
  border-radius: .5rem;
  padding: 1rem 0; 
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.modelo_tarefa {
  width: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  background: #8395a770;
  border-radius: 1rem;
  padding: 1rem; 
}

.modelo_conteudo {
  padding: .8rem .5rem;
  background: #c3f3d990;
  border-radius: .5rem;
}

.modelo_tarefa:last-child {
  opacity: .6;
}


/* container de botões */

.container_botoes {
  width: 95%;
  display: flex;
  align-items: center;
  justify-content: space-evenly; /* mostrar com background red */
  margin: 3rem 0 2rem;
}

.button_marca {
  background-color: #54a0ff;
  border: solid 1px #54a0ff;
  color: #f3f3f3;
  padding: 1.2rem 1rem;
  font-size: 1.5rem;
  border-radius: .8rem;
  cursor: pointer;
  transition: linear 0.3s;
}

.button_limpa {
  background-color: #f368e0;
  border: solid 1px #f368e0;
  color: #f3f3f3;
  padding: 1.2rem 1rem;
  font-size: 1.5rem;
  border-radius: .8rem;
  cursor: pointer;
  transition: linear 0.3s;
} 

/*
após escrever separados juntar tudo que for em comum nos botões em:

.button_marca, .button_limpa {
  color: #f3f3f3;
  padding: 1.2rem 1rem;
  font-size: 1.5rem;
  border-radius: .8rem;
  cursor: pointer;
  transition: linear 0.3s;
}
*/

.button_marca:hover {
  background-color: #f3f3f3;
  color: #54a0ff;
  transition: linear 0.3s;
}

.button_limpa:hover {
  background-color: #f3f3f3;
  color: #f368e0;
  transition: linear 0.3s;
}

/* media queries */

@media only screen and (max-width: 480px) {
  .container_principal {
    min-width: 30rem;
    padding: 1.5rem;
  }
  
  .titulo_lista {
    margin: 2rem 0;
    font-size: 2rem;
  }

  .form_add {
    flex-direction: column;
    margin-bottom: 2rem;
  }
  
  .input_add {
    width: 100%;
    border-radius: .8rem;
    font-size: 1.2rem;
  }
  
  .input_add:focus {
    border-right: solid 1px #00d2d3;
  }
  
  .button_add {
    padding: .5rem;
    font-size: 1.3rem;
    border-radius: .8rem;
    margin-top: .5rem;
  }

  li {
    font-size: 1.2rem;
  }

  .modelo {
    min-height: 7rem;
    padding: .5rem 0; 
  }

  .modelo_tarefa {
    padding: .7rem; 
  }
  
  .modelo_conteudo {
    padding: .6rem .5rem;
  }

  .container_botoes {
    /* width: 100%; */
    flex-direction: column;
    margin: 2rem;
  }
  
  .button_marca, .button_limpa {
    padding: .5rem;
    font-size: 1.3rem;
    width: 100%;
  }
  .button_limpa {
    margin-top: .5rem ;
  }
}
