/* Beach Party — 5×4 Stacked Wilds */
@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@600;700&family=Teko:wght@600;700&display=swap');

.game-shell.bp-mode {
  max-width: 480px;
  margin: 0 auto;
  background: #0c4a6e;
}
.game-shell.bp-mode .game-top {
  display: none;
}
.game-shell.bp-mode .game-stage {
  padding: 0;
  max-width: 100%;
  width: 100%;
  min-height: 100dvh;
  display: block;
}

.bp-screen {
  position: relative;
  min-height: 100dvh;
  color: #fff;
  font-family: Teko, 'Trebuchet MS', sans-serif;
  overflow: hidden;
}
.bp-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}
.bp-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(12, 74, 110, 0.15) 0%, rgba(12, 74, 110, 0.05) 45%, rgba(15, 23, 42, 0.72) 100%);
}
.bp-ui {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding: max(6px, env(safe-area-inset-top)) 8px max(8px, env(safe-area-inset-bottom));
  box-sizing: border-box;
  gap: 4px;
}

.bp-top {
  display: grid;
  grid-template-columns: 40px 1fr 40px;
  align-items: center;
  gap: 6px;
}
.bp-ico {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  padding: 0;
  background: transparent;
  cursor: pointer;
}
.bp-ico img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: transparent !important;
}
.bp-logo {
  width: min(240px, 68vw);
  height: auto;
  margin: 0 auto;
  display: block;
  object-fit: contain;
  background: transparent !important;
  filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.35));
}

.bp-piggy {
  position: absolute;
  right: 10px;
  top: 56px;
  z-index: 5;
  border: none;
  background: transparent;
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 54px;
  text-shadow: 0 1px 3px #000;
}
.bp-piggy img {
  width: 46px;
  height: 46px;
  object-fit: contain;
  background: transparent !important;
}

.bp-banner {
  align-self: center;
  margin-top: 2px;
  padding: 6px 18px;
  border-radius: 999px 999px 40% 40%;
  background: linear-gradient(180deg, #7dd3fc, #38bdf8);
  color: #0c4a6e;
  font-family: Fredoka, sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  max-width: 92%;
}

.bp-mults {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 4px 0;
}
.bp-mult {
  width: 36px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50% 50% 45% 45%;
  background: rgba(255, 255, 255, 0.35);
  border: 2px solid rgba(255, 255, 255, 0.7);
  color: #0c4a6e;
  font-family: Fredoka, sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
}
.bp-mult.on {
  background: linear-gradient(180deg, #fde68a, #fbbf24);
  border-color: #fff;
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.8);
  transform: scale(1.08);
}

.bp-reels {
  position: relative;
  display: grid;
  grid-template-columns: repeat(var(--cols, 5), minmax(0, 1fr));
  gap: 3px;
  margin: 2px auto 0;
  width: min(100%, 420px);
  padding: 6px;
  border-radius: 12px;
  background: rgba(224, 242, 254, 0.55);
  border: 2px solid rgba(255, 255, 255, 0.65);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  flex: 1 1 auto;
  min-height: 220px;
  max-height: 42vh;
}
.bp-reel {
  display: grid;
  grid-template-rows: repeat(var(--rows, 4), minmax(0, 1fr));
  gap: 3px;
  min-height: 0;
}
.bp-reel.bp-stacked {
  grid-template-rows: 1fr;
}
.bp-cell {
  position: relative;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.45);
  overflow: hidden;
  min-height: 0;
}
.bp-cell img {
  width: 88%;
  height: 88%;
  object-fit: contain;
  background: transparent !important;
}
.bp-wild-tall img {
  width: 92%;
  height: 92%;
  object-fit: contain;
}
.bp-cell i {
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  font-style: normal;
  font-size: 0.55rem;
  font-weight: 900;
  color: #fbbf24;
  text-shadow: 0 1px 2px #000;
  pointer-events: none;
}
.bp-cell i.sc {
  color: #f97316;
}
.bp-wild-tall em {
  position: absolute;
  top: 6px;
  right: 6px;
  font-style: normal;
  font-family: Fredoka, sans-serif;
  font-size: 0.9rem;
  color: #fff;
  background: #0ea5e9;
  border-radius: 8px;
  padding: 1px 6px;
  text-shadow: none;
}
.bp-cell.is-hit {
  outline: 2px solid #fbbf24;
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.7);
}
.bp-reels.is-spinning .bp-reel {
  animation: bp-blur 0.16s linear infinite;
  animation-delay: calc(var(--d, 0) * 35ms);
}
@keyframes bp-blur {
  0% {
    filter: brightness(1.1);
  }
  50% {
    filter: brightness(0.85) blur(0.4px);
  }
  100% {
    filter: brightness(1.1);
  }
}
.bp-lines {
  position: absolute;
  inset: 6px;
  width: calc(100% - 12px);
  height: calc(100% - 12px);
  pointer-events: none;
  z-index: 4;
}
.bp-mult-toast {
  text-align: center;
  font-family: Fredoka, sans-serif;
  font-size: 1.6rem;
  color: #fbbf24;
  text-shadow: 0 2px 0 #0c4a6e;
  animation: bp-pop 0.4s ease;
}

.bp-foot {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.bp-stats {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  gap: 6px;
  align-items: center;
}
.bp-bal,
.bp-bet,
.bp-won {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  background: rgba(15, 23, 42, 0.7);
  border-radius: 10px;
  padding: 6px 8px;
  font-size: 0.95rem;
}
.bp-bal img,
.bp-bet img {
  width: 18px;
  height: 18px;
  background: transparent !important;
}
.bp-won {
  color: #fde68a;
}
.bp-plus {
  width: 22px;
  height: 22px;
  border: none;
  border-radius: 50%;
  background: #fbbf24;
  color: #0c4a6e;
  font-weight: 900;
  cursor: pointer;
}
.bp-controls {
  display: grid;
  grid-template-columns: auto auto 1fr auto auto;
  gap: 6px;
  align-items: center;
}
.bp-fast,
.bp-auto,
.bp-round {
  border: none;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  background: #fbbf24;
  color: #0c4a6e;
  font-weight: 800;
  font-size: 0.7rem;
  cursor: pointer;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
}
.bp-fast.on,
.bp-auto.on {
  outline: 2px solid #fff;
  background: #f472b6;
  color: #fff;
}
.bp-round {
  font-size: 1.3rem;
  background: #e2e8f0;
}
.bp-spin {
  position: relative;
  border: none;
  background: transparent;
  padding: 0;
  cursor: pointer;
  justify-self: center;
  width: 84px;
  height: 84px;
}
.bp-spin img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: transparent !important;
  filter: drop-shadow(0 4px 12px rgba(56, 189, 248, 0.55));
}
.bp-spin span {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: Fredoka, sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #0c4a6e;
  text-shadow: 0 1px 0 #fff;
  pointer-events: none;
}
.bp-spin.stop span {
  color: #7f1d1d;
}
.bp-fs {
  text-align: center;
  font-style: normal;
  color: #7dd3fc;
  font-size: 1rem;
}
.bp-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: #cbd5e1;
  padding: 0 2px;
}
.bp-ping {
  color: #4ade80;
}

.bp-modal {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: center;
  background: rgba(12, 74, 110, 0.72);
  padding: 16px;
}
.bp-card {
  width: min(92vw, 360px);
  max-height: 80vh;
  overflow: auto;
  background: linear-gradient(180deg, #e0f2fe, #bae6fd);
  border: 3px solid #38bdf8;
  border-radius: 18px;
  padding: 14px;
  color: #0c4a6e;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.4);
}
.bp-card-h {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}
.bp-card-h h3 {
  margin: 0;
  font-family: Fredoka, sans-serif;
  color: #0369a1;
}
.bp-card-h button {
  border: none;
  background: #0ea5e9;
  color: #fff;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  cursor: pointer;
  font-weight: 900;
}
.bp-rules p {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 8px;
  align-items: start;
  font-size: 0.95rem;
  margin: 0 0 10px;
}
.bp-rules img,
.bp-rule-num {
  width: 44px;
  height: 44px;
  object-fit: contain;
  background: transparent !important;
}
.bp-rule-num {
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(180deg, #fde68a, #fbbf24);
  color: #0c4a6e;
  font-family: Fredoka, sans-serif;
  font-size: 0.75rem;
}
.bp-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 10px;
  font-weight: 700;
}
.bp-field select {
  padding: 8px;
  border-radius: 10px;
  border: 2px solid #38bdf8;
  background: #fff;
  color: #0c4a6e;
  font-size: 1rem;
}
.bp-apply {
  width: 100%;
  border: none;
  border-radius: 12px;
  padding: 10px;
  background: linear-gradient(180deg, #38bdf8, #0284c7);
  color: #fff;
  font-weight: 900;
  font-size: 1.1rem;
  cursor: pointer;
}
.bp-bigwin {
  background: rgba(12, 74, 110, 0.85);
}
.bp-bigwin-inner {
  text-align: center;
  color: #fff;
}
.bp-bigwin-txt {
  font-family: Fredoka, sans-serif;
  font-size: clamp(2.2rem, 12vw, 3.2rem);
  color: #fbbf24;
  text-shadow: 0 0 20px rgba(56, 189, 248, 0.8);
  animation: bp-pop 0.45s ease;
}
.bp-bigwin-inner b {
  display: block;
  margin-top: 10px;
  font-size: 2rem;
  color: #fff;
}
.bp-bigwin-inner small {
  display: block;
  margin-top: 6px;
  font-size: 1.4rem;
  color: #7dd3fc;
}
@keyframes bp-pop {
  from {
    transform: scale(0.5);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}
.bp-extra-cat {
  display: block;
  width: 120px;
  margin: 0 auto 10px;
  background: transparent !important;
}

@media (max-height: 700px) {
  .bp-reels {
    max-height: 36vh;
  }
  .bp-logo {
    width: min(180px, 55vw);
  }
  .bp-spin {
    width: 72px;
    height: 72px;
  }
}

