/* Pastille d'annonce partagée (shared/focal-chip.js) : monte du bas de l'écran pour confirmer une action. Habillage historique de Focal Review
   (.fr-mode-chip), maintenant commun : Focal Review (raccourcis clavier), navigateur de fichiers (retours du serveur), futurs retours d'action. */
/* Chip d'annonce du mode (« Gomme » / « Stylo ») : monte du bas de l'écran, même look que les options du sous-menu Flag */
.fr-mode-chip {
    position: fixed;
    left: 50%;
    bottom: 28px;
    z-index: 10001;
    display: flex;
    align-items: center;
    gap: 8px;
    box-sizing: border-box;
    height: 40px;
    padding: 0 14px;
    border-radius: 999px;
    background-color: var(--blanc-focal);
    border: 1px solid var(--gris-clair);
    color: var(--noir-focal);
    font-family: inherit;
    font-size: var(--text-sm);
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transform: translate(-50%, calc(100% + 40px));
    transition: transform .25s ease-in, opacity .2s ease;
}
.fr-mode-chip.is-in {
    opacity: 1;
    transform: translate(-50%, 0);
    transition: transform .3s cubic-bezier(0.34, 1.38, 0.64, 1), opacity .2s ease;
}
/* Barre d'outils amarrée en bas (classe posée par showShortcutChip) : la pastille apparaît EN HAUT du canvas, sous la barre du haut, et glisse vers le bas (animation inversée) */
.fr-mode-chip.is-top { bottom: auto; top: calc(var(--space-xl, 64px) + 20px); transform: translate(-50%, calc(-100% - 40px)); }
.fr-mode-chip.is-top.is-in { transform: translate(-50%, 0); }
.fr-mode-chip i { font-size: 16px; line-height: 1; }
.fr-mode-chip kbd {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    margin-left: 4px;
    padding: 0 5px;
    box-sizing: border-box;
    font: inherit;
    font-size: 11px;
    line-height: 1;
    color: var(--gris-moyen);
    border: 1px solid var(--gris-clair);
    border-radius: 3px;
}
@media (prefers-reduced-motion: reduce) {
    .fr-mode-chip, .fr-mode-chip.is-in { transition: opacity .2s ease; }
}
/* « Rien à annuler » : secousse rapide de gauche à droite (translate(-50%) = le centrage de la pastille, à conserver à chaque image-clé) */
.fr-mode-chip.is-in.is-shake { animation: fr-chip-shake .36s cubic-bezier(.36, .07, .19, .97) both; }
@keyframes fr-chip-shake {
    0%, 100% { transform: translate(-50%, 0); }
    12% { transform: translate(calc(-50% - 10px), 0); }
    28% { transform: translate(calc(-50% + 9px), 0); }
    44% { transform: translate(calc(-50% - 7px), 0); }
    60% { transform: translate(calc(-50% + 5px), 0); }
    78% { transform: translate(calc(-50% - 2px), 0); }
}
@media (prefers-reduced-motion: reduce) { .fr-mode-chip.is-in.is-shake { animation: none; } }
/* Variante « erreur » */
.fr-mode-chip.is-error { border-color: var(--rouge-alerte); color: var(--rouge-alerte); }
.fr-mode-chip.is-error i { color: var(--rouge-alerte); }
