/* Receipt-only celebration: the upper display is a stage; the lower display
   retains large native controls, including on compact two-screen layouts. */
.display-preview:has(.mystery-reveal-stage){padding:0!important;overflow:hidden;background:#17223f;color:#fff3ce}
.mystery-reveal-stage{position:absolute;inset:0;isolation:isolate;display:grid;place-items:center;overflow:hidden;background:radial-gradient(ellipse at 50% 45%,#334a70,#17223f 70%);font-family:system-ui,sans-serif;text-align:center}
.dual-console .screen .mystery-reveal-stage>canvas{position:absolute;inset:0;width:100%;height:100%;max-width:none;object-fit:contain;margin:0;image-rendering:pixelated;pointer-events:none}
.mystery-reveal-eyebrow{position:absolute;top:5%;left:10%;right:10%;color:#f5dcaa;font-size:clamp(10px,1.5vw,14px);font-weight:800;letter-spacing:.17em;line-height:1.3;text-shadow:0 2px 3px #111a30}
.mystery-reveal-caption{position:absolute;bottom:5%;left:6%;right:6%;margin:0;padding:4px 8px;border-radius:6px;background:#17223feb;color:#fff4d2;font-size:clamp(12px,1.8vw,18px);font-weight:750;line-height:1.2;overflow-wrap:anywhere;text-wrap:balance}
.mystery-reveal-stage[data-variant=prism] .mystery-reveal-caption{color:#c7f6ff;border:1px solid #bba5e0}
.mystery-reveal-stage[data-variant=shiny] .mystery-reveal-caption{color:#ffe29c}
.mystery-reveal-items{position:absolute;top:20%;bottom:22%;left:10%;right:10%;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;align-content:center}
.mystery-reveal-items[data-count="1"]{grid-template-columns:minmax(0,1fr);left:26%;right:26%}
.mystery-item{min-width:0;border:1px solid #7f8fa7;border-radius:10px;padding:7px 5px;background:linear-gradient(145deg,#34435ded,#1c2a47ed);box-shadow:0 5px 15px #09132960;color:#fff1cb;animation:mystery-item-arrive .5s cubic-bezier(.2,.8,.3,1) both}
.mystery-item:nth-child(2){animation-delay:.12s}.mystery-item:nth-child(3){animation-delay:.24s}.mystery-item:nth-child(4){animation-delay:.36s}
.mystery-item-art{display:flex;align-items:center;justify-content:center;gap:7px}.mystery-item-art img{width:clamp(24px,5vw,42px);height:clamp(24px,5vw,42px);object-fit:contain;image-rendering:pixelated}.mystery-item-art strong{font-size:clamp(16px,2.5vw,26px);font-variant-numeric:tabular-nums;white-space:nowrap}.mystery-item h3{margin:3px 0 0;font-size:clamp(10px,1.6vw,15px);line-height:1.15;overflow-wrap:anywhere;color:inherit}.mystery-item small{font-size:10px}
.mystery-reveal-items[data-count="1"] .mystery-item{padding:14px 8px}.mystery-reveal-items[data-count="1"] img{width:56px;height:56px}
.mystery-reveal-stage[data-kind=items] .mystery-reveal-caption{font-size:clamp(10px,1.4vw,14px)}
.mystery-fallback-art{position:absolute;top:22%;left:25%;width:50%;height:53%;object-fit:contain;image-rendering:pixelated}
.mystery-reveal-stage [hidden]{display:none!important}
#control-display #overlay[data-kind=mystery-reveal]{display:flex!important;flex-direction:column;gap:8px;overflow:auto;padding:10px!important}
#control-display #overlay[data-kind=mystery-reveal]>.overlay-header{flex:none;margin:0;padding-bottom:5px;min-height:0}
#control-display #overlay[data-kind=mystery-reveal]>.overlay-header .sub{display:none}
#control-display #overlay[data-kind=mystery-reveal]>.overlay-header h2{font-size:clamp(18px,3vw,24px);line-height:1.1;margin:0}
#mystery-reveal-anchor{flex:1 1 auto;min-height:0;overflow:auto;overscroll-behavior:contain}
#mystery-reveal-status{font:700 clamp(15px,2.4vw,20px)/1.3 system-ui,sans-serif;margin:0 0 7px;overflow-wrap:anywhere}
.mystery-reveal-safe{font:12px/1.4 system-ui,sans-serif;margin:0;opacity:.85}
.mystery-reveal-actions{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(0,1fr);gap:7px;flex:none}
#control-display .mystery-reveal-actions button{min-height:44px;padding:8px 6px;font:700 clamp(12px,2vw,16px)/1.15 system-ui,sans-serif;touch-action:manipulation;white-space:normal}
@keyframes mystery-item-arrive{from{opacity:0;transform:translateY(12px) scale(.85)}to{opacity:1;transform:none}}
.mystery-reveal-stage[data-quiet=true] .mystery-item{animation:none}
@media(prefers-reduced-motion:reduce){.mystery-item{animation:none}}
@media(max-width:359px){.mystery-reveal-items{gap:4px;left:8%;right:8%}.mystery-item{padding:4px}.mystery-item-art{gap:4px}.mystery-reveal-eyebrow{letter-spacing:.09em}.mystery-reveal-safe{font-size:11px}.mystery-reveal-actions{gap:4px}}
/* The reveal owns the upper screen and has no dialogue. Reclaim its band even
   if an earlier toast is still visible; closing restores the normal layout. */
.dual-console[data-surface=adventure] .top-display:has(.mystery-reveal-stage) .display-dialogue{display:none}
.mystery-reveal-stage{container-type:size}
.mystery-reveal-items{top:18%;bottom:18%;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin}
@container(max-height:230px){
 .mystery-reveal-items{left:6%;right:6%;gap:4px}
 .mystery-reveal-items:not([data-count="1"]) .mystery-item{display:grid;grid-template-columns:auto minmax(0,1fr);gap:4px;padding:4px;align-items:center}
 .mystery-reveal-items:not([data-count="1"]) .mystery-item-art{gap:3px}
 .mystery-reveal-items:not([data-count="1"]) .mystery-item-art img{width:22px;height:22px}
 .mystery-reveal-items:not([data-count="1"]) .mystery-item-art strong{font-size:15px}
 .mystery-reveal-items:not([data-count="1"]) h3{font-size:10px;line-height:1.1;margin:0}
 .mystery-reveal-items:not([data-count="1"]) small{grid-column:2;font-size:9px}
 .mystery-reveal-items[data-count="1"] .mystery-item{padding:8px}
 .mystery-reveal-items[data-count="1"] img{width:40px;height:40px}
 .mystery-reveal-eyebrow{font-size:10px;top:4%}.mystery-reveal-caption{font-size:11px;bottom:3%;padding:3px 5px}
}
