/* Word Quest FX kit styles (see assets/fx.js). Game-specific styles live in assets/arcade/<game>.css. */
#fx .fxp,#fx .fxf,#fx .fxb,#fx .fxflash{position:absolute;pointer-events:none;font-style:normal;will-change:transform,opacity}
#fx .fxp{line-height:1}
#fx .fxd{border-radius:2px;border:2px solid #1b1f2e}
#fx .fxf{font-weight:900;font-size:28px;color:#ffc928;white-space:nowrap;-webkit-text-stroke:5px #1b1f2e;paint-order:stroke fill;text-shadow:0 3px 0 #1b1f2e}
#fx .fxb{left:50%;top:42%;font-weight:900;font-size:clamp(56px,16vw,150px);color:#ffc928;white-space:nowrap;-webkit-text-stroke:10px #1b1f2e;paint-order:stroke fill;text-shadow:0 8px 0 #1b1f2e}
#fx .fxflash{inset:0}

/* a Wordling actor: give .fxactor a size (width or height) in the game's own CSS; it stays square */
.fxactor{position:relative;aspect-ratio:1;width:clamp(96px,22vmin,220px);flex:none}
.fxactor.big{width:clamp(140px,34vmin,340px)}.fxactor.small{width:clamp(64px,13vmin,120px)}
.fxactor-in{position:absolute;inset:0;display:grid;place-items:center;transform-origin:50% 85%}
.fxactor img,.fxactor-in img{width:88%;height:88%;object-fit:contain}
.fxactor-in.flip2d img{transform:scaleX(-1)}
.fxactor canvas.fx3d{width:100%!important;height:100%!important;display:block}
.fxactor .monf{font-size:clamp(48px,12vmin,120px)}

/* a full-bleed game stage: <main class="fxg" style="--g1:#243b6b;--g2:#0f1220"> … fills the screen under .shead,
   never scrolls, and lays its children out as a column: HUD (.fxg-hud), play area (.fxg-play, takes the spare room), controls (.fxg-foot) */
#app>main.fxg{padding:0;overflow:hidden;position:relative;display:flex;flex-direction:column;color:#fff;
  background:radial-gradient(120% 80% at 50% 0,var(--g1,#2f5fb3),var(--g2,#141a33))}
.fxg-hud{flex:none;display:flex;align-items:center;gap:10px;padding:10px max(14px,env(safe-area-inset-left)) 6px max(14px,env(safe-area-inset-right));font-weight:900}
.fxg-play{flex:1;min-height:0;position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:clamp(8px,2vmin,20px);padding:8px max(14px,calc((100% - 1100px)/2))}
.fxg-foot{flex:none;padding:8px max(14px,calc((100% - 900px)/2)) calc(14px + env(safe-area-inset-bottom))}
.fxg .chip{background:rgba(15,18,32,.55);border:3px solid #0f1220;border-radius:12px;padding:4px 12px;font-weight:900;white-space:nowrap}
.fxg .chip.hot{background:#ff7a1a;color:#fff;animation:fxhot .5s infinite alternate}
@keyframes fxhot{to{transform:scale(1.08);filter:brightness(1.25)}}
.fxg .timebar{flex:1;height:16px;border-radius:10px;background:rgba(15,18,32,.55);border:3px solid #0f1220;overflow:hidden}
.fxg .timebar>i{display:block;height:100%;background:linear-gradient(90deg,#57c84d,#ffc928);transition:width .25s linear}
.fxg .timebar.low>i{background:#e5484d}
/* fever / danger moods a game can toggle on the stage */
.fxg.fever{background:radial-gradient(120% 80% at 50% 0,#ff9a1f,#b3261e);animation:fxfever 1s infinite alternate}
@keyframes fxfever{to{filter:saturate(1.35) brightness(1.08)}}
@media (prefers-reduced-motion:reduce){.fxg.fever,.fxg .chip.hot{animation:none}}

/* auto-continue countdown (FX.autoScan): 3 · 2 · 1 badge on the button and a bar that empties */
.btn.auto { position: relative; overflow: hidden; }
.btn.auto::after { content: ''; position: absolute; left: 0; bottom: 0; height: 4px; width: calc(var(--cd, 1) * 100%); background: rgba(255,255,255,.75); transition: width .12s linear; }
.btn .cd { display: inline-grid; place-items: center; min-width: 1.5em; height: 1.5em; margin-left: .45em; border-radius: 50%; background: rgba(255,255,255,.3); font-weight: 800; font-size: .9em; }
