:root{color-scheme:dark;--ink: #241910;--paper: #f4ecdc;--sand: #e7d2b0;--clay: #9c4a32;font-family:Liberation Sans,Noto Sans,sans-serif}*{box-sizing:border-box}html,body{margin:0;height:100%;width:100%;overflow:hidden;position:fixed;top:0;right:0;bottom:0;left:0;touch-action:none;overscroll-behavior:none;background:var(--sand);user-select:none;-webkit-user-select:none}#c{display:block;width:100%;height:100%;touch-action:none}#minimap{position:fixed;z-index:6;left:calc(14px + env(safe-area-inset-left));bottom:calc(16px + env(safe-area-inset-bottom));width:156px;height:156px;border-radius:12px;border:2px solid rgba(255,244,220,.7);background:#e7d3a4;box-shadow:0 6px 16px #140c0647;pointer-events:auto;touch-action:manipulation}body.touch-ui #minimap{left:auto;bottom:auto;top:calc(78px + env(safe-area-inset-top));right:calc(12px + env(safe-area-inset-right));width:132px;height:132px}#crosshair{position:fixed;left:50%;top:50%;width:18px;height:18px;transform:translate(-50%,-50%);pointer-events:none;z-index:4}#crosshair:before,#crosshair:after{content:"";position:absolute;background:#fffaf3;box-shadow:0 0 0 1px #140e08d9}#crosshair:before{left:8px;top:2px;width:2px;height:14px}#crosshair:after{top:8px;left:2px;width:14px;height:2px}#target-name{position:fixed;left:50%;top:calc(50% + 16px);transform:translate(-50%);color:#fffaf3;text-shadow:0 1px 2px #1a120c;font-size:13px;letter-spacing:.02em;pointer-events:none;z-index:4;min-height:1em}#topbar{position:fixed;z-index:6;top:0;left:0;right:0;display:flex;justify-content:space-between;align-items:flex-start;gap:12px;padding:calc(10px + env(safe-area-inset-top)) calc(12px + env(safe-area-inset-right)) 0 calc(12px + env(safe-area-inset-left));pointer-events:none}.brand{max-width:min(460px,62vw)}.mark,#overlay h1,#help-card h2{font-family:"Liberation Serif","DejaVu Serif",Georgia,serif;font-weight:700;letter-spacing:-.03em}.mark{margin:0;color:#fffaf3;font-size:28px;text-shadow:0 1px 2px rgba(20,12,6,.65)}#where-row{display:flex;align-items:center;flex-wrap:wrap;gap:8px}#where,#detail,#coords,.hint{margin:0;color:#fffaf3;text-shadow:0 1px 2px rgba(20,12,6,.7)}#where-row .sv-link,#save-place{min-height:44px;padding:6px 12px;border-radius:999px;background:#1c140e8c;color:#fffaf3;text-decoration:none;font-size:13px;font-weight:700;text-shadow:none;pointer-events:auto;border:1px solid rgba(255,244,220,.35)}#where{font-size:15px;font-weight:700}#detail,#coords,.hint{font-size:13px;line-height:1.35}#coords{opacity:.9;margin-top:2px}.hint{margin-top:8px;max-width:440px}.hint.touch,body.touch-ui .hint.desk{display:none}body.touch-ui .hint.touch{display:block}.pills{display:flex;gap:8px;pointer-events:auto}button{font:inherit}.pills button,#close-help,#enter{min-height:44px;border-radius:999px;border:1px solid rgba(255,244,220,.4);background:#1c140e7a;color:#f7f1e6;padding:0 14px;font-weight:700}#enter,#close-help{width:100%;background:var(--clay);border:0;color:#fffaf3;font-size:18px}#mount-btn{position:fixed;z-index:8;left:50%;bottom:calc(96px + env(safe-area-inset-bottom));transform:translate(-50%);min-height:48px;min-width:128px;padding:0 18px;border:0;border-radius:999px;background:#9c4a32;color:#fffaf3;font-weight:700;pointer-events:auto}#mount-btn[hidden]{display:none}body.touch-ui #mount-btn{bottom:calc(214px + env(safe-area-inset-bottom))}#hotbar-wrap{position:fixed;z-index:6;left:50%;bottom:calc(14px + env(safe-area-inset-bottom));transform:translate(-50%);display:flex;flex-direction:column;align-items:center;gap:6px;pointer-events:none}body.touch-ui #hotbar-wrap{bottom:calc(128px + env(safe-area-inset-bottom))}#slot-name{color:#fffaf3;text-shadow:0 1px 2px #1a120c;font-size:13px;font-weight:700}#hotbar{display:flex;gap:6px;pointer-events:auto}.slot{width:56px;height:56px;border-radius:10px;border:2px solid rgba(255,244,220,.22);background:#16100c8c;position:relative;padding:0;touch-action:none}body.touch-ui .slot{width:56px;height:56px}.slot.all{font-size:12px;font-weight:800;color:#f6efe2}.slot img{width:32px;height:32px;image-rendering:pixelated;pointer-events:none}.slot .num{position:absolute;left:4px;top:2px;font-size:10px;color:#f6efe2}.slot.selected{border-color:#f0d7a2;background:#483018e0;transform:translateY(-4px)}.joystick{display:none;position:fixed;z-index:6;left:calc(18px + env(safe-area-inset-left));bottom:calc(18px + env(safe-area-inset-bottom));width:132px;height:132px;border-radius:50%;background:#14100c52;border:2px solid rgba(255,244,220,.45);touch-action:none}body.touch-ui .joystick{display:block}.knob{position:absolute;left:50%;top:50%;width:64px;height:64px;margin:-32px 0 0 -32px;border-radius:50%;background:#f4e8d2eb;box-shadow:0 4px 10px #140c0640}.actions{display:none;position:fixed;z-index:6;right:calc(14px + env(safe-area-inset-right));bottom:calc(14px + env(safe-area-inset-bottom));grid-template-columns:84px 84px;grid-template-areas:"break place" "jump jump";gap:10px;justify-items:center}body.touch-ui .actions{display:grid}.actions button{width:80px;height:80px;border-radius:50%;border:2px solid rgba(255,250,240,.45);color:#fffaf3;font-weight:800;font-size:14px;touch-action:none}#btn-break{grid-area:break;background:#8d3d32}#btn-place{grid-area:place;background:#2f6f66}#btn-jump{grid-area:jump;width:94px;height:94px;background:#c47a3a;font-size:16px}.actions button:active,.slot:active,.pills button:active,#enter:active{transform:scale(.97)}#overlay,#help-card{position:fixed;top:0;right:0;bottom:0;left:0;z-index:20;display:grid;place-items:center;padding:calc(18px + env(safe-area-inset-top)) 16px calc(18px + env(safe-area-inset-bottom));background:#1c140e47}#help-card[hidden],#overlay[hidden]{display:none}.card{width:min(460px,100%);background:var(--paper);color:var(--ink);border-radius:18px;padding:26px 24px 20px;box-shadow:0 18px 50px #28180a59}.card h1{font-size:64px;line-height:.9;margin:0 0 8px}.card h2{font-size:32px;margin:0 0 8px}.card p{margin:0 0 12px;line-height:1.4}.eyebrow{text-transform:uppercase;letter-spacing:.14em;font-size:12px;font-weight:700;color:#7a5a3a}.fine,#boot-status{font-size:13px;color:#5c4636}.card.slim p{font-size:15px}@media(orientation:portrait)and (min-width:521px){body.touch-ui #hotbar-wrap{bottom:calc(214px + env(safe-area-inset-bottom))}body.touch-ui .slot{width:48px;height:48px}.mark{font-size:24px}.card h1{font-size:52px}}@media(max-width:520px){.mark{font-size:20px}#where,#detail,#coords,.hint{font-size:11px}.hint{max-width:52vw}.pills button{min-height:36px;padding:0 10px;font-size:13px}body.touch-ui #minimap{top:calc(92px + env(safe-area-inset-top));right:calc(8px + env(safe-area-inset-right));width:108px;height:108px}.card h1{font-size:42px}.joystick{width:104px;height:104px;left:calc(10px + env(safe-area-inset-left));bottom:calc(10px + env(safe-area-inset-bottom))}.knob{width:48px;height:48px;margin:-24px 0 0 -24px}.actions{grid-template-columns:68px 68px;gap:8px;right:calc(10px + env(safe-area-inset-right));bottom:calc(10px + env(safe-area-inset-bottom))}.actions button{width:64px;height:64px;font-size:12px}#btn-jump{width:72px;height:72px;font-size:13px}body.touch-ui #hotbar-wrap{bottom:calc(158px + env(safe-area-inset-bottom));max-width:calc(100vw - 16px - env(safe-area-inset-left) - env(safe-area-inset-right))}body.touch-ui #hotbar{gap:3px}body.touch-ui .slot{width:32px;height:32px;border-radius:8px}body.touch-ui .slot img{width:20px;height:20px}.slot .num{font-size:9px}.map-row{flex-direction:column;align-items:stretch}.map-actions{display:grid;grid-template-columns:1fr 1fr}}@media(max-height:480px)and (orientation:landscape){#topbar{padding-top:calc(4px + env(safe-area-inset-top))}.mark{font-size:16px}#detail,.hint{display:none}#where,#coords{font-size:11px}.pills button{min-height:32px;padding:0 8px;font-size:12px}body.touch-ui #mount-btn{top:calc(40px + env(safe-area-inset-top));bottom:auto;min-height:40px}body.touch-ui #minimap{top:calc(42px + env(safe-area-inset-top));right:calc(8px + env(safe-area-inset-right));width:84px;height:84px}.joystick{width:88px;height:88px;left:calc(8px + env(safe-area-inset-left));bottom:calc(8px + env(safe-area-inset-bottom))}.knob{width:42px;height:42px;margin:-21px 0 0 -21px}.actions{grid-template-columns:54px 54px 60px;grid-template-areas:"break place jump";gap:6px;right:calc(8px + env(safe-area-inset-right));bottom:calc(8px + env(safe-area-inset-bottom))}.actions button,#btn-jump{width:54px;height:54px;font-size:11px}#btn-jump{width:60px;height:60px}body.touch-ui #hotbar-wrap{bottom:calc(8px + env(safe-area-inset-bottom));max-width:calc(100vw - 290px - env(safe-area-inset-left) - env(safe-area-inset-right))}body.touch-ui #hotbar{gap:3px}body.touch-ui .slot{width:32px;height:32px}body.touch-ui .slot img{width:18px;height:18px}.slot.all{font-size:9px}}.sheet{position:fixed;z-index:30;top:0;right:0;bottom:0;left:0;display:flex;flex-direction:column;gap:8px;padding:calc(10px + env(safe-area-inset-top)) calc(12px + env(safe-area-inset-right)) calc(12px + env(safe-area-inset-bottom)) calc(12px + env(safe-area-inset-left));background:#f4ecdc;color:#241910;touch-action:pan-y;overflow:auto}.sheet[hidden]{display:none}.dialog-back{position:fixed;z-index:32;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;padding:calc(16px + env(safe-area-inset-top)) 16px calc(16px + env(safe-area-inset-bottom));background:#1c140e73}.dialog-back[hidden]{display:none}.dialog{width:min(400px,100%);display:flex;flex-direction:column;gap:12px;padding:16px;border-radius:16px;background:#f4ecdc;color:#241910;box-shadow:0 16px 40px #1c140e47}.dialog .sheet-bar h2{font-size:26px}.dialog #place-form{max-width:none}.sheet-bar{display:flex;align-items:center;justify-content:space-between;gap:12px}.sheet-bar h2{margin:0;font-family:"Liberation Serif",Georgia,serif;font-size:28px}.sheet-bar button,.map-row{min-height:44px;border-radius:999px;border:0;background:#9c4a32;color:#fffaf3;font-weight:700;padding:0 16px}.sheet-note{margin:0;font-size:14px}#city-map{width:100%;height:min(46vh,420px);border-radius:12px;background:#e7d3a4;touch-action:none;flex:0 0 auto}#map-list{display:flex;flex-direction:column;gap:8px}.map-row{width:100%;border-radius:12px;text-align:left;background:#fffaf3;color:#241910;border:1px solid rgba(36,25,16,.12);display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:8px;padding:8px 12px;min-height:0}.map-row strong,.map-row small{display:block}.map-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end}.map-head{margin:8px 0 0;font-size:13px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:#5c4636}.map-actions button,.map-actions .sv-link{min-height:44px;border-radius:999px;border:0;background:#9c4a32;color:#fffaf3;font-weight:700;padding:8px 14px;text-decoration:none;display:inline-flex;align-items:center;justify-content:center}.map-actions .map-remove{background:#5c4636}.map-row small{color:#5c4636;font-weight:600}#place-form{display:flex;flex-direction:column;gap:12px;max-width:420px}#place-name{min-height:48px;border-radius:12px;border:1px solid rgba(36,25,16,.25);background:#fffaf3;color:#241910;font:inherit;font-size:16px;padding:0 14px;user-select:text;-webkit-user-select:text}#place-form button{min-height:48px;border:0;border-radius:999px;background:#9c4a32;color:#fffaf3;font-weight:700}#palette-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(104px,1fr));gap:8px}.palette-block{min-height:72px;border-radius:12px;border:1px solid rgba(36,25,16,.15);background:#fffaf3;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;font-size:12px;font-weight:700;color:#241910}.palette-block img{width:28px;height:28px;image-rendering:pixelated}
