:root{
--pente:min(4.4vw, 80px);
}

#entete{
top:0;
left: 50%;
position:fixed;
text-align:center;
transform: translateX(-50%);
transition:all ease 0.5s;
width:100%;
display:block;
z-index:998;
height:190px;
--trait:2px;                /* thickness of the light blue edge */
background:var(--bleu3);    /* edge color, adjust if needed */
clip-path:polygon(0 0,100% 0,100% calc(100% - var(--pente)),0 100%);
}
/* Dark fill, same shape shifted up by --trait to reveal the edge line */
#entete::after{
content:"";
position:absolute;
inset:0 0 var(--trait) 0;
background:var(--bleu3);
clip-path:polygon(0 0,100% 0,100% calc(100% - var(--pente)),0 100%);
z-index:-1;
pointer-events:none;
}

/* Home page, desktop : the header overlays the slideshow, no background,
   until the page is scrolled past 100px (.is-scrolled, set by the header JS) */
#entete::after{
transition:background ease .5s;
}
@media screen and (min-width: 861px) {
  body:has(.page.home) #entete:not(.is-scrolled),
  body:has(.page.home) #entete:not(.is-scrolled)::after{
    background:transparent;
  }
}

.page.home .ss-slideshow::after{
content:"";
position:absolute;
left:0;
right:0;
bottom:0;
height:var(--pente);
background:var(--gris);
clip-path:polygon(100% 0,100% 100%,0 100%);
z-index:3;               /* above the slides (2), below the fixed text (4) and arrows/dots (5) */
pointer-events:none;
}

.entete{
max-width:1280px;
margin:auto;
height:120px;
display:flex;
align-items:end;
/* justify-content:space-between; */
position:relative;
}

/* social */
.bandeauMetiers .social{
display:flex;
align-items:center;
display:none;
}
.bandeauMetiers .social a{
display:block;
width:24px;
height:24px;
border:none;
padding:0;
margin:0 3px 0 0;
}
.bandeauMetiers .social a:hover{
transform:none;  
}
.bandeauMetiers .social a svg{    
fill:var(--bleu);
display:block;
}
.bandeauMetiers .social a:hover svg{    
fill:var(--bleu2);
}

.entete .logo{
position:absolute;
left:80px; 
height:100px;
width:100px;
display:flex;
align-items:center;
}
.entete .logo svg{
height:100%;
width:100%;
max-width:100%;
max-height:100%;
}


.entete .menu{
box-sizing:border-box;
transition:all ease 0.5s;
position:absolute;
z-index:999;
width:auto;
right:0;
/* background:#ff00004a; */
top:50%;
transform:translateY(-50%);
}
.menu ul{
list-style:none;
padding:0;
margin:0;
display:flex;
align-items:center;
}
.menu li{
padding:0 .75vw;
}
.menu li a{
font-optical-sizing: auto;
font-style: normal;
/* text-transform:uppercase; */
font-weight:500;
text-decoration:none;
white-space:nowrap;
transition:all 0.3s ease;
line-height:50px;
display:inline-block;
position:relative;
color:var(--blanc);
letter-spacing: 0px;
font-size: clamp(0.5vw, 1.1em, 1.3vw);
}
.menu li a::after,
.menu li.open a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 5px;
    background:linear-gradient(to right, #ffffff00, var(--rose));
    border-radius: 5px;
    width: 0;
    transition: width 0.5s ease;
}
.menu li a:hover::after,
.menu li.open a::after {
    width: 100%;
    background:linear-gradient(to right, #ffffff00, var(--rose));
}
 .menu li.open a,
.menu li a:hover{
color:var(--rose)!important;
}

/* ==========================================================
   RESPONSIVE
   Header switches to burger at 860px. All breakpoints live here.
   ========================================================== */

/* ---------- Desktop guard ---------- */

/* ---------- <= 1100px : tighten the desktop nav ---------- */
@media screen and (max-width: 1100px) {
  /* The desktop clamp() caps at 1.3vw, which is unreadable below ~1100px */
  .menu li a { font-size: 1em; }
  .menu li { padding: 0 .5vw; }
}
@media screen and (max-width: 980px) {
  .menu li a { font-size: .92em; }
  .menu li { padding: 0 .4vw; }
}

/* ---------- <= 860px : burger mode ---------- */
@media screen and (max-width: 860px) {

  /* Decorative corner shape, scaled to the 100px header (65/190 ratio) */
  #entete::before {
    height: 100px;
    width: 34px;
  }

  /* Top bars */
  #entete .bandeauMetiers,
#entete .bandeau,
.entete .liens,
.entete .menu{
    display: none;
  }

  .entete {
    height: 100px;
    display: flex;
    align-items: center;
    padding: 0 18px 0 44px;            /* left: clears the corner shape */
    box-sizing: border-box;
  }

  .entete .logo {
    position: relative;
    top: auto;
    left: auto;
    height: 100%;
    display: flex;
    align-items: center;
    z-index: 1002;
  }
  .entete .logo .img2 {
    width: 230px;
    height: auto;
    max-height: 95px;
    padding: 0;
  }

}

/* ---------- <= 380px : small phone ---------- */
@media screen and (max-width: 380px) {
  .entete {
    height: 90px;
    padding: 0 12px 0 36px;
  }
  #entete::before {
    height: 90px;
    width: 31px;
  }
  .entete .logo .img2 {
    width: 140px;
    max-height: 74px;
  }
}

/* ==========================================================================
   En-tête mobile (nov. 2026) : barre compacte, logo calé en haut à 20px,
   bouton Menu (module menu) en haut à droite
   ========================================================================== */
@media screen and (max-width:860px){
  /* Hauteur = barre + biseau (et non plus les 190px du desktop qui recouvraient le haut de la page) */
  #entete{height:calc(100px + var(--pente));}
  .entete{align-items:flex-start;padding:20px 20px 0 20px;}
  /* Logo : même écart (20px) avec le haut qu'avec le bord gauche */
  .entete .logo{height:auto;align-items:flex-start;}
  .entete .logo .img2{width:auto;max-height:none;}
  .entete .logo .img2 svg{height:72px;width:auto;}
  /* Le module menu ne garde que le burger (menuBurger.css) : réaffiché, à droite, centré sur le logo */
  .entete .menu{display:block;right:20px;top:56px;}   /* 20px + 72px / 2 */
  .entete .menu .menu-level1{gap:0;}
}
@media screen and (max-width:380px){
  #entete{height:calc(90px + var(--pente));}
  .entete .logo .img2 svg{height:64px;}
  .entete .menu{right:20px;top:52px;}                 /* 20px + 64px / 2 */
}
