:root{--cream:#fbf6e9;--green:#1e4d34;--ink:#1b2a22;--safe-b:env(safe-area-inset-bottom,0px);--safe-t:env(safe-area-inset-top,0px);--safe-l:env(safe-area-inset-left,0px);--safe-r:env(safe-area-inset-right,0px)}html,body{height:100%;color:var(--ink);touch-action:none;-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;-webkit-tap-highlight-color:transparent;overscroll-behavior:none;background:#b9c8d2;margin:0;font-family:Trebuchet MS,Segoe UI,Roboto,system-ui,-apple-system,BlinkMacSystemFont,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;overflow:hidden}#app,#app canvas{width:100%;height:100%;display:block;position:fixed;top:0;bottom:0;left:0;right:0}#loading{background:var(--green);color:var(--cream);z-index:10;flex-direction:column;justify-content:center;align-items:center;gap:10px;transition:opacity .6s;display:flex;position:fixed;top:0;bottom:0;left:0;right:0}#loading .title{letter-spacing:.02em;font-family:Georgia,Times New Roman,serif;font-size:clamp(28px,7vw,54px);font-weight:700}#loading .sub{opacity:.85;font-size:18px}#loading.done{opacity:0;pointer-events:none}#place{top:calc(12px + var(--safe-t));left:calc(12px + var(--safe-l));color:var(--cream);pointer-events:none;background:#1e4d34d9;border-radius:999px;padding:6px 12px;font-size:14px;position:fixed}#tea{top:calc(50px + var(--safe-t));left:calc(12px + var(--safe-l));border:2px solid var(--green);color:var(--green);pointer-events:none;transform-origin:0;background:#fbf6e9e6;border-radius:999px;align-items:center;gap:8px;padding:4px 12px 4px 6px;font-size:15px;font-weight:700;display:flex;position:fixed}#tea .cup{width:30px;height:30px}#tea .cup-line{fill:none;stroke:currentColor;stroke-width:2.2px;stroke-linejoin:round}#tea .steam{fill:none;stroke:currentColor;stroke-width:1.6px;stroke-linecap:round;opacity:.6}#tea-fill{fill:#b07a45}#tea .bar{background:#1e4d342e;border-radius:5px;width:72px;height:10px;overflow:hidden}#tea-bar{background:#b07a45;border-radius:5px;width:75%;height:100%;transition:width .3s linear;display:block}#tea.low #tea-bar,#tea.low #tea-fill{fill:#d9822b;background:#d9822b}#tea.low{animation:1.6s ease-in-out infinite tea-pulse}#tea.empty .steam{display:none}@keyframes tea-pulse{50%{transform:scale(1.06)}}#fps{top:calc(12px + var(--safe-t));right:calc(12px + var(--safe-r));color:#fff;pointer-events:none;background:#00000073;border-radius:6px;padding:4px 8px;font:12px/1.2 ui-monospace,Consolas,monospace;position:fixed}#hint,#toast{text-align:center;pointer-events:none;max-width:min(90vw,520px);transition:opacity .4s;position:fixed;left:50%;transform:translate(-50%)}#hint{bottom:calc(18px + var(--safe-b));color:#fff;background:#0006;border-radius:12px;padding:8px 14px;font-size:15px}#toast{top:calc(190px + var(--safe-t));background:var(--cream);border:3px solid var(--green);color:var(--green);opacity:0;border-radius:14px;padding:10px 18px;font-size:18px;font-weight:700}#toast.show{opacity:1}#spoons{top:calc(140px + var(--safe-t));left:calc(12px + var(--safe-l));pointer-events:none;background:#fbf6e9e6;border:2px solid #8a5a2b;border-radius:999px;gap:2px;padding:4px 10px;display:flex;position:fixed}#spoons[hidden]{display:none}#spoons .spoon{fill:#8a5a2b;opacity:.18;width:22px;height:22px}#spoons .spoon.full{fill:#c98a3c;stroke:#6b4320;stroke-width:1px;opacity:1}body.has-spoons #goal{top:calc(182px + var(--safe-t))}body[data-mode=drive] #toast{top:auto;bottom:calc(70px + var(--safe-b))}body[data-mode=drive].touch #toast{bottom:calc(214px + var(--safe-b))}body[data-mode=drive].touch #hint{display:none}.pad{border:3px solid var(--green);width:76px;height:76px;color:var(--green);touch-action:none;cursor:pointer;background:#fbf6e9e0;border-radius:20px;font:700 22px Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.pad.small{font-size:17px}.pad.held,.pad:active{background:var(--green);color:var(--cream)}#action{right:calc(16px + var(--safe-r));bottom:calc(92px + var(--safe-b));width:auto;max-width:calc(100vw - 150px - var(--safe-l) - var(--safe-r));height:auto;min-height:60px;padding:6px 20px;font-size:19px;line-height:1.15;position:fixed}body[data-mode=drive].touch #action{bottom:calc(118px + var(--safe-b))}.drive-pad{bottom:calc(18px + var(--safe-b));gap:14px;display:none;position:fixed}#drive-left{left:calc(16px + var(--safe-l))}#drive-right{right:calc(16px + var(--safe-r))}body[data-mode=drive].touch .drive-pad{display:flex}#skip-intro{top:calc(74px + var(--safe-t));right:calc(12px + var(--safe-r));color:#fff;cursor:pointer;z-index:4;background:#0000006b;border:none;border-radius:999px;padding:7px 13px;font:14px Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;position:fixed}body:not(.touch) #skip-intro{top:calc(106px + var(--safe-t))}#skip-intro[hidden]{display:none}#sound{top:calc(98px + var(--safe-t));left:calc(12px + var(--safe-l));border:2px solid var(--green);color:var(--green);pointer-events:none;background:#fbf6e9e6;border-radius:999px;align-items:center;gap:7px;padding:5px 12px 5px 8px;font-size:15px;font-weight:700;display:flex;position:fixed}#sound .thumb{fill:#f2c94c;stroke:currentColor;stroke-width:1.8px;stroke-linejoin:round;width:22px;height:22px}#sound .bar{background:#1e4d342e;border-radius:5px;width:56px;height:10px;overflow:hidden}#sound-bar{background:var(--green);border-radius:5px;width:0;height:100%;transition:width .4s;display:block}#sound-pop{background:var(--cream);border:2px solid var(--green);color:var(--green);opacity:0;border-radius:999px;margin-left:8px;padding:1px 9px;font-size:16px;position:absolute;left:100%}#sound-pop.down{color:#a1392d;border-color:#a1392d}#sound-pop.show{animation:1.6s ease-out sound-pop}@keyframes sound-pop{0%{opacity:0;transform:translateY(6px)}15%{opacity:1;transform:none}70%{opacity:1}to{opacity:0;transform:translateY(-14px)}}#chat{left:calc(8px + var(--safe-l));right:calc(8px + var(--safe-r));background:var(--cream);border:3px solid var(--green);max-width:560px;max-height:min(62vh,520px);padding-bottom:var(--safe-b);z-index:5;border-bottom:none;border-radius:18px 18px 0 0;flex-direction:column;margin:0 auto;display:flex;position:fixed;bottom:0;box-shadow:0 -6px 24px #00000040}#chat[hidden]{display:none}@media (min-width:820px) and (orientation:landscape){#chat{left:auto;right:calc(16px + var(--safe-r));width:400px;max-height:min(80vh,640px);margin:0}}#chat header{color:var(--green);justify-content:space-between;align-items:center;padding:10px 12px 6px 16px;font:700 18px Georgia,Times New Roman,serif;display:flex}#chat-close{width:40px;height:40px;color:var(--green);cursor:pointer;background:0 0;border:none;border-radius:12px;font-size:22px}#chat-log{-webkit-user-select:text;user-select:text;touch-action:pan-y;flex-direction:column;flex:1;gap:8px;min-height:90px;padding:4px 12px 8px;display:flex;overflow-y:auto}.bubble{border-radius:16px;max-width:85%;padding:9px 13px;font-size:17px;line-height:1.35}.bubble.npc{background:#fff;border:2px solid #d8d0bb;border-bottom-left-radius:4px;align-self:flex-start}.bubble.me{background:var(--green);color:var(--cream);border-bottom-right-radius:4px;align-self:flex-end}.bubble.typing span{background:#9a917d;border-radius:50%;width:7px;height:7px;margin:0 2px;animation:1s ease-in-out infinite typing-dot;display:inline-block}.bubble.typing span:nth-child(2){animation-delay:.15s}.bubble.typing span:nth-child(3){animation-delay:.3s}@keyframes typing-dot{50%{opacity:.5;transform:translateY(-4px)}}#chat-offer,#chat-chips{flex-wrap:wrap;gap:8px;padding:4px 12px 8px;display:flex}#chat-offer[hidden],#chat-chips[hidden],#chat-form[hidden]{display:none}.chip{border:2px solid var(--green);max-width:100%;min-height:40px;color:var(--green);cursor:pointer;background:#fff;border-radius:999px;flex:none;padding:6px 14px;font:700 15px Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}.chip.strong{background:var(--green);color:var(--cream)}.chip:disabled{opacity:.45}#chat-form{gap:8px;padding:6px 12px 12px;display:flex}#chat-input{min-width:0;height:44px;color:var(--ink);-webkit-user-select:text;user-select:text;background:#fff;border:2px solid #cfc6ae;border-radius:999px;flex:1;padding:0 14px;font-size:16px}#chat-input:focus{border-color:var(--green);outline:none}#chat-send{background:var(--green);height:44px;color:var(--cream);cursor:pointer;border:none;border-radius:999px;padding:0 18px;font:700 16px Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}#chat-send:disabled{opacity:.5}body.chatting #action,body.chatting #hint,body.chatting .drive-pad{display:none!important}#goal{top:calc(140px + var(--safe-t));left:calc(12px + var(--safe-l));max-width:calc(100vw - 24px);color:var(--cream);pointer-events:none;background:#1e4d34e0;border-radius:999px;align-items:center;gap:8px;padding:6px 12px 6px 8px;font-size:15px;font-weight:700;display:flex;position:fixed}#goal[hidden]{display:none}#goal-arrow{fill:#f2c94c;flex:none;width:22px;height:22px;transition:transform .15s linear}#goal-dist{opacity:.85;white-space:nowrap;font-weight:400}#goal-clock{background:var(--cream);color:var(--green);font-variant-numeric:tabular-nums;white-space:nowrap;border-radius:999px;flex:none;padding:1px 9px}#goal-clock[hidden]{display:none}#goal-clock.hurry{color:#fff;background:#c0302a;animation:1s ease-in-out infinite clock-pulse}@keyframes clock-pulse{50%{transform:scale(1.1)}}#passed{text-align:center;pointer-events:none;z-index:6;position:fixed;top:28%;left:0;right:0}#passed[hidden]{display:none}#passed-title{color:#f2c94c;letter-spacing:.02em;-webkit-text-stroke:2px #1b2a22;text-shadow:0 4px #1b2a22,0 8px 18px #00000073;font:900 clamp(38px,11vw,76px)/1 Arial Black,Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}#passed-sub{color:#fbf6e9;-webkit-text-stroke:1px #1b2a22;text-shadow:0 3px #1b2a22;margin-top:6px;font:900 clamp(22px,6vw,38px)/1.1 Arial Black,Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}#passed-line{background:var(--cream);border:3px solid var(--green);max-width:min(86vw,460px);color:var(--green);border-radius:14px;margin-top:14px;padding:8px 14px;font-size:17px;font-weight:700;display:inline-block}#passed-line:empty{display:none}#passed.show{animation:4.2s both passed-in}@keyframes passed-in{0%{opacity:0;transform:scale(1.6)}8%{opacity:1;transform:scale(.95)}12%{transform:scale(1)}85%{opacity:1}to{opacity:0}}#phone-btn{top:calc(12px + var(--safe-t));right:calc(12px + var(--safe-r));border:3px solid var(--green);width:52px;height:52px;color:var(--green);cursor:pointer;z-index:4;background:#fbf6e9eb;border-radius:16px;position:fixed}body:not(.touch) #phone-btn{top:calc(44px + var(--safe-t))}#phone-btn svg{width:26px;height:26px;margin:auto;display:block}#phone-dot{border:2px solid var(--cream);background:#d8392b;border-radius:50%;width:16px;height:16px;position:absolute;top:-6px;right:-6px}#phone-dot[hidden]{display:none}#phone-note{top:calc(72px + var(--safe-t));right:calc(12px + var(--safe-r));border:2px solid var(--green);max-width:min(74vw,300px);color:var(--ink);pointer-events:none;opacity:0;z-index:4;background:#fff;border-radius:14px 4px 14px 14px;padding:9px 13px;font-size:15px;line-height:1.3;transition:opacity .3s,transform .3s;position:fixed;transform:translateY(-8px)}body:not(.touch) #phone-note{top:calc(104px + var(--safe-t))}#phone-note.show{opacity:1;transform:none}#phone-call{top:calc(10px + var(--safe-t));left:calc(12px + var(--safe-l));right:calc(76px + var(--safe-r));background:var(--cream);border:3px solid var(--green);z-index:7;border-radius:18px;max-width:380px;margin:0 auto;padding:12px 14px;position:fixed;box-shadow:0 6px 24px #00000040}#phone-call[hidden]{display:none}#phone-call.ringing{animation:1.1s ease-in-out infinite buzz}@keyframes buzz{0%,60%,to{transform:none}64%,72%,80%{transform:translate(-4px)}68%,76%,84%{transform:translate(4px)}}#phone-call .who{justify-content:space-between;align-items:baseline;gap:10px;display:flex}#call-name{color:var(--green);font:700 19px Georgia,Times New Roman,serif}#call-state{color:#6b6450;font-size:14px}#call-lines{flex-direction:column;gap:6px;margin-top:6px;display:flex}#call-lines:empty{display:none}.call-line{font-size:17px;line-height:1.3}.call-line.me{color:var(--green);align-self:flex-end;font-weight:700}#call-buttons{justify-content:center;gap:10px;margin-top:10px;display:flex}#call-buttons:empty{display:none}#call-buttons .chip{min-width:96px;min-height:46px;font-size:17px}#phone-view{top:calc(72px + var(--safe-t));right:calc(8px + var(--safe-r));background:var(--cream);border:3px solid var(--green);z-index:5;border-radius:18px;flex-direction:column;width:min(100vw - 16px,360px);max-height:min(64vh,520px);display:flex;position:fixed;box-shadow:0 6px 24px #00000040}body:not(.touch) #phone-view{top:calc(104px + var(--safe-t))}#phone-view[hidden]{display:none}body.chatting #phone-view{max-height:calc(38vh - 84px - var(--safe-t))}@media (min-width:820px) and (orientation:landscape){body.chatting #phone-view{right:calc(16px + 400px + 12px + var(--safe-r));max-height:min(64vh,520px)}}#phone-view header{color:var(--green);justify-content:space-between;align-items:center;padding:8px 8px 4px 14px;font:700 18px Georgia,Times New Roman,serif;display:flex}#phone-close{width:40px;height:40px;color:var(--green);cursor:pointer;background:0 0;border:none;border-radius:12px;font-size:22px}#phone-log{touch-action:pan-y;flex-direction:column;flex:1;gap:8px;min-height:80px;padding:4px 12px 12px;display:flex;overflow-y:auto}#phone-log:empty:before{content:"Nothing yet. Give it time.";color:#6b6450;text-align:center;padding:18px 0;font-size:15px}.msg{background:#fff;border:2px solid #d8d0bb;border-radius:4px 14px 14px;align-self:flex-start;max-width:88%;padding:7px 12px 9px;font-size:16px;line-height:1.3}.msg .who{color:var(--green);font-size:13px;font-weight:700;display:block}.msg.missed{color:#a1392d;background:0 0;border:none;align-self:center;font-size:14px}#phone-view footer{justify-content:center;padding:4px 12px 12px;display:flex}#phone-log[hidden],#phone-backup[hidden]{display:none}#phone-backup{touch-action:pan-y;flex-direction:column;flex:1;gap:8px;padding:2px 14px 6px;display:flex;overflow-y:auto}#phone-backup p,#phone-backup label{margin:0;font-size:15px;line-height:1.35}#phone-backup textarea{box-sizing:border-box;width:100%;color:var(--ink);resize:none;word-break:break-all;-webkit-user-select:text;user-select:text;touch-action:auto;background:#fff;border:2px solid #d8d0bb;border-radius:10px;padding:8px 10px;font:16px/1.3 Consolas,Courier New,monospace}#backup-code{font-size:13px!important}#backup-copy{align-self:flex-start}#backup-msg{color:var(--green);font-size:15px;font-weight:700}#backup-msg:empty{display:none}#backup-buttons{gap:10px;display:flex}#shelf{left:calc(8px + var(--safe-l));right:calc(8px + var(--safe-r));background:var(--cream);border:3px solid var(--green);max-width:560px;max-height:min(78vh,640px);padding-bottom:var(--safe-b);z-index:5;border-bottom:none;border-radius:18px 18px 0 0;flex-direction:column;margin:0 auto;display:flex;position:fixed;bottom:0;box-shadow:0 -6px 24px #00000040}#shelf[hidden]{display:none}@media (min-width:820px) and (orientation:landscape){#shelf{left:auto;right:calc(16px + var(--safe-r));width:420px;max-height:min(86vh,700px);margin:0}}#shelf header{color:var(--green);justify-content:space-between;align-items:center;padding:10px 12px 2px 16px;font:700 18px Georgia,Times New Roman,serif;display:flex}#shelf-close{width:40px;height:40px;color:var(--green);cursor:pointer;background:0 0;border:none;border-radius:12px;font-size:22px}#shelf-note{color:#5b5750;margin:0 12px 6px;font-size:15px;line-height:1.35}#shelf-note.call{max-height:6.8em;color:var(--ink);touch-action:pan-y;background:#fff;border:2px solid #d8d0bb;border-radius:14px;padding:8px 12px;overflow-y:auto}#shelf-grid{touch-action:pan-y;flex:1;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;min-height:0;padding:4px 12px 8px;display:grid;overflow-y:auto}.shelf-item{position:relative}.shelf-add{border:2px solid #d8d0bb;border-top:7px solid var(--item);width:100%;min-height:74px;color:var(--ink);cursor:pointer;background:#fff;border-radius:14px;flex-direction:column;justify-content:center;align-items:center;gap:2px;padding:10px 4px 6px;font:700 13px/1.15 Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;display:flex}.shelf-item.picked .shelf-add{border-color:var(--green);border-top-color:var(--item);background:#eef5ee}.shelf-add .icon{font-size:22px;line-height:1}.shelf-add .n{color:var(--green);font-size:14px;position:absolute;top:8px;right:8px}.shelf-less{border:2px solid var(--green);background:var(--cream);width:30px;height:30px;color:var(--green);cursor:pointer;border-radius:50%;font:700 18px/1 Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;display:none;position:absolute;top:6px;left:4px}.shelf-item.picked .shelf-less{display:block}#shelf footer{flex-wrap:wrap;align-items:center;gap:8px;padding:6px 12px 12px;display:flex}#shelf-count{color:var(--green);flex:1 0 100%;font-weight:700}#shelf footer .chip{flex:1;min-height:46px}body.shopping #action,body.shopping #hint,body.shopping .drive-pad{display:none!important}#fail{z-index:20;text-align:center;pointer-events:auto;opacity:0;background:radial-gradient(#46080cb8,#140002f0);flex-direction:column;justify-content:center;align-items:center;gap:14px;padding:0 16px;display:flex;position:fixed;top:0;bottom:0;left:0;right:0}#fail[hidden]{display:none}#fail.in{animation:.5s both fail-in}#fail.out{animation:.6s both fail-out}#fail-title{white-space:nowrap;color:#e8423a;letter-spacing:.02em;-webkit-text-stroke:2px #1b0506;text-shadow:0 5px #1b0506,0 10px 26px #0009;font:900 clamp(30px,9vw,92px)/1 Arial Black,Trebuchet MS,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif}#fail-sub{color:#fbf6e9;font:italic 700 clamp(20px,5.5vw,30px)/1.2 Georgia,Times New Roman,serif}@keyframes fail-in{0%{opacity:0;transform:scale(1.15)}to{opacity:1;transform:none}}@keyframes fail-out{0%{opacity:1}to{opacity:0}}#radar{left:calc(12px + var(--safe-l));bottom:calc(76px + var(--safe-b));border:3px solid var(--green);pointer-events:none;background:#6f9a4a;border-radius:50%;width:108px;height:108px;position:fixed;box-shadow:0 3px 10px #0000004d}body:not(.touch) #radar{bottom:calc(16px + var(--safe-b));width:132px;height:132px}body.touch[data-mode=drive] #radar{bottom:calc(108px + var(--safe-b));width:100px;height:100px}body.chatting #radar,body.shopping #radar{display:none}#home-screen{left:50%;top:calc(64px + var(--safe-t));box-sizing:border-box;background:var(--cream);border:3px solid var(--green);width:min(92vw,420px);color:var(--ink);z-index:8;border-radius:16px;padding:14px 16px;font-size:16px;line-height:1.35;position:fixed;transform:translate(-50%);box-shadow:0 8px 24px #0000004d}#home-screen .title{color:var(--green);font-size:18px;font-weight:700}#home-screen p{margin:6px 0 12px}#home-screen .row{justify-content:flex-end;gap:8px;display:flex}
