/* The store (shop.js). Quiet on purpose: near-black, big tight type, soft depth, one accent. All the
   motion uses the same long, soft curve, so everything arrives the way a good door closes. Worlds
   repaint it through the --px variables. */

body { --px-ease: cubic-bezier(.16,1,.3,1);
  --px-bg: radial-gradient(90% 70% at 50% 18%, #1c1417 0%, #0b080a 55%, #050405 100%);
  --px-card: linear-gradient(180deg, #1d191c 0%, #120f12 100%); --px-edge: rgba(255,255,255,.09); --px-edge-hi: rgba(255,255,255,.16);
  --px-text: #f7f3ee; --px-dim: rgba(247,243,238,.58); --px-faint: rgba(247,243,238,.36);
  --px-accent: #ffd98a; --px-glow: rgba(255,190,90,.5); --px-light: rgba(255,226,170,.13); --px-seg: rgba(255,255,255,.06); --px-thumb: rgba(255,255,255,.13);
  --px-primary: linear-gradient(180deg, #fff3cc, #e8bb5c); --px-on-primary: #2a1a08; --px-pill: rgba(255,255,255,.1); --px-pill-hover: rgba(255,255,255,.17);
  --px-plate: radial-gradient(60% 75% at 50% 60%, rgba(255,226,170,.17), transparent 72%); --px-bubble: #181416;
  --px-own-glow: rgba(255,205,120,.34); --px-rim-lo: rgba(224,176,74,.6); --px-rim-hi: #ffe6a8; }

/* ---- the chips, in the top bar next to the spice ---- */
#topbar .chip-pill { display: inline-flex; align-items: center; gap: .45vw; }
#topbar .chip-pill b { font-weight: 700; letter-spacing: 0; font-size: 1.08em; font-variant-numeric: tabular-nums; color: var(--px-accent); }
.chip-pill-icon { display: block; font-size: 1.35em; line-height: 0; }
.chip-pill:not(.hidden) { animation: px-pill-in .9s var(--px-ease); }
body:not(.hub-open) #topbar .chip-pill { display: none; }
#topbar .chip-pill.glow { animation: px-pill-glow .9s var(--px-ease); }
@keyframes px-pill-in { from { opacity: 0; transform: translateX(1vw) scale(.9); filter: blur(6px); } }
@keyframes px-pill-glow { 30% { box-shadow: 0 0 0 1px var(--px-accent), 0 0 2.2vw var(--px-glow); transform: scale(1.06); } }

#hub-view-store { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding-top: 56px; box-sizing: border-box; background: var(--px-bg); font-family: "Quicksand", sans-serif; color: var(--px-text); -webkit-font-smoothing: antialiased; }
#hub-view-store.hidden { display: none; }

/* ---- before you own it: the pitch. Copy on the left, Pib selling it on the right ---- */
.px-gate { position: relative; width: 100%; height: 100%; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, .55fr); align-items: center; gap: 1vw; padding: 0 5vw 0 8vw; box-sizing: border-box; }
.px-gate::before { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(40% 55% at 74% 58%, rgba(255,79,154,.14), transparent 70%), radial-gradient(45% 50% at 22% 40%, rgba(255,190,90,.12), transparent 70%); }
.px-pitch { position: relative; display: flex; flex-direction: column; align-items: flex-start; }
.px-pitch > * { animation: px-in 1.1s calc(var(--i, 0) * .09s) var(--px-ease) both; }
.px-kicker { font-size: max(12px, .9vw); font-weight: 600; letter-spacing: .32em; text-transform: uppercase; color: #ff8cc4; text-shadow: 0 0 .8vw rgba(255,79,154,.6); }
/* the headline as Vegas neon, like the Squib sign: "Game night," in a pink tube, "hosted." in gold */
.px-pitch-h { margin: 0; font-family: "Sacramento", cursive; font-weight: 400; font-size: 7.6vw; line-height: 1.02; letter-spacing: 0; color: #ffe6f1; -webkit-text-stroke: .07vw #ffe6f1;
  text-shadow: 0 0 1px #fff, 0 0 .4vw #ffb3d6, 0 0 1vw #ff6fae, 0 0 2.2vw #ff4f9a, 0 0 4.6vw rgba(255,79,154,.5); animation: px-hum 4.4s ease-in-out 1.2s infinite; }
.px-hosted { display: inline-block; margin-left: 2.4vw; font-size: 1.18em; color: #fff6dc; -webkit-text-stroke: .08vw #fff6dc;
  text-shadow: 0 0 1px #fff, 0 0 .47vw #ffe3a0, 0 0 1.1vw #ffc35a, 0 0 2.3vw #ffa53a, 0 0 4.8vw rgba(255,150,50,.55); animation: px-hum 5s ease-in-out 1.5s infinite; }
@keyframes px-hum { 0%, 100% { filter: brightness(1); } 50% { filter: brightness(1.12); } }
.px-pitch-p { margin: 1.4vw 0 0; max-width: 40vw; font-size: max(15px, 1.45vw); line-height: 1.45; font-weight: 500; color: var(--px-dim); }
/* the games, lit up in their own colours */
.px-games { list-style: none; margin: 2.4vw 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: .6vw; }
.px-games li { position: relative; animation: px-in 1s calc(.3s + var(--k) * .08s) var(--px-ease) both; }
.px-games li.open { z-index: 5; }
.px-game { display: flex; align-items: center; gap: .5vw; min-height: 44px; padding: .6vw 1vw .6vw .75vw; border-radius: 999px; cursor: pointer; font: 600 max(13px, .98vw) "Quicksand", sans-serif; color: var(--px-text);
  border: 1px solid color-mix(in srgb, var(--c) 55%, transparent); background: color-mix(in srgb, var(--c) 9%, transparent); box-shadow: 0 0 1.4vw -.5vw var(--c);
  transition: background .2s, border-color .2s, box-shadow .2s, transform .2s var(--px-ease); }
.px-game:hover, .px-game[aria-expanded="true"] { border-color: var(--c); background: color-mix(in srgb, var(--c) 20%, transparent); box-shadow: 0 0 1.8vw -.2vw var(--c); }
.px-game:active { transform: scale(.97); }
.px-game:focus-visible { outline: 2px solid var(--c); outline-offset: 3px; }
/* the info bubble over a game, its tail pointing down at the button */
.px-info { position: absolute; left: 50%; bottom: calc(100% + .9vw); width: max(220px, 17vw); padding: .9vw 1.1vw; box-sizing: border-box; transform: translateX(-50%); border-radius: 1vw; text-align: center;
  font-size: max(14px, 1.02vw); font-weight: 500; line-height: 1.35; color: var(--px-text); background: var(--px-bubble); border: 1px solid var(--c); box-shadow: 0 0 1.8vw -.5vw var(--c), 0 1.2vw 2.4vw -1vw #000;
  animation: px-info-in .32s var(--px-ease) both; }
.px-info[hidden] { display: none; }
.px-info::after { content: ""; position: absolute; left: 50%; bottom: -.42vw; width: .7vw; height: .7vw; margin-left: -.35vw; transform: rotate(45deg); background: var(--px-bubble); border: solid var(--c); border-width: 0 1px 1px 0; }
@keyframes px-info-in { from { opacity: 0; transform: translateX(-50%) translateY(.5vw) scale(.97); } }
.px-games svg { width: 1.7vw; height: 1.7vw; min-width: 20px; min-height: 20px; fill: none; stroke: var(--c); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 .3vw var(--c)); }
/* the button, and what it buys beside it */
.px-buyrow { margin-top: 3vw; display: flex; align-items: center; gap: 2.4vw; }
.px-perks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .5vw; font-size: max(13px, 1vw); font-weight: 500; color: var(--px-dim); }
.px-perks li { display: flex; align-items: center; gap: .6vw; }
.px-perks li::before { content: ""; width: .5vw; height: .9vw; min-width: 6px; min-height: 11px; margin: -.25vw .15vw 0 .1vw; border: solid var(--px-accent); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.px-test { margin-top: 1.6vw; font-size: max(12px, .82vw); color: var(--px-faint); }
.px-gate .px-buy { font-size: max(24px, 2.3vw); padding: 1.35vw 3.4vw; }
.px-gate:has(.px-buy.pressed) .px-pitch > :not(.px-buyrow), .px-gate:has(.px-buy.pressed) .px-perks, .px-gate:has(.px-buy.pressed) .px-pib-side,
.px-gate:has(.px-buy.pressed) .px-buy:not(.pressed) { opacity: 0; filter: blur(8px); transition: opacity .35s, filter .35s; }
/* the two ways to buy it, side by side: Buy Squib in gold, Buy Squib+ in pink, each with what's in it */
.px-gate .px-buy.px-ed { flex-direction: column; align-items: flex-start; gap: .55vw; padding: 1.15vw 2.2vw 1.2vw; border-radius: 1.6vw; font-size: max(20px, 1.85vw); text-align: left; }
.px-ed-top { display: flex; align-items: baseline; gap: .9vw; }
.px-ed-perks { display: flex; align-items: center; gap: .5vw .9vw; flex-wrap: wrap; font-size: max(12px, .86vw); font-weight: 600; letter-spacing: 0; opacity: .82; }
.px-ed-perks > span { display: inline-flex; align-items: center; gap: .3vw; }
.px-ed-perks > span + span::before { content: ""; width: .3vw; height: .3vw; min-width: 4px; min-height: 4px; margin-right: .6vw; border-radius: 50%; background: currentColor; opacity: .5; }
.px-ed-perks .fchip.tiny { font-size: 1.15em; }
.px-buy.px-buy-plus { --px-on-plus: #2c0718; color: var(--px-on-plus); background: linear-gradient(180deg, #ffe0ef, #ff5fa6);
  box-shadow: 0 0 0 1px rgba(255,255,255,.2) inset, 0 1.4vw 3.6vw -1vw rgba(255,79,154,.55), 0 0 5vw -1vw rgba(255,79,154,.5); }
.px-buy.px-buy-plus:hover { box-shadow: 0 0 0 1px rgba(255,255,255,.25) inset, 0 1.8vw 4.4vw -1vw rgba(255,79,154,.65), 0 0 7vw -1vw rgba(255,79,154,.6); }
.px-buy.px-buy-plus::after { animation-delay: 3.5s; }
.px-buy.px-buy-plus:focus-visible { outline-color: #ff8cc4; }
body.skin-sea .px-buy.px-buy-plus { background: linear-gradient(180deg, #ffe6f3, #ff8cc4); }

/* Pib, under a spotlight, bobbing along and making his pitch in a bubble */
.px-pib-side { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 70%; animation: px-in 1.2s .25s var(--px-ease) both; }
.px-pib { position: relative; z-index: 1; width: min(21vw, 46vh); transform-origin: 50% 100%; animation: px-pib-sway 4.8s ease-in-out infinite; }
.px-pib svg { display: block; width: 100%; height: auto; overflow: visible; transform-origin: 50% 100%; animation: px-pib-bob 2.4s ease-in-out infinite; }
.px-pib .shadow { display: none; }
.px-pib #sp-hat { transform-box: fill-box; transform-origin: 50% 100%; animation: px-pib-tip 9.6s ease-in-out infinite; }
.px-pib #sp-arm-r { transform-box: fill-box; transform-origin: 15% 15%; animation: px-pib-wave 4.8s ease-in-out infinite; }
.px-pib .pupil { transition: transform .45s cubic-bezier(.3,.7,.3,1); }
.px-pib .eye .lid { transform-box: fill-box; transform-origin: 50% 0; transform: scaleY(0); transition: transform .08s; }
.px-pib.blink .eye .lid { transform: scaleY(1); }
@keyframes px-pib-bob { 0%, 100% { transform: scale(1, 1) translateY(0); } 50% { transform: scale(1.03, .97) translateY(.3vw); } }
@keyframes px-pib-sway { 0%, 100% { transform: rotate(-2deg); } 50% { transform: rotate(2deg); } }
@keyframes px-pib-wave { 0%, 55%, 100% { transform: rotate(0); } 62% { transform: rotate(-38deg); } 68% { transform: rotate(-22deg); } 74% { transform: rotate(-38deg); } 82% { transform: rotate(0); } }
@keyframes px-pib-tip { 0%, 80%, 90%, 100% { transform: none; } 85% { transform: rotate(-12deg) translateY(-6px); } }
.px-pib-floor { position: absolute; bottom: -1.2vw; width: 26vw; height: 3.4vw; border-radius: 50%; background: radial-gradient(closest-side, rgba(255,226,170,.28), transparent); filter: blur(.4vw); }
.px-says { position: relative; z-index: 2; max-width: 24vw; min-height: 2.6em; margin-bottom: 1.6vw; padding: 1vw 1.4vw; border-radius: 1.4vw; box-sizing: border-box;
  font-size: max(14px, 1.2vw); font-weight: 600; line-height: 1.35; text-align: center; color: var(--px-text);
  background: var(--px-bubble); border: 1px solid var(--px-edge-hi); box-shadow: 0 1.4vw 3vw -1.4vw rgba(0,0,0,.8);
  opacity: 0; transform: translateY(.6vw) scale(.96); transition: opacity .35s, transform .5s var(--px-ease); }
.px-says.on { opacity: 1; transform: none; }
.px-says em { color: #ff8cc4; }
.px-says::after { content: ""; position: absolute; left: 50%; bottom: -.5vw; width: 1vw; height: 1vw; margin-left: -.5vw; background: var(--px-bubble); border: 1px solid var(--px-edge-hi); border-left-color: transparent; border-top-color: transparent; transform: rotate(45deg); }
.px-buy { position: relative; overflow: hidden; display: inline-flex; align-items: baseline; gap: 1vw; padding: 1.25vw 3.2vw; border: 0; border-radius: 999px; cursor: pointer; font: 600 max(22px, 2vw) "Quicksand", sans-serif; letter-spacing: -.02em; color: var(--px-on-primary); background: var(--px-primary);
  box-shadow: 0 0 0 1px rgba(255,255,255,.2) inset, 0 1.4vw 3.6vw -1vw var(--px-glow), 0 0 5vw -1vw var(--px-glow); transition: transform .6s var(--px-ease), box-shadow .6s var(--px-ease); }
.px-buy::after { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255,255,255,.65) 50%, transparent 65%); transform: translateX(-120%); animation: px-sheen 4.2s 1.4s ease-in-out infinite; }
.px-buy:hover { transform: scale(1.035); box-shadow: 0 0 0 1px rgba(255,255,255,.25) inset, 0 1.8vw 4.4vw -1vw var(--px-glow), 0 0 7vw -1vw var(--px-glow); }
.px-buy:active { transform: scale(.975); transition-duration: .15s; }
.px-buy.pressed { transform: scale(.94); opacity: 0; filter: blur(10px); transition: transform .5s var(--px-ease), opacity .4s, filter .4s; pointer-events: none; }
.px-buy-price { font-weight: 400; opacity: .72; }
.px-buy:focus-visible, .px-get:focus-visible, .px-seg-btn:focus-visible, .px-note button:focus-visible, #topbar .chip-pill:focus-visible, .nope-go:focus-visible, .nope-no:focus-visible, .pib-switch:focus-visible { outline: 2px solid var(--px-accent); outline-offset: 3px; }


/* ---- the show ---- */
.px-show { position: fixed; inset: 0; z-index: 55; overflow: hidden; background: #000; animation: px-fade .5s ease-out; cursor: default; }
.px-show.out { opacity: 0; transition: opacity .85s ease; pointer-events: none; }
.px-show-sky { position: absolute; inset: 0; width: 100%; height: 100%; }
.px-show-flash { position: absolute; inset: 0; background: radial-gradient(60% 60% at 50% 32%, #fff, rgba(255,214,140,.5) 45%, transparent 75%); opacity: 0; pointer-events: none; }
.px-show-flash.on { animation: px-flash 1.1s ease-out; }
.px-show-title { position: absolute; left: 0; right: 0; top: 40%; text-align: center; font-size: 8vw !important; line-height: 1.15; opacity: 0; }
.px-show-title.on { animation: px-title 1.5s var(--px-ease) both; }

/* ---- the store ---- */
.px-store { display: flex; flex-direction: column; align-items: center; width: 60vw; min-width: 680px; }
.px-store > *, .px-card { animation: px-in 1.1s calc(var(--i, 0) * 85ms) var(--px-ease) both; }

.px-seg { position: relative; display: inline-flex; padding: .25vw; border-radius: 999px; background: var(--px-seg); border: 1px solid var(--px-edge); backdrop-filter: blur(20px); }
.px-seg-thumb { position: absolute; top: .25vw; bottom: .25vw; left: 0; width: var(--w, 0); transform: translateX(var(--x, 0)); border-radius: 999px; background: var(--px-thumb); box-shadow: inset 0 1px 0 rgba(255,255,255,.14), 0 .3vw .8vw rgba(0,0,0,.4); transition: transform .55s var(--px-ease), width .55s var(--px-ease); }
.px-seg-btn { position: relative; min-height: 40px; padding: .45vw 1.7vw; border: 0; border-radius: 999px; background: none; cursor: pointer; font: 500 max(13px, .92vw) "Quicksand", sans-serif; letter-spacing: -.005em; color: var(--px-dim); transition: color .3s; }
.px-seg-btn:hover { color: var(--px-text); }
.px-seg-btn.on { color: var(--px-text); }

.px-line { margin: 1.3vw 0 0; font-size: max(30px, 3.3vw); font-weight: 600; line-height: 1.08; letter-spacing: -.035em; color: var(--px-text); }
.px-sub { margin: .4vw 0 1.1vw; min-height: 1.4em; font-size: max(14px, 1.02vw); letter-spacing: -.01em; color: var(--px-dim); }
.px-line:empty { display: none; } /* the shelves have no headline now: the tabs say what they are */
.px-line:empty + .px-sub { margin-top: 1.1vw; }

/* the shelf: two cards at a time, sliding. It's padded so a lifted card's glow isn't cut off */
.px-rail { position: relative; width: 100%; }
/* the side margin stays narrower than the gap between cards, so the window ends before the next card starts */
.px-stage { display: flex; gap: 1.1vw; margin: -1.2vw -.5vw; padding: 1.2vw .5vw; overflow: hidden; scrollbar-width: none; perspective: 90vw;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 .5vw, #000 calc(100% - .5vw), transparent 100%); mask-image: linear-gradient(90deg, transparent 0, #000 .5vw, #000 calc(100% - .5vw), transparent 100%); }
.px-stage::-webkit-scrollbar { display: none; }
.px-stage.few { overflow: visible; -webkit-mask-image: none; mask-image: none; }
/* the arrows: the main screen's gold ring (menu.css .sq-more), so they're easy to find */
.px-arrow { position: absolute; z-index: 4; top: 50%; width: 3vw; height: 3vw; min-width: 44px; min-height: 44px; margin-top: -1.5vw; padding: 0; border: 0; border-radius: 50%; cursor: pointer;
  color: var(--px-accent); background: rgba(10,7,12,.72); box-shadow: 0 0 0 2px currentColor, 0 0 1.8vw -.1vw currentColor; backdrop-filter: blur(20px); transition: opacity .4s, transform .5s var(--px-ease), background .3s, color .25s; }
.px-arrow svg { display: block; width: 50%; height: 50%; margin: auto; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.px-arrow.prev { left: -4.6vw; } .px-arrow.next { right: -4.6vw; }
.px-arrow:hover { color: #fff; background: rgba(40,28,34,.85); transform: scale(1.08); }
body.skin-sea .px-arrow { background: rgba(6,40,60,.72); }
body.skin-sea .px-arrow:hover { background: rgba(10,70,100,.85); }
.px-arrow:active { transform: scale(.94); }
.px-arrow:focus-visible { outline: 2px solid var(--px-accent); outline-offset: 3px; }
.px-arrow.off { opacity: 0; pointer-events: none; }
.px-card { position: relative; flex: 0 0 calc((100% - 1.1vw) / 2); min-width: 0; display: flex; flex-direction: column; overflow: hidden; border-radius: 1.5vw; background: var(--px-card); box-shadow: inset 0 0 0 1px var(--px-edge), inset 0 1px 0 var(--px-edge-hi), 0 1.6vw 3.4vw -1.4vw rgba(0,0,0,.9);
  transform: rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .7s var(--px-ease), box-shadow .5s var(--px-ease); will-change: transform; }
.px-card::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; background: radial-gradient(38% 55% at var(--mx, 50%) var(--my, 50%), var(--px-light), transparent 72%); transition: opacity .5s; }
.px-card.lit::after { opacity: 1; }
.px-card.lit { box-shadow: inset 0 0 0 1px var(--px-edge-hi), inset 0 1px 0 var(--px-edge-hi), 0 2.4vw 4.4vw -1.4vw rgba(0,0,0,.95); }
.px-card.got::before { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: linear-gradient(105deg, transparent 30%, rgba(255,255,255,.34) 50%, transparent 70%); animation: px-sweep 1.2s var(--px-ease) both; }
.px-card-art { position: relative; display: flex; align-items: center; justify-content: center; height: 13.5vw; overflow: hidden; background: var(--px-plate); }
.px-row { display: flex; align-items: flex-end; justify-content: center; gap: .3vw; transition: transform .9s var(--px-ease); }
.px-card.lit .px-row, .px-card.lit .px-sea { transform: scale(1.05); }
.px-card.got .px-row { animation: px-pop .9s var(--px-ease); }
.px-row svg { display: block; width: 100%; overflow: visible; filter: drop-shadow(0 .7vw .9vw rgba(0,0,0,.5)); }
.px-card.wide { flex-basis: 100%; }
/* a pack's five hats, in an arc */
.px-row.px-hats { gap: 0; }
.px-hats span { flex: none; width: 5.1vw; margin: 0 -.2vw; }
.px-hats span:nth-child(2), .px-hats span:nth-child(4) { margin-bottom: 1.3vw; }
.px-hats span:nth-child(3) { margin-bottom: 2vw; }
.px-guests span { width: 8.4vw; margin: 0 -.3vw; }
.px-sea { position: absolute; inset: 0; background: radial-gradient(70% 110% at 50% -10%, #6fd3ea 0%, #1b86ad 28%, #0b4d73 60%, #032338 100%); transition: transform 1.2s var(--px-ease); }
.px-sea i { position: absolute; bottom: -2vw; left: calc(9% + var(--b) * 16%); width: calc(.8vw + var(--b) * .13vw); height: calc(.8vw + var(--b) * .13vw); border-radius: 50%; border: 1px solid rgba(225,252,255,.7); background: radial-gradient(circle at 32% 30%, #fff 0 16%, rgba(160,240,255,.14) 46%); animation: px-bubble 9s calc(var(--b) * -1.6s) linear infinite; }
.px-card-foot { position: relative; z-index: 1; display: flex; align-items: center; justify-content: space-between; gap: 1vw; padding: 1.05vw 1.3vw 1.15vw; }
/* what you don't own yet waits in the half-dark, perfectly still */
.px-card-art > * { transition: filter .9s var(--px-ease), transform .9s var(--px-ease); }
.px-card:not(.have) .px-card-art > * { filter: saturate(.6) brightness(.74); }
.px-card:not(.have).lit .px-card-art > * { filter: saturate(.9) brightness(.95); }
.px-card:not(.have) .bob, .px-card:not(.have) .eyes { animation: none !important; }
.px-card:not(.have) .px-sea i { animation-play-state: paused; }
/* what you own comes alive: the lights come up, the guys bob and blink, the hats float, the bubbles
   rise, a gold rim runs round the card with a glint travelling along it, and there's a gold tick */
.px-card.have .px-card-art { background: radial-gradient(60% 80% at 50% 62%, var(--px-own-glow), transparent 74%); }
.px-card.have { box-shadow: inset 0 0 0 1px transparent, 0 1.6vw 3.4vw -1.4vw rgba(0,0,0,.9), 0 0 3vw -1.2vw var(--px-glow); }
.px-card.have.lit { box-shadow: inset 0 0 0 1px transparent, 0 2.4vw 4.4vw -1.4vw rgba(0,0,0,.95), 0 0 3.6vw -1vw var(--px-glow); }
.px-card.have .px-hats span { animation: px-float 3.6s ease-in-out infinite; }
.px-card.have .px-hats span:nth-child(2) { animation-delay: -1.2s; }
.px-card.have .px-hats span:nth-child(3) { animation-delay: -2.4s; }
.px-card.have .px-hats span:nth-child(4) { animation-delay: -.6s; }
.px-card.have .px-hats span:nth-child(5) { animation-delay: -1.8s; }
@property --px-spin { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.px-rim { position: absolute; inset: 0; z-index: 3; padding: 1.5px; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .9s var(--px-ease);
  background: conic-gradient(from var(--px-spin), var(--px-rim-lo) 0 72%, var(--px-rim-hi) 86%, #fff 90%, var(--px-rim-hi) 94%, var(--px-rim-lo) 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; animation: px-rim-spin 5.5s linear infinite; }
.px-card.have .px-rim { opacity: 1; }
.px-badge { position: absolute; z-index: 3; top: .85vw; right: .85vw; display: grid; place-items: center; width: 1.9vw; height: 1.9vw; min-width: 26px; min-height: 26px; border-radius: 50%; background: var(--px-primary); box-shadow: 0 .25vw .9vw -.1vw var(--px-glow), inset 0 1px 0 rgba(255,255,255,.55); opacity: 0; transform: scale(.4); transition: opacity .4s, transform .7s var(--px-ease); }
.px-badge svg { width: 62%; height: 62%; fill: none; stroke: var(--px-on-primary); stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.px-card.have .px-badge { opacity: 1; transform: none; }
.px-card.have .px-card-text h3 { color: var(--px-accent); transition: color .6s; }
/* the moment you buy it */
.px-card.got { animation: px-got .95s var(--px-ease); }
.px-card.got .px-badge { animation: px-stamp .75s cubic-bezier(.2,1.6,.35,1); }
.px-card.got .px-badge::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--px-accent); animation: px-ripple .9s var(--px-ease) both; }
.px-card.got .px-rim { animation: px-rim-spin .9s linear 2, px-rim-flash 1.4s ease-out; }
.px-mini-sky { position: fixed; inset: 0; z-index: 49; width: 100%; height: 100%; pointer-events: none; }
.px-card-text { min-width: 0; }
.px-card-text h3 { margin: 0; font-size: max(15px, 1.22vw); font-weight: 600; letter-spacing: -.02em; }
.px-card-text p { margin: .12vw 0 0; min-height: 2.5em; font-size: max(11px, .8vw); line-height: 1.25; letter-spacing: -.005em; color: var(--px-dim); }

/* the pill: a price, then a spinner, then a tick */
.px-get { position: relative; flex: none; display: inline-flex; align-items: center; justify-content: center; min-width: 5.4vw; min-height: 38px; padding: .42vw 1.1vw; border: 0; border-radius: 999px; cursor: pointer; font: 600 max(13px, .92vw) "Quicksand", sans-serif; font-variant-numeric: tabular-nums; letter-spacing: -.01em; color: var(--px-text); background: var(--px-pill); transition: background .3s, transform .5s var(--px-ease), color .3s, min-width .5s var(--px-ease), opacity .3s; }
.px-get:hover { background: var(--px-pill-hover); transform: scale(1.04); }
.px-get:active { transform: scale(.95); transition-duration: .12s; }
.px-get-label { display: inline-flex; align-items: center; gap: .32vw; transition: opacity .25s, transform .4s var(--px-ease); }
.px-get.primary { color: var(--px-on-primary); background: var(--px-primary); box-shadow: 0 .4vw 1.4vw -.5vw var(--px-glow); }
.px-get.primary:hover { background: var(--px-primary); filter: brightness(1.06); }
.px-get.short { color: var(--px-dim); }
.px-get.owned { color: var(--px-dim); background: none; cursor: default; }
.px-get.owned:hover { transform: none; background: none; }
.px-tick { position: absolute; left: 50%; top: 50%; width: 1.25em; height: 1.25em; margin: -.625em 0 0 -.625em; fill: none; stroke: #2a1a08; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 24; stroke-dashoffset: 24; pointer-events: none; }
.px-get.working { pointer-events: none; background: var(--px-pill); }
.px-get.working .px-get-label { opacity: 0; transform: scale(.8); }
.px-get.working::after { content: ""; position: absolute; left: 50%; top: 50%; width: 1.1em; height: 1.1em; margin: -.55em 0 0 -.55em; border-radius: 50%; border: 2px solid rgba(255,255,255,.2); border-top-color: var(--px-text); animation: px-spin .7s linear infinite; }
.px-get.done { pointer-events: none; background: var(--px-primary); }
.px-get.done .px-get-label { opacity: 0; transform: scale(.8); }
.px-get.done .px-tick { stroke-dashoffset: 0; stroke: var(--px-on-primary); transition: stroke-dashoffset .5s .05s var(--px-ease); }

/* hat cards turn over (shop.js flipCard): the back is one of your guys trying the pack's hats on */
.px-card-art[role="button"] { cursor: pointer; }
.px-card-art[role="button"]:focus-visible { outline: 2px solid var(--px-accent); outline-offset: -4px; }
.px-face { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.px-face[hidden] { display: none; }
.px-card .px-card-art > .px-back, .px-card:not(.have) .px-card-art > .px-back { filter: none; } /* trying on is always in full colour */
.px-back { gap: 1.2vw; background: radial-gradient(55% 75% at 50% 62%, var(--px-own-glow), transparent 74%); }
.px-model { width: 7.6vw; margin-bottom: 1.2vw; }
.px-model svg { display: block; width: 100%; overflow: visible; filter: drop-shadow(0 .7vw .9vw rgba(0,0,0,.5)); }
.px-try-arrow { flex: none; width: 2.4vw; height: 2.4vw; min-width: 36px; min-height: 36px; padding: 0; border: 0; border-radius: 50%; cursor: pointer;
  color: var(--px-accent); background: rgba(10,7,12,.72); box-shadow: 0 0 0 2px currentColor, 0 0 1.4vw -.2vw currentColor; transition: transform .4s var(--px-ease), color .25s; }
.px-try-arrow svg { display: block; width: 52%; height: 52%; margin: auto; fill: none; stroke: currentColor; stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }
.px-try-arrow:hover { color: #fff; transform: scale(1.08); }
.px-try-arrow:active { transform: scale(.94); }
.px-try-arrow:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.px-dots { position: absolute; left: 0; right: 0; bottom: .8vw; display: flex; justify-content: center; gap: .45vw; }
.px-dots i { width: .45vw; height: .45vw; min-width: 6px; min-height: 6px; border-radius: 50%; background: rgba(255,255,255,.25); transition: background .3s, transform .3s var(--px-ease); }
.px-dots i.on { background: var(--px-accent); transform: scale(1.3); }
.px-try-hint { position: absolute; left: 50%; bottom: .7vw; translate: -50% 0; z-index: 1; pointer-events: none; white-space: nowrap; font-size: max(11px, .74vw); font-weight: 600; letter-spacing: .04em;
  color: var(--px-accent); opacity: 0; transition: opacity .35s; }
.px-card.lit:not(.flipped) .px-try-hint, .px-card-art:focus-visible .px-try-hint { opacity: .9; }
.px-card.flipped .px-try-hint { display: none; }

/* the Chips tab: real money for chips, a pile on each card (pressing something you can't afford lands here) */
.px-cash .px-card-art > *, .px-card.px-cash:not(.have) .px-card-art > * { filter: none; }
.px-cash .px-card-art { background: radial-gradient(60% 80% at 50% 62%, var(--px-own-glow), transparent 74%); }
.px-cash.best .px-rim { opacity: 1; }
.px-pile { display: flex; flex-wrap: wrap-reverse; justify-content: center; align-content: center; width: calc(min(var(--n), 7) * 2.6vw + 1vw); transition: transform .9s var(--px-ease); }
.px-pile span { width: 3.2vw; height: 3.2vw; margin: -.35vw -.3vw; transform: rotate(calc(var(--k) * 23deg)) translateY(calc(var(--k) * -.04vw)); }
.px-pile .fchip { box-shadow: 0 .2vw .6vw rgba(0,0,0,.6); }
.px-card.lit .px-pile { transform: scale(1.05); }
.px-card.got .px-pile { animation: px-pop .9s var(--px-ease); }
.px-ribbon { position: absolute; z-index: 3; top: .85vw; left: .85vw; padding: .3vw .8vw; border-radius: 999px; font: normal 700 max(11px, .74vw) "Quicksand", sans-serif; letter-spacing: .06em; text-transform: uppercase;
  color: var(--px-on-primary); background: var(--px-primary); box-shadow: 0 .25vw .9vw -.1vw var(--px-glow); }
.px-cash .px-get { min-width: 6.4vw; font-size: max(15px, 1.1vw); }

.px-note { margin-top: 1vw; font-size: max(10px, .68vw); white-space: nowrap; color: var(--px-faint); }
.px-note button { padding: 4px 2px; border: 0; background: none; color: var(--px-dim); font: inherit; text-decoration: underline; cursor: pointer; }
.px-note button:hover { color: var(--px-text); }

/* ---- a chip seen from above ---- */
.fchip { display: block; flex: none; width: 100%; height: 100%; border-radius: 50%; box-sizing: border-box;
  background: radial-gradient(circle closest-side, var(--i) 0 54%, var(--s) 55% 58%, var(--t) 59% 76%, transparent 76.8%), repeating-conic-gradient(from 11deg, var(--s) 0 22deg, var(--t) 22deg 60deg);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.35), inset -.08em -.1em .25em rgba(0,0,0,.35), 0 .1vw .4vw rgba(0,0,0,.5); }
.fchip.tiny { width: 1em; height: 1em; }
.shop-fly { position: fixed; inset: 0; z-index: 48; pointer-events: none; overflow: hidden; }
.shop-fly .fchip { position: absolute; }

/* ---- the machine says no ---- */
.nope-back { position: fixed; inset: 0; z-index: 50; display: flex; align-items: center; justify-content: center; background: rgba(4,2,4,.66); backdrop-filter: blur(3px); animation: px-fade .16s ease-out; }
.nope-box { display: flex; flex-direction: column; align-items: center; width: min(92vw, 36vw); min-width: min(92vw, 420px); box-sizing: border-box; padding: 2vw 2.6vw 1.3vw; border-radius: 1.6vw; text-align: center; font-family: "Quicksand", sans-serif; color: #fff;
  background: linear-gradient(180deg, #2a1420, #120a12); border: 2px solid #ff8cc4; box-shadow: 0 0 0 1px rgba(0,0,0,.5), 0 0 5vw -.5vw rgba(255,79,154,.7), 0 2vw 6vw rgba(0,0,0,.8); animation: cg-nope .5s cubic-bezier(.2,1.5,.35,1); }
.nope-x { width: 4.2vw; height: 4.2vw; min-width: 48px; min-height: 48px; margin-bottom: .4vw; }
.nope-x svg { display: block; width: 100%; height: 100%; fill: none; stroke: #ff2a44; stroke-width: 8; stroke-linecap: round; filter: drop-shadow(0 0 .7vw #ff2a44); }
.nope-shout { font-size: max(38px, 4.2vw); font-weight: 900; line-height: 1.1; letter-spacing: -.01em; white-space: nowrap; }
.nope-shout span { display: inline-block; color: var(--c); text-shadow: 0 0 1.2vw var(--c), 0 .15vw 0 rgba(0,0,0,.4); animation: cg-letter .5s var(--d) cubic-bezier(.2,1.7,.4,1) both; }
.nope-line { margin: .7vw 0 1.2vw; font-size: max(15px, 1.14vw); line-height: 1.45; color: rgba(255,255,255,.82); }
.nope-line b { color: var(--c); font-weight: 800; text-shadow: 0 0 .7vw var(--c); }
.nope-go { width: 100%; min-height: 48px; padding: .75vw 1.6vw; border: 0; border-radius: 999px; cursor: pointer; font: 700 max(17px, 1.34vw) "Quicksand", sans-serif; color: var(--px-on-primary); background: var(--px-primary); box-shadow: 0 0 2.2vw -.3vw var(--px-glow); animation: cg-beckon 1.4s 1s ease-in-out infinite; }
.nope-no { min-height: 40px; margin-top: .35vw; padding: 0 1vw; border: 0; background: none; cursor: pointer; font: 600 max(13px, .86vw) "Quicksand", sans-serif; color: rgba(255,255,255,.55); }
.nope-no:hover { color: #fff; }

/* ---- Pib live, on the game floor ---- */
.pib-switch { display: inline-flex; align-items: center; gap: .55vw; min-height: 44px; padding: 0 1vw 0 .7vw; border-radius: 999px; cursor: pointer; font: 600 max(13px, .9vw) "Quicksand", sans-serif; color: rgba(255,255,255,.8);
  background: rgba(16,11,18,.75); border: 1px solid rgba(255,255,255,.2); transition: border-color .2s, box-shadow .2s, color .2s; }
.pib-switch:hover { border-color: rgba(255,217,138,.6); }
.pib-switch .fchip.tiny { font-size: max(13px, .95vw); }
.pib-switch b { font-variant-numeric: tabular-nums; color: #ffd98a; }
.pib-knob { position: relative; display: block; width: 2.1em; height: 1.2em; border-radius: 999px; background: rgba(255,255,255,.18); transition: background .2s; }
.pib-knob::after { content: ""; position: absolute; left: .15em; top: .15em; width: .9em; height: .9em; border-radius: 50%; background: #fff; transition: transform .2s cubic-bezier(.3,1.5,.5,1); }
.pib-switch.on { color: #fff; border-color: #ff8cc4; box-shadow: 0 0 1.6vw -.3vw rgba(255,79,154,.8); }
.pib-switch.on .pib-knob { background: #ff4f9a; }
.pib-switch.on .pib-knob::after { transform: translateX(.9em); }
.pib-switch.short { opacity: .65; }
.pib-switch.short.locked { opacity: 1; }
/* held on by the Custom tone: gold rather than pink, and it shakes its head if you try */
.pib-switch.locked { border-color: var(--px-accent); box-shadow: 0 0 1.6vw -.3vw var(--px-glow); cursor: default; }
.pib-switch.locked .pib-knob { background: var(--px-accent); }
.pib-switch.held { animation: ct-shake .42s var(--px-ease); }

.shop-toast { position: fixed; left: 50%; bottom: 4vh; z-index: 60; transform: translateX(-50%); max-width: 80vw; padding: .75vw 1.6vw; border-radius: 999px; font: 500 max(14px, .98vw) "Quicksand", sans-serif; letter-spacing: -.005em; color: var(--px-text); background: rgba(40,36,38,.86); backdrop-filter: blur(24px); box-shadow: inset 0 0 0 1px var(--px-edge-hi), 0 .8vw 2.6vw rgba(0,0,0,.6); animation: px-toast 3.2s var(--px-ease) both; pointer-events: none; }

/* Settings › World: a world you don't own yet */
.set-world label:has(input:disabled) { opacity: .5; cursor: default; }
.set-world label:has(input:disabled)::after { content: "In the store"; margin-left: auto; font-size: .8em; color: #ffd98a; }

@keyframes px-in { from { opacity: 0; transform: translateY(2.4vh) scale(.985); filter: blur(12px); } }
@keyframes px-fade { from { opacity: 0; } }
@keyframes px-sheen { 0%, 62% { transform: translateX(-120%); } 88%, 100% { transform: translateX(120%); } }
@keyframes px-flash { 0% { opacity: 0; } 12% { opacity: .95; } 100% { opacity: 0; } }
@keyframes px-title { 0% { opacity: 0; transform: scale(.9); filter: blur(22px); } 100% { opacity: 1; transform: none; filter: blur(0); } }
@keyframes px-sweep { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
@keyframes px-pop { 35% { transform: scale(1.14) translateY(-.5vw); } }
@keyframes px-float { 50% { transform: translateY(-.45vw); } }
@keyframes px-rim-spin { to { --px-spin: 360deg; } }
@keyframes px-rim-flash { 0% { filter: brightness(2.4); } 100% { filter: none; } }
@keyframes px-got { 22% { transform: scale(1.025) translateY(-.4vw); } }
@keyframes px-stamp { 0% { opacity: 0; transform: scale(2.6) rotate(-16deg); } 60% { opacity: 1; } 100% { opacity: 1; transform: none; } }
@keyframes px-ripple { from { opacity: .9; transform: scale(1); } to { opacity: 0; transform: scale(3); } }
@keyframes px-spin { to { transform: rotate(360deg); } }
@keyframes px-nudge { 30% { box-shadow: inset 0 0 0 1px var(--px-accent), 0 0 3vw -.4vw var(--px-glow); } }
@keyframes px-bubble { 0% { transform: translateY(0); opacity: 0; } 12% { opacity: .9; } 90% { opacity: .7; } 100% { transform: translateY(-16vw) translateX(.8vw); opacity: 0; } }
@keyframes px-toast { 0% { opacity: 0; transform: translate(-50%, 1.8vh) scale(.97); filter: blur(6px); } 12%, 88% { opacity: 1; transform: translate(-50%, 0); filter: blur(0); } 100% { opacity: 0; } }
@keyframes cg-shake { 20% { transform: translateX(-.5vw); } 40% { transform: translateX(.45vw); } 60% { transform: translateX(-.3vw); } 80% { transform: translateX(.15vw); } }
@keyframes cg-nope { from { opacity: 0; transform: scale(.6) rotate(-3deg); } }
@keyframes cg-letter { from { opacity: 0; transform: translateY(1.4vw) scale(.4) rotate(-14deg); } }
@keyframes cg-beckon { 50% { filter: brightness(1.14); transform: scale(1.025); } }

/* the Deep Sea */
body.skin-sea { --px-bg: radial-gradient(90% 70% at 50% 14%, #0f5a7f 0%, #05304f 52%, #021626 100%);
  --px-card: linear-gradient(180deg, rgba(20,86,116,.75), rgba(5,38,62,.85)); --px-edge: rgba(191,246,255,.14); --px-edge-hi: rgba(191,246,255,.26);
  --px-text: #f4feff; --px-dim: rgba(214,248,255,.66); --px-faint: rgba(214,248,255,.4);
  --px-accent: #9ff0ff; --px-glow: rgba(127,232,255,.5); --px-light: rgba(191,246,255,.14); --px-seg: rgba(191,246,255,.08); --px-thumb: rgba(191,246,255,.2);
  --px-primary: linear-gradient(180deg, #ffffff, #8fe9f5); --px-on-primary: #053049; --px-pill: rgba(191,246,255,.13); --px-pill-hover: rgba(191,246,255,.22);
  --px-plate: radial-gradient(60% 75% at 50% 60%, rgba(191,246,255,.2), transparent 72%); --px-bubble: #0b3a58;
  --px-own-glow: rgba(127,232,255,.36); --px-rim-lo: rgba(127,232,255,.55); --px-rim-hi: #d9fbff; }
body.skin-sea #hub-view-store, body.skin-sea .px-buy, body.skin-sea .px-seg-btn, body.skin-sea .px-get, body.skin-sea .pib-switch { font-family: var(--sea-round), "Quicksand", sans-serif; }
body.skin-sea .pib-switch b { color: var(--sea-aqua); }

@media (prefers-reduced-motion: reduce) {
  .px-rim, .px-card.got, .px-card.got .px-rim, .px-card.got .px-badge, .px-card.got .px-badge::after, .px-card.have .px-hats span,
  .px-gate, .px-pitch > *, .px-games li, .px-info, .px-pib, .px-pib svg, .px-pib #sp-hat, .px-pib #sp-arm-r, .px-hosted, .px-store > *, .px-card, .px-buy::after, .px-sea i, .chip-pill:not(.hidden), #topbar .chip-pill.glow, .nope-go, .nope-box, .nope-shout span, .px-card.got::before, .px-card.got .px-row { animation: none; }
  .px-card { transform: none; }
}

/* Game skins: try a world on in the store (shop.js, Skins.preview) */
.px-preview { flex: none; margin-left: auto; min-height: 38px; padding: .42vw 1.1vw; border-radius: 999px; cursor: pointer; font: 700 max(13px, .92vw) "Quicksand", sans-serif;
  color: var(--px-accent); background: none; border: 1.5px solid color-mix(in srgb, var(--px-accent) 60%, transparent); transition: background .25s, color .25s, transform .4s var(--px-ease); }
.px-preview:hover { background: color-mix(in srgb, var(--px-accent) 14%, transparent); transform: scale(1.04); }
.px-preview.on { color: var(--px-on-primary); background: var(--px-primary); border-color: transparent; }
.px-preview:focus-visible { outline: 2px solid var(--px-accent); outline-offset: 3px; }
.px-preview[hidden] { display: none; }
