/* ============================================================
   BINGO — casino 75-ball bingo. Dark felt + neon gold/green,
   an animated bolillero (ball machine), daubed cartones and a
   confetti winner screen. Self-contained; layers on styles.css.
   ============================================================ */
:root {
  --bng-green: #22c55e;
  --bng-gold: #f5b942;
  --bng-felt: #0b2418;
  --bng-ink: #e9eef7;
}

#bng-lobby, #bng-room { color: var(--bng-ink); }

/* ── Buttons ── */
.bng-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 11px 18px; border-radius: 13px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04); color: var(--bng-ink); font-weight: 800;
  font-size: 0.92rem; cursor: pointer; line-height: 1;
  transition: transform .15s ease, box-shadow .18s ease, background .18s ease, opacity .15s ease;
}
.bng-btn:hover { transform: translateY(-1px); }
.bng-btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }
.bng-btn-sm { padding: 8px 13px; font-size: 0.82rem; border-radius: 11px; }
.bng-btn-block { width: 100%; }
.bng-btn-primary {
  background: linear-gradient(135deg, #22c55e, #0ea5a0); border-color: transparent; color: #04130c;
  box-shadow: 0 10px 24px rgba(34,197,94,0.28);
}
.bng-btn-primary:hover:not(:disabled) { box-shadow: 0 16px 30px rgba(34,197,94,0.4); }
.bng-btn-gold {
  background: linear-gradient(135deg, #ffd86b, #f5a623); border-color: transparent; color: #2a1a00;
  box-shadow: 0 10px 24px rgba(245,166,35,0.3);
}
.bng-btn-gold:hover:not(:disabled) { box-shadow: 0 16px 32px rgba(245,166,35,0.45); }
.bng-btn-ghost { background: rgba(255,255,255,0.05); }

/* ── Lobby ── */
.bng-topbar-actions { margin-left: auto; }
.bng-content { max-width: 1100px; margin: 0 auto; padding: 22px 18px 60px; }
.bng-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 20px;
  padding: 26px; border-radius: 24px; margin-bottom: 26px;
  background:
    radial-gradient(120% 120% at 90% 0%, rgba(245,185,66,0.16), transparent 55%),
    radial-gradient(120% 120% at 0% 100%, rgba(34,197,94,0.18), transparent 50%),
    linear-gradient(160deg, #14241c, #0c1118);
  border: 1px solid rgba(245,185,66,0.18);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}
.bng-head-badge {
  display: inline-block; padding: 5px 12px; border-radius: 999px; font-size: 0.72rem; font-weight: 800;
  letter-spacing: 0.04em; color: var(--bng-gold); background: rgba(245,185,66,0.12);
  border: 1px solid rgba(245,185,66,0.3); margin-bottom: 12px;
}
.bng-head h1 { font-size: 2.3rem; margin: 0 0 8px; letter-spacing: -0.01em;
  background: linear-gradient(120deg, #fff, #ffe6a8); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.bng-head p { margin: 0; color: var(--text-secondary); max-width: 640px; line-height: 1.5; font-size: 0.95rem; }
.bng-head .bng-create { flex-shrink: 0; }

.bng-rooms-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 14px; flex-wrap: wrap; }
.bng-section-title { font-size: 1.05rem; font-weight: 800; margin: 0; }
.bng-count { color: var(--text-muted); font-weight: 700; }
.bng-search { position: relative; }
.bng-search-ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px;
  fill: none; stroke: var(--text-muted); stroke-width: 2; }
.bng-search input { padding: 10px 14px 10px 36px; border-radius: 12px; border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04); color: var(--bng-ink); font-size: 0.88rem; width: 230px; max-width: 60vw; }

.bng-rooms { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.bng-empty { grid-column: 1/-1; text-align: center; padding: 56px 20px; color: var(--text-muted);
  border: 1px dashed rgba(255,255,255,0.12); border-radius: 18px; }
.bng-empty-ic { display: block; font-size: 2.4rem; margin-bottom: 10px; }
.bng-room-card {
  text-align: left; cursor: pointer; padding: 16px; border-radius: 18px; color: var(--bng-ink);
  background: linear-gradient(165deg, rgba(255,255,255,0.05), rgba(255,255,255,0.02));
  border: 1px solid rgba(255,255,255,0.08); border-left: 4px solid var(--rc, #22c55e);
  transition: transform .16s ease, box-shadow .18s ease, border-color .18s ease;
}
.bng-room-card:hover { transform: translateY(-3px); box-shadow: 0 16px 30px rgba(0,0,0,0.35); border-color: var(--rc); }
.bng-rc-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.bng-rc-emoji { font-size: 1.7rem; }
.bng-rc-badge { font-size: 0.68rem; font-weight: 800; padding: 4px 9px; border-radius: 999px;
  background: rgba(255,255,255,0.08); color: var(--text-secondary); }
.bng-rc-badge.live { background: rgba(239,68,68,0.18); color: #ff8a8a; animation: bngPulse 1.4s infinite; }
@keyframes bngPulse { 0%,100% { opacity: 1; } 50% { opacity: .5; } }
.bng-rc-name { font-weight: 800; font-size: 1.02rem; margin-bottom: 8px; }
.bng-rc-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; color: var(--text-muted); font-size: 0.78rem; font-weight: 600; }
.bng-rc-pot { margin-top: 10px; padding-top: 10px; border-top: 1px solid rgba(255,255,255,0.07); font-size: 0.82rem; color: var(--bng-gold); }
.bng-rc-pot strong { font-size: 1.05rem; }

/* ── Room top ── */
.bng-room-top { display: flex; align-items: center; gap: 12px; padding: 14px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.07); background: linear-gradient(180deg, #0e1620, #0b0f16); position: sticky; top: 0; z-index: 20; }
.bng-room-back { background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); color: var(--bng-ink);
  padding: 9px 14px; border-radius: 11px; font-weight: 800; cursor: pointer; }
.bng-room-back:hover { background: rgba(255,255,255,0.12); }
.bng-room-title { display: flex; align-items: center; gap: 10px; min-width: 0; }
.bng-room-emoji { font-size: 1.6rem; }
.bng-room-name { font-weight: 800; font-size: 1.02rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 40vw; }
.bng-room-meta { font-size: 0.76rem; color: var(--text-muted); }
.bng-room-pot { margin-left: auto; display: flex; align-items: center; gap: 6px; font-weight: 900; color: var(--bng-gold);
  padding: 8px 14px; border-radius: 999px; background: rgba(245,185,66,0.1); border: 1px solid rgba(245,185,66,0.3); }
.bng-pot-ic { filter: drop-shadow(0 0 6px rgba(245,185,66,0.6)); }
.bng-pillbtn { background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); color: var(--bng-ink);
  width: 40px; height: 40px; border-radius: 11px; cursor: pointer; font-size: 1rem; }
.bng-pillbtn:hover { background: rgba(255,255,255,0.12); }

.bng-stage { padding: 18px; max-width: 1140px; margin: 0 auto; }

/* ════════ BUYING / WAITING ════════ */
.bng-buy-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 18px; }
.bng-buy-card { padding: 20px; border-radius: 22px; border: 1px solid rgba(34,197,94,0.22);
  background: radial-gradient(120% 90% at 100% 0%, rgba(34,197,94,0.1), transparent 60%), linear-gradient(160deg, #122019, #0c1016); }
.bng-buy-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.bng-buy-title { font-size: 1.15rem; font-weight: 800; }
.bng-buy-mode { font-size: 0.74rem; font-weight: 800; padding: 5px 11px; border-radius: 999px; color: var(--bng-green);
  background: rgba(34,197,94,0.14); border: 1px solid rgba(34,197,94,0.3); }
.bng-price-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 12px; }
.bng-price-tag { display: flex; align-items: baseline; gap: 6px; }
.bng-price-ic { font-size: 1.1rem; align-self: center; }
.bng-price-tag strong { font-size: 1.6rem; color: var(--bng-gold); }
.bng-price-lbl { font-size: 0.78rem; color: var(--text-muted); }
.bng-stepper { display: flex; align-items: center; gap: 4px; margin-left: auto; background: rgba(0,0,0,0.3);
  border: 1px solid rgba(255,255,255,0.1); border-radius: 12px; padding: 4px; }
.bng-step-btn { width: 34px; height: 34px; border-radius: 9px; border: none; background: rgba(255,255,255,0.08);
  color: var(--bng-ink); font-size: 1.3rem; font-weight: 800; cursor: pointer; line-height: 1; }
.bng-step-btn:hover { background: rgba(34,197,94,0.3); }
.bng-qty { min-width: 28px; text-align: center; font-size: 1.15rem; font-weight: 900; }
.bng-buy-btn { white-space: nowrap; }
.bng-buy-note { font-size: 0.82rem; color: var(--text-secondary); margin-bottom: 8px; }
.bng-buy-card.is-spectator .bng-price-row, .bng-buy-card.is-spectator .bng-stepper { opacity: .4; pointer-events: none; }

.bng-my-cartons, .bng-cartons-mine, .bng-cartons-others { display: flex; flex-wrap: wrap; gap: 14px; }
.bng-my-cartons { margin-top: 14px; }
.bng-no-cartons { color: var(--text-muted); font-size: 0.88rem; padding: 18px 4px; }

.bng-lobby-side { display: flex; flex-direction: column; gap: 14px; }
.bng-players-card { padding: 16px; border-radius: 20px; border: 1px solid rgba(255,255,255,0.08); background: rgba(255,255,255,0.03); }
.bng-players-head { font-weight: 800; margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.bng-players-count { font-size: 0.74rem; background: rgba(34,197,94,0.16); color: var(--bng-green); padding: 2px 9px; border-radius: 999px; }
.bng-players { display: flex; flex-direction: column; gap: 8px; max-height: 360px; overflow-y: auto; }
.bng-players-empty { color: var(--text-muted); font-size: 0.84rem; }
.bng-player { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 13px;
  background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.05); }
.bng-player.me { border-color: rgba(34,197,94,0.4); background: rgba(34,197,94,0.08); }
.bng-player-info { min-width: 0; flex: 1; }
.bng-player-name { font-weight: 700; font-size: 0.9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bng-host-tag { color: var(--bng-gold); }
.bng-player-sub { font-size: 0.74rem; color: var(--text-muted); }
.bng-player-cnt { font-size: 0.78rem; font-weight: 800; color: var(--bng-gold); }

.bng-host-controls { display: flex; flex-direction: column; gap: 8px; }
.bng-host-hint { font-size: 0.78rem; color: var(--text-muted); text-align: center; }
.bng-host-wait { display: flex; align-items: center; gap: 10px; padding: 14px; border-radius: 16px; font-size: 0.88rem;
  color: var(--text-secondary); background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.07); }
.bng-spin { width: 18px; height: 18px; border-radius: 50%; border: 2px solid rgba(34,197,94,0.25); border-top-color: var(--bng-green);
  animation: bngSpin 0.8s linear infinite; flex-shrink: 0; }
@keyframes bngSpin { to { transform: rotate(360deg); } }

/* ── Avatars ── */
.bng-avatar { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px;
  border-radius: 50%; color: #fff; font-weight: 800; font-size: 0.82rem; flex-shrink: 0; overflow: hidden; }
.bng-avatar img { width: 100%; height: 100%; object-fit: cover; }
.bng-avatar.sm { width: 22px; height: 22px; font-size: 0.68rem; }
.bng-avatar.lg { width: 54px; height: 54px; font-size: 1.4rem; box-shadow: 0 0 0 3px rgba(245,185,66,0.4); }

/* ════════ CARTON ════════ */
.bng-carton { padding: 10px; border-radius: 16px; background: linear-gradient(160deg, #182a36, #0d141c);
  border: 1px solid rgba(255,255,255,0.1); box-shadow: 0 10px 22px rgba(0,0,0,0.3); }
.bng-carton.mine { border-color: rgba(34,197,94,0.45); box-shadow: 0 0 0 1px rgba(34,197,94,0.2), 0 12px 26px rgba(0,0,0,0.35); }
.bng-carton.winner { border-color: var(--bng-gold); box-shadow: 0 0 28px rgba(245,185,66,0.4); animation: bngWinPulse 1.1s ease infinite; }
@keyframes bngWinPulse { 0%,100% { box-shadow: 0 0 22px rgba(245,185,66,0.35); } 50% { box-shadow: 0 0 40px rgba(245,185,66,0.6); } }
.bng-carton-owner { display: flex; align-items: center; gap: 6px; margin-bottom: 7px; font-size: 0.78rem; font-weight: 700; color: var(--text-secondary); }
.bng-carton-head, .bng-carton-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
.bng-carton-head { margin-bottom: 5px; }
.bng-ch { display: flex; align-items: center; justify-content: center; height: 26px; border-radius: 8px; color: #fff;
  font-weight: 900; font-size: 0.95rem; letter-spacing: 0.02em; }
.bng-cell { position: relative; display: flex; align-items: center; justify-content: center;
  aspect-ratio: 1/1; border-radius: 9px; font-weight: 800; font-size: 0.98rem;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.07); color: #cdd6e4;
  transition: background .2s ease, color .2s ease, transform .2s ease; }
.bng-cell.free { color: var(--bng-gold); background: rgba(245,185,66,0.14); border-color: rgba(245,185,66,0.3); font-size: 1.1rem; }
.bng-cell.marked { color: #04130c; background: linear-gradient(145deg, #34d36a, #16a34a); border-color: transparent;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.2); }
.bng-cell.marked::after { content: ""; position: absolute; inset: 3px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.45); pointer-events: none; }
.bng-cell.free.marked { color: var(--bng-gold); background: rgba(245,185,66,0.2); }
.bng-cell.free.marked::after { border-color: rgba(245,185,66,0.5); }
.bng-cell.just { animation: bngDaub .55s cubic-bezier(.34,1.56,.6,1); z-index: 2; }
@keyframes bngDaub { 0% { transform: scale(0.5); } 55% { transform: scale(1.25); } 100% { transform: scale(1); } }
.bng-cell.win { background: linear-gradient(145deg, #ffd86b, #f5a623); color: #2a1a00; border-color: #fff;
  box-shadow: 0 0 14px rgba(245,185,66,0.7); }
.bng-cell.win::after { border-color: rgba(255,255,255,0.7); }

/* sizes: lobby/mine bigger, others compact */
.bng-my-cartons .bng-carton, .bng-cartons-mine .bng-carton, .bng-ended-carton .bng-carton { width: 230px; }
.bng-cartons-others .bng-carton { width: 152px; }
.bng-cartons-others .bng-cell { font-size: 0.74rem; border-radius: 7px; }
.bng-cartons-others .bng-ch { height: 18px; font-size: 0.74rem; }

/* ════════ DRAWING ════════ */
.bng-play-top { display: grid; grid-template-columns: 280px 1fr; gap: 20px; margin-bottom: 22px; }
.bng-machine { display: flex; flex-direction: column; align-items: center; gap: 0; }
.bng-machine-glass { position: relative; width: 230px; height: 230px; border-radius: 50%;
  background: radial-gradient(circle at 35% 28%, rgba(255,255,255,0.16), rgba(255,255,255,0.02) 60%), radial-gradient(circle at 50% 50%, #16324a, #0a1622);
  border: 6px solid rgba(255,255,255,0.08); box-shadow: inset 0 0 40px rgba(0,0,0,0.5), 0 18px 40px rgba(0,0,0,0.5);
  overflow: hidden; display: flex; align-items: center; justify-content: center; }
.bng-machine-glass::before { content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: linear-gradient(135deg, rgba(255,255,255,0.18), transparent 45%); pointer-events: none; }
.bng-machine-balls { position: absolute; inset: 0; }
.bng-mini-ball { position: absolute; width: 17px; height: 17px; border-radius: 50%;
  box-shadow: inset -2px -2px 3px rgba(0,0,0,0.4), inset 2px 2px 3px rgba(255,255,255,0.5);
  animation: bngFloat 2.4s ease-in-out infinite; }
@keyframes bngFloat { 0%,100% { transform: translate(0,0); } 25% { transform: translate(7px,-9px); }
  50% { transform: translate(-6px,6px); } 75% { transform: translate(5px,8px); } }
.bng-current-ball { position: relative; z-index: 3; width: 116px; height: 116px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0;
  background: radial-gradient(circle at 34% 28%, #fff, var(--ball-color, #7c5cff) 78%);
  box-shadow: inset -6px -6px 12px rgba(0,0,0,0.35), inset 5px 5px 10px rgba(255,255,255,0.6), 0 8px 20px rgba(0,0,0,0.45);
  color: #14202c; }
.bng-current-ball.pop { animation: bngBallPop .6s cubic-bezier(.2,1.5,.4,1); }
@keyframes bngBallPop { 0% { transform: scale(0.2) translateY(40px) rotate(-30deg); opacity: 0; }
  60% { transform: scale(1.15) translateY(0) rotate(6deg); opacity: 1; } 100% { transform: scale(1) rotate(0); } }
.bng-cb-letter { font-size: 1.05rem; font-weight: 900; letter-spacing: 0.08em; opacity: 0.85; line-height: 1; }
.bng-cb-num { font-size: 2.5rem; font-weight: 900; line-height: 1; }
.bng-machine-base { margin-top: 14px; text-align: center; }
.bng-draw-count { font-weight: 900; font-size: 1.05rem; }
.bng-draw-next { font-size: 0.78rem; color: var(--text-muted); margin-top: 3px; min-height: 1em; }

.bng-recent { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.bng-recent-label { font-size: 0.74rem; font-weight: 800; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.08em; }
.bng-recent-list { display: flex; gap: 8px; flex-wrap: wrap; min-height: 38px; }
.bng-recent-chip { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 38px;
  padding: 0 8px; border-radius: 11px; color: #fff; font-weight: 900; font-size: 0.86rem;
  box-shadow: inset -2px -2px 4px rgba(0,0,0,0.3), inset 2px 2px 4px rgba(255,255,255,0.3);
  animation: bngChipIn .4s ease; }
.bng-recent-chip:first-child { outline: 2px solid rgba(255,255,255,0.5); transform: scale(1.06); }
@keyframes bngChipIn { from { transform: scale(0.4); opacity: 0; } }

.bng-board { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 4px; }
.bng-board-col { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.bng-board-letter { font-weight: 900; font-size: 1rem; margin-bottom: 3px; }
.bng-board-cell { width: 100%; display: flex; align-items: center; justify-content: center; height: 22px; border-radius: 6px;
  font-size: 0.68rem; font-weight: 700; color: var(--text-muted); background: rgba(255,255,255,0.035);
  border: 1px solid rgba(255,255,255,0.05); transition: all .25s ease; }
.bng-board-cell.on { color: #04130c; background: linear-gradient(145deg, #34d36a, #16a34a); border-color: transparent; font-weight: 900;
  box-shadow: 0 0 10px rgba(34,197,94,0.5); transform: scale(1.05); }

.bng-cartons-zone { padding-top: 6px; }
.bng-cartons-label { font-size: 0.76rem; font-weight: 800; color: var(--text-muted); text-transform: uppercase;
  letter-spacing: 0.08em; margin-bottom: 10px; }
.bng-others-label { margin-top: 22px; }
.bng-cartons-others { gap: 10px; }

/* ════════ ENDED / WINNER ════════ */
#bng-phase-ended { position: relative; }
.bng-confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 60; }
.bng-confetti-bit { position: absolute; top: -16px; width: 10px; height: 16px; border-radius: 2px; opacity: 0.95;
  animation: bngFall linear forwards; }
@keyframes bngFall { to { transform: translateY(108vh) rotate(680deg); opacity: 0.9; } }
.bng-ended-card { position: relative; z-index: 2; max-width: 560px; margin: 16px auto; text-align: center;
  padding: 30px 24px; border-radius: 26px; border: 1px solid rgba(245,185,66,0.35);
  background: radial-gradient(120% 100% at 50% 0%, rgba(245,185,66,0.14), transparent 60%), linear-gradient(170deg, #16241c, #0b0f16);
  box-shadow: 0 24px 60px rgba(0,0,0,0.5); }
.bng-ended-shout { font-size: 2.8rem; font-weight: 900; letter-spacing: 0.04em; margin-bottom: 16px;
  background: linear-gradient(120deg, #ffe9a8, #f5a623, #ffe9a8); -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; animation: bngShout .7s cubic-bezier(.2,1.6,.4,1); text-shadow: 0 0 30px rgba(245,166,35,0.3); }
@keyframes bngShout { 0% { transform: scale(0.3) rotate(-8deg); opacity: 0; } 60% { transform: scale(1.18); } 100% { transform: scale(1); } }
.bng-winner-row { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-bottom: 20px; }
.bng-winner-chip { display: flex; align-items: center; gap: 11px; padding: 10px 16px 10px 10px; border-radius: 16px;
  background: rgba(255,255,255,0.05); border: 1px solid rgba(245,185,66,0.3); }
.bng-winner-meta { text-align: left; }
.bng-winner-name { font-weight: 800; }
.bng-winner-prize { font-size: 1.15rem; font-weight: 900; color: var(--bng-gold); }
.bng-house-note { font-size: 0.8rem; font-weight: 700; color: var(--text-secondary); margin-bottom: 16px;
  padding: 8px 12px; border-radius: 12px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08); display: inline-block; }
.bng-ended-carton { display: flex; justify-content: center; margin-bottom: 18px; }
.bng-ended-sub { color: var(--text-secondary); font-size: 0.9rem; }
.bng-ended-sub span { color: var(--bng-gold); font-weight: 800; }

/* ── Create modal ── */
.bng-modal { max-width: 520px; }
.bng-modal h3 { margin: 0 0 18px; font-size: 1.3rem; }
.bng-modal-close { position: absolute; top: 16px; right: 16px; width: 36px; height: 36px; border-radius: 10px; border: none;
  background: rgba(255,255,255,0.06); color: var(--bng-ink); font-size: 1rem; cursor: pointer; }
.bng-field { margin-bottom: 14px; }
.bng-field .form-label { display: block; margin-bottom: 6px; font-size: 0.82rem; font-weight: 700; color: var(--text-secondary); }
.bng-row3 { display: grid; grid-template-columns: auto auto 1fr; gap: 12px; align-items: end; }
.bng-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.bng-grow { min-width: 0; }
.bng-emoji-input { width: 70px; text-align: center; font-size: 1.2rem; }
.bng-color-input { width: 58px; height: 44px; padding: 4px; }
.bng-field-note { font-size: 0.78rem; color: var(--text-muted); margin: 6px 0 16px; line-height: 1.45; }
.bng-form-actions { display: flex; gap: 10px; justify-content: flex-end; }

/* ── Responsive ── */
@media (max-width: 860px) {
  .bng-buy-grid { grid-template-columns: 1fr; }
  .bng-play-top { grid-template-columns: 1fr; }
  .bng-machine-glass { width: 200px; height: 200px; }
  .bng-head { flex-direction: column; align-items: flex-start; }
  .bng-head h1 { font-size: 1.9rem; }
}
@media (max-width: 560px) {
  .bng-stage { padding: 12px; }
  .bng-my-cartons .bng-carton, .bng-cartons-mine .bng-carton, .bng-ended-carton .bng-carton { width: 100%; max-width: 300px; }
  .bng-cartons-mine { justify-content: center; }
  .bng-room-name { max-width: 30vw; }
  .bng-price-row { gap: 10px; }
  .bng-stepper { margin-left: 0; }
  .bng-buy-btn { flex: 1; }
}

/* ============================================================
   Manual daubing + caller controls (hand-marked cartones)
   ============================================================ */
/* Tappable cells on YOUR cartones during the draw */
.bng-cell.tappable { cursor: pointer; }
.bng-cell.tappable:hover { background: rgba(255,255,255,0.1); }
/* A called (drawn) number you haven't daubed yet — pulses to invite a tap */
.bng-cell.callable {
  color: var(--bng-gold);
  border-color: rgba(245,185,66,0.65);
  box-shadow: 0 0 0 2px rgba(245,185,66,0.28) inset, 0 0 12px rgba(245,185,66,0.25);
  animation: bngCallable 1.15s ease-in-out infinite;
}
@keyframes bngCallable {
  0%, 100% { box-shadow: 0 0 0 2px rgba(245,185,66,0.25) inset, 0 0 10px rgba(245,185,66,0.2); }
  50%      { box-shadow: 0 0 0 2px rgba(245,185,66,0.6) inset, 0 0 18px rgba(245,185,66,0.5); }
}
/* marked wins over callable (server truth after you daub) */
.bng-cell.marked.callable { animation: none; }
.bng-cell.shake { animation: bngShake .4s ease; }
@keyframes bngShake { 0%,100% { transform: translateX(0); } 20%,60% { transform: translateX(-4px); } 40%,80% { transform: translateX(4px); } }

/* Controls bar above your cartones */
.bng-cartons-topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 4px; }
.bng-mark-hint { font-size: 0.78rem; font-weight: 600; color: #8b93a7; }
.bng-play-controls { display: flex; align-items: center; gap: 10px; }

.bng-voice-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 999px; cursor: pointer;
  font-weight: 800; font-size: 0.84rem; color: var(--bng-ink);
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.12);
  transition: background .15s ease, border-color .15s ease, opacity .15s ease;
}
.bng-voice-toggle:hover { background: rgba(255,255,255,0.1); }
.bng-voice-toggle.off { opacity: 0.55; }

.bng-claim-btn {
  padding: 11px 22px; border-radius: 999px; border: none; cursor: not-allowed;
  font-weight: 900; font-size: 0.95rem; letter-spacing: 0.04em; color: #2a1a00;
  background: rgba(255,255,255,0.08); color: #8b93a7;
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}
.bng-claim-btn.ready {
  cursor: pointer; color: #2a1a00;
  background: linear-gradient(145deg, #ffd86b, #f5a623);
  box-shadow: 0 6px 22px rgba(245,185,66,0.5);
  animation: bngClaimPulse 1s ease-in-out infinite;
}
.bng-claim-btn.ready:hover { filter: brightness(1.06); transform: translateY(-1px); }
.bng-claim-btn.shake { animation: bngShake .4s ease; }
@keyframes bngClaimPulse {
  0%, 100% { box-shadow: 0 6px 22px rgba(245,185,66,0.45); }
  50%      { box-shadow: 0 6px 30px rgba(245,185,66,0.85); transform: translateY(-1px); }
}

@media (max-width: 560px) {
  .bng-cartons-topbar { position: sticky; bottom: 0; z-index: 5; }
  .bng-claim-btn { padding: 10px 18px; }
}
