/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background: 
        radial-gradient(circle at 20% 50%, rgba(120, 0, 0, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(0, 0, 0, 0.4) 0%, transparent 50%),
        linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 50%, #0a0a0a 100%);
    min-height: 100vh;
    color: white;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 2px,
            rgba(255, 215, 0, 0.03) 2px,
            rgba(255, 215, 0, 0.03) 4px
        );
    pointer-events: none;
    z-index: -1;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 30px;
}

.title {
    font-size: 3rem;
    font-weight: 900;
    color: #ffd700;
    text-shadow: 
        0 0 10px #ffd700,
        0 0 20px #ffd700,
        0 0 30px #ffd700,
        2px 2px 4px rgba(0, 0, 0, 0.8);
    margin-bottom: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    animation: neonGlow 2s ease-in-out infinite alternate;
}

@keyframes neonGlow {
    from { 
        text-shadow: 
            0 0 10px #ffd700,
            0 0 20px #ffd700,
            0 0 30px #ffd700,
            2px 2px 4px rgba(0, 0, 0, 0.8);
    }
    to { 
        text-shadow: 
            0 0 15px #ffd700,
            0 0 25px #ffd700,
            0 0 35px #ffd700,
            0 0 45px #ffd700,
            2px 2px 4px rgba(0, 0, 0, 0.8);
    }
}

/* Game Container */
.game-container {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.main-slot-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.side-panel {
    width: 300px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: sticky;
    top: 20px;
}

/* Stats Container */
.stats-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: linear-gradient(145deg, #2a2a2a, #1a1a1a);
    padding: 20px;
    border-radius: 15px;
    border: 3px solid #ffd700;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 20px rgba(255, 215, 0, 0.3);
    position: relative;
}

.stats-container::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ffd700, #ff6b6b, #4ecdc4, #ffd700);
    border-radius: 17px;
    z-index: -1;
    opacity: 0.7;
}

.stat-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 1;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #ccc;
}

.stat-value {
    font-size: 1.4rem;
    font-weight: 900;
    color: #ffd700;
    text-shadow: 
        0 0 10px #ffd700,
        0 0 20px #ffd700;
    font-family: 'Courier New', monospace;
}

/* Slot Machine */
.slot-machine {
    background: linear-gradient(145deg, #1a1a1a, #2a2a2a);
    border-radius: 20px;
    padding: 35px;
    box-shadow: 
        0 20px 50px rgba(0, 0, 0, 0.7),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 30px rgba(255, 215, 0, 0.4);
    border: 4px solid #ffd700;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.slot-machine::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 30% 70%, rgba(255, 215, 0, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 70% 30%, rgba(255, 107, 107, 0.1) 0%, transparent 50%);
    border-radius: 20px;
    z-index: 0;
}

.slot-machine::after {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    right: -3px;
    bottom: -3px;
    background: linear-gradient(45deg, #ffd700, #ff6b6b, #4ecdc4, #45b7d1, #ffd700);
    background-size: 400% 400%;
    border-radius: 23px;
    z-index: -1;
    animation: borderGlow 3s ease-in-out infinite;
    opacity: 0.8;
}

@keyframes borderGlow {
    0%, 100% { background-position: 0% 50%; opacity: 0.8; }
    50% { background-position: 100% 50%; opacity: 1; }
}

.reels-container {
    display: flex;
    gap: 15px;
    background: linear-gradient(145deg, #000000, #1a1a1a);
    padding: 25px;
    border-radius: 15px;
    border: 3px solid #ffd700;
    position: relative;
    z-index: 1;
    box-shadow: 
        inset 0 4px 8px rgba(0, 0, 0, 0.8),
        0 4px 8px rgba(0, 0, 0, 0.5);
}

.reel {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: linear-gradient(180deg, #2a2a2a, #1a1a1a);
    padding: 20px;
    border-radius: 12px;
    border: 3px solid #ffd700;
    min-width: 90px;
    min-height: 260px;
    position: relative;
    box-shadow: 
        inset 0 4px 8px rgba(0, 0, 0, 0.6),
        0 4px 8px rgba(0, 0, 0, 0.4),
        0 0 15px rgba(255, 215, 0, 0.3);
    transition: all 0.3s ease;
}

.reel:hover {
    border-color: #ffed4e;
    box-shadow: 
        inset 0 4px 8px rgba(0, 0, 0, 0.6),
        0 6px 12px rgba(0, 0, 0, 0.4),
        0 0 20px rgba(255, 215, 0, 0.5);
}

.symbol {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    height: 70px;
    background: linear-gradient(145deg, #ffffff, #f0f0f0);
    border-radius: 10px;
    border: 2px solid #ddd;
    transition: all 0.3s ease;
    user-select: none;
    position: relative;
    overflow: hidden;
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.symbol::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    transition: left 0.5s ease;
}

.symbol:hover::before {
    left: 100%;
}

.symbol.winning {
    animation: winPulse 0.8s ease-in-out 3;
    background: linear-gradient(145deg, #ffd700, #ffed4e);
    border-color: #ff6b6b;
    transform: scale(1.2);
    box-shadow: 
        0 10px 20px rgba(255, 215, 0, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.9),
        0 0 30px rgba(255, 215, 0, 0.8);
}

@keyframes winPulse {
    0%, 100% { transform: scale(1.2); }
    50% { transform: scale(1.4); }
}

.symbol.spinning {
    animation: spin 0.1s linear infinite;
    background: linear-gradient(145deg, #e0e0e0, #d0d0d0);
}

@keyframes spin {
    0% { transform: translateY(-100%) rotateX(90deg); opacity: 0; }
    50% { transform: translateY(0) rotateX(0deg); opacity: 1; }
    100% { transform: translateY(100%) rotateX(-90deg); opacity: 0; }
}

/* Win Lines */
.win-lines {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 2;
}

.win-line {
    position: absolute;
    height: 8px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 215, 0, 0.4) 20%, 
        #ffd700 50%, 
        rgba(255, 215, 0, 0.4) 80%, 
        transparent 100%);
    border-radius: 4px;
    opacity: 0;
    transition: all 0.3s ease;
    box-shadow: 
        0 0 15px rgba(255, 215, 0, 0.7),
        0 0 30px rgba(255, 215, 0, 0.5);
}

.win-line.active {
    opacity: 1;
    animation: lineGlow 2s ease-in-out infinite;
}

@keyframes lineGlow {
    0%, 100% { 
        opacity: 0.9; 
        box-shadow: 
            0 0 15px rgba(255, 215, 0, 0.7),
            0 0 30px rgba(255, 215, 0, 0.5);
    }
    50% { 
        opacity: 1; 
        box-shadow: 
            0 0 25px rgba(255, 215, 0, 1),
            0 0 50px rgba(255, 215, 0, 0.8),
            0 0 75px rgba(255, 215, 0, 0.6);
    }
}

#line-1 { top: 33%; left: 0; right: 0; }
#line-2 { top: 50%; left: 0; right: 0; }
#line-3 { top: 67%; left: 0; right: 0; }

/* Controls */
.controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.bet-controls {
    display: flex;
    align-items: center;
    gap: 15px;
    background: linear-gradient(145deg, #2a2a2a, #1a1a1a);
    padding: 15px;
    border-radius: 15px;
    border: 3px solid #ffd700;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 20px rgba(255, 215, 0, 0.3);
}

.bet-display {
    font-size: 1.3rem;
    font-weight: 900;
    color: #ffd700;
    min-width: 80px;
    text-align: center;
    text-shadow: 
        0 0 10px #ffd700,
        0 0 20px #ffd700;
    font-family: 'Courier New', monospace;
}

.auto-controls {
    display: flex;
    gap: 10px;
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 900;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
    font-family: 'Arial', sans-serif;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.btn-primary {
    background: linear-gradient(145deg, #ff6b6b, #ee5a52);
    color: white;
    box-shadow: 
        0 8px 25px rgba(255, 107, 107, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(145deg, #ee5a52, #d63031);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 12px 35px rgba(255, 107, 107, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.btn-secondary {
    background: linear-gradient(145deg, #4ecdc4, #44a08d);
    color: white;
    box-shadow: 
        0 8px 25px rgba(78, 205, 196, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover:not(:disabled) {
    background: linear-gradient(145deg, #44a08d, #2d3436);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 12px 35px rgba(78, 205, 196, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.btn-spin {
    font-size: 1.5rem;
    padding: 15px 40px;
    background: linear-gradient(145deg, #ffd700, #ffed4e);
    color: #1a1a1a;
    box-shadow: 
        0 15px 40px rgba(255, 215, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    border: 3px solid rgba(255, 255, 255, 0.3);
    font-weight: 900;
    letter-spacing: 2px;
}

.btn-spin:hover:not(:disabled) {
    background: linear-gradient(145deg, #ffed4e, #ffd700);
    transform: translateY(-3px) scale(1.05);
    box-shadow: 
        0 20px 50px rgba(255, 215, 0, 0.7),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    color: #000;
}

.btn-spin:active:not(:disabled) {
    transform: translateY(-1px) scale(1.02);
}

/* Paytable */
.paytable {
    background: linear-gradient(145deg, #2a2a2a, #1a1a1a);
    padding: 20px;
    border-radius: 15px;
    border: 3px solid #ffd700;
    box-shadow: 
        0 10px 30px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 0 20px rgba(255, 215, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.paytable::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #ffd700, #ff6b6b, #4ecdc4, #ffd700);
    border-radius: 17px;
    z-index: -1;
    opacity: 0.7;
}

.paytable h3 {
    text-align: center;
    margin-bottom: 15px;
    color: #ffd700;
    font-size: 1.2rem;
    font-weight: 700;
    position: relative;
    z-index: 1;
    text-shadow: 0 0 10px #ffd700;
}

.paytable-grid {
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    z-index: 1;
}

.paytable-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.paytable-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.paytable-item .symbol {
    font-size: 1.1rem;
    background: none;
    border: none;
    padding: 0;
    height: auto;
}

.paytable-item .payout {
    font-weight: 700;
    color: #f1c40f;
    font-size: 1rem;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .game-container {
        flex-direction: column;
        align-items: center;
    }
    
    .side-panel {
        width: 100%;
        max-width: 500px;
        position: static;
    }
    
    .stats-container {
        flex-direction: row;
        gap: 30px;
    }
    
    .paytable-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .title {
        font-size: 2rem;
    }
    
    .game-container {
        gap: 20px;
    }
    
    .stats-container {
        flex-direction: column;
        gap: 15px;
    }
    
    .reels-container {
        padding: 15px;
        gap: 8px;
    }
    
    .reel {
        min-width: 60px;
        min-height: 180px;
        padding: 10px;
    }
    
    .symbol {
        font-size: 1.8rem;
        height: 45px;
    }
    
    .controls {
        gap: 15px;
    }
    
    .bet-controls {
        flex-direction: column;
        gap: 10px;
    }
    
    .auto-controls {
        flex-direction: column;
        gap: 10px;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
    
    .btn-spin {
        font-size: 1.1rem;
        padding: 12px 30px;
    }
    
    .paytable-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .title {
        font-size: 1.5rem;
    }
    
    .reel {
        min-width: 50px;
        min-height: 150px;
        padding: 8px;
    }
    
    .symbol {
        font-size: 1.5rem;
        height: 35px;
    }
    
    .paytable-grid {
        grid-template-columns: 1fr;
    }
}

/* Loading Animation */
.loading {
    opacity: 0.7;
    pointer-events: none;
}

/* Win Animation */
@keyframes celebrate {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.celebrating {
    animation: celebrate 0.5s ease-in-out 3;
}

/* Money Transfer Animations */
@keyframes moneyTransfer {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes balanceIncrease {
    0% {
        transform: scale(1);
        text-shadow: 0 0 10px #ffd700, 0 0 20px #ffd700;
    }
    50% {
        transform: scale(1.05);
        text-shadow: 0 0 15px #ffd700, 0 0 25px #ffd700, 0 0 35px #ffd700;
    }
    100% {
        transform: scale(1);
        text-shadow: 0 0 10px #ffd700, 0 0 20px #ffd700;
    }
}

.transferring {
    animation: moneyTransfer 1.5s ease-in-out;
}

.balance-increasing {
    animation: balanceIncrease 1.5s ease-in-out;
} 