* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #8fd3ff; font-family: "Trebuchet MS", "Nunito", system-ui, sans-serif; color: #4a3428; touch-action: none; -webkit-user-select: none; user-select: none; }
#c { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
.card { background: #fff8eb; border: 3px solid #4a3428; border-radius: 16px; box-shadow: 0 4px 0 #4a3428; }
#hud { position: fixed; top: max(10px, env(safe-area-inset-top)); left: 10px; right: 10px; display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; pointer-events: none; }
#clock { padding: 6px 14px; display: flex; gap: 10px; align-items: baseline; font-size: 18px; }
#clock span { background: #ffd166; border-radius: 99px; padding: 1px 10px; font-size: 14px; font-weight: bold; }
.cams { display: flex; gap: 6px; pointer-events: auto; flex-wrap: wrap; justify-content: flex-end; }
button { font: inherit; font-weight: bold; color: #4a3428; background: #fff8eb; border: 3px solid #4a3428; border-radius: 12px; box-shadow: 0 3px 0 #4a3428; padding: 6px 12px; cursor: pointer; }
button:active { transform: translateY(2px); box-shadow: 0 1px 0 #4a3428; }
.cams button.on { background: #5cc8a8; color: #fff; }
#hint { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); padding: 18px 22px; display: flex; flex-direction: column; gap: 6px; max-width: min(92vw, 460px); text-align: center; font-size: 15px; }
#hint b { font-size: 24px; color: #e8637a; }
#hint button { margin-top: 8px; background: #5cc8a8; color: #fff; font-size: 18px; }
#hint.hide { display: none; }
#prompt { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); padding: 8px 16px; font-weight: bold; text-align: center; max-width: 90vw; }
#stick, #jump { display: none; }
body.touch #stick { display: block; position: fixed; left: 24px; bottom: max(24px, env(safe-area-inset-bottom)); width: 130px; height: 130px; border-radius: 50%; background: rgba(255,248,235,.45); border: 3px solid rgba(74,52,40,.5); }
#knob { position: absolute; left: 50%; top: 50%; width: 56px; height: 56px; margin: -28px 0 0 -28px; border-radius: 50%; background: #fff8eb; border: 3px solid #4a3428; }
body.touch #jump { display: block; position: fixed; right: 24px; bottom: max(30px, env(safe-area-inset-bottom)); width: 86px; height: 86px; border-radius: 50%; background: #5cc8a8; color: #fff; }
body.touch #hint span:nth-of-type(n+2) { display: none; }
body.touch #prompt { bottom: 170px; }
#loading { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); padding: 14px 22px; font-weight: bold; font-size: 18px; z-index: 5; }
