/* ═══════════════════════════════════════════
   BLACKJACK — IceC Originals  (v2)
   Matches keno frame layout exactly
   ═══════════════════════════════════════════ */

/* ── Page Layout ──────────────────────────── */
.bj-page {
  max-width: 1100px;
  margin: 0 auto;
  padding: 100px 24px 60px;
  min-height: 80vh;
  width: 100%;
  box-sizing: border-box;
}

/* ── Auth Gate ────────────────────────────── */
.bj-gate {
  text-align: center;
  padding: 4rem 2rem;
}
.bj-gate-icon { margin-bottom: 1rem; }
.bj-gate-title {
  font-family: 'Bungee', cursive;
  font-size: 1.4rem;
  color: #fff;
  margin-bottom: 0.5rem;
}
.bj-gate-sub {
  color: rgba(255,255,255,0.5);
  font-size: 0.95rem;
}

/* ── Title Row ────────────────────────────── */
.bj-title-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}
.bj-back-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 8px;
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.5);
  transition: all 0.2s;
  text-decoration: none;
}
.bj-back-arrow:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.bj-title {
  font-family: 'Bungee', cursive;
  font-size: 1.5rem;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* ═══════════════════════════════════════════
   FRAME — mirrors keno-frame exactly
   ═══════════════════════════════════════════ */
.bj-frame {
  display: flex;
  gap: 0;
  width: 100%;
  background: var(--bg-card);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 16px;
  overflow: hidden;
  height: 660px;
  min-height: 660px;
  max-height: 660px;
  position: relative;
}

/* ── Sidebar (absolutely positioned, same as keno) ── */
.bj-sidebar {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 260px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: rgba(0,0,0,0.15);
  border-right: 1px solid rgba(255,255,255,0.06);
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 3;
}
.bj-control-group { display: flex; flex-direction: column; gap: 0.4rem; }
.bj-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  color: rgba(255,255,255,0.45);
  letter-spacing: 0.04em;
}

/* Spacer to push deal button to bottom */
.bj-sidebar-spacer { flex: 1; }

/* ── Standard / Side Bet Toggle (mirrors keno Manual/Auto) ── */
.bj-mode-toggle {
  display: flex;
  border-radius: 999px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10);
  padding: 3px;
  gap: 0;
}
.bj-mode-btn {
  flex: 1;
  padding: 8px 0;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  color: rgba(255,255,255,0.45);
  background: transparent;
  border: none;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.25s ease;
}
.bj-mode-btn.active {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.bj-mode-btn:hover:not(.active) {
  color: rgba(255,255,255,0.7);
}

/* Panel visibility */
.bj-panel { display: flex; flex-direction: column; gap: 14px; }

/* ── Side Bet Adj Buttons ─────────────────── */
.bj-side-adj {
  padding: 6px 6px;
  font-size: 0.7rem;
}

/* Bet input */
.bj-bet-row {
  display: flex;
  gap: 4px;
  align-items: center;
}
.bj-bet-adj {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.55);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 7px 7px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
}
.bj-bet-adj:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.bj-bet-input-wrap {
  flex: 1;
  position: relative;
}
.bj-bet-gem-icon {
  position: absolute;
  left: 8px; top: 50%;
  transform: translateY(-50%);
  width: 14px; height: 14px;
  filter: brightness(0) saturate(100%) invert(83%) sepia(50%) saturate(1000%) hue-rotate(350deg) brightness(105%);
  pointer-events: none;
}
.bj-bet-input {
  width: 100%;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 8px;
  color: #fff;
  font-family: var(--font-space);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 6px 8px 26px;
  text-align: left;
  outline: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
  min-width: 0;
}
.bj-bet-input:focus { border-color: var(--pink); }

/* ── Side Bets ────────────────────────────── */
.bj-side-bets-group { gap: 0.35rem; }
.bj-side-bet {
  background: rgba(0,0,0,0.15);
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 10px;
  padding: 0.5rem 0.65rem;
  transition: border-color 0.2s;
}
.bj-side-bet:has(.bj-side-check:checked) {
  border-color: rgba(245,119,226,0.3);
}
.bj-side-bet-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
}
.bj-side-check {
  appearance: none;
  width: 16px; height: 16px;
  border: 2px solid rgba(255,255,255,0.2);
  border-radius: 4px;
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  transition: all 0.15s;
}
.bj-side-check:checked {
  background: var(--pink);
  border-color: var(--pink);
}
.bj-side-check:checked::after {
  content: '';
  position: absolute;
  left: 3px; top: 0;
  width: 5px; height: 9px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.bj-side-name {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.65);
  cursor: pointer;
  flex: 1;
}
.bj-side-bet-input {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 0.4rem;
}
.bj-side-gem {
  width: 14px; height: 14px;
  filter: brightness(0) saturate(100%) invert(83%) sepia(50%) saturate(1000%) hue-rotate(350deg) brightness(105%);
}
.bj-side-amount {
  flex: 1;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  color: #fff;
  font-family: var(--font-space);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 6px 8px 26px;
  text-align: left;
  outline: none;
  box-sizing: border-box;
  min-width: 0;
  width: 100%;
}
.bj-side-amount:focus { border-color: var(--pink); }

/* ── DDM mode button distinction ────────────── */
.bj-mode-btn[data-mode="ddm"] {
  background: linear-gradient(135deg, rgba(245,119,226,0.06), rgba(255,206,43,0.06));
}
.bj-mode-btn[data-mode="ddm"].active {
  background: linear-gradient(135deg, rgba(245,119,226,0.25), rgba(255,206,43,0.18));
  border-color: rgba(245,119,226,0.5);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(245,119,226,0.45);
}

/* ── DDM rules blurb ────────────────────────── */
.bj-ddm-rules {
  margin-top: 16px;
  padding: 14px;
  background: linear-gradient(135deg, rgba(245,119,226,0.08), rgba(255,206,43,0.05));
  border: 1px solid rgba(245,119,226,0.22);
  border-radius: 10px;
}
.bj-ddm-rules-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-space);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  color: #fff;
  margin-bottom: 8px;
}
.bj-ddm-rules-tag {
  font-size: 0.58rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 2px 6px;
  border-radius: 6px;
  background: rgba(245,119,226,0.25);
  color: var(--pink, #F577E2);
  text-transform: uppercase;
}
.bj-ddm-rules-list {
  margin: 0;
  padding: 0 0 0 1.1rem;
  list-style: disc;
  color: rgba(255,255,255,0.72);
  font-size: 0.72rem;
  line-height: 1.55;
  font-family: var(--font-space);
}
.bj-ddm-rules-list li { margin: 2px 0; }
.bj-ddm-rules-list strong { color: var(--gold, #FFCE2B); font-weight: 700; }

/* ── Table watermark mode accent ────────────── */
.bj-table-text.is-ddm .bj-table-text-main {
  color: var(--gold, #FFCE2B);
}

/* ── Double Down Madness — bet tag flash on re-double ── */
@keyframes bjDoubledFlash {
  0%   { transform: scale(1);    box-shadow: 0 0 0 0 rgba(255,206,43,0);   color: var(--gold, #FFCE2B); }
  30%  { transform: scale(1.15); box-shadow: 0 0 12px 4px rgba(255,206,43,0.55); color: #fff; }
  100% { transform: scale(1);    box-shadow: 0 0 0 0 rgba(255,206,43,0); }
}
.bj-hand-bet-tag.bj-doubled-flash {
  animation: bjDoubledFlash 0.65s ease-out;
}

/* ── Total Wager Summary ─────────────────── */
.bj-total-wager {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
  padding: 10px 12px;
  background: linear-gradient(135deg, rgba(245,119,226,0.08), rgba(255,206,43,0.06));
  border: 1px solid rgba(245,119,226,0.18);
  border-radius: 8px;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.bj-total-wager.has-value {
  border-color: rgba(245,119,226,0.5);
  background: linear-gradient(135deg, rgba(245,119,226,0.15), rgba(255,206,43,0.1));
}
.bj-total-wager-label {
  font-family: var(--font-space);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
}
.bj-total-wager-value {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-space);
  font-size: 1rem;
  font-weight: 800;
  color: var(--gold, #FFCE2B);
}
.bj-total-wager-value .bj-bet-gem-icon {
  width: 16px;
  height: 16px;
  position: static;
  transform: none;
}

/* ── Deal Button ──────────────────────────── */
.bj-deal-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 12px;
  border-radius: 12px;
  border: none;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  background: linear-gradient(135deg, var(--green), #3dd67f);
  color: #0a1a0f;
  box-shadow: 0 4px 15px rgba(80,235,150,0.25);
}
.bj-deal-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(80,235,150,0.35);
}
.bj-deal-btn:active { transform: translateY(0); }
.bj-deal-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none !important;
  box-shadow: none !important;
}

/* ═══════════════════════════════════════════
   TABLE AREA — fills right side like keno-board-area
   ═══════════════════════════════════════════ */
.bj-table {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 20px;
  gap: 14px;
  position: relative;
  margin-left: 260px;
  overflow: hidden;
}

.bj-felt {
  flex: 1;
  background: linear-gradient(180deg,
    rgba(13,28,48,0.7) 0%,
    rgba(8,20,38,0.8) 40%,
    rgba(6,16,32,0.85) 100%
  );
  border: 1px solid rgba(100,160,255,0.12);
  border-radius: 16px;
  padding: 2rem 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}
.bj-felt::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 50% 30%, rgba(100,160,255,0.05) 0%, transparent 70%);
  pointer-events: none;
}
/* Isolate felt's 3D card animations from affecting outside backdrop-filters */
.bj-frame {
  isolation: isolate;
  contain: layout style;
}

/* Table text (like Stake's "BLACKJACK PAYS 3 TO 2") */
.bj-table-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  pointer-events: none;
  z-index: 1;
  opacity: 0.12;
}
.bj-table-text-main {
  font-family: 'Bungee', cursive;
  font-size: 0.85rem;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  display: block;
  margin-bottom: 4px;
}
.bj-table-text-sub {
  font-size: 0.65rem;
  font-weight: 600;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: block;
}

/* ── Side Bet Results Banner ──────────────── */
.bj-side-results {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: center;
  position: absolute;
  top: 0.8rem;
  left: 0;
  right: 0;
  z-index: 6;
}
.bj-side-result-tag {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.7rem;
  font-weight: 700;
  animation: bjSideResultPop 0.4s cubic-bezier(0.34,1.56,0.64,1);
}
.bj-side-result-tag.win {
  background: linear-gradient(135deg, rgba(255,206,43,0.25), rgba(255,206,43,0.1));
  border: 1px solid rgba(255,206,43,0.4);
  color: var(--gold);
}
.bj-side-result-tag.lose {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.35);
  text-decoration: line-through;
}
@keyframes bjSideResultPop {
  0% { transform: scale(0.6); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* ── Cards ────────────────────────────────── */
.bj-cards {
  display: flex;
  justify-content: center;
  gap: 0;
  min-height: 120px;
  position: relative;
}
.bj-card-slot {
  width: 85px;
  height: 120px;
  position: relative;
  transition: margin-left 0.3s;
  flex-shrink: 0;
}
.bj-card-slot:not(:first-child) {
  margin-left: -25px;
}
.bj-card {
  width: 85px;
  height: 120px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  position: relative;
  transform-style: preserve-3d;
  transition: transform 0.1s;
}
.bj-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  border-radius: 8px;
  background: #fff;
}
.bj-card.bj-card-back img {
  background: transparent;
}

/* Deal animation — slide only, face always visible */
.bj-card-deal {
  animation: bjCardDeal 0.3s ease-out both;
}
@keyframes bjCardDeal {
  0% {
    transform: translateY(-30px);
    opacity: 0.85;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Hit animation — slide only, face always visible */
.bj-card-hit {
  animation: bjCardHit 0.25s ease-out both;
}
@keyframes bjCardHit {
  0% {
    transform: translateY(-20px);
    opacity: 0.85;
  }
  100% {
    transform: translateY(0);
    opacity: 1;
  }
}

/* Flip animation for hole card reveal */
.bj-card-flip {
  animation: bjCardFlip 0.5s ease-in-out forwards;
  will-change: transform;
  contain: layout style paint;
}
@keyframes bjCardFlip {
  0%   { transform: rotateY(0deg); }
  50%  { transform: rotateY(90deg); }
  100% { transform: rotateY(0deg); }
}

/* ── Hand Labels & Values ─────────────────── */
.bj-hand-label {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
  position: relative;
  z-index: 2;
}
.bj-hand-label span:first-child {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.35);
}
.bj-hand-value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  padding: 2px 8px;
  border-radius: 6px;
  background: rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.1);
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
}
.bj-hand-value.bj-val-21 { color: var(--gold); border-color: rgba(255,206,43,0.4); }
.bj-hand-value.bj-val-bj { color: var(--gold); border-color: rgba(255,206,43,0.5); background: rgba(255,206,43,0.1); }
.bj-hand-value.bj-val-bust { color: #ff4757; border-color: rgba(255,71,87,0.4); }

/* ── Dealer Area ──────────────────────────── */
.bj-dealer-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* ── Table Divider ────────────────────────── */
.bj-table-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(100,160,255,0.15), transparent);
  margin: 0.6rem 0;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ── Result Badge ─────────────────────────── */
.bj-result-badge {
  position: absolute;
  padding: 6px 20px;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  z-index: 5;
  animation: bjBadgePop 0.4s cubic-bezier(0.34,1.56,0.64,1);
  white-space: nowrap;
}
.bj-result-badge.bj-badge-win {
  background: linear-gradient(135deg, rgba(80,235,150,0.15), rgba(80,235,150,0.06));
  border: 1px solid rgba(80,235,150,0.5);
  color: var(--green);
  backdrop-filter: blur(12px) saturate(1.4);
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
}
.bj-result-badge.bj-badge-blackjack {
  background: linear-gradient(135deg, rgba(255,206,43,0.18), rgba(255,206,43,0.06));
  border: 1px solid rgba(255,206,43,0.6);
  color: var(--gold);
  backdrop-filter: blur(12px) saturate(1.4);
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
}
.bj-result-badge.bj-badge-push {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.2);
  color: rgba(255,255,255,0.6);
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
}
.bj-result-badge.bj-badge-lose {
  background: rgba(255,71,87,0.08);
  border: 1px solid rgba(255,71,87,0.35);
  color: #ff4757;
  backdrop-filter: blur(12px) saturate(1.4);
  -webkit-backdrop-filter: blur(12px) saturate(1.4);
}
@keyframes bjBadgePop {
  0% { transform: scale(0); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

/* ── Player Area ──────────────────────────── */
.bj-player-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.bj-hands-container {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  flex-wrap: wrap;
}
.bj-player-hand {
  display: flex;
  flex-direction: column;
  align-items: center;
}
.bj-player-hand .bj-hand-label {
  margin-top: 0.5rem;
  margin-bottom: 0;
}
.bj-player-hand.bj-hand-active .bj-cards {
  filter: brightness(1);
}
.bj-player-hand:not(.bj-hand-active):not(.bj-hand-only) .bj-cards {
  filter: brightness(0.5);
  opacity: 0.7;
}
.bj-player-hand.bj-hand-only .bj-cards {
  filter: brightness(1) !important;
  opacity: 1 !important;
}
.bj-hand-bet-tag {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.35);
  margin-top: 0.25rem;
}
.bj-hand-bet-tag img {
  width: 12px; height: 12px;
  vertical-align: -2px;
  filter: brightness(0) saturate(100%) invert(83%) sepia(50%) saturate(1000%) hue-rotate(350deg) brightness(105%);
}

/* ── Felt Action Buttons (pinned to bottom of felt) ── */
.bj-felt-actions {
  display: flex;
  gap: 8px;
  justify-content: center;
  position: absolute;
  bottom: 1.2rem;
  left: 0;
  right: 0;
  z-index: 5;
}
.bj-felt-btn {
  padding: 9px 22px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.5);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  box-shadow: 0 2px 8px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,255,255,0.06);
}
.bj-felt-btn:hover:not(:disabled) {
  background: rgba(255,255,255,0.12);
  border-color: rgba(255,255,255,0.3);
  color: #fff;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.1);
}
.bj-felt-btn:disabled {
  opacity: 0.2;
  cursor: not-allowed;
}
.bj-felt-btn.bj-felt-active {
  background: rgba(80,235,150,0.1);
  border-color: rgba(80,235,150,0.4);
  color: var(--green);
  box-shadow: 0 2px 10px rgba(80,235,150,0.15), inset 0 1px 0 rgba(80,235,150,0.1);
}
.bj-felt-btn.bj-felt-active:hover:not(:disabled) {
  background: rgba(80,235,150,0.18);
  box-shadow: 0 4px 14px rgba(80,235,150,0.25), inset 0 1px 0 rgba(80,235,150,0.15);
}

/* ── Play Again Button (pinned to bottom of felt) ── */
.bj-play-again-wrap {
  display: flex;
  justify-content: center;
  position: absolute;
  bottom: 1.2rem;
  left: 0;
  right: 0;
  z-index: 5;
  animation: bjBadgePop 0.35s cubic-bezier(0.34,1.56,0.64,1);
}
.bj-play-again-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 28px;
  border-radius: 12px;
  border: 1px solid rgba(80,235,150,0.35);
  background: rgba(80,235,150,0.08);
  color: var(--green);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  box-shadow: 0 2px 10px rgba(80,235,150,0.12), inset 0 1px 0 rgba(80,235,150,0.08);
}
.bj-play-again-btn:hover {
  background: rgba(80,235,150,0.15);
  border-color: rgba(80,235,150,0.5);
  box-shadow: 0 4px 16px rgba(80,235,150,0.25), inset 0 1px 0 rgba(80,235,150,0.12);
  transform: translateY(-1px);
}
.bj-play-again-btn:active {
  transform: translateY(0);
}
.bj-play-again-btn svg {
  opacity: 0.8;
}
.bj-play-again-btn:disabled,
.bj-play-again-btn[disabled] {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
  filter: grayscale(0.6);
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.4);
  box-shadow: none;
}

/* Deal button in "not enough gems" state — red-tinted, muted */
.bj-deal-btn.bj-no-funds {
  background: rgba(255,71,87,0.1) !important;
  border-color: rgba(255,71,87,0.3) !important;
  color: rgba(255,120,120,0.85) !important;
  box-shadow: none !important;
}

/* ── Insurance Bar (pinned to bottom of felt) ── */
.bj-insurance-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 10px 16px;
  background: rgba(255,206,43,0.06);
  border: 1px solid rgba(255,206,43,0.3);
  border-radius: 12px;
  position: absolute;
  bottom: 1.2rem;
  left: 1.5rem;
  right: 1.5rem;
  z-index: 5;
  backdrop-filter: blur(14px) saturate(1.3);
  -webkit-backdrop-filter: blur(14px) saturate(1.3);
  box-shadow: 0 2px 10px rgba(0,0,0,0.2), inset 0 1px 0 rgba(255,206,43,0.08);
}
.bj-insurance-btns {
  display: flex;
  gap: 8px;
}
.bj-ins-btn {
  padding: 6px 18px;
  border-radius: 8px;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid rgba(255,255,255,0.12);
  transition: all 0.15s;
}
.bj-ins-yes {
  background: rgba(255,206,43,0.15);
  border-color: rgba(255,206,43,0.4);
  color: var(--gold);
}
.bj-ins-yes:hover { background: rgba(255,206,43,0.25); }
.bj-ins-no {
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.5);
}
.bj-ins-no:hover { background: rgba(255,255,255,0.1); color: #fff; }


/* ── Insurance Prompt Text ────────────────── */
.bj-insurance-prompt {
  color: rgba(255,255,255,0.6);
  font-size: 0.8rem;
  white-space: nowrap;
}

/* ── Bottom Buttons (sidebar) ────────────── */
.bj-bottom-btns {
  display: flex;
  gap: 6px;
}
.bj-bottom-btns .bj-fairness-toggle { flex: 1; }
.bj-fairness-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  color: rgba(255,255,255,0.4);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.75rem;
  cursor: pointer;
  padding: 8px 10px;
  transition: all 0.15s;
  width: 100%;
  justify-content: center;
}
.bj-fairness-toggle:hover { color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.07); }

/* ═══════════════════════════════════════════
   PROVABLY FAIR MODAL (mirrors keno exactly)
   ═══════════════════════════════════════════ */
.bj-fair-overlay {
  position: fixed;
  inset: 0;
  z-index: 9998;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.bj-fair-modal {
  background: var(--bg-card, #141428);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 24px;
  max-width: 480px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}
.bj-fair-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.bj-fair-modal-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}
.bj-fair-modal-title svg { color: var(--green, #50EB96); }
.bj-fair-modal-close {
  background: none;
  border: none;
  color: rgba(255,255,255,0.4);
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 0 4px;
  transition: color 0.15s;
}
.bj-fair-modal-close:hover { color: #fff; }

/* ── Fair Tabs ────────────────────────────── */
.bj-fair-tabs {
  display: flex;
  background: rgba(255,255,255,0.05);
  border-radius: 10px;
  padding: 3px;
  gap: 2px;
}
.bj-fair-tab {
  flex: 1;
  padding: 8px 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: rgba(255,255,255,0.4);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
}
.bj-fair-tab:hover { color: rgba(255,255,255,0.7); }
.bj-fair-tab.active {
  background: rgba(255,255,255,0.1);
  color: #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
.bj-fair-tab-panel {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 4px;
}

/* ── Fair Fields ──────────────────────────── */
.bj-fair-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.bj-fair-field-box {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 8px;
  padding: 10px 12px;
  min-height: 20px;
}
.bj-fair-field-value {
  flex: 1;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.7);
  word-break: break-all;
  line-height: 1.3;
}
.bj-fair-copy {
  background: none;
  border: none;
  color: rgba(255,255,255,0.4);
  cursor: pointer;
  padding: 2px;
  transition: color 0.15s;
  flex-shrink: 0;
}
.bj-fair-copy:hover { color: var(--pink, #F577E2); }
.bj-fair-divider {
  height: 1px;
  background: rgba(255,255,255,0.08);
  margin: 4px 0;
}
.bj-fair-section-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}
.bj-fair-label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.04em;
}
.bj-fair-hash { font-size: 0.65rem; opacity: 0.7; }
.bj-fair-rotate-row {
  display: flex;
  gap: 8px;
}
.bj-fair-rotate-row .bj-fair-input { flex: 1; }
.bj-fair-input {
  width: 100%;
  padding: 8px 12px;
  border-radius: 8px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.05);
  color: #fff;
  font-size: 0.82rem;
  font-family: 'Space Grotesk', sans-serif;
  outline: none;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.bj-fair-input:focus { border-color: var(--pink, #F577E2); }
.bj-fair-change-btn {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 8px;
  color: rgba(255,255,255,0.7);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 8px 18px;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}
.bj-fair-change-btn:hover {
  background: rgba(255,255,255,0.12);
  color: #fff;
}
.bj-fair-input-copy {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 6px;
  color: rgba(255,255,255,0.4);
  padding: 6px 8px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.bj-fair-input-copy:hover { color: var(--pink, #F577E2); background: rgba(255,255,255,0.1); }
.bj-fair-note {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.65rem;
  color: rgba(255,255,255,0.4);
  opacity: 0.7;
  margin: 0 0 4px;
  line-height: 1.4;
}
.bj-verify-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 10px;
  background: var(--green, #50EB96);
  border: none;
  border-radius: 8px;
  color: #000;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s;
}
.bj-verify-btn:hover { filter: brightness(1.1); }
.bj-verify-result {
  background: rgba(0,0,0,0.2);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.bj-verify-hash {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.65rem;
  color: rgba(255,255,255,0.7);
  word-break: break-all;
  opacity: 0.8;
}
.bj-verify-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}
.bj-verify-card {
  width: 40px;
  height: 56px;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}
.bj-verify-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
  border-radius: 4px;
}
.bj-verify-range {
  font-size: 0.6rem;
  color: rgba(255,255,255,0.4);
  font-weight: 400;
}

/* ═══════════════════════════════════════════
   RECENT BETS STRIP — mirrors keno exactly
   ═══════════════════════════════════════════ */
.bj-recent-strip {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 2px 0;
  min-height: 28px;
}
.bj-recent-strip::-webkit-scrollbar { display: none; }

.bj-recent-chip {
  flex-shrink: 0;
  padding: 4px 10px;
  border-radius: 6px;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s;
  white-space: nowrap;
}
.bj-recent-chip:hover {
  transform: translateY(-1px);
  filter: brightness(1.2);
}
.bj-recent-chip.win {
  background: rgba(80,235,150,0.15);
  color: var(--green);
  border-color: rgba(80,235,150,0.2);
}
.bj-recent-chip.loss {
  background: rgba(255,255,255,0.05);
  color: rgba(255,255,255,0.35);
  border-color: rgba(255,255,255,0.06);
}
.bj-recent-chip.blackjack {
  background: rgba(255,206,43,0.15);
  color: var(--gold);
  border-color: rgba(255,206,43,0.25);
}
.bj-recent-chip.push {
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.45);
  border-color: rgba(255,255,255,0.1);
}

/* ═══════════════════════════════════════════
   HAND REPLAY MODAL
   ═══════════════════════════════════════════ */
.bj-replay-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.bj-replay-modal {
  background: var(--bg-card, #141428);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 16px;
  padding: 24px;
  max-width: 520px;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  position: relative;
}
.bj-replay-close {
  position: absolute;
  top: 12px;
  right: 16px;
  background: none;
  border: none;
  color: rgba(255,255,255,0.4);
  font-size: 1.5rem;
  cursor: pointer;
  transition: color 0.15s;
  line-height: 1;
}
.bj-replay-close:hover { color: #fff; }

.bj-replay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.bj-replay-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
}
.bj-replay-meta {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.35);
}

.bj-replay-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(100,160,255,0.15), transparent);
}

/* Dealer / Player sections in replay */
.bj-replay-dealer,
.bj-replay-player {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.bj-replay-section-label {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: rgba(255,255,255,0.3);
}
.bj-replay-cards {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
}
.bj-replay-card {
  width: 60px;
  height: 84px;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 3px 10px rgba(0,0,0,0.4);
}
.bj-replay-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
  border-radius: 6px;
}
.bj-replay-hand-value {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  padding: 2px 10px;
  border-radius: 6px;
  background: rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.1);
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  color: #fff;
}
.bj-replay-hand-value.val-21 { color: var(--gold); border-color: rgba(255,206,43,0.4); }
.bj-replay-hand-value.val-bj { color: var(--gold); border-color: rgba(255,206,43,0.5); background: rgba(255,206,43,0.1); }
.bj-replay-hand-value.val-bust { color: #ff4757; border-color: rgba(255,71,87,0.4); }

/* Multiple hands in replay */
.bj-replay-hands-wrap {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}
.bj-replay-hand-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.bj-replay-hand-label {
  font-size: 0.6rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255,255,255,0.3);
}

/* Stats row at bottom of replay */
.bj-replay-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  padding-top: 6px;
}
.bj-replay-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-width: 60px;
}
.bj-replay-stat-label {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.6rem;
  color: rgba(255,255,255,0.35);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.bj-replay-stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
}
.bj-replay-stat-value.win { color: var(--green); }
.bj-replay-stat-value.loss { color: rgba(255,255,255,0.35); }
.bj-replay-stat-value.gold { color: var(--gold); }

/* Side bet results in replay */
.bj-replay-sides {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
}
.bj-replay-side-tag {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.68rem;
  font-weight: 700;
}
.bj-replay-side-tag.win {
  background: linear-gradient(135deg, rgba(255,206,43,0.2), rgba(255,206,43,0.08));
  border: 1px solid rgba(255,206,43,0.35);
  color: var(--gold);
}
.bj-replay-side-tag.lose {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.3);
  text-decoration: line-through;
}

/* ═══════════════════════════════════════════
   RESPONSIVE — mirrors keno breakpoints
   ═══════════════════════════════════════════ */
@media (max-width: 860px) {
  .bj-page { padding-top: 80px; }
  .bj-frame {
    flex-direction: column;
    height: auto;
    min-height: auto;
    max-height: none;
  }
  .bj-sidebar {
    position: relative;
    top: auto;
    left: auto;
    bottom: auto;
    width: 100%;
    min-width: unset;
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    padding: 16px;
    overflow-y: visible;
  }
  .bj-table { padding: 16px; margin-left: 0; overflow: visible; }
  .bj-felt {
    min-height: 380px;
    padding: 1.25rem 1rem;
  }
  .bj-card-slot { width: 70px; height: 100px; }
  .bj-card { width: 70px; height: 100px; }
  .bj-card-slot:not(:first-child) { margin-left: -20px; }
  .bj-sidebar-spacer { display: none; }
}
@media (max-width: 480px) {
  .bj-card-slot { width: 60px; height: 86px; }
  .bj-card { width: 60px; height: 86px; }
  .bj-card-slot:not(:first-child) { margin-left: -18px; }
  .bj-action-btn { padding: 8px 14px; font-size: 0.8rem; }
  .bj-replay-card { width: 48px; height: 67px; }
  .bj-replay-modal { padding: 16px; }
}

/* ═══════════════════════════════════════════
   ACTIVE CHALLENGES — mirrors keno exactly
   ═══════════════════════════════════════════ */
.bj-challenges-section {
  margin-top: 18px;
  background:
    linear-gradient(
      165deg,
      rgba(255,255,255,0.10) 0%,
      rgba(255,255,255,0.03) 35%,
      rgba(180,200,255,0.04) 55%,
      rgba(255,255,255,0.07) 100%
    ),
    rgba(14,18,32,0.45);
  -webkit-backdrop-filter: blur(24px) saturate(1.6) brightness(1.05);
  backdrop-filter: blur(24px) saturate(1.6) brightness(1.05);
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 14px;
  padding: 16px 18px;
  box-shadow:
    inset 0 1px 1px 0 rgba(255,255,255,0.18),
    inset 0 -0.5px 1px 0 rgba(255,255,255,0.06),
    0 4px 24px rgba(0,0,0,0.2);
  /* Prevent backdrop-filter flicker during card flip animations */
  will-change: backdrop-filter;
  transform: translateZ(0);
  isolation: isolate;
}
.bj-challenges-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-space);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 12px;
}
.bj-challenges-header svg {
  color: var(--gold);
  flex-shrink: 0;
}
.bj-challenges-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.bj-challenges-empty {
  font-family: var(--font-space);
  font-size: 0.8rem;
  color: var(--text-muted);
  text-align: center;
  padding: 20px 0;
  opacity: 0.6;
}

/* Single challenge card */
.bj-challenge-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background:
    linear-gradient(
      165deg,
      rgba(255,255,255,0.08) 0%,
      rgba(255,255,255,0.02) 50%,
      rgba(255,255,255,0.05) 100%
    ),
    rgba(14,18,32,0.35);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  backdrop-filter: blur(16px) saturate(1.4);
  border: 1px solid rgba(255,255,255,0.09);
  border-radius: 10px;
  padding: 12px 14px;
  transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
  box-shadow: inset 0 1px 0 0 rgba(255,255,255,0.10);
}
.bj-challenge-card:hover {
  border-color: rgba(255,206,43,0.25);
  background:
    linear-gradient(
      165deg,
      rgba(255,255,255,0.11) 0%,
      rgba(255,255,255,0.03) 50%,
      rgba(255,255,255,0.07) 100%
    ),
    rgba(14,18,32,0.40);
  box-shadow: inset 0 1px 0 0 rgba(255,255,255,0.14), 0 2px 12px rgba(255,206,43,0.06);
}
.bj-challenge-card.completed {
  border-color: rgba(80,235,150,0.3);
  background:
    linear-gradient(
      165deg,
      rgba(80,235,150,0.08) 0%,
      rgba(80,235,150,0.02) 50%,
      rgba(80,235,150,0.05) 100%
    ),
    rgba(14,18,32,0.35);
  opacity: 0.7;
}

/* Icon circle */
.bj-challenge-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,206,43,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.bj-challenge-icon svg { color: var(--gold); }
.bj-challenge-card.completed .bj-challenge-icon {
  background: rgba(80,235,150,0.15);
}
.bj-challenge-card.completed .bj-challenge-icon svg {
  color: var(--green);
}

/* Info block */
.bj-challenge-info { flex: 1; min-width: 0; }
.bj-challenge-title {
  font-family: var(--font-space);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
}
.bj-challenge-desc {
  font-family: var(--font-space);
  font-size: 0.72rem;
  color: var(--text-secondary);
  margin-top: 2px;
  line-height: 1.3;
}
.bj-challenge-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}
.bj-challenge-tag {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-family: var(--font-space);
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--text-muted);
  background: rgba(255,255,255,0.06);
  border-radius: 4px;
  padding: 2px 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Reward badge */
.bj-challenge-reward {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
  font-family: var(--font-bungee, var(--font-space));
  font-size: 0.85rem;
  color: var(--gold);
  white-space: nowrap;
}
.bj-challenge-reward img {
  width: 16px;
  height: 16px;
  filter: brightness(0) saturate(100%) invert(83%) sepia(50%) saturate(1000%) hue-rotate(350deg) brightness(105%);
}
.bj-challenge-card.completed .bj-challenge-reward {
  color: var(--green);
}

/* Completed checkmark */
.bj-challenge-check {
  display: none;
  color: var(--green);
  flex-shrink: 0;
}
.bj-challenge-card.completed .bj-challenge-check {
  display: flex;
}

/* Progress bar */
.bj-challenge-progress {
  width: 100%;
  height: 3px;
  background: rgba(255,255,255,0.08);
  border-radius: 2px;
  margin-top: 5px;
  overflow: hidden;
}
.bj-challenge-progress-fill {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  transition: width 0.4s ease;
}
.bj-challenge-card.completed .bj-challenge-progress-fill {
  background: var(--green);
}

/* Challenge toast */
.bj-challenge-toast {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 10000;
  background: linear-gradient(135deg, rgba(30,30,40,0.97) 0%, rgba(20,20,30,0.97) 100%);
  border: 1px solid rgba(255,206,43,0.4);
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4), 0 0 20px rgba(255,206,43,0.15);
  animation: bjChallengeToastIn 0.4s ease;
  max-width: 340px;
}
.bj-challenge-toast.out {
  animation: bjChallengeToastOut 0.3s ease forwards;
}
.bj-challenge-toast-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255,206,43,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.bj-challenge-toast-icon svg { color: var(--gold); }
.bj-challenge-toast-body { flex: 1; }
.bj-challenge-toast-title {
  font-family: var(--font-space);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--gold);
}
.bj-challenge-toast-sub {
  font-family: var(--font-space);
  font-size: 0.72rem;
  color: rgba(255,255,255,0.6);
  margin-top: 2px;
}
.bj-challenge-toast-gems {
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-bungee, var(--font-space));
  font-size: 0.9rem;
  color: var(--gold);
  white-space: nowrap;
}
.bj-challenge-toast-gems img {
  width: 16px;
  height: 16px;
  filter: brightness(0) saturate(100%) invert(83%) sepia(50%) saturate(1000%) hue-rotate(350deg) brightness(105%);
}
@keyframes bjChallengeToastIn {
  0% { transform: translateX(120%); opacity: 0; }
  100% { transform: translateX(0); opacity: 1; }
}
@keyframes bjChallengeToastOut {
  0% { transform: translateX(0); opacity: 1; }
  100% { transform: translateX(120%); opacity: 0; }
}
