/**
 * Pied de page.
 *
 * Préfixe : .lenain-footer
 * Deux étages : les colonnes de liens et la carte de contact sur fond gris,
 * puis un panneau anthracite arrondi, plus large que le contenu et collé au bas
 * de la page — il porte le logo, les réseaux et la mention légale.
 *
 * Le pré-footer remonte sur ce panneau (marge basse négative côté bloc) ; la
 * place lui est ménagée ici par --lp-footer-offset, jamais par une marge
 * négative portée par le pied de page.
 */

.lenain-footer {
    position: relative;
    z-index: 1;
    background: var(--wp--preset--color--bg);
    color: var(--wp--preset--color--text-soft);
}

/* --------------------------------------------------------------- Colonnes */

.lenain-footer__cols {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 48px;
    align-items: start;
    padding-top: var(--lp-footer-pad-top);
    padding-bottom: 48px;
}

.lenain-footer__col {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

/*
 * Les intitulés de colonne restent en Jost : dans la maquette, seule la
 * signalétique de section utilise Ohitashi.
 */
.lenain-footer__title {
    margin: 0 0 6px;
    color: var(--wp--preset--color--titre);
    font-family: var(--wp--preset--font-family--body);
    font-size: var(--wp--preset--font-size--xxs);
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.lenain-footer__nav :where(ul) {
    display: flex;
    flex-direction: column;
    gap: 9px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.lenain-footer__nav :where(a) {
    color: var(--wp--preset--color--text-soft);
    font-size: var(--wp--preset--font-size--sm);
    transition: color 0.2s ease;
}

.lenain-footer__nav :where(a):hover,
.lenain-footer__nav :where(a):focus-visible {
    color: var(--wp--preset--color--rose);
}

/* -------------------------------------------------------- Carte de contact */

.lenain-footer__contact {
    gap: 12px;
    padding: 24px;
    border-radius: var(--lp-radius-lg);
    background: var(--wp--preset--color--white);
    color: var(--wp--preset--color--text-soft);
    font-size: var(--wp--preset--font-size--sm);
    line-height: 1.6;
}

.lenain-footer__contact .lenain-footer__title {
    color: var(--wp--preset--color--titre);
}

.lenain-footer__info {
    position: relative;
    margin: 0;
    padding-left: 26px;
    font-style: normal;
}

/* Pictogramme de chaque coordonnée, recoloré via masque. */
.lenain-footer__info::before {
    content: "";
    position: absolute;
    top: 3px;
    left: 0;
    width: 16px;
    height: 16px;
    background-color: var(--wp--preset--color--anthracite);
    -webkit-mask: var(--lp-info-icon) center / contain no-repeat;
    mask: var(--lp-info-icon) center / contain no-repeat;
}

.lenain-footer__info--address {
    --lp-info-icon: url("../img/icon-pin.svg");
}

.lenain-footer__info--phone {
    --lp-info-icon: url("../img/icon-phone.svg");
}

.lenain-footer__info--email {
    --lp-info-icon: url("../img/icon-mail.svg");
}

.lenain-footer__info--phone :where(a) {
    color: var(--wp--preset--color--anthracite);
    font-weight: 700;
}

.lenain-footer__info--email :where(a) {
    color: var(--wp--preset--color--text-soft);
    overflow-wrap: anywhere;
}

.lenain-footer__info :where(a):hover,
.lenain-footer__info :where(a):focus-visible {
    color: var(--wp--preset--color--rose);
}

/* ---------------------------------------------------- Panneau anthracite */

/*
 * Le panneau est plus large que le contenu (1560 contre 1440) et s'arrête au
 * bas de la page : ses angles ne s'arrondissent qu'en haut.
 */
.lenain-footer__bottom {
    max-width: 1560px;
    margin-inline: auto;
    padding-inline: var(--lp-container-padding);
}

.lenain-footer__plate {
    /*
     * Gris du panneau, dérivés de la palette plutôt que codés en dur : le texte
     * courant, la baseline et la mention légale sont trois éclaircissements de
     * l'anthracite vers le blanc.
     */
    --lp-footer-text: color-mix(in srgb, var(--wp--preset--color--white) 69%, var(--wp--preset--color--anthracite));
    --lp-footer-soft: color-mix(in srgb, var(--wp--preset--color--white) 58%, var(--wp--preset--color--anthracite));
    --lp-footer-legal: color-mix(in srgb, var(--wp--preset--color--white) 52%, var(--wp--preset--color--anthracite));
    --lp-footer-rule: rgb(255 255 255 / 0.12);
    --lp-footer-social: rgb(255 255 255 / 0.35);

    background: var(--wp--preset--color--anthracite);
    color: var(--lp-footer-text);
    border-radius: var(--lp-radius-lg) var(--lp-radius-lg) 0 0;
    overflow: hidden;
}

/* --------------------------------------------------- Bande logo + réseaux */

.lenain-footer__brand {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    flex-wrap: wrap;
    padding: 32px 40px;
}

.lenain-footer__identity {
    display: flex;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
}

.lenain-footer__logo :where(img) {
    display: block;
    width: auto;
    height: 52px;
}

.lenain-footer__baseline {
    max-width: 400px;
    margin: 0;
    color: var(--lp-footer-soft);
    font-size: var(--wp--preset--font-size--sm);
    line-height: 1.6;
}

/* La ligne légale : le copyright à gauche, les réseaux à droite. */
.lenain-footer__legal {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    padding: 14px 40px;
    border-top: 1px solid var(--lp-footer-rule);
}

.lenain-footer__legal .lenain-footer__copyright {
    padding: 0;
    border-top: 0;
}

.lenain-footer__social {
    display: flex;
    gap: 12px;
}

/* Le lien d'avis : discret, dans la voix des libellés du footer. */
.lenain-footer__avis {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: rgb(255 255 255 / 0.7);
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    text-decoration: none;
    transition: color 0.2s ease;
}

/* La flèche des CTA, à l'échelle du lien ; currentColor suit le survol. */
.lenain-footer__avis-arrow {
    flex: 0 0 auto;
    width: 12px;
    height: 12px;
    background-color: currentColor;
    -webkit-mask: url("../img/arrow-right.svg") center / contain no-repeat;
    mask: url("../img/arrow-right.svg") center / contain no-repeat;
}

.lenain-footer__avis:hover,
.lenain-footer__avis:focus-visible {
    color: var(--wp--preset--color--white);
}

.lenain-footer__social :where(a) {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid var(--lp-footer-social);
    border-radius: 50%;
    color: var(--wp--preset--color--white);
    transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

.lenain-footer__social :where(a):hover,
.lenain-footer__social :where(a):focus-visible {
    border-color: var(--wp--preset--color--rose);
    background: var(--wp--preset--color--rose);
    color: var(--wp--preset--color--white);
}

.lenain-footer__social :where(svg) {
    width: 16px;
    height: 16px;
}

/* ------------------------------------------------------------ Barre légale */

.lenain-footer__copyright {
    margin: 0;
    padding: 18px 40px;
    border-top: 1px solid var(--lp-footer-rule);
    color: var(--lp-footer-legal);
    font-size: var(--wp--preset--font-size--xs);
}

/*
 * Le pré-footer n'est posé que sur certaines pages. Quand il l'est, il remonte
 * sur le panneau : celui-ci lui ménage alors la place correspondante.
 */
body:has(.lenain-prefooter) .lenain-footer__cols {
    padding-top: var(--lp-footer-offset);
}

/* ------------------------------------------------------------- Responsive */

@media (max-width: 1024px) {
    .lenain-footer__cols {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 40px;
    }

    .lenain-footer__identity {
        gap: 24px;
    }
}

@media (max-width: 640px) {
    .lenain-footer__cols {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
    }
}
