/*
 * Styles communs aux panels admin et client, chargés sur chaque page via FilamentAsset (app/Providers/FilamentServiceProvider).
 * Publié dans public/css/app/esr-panels.css par `php artisan filament:assets` (à relancer et commiter après modification).
 */

/* Sélecteur de thème daisyUI : rendu après le bloc .fi-topbar-end (hook TOPBAR_END), donc hors de son gap-x-4 */
[data-daisy-theme-switcher] {
    margin-inline-start: 1rem;
}

/* Bouton clair/sombre maison (resources/views/filament/theme-mode-toggle.blade.php), rendu par le même hook */
[data-esr-theme-mode-toggle] {
    margin-inline-start: 1rem;
}

/*
 * Icône « copier » visible après le texte des colonnes et entrées ->copyable() (courriels, numéros de facture, uuid…).
 * Filament rend ces éléments copiables au clic sans indice visuel : l'icône fait partie de l'élément cliquable, donc le clic copie aussi.
 */
.fi-ta-text-item > .fi-copyable:not(.fi-badge)::after,
.fi-in-text-item > .fi-copyable:not(.fi-badge)::after {
    content: '';
    display: inline-block;
    width: 1rem;
    height: 1rem;
    margin-inline-start: 0.375rem;
    vertical-align: -0.1875em;
    background-color: currentColor;
    opacity: 0.4;
    transition: opacity 150ms;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke-width='1.5' stroke='black'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 0 1-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 0 1 1.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 0 0-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 0 1-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 0 0-3.375-3.375h-1.5a1.125 1.125 0 0 1-1.125-1.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H9.75'/%3E%3C/svg%3E") center / contain no-repeat;
}

.fi-ta-text-item > .fi-copyable:not(.fi-badge):hover::after,
.fi-in-text-item > .fi-copyable:not(.fi-badge):hover::after {
    opacity: 0.9;
}
