:root { --ink: #0d1117; --paper: rgba(12, 16, 24, .82); --line: rgba(255, 255, 255, .16); --accent: #6fd3ff; --good: #7ee787; --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; } * { box-sizing: border-box; -webkit-tap-highlight-color: transparent; } html, body { margin: 0; height: 100%; overflow: hidden; background: #9fd4ff; color: #eaf2ff; font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif; } body { touch-action: none; user-select: none; } #app, #gl { position: fixed; inset: 0; width: 100%; height: 100%; display: block; } #gl { image-rendering: pixelated; } #crosshair { position: fixed; left: 50%; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; pointer-events: none; opacity: .85; mix-blend-mode: difference; } #crosshair::before, #crosshair::after { content: ""; position: absolute; background: #fff; } #crosshair::before { left: 8px; top: 0; width: 2px; height: 18px; } #crosshair::after { top: 8px; left: 0; height: 2px; width: 18px; } #hud { position: fixed; left: 12px; top: 12px; padding: 6px 10px; border-radius: 8px; background: var(--paper); border: 1px solid var(--line); font: 12px/1 var(--mono); color: #cfe6ff; pointer-events: none; letter-spacing: .02em; } #tag { position: fixed; right: 12px; top: 12px; padding: 6px 10px; border-radius: 8px; background: var(--paper); border: 1px solid var(--line); font-size: 12px; color: #cfe6ff; pointer-events: none; } .hotbar { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); transform: translateX(-50%); display: flex; gap: 6px; padding: 6px; border-radius: 12px; background: rgba(8, 12, 18, .55); border: 1px solid var(--line); backdrop-filter: blur(8px); } .slot { position: relative; width: 46px; height: 46px; border-radius: 8px; border: 2px solid rgba(255,255,255,.18); background: rgba(255,255,255,.08); padding: 0; display: grid; place-items: center; cursor: pointer; transition: transform .08s ease, border-color .12s ease; } .slot canvas { width: 30px; height: 30px; image-rendering: pixelated; border-radius: 3px; } .slot.on { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(111,211,255,.25); transform: translateY(-3px); } .slot { color: #9fb6cf; font: 10px/1 var(--mono); } #cur { position: fixed; left: 50%; bottom: calc(78px + env(safe-area-inset-bottom)); transform: translateX(-50%); font-size: 12px; color: #e8f3ff; text-shadow: 0 1px 3px rgba(0,0,0,.6); } #cur b { color: #fff; } #toast { position: fixed; left: 50%; top: 22%; transform: translate(-50%, -8px); padding: 8px 14px; border-radius: 10px; background: rgba(10, 14, 20, .86); border: 1px solid var(--line); font-size: 13px; opacity: 0; transition: opacity .2s ease, transform .2s ease; pointer-events: none; } #toast.show { opacity: 1; transform: translate(-50%, 0); } #pause { position: fixed; inset: 0; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, rgba(95,170,255,.28), rgba(6,12,22,.82)); backdrop-filter: blur(3px); } #pause[hidden] { display: none; } .pause-card { width: min(460px, 88vw); padding: 26px; border-radius: 18px; background: rgba(10, 16, 26, .82); border: 1px solid var(--line); text-align: center; box-shadow: 0 20px 60px rgba(0,0,0,.45); } .pause-card h1 { margin: 0 0 6px; font-size: 26px; letter-spacing: .04em; } .pause-card p { margin: 6px 0 16px; color: #b9cde4; font-size: 13px; } .pause-card .row { display: flex; gap: 10px; justify-content: center; } .hint { font-size: 11.5px; color: #8fa6bd; margin-top: 14px !important; } .hint b { font-family: var(--mono); color: #cfe6ff; } .btn { border: 1px solid rgba(111,211,255,.4); background: linear-gradient(180deg, rgba(111,211,255,.26), rgba(111,211,255,.12)); color: #eaf6ff; padding: 9px 16px; border-radius: 10px; font-size: 13px; cursor: pointer; } .btn:hover { border-color: var(--accent); } .btn.ghost { background: rgba(255,255,255,.06); border-color: var(--line); } #help { position: fixed; inset: 0; display: grid; place-items: center; background: rgba(4, 8, 14, .72); backdrop-filter: blur(4px); z-index: 20; } #help[hidden] { display: none; } .help-card { width: min(520px, 90vw); max-height: 84vh; overflow: auto; padding: 22px; border-radius: 16px; background: #0d1520; border: 1px solid var(--line); } .help-card h2 { margin: 0 0 14px; font-size: 18px; } .keys { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; font-size: 13px; color: #cfe0f2; } kbd { display: inline-block; min-width: 20px; padding: 2px 6px; margin-right: 3px; border-radius: 5px; background: rgba(255,255,255,.1); border: 1px solid var(--line); font: 11px/1.5 var(--mono); text-align: center; } .tip { font-size: 12.5px; color: #9db2c8; margin: 12px 0 0; } .help-card .btn { margin-top: 16px; width: 100%; } /* 触屏 */ body.touch #crosshair { opacity: .6; } #joy { position: fixed; width: 108px; height: 108px; border-radius: 50%; border: 2px solid rgba(255,255,255,.3); background: rgba(10,16,26,.25); margin-left: -54px; margin-top: -54px; pointer-events: none; z-index: 10; } #joy[hidden] { display: none; } #stick { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; background: rgba(255,255,255,.55); box-shadow: 0 4px 12px rgba(0,0,0,.3); } #touchpad { display: none; position: fixed; right: 12px; bottom: calc(96px + env(safe-area-inset-bottom)); grid-template-columns: 56px 56px; gap: 8px; z-index: 10; } body.touch #touchpad { display: grid; } .tbtn { width: 56px; height: 56px; border-radius: 50%; border: 1px solid rgba(255,255,255,.28); background: rgba(10,16,26,.38); color: #eaf6ff; font-size: 13px; backdrop-filter: blur(6px); } .tbtn:active { background: rgba(111,211,255,.35); } body.touch .hotbar { bottom: calc(10px + env(safe-area-inset-bottom)); } body.touch #cur { bottom: calc(66px + env(safe-area-inset-bottom)); } body.touch .slot { width: 40px; height: 40px; } body.touch .slot canvas { width: 26px; height: 26px; } .nogl { position: fixed; inset: 0; display: grid; place-content: center; gap: 8px; text-align: center; padding: 24px; background: #0b1220; z-index: 50; } .nogl h1 { margin: 0; font-size: 20px; } .nogl p { margin: 0; color: #9db2c8; font-size: 13px; }