/* =====================================================================
   AZORLEARN — PAGE « NOS FORMATIONS » (v3)
   Styles limités à .fm-main : le header et le footer ne sont pas touchés.
   ===================================================================== */

.fm-main {
    --fm-blue: #0b5fe0;
    --fm-blue-2: #2f86f5;
    --fm-blue-dark: #0a47b8;
    --fm-sky: #43b9f2;
    --fm-amber: #f5a524;
    --fm-navy: #0a1a3a;
    --fm-ink: #13234a;
    --fm-text: #3b4a6b;
    --fm-muted: #6a7a98;
    --fm-line: #e4ebf6;
    --fm-soft: #f3f7fe;
    --fm-radius: 22px;
    --fm-shadow: 0 14px 40px rgba(10, 26, 58, .08);
    --fm-shadow-lg: 0 26px 60px rgba(10, 26, 58, .16);
    --fm-font: "Lexend", "Segoe UI", system-ui, Arial, sans-serif;

    position: relative;
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    overflow-x: clip;
    color: var(--fm-text);
    background: #fff;
    font-family: var(--fm-font);
    font-size: var(--t-body);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

.fm-main *, .fm-main *::before, .fm-main *::after { box-sizing: border-box; }
.fm-main h1, .fm-main h2, .fm-main h3, .fm-main p, .fm-main ul, .fm-main ol { margin: 0; padding: 0; }
.fm-main ul, .fm-main ol { list-style: none; }
.fm-main img { display: block; max-width: 100%; height: auto; }
.fm-main a { color: inherit; text-decoration: none; }
.fm-main button, .fm-main input, .fm-main select { font-family: inherit; font-size: inherit; color: inherit; }
.fm-main h1, .fm-main h2, .fm-main h3 { font-family: var(--fm-font); color: var(--fm-navy); letter-spacing: -.025em; }
.fm-main :focus-visible { outline: 3px solid rgba(11, 95, 224, .4); outline-offset: 3px; }

.fm-main .fm-ico { width: 1.2em; height: 1.2em; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.fm-main .fm-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.fm-main .fm-wrap { width: min(1320px, calc(100% - 48px)); margin-inline: auto; }
.fm-main .fm-section { padding: 64px 0; }

/* ---------- Apparition progressive ---------- */

.fm-main.fm-js .fm-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity .85s ease, transform .85s cubic-bezier(.2, .7, .2, 1);
    transition-delay: var(--fm-d, 0s);
}
.fm-main.fm-js .fm-reveal[data-reveal="right"] { transform: translateX(60px); }
.fm-main.fm-js .fm-reveal.is-visible { opacity: 1; transform: none; }

@keyframes fmPop { from { opacity: 0; transform: translateY(22px) scale(.97); } to { opacity: 1; transform: none; } }
.fm-main .fm-card.fm-pop { animation: fmPop .5s ease both; animation-delay: var(--fm-pd, 0s); }

/* ---------- Boutons ---------- */

.fm-main .fm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 48px;
    padding: 0 22px;
    border: 1.5px solid transparent;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--fm-blue), var(--fm-blue-2));
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    box-shadow: 0 12px 26px rgba(11, 95, 224, .28);
    transition: transform .25s, box-shadow .25s, background .25s, color .25s, border-color .25s;
}
.fm-main .fm-btn .fm-ico { transition: transform .25s; }
.fm-main .fm-btn:hover { transform: translateY(-2px); box-shadow: 0 16px 32px rgba(11, 95, 224, .38); }
.fm-main .fm-btn:hover .fm-ico { transform: translateX(4px); }
.fm-main .fm-btn--sm { min-height: 40px; padding: 0 16px; border-radius: 999px; font-size: 14px; }
.fm-main .fm-btn--amber { background: var(--fm-amber); color: #1a1300; box-shadow: 0 14px 30px rgba(245, 165, 36, .35); }
.fm-main .fm-btn--ghost { background: transparent; border-color: rgba(255, 255, 255, .55); color: #fff; box-shadow: none; }
.fm-main .fm-btn--ghost:hover { background: rgba(255, 255, 255, .12); border-color: #fff; box-shadow: none; }
.fm-main .fm-btn--outline { background: #fff; border-color: #c9dbf8; color: var(--fm-blue); box-shadow: none; }
.fm-main .fm-btn--outline:hover { border-color: var(--fm-blue); box-shadow: none; }

/* ---------- Titres ---------- */

.fm-main .fm-head--center { max-width: 760px; margin: 0 auto; text-align: center; }
.fm-main .fm-head--center .fm-sub { margin-inline: auto; }

.fm-main .fm-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding: 6px 13px;
    border-radius: 999px;
    background: #e8f1ff;
    color: var(--fm-blue);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}
.fm-main .fm-kicker::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }

.fm-main .fm-title { font-size: var(--t-h2); font-weight: 800; line-height: 1.2; }
.fm-main .fm-sub { max-width: 680px; margin-top: 8px; color: var(--fm-muted); font-size: 16px; }

/* =====================================================================
   HERO (pleine largeur, collé au header et aux bords)
   ===================================================================== */

.fm-main .fm-hero {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 440px;
    overflow: hidden;
    background: linear-gradient(120deg, #ffffff 0%, #f3f8ff 100%);
}

.fm-main .fm-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    background-image:
        linear-gradient(rgba(11, 95, 224, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(11, 95, 224, .05) 1px, transparent 1px);
    background-size: 56px 56px;
    -webkit-mask-image: linear-gradient(90deg, #000, transparent 55%);
            mask-image: linear-gradient(90deg, #000, transparent 55%);
}

.fm-main .fm-hero__visual {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
    width: 52%;
    margin: 0;
    background: linear-gradient(135deg, #0b5fe0, #0a1a3a);
}
.fm-main .fm-hero__visual img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; }

/* Fondu blanc sur le côté gauche de l'image */
.fm-main .fm-hero__visual::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(90deg, #fbfdff 0%, rgba(251, 253, 255, .85) 18%, rgba(251, 253, 255, 0) 55%);
}
.fm-main .fm-hero__visual::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(200deg, rgba(10, 26, 58, .55) 0%, transparent 40%);
}

.fm-main .fm-hero__tag {
    position: absolute;
    top: 34px;
    right: 40px;
    z-index: 2;
    color: #fff;
    font-size: clamp(19px, 1.8vw, 26px);
    font-weight: 800;
    line-height: 1.12;
    text-align: right;
    transform: rotate(-5deg);
    text-shadow: 0 4px 16px rgba(0, 0, 0, .35);
}
.fm-main .fm-hero__tag span { color: #ffc461; }

.fm-main .fm-hero__inner {
    position: relative;
    z-index: 2;
    width: min(1320px, calc(100% - 48px));
    margin-inline: auto;
    padding: 44px 0;
}
.fm-main .fm-hero__text { max-width: 700px; }

.fm-main .fm-crumb { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; color: var(--fm-muted); font-size: 13.5px; font-weight: 600; }
.fm-main .fm-crumb a { display: inline-flex; align-items: center; gap: 6px; color: var(--fm-ink); }
.fm-main .fm-crumb a:hover { color: var(--fm-blue); }
.fm-main .fm-crumb [aria-current] { color: var(--fm-blue); }

.fm-main .fm-pill {
    display: inline-block;
    padding: 6px 15px;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 8px 22px rgba(11, 95, 224, .1), inset 0 0 0 1px var(--fm-line);
    color: var(--fm-blue);
    font-size: 13.5px;
    font-weight: 700;
}

.fm-main .fm-hero__title { margin: 14px 0 14px; font-size: var(--t-h1); font-weight: 800; line-height: 1.12; }
.fm-main .fm-hero__title span {
    background: linear-gradient(90deg, var(--fm-blue), var(--fm-sky));
    -webkit-background-clip: text;
            background-clip: text;
    color: transparent;
}
.fm-main .fm-hero__lead { max-width: 560px; color: var(--fm-text); font-size: var(--t-lead); line-height: 1.7; }

.fm-main .fm-feats { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.fm-main .fm-feat {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px 8px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .92);
    border: 1px solid var(--fm-line);
    box-shadow: 0 10px 24px rgba(10, 26, 58, .06);
}
.fm-main .fm-feat__icon {
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: color-mix(in srgb, var(--c) 13%, #fff);
    color: var(--c);
    font-size: 17px;
}
.fm-main .fm-feat strong { display: block; color: var(--fm-ink); font-size: 14px; font-weight: 800; line-height: 1.3; }
.fm-main .fm-feat small { display: block; color: var(--fm-muted); font-size: 12px; line-height: 1.35; }

/* =====================================================================
   CATÉGORIES
   ===================================================================== */

.fm-main .fm-cats { padding-bottom: 20px; }

.fm-main .fm-cats__grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-top: 26px; }

.fm-main .fm-cat {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    min-width: 0;
    padding: 16px 10px 14px;
    border: 1px solid var(--fm-line);
    border-radius: 16px;
    background: #fff;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(10, 26, 58, .05);
    transition: transform .3s, box-shadow .3s, border-color .3s, background .3s;
}
.fm-main .fm-cat:hover { transform: translateY(-6px); border-color: color-mix(in srgb, var(--c) 35%, #fff); box-shadow: 0 18px 36px color-mix(in srgb, var(--c) 18%, transparent); }

.fm-main .fm-cat__icon {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    margin-bottom: 6px;
    border-radius: 13px;
    background: color-mix(in srgb, var(--c) 13%, #fff);
    color: var(--c);
    font-size: 20px;
    transition: transform .35s, background .35s, color .35s;
}
.fm-main .fm-cat:hover .fm-cat__icon { transform: rotate(-8deg) scale(1.08); }

.fm-main .fm-cat__name { color: var(--fm-ink); font-size: 14.5px; font-weight: 800; line-height: 1.3; overflow-wrap: anywhere; }
.fm-main .fm-cat__count { color: var(--fm-muted); font-size: 12.5px; font-weight: 600; }

.fm-main .fm-cat.is-active {
    border-color: transparent;
    background: linear-gradient(160deg, var(--c), color-mix(in srgb, var(--c) 70%, #000));
    box-shadow: 0 18px 36px color-mix(in srgb, var(--c) 35%, transparent);
}
.fm-main .fm-cat.is-active .fm-cat__name,
.fm-main .fm-cat.is-active .fm-cat__count { color: #fff; }
.fm-main .fm-cat.is-active .fm-cat__icon { background: rgba(255, 255, 255, .2); color: #fff; }

/* =====================================================================
   LISTE + OUTILS
   ===================================================================== */

.fm-main .fm-list { padding-top: 40px; }

.fm-main .fm-toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px; }

.fm-main .fm-tools { display: flex; flex-wrap: wrap; gap: 12px; }
.fm-main .fm-search, .fm-main .fm-sort { position: relative; display: block; }

.fm-main .fm-search input,
.fm-main .fm-sort select {
    height: 46px;
    border: 1.5px solid var(--fm-line);
    border-radius: 999px;
    background: #fff;
    font-size: 15px;
    outline: none;
    box-shadow: 0 6px 16px rgba(10, 26, 58, .04);
    transition: border-color .25s, box-shadow .25s;
}
.fm-main .fm-search input { width: 290px; padding: 0 18px 0 46px; }
.fm-main .fm-sort select { width: 250px; padding: 0 46px 0 18px; appearance: none; -webkit-appearance: none; cursor: pointer; }
.fm-main .fm-search input:focus,
.fm-main .fm-sort select:focus { border-color: var(--fm-blue); box-shadow: 0 0 0 4px rgba(11, 95, 224, .14); }

.fm-main .fm-search .fm-ico { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: var(--fm-blue); pointer-events: none; }
.fm-main .fm-sort .fm-ico { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); color: var(--fm-blue); pointer-events: none; }

.fm-main .fm-count { margin-top: 18px; color: var(--fm-muted); font-size: 14px; }
.fm-main .fm-count strong { color: var(--fm-blue); }

.fm-main .fm-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; margin-top: 14px; }

.fm-main .fm-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--fm-line);
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--fm-shadow);
}
.fm-main .fm-card[hidden] { display: none; }
.fm-main .fm-card.is-visible { transition: transform .35s, box-shadow .35s, opacity .85s ease; }
.fm-main .fm-card.is-visible:hover { transform: translateY(-10px); box-shadow: var(--fm-shadow-lg); }

.fm-main .fm-card__media { position: relative; height: 175px; overflow: hidden; background: linear-gradient(135deg, #0b5fe0, #0a1a3a); }
.fm-main .fm-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.fm-main .fm-card:hover .fm-card__media img { transform: scale(1.08); }
.fm-main .fm-card__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(10, 26, 58, .55)); }

.fm-main .fm-card__badge {
    position: absolute;
    left: 16px;
    bottom: 12px;
    z-index: 2;
    max-width: calc(100% - 32px);
    padding: 4px 11px;
    border-radius: 999px;
    background: var(--c, var(--fm-blue));
    color: #fff;
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 6px 16px rgba(0, 0, 0, .25);
}

.fm-main .fm-card__promo {
    position: absolute;
    top: 16px;
    left: 14px;
    z-index: 2;
    padding: 3px 9px;
    border-radius: 8px;
    background: var(--fm-amber);
    color: #1a1300;
    font-size: 12px;
    font-weight: 800;
}

.fm-main .fm-card__quick {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 12px;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, .95);
    color: var(--fm-ink);
    font-size: 12.5px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(0, 0, 0, .18);
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity .3s, transform .3s, background .3s, color .3s;
}
.fm-main .fm-card:hover .fm-card__quick,
.fm-main .fm-card__quick:focus-visible { opacity: 1; transform: none; }
.fm-main .fm-card__quick:hover { background: var(--c); color: #fff; }

.fm-main .fm-card__body { flex: 1; display: flex; flex-direction: column; padding: 16px 18px 18px; }
.fm-main .fm-card__title { font-size: var(--t-h3); font-weight: 800; line-height: 1.3; }
.fm-main .fm-card__title a { transition: color .25s; }
.fm-main .fm-card__title a:hover { color: var(--c); }
.fm-main .fm-card__desc { flex: 1; margin-top: 5px; color: var(--fm-muted); font-size: 14.5px; line-height: 1.55; }

.fm-main .fm-card__meta { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0; }
.fm-main .fm-card__meta li {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 9px;
    border-radius: 8px;
    background: var(--fm-soft);
    color: var(--fm-ink);
    font-size: 12.5px;
    font-weight: 600;
}
.fm-main .fm-card__meta .fm-ico { color: var(--c); }

.fm-main .fm-card__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-top: 12px;
    border-top: 1px solid var(--fm-line);
}
.fm-main .fm-card__price small { display: block; color: var(--fm-muted, #64748b); font-size: 12px; font-weight: 600; }
.fm-main .fm-card__price strong { display: block; color: var(--fm-blue); font-size: 19px; font-weight: 800; line-height: 1.15; }
.fm-main .fm-card__price s { color: #94a3b8; font-size: 13px; }

.fm-main .fm-empty {
    margin-top: 24px;
    padding: 56px 20px;
    border: 2px dashed var(--fm-line);
    border-radius: var(--fm-radius);
    color: var(--fm-muted);
    font-size: 18px;
    text-align: center;
}
.fm-main .fm-empty[hidden] { display: none; }
.fm-main .fm-empty .fm-ico { width: 56px; height: 56px; margin: 0 auto 12px; color: var(--fm-blue); }
.fm-main .fm-empty .fm-btn { margin-top: 18px; }

/* =====================================================================
   ÉTAPES
   ===================================================================== */

.fm-main .fm-steps { background: var(--fm-soft); }

.fm-main .fm-steps__list { position: relative; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 32px; }
.fm-main .fm-steps__list::before {
    content: "";
    position: absolute;
    top: 41px;
    left: 12%;
    right: 12%;
    height: 2px;
    background: repeating-linear-gradient(90deg, #b9cff3 0 10px, transparent 10px 18px);
}

.fm-main .fm-step {
    position: relative;
    padding: 20px 18px;
    border-radius: 18px;
    background: #fff;
    border: 1px solid var(--fm-line);
    box-shadow: var(--fm-shadow);
    text-align: center;
}
.fm-main .fm-step__num {
    position: absolute;
    top: 16px;
    right: 18px;
    color: #dbe7fb;
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
}
.fm-main .fm-step__icon {
    position: relative;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    margin: 0 auto 12px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--fm-blue), var(--fm-sky));
    color: #fff;
    font-size: 19px;
    box-shadow: 0 0 0 6px #fff, 0 12px 26px rgba(11, 95, 224, .3);
}
.fm-main .fm-step h3 { margin-bottom: 4px; font-size: 16px; font-weight: 800; }
.fm-main .fm-step p { color: var(--fm-muted); font-size: 14px; line-height: 1.5; }

/* =====================================================================
   POURQUOI
   ===================================================================== */

.fm-main .fm-why__box {
    display: grid;
    grid-template-columns: minmax(260px, 340px) minmax(0, 1fr);
    align-items: center;
    gap: 28px;
    padding: 28px 30px;
    border-radius: 22px;
    background:
        radial-gradient(circle at 0% 0%, rgba(67, 185, 242, .2), transparent 45%),
        linear-gradient(120deg, #eaf3ff, #f7fbff);
    border: 1px solid var(--fm-line);
}
.fm-main .fm-why__title { font-size: var(--t-h2); font-weight: 800; line-height: 1.15; }
.fm-main .fm-why__title span { color: var(--fm-blue); }
.fm-main .fm-why__intro p { margin-top: 8px; color: var(--fm-muted); font-size: 15.5px; }

.fm-main .fm-why__list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.fm-main .fm-why__item {
    padding: 14px 14px;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 8px 22px rgba(10, 26, 58, .05);
    transition: transform .3s, box-shadow .3s;
}
.fm-main .fm-why__item:hover { transform: translateY(-6px); box-shadow: var(--fm-shadow); }
.fm-main .fm-why__icon {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    background: color-mix(in srgb, var(--c) 13%, #fff);
    color: var(--c);
    font-size: 19px;
    transition: transform .3s, background .3s, color .3s;
}
.fm-main .fm-why__item:hover .fm-why__icon { background: var(--c); color: #fff; transform: rotate(-8deg); }
.fm-main .fm-why__item h3 { margin: 10px 0 4px; font-size: 15px; font-weight: 800; line-height: 1.3; }
.fm-main .fm-why__item p { color: var(--fm-muted); font-size: 13.5px; line-height: 1.5; }

/* =====================================================================
   CTA (pleine largeur, angles droits)
   ===================================================================== */

.fm-main .fm-cta {
    position: relative;
    overflow: hidden;
    margin-top: 20px;
    border-radius: 0;
    background:
        radial-gradient(circle at 15% 0%, rgba(67, 185, 242, .45), transparent 45%),
        linear-gradient(105deg, #0a1a3a 0%, #0b3f93 55%, #0b5fe0 100%);
    color: #fff;
}
.fm-main .fm-cta__ring { position: absolute; right: -120px; top: -160px; width: 420px; height: 420px; border-radius: 50%; border: 60px solid rgba(255, 255, 255, .06); pointer-events: none; }

.fm-main .fm-cta__inner {
    position: relative;
    display: flex;
    align-items: center;
    gap: 22px;
    width: min(1320px, calc(100% - 48px));
    margin-inline: auto;
    padding: 40px 0;
}
.fm-main .fm-cta__icon {
    width: 58px;
    height: 58px;
    flex: 0 0 58px;
    display: grid;
    place-items: center;
    border-radius: 17px;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .22);
    font-size: 27px;
}
.fm-main .fm-cta__text { flex: 1; min-width: 0; }
.fm-main .fm-cta__text h2 { color: #fff; font-size: var(--t-cta); font-weight: 800; line-height: 1.15; }
.fm-main .fm-cta__text p { margin-top: 4px; color: #d7e6ff; font-size: 15.5px; }
.fm-main .fm-cta__actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* =====================================================================
   FENÊTRE « APERÇU RAPIDE »
   ===================================================================== */

.fm-main .fm-modal {
    position: fixed;
    inset: 0;
    z-index: 200100;
    display: grid;
    place-items: center;
    padding: 20px;
    visibility: hidden;
    opacity: 0;
    transition: opacity .3s, visibility .3s;
}
.fm-main .fm-modal.is-open { visibility: visible; opacity: 1; }

.fm-main .fm-modal__overlay { position: absolute; inset: 0; background: rgba(5, 14, 36, .65); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }

.fm-main .fm-modal__box {
    position: relative;
    width: min(920px, 100%);
    max-height: calc(100vh - 40px);
    display: grid;
    grid-template-columns: 42% 58%;
    overflow: hidden;
    border-radius: 26px;
    background: #fff;
    box-shadow: 0 40px 100px rgba(0, 0, 0, .4);
    transform: translateY(26px) scale(.95);
    transition: transform .45s cubic-bezier(.2, .9, .25, 1.15);
}
.fm-main .fm-modal.is-open .fm-modal__box { transform: none; }

.fm-main .fm-modal__media { position: relative; min-height: 100%; background: #0a1a3a; }
.fm-main .fm-modal__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.fm-main .fm-modal__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(10, 26, 58, .6)); }

.fm-main .fm-modal__body { padding: 38px 36px 32px; overflow-y: auto; }
.fm-main .fm-modal__body h2 { padding-right: 40px; font-size: 28px; font-weight: 800; line-height: 1.2; }
.fm-main .fm-modal__body > p { margin-top: 10px; color: var(--fm-muted); font-size: 16.5px; }

.fm-main .fm-modal__meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 20px; }
.fm-main .fm-modal__meta li { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 10px; background: var(--fm-soft); color: var(--fm-ink); font-size: 14px; font-weight: 600; }
.fm-main .fm-modal__meta .fm-ico { color: var(--fm-blue); }

.fm-main .fm-modal__subtitle { margin-bottom: 10px !important; color: var(--fm-ink); font-size: 15px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.fm-main .fm-modal__points { display: grid; gap: 9px; }
.fm-main .fm-modal__points li { display: flex; align-items: center; gap: 10px; color: var(--fm-ink); font-size: 16px; font-weight: 500; }
.fm-main .fm-modal__points .fm-ico { width: 24px; height: 24px; padding: 4px; border-radius: 50%; background: #d9f5e6; color: #0f8a4f; stroke-width: 3; }

.fm-main .fm-modal__price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; margin: 22px 0; padding-top: 18px; border-top: 1px solid var(--fm-line); }
.fm-main .fm-modal__price small { flex-basis: 100%; color: #64748b; font-size: 13px; font-weight: 600; }
.fm-main .fm-modal__price strong { color: var(--fm-blue); font-size: 28px; font-weight: 800; }
.fm-main .fm-modal__offers { margin-left: auto; color: var(--fm-blue); font-size: 14px; font-weight: 700; text-decoration: underline; }
.fm-main .fm-offers__lead { max-width: 640px; margin: 10px auto 0; color: #5a6a88; font-size: var(--t-lead); }
.fm-main .fm-card__promo { background: #12a150 !important; color: #fff !important; }
.fm-main .fm-modal__price s { color: #94a3b8; font-size: 16px; }
.fm-main .fm-modal__price span { padding: 4px 10px; border-radius: 8px; background: #e3f6ee; color: #0f8a5f; font-size: 13.5px; font-weight: 800; }

.fm-main .fm-modal__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.fm-main .fm-modal__actions .fm-btn { flex: 1; }

.fm-main .fm-modal__close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 3;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 50%;
    background: var(--fm-soft);
    color: var(--fm-navy);
    font-size: 22px;
    cursor: pointer;
    transition: transform .3s, background .3s;
}
.fm-main .fm-modal__close:hover { transform: rotate(90deg); background: #e2eafa; }

/* =====================================================================
   RESPONSIVE
   ===================================================================== */

@media (max-width: 1200px) {
    .fm-main .fm-cats__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .fm-main .fm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .fm-main .fm-why__box { grid-template-columns: 1fr; }
    .fm-main .fm-steps__list { grid-template-columns: repeat(2, 1fr); }
    .fm-main .fm-steps__list::before { display: none; }
    .fm-main .fm-hero__text { max-width: 54%; }
}

@media (max-width: 960px) {
    .fm-main .fm-hero { display: block; min-height: 0; }
    .fm-main .fm-hero__visual { position: relative; width: 100%; height: 250px; }
    .fm-main .fm-hero__visual::before { background: linear-gradient(0deg, #fbfdff 0%, rgba(251, 253, 255, 0) 45%); }
    .fm-main .fm-hero__inner { padding: 0 0 36px; margin-top: -30px; }
    .fm-main .fm-hero__text { max-width: 100%; }
    .fm-main .fm-why__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .fm-main .fm-cta__inner { flex-direction: column; text-align: center; }
    .fm-main .fm-cta__actions { justify-content: center; }
    .fm-main .fm-toolbar { align-items: stretch; }
    .fm-main .fm-tools { width: 100%; }
    .fm-main .fm-search, .fm-main .fm-sort { flex: 1 1 240px; }
    .fm-main .fm-search input, .fm-main .fm-sort select { width: 100%; }

    .fm-main .fm-modal__box { grid-template-columns: 1fr; overflow-y: auto; }
    .fm-main .fm-modal__media { height: 200px; min-height: 200px; }
    .fm-main .fm-modal__body { overflow: visible; padding: 26px 22px 24px; }
}

@media (max-width: 640px) {

    .fm-main .fm-wrap, .fm-main .fm-hero__inner, .fm-main .fm-cta__inner { width: calc(100% - 32px); }
    .fm-main .fm-section { padding: 44px 0; }
    .fm-main .fm-sub { font-size: 15px; }

    .fm-main .fm-hero__visual { height: 190px; }
    .fm-main .fm-hero__tag { top: 14px; right: 14px; font-size: 17px; }
    .fm-main .fm-feats { gap: 8px; }
    .fm-main .fm-feat small { display: none; }

    .fm-main .fm-cats__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 20px; }
    .fm-main .fm-cat { padding: 12px 6px; border-radius: 14px; }
    .fm-main .fm-cat__icon { width: 38px; height: 38px; font-size: 18px; border-radius: 11px; margin-bottom: 4px; }
    .fm-main .fm-cat__name { font-size: 12.5px; }
    .fm-main .fm-cat__count { font-size: 11px; }

    .fm-main .fm-grid { grid-template-columns: 1fr; gap: 14px; }
    .fm-main .fm-card__quick { opacity: 1; transform: none; }
    .fm-main .fm-card__media { height: 140px; }

    .fm-main .fm-steps__list { grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; }
    .fm-main .fm-step { padding: 16px 12px; }
    .fm-main .fm-step__icon { width: 40px; height: 40px; font-size: 17px; }
    .fm-main .fm-step__num { font-size: 22px; top: 10px; right: 12px; }
    .fm-main .fm-step h3 { font-size: 14.5px; }
    .fm-main .fm-step p { font-size: 12.5px; }

    .fm-main .fm-why__box { padding: 20px 14px; gap: 16px; }
    .fm-main .fm-why__list { gap: 8px; }
    .fm-main .fm-why__item { padding: 12px; }

    .fm-main .fm-cta__inner { padding: 36px 0; }
    .fm-main .fm-cta__actions, .fm-main .fm-cta__actions .fm-btn { width: 100%; }
}

@media (max-width: 400px) {
    .fm-main .fm-card__foot { flex-direction: column; align-items: stretch; }
    .fm-main .fm-card__foot .fm-btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .fm-main.fm-js .fm-reveal { opacity: 1; transform: none; transition: none; }
    .fm-main .fm-card.fm-pop { animation: none; }
    .fm-main * { transition-duration: .01ms !important; }
}

/* Espace entre le texte d’introduction et les cartes de formules */
.fm-main .fm-offers .fm-head { margin-bottom: 0 !important; }
.fm-main .fm-offers .fp-offers { margin-top: 44px !important; }
@media (max-width: 760px) { .fm-main .fm-offers .fp-offers { margin-top: 30px !important; } }
