@import url('https://fonts.googleapis.com/css2?family=Audiowide&display=swap');

:root{
  --main-font: 'Audiowide', Tahoma, Geneva, Verdana, sans-serif;
  --primary-color: #e2cbf4;
  --secondary-color: #8f35d3;
}

body {
  position: relative;
  margin: 0px;
  background-image: linear-gradient(rgba(0, 0, 0, 0.383),rgba(34, 27, 58, 0.459)), url(./img/desk1.jpg);
  background-size: cover;        /* L’image couvre toute la page */
  background-repeat: no-repeat;  /* Empêche la répétition de l’image */
  background-position: center;   /*Centre l’image dans la fenêtre */
  background-attachment: fixed;
  font-family: var(--main-font);
  color: white;
  font-size: 22px;
}
.todolist {
  width: 440px;
  height: auto;
  min-height: 400px;;
  margin: auto;
  backdrop-filter: blur(7px);
  border: 2px solid var(--secondary-color);
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  padding: 20px;
  margin-top: 60px;
}
#title {
  text-align: center;
  color: var(--primary-color);
  font-size: 48px;;
}
.addTask {
  width: 100%;
  margin-top: 30px;
  text-align: center;
}
.addTitle {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}
.addInfos {
  margin-top: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  /* gap: 10px; */
}
#new-task-input {
  margin: auto;
  display: block;
  width: 70%;
  background-color: rgba(231, 203, 251, 0.11);
  border: 2px solid var(--secondary-color);
  border-radius: 50px;
  padding: 10px;
  color: var(--primary-color);
  font-family: var(--main-font);
  font-size: 22px;
}
#new-task-descr-input {
  margin: 10px;
  padding: 5px;
  display: block;
  width: 70%;
  background-color: rgba(231, 203, 251, 0.11);
  border: 2px solid var(--secondary-color);
  border-radius: 30px;
  color: grey;
  font-family: var(--main-font);
  font-size: 16px;
}
#new-task-date-input {
  margin: 10px;
  padding: 5px;
  display: block;
  width: 38%;
  background-color: rgba(231, 203, 251, 0.11);
  border: 2px solid var(--secondary-color);
  border-radius: 30px;
  color: grey;
  font-family: var(--main-font);
  font-size: 12px;
}
#submit {
  width: 30px;
  height: 30px;
  margin: auto;
  display: block;
  background-color: var(--secondary-color);
  border: 1px solid var(--secondary-color);
  color: var(--primary-color);
  border-radius: 50px;
  padding: 10px ;
  font-family: var(--main-font);
  font-size: 22px;
  text-align: center;
  cursor: pointer;
}
#submit:hover {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: 1px solid var(--secondary-color);
}
.taskList{
  margin: 30px 30px;
  list-style-type: none;
}
.taskItem {
  background-color: rgba(231, 203, 251, 0.11);
  border: 2px solid var(--secondary-color);
  border-radius: 10px;
  padding: 10px;
  margin-bottom: 10px;
}
.taskItem p{
  /* flex-grow: 1; */
  margin: 0;
}
.delete, .edit {
  margin-left: 10px;
  background-color: transparent;
  border: 1px solid var(--primary-color);
  padding: 8px;
  border-radius: 50px;
  color: var(--primary-color);
  font-size: 20px;
  cursor: pointer;
}
.edit {
  margin-left: auto;
}
#delete:hover, #edit:hover {
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: 1px solid var(--secondary-color);
}
.completed p{
  text-decoration: line-through;
  font-style: italic;
  opacity: 0.6;
}
.taskLine{
  display: flex;
  align-items: center;
}
.taskDescription{
  font-size: 15px;
  color: var(--primary-color);
  padding-left: 50px;
}
.taskDate{
  font-size: 12px;
  color: var(--primary-color);
  padding-left: 50px;
  padding-top: 5px;
  font-style: italic;
}

/* ! BUTTONS */

.filter{
  margin-left: 16px;
  margin-top: 15px;
}
button{
  background-color: var(--secondary-color);
  color: var(--primary-color);
  border-radius: 15px;
  border: 1px solid var(--secondary-color);
  padding: 8px;
  cursor: pointer;
  font-size: 14px;
  font-family: var(--main-font);
  margin-right: 20px;
}
button:hover{
  background-color: var(--primary-color);
  color: var(--secondary-color);
  border: 1px solid var(--secondary-color);
}


/* ? CHECKBOX */

input[type=checkbox] {    /* Supprime le style par défaut */
    -webkit-appearance: none;
    appearance: none;
    -moz-appearance: none;
    -ms-appearance: none;
}

input[type="checkbox"] {
  border-radius: 4px;
  height: 15px;
  width: 15px;
  background-color: rgba(234, 212, 250, 0.441);;
  border: 1px solid var(--secondary-color);
  cursor: pointer;
  margin-right: 10px;
}

input[type="checkbox"]:checked {
  background-color: var(--secondary-color);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}
