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

body {
  font-family: 'Segoe UI', sans-serif;
  background: linear-gradient(to right, #0f2027, #203a43, #2c5364);
  color: #f0f0f0;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.container {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  border-radius: 12px;
  padding: 2rem;
  width: 90%;
  max-width: 500px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  color: #f0f0f0;
}

h1 {
  text-align: center;
  margin-bottom: 1rem;
  color: #8ec5fc;
}

.input-group {
  display: flex;
  gap: 10px;
  margin-bottom: 0.6rem;
}

#todoInput {
  flex: 1;
  padding: 10px;
  font-size: 16px;
  background: #1b2b34;
  color: #f0f0f0;
  border: 2px solid #8ec5fc;
  border-radius: 6px;
}

#addTodoButton {
  background: #8ec5fc;
  color: white;
  border: none;
  padding: 10px 16px;
  font-size: 16px;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.3s;
}
#addTodoButton:hover {
  background: #1b2b34;
}

.date-time-row {
  display: flex;
  gap: 10px;
  margin-bottom: 1rem;
}

.date-time-row input[type="date"], .date-time-row input[type="time"] {
  flex: 1;
  padding: 10px;
  font-size: 16px;
  background: #1b2b34;
  color: #f0f0f0;
  border: 2px solid #8ec5fc;
  border-radius: 6px;
  min-width: 100px;
}

/* Filter bar */
.filter-group {
  display: flex;
  justify-content: center;
  gap: 0.8em;
  margin-bottom: 1.2em;
  margin-top: 0.3em;
}
.filter-btn {
  background: rgba(142,197,252,0.13);
  color: #8ec5fc;
  border: 2px solid #8ec5fc;
  border-radius: 7px;
  padding: 0.5em 1.35em;
  font-size: 1em;
  font-weight: 500;
  cursor: pointer;
  outline: none;
  transition: background 0.18s, color 0.18s, border 0.14s;
}
.filter-btn.active,
.filter-btn:focus {
  background: linear-gradient(to right, #8ec5fc, #1b2b34);
  color: #fff;
  border: 2px solid #fff;
}
.filter-btn:hover {
  background: #1b2b34;
  color: #8ec5fc;
  border: 2px solid #8ec5fc;
}

#todoList {
  list-style: none;
  padding: 0;
}

#todoList li {
  background: rgba(255, 255, 255, 0.08);
  padding: 12px 16px;
  margin-bottom: 10px;
  border-left: 5px solid #8ec5fc;
  border-radius: 6px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #f0f0f0;
  transition: all 0.3s;
}

#todoList li.completed {
  text-decoration: line-through;
  color: #aaa;
  background: rgba(255, 255, 255, 0.04);
}

.task-main {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
}

.task-date-time {
  font-size: 0.96em;
  color: #8ec5fc;
  background: transparent;
  margin-left: 5px;
  letter-spacing: 0.5px;
  white-space: nowrap;
  font-weight: 400;
  opacity: 0.85;
}

.delete-btn, .edit-btn, .save-btn {
  background-color: #1b2b34;
  border: none;
  padding: 6px 10px;
  border-radius: 4px;
  color: white;
  cursor: pointer;
  margin-left: 7px;
  font-size: 0.96em;
  transition: background 0.3s;
}
.delete-btn:hover, .edit-btn:hover, .save-btn:hover {
  background-color: #8ec5fc;
  color: #203a43;
}

/* Edit mode inputs alignment */
.editing-inputs input[type="date"], .editing-inputs input[type="time"] {
  min-width: 85px;
  margin-right: 6px;
  font-size: 0.97em;
}

@media (max-width: 600px) {
  .input-group, .date-time-row {
    flex-direction: column;
    gap: 7px;
  }
  #addTodoButton, #todoInput, #todoDate, #todoTime {
    width: 100%;
    min-width: 0;
  }
}
