/* --- RESET DE BASE --- */
body, margin, padding {
    margin: 0;
    padding: 0;
    font-family: 'Arial', sans-serif; /* On changera la police plus tard */
    overflow-x: hidden;
}

/* --- HERO IMMERSIF --- */
.hero-immersive {
    position: relative;
    width: 100%;
    height: 100vh; /* Prend 100% de la hauteur de l'écran */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* La vidéo prend tout l'espace */
.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Coupe les bords si besoin pour remplir l'écran */
    z-index: -2;
}

/* Filtre sombre pour faire ressortir le texte */
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(20, 20, 20, 0.6); /* Noir transparent à 60% */
    z-index: -1;
}

/* Le texte au centre */
.hero-content {
    text-align: center;
    color: #ffffff;
    z-index: 1;
    padding: 20px;
}

.hero-content h1 {
    font-size: 4rem;
    text-transform: uppercase;
    font-style: italic;
    margin-bottom: 10px;
}

/* Le bouton d'action (Néon / Racing) */
.btn-primary {
    display: inline-block;
    margin-top: 20px;
    padding: 15px 30px;
    background-color: #e50000; /* Rouge racing */
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    text-transform: uppercase;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.btn-primary:hover {
    background-color: #b30000;
}

/* --- SECTION FLOTTE & CIRCUITS (Style Tournai) --- */
.fleet-section {
    background-color: #111111; /* Fond très sombre */
    color: #ffffff;
    padding: 60px 20px;
    font-family: 'Arial', sans-serif;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    text-transform: uppercase;
    font-style: italic;
    color: #ff0000; /* Rouge vif comme sur le screen */
    margin-bottom: 10px;
    font-weight: 900;
}

.section-subtitle {
    text-align: center;
    color: #888;
    margin-bottom: 40px;
    font-size: 1.1rem;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 20px;
}

.racing-card {
    position: relative;
    height: 225px; /* On adapte la hauteur à la taille de tes images */
    background-color: #111; /* Fond très sombre pour le circuit qui est carré */
    border-radius: 4px; 
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

.card-bg {
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 175px; /* Sur une carte de 225px, ça laisse exactement 50px en bas */
    background-size: contain; /* L'image s'adapte sans jamais être coupée */
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.4s ease, opacity 0.4s ease;
    opacity: 0.9;
}

/* Le bandeau noir en bas pour le titre */
.card-content {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50px; /* Les 50px restants de la carte */
    background: #000; /* Fond totalement noir */
    padding: 0 20px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Centre le titre verticalement dans son bandeau */
    transition: all 0.4s ease;
    z-index: 2;
}


.card-content h3 {
    font-size: 1.4rem;
    margin: 0;
    text-transform: uppercase;
    font-weight: 900;
    letter-spacing: 1px;
    color: #ffffff; /* <--- LA LIGNE MAGIQUE À AJOUTER */
}

/* L'histoire cachée qui monte au survol */
.card-story {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: all 0.4s ease;
    margin-top: 0;
}

.card-story p {
    font-size: 0.85rem; 
    line-height: 1.3;
    color: #ddd;
    margin-top: 10px;
    margin-bottom: 10px;
}

.badge {
    display: inline-block;
    padding: 4px 8px;
    background-color: #333;
    font-size: 0.75rem;
    font-weight: bold;
    border-radius: 3px;
    text-transform: uppercase;
}


.track-card .card-bg {
    /* "auto 80%" = largeur automatique, et hauteur bloquée à 80% de l'espace disponible */
    background-size: auto 80%; 
    background-position: center;
    opacity: 1;
}

/* --- ANIMATIONS AU SURVOL --- */
.racing-card:hover .card-bg {
    transform: scale(1.05); /* Zoom léger de l'image */
    opacity: 0.4; /* L'image s'assombrit pour bien lire le texte */
}

.racing-card:hover .card-content {
    height: 100%; /* Le bandeau remonte sur toute la carte au survol */
    background: rgba(0,0,0,0.9);
}

.racing-card:hover .card-story {
    max-height: 150px; /* Un peu moins haut */
    opacity: 1;
    margin-top: 10px;
}


/* --- FOOTER --- */
.site-footer {
    background-color: #050505; 
    color: #cccccc;
    padding: 60px 0 0 0;
    font-family: 'Arial', sans-serif;
    border-top: 2px solid #e50000; 
    clear: both;
    
    /* LA NOUVELLE MAGIE DU BREAKOUT (Fini la bande blanche !) */
    width: 100vw !important;
    position: relative;
    left: 50%;
    transform: translateX(-50%); /* Centre parfaitement le bloc sans erreur de calcul */
}
/* On centre les colonnes de texte au milieu de l'écran */
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    padding-bottom: 40px;
    max-width: 1200px; /* Empêche le texte de s'étirer à l'infini */
    margin: 0 auto; /* Magie : centre la grille parfaitement */
    padding-left: 20px; /* Marges de sécurité pour téléphone */
    padding-right: 20px;
}

.footer-col h3 {
    color: #ffffff;
    font-size: 1.5rem;
    font-style: italic;
    margin-top: 0;
    margin-bottom: 20px;
}

.footer-col h4 {
    color: #ffffff;
    font-size: 1.2rem;
    text-transform: uppercase;
    margin-top: 0;
    margin-bottom: 20px;
    border-bottom: 1px solid #333;
    padding-bottom: 10px;
    display: inline-block;
}

.footer-col p {
    line-height: 1.6;
    font-size: 0.95rem;
    margin-bottom: 10px;
}

/* Style des liens rapides */
.links-col ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.links-col ul li {
    margin-bottom: 12px;
}

.links-col ul a {
    color: #cccccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.links-col ul a:hover {
    color: #e50000; /* Touche de rouge au survol */
}

/* Réseaux sociaux en ligne */
.social-links {
    margin-top: 20px;
    display: flex;
    gap: 15px;
}

.social-links a {
    color: #fff;
    text-decoration: none;
    font-size: 0.9rem;
    background: #222;
    padding: 5px 10px;
    border-radius: 3px;
    transition: background 0.3s ease;
}

.social-links a:hover {
    background: #e50000;
}

/* La ligne de Copyright tout en bas */
.footer-bottom {
    background-color: #000000; /* Encore plus sombre pour contraster */
    text-align: center;
    padding: 20px;
    font-size: 0.85rem;
    color: #666;
    width: 100%; /* S'assure que cette ligne va aussi de bord en bord */
}

.footer-bottom p {
    margin: 0;
}
/* --- HEADER & NAVIGATION --- */
.site-header {
    position: fixed; /* La barre reste accrochée en haut quand on scroll */
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(5, 5, 5, 0.85); /* Noir avec 85% d'opacité */
    backdrop-filter: blur(8px); /* Effet vitre floutée moderne */
    z-index: 1000; /* Assure que le menu passe toujours par-dessus le reste */
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 20px;
    display: flex;
    justify-content: space-between; /* Écarte le logo à gauche et le menu à droite */
    align-items: center;
}

/* Style du Logo */
.site-logo a {
    color: #ffffff;
    font-size: 1.8rem;
    font-weight: 900;
    font-style: italic;
    text-decoration: none;
    letter-spacing: 2px;
}

.site-logo a span {
    color: #e50000; /* Le point en rouge pour le dynamisme */
}

/* Style du Menu */
.main-navigation ul.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 30px; /* Espace entre chaque lien */
}

.main-navigation ul.nav-menu li a {
    color: #cccccc;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: color 0.3s ease;
    position: relative;
    padding-bottom: 5px;
}

.main-navigation ul.nav-menu li a:hover {
    color: #ffffff;
}

/* Ligne rouge animée qui apparaît sous le texte au survol */
.main-navigation ul.nav-menu li a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background-color: #e50000;
    transition: width 0.3s ease;
}

.main-navigation ul.nav-menu li a:hover::after {
    width: 100%;
}

/* ==================================================== */
/* --- CORRECTIF PAGE VOITURES & CIRCUITS --- */
/* ==================================================== */

/* 1. On pousse le contenu vers le bas pour ne pas être sous le menu */
.page-fleet {
    padding-top: 120px; /* Hauteur de ton menu + marge */
    background-color: #0a0a0a;
    min-height: 100vh;
}

.page-header-immersive {
    padding: 60px 0;
    text-align: center;
    border-bottom: 1px solid #222;
}

.page-header-immersive h1 {
    font-size: 3rem;
    color: #fff;
    font-style: italic;
    text-transform: uppercase;
    margin-bottom: 10px;
}

/* 2. On stylise les boutons de filtres */
.fleet-filters {
    padding: 30px 0;
    text-align: center;
    background: #111;
}

.filter-btn {
    background: #1a1a1a; /* Fond sombre par défaut */
    border: 2px solid #333;
    color: #fff;
    padding: 10px 25px;
    margin: 0 10px;
    cursor: pointer;
    text-transform: uppercase;
    font-weight: 900;
    font-style: italic;
    transition: all 0.3s ease;
    border-radius: 0; /* Look carré plus agressif */
}

.filter-btn:hover {
    border-color: #e50000;
}

.filter-btn.active {
    background: #e50000;
    border-color: #e50000;
    box-shadow: 0 0 15px rgba(229, 0, 0, 0.4);
}

/* 3. LOGIQUE D'AFFICHAGE (Très important) */
.fleet-content {
    display: none !important; /* CACHE TOUT PAR DÉFAUT */
    padding: 50px 0;
}

.fleet-content.active {
    display: block !important; /* AFFICHE SEULEMENT LA SECTION ACTIVE */
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==================================================== */
/* --- PAGES STANDARDS (Réservation, Contact...) --- */
/* ==================================================== */

.generic-page {
    padding-top: 150px; /* Pour ne pas être caché par le menu fixe */
    padding-bottom: 80px;
    background-color: #0a0a0a;
    min-height: 100vh;
    color: #fff;
}

.generic-page .page-header {
    text-align: center;
    margin-bottom: 50px;
}

.generic-page .page-header h1 {
    font-size: 3rem;
    font-style: italic;
    text-transform: uppercase;
    color: #fff;
    border-bottom: 2px solid #e50000; /* Petite ligne rouge stylée */
    display: inline-block;
    padding-bottom: 10px;
}

.generic-page .page-content {
    background: #111;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

/* --- SURCHARGES DU PLUGIN AMELIA --- */
/* Cacher le lien de publicité Amelia en bas du calendrier */
#am-link-to-us, 
.am-powered-by,
a[href*="wpamelia.com"] {
    display: none !important;
}

/* Optionnel : Rendre le conteneur du calendrier transparent pour qu'il fusionne avec ta page */
.am-step-booking {
    background-color: transparent !important;
}

/* ==================================================== */
/* --- SECTION MATÉRIEL (Accueil) --- */
/* ==================================================== */

.equipment-section {
    background-color: #111111;
    padding: 80px 20px;
    color: #fff;
    border-top: 1px solid #222;
}

.equipment-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.equipment-card {
    background: #1a1a1a;
    border: 1px solid #333;
    padding: 40px 20px;
    text-align: center;
    border-radius: 4px;
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.equipment-card:hover {
    transform: translateY(-10px);
    border-color: #e50000;
    box-shadow: 0 10px 20px rgba(229, 0, 0, 0.15);
}

.equipment-icon {
    width: 80px;
    height: 80px;
    object-fit: contain;
    margin-bottom: 25px;
    filter: drop-shadow(0 0 5px rgba(255,255,255,0.2)); /* Léger halo lumineux */
}

.equipment-card h3 {
    font-size: 1.3rem;
    color: #fff;
    text-transform: uppercase;
    font-weight: 900;
    font-style: italic;
    margin-bottom: 15px;
    letter-spacing: 1px;
}

.equipment-card p {
    color: #999;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}
/* Bouton Burger caché sur PC */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #ffffff;
    font-size: 28px;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s ease;
}
.mobile-menu-toggle:hover {
    color: #e50000;
}
/* ==================================================== */
/* --- RESPONSIVE DESIGN (Mobiles & Tablettes) --- */
/* ==================================================== */

/* Ces règles ne s'activent que si l'écran fait moins de 768px de large */
@media screen and (max-width: 768px) {
    
    /* 1. On réduit la taille des gros titres */
    .hero-content h1 {
        font-size: 2.5rem;
    }
    .section-title, .generic-page .page-header h1 {
        font-size: 2rem;
    }

    /* 1. Logo à gauche, Burger à droite */
    .header-container {
        flex-direction: row !important; 
        justify-content: space-between;
        flex-wrap: wrap; /* Autorise le menu à passer en dessous */
        padding: 15px;
    }

    /* 2. On affiche le bouton Burger ET on le force à droite */
    .mobile-menu-toggle {
        display: block;
        margin-left: auto; /* <-- LE RESSORT QUI LE POUSSE À DROITE */
    }

    /* 3. On CACHE le menu de base */
    .main-navigation {
        display: none; /* Disparaît par défaut */
        width: 100%; /* Prend toute la largeur quand il sera ouvert */
        padding-top: 20px;
        border-top: 1px solid #222;
        margin-top: 15px;
    }

    /* 4. La classe "active" qui sera rajoutée par le JavaScript au clic */
    .main-navigation.active {
        display: block;
        animation: fadeIn 0.3s ease;
    }

    /* 5. On empile les liens proprement pour le mobile */
    .main-navigation ul.nav-menu {
        flex-direction: column;
        gap: 20px;
        align-items: center;
        text-align: center;
    }

    /* 6. On annule l'affichage chelou des sous-menus (ex: Boutique) sur mobile */
    ul.sub-menu {
        position: relative !important;
        box-shadow: none !important;
        background: transparent !important;
        display: none !important; /* Caché par défaut */
    }
    
    /* On force l'affichage du sous-menu sur mobile quand on le survole/clique */
    li.menu-item-has-children:hover > ul.sub-menu,
    li.menu-item-has-children:active > ul.sub-menu {
        display: block !important;
        margin-top: 10px !important;
    }    
    /* On pousse un peu plus le contenu vers le bas car le menu empilé prend plus de place en haut */
    .generic-page, .page-fleet {
        padding-top: 160px; 
    }
}

/* ==================================================== */
/* --- MODALE DE RÉSERVATION (POPUP) --- */
/* ==================================================== */

.custom-modal {
    display: none; /* Caché par défaut */
    position: fixed;
    z-index: 9999; /* Par-dessus tout le reste (menu inclus) */
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85); /* Noir semi-transparent */
    backdrop-filter: blur(8px); /* Effet flou sur la vidéo en fond */
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: #111111;
    padding: 40px;
    border-radius: 8px;
    border: 1px solid #333;
    width: 90%;
    max-width: 900px;
    position: relative;
    box-shadow: 0 10px 30px rgba(229, 0, 0, 0.2); /* Léger halo rouge */
    max-height: 90vh; /* Empêche de dépasser de l'écran */
    overflow-y: auto; /* Permet de scroller à l'intérieur si besoin */
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 10px;
    color: #888;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: #e50000;
}

/* ==================================================== */
/* --- STYLE BOUTIQUE WOOCOMMERCE (RACING DARK) --- */
/* ==================================================== */

/* Fond de la page boutique */
.post-type-archive-product, .single-product, .woocommerce-page {
    background-color: #0a0a0a !important;
    color: #ffffff;
}

/* Titres des produits */
.woocommerce-loop-product__title {
    color: #ffffff !important;
    font-style: italic;
    text-transform: uppercase;
}

/* Prix */
.woocommerce Price-amount {
    color: #e50000 !important;
    font-weight: bold;
}

/* Bouton "Ajouter au panier" */
.woocommerce .button.add_to_cart_button, 
.woocommerce .button.checkout,
.woocommerce #respond input#submit {
    background-color: #e50000 !important;
    color: #fff !important;
    border-radius: 0 !important;
    text-transform: uppercase !important;
    font-weight: bold !important;
}

.woocommerce .button:hover {
    background-color: #b30000 !important;
}

/* On cache les messages WooCommerce bleus/violets */
.woocommerce-info, .woocommerce-message {
    border-top-color: #e50000 !important;
    background-color: #111 !important;
    color: #fff !important;
}
/* Centrer la boutique et lui donner de l'espace */
.woocommerce, .woocommerce-page {
    max-width: 1200px !important;
    margin: 40px auto !important; /* Centre le bloc avec une marge en haut/bas */
    padding: 0 20px;
}

/* Cacher les widgets "sauvages" au cas où ton thème force leur affichage */
.widget-area, #secondary {
    display: none !important;
}

/* Rendre les menus déroulants (taille/couleur) sombres */
.woocommerce select {
    background-color: #111;
    color: #fff;
    border: 1px solid #333;
    padding: 10px;
    margin-bottom: 15px;
}
/* Correction pour les options du menu déroulant WooCommerce */
.woocommerce select option {
    background-color: #1a1a1a; /* Fond gris très foncé */
    color: #ffffff;            /* Texte blanc */
}

/* ==================================================== */
/* --- PANIER & CHECKOUT WOOCOMMERCE (DARK THEME) --- */
/* ==================================================== */

/* Tableaux du panier et récapitulatif */
.woocommerce table.shop_table {
    border: 1px solid #333;
    border-radius: 4px;
}

.woocommerce table.shop_table th, 
.woocommerce table.shop_table td {
    border-top: 1px solid #333;
    color: #fff;
    background-color: #111;
}

/* Formulaires de commande (Nom, Prénom, Adresse...) */
.woocommerce form .form-row input.input-text, 
.woocommerce form .form-row textarea,
.woocommerce form .form-row select {
    background-color: #1a1a1a;
    color: #fff;
    border: 1px solid #333;
    padding: 10px;
    border-radius: 4px;
}

/* Zone de paiement finale (Carte bancaire, etc.) */
#add_payment_method #payment, 
.woocommerce-cart #payment, 
.woocommerce-checkout #payment {
    background: #111;
    border-radius: 5px;
    border: 1px solid #333;
}

#add_payment_method #payment div.payment_box, 
.woocommerce-cart #payment div.payment_box, 
.woocommerce-checkout #payment div.payment_box {
    background-color: #1a1a1a;
    color: #aaa;
    box-shadow: none;
}

/* Petit triangle au-dessus de l'explication du paiement */
#add_payment_method #payment div.payment_box::before, 
.woocommerce-cart #payment div.payment_box::before, 
.woocommerce-checkout #payment div.payment_box::before {
    border-bottom-color: #1a1a1a;
}
/* ==================================================== */
/* --- RESTRINDRE LES PAYS DU TELEPHONE (AMELIA) --- */
/* ==================================================== */

/* 1. On cache absolument tous les pays de la liste par défaut */
.iti__country {
    display: none !important;
}

/* 2. On force l'affichage UNIQUEMENT pour la France et La Réunion */
.iti__country[data-country-code="fr"],
.iti__country[data-country-code="re"] {
    display: block !important;
}
/* ==================================================== */
/* --- MUR DES RECORDS : REFONTE GRAPHIQUE ESPORT --- */
/* ==================================================== */

.leaderboard-container {
    max-width: 900px;
    margin: 50px auto;
    background: #0d0d0d; /* Noir plus profond */
    border: 1px solid #222;
    border-radius: 12px; /* Un peu plus rond et moderne */
    box-shadow: 0 0 40px rgba(229, 0, 0, 0.15); /* Halo rouge diffus */
    overflow: hidden;
    position: relative;
}
/* --- FOND DE LA SECTION RECORDS --- */
.records-section {
    background-color: #050505; /* Le fond noir profond */
    padding: 80px 20px; 
    width: 100%;
    min-height: 50vh; /* S'assure que le noir descend jusqu'en bas de l'écran */
}

/* L'en-tête façon "Racing Team" */
.leaderboard-header {
    background: linear-gradient(135deg, #e50000 0%, #8b0000 100%); /* Dégradé rouge dynamique */
    color: #ffffff;
    text-align: center;
    padding: 35px 20px;
    border-bottom: 3px solid #ff3333; /* Ligne lumineuse en dessous */
    position: relative;
}

/* Effet de rayures (Vitesse) en arrière-plan du header */
.leaderboard-header::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-image: repeating-linear-gradient(45deg, transparent, transparent 10px, rgba(0,0,0,0.1) 10px, rgba(0,0,0,0.1) 20px);
    pointer-events: none;
}

.leaderboard-header h2 {
    margin: 0;
    font-size: 2.2rem;
    font-style: italic;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    position: relative; /* Reste au-dessus des rayures */
}

.leaderboard-header h2 i {
    color: #ffd700; /* Les icônes passent en Or */
    margin: 0 10px;
}

.leaderboard-header p {
    margin: 10px 0 0 0;
    font-size: 1rem;
    color: #ffcccc;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
}

/* --- LE NOUVEAU SÉLECTEUR DE CIRCUIT --- */
.select-container {
    margin-top: 25px;
    position: relative;
}

#circuit-selector {
    appearance: none;
    background-color: rgba(0, 0, 0, 0.6); /* Fond sombre translucide */
    color: #ffffff;
    border: 1px solid rgba(255,255,255,0.3);
    padding: 12px 45px 12px 25px;
    font-size: 1rem;
    font-weight: bold;
    font-family: 'Arial', sans-serif;
    text-transform: uppercase;
    border-radius: 30px; /* Bouton style "Pilule" très pro */
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    
    /* Flèche customisée */
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23FFFFFF%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 18px top 50%;
    background-size: 12px auto;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

#circuit-selector:hover {
    background-color: rgba(0, 0, 0, 0.9);
    border-color: #fff;
    transform: translateY(-2px);
}

#circuit-selector option {
    background-color: #111;
    color: #fff;
}

/* --- LE TABLEAU (HUD STYLE) --- */
.tablepress {
    width: 100% !important;
    margin: 0 !important;
    border: none !important;
    background-color: #0d0d0d !important;
}

/* Ligne des titres (Pilote, Chrono) */
.tablepress thead th, .tablepress th {
    background-color: #111 !important;
    color: #555 !important;
    padding: 20px 15px !important;
    font-size: 0.8rem !important;
    letter-spacing: 3px !important;
    text-transform: uppercase;
    text-align: center !important;
    border: none !important;
    border-bottom: 1px solid #222 !important;
}

/* Lignes des joueurs */
.tablepress tbody td, .tablepress td {
    background-color: #0d0d0d !important;
    color: #ccc !important;
    padding: 18px 15px !important;
    text-align: center !important;
    border: none !important;
    border-bottom: 1px solid #1a1a1a !important;
    font-size: 1.05rem;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.tablepress tbody tr:hover td {
    background-color: #151515 !important;
    color: #fff !important;
}

/* 🏆 LE PREMIER (CHAMPION ABSOLU) */
.tablepress tbody tr:first-child td {
    background: linear-gradient(90deg, rgba(212,175,55,0.15) 0%, rgba(212,175,55,0.02) 100%) !important;
    color: #ffd700 !important;
    font-size: 1.15rem;
    font-weight: 900 !important;
    border-bottom: 1px solid rgba(212,175,55,0.3) !important;
}

/* Typographie Digitale pour les colonnes des chronos (Colonnes 3 et 4 si présentes) */
.tablepress tbody td.column-3,
.tablepress tbody td.column-4 {
    font-family: 'Courier New', Courier, monospace !important;
    font-weight: 700 !important;
    letter-spacing: 1px;
}

/* L'écart (s'il y en a un) s'affiche en rouge foncé */
.tablepress tbody td.column-4 {
    color: #cc0000 !important; 
    font-size: 0.95rem;
}

/* Sauf pour le premier ! */
.tablepress tbody tr:first-child td.column-4 {
    color: #ffd700 !important;
}

/* Démolition du lien "Modifier" bleu */
.tab-content a[href*="action=edit"],
.tablepress-edit-link {
    display: none !important;
}
/* --- GALERIE FLICKR (MODE PINTEREST / MASONRY) --- */
.flickr-gallery-grid {
    column-count: 3; /* Nombre de colonnes */
    column-gap: 20px;
    margin: 40px 0;
}

/* Sur les petits écrans (téléphones), on passe à 1 seule colonne */
@media (max-width: 768px) {
    .flickr-gallery-grid {
        column-count: 1;
    }
}

.flickr-photo-card {
    break-inside: avoid; /* Empêche l'image d'être coupée entre deux colonnes */
    margin-bottom: 20px;
    border-radius: 8px;
    border: 2px solid #333;
    transition: transform 0.3s ease, border-color 0.3s ease;
    overflow: hidden;
    display: inline-block;
    width: 100%;
}

.flickr-photo-card img {
    width: 100%;
    height: auto; /* Laisse l'image prendre sa hauteur naturelle ! */
    display: block;
    filter: grayscale(30%);
    transition: filter 0.3s ease;
}

/* Effet au survol */
.flickr-photo-card:hover {
    transform: translateY(-5px);
    border-color: #e50000;
}

.flickr-photo-card:hover img {
    filter: grayscale(0%);
}
/* --- BOUTON VOIR PLUS FLICKR --- */
.flickr-more-btn-container {
    text-align: center;
    margin-top: 30px;
    margin-bottom: 50px;
}

.btn-flickr-more {
    display: inline-block;
    background-color: #e50000;
    color: #ffffff;
    padding: 15px 30px;
    font-size: 1.1rem;
    font-weight: bold;
    text-transform: uppercase;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.btn-flickr-more:hover {
    background-color: #ff1a1a;
    transform: scale(1.05);
    color: #ffffff;
}
/* ==================================================== */
/* --- DESIGN DU MENU DÉROULANT (DROPDOWN COMPLET) --- */
/* ==================================================== */

/* 1. On prépare le bouton parent ("À PROPOS") */
li.menu-item-has-children {
    position: relative !important; 
}

/* On force le lien principal à être une boîte rigide sur une seule ligne */
li.menu-item-has-children > a {
    display: flex !important;
    flex-direction: row !important; /* Force l'affichage horizontal */
    flex-wrap: nowrap !important; /* Interdiction stricte de passer à la ligne */
    align-items: center !important; /* Centre verticalement */
    width: max-content !important; /* La boîte s'adapte au texte + la flèche */
}


/* 3. On cache et on met en forme le sous-menu ("Galerie") */
ul.sub-menu {
    position: absolute !important;
    top: 100%; 
    left: 0;
    background-color: #111111 !important; /* Fond très sombre */
    min-width: 200px;
    padding: 0 !important;
    margin: 0 !important;
    list-style: none !important;
    border-top: 3px solid #e50000 !important; /* Ligne rouge V-Concept (en haut du sous-menu) */
    box-shadow: 0 10px 25px rgba(0,0,0,0.5) !important;
    display: block !important;
    
    /* Animation de masquage */
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 999;
}

/* 4. On affiche le sous-menu au survol du parent */
li.menu-item-has-children:hover > ul.sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* 5. Style des liens à l'intérieur du sous-menu */
ul.sub-menu li {
    width: 100%;
    border-bottom: 1px solid #222 !important;
    display: block !important;
}

ul.sub-menu li:last-child {
    border-bottom: none !important;
}

ul.sub-menu li a {
    display: block !important;
    padding: 15px 20px !important;
    color: #ffffff !important;
    font-size: 0.9rem !important;
    text-transform: uppercase !important;
    text-decoration: none !important;
    border: none !important; /* Annule la ligne rouge sur les sous-liens */
    transition: background 0.3s ease, padding-left 0.3s ease !important;
}

/* Effet au survol d'un lien du sous-menu */
ul.sub-menu li a:hover {
    background-color: #1a1a1a !important;
    color: #e50000 !important; /* Le texte passe en rouge */
    padding-left: 25px !important; /* Petit décalage stylé vers la droite */
}
/* ==================================================== */
/* --- ICÔNES RÉSEAUX SOCIAUX (FOOTER) --- */
/* ==================================================== */

.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 20px;
}

.social-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: #1a1a1a; /* Fond sombre par défaut */
    color: #ffffff; /* Icône blanche */
    border-radius: 50%; /* Transforme le carré en rond parfait */
    text-decoration: none;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

/* Effet au survol (Le rouge V-Concept) */
.social-links a:hover {
    background-color: #e50000;
    color: #ffffff;
    transform: translateY(-5px); /* Fait "sauter" l'icône vers le haut */
    box-shadow: 0 5px 15px rgba(229, 0, 0, 0.4); /* Petit halo rouge */
}
/* ==================================================== */
/* --- CORRECTION ESPACEMENT CODE PAYS (AMELIA) --- */
/* ==================================================== */

/* 1. Force un espace dans la liste déroulante */
.m-select-list-item {
    display: flex !important;
    gap: 8px !important; /* Crée un espace de 8 pixels entre le drapeau, le chiffre et le texte */
    align-items: center !important;
}

/* 2. Au cas où le plugin utilise des <span> imbriqués, on force une marge */
.m-select-list-item span {
    margin-right: 5px !important;
}

/* 3. Force un espace une fois que le pays est SÉLECTIONNÉ dans le champ */
.am-selected-country,
.m-selected-item,
.el-input__inner {
    gap: 8px !important;
}

.am-selected-country span,
.m-selected-item span {
    margin-right: 5px !important;
}
/* ==================================================== */
/* --- DESIGN DU LOGO : KOPPAZ (BLANC) RACING (GRIS) --- */
/* ==================================================== */

.logo-wrapper {
    position: relative; 
    display: inline-flex;
    align-items: center;
    text-decoration: none !important;
    font-size: 32px; 
    font-family: 'Arial', sans-serif;
    font-style: italic;
    padding-left: 10px; 
}

/* Le drapeau (Calque du fond) */
.custom-racing-flag {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%); 
    z-index: 1; 
    opacity: 0.8; 
}

/* Le bloc de texte (Calque du dessus) */
.logo-text {
    position: relative;
    z-index: 2; 
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8); /* Ombre noire pour que le texte ressorte sur le damier */
}

/* KOPPAZ (Blanc forcé) */
.logo-koppaz {
    color: #ffffff !important; 
    font-weight: 900; 
    letter-spacing: 1px;
}

/* RACING (Gris clair forcé) */
.logo-racing {
    color: #b3b3b3 !important; 
    font-weight: 600; 
    margin-left: 6px; 
}