:root { color-scheme: light; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: #24372f; background: #f3f5f1; }
* { box-sizing: border-box; }
body { margin: 0; }
main { max-width: 760px; margin: 80px auto; padding: 0 24px; }
.badge { font-size: 11px; font-weight: 700; letter-spacing: 2px; color: #50795f; }
h1 { font-size: clamp(32px, 6vw, 44px); letter-spacing: -1px; margin: 14px 0; }
header p, footer { color: #6d796f; }
header p { margin-bottom: 32px; line-height: 1.7; }
section { background: white; padding: 28px; border: 1px solid #e0e6de; border-radius: 20px; box-shadow: 0 12px 45px #24372f07; }
form { display: flex; gap: 10px; }
input, button { font: inherit; }
input[type="text"], input:not([type]) { width: 100%; min-width: 0; border: 1px solid #d9e1d7; background: #fafbf9; padding: 13px 14px; border-radius: 10px; }
button { border: 0; border-radius: 10px; background: #34634b; color: white; padding: 12px 18px; white-space: nowrap; cursor: pointer; }
button:hover { background: #274d39; }
button:disabled { opacity: .5; cursor: wait; }
:focus-visible { outline: 3px solid #8ab999; outline-offset: 3px; }
.list-header { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 26px; }
h2 { font-size: 16px; margin: 0; }
#count { color: #748177; font-size: 12px; }
ul { list-style: none; margin: 14px 0 0; padding: 0; }
li { display: flex; align-items: center; gap: 12px; padding: 15px 0; border-top: 1px solid #eef1ec; }
li label { display: flex; align-items: center; gap: 12px; flex: 1; min-width: 0; line-height: 1.6; cursor: pointer; }
li span { overflow-wrap: anywhere; }
input[type="checkbox"] { flex-shrink: 0; width: 18px; height: 18px; accent-color: #34634b; }
.completed label span { color: #8c968e; text-decoration: line-through; }
.delete { color: #8d5555; background: #fbf3f0; font-size: 12px; padding: 7px 10px; }
.delete:hover { background: #f4e5e0; }
#message { color: #ad3939; font-size: 13px; line-height: 1.6; }
#message:empty { display: none; }
#empty { text-align: center; padding: 32px 0 18px; color: #79857b; font-size: 14px; }
footer { text-align: center; margin-top: 24px; font-size: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
@media (max-width: 520px) { main { margin: 40px auto; padding: 0 16px; } section { padding: 20px; } form { flex-direction: column; } form button { width: 100%; } }
