
/* Cacher le custom-menu par défaut */
#custom-menu {
  display: none;
}


/* Styles spécifiques pour les écrans entre 993px et 1200px */
@media (min-width: 769px) and (max-width: 1200px) {
	
	
	.menu-decale {
  margin-left: 50px; /* ajuste la valeur selon ton besoin */
}
		.menu-decale2 {
  margin-left: 39px; /* ajuste la valeur selon ton besoin */
}
	
	
	
	
	#custom-menu {
    display: block;
  }
  
  
  #custom-menu .line-break {
  flex-basis: 100%;
  height: 0;
}
  
  
    .header .logo img {
    margin-left: 10px;
  
  }
  
  
  
   .logo-albedo {
    max-height: 15px;
  margin-right: 2px;
  }



  /* Base */
  .custom-navmenu {
    /* background: #fff; */
    font-family: Arial, sans-serif;
  }

  .custom-main-menu,
  .custom-submenu,
  .custom-subsubmenu {
    list-style: none;
    margin: 0;
    padding: 0;
	
  }

  .custom-main-menu {
	  transform: translateX(-90px);
    display: flex;
    flex-wrap: wrap; /* <<< permet d'aller à la ligne */
    justify-content: center;
    align-items: center;
    gap: 5px;
	padding: 0 35px;
  }


.custom-main-menu > li {
  flex: 0 1 auto;
  max-width: none; /* ou 150px si tu veux une limite douce */
  text-align: center;
  white-space: nowrap;
}



/* Ajustement taille police et padding pour tout faire tenir */
.custom-main-menu a {
  font-size: 16px;
  padding: 4px 8px;
}



  /* On force les 4 premiers éléments sur la première ligne 
  .custom-main-menu > li:nth-child(-n+4) {
    flex: 1 1 auto;
  }

  /* On force les suivants (à partir du 5e) sur une nouvelle ligne 
  .custom-main-menu > li:nth-child(n+5) {
    flex-basis: 20%; /* largeur fixe pour les petits items dessous 
    text-align: center;
  }
*/


  .custom-main-menu a {
    display: block;
    padding: 10px 20px;
    color: #222;
    text-decoration: none;
  }

  .custom-active {
    font-weight: bold;
    /* border-bottom: 2px solid #0c8346; */
  }

  /* Sous-menu principal */
  .custom-submenu {
	   margin-bottom: 5px;  /* Ajouter un léger espacement entre les éléments */
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    min-width: 200px;
    z-index: 1000;
  }
  
  
  /* Réduit la largeur du sous-menu de "Références" uniquement */
.references-item .custom-submenu {
  min-width: 160px; /* ou autre valeur plus petite que 200px */
}

  
  .references-item .custom-subsubmenu {
  min-width: 160px;
}

  
  .references-item .custom-submenu a,
.references-item .custom-subsubmenu a {
  font-size: 13px;
  padding: 6px 10px;
    text-align: left;
  justify-content: flex-start; /* pour les flexbox éventuelles */
}

  
   /* Affichage par la classe .show (activé par JS) */
  .custom-submenu.show {
    display: block;
  }
  

  .custom-menu-item:hover .custom-submenu {
    display: block;
  }

  .custom-submenu > li {
    position: relative;
  }

  .custom-submenu a:hover {
    background-color: #e6f4ec;
    color: #0c8346;
  }

  /* Sous-sous-menu */
  .custom-subsubmenu {
    display: none;
    position: absolute;
    top: 0;
    left: 90%;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    min-width: 200px;
  }

  .custom-has-submenu:hover .custom-subsubmenu {
    display: block;
  }
  
  
    /* Affichage par la classe .show (activé par JS) */
  .custom-subsubmenu.show {
    display: block;
  }
  
  
  
  /* Centrage des flèches */
.custom-submenu-toggle,
.custom-has-submenu > a {
  display: inline-flex;
  align-items: center;  /* Cela va centrer verticalement le texte et la flèche */
  justify-content: space-between; /* Espace entre le texte et la flèche */
  width: 100%;  /* Lien occupe toute la largeur de l'élément parent */
}
  
  


  /* Flèches */
  .custom-submenu-toggle::after {
    content: " ▼";
    font-size: 0.7em;
  }

  .custom-has-submenu > a::after {
    content: " ▶";
    float: right;
    font-size: 0.7em;
    margin-left: 5px;
  }
}





@media (min-width: 800px) and (max-width: 950px) {
	.custom-main-menu {
	   transform: translateX(-90px);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 5px;
    padding: 0 35px;
	}
	
	
	.custom-main-menu .line-break {
  flex-basis: 100%;
  height: 0;
}
	
  .custom-main-menu li a[href="./index.html#competences"] {
    margin-left: -23px; /* rapproche légèrement de l'élément précédent */
  }
  
   .custom-main-menu li a[href="../index.html#services"] {
    margin-left: -15px; /* Ajuste à -5px ou -15px selon besoin */
   }
   
     .custom-main-menu li a[href="../index.html#recrutement"] {
    margin-left: -35px; /* Ajuste à -5px ou -15px selon besoin */
   }
  
  
}



