/* Footer Styles */
.site-footer {
    background: linear-gradient(135deg, #0a1628, #000814);
    color: #fff;
    padding: 1rem 0;
    /* plus compact */
    margin-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.site-footer .container {
    max-width: none;
    width: 100%;
    margin: 0;
    padding-left: 1rem;
    padding-right: 1rem;
}

.footer-content {
    display: flex;
    align-items: center;
    /* centrage vertical global */
    justify-content: space-between;
    gap: 0.75rem;
    /* plus compact */
    width: 100%;
}

/* Réseaux sociaux */
.footer-social {
    display: flex;
    gap: 0.75rem;
    /* plus compact */
    justify-content: center;
    align-items: center;
    align-self: center;
    /* centre verticalement le bloc dans le footer */
}

/* Surcharger les styles globaux pour les liens sociaux */
.site-footer .social-link,
.site-footer a.social-link,
.site-footer .footer-social a,
.site-footer .footer-social a.social-link {
    color: #ffffff !important;
}

.site-footer .social-link:hover,
.site-footer .social-link:focus,
.site-footer a.social-link:hover,
.site-footer a.social-link:focus,
.site-footer .footer-social a:hover,
.site-footer .footer-social a:focus,
.site-footer .footer-social a.social-link:hover,
.site-footer .footer-social a.social-link:focus {
    color: #ffffff !important;
}

/* Force la couleur blanche sur tous les enfants et pseudo-éléments */
.site-footer .social-link *,
.site-footer .social-link::before,
.site-footer .social-link::after,
.site-footer a.social-link *,
.site-footer a.social-link::before,
.site-footer a.social-link::after {
    color: #ffffff !important;
}

.site-footer .social-link:hover *,
.site-footer .social-link:hover::before,
.site-footer .social-link:hover::after,
.site-footer .social-link:focus *,
.site-footer .social-link:focus::before,
.site-footer .social-link:focus::after,
.site-footer a.social-link:hover *,
.site-footer a.social-link:hover::before,
.site-footer a.social-link:hover::after,
.site-footer a.social-link:focus *,
.site-footer a.social-link:focus::before,
.site-footer a.social-link:focus::after {
    color: #ffffff !important;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    /* plus compact */
    height: 36px;
    /* plus compact */
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: #fff !important;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 15px;
    /* plus compact */
}

.social-link i,
.social-link .fab,
.social-link .fas,
.social-link svg {
    color: #ffffff !important;
    fill: #ffffff !important;
}

.social-link i::before,
.social-link .fab::before,
.social-link .fas::before,
.social-link .fa::before {
    color: #ffffff !important;
}

.social-link:hover,
.social-link:focus {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
    color: #ffffff !important;
    text-decoration: none !important;
}

.social-link:hover *,
.social-link:focus * {
    color: #ffffff !important;
    fill: #ffffff !important;
    stroke: #ffffff !important;
}

.social-link:hover i,
.social-link:hover .fab,
.social-link:hover .fas,
.social-link:hover .fa,
.social-link:hover .fa-facebook-f,
.social-link:hover .fa-instagram,
.social-link:hover .fa-linkedin-in,
.social-link:hover svg,
.social-link:hover svg path,
.social-link:hover svg circle,
.social-link:hover svg g,
.social-link:focus i,
.social-link:focus .fab,
.social-link:focus .fas,
.social-link:focus .fa,
.social-link:focus .fa-facebook-f,
.social-link:focus .fa-instagram,
.social-link:focus .fa-linkedin-in,
.social-link:focus svg,
.social-link:focus svg path,
.social-link:focus svg circle,
.social-link:focus svg g {
    color: #ffffff !important;
    fill: #ffffff !important;
    stroke: #ffffff !important;
}

.social-link:hover i::before,
.social-link:hover .fab::before,
.social-link:hover .fas::before,
.social-link:hover .fa::before,
.social-link:hover .fa-facebook-f::before,
.social-link:hover .fa-instagram::before,
.social-link:hover .fa-linkedin-in::before,
.social-link:focus i::before,
.social-link:focus .fab::before,
.social-link:focus .fas::before,
.social-link:focus .fa::before,
.social-link:focus .fa-facebook-f::before,
.social-link:focus .fa-instagram::before,
.social-link:focus .fa-linkedin-in::before {
    color: #ffffff !important;
}

/* Forcer les marques individuellement (cas Instagram qui restait bleu au hover) */
.site-footer .footer-social .fa-facebook-f,
.site-footer .footer-social .fa-instagram,
.site-footer .footer-social .fa-linkedin-in,
.site-footer .footer-social .fa-facebook-f::before,
.site-footer .footer-social .fa-instagram::before,
.site-footer .footer-social .fa-linkedin-in::before {
    color: #ffffff !important;
}

.site-footer .footer-social a:hover .fa-facebook-f,
.site-footer .footer-social a:hover .fa-instagram,
.site-footer .footer-social a:hover .fa-linkedin-in,
.site-footer .footer-social a:hover .fa-facebook-f::before,
.site-footer .footer-social a:hover .fa-instagram::before,
.site-footer .footer-social a:hover .fa-linkedin-in::before,
.site-footer .footer-social a:focus .fa-facebook-f,
.site-footer .footer-social a:focus .fa-instagram,
.site-footer .footer-social a:focus .fa-linkedin-in,
.site-footer .footer-social a:focus .fa-facebook-f::before,
.site-footer .footer-social a:focus .fa-instagram::before,
.site-footer .footer-social a:focus .fa-linkedin-in::before {
    color: #ffffff !important;
}

.social-link:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* Section texte et copyright */
.footer-text {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
    gap: 0.35rem;
    /* plus compact */
    margin-left: auto;
}

/* Aligner les liens du bloc texte à droite sur desktop */
.site-footer .footer-text .footer-links {
    justify-content: flex-end;
}

.copyright {
    margin: 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    opacity: 0.9;
}

/* Liens du footer */
.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    font-size: 14px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    transition: color 0.3s ease, transform 0.2s ease;
    padding: 0.25rem 0.5rem;
    position: relative;
    /* pour l'underline animé */
}

/* Soulignement animé au survol/focus */
.footer-links a::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #667eea, #764ba2);
    border-radius: 2px;
    transition: width 0.25s ease;
}

.footer-links a:hover,
.footer-links a:focus {
    color: #fff;
    text-decoration: none;
    /* on remplace par l'underline animé */
    transform: translateY(-1px);
}

.footer-links a:hover::after,
.footer-links a:focus::after {
    width: 80%;
}

.footer-links a:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
    border-radius: 2px;
}

.separator {
    color: rgba(255, 255, 255, 0.5);
    margin: 0 0.25rem;
}

/* Bouton Back to Top */
.back-to-top {
    position: fixed;
    bottom: calc(2rem + 70px);
    right: 2rem;
    width: 48px;
    height: 48px;
    background: #000428;
    color: #fff;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    font-size: 18px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover,
.back-to-top:focus {
    background: rgba(0, 4, 40, 0.9);
    border-color: rgba(255, 255, 255, 0.4);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.back-to-top:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.back-to-top:active {
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .site-footer {
        padding: 0.9rem 0;
        /* plus compact */
        margin-top: 3rem;
    }

    .site-footer .container {
        padding: 0 1rem;
    }

    .footer-content {
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        justify-content: center;
        gap: 0.75rem;
    }

    .footer-text {
        width: 100%;
        align-items: center;
        text-align: center;
        gap: 0.75rem;
        margin-left: 0;
    }

    .site-footer .footer-text .footer-links {
        justify-content: center;
    }

    .copyright {
        text-align: center;
    }

    .footer-social {
        gap: 0.75rem;
        /* plus compact */
    }

    .social-link {
        width: 32px;
        /* plus compact */
        height: 32px;
        /* plus compact */
        font-size: 14px;
        /* plus compact */
    }

    .footer-links {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem 0.75rem;
    }

    .separator {
        display: none;
    }

    .back-to-top {
        bottom: calc(1.5rem + 70px);
        right: 1.5rem;
        width: 44px;
        height: 44px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .footer-links {
        font-size: 13px;
    }

    .copyright {
        font-size: 13px;
    }
}