-- Track when a checklist item was marked done so items done >24h can be hidden
-- from the active list and dropped from its item count (they stay in the DB).
ALTER TABLE "ChecklistItem" ADD COLUMN "completedAt" TIMESTAMP(3);

-- Backfill existing done items to now() so they get a fresh 24h grace window
-- (we don't know when they were actually checked off) rather than vanishing on
-- deploy.
UPDATE "ChecklistItem" SET "completedAt" = now() WHERE "done" = true;
