
.lb-app, .lb-app * { box-sizing: border-box; }
.lb-app { --lb-ink: #eef3fb; --lb-muted: #a9b8d0; --lb-line: rgba(255, 255, 255, .14); --lb-glass: rgba(10, 17, 30, .72);
  --lb-good: #7ed492; --lb-bad: #f2a07b; --lb-gold: #ffd34d; --lb-accent: #86efac;
  --gs-ink: var(--lb-ink); --gs-muted: var(--lb-muted); --gs-line: #26364d; --gs-accent: #86efac; --gs-accent-ink: #082414;
  --gs-panel: #111c2e; --gs-bg: #0b1220; --gs-chip: rgba(17, 28, 46, .9);
  position: relative; display: flex; flex-direction: column; color: var(--lb-ink); font: 16px/1.45 "Segoe UI", system-ui, Arial, sans-serif; overflow: clip; }
.lb-app.lb-embedded { height: clamp(560px, calc(100svh - 110px), 880px); clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px); border: 1px solid #26364d; background: #0b1220; }
.lb-app.gs-fs { background: #0b1220; }
.lb-app button { font: inherit; color: inherit; cursor: pointer; }
.lb-app button:focus-visible { outline: 2px solid var(--lb-gold); outline-offset: 2px; }
.lb-app .gs-stage, .lb-app .gs-main { min-height: 0; }
.lb-app.gs-wide .gs-stage { align-items: stretch; grid-template-rows: minmax(0, 1fr); }
.lb-app .gs-side { min-height: 0; overflow: auto; }
.lb-msg { text-align: center; padding: 30px 10px; color: var(--lb-muted); }
.lb-body { position: relative; flex: 1; min-height: 0; display: flex; }
.lb-stage { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; overflow: hidden; clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px); }
.lb-scene { position: absolute; inset: 0; background: #ffd7b0; }
.lb-scene canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.lb-plain-box { position: absolute; inset: 0; }
.lb-plain-box svg { display: block; width: 100%; height: 100%; }
.lb-scene.pw-ready .lb-plain-box { visibility: hidden; transition: visibility 0s linear .8s; }
.lb-scene.pw-ready .lb-plain-box * { animation: none; }   
.lb-place { position: absolute; right: 10px; bottom: calc(var(--lb-bottom, 150px) + 6px); z-index: 2; display: none; font: 600 11px "Segoe UI", Arial, sans-serif;
  color: #fff; background: rgba(5, 8, 14, .4); padding: 2px 9px; clip-path: polygon(4px 0, 100% 0, 100% calc(100% - 4px), calc(100% - 4px) 100%, 0 100%, 0 4px); pointer-events: none; }
.lb-scene.pw-live .lb-place { display: block; }
.lb-waves { animation: lbFlow 6s linear infinite; }
@keyframes lbFlow { from { transform: translateX(0); } to { transform: translateX(60px); } }
.lb-walker { transition: transform 0.95s ease-in-out; }
.lb-walker.walking .lb-leg-a, .lb-walker.walking .lb-arm-b { animation: lbSwing 0.32s ease-in-out infinite alternate; transform-origin: 0 -16px; }
.lb-walker.walking .lb-leg-b, .lb-walker.walking .lb-arm-a { animation: lbSwing 0.32s ease-in-out infinite alternate-reverse; transform-origin: 0 -16px; }
.lb-walker.walking .lb-fig { animation: lbBob 0.32s ease-in-out infinite alternate; }
@keyframes lbSwing { from { transform: rotate(-24deg); } to { transform: rotate(24deg); } }
@keyframes lbBob { from { transform: translateY(0); } to { transform: translateY(-2px); } }
.lb-drop { animation: lbDrop 0.5s cubic-bezier(.3,1.6,.5,1) both; }
@keyframes lbDrop { from { transform: translateY(-40px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
.lb-fall { animation: lbFall 1.2s ease-in both; transform-box: fill-box; transform-origin: center; }
@keyframes lbFall { 0% { transform: translateY(0) rotate(0); opacity: 1; } 100% { transform: translateY(95px) rotate(28deg); opacity: 0; } }
.lb-splash ellipse { animation: lbSplash 1s ease-out 0.75s both; transform-box: fill-box; transform-origin: center; }
@keyframes lbSplash { 0% { transform: scale(0.2); opacity: 0; } 30% { opacity: 1; } 100% { transform: scale(2.2); opacity: 0; } }
.lb-flag { transform-box: fill-box; transform-origin: left center; transform: scaleX(0.4); transition: transform 0.6s ease 1.6s; }
.lb-flag.up { transform: scaleX(1); animation: lbWave 1s ease-in-out 2.2s infinite alternate; }
@keyframes lbWave { from { transform: scaleX(1) skewY(0); } to { transform: scaleX(0.85) skewY(-6deg); } }
.lb-top { position: relative; z-index: 3; display: flex; flex-direction: column; gap: 8px; padding: 10px 10px 0; pointer-events: none; }
.lb-top > * { pointer-events: auto; }
.lb-hud { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; pointer-events: none; width: min(100%, 640px); align-self: center; }
.lb-chip { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; padding: 5px 4px; min-width: 0;
  background: var(--lb-glass); border: 1px solid var(--lb-line); backdrop-filter: blur(4px); clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); }
.lb-chip small { font: 700 9px/1 monospace; letter-spacing: 1.3px; color: var(--lb-muted); text-transform: uppercase; white-space: nowrap; }
.lb-chip b { display: inline-flex; align-items: center; gap: 5px; font: 800 16px/1.15 monospace; color: #fff; white-space: nowrap; font-variant-numeric: tabular-nums; }
.lb-chip b.g { color: var(--lb-accent); }
.lb-band { font-size: 11px; font-weight: 700; padding: 1px 6px; clip-path: polygon(3px 0, 100% 0, 100% calc(100% - 3px), calc(100% - 3px) 100%, 0 100%, 0 3px); background: var(--b); color: #0b1020; }
.lb-grow b { gap: 4px; min-height: 18px; }
.lb-grow i { width: 9px; height: 9px; transform: rotate(45deg); background: rgba(255, 255, 255, .22); }
.lb-grow i.on { background: #d9a867; box-shadow: 0 0 6px #d9a867; }
.lb-streak { align-self: center; width: min(100%, 640px); display: flex; justify-content: flex-end; height: 24px; visibility: hidden; pointer-events: none; }
.lb-streak.on { visibility: visible; }
.lb-pill { padding: 3px 10px; font: 700 12px/1.2 system-ui, sans-serif; color: #ffd9b0; white-space: nowrap; background: var(--lb-glass); border: 1px solid rgba(255, 150, 70, .6);
  clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); will-change: transform; }
.lb-pill b { color: #fff; font: 800 14px/1 monospace; }
.lb-pill small { font-size: 10px; color: rgba(255,255,255,.65); margin-left: 4px; }
.lb-pill.ms { color: #fff; background: rgba(120, 50, 0, .82); }
.lb-pill.pop { animation: lbPillPop .5s ease; }
.lb-pill.ms.pop { animation: lbPillMs .9s ease; }
@keyframes lbPillPop { 40% { transform: scale(1.18); } }
@keyframes lbPillMs { 25% { transform: scale(1.4); } 55% { transform: scale(.96); } 80% { transform: scale(1.08); } }
.lb-card { align-self: center; width: min(100%, 640px); background: rgba(10, 17, 30, .8); border: 1px solid var(--lb-line); clip-path: polygon(12px 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%, 0 12px);
  padding: 10px 16px 12px; text-align: center; backdrop-filter: blur(6px); box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }
.lb-fam { font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--lb-muted); }
.lb-fam b { color: var(--lb-accent); }
.lb-sent { font-size: 18px; line-height: 1.55; margin-top: 2px; }
.lb-gap { display: inline-block; min-width: 92px; margin: 0 3px; padding: 0 8px; border-bottom: 2px dashed #ffd36b; transition: background .15s, border-color .15s; }
.lb-gap.hot { background: rgba(255, 211, 107, .25); border-bottom-style: solid; }
.lb-gap.filled { border-bottom: 0; font-weight: 700; }
.lb-gap.good { color: #0f2a17; background: var(--lb-good); }
.lb-gap.bad { color: #2a1405; background: var(--lb-bad); }
.lb-say { position: absolute; left: 50%; top: 38%; z-index: 4; transform: translate(-50%, 6px); max-width: 90%; text-align: center; background: var(--lb-glass);
  border: 1px solid var(--lb-line); clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); padding: 6px 14px; font-weight: 600; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .3s, transform .3s; }
.lb-say.on { opacity: 1; transform: translate(-50%, 0); }
.lb-cross { position: absolute; inset: 0; z-index: 5; display: flex; align-items: center; justify-content: center; padding: 16px; cursor: pointer; }
.lb-cross[hidden] { display: none; }
.lb-cross-card { background: rgba(10, 17, 30, .9); border: 1px solid var(--lb-line); clip-path: polygon(14px 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%, 0 14px); padding: 16px 22px; text-align: center; max-width: 340px;
  box-shadow: 0 14px 40px rgba(0, 0, 0, .45); animation: lbPop .5s cubic-bezier(.3, 1.6, .5, 1); }
.lb-cross-icon { font-size: 40px; line-height: 1; }
.lb-stars { font-size: 26px; letter-spacing: 4px; color: rgba(255, 255, 255, .25); }
.lb-stars .on { color: var(--lb-gold); text-shadow: 0 0 10px rgba(255, 211, 77, .7); }
.lb-cross-title { font-weight: 700; font-size: 18px; }
.lb-cross-sub { color: var(--lb-muted); font-size: 14px; }
.lb-pts { margin-top: 6px; font-weight: 700; color: var(--lb-good); }
@keyframes lbPop { from { transform: scale(.7); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.lb-bottom { position: relative; z-index: 3; margin-top: auto; padding: 0 10px calc(10px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; gap: 8px; align-items: center; background: linear-gradient(transparent, rgba(5, 9, 18, .35) 40%); }
.lb-why { width: min(100%, 640px); max-height: 42vh; overflow-y: auto; background: rgba(10, 17, 30, .9); border: 1px solid var(--lb-line); clip-path: polygon(12px 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%, 0 12px); padding: 10px 14px; }
.lb-why[hidden] { display: none; }
.lb-why-head { font-size: 16px; }
.lb-why-head.good { color: var(--lb-good); }
.lb-why-head.bad { color: var(--lb-bad); }
.lb-why-head b { color: var(--lb-ink); }
.lb-tip { color: var(--lb-ink); font-size: 14px; margin-top: 4px; }
.lb-pos { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; padding: 1px 8px; clip-path: polygon(3px 0, 100% 0, 100% calc(100% - 3px), calc(100% - 3px) 100%, 0 100%, 0 3px);
  background: rgba(255, 255, 255, .12); color: #fff; vertical-align: middle; }
.lb-next { position: relative; overflow: hidden; margin-top: 8px; border: 0; clip-path: polygon(8px 0, 100% 0, 100% calc(100% - 8px), calc(100% - 8px) 100%, 0 100%, 0 8px); padding: 8px 18px; min-height: 44px; font-weight: 700; background: #86efac; color: #082414; }
.lb-ring { position: absolute; left: 0; bottom: 0; height: 3px; width: 0; background: rgba(8, 36, 20, .45); }
.lb-ring.go { animation: lbRing linear forwards; }
@keyframes lbRing { to { width: 100%; } }
.lb-opts { width: min(100%, 640px); display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.lb-opt { position: relative; min-height: 58px; clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px); border: 1px solid rgba(255, 255, 255, .18); background: linear-gradient(180deg, #8a5a2e, #5c3a1c);
  font-size: 18px; font-weight: 600; box-shadow: inset 0 -4px 0 #3a230f; touch-action: none; user-select: none; -webkit-user-select: none;
  display: flex; align-items: center; justify-content: center; gap: 8px; transition: transform .12s, box-shadow .12s, opacity .2s; }
.lb-opt:active:not([disabled]) { transform: translateY(3px); box-shadow: inset 0 -1px 0 #3a230f; }
.lb-opt.lifted { opacity: .35; }
.lb-opt.right { background: linear-gradient(180deg, #4caf6a, #2f8a4b); color: #fff; }
.lb-opt.wrong { background: linear-gradient(180deg, #b5583c, #8a3d26); color: #fff; }
.lb-opt.dim { opacity: .45; }
.lb-opt[disabled] { cursor: default; }
.lb-key { font-size: 11px; min-width: 20px; padding: 1px 5px; clip-path: polygon(3px 0, 100% 0, 100% calc(100% - 3px), calc(100% - 3px) 100%, 0 100%, 0 3px); background: rgba(255, 255, 255, .12); color: var(--lb-muted); }
@media (hover: none) { .lb-key { display: none; } }
.lb-ghost { position: fixed; z-index: 99; pointer-events: none; transform: translate(-50%, -60%) scale(1.08); min-width: 120px; padding: 0 16px;
  box-shadow: 0 14px 30px rgba(0, 0, 0, .45); }
.lb-app .shake, .lb-ghost.shake { animation: lbShake .38s; }
@keyframes lbShake { 0%, 100% { transform: translateX(0); } 20% { transform: translateX(-7px); } 40% { transform: translateX(6px); } 60% { transform: translateX(-4px); } 80% { transform: translateX(3px); } }
.lb-list { margin: 0; padding-left: 18px; display: grid; gap: 6px; }
@media (max-width: 420px) {
  .lb-app.gs-root .gs-bar { gap: 4px; }
  .lb-app.gs-root .gs-btn { min-width: 40px; padding: 0 6px; }
  .lb-app .gs-title { font-size: 13px; letter-spacing: .04em; }
  .lb-sent { font-size: 17px; }
  .lb-opt { min-height: 54px; font-size: 17px; }
  .lb-hud { gap: 4px; }
  .lb-chip small { font-size: 8.5px; letter-spacing: 1px; }
  .lb-chip b { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) { .lb-app .shake { animation: none; } }
