/*
 Theme Name:   GeneratePress Child
 Theme URI:    https://generatepress.com
 Description:  Default GeneratePress child theme
 Author:       Tom Usborne
 Author URI:   https://tomusborne.com
 Template:     generatepress
 Version:      0.1
*/

/* --- TYPO & GENERAL --- */
body.page-child p {
	font-size : 16px;
}

body.archive {
	background-color : #fbf8ea;
}

body.archive h1, body.archive h2 a{
	color : #4f153f;
}

body.archive .site-content {
	background-color : #fbf8ea;
}

body.archive .inside-article img {
	border-radius : 10px;
}
.inside-article header h1 {
	color : #4f153f;
}

body.page-child ul.wp-block-list li {
	font-size : 16px;
}

body.page-child h2 {
	margin-top : 40px;
}

body.page-child .site-content {
	margin-bottom : 20px !important;
}

body.page-child .gbp-button--primary {
	margin-top : 20px;
}


h2 {
	color : #4F153F;
}

.custom-h2-color { 
  color: #4F153F !important; 
}

.gb-text-accent { 
  color: #DBBF2F; 
  text-transform: uppercase; 
  font-weight: 600; 
  margin-bottom: 1rem; 
}

.text-center { 
  text-align: center; 
}

/* Image responsive */
.gb-image-styled { 
  width: 100%; 
  height: 100%; 
  object-fit: cover; 
  display: block; 
}

/* --- BOUTONS --- */
.gbp-button--primary {
  display: inline-block;
  padding: 12px 24px;
  text-decoration: none;
  font-weight: bold;
  border-radius: 5px;
  transition: 0.3s;
  border: 1px solid transparent;
}

/* Prune (Hover Jaune) */
.btn-style-prune, body.archive .read-more-container a {
  background-color: #4F153F !important;
  color: #DBBF2F !important;
  border-color: #4F153F !important;
}

.btn-style-prune:hover, body.archive .read-more-container a {
  background-color: #DBBF2F !important;
  color: #4F153F !important;
  border-color: #DBBF2F !important;
}

/* Jaune (Hover Prune) */
.btn-style-yellow {
  background-color: #DBBF2F !important;
  color: #4F153F !important;
  border-color: #DBBF2F !important;
}

.btn-style-yellow:hover {
  background-color: #4F153F !important;
  color: #DBBF2F !important;
  border-color: #4F153F !important;
}

/* === CAS 1 & 4 : STYLE BOXED (Contenu centré) === */
.style-boxed-beige { 
  background-color: rgba(219, 191, 47, 0.1); 
}

.style-boxed-white { 
  background-color: #ffffff; 
}

.custom-grid-boxed {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

/* Arrondi image uniquement sur les versions boxed */
.col-boxed-image .gb-image-styled { 
  border-radius: 5px; 
}

/* === CAS 2 & 3 : STYLE FULL SPLIT === */
.style-full-split-wrapper {
  width: 100%;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50%;
  margin-right: -50%;
  background-color: #ffffff;
  overflow: hidden;
}

.custom-full-flex {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  min-height: 600px;
}

/* Colonne Image (50%) */
.col-full-image {
  flex: 1;
  min-width: 50%;
  position: relative;
}

.col-full-image .gb-image-styled {
  border-radius: 0;
}

/* Colonne Texte (50% avec fond jaune) */
.col-full-text-bg {
  flex: 1;
  min-width: 50%;
  display: flex;
  align-items: center; /* Centre verticalement */
  background-color: rgba(219, 191, 47, 0.5);
  padding: 4rem; /* Padding global */
  box-sizing: border-box;
}

/* --- ALIGNEMENT DU CONTENU TEXTE --- */

/* Configuration de base (CAS 2 : Texte à droite) */
/* Le texte se colle à gauche (vers l'image) */
.col-full-text-bg .custom-text-inner {
  max-width: 600px;
  width: 100%;
  margin-right: auto; /* Pousse le reste à droite */
  margin-left: 0;     /* Colle à gauche */
}

/* Surcharge pour le CAS 3 (Texte à gauche) */
/* Si la colonne texte est le PREMIER élément, c'est qu'elle est à gauche. */
.col-full-text-bg:first-child .custom-text-inner {
  margin-left: auto;  /* Pousse le texte vers la droite (vers l'image) */
  margin-right: 0;
}

/* === CAS 5 : HERO OVERLAY === */
.style-hero-overlay {
  width: 100%;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50%;
  margin-right: -50%;
  min-height: 600px;
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-box-white {
  background-color: rgba(255, 255, 255, 0.9);
  padding: 60px;
  max-width: 800px;
  border-radius: 5px;
  margin: 20px;
}

/* === RESPONSIVE MOBILE === */
@media (max-width: 1024px) {
  /* Boxed */
  .custom-grid-boxed { 
    display: block; 
  }

  .col-boxed-image { 
    margin: 2rem 0; 
  }
  
  /* Full Split */
  .custom-full-flex { 
    flex-direction: column; 
  }

  .col-full-image, 
  .col-full-text-bg { 
    min-width: 100%; 
    width: 100%; 
  }
  
  /* IMPORTANT : L'image passe toujours en premier sur mobile */
  .col-full-image { 
    order: -1; 
    height: 300px; 
  }
  
  .col-full-text-bg { 
    padding: 3rem 20px; 
  }
}

@media (max-width: 1200px) {
  #top_header > div {
    padding-inline: 40px;
  }

  .site-footer > div {
    padding-inline: 40px;
  }
}

@media (max-width: 1000px) {
  #top_header > div {
    padding-inline: 10px;
  }

  .site-footer > div {
    padding-inline: 10px;
  }
}

/* HEADER & LAYOUT GÉNÉRAL */
header.site-header {
  box-shadow: 0px 8px 14px 0px rgba(0, 0, 0, 0.25);
}

body:not(.home, .archive) header {
  z-index: 2;
}

.one-container.left-sidebar .site-main {
  margin-top: 40px;
  margin-left: 20px;
  margin-right: 20px;
	margin-bottom : 40px;
}

/* ---- FORMULAIRE CONTACT FORM 7 --- */
.wpcf7-form {
  max-width: 600px;
  margin: 0 auto;
  font-family: inherit;
}

/* Label */
.wpcf7-form p label {
  font-weight: 600;
  color: #4F153F;
  display: block;
  margin-bottom: 6px;
}

/* Champs input + textarea */
.wpcf7-form-control.wpcf7-text,
.wpcf7-form-control.wpcf7-email,
.wpcf7-form-control.wpcf7-textarea {
  width: 100%;
  background: #ffffff;
  border: 1px solid #e1e1e1;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 16px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  transition: all 0.25s ease;
}

/* Focus amélioré */
.wpcf7-form-control:focus {
  border-color: #DBBF2F;
  box-shadow: 0 4px 12px rgba(219, 191, 47, 0.25);
  outline: none;
}

/* Textarea auto-adaptée */
.wpcf7-textarea {
  resize: vertical;
}

/* Bouton Envoyer */
.wpcf7-submit {
  background: #DBBF2F !important;
  color: #4F153F !important;
  border: none;
  border-radius: 8px;
  padding: 12px 28px;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

/* Hover bouton CF7 */
.wpcf7-submit:hover {
  background: #c5a729 !important;
  transform: translateY(-2px);
}

/* Spinner repositionné */
.wpcf7-spinner {
  margin-left: 12px !important;
}

/* Message de confirmation */
.wpcf7-response-output {
  border-radius: 8px;
  padding: 12px 15px;
  margin-top: 15px;
}

.wpcf7-form-control.wpcf7-select {
  width: 100%;
  background: #ffffff;
  border: 1px solid #e1e1e1;
  border-radius: 8px;
  padding: 12px 42px 12px 14px; /* place pour la flèche */
  font-size: 16px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  transition: all 0.25s ease;
  cursor: pointer;

  /* reset look natif */
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;

  /* flèche custom */
  background-image:
    linear-gradient(45deg, transparent 50%, #4F153F 50%),
    linear-gradient(135deg, #4F153F 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50%;
  background-size: 7px 7px, 7px 7px;
  background-repeat: no-repeat;
}

/* Focus comme tes inputs */
.wpcf7-form-control.wpcf7-select:focus {
  border-color: #DBBF2F;
  box-shadow: 0 4px 12px rgba(219, 191, 47, 0.25);
  outline: none;
}

/* Optionnel : état disabled */
.wpcf7-form-control.wpcf7-select:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

/* Optionnel : couleur du placeholder si tu utilises une première option "Choisir..." */
.wpcf7-form-control.wpcf7-select option[disabled] {
  color: #777;
}

/* TITRE SPÉCIFIQUE PAGE */
.page-id-274 h1 {
  color: #4F153F;
  text-shadow: 4.08px 4.08px 8.16px rgba(0, 0, 0, 0.25);
}

/* SMASH BALLOON / FACEBOOK FEED */
.cff-posts-wrap .cff-item .cff-media-link {
  display: none;
}

.cff-text {
  font-size: 15px;
  line-height: 1.1;
}

/* MENU PRINCIPAL / NAVIGATION */
@media (min-width: 769px) {
  .menu-item-has-children .dropdown-menu-toggle {
    display: none;
  }

  .main-navigation .main-nav ul li.menu-item-has-children > a {
    padding-right: 20px;
  }
}

.main-navigation:not(.toggled) ul li.sfHover > ul, 
.main-navigation:not(.toggled) ul li:hover > ul {
  border-radius: 10px;
}

/* ===========================
   Sidebar menu - Modern UI (Prune / Or / Beige)
   =========================== */

/* Container global */
.wp-block-advanced-sidebar-menu-pages {
  font-family: system-ui, "Segoe UI", Roboto, sans-serif;
  color: #2a1d24; /* sidebar-text */
}

/* Bloc principal */
.wp-block-advanced-sidebar-menu-pages .parent-sidebar-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  background: #fbf8ea; /* sidebar-bg (color-beige) */
  border-radius: 14px; /* radius-lg */
  border: 1px solid rgba(79, 21, 63, 0.15);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.06); /* shadow-soft */
  padding: 12px;
}

/* Lien parent (ex: Découvrir Lormes) */
.wp-block-advanced-sidebar-menu-pages .parent-sidebar-menu > li > a {
  display: block;
  padding: 12px 14px;
  border-radius: 10px; /* radius-md */
  font-weight: 600;
  text-decoration: none;
  color: #4F153F;
  background: rgba(79, 21, 63, 0.05);
  transition:
    background 160ms ease-out,
    color 160ms ease-out,
    transform 160ms ease-out;
}

/* Survol parent */
.wp-block-advanced-sidebar-menu-pages .parent-sidebar-menu > li > a:hover {
  background: #DBBF2F;
  color: #4F153F;
  transform: translateX(3px);
}

/* Parent actif */
.wp-block-advanced-sidebar-menu-pages .parent-sidebar-menu > li.current_page_parent > a,
.wp-block-advanced-sidebar-menu-pages .parent-sidebar-menu > li.current-menu-parent > a {
  background: #4F153F;
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(79, 21, 63, 0.25);
}

/* Menu enfants */
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu {
  list-style: none;
  margin: 10px 0 6px 0;
  padding: 4px 0 4px 10px;
}

/* Lien enfant */
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li > a {
  display: block;
  padding: 8px 12px;
  border-radius: 10px; /* radius-md */
  font-size: 14px;
  text-decoration: none;
  color: #6d5f68; /* sidebar-muted */
  position: relative;
  transition:
    background 160ms ease-out,
    color 160ms ease-out,
    transform 160ms ease-out;
}

/* Petit bullet */
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li > a::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 50%;
  width: 6px;
  height: 6px;
  background: rgba(79, 21, 63, 0.3);
  border-radius: 50%;
  transform: translateY(-50%);
}

/* Hover enfant */
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li > a:hover {
  background: rgba(219, 191, 47, 0.25);
  color: #4F153F;
  transform: translateX(4px);
}

/* Enfant actif */
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li.current_page_item > a,
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li.current-menu-item > a {
  background: #4F153F;
  color: #ffffff;
  font-weight: 600;
}

/* Bullet actif (barre or) */
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li.current_page_item > a::before,
.wp-block-advanced-sidebar-menu-pages .child-sidebar-menu > li.current-menu-item > a::before {
  background: #DBBF2F;
  width: 4px;
  height: 20px;
  border-radius: 4px;
}

/* ------------------ WRAPPER ------------------ */
.wp-block-table {
    overflow-x: auto;            /* Scroll horizontal sur mobile */
    -webkit-overflow-scrolling: touch;
}

/* ------------------ TABLE ------------------ */
.wp-block-table table {
    width: 100%;
    border-collapse: collapse;
    background: #ffffff;
	border-top-left-radius : 10px;
	border-top-right-radius : 10px;
    overflow: hidden;
    color: #222222;
    font-family: system-ui, sans-serif;
    font-size: 0.95rem;
    min-width: 600px;            /* force le scroll horizontal */
}

/* ------------------ HEAD ------------------ */
.wp-block-table thead {
    background: #4f153f;         /* prune */
    color: #ffffff;
	border-bottom : none !important;
}
table {
		border: 1px  rgba(0, 0, 0, .1) ;
}
.wp-block-table thead td,
.wp-block-table thead th {
    padding: 0.9rem 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    border-bottom: 2px solid rgba(255,255,255,0.15);
}

/* ------------------ BODY ------------------ */
.wp-block-table tbody tr:nth-child(odd) {
    background: #ffffff;
}

.wp-block-table tbody tr:nth-child(even) {
	background: #fbf8ea;         /* beige ultra soft */
}

.wp-block-table tbody tr:hover {
    background: #dbbf2f40;       /* jaune translucide */
}

/* Cellules */
.wp-block-table td {
    padding: 0.8rem 1.1rem;
	border: 1px solid rgba(0, 0, 0, .1) !important;
}

/* Dernière ligne */
.wp-block-table tbody tr:last-child td {
    border-bottom-left-radius : 10px;
	border-bottom-right-radius : 10px;
}

/* ---------------- ACCORDÉON GLOBAL ---------------- */

.gb-accordion .gb-accordion__item {
	padding : 0 !important;
	border : 3px solid #fbf8ea;
	border-top-left-radius : 10px;
	border-top-right-radius : 10px;
	box-shadow: 0 8px 22px rgba(0, 0, 0, 0.06);
}

.gb-accordion .gb-accordion__item .gb-accordion__toggle {
	color : #4F153F;
	padding : 1em;
	padding-bottom 0;
	background-color : #fbf8ea;
}

.gb-accordion .gb-accordion__item .gb-accordion__content {
	padding-left : 1em;
	padding-right : 1em;
}

.inside-left-sidebar {
	position: sticky;
    top: 70px;
}

.widget ul li {
    list-style-type: none;
    position: relative;
    margin-bottom : 0px;
}

/* ==========================================================
   LISTE PAGES ENFANTS — DOM RÉDUIT / RENDU IDENTIQUE
   ========================================================== */

/* --------------------------
   BASE
   -------------------------- */
.lp__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lp__tagline {
  margin-bottom: 1rem;
}

.lp__title {
  margin-bottom: 1rem;
}

.lp__excerpt {
  margin-bottom: 1.2rem;
}

/* ==========================================================
   CAS 1 & 4 — BOXED (CONTENU CENTRÉ, PAS FULL WIDTH)
   ========================================================== */

.lp--boxed {
  padding-block: 120px;
}

/* Conteneur équivalent à gbp-section__inner */
.lp--boxed .lp__wrap--grid {
  max-width: 1200px;      /* largeur container */
  margin-inline: auto;
  box-sizing: border-box;

  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: center;
}

/* Fond */
.lp--boxed.lp--beige {
  background-color: rgba(219, 191, 47, 0.1);
}


/* Image arrondie uniquement en boxed */
.lp--boxed .lp__img {
  border-radius: 5px;
}

/* ==========================================================
   CAS 2 & 3 — FULL SPLIT (PLEINE LARGEUR)
   ========================================================== */

.lp--split {
  width: 100%;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50%;
  margin-right: -50%;
  background-color: #ffffff;
  overflow: hidden;
}

.lp__wrap--flex {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  min-height: 600px;
}

/* Colonnes */
.lp__media {
  flex: 1;
  min-width: 50%;
  position: relative;
}

.lp__textBg {
  flex: 1;
  min-width: 50%;
  display: flex;
  align-items: center;
  background-color: rgba(219, 191, 47, 0.5);
  padding: 4rem;
  box-sizing: border-box;
}

/* Alignement texte (équivalent custom-text-inner) */
.lp__textBg .lp__text {
  max-width: 600px;
  width: 100%;
  margin-left: 0;
  margin-right: auto;
}

/* CAS 3 : texte à gauche → collé vers l’image */
.lp--img-right .lp__textBg .lp__text {
  margin-left: auto;
  margin-right: 0;
}

/* ==========================================================
   CAS 5 — HERO FULL BLEED
   ========================================================== */

.lp--hero {
  width: 100%;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50%;
  margin-right: -50%;
  min-height: 600px;

  background-size: cover;
  background-position: center;

  display: flex;
  align-items: center;
  justify-content: center;
}

.lp__heroBox {
  background-color: rgba(255, 255, 255, 0.9);
  padding: 60px;
  max-width: 800px;
  margin: 20px;
  border-radius: 5px;
  text-align: center;
}

/* ==========================================================
   RESPONSIVE — IDENTIQUE AU COMPORTEMENT ACTUEL
   ========================================================== */

@media (max-width: 1024px) {

  /* BOXED */
  .lp--boxed .lp__wrap--grid {
    display: block;
    padding-inline: 20px;
  }

  .lp--boxed .lp__media {
    margin: 2rem 0;
  }

  /* FULL SPLIT */
  .lp__wrap--flex {
    flex-direction: column;
  }

  .lp__media,
  .lp__textBg {
    min-width: 100%;
    width: 100%;
  }

  /* Image toujours en premier */
  .lp__media {
    order: -1;
    height: 300px;
  }

  .lp__textBg {
    padding: 3rem 20px;
  }
}

@media (max-width: 1000px) {
  .lp--boxed .lp__wrap--grid {
    padding-inline: 10px;
  }
}


/* ==========================================================
   SUBTITLE — couleur spécifique sur fond jaune (CAS 2 & 3)
   ========================================================== */

/* Cas 2 & 3 = sections full split */
.lp--split .lp__tagline {
  color: #222222 !important;
}

/* --- NEWSLETTER (Mailchimp for WP) --- */
.newsletter-form{
  max-width: 600px;
  margin: 0 auto;
  font-family: inherit;
}

/* Champ */
.newsletter-field{
  margin-bottom: 12px;
}

.newsletter-label{
  font-weight: 600;
  color: #4F153F;
  display: block;
  margin-bottom: 6px;
}

.newsletter-input{
  width: 100%;
  background: #ffffff;
  border: 1px solid #e1e1e1;
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 16px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
  transition: all 0.25s ease;
}

.newsletter-input:focus{
  border-color: #DBBF2F;
  box-shadow: 0 4px 12px rgba(219, 191, 47, 0.25);
  outline: none;
}

/* Actions */
.newsletter-actions{
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 10px;
}

/* Bouton : on s’appuie sur tes classes existantes */
.newsletter-submit{
  border: none;
  cursor: pointer;
}

/* Petit texte */
.newsletter-hint{
  font-size: 14px;
  color: #6d5f68;
  line-height: 1.2;
}

/* Mobile: bouton pleine largeur */
@media (max-width: 600px){
  .newsletter-submit{
    width: 100%;
    text-align: center;
  }
}

#cff .cff-author .cff-date {
    color: #6B7790 !important;
    font-size: 11px;
    margin-top: 2px !important;
    margin-bottom: 0 !important;
}

.ecoindex__list {
    margin-top: 20px !important;
    margin-bottom: 20px !important;
    display: flex !important;
    flex-wrap: wrap !important;
    padding: 0;
    margin: 0;
    list-style: none;
  }
  
  .ecoindex__note {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    align-items: flex-end;
    justify-content: flex-end;
    display: flex;
    padding: 0.325rem;
    margin: 0.15rem;
    border-width: 0.125rem;
    border-style: solid;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 0.625rem;
    font-size: 0.725rem;
    color: #000;
    font-weight: bold;
    background-color: #fff;
  
    @media (min-width: 55em) {
      width: 5rem;
      height: 5rem;
      border-radius: 1.25rem;
      font-size: 1.375rem;
      padding: 0.625rem;
      margin: 0.25rem;
    }
  }
  
  /* A */
  .ecoindex__note:nth-of-type(1) {
    border-color: #4f9f30;
  
    &.ecoindex__note--active {
      background-color: #4f9f30;
    }
  }
  
  /* B */
  .ecoindex__note:nth-of-type(2) {
    border-color: #51b84b;
  
    &.ecoindex__note--active {
      background-color: #51b84b;
    }
  }
  
  /* C */
  .ecoindex__note:nth-of-type(3) {
    border-color: #cadb2a;
  
    &.ecoindex__note--active {
      background-color: #cadb2a;
    }
  }
  
  /* D */
  .ecoindex__note:nth-of-type(4) {
    border-color: #f6eb15;
  
    &.ecoindex__note--active {
      background-color: #f6eb15;
    }
  }
  
  /* E */
  .ecoindex__note:nth-of-type(5) {
    border-color: #fecd06;
  
    &.ecoindex__note--active {
      background-color: #fecd06;
    }
  }
  
  /* F */
  .ecoindex__note:nth-of-type(6) {
    border-color: #f99839;
  
    &.ecoindex__note--active {
      background-color: #f99839;
    }
  }
  
  /* G */
  .ecoindex__note:nth-of-type(7) {
    border-color: #ed2124;
  
    &.ecoindex__note--active {
      background-color: #ed2124;
    }
  }
  