/* 1. RESET & CONFIGURATION GLOBALE*/
   *,
   *::after,
   *::before {
       box-sizing: border-box;
       margin: 0;
       padding: 0;
   }
   
   body {
       font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
       background-color: #0f172a;
       color: #f8fafc;
       line-height: 1.6;
   }
   
   .container {
    width: 95%;
    margin: 0 auto;
    max-width: 1400px;
    }
   
   /* 2. HEADER & NAVIGATION*/
   header {
       background-color: black;
       padding: 1.5rem 0;
       border-bottom: 2px solid #00d2ff;
   }
   
   .navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 95%;
    margin: 0 auto;
    }
   
   .logo { 
       font-size: 1.8rem; 
       font-weight: bold; 
       color: #f8fafc;
   }
   
   .logo span { 
       color: #00d2ff; 
   }
   
   .nav-links {
       list-style: none;
       display: flex;
       align-items: center;
       margin: 0;
       padding: 0;
   }
   
   .nav-links > li { 
       margin-left: 30px; 
       position: relative; 
   }
   
   .nav-links a {
       text-decoration: none;
       color: #f8fafc;
       font-weight: 500;
       transition: 0.3s ease;
   }
   
   .nav-links a:hover, 
   .nav-links a.active { 
       color: #00d2ff; 
   }
   
   /* --- DESIGN DU MENU DÉROULANT (DROPDOWN) --- */
   .dropdown-trigger {
       display: flex;
       align-items: center;
       gap: 6px;
       cursor: pointer;
   }
   
   .arrow-down {
       display: inline-block;
       width: 0;
       height: 0;
       border-left: 4px solid transparent;
       border-right: 4px solid transparent;
       border-top: 5px solid #ffffff; 
       transition: transform 0.3s ease;
   }
   
   .dropdown-menu {
       display: none; 
       position: absolute;
       top: 90%; 
       left: 50%;
       transform: translateX(-50%) translateY(10px); 
       background-color: #1e293b; 
       min-width: 160px;
       box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
       border-radius: 6px;
       padding: 8px 0;
       list-style: none;
       margin: 0;
       z-index: 999;
       opacity: 0;
       visibility: hidden;
       transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
   }
   
   .dropdown-menu li {
       margin-left: 0 !important; 
       display: block;
       width: 100%;
   }
   
   .dropdown-menu li a {
       padding: 10px 20px;
       display: block;
       font-size: 14px;
       color: #cbd5e1;
       white-space: nowrap; 
       text-align: left;
       transition: background-color 0.2s ease, color 0.2s ease;
   }
   
   .dropdown-menu li a:hover {
       background-color: #00d2ff; 
       color: #0f172a;
   }
   
   .nav-links li.dropdown:hover .dropdown-menu {
       display: block;
       opacity: 1;
       visibility: visible;
       transform: translateX(-50%) translateY(0px); 
   }
   
   .nav-links li.dropdown:hover .arrow-down {
       transform: rotate(180deg);
   }
   
   
/* 3. EN-TÊTE DU CATALOGUE*/
   .catalog-header {
    margin: 40px 0 20px 0;
}

.catalog-header h1 {
    font-size: 2.3rem;
    margin-bottom: 25px;
    text-align: center;
}

.search-sort-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: flex-end; 
    width: 100%;
    padding-bottom: 25px;
    border-bottom: 1px solid #1e293b;
    margin-bottom: 25px;
}

.spacer-left {
    display: block;
}

/* Bloc de recherche (Centre) */
.search-box {
    display: flex;
    align-items: flex-end;
}

.search-field-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.search-field-group label {
    font-size: 0.95rem;
    color: #00d2ff;
    font-weight: 600;
    letter-spacing: 0.5px;
    margin-left: 5px;
}

.search-input-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.search-box input {
    padding: 12px 20px;
    width: 320px;
    border-radius: 25px;
    border: 1px solid #334155;
    background: #1e293b;
    color: white;
    outline: none;
    font-size: 1rem;
    transition: 0.3s;
}

.search-box input:focus {
    border-color: #00d2ff;
    box-shadow: 0 0 10px rgba(0, 210, 255, 0.2);
}

.search-box button {
    padding: 12px 25px;
    background: #00d2ff;
    color: #0f172a;
    border: none;
    border-radius: 25px;
    font-weight: bold;
    cursor: pointer;
    font-size: 1rem;
    transition: 0.3s;
    height: 46px;
}

.search-box button:hover {
    background: #00b4db;
    transform: scale(1.03);
}

.btn-reset {
    color: #94a3b8;
    text-decoration: none;
    transition: 0.3s;
}

.btn-reset:hover {
    color: #f1f5f9;
}

.sort-box {
    display: flex;
    justify-content: flex-end; 
    align-items: center;
}

.sort-select {
    padding: 12px 20px;
    border-radius: 25px;
    border: 1px solid #334155;
    background: #1e293b;
    color: #f8fafc;
    font-size: 0.95rem;
    font-weight: bold;
    outline: none;
    cursor: pointer;
    transition: 0.3s ease;
}

.sort-select:hover {
    border-color: #00d2ff;
}

.card-extra-info {
    display: flex;
    gap: 8px;
    margin-top: auto;
    padding-top: 15px;
    flex-wrap: wrap;
}

.game-card .date {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: 5px;
}
   
   /* 4. LAYOUT : COLONNE FILTRES À GAUCHE & GRILLE À DROITE*/
   .catalog-layout {
       display: grid;
       grid-template-columns: 280px 1fr;
       gap: 40px;
       align-items: start;
       margin-bottom: 60px;
   }
   
   /* Barre latérale de filtres */
   .filter-sidebar {
       background: #1e293b;
       padding: 25px;
       border-radius: 15px;
       border: 1px solid #334155;
       position: sticky; 
       top: 20px;
   }
   
   .sidebar-title {
       font-size: 1.2rem;
       font-weight: bold;
       color: #00d2ff;
       margin-bottom: 20px;
       border-bottom: 1px solid #334155;
       padding-bottom: 10px;
   }
   
   /* Alignement vertical des filtres */
   .filter-sort-wrapper {
       display: flex;
       flex-direction: column;
       gap: 20px;
       width: 100%;
   }
   
   .filter-group {
       display: flex;
       flex-direction: column;
       gap: 8px;
   }
   
   .filter-group label {
       font-size: 0.85rem;
       color: #94a3b8;
       font-weight: 600;
       text-transform: uppercase;
       letter-spacing: 0.5px;
   }
   
   /* Style des filtres en colonne */
   .filter-select {
       padding: 10px 15px;
       background-color: #0f172a;
       color: #f8fafc;
       border: 1px solid #334155;
       border-radius: 8px;
       outline: none;
       cursor: pointer;
       font-size: 0.95rem;
       width: 100%; 
       transition: all 0.2s ease;
   }
   
   .filter-select:hover, .filter-select:focus {
       border-color: #00d2ff;
       box-shadow: 0 0 8px rgba(0, 210, 255, 0.15);
   }
   
   
   /* 5. GRILLE DU CATALOGUE & CARTES DE JEUX*/
   .catalog-content {
       width: 100%;
   }
   
   .game-grid {
       display: grid;
       grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
       gap: 25px;
   }

.game-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin: 40px 0 60px 0;
}

.game-card {
    background: #1e293b;
    padding: 25px;
    border-radius: 15px;
    border: 1px solid #334155;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    transition: all 0.3s ease;
    height: 100%;
}

.game-card:hover {
    transform: translateY(-5px);
    border-color: #00d2ff;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.game-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 15px;
}

.card-header h3 {
    margin: 0;
    color: #00d2ff;
    font-size: 1.3rem;
}

.card-extra-info {
    display: flex;
    gap: 8px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.badge-pegi {
    background-color: #e11d48;
    color: white;
    padding: 2px 8px;
    font-size: 0.75rem;
    font-weight: bold;
    border-radius: 4px;
}

.badge-mode {
    background-color: #3b82f6;
    color: white;
    padding: 2px 8px;
    font-size: 0.75rem;
    font-weight: bold;
    border-radius: 4px;
}

.game-card .date {
    font-size: 0.85rem;
    color: #64748b;
    margin-top: auto; 
    padding-top: 15px;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    padding-top: 15px;
    border-top: 1px solid #334155;
    width: 100%;
}

.game-price {
    color: #4ade80;
    font-weight: bold;
    font-size: 1.2rem;
}

.btn-details {
    background: transparent;
    border: 1px solid #00d2ff;
    color: #00d2ff;
    padding: 7px 15px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: 0.3s;
    cursor: pointer;
}

.btn-details:hover {
    background: #00d2ff;
    color: #0f172a;
}
   
   .no-results {
       text-align: center;
       padding: 50px;
       color: #94a3b8;
       font-size: 1.2rem;
       width: 100%;
   }
   
   
   /* 6. FENÊTRE MODALE*/
   .modal {
       display: none; 
       position: fixed; 
       z-index: 1000; 
       left: 0;
       top: 0;
       width: 100%; 
       height: 100%; 
       background-color: rgba(0,0,0,0.8);
       backdrop-filter: blur(5px);
       justify-content: center; 
       align-items: center; 
   }
   
   .modal-content {
       background-color: #1e293b;
       width: 75%;
       max-width: 950px;
       min-height: 450px;
       padding: 30px;
       border: 1px solid #334155;
       border-radius: 20px;
       position: relative;
       color: #f8fafc;
       box-shadow: 0 10px 40px rgba(0,0,0,0.5);
       animation: modalOpen 0.3s ease;
   }
   
   .close {
       position: absolute;
       right: 20px;
       top: 10px;
       color: #94a3b8;
       font-size: 35px;
       font-weight: bold;
       cursor: pointer;
       z-index: 10;
   }
   
   .close:hover {
       color: #00d2ff;
   }
   
   .modal-game {
       display: grid;
       grid-template-columns: 280px 1fr; 
       gap: 40px;
       align-items: start;
   }
   
   .modal-image {
       width: 100%;
       height: 400px;
       object-fit: cover;
       border-radius: 15px;
       border: 1px solid #334155;
   }
   
   .modal-content-right {
       display: flex;
       flex-direction: column;
   }
   
   .modal-title {
       color: #00d2ff;
       font-size: 2.2rem;
       margin-bottom: 15px;
   }
   
   .modal-infos {
       display: grid;
       grid-template-columns: 1fr 1fr; 
       gap: 12px 20px;
       padding-bottom: 20px;
       margin-bottom: 20px;
       border-bottom: 1px solid #334155;
       font-size: 1rem;
   }
   
   .modal-infos p { color: #cbd5e1; }
   .modal-infos strong { color: #94a3b8; }
   .modal-price {
       color: #4ade80;
       font-weight: bold;
       font-size: 1.2rem;
   }
   
   .modal-description h3 {
       color: #00d2ff;
       margin-bottom: 10px;
   }
   
   .modal-description p {
       color: #cbd5e1;
       line-height: 1.7;
   }
   
   @keyframes modalOpen {
       from { opacity: 0; transform: translateY(-20px); }
       to { opacity: 1; transform: translateY(0); }
   }
   
   
   /* 7. FOOTER*/
   footer {
       text-align: center;
       padding: 20px;
       background-color: #020617;
       color: #64748b;
       margin-top: auto;
       border-top: 1px solid #1e293b;
   }
   