:root{--bg: #0e1116;--panel: #171c26;--panel-2: #212940;--text: #e8ecf4;--muted: #93a0b4;--ink: #0b0f16;--line: #3a465e;--wood: #6f5738;--correct: #35a56b;--danger: #f2565f;--heart: #f43f5e;--key: #333c52;--key-dead: #232a3b;--accent: #38bdf8;--accent-ink: #06283a;color-scheme:dark}*{box-sizing:border-box}[hidden]{display:none!important}html,body,#app{height:100%}body{margin:0;background:var(--bg);color:var(--text);font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;-webkit-tap-highlight-color:transparent;overflow:hidden}.game{position:relative;height:100%;max-width:620px;margin-inline:auto;padding:max(10px,env(safe-area-inset-top)) max(10px,env(safe-area-inset-right)) max(10px,env(safe-area-inset-bottom)) max(10px,env(safe-area-inset-left));display:flex;flex-direction:column;gap:10px;-webkit-touch-callout:none;-webkit-user-select:none;user-select:none}.hud{display:flex;align-items:center;justify-content:space-between;gap:8px;flex:none}.chips{display:flex;gap:6px;min-width:0}.chip{display:inline-flex;align-items:center;gap:6px;min-height:38px;padding-inline:10px;border-radius:10px;background:var(--panel);font-size:15px;font-weight:700;font-variant-numeric:tabular-nums;white-space:nowrap}.chip .icon{width:17px;height:17px;flex:none}#lives-chip .icon{color:var(--heart)}#lives-chip.is-low{color:var(--danger)}#lives-chip.is-low .icon{color:var(--danger);animation:beat 1.1s ease-in-out infinite}@keyframes beat{0%,to{transform:scale(1)}30%{transform:scale(1.18)}}#streak-chip .icon{color:#f59e0b}.actions{display:flex;gap:6px}.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;min-width:44px;padding-inline:14px;border:0;border-radius:10px;background:var(--panel-2);color:var(--text);font:inherit;font-weight:600;cursor:pointer;touch-action:manipulation}.btn .icon{width:21px;height:21px;flex:none}.btn:active{transform:translateY(1px)}.btn-icon{padding-inline:0}.btn-primary{background:var(--accent);color:var(--accent-ink);padding-inline:22px}.stage{flex:1;min-height:0;min-width:0;display:flex;flex-direction:column;align-items:center;gap:10px}.figure-wrap{flex:1;min-height:0;width:100%;display:flex;justify-content:center}.figure{width:100%;height:100%;max-width:260px}.gallows path{fill:none;stroke:var(--wood);stroke-width:8;stroke-linecap:round}.rope{fill:none;stroke:var(--wood);stroke-width:5;stroke-linecap:round}.part{fill:none;stroke:var(--text);stroke-width:6;stroke-linecap:round;stroke-dasharray:1;stroke-dashoffset:1;transition:stroke-dashoffset .34s ease-out}.part.is-on{stroke-dashoffset:0}.figure.is-lost .part{stroke:var(--danger)}.word-wrap{flex:none;width:100%;min-width:0;display:flex;flex-direction:column;align-items:center;gap:6px}.clue{margin:0;display:flex;gap:6px;align-items:baseline;font-size:13px;font-weight:700}.clue-label{color:var(--muted);text-transform:uppercase;letter-spacing:.04em;font-size:11px}.clue-value{color:var(--accent)}.word{display:flex;justify-content:center;gap:6px;width:100%;min-width:0}.slot{width:var(--slot, 40px);height:calc(var(--slot, 40px) * 1.2);display:flex;align-items:flex-end;justify-content:center;border-bottom:3px solid var(--line);color:transparent;font-size:calc(var(--slot, 40px) * .66);font-weight:800;line-height:1.05}.slot.is-open{color:var(--text);border-bottom-color:var(--correct)}.slot.is-missed{color:var(--danger);border-bottom-color:var(--danger)}.slot.is-pop{animation:pop .2s ease-out}@keyframes pop{0%{transform:translateY(22%) scale(.7);opacity:0}to{transform:none;opacity:1}}.overlay{position:absolute;inset:0;z-index:2;display:flex;align-items:center;justify-content:center;padding:10px;background:#0e1116ad;-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px);animation:overlay-in .2s ease-out}@keyframes overlay-in{0%{opacity:0}to{opacity:1}}.card{width:min(100%,330px);max-height:100%;overflow-y:auto;display:flex;flex-direction:column;align-items:center;gap:8px;padding:16px 18px;border-radius:16px;background:var(--panel);box-shadow:0 18px 44px #0000008c;text-align:center}.card-title{margin:0;font-size:clamp(19px,4.4vw,26px);font-weight:800}.card-line{margin:0;color:var(--muted);font-size:15px;font-weight:600}.stats{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;width:100%;margin:2px 0 0}.stat{display:flex;flex-direction:column;align-items:center;gap:2px}.stat-value{margin:0;font-size:20px;font-weight:800;font-variant-numeric:tabular-nums}.stat-label{font-size:11px;line-height:1.2;color:var(--muted)}.card-actions{display:flex;flex-wrap:wrap;justify-content:center;gap:8px;margin-top:6px}.side{flex:none;display:flex;flex-direction:column;gap:8px;min-width:0}.keys{display:flex;flex-direction:column;gap:5px}.key-row{display:flex;justify-content:center;gap:4px}.key{flex:1 1 0;min-width:0;height:46px;display:flex;align-items:center;justify-content:center;padding:0 2px;border:0;border-radius:7px;background:var(--key);color:var(--text);font:inherit;font-size:clamp(13px,3.4vw,18px);font-weight:700;cursor:pointer;touch-action:manipulation}.key:active{transform:translateY(1px)}.key.is-hit{background:var(--correct);color:var(--ink)}.key.is-miss{background:var(--key-dead);color:#6b7488}.key:disabled{cursor:default}.key:disabled:active{transform:none}.key:disabled:not(.is-hit):not(.is-miss){opacity:.45}.key-row:last-child{padding-inline-end:56px}.hint{flex:none;margin:0;margin-inline-end:56px;text-align:center;color:var(--muted);font-size:13px;line-height:1.45}@media(min-width:620px){.key-row:last-child,.hint{padding-inline-end:0;margin-inline-end:150px}}@media(max-width:440px){.game{gap:8px;padding-left:max(8px,env(safe-area-inset-left));padding-right:max(8px,env(safe-area-inset-right))}.key{border-radius:6px}.key-row{gap:3px}}@media(max-height:620px){.game{gap:8px}.stage{gap:6px}.chip{min-height:34px;padding-inline:8px;font-size:14px}.key{height:44px}.hint{font-size:12px}}@media(max-height:470px){.key{height:38px;font-size:14px}.keys{gap:4px}.hint{display:none}.card{gap:5px;padding:12px 14px}}@media(min-aspect-ratio:6 / 5)and (min-width:560px){.game{display:grid;grid-template-columns:minmax(0,1fr) min(46vw,460px);grid-template-rows:auto 1fr;column-gap:12px;max-width:none}.hud{grid-column:1 / -1}.side{align-self:center;min-width:0}.key-row:last-child,.hint{padding-inline-end:0;margin-inline-end:0}.key{height:46px}}@media(min-aspect-ratio:6 / 5)and (min-width:560px)and (max-height:430px){.key{height:40px;font-size:15px}}@media(prefers-reduced-motion:reduce){.part{transition-duration:1ms}.slot.is-pop,.overlay,#lives-chip.is-low .icon{animation-duration:1ms;animation-iteration-count:1}}
