/* ===========================
   Animated Slot Symbol Styles
   =========================== */

/* Base SVG symbol styling */
.slot-symbol-svg {
    width: 110px;
    height: 110px;
    display: block;
    margin: auto;
    transition: transform 0.3s ease;
}

/* Ensure symbols fill the reel cell */
.reel-symbol {
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: visible;
    padding: 5px;
    box-sizing: border-box;
}

/* ===========================
   SEVEN Symbol - The Jackpot
   =========================== */
.slot-symbol-svg.seven .seven-text {
    transform-origin: center;
    text-shadow: 0 0 10px rgba(255, 0, 0, 0.8);
}

.slot-symbol-svg.seven .seven-sparkle {
    animation: sparkleFloat 2s ease-in-out infinite;
    filter: drop-shadow(0 0 4px #ffff00);
}

.slot-symbol-svg.seven .seven-sparkle.s1 { animation-delay: 0s; }
.slot-symbol-svg.seven .seven-sparkle.s2 { animation-delay: 0.4s; }
.slot-symbol-svg.seven .seven-sparkle.s3 { animation-delay: 0.8s; }

@keyframes sparkleFloat {
    0%, 100% { 
        opacity: 0.4; 
        transform: scale(0.8); 
    }
    50% { 
        opacity: 1; 
        transform: scale(1.3); 
    }
}

/* ===========================
   DIAMOND Symbol - The Wild
   =========================== */
.slot-symbol-svg.diamond .diamond-shape {
    animation: diamondRotate 10s linear infinite;
    transform-origin: center;
    filter: drop-shadow(0 0 8px rgba(0, 255, 255, 0.6));
}

.slot-symbol-svg.diamond .diamond-inner {
    animation: diamondPulse 2s ease-in-out infinite;
}

.slot-symbol-svg.diamond .diamond-shine {
    animation: shineFlicker 3s ease-in-out infinite;
}

@keyframes diamondRotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes diamondPulse {
    0%, 100% { opacity: 0.2; }
    50% { opacity: 0.5; }
}

@keyframes shineFlicker {
    0%, 100% { opacity: 0.9; stroke-width: 3px; }
    50% { opacity: 0.4; stroke-width: 5px; }
}

/* ===========================
   STAR Symbol
   =========================== */
.slot-symbol-svg.star .star-shape {
    animation: starTwinkle 2.5s ease-in-out infinite;
    transform-origin: center;
    filter: drop-shadow(0 0 6px rgba(255, 204, 0, 0.7));
}

.slot-symbol-svg.star .star-center {
    animation: starCenterPulse 1.5s ease-in-out infinite;
}

@keyframes starTwinkle {
    0%, 100% { 
        transform: scale(1) rotate(0deg); 
    }
    25% { 
        transform: scale(1.05) rotate(3deg); 
    }
    75% { 
        transform: scale(1.05) rotate(-3deg); 
    }
}

@keyframes starCenterPulse {
    0%, 100% { opacity: 0.3; r: 10; }
    50% { opacity: 0.7; r: 14; }
}

/* ===========================
   BELL Symbol
   =========================== */
.slot-symbol-svg.bell .bell-body {
    animation: bellSwing 1.2s ease-in-out infinite;
    transform-origin: 50% 8px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.slot-symbol-svg.bell .bell-clapper {
    animation: clapperSwing 0.6s ease-in-out infinite;
    transform-origin: 50% -10px;
}

.slot-symbol-svg.bell .bell-shine {
    animation: bellShine 3s ease-in-out infinite;
}

@keyframes bellSwing {
    0%, 100% { transform: rotate(-2deg); }
    50% { transform: rotate(2deg); }
}

@keyframes clapperSwing {
    0%, 100% { transform: translateX(-2px); }
    50% { transform: translateX(2px); }
}

@keyframes bellShine {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

/* ===========================
   WATERMELON Symbol
   =========================== */
.slot-symbol-svg.watermelon .watermelon-flesh {
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.2));
}

.slot-symbol-svg.watermelon .seed {
    animation: seedBounce 1.2s ease-in-out infinite;
}

.slot-symbol-svg.watermelon .seed.s1 { animation-delay: 0s; }
.slot-symbol-svg.watermelon .seed.s2 { animation-delay: 0.15s; }
.slot-symbol-svg.watermelon .seed.s3 { animation-delay: 0.3s; }
.slot-symbol-svg.watermelon .seed.s4 { animation-delay: 0.45s; }
.slot-symbol-svg.watermelon .seed.s5 { animation-delay: 0.6s; }

@keyframes seedBounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}

/* ===========================
   CHERRY Symbol
   =========================== */
.slot-symbol-svg.cherry .cherry-left,
.slot-symbol-svg.cherry .cherry-right {
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.slot-symbol-svg.cherry .cherry-left {
    animation: cherryBounceLeft 1.8s ease-in-out infinite;
}

.slot-symbol-svg.cherry .cherry-right {
    animation: cherryBounceRight 1.8s ease-in-out infinite;
    animation-delay: 0.3s;
}

.slot-symbol-svg.cherry .cherry-leaf {
    animation: leafWiggle 2s ease-in-out infinite;
    transform-origin: center;
}

@keyframes cherryBounceLeft {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

@keyframes cherryBounceRight {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

@keyframes leafWiggle {
    0%, 100% { transform: rotate(-25deg); }
    50% { transform: rotate(-20deg); }
}

/* ===========================
   ORANGE Symbol
   =========================== */
.slot-symbol-svg.orange .orange-body {
    animation: orangePulse 2s ease-in-out infinite;
    filter: drop-shadow(0 3px 5px rgba(0, 0, 0, 0.25));
}

.slot-symbol-svg.orange .orange-leaf {
    animation: orangeLeafWave 2.5s ease-in-out infinite;
    transform-origin: 50% 100%;
}

@keyframes orangePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

@keyframes orangeLeafWave {
    0%, 100% { transform: rotate(0deg); }
    50% { transform: rotate(5deg); }
}

/* ===========================
   LEMON Symbol
   =========================== */
.slot-symbol-svg.lemon .lemon-body {
    animation: lemonRock 2.5s ease-in-out infinite;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.slot-symbol-svg.lemon .lemon-shine {
    animation: lemonShine 3s ease-in-out infinite;
}

.slot-symbol-svg.lemon .lemon-leaf {
    animation: lemonLeafBounce 1.5s ease-in-out infinite;
    transform-origin: 72% 22%;
}

@keyframes lemonRock {
    0%, 100% { transform: rotate(-15deg); }
    50% { transform: rotate(-12deg); }
}

@keyframes lemonShine {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}

@keyframes lemonLeafBounce {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

/* ===========================
   Win Animation Enhancements
   =========================== */
.reel-symbol[data-is-center="true"] .slot-symbol-svg {
    /* Center symbol is slightly larger */
    transform: scale(1.05);
}

/* Winning symbol pulse */
@keyframes winSymbolPulse {
    0% { 
        transform: scale(1); 
        filter: drop-shadow(0 0 0 transparent);
    }
    50% { 
        transform: scale(1.15); 
        filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.8));
    }
    100% { 
        transform: scale(1); 
        filter: drop-shadow(0 0 0 transparent);
    }
}

.win-glow + .slot-reel .reel-symbol[data-is-center="true"] .slot-symbol-svg,
.slot-reel-container.winning .reel-symbol[data-is-center="true"] .slot-symbol-svg {
    animation: winSymbolPulse 0.5s ease-in-out 3;
}

/* ===========================
   Spinning State - Blur symbols
   =========================== */
.spinning .slot-symbol-svg {
    filter: blur(2px);
    opacity: 0.7;
}

/* ===========================
   Responsive Adjustments
   =========================== */
@media (max-width: 768px) {
    .slot-symbol-svg {
        width: 80px;
        height: 80px;
    }
    
    .reel-symbol {
        width: 90px;
        height: 90px;
    }
}

@media (max-width: 480px) {
    .slot-symbol-svg {
        width: 60px;
        height: 60px;
    }
    
    .reel-symbol {
        width: 70px;
        height: 70px;
    }
}
