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

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #f4f4f5;
  color: #18181b;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  padding: 3rem 1rem;
}

.app {
  width: 100%;
  max-width: 480px;
}

h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

#todo-form {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

#todo-input {
  flex: 1;
  padding: 0.6rem 0.8rem;
  border: 1px solid #d4d4d8;
  border-radius: 8px;
  font-size: 1rem;
}

#todo-input:focus {
  outline: 2px solid #2563eb;
  border-color: transparent;
}

button[type="submit"] {
  padding: 0.6rem 1.1rem;
  border: none;
  border-radius: 8px;
  background: #2563eb;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
}

button[type="submit"]:hover {
  background: #1d4ed8;
}

#todo-list {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.todo-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: #fff;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  padding: 0.6rem 0.8rem;
}

.todo-item input[type="checkbox"] {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: #2563eb;
  cursor: pointer;
}

.todo-item span {
  flex: 1;
  overflow-wrap: anywhere;
}

.todo-item.done span {
  text-decoration: line-through;
  color: #a1a1aa;
}

.delete-btn {
  border: none;
  background: none;
  color: #a1a1aa;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
}

.delete-btn:hover {
  color: #dc2626;
}

#empty-state {
  color: #a1a1aa;
  text-align: center;
  margin-top: 1rem;
}
