@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100..900;1,100..900&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: url("./Assets/pexels-crazy-motions-80195021-12198537.jpg");
  background-size: cover;
  background-position: center;
  width: 100vw;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: "Roboto", sans-serif;
}

body::before {
  content: "";
  position: absolute;
  width: 100vw;
  height: 100vh;
  background: rgb(0, 0, 0, 0.15);
  backdrop-filter: blur(10px);
}

.container {
  height: 660px;
  width: 480px;
  display: flex;
  flex-direction: column;
  padding: 1rem;
  z-index: 1;
  background-color: rgba(255, 255, 255, 0.15);
  border-radius: 1rem;
  text-align: center;
  border: 2px solid rgba(255, 255, 255, 0.1);
}
h1 {
  margin-bottom: 1rem;
  color: rgba(255, 255, 255, 0.9);
}

.header {
  display: flex;
  padding: 1rem;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  height: 4rem;
  margin-bottom: 1rem;
  h1 {
    padding: 0;
    margin: 0;
  }
  h2 {
    color: rgba(0, 0, 0, 0.7);
    font-size: large;
  }
}

.add-todo {
  width: 100%;
  height: 2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  input {
    width: 90%;
    height: 2rem;
    border-radius: 1rem;
    border-style: none;
    padding: 1rem;
    padding-right: 4rem;
    font-size: 1rem;
    font-weight: bold;
  }
  .add {
    position: absolute;
    right: 2rem;
    cursor: pointer;
  }
}

.todos {
  height: 70%;
  margin-top: 2rem;
  padding: 2rem 1rem;
  background-color: rgba(0, 0, 0, 0.1);
  text-align: center;
  overflow: scroll;
  overflow-x: hidden;
  border-radius: 1rem;
  ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }
  li {
    display: flex;
    justify-content: space-between;
    color: rgba(0, 0, 0, 0.9);
    padding: 0.6rem;
    background-color: white;
    border-radius: 3rem;
    padding: 0.5rem 1.5rem;
  }
}

.todos::-webkit-scrollbar {
  width: 5px;
}

.todos::-webkit-scrollbar-track {
  background-color: rgba(0, 0, 0, 0.15);
}

.todos::-webkit-scrollbar-thumb {
  background-color: rgba(255, 255, 255, 0.5);
}

.remove {
  cursor: pointer;
}

.done {
  text-decoration: line-through;
}

.buttons {
  display: flex;
  width: 100%;
  height: auto;
  justify-content: center;
  gap: 4rem;
  .btn {
    border: none;
    padding: 0.5rem 1rem;
    margin-top: 1rem;
    background-color: rgba(255, 255, 255, 0.7);
    border-radius: 1rem;
    cursor: pointer;
    color: rgba(0, 0, 0, 0.9);
    font-weight: bold;
  }
}

@media (max-width: 400px) {
  .container {
    height: 600px;
    width: 350px;
    display: flex;
    flex-direction: column;
    padding: 1rem;
    z-index: 1;
    background-color: rgba(255, 255, 255, 0.15);
    border-radius: 1rem;
    text-align: center;
    border: 2px solid rgba(255, 255, 255, 0.1);
    margin: 0rem 1rem;
  }
  h1 {
    margin-bottom: 1rem;
    color: rgba(255, 255, 255, 0.9);
  }
  .header {
    display: flex;
    padding: 0.5rem;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    height: 4rem;
    margin-bottom: 1rem;
    h1 {
      padding: 0;
      margin: 0;
      font-size: 1.1rem;
      width: 40%;
    }
    h2 {
      color: rgba(0, 0, 0, 0.7);
      font-size: 1.1rem;
      width: 40%;
    }
  }
  .add-todo {
    width: 100%;
    height: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    input {
      width: 90%;
      height: 1rem;
      border-radius: 1rem;
      border-style: none;
      padding: 1rem;
      padding-right: 4rem;
      font-size: 0.7rem;
      font-weight: bold;
    }
    .add {
      position: absolute;
      right: 2rem;
      cursor: pointer;
    }
  }
}
