* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    color-scheme: dark;
    --bg: #030014;
    --bg-accent: #11052c;
    --card: rgba(15, 5, 40, 0.7);
    --glass-border: rgba(255, 255, 255, 0.08);
    --neon-pink: #ff3cac;
    --neon-cyan: #2ecae6;
    --neon-purple: #9b5cfa;
    --text-muted: rgba(255, 255, 255, 0.7);
    --success: #2ecc71;
    --warning: #f7b733;
    --reel-height: 180px;
}

body {
    font-family: 'Poppins', 'Noto Sans SC', system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, #040019 0%, #0c0426 40%, #1b053d 100%);
    color: #f6f4ff;
    padding: 48px 24px 72px;
}

.app-shell {
    width: min(1280px, 100%);
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.hero {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    padding: 32px 40px;
    border-radius: 24px;
    background: radial-gradient(circle at top left, rgba(255, 60, 172, 0.25), transparent 55%),
                radial-gradient(circle at top right, rgba(46, 202, 230, 0.18), transparent 45%),
                rgba(8, 3, 32, 0.75);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(18px);
    box-shadow: 0 20px 60px rgba(3, 0, 20, 0.6);
}

.hero-text h1 {
    font-size: clamp(2.4rem, 4vw, 3.2rem);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-shadow: 0 0 30px rgba(255, 60, 172, 0.4);
}

.subtitle {
    margin-top: 8px;
    color: var(--text-muted);
    max-width: 520px;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.35em;
    font-size: 0.75rem;
    color: var(--neon-cyan);
    margin-bottom: 6px;
}

.hero-credit {
    min-width: 220px;
    padding: 24px;
    border-radius: 18px;
    background: rgba(3, 150, 255, 0.08);
    border: 1px solid rgba(46, 202, 230, 0.35);
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.hero-credit span {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.hero-credit strong {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--neon-cyan);
}

.layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(320px, 1fr);
    gap: 32px;
    align-items: start;
}

.card {
    border-radius: 24px;
    background: var(--card);
    border: 1px solid var(--glass-border);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
    backdrop-filter: blur(18px);
}

.slot-panel {
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 28px;
    position: relative;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.panel-header h2,
.panel-header h3 {
    font-size: 1.45rem;
}

.status-pill {
    padding: 6px 14px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-size: 0.85rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.status-pill.ghost {
    border-color: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.45);
}

.status-pill.live-dot {
    width: 14px;
    height: 14px;
    padding: 0;
    border: none;
    background: radial-gradient(circle, #42ff85 0%, #00c853 60%, #009146 100%);
    box-shadow: 0 0 10px rgba(0, 255, 153, 0.8);
    animation: livePulse 1.6s ease-in-out infinite;
}

.status-pill.live-dot::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 20px rgba(0, 255, 153, 0.7);
    opacity: 0.6;
}

@keyframes livePulse {
    0%, 100% { transform: scale(0.9); opacity: 0.9; }
    50% { transform: scale(1.15); opacity: 1; }
}

.slot-window {
    position: relative;
    padding: 24px;
    border-radius: 18px;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.08), rgba(5, 0, 15, 0.9));
    border: 1px solid rgba(255, 255, 255, 0.06);
    overflow: hidden;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04), 0 20px 35px rgba(0, 0, 0, 0.55);
}

.slot-frame {
    border-radius: 16px;
    padding: 18px;
    background: linear-gradient(120deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0));
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.reels {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    height: var(--reel-height);
}

.reel {
    position: relative;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(245, 245, 255, 0.75));
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.15);
    box-shadow: inset 0 8px 18px rgba(5, 5, 5, 0.2);
}

.symbol-container {
    transition: transform 0.8s cubic-bezier(0.25, 0.75, 0.35, 1.1);
}

.symbol {
    height: var(--reel-height);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4.2rem;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.win-line {
    position: absolute;
    top: calc(50% + 8px);
    left: 24px;
    right: 24px;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, transparent, rgba(255, 0, 122, 0.8), transparent);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.9; }
}

.control-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.control-card {
    padding: 18px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.progress-card {
    grid-column: span 2;
}

.progress-track {
    width: 100%;
    height: 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--neon-cyan), var(--neon-purple));
    transition: width 0.4s ease;
}

.control-card .hint {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.bet-control select {
    width: 100%;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: linear-gradient(145deg, rgba(18, 12, 42, 0.95), rgba(43, 24, 78, 0.85));
    color: #f8f6ff;
    font-size: 1rem;
    appearance: none;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.05);
    font-weight: 600;
    letter-spacing: 0.05em;
    padding-right: 44px;
    background-image: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0)), url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath fill='%23f7f2ff' d='M1 1l5 6 5-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left top, right 16px center;
    background-size: auto, 12px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.bet-control select option {
    color: #fefbff;
    background-color: #0f0821;
}

.bet-control select:hover {
    border-color: rgba(255, 255, 255, 0.35);
    box-shadow: 0 0 12px rgba(255, 60, 172, 0.15), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.bet-control select:focus-visible {
    outline: none;
    border-color: var(--neon-cyan);
    box-shadow: 0 0 0 3px rgba(46, 202, 230, 0.25), inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.bet-control select::-ms-expand {
    display: none;
}

.label {
    font-size: 0.85rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.value {
    font-size: 1.4rem;
    font-weight: 600;
}

.spin-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 18px;
    background: linear-gradient(120deg, var(--neon-pink), var(--neon-purple));
    color: #fff;
    font-size: 1.2rem;
    font-weight: 600;
    padding: 22px;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.3s ease;
    box-shadow: 0 20px 45px rgba(255, 60, 172, 0.35);
}

.control-grid .spin-button {
    grid-column: span 2;
}

.spin-button:hover:not(:disabled) {
    transform: translateY(-3px) scale(1.01);
}

.spin-button:active:not(:disabled) {
    transform: translateY(1px) scale(0.99);
}

.spin-button:disabled {
    background: linear-gradient(120deg, #545068, #3a3450);
    box-shadow: none;
    cursor: not-allowed;
}

.spin-button .btn-text {
    display: block;
    font-size: 1rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.spin-button .btn-price {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
}

.cheat-hint .value {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.reward-feed {
    margin-top: 18px;
    padding: 20px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.panel-header.compact h3 {
    font-size: 1.1rem;
}

.reward-history {
    list-style: none;
    margin-top: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.reward-history li {
    padding: 12px 16px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.95rem;
}

.reward-history .placeholder {
    justify-content: center;
    color: var(--text-muted);
}

.info-panel {
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.paytable {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.paytable-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: border-color 0.3s ease, transform 0.2s ease;
}

.paytable-row:hover {
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.symbols {
    font-size: 1.1rem;
    letter-spacing: 0.08em;
}

.payout {
    font-weight: 600;
    color: var(--neon-cyan);
}

.meta-panel {
    padding: 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.15);
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-muted);
}

.message {
    position: fixed;
    right: 56px;
    bottom: 56px;
    transform: translateY(20px);
    padding: 22px 36px;
    border-radius: 18px;
    background: rgba(5, 0, 15, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.25);
    font-size: 1.1rem;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 100;
}

.message.show {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0);
}

.message.win {
    border-color: var(--success);
    color: var(--success);
}

.message.jackpot {
    border-color: var(--warning);
    color: var(--warning);
    box-shadow: 0 0 25px rgba(247, 183, 51, 0.5);
}

@media (max-width: 960px) {
    body {
        padding: 32px 16px 56px;
    }

    .hero {
        flex-direction: column;
    }

    .hero-credit {
        align-self: flex-start;
        text-align: left;
    }

    .layout {
        grid-template-columns: 1fr;
    }

    .control-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }

    .control-grid .spin-button {
        grid-column: span 1;
    }
}

@media (max-width: 640px) {
    :root {
        --reel-height: 140px;
    }

    body {
        padding: 24px 16px;
    }

    .slot-panel,
    .info-panel,
    .hero {
        padding: 20px;
    }

    .symbol {
        font-size: 3rem;
    }
}
