/*

Theme Name: Avada Child

Description: Child theme for Avada theme

Author: ThemeFusion

Author URI: https://theme-fusion.com

Template: Avada

Version: 1.0.0

Text Domain:  Avada

*/

.sjdl_testimonials {
    min-height: 422px;
}

/* =========================================================
   RESERVATION
   ========================================================= */

/* 1. Masquer la zone du formulaire sur le site public */
#zone-formulaire-reservation.formulaire-masque {
    display: none;
}

/* 2. FORCER l'affichage de la zone dans l'éditeur Avada Live Builder */
body.fusion-builder-live-active #zone-formulaire-reservation.formulaire-masque,
body.fusion-builder-live #zone-formulaire-reservation.formulaire-masque {
    display: block !important;
    /* (Optionnel) Ajoute une légère bordure en édition pour bien visualiser la zone masquée */
    outline: 2px dashed #0073aa;
    outline-offset: -2px;
}

/* Base du bouton avec transitions matérielles fluides */
.btn-je-reserve-sticky {
    z-index: 999999 !important; /* Z-index absolu garanti à la racine du body */
    transition: transform 0.35s cubic-bezier(0.25, 1, 0.5, 1), 
                opacity 0.3s ease, 
                box-shadow 0.3s ease, 
                background-color 0.3s ease !important;
    will-change: transform, opacity;
}

/* État Sticky (quand on défile dans la page) */
.btn-je-reserve-sticky.is-stuck {
    position: fixed !important;
    top: 100px !important;
    right: 30px !important;
    transform: translateY(0) scale(1);
    opacity: 1;
    visibility: visible;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25) !important;
}

/* État Masqué (quand on arrive au niveau du formulaire) */
.btn-je-reserve-sticky.is-hidden {
    opacity: 0 !important;
    visibility: hidden !important;
    transform: translateY(-15px) scale(0.95) !important; /* Glisse doucement vers le haut en disparaissant */
    pointer-events: none !important;
}


/* =========================================================
   ALIGNEMENT TYPO & COULEURS : BOUTON HBOOK / AVADA
   ========================================================= */

html body .hb-button-wrapper input[type="submit"],
html body .hb-search-submit-wrapper input[type="submit"],
html body input[id*="hb-form-"][type="submit"] {
    
    /* 1. RESET STRICT DES STYLES NAVIGATEUR */
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    background-image: none !important;
    text-shadow: none !important;
    box-sizing: border-box !important;

    /* 2. TYPOGRAPHIE NATIVE AVADA */
    /* Remplace "inherit" par le nom de ta police (ex: 'Open Sans', sans-serif) si besoin */
    font-family: var(--button_typography-font-family, inherit) !important;
    font-size: 14px !important;              /* Taille du texte des boutons Avada */
    font-weight: 700 !important;             /* Gras (Bold) */
    line-height: 1 !important;
    letter-spacing: 1.5px !important;         /* Espacement des lettres d'Avada */
    text-transform: uppercase !important;     /* Force les majuscules */

    /* 3. COULEURS (Palette Avada) */
    /* Remplace var(--awb-color1) par la variable ou le code couleur de ton choix */
    background-color: var(--awb-color4, #0073aa) !important; 
    color: #ffffff !important;

    /* 4. FORME & SPACING AVADA */
    border: none !important;
    border-radius: var(--button_border_radius, 4px) !important; /* Arrondi des boutons */
    padding: 14px 32px !important;            /* Margin/Padding interne */
    display: inline-block !important;
    height: auto !important;

    /* 5. TRANSITIONS & OMBRE */
    cursor: pointer !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12) !important;
    transition: all 0.25s cubic-bezier(0.25, 1, 0.5, 1) !important;
}

/* =========================================================
   SURVOL (HOVER)
   ========================================================= */
html body .hb-button-wrapper input[type="submit"]:hover,
html body .hb-search-submit-wrapper input[type="submit"]:hover,
html body input[id*="hb-form-"][type="submit"]:hover {
    /* Couleur au survol (ex: Couleur 2 d'Avada) */
    background-color: var(--awb-color2, #005177) !important; 
    color: #ffffff !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.2) !important;
}

/* Suppression du label vide HBook qui peut créer un décalage vertical */
html body .hb-button-wrapper label[for*="hb-search-form-submit"] {
    display: none !important;
}

/* =========================================================
   ZONE RESERVATION : couleur du texte (titres h3 + libelles) selon le fond du gite
   Fonds : Le Brut gris #6e6e6e (page 1605) -> texte blanc (5,1:1)
           Le Doux vert #7faf8a et La Petillante ocre #e39d2d -> texte #171717 (7,2:1 et 7,8:1)
   ========================================================= */
#zone-formulaire-reservation h3,
#zone-formulaire-reservation label,
#zone-formulaire-reservation .hb-multi-accom-people-title,
body.fusion-builder-live-active #zone-formulaire-reservation h3 {
    color: var(--awb-color8) !important;
}
body.page-id-1605 #zone-formulaire-reservation h3,
body.page-id-1605 #zone-formulaire-reservation label,
body.page-id-1605 #zone-formulaire-reservation .hb-multi-accom-people-title {
    color: var(--awb-color1) !important;
}

#zone-formulaire-reservation .hb-resa-summary-content {
    color: var(--awb-color8) !important;
}

/* =========================================================
   FORMULAIRE DE RECHERCHE HBOOK : espacement des champs + bouton Chercher
   ========================================================= */
html body .hbook-wrapper .hb-horizontal-search-form .hb-search-fields {display:flex !important;flex-wrap:wrap;align-items:flex-end;gap:20px 24px;}
html body .hbook-wrapper .hb-horizontal-search-form .hb-search-fields::before,
html body .hbook-wrapper .hb-horizontal-search-form .hb-search-fields::after {display:none !important;}
html body .hbook-wrapper .hb-horizontal-search-form .hb-search-fields > p {float:none !important;width:auto !important;margin:0 !important;box-sizing:border-box;}
html body .hbook-wrapper .hb-horizontal-search-form .hb-check-dates-wrapper {flex:1 1 calc(50% - 12px);min-width:130px;}
html body .hbook-wrapper .hb-horizontal-search-form .hb-people-wrapper {flex:0 0 88px;}
html body .hbook-wrapper .hb-horizontal-search-form .hb-search-submit-wrapper {flex:1 1 140px;}
html body .hbook-wrapper .hb-search-submit-wrapper input[type="submit"] {width:100% !important;min-height:44px;white-space:nowrap !important;padding:14px 20px !important;}

/* =========================================================
   HBOOK : boutons Precedent / Suivant / Modifier la recherche
   ========================================================= */
html body .hbook-wrapper .hb-step-button{text-align:center;margin:24px 0!important}
html body .hbook-wrapper .hb-step-button input[type="button"],html body .hbook-wrapper .hb-step-button input[type="submit"],html body .hbook-wrapper .hb-step-button button{-webkit-appearance:none!important;appearance:none!important;box-sizing:border-box!important;font-family:var(--button_typography-font-family,inherit)!important;font-size:14px!important;font-weight:700!important;line-height:1!important;letter-spacing:1.5px!important;text-transform:uppercase!important;white-space:nowrap!important;min-height:44px;padding:14px 28px!important;border:2px solid var(--awb-color4,#5a7f63)!important;border-radius:var(--button_border_radius,4px)!important;cursor:pointer!important;transition:all .25s cubic-bezier(.25,1,.5,1)!important}
html body .hbook-wrapper .hb-next-step input[type="button"],html body .hbook-wrapper .hb-next-step input[type="submit"],html body .hbook-wrapper .hb-next-step button{background-color:var(--awb-color4,#5a7f63)!important;color:#fff!important;box-shadow:0 2px 6px rgba(0,0,0,.12)!important}
html body .hbook-wrapper .hb-next-step input[type="button"]:hover,html body .hbook-wrapper .hb-next-step input[type="submit"]:hover,html body .hbook-wrapper .hb-next-step button:hover{background-color:var(--awb-color2,#455d63)!important;border-color:var(--awb-color2,#455d63)!important;transform:translateY(-2px);box-shadow:0 6px 18px rgba(0,0,0,.2)!important}
html body .hbook-wrapper .hb-previous-step input[type="button"],html body .hbook-wrapper .hb-previous-step input[type="submit"],html body .hbook-wrapper .hb-previous-step button{background-color:transparent!important;color:var(--awb-color4,#5a7f63)!important;box-shadow:none!important}
html body .hbook-wrapper .hb-previous-step input[type="button"]:hover,html body .hbook-wrapper .hb-previous-step input[type="submit"]:hover,html body .hbook-wrapper .hb-previous-step button:hover{background-color:var(--awb-color4,#5a7f63)!important;color:#fff!important;transform:translateY(-2px);box-shadow:0 6px 18px rgba(0,0,0,.2)!important}
html body .hbook-wrapper .hb-confirm-button input[type="submit"]{min-height:44px}

/* Pages gite (panneau gris) */
html body .hbook-wrapper.hb-accom-page .hb-step-button input[type="button"],html body .hbook-wrapper.hb-accom-page .hb-step-button input[type="submit"]{width:100%!important}
html body .hbook-wrapper.hb-accom-page .hb-previous-step input[type="button"]{color:#fff!important;border-color:#fff!important}
html body .hbook-wrapper.hb-accom-page .hb-previous-step input[type="button"]:hover{background-color:#fff!important;color:var(--awb-color4,#5a7f63)!important}

/* Modifier la recherche */
html body .hbook-wrapper .hb-change-search-wrapper input[type="submit"]{width:auto!important;white-space:nowrap!important;min-height:44px;padding:14px 20px!important}
html body .hbook-wrapper.hb-accom-page .hb-change-search-wrapper{width:100%!important;flex:1 1 100%}
html body .hbook-wrapper.hb-accom-page .hb-change-search-wrapper input[type="submit"]{width:100%!important}

/* Recapitulatif de recherche (page /reservation/ uniquement) : applique seulement quand HBook l'affiche (style inline display:block) */
html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]{display:flex!important;flex-wrap:wrap;align-items:flex-end;justify-content:flex-start;gap:16px 24px;margin-bottom:24px!important}
html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]::before,html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]::after{display:none!important}
html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]>*{float:none!important;margin:0!important}
html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]>p{text-align:left!important}
html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]>.hb-change-search-wrapper{flex:1 1 100%;width:100%!important;text-align:left;padding-bottom:24px;border-bottom:1px solid #4a4a4a}
html body .hbook-wrapper:not(.hb-accom-page) .hb-searched-summary[style*="display: block"]>.hb-change-search-wrapper input[type="submit"]{width:auto!important}


/* =========================================================
   RESPONSIVE GLOBAL : tablette (<=1024px) et mobile (<=640px)
   Regles par type d'element, valables pour tout le site.
   ========================================================= */
@media (max-width:1024px){
html:root{--awb-typography4-line-height:1.75;--body_typography-line-height:1.75}
/* Titres : interligne serree, pas de debordement, coupure des mots longs uniquement (10 lettres et plus) */
html body #main .fusion-title .fusion-title-heading{line-height:1.2!important;min-width:0;max-width:100%;overflow-wrap:break-word;hyphens:auto;hyphenate-limit-chars:10 4 4}
/* Colonnes : plafonner les marges internes laterales definies pour le bureau */
html body #main .fusion-column-wrapper{padding-left:min(var(--awb-padding-left,0px),40px)!important;padding-right:min(var(--awb-padding-right,0px),40px)!important}
}
@media (max-width:640px){
html:root{--awb-typography2-letter-spacing:2.5px;--awb-typography4-line-height:1.65;--body_typography-line-height:1.65}
html body #main .fusion-column-wrapper{padding-left:min(var(--awb-padding-left,0px),20px)!important;padding-right:min(var(--awb-padding-right,0px),20px)!important}
/* Sections : plafonner les espacements verticaux (hero et sections pleine largeur exclus) */
html body #main .fusion-fullwidth:not(.hundred-percent-fullwidth){padding-top:min(var(--awb-padding-top-small,var(--awb-padding-top-medium,var(--awb-padding-top,0px))),56px)!important;padding-bottom:min(var(--awb-padding-bottom-small,var(--awb-padding-bottom-medium,var(--awb-padding-bottom,0px))),40px)!important}
/* Surtitres (kickers) : espacement des lettres homogène, même quand il est fixé en dur dans l'élément */
html body #main .fusion-title-heading[style*="--fontSize:13"]{letter-spacing:2.5px!important;line-height:1.7!important}
html body #main .fusion-title:has(>.fusion-title-heading[style*="--fontSize:13"]){margin-bottom:14px!important}
/* Marges latérales des sections plafonnées (cartes plus larges) */
html body #main .fusion-fullwidth:not(.hundred-percent-fullwidth){padding-left:min(var(--awb-padding-left-small,var(--awb-padding-left,0px)),16px)!important;padding-right:min(var(--awb-padding-right-small,var(--awb-padding-right,0px)),16px)!important}
/* Colonnes encadrées (ex. L'Eclat) : bordure épaisse réduite */
html body #main .fusion-layout-column:is([style*="--awb-border-top:2"],[style*="--awb-border-top:3"],[style*="--awb-border-top:4"],[style*="--awb-border-top:5"])>.fusion-column-wrapper{border-width:12px!important}
/* Services (Content Boxes 4 ou 6 colonnes) : grille 2 colonnes compacte */
html body #main .fusion-content-boxes.fusion-columns-6,html body #main .fusion-content-boxes.fusion-columns-4{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 12px;align-items:start}
html body #main .fusion-content-boxes.fusion-columns-6::before,html body #main .fusion-content-boxes.fusion-columns-6::after,html body #main .fusion-content-boxes.fusion-columns-4::before,html body #main .fusion-content-boxes.fusion-columns-4::after{display:none!important}
html body #main .fusion-content-boxes.fusion-columns-6>.fusion-column,html body #main .fusion-content-boxes.fusion-columns-4>.fusion-column{width:auto!important;margin:0 0 8px!important;float:none}
html body #main .fusion-content-boxes.fusion-columns-6 .content-box-wrapper,html body #main .fusion-content-boxes.fusion-columns-4 .content-box-wrapper{padding:12px 6px!important}
html body #main .fusion-content-boxes.fusion-columns-6 .content-box-heading,html body #main .fusion-content-boxes.fusion-columns-4 .content-box-heading{font-size:18px!important;line-height:1.25!important;overflow-wrap:normal;hyphens:auto}
}
/* MACARON PARTENAIRE sur les photos du carrousel "Activités & sorties"
   Déclencheur : le texte alternatif de l'image (Avada > Image Carousel > image > "Image Alt Text")
   contient le mot "partenaire", ex. : "Aquarium de Touraine, partenaire de Séjours de Loire" */
.fusion-image-wrapper{position:relative}
.fusion-image-wrapper:has(img[alt*="partenaire" i])::after{content:"Partenaire";position:absolute;top:10px;right:10px;z-index:3;width:72px;height:72px;box-sizing:border-box;display:flex;align-items:center;justify-content:center;text-align:center;border-radius:50%;background:radial-gradient(circle at 30% 25%,#709a7b,#4a6b53 70%);color:#fff;font:600 8px/1 var(--awb-typography2-font-family,sans-serif);letter-spacing:.08em;text-indent:.08em;text-transform:uppercase;box-shadow:inset 0 0 0 3px #4a6b53,inset 0 0 0 4px rgba(255,255,255,.85),0 4px 12px rgba(0,0,0,.3);pointer-events:none}
@media (max-width:640px){.fusion-image-wrapper:has(img[alt*="partenaire" i])::after{width:64px;height:64px;font-size:7.5px;top:8px;right:8px}}

/* CARROUSEL ACTIVITES (classe "activites" sur le carrousel) : titres des legendes en 15px au lieu de 16px */
.activites .awb-imageframe-caption-title{font-size:15px!important}

/* MESSAGES D'ERREUR HBOOK : lisibles sur les 3 fonds de gites (gris #6e6e6e, vert #7faf8a, ocre #e39d2d)
   Un encart blanc + rouge fonce (contraste 6,5:1) fonctionne quelle que soit la couleur de fond */
.hb-search-error,.hb-policies-error,.hb-confirm-error{background:#fff;color:#b3261e!important;font-weight:600;line-height:1.5;padding:12px 16px;margin:12px 0;border-left:4px solid #b3261e;border-radius:3px;box-shadow:0 1px 4px rgba(0,0,0,.18)}

/* CONFIRMATION DE PAIEMENT HBOOK : le bloc est masque par defaut (.formulaire-masque) mais doit apparaitre au retour de paiement, sur toutes les pages */
body.hb-payment-confirm #zone-formulaire-reservation.formulaire-masque{display:block!important;scroll-margin-top:90px}
