:root {
  --ink: #1e2420;
  --muted: #777d77;
  --paper: #f4f1e9;
  --card: #fffefa;
  --line: #dcd9d0;
  --green: #3f7155;
  --green-light: #dce8df;
  --red: #a9483f;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--paper); }
button, input { font: inherit; }
button { color: inherit; }
.shell { width: min(920px, calc(100% - 40px)); margin: 0 auto; }
.masthead { height: 88px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.brand { font-family: Georgia, serif; font-weight: 700; letter-spacing: -.02em; font-size: 20px; display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 27px; height: 27px; display: grid; place-items: center; border: 1px solid var(--ink); border-radius: 50%; font: 14px sans-serif; }
.date { color: var(--muted); font-size: 13px; letter-spacing: .04em; }
.hero { padding: 72px 0 47px; }
.eyebrow { margin: 0 0 22px; color: var(--green); letter-spacing: .18em; font-size: 11px; font-weight: 800; }
h1 { margin: 0; font-family: Georgia, "Noto Serif SC", serif; font-weight: 400; font-size: clamp(48px, 7vw, 76px); line-height: 1.06; letter-spacing: -.05em; }
h1 em { color: var(--green); font-weight: 400; }
.intro { max-width: 500px; margin: 25px 0 0; color: var(--muted); font-size: 15px; line-height: 1.8; }
.workspace { background: var(--card); border: 1px solid #dedbd3; box-shadow: 0 20px 60px rgba(43, 48, 43, .07); }
.composer { display: flex; align-items: center; padding: 17px; gap: 13px; border-bottom: 1px solid var(--line); }
.plus { font-size: 28px; color: #92968f; font-weight: 200; margin-left: 5px; }
.composer input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; font-size: 16px; color: var(--ink); }
.composer input::placeholder { color: #a3a69f; }
.composer button { border: 0; border-radius: 3px; padding: 12px 17px; background: var(--ink); color: white; cursor: pointer; font-weight: 650; font-size: 13px; }
.composer button:hover { background: var(--green); }
.composer button span { opacity: .55; padding-left: 5px; }
.toolbar { min-height: 62px; padding: 0 20px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.filters { display: flex; height: 62px; gap: 27px; }
.filter, .clear { border: 0; background: transparent; cursor: pointer; color: var(--muted); font-size: 12px; }
.filter { padding: 0; border-bottom: 2px solid transparent; font-weight: 650; }
.filter.active { border-color: var(--green); color: var(--ink); }
.filter span { padding: 1px 6px; margin-left: 5px; color: white; background: var(--green); border-radius: 9px; font-size: 10px; }
.clear:hover { color: var(--red); }
.todo-list { margin: 0; padding: 0; list-style: none; }
.todo-item { display: flex; align-items: center; gap: 15px; min-height: 76px; padding: 14px 23px; border-bottom: 1px solid #ece9e1; animation: enter .22s ease-out; }
@keyframes enter { from { transform: translateY(-5px); opacity: 0; } }
.todo-item:hover { background: #fbfaf5; }
.check { width: 23px; height: 23px; flex: none; border: 1.5px solid #a7aaa4; border-radius: 50%; background: transparent; cursor: pointer; display: grid; place-items: center; }
.check span { opacity: 0; font-size: 12px; color: white; }
.todo-copy { min-width: 0; flex: 1; }
.todo-title { line-height: 1.4; font-size: 15px; overflow-wrap: anywhere; }
.todo-time { color: #a0a39d; font-size: 10px; margin-top: 5px; letter-spacing: .03em; }
.completed .check { background: var(--green); border-color: var(--green); }
.completed .check span { opacity: 1; }
.completed .todo-title { color: #9b9e98; text-decoration: line-through; }
.actions { opacity: 0; display: flex; gap: 4px; transition: opacity .15s; }
.todo-item:hover .actions, .actions:focus-within { opacity: 1; }
.actions button { width: 31px; height: 31px; border: 0; background: transparent; color: #8d918a; cursor: pointer; font-size: 18px; }
.actions .delete:hover { color: var(--red); }
.actions .edit:hover { color: var(--green); }
.editing .todo-title { display: none; }
.edit-input { width: 100%; border: 0; border-bottom: 1px solid var(--green); outline: 0; background: transparent; padding: 3px 0; }
.summary { min-height: 61px; padding: 0 23px; display: flex; align-items: center; gap: 17px; color: var(--muted); font-size: 11px; }
.summary strong { color: var(--ink); }
.progress-track { flex: 1; height: 3px; background: #e5e4df; }
.progress { width: 0; height: 100%; background: var(--green); transition: width .3s; }
.empty { text-align: center; padding: 60px 20px; border-bottom: 1px solid var(--line); }
.empty-icon { display: grid; place-items: center; width: 44px; height: 44px; margin: 0 auto 13px; border: 1px solid #bec6be; color: var(--green); border-radius: 50%; }
.empty h2 { margin: 0 0 8px; font: 21px Georgia, serif; }
.empty p { margin: 0; color: var(--muted); font-size: 13px; }
.error { margin: 12px 20px 0; background: #f7e5e2; color: #823b34; padding: 10px 13px; font-size: 12px; border-left: 3px solid var(--red); }
.page-footer { display: flex; justify-content: space-between; padding: 27px 0 40px; color: #9a9c96; font: italic 12px Georgia, serif; }

@media (max-width: 600px) {
  .shell { width: min(100% - 22px, 920px); }
  .masthead { height: 68px; }
  .hero { padding: 48px 4px 34px; }
  h1 { font-size: 47px; }
  .composer { flex-wrap: wrap; }
  .composer input { width: calc(100% - 50px); }
  .composer button { width: 100%; }
  .toolbar { align-items: stretch; padding: 0 15px; }
  .filters { gap: 17px; }
  .clear { display: none; }
  .actions { opacity: 1; }
  .todo-item { padding-inline: 17px; }
  .summary { padding-inline: 17px; }
  .page-footer { flex-direction: column; gap: 7px; }
}

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
