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

:root {
  --background: #171823;
  --primary-color: #25273d;
  --secondary-color: #c058f3;
  --acent-color: #00ffc4;
  --text-color: #f9f9f9;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Marcellus", serif;
  letter-spacing: -0.35px;
}
body {
  width: 100%;
  height: auto;
  background-color: var(--background);
}
.top-section {
  width: 100%;
  height: 12rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  row-gap: 1.6rem;
  background-color: grey;
  background-image: url(Bitmap.jpg);
  border-radius: 0.6rem 0.6rem 0rem 0rem;
}

.main-container {
  width: 100%;
  height: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  row-gap: 4rem;
}
h1 {
  margin-top: 100px;
  margin-bottom: 20px;
  font-size: 3rem;
  font-weight: 800;
  text-align: center;
  color: var(--text-color);
}
#todo-input {
  box-sizing: border-box;
  padding: 0.6rem 6rem;
  width: 100%;
  background: none;
  border: 2px solid var(--secondary-color);
  border-radius: 0.6rem;
  color: #f4f4f4;
}

#todo-input:focus {
  outline: none;
}
form {
  position: relative;
}

#add-button {
  position: absolute;
  top: 0;
  right: 0;
  background-color: var(--secondary-color);
  height: 100%;
  padding: 0 0.8rem;
  border: none;
  border-radius: 0.6rem;
  font-weight: 500;
  color: #171823;
  cursor: pointer;
}
.todo {
  margin-bottom: 10px;
  padding: 0 16px;
  background-color: var(--primary-color);
  border-radius: 0.8rem;
  display: flex;
  align-items: center;
}
.todo .todo-text {
  padding: 0.6rem;
  padding-right: 0;
  flex-grow: 1;
  align-items: center;
}
.item-container {
  width: 28%;
  height: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0.8rem;
  background-color: var(--primary-color);
  border-radius: 0.6rem;
}
.delete-button {
  padding: 0.1rem;
  background: none;
  border: none;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
}
.delete-button:hover img {
  background-color: #ff0033;
}
.custom-checkbox {
  border: 2px solid var(--secondary-color);
  border-radius: 50%;
  min-height: 20px;
  min-width: 20px;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
  transition: 200ms ease;
  cursor: pointer;
}
.todo-text {
  color: #ffffff;
}

input[type="checkbox"]:checked ~ .custom-checkbox {
  background-color: var(--secondary-color);
}

input[type="checkbox"]:checked ~ .custom-checkbox img {
  fill: var(--primary-color);
}

input[type="checkbox"]:checked ~ .todo-text {
  text-decoration: line-through;
  color: var(--secondary-color);
}

input[type="checkbox"] {
  display: none;
}
@media (max-width: 500px) {
  html {
    font: 10px;
  }
  h1 {
    margin-top: 100px;
    margin-bottom: 20px;
    font-size: 0.6rem;
    font-weight: 800;
    text-align: center;
    color: var(--text-color);
  }
  .top-section {
    width: 100%;
    height: 12rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    row-gap: 4rem;
  }
  .main-container {
    width: 100%;
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    row-gap: 7.8rem;
  }
  #add-button {
    position: unset;
    width: 100%;
    margin-top: 10px;
    padding: 15px;
    height: auto;
  }
  #todo-input {
    box-sizing: border-box;
    padding: 0.6rem 3rem;
    width: 100%;
    background: none;
    border: 2px solid var(--secondary-color);
    border-radius: 0.6rem;
    color: #f4f4f4;
  }

  h1 {
    margin-top: 50px;
    font-size: 15vw;
  }
  .item-container {
    width: 75%;
    height: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.8rem;
    background-color: var(--primary-color);
    border-radius: 0.3rem;
  }
}
