/* ============================================================
   ZilverSpel – Games Shared CSS
   ============================================================ */

/* ── Game Balance Bar ─────────────────────────────────────── */
.game-balance-bar {
    display: flex; align-items: center; justify-content: center; gap: 32px;
    background: var(--emerald-card); border: 1px solid var(--border);
    border-radius: var(--radius-xl); padding: 20px 40px; margin: 0 auto 36px;
    max-width: 680px; flex-wrap: wrap;
}
.game-bal-item { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 90px; }
.game-bal-item--win .game-bal-value { color: #A5D6A7; }
.game-bal-label { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.1em; }
.game-bal-value { font-family: var(--font-display); font-size: 1.6rem; font-weight: 700; color: var(--silver); line-height: 1; transition: all 0.3s ease; }
.game-bal-unit  { font-size: 0.72rem; color: var(--text-muted); letter-spacing: 0.08em; }
.bet-controls { display: flex; align-items: center; gap: 8px; }
.bet-btn {
    width: 28px; height: 28px; background: rgba(192,200,216,0.1);
    border: 1px solid var(--border); border-radius: 6px; color: var(--silver);
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 0.75rem; transition: var(--transition);
}
.bet-btn:hover { background: rgba(192,200,216,0.25); border-color: var(--silver); }
#bet-display { font-family: var(--font-display); font-size: 1.1rem; font-weight: 700; color: var(--silver); min-width: 36px; text-align: center; }

/* ── Wheel Wrapper ────────────────────────────────────────── */
.wheel-wrapper { max-width: 720px; margin: 0 auto; padding: 0 24px; }

/* ── Wheel Machine ────────────────────────────────────────── */
.wheel-machine {
    background: linear-gradient(145deg, #081a10 0%, #061008 100%);
    border: 2px solid rgba(192,200,216,0.3);
    border-radius: var(--radius-xl); padding: 32px 28px 24px;
    margin-bottom: 24px; position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.7), inset 0 1px 0 rgba(192,200,216,0.08);
}

/* Lights */
.machine-lights { display: flex; justify-content: center; gap: 10px; margin-bottom: 16px; }
.light { width: 14px; height: 14px; border-radius: 50%; background: var(--silver); box-shadow: 0 0 8px var(--silver); animation: lightBlink 1.4s ease-in-out infinite; }
.light:nth-child(2) { animation-delay:0.2s; } .light:nth-child(3) { animation-delay:0.4s; }
.light:nth-child(4) { animation-delay:0.6s; } .light:nth-child(5) { animation-delay:0.8s; }
.light:nth-child(6) { animation-delay:1.0s; } .light:nth-child(7) { animation-delay:1.2s; }
@keyframes lightBlink {
    0%,100% { opacity:1; box-shadow: 0 0 8px var(--silver); }
    50%      { opacity:0.2; box-shadow:none; }
}
.machine-title { display:flex; align-items:center; justify-content:center; gap:12px; font-family:var(--font-display); font-size:0.9rem; font-weight:700; color:var(--silver); letter-spacing:0.12em; margin-bottom:24px; }
.machine-title i { font-size:0.8rem; }

/* ── Canvas Wheel ─────────────────────────────────────────── */
.wheel-canvas-wrap {
    position: relative; display: flex; align-items: center;
    justify-content: center; margin-bottom: 20px;
}
#wheel-canvas { border-radius: 50%; display: block; filter: drop-shadow(0 0 24px rgba(192,200,216,0.25)); }

/* Pointer */
.wheel-pointer {
    position: absolute; top: -14px; left: 50%; transform: translateX(-50%);
    width: 0; height: 0;
    border-left: 14px solid transparent;
    border-right: 14px solid transparent;
    border-top: 28px solid var(--silver);
    filter: drop-shadow(0 2px 8px rgba(192,200,216,0.6));
    z-index: 5;
    animation: floatUpDown 1.2s ease-in-out infinite;
}

/* Win message */
.wheel-result { text-align:center; font-family:var(--font-display); font-size:1.4rem; font-weight:700; min-height:38px; color:var(--silver); padding:4px 0; }

/* ── Controls ─────────────────────────────────────────────── */
.wheel-controls { display:flex; align-items:center; justify-content:center; gap:16px; margin-bottom:32px; flex-wrap:wrap; }

/* ── Segments legend ──────────────────────────────────────── */
.wheel-legend {
    background: var(--emerald-card); border: 1px solid var(--border-light);
    border-radius: var(--radius-lg); padding: 24px; margin-bottom: 48px;
}
.wheel-legend__title { font-family:var(--font-display); font-size:1rem; color:var(--silver); margin-bottom:16px; display:flex; align-items:center; gap:8px; }
.wheel-legend__grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(160px,1fr)); gap:10px; margin-bottom:14px; }
.legend-row { display:flex; align-items:center; gap:10px; background:rgba(255,255,255,0.03); border:1px solid var(--border-light); border-radius:var(--radius-sm); padding:8px 12px; font-size:0.85rem; }
.legend-dot { width:14px; height:14px; border-radius:50%; flex-shrink:0; }
.legend-label { color:var(--text-secondary); flex:1; }
.legend-mult { color:var(--silver); font-weight:700; font-family:var(--font-display); }
.wheel-legend__disclaimer { font-size:0.78rem; color:var(--text-muted); display:flex; align-items:center; gap:7px; }
.wheel-legend__disclaimer i { color:var(--accent); }

/* ── Win overlay ──────────────────────────────────────────── */
.game-overlay { position:fixed; inset:0; z-index:8000; display:flex; align-items:center; justify-content:center; background:rgba(0,0,0,0.85); backdrop-filter:blur(8px); opacity:0; pointer-events:none; transition:opacity 0.4s ease; }
.game-overlay.active { opacity:1; pointer-events:all; }
.game-overlay-box { background:var(--emerald-card); border:1px solid var(--border); border-radius:var(--radius-xl); padding:48px 40px; max-width:400px; width:90%; text-align:center; animation:scaleIn 0.4s ease; }
.game-overlay-icon { font-size:3.5rem; margin-bottom:16px; }
.game-overlay-title { font-family:var(--font-display); font-size:2rem; color:var(--silver); margin-bottom:10px; }
.game-overlay-sub { color:var(--text-secondary); margin-bottom:28px; }
.game-overlay-amount { font-family:var(--font-display); font-size:2.8rem; color:var(--silver); margin-bottom:24px; }

@media (max-width:600px) {
    .game-balance-bar { gap:16px; padding:16px 20px; }
    #wheel-canvas { width:280px !important; height:280px !important; }
}
