/*
Theme Name: Divi-child
Description: Theme enfant de Divi. Vous pouvez maintenant effectuer vos modifications en toute sécurité.
Author: WPMarmite
Author URI: https://wpmarmite.com
Template: Divi
Version: 1.0
*/


body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, sans-serif;
}

html {
    font-display: swap;
}

.et_pb_section:last-of-type {
    padding-bottom: 0 !important;
}



/* Sous-menus desktop uniquement */
@media (min-width: 769px) {
	.nav-menu li:hover > ul { 
		display: block; 
	}
	
	.nav-menu li ul li a:hover {
		background-color: #f5faff;
	}
}

/* =========================
	OPTI LCP
==========================*/
.et_pb_section {
  min-height: 1px;
}

/*.et_pb_image img,
.et_pb_code iframe,
.lottie-animation {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
}*/

#et-main-area {
  min-height: 100vh;
  overflow-anchor: none;
}


img {
  aspect-ratio: attr(width) / attr(height);
  display: block;
}

.et_pb_module, body, h1, h2, h3, h4, h5, h6 {
  font-display: swap;
}

/*img.wp-image-542,
.et_pb_image img {
  aspect-ratio: 524 / 377;
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
}*/

html {
  font-display: swap;
}


/* =========================
	GENERAL
=========================*/
.et_pb_module_header:before,
.et_pb_module_header:after {
  display: none !important;
}

.responsive-title {
    background-color: #b0d229;
    color: white !important;
    padding: 10px 10px;
    border-radius: 0px;
    font-weight: bold;
    text-align: center;
    display: inline;
    line-height: 2;
    box-decoration-break: clone;
	
    -webkit-box-decoration-break: clone;
    padding-top: 2px;
    padding-bottom: 5px;
}



/* --------------- TITRE H3 ----- */
.title-border .et_pb_text_inner > * {
  position: relative;
  margin: 0;
  line-height: 1.05;
  padding-left: 14px;
  border-left: none !important;
}

.title-border .et_pb_text_inner > *::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-80%);
  width: 5px;
  height: 0.9em;
  background: #9acd32;
  }



/* --------------- BOUTON HAUT DE PAGE ----- */
.back-to-top {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
}

/* -------------- COMPTEUR -------------*/
.counter-wrapper {
  text-align: center;
  font-family: 'PT Sans', sans-serif;
  margin: 3rem auto;
  line-height: 1.2;
}

/* Ligne principale */
.counter-line {
  display: flex;
  justify-content: center;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 10px;
}

/* Préfixe (+ DE) */
.counter-wrapper .prefix {
  color: #B0D229;
  text-transform: uppercase;
  font-weight: 700;
  font-size: clamp(24px, 3vw, 42px);
  letter-spacing: 1px;
}

/* Nombre (2500) */
.counter-wrapper .counter {
  font-size: clamp(48px, 8vw, 96px);
  font-weight: 800;
  color: #0f96bc;
  line-height: 1;
  letter-spacing: -1px;
  display: inline-block;
  min-width: 120px;
}

/* Suffixe sur la 2e ligne */
.counter-wrapper .suffix {
  display: block;
  text-transform: uppercase;
  font-size: clamp(14px, 1.4vw, 18px);
  font-weight: 600;
  color: #B0D229;
  letter-spacing: 3px;
  margin-top: 10px;
  opacity: 0.9;
}



/* --------------- ACCORDÉON ----------------- */
.faq-accordion .et_pb_toggle .et_pb_toggle_icon { 
  display: none !important; 
}

.faq-accordion .et_pb_toggle .et_pb_toggle_title {
  display: flex;
  align-items: center;   
  justify-content: space-between;
  padding-right: 0;     
  position: relative;
}

.faq-accordion .et_pb_toggle .et_pb_toggle_title:after {
  content: "\3a";  
  font-family: "ETmodules";
  font-size: 20px;
  color: #0F96BC;
  margin-left: 12px;  
  transition: transform .25s ease;
}

.faq-accordion .et_pb_toggle.et_pb_toggle_open .et_pb_toggle_title:after {
  transform: rotate(180deg);
}

.faq-accordion .et_pb_toggle .et_pb_toggle_icon,
.faq-accordion .et_pb_toggle .et_pb_toggle_title:before {
  display: none !important;
}

/* TAILLE SVG DANS WP GRID */
.wp-grid-builder .wpgb-card [class*=wpgb-block-] svg{
	width: auto !important;
	height: 59px !important;
}


/* -------------------ÉTAPE CLÉS-------------- */
body {
  counter-reset: etape;
}

.bloc-etape {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.etape-icone svg {
  width: 54px;
  height: 54px;
  flex-shrink: 0;
}

.etape-texte {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.etape-titre {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin-bottom: 0.2rem;
}

.etape-num::before {
  counter-increment: etape;
  content: counter(etape, decimal-leading-zero);
  font-size: 28px;
  font-weight: 800;
  color: transparent;
  -webkit-text-stroke: 1.4px #0F96BC;
  text-stroke: 1.4px #0F96BC;
  font-family: 'Arial Black', 'Helvetica Neue', sans-serif;
  line-height: 1;
  letter-spacing: -0.5px;
}

.etape-label {
  color: #0F96BC;
  font-weight: 700;
  font-size: 17px;
  text-transform: uppercase;
  line-height: 1.3;
  letter-spacing: 0.5px;
}

.etape-desc {
  font-size: 1rem;
  color: #222;
  opacity: 0.9;
  font-style: italic;
  margin-left: 2.6rem;
  line-height: 1.5;
}




/* =========================
   HEADER
========================= */

/* Base */
.header-custom{
  box-shadow : 0 4px 10px rgba(0, 0, 0, 0.04) ;
  background-color : #fff ;
  position : relative ;
  z-index : 999 ;
  transition : padding .4s ease, box-shadow .4s ease, background-color .4s ease ;
  overflow-x : clip ;
}
.container{
  max-width : 1240px ;
  margin : 0 auto ;
  padding : 0 2rem ;
}

/* Niveau 1 – bande infos */
.header-top .container{
  display : flex ;
  justify-content : flex-end ;
}
.header-infos{
  display : flex ;
  align-items : center ;
  gap : clamp(12px, 2vw, 32px) ;
  background-color : #e5f3b245 ;
  padding : clamp(8px, 1.2vw, 15px) clamp(10px, 1.6vw, 20px) ;
  border-radius : 8px ;
}
.header-infos .social-icons{
  display : flex ;
  align-items : center ;
  gap : clamp(6px, .8vw, 12px) ;
}
.header-infos .social-icons a{
  color : #000 ;
  text-decoration : none ;
  transition : opacity .3s ease ;
}
.header-infos .social-icons a:hover{
  opacity : .7 ;
}
.header-infos .phone{
  margin : 0 ;
  padding : 0 ;
  line-height : 1 ;
}
.phone span{
  line-height : 1 ;
  font-weight : 700 ;
  color : #b2cf61 ;
  font-size : 18px ;
  font-family : 'PT Sans' ;
}

/* Niveau 2 – logo + menu */
.header-bottom{
  padding : 1rem 0 ;
}
.header-bottom .container{
  display : flex ;
  align-items : center ;
  justify-content : space-between ;
  gap : clamp(12px, 2.4vw, 40px) ;
  padding-inline : clamp(12px, 2.2vw, 32px) ;
  min-width : 0 ;
  flex-wrap : nowrap ;
}

/* Logo */
.header-custom .logo{
  display : flex ;
  align-items : center ;
  flex : 0 0 auto ;
}
.header-custom .logo svg{
  display : block ;
  height : clamp(46px, 5.4vw, 70px) ;
  width : auto ;
  object-fit : contain ;
  transition : transform .4s ease ;
}

/* Menu (desktop) */
.header-custom .menu-header{
  display : flex ;
  align-items : center ;
  flex : 1 1 auto ;
  min-width : 0 ;
}
.header-custom .nav-menu{
  display : flex ;
  justify-content : flex-end ;
  align-items: center;
  list-style : none ;
  margin : 0 ;
  padding : 0 ;
  flex : 1 1 auto ;
  min-width : 0 ;
  flex-wrap : nowrap !important ;
  gap : clamp(6px, 1.2vw, 16px) ;
}
.header-custom .nav-menu > li{
  position : relative ;
  padding : 0 ;
  text-transform : uppercase ;
  letter-spacing : .5px ;
  flex : 0 1 auto ;
  min-width : 0 ;
}
.nav-menu > li a{
  color : #000 !important ;
  text-decoration : none ;
  font-weight : 500 ;
  position : relative ;
  transition : color .3s ;
  padding : clamp(6px, .9vw, 16px) 0 ;
  font-size : clamp(12px, 1.05vw, 16px) ;
  letter-spacing : clamp(.1px, .04vw, .5px) ;
  line-height : 1.2 ;
  white-space : nowrap ;
}

/*Onglet Simulateur solaire*/
.simulateur-solaire-link {
  background-color: #B0D229;
  padding:5px !important;
}


/* Sous-menus (desktop) */
.nav-menu li ul{
  display : none ;
  position : absolute ;
  top : 110% ;
  left : 0 ;
  z-index : 999 ;
  background-color : #fff ;
  min-width : clamp(180px, 20vw, 240px) ;
  box-shadow : 0 12px 24px rgba(0, 0, 0, 0.08) ;
  border-radius : .5rem ;
  overflow : hidden ;
  padding : .5rem 0 ;
  animation : fadeIn .2s ease-out ;
}
.nav-menu li ul li a{
  display : block ;
  padding : clamp(8px, 1vw, 16px) clamp(12px, 1.2vw, 24px) ;
  color : #222 ;
  text-decoration : none ;
  font-weight : 500 ;
  transition : background-color .2s ease ;
}
@keyframes fadeIn{
  from{ opacity : 0 ; transform : translateY(-10px) ; }
  to{ opacity : 1 ; transform : translateY(0) ; }
}

/* Burger */
.header-custom .menu-toggle{
  display : none ;
  background : none ;
  border : 0 ;
  cursor : pointer ;
  padding : 10px ;
  position : relative ;
  z-index : 1001 ;
  flex-direction : column ;
  gap : 4px ;
}
.header-custom .menu-toggle .bar{
  display : block ;
  width : 25px ;
  height : 3px ;
  background-color : #000 ;
  transition : transform .3s ease, opacity .3s ease ;
  transform-origin : center ;
}
.header-custom .menu-toggle.active .bar:nth-child(1){
  transform : rotate(45deg) translate(6px, 6px) ;
}
.header-custom .menu-toggle.active .bar:nth-child(2){
  opacity : 0 ;
}
.header-custom .menu-toggle.active .bar:nth-child(3){
  transform : rotate(-45deg) translate(4px, -4px) ;
}

/* Sticky */
.header-custom.sticky-header .header-bottom{
  position : fixed ;
  top : 0 ;
  left : 0 ;
  right : 0 ;
  background : #fff ;
  z-index : 1000 ;
  box-shadow : 0 4px 12px rgba(0, 0, 0, .08) ;
  padding : .5rem 0 ;
}
.header-custom.sticky-header .logo svg{
  height : 50px ;
  transition : height .25s ease ;
}
.admin-bar .header-custom.sticky-header .header-bottom{
  top : 32px ;
}
@media (max-width: 782px){
  .admin-bar .header-custom.sticky-header .header-bottom{
    top : 46px ;
  }
}

/* Serrage doux avant burger */
@media (max-width: 900px) and (min-width: 769px){
  .header-custom .logo svg{ height : 44px ; }
  .header-custom .nav-menu{ gap : 8px ; }
  .header-custom .nav-menu > li > a{
    font-size : 13px ;
    padding-block : 6px ;
  }
}

/* soulignement page active */
@media (min-width: 901px) {
  .nav-menu > li.current-menu-item > a,
  .nav-menu > li.current-menu-ancestor > a {
    position: relative;
    color: #0f96bc !important;
  }
    .nav-menu > li.current-menu-item:last-child > a,
    .nav-menu > li.current-menu-ancestor:last-child > a {
    color:#000 !important;
  }

  .nav-menu > li.current-menu-item > a::after,
  .nav-menu > li.current-menu-ancestor > a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 4px; /* distance ajustée */
    width: 100%;
    height: 2px;
    background-color: #0f96bc; /* couleur mise à jour */
    transform: scaleX(1);
    transition: transform 0.3s ease;
  }

  .nav-menu > li > a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 4px; /* distance ajustée */
    width: 100%;
    height: 2px;
    background-color: #0f96bc; /* couleur mise à jour */
    transform: scaleX(0);
    transition: transform 0.3s ease;
  }

  .nav-menu > li > a:hover::after {
    transform: scaleX(1);
  }
}

/* Désactivation du hover et du soulignement en mobile */
@media (max-width: 900px) {
  .nav-menu > li > a,
  .nav-menu > li.current-menu-item > a,
  .nav-menu > li.current-menu-ancestor > a {
    color: #000 !important;
  }

  .nav-menu > li > a::after,
  .nav-menu > li.current-menu-item > a::after,
  .nav-menu > li.current-menu-ancestor > a::after {
    content: none !important;
  }
}



/* =========================
   MOBILE / BURGER ≤ 903px
========================= */
@media (max-width: 903px){

  /* Top bar */
  .header-infos{
    gap : 1rem ;
    flex-wrap : wrap ;
    justify-content : center ;
    padding : 10px 15px ;
  }
  .header-infos .social-icons{ gap : .5rem ; }
  .phone span{ font-size : 16px ; }

  /* Structure */
  .header-bottom .container{
    justify-content : space-between ;
    position : relative ;
  }
  .header-custom .menu-header{ display : none ; }
  .header-custom .menu-toggle{ display : flex ; }

  /* Overlay */
  .header-custom .menu-header.mobile-menu-open{
    display : flex ;
    position : fixed ;
    inset : 0 ;
    width : 100vw ;
    height : 100vh ;
    background : #fff ;
    z-index : 1000 ;
    flex-direction : column ;
    justify-content : center ;
    align-items : center ;
    animation : slideInRight .3s ease-out ;
    overflow-y : auto ;
  }
  .header-custom .menu-header.mobile-menu-closing{
    animation : slideOutRight .3s ease-in forwards ;
  }
  @keyframes slideInRight{
    from{ transform : translateX(100%) ; }
    to{   transform : translateX(0) ; }
  }
  @keyframes slideOutRight{
    from{ transform : translateX(0) ; }
    to{   transform : translateX(100%) ; }
  }

  /* Liste verticale lisible */
  .header-custom .nav-menu{ gap : 0 ; }
  .mobile-menu-open .nav-menu{
    flex-direction : column ;
    gap : 0 ;
    padding : 0 ;
    text-align : center ;
    width : 100% ;
  }
  .mobile-menu-open .nav-menu > li{
    padding : 0 ;
    width : 100% ;
    border-bottom : 1px solid #f0f0f0 ;
  }
  .mobile-menu-open .nav-menu > li > a{
    font-size : 20px ;
    line-height : 1.35 ;
    padding : 20px ;
    letter-spacing : 1px ;
    color : #000 !important ;
    display : flex ;
    justify-content : center ;
    align-items : center ;
    position : relative ;
    cursor : pointer ;
    transition : none ;
    white-space : normal ;
    text-transform : uppercase ;
    font-weight : 600 ;
  }

  /* Flèche sous-menu */
  .mobile-menu-open .nav-menu > li.menu-item-has-children > a::after{
    content : '›' ;
    font-size : 1.5rem ;
    font-weight : 700 ;
    position : absolute ;
    right : 20px ;
    transform : rotate(90deg) ;
    transition : transform .3s ease ;
  }
  .mobile-menu-open .nav-menu > li.menu-item-has-children.submenu-open > a::after{
    transform : rotate(270deg) ;
  }

  /* Sous-menus mobile */
  .mobile-menu-open .menu-item-has-children .sub-menu{
    position : static !important ;
    background : transparent !important ;
    box-shadow : none !important ;
    border-radius : 0 !important ;
    padding : 0 !important ;
    margin : 0 !important ;
    overflow : hidden !important ;
    max-height : 0 !important ;
    opacity : 0 !important ;
    transition : max-height .4s ease, opacity .4s ease !important ;
    width : 100% !important ;
    display : block !important ;
  }
  .mobile-menu-open .submenu-open .sub-menu{
    max-height : 500px !important ;
    opacity : 1 !important ;
  }
  .mobile-menu-open .nav-menu li .sub-menu li{
    opacity : 0 ;
    transform : translateY(-10px) ;
    transition : opacity .3s ease, transform .3s ease ;
    width : 100% ;
    border-bottom : 1px solid #f0f0f0 ;
  }
  .mobile-menu-open .nav-menu li.submenu-open .sub-menu li{
    opacity : 1 ;
    transform : translateY(0) ;
  }
  .mobile-menu-open .nav-menu li .sub-menu li:nth-child(1){ transition-delay : .10s ; }
  .mobile-menu-open .nav-menu li .sub-menu li:nth-child(2){ transition-delay : .15s ; }
  .mobile-menu-open .nav-menu li .sub-menu li:nth-child(3){ transition-delay : .20s ; }
  .mobile-menu-open .nav-menu li .sub-menu li:nth-child(4){ transition-delay : .25s ; }
  .mobile-menu-open .nav-menu li .sub-menu li a{
    font-size : 18px ;
    line-height : 1.35 ;
    padding : 16px 20px ;
    letter-spacing : .5px ;
    color : #000 !important ;
    display : flex ;
    align-items : center ;
    justify-content : center ;
    text-transform : uppercase ;
    font-weight : 500 ;
    transition : none ;
  }

  /* Neutralise le nowrap desktop en mobile */
  .header-custom .nav-menu > li > a{
    white-space : normal ;
  }
}




/* FOOTER PERSONNALISÉ ========================================================= */

.footer-custom {
	background-color: #1e242c;
	color: white;
	padding: 3rem 0 0 0;
	position: relative;
}

.footer-custom .container {
	max-width: 1240px;
	margin: 0 auto;
	padding: 0 2rem;
}

/* GRID LAYOUT ========================================================= */

.footer-grid {
	display: grid;
	grid-template-columns: 1fr 1fr 1fr;
	gap: 3rem;
	align-items: start;
	padding-bottom: 2rem;
}

/* COLONNE 1 : LOGO + CITATION ========================================================= */

.footer-col.col-1 {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
}

.footer-logo svg {
	height: 60px;
	width: auto;
	margin-bottom: 1.5rem;
}

.citation-footer {
	font-style: italic;
	font-size: 0.9rem;
	line-height: 1.6;
	color: #b8c5d1;
	margin: 0;
	font-weight: 300;
}

/* COLONNE 2 : ADRESSE ========================================================= */

.footer-col.col-2 address {
	font-style: normal;
	margin: 0;
}

.footer-col.col-2 address p {
	margin: 0;
	line-height: 1.8;
	font-size: 0.95rem;
	color: white;
	font-weight: 400;
}

/* COLONNE 3 : LOGOS + LIENS ========================================================= */

.footer-col.col-4 {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 2rem;
	text-align: right;
}

.footer-partners {
	display: flex;
	gap: 1rem;
	align-items: center;
}

.footer-partners svg {
	height: 50px;
	width: auto;
}

.footer-links-logos {
	display: flex;
	flex-direction: column;
	gap: 0.8rem;
	align-items: flex-end;
}

.footer-links-logos a {
	color: white;
	text-decoration: none;
	font-size: 0.95rem;
	font-weight: 500;
	transition: color 0.3s ease;
	text-align: right;
}

.footer-links-logos a:hover {
	color: #b2cf61;
}

/* SIGNATURE EN BAS ========================================================= */

.footer-signature {
	background-color: #1e242c;
	padding: 5px;
	text-align: center;
	margin-top: 1rem;
}

.footer-signature p {
	margin: 0;
	font-size: 0.8rem;
	color: white;
	font-weight: 300;
}

.footer-signature a {
	color: white;
	text-decoration: none;
	transition: color 0.3s ease;
}

.footer-signature a:hover {
	color: white;
}

/* RESPONSIVE ========================================================= */

@media (max-width: 768px) {
	.footer-grid {
		grid-template-columns: 1fr;
		gap: 2rem;
		text-align: center;
	}
	
	.footer-col.col-1 {
		align-items: center;
	}
	
	.footer-col.col-4 {
		align-items: center;
	}
	
	.footer-links-logos {
		align-items: center;
	}
	
	.footer-links-logos a {
		text-align: center;
	}
	
	.citation-footer {
		text-align: center;
	}
	
	.footer-partners {
		justify-content: center;
	}
	
	.footer-custom {
		padding: 2rem 0 0 0;
	}
}