/* ============================================
   SITE FOOTER - Structure complète selon maquettes
   ============================================ */

.site-footer {
    width: 100%;
}

/* ============================================
   FOOTER FORMS - Wrapper contact + newsletter
   Note : margin 0 40px supprimé (non-Figma) — les blips décoratifs
   utilisaient ce retrait pour leur positionnement, mais il réduisait
   la largeur des formulaires de 80px sans contrepartie dans la maquette.
   Le gap entre sections est géré par le gap: 40px du flex container.
   ============================================ */

.footer-forms {
    margin: 0;
    padding: 0 0 40px 0; /* Pas de padding-top : évite espace blanc entre dernier image-block et footer-return */
    display: flex;
    flex-direction: column;
    gap: 40px; /* Espace entre contact et newsletter = 1× largeur blip */
}

/* ============================================
   FOOTER RETURN - Section noire avec boutons
   ============================================ */

.footer-return {
    background-color: #000000;
    padding: var(--space-3xl) 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.footer-return__text {
    font-family:'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 16px;
    font-weight: 300;
    color: var(--color-blanc);
    margin-bottom: 40px;
}

.footer-return__buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
}

.footer-return__button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 255px;
    height: 85px;
    padding: 17px 34px;
    border: 2px solid var(--color-blanc);
    background: transparent;
    color: var(--color-blanc);
    font-family: 'PP Neue Machina', sans-serif;
    font-size: 30px;
    font-weight: 400;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-return__button:hover {
    background-color: var(--color-blanc);
    color: var(--color-noir);
}

/* Bouton PARTICULIERS — couleur bleue */
.footer-return__button--particuliers {
    border-color: #006DFF;
    color: #006DFF;
}

.footer-return__button--particuliers:hover {
    background-color: #006DFF;
    color: var(--color-blanc);
}

/* Bouton ENTREPRISES — couleur verte */
.footer-return__button--entreprises {
    border-color: #1A4945;
    color: #1A4945;
}

.footer-return__button--entreprises:hover {
    background-color: #1A4945;
    color: var(--color-blanc);
}

/* ============================================
   FOOTER CONTACT - Section contact
   ============================================ */

.footer-contact {
    background-color: #f3f3f3;
    padding: 60px var(--hero-margin); /* Correction 26 : marges latérales via var(--hero-margin) */
    margin: 0; /* Marges gérées par .footer-forms */
    position: relative;
    scroll-margin-top: 100px; /* Lot 4 #646 : compenser le header fixe (100px) pour scroll vers #contact */
}

.footer-contact__container {
    max-width: 629px;
    width: 100%;
    margin: 0 auto;
    padding: 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
}

.footer-contact__title {
    display: block !important; /* Correction 18 : forcer la visibilité du titre */
    font-family: 'PP Neue Machina', sans-serif;
    font-size: 39px; /* Modif #6 : +30% — 30 × 1.3 = 39px */
    font-weight: 400;
    color: var(--color-noir);
    margin: 0 0 17px 0;
    text-transform: uppercase;
    letter-spacing: 0;
    line-height: 1.143;
}

.footer-contact__subtitle {
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 26px;
    font-weight: 100;
    color: var(--color-noir);
    margin: 0 0 54px 0;
    line-height: 1.143;
}

.footer-contact__form {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Force CF7 wrapper à prendre toute la largeur */
.footer-contact__form > .wpcf7,
.footer-contact__form .wpcf7-form {
    width: 100%;
}

.footer-contact__form p {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 0 30px 0 !important;
}

.footer-contact__form p:last-of-type {
    margin-bottom: 0 !important;
}

.footer-contact__form label {
    display: none !important;
}

.footer-contact__form .wpcf7-form-control-wrap {
    display: block;
    width: 100% !important;
}

.footer-contact__form input[type="text"] {
    width: 100% !important;
    height: 64px;
    padding: 10px 20px;
    border: none;
    background-color: #ffffff;
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 19px;
    font-weight: 400;
    color: var(--color-noir);
    outline: none;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
}

.footer-contact__form input[type="text"]::placeholder {
    color: #767676;
}

.footer-contact__form input[type="email"] {
    width: 100% !important;
    height: 68px;
    padding: 10px 20px;
    border: none;
    background-color: #ffffff;
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 19px;
    font-weight: 400;
    color: var(--color-noir);
    outline: none;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
}

.footer-contact__form input[type="email"]::placeholder {
    color: #767676;
}

.footer-contact__form textarea {
    width: 100% !important;
    height: 167px;
    padding: 20px;
    border: none;
    background-color: #ffffff;
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 19px;
    font-weight: 400;
    color: var(--color-noir);
    outline: none;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
    resize: none;
}

.footer-contact__form textarea::placeholder {
    color: #767676;
}

.footer-contact__form input[type="text"]:focus,
.footer-contact__form input[type="email"]:focus,
.footer-contact__form textarea:focus {
    opacity: 0.8;
}

.footer-contact__form input[type="submit"],
.footer-contact__form button[type="submit"] {
    background-color: #000000;
    color: #ffffff;
    border: none;
    height: 54px;
    padding: 0;
    font-family: 'PP Neue Machina', sans-serif;
    font-size: 17px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0;
    cursor: pointer;
    display: block;
    width: 100% !important;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
}

.footer-contact__form input[type="submit"]:hover,
.footer-contact__form button[type="submit"]:hover {
    opacity: 0.8;
}

/* Messages de validation CF7 */
.footer-contact__form .wpcf7-not-valid-tip {
    color: #d9534f;
    font-size: 14px;
    margin-top: 5px;
    text-align: left;
}

.footer-contact__form .wpcf7-response-output {
    padding: 15px;
    margin-top: 20px;
    font-size: 14px;
}

/* ============================================
   FOOTER NEWSLETTER - Section newsletter
   ============================================ */

.footer-newsletter {
    background-color: #f3f3f3;
    padding: var(--space-4xl) var(--hero-margin); /* Correction 26 : marges latérales via var(--hero-margin) */
    margin: 0; /* Marges gérées par .footer-forms */
    position: relative;
}

.footer-newsletter__container {
    max-width: 629px;
    width: 100%;
    margin: 0 auto;
    padding: 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-sizing: border-box;
}

.footer-newsletter__title {
    font-family: 'PP Neue Machina', sans-serif;
    font-size: 39px; /* Modif #6 : +30% — 30 × 1.3 = 39px */
    font-weight: 400;
    color: var(--color-noir);
    margin: 0 0 17px 0;
    text-transform: uppercase;
    letter-spacing: 0;
    line-height: 1.143;
}

.footer-newsletter__subtitle {
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 26px;
    font-weight: 100;
    color: var(--color-noir);
    margin: 0 0 40px 0; /* gap sous-titre → description : 40px (via container gap 34px + arrondi) */
    line-height: 1.073;
    text-align: center;
}

.footer-newsletter__description {
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 22px;
    font-weight: 300;
    color: var(--color-noir);
    line-height: 33px;
    margin: 0 0 40px 0; /* gap description → formulaire : 40px */
    text-align: center;
}

.footer-newsletter__email {
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 19px;
    font-weight: 300;
    color: var(--color-noir);
    margin: 0 0 40px 0;
}

.footer-newsletter__form {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Force CF7 wrapper à prendre toute la largeur */
.footer-newsletter__form > .wpcf7,
.footer-newsletter__form .wpcf7-form {
    width: 100%;
}

.footer-newsletter__form p {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 0 17px 0 !important;
}

.footer-newsletter__form p:last-of-type {
    margin-bottom: 0 !important;
}

.footer-newsletter__form label {
    display: none !important;
}

.footer-newsletter__form .wpcf7-form-control-wrap {
    display: block;
    width: 100% !important;
    max-width: none !important;
}

.footer-newsletter__form input[type="email"] {
    width: 100% !important;
    height: 68px;
    padding: 10px 17px;
    border: none;
    background-color: #ffffff;
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 19px;
    font-weight: 400;
    color: var(--color-noir);
    outline: none;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
}

.footer-newsletter__form input[type="email"]::placeholder {
    color: #767676;
}

.footer-newsletter__form input[type="email"]:focus {
    opacity: 0.8;
}

.footer-newsletter__button,
.footer-newsletter__form input[type="submit"] {
    background-color: #000000;
    color: #f9f9f9;
    border: none;
    height: 54px;
    padding: 0;
    font-family: 'PP Neue Machina', sans-serif;
    font-size: 17px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0;
    line-height: 44px;
    cursor: pointer;
    display: block;
    width: 100% !important;
    transition: opacity 0.3s ease;
    box-sizing: border-box;
}

.footer-newsletter__button:hover,
.footer-newsletter__form input[type="submit"]:hover {
    opacity: 0.8;
}

/* Messages de validation CF7 — harmonises sur la meme taille que .footer-contact__form
   (op #34227 T2 : le message de reponse newsletter n'avait pas de regle dediee et
   heritait de la taille fluide du body, plus grande que les 14px fixes du contact) */
.footer-newsletter__form .wpcf7-not-valid-tip {
    color: #d9534f;
    font-size: 14px;
    margin-top: 5px;
    text-align: left;
}

.footer-newsletter__form .wpcf7-response-output {
    padding: 15px;
    margin-top: 20px;
    font-size: 14px;
}

/* ============================================
   FOOTER LEGAL - Section légale noire
   ============================================ */

.footer-legal {
    background-color: #000000;
    color: var(--color-blanc);
    padding: 77px 0 53px 0;
}

.footer-legal__container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 var(--marge-laterale);
}

/* Séparateur horizontal */
.footer-legal__separator {
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    margin: 40px 0;
}

/* Ligne générique */
.footer-legal__row {
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 12px;
    font-weight: 300;
    line-height: 1.6;
}

/* Ligne 1 : Logo */
.footer-legal__row--logo {
    text-align: left;
}

.footer-legal__logo {
    display: block;
}

.footer-legal__logo img {
    width: 300px;
    height: auto;
    display: block;
}

/* Ligne 2 : Informations (3 colonnes) */
.footer-legal__row--info {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 60px;
    font-size: 16px;
    font-weight: 400;
    line-height: 22px;
}

.footer-legal__col p {
    margin: 0 0 8px 0;
}

.footer-legal__col a {
    color: var(--color-blanc);
    text-decoration: none;
}

.footer-legal__col a:hover {
    text-decoration: underline;
}

/* Ligne 3 : Détails professionnels */
.footer-legal__row--details {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 173px;
}

.footer-legal__row--details p {
    margin: 0;
}

/* Ligne 4 : Navigation et Copyright */
.footer-legal__row--bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    font-family: 'PP Neue Machina', sans-serif;
    font-weight: 300;
    font-size: 22px;
    line-height: 44px;
    gap: 171px;
}

.footer-legal__nav {
    display: flex;
    gap: 60px;
}

.footer-legal__nav-column {
    display: flex;
    flex-direction: column;
}

.footer-legal__links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.footer-legal__links li {
    margin: 0;
}

.footer-legal__links a {
    font-family: 'PP Neue Machina', sans-serif;
    font-size: 12px;
    font-weight: 400;
    color: var(--color-blanc);
    text-decoration: none;
    text-transform: uppercase;
    transition: opacity 0.3s ease;
}

.footer-legal__links a:hover {
    opacity: 0.7;
}

.footer-legal__copyright {
    font-family: 'tt-commons-pro', 'TT Commons Pro', sans-serif;
    font-size: 16px;
    font-weight: 300;
    line-height: 28px;
    margin: 0;
    text-align: right;
}

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

@media (max-width: 1024px), (hover: none) and (pointer: coarse) and (orientation: portrait) and (max-width: 1032px) {
    .footer-contact,
    .footer-newsletter {
        padding: 80px max(var(--hero-margin), env(safe-area-inset-right)) 80px max(var(--hero-margin), env(safe-area-inset-left)); /* Correction 26 : marges latérales via var(--hero-margin) */
    }

    .footer-legal__row--info {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: left;
        align-items: flex-start;
    }

    .footer-legal__row--bottom {
        flex-direction: column;
        align-items: center;
        gap: 30px;
    }

    .footer-legal__nav {
        flex-direction: column;
        gap: 30px;
    }

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

@media (max-width: 768px), (hover: none) and (pointer: coarse) and (orientation: portrait) and (max-width: 1032px) {
    .footer-return {
        padding: 26px 10px; /* Réduit de moitié : 51px → 26px */
        min-height: 500px;
    }

    /* Boutons footer-return : même largeur + même taille de texte — +30% vs modif #3 (cumul +56% vs origine) */
    .footer-return__button {
        width: 100%;
        font-size: 17px; /* +30% : 13 × 1.3 = 16.9 → 17px */
        height: auto;
        min-height: 69px; /* +30% : 53 × 1.3 = 68.9 → 69px */
        padding: 16px 25px; /* +30% : 12 × 1.3 = 15.6 → 16px | 19 × 1.3 = 24.7 → 25px */
    }

    /* footer-forms : marges réduites */
    .footer-forms {
        margin: 0;
        gap: var(--hero-margin); /* Correction 13 : remonté de 10px → var(--hero-margin) (24px mobile) */
    }

    /* ---- CONTACT MOBILE ---- */
    .footer-contact {
        padding: 25px 30px 67px; /* Fix #657 : 30px (taille blip, comme footer-legal) — était var(--hero-margin)=24px */
    }

    .footer-contact__container {
        max-width: 100%;
        padding: 0; /* Annule le padding desktop 110px */
    }

    .footer-contact__title {
        font-size: 29px; /* Modif #6 : +30% — 22 × 1.3 = 28.6 → 29px (arrondi sup) */
        margin-bottom: 17px;
    }

    .footer-contact__subtitle {
        font-size: 22px;
        font-weight: 300;
        margin-bottom: 27px; /* Réduit de moitié : 54px → 27px */
    }

    /* Champs CF7 contact — valeurs identiques au desktop (déjà définies) */
    .footer-contact__form p {
        margin-bottom: 15px !important; /* Réduit de moitié : 30px → 15px */
    }

    /* ---- NEWSLETTER MOBILE ---- */
    .footer-newsletter {
        padding: 25px 30px 77px; /* Fix #657 : 30px (taille blip, comme footer-legal) — était var(--hero-margin)=24px */
    }

    .footer-newsletter__container {
        max-width: 100%;
        padding: 0; /* Annule le padding desktop 110px */
    }

    .footer-newsletter__title {
        font-size: 29px; /* Modif #6 : +30% — 22 × 1.3 = 28.6 → 29px (arrondi sup) */
        margin-bottom: 17px;
    }

    .footer-newsletter__subtitle {
        font-size: 21px;
        font-weight: 300;
        line-height: 1.073;
        text-align: left;
    }

    .footer-newsletter__description {
        font-size: 21px;
        font-weight: 300;
        line-height: 33px;
    }

    /* Champ email newsletter — valeurs identiques au desktop (déjà définies) */
    .footer-newsletter__form p {
        margin-bottom: 17px !important;
    }

    /* Fix debordement bouton newsletter (op #34227, 25/09) : <input type="submit"> ne wrap jamais
       son texte value. A 17px (taille desktop), "INSCRIVEZ-VOUS À LA NEWSLETTER" (319px de texte)
       deborde de la boite des que la largeur du bouton descend sous ~320px (mesure Puppeteer :
       260px a 320px viewport, 315px a 375px). 13px fait tenir le texte sans reste a 320px comme
       375px (verifie scrollWidth<=clientWidth). Bouton contact ("ENVOYER") non concerne, texte
       court, aucun debordement mesure. */
    .footer-newsletter__form input[type="submit"] {
        font-size: 13px;
    }

    /* ---- FOOTER LEGAL MOBILE ---- */
    .footer-legal__container {
        padding: 0 var(--marge-laterale);
    }

    .footer-legal__links {
        gap: 4px; /* #650 — espacement réduit mobile */
        text-align: left; /* #652 — aligner à gauche (était center) */
        align-items: flex-start; /* #652 — les li s'alignent à gauche dans le flex column */
    }

    .footer-legal__row--bottom {
        align-items: flex-start; /* #652 — override align-items:center hérité de @media 1024px */
    }

    .footer-legal__copyright {
        text-align: left; /* #652 — copyright aligné à gauche */
    }

    .footer-legal__links a {
        line-height: 1.4; /* #650 — annule line-height 44px hérité du parent, réduit l'espacement vertical */
    }

    .footer-legal__row--details {
        grid-template-columns: 1fr;
    }

    .footer-legal {
        padding: 27px 0;
    }

    .footer-legal__separator {
        margin: 20px 0; /* Réduit de moitié : 40px → 20px */
    }

    .footer-legal__row--info {
        flex-direction: column;
        gap: 8px; /* Réduit de moitié : 16px → 8px */
    }

    .footer-legal__row--bottom {
        flex-direction: column;
        gap: 17px; /* Réduit de moitié : 34px → 17px */
    }
}

/* ============================================
   PAYSAGE TACTILE - Tablette et téléphone en paysage
   Titres réduits
   ============================================ */

@media (hover: none) and (pointer: coarse) and (orientation: landscape) and (min-width: 769px) and (max-width: 1376px) {
    .footer-contact__title,
    .footer-newsletter__title {
        font-size: 32px;
    }
}
