* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, #667eea, #764ba2);
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  color: #333;
}

.container {
  background: #fff;
  padding: 25px;
  border-radius: 16px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.2);
  width: 400px;
  animation: fadeIn 0.7s ease-in-out;
}

h1 {
  text-align: center;
  margin-bottom: 20px;
  color: #444;
}

.input-box {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

#taskInput {
  flex: 1;
  padding: 12px;
  border: 2px solid #ddd;
  border-radius: 10px;
  font-size: 14px;
}

#addBtn {
  padding: 0 20px;
  border: none;
  background: #667eea;
  color: white;
  border-radius: 10px;
  cursor: pointer;
  transition: 0.3s;
  font-size: 16px;
}

#addBtn:hover {
  background: #4b5bdc;
}

ul {
  list-style: none;
  max-height: 300px;
  overflow-y: auto;
}

li {
  background: #f9f9f9;
  padding: 12px;
  border-radius: 10px;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: 0.3s;
}

li:hover {
  background: #f1f1f1;
}

li.completed {
  text-decoration: line-through;
  color: gray;
  background: #e8e8e8;
}

button.deleteBtn {
  background: transparent;
  border: none;
  color: #e63946;
  cursor: pointer;
  font-size: 18px;
  transition: 0.3s;
}

button.deleteBtn:hover {
  color: #b71c1c;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
