/*BODY*/
:root {
  --clr-primary: rgb(161, 192, 238);
  --clr-light: #f4f4f4;
  --clr-dark: #333;
  --clr-warning: rgb(99, 36, 36);
}

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

body {
  font-family: "Roboto", sans-serif;
  font-size: 1.5rem;
  font-weight: 400;
  color: whitesmoke;
  /* background-image: linear-gradient(
    to left top,
    #7a1825,
    #8a2430,
    #9b2f3c,
    #ac3b48,
    #bd4655,
    #bd4655,
    #bd4655,
    #bd4655,
    #ac3b48,
    #9b2f3c,
    #8a2430,
    #7a1825
  ); */
  /* background-image: url("https://source.unsplash.com/1920x1024/?iceland"); */
  background-image: url(./connor-dugan-2l9BhKOvSNI-unsplash.jpg);
  background-repeat: no-repeat;
  background-size: cover;
  background-attachment: fixed;
  height: 100vh;
}

img {
  filter: brightness(10%);
}

.material-symbols-outlined {
  font-variation-settings: "FILL" 0, "wght" 900, "GRAD" 0, "opsz" 48;
}

/*MAIN*/
#main {
  display: grid;
  grid:
    "header header header header" auto
    "...... lists  active ......" auto /
    1fr minmax(100px, 300px)
    minmax(250px, 500px) 1fr;
}

.title {
  grid-area: header;
  font-size: calc(7vw + 2rem);
  font-weight: 900;
  color: rgba(0, 0, 0, 0.3);
  letter-spacing: 1rem;
}

.all-tasks {
  grid-area: lists;
  background-color: rgba(0, 0, 0, 0.3);
}

.task-list {
  font-size: 1.2rem;
  line-height: 1.7;
  list-style: circle;
  padding-left: 1.5rem;
}

.active-list {
  font-weight: 900;
}

.list-name {
  cursor: pointer;
}

.list-name:hover {
  opacity: 0.7;
}

.todo-list {
  --spacer: 2rem;

  grid-area: active;
  background-color: rgba(0, 0, 0, 0.3);
}

.form {
  display: flex;
}

.btn {
  cursor: pointer;
  background: 0;
  padding: 0;
  border: 0;
  color: inherit;
}

.btn.create {
  font-size: 1.5rem;
  margin-right: 0.25rem;
  transition: opacity 250ms ease-in;
}

.btn.create:hover {
  opacity: 0.7;
}

.btn.delete {
  font-size: 1rem;
}

.btn.delete:hover {
  color: var(--clr-warning);
}

.new {
  background: transparent;
  border: 0;
  color: inherit;
  border-bottom: 1px solid currentColor;
  padding: 0.25em;
  font-size: inherit;
  outline: none;
  transition: border-bottom 150ms ease-in;
  order: 2;
}

.new:focus {
  border-bottom-width: 3px;
}

.new:focus::placeholder {
  opacity: 0.2;
}

.new.list {
  font-size: 1.1rem;
}

.new.task {
  margin-bottom: 0;
}

.todo-header,
.task-list-title {
  padding: var(--spacer);
  background-color: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.task-list-title {
  height: 4em;
}

.list-title {
  margin: 0 1rem 0 0;
}

.task-count {
  margin: 0;
  font-size: 1rem;
}

.todo-body {
  padding: var(--spacer);
  position: relative;
}

[type="checkbox"] {
  opacity: 0;
  position: absolute;
}

.task label {
  display: inline-flex;
  align-items: center;
  position: relative;
}

.task {
  position: relative;
  margin-bottom: 1.25rem;
}

.task::after {
  content: "";
  position: absolute;
  right: 0;
  left: 0;
  bottom: -0.5em;
  height: 1px;
  background: currentColor;
  opacity: 0.1;
}

.custom-checkbox {
  --size: 0.75em;
  display: inline-block;
  width: var(--size);
  height: var(--size);
  margin-right: var(--size);
  cursor: pointer;
  border: 2px solid currentColor;
  border-radius: 50%;
  transform: scale(1);
  transition: transform 250ms ease-in-out;
}

.task:hover .custom-checkbox,
[type="checkbox"]:focus + label .custom-checkbox {
  -webkit-transform: scale(1.2);
  transform: scale(1.2);
  color: var(--clr-primary);
}

[type="checkbox"]:checked + label .custom-checkbox {
  background: var(--clr-primary);
  border-color: var(--clr-primary);
  box-shadow: inset 0 0 0px 2px white;
}

[type="checkbox"]:checked + label {
  opacity: 0.5;
}

.task label::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  left: 1.5em;
  top: 50%;
  height: 3px;
  background: currentColor;
  -webkit-transform: scaleX(0);
  transform: scaleX(0);
  -webkit-transform-origin: right;
  transform-origin: right;
  transition: -webkit-transform 150ms ease-in-out;
  transition: transform 150ms ease-in-out;
  transition: transform 150ms ease-in-out, -webkit-transform 150ms ease-in-out;
}

[type="checkbox"]:checked + label::after {
  -webkit-transform: scaleX(1);
  transform: scaleX(1);
  -webkit-transform-origin: left;
  transform-origin: left;
}

.delete-stuff {
  display: flex;
  justify-content: space-evenly;
  position: absolute;
  width: 100%;
  left: 0;
  bottom: -18px;
  color: whitesmoke;
}
