/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Pokémon Background */
.pokemon-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

.pokeball-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.stars {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(2px 2px at 20px 30px, #eee, transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(255,255,255,0.8), transparent),
        radial-gradient(1px 1px at 90px 40px, #fff, transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(255,255,255,0.6), transparent),
        radial-gradient(2px 2px at 160px 30px, #ddd, transparent);
    background-repeat: repeat;
    background-size: 200px 100px;
    animation: sparkle 3s linear infinite;
}

@keyframes float {
    0%, 100% { transform: translate(-50%, -50%) rotate(0deg); }
    50% { transform: translate(-50%, -50%) rotate(180deg); }
}

@keyframes sparkle {
    0% { transform: translateY(0px); }
    100% { transform: translateY(-100px); }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
.header {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border-bottom: 3px solid #ffd700;
    padding: 2rem 0;
    text-align: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    animation: shine 3s infinite;
}

@keyframes shine {
    0% { left: -100%; }
    100% { left: 100%; }
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.pokeball-logo {
    position: relative;
    width: 80px;
    height: 80px;
    animation: bounce 2s infinite;
    display: flex;
    align-items: center;
    justify-content: center;
}

.pokeball-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 50%;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0); }
    40% { transform: translateY(-10px); }
    60% { transform: translateY(-5px); }
}

.logo {
    font-family: 'Press Start 2P', cursive;
    font-size: 2.5rem;
    font-weight: 400;
    text-shadow: 3px 3px 0px #000, 6px 6px 0px rgba(0,0,0,0.3);
    color: #ffd700;
    margin: 0;
}

.subtitle {
    font-size: 1.2rem;
    font-weight: 500;
    opacity: 0.9;
    margin-bottom: 1rem;
}

.pikachu-animation {
    font-size: 2rem;
    animation: lightning 1.5s infinite;
}

@keyframes lightning {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(1.2); }
}

/* Main Content */
.main {
    padding: 3rem 0;
}

/* Console Section */
.console-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 25px;
    padding: 2.5rem;
    margin-bottom: 3rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border: 3px solid transparent;
    background-clip: padding-box;
    position: relative;
    overflow: hidden;
}

.console-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57);
    background-size: 400% 400%;
    animation: gradientShift 8s ease infinite;
    z-index: -1;
    margin: -3px;
    border-radius: 25px;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.console-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 3px solid #ffd700;
    position: relative;
}

.console-icon {
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 20px;
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
    animation: pulse 2s infinite;
    padding: 12px;
    margin-top: 10px;
}

.console-icon-img {
    width: 130%;
    height: 130%;
    object-fit: contain;
    filter: brightness(1.2) contrast(1.1);
    margin-top: 20px;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

.console-info h2 {
    font-family: 'Press Start 2P', cursive;
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 0.5rem;
    text-shadow: 2px 2px 0px rgba(0,0,0,0.1);
}

.console-year {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-block;
}

/* Games Grid */
.games-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
}

/* Game Card */
.game-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    transition: all 0.4s ease;
    border: 3px solid transparent;
    position: relative;
}

.game-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    border-color: #ffd700;
}

.game-jacket {
    width: 100%;
    height: 350px;
    overflow: hidden;
    position: relative;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border: 4px solid #ffd700;
    border-radius: 15px;
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.game-jacket:hover {
    border-color: #ff6b6b;
    box-shadow: 
        0 12px 35px rgba(0, 0, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
}

.game-jacket img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
    border-radius: 10px;
}

.game-card:hover .game-jacket img {
    transform: scale(1.1);
}

/* Style pour les images de fallback */
.game-jacket img[style*="background"] {
    border-radius: 10px !important;
    font-family: 'Press Start 2P', cursive !important;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5) !important;
    letter-spacing: 1px !important;
    text-align: center !important;
    line-height: 1.2 !important;
    padding: 20px !important;
    box-sizing: border-box !important;
}

.game-info {
    padding: 1.5rem;
    text-align: center;
}

.game-info h3 {
    font-family: 'Press Start 2P', cursive;
    font-size: 1.2rem;
    color: #333;
    margin-bottom: 0.5rem;
    text-shadow: 1px 1px 0px rgba(0,0,0,0.1);
}

.game-info p {
    color: #666;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.game-stats {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    gap: 1rem;
}

.type {
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.type.fire { background: linear-gradient(135deg, #ff6b6b, #ee5a24); color: white; }
.type.water { background: linear-gradient(135deg, #74b9ff, #0984e3); color: white; }
.type.electric { background: linear-gradient(135deg, #fdcb6e, #e17055); color: white; }
.type.ice { background: linear-gradient(135deg, #81ecec, #00cec9); color: white; }
.type.grass { background: linear-gradient(135deg, #55efc4, #00b894); color: white; }

.year {
    background: rgba(0, 0, 0, 0.1);
    padding: 0.3rem 0.8rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 600;
    color: #666;
}

/* Download Button */
.download-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    text-decoration: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
}

.download-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.download-btn:hover::before {
    left: 100%;
}

.download-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
    background: linear-gradient(135deg, #ee5a24, #ff6b6b);
}

.download-btn i {
    font-size: 1rem;
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.9);
    color: white;
    text-align: center;
    padding: 2rem 0;
    margin-top: 3rem;
    border-top: 3px solid #ffd700;
}

.footer p {
    margin-bottom: 0.5rem;
    opacity: 0.8;
    font-size: 0.9rem;
}

.footer i {
    color: #ffd700;
    margin-right: 0.5rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .logo {
        font-size: 1.8rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .console-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .console-info h2 {
        font-size: 1.2rem;
    }
    
    .console-icon {
        font-size: 2rem;
        width: 60px;
        height: 60px;
    }
    
    .games-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .game-jacket {
        height: 250px;
    }
    
    .container {
        padding: 0 15px;
    }
    
    .console-section {
        padding: 1.5rem;
        margin-bottom: 2rem;
    }
}

@media (max-width: 480px) {
    .header {
        padding: 1.5rem 0;
    }
    
    .logo {
        font-size: 1.4rem;
    }
    
    .main {
        padding: 2rem 0;
    }
    
    .console-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .game-jacket {
        height: 200px;
    }
    
    .game-info {
        padding: 1rem;
    }
    
    .game-info h3 {
        font-size: 1rem;
    }
    
    .download-btn {
        padding: 0.8rem 1.5rem;
        font-size: 0.8rem;
    }
}

/* Animation for page load */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.console-section {
    animation: fadeInUp 0.8s ease-out;
}

.game-card {
    animation: fadeInUp 0.8s ease-out;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    border-radius: 6px;
    border: 2px solid rgba(255, 255, 255, 0.1);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #ee5a24, #ff6b6b);
}

/* Search and Filter Styles (from JavaScript) */
.search-container {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
}

.search-box {
    position: relative;
    max-width: 500px;
    width: 100%;
}

.search-box i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #ffd700;
    font-size: 1.2rem;
    z-index: 2;
}

.search-box input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    border: 3px solid rgba(255, 215, 0, 0.3);
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.95);
    font-size: 1rem;
    outline: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.search-box input:focus {
    border-color: #ffd700;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.3);
    background: white;
}

.clear-search {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 50%;
    transition: all 0.3s ease;
    z-index: 2;
}

.clear-search:hover {
    background: rgba(255, 107, 107, 0.1);
    color: #ff6b6b;
}

.filter-container {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
}

.filter-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    background: rgba(255, 255, 255, 0.95);
    border: 3px solid rgba(255, 215, 0, 0.3);
    color: #333;
    padding: 0.8rem 1.5rem;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.filter-btn:hover {
    background: rgba(255, 215, 0, 0.1);
    transform: translateY(-2px);
    border-color: #ffd700;
}

.filter-btn.active {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    color: white;
    border-color: #ff6b6b;
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
}

.game-card.hidden {
    display: none;
}

.console-section.hidden {
    display: none;
}

/* Download notification */
.download-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #00b894, #00a085);
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0, 184, 148, 0.3);
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

/* Ripple effect */
.download-btn {
    position: relative;
    overflow: hidden;
}

.ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    transform: scale(0);
    animation: ripple-animation 0.6s linear;
    pointer-events: none;
}

@keyframes ripple-animation {
    to {
        transform: scale(4);
        opacity: 0;
    }
}




.download-btn {
    background: linear-gradient(135deg, #ff3e3e, #ff8f3e);
    color: white;
    padding: 15px 30px 15px 50px; /* marge gauche augmentée pour la flèche */
    font-size: 18px;
    font-weight: bold;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    box-shadow: 0 8px 15px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    text-decoration: none;
    position: relative;
    display: inline-block;
}

.download-btn::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    background-image: url('https://raw.githubusercontent.com/SROff23712/image/refs/heads/main/97607%20(1).png');
    background-size: contain;
    background-repeat: no-repeat;
    position: absolute;
    left: 15px; /* position à gauche */
    top: 50%;
    transform: translateY(-50%);
    transition: transform 0.3s ease;
}

.download-btn:hover::before {
    transform: translateY(-50%) translateY(3px); /* petite animation */
}

.download-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 20px rgba(0,0,0,0.3);
}

.download-btn:active {
    transform: translateY(1px);
    box-shadow: 0 6px 10px rgba(0,0,0,0.2);
}
