/* CUSTOM FONTS FROM GOOGLE ******************

@import url('https://fonts.googleapis.com/css2?family=your_own_font&display=swap');*/

/* CUSTOM FONTS FROM HOST ********************

@font-face {
    font-family: 'your_own_font2';
    src: local('your_own_font2'), url('../fonts/your_own_font2.woff') format('woff');
}*/

/* CUSTOM COLORS VARIABLES *******************

:root {
    --main-color: #0c1f31; main color override
    --highlight-color: #cda84f; highlight color override
}*/

/* CUSTOM HEADINGS ***************************
h1, h2, h3, h4, h5, h6 {
    font-family: 'your_own_font', serif;
    font-weight: 400;
    text-transform: none;
}
h1 small, h2 small, h3 small, h4 small, h5 small, h6 small {
    font-family: 'your_own_font2', sans-serif;
    font-weight: 200;
    text-transform: uppercase;
    letter-spacing: 0.09em;
}*/

/* H2 CUSTOM *********************************

h2 {
    font-size: 52px;
    position: relative;
    margin-bottom: 70px;
}*/

/* H2 UNDERLINE ******************************

h2::after {
    content: '';
    display: block;
    width: 200px;
    height: 1px;
    background: var(--highlight-color);
    position: absolute;
    bottom: -30px;
    left: 0;
}
h2.text-center::after, h2[style*="text-align:center"]::after,
.text-center h2::after, [style*="text-align:center"] h2::after {
    transform: translateX(-50%);
    margin-left: 50%;
    left: auto !important;
}*/

/* SLIDE HEADING *****************************

.hero-1 .hero-contents h1 {
    color: #0c1f31;
    font-size: 62px;
}*/

/* SLIDE PARAGRAPH ***************************

.hero-1 .hero-contents p {
    color: #888888;
}*/

/* HIDE SLIDE OVERLAY ************************

.hero-1 .single-slide.bg-cover::before {
    display: none;
}*/

/* CUSTOM BUTTONS ****************************

.btn {
    font-weight: normal;
    text-transform: uppercase;
    padding: 20px;
}*/

/* SERVICE CARD WITHOUT BORDERS **************

.single-service-card {
    border: none;
    background-color: transparent;
    box-shadow: none;
}*/

/* PARALLAX POLYGON **************************

.parallax-wrap {
    background-color: #434F5B;
    padding: 10vh 10vh 8vh 10vh;
    min-height: 450px;
    transform: translate3d(0, 0, 0);
    clip-path: polygon(0 18%, 100% 0, 100% 100%, 0% 100%);
}*/

/* INVERSE FOOTER COLORS *********************

.footer-2 .footer-widgets-wrapper {
    background-color: #fff;
}
.footer-2 .footer-bottom {
    background-color: var(--main-color);
}
.footer-wrap .single-footer-wid.site_info_widget .single-contact-info .icon {
    color: var(--highlight-color)!important;
}
.footer-bottom * {
    color: #fff!important;
}*/
/* ============================================= */
/* == STYLE POUR LE MÉGA MENU                 == */
/* ============================================= */

/* On cache le méga menu par défaut */
/* ============================================= */
/* == NOUVEAU STYLE POUR LE MÉGA MENU (CORRIGÉ) == */
/* ============================================= */

/* On s'assure que le conteneur principal du menu peut positionner le méga menu */
/* ================================================= */
/* == CSS DÉFINITIF POUR LE MÉGA MENU (ANTI-CONFLIT) == */
/* ================================================= */

/* On force le conteneur <li> à être statique pour bien positionner le méga menu */
/* ================================================= */
/* == SOLUTION CSS DÉFINITIVE (ANTI-CONFLIT)      == */
/* ================================================= */

/* On s'assure que le <li> parent peut contenir le menu en position absolue */
/* ================================================= */
/* == CSS FINAL POUR LE MÉGA MENU                 == */
/* ================================================= */

/* ================================================= */
/* == SOLUTION CSS FINALE POUR LE MÉGA MENU       == */
/* ================================================= */

/* LA CORRECTION LA PLUS IMPORTANTE : On ajoute le "crochet" au parent */
/* ================================================= */
/* == STYLE FINAL POUR LE NOUVEAU MENU ORDINATEUR == */
/* ================================================= */

/* ========================================================= */
/* == BLOC CSS COMPLET ET FINAL POUR LE MENU ET MÉGA MENU == */
/* ========================================================= */

/* 1. FORCER LE MENU PRINCIPAL À ÊTRE HORIZONTAL SUR ORDINATEUR */
/* ================================================= */
/* == CSS FINAL POUR LE NOUVEAU MENU ORDINATEUR   == */
/* ================================================= */

/* ========================================================= */
/* == CSS FINAL POUR UN MÉGA MENU CENTRÉ ET RESPONSIVE    == */
/* ========================================================= */

/* ========================================================= */
/* == CSS AJUSTÉ POUR UN MENU PLUS COMPACT                == */
/* ========================================================= */

/* --- 1. Alignement et style du menu principal --- */
.desktop-mega-menu nav > ul {
    display: flex;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
}
.desktop-mega-menu nav > ul > li {
    position: relative;
}

/* CORRECTION : Padding réduit pour rendre les liens moins larges */
.desktop-mega-menu nav > ul > li > a {
    display: block;
    font-weight: 600;
    font-size: 18px; /* Police légèrement réduite */
    text-transform: uppercase;
    padding: 25px 15px; /* Moins d'espace horizontal */
    color: #53545a;
}

.desktop-mega-menu nav > ul > li > a:hover,
.desktop-mega-menu nav > ul > li > a.active {
    color: var(--main-color);
}

/* --- 2. Le panneau du méga menu --- */
.desktop-mega-menu .mega-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: auto; /* La largeur s'adapte au contenu */
    min-width: 700px; /* Largeur minimale réduite */
    max-width: 1100px; /* Largeur maximale réduite */
    background: #fff;
    padding: 25px; /* Padding général réduit */
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    z-index: 999;
}

/* Affichage au survol */
.desktop-mega-menu li:hover > .mega-menu {
    display: block;
}

/* --- 3. Contenu du méga menu --- */
/* CORRECTION : Espace entre les colonnes (gap) réduit */
.mega-menu-wrapper { display: flex; gap: 20px; }
.mega-menu-column { flex: 1; min-width: 200px; text-align: left; }
.mega-menu-column h4 a { font-size: 16px; font-weight: 700; color: var(--main-color) !important; margin-bottom: 10px; padding-bottom: 10px; border-bottom: 1px solid #f0f0f0; text-transform: uppercase; display: block; }
.mega-menu-column h4 a:hover { color: var(--highlight-color) !important; }
.mega-menu-column ul { list-style: none; padding: 0; margin: 0; }
.mega-menu-column ul li a { display: block; padding: 6px 0; font-size: 15px; color: #53545a; text-transform: none; }
.mega-menu-column ul li a:hover { color: var(--highlight-color); padding-left: 8px; }

/* --- 4. Style pour la recherche et la langue --- */
/* CORRECTION : Padding réduit pour ces éléments aussi */
.header-right-elements .nav-lang .dropdown-toggle {
    background: none; border: none; font-weight: 600; font-size: 18px;
    text-transform: uppercase; color: #53545a; padding: 25px 15px;
}
.header-right-elements .nav-lang .dropdown-toggle img { margin-right: 5px; }
.header-right-elements .search-btn { font-size: 18px; padding: 25px 15px; color: #53545a; }
.header-right-elements .search-btn:hover { color: var(--main-color); }

/* ========================================================= */
/* == STYLE ORIGINAL POUR LA GRILLE DE PRODUITS AVEC OVERLAY == */
/* ========================================================= */

/* Le conteneur de la grille de produits */
.product-grid-overlay {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 colonnes par défaut */
    gap: 25px;
    padding: 40px 0;
}

/* Style de chaque carte de produit */
.product-card-overlay {
    position: relative; /* Indispensable pour l'overlay */
    overflow: hidden; /* Cache l'overlay qui dépasse */
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    aspect-ratio: 1 / 1; /* Force un format carré parfait */
}

/* L'image du produit */
.product-card-overlay img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Assure que l'image remplit la carte sans être déformée */
    transition: transform 0.4s ease;
}

/* Le volet d'information (caché par défaut) */
.card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(to top, rgba(16, 109, 190, 0.9), rgba(3, 69, 168, 0.5));
    color: white;
    
    /* On le cache en le déplaçant vers le bas */
    transform: translateY(100%);
    transition: transform 0.4s ease-in-out;
}

/* L'EFFET : Quand on survole la carte... */
.product-card-overlay:hover img {
    transform: scale(1.1); /* On zoome légèrement sur l'image */
}

.product-card-overlay:hover .card-overlay {
    transform: translateY(0); /* On fait glisser l'overlay en position */
}

/* Style du contenu de l'overlay */
.overlay-title {
    font-family: 'Urbanist', sans-serif;
    font-size: 1.4em;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: white !important;
}

.overlay-buttons {
    display: flex;
    gap: 10px;
}

.overlay-button {
    flex: 1;
    padding: 10px;
    background-color: var(--highlight-color);
    color: white !important;
    text-decoration: none;
    text-align: center;
    border-radius: 5px;
    font-weight: 600;
    font-size: 12px;
    transition: background-color 0.3s ease;
}

.overlay-button:hover {
    background-color: #fff;
    color: var(--highlight-color) !important;
}

/* --- Styles pour les différentes tailles d'écran (Responsive) --- */
@media (max-width: 1200px) {
    .product-grid-overlay { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 992px) {
    .product-grid-overlay { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
    .product-grid-overlay { grid-template-columns: repeat(1, 1fr); }
}


/* ========================================================= */
/* == STYLE POUR L'IMAGE AU SURVOL D'UN TEXTE             == */
/* ========================================================= */

.image-survol-conteneur {
  position: relative; /* Indispensable pour positionner l'image */
  border-bottom: 2px dotted var(--highlight-color); /* Souligné pointillé pour montrer que c'est interactif */
  cursor: help; /* Le curseur de la souris change en point d'interrogation */
}

.image-survol-cachee {
  /* On cache l'image par défaut */
  opacity: 0;
  visibility: hidden;
  
  /* Style et position */
  position: absolute;
  bottom: 130%; /* S'affiche au-dessus du texte avec une petite marge */
  left: 50%;
  transform: translateX(-50%); /* Centre l'image horizontalement */
  z-index: 10;
  width: 200px; /* Largeur de l'image qui apparaît */
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0,0,0,0.15);
  
  /* Transition pour une apparition douce */
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Quand on survole le conteneur parent, on affiche l'image enfant */
.image-survol-conteneur:hover .image-survol-cachee {
  opacity: 1;
  visibility: visible;
}
/* ================================================================= */
/* == STYLE POUR PAGE PRODUITS AVEC FILTRE INTERACTIF             == */
/* ================================================================= */

/* --- 1. MISE EN PAGE PRINCIPALE (BARRE LATERALE + GRILLE) --- */
.product-filter-page {
    display: grid;
    grid-template-columns: 280px 1fr; /* Colonne fixe de 280px pour le filtre, le reste pour la grille */
    gap: 40px;
    padding: 40px 0;
}

/* --- 2. STYLE DE LA BARRE LATÉRALE DE FILTRES --- */
.product-filters h3 {
    font-family: 'Urbanist', sans-serif;
    font-size: 20px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--main-color);
    padding-bottom: 15px;
    border-bottom: 2px solid #eee;
    margin-bottom: 20px;
}

.product-filters ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.product-filters ul li {
    margin-bottom: 12px;
}

/* Style personnalisé pour les cases à cocher */
.product-filters .checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    color: #333;
}

.product-filters input[type="checkbox"] {
    display: none; /* On cache la case à cocher par défaut */
}

.product-filters .checkbox-custom {
    width: 20px;
    height: 20px;
    border: 2px solid #ccc;
    border-radius: 4px;
    margin-right: 12px;
    display: inline-block;
    position: relative;
    transition: all 0.3s ease;
}

/* Style de la coche (check mark) */
.product-filters .checkbox-custom::after {
    content: '';
    position: absolute;
    display: none;
    left: 6px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

/* Quand la case est cochée */
.product-filters input[type="checkbox"]:checked + .checkbox-custom {
    background-color: var(--highlight-color);
    border-color: var(--highlight-color);
}

.product-filters input[type="checkbox"]:checked + .checkbox-custom::after {
    display: block;
}

/* --- 3. STYLE DE LA GRILLE DE PRODUITS --- */
.product-grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 produits par ligne */
    gap: 25px;
}

.product-item-filterable {
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    transition: all 0.4s ease;
}

.product-item-filterable:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.product-item-filterable .product-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    background-size: cover;
    background-position: center;
}

.product-item-filterable .product-info {
    padding: 20px;
}
.product-item-filterable h4 {
    font-family: 'Urbanist', sans-serif;
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 15px 0;
}
.product-item-filterable .product-buttons { display: flex; gap: 10px; }
.product-item-filterable .product-button {
    flex: 1; padding: 8px; background-color: #f0f0f0; color: #333;
    text-align: center; text-decoration: none; border-radius: 5px;
    font-size: 12px; font-weight: 600; transition: all 0.3s ease;
}
.product-item-filterable .product-button:hover { background-color: var(--highlight-color); color: white; }

/* --- RESPONSIVE --- */
@media (max-width: 992px) {
    .product-filter-page { grid-template-columns: 1fr; }
    .product-grid-container { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
    .product-grid-container { grid-template-columns: 1fr; }
}