/* dex/css/enhanced.css */
/* Add these rules or ensure they exist */

/* ... other styles in enhanced.css ... */


/* ==========================================================================
   Breathing/Glow Effect for Grid Cards
   ========================================================================== */

   @keyframes pokedexCardBreathe {
    0%, 100% {
        box-shadow: 0 3px 6px rgba(0,0,0,0.2), /* Base shadow */
                    0 0 8px 2px rgba(var(--breathe-glow-color-rgb, 59, 130, 246), 0.4); /* Subtle glow - Fallback blue */
        transform: scale(1);
    }
    50% {
         box-shadow: 0 6px 12px rgba(0,0,0,0.25), /* Slightly larger base shadow */
                    0 0 15px 5px rgba(var(--breathe-glow-color-rgb, 59, 130, 246), 0.6); /* Brighter/larger glow */
        transform: scale(1.015); /* Slight scale pulse */
    }
}

/* Ensure base card resets animation */
.pokedex-grid-card {
    position: relative; /* Needed for shadow positioning */
    animation: none; /* Reset base animation */
}

/* Apply animation when .breathing class is added */
.pokedex-grid-card.breathing {
    animation: pokedexCardBreathe 2.5s ease-in-out infinite alternate;
    border-color: var(--breathe-glow-color, var(--color-accent)); /* Match border to glow */
    /* Ensure it's visible if opacity was used before */
    opacity: 1 !important;
}

/* Re-apply fade-in animation if needed */
.pokedex-grid-card.animated {
     animation: fadeInCard var(--animation-speed-normal) cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
     /* Apply animation delay based on nth-child */
}
/* Re-add nth-child delays if they were removed from dex.css/enhanced.css */
.pokedex-grid-card:nth-child(6n+1) { animation-delay: 0.05s; }
.pokedex-grid-card:nth-child(6n+2) { animation-delay: 0.1s; }
.pokedex-grid-card:nth-child(6n+3) { animation-delay: 0.15s; }
.pokedex-grid-card:nth-child(6n+4) { animation-delay: 0.2s; }
.pokedex-grid-card:nth-child(6n+5) { animation-delay: 0.25s; }
.pokedex-grid-card:nth-child(6n+6) { animation-delay: 0.3s; }

/* Ensure fadeInCard keyframes exist in one of your CSS files */
@keyframes fadeInCard {
    from { opacity: 0; transform: translateY(10px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
/* Neon Glow Effect Keyframes */
@keyframes neonGlow {
    0%, 100% {
        box-shadow: 0 0 8px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.5),
                    0 0 15px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.3);
    }
    50% {
        box-shadow: 0 0 12px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.8),
                    0 0 20px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.6);
    }
}/* Apply glow to selected elements */
.selected, .glowing {
    animation: neonGlow 1.5s ease-in-out infinite alternate;
    border-color: var(--neon-glow-color, var(--color-accent));
    box-shadow: 0 0 8px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.5),
                0 0 15px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.3);
}

/* Glow for dex cards */
.pokedex-grid-card.selected {
    animation: neonGlow 2s ease-in-out infinite alternate;
    border: 2px solid var(--neon-glow-color, var(--color-accent));
}

/* Glow for buttons */
button.selected, .button-glow {
    animation: neonGlow 1.5s ease-in-out infinite alternate;
    border: 2px solid var(--neon-glow-color, var(--color-accent));
    box-shadow: 0 0 10px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.6);
}

/* Glow for icons */
.icon-glow {
    animation: neonGlow 1.5s ease-in-out infinite alternate;
    color: var(--neon-glow-color, var(--color-accent));
    text-shadow: 0 0 8px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.5),
                 0 0 15px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.3);
}

/* Glow for borders and boxes */
.box-glow {
    animation: neonGlow 2s ease-in-out infinite alternate;
    border: 2px solid var(--neon-glow-color, var(--color-accent));
    box-shadow: 0 0 12px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.6),
                0 0 20px rgba(var(--neon-glow-color-rgb, 255, 255, 255), 0.4);
}:root {
    --neon-glow-color: #3b82f6; /* Default blue glow */
    --neon-glow-color-rgb: 59, 130, 246; /* RGB for blue glow */
}@keyframes pokedexCardBreathe {
    0%, 100% {
        box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2),
                    0 0 8px 2px rgba(var(--breathe-glow-color-rgb, 59, 130, 246), 0.4);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 6px 12px rgba(0, 0, 0, 0.25),
                    0 0 15px 5px rgba(var(--breathe-glow-color-rgb, 59, 130, 246), 0.6);
        transform: scale(1.015);
    }
}

.breathing {
    animation: pokedexCardBreathe 2.5s ease-in-out infinite alternate;
    border-color: var(--breathe-glow-color, var(--color-accent));
}