:root{--bg: #f6f7f9;--card: #ffffff;--text: #1f2937;--muted: #6b7280;--border: #e5e7eb;--empty: #eceef1;--green: #16a34a;--green-soft: #dcfce7;font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;color:var(--text);background:var(--bg)}@media(prefers-color-scheme:dark){:root{--bg: #111418;--card: #1a1f25;--text: #e5e7eb;--muted: #9ca3af;--border: #2a3038;--empty: #242a31;--green: #22c55e;--green-soft: #14361f}}*{box-sizing:border-box}body{margin:0;background:var(--bg)}.app{max-width:480px;margin:0 auto;padding:calc(24px + env(safe-area-inset-top)) calc(16px + env(safe-area-inset-right)) calc(48px + env(safe-area-inset-bottom)) calc(16px + env(safe-area-inset-left))}body{-webkit-user-select:none;user-select:none}input{-webkit-user-select:text;user-select:text}header{text-align:center;margin-bottom:20px;padding:0 40px}h1{margin:0;font-size:1.6rem;cursor:pointer}.pencil{font-size:.9rem;color:var(--muted)}.date{margin:4px 0 0;color:var(--muted)}.rename{display:flex;gap:8px;justify-content:center}.rename input{font:inherit;font-size:1.1rem;padding:6px 10px;border:1px solid var(--border);border-radius:8px;background:var(--card);color:var(--text);min-width:0;flex:1}.rename button{font:inherit;padding:6px 14px;border:0;border-radius:8px;background:var(--green);color:#fff;cursor:pointer}.big-button{width:100%;min-height:160px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;font:inherit;font-size:1.25rem;font-weight:600;border:2px dashed var(--border);border-radius:20px;background:var(--card);color:var(--text);cursor:pointer;transition:transform .1s,background .2s,border-color .2s;-webkit-tap-highlight-color:transparent}.big-button:active{transform:scale(.97)}.big-button .check{font-size:3rem;line-height:1;color:var(--muted)}.big-button small{font-weight:400;font-size:.85rem;opacity:.8}.big-button.is-done{background:var(--green);border:2px solid var(--green);color:#fff}.big-button.is-done .check{color:#fff}.error{color:#dc2626;text-align:center}.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin:20px 0}.stat{background:var(--card);border:1px solid var(--border);border-radius:14px;padding:12px 8px;text-align:center}.stat-value{font-size:1.6rem;font-weight:700}.stat-unit{font-size:.75rem;color:var(--muted)}.stat-label{font-size:.8rem;margin-top:4px}.history{background:var(--card);border:1px solid var(--border);border-radius:16px;padding:16px}.history h2{margin:0 0 12px;font-size:1rem}.grid{display:grid;grid-template-columns:52px repeat(7,1fr);gap:5px;align-items:center}.day-label,.week-label{font-size:.7rem;color:var(--muted);text-align:center}.week-label{text-align:left;white-space:nowrap}.cell{aspect-ratio:1;border:0;border-radius:8px;background:var(--empty);color:var(--muted);font-size:.75rem;display:flex;align-items:center;justify-content:center}.cell.done{background:var(--green);color:#fff;font-weight:600}.cell.today{outline:2px solid var(--green);outline-offset:1px}.cell.future{opacity:.35}.app{position:relative}.icon-button{border:0;background:none;color:var(--muted);font-size:1.4rem;line-height:1;padding:8px;cursor:pointer;border-radius:10px}.icon-button:hover{background:var(--empty)}.settings-button{position:absolute;top:calc(16px + env(safe-area-inset-top));right:calc(8px + env(safe-area-inset-right))}.sheet-backdrop{position:fixed;top:0;right:0;bottom:0;left:0;z-index:10;background:#0006;display:flex;align-items:flex-end;justify-content:center}.sheet{width:100%;max-width:480px;max-height:90vh;overflow-y:auto;background:var(--bg);color:var(--text);border-radius:20px 20px 0 0;padding:16px 16px calc(20px + env(safe-area-inset-bottom));animation:slide-up .2s ease-out}@media(min-width:600px){.sheet-backdrop{align-items:center}.sheet{border-radius:20px}}@keyframes slide-up{0%{transform:translateY(40px);opacity:0}}.sheet-header{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}.sheet-header h2{margin:0;font-size:1.2rem}.settings-group{background:var(--card);border:1px solid var(--border);border-radius:14px;padding:4px 14px;margin-bottom:14px}.settings-group h3{margin:10px 0 2px;font-size:.75rem;text-transform:uppercase;letter-spacing:.05em;color:var(--muted)}.row{display:flex;align-items:center;gap:12px;min-height:48px;border-bottom:1px solid var(--border)}.row:last-of-type{border-bottom:0}.row>span{flex:1}.muted{color:var(--muted)}.note{font-size:.8rem;color:var(--muted);margin:8px 0 10px}.ok{color:var(--green);text-align:center}.row input[type=time]{font:inherit;padding:6px 8px;border-radius:8px;border:1px solid var(--border);background:var(--bg);color:var(--text)}.row input[type=time]:disabled{opacity:.4}.switch{-moz-appearance:none;appearance:none;-webkit-appearance:none;flex-shrink:0;width:46px;height:28px;margin:0;border-radius:14px;background:var(--border);position:relative;cursor:pointer;transition:background .2s}.switch:after{content:"";position:absolute;top:3px;left:3px;width:22px;height:22px;border-radius:50%;background:#fff;box-shadow:0 1px 3px #0000004d;transition:transform .2s}.switch:checked{background:var(--green)}.switch:checked:after{transform:translate(18px)}.switch:disabled{opacity:.5}.link-button{border:0;background:none;color:var(--green);font:inherit;padding:4px 0 12px;cursor:pointer}.primary{width:100%;font:inherit;font-weight:600;padding:14px;border:0;border-radius:14px;background:var(--green);color:#fff;cursor:pointer}.primary:disabled,.link-button:disabled{opacity:.6}.auth{text-align:center;padding-top:calc(48px + env(safe-area-inset-top))}.auth-logo{width:72px;height:72px;border-radius:18px}.auth h1{cursor:default;margin:12px 0 20px}.tabs{display:grid;grid-template-columns:1fr 1fr;gap:4px;padding:4px;background:var(--empty);border-radius:12px;margin-bottom:16px}.tabs button{font:inherit;border:0;border-radius:9px;padding:10px;cursor:pointer;background:none;color:var(--muted)}.tabs button[aria-selected=true]{background:var(--card);color:var(--text);font-weight:600}.auth-form{display:flex;flex-direction:column;gap:12px;text-align:left}.auth-form label{display:flex;flex-direction:column;gap:4px;font-size:.85rem;color:var(--muted)}.auth-form input,.password-form input{font:inherit;font-size:1rem;padding:12px;border-radius:10px;border:1px solid var(--border);background:var(--card);color:var(--text)}.center{text-align:center}.block{display:block}.account{margin-top:14px;padding-bottom:14px}.password-form{display:flex;flex-direction:column;gap:8px;margin-top:10px}.button-row{display:flex;gap:8px;margin-top:10px}.button-row>*{flex:1}.secondary{font:inherit;padding:12px;border-radius:12px;cursor:pointer;border:1px solid var(--border);background:var(--bg);color:var(--text)}.danger{color:#dc2626}.link-button.danger{padding:4px 0}
