/* =========================================================
   GOTIQUE — taxonomy-editorial.css
   Chargé sur : catégories et étiquettes produit uniquement.
   Contenu : mise en forme des descriptions éditoriales.

   Les sélecteurs `div.clearfix:has(h3)` sont conservés tels
   quels : le conteneur généré par Kadence/WooCommerce n'expose
   aucune classe métier exploitable. Comme ce fichier n'est plus
   chargé que sur les archives produit, la portée de `:has()`
   est déjà fortement réduite par rapport à un chargement global.
   ========================================================= */


div.clearfix:has(h3) {

    max-width: 980px;
    margin: 70px auto 40px;
    padding: 0 20px;

    font-size: 16px;
    line-height: 1.75;
    color: var(--global-palette4);
}


/* =========================================================
   PARAGRAPHES
   ========================================================= */

div.clearfix:has(h3) p {
    margin: 0 0 24px;
}


/* =========================================================
   H2 — GRANDES SECTIONS
   ========================================================= */

div.clearfix:has(h3) h2 {

    position: relative;

    margin: 58px 0 26px;
    padding: 0 0 14px 18px;

    font-size: 27px;
    line-height: 1.3;
    font-weight: 700;

    color: var(--global-palette3);

    border-bottom: 1px solid rgba(86, 26, 80, 0.20);
}

/* Accent violet H2 */
div.clearfix:has(h3) h2::before {

    content: "";

    position: absolute;
    left: 0;
    top: 2px;

    width: 5px;
    height: calc(100% - 16px);

    background: #561A50;
    border-radius: 4px;
}


/* =========================================================
   H3 — SOUS-SECTIONS
   ========================================================= */

div.clearfix:has(h3) h3 {

    position: relative;

    margin: 44px 0 19px;
    padding: 0 0 11px 15px;

    font-size: 22px;
    line-height: 1.35;
    font-weight: 700;

    color: var(--global-palette3);

    border-bottom: 1px solid rgba(86, 26, 80, 0.15);
}

/* Accent violet H3 */
div.clearfix:has(h3) h3::before {

    content: "";

    position: absolute;
    left: 0;
    top: 2px;

    width: 4px;
    height: calc(100% - 13px);

    background: #561A50;
    border-radius: 3px;
}


/* =========================================================
   LIENS DANS LES TITRES
   ========================================================= */

div.clearfix:has(h3) h2 a,
div.clearfix:has(h3) h3 a {

    color: #561A50 !important;
    text-decoration: none !important;

    transition: color 0.2s ease;
}

div.clearfix:has(h3) h2 a:hover,
div.clearfix:has(h3) h3 a:hover {

    color: #8a2be2 !important;
}


/* =========================================================
   LIENS DANS LES PARAGRAPHES
   ========================================================= */

div.clearfix:has(h3) p a {

    color: #561A50 !important;
    text-decoration: underline !important;

    text-decoration-thickness: 1px;
    text-underline-offset: 3px;

    transition: color 0.2s ease;
}

div.clearfix:has(h3) p a:hover {

    color: #8a2be2 !important;
}


/* =========================================================
   TEXTE EN GRAS
   ========================================================= */

div.clearfix:has(h3) strong {

    font-weight: 700;
    color: var(--global-palette3);
}


/* =========================================================
   FAQ — ACCORDÉONS
   ========================================================= */

div.clearfix:has(h3) details {

    margin: 0;

    border-top: 1px solid rgba(86, 26, 80, 0.15);
}

div.clearfix:has(h3) details:last-of-type {

    border-bottom: 1px solid rgba(86, 26, 80, 0.15);
}


/* ---------------------------------------------------------
   QUESTION
   --------------------------------------------------------- */

div.clearfix:has(h3) details summary {

    position: relative;

    padding: 19px 45px 19px 4px;

    cursor: pointer;

    font-size: 17px;
    line-height: 1.45;
    font-weight: 700;

    color: var(--global-palette3);

    list-style: none;

    transition:
        color 0.2s ease,
        padding-left 0.2s ease;
}

/* Supprime le triangle natif */
div.clearfix:has(h3) details summary::-webkit-details-marker {

    display: none;
}

/* Symbole + */
div.clearfix:has(h3) details summary::after {

    content: "+";

    position: absolute;

    right: 5px;
    top: 50%;

    transform: translateY(-50%);

    font-size: 25px;
    font-weight: 400;
    line-height: 1;

    color: #561A50;

    transition: color 0.2s ease;
}

/* Question au survol */
div.clearfix:has(h3) details summary:hover {

    color: #561A50;
    padding-left: 9px;
}

/* Symbole quand ouvert */
div.clearfix:has(h3) details[open] summary::after {

    content: "−";
    color: #8a2be2;
}


/* ---------------------------------------------------------
   RÉPONSE FAQ
   --------------------------------------------------------- */

div.clearfix:has(h3) details > p {

    margin: 0;

    padding: 0 45px 23px 9px;

    font-size: 15.5px;
    line-height: 1.7;

    font-weight: 400 !important;
    color: var(--global-palette4);
}

/* Les <strong> volontaires restent en gras */
div.clearfix:has(h3) details > p strong {

    font-weight: 700 !important;
    color: var(--global-palette3);
}

/* Liens dans les réponses FAQ */
div.clearfix:has(h3) details > p a {

    color: #561A50 !important;
    text-decoration: underline !important;

    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}


/* =========================================================
   DERNIER PARAGRAPHE
   ========================================================= */

div.clearfix:has(h3) > p:last-child {

    margin-bottom: 0;
}


/* =========================================================
   VERSION MOBILE
   ========================================================= */

@media (max-width: 767px) {

    div.clearfix:has(h3) {

        margin: 50px auto 30px;
        padding: 0 16px;

        font-size: 15px;
        line-height: 1.7;
    }

    /* H2 */
    div.clearfix:has(h3) h2 {

        margin-top: 45px;
        margin-bottom: 21px;

        padding-left: 14px;
        padding-bottom: 11px;

        font-size: 23px;
    }

    /* H3 */
    div.clearfix:has(h3) h3 {

        margin-top: 35px;
        margin-bottom: 17px;

        padding-left: 12px;
        padding-bottom: 9px;

        font-size: 19px;
    }

    /* Questions FAQ */
    div.clearfix:has(h3) details summary {

        padding: 17px 38px 17px 2px;

        font-size: 16px;
    }

    /* Réponses FAQ */
    div.clearfix:has(h3) details > p {

        padding: 0 35px 20px 5px;

        font-size: 15px;

        font-weight: 400 !important;
    }

    div.clearfix:has(h3) details > p strong {

        font-weight: 700 !important;
    }
}
