/* Bannière de consentement aux cookies (js/consentement.js). Tout est préfixé fsm-cookies.
   Petite carte discrète en bas à droite (en bas sur toute la largeur sur téléphone). */

.fsm-cookies {
    position: fixed;
    right: 20px;
    bottom: calc(20px + env(safe-area-inset-bottom, 0px));
    z-index: 2147483000;
    width: min(380px, calc(100vw - 40px));
    font-family: 'Inter', sans-serif;
}

.fsm-cookies[hidden] {
    display: none;
}

.fsm-cookies__boite {
    padding: 16px;
    background: #fff;
    color: #374151;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    box-shadow: 0 18px 45px -12px rgba(17, 24, 39, 0.35);
    animation: fsm-cookies-arrivee 0.35s ease-out;
}

@keyframes fsm-cookies-arrivee {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: none; }
}

.fsm-cookies__haut {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.fsm-cookies__icone {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 9999px;
    background: #fef2f2;
    color: #dc2626;
}

.fsm-cookies__icone svg {
    width: 18px;
    height: 18px;
}

.fsm-cookies__texte {
    margin: 0;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.5;
    color: #374151;
}

.fsm-cookies__plus {
    padding: 0;
    margin: 0;
    border: 0;
    background: none;
    font: inherit;
    font-weight: 700;
    color: #111827;
    text-decoration: underline;
    text-underline-offset: 2px;
    cursor: pointer;
}

.fsm-cookies__plus:hover {
    color: #dc2626;
}

.fsm-cookies__details {
    margin: 10px 0 0;
    padding: 10px 12px;
    background: #f9fafb;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.55;
    color: #4b5563;
}

.fsm-cookies__details[hidden] {
    display: none;
}

.fsm-cookies__details a {
    color: #111827;
    font-weight: 700;
    text-decoration: underline;
}

.fsm-cookies__boutons {
    display: flex;
    margin-top: 14px;
}

/* Accepter : le seul vrai bouton, rond, dans le rouge du site */
.fsm-cookies__bouton {
    flex: 1 1 auto;
    min-height: 42px;
    padding: 0 22px;
    margin: 0;
    border: 0;
    border-radius: 9999px;
    background: #dc2626;
    color: #fff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: background-color 0.15s;
}

.fsm-cookies__bouton:hover {
    background: #b91c1c;
}

/* Refuser : un mot souligné glissé dans la phrase */
.fsm-cookies__refus {
    padding: 0;
    margin: 0;
    border: 0;
    background: none;
    font: inherit;
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
    cursor: pointer;
}

.fsm-cookies__refus:hover {
    color: #111827;
}

.fsm-cookies__bouton:focus-visible,
.fsm-cookies__refus:focus-visible,
.fsm-cookies__plus:focus-visible {
    outline: 3px solid #fca5a5;
    outline-offset: 2px;
}

/* Lien « Gérer les cookies » du pied de page : un bouton qui a l'air d'un lien */
.fsm-cookies-lien {
    background: none;
    border: 0;
    padding: 0;
    margin: 0;
    font: inherit;
    color: inherit;
    cursor: pointer;
}

.fsm-cookies-lien:hover {
    color: #dc2626;
}

@media (max-width: 640px) {
    .fsm-cookies {
        left: 10px;
        right: 10px;
        bottom: calc(10px + env(safe-area-inset-bottom, 0px));
        width: auto;
    }

    .fsm-cookies__boite {
        padding: 14px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .fsm-cookies__boite {
        animation: none;
    }
}
