/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', Tahoma, sans-serif;
  background: linear-gradient(135deg, #dbeafe, #c7d2fe);
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 20px;
}

/* Main container */
.container {
  background: white;
  padding: 25px 20px;
  border-radius: 16px;
  width: 100%;
  max-width: 500px;
  margin: auto;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  text-align: center;
  animation: fadeIn 0.4s ease;
}

/* Headings */
h1, h2, h3 {
  margin-bottom: 20px;
  color: #1e3a8a;
}

/* Task Text Colors */
#taskList h3,
#taskList div div span {
  color: #000 !important;
}

/* Text & Paragraphs */
p {
  margin-bottom: 20px;
  color: #334155;
  font-size: 16px;
}

/* Inputs & Selects */
input, select {
  width: 100%;
  padding: 12px;
  margin-bottom: 16px;
  border: 1px solid #94a3b8;
  border-radius: 8px;
  font-size: 16px;
  background: #f8fafc;
  transition: border 0.3s ease;
}

input:focus, select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.3);
}

/* Buttons */
button {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  font-weight: bold;
  color: white;
  background: linear-gradient(90deg, #3b82f6, #1e40af);
  border: none;
  border-radius: 10px;
  cursor: pointer;
  margin-bottom: 12px;
  transition: all 0.2s ease-in-out;
  box-shadow: 0 4px 10px rgba(59, 130, 246, 0.25);
}

button:hover {
  background: linear-gradient(90deg, #2563eb, #1e3a8a);
  transform: scale(1.03);
}

button:active {
  transform: scale(0.96);
  box-shadow: 0 2px 6px rgba(30, 64, 175, 0.4);
}

/* Task List */
ul {
  list-style: none;
  padding: 0;
  margin-bottom: 24px;
}

li {
  background: #f0f9ff;
  padding: 12px;
  margin-bottom: 10px;
  border-radius: 8px;
  font-size: 15px;
  color: #1e293b;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

li button {
  background-color: #22c55e;
  font-size: 14px;
  padding: 6px 10px;
  border-radius: 6px;
  width: auto;
  box-shadow: none;
}

li button:hover {
  background-color: #16a34a;
}

/* Mobile Responsive */
@media (max-width: 600px) {
  h1, h2, h3 {
    font-size: 20px;
  }

  input, select, button {
    font-size: 15px;
  }

  li {
    flex-direction: column;
    align-items: flex-start;
  }

  li button {
    width: 100%;
    margin-top: 10px;
  }
}

/* Dark Mode Fix */
@media (prefers-color-scheme: dark) {
  body {
    background: #0f172a;
  }

  .container {
    background: #1e293b;
    color: white;
  }

  input, select {
    background: #334155;
    color: white;
    border: 1px solid #64748b;
  }

  input::placeholder, select::placeholder {
    color: #cbd5e1;
  }

  button {
    background: linear-gradient(90deg, #60a5fa, #2563eb);
  }

  #taskList h3,
  #taskList div div span {
    color: #000 !important;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
