/* ============================================================
   Panneau latéral de l'éditeur — version sobre (26/09/2026)
   ------------------------------------------------------------
   Retour du restaurateur : « la sidebar n'est pas assez minimaliste,
   la barre d'étapes est rognée, certains boutons manquent de contraste ».
   Mêmes fonctions qu'avant, mais :
   - une surface neutre, sombre dans les deux thèmes (la carte, au centre,
     reste la seule chose en couleur à l'écran) ;
   - une seule chose importante par étape, le reste replié
     (<details class="plus-options">) ;
   - pas de cadres imbriqués, pas d'aplats colorés ;
   - chaque couleur de texte mesurée : ≥ 4,5:1 sur les trois fonds du
     panneau, bords de champs ≥ 3:1 (voir les commentaires des jetons).
   Chargée APRÈS editor.css, editor-gallery.css et atelier.css.
   ============================================================ */

.body-editor {
    --sb-bg: #1b1819;       /* fond du panneau et de l'en-tête          */
    --sb-bg-2: #252122;     /* champs, survols                          */
    --sb-bg-3: #312c2d;     /* état pressé, pastilles                   */
    --sb-line: #3b3536;     /* séparateurs (décoratifs)                 */
    --sb-line-2: #7a706d;   /* bords de champs : 3,66 sur bg, 3,31 sur bg-2 */
    --sb-ink: #f7f1ea;      /* 15,7 sur bg                              */
    --sb-muted: #ddd4ca;    /* 12,0 sur bg                              */
    --sb-dim: #b3a89e;      /* 7,6 sur bg, 5,9 sur bg-3                 */
    --sb-accent: #f4a28c;   /* liens, focus : 8,7 sur bg                */
    --sb-cta: #b23a22;      /* bouton principal : texte crème à 5,7     */
    --sb-cta-hover: #9c3019;
}

/* Les composants du panneau (vignette du modèle, palettes, catégories,
   interrupteurs…) lisent les jetons du thème : on les rebranche sur la
   surface sombre, une fois pour toutes, au lieu de les corriger un par un. */
.editor-sidebar {
    --card: var(--sb-bg-2);
    --card-border: var(--sb-line);
    --ink-strong: var(--sb-ink);
    --ink: var(--sb-ink);
    --ink-muted: var(--sb-muted);
    --ink-dim: var(--sb-dim);
    --laiton: var(--sb-accent);
    --line: var(--sb-line);
    --line-strong: var(--sb-line-2);
    --surface-1: var(--sb-bg-2);
    --paper: var(--sb-bg);
    --white: #ffffff;
    --gray-900: var(--sb-bg);
    --gray-800: var(--sb-bg-2);
    --gray-700: var(--sb-line);
    --gray-600: var(--sb-dim);
    --gray-500: var(--sb-dim);
    --gray-400: var(--sb-muted);
    --gray-300: var(--sb-muted);
    --gray-200: #ebe4db;
    --gray-100: #f4efe9;
    background: var(--sb-bg);
    color: var(--sb-muted);
    border-right: 1px solid var(--sb-line);
}

/* ---------- En-tête ---------- */
.editor-header { background: var(--sb-bg); border-bottom: 1px solid var(--sb-line); }
.editor-autosave { color: var(--sb-dim); }
.editor-header .theme-toggle,
.editor-historique { border-color: var(--sb-line-2) !important; }
.editor-header .theme-toggle { color: var(--sb-muted); }
.editor-header .theme-toggle:hover { border-color: var(--sb-ink) !important; color: var(--sb-ink); }
.editor-historique__btn:disabled { color: var(--sb-dim) !important; opacity: 1 !important; }
.editor-historique__btn:disabled svg { opacity: .55; }
.editor-header :is(a, button):focus-visible { outline: 2px solid var(--sb-accent); outline-offset: 2px; }

.editor-header .theme-toggle { margin: 0; width: 38px; height: 38px; border-radius: 10px; }
.editor-mobile-preview-toggle { background: var(--sb-cta); color: #fffaf0; }
.editor-mobile-preview-toggle:hover { background: var(--sb-cta-hover); }
.editor-mobile-preview-toggle:focus-visible { outline: 2px solid var(--sb-ink); outline-offset: 3px; box-shadow: 0 0 0 5px var(--sb-bg); }

/* ---------- Barre d'étapes ----------
   Libellés complets tant que la barre mesure au moins 300 px (colonne de
   380 px sur ordinateur, pleine largeur sur mobile dès 340 px d'écran) ;
   en dessous, les numéros seuls et le libellé de l'étape en cours. */
.editor-stepper {
    container-type: inline-size;
    flex-shrink: 0;
    padding: 14px 16px 12px;
    background: var(--sb-bg);
    border-bottom: 1px solid var(--sb-line);
}
.editor-sidebar .editor-steps {
    position: relative;
    display: flex;
    justify-content: space-between;
    gap: 0;
    max-width: 520px;
    margin: 0 auto;
    padding: 0;
    background: none;
}
/* Le fil qui relie les numéros : chaque étape en trace sa moitié gauche et
   sa moitié droite, ce qui reste continu quelle que soit la largeur de
   chaque libellé (les colonnes épousent leur texte). */
.editor-sidebar .editor-step::before,
.editor-sidebar .editor-step::after {
    content: "";
    position: absolute;
    top: 13px;
    height: 1px;
    background: var(--sb-line-2);
}
.editor-sidebar .editor-step::before { left: 0; right: 50%; }
.editor-sidebar .editor-step::after { left: 50%; right: 0; }
.editor-sidebar .editor-step:first-child::before,
.editor-sidebar .editor-step:last-child::after { display: none; }
.editor-sidebar .editor-step {
    position: relative;
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 0 2px 2px;
    background: none;
    box-shadow: none;
    border-radius: 8px;
    color: var(--sb-dim);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0;
    white-space: nowrap;
    cursor: pointer;
}
.editor-sidebar .editor-step-num {
    position: relative;
    z-index: 1;
    width: 27px;
    height: 27px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: var(--sb-bg);
    border: 1.5px solid var(--sb-line-2);
    color: var(--sb-muted);
    font-size: 12px;
    font-weight: 700;
    transition: background-color .15s, border-color .15s, color .15s;
}
.editor-step-label { overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.editor-sidebar .editor-step:hover { background: none; color: var(--sb-ink); }
.editor-sidebar .editor-step:hover .editor-step-num { border-color: var(--sb-ink); color: var(--sb-ink); }
.editor-sidebar .editor-step.is-completed { color: var(--sb-muted); }
.editor-sidebar .editor-step.is-completed .editor-step-num { border-color: var(--sb-muted); color: var(--sb-ink); }
.editor-sidebar .editor-step.is-active,
.editor-sidebar .editor-step.is-active:hover { background: none; color: var(--sb-ink); box-shadow: none; }
.editor-sidebar .editor-step.is-active .editor-step-num { background: var(--sb-ink); border-color: var(--sb-ink); color: var(--sb-bg); }
.editor-sidebar .editor-step:focus-visible { outline: 2px solid var(--sb-accent); outline-offset: 3px; }

@container (max-width: 299px) {
    .editor-sidebar .editor-steps { justify-content: flex-start; gap: 6px; }
    .editor-sidebar .editor-step::before, .editor-sidebar .editor-step::after { display: none; }
    .editor-sidebar .editor-step { flex: 0 0 auto; flex-direction: row; gap: 8px; padding: 0; }
    .editor-sidebar .editor-step:not(.is-active) .editor-step-label { display: none; }
    .editor-sidebar .editor-step.is-active { padding-right: 10px; margin-inline: 2px; }
}

/* ---------- Contenu des étapes ---------- */
.editor-sidebar-content { padding: 22px 24px 0; }
.editor-sidebar-content::-webkit-scrollbar-thumb { background: var(--sb-line-2); }
.editor-sidebar .editor-panel-title,
.piste-c .editor-sidebar .editor-panel-title {
    font-family: var(--font-display);
    font-size: 1.4rem;
    line-height: 1.2;
    color: var(--sb-ink);
    margin: 0 0 4px;
}
.editor-sidebar .editor-panel-desc { font-size: .84rem; line-height: 1.5; color: var(--sb-dim); margin: 0 0 20px; }
.editor-sidebar .form-group { margin-bottom: 14px; }
.editor-sidebar .form-label { display: block; margin-bottom: 6px; font-size: .78rem; font-weight: 600; color: var(--sb-muted); letter-spacing: 0; }
.form-requis { color: var(--sb-accent); }
.editor-sidebar :is(.form-input, .form-select, .form-textarea) {
    background: var(--sb-bg-2);
    border: 1px solid var(--sb-line-2);
    border-radius: 8px;
    color: var(--sb-ink);
    font-size: .9rem;
    box-shadow: none;
}
.editor-sidebar :is(.form-input, .form-select) { min-height: 40px; padding: 8px 12px; }
.editor-sidebar :is(.form-input, .form-textarea)::placeholder { color: var(--sb-dim); opacity: 1; }
.editor-sidebar :is(.form-input, .form-select, .form-textarea):hover { border-color: var(--sb-dim); }
.editor-sidebar :is(.form-input, .form-select, .form-textarea):focus,
.editor-sidebar :is(.form-input, .form-select, .form-textarea):focus-visible {
    outline: 2px solid var(--sb-accent);
    outline-offset: 1px;
    border-color: var(--sb-accent);
    box-shadow: none;
}

/* Boutons : plats, rayon court, sans l'ombre décalée de la vitrine. */
.editor-sidebar .btn,
.piste-c .editor-sidebar .btn { border-radius: 8px; box-shadow: none; transform: none; font-weight: 650; }
.editor-sidebar .btn-primary,
.piste-c .editor-sidebar .btn-primary { --btn-bg: var(--sb-cta); --btn-bd: var(--sb-cta); --btn-fg: #fffaf0; box-shadow: none; }
.editor-sidebar .btn-primary:hover,
.piste-c .editor-sidebar .btn-primary:hover { --btn-bg: var(--sb-cta-hover); --btn-bd: var(--sb-cta-hover); box-shadow: none; transform: none; }
.editor-sidebar .btn-outline { --btn-bg: transparent; --btn-fg: var(--sb-ink); --btn-bd: var(--sb-line-2); }
.editor-sidebar .btn-outline:hover { --btn-bg: var(--sb-bg-2); --btn-bd: var(--sb-ink); --btn-fg: var(--sb-ink); }
.editor-sidebar .btn-secondary,
:root[data-theme="dark"] .editor-sidebar .btn-secondary { --btn-bg: var(--sb-ink); --btn-bd: var(--sb-ink); --btn-fg: var(--sb-bg); }
.editor-sidebar .btn-secondary:hover { --btn-bg: #ffffff; --btn-bd: #ffffff; }
.editor-sidebar .btn-ghost { --btn-fg: var(--sb-muted); --btn-bd: transparent; }
.editor-sidebar .btn-ghost:hover { --btn-bg: var(--sb-bg-2); --btn-fg: var(--sb-ink); }
.editor-sidebar .btn:disabled,
.editor-sidebar .btn[aria-disabled="true"] { --btn-bg: var(--sb-bg-3); --btn-bd: var(--sb-bg-3); --btn-fg: var(--sb-dim); opacity: 1; }
.editor-sidebar :is(.btn, button, a, summary, [role="button"], label, input):focus-visible {
    outline: 2px solid var(--sb-accent);
    outline-offset: 2px;
}
.editor-sidebar a:not(.btn) { color: var(--sb-accent); text-decoration: underline; text-underline-offset: 2px; }

.editor-lien-discret {
    display: inline-block;
    margin-top: 6px;
    padding: 4px 0;
    background: none;
    border: 0;
    color: var(--sb-dim);
    font: inherit;
    font-size: .8rem;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--sb-line-2);
    text-underline-offset: 3px;
    cursor: pointer;
}
.editor-lien-discret:hover { color: var(--sb-ink); text-decoration-color: currentColor; }

/* Pied d'étape collé en bas de la colonne : Retour / Suivant toujours à portée. */
.editor-sidebar .editor-panel-footer {
    position: sticky;
    bottom: 0;
    z-index: 3;
    display: flex;
    gap: 10px;
    margin: 24px -24px 0;
    padding: 12px 24px 16px;
    background: var(--sb-bg);
    border-top: 1px solid var(--sb-line);
}

/* ---------- Réglages repliés ---------- */
.plus-options { border-top: 1px solid var(--sb-line); }
.plus-options:last-of-type { border-bottom: 1px solid var(--sb-line); }
.plus-options > summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 13px 2px;
    list-style: none;
    cursor: pointer;
    color: var(--sb-muted);
    font-size: .86rem;
    font-weight: 600;
    border-radius: 6px;
}
.plus-options > summary::-webkit-details-marker { display: none; }
.plus-options > summary::after {
    content: "";
    width: 7px;
    height: 7px;
    margin-right: 4px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg) translateY(-2px);
    transition: transform .15s;
}
.plus-options[open] > summary::after { transform: rotate(-135deg) translateY(-1px); }
.plus-options > summary:hover { color: var(--sb-ink); }
.plus-options__corps { padding: 2px 0 14px; }

/* ---------- Étape 1 ---------- */
.editor-bandeau-exemple,
.editor-sidebar .editor-bandeau-exemple {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 0 0 18px;
    padding: 8px 10px 8px 12px;
    border: 1px solid var(--sb-line);
    border-radius: 8px;
    background: none;
    color: var(--sb-muted);
    font-size: .8rem;
    line-height: 1.4;
}
.editor-bandeau-exemple[hidden] { display: none; }
.editor-bandeau-exemple { flex-wrap: wrap; row-gap: 4px; }
.editor-bandeau-exemple p { display: flex; align-items: center; gap: 8px; margin: 0; white-space: nowrap; }
.editor-bandeau-exemple p::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #f2c47a; flex-shrink: 0; }
.editor-bandeau-exemple__vider,
.editor-sidebar .editor-bandeau-exemple__vider {
    flex-shrink: 0;
    padding: 2px 0;
    color: var(--sb-ink);
    font-size: .8rem;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--sb-line-2);
    text-underline-offset: 3px;
}
.editor-bandeau-exemple__vider:hover { text-decoration-color: currentColor; }

.editor-sidebar .editor-current-template {
    align-items: center;
    gap: 14px;
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid var(--sb-line);
    border-radius: 10px;
    background: var(--sb-bg-2);
}
.editor-sidebar .editor-current-template__preview { flex-basis: 64px; border-radius: 4px; }
.editor-sidebar .editor-current-template__label { font-size: .7rem; letter-spacing: .08em; color: var(--sb-dim); }
.editor-sidebar .editor-current-template__name { font-size: 1rem; color: var(--sb-ink); }
.editor-sidebar .editor-current-template__famille { font-size: .78rem; color: var(--sb-dim); }

/* IA : une entrée d'une ligne, qui s'ouvre au clic. */
.editor-sidebar .ia-modele {
    display: block;
    margin: 18px 0 0;
    padding: 0;
    border: 1px solid var(--sb-line);
    border-radius: 10px;
    background: none;
    overflow: visible;
}
.editor-sidebar .ia-modele::after { display: none; }
.ia-modele__entree {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 12px;
    list-style: none;
    cursor: pointer;
    border-radius: 10px;
}
.ia-modele__entree::-webkit-details-marker { display: none; }
.ia-modele__entree:hover { background: var(--sb-bg-2); }
.editor-sidebar .ia-modele__etincelle {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--sb-bg-3);
    color: #f2c47a;
    font-size: .95rem;
}
.ia-modele__entree-texte { flex: 1; min-width: 0; display: grid; gap: 1px; }
.ia-modele__entree-texte strong { font-size: .86rem; font-weight: 650; color: var(--sb-ink); }
.ia-modele__entree-texte span { font-size: .76rem; color: var(--sb-dim); }
.ia-modele__chevron { flex-shrink: 0; color: var(--sb-dim); transition: transform .15s; }
.ia-modele[open] .ia-modele__chevron { transform: rotate(90deg); }
.ia-modele[open] .ia-modele__entree { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.ia-modele__corps { display: grid; gap: 10px; padding: 4px 12px 14px; }
.editor-sidebar .ia-modele__idees button { color: var(--sb-muted); border-color: var(--sb-line-2); font-weight: 600; }
.editor-sidebar .ia-modele__idees button:hover { color: var(--sb-ink); border-color: var(--sb-ink); background: var(--sb-bg-2); }
.editor-sidebar .ia-modele__quota { color: var(--sb-dim); text-align: left; }
.editor-sidebar .ia-modele__quota a { color: var(--sb-accent); }
.editor-sidebar .ia-modele__resultat { border-top-color: var(--sb-line); }

/* ---------- Étape 3 ---------- */
.editor-sidebar .editor-import-btn { margin: 16px 0 8px; }
.editor-sidebar .editor-add-buttons { display: grid; gap: 0; justify-items: start; }
.editor-sidebar .editor-add-buttons .btn { justify-self: stretch; }

.editor-sidebar .editor-categories { gap: 12px; }
.editor-sidebar .editor-category { background: none; border: 1px solid var(--sb-line); border-radius: 10px; }
.editor-sidebar .editor-category-header { padding: 8px 8px 8px 10px; background: none; border-bottom: 1px solid var(--sb-line); }
.editor-sidebar .editor-category-name-input { font-size: .92rem; font-weight: 650; color: var(--sb-ink); border-radius: 6px; padding: 4px 6px; }
.editor-sidebar :is(.editor-category-drag, .editor-item-drag) { color: var(--sb-dim); }
.editor-sidebar :is(.editor-category-toggle, .editor-category-delete, .editor-item-delete) { flex: 0 0 28px; width: 28px; height: 28px; display: grid; place-items: center; padding: 0; color: var(--sb-dim); border-radius: 6px; }
.editor-sidebar :is(.editor-category-toggle, .editor-category-delete, .editor-item-delete):hover { color: var(--sb-ink); background: var(--sb-bg-2); }
.editor-sidebar .editor-category-body { padding: 10px 10px 8px; }
.editor-sidebar .editor-category-desc-input { background: none; border: 0; border-radius: 6px; padding: 4px 6px; margin-bottom: 4px; color: var(--sb-muted); font-size: .8rem; }
.editor-sidebar .editor-items { gap: 0; }
.editor-sidebar .editor-item { background: none; border: 0; border-top: 1px solid var(--sb-line); border-radius: 0; padding: 10px 0 10px 2px; }
.editor-sidebar .editor-item-name { color: var(--sb-ink); font-size: .88rem; border-radius: 6px; padding: 3px 6px; }
.editor-sidebar .editor-item-price { color: var(--sb-ink); font-variant-numeric: tabular-nums; border-radius: 6px; padding: 3px 6px; width: 72px; }
.editor-sidebar .editor-item-desc { color: var(--sb-dim); font-size: .8rem; border-radius: 6px; padding: 3px 6px; }
/* Champs en ligne : pas de cadre, un pointillé dessous (3,7:1) suffit à dire « modifiable ». */
.editor-sidebar :is(.editor-category-name-input, .editor-category-desc-input, .editor-item-name, .editor-item-price, .editor-item-desc) { border: 0; border-bottom: 1px dashed var(--sb-line-2); border-radius: 4px 4px 0 0; }
.editor-sidebar :is(.editor-category-name-input, .editor-category-desc-input, .editor-item-name, .editor-item-price, .editor-item-desc)::placeholder { color: var(--sb-dim); opacity: 1; }
.editor-sidebar :is(.editor-category-name-input, .editor-category-desc-input, .editor-item-name, .editor-item-price, .editor-item-desc):hover { background: var(--sb-bg-2); }
.editor-sidebar :is(.editor-category-name-input, .editor-category-desc-input, .editor-item-name, .editor-item-price, .editor-item-desc):focus { background: var(--sb-bg-2); box-shadow: 0 0 0 2px var(--sb-accent); }
.editor-sidebar .editor-item-details, .editor-sidebar .editor-item-flags-row { padding-left: 18px; margin-top: 4px; }
.editor-sidebar .editor-item-flag { width: auto; min-width: 26px; height: 24px; padding: 0 6px; border: 1px solid var(--sb-line); border-radius: 6px; background: none; color: var(--sb-dim); font-size: 11px; }
.editor-sidebar .editor-item-flag:hover { border-color: var(--sb-dim); color: var(--sb-ink); }
.editor-sidebar .editor-item-flag.is-active { background: var(--sb-ink); border-color: var(--sb-ink); color: var(--sb-bg); }
.editor-sidebar .editor-add-item-btn { width: 100%; justify-content: flex-start; margin-top: 2px; padding: 8px 6px; border: 0; border-top: 1px solid var(--sb-line); border-radius: 0; background: none; color: var(--sb-muted); font-size: .82rem; font-weight: 600; }
.editor-sidebar .editor-add-item-btn:hover { color: var(--sb-ink); background: none; }

/* ---------- Étape 4 ---------- */
.editor-sidebar .editor-customize-section { margin-bottom: 18px; padding: 0; border: 0; }
.editor-sidebar .editor-customize-label {
    margin: 0 0 10px;
    font-family: var(--font-body);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--sb-dim);
}
.editor-sidebar .editor-palette { background: none; border-color: var(--sb-line); border-radius: 8px; }
.editor-sidebar .editor-palette:hover { border-color: var(--sb-dim); transform: none; }
.editor-sidebar .editor-palette.is-active { border-color: var(--sb-ink); box-shadow: 0 0 0 1px var(--sb-ink) inset; }
.editor-sidebar .editor-palette__nom { color: var(--sb-muted); }
.editor-sidebar .editor-palette.is-active .editor-palette__nom { color: var(--sb-ink); }
.editor-sidebar .editor-color-item label { color: var(--sb-muted); font-size: .8rem; }
.editor-sidebar .editor-color-input { border-color: var(--sb-line-2); }

/* ---------- Étape 5 ---------- */
.pub-bloc--pdf,
.editor-sidebar .pub-bloc--pdf { margin: 22px 0 0; padding: 16px 0; border: 0; border-top: 1px solid var(--sb-line); border-radius: 0; background: none; }
.pub-pdf { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.pub-pdf__texte { display: grid; gap: 2px; min-width: 0; }
.pub-pdf__texte strong { font-size: .88rem; color: var(--sb-ink); }
.pub-pdf__texte span { font-size: .78rem; color: var(--sb-dim); }
.pub-pdf .btn { flex-shrink: 0; }
.editor-sidebar .pub-apercu .editor-online-preview-title { display: none; }
.editor-sidebar .pub-email { margin: 0; padding: 0; }
.editor-sidebar .pub-email > summary { color: var(--sb-muted); font-size: .86rem; }
.editor-sidebar .pub-email > summary::after { content: ""; color: inherit; }
.editor-sidebar .pub-email[open] > summary::after { content: ""; }
.editor-sidebar .pub-bloc__tete svg { color: var(--sb-dim); }
.editor-sidebar .editor-online-preview { padding: 0 !important; margin-bottom: 18px; border: 0 !important; background: none !important; }
.editor-sidebar .editor-online-preview-title { font-size: .72rem; font-weight: 700 !important; letter-spacing: .08em; text-transform: uppercase; color: var(--sb-dim) !important; }
.editor-sidebar .pub-offres__titre { color: var(--sb-dim); letter-spacing: .08em; font-size: .72rem; }
.editor-sidebar .pub-offre__corps { border-width: 1px; border-color: var(--sb-line-2); border-radius: 10px; background: none; }
.editor-sidebar .pub-offre:hover .pub-offre__corps { border-color: var(--sb-dim); }
.editor-sidebar .pub-offre input:checked + .pub-offre__corps { border-color: var(--sb-ink); background: var(--sb-bg-2); box-shadow: 0 0 0 1px var(--sb-ink) inset; }
.editor-sidebar .pub-offre__corps::before { border-color: var(--sb-line-2); }
.editor-sidebar .pub-offre input:checked + .pub-offre__corps::before { border-color: var(--sb-ink); box-shadow: inset 0 0 0 3px var(--sb-bg-2), inset 0 0 0 8px var(--sb-ink); }
.editor-sidebar .pub-offre input:focus-visible + .pub-offre__corps { outline: 2px solid var(--sb-accent); outline-offset: 2px; }
.editor-sidebar .pub-offre__badge { background: var(--sb-bg-3); color: var(--sb-muted); }
.editor-sidebar .pub-periode { background: var(--sb-bg); border-color: var(--sb-line-2); }
.editor-sidebar .pub-periode button { color: var(--sb-muted); }
.editor-sidebar .pub-periode button[aria-pressed="true"] { background: var(--sb-ink); color: var(--sb-bg); }
.editor-sidebar .pub-periode button[aria-pressed="true"] em { color: #2f6b43; }
.editor-sidebar .pub-email { border-top-color: var(--sb-line); }
.editor-sidebar .pub-email summary { color: var(--sb-muted); }
.editor-sidebar .pub-email summary::after { color: var(--sb-dim); }

@media (max-width: 900px) {
    .editor-sidebar { flex: 1 1 auto; }
    .editor-sidebar-content { padding: 18px 16px 0; }
    .editor-sidebar .editor-panel-footer { margin-inline: -16px; padding-inline: 16px; }
    .editor-mobile-preview-toggle { bottom: 84px; }
    /* Le pied d'étape collé en bas fait déjà « Suivant » / « Publier » : la barre flottante
       du bureau le recouvrait sur mobile. */
    .editor-floating-cta { display: none !important; }
}

/* ---------- Hors panneau : barre « Terminer », collage de carte ---------- */
.editor-floating-cta { background: var(--sb-bg); border-top: 1px solid var(--sb-line); }
.editor-floating-cta-text strong { color: var(--sb-ink); }
.editor-floating-cta-text span { color: var(--sb-dim); }
.editor-floating-cta .btn-primary,
.piste-c .editor-floating-cta .btn-primary { --btn-bg: var(--sb-cta); --btn-bd: var(--sb-cta); --btn-fg: #fffaf0; box-shadow: none; }
.editor-floating-cta :focus-visible { outline: 2px solid var(--sb-accent); outline-offset: 2px; }
.import-carte__close:hover { color: var(--on-accent); }
.import-carte__saisie textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
