html,body{margin:0;min-width:0;background:#fff9ef}body{border:0;padding:0}.play-stage{border:0;width:100%;min-width:0}.game-heading h1{font:inherit;font-size:clamp(1.6rem,4vw,2.6rem);line-height:1;margin:0}.game-panel{min-width:0}button{touch-action:manipulation}
/* Keep the control slot in flow while its action is unavailable. */
#double-take .game-actions{margin-bottom:18px}
#memory-action.is-unavailable{visibility:hidden;pointer-events:none}
#double-take[data-state="idle"] .memory-tile:disabled{background:var(--soft);color:var(--muted);box-shadow:0 4px 0 #d8cec1}
#double-take[data-state="idle"] .back-symbol{--symbol-hole:var(--soft)}
/* A minimum, not a fixed height: messages can grow with text zoom. */
#memory-status{min-height:calc(4.5em + 23px)}
@media(max-width:639px){#memory-status{min-height:calc(7.5em + 28px)}}

/* Set synchronously in the head, before styles: standalone keeps its layout. */
.is-embedded .game-heading > div:first-child,
.is-embedded #memory-instructions {
  position:absolute;width:1px;height:1px;padding:0;margin:-1px;
  overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0;
}
.is-embedded .play-stage { min-height:0; padding-top:12px; }
.is-embedded .game-heading { justify-content:flex-end; margin-bottom:12px; }
@media(max-width:639px) {
  .is-embedded #double-take .game-actions { flex-wrap:nowrap; align-items:stretch; gap:8px; }
  .is-embedded #memory-action {
    flex:1;min-width:0;width:auto;gap:8px;padding-inline:10px;
  }
  .is-embedded #memory-action > .icon { display:none; }
  .is-embedded #memory-reset { flex:none;margin-left:0;min-height:48px; }
}
