/* ========== Overall Container ========== */

.rspokies-game-container {
    max-width: 420px;
    margin: 1.5rem auto;
    padding: 0.5rem;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

/* Machine cabinet */
.rspokies-machine {
    background: radial-gradient(circle at top, #333 0, #111 40%, #050505 100%);
    border-radius: 18px;
    padding: 0.75rem 0.75rem 1rem;
    box-shadow:
        0 0 0 2px #222,
        0 10px 25px rgba(0,0,0,0.7);
    color: #f5f5f5;
    position: relative;
}

/* ========== Top Panel / Marquee ========== */

.rspokies-top-panel {
    background: linear-gradient(135deg, #ffb648, #ff6a4d);
    border-radius: 12px;
    padding: 0.45rem 0.75rem;
    box-shadow:
        0 0 0 2px rgba(0,0,0,0.4),
        0 3px 8px rgba(0,0,0,0.6);
    text-align: center;
    margin-bottom: 0.75rem;
}

.rspokies-game-title {
    font-size: 1.3rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-shadow: 0 2px 4px rgba(0,0,0,0.6);
}

.rspokies-game-subtitle {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: rgba(0,0,0,0.8);
}

/* ========== Reels Window ========== */

.rspokies-window {
    margin: 0.75rem 0;
    padding: 0.4rem;
    border-radius: 12px;
    background: radial-gradient(circle at top, #202020, #050505);
    box-shadow:
        inset 0 0 0 1px rgba(255,255,255,0.05),
        inset 0 0 15px rgba(0,0,0,0.8);
    position: relative;
}

.rspokies-reels {
    display: flex;
    gap: 0.35rem;
    justify-content: center;
}

/* Win highlight overlay (middle row-ish glow) */
.rspokies-win-overlay {
    position: absolute;
    inset: 0.4rem;
    pointer-events: none;
    opacity: 0;
    border-radius: 10px;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        transparent 25%,
        rgba(255, 240, 120, 0.1) 40%,
        rgba(255, 240, 120, 0.35) 50%,
        rgba(255, 240, 120, 0.1) 60%,
        transparent 75%,
        transparent 100%
    );
    box-shadow: 0 0 0 0 rgba(255, 255, 150, 0.5);
    transition: opacity 0.15s ease-out, box-shadow 0.15s ease-out;
}

.rspokies-win-overlay.is-active {
    opacity: 1;
    box-shadow: 0 0 18px 4px rgba(255, 255, 150, 0.5);
}

/* Individual reel frames */
.rspokies-reel {
    width: 80px;
    height: 150px; /* shows 3 symbols at ~50px each */
    border-radius: 10px;
    border: 1px solid #555;
    background: linear-gradient(180deg, #181818, #101010);
    overflow: hidden;
    box-shadow:
        inset 0 0 3px rgba(0,0,0,0.9),
        0 0 8px rgba(0,0,0,0.8);
    position: relative;
}

.rspokies-reel-strip {
    display: flex;
    flex-direction: column;
    transform: translateY(0);
    /* Transition is set dynamically in JS per spin. */
}

/* Symbol tiles */
.rspokies-symbol {
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
    color: #fff;
}

/* Alternate subtle background stripes per symbol row */
.rspokies-symbol:nth-child(odd) {
    background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
}

.rspokies-symbol:nth-child(even) {
    background: linear-gradient(180deg, rgba(0,0,0,0.25), rgba(0,0,0,0.35));
}

/* ========== Info Panel (Credits / Bet / Win) ========== */

.rspokies-info-panel {
    margin-top: 0.2rem;
    margin-bottom: 0.6rem;
    background: #050505;
    border-radius: 10px;
    padding: 0.4rem 0.6rem;
    display: flex;
    justify-content: space-between;
    gap: 0.4rem;
    box-shadow:
        inset 0 0 4px rgba(0,0,0,0.9),
        0 2px 4px rgba(0,0,0,0.7);
}

.rspokies-info-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.rspokies-info-label {
    font-size: 0.6rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #999;
}

.rspokies-info-value {
    margin-top: 0.15rem;
    font-family: "Courier New", monospace;
    font-size: 0.95rem;
    color: #8dff7a;
}

/* Win flash on WIN value */
.rspokies-info-value--win-flash {
    color: #fff7b0;
    text-shadow: 0 0 6px rgba(255, 255, 190, 0.9);
    animation: rspokies-win-pulse 0.7s ease-out 0s 1;
}

@keyframes rspokies-win-pulse {
    0% {
        transform: scale(1);
        color: #8dff7a;
    }
    40% {
        transform: scale(1.25);
    }
    70% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* ========== Controls Panel & Bet Controls ========== */

.rspokies-controls-panel {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}

.rspokies-bet-controls {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: #050505;
    border-radius: 999px;
    padding: 0.25rem 0.45rem;
    box-shadow:
        inset 0 0 3px rgba(0,0,0,0.9),
        0 1px 3px rgba(0,0,0,0.6);
}

.rspokies-bet-button {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: linear-gradient(135deg, #3b3b3b, #181818);
    color: #f5f5f5;
    font-weight: 700;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        0 0 0 1px #000,
        0 2px 4px rgba(0,0,0,0.7);
    transition: transform 0.05s ease-out, box-shadow 0.05s ease-out, filter 0.1s;
}

.rspokies-bet-button:hover {
    filter: brightness(1.05);
}

.rspokies-bet-button:active {
    transform: translateY(1px);
    box-shadow:
        0 0 0 1px #000,
        0 1px 3px rgba(0,0,0,0.8);
}

.rspokies-bet-display-inline {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 60px;
}

.rspokies-bet-inline-label {
    font-size: 0.55rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #b5b5b5;
}

.rspokies-bet-inline-amount {
    font-family: "Courier New", monospace;
    font-size: 0.95rem;
    color: #f5f5f5;
}

/* Spin button */

.rspokies-spin-button,
#rspokies-spin-button {
    padding: 0.55rem 2.2rem;
    border-radius: 999px;
    border: none;
    background: radial-gradient(circle at top, #4fff68, #1ca92b);
    color: #052006;
    font-weight: 800;
    cursor: pointer;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    box-shadow:
        0 0 0 2px #0c3c11,
        0 7px 14px rgba(0,0,0,0.8);
    transition: transform 0.05s ease-out, box-shadow 0.05s ease-out, filter 0.1s;
}

.rspokies-spin-button:hover,
#rspokies-spin-button:hover {
    filter: brightness(1.1);
}

.rspokies-spin-button:active,
#rspokies-spin-button:active {
    transform: translateY(1px);
    box-shadow:
        0 0 0 2px #0c3c11,
        0 3px 6px rgba(0,0,0,0.7);
}

.rspokies-spin-button:disabled,
#rspokies-spin-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ========== Status Bar ========== */

.rspokies-status-bar {
    margin-top: 0.2rem;
    padding: 0.3rem 0.4rem 0.1rem;
    border-radius: 8px;
    background: linear-gradient(180deg, #151515, #050505);
    box-shadow:
        inset 0 0 4px rgba(0,0,0,0.9),
        0 1px 0 rgba(255,255,255,0.06);
}

.rspokies-status,
#rspokies-status {
    font-size: 0.78rem;
    color: #e2e2e2;
}

/* Warning style for status */
.rspokies-status--warning {
    color: #ff8b8b;
}

/* ========== Rules / Paytable ========== */

.rspokies-rules {
    margin-top: 0.75rem;
    padding: 0.6rem 0.75rem;
    border-radius: 10px;
    background: #f7f7f7;
    border: 1px solid #e0e0e0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.03);
    font-size: 0.85rem;
    color: #333;
}

.rspokies-rules-title {
    font-weight: 600;
    margin-bottom: 0.3rem;
}

.rspokies-rules-list {
    margin: 0;
    padding-left: 1.1rem;
}

.rspokies-rules-list li {
    margin: 0.15rem 0;
}

/* ========== Responsive Tweaks ========== */

@media (max-width: 480px) {
    .rspokies-game-container {
        max-width: 100%;
        padding: 0.25rem;
    }

    .rspokies-machine {
        border-radius: 14px;
        padding: 0.6rem 0.5rem 0.8rem;
    }

    .rspokies-reel {
        width: 70px;
        height: 135px;
    }

    .rspokies-symbol {
        font-size: 1.4rem;
        height: 45px;
    }

    .rspokies-controls-panel {
        flex-direction: column;
        align-items: stretch;
    }

    .rspokies-bet-controls {
        justify-content: center;
    }

    .rspokies-spin-button,
    #rspokies-spin-button {
        width: 100%;
        text-align: center;
    }
}
