/*
 * Formations e-learning : fiche, grille de la page Formations, colonne du
 * mega menu (v2-files/v2-elearning-fiche.php). Couleurs du kit Elementor du
 * site, police heritee (Raleway). Mobile d'abord.
 */

.gel-fiche,
.gel-grille,
.gel-menu {
    --gel-primaire: var(--e-global-color-primary, #0077BB);
    --gel-primaire-fonce: #005f96;
    --gel-fond: #F1F5F8;
    --gel-bordure: #DBDEE6;
    --gel-texte: #272727;
    --gel-doux: #5b6470;
    --gel-rayon: 14px;
}

.gel-fiche *,
.gel-grille *,
.gel-menu * {
    box-sizing: border-box;
}

/* ----- Elements communs ----- */

.gel-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 999px;
    background: var(--gel-primaire);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

.gel-badge--clair {
    background: #fff;
    color: var(--gel-primaire);
    border: 1px solid var(--gel-bordure);
}

.gel-bouton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.95rem;
    line-height: 1.2;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.2s ease;
}

.gel-bouton--plein {
    background: var(--gel-primaire);
    color: #fff;
}

.gel-bouton--plein:hover,
.gel-bouton--plein:focus-visible,
.gel-carte__lien:hover .gel-bouton--plein,
.gel-carte__lien:focus-visible .gel-bouton--plein {
    background: var(--gel-primaire-fonce);
    color: #fff;
}

.gel-bouton--large {
    width: 100%;
    min-height: 52px;
    font-size: 1rem;
}

.gel-prix {
    font-weight: 800;
    color: var(--gel-primaire);
    white-space: nowrap;
}

.gel-image-vide {
    display: block;
    background: linear-gradient(135deg, #e3eef6, var(--gel-fond));
}

.gel-vide {
    margin: 0;
    color: var(--gel-doux);
}

/* ----- Grille de la page Formations ----- */

.gel-grille {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    scroll-margin-top: 120px;
}

.gel-carte {
    display: flex;
    min-width: 0;
}

.gel-carte__lien {
    display: flex;
    flex-direction: column;
    width: 100%;
    overflow: hidden;
    border: 1px solid var(--gel-bordure);
    border-radius: var(--gel-rayon);
    background: #fff;
    color: var(--gel-texte);
    text-decoration: none;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

/* Specificite renforcee : le theme souligne les liens de contenu
   (.page-content a), y compris dans un widget shortcode. */
.gel-grille .gel-carte__lien,
.gel-grille .gel-carte__lien *,
.gel-carrousel .gel-carte__lien,
.gel-carrousel .gel-carte__lien *,
.gel-menu .gel-menu__lien,
.gel-menu .gel-menu__lien * {
    text-decoration: none;
}

.gel-carte__lien:hover,
.gel-carte__lien:focus-visible {
    color: var(--gel-texte);
    box-shadow: 0 10px 28px rgba(0, 40, 80, 0.12);
    transform: translateY(-2px);
}

.gel-carte__media {
    position: relative;
    overflow: hidden;
    /* Carre : le format des visuels de la cliente (images produit). */
    aspect-ratio: 1 / 1;
    background: var(--gel-fond);
}

/* En position absolue : l'image remplit le cadre sans en changer la
   hauteur, quelles que soient ses proportions. Specificite renforcee :
   Elementor impose height:auto aux images (.elementor img). */
.gel-carte__media .gel-carte__image {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

.gel-carte__media .gel-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    padding: 3px 8px;
    font-size: 0.625rem;
    line-height: 1.4;
}

.gel-carte__corps {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 10px;
    padding: 18px;
}

.gel-carte__titre {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--gel-texte);
    overflow-wrap: anywhere;
}

.gel-carte__accroche {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--gel-doux);
}

/* Titre sur 2 lignes et extrait sur 3 au plus, coupes par « … » : les
   cartes gardent la meme hauteur et restent compactes. */
.gel-carte__titre,
.gel-carte__accroche {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.gel-carte__titre {
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.gel-carte__accroche {
    -webkit-line-clamp: 3;
    line-clamp: 3;
}

.gel-carte__pied {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 6px 12px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--gel-bordure);
    font-size: 0.9rem;
}

.gel-carte__duree {
    /* Une seule ligne : « 24h de formation (21 h en presentiel... » est coupe
       par « … », le texte complet reste au survol (title). */
    flex: 1;
    min-width: 0;
    overflow: hidden;
    color: var(--gel-doux);
    white-space: nowrap;
    text-overflow: ellipsis;
}

.gel-carte__corps .gel-bouton {
    width: 100%;
}

@media (min-width: 768px) {
    .gel-grille {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 30px;
    }
}

@media (min-width: 1025px) {
    .gel-grille {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 40px;
    }
}

/* ----- Colonne du mega menu ----- */

.gel-menu {
    margin: 0;
    padding: 0;
    list-style: none;
}

.gel-menu li {
    margin: 0;
    padding: 0;
}

.gel-menu__lien {
    display: block;
    padding: 8px 0;
    border-bottom: 1px solid var(--gel-bordure);
    color: var(--gel-texte);
    text-decoration: none;
}

.gel-menu li:last-child .gel-menu__lien {
    border-bottom: 0;
}

.gel-menu__titre {
    display: block;
    font-weight: 600;
    font-size: 0.95rem;
    line-height: 1.3;
}

.gel-menu__infos {
    display: block;
    margin-top: 2px;
    font-size: 0.8rem;
    color: var(--gel-doux);
}

.gel-menu__lien:hover .gel-menu__titre,
.gel-menu__lien:focus-visible .gel-menu__titre {
    color: var(--gel-primaire);
}

/* ----- Fiche ----- */

.gel-fiche {
    color: var(--gel-texte);
    overflow-x: clip;
}

.gel-wrap {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

.gel-hero {
    padding: 28px 0 32px;
    background: var(--gel-fond);
}

.gel-hero__grille {
    display: grid;
    gap: 24px;
}

.gel-ariane {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
    font-size: 0.85rem;
    color: var(--gel-doux);
}

.gel-ariane a {
    color: var(--gel-doux);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.gel-ariane a:hover {
    color: var(--gel-primaire);
}

.gel-hero__titre {
    margin: 14px 0 0;
    font-size: clamp(1.6rem, 1.2rem + 2vw, 2.5rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--gel-texte);
    overflow-wrap: anywhere;
}

.gel-hero__accroche {
    margin: 14px 0 0;
    font-size: 1.05rem;
    line-height: 1.55;
    color: var(--gel-doux);
}

.gel-faits {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 20px 0 0;
    padding: 0;
    list-style: none;
}

.gel-faits li {
    display: flex;
    flex-direction: column;
    margin: 0;
    padding: 10px 14px;
    border: 1px solid var(--gel-bordure);
    border-radius: 10px;
    background: #fff;
    font-weight: 700;
    font-size: 0.95rem;
}

.gel-faits__libelle {
    font-weight: 500;
    font-size: 0.75rem;
    color: var(--gel-doux);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.gel-hero__media {
    overflow: hidden;
    width: 100%;
    max-width: 460px;
    justify-self: center;
    border-radius: var(--gel-rayon);
    background: #fff;
}

/* Image entiere, a ses proportions : rien n'est coupe. */
.gel-hero__image {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
}

.gel-hero__media .gel-image-vide {
    aspect-ratio: 1 / 1;
}

.gel-corps {
    display: grid;
    gap: 28px;
    padding-top: 28px;
    padding-bottom: 56px;
}

.gel-achat {
    align-self: start;
    padding: 20px;
    border: 1px solid var(--gel-bordure);
    border-radius: var(--gel-rayon);
    background: #fff;
    box-shadow: 0 10px 28px rgba(0, 40, 80, 0.08);
}

.gel-achat__prix {
    margin: 0 0 14px;
    font-size: 1.9rem;
    font-weight: 800;
    line-height: 1.1;
    color: var(--gel-primaire);
}

.gel-achat__note {
    margin: 12px 0 0;
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--gel-doux);
}

.gel-achat__espace {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin-top: 6px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--gel-primaire);
}

.gel-contenu {
    min-width: 0;
}

.gel-bloc + .gel-bloc {
    margin-top: 32px;
    padding-top: 32px;
    border-top: 1px solid var(--gel-bordure);
}

.gel-bloc__titre {
    margin: 0 0 14px;
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--gel-texte);
}

.gel-texte {
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.gel-texte > :first-child {
    margin-top: 0;
}

.gel-texte img {
    max-width: 100%;
    height: auto;
}

.gel-liste {
    margin: 0;
    padding: 0;
    list-style: none;
}

.gel-liste li {
    position: relative;
    margin: 0 0 10px;
    padding-left: 30px;
    line-height: 1.5;
}

.gel-liste--coches li::before {
    content: "";
    position: absolute;
    top: 0.2em;
    left: 0;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gel-primaire) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='white'%3E%3Cpath d='M8.1 13.6 4.5 10l1.1-1.1 2.5 2.5 6.3-6.3 1.1 1.1z'/%3E%3C/svg%3E") center / 14px no-repeat;
}

.gel-programme {
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: gel-module;
}

.gel-programme li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 8px;
    padding: 12px 14px;
    border: 1px solid var(--gel-bordure);
    border-radius: 10px;
    background: var(--gel-fond);
    font-weight: 600;
    line-height: 1.4;
    counter-increment: gel-module;
    overflow-wrap: anywhere;
}

.gel-programme li::before {
    content: counter(gel-module);
    flex: 0 0 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    color: var(--gel-primaire);
    font-weight: 800;
    font-size: 0.85rem;
    line-height: 28px;
    text-align: center;
}

.gel-infos {
    display: grid;
    gap: 12px;
    margin: 0;
}

.gel-infos div {
    padding: 14px 16px;
    border: 1px solid var(--gel-bordure);
    border-radius: 10px;
}

.gel-infos dt {
    margin: 0 0 4px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--gel-doux);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.gel-infos dd {
    margin: 0;
    line-height: 1.5;
}

.gel-retour {
    margin: 36px 0 0;
}

.gel-retour a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-weight: 700;
    color: var(--gel-primaire);
}

@media (min-width: 768px) {
    .gel-wrap {
        padding: 0 32px;
    }

    .gel-hero {
        padding: 40px 0 48px;
    }

    .gel-infos {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (min-width: 1025px) {
    .gel-hero__grille {
        grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
        align-items: center;
        gap: 48px;
    }

    .gel-corps {
        grid-template-columns: minmax(0, 1fr) 340px;
        gap: 48px;
        padding-top: 48px;
        padding-bottom: 80px;
    }

    /* Colonne de droite, toujours visible pendant la lecture. */
    .gel-achat {
        grid-column: 2;
        grid-row: 1;
        position: sticky;
        top: 120px;
    }

    .gel-contenu {
        grid-column: 1;
        grid-row: 1;
    }
}

/* ----- Formations en presentiel et en classe virtuelle ----- */

.gel-liste-formations {
    --gel-primaire: var(--e-global-color-primary, #0077BB);
    --gel-primaire-fonce: #005f96;
    --gel-fond: #F1F5F8;
    --gel-bordure: #DBDEE6;
    --gel-texte: #272727;
    --gel-doux: #5b6470;
    --gel-rayon: 14px;
}

/* Photos sans texte : recadrees dans un cadre fixe, toutes les cartes ont
   une image de meme hauteur quel que soit le format d'origine. */
.gel-carte--presentiel .gel-carte__media {
    aspect-ratio: 16 / 10;
}

.gel-badge--sombre {
    background: var(--gel-texte);
    color: #fff;
}

.gel-bouton--contour {
    border: 2px solid var(--gel-primaire);
    background: #fff;
    color: var(--gel-primaire);
    cursor: pointer;
}

.gel-bouton--contour:hover,
.gel-bouton--contour:focus-visible {
    background: var(--gel-primaire);
    color: #fff;
}

.gel-plus {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 32px;
}

/* Specificite renforcee : le theme et le kit Elementor stylent tous les
   <button> (bordure, couleur, survol). */
.gel-plus .gel-plus__bouton {
    gap: 10px;
    min-width: min(100%, 280px);
    min-height: 48px;
    margin: 0;
    padding: 12px 28px;
    border: 2px solid var(--gel-primaire);
    border-radius: 8px;
    background: #fff;
    color: var(--gel-primaire);
    font-family: inherit;
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.2;
    text-transform: none;
    box-shadow: none;
}

.gel-plus .gel-plus__bouton:hover,
.gel-plus .gel-plus__bouton:focus-visible {
    border-color: var(--gel-primaire);
    background: var(--gel-primaire);
    color: #fff;
}

.gel-plus .gel-plus__bouton:focus-visible {
    outline: 3px solid rgba(0, 119, 187, 0.35);
    outline-offset: 2px;
}

.gel-plus .gel-plus__bouton:disabled {
    border-color: var(--gel-primaire);
    background: #fff;
    color: var(--gel-primaire);
    cursor: wait;
}

.gel-plus__roue {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: gel-tourne 0.7s linear infinite;
}

.gel-plus__bouton.is-chargement .gel-plus__roue {
    display: inline-block;
}

.gel-plus__etat {
    min-height: 1.2em;
    margin: 0;
    font-size: 0.85rem;
    color: var(--gel-doux);
    text-align: center;
}

.gel-plus__etat:empty {
    min-height: 0;
}

/* Cartes d'attente pendant le chargement. */
.gel-carte--attente .gel-carte__lien {
    pointer-events: none;
}

.gel-carte--attente .gel-carte__media {
    aspect-ratio: 16 / 10;
}

.gel-carte--attente .gel-carte__media,
.gel-trait {
    background: linear-gradient(90deg, #eef2f6 25%, #f7f9fb 50%, #eef2f6 75%);
    background-size: 200% 100%;
    animation: gel-reflet 1.2s ease-in-out infinite;
}

.gel-trait {
    display: block;
    height: 14px;
    border-radius: 7px;
}

.gel-trait--titre {
    width: 80%;
    height: 20px;
}

.gel-trait--court {
    width: 55%;
}

.gel-carte--attente .gel-carte__corps {
    min-height: 180px;
}

@keyframes gel-tourne {
    to { transform: rotate(360deg); }
}

@keyframes gel-reflet {
    from { background-position: 200% 0; }
    to { background-position: -200% 0; }
}

@media (prefers-reduced-motion: reduce) {
    .gel-plus__roue,
    .gel-carte--attente .gel-carte__media,
    .gel-trait {
        animation: none;
    }
}

/* ----- Carrousel des formations (accueil) ----- */

.gel-carrousel {
    --gel-primaire: var(--e-global-color-primary, #0077BB);
    --gel-primaire-fonce: #005f96;
    --gel-fond: #F1F5F8;
    --gel-bordure: #DBDEE6;
    --gel-texte: #272727;
    --gel-doux: #5b6470;
    --gel-rayon: 14px;
    --gel-visibles: 1.15;
    --gel-ecart: 16px;
    position: relative;
}

.gel-carrousel *,
.gel-carrousel *::before {
    box-sizing: border-box;
}

.gel-carrousel__piste {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - (var(--gel-visibles) - 1) * var(--gel-ecart)) / var(--gel-visibles));
    column-gap: var(--gel-ecart);
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    /* Place sous les cartes pour leur ombre au survol : la piste defile en
       horizontal, elle rogne tout ce qui depasse. */
    padding: 4px 2px 22px;
    /* Meme marge que la piste : l'alignement ne rogne pas la bordure de la
       premiere carte. */
    scroll-padding-inline: 2px;
}

.gel-carrousel__piste::-webkit-scrollbar {
    display: none;
}

.gel-carrousel__piste:focus-visible {
    outline: 3px solid rgba(0, 119, 187, 0.35);
    outline-offset: 4px;
    border-radius: var(--gel-rayon);
}

.gel-carrousel__item {
    display: flex;
    min-width: 0;
    scroll-snap-align: start;
}

.gel-carrousel__item .gel-carte {
    width: 100%;
}

/* Survol sans soulevement et ombre plus serree : elle tient dans la piste. */
.gel-carrousel .gel-carte__lien:hover,
.gel-carrousel .gel-carte__lien:focus-visible {
    transform: none;
    box-shadow: 0 6px 14px rgba(0, 40, 80, 0.12);
}

.gel-carrousel__nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 6px 0 28px;
}

.gel-carrousel.is-statique .gel-carrousel__nav {
    display: none;
}

/* Specificite renforcee : le theme et le kit Elementor stylent les <button>. */
.gel-carrousel .gel-carrousel__fleche {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    padding: 0;
    border: 2px solid var(--gel-primaire);
    border-radius: 50%;
    background: #fff;
    color: var(--gel-primaire);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    box-shadow: none;
}

.gel-carrousel .gel-carrousel__fleche span {
    margin-top: -3px;
}

.gel-carrousel .gel-carrousel__fleche:hover,
.gel-carrousel .gel-carrousel__fleche:focus-visible {
    background: var(--gel-primaire);
    color: #fff;
}

.gel-carrousel__points {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2px;
}

/* Point visible de 10 px, zone cliquable de 28 px. */
.gel-carrousel .gel-carrousel__point {
    position: relative;
    width: 28px;
    height: 28px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    box-shadow: none;
}

.gel-carrousel .gel-carrousel__point::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--gel-bordure);
    transform: translate(-50%, -50%);
    transition: background-color 0.2s ease, width 0.2s ease;
}

.gel-carrousel .gel-carrousel__point[aria-current="true"]::before {
    width: 22px;
    border-radius: 5px;
    background: var(--gel-primaire);
}

.gel-carrousel .gel-carrousel__point:hover,
.gel-carrousel .gel-carrousel__point:focus-visible {
    background: transparent;
}

@media (min-width: 768px) {
    .gel-carrousel {
        --gel-visibles: 2;
        --gel-ecart: 30px;
    }
}

@media (min-width: 1025px) {
    .gel-carrousel {
        --gel-visibles: 3;
        --gel-ecart: 40px;
    }
}

/* Mobile : la piste va d'un bord a l'autre de l'ecran. Les cartes defilent
   jusqu'aux bords, et la premiere reste alignee sur le titre : la marge
   gagnee est rendue en padding (le scroll-padding assorti est pose par le
   script, un pourcentage n'y designant pas la meme largeur). */
@media (max-width: 767px) {
    .gel-carrousel__piste {
        margin-inline: calc(50% - 50vw);
        padding-inline: calc(50vw - 50%);
    }
}

@media (max-width: 400px) {
    .gel-carrousel__points {
        display: none;
    }
}

/* ----- Carrousel des formateurs (accueil) ----- */

.gel-carte--formateur .gel-carte__media {
    aspect-ratio: 1 / 1;
    background: var(--gel-primaire);
}

/* Portraits sur fond uni : on garde la tete dans le cadre. */
.gel-carte--formateur .gel-carte__media .gel-carte__image {
    object-position: center top;
}

.gel-carte--formateur .gel-carte__corps {
    gap: 4px;
    padding: 16px;
    text-align: center;
}

.gel-carte--formateur .gel-carte__titre {
    font-size: 1.05rem;
}

.gel-carte__metier {
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.4;
    color: var(--gel-doux);
}

@media (min-width: 768px) {
    .gel-carrousel--formateurs {
        --gel-visibles: 3;
    }
}

@media (min-width: 1025px) {
    .gel-carrousel--formateurs {
        --gel-visibles: 4;
        --gel-ecart: 30px;
    }
}

/* ----- Carrousel des actualites (accueil) ----- */

.gel-carte--article .gel-carte__media {
    aspect-ratio: 16 / 10;
}

/* ----- Page produit (boutique) ----- */

.gel-produit {
    padding: 24px 0 56px;
}

.gel-produit__haut {
    display: grid;
    gap: 24px;
}

.gel-produit .gel-hero__titre {
    margin-top: 0;
}

.gel-galerie {
    min-width: 0;
}

.gel-galerie__principale {
    overflow: hidden;
    aspect-ratio: 3 / 2;
    border: 1px solid var(--gel-bordure);
    border-radius: var(--gel-rayon);
    background: var(--gel-fond);
}

.gel-galerie__principale img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

.gel-galerie__principale .gel-image-vide {
    width: 100%;
    height: 100%;
}

.gel-galerie__vignettes {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(64px, 1fr));
    gap: 10px;
    margin-top: 12px;
}

/* Specificite renforcee : le theme stylent tous les <button>. */
.gel-galerie .gel-galerie__vignette {
    display: block;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    margin: 0;
    padding: 0;
    border: 2px solid transparent;
    border-radius: 10px;
    background: var(--gel-fond);
    cursor: pointer;
    box-shadow: none;
}

.gel-galerie .gel-galerie__vignette img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

.gel-galerie .gel-galerie__vignette[aria-current="true"],
.gel-galerie .gel-galerie__vignette:hover,
.gel-galerie .gel-galerie__vignette:focus-visible {
    border-color: var(--gel-primaire);
    background: var(--gel-fond);
}

.gel-produit__infos {
    min-width: 0;
}

.gel-produit__resume {
    margin-top: 14px;
    font-size: 1.05rem;
    line-height: 1.6;
    color: var(--gel-doux);
}

.gel-produit__resume p {
    margin: 0 0 0.6em;
}

.gel-produit .gel-produit__achat {
    position: static;
    margin-top: 20px;
}

.gel-produit .gel-achat__prix del {
    margin-right: 8px;
    font-size: 1.1rem;
    color: var(--gel-doux);
}

.gel-produit .gel-achat__prix ins {
    text-decoration: none;
}

/* Formulaire WooCommerce : stock, quantite, bouton. */
.gel-produit__achat .stock {
    margin: 0 0 12px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #00875a;
}

.gel-produit__achat .stock.out-of-stock {
    color: #b32d2e;
}

.gel-produit__achat form.cart {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0;
}

/* Vendu a l'unite : la quantite est un champ cache, son bloc ne doit pas
   decaler le bouton. */
.gel-produit__achat form.cart .quantity:has(input[type="hidden"]) {
    display: none;
}

.gel-produit__achat form.cart .quantity input {
    width: 72px;
    min-height: 52px;
    border: 1px solid var(--gel-bordure);
    border-radius: 8px;
    text-align: center;
}

/* Specificite renforcee : WooCommerce (.woocommerce button.button.alt) et
   le kit Elementor stylent ce bouton. */
.gel-produit .gel-produit__achat form.cart button.single_add_to_cart_button {
    flex: 1;
    min-height: 52px;
    margin: 0;
    padding: 12px 24px;
    border: 0;
    border-radius: 8px;
    background: var(--gel-primaire);
    color: #fff;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
}

.gel-produit .gel-produit__achat form.cart button.single_add_to_cart_button:hover,
.gel-produit .gel-produit__achat form.cart button.single_add_to_cart_button:focus-visible {
    background: var(--gel-primaire-fonce);
    color: #fff;
}

.gel-produit__bas {
    max-width: 820px;
    margin-top: 48px;
}

/* Description saisie dans WooCommerce : titres, paragraphes et listes
   espaces pour se lire comme un texte, quelles que soient les balises
   choisies dans l'editeur (h3, h5, h6, styles en ligne). */
.gel-produit__description {
    font-size: 1rem;
    line-height: 1.7;
}

.gel-produit__description p,
.gel-produit__description ul,
.gel-produit__description ol {
    margin: 0 0 1em;
}

.gel-produit__description ul ul,
.gel-produit__description ol ul {
    margin: 0.4em 0 0;
}

.gel-produit__description li {
    margin-bottom: 0.35em;
}

.gel-produit__description ul {
    padding-left: 1.3em;
}

.gel-produit__description li::marker {
    color: var(--gel-primaire);
}

.gel-produit__description h2,
.gel-produit__description h3,
.gel-produit__description h4,
.gel-produit__description h5 {
    margin: 1.6em 0 0.6em;
    font-size: 1.2rem;
    font-weight: 800 !important;
    line-height: 1.3;
    color: var(--gel-texte);
}

.gel-produit__description > :first-child {
    margin-top: 0;
}

/* Petite mention (h6) : encadre d'information. */
.gel-produit__description h6 {
    margin: 0 0 1.2em;
    padding: 12px 16px;
    border-left: 4px solid var(--gel-primaire);
    border-radius: 0 8px 8px 0;
    background: var(--gel-fond);
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.5;
    color: var(--gel-texte);
}

.gel-produit__description a {
    color: var(--gel-primaire);
    text-decoration: underline;
}

.gel-video {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border-radius: var(--gel-rayon);
    background: #000;
}

.gel-video iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

@media (min-width: 768px) {
    .gel-produit {
        padding: 32px 0 80px;
    }
}

@media (min-width: 1025px) {
    .gel-produit__haut {
        grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
        align-items: start;
        gap: 48px;
    }
}

/* ----- Panier flottant ----- */

.gel-panier {
    --gel-primaire: var(--e-global-color-primary, #0077BB);
    --gel-primaire-fonce: #005f96;
    --gel-fond: #F1F5F8;
    --gel-bordure: #DBDEE6;
    --gel-texte: #272727;
    --gel-doux: #5b6470;
    --gel-rayon: 14px;
}

.gel-panier[hidden] {
    display: none;
}

.gel-panier *,
.gel-panier *::before {
    box-sizing: border-box;
}

.gel-panier .screen-reader-text {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

/* Specificite renforcee : le theme et le kit Elementor stylent les <button>. */
.gel-panier .gel-panier__bouton {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 99990;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--gel-primaire);
    color: #fff;
    box-shadow: 0 8px 24px rgba(0, 40, 80, 0.28);
    cursor: pointer;
    animation: gel-panier-entree 0.25s ease-out;
}

.gel-panier .gel-panier__bouton:hover,
.gel-panier .gel-panier__bouton:focus-visible {
    background: var(--gel-primaire-fonce);
    color: #fff;
}

.gel-panier .gel-panier__bouton:focus-visible {
    outline: 3px solid rgba(0, 119, 187, 0.4);
    outline-offset: 3px;
}

.gel-panier__compte {
    position: absolute;
    top: -2px;
    right: -2px;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border: 2px solid #fff;
    border-radius: 11px;
    background: #CE2424;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 800;
    line-height: 18px;
    text-align: center;
}

.gel-panier__fond {
    position: fixed;
    inset: 0;
    z-index: 99991;
    background: rgba(15, 23, 32, 0.45);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s;
}

.gel-panier__volet {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 99992;
    display: flex;
    flex-direction: column;
    width: min(420px, 100%);
    background: #fff;
    color: var(--gel-texte);
    box-shadow: -12px 0 32px rgba(0, 40, 80, 0.18);
    transform: translateX(100%);
    visibility: hidden;
    transition: transform 0.3s ease, visibility 0.3s;
    outline: none;
}

.gel-panier.is-ouvert .gel-panier__fond {
    opacity: 1;
    visibility: visible;
}

.gel-panier.is-ouvert .gel-panier__volet {
    transform: none;
    visibility: visible;
}

html.gel-panier-ouvert {
    overflow: hidden;
}

.gel-panier__contenu {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 0;
    transition: opacity 0.2s;
}

.gel-panier__contenu.is-chargement {
    opacity: 0.55;
    pointer-events: none;
}

.gel-panier__entete {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 20px;
    border-bottom: 1px solid var(--gel-bordure);
}

.gel-panier__titre {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--gel-texte);
}

.gel-panier__titre span {
    font-weight: 600;
    color: var(--gel-doux);
}

.gel-panier .gel-panier__fermer {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--gel-fond);
    color: var(--gel-texte);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
}

.gel-panier .gel-panier__fermer:hover,
.gel-panier .gel-panier__fermer:focus-visible {
    background: var(--gel-bordure);
    color: var(--gel-texte);
}

.gel-panier__message {
    margin: 14px 20px 0;
    padding: 10px 14px;
    border-radius: 8px;
    background: #e8f6ee;
    color: #00663f;
    font-size: 0.9rem;
    line-height: 1.4;
}

.gel-panier__message--erreur {
    background: #fdecec;
    color: #a11b1b;
}

.gel-panier__vide {
    margin: 0;
    padding: 32px 20px;
    color: var(--gel-doux);
    text-align: center;
}

.gel-panier__lignes {
    flex: 1;
    margin: 0;
    padding: 8px 20px;
    overflow-y: auto;
    list-style: none;
}

.gel-panier__ligne {
    display: flex;
    gap: 14px;
    margin: 0;
    padding: 14px 0;
    border-bottom: 1px solid var(--gel-bordure);
}

.gel-panier__ligne:last-child {
    border-bottom: 0;
}

.gel-panier__image {
    flex: 0 0 72px;
    width: 72px;
    height: 72px;
    overflow: hidden;
    border-radius: 10px;
    background: var(--gel-fond);
}

.gel-panier__image img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

.gel-panier__detail {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.gel-panier__nom {
    font-weight: 700;
    line-height: 1.3;
    color: var(--gel-texte);
    text-decoration: none;
}

a.gel-panier__nom:hover {
    color: var(--gel-primaire);
}

.gel-panier__prix {
    font-weight: 700;
    color: var(--gel-primaire);
}

.gel-panier__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 4px;
}

.gel-panier__quantite {
    display: inline-flex;
    align-items: center;
    border: 1px solid var(--gel-bordure);
    border-radius: 8px;
}

.gel-panier__quantite span {
    min-width: 28px;
    font-weight: 700;
    text-align: center;
}

.gel-panier .gel-panier__quantite button {
    width: 36px;
    height: 36px;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--gel-texte);
    font-size: 1.1rem;
    cursor: pointer;
}

.gel-panier .gel-panier__quantite button:hover,
.gel-panier .gel-panier__quantite button:focus-visible {
    background: var(--gel-fond);
    color: var(--gel-texte);
}

.gel-panier .gel-panier__retirer {
    min-height: 36px;
    margin: 0;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: var(--gel-doux);
    font-size: 0.85rem;
    text-decoration: underline;
    cursor: pointer;
}

.gel-panier .gel-panier__retirer:hover,
.gel-panier .gel-panier__retirer:focus-visible {
    background: transparent;
    color: #a11b1b;
}

.gel-panier__pied {
    padding: 16px 20px 20px;
    border-top: 1px solid var(--gel-bordure);
    background: var(--gel-fond);
}

.gel-panier__total {
    display: flex;
    justify-content: space-between;
    margin: 0;
    font-size: 1.05rem;
}

.gel-panier__note {
    margin: 4px 0 14px;
    font-size: 0.8rem;
    color: var(--gel-doux);
}

.gel-panier .gel-panier__pied .gel-bouton--plein {
    text-decoration: none;
}

.gel-panier__voir {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    margin-top: 6px;
    font-weight: 600;
    color: var(--gel-primaire);
}

/* Bouton d'ajout de la page produit pendant l'envoi. */
.gel-produit .gel-produit__achat form.cart button.single_add_to_cart_button.is-chargement {
    opacity: 0.7;
    cursor: wait;
}

@keyframes gel-panier-entree {
    from { transform: scale(0.6); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
    .gel-panier .gel-panier__bouton,
    .gel-panier__volet,
    .gel-panier__fond {
        animation: none;
        transition: none;
    }
}

/* ----- Page formateur ----- */

.gel-formateur__entete {
    display: grid;
    gap: 20px;
    align-items: center;
    justify-items: center;
    text-align: center;
}

.gel-formateur__photo {
    overflow: hidden;
    width: 200px;
    aspect-ratio: 1 / 1;
    border: 4px solid #fff;
    border-radius: 50%;
    background: var(--gel-primaire);
    box-shadow: 0 10px 28px rgba(0, 40, 80, 0.15);
}

.gel-formateur__photo img,
.gel-formateur__photo .gel-image-vide {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center top;
}

.gel-formateur__identite .gel-hero__titre {
    margin-top: 12px;
}

.gel-formateur__identite .gel-hero__accroche {
    margin-top: 6px;
}

.gel-formateur__cv {
    margin-top: 18px;
    text-decoration: none;
}

.gel-formateur__corps {
    padding-top: 32px;
    padding-bottom: 56px;
}

/* Toute la largeur, en deux colonnes sur grand ecran : le texte reste
   lisible sans laisser de vide a droite. Un paragraphe n'est jamais coupe
   entre deux colonnes. */
.gel-formateur__presentation .gel-produit__description p {
    break-inside: avoid;
}

@media (min-width: 1025px) {
    .gel-formateur__presentation .gel-produit__description {
        column-count: 2;
        column-gap: 56px;
    }
}

.gel-formateur__parcours {
    display: grid;
    gap: 20px;
    margin-top: 40px;
}

.gel-formateur__carte {
    padding: 22px;
    border: 1px solid var(--gel-bordure);
    border-radius: var(--gel-rayon);
    background: var(--gel-fond);
}

.gel-formateur__carte .gel-bloc__titre {
    font-size: 1.15rem;
}

.gel-formateur__carte .gel-liste li:last-child {
    margin-bottom: 0;
}

.gel-formateur__animees {
    margin-top: 48px;
}

.gel-formateur__animees .gel-carrousel {
    margin-top: 20px;
}

@media (min-width: 768px) {
    .gel-formateur__entete {
        grid-template-columns: auto minmax(0, 1fr);
        justify-items: start;
        gap: 36px;
        text-align: left;
    }

    .gel-formateur__photo {
        width: 240px;
    }

    .gel-formateur__parcours {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .gel-formateur__corps {
        padding-top: 48px;
        padding-bottom: 80px;
    }
}

/* ----- Page lieu de formation ----- */

.gel-lieu__bandeau {
    position: relative;
    overflow: hidden;
    padding: 40px 0 44px;
    background: #1f2a33;
    color: #fff;
}

/* Photo du lieu en fond, assombrie pour que le texte reste lisible. */
.gel-lieu__bandeau .gel-lieu__fond {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

.gel-lieu__bandeau::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(10, 20, 30, 0.35), rgba(10, 20, 30, 0.75));
}

.gel-lieu__bandeau-contenu {
    position: relative;
    z-index: 1;
}

.gel-lieu__bandeau .gel-ariane,
.gel-lieu__bandeau .gel-ariane a {
    color: rgba(255, 255, 255, 0.85);
}

.gel-lieu__bandeau .gel-ariane a:hover {
    color: #fff;
}

.gel-lieu__bandeau .gel-hero__titre {
    color: #fff;
}

.gel-lieu__ville {
    margin: 8px 0 0;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
}

.gel-lieu__corps {
    padding-top: 32px;
    padding-bottom: 56px;
}

.gel-lieu__faits {
    display: grid;
    gap: 16px;
}

.gel-lieu__fait {
    padding: 18px 20px;
    border: 1px solid var(--gel-bordure);
    border-radius: var(--gel-rayon);
    background: #fff;
}

.gel-lieu__fait p {
    margin: 4px 0 0;
    font-size: 1.05rem;
    font-weight: 600;
    line-height: 1.5;
}

.gel-lieu__fait .gel-lieu__riche p:first-child {
    margin-top: 4px;
}

.gel-lieu__riche p {
    margin: 0 0 0.6em;
}

.gel-lieu__riche > :last-child {
    margin-bottom: 0;
}

.gel-lieu__carte {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-weight: 600;
    color: var(--gel-primaire);
}

.gel-lieu__infos {
    margin-top: 24px;
}

.gel-lieu__video {
    max-width: 900px;
    margin-top: 48px;
}

/* Miniature et bouton de lecture : YouTube ne charge qu'au clic. */
.gel-video--facade .gel-video__miniature {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
}

.gel-video .gel-video__lancer {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: rgba(0, 0, 0, 0.15);
    cursor: pointer;
}

.gel-video .gel-video__lancer:hover,
.gel-video .gel-video__lancer:focus-visible {
    background: rgba(0, 0, 0, 0.3);
}

.gel-video__play {
    position: relative;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--gel-primaire);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.gel-video__play::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 54%;
    border-top: 13px solid transparent;
    border-bottom: 13px solid transparent;
    border-left: 20px solid #fff;
    transform: translate(-50%, -50%);
}

.gel-video__accord {
    position: absolute;
    right: 12px;
    bottom: 12px;
    left: 12px;
    display: none;
    margin: 0;
    padding: 10px 14px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.95);
    font-size: 0.85rem;
    line-height: 1.4;
    color: var(--gel-texte);
    pointer-events: none;
}

.gel-video.is-accord .gel-video__accord {
    display: block;
}

@media (min-width: 768px) {
    .gel-lieu__bandeau {
        padding: 64px 0 72px;
    }

    .gel-lieu__faits {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .gel-lieu__corps {
        padding-top: 40px;
        padding-bottom: 80px;
    }
}

/* ----- Grille des lieux (page « Nos etablissements ») ----- */

.gel-carte--lieu .gel-carte__media {
    aspect-ratio: 16 / 10;
}

.gel-carte--lieu .gel-carte__accroche {
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

/* Sans ligne de pied, le bouton descend quand meme en bas de la carte. */
.gel-carte__accroche + .gel-bouton,
.gel-carte__titre + .gel-bouton {
    margin-top: auto;
}

/* ----- Grille des formateurs (page « Les formateurs ») ----- */

/* Portraits sur fond bleu : cadre 4/3, cale en haut pour garder le visage. */
.gel-carte--profil .gel-carte__media {
    aspect-ratio: 4 / 3;
}

.gel-carte--profil .gel-carte__corps {
    gap: 8px;
    padding: 18px;
    text-align: left;
}

.gel-carte--profil .gel-carte__titre {
    font-size: 1.1rem;
}

.gel-carte--profil .gel-carte__metier {
    margin-top: -4px;
    font-weight: 600;
    color: var(--gel-primaire);
}
