/* ===== BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(180deg, #1a0a2e 0%, #16213e 50%, #0f0f23 100%);
    min-height: 100vh;
    overflow-x: hidden;
    color: #fff;
}

/* ===== GAME CONTAINER ===== */
.game-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 10px;
    position: relative;
    min-height: 100vh;
}

/* ===== BACKGROUND EFFECTS ===== */
.bg-effects {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.lightning {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at top, rgba(255, 215, 0, 0.1) 0%, transparent 70%);
    animation: lightning 8s infinite;
}

@keyframes lightning {
    0%, 90%, 100% { opacity: 0.3; }
    92%, 94%, 96% { opacity: 1; }
}

.clouds {
    position: absolute;
    top: 0;
    width: 200%;
    height: 200px;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 20"><ellipse cx="20" cy="10" rx="15" ry="8" fill="rgba(255,255,255,0.05)"/><ellipse cx="50" cy="12" rx="20" ry="10" fill="rgba(255,255,255,0.03)"/><ellipse cx="80" cy="8" rx="12" ry="6" fill="rgba(255,255,255,0.04)"/></svg>');
    animation: moveClouds 60s linear infinite;
}

@keyframes moveClouds {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

/* ===== HEADER ===== */
.game-header {
    text-align: center;
    padding: 15px 0;
    position: relative;
    z-index: 1;
}

.logo h1 {
    font-size: 2rem;
    background: linear-gradient(180deg, #ffd700 0%, #ff8c00 50%, #ffd700 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
    letter-spacing: 3px;
    animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
    from { filter: drop-shadow(0 0 10px #ffd700); }
    to { filter: drop-shadow(0 0 25px #ff8c00); }
}

.subtitle {
    color: #87ceeb;
    font-size: 0.9rem;
    letter-spacing: 5px;
    margin-top: 5px;
}

/* ===== ZEUS CHARACTER ===== */
.zeus-container {
    position: absolute;
    right: -20px;
    top: 100px;
    z-index: 10;
}

.zeus {
    font-size: 4rem;
    filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.8));
    animation: zeusFloat 3s ease-in-out infinite;
    transition: transform 0.3s;
}

.zeus.excited {
    animation: zeusExcited 0.5s ease-in-out;
}

@keyframes zeusFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

@keyframes zeusExcited {
    0%, 100% { transform: scale(1) rotate(0deg); }
    25% { transform: scale(1.2) rotate(-10deg); }
    75% { transform: scale(1.2) rotate(10deg); }
}

/* ===== MAIN GAME AREA ===== */
.game-area {
    position: relative;
    z-index: 1;
}

/* ===== MULTIPLIER PANEL ===== */
.multiplier-panel {
    position: absolute;
    left: -60px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(180deg, #4a0080 0%, #2d004d 100%);
    border: 3px solid #ffd700;
    border-radius: 10px;
    padding: 15px 10px;
    text-align: center;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
    display: none;
}

.multiplier-panel.active {
    display: block;
    animation: pulseMultiplier 0.5s ease-out;
}

@keyframes pulseMultiplier {
    0% { transform: translateY(-50%) scale(0.8); }
    50% { transform: translateY(-50%) scale(1.1); }
    100% { transform: translateY(-50%) scale(1); }
}

.mult-label {
    display: block;
    font-size: 0.6rem;
    color: #ffd700;
    margin-bottom: 5px;
}

.mult-value {
    display: block;
    font-size: 1.5rem;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 0 10px #ffd700;
}

/* ===== SLOT FRAME ===== */
.slot-frame {
    background: linear-gradient(180deg, #1e0533 0%, #0d001a 100%);
    border: 4px solid;
    border-image: linear-gradient(180deg, #ffd700, #ff8c00, #ffd700) 1;
    border-radius: 15px;
    padding: 15px;
    position: relative;
    box-shadow:
        0 0 30px rgba(255, 215, 0, 0.3),
        inset 0 0 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
}

/* ===== SLOT GRID ===== */
.slot-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: repeat(5, 1fr);
    gap: 8px;
    padding: 10px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
}

/* ===== SYMBOL STYLES ===== */
.symbol {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    background: linear-gradient(180deg, rgba(255,255,255,0.1) 0%, rgba(0,0,0,0.2) 100%);
    border-radius: 10px;
    border: 2px solid rgba(255, 215, 0, 0.2);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.symbol::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255,255,255,0.1), transparent);
    transform: rotate(45deg);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%) rotate(45deg); }
    100% { transform: translateX(100%) rotate(45deg); }
}

/* Exit animation - symbols fly up */
.symbol.exit-up {
    animation: exitUp 0.3s ease-in forwards;
}

@keyframes exitUp {
    0% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translateY(-150%) scale(0.5);
        opacity: 0;
    }
}

/* Cascade in - symbols drop from above */
.symbol.cascade-in {
    animation: cascadeIn 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

@keyframes cascadeIn {
    0% {
        transform: translateY(-200%);
        opacity: 0;
    }
    60% {
        transform: translateY(10%);
        opacity: 1;
    }
    80% {
        transform: translateY(-5%);
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Winning symbols pulse */
.symbol.winning {
    animation: winPulse 0.4s ease-in-out infinite;
    border-color: #ffd700;
    box-shadow: 0 0 25px #ffd700, 0 0 50px rgba(255, 215, 0, 0.5);
    z-index: 5;
}

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

/* Exploding symbols */
.symbol.exploding {
    animation: explode 0.35s ease-out forwards;
}

@keyframes explode {
    0% {
        transform: scale(1);
        opacity: 1;
        filter: brightness(1);
    }
    30% {
        transform: scale(1.4);
        filter: brightness(2);
        box-shadow: 0 0 30px #ffd700, 0 0 60px #ff8c00;
    }
    100% {
        transform: scale(0);
        opacity: 0;
        filter: brightness(3);
    }
}

/* Hidden symbols */
.symbol.hidden {
    opacity: 0;
    visibility: hidden;
}

/* Dropping symbols - cascade down */
.symbol.dropping {
    animation: dropDown 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes dropDown {
    0% {
        transform: translateY(calc(var(--drop-distance, 1) * -100%));
        opacity: 0.5;
    }
    60% {
        opacity: 1;
    }
    80% {
        transform: translateY(8%);
    }
    90% {
        transform: translateY(-4%);
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Legacy spinning animation */
.symbol.spinning {
    animation: symbolSpin 0.1s linear infinite;
}

@keyframes symbolSpin {
    0% { transform: translateY(-100%); opacity: 0; }
    50% { opacity: 1; }
    100% { transform: translateY(100%); opacity: 0; }
}

/* Legacy falling animation */
.symbol.falling {
    animation: fall 0.4s ease-out forwards;
}

@keyframes fall {
    0% { transform: translateY(-100px); opacity: 0; }
    60% { transform: translateY(10px); }
    100% { transform: translateY(0); opacity: 1; }
}

/* ===== WIN OVERLAY ===== */
.win-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.7);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 20;
}

.win-overlay.active {
    opacity: 1;
    visibility: visible;
}

.win-amount {
    font-size: 3rem;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 20px #ffd700;
    animation: winBounce 0.5s ease-out;
}

@keyframes winBounce {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

/* ===== INFO PANEL ===== */
.info-panel {
    display: flex;
    justify-content: space-around;
    background: linear-gradient(180deg, #2d004d 0%, #1a002e 100%);
    border: 2px solid #ffd700;
    border-radius: 10px;
    padding: 15px;
    margin-top: 15px;
}

.info-item {
    text-align: center;
}

.info-item .label {
    display: block;
    font-size: 0.75rem;
    color: #87ceeb;
    margin-bottom: 5px;
}

.info-item .value {
    display: block;
    font-size: 1.3rem;
    font-weight: bold;
    color: #ffd700;
}

/* ===== CONTROLS ===== */
.controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.btn {
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-weight: bold;
    transition: all 0.2s;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(0);
}

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

/* Bet Controls */
.bet-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-bet {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(180deg, #4a0080 0%, #2d004d 100%);
    border: 2px solid #ffd700;
    color: #ffd700;
    font-size: 1.5rem;
}

.bet-display {
    background: rgba(0, 0, 0, 0.5);
    padding: 8px 20px;
    border-radius: 5px;
    text-align: center;
}

.bet-display span {
    display: block;
}

.bet-display span:first-child {
    font-size: 0.7rem;
    color: #87ceeb;
}

.bet-display span:last-child {
    color: #ffd700;
    font-weight: bold;
}

/* Spin Button */
.btn-spin {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(180deg, #ffd700 0%, #ff8c00 50%, #ffd700 100%);
    color: #1a0a2e;
    font-size: 1.2rem;
    box-shadow:
        0 0 30px rgba(255, 215, 0, 0.5),
        0 5px 15px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.btn-spin:hover {
    background: linear-gradient(180deg, #ffed4a 0%, #ffa500 50%, #ffed4a 100%);
    box-shadow: 0 0 50px rgba(255, 215, 0, 0.8);
}

.btn-spin.spinning {
    animation: spinButton 1s linear infinite;
}

@keyframes spinButton {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.spin-icon {
    font-size: 2rem;
}

/* Auto Controls */
.auto-controls {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-auto, .btn-turbo {
    padding: 10px 20px;
    border-radius: 5px;
    background: linear-gradient(180deg, #4a0080 0%, #2d004d 100%);
    border: 2px solid #87ceeb;
    color: #87ceeb;
    font-size: 0.9rem;
}

.btn-auto.active, .btn-turbo.active {
    background: linear-gradient(180deg, #00a0ff 0%, #0066cc 100%);
    border-color: #fff;
    color: #fff;
}

/* ===== POPUPS ===== */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-content {
    background: linear-gradient(180deg, #4a0080 0%, #1a002e 100%);
    border: 4px solid #ffd700;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    animation: popupBounce 0.5s ease-out;
    box-shadow: 0 0 50px rgba(255, 215, 0, 0.5);
}

@keyframes popupBounce {
    0% { transform: scale(0); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

.popup-zeus {
    font-size: 4rem;
    margin-bottom: 20px;
    animation: zeusExcited 1s ease-in-out infinite;
}

.popup-content h2 {
    font-size: 2.5rem;
    color: #ffd700;
    text-shadow: 0 0 20px #ffd700;
    margin-bottom: 15px;
}

.popup-content p {
    color: #87ceeb;
    margin: 10px 0;
}

.free-spins-count {
    font-size: 5rem;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 30px #ffd700;
    animation: countPulse 1s ease-in-out infinite;
}

@keyframes countPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.btn-start, .btn-continue {
    margin-top: 25px;
    padding: 15px 50px;
    font-size: 1.2rem;
    border-radius: 30px;
    background: linear-gradient(180deg, #ffd700 0%, #ff8c00 100%);
    color: #1a0a2e;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
}

/* Big Win Popup */
.popup-content.big-win h2 {
    font-size: 3rem;
    animation: rainbowText 2s linear infinite;
}

@keyframes rainbowText {
    0% { color: #ff0000; }
    17% { color: #ff8000; }
    33% { color: #ffff00; }
    50% { color: #00ff00; }
    67% { color: #0080ff; }
    83% { color: #8000ff; }
    100% { color: #ff0000; }
}

.big-win-amount {
    font-size: 4rem;
    font-weight: bold;
    color: #ffd700;
    text-shadow: 0 0 30px #ffd700;
    margin: 20px 0;
}

/* ===== FOOTER ===== */
.game-footer {
    text-align: center;
    padding: 20px;
    color: #666;
    font-size: 0.8rem;
    position: relative;
    z-index: 1;
}

/* ===== FREE SPINS MODE ===== */
.game-container.free-spins-mode .slot-frame {
    border-image: linear-gradient(180deg, #00ff00, #00cc00, #00ff00) 1;
    box-shadow: 0 0 50px rgba(0, 255, 0, 0.3);
}

.game-container.free-spins-mode .logo h1 {
    background: linear-gradient(180deg, #00ff00 0%, #00cc00 50%, #00ff00 100%);
    -webkit-background-clip: text;
    background-clip: text;
}

/* Free Spins Counter */
.free-spins-counter {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(180deg, #00ff00 0%, #00aa00 100%);
    padding: 10px 20px;
    border-radius: 10px;
    font-weight: bold;
    color: #fff;
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.5);
    z-index: 10;
}

/* ===== SCATTER SYMBOL HIGHLIGHT ===== */
.symbol.scatter {
    animation: scatterGlow 1s ease-in-out infinite;
}

@keyframes scatterGlow {
    0%, 100% {
        box-shadow: 0 0 20px #ffd700;
        transform: scale(1);
    }
    50% {
        box-shadow: 0 0 40px #ffd700;
        transform: scale(1.05);
    }
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .game-container {
        padding: 5px;
    }

    .logo h1 {
        font-size: 1.3rem;
    }

    .symbol {
        font-size: 1.8rem;
    }

    .zeus-container {
        display: none;
    }

    .multiplier-panel {
        left: 5px;
        top: 10px;
        transform: none;
        padding: 8px;
    }

    .btn-spin {
        width: 80px;
        height: 80px;
        font-size: 0.9rem;
    }

    .spin-icon {
        font-size: 1.5rem;
    }

    .info-item .value {
        font-size: 1rem;
    }

    .controls {
        gap: 10px;
    }

    .bet-controls {
        order: 1;
    }

    .btn-spin {
        order: 2;
    }

    .auto-controls {
        order: 3;
        flex-direction: row;
    }
}

@media (max-width: 480px) {
    .slot-grid {
        gap: 4px;
        padding: 5px;
    }

    .symbol {
        font-size: 1.4rem;
        border-radius: 5px;
    }

    .info-panel {
        padding: 10px;
    }

    .popup-content {
        padding: 25px;
        margin: 20px;
    }

    .popup-content h2 {
        font-size: 1.8rem;
    }

    .free-spins-count, .big-win-amount {
        font-size: 3rem;
    }
}

.symbol.exploding img{
    opacity:0;
}

.symbol img{
    width:100%;
    height:100%;
    object-fit:contain;
    pointer-events:none;
}

.drop{
animation:dropSymbol 0.35s ease;
}

@keyframes dropSymbol{

0%{
transform:translateY(-80px);
opacity:0;
}

100%{
transform:translateY(0);
opacity:1;
}

}

/* symbol base */
.symbol{
width:100%;
height:100%;
display:flex;
align-items:center;
justify-content:center;
transition:transform 0.25s ease, opacity 0.25s ease;
}

/* symbol image */
.symbol img{
width:100%;
height:100%;
object-fit:contain;
pointer-events:none;
}

