@import url("https://fonts.googleapis.com/css2?family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap");

:root {
  --ffPoppins: "Poppins", sans-serif;
  --ffNunitoSans: "Nunito Sans", sans-serif;

  --bodyBgColor: #f0f8ff;
  --colorWhite: #fff;

  --pendingBG: #ffa500;
  --completedBG: #28a745;
  --urgentActionBG: #dc3545;

  --instaThemeColor1: rgba(142, 156, 123, 0.5);
  --instaThemeColor2: rgba(125, 135, 110, 0.75);
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: var(--ffPoppins);
  user-select: none;
}
svg {
  height: 24px;
}
li {
  list-style: none;
}
html {
  background: #7d876e;
}
/*  */
body {
  background: var(--bodyBgColor);
  background: linear-gradient(var(--instaThemeColor1), var(--instaThemeColor2));
}
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  background: url("https://img.freepik.com/free-vector/vector-white-lotus-flower-pad-pond-isolated-blur-background_1284-48393.jpg");
  height: 100vh;
  width: 100vw;
  z-index: -1;
  background-position: center;
  background-size: cover;
}

/*  */
header {
  height: 60px;
  align-content: center;
}
.logo-container {
  display: flex;
  align-items: center;
  padding: 12px;
  width: fit-content;
  max-height: 100%;
  gap: 8px;
}
.logo-container h1 {
  font-size: 1.5em;
}
/*  */
main {
  min-height: 100dvh;
}
.container {
  padding: 12px;
}
.row {
  display: flex;
  align-items: center;
  padding: 4px;
  position: relative;
  background: var(--bodyBgColor);
  position: sticky;
  top: 12px;
  z-index: 1;

  box-shadow: 0 0 12px -6px;
  border-radius: 12px;

  background: transparent;
  backdrop-filter: blur(12px);
}

.row label {
  position: absolute;
  background: var(--bodyBgColor);
  padding-left: 18px;
  width: 100%;
  left: 0;
  transition: all 0.3s ease;
  height: 100%;
  align-content: center;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  border-radius: 12px;

  display: none;
}
.row #input-box {
  width: calc(100% - 85px);
  padding: 16px;
  font-size: 1em;
  border: 0;
  background: transparent;
  border-radius: 12px 0 0 12px;

  color: var(--colorWhite);
  z-index: 1;
}
.row #input-box:focus {
  outline: 0;
}
.row #input-box::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.labelActive {
  font-size: 0.7em;
  transform: translate(-12px, -40px);
  transition: transform 0.3s ease, font-size 0.3s ease;
  background: none !important;
  height: unset;
}

#addButton {
  position: absolute;
  background: #007bff;
  color: var(--colorWhite);
  font-size: 1em;
  right: 0;
  height: 100%;
  width: 100px;
  border: 0;
  border-radius: 36px 12px 12px 36px;
  transition: 0.3s ease;
}
#addButton:active {
  background: #0056b3;
}
/*  */
.tasks-container {
  padding: 4px;
}
.tasks-ul {
  display: flex;
  flex-direction: column;
}

.tasks-ul li {
  padding: 12px;
  display: flex;
  flex-direction: column;
  border-radius: 12px;
  cursor: pointer;
  margin-bottom: 6px;

  background: var(--colorWhite);
  /* box-shadow: 0 0 6px -4px black; */

  background-size: contain;
  background: rgba(0, 0, 0, 0.25);
  background-image: url(/assets/noiseEffect-50.avif);
  background-position: center;
  color: var(--colorWhite);
}
.task-text {
  position: relative;
  max-width: calc(100% - 32px);
  padding-right: 6px;
  user-select: text;
}
.task-text::before {
  content: "";
  position: absolute;
  height: 32px;
  aspect-ratio: 1;
  background: url(assets/unchecked.png);
  right: -32px;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
}
.task-Extra-Info {
  display: flex;
  justify-content: space-between;
  margin-top: 18px;
}
.task-Status {
  background: var(--pendingBG);
  font-size: 0.75em;
  border-radius: 6px;
  padding: 6px;
}
.task-Time {
  font-size: 0.75em;
  display: grid;
  place-items: center;
  padding: 6px;
  color: #444;
  color: rgba(255, 255, 255, 0.5);
}
/*  */
li.completed {
  margin-bottom: 24px;
}
li.completed .task-text {
  text-decoration: line-through;
}
li.completed .task-text::before {
  background: url(assets/checked.png);
  background-size: contain;
}
li.completed .task-Status {
  background: var(--completedBG);
  color: var(--colorWhite);
}
/*  */
.date-header {
  margin: 10px 0;
  padding: 5px;
  border-radius: 4px;
}
.task-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column-reverse;
}

/*  */
/*  */
.delete-button {
  margin-left: 10px;
  padding: 6px 18px;
  background-color: #ff4444;
  color: var(--colorWhite);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  width: fit-content;
  margin-top: 26px;
  position: absolute;
  right: 24px;
}

.delete-button:hover {
  background-color: #cc0000;
}

.completed .delete-button {
  display: inline-block;
}
/*  */
/*  */
.row-2 {
  margin-top: 16px;
}
.tasks-count-container {
  display: flex;
  gap: 12px;
}
.pending-tasks-cnt,
.completed-tasks-cnt {
  border-radius: 12px;
  padding: 12px;
  display: flex;
  justify-content: center;
  gap: 6px;
}
.pending-tasks-cnt span:nth-child(1),
.completed-tasks-cnt > span:nth-child(1) {
  font-size: 0.75em;
  align-content: center;
}
.pending-tasks-cnt span:nth-child(2),
.completed-tasks-cnt > span:nth-child(2) {
  min-width: 36px;
  text-align: center;
  font-family: var(--ffNunitoSans);
  font-weight: 600;
}
.pending-tasks-cnt {
  background: var(--pendingBG);
}
.completed-tasks-cnt {
  background: var(--completedBG);
  color: var(--colorWhite);
}
