:root{color-scheme:dark;font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#f8efd9;background:#17251e}*{box-sizing:border-box}html,body{margin:0;width:100%;min-height:100%;overflow-x:hidden}html{height:100%}body{height:100%}button,select,textarea{font:inherit}button,select{color:#f8efd9;background:#293e31;border:1px solid #57705a;border-radius:9px;min-height:36px;padding:6px 12px;cursor:pointer}button:hover{background:#425943}button:focus-visible,summary:focus-visible,select:focus-visible,canvas:focus-visible{outline:2px solid #f6cf73;outline-offset:-3px}button:disabled,select:disabled{opacity:.5;cursor:default}[hidden]{display:none!important}.game{min-height:100%;height:100%;display:flex;flex-direction:column}.toolbar{display:flex;align-items:center;gap:20px;padding:12px 18px;background:#1c3026;flex-shrink:0}.difficulty{display:flex;align-items:center;gap:8px;font-size:12px}.clock,.record,.wallet{display:flex;flex-direction:column;gap:3px}.clock>span,.record>span,.wallet>span{font-size:9px;letter-spacing:.14em;color:#b2c4a8}.clock strong,.record strong{font-size:21px;font-variant-numeric:tabular-nums;font-weight:600}.record{margin-right:auto}.wallet{min-width:112px;border-left:1px solid #4b5e45;padding-left:18px}.wallet strong{font-size:18px;font-variant-numeric:tabular-nums}.wallet small{font-size:10px;color:#b4c4a7;font-weight:400}.equipment{padding:8px 18px;background:#20382b;border-top:1px solid #3b4d35;flex-shrink:0}.tool-row{display:flex;align-items:center;gap:8px}.tool-row button{font-size:12px;flex-shrink:0}button[aria-pressed=true]{background:#edc36f;border-color:#edc36f;color:#253024}.signal{font-size:12px;color:#d2dfc9;line-height:1.3}.signal.cold{color:#a8d1ff}.signal.warm{color:#f4da82}.signal.hot{color:#ff986b}.signal.very-hot{color:#ffbd92}.shop-panel{margin-top:7px}.shop-panel summary{cursor:pointer;font-size:12px;color:#efd398;padding:6px 0}.shop-panel summary span{float:right;font-size:10px;color:#adc4a2}.shop{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;padding:6px 0}.shop button{text-align:left;white-space:pre-line;font-size:11px;line-height:1.5;min-height:54px;padding:5px 8px}.preferences{display:flex;gap:6px;margin-top:5px}.preferences button{min-height:26px;padding:3px 8px;font-size:10px;border-color:#4a6148;background:transparent}.preferences button[aria-pressed=true]{color:#edc36f}.field{position:relative;flex:1;min-height:340px;background:#496840;overflow:hidden}canvas{display:block;width:100%;height:100%;position:absolute;inset:0;touch-action:none;cursor:crosshair;user-select:none}.field,.loading{background-color:#6a7544;background-image:radial-gradient(ellipse at 47% 40%,#d4b669,#a3894a 45%,#47613d 78%)}.loading{position:absolute;inset:0;display:grid;place-content:center;color:#fff4d5;font-weight:600;text-shadow:0 1px 4px #292211;pointer-events:none}.field-caption{position:absolute;left:20px;top:15px;pointer-events:none;display:flex;flex-direction:column;gap:3px;text-shadow:0 2px 4px #17291d}.field-caption span{font-size:10px;font-weight:700;letter-spacing:.23em;color:#fff2c8}.field-caption small{font-family:Georgia,serif;font-size:13px;color:#e0e6bd}.view-tools{position:absolute;top:12px;right:12px;display:flex;gap:5px}.view-tools button{padding:0;width:34px;min-height:34px;font-size:21px;background:#20362bec}.mobile-controls{position:absolute;bottom:16px;left:16px;right:16px;display:flex;justify-content:space-between;align-items:center;pointer-events:none}#joystick{width:86px;height:86px;border:1px solid #ffffff55;border-radius:50%;background:#15352966;display:grid;place-items:center;touch-action:none;pointer-events:auto;box-shadow:inset 0 0 25px #18291b55}#joystick-knob{display:grid;place-items:center;width:42px;height:42px;border-radius:50%;color:#fff1c0;background:#d6b471bd;font-size:24px;pointer-events:none}#action{pointer-events:auto;touch-action:none;border-radius:50%;width:70px;height:70px;background:#e8c174;color:#283c28;font-size:12px;font-weight:700;border:3px solid #fff0b266;box-shadow:0 4px 15px #19362166}.win,.board{position:absolute;inset:0;overflow:auto;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:20px;text-align:center;background:radial-gradient(ellipse at 50% 35%,#36533cf5,#132a21f7)}.eyebrow{font-size:10px;letter-spacing:.2em;color:#edcb80}.win h2,.board h2{font-family:Georgia,serif;font-weight:400;font-size:clamp(30px,5vw,52px);margin:10px 0}.win p,.board p{font-size:13px;max-width:440px;line-height:1.5;margin:8px 0}.win button{margin:5px;min-width:190px}#share{background:#eac378;color:#243723;border-color:#eac378}.needle-closeup{height:76px;width:130px;position:relative;filter:drop-shadow(0 0 13px #e0f7ff66)}.needle-closeup i{position:absolute;top:36px;left:6px;width:112px;height:4px;background:linear-gradient(#fff,#8397a2);transform:rotate(-25deg);border-radius:90% 3px 3px 90%}.needle-closeup i:after{content:"";position:absolute;right:1px;top:-2px;width:12px;height:8px;border:2px solid #e5f4fa;border-radius:50%;background:#34503a}.needle-closeup span{position:absolute;right:0;top:0;color:#f3e6a3;font-size:27px}.board{justify-content:flex-start;padding-top:24px;z-index:5}#board-close{position:absolute;right:10px;top:10px}.board ol{padding:0;list-style:none;width:min(100%,510px);margin:12px 0;counter-reset:places}.board li{counter-increment:places;display:flex;justify-content:space-between;gap:10px;text-align:left;padding:9px 12px;background:#ffffff09;border-bottom:1px solid #ffffff15;font-size:13px}.board li:before{content:counter(places);color:#dabe79}.board small{display:block;font-size:10px;color:#b9cfad;margin-top:3px}.board li.empty:before{content:""}#copy-fallback{font-size:12px;max-width:400px;width:100%}textarea{display:block;width:100%;color:#fff;background:#263c2d;border:1px solid #8c966c;border-radius:5px;margin-top:6px;padding:8px}footer{display:flex;flex-wrap:wrap;justify-content:space-between;gap:4px 12px;padding:9px 18px;background:#1c3026;font-size:10px;color:#c2d0b6;flex-shrink:0}footer strong{color:#efd18a;font-weight:550}#status{width:100%;font-size:11px;color:#d7dfc5}#save-status{color:#b7c6a8;font-size:10px}.purchase{animation:purchase .4s ease-out}@keyframes purchase{50%{background:#e9c16b;color:#173223;transform:translateY(-2px)}}@media(min-width:900px){#joystick{opacity:.55;width:70px;height:70px}#action{width:60px;height:60px}.field-caption small:after{content:" · WASD to walk, Space to use tool"}}@media(max-width:600px){.toolbar{gap:8px;padding:8px}.difficulty{font-size:0;gap:0}select{font-size:12px;max-width:119px;padding:6px}.clock strong{font-size:16px}.record{display:none}.wallet{margin-left:auto;min-width:75px;padding-left:8px}.wallet strong{font-size:15px}.wallet small{font-size:8px}.wallet>span{font-size:9px;letter-spacing:.05em}.toolbar>button{font-size:10px;padding:5px 7px;max-width:63px;line-height:1.2}.equipment{padding:6px 8px}.tool-row{gap:6px}.tool-row button{padding:4px 9px;min-height:32px}.signal{font-size:10px}.shop{grid-template-columns:repeat(2,minmax(0,1fr))}.shop-panel summary{font-size:11px;padding:5px 0}.preferences{margin-top:4px;gap:4px}.preferences button{font-size:10px;padding:3px 6px}.field-caption{left:12px;top:12px}.field-caption small{font-size:11px}.field-caption span{font-size:9px}.view-tools{right:8px;top:40px}.view-tools button{width:30px;min-height:30px;font-size:19px}footer{padding:8px;line-height:1.35;font-size:9px}.win{padding:14px}.win h2{margin:6px 0}.win p{font-size:12px}.win button{min-height:34px;font-size:12px;margin:3px}.board li{font-size:12px}.game{min-height:100vh}.field{min-height:340px}}@media(prefers-reduced-motion:reduce){.purchase{animation:none}}@media(max-height:420px){.game{height:auto}.field{height:340px;flex:none}.win{justify-content:flex-start}.needle-closeup{height:55px;flex-shrink:0}}

.confetti{position:absolute;inset:0;pointer-events:none;overflow:hidden}.confetti i{position:absolute;left:var(--x);top:-15px;width:7px;height:12px;background:#ecc97d;animation:celebrate 1.8s var(--delay) ease-out both}.confetti i:nth-child(3n){background:#aad6a6}.confetti i:nth-child(3n+1){background:#f4ede0}.win:not([hidden]) .needle-closeup{animation:needle-reveal .85s ease-out both}.win.calm .confetti{display:none}.win.calm .needle-closeup{animation:none}@keyframes celebrate{to{top:110%;transform:rotate(var(--turn));opacity:0}}@keyframes needle-reveal{0%{transform:scale(.35) rotate(-12deg);opacity:0}65%{transform:scale(1.1)}100%{transform:scale(1);opacity:1}}@media(prefers-reduced-motion:reduce){.confetti{display:none}.win:not([hidden]) .needle-closeup{animation:none}}
