/* ==========================================================================
   El Mouchir : pages d'inscription (/login et /create/entreprise)
   Feuille autonome : ces pages n'utilisent pas les styles du reste du site.
   Toutes les classes commencent par "emx-".
   ========================================================================== */

:root {
    --emx-ink: #17241e;
    --emx-ink-2: #44534c;
    --emx-ink-3: #66756e;
    --emx-paper: #f2f5f3;
    --emx-surface: #ffffff;
    --emx-surface-2: #f7f9f8;
    --emx-line: #d7e0dc;
    --emx-line-strong: #b4c3bc;
    --emx-green: #0a7d46;
    --emx-green-strong: #075c34;
    --emx-green-soft: #e4f3eb;
    --emx-green-line: #9fd2b5;
    --emx-red: #b42318;
    --emx-red-soft: #fdeceb;
    --emx-amber: #7a4f00;
    --emx-amber-soft: #fff4d9;
    --emx-amber-line: #f0c96a;
    --emx-info: #1d4f7a;
    --emx-info-soft: #e8f1fa;
    --emx-info-line: #a9c8e6;
    --emx-ring: rgba(10, 125, 70, .28);
    --emx-ring-error: rgba(180, 35, 24, .22);
    --emx-radius: 10px;
    --emx-radius-lg: 14px;
    --emx-font: "IBM Plex Sans", "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    --emx-shadow-pop: 0 10px 30px rgba(23, 36, 30, .14), 0 2px 6px rgba(23, 36, 30, .08);
    color-scheme: light;
}

[dir="rtl"] {
    --emx-font: "IBM Plex Sans Arabic", "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Tahoma, Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --emx-ink: #e4ece8;
        --emx-ink-2: #b9c6c0;
        --emx-ink-3: #93a29b;
        --emx-paper: #0f1513;
        --emx-surface: #161f1b;
        --emx-surface-2: #1b2521;
        --emx-line: #2b3832;
        --emx-line-strong: #3d4d46;
        --emx-green: #3fbf7f;
        --emx-green-strong: #6fd6a1;
        --emx-green-soft: #173527;
        --emx-green-line: #2d6a4b;
        --emx-red: #ff8a80;
        --emx-red-soft: #3a1c1a;
        --emx-amber: #f3c56b;
        --emx-amber-soft: #33290f;
        --emx-amber-line: #6b5524;
        --emx-info: #9cc7f0;
        --emx-info-soft: #172634;
        --emx-info-line: #2f4a63;
        --emx-ring: rgba(63, 191, 127, .35);
        --emx-ring-error: rgba(255, 138, 128, .3);
        --emx-shadow-pop: 0 10px 30px rgba(0, 0, 0, .5);
        color-scheme: dark;
    }
}

:root[data-theme="dark"] {
    --emx-ink: #e4ece8;
    --emx-ink-2: #b9c6c0;
    --emx-ink-3: #93a29b;
    --emx-paper: #0f1513;
    --emx-surface: #161f1b;
    --emx-surface-2: #1b2521;
    --emx-line: #2b3832;
    --emx-line-strong: #3d4d46;
    --emx-green: #3fbf7f;
    --emx-green-strong: #6fd6a1;
    --emx-green-soft: #173527;
    --emx-green-line: #2d6a4b;
    --emx-red: #ff8a80;
    --emx-red-soft: #3a1c1a;
    --emx-amber: #f3c56b;
    --emx-amber-soft: #33290f;
    --emx-amber-line: #6b5524;
    --emx-info: #9cc7f0;
    --emx-info-soft: #172634;
    --emx-info-line: #2f4a63;
    --emx-ring: rgba(63, 191, 127, .35);
    --emx-ring-error: rgba(255, 138, 128, .3);
    --emx-shadow-pop: 0 10px 30px rgba(0, 0, 0, .5);
    color-scheme: dark;
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }

.emx-body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--emx-paper);
    color: var(--emx-ink);
    font-family: var(--emx-font);
    font-size: 16px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

.emx-body img, .emx-body svg { max-width: 100%; }
.emx-body button, .emx-body input, .emx-body select, .emx-body textarea { font: inherit; color: inherit; }
.emx-body a { color: var(--emx-green); }
[hidden] { display: none !important; }

.emx-sr {
    position: absolute !important;
    width: 1px; height: 1px;
    margin: -1px; padding: 0;
    overflow: hidden; clip: rect(0 0 0 0);
    white-space: nowrap; border: 0;
}

.emx-skip {
    position: absolute;
    inset-inline-start: 12px;
    top: -60px;
    z-index: 100;
    padding: 10px 14px;
    background: var(--emx-ink);
    color: var(--emx-surface) !important;
    border-radius: var(--emx-radius);
    text-decoration: none;
}
.emx-skip:focus { top: 12px; }

:focus-visible {
    outline: 3px solid var(--emx-green);
    outline-offset: 2px;
}

/* --------------------------------------------------------------------------
   En-tete et pied de page
   -------------------------------------------------------------------------- */
.emx-header {
    background: var(--emx-surface);
    border-bottom: 1px solid var(--emx-line);
}
.emx-header__in {
    max-width: 1120px;
    margin: 0 auto;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.emx-brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--emx-ink) !important;
    text-decoration: none;
    min-width: 0;
}
.emx-brand__logo { width: 36px; height: 36px; object-fit: contain; flex: none; }
.emx-brand__logo--txt {
    display: inline-grid;
    place-items: center;
    border-radius: 9px;
    background: var(--emx-green);
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}
.emx-brand__txt { display: flex; flex-direction: column; line-height: 1.2; min-width: 0; }
.emx-brand__txt strong { font-size: 18px; font-weight: 600; }
.emx-brand__txt span { font-size: 13px; color: var(--emx-ink-3); }

.emx-header__nav { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.emx-lang { display: flex; gap: 4px; margin: 0; padding: 0; list-style: none; }
.emx-lang a {
    display: inline-block;
    padding: 6px 8px;
    border-radius: 6px;
    color: var(--emx-ink-2) !important;
    font-size: 14px;
    text-decoration: none;
}
.emx-lang a:hover { background: var(--emx-surface-2); }
.emx-lang a[aria-current="true"] { color: var(--emx-ink) !important; font-weight: 600; box-shadow: inset 0 -2px 0 var(--emx-green); border-radius: 0; }
.emx-header__cta {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 14px;
    border: 1px solid var(--emx-line-strong);
    border-radius: var(--emx-radius);
    color: var(--emx-ink) !important;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
}
.emx-header__cta:hover { border-color: var(--emx-green); color: var(--emx-green) !important; }

.emx-main { flex: 1; padding: 28px 16px 56px; outline: none; }

.emx-footer { border-top: 1px solid var(--emx-line); background: var(--emx-surface); }
.emx-footer__in {
    max-width: 1120px;
    margin: 0 auto;
    padding: 18px 16px 24px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 24px;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
    color: var(--emx-ink-3);
}
.emx-footer__in p { margin: 0; }
.emx-footer__links { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 0; padding: 0; list-style: none; }
.emx-footer__links a, .emx-footer__support a { color: var(--emx-ink-2) !important; }
.emx-footer__support a { margin-inline-start: 6px; }

/* --------------------------------------------------------------------------
   Mise en page
   -------------------------------------------------------------------------- */
.emx-wrap { max-width: 1120px; margin: 0 auto; }

.emx-layout { display: grid; gap: 24px; align-items: start; }
@media (min-width: 960px) {
    .emx-layout { grid-template-columns: 272px minmax(0, 1fr); gap: 28px; }
}
.emx-flow { min-width: 0; }
/* Apres l'envoi, la colonne des etapes disparait : le recu occupe toute la largeur. */
.emx-layout > .emx-spine[hidden] + .emx-flow { grid-column: 1 / -1; width: 100%; max-width: 680px; justify-self: center; }

.emx-card {
    background: var(--emx-surface);
    border: 1px solid var(--emx-line);
    border-radius: var(--emx-radius-lg);
    padding: 24px 20px;
}
@media (min-width: 640px) { .emx-card { padding: 32px; } }
.emx-card--narrow { max-width: 440px; margin: 0 auto; }

.emx-h1 { margin: 0 0 8px; font-size: 26px; line-height: 1.2; font-weight: 600; letter-spacing: -.01em; }
.emx-h2 { margin: 0 0 18px; font-size: 21px; line-height: 1.25; font-weight: 600; outline: none; }
.emx-h2__num { display: block; margin-bottom: 4px; font-size: 13px; font-weight: 600; color: var(--emx-green); }
.emx-h3 { margin: 0 0 6px; font-size: 16px; font-weight: 600; padding: 0; }
.emx-lead { margin: 0 0 16px; color: var(--emx-ink-2); max-width: 64ch; }
.emx-note { margin: 0 0 16px; color: var(--emx-ink-2); font-size: 15px; max-width: 70ch; }
.emx-note--quiet { font-size: 13px; color: var(--emx-ink-3); }
.emx-legend-req { margin: 0 0 20px; font-size: 13px; color: var(--emx-ink-3); }
.emx-form__head { margin-bottom: 20px; padding-bottom: 20px; border-bottom: 1px solid var(--emx-line); }
.emx-form__head .emx-note { margin: 0; font-size: 14px; }

.emx-grid { display: grid; gap: 0 20px; }
@media (min-width: 640px) {
    .emx-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .emx-grid--wilaya { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); }
    .emx-grid--contact { grid-template-columns: 150px minmax(0, 1fr) minmax(0, 1fr); }
    .emx-span-2 { grid-column: 1 / -1; }
}
@media (min-width: 760px) {
    .emx-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* --------------------------------------------------------------------------
   Onglets (connexion / creer un compte)
   -------------------------------------------------------------------------- */
.emx-tabs {
    display: flex;
    width: max-content;
    max-width: 100%;
    margin: 0 auto 24px;
    padding: 4px;
    gap: 4px;
    background: var(--emx-surface-2);
    border: 1px solid var(--emx-line);
    border-radius: 12px;
}
.emx-tab {
    min-height: 40px;
    padding: 0 18px;
    border: 1px solid transparent;
    border-radius: 9px;
    background: transparent;
    color: var(--emx-ink-2);
    font-weight: 500;
    cursor: pointer;
}
.emx-tab[aria-selected="true"] {
    background: var(--emx-surface);
    border-color: var(--emx-line);
    color: var(--emx-ink);
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   Colonne "dossier"
   -------------------------------------------------------------------------- */
.emx-spine { position: relative; }
@media (min-width: 960px) {
    .emx-spine { position: sticky; top: 20px; }
}
.emx-spine__toggle { display: none; }
.emx-spine__body {
    background: var(--emx-surface);
    border: 1px solid var(--emx-line);
    border-radius: var(--emx-radius-lg);
    padding: 20px 18px;
}
.emx-spine__title { margin: 0 0 16px; font-size: 14px; font-weight: 600; color: var(--emx-ink-2); }
.emx-spine__list { position: relative; margin: 0; padding: 0; list-style: none; }

/* Le "dos" du dossier : un trait qui se remplit au fil des etapes */
.emx-spine__list::before,
.emx-spine__list::after {
    content: "";
    position: absolute;
    inset-inline-start: 13px;
    top: 16px;
    width: 2px;
    border-radius: 2px;
}
.emx-spine__list::before { bottom: 24px; background: var(--emx-line); }
.emx-spine__list::after {
    height: var(--emx-progress, 0px);
    max-height: calc(100% - 40px);
    background: var(--emx-green);
    transition: height .35s ease;
}
.emx-spine__item { position: relative; z-index: 1; }
.emx-spine__item + .emx-spine__item { margin-top: 6px; }
.emx-spine__btn {
    display: flex;
    gap: 12px;
    width: 100%;
    padding: 6px 6px 6px 0;
    border: 0;
    border-radius: 8px;
    background: transparent;
    text-align: start;
    cursor: pointer;
}
[dir="rtl"] .emx-spine__btn { padding: 6px 0 6px 6px; }
.emx-spine__btn:disabled { cursor: default; }
.emx-spine__btn:not(:disabled):hover .emx-spine__label { color: var(--emx-green); }
.emx-spine__num {
    flex: none;
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border: 2px solid var(--emx-line-strong);
    border-radius: 50%;
    background: var(--emx-surface);
    color: var(--emx-ink-3);
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
}
.emx-spine__txt { display: flex; flex-direction: column; min-width: 0; padding-top: 3px; }
.emx-spine__label { font-size: 15px; font-weight: 500; color: var(--emx-ink-2); }
.emx-spine__sum {
    font-size: 13px;
    color: var(--emx-ink-3);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.emx-spine__sum:empty { display: none; }

.emx-spine__item.is-done .emx-spine__num {
    border-color: var(--emx-green);
    background: var(--emx-green-soft);
    color: var(--emx-green);
    font-size: 0;
}
.emx-spine__item.is-done .emx-spine__num::before {
    content: "";
    width: 10px;
    height: 6px;
    border: solid currentColor;
    border-width: 0 0 2px 2px;
    transform: translateY(-1px) rotate(-45deg);
}
.emx-spine__item.is-current .emx-spine__num {
    border-color: var(--emx-green);
    background: var(--emx-green);
    color: #fff;
    font-size: 13px;
}
.emx-spine__item.is-current .emx-spine__num::before { content: none; }
.emx-spine__item.is-current .emx-spine__label { color: var(--emx-ink); font-weight: 600; }
.emx-spine__item.is-error .emx-spine__num { border-color: var(--emx-red); color: var(--emx-red); background: var(--emx-red-soft); font-size: 13px; }
.emx-spine__item.is-error .emx-spine__num::before { content: none; }
.emx-spine__item.is-error .emx-spine__label { color: var(--emx-red); }

.emx-spine__draft {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px dashed var(--emx-line);
    font-size: 13px;
    color: var(--emx-ink-3);
}
.emx-spine__saved { margin: 0 0 6px; display: flex; gap: 8px; align-items: baseline; }
.emx-spine__saved::before {
    content: "";
    flex: none;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--emx-line-strong);
    transform: translateY(-1px);
}
.emx-spine__draft.is-saved .emx-spine__saved::before { background: var(--emx-green); }
.emx-spine__draft.is-off .emx-spine__saved::before { background: var(--emx-amber-line); }

@media (max-width: 959.98px) {
    .emx-spine__toggle {
        display: grid;
        grid-template-columns: auto 1fr;
        grid-template-areas: "count current" "bar bar";
        gap: 4px 10px;
        align-items: baseline;
        width: 100%;
        padding: 12px 16px;
        border: 1px solid var(--emx-line);
        border-radius: var(--emx-radius-lg);
        background: var(--emx-surface);
        text-align: start;
        cursor: pointer;
    }
    .emx-spine__count { grid-area: count; font-size: 13px; font-weight: 600; color: var(--emx-green); }
    .emx-spine__current { grid-area: current; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    .emx-spine__current::after {
        content: "";
        display: inline-block;
        width: 7px;
        height: 7px;
        margin-inline-start: 8px;
        border: solid var(--emx-ink-3);
        border-width: 0 2px 2px 0;
        transform: translateY(-3px) rotate(45deg);
    }
    .emx-spine__toggle[aria-expanded="true"] .emx-spine__current::after { transform: translateY(0) rotate(-135deg); }
    .emx-spine__progress { grid-area: bar; height: 4px; margin-top: 6px; border-radius: 4px; background: var(--emx-line); overflow: hidden; }
    .emx-spine__progress span { display: block; height: 100%; width: 0; background: var(--emx-green); transition: width .3s ease; }
    .emx-spine__body { display: none; margin-top: 8px; }
    .emx-spine.is-open .emx-spine__body { display: block; }
}

/* --------------------------------------------------------------------------
   Champs
   -------------------------------------------------------------------------- */
.emx-field { margin: 0 0 18px; min-width: 0; }
.emx-label { display: block; margin: 0 0 6px; font-size: 14px; font-weight: 500; color: var(--emx-ink); }
.emx-req { color: var(--emx-red); font-weight: 600; }
.emx-hint { margin: 6px 0 0; font-size: 13px; color: var(--emx-ink-3); }
.emx-hint ul, .emx-hint dl { margin: 4px 0 0; padding-inline-start: 18px; }
.emx-error {
    display: flex;
    gap: 6px;
    margin: 6px 0 0;
    font-size: 13px;
    font-weight: 500;
    color: var(--emx-red);
}
.emx-error::before {
    content: "!";
    flex: none;
    display: grid;
    place-items: center;
    width: 16px;
    height: 16px;
    margin-top: 1px;
    border-radius: 50%;
    background: var(--emx-red);
    color: var(--emx-surface);
    font-size: 11px;
    font-weight: 700;
}
.emx-status { margin: 6px 0 0; font-size: 13px; color: var(--emx-ink-3); }
.emx-status.is-ok { color: var(--emx-green); }
.emx-status.is-ok::before { content: "\2713\00a0"; }
.emx-status.is-warn { color: var(--emx-amber); }
.emx-status a, .emx-status button { font-size: 13px; }

/* "Utiliser ma position actuelle" : remplit adresse, wilaya et carte */
.emx-locate {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 10px 0 0;
    padding: 6px 12px 6px 10px;
    border: 1px solid var(--emx-green-line);
    border-radius: 999px;
    background: var(--emx-green-soft);
    color: var(--emx-green-strong);
    font: inherit;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.3;
    cursor: pointer;
}
[dir="rtl"] .emx-locate { padding: 6px 10px 6px 12px; }
.emx-locate:hover { border-color: var(--emx-green); }
.emx-locate:focus-visible { outline: 3px solid var(--emx-green); outline-offset: 2px; }
.emx-locate[disabled] { opacity: .65; cursor: progress; }
@supports ((-webkit-mask-image: url("x.svg")) or (mask-image: url("x.svg"))) {
    .emx-locate::before {
        content: "";
        flex: none;
        width: 16px;
        height: 16px;
        background: currentColor;
        -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5a7 7 0 0 0-7 7c0 5.2 7 12 7 12s7-6.8 7-12a7 7 0 0 0-7-7Zm0 9.6a2.6 2.6 0 1 1 0-5.2 2.6 2.6 0 0 1 0 5.2Z'/%3E%3C/svg%3E") center / contain no-repeat;
        mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2.5a7 7 0 0 0-7 7c0 5.2 7 12 7 12s7-6.8 7-12a7 7 0 0 0-7-7Zm0 9.6a2.6 2.6 0 1 1 0-5.2 2.6 2.6 0 0 1 0 5.2Z'/%3E%3C/svg%3E") center / contain no-repeat;
    }
}
.emx-locate-status { margin: 8px 0 0; font-size: 13px; color: var(--emx-ink-2); }
.emx-locate-status.is-ok { color: var(--emx-green-strong); }
.emx-locate-status.is-warn { color: var(--emx-amber); }
.emx-suggest { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; margin: 8px 0 0; font-size: 13px; color: var(--emx-ink-2); }
.emx-suggest .emx-link { font-size: 13px; }

/* Champ rempli automatiquement : bref eclairage */
.emx-input.is-autofilled { animation: emx-autofill 1.6s ease-out; }
@keyframes emx-autofill {
    0%, 35% { background-color: var(--emx-green-soft); box-shadow: 0 0 0 4px var(--emx-ring); }
    100% { box-shadow: 0 0 0 0 transparent; }
}
@media (prefers-reduced-motion: reduce) {
    .emx-input.is-autofilled { animation: none; background-color: var(--emx-green-soft); }
}

.emx-input {
    display: block;
    width: 100%;
    min-height: 46px;
    padding: 10px 14px;
    border: 1px solid var(--emx-line-strong);
    border-radius: 8px;
    background: var(--emx-surface);
    color: var(--emx-ink);
    font-size: 16px;
    line-height: 1.35;
    transition: border-color .15s ease, box-shadow .15s ease;
    -webkit-appearance: none;
    appearance: none;
}
.emx-input::placeholder { color: var(--emx-ink-3); opacity: .8; }
.emx-input:hover { border-color: var(--emx-ink-3); }
.emx-input:focus { outline: none; border-color: var(--emx-green); box-shadow: 0 0 0 3px var(--emx-ring); }
.emx-input[aria-invalid="true"] { border-color: var(--emx-red); }
.emx-input[aria-invalid="true"]:focus { box-shadow: 0 0 0 3px var(--emx-ring-error); }
.emx-input:disabled { opacity: .6; }
.emx-textarea { min-height: 120px; resize: vertical; }
.emx-select {
    padding-inline-end: 40px;
    background-image: linear-gradient(45deg, transparent 50%, var(--emx-ink-3) 50%), linear-gradient(135deg, var(--emx-ink-3) 50%, transparent 50%);
    background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%;
    background-size: 5px 5px, 5px 5px;
    background-repeat: no-repeat;
}
[dir="rtl"] .emx-select { background-position: 15px 50%, 20px 50%; }
.emx-counter { margin: 4px 0 0; font-size: 12px; color: var(--emx-ink-3); text-align: end; }

.emx-pass { position: relative; }
.emx-pass .emx-input { padding-inline-end: 96px; }
.emx-pass__toggle {
    position: absolute;
    inset-inline-end: 6px;
    top: 50%;
    transform: translateY(-50%);
    min-height: 34px;
    padding: 0 10px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--emx-green);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}
.emx-pass__toggle:hover { background: var(--emx-green-soft); }

.emx-meter { display: flex; align-items: center; gap: 10px; margin-top: 8px; font-size: 13px; color: var(--emx-ink-3); }
.emx-meter__bar { flex: 1; height: 4px; border-radius: 4px; background: var(--emx-line); overflow: hidden; }
.emx-meter__bar span { display: block; height: 100%; width: 0; background: var(--emx-red); transition: width .2s ease, background-color .2s ease; }
.emx-meter[data-niveau="1"] .emx-meter__bar span { width: 33%; background: var(--emx-red); }
.emx-meter[data-niveau="2"] .emx-meter__bar span { width: 66%; background: var(--emx-amber-line); }
.emx-meter[data-niveau="3"] .emx-meter__bar span { width: 100%; background: var(--emx-green); }

.emx-affix { position: relative; }
.emx-affix .emx-input { padding-inline-end: 48px; }
.emx-affix__txt { position: absolute; inset-inline-end: 14px; top: 50%; transform: translateY(-50%); color: var(--emx-ink-3); font-size: 14px; pointer-events: none; }

.emx-fieldset { margin: 0 0 18px; padding: 0; border: 0; min-width: 0; }
.emx-fieldset > legend { padding: 0; }
.emx-box {
    padding: 18px;
    border: 1px solid var(--emx-line);
    border-radius: 12px;
    background: var(--emx-surface-2);
}
.emx-box > legend { float: left; width: 100%; margin-bottom: 4px; }
[dir="rtl"] .emx-box > legend { float: right; }
.emx-box > legend + * { clear: both; }
.emx-indent { margin-top: -6px; padding-inline-start: 16px; border-inline-start: 3px solid var(--emx-green-line); }

.emx-row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin: 0 0 18px; }

.emx-check { display: inline-flex; gap: 10px; align-items: flex-start; font-size: 15px; cursor: pointer; }
.emx-check input { flex: none; width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--emx-green); }
.emx-check--block { display: flex; padding: 14px 16px; border: 1px solid var(--emx-line); border-radius: 10px; background: var(--emx-surface-2); }

/* Choix sous forme de cartes (radio) */
.emx-choices { display: grid; gap: 8px; }
@media (min-width: 640px) { .emx-choices { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.emx-choices--inline { display: flex; flex-wrap: wrap; }
.emx-choice {
    display: flex;
    gap: 10px;
    align-items: center;
    min-height: 48px;
    padding: 10px 14px;
    border: 1px solid var(--emx-line-strong);
    border-radius: 10px;
    background: var(--emx-surface);
    cursor: pointer;
    font-size: 15px;
}
.emx-choice input { flex: none; width: 18px; height: 18px; margin: 0; accent-color: var(--emx-green); }
.emx-choice:hover { border-color: var(--emx-ink-3); }
.emx-choice:has(input:checked) { border-color: var(--emx-green); background: var(--emx-green-soft); box-shadow: inset 0 0 0 1px var(--emx-green); }
.emx-choice.is-checked { border-color: var(--emx-green); background: var(--emx-green-soft); box-shadow: inset 0 0 0 1px var(--emx-green); }
.emx-choices--inline .emx-choice { min-width: 110px; }

/* Cases a cocher en pastilles */
.emx-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.emx-pill { position: relative; display: inline-flex; cursor: pointer; }
.emx-pill input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.emx-pill span {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 38px;
    padding: 6px 14px;
    border: 1px solid var(--emx-line-strong);
    border-radius: 999px;
    background: var(--emx-surface);
    font-size: 14px;
}
.emx-pill:hover span { border-color: var(--emx-ink-3); }
.emx-pill input:checked + span { border-color: var(--emx-green); background: var(--emx-green-soft); color: var(--emx-ink); }
.emx-pill input:checked + span::before {
    content: "";
    width: 8px;
    height: 5px;
    border: solid var(--emx-green);
    border-width: 0 0 2px 2px;
    transform: translateY(-2px) rotate(-45deg);
}
.emx-pill input:focus-visible + span { outline: 3px solid var(--emx-green); outline-offset: 2px; }

/* Listes de valeurs (emails, telephones, mots-cles) */
.emx-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    min-height: 46px;
    padding: 6px 8px;
    border: 1px solid var(--emx-line-strong);
    border-radius: 8px;
    background: var(--emx-surface);
    cursor: text;
}
.emx-chips:focus-within { border-color: var(--emx-green); box-shadow: 0 0 0 3px var(--emx-ring); }
.emx-chips.is-invalid { border-color: var(--emx-red); }
.emx-chips__list { display: contents; margin: 0; padding: 0; list-style: none; }
.emx-chip {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    max-width: 100%;
    min-height: 30px;
    padding: 2px 4px 2px 10px;
    border-radius: 999px;
    background: var(--emx-green-soft);
    border: 1px solid var(--emx-green-line);
    font-size: 14px;
    direction: ltr;
}
.emx-chip__txt { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.emx-chip__del {
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--emx-ink-2);
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
}
.emx-chip__del:hover { background: rgba(0, 0, 0, .08); color: var(--emx-red); }
.emx-chips__input {
    flex: 1 1 140px;
    min-width: 120px;
    min-height: 32px;
    padding: 4px 6px;
    border: 0;
    background: transparent;
    font-size: 16px;
    outline: none;
}
.emx-chips__input::placeholder { color: var(--emx-ink-3); opacity: .8; }

/* Sections repliables */
.emx-more { margin: -4px 0 18px; }
.emx-more > summary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    color: var(--emx-green);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    list-style: none;
}
.emx-more > summary::-webkit-details-marker { display: none; }
.emx-more > summary::before {
    content: "+";
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border: 1.5px solid currentColor;
    border-radius: 6px;
    font-size: 15px;
    line-height: 1;
}
.emx-more[open] > summary::before { content: "\2212"; }
.emx-more[open] > summary { margin-bottom: 12px; }
.emx-more.has-value > summary::after {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--emx-green);
}

/* --------------------------------------------------------------------------
   Boutons et liens
   -------------------------------------------------------------------------- */
.emx-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 0 20px;
    border: 1px solid transparent;
    border-radius: var(--emx-radius);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.emx-btn--primary { background: var(--emx-green); color: #fff !important; }
.emx-btn--primary:hover { background: var(--emx-green-strong); }
:root[data-theme="dark"] .emx-btn--primary { color: #0b1a12 !important; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .emx-btn--primary { color: #0b1a12 !important; } }
.emx-btn--ghost { background: var(--emx-surface); border-color: var(--emx-line-strong); color: var(--emx-ink) !important; }
.emx-btn--ghost:hover { border-color: var(--emx-green); color: var(--emx-green) !important; }
.emx-btn--small { min-height: 38px; padding: 0 14px; font-size: 14px; font-weight: 500; }
.emx-btn--block { width: 100%; }
.emx-btn:disabled, .emx-btn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; }
.emx-btn.is-busy { position: relative; color: transparent !important; pointer-events: none; }
.emx-btn.is-busy::after {
    content: "";
    position: absolute;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, .45);
    border-top-color: #fff;
    border-radius: 50%;
    animation: emx-spin .7s linear infinite;
}
.emx-btn--ghost.is-busy::after { border-color: var(--emx-line); border-top-color: var(--emx-green); }
@keyframes emx-spin { to { transform: rotate(360deg); } }

.emx-link {
    padding: 0;
    border: 0;
    background: none;
    color: var(--emx-green) !important;
    font-size: inherit;
    font-weight: 500;
    text-decoration: underline;
    text-underline-offset: 2px;
    cursor: pointer;
}
.emx-link--quiet { color: var(--emx-ink-3) !important; font-weight: 400; }
.emx-link--danger { color: var(--emx-red) !important; }

.emx-switch { margin: 18px 0 0; text-align: center; color: var(--emx-ink-2); font-size: 15px; }

/* Barre d'actions des etapes */
.emx-actions {
    display: flex;
    gap: 12px;
    justify-content: space-between;
    align-items: center;
    margin-top: 28px;
    padding-top: 20px;
    border-top: 1px solid var(--emx-line);
}
.emx-actions [data-action="next"], .emx-actions [data-action="submit"] { margin-inline-start: auto; }
@media (max-width: 639.98px) {
    .emx-actions {
        position: sticky;
        bottom: 0;
        z-index: 5;
        margin: 24px -20px -24px;
        padding: 12px 20px calc(12px + env(safe-area-inset-bottom));
        background: var(--emx-surface);
        border-radius: 0 0 var(--emx-radius-lg) var(--emx-radius-lg);
    }
    .emx-actions .emx-btn { flex: 1; padding: 0 12px; }
}

/* --------------------------------------------------------------------------
   Messages
   -------------------------------------------------------------------------- */
.emx-alert {
    margin: 0 0 18px;
    padding: 14px 16px;
    border: 1px solid var(--emx-line);
    border-inline-start-width: 4px;
    border-radius: 10px;
    background: var(--emx-surface-2);
    font-size: 15px;
}
.emx-alert p { margin: 0; }
.emx-alert p + p { margin-top: 6px; }
.emx-alert__title { display: block; margin-bottom: 4px; font-weight: 600; }
.emx-alert--error { border-color: #f1b9b4; border-inline-start-color: var(--emx-red); background: var(--emx-red-soft); }
.emx-alert--warn { border-color: var(--emx-amber-line); border-inline-start-color: var(--emx-amber); background: var(--emx-amber-soft); }
.emx-alert--info { border-color: var(--emx-info-line); border-inline-start-color: var(--emx-info); background: var(--emx-info-soft); }
.emx-alert--success { border-color: var(--emx-green-line); border-inline-start-color: var(--emx-green); background: var(--emx-green-soft); }
.emx-alert__actions { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; margin-top: 12px; }
.emx-noscript { max-width: 640px; margin: 0 auto 20px; }
:root[data-theme="dark"] .emx-alert--error { border-color: #5b2b28; }

.emx-explain { margin: 0 0 18px; padding: 16px 18px; border-radius: 12px; background: var(--emx-surface-2); border: 1px solid var(--emx-line); }
.emx-explain p { margin: 0; }
.emx-explain ul { margin: 8px 0; padding-inline-start: 20px; }
.emx-explain li + li { margin-top: 4px; }
.emx-explain__privacy { margin: 0 0 18px; font-size: 14px; color: var(--emx-ink-2); display: flex; gap: 8px; }
.emx-explain .emx-explain__privacy { margin: 8px 0 0; }
/* Cadenas (masque SVG) ; sans prise en charge des masques, pas d'icone. */
@supports ((-webkit-mask-image: url("x.svg")) or (mask-image: url("x.svg"))) {
    .emx-explain__privacy::before {
        content: "";
        flex: none;
        width: 16px;
        height: 16px;
        margin-top: 2px;
        background: var(--emx-ink-3);
        -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7.5 10.5V7.5a4.5 4.5 0 0 1 9 0v3' fill='none' stroke='%23000' stroke-width='2.2'/%3E%3Crect x='4.5' y='10.5' width='15' height='10.5' rx='2.2'/%3E%3C/svg%3E") center / contain no-repeat;
        mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7.5 10.5V7.5a4.5 4.5 0 0 1 9 0v3' fill='none' stroke='%23000' stroke-width='2.2'/%3E%3Crect x='4.5' y='10.5' width='15' height='10.5' rx='2.2'/%3E%3C/svg%3E") center / contain no-repeat;
    }
}

.emx-aside-cta {
    margin-top: 24px;
    padding: 18px;
    border: 1px dashed var(--emx-line-strong);
    border-radius: 12px;
}
.emx-aside-cta p { margin: 0 0 6px; }
.emx-aside-cta p + p { color: var(--emx-ink-2); font-size: 15px; margin-bottom: 14px; }

/* --------------------------------------------------------------------------
   Recherche d'entreprise et resultats
   -------------------------------------------------------------------------- */
.emx-search { position: relative; }
.emx-search__icon { position: absolute; inset-inline-start: 14px; top: 50%; transform: translateY(-50%); color: var(--emx-ink-3); pointer-events: none; }
.emx-search__input { padding-inline-start: 44px; }
.emx-search__input::-webkit-search-cancel-button { cursor: pointer; }

.emx-results { margin-top: 14px; }
.emx-results__meta { margin: 0 0 8px; font-size: 13px; color: var(--emx-ink-3); }
.emx-results__list { margin: 0; padding: 0; list-style: none; border: 1px solid var(--emx-line); border-radius: 12px; overflow: hidden; }
.emx-company {
    display: flex;
    gap: 12px;
    align-items: center;
    padding: 12px 14px;
    background: var(--emx-surface);
}
.emx-results__list .emx-company + .emx-company { border-top: 1px solid var(--emx-line); }
.emx-company__avatar {
    flex: none;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: var(--emx-green-soft);
    color: var(--emx-green);
    font-weight: 600;
    font-size: 15px;
    overflow: hidden;
}
.emx-company__avatar img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.emx-company__body { flex: 1; min-width: 0; }
.emx-company__name { display: block; font-weight: 600; overflow-wrap: anywhere; }
.emx-company__meta { display: block; font-size: 13px; color: var(--emx-ink-3); overflow-wrap: anywhere; }
.emx-company__badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.emx-badge {
    display: inline-block;
    padding: 1px 8px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 500;
    background: var(--emx-surface-2);
    border: 1px solid var(--emx-line);
    color: var(--emx-ink-2);
}
.emx-badge--warn { background: var(--emx-amber-soft); border-color: var(--emx-amber-line); color: var(--emx-amber); }
.emx-company .emx-btn { flex: none; }
.emx-results__more { display: block; width: 100%; margin-top: 10px; }
.emx-results__empty { padding: 18px; border: 1px solid var(--emx-line); border-radius: 12px; background: var(--emx-surface-2); }
.emx-results__empty p { margin: 0 0 6px; }
.emx-results__empty p:last-child { margin: 0; }

.emx-selected { margin-top: 14px; }
.emx-selected .emx-company { border: 2px solid var(--emx-green); border-radius: 12px; background: var(--emx-green-soft); }
.emx-selected .emx-alert { margin-top: 12px; }

.emx-similar { margin-top: 10px; }
.emx-similar .emx-results__list { margin-top: 6px; }

/* Liste deroulante d'autocompletion (groupe, direction generale) */
.emx-combo { position: relative; }
.emx-combo__list {
    position: absolute;
    z-index: 20;
    inset-inline: 0;
    top: calc(100% + 4px);
    max-height: 260px;
    margin: 0;
    padding: 4px;
    overflow: auto;
    list-style: none;
    background: var(--emx-surface);
    border: 1px solid var(--emx-line-strong);
    border-radius: 10px;
    box-shadow: var(--emx-shadow-pop);
}
.emx-combo__opt { padding: 10px 12px; border-radius: 8px; cursor: pointer; overflow-wrap: anywhere; }
.emx-combo__opt[aria-selected="true"], .emx-combo__opt:hover { background: var(--emx-green-soft); }
.emx-combo__msg { padding: 10px 12px; color: var(--emx-ink-3); font-size: 14px; }
.emx-combo.has-value .emx-input { border-color: var(--emx-green); background: var(--emx-green-soft); }

/* --------------------------------------------------------------------------
   Selecteur d'activites
   -------------------------------------------------------------------------- */
.emx-picker__selected { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; padding: 0; list-style: none; }
.emx-picker__selected .emx-chip { direction: inherit; }
.emx-picker__count { margin: 0 0 8px; font-size: 13px; font-weight: 500; color: var(--emx-ink-2); }
.emx-picker__box { border: 1px solid var(--emx-line-strong); border-radius: 12px; overflow: hidden; background: var(--emx-surface); }
.emx-picker__box:focus-within { border-color: var(--emx-green); box-shadow: 0 0 0 3px var(--emx-ring); }
.emx-picker.is-invalid .emx-picker__box { border-color: var(--emx-red); }
.emx-picker__search { position: relative; border-bottom: 1px solid var(--emx-line); }
.emx-picker__search .emx-input { border: 0; border-radius: 0; padding-inline-start: 44px; box-shadow: none !important; }
.emx-picker__list { max-height: 380px; overflow: auto; overscroll-behavior: contain; }
.emx-sector + .emx-sector { border-top: 1px solid var(--emx-line); }
.emx-sector__head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    background: var(--emx-surface-2);
    position: sticky;
    top: 0;
    z-index: 1;
}
.emx-sector__toggle {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    padding: 0;
    border: 0;
    background: none;
    text-align: start;
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
}
.emx-sector__toggle::before {
    content: "";
    flex: none;
    width: 7px;
    height: 7px;
    border: solid var(--emx-ink-3);
    border-width: 0 2px 2px 0;
    transform: rotate(-45deg);
    transition: transform .15s ease;
}
[dir="rtl"] .emx-sector__toggle::before { transform: rotate(135deg); }
.emx-sector__toggle[aria-expanded="true"]::before { transform: rotate(45deg); }
.emx-sector__n { font-weight: 500; color: var(--emx-green); font-size: 13px; }
.emx-sector__all { font-size: 13px; color: var(--emx-ink-2); white-space: nowrap; }
.emx-sector__all input { width: 16px; height: 16px; margin: 0 0 0 0; vertical-align: -3px; accent-color: var(--emx-green); }
.emx-body input[type="checkbox"], .emx-body input[type="radio"] { accent-color: var(--emx-green); }
.emx-sector__items { margin: 0; padding: 4px 0; list-style: none; }
.emx-act { display: flex; gap: 10px; align-items: flex-start; padding: 8px 14px 8px 40px; cursor: pointer; font-size: 15px; }
[dir="rtl"] .emx-act { padding: 8px 40px 8px 14px; }
.emx-act:hover { background: var(--emx-surface-2); }
.emx-act input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--emx-green); }
.emx-act mark { background: var(--emx-amber-soft); color: inherit; border-radius: 3px; padding: 0 1px; }
.emx-picker__empty { padding: 18px 14px; color: var(--emx-ink-3); }

/* --------------------------------------------------------------------------
   Fichiers
   -------------------------------------------------------------------------- */
.emx-drop { position: relative; }
.emx-drop__input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; z-index: 0; }
.emx-drop__input:focus-visible + .emx-drop__zone { outline: 3px solid var(--emx-green); outline-offset: 2px; }
.emx-drop__zone {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 22px 16px;
    border: 1.5px dashed var(--emx-line-strong);
    border-radius: 12px;
    background: var(--emx-surface-2);
    text-align: center;
    cursor: pointer;
    pointer-events: none;
    transition: border-color .15s ease, background-color .15s ease;
}
.emx-drop:hover .emx-drop__zone, .emx-drop.is-over .emx-drop__zone { border-color: var(--emx-green); background: var(--emx-green-soft); }
.emx-files.is-invalid .emx-drop__zone { border-color: var(--emx-red); }
.emx-drop__icon { color: var(--emx-green); }
.emx-drop__txt { font-size: 15px; }
.emx-drop__btn { color: var(--emx-green); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }
.emx-drop__formats { font-size: 13px; color: var(--emx-ink-3); }
.emx-files.is-full .emx-drop { display: none; }

.emx-filelist { margin: 10px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.emx-filelist:empty { display: none; }
.emx-file {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 10px;
    border: 1px solid var(--emx-line);
    border-radius: 10px;
    background: var(--emx-surface);
}
.emx-file__thumb {
    flex: none;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background: var(--emx-surface-2);
    border: 1px solid var(--emx-line);
    overflow: hidden;
    font-size: 11px;
    font-weight: 600;
    color: var(--emx-ink-2);
}
.emx-file__thumb img { width: 100%; height: 100%; object-fit: cover; }
.emx-file__body { flex: 1; min-width: 0; }
.emx-file__name { display: block; font-size: 14px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.emx-file__meta { display: block; font-size: 12px; color: var(--emx-ink-3); }
.emx-file.is-working .emx-file__meta::after { content: ""; display: inline-block; width: 10px; height: 10px; margin-inline-start: 6px; border: 2px solid var(--emx-line); border-top-color: var(--emx-green); border-radius: 50%; animation: emx-spin .7s linear infinite; vertical-align: -1px; }
.emx-file__del {
    flex: none;
    min-height: 34px;
    padding: 0 10px;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--emx-red);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}
.emx-file__del:hover { background: var(--emx-red-soft); }

/* --------------------------------------------------------------------------
   Carte
   -------------------------------------------------------------------------- */
.emx-map-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 10px 0; }
.emx-map { height: 320px; margin-bottom: 14px; border: 1px solid var(--emx-line); border-radius: 12px; overflow: hidden; background: var(--emx-surface-2); }
.emx-map:empty { display: none; }

/* --------------------------------------------------------------------------
   Contacts supplementaires
   -------------------------------------------------------------------------- */
.emx-repeat { display: grid; gap: 14px; margin: 10px 0 12px; }
.emx-repeat:empty { display: none; }
.emx-contact .emx-row-between { margin: 4px 0 0; }

/* --------------------------------------------------------------------------
   Recapitulatif, envoi, succes
   -------------------------------------------------------------------------- */
.emx-summary { margin: 8px 0 22px; border: 1px solid var(--emx-line); border-radius: 12px; overflow: hidden; }
.emx-summary:empty { display: none; }
.emx-summary__title { margin: 0; padding: 14px 16px; font-size: 16px; font-weight: 600; background: var(--emx-surface-2); border-bottom: 1px solid var(--emx-line); }
.emx-summary__sec { padding: 12px 16px; }
.emx-summary__sec + .emx-summary__sec { border-top: 1px solid var(--emx-line); }
.emx-summary__head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 6px; }
.emx-summary__head h3 { margin: 0; font-size: 15px; font-weight: 600; }
.emx-summary__head .emx-link { font-size: 14px; }
.emx-summary dl { display: grid; gap: 4px 16px; margin: 0; font-size: 14px; }
@media (min-width: 640px) { .emx-summary dl { grid-template-columns: minmax(140px, 34%) minmax(0, 1fr); } }
.emx-summary dt { color: var(--emx-ink-3); }
.emx-summary dd { margin: 0; overflow-wrap: anywhere; }

.emx-submit { margin-top: 22px; }
.emx-progress { margin: 0; }
.emx-progress__bar { height: 6px; margin-top: 10px; border-radius: 6px; background: var(--emx-line); overflow: hidden; }
.emx-progress__bar span { display: block; height: 100%; width: 0; background: var(--emx-green); transition: width .2s ease; }
.emx-progress__bar.is-indeterminate span { width: 35%; animation: emx-slide 1.2s ease-in-out infinite; }
@keyframes emx-slide { 0% { transform: translateX(-100%); } 100% { transform: translateX(300%); } }
[dir="rtl"] .emx-progress__bar.is-indeterminate span { animation-name: emx-slide-rtl; }
@keyframes emx-slide-rtl { 0% { transform: translateX(100%); } 100% { transform: translateX(-300%); } }

.emx-ref {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    padding: 6px 6px 6px 12px;
    border: 1px solid var(--emx-line-strong);
    border-radius: 8px;
    background: var(--emx-surface);
    font-family: inherit;
}
.emx-ref code { font-family: inherit; font-weight: 600; letter-spacing: .04em; direction: ltr; unicode-bidi: isolate; }

.emx-receipt-banner { margin: 0 auto 20px; }

.emx-success {
    background: var(--emx-surface);
    border: 1px solid var(--emx-line);
    border-radius: var(--emx-radius-lg);
    padding: 32px 22px;
    text-align: center;
    outline: none;
}
.emx-success .emx-lead { margin-inline: auto; }
.emx-stamp { color: var(--emx-green); display: inline-block; transform: rotate(-9deg); margin-bottom: 12px; }
.emx-stamp__main { font-size: 21px; font-weight: 600; fill: currentColor; font-family: var(--emx-font); }
.emx-stamp__date { font-size: 15px; fill: currentColor; font-family: var(--emx-font); }
.emx-success.is-shown .emx-stamp { animation: emx-stamp .55s cubic-bezier(.2, .9, .3, 1.2) both; }
@keyframes emx-stamp {
    0% { transform: rotate(-9deg) scale(1.6); opacity: 0; }
    60% { transform: rotate(-9deg) scale(.94); opacity: 1; }
    100% { transform: rotate(-9deg) scale(1); opacity: 1; }
}
.emx-receipt { display: inline-grid; gap: 8px; margin: 8px auto 12px; text-align: start; }
.emx-receipt__row { display: flex; gap: 12px; justify-content: space-between; padding: 10px 14px; border: 1px solid var(--emx-line); border-radius: 10px; background: var(--emx-surface-2); }
.emx-receipt dt { color: var(--emx-ink-3); font-size: 14px; }
.emx-receipt dd { margin: 0; font-weight: 600; }
.emx-success .emx-note { margin-inline: auto; }
.emx-success .emx-alert { text-align: start; max-width: 560px; margin: 0 auto 16px; }
.emx-success__actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 18px; }

/* --------------------------------------------------------------------------
   Mouvement reduit et impression
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

@media print {
    .emx-header__nav, .emx-footer, .emx-spine, .emx-actions, .emx-success__actions, .emx-skip { display: none !important; }
    .emx-body { background: #fff; }
    .emx-card, .emx-success { border: 0; }
}
