
/* CHA-01 / CRM-02 · Cadre « Fichiers » des fiches projet et lead : explorateur, dépôt, visionneuse (30/10/2026) */
.st-fichiers { position: relative; display: flex; flex-direction: column; gap: .5rem; font-size: .86rem; color: var(--st-texte); }
.st-fichiers--survol { outline: 2px dashed var(--st-accent); outline-offset: 4px; border-radius: .6rem; }
.st-fichiers__note { margin: 0; padding: .45rem .6rem; border-radius: .5rem; background: var(--st-carte-2); border: 1px solid var(--st-bord); color: var(--st-texte-2); font-size: .8rem; }
.st-fichiers__barre { display: flex; align-items: center; justify-content: space-between; gap: .4rem; }
.st-fichiers__fil { display: flex; flex-wrap: wrap; align-items: center; gap: .1rem; min-width: 0; }
.st-fichiers__sep { color: var(--st-texte-2); margin: 0 .1rem; }
.st-fichiers__miette { background: none; border: 0; padding: .15rem .3rem; border-radius: .35rem; color: var(--st-accent-encre); cursor: pointer; font: inherit; font-weight: 600; }
.st-fichiers__miette:hover { background: var(--st-survol); }
.st-fichiers__miette.actif { color: var(--st-texte); cursor: default; }
.st-fichiers__outils { display: flex; gap: .25rem; flex: 0 0 auto; }
.st-fichiers__outil { display: inline-flex; align-items: center; justify-content: center; min-width: 1.75rem; height: 1.75rem; padding: 0 .35rem; border-radius: .45rem;
    border: 1px solid var(--st-bord); background: var(--st-carte); color: var(--st-texte-2); cursor: pointer; text-decoration: none; font-size: .85rem; line-height: 1; }
.st-fichiers__outil:hover { background: var(--st-accent); border-color: var(--st-accent); color: #1f2a00; }
.st-fichiers__liste { border: 1px solid var(--st-bord); border-radius: .6rem; background: var(--st-carte); max-height: 26rem; overflow-y: auto; }
.st-fichiers__liste ul { list-style: none; margin: 0; padding: .2rem; }
.st-fichiers__vide, .st-fichiers__erreur { margin: 0; padding: .8rem; text-align: center; }
.st-fichiers__erreur { color: var(--st-danger); background: var(--st-danger-doux); border-radius: .5rem; margin: .3rem; }
.st-fichiers__ligne { display: flex; align-items: center; gap: .55rem; padding: .35rem .45rem; border-radius: .45rem; cursor: pointer; }
.st-fichiers__ligne:hover { background: var(--st-survol); }
.st-fichiers__ligne--vide { opacity: .55; }
.st-fichiers__ligne--inactif { cursor: default; }
.st-fichiers__icone { flex: 0 0 2.1rem; width: 2.1rem; height: 2.1rem; display: flex; align-items: center; justify-content: center; font-size: 1.35rem;
    border-radius: .35rem; overflow: hidden; background: var(--st-carte-2); }
.st-fichiers__icone img { width: 100%; height: 100%; object-fit: cover; }
.st-fichiers__nom { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.st-fichiers__titre { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.st-fichiers__ligne--dossier .st-fichiers__titre { font-weight: 700; }
.st-fichiers__nom .st-sous { font-size: .74rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-fichiers__actions { display: flex; align-items: center; gap: .25rem; flex: 0 0 auto; }
.st-fichiers__type { max-width: 11rem; font-size: .76rem; padding: .15rem 1.6rem .15rem .4rem; border-radius: .4rem; border: 1px solid var(--st-bord);
    background-color: var(--st-carte); color: var(--st-texte); }
.st-fichiers__envois { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .3rem; }
.st-fichiers__envoi { padding: .35rem .5rem; border: 1px solid var(--st-bord); border-radius: .5rem; background: var(--st-carte-2); }
.st-fichiers__envoi--erreur { border-color: var(--st-danger); background: var(--st-danger-doux); }
.st-fichiers__envoi--fini { border-color: var(--st-accent); }
.st-fichiers__envoi-tete { display: flex; align-items: center; gap: .5rem; }
.st-fichiers__envoi-tete .st-fichiers__titre { flex: 1; min-width: 0; font-weight: 600; }
.st-fichiers__progression { height: .4rem; margin-top: .3rem; border-radius: 999px; background: var(--st-bord); overflow: hidden; }
.st-fichiers__progression span { display: block; height: 100%; background: var(--st-accent); transition: width .2s; }
.st-fichiers__envois-pied { text-align: right; }
.st-fichiers__depot { display: flex; align-items: center; gap: .7rem; padding: .7rem .8rem; border: 2px dashed var(--st-bord); border-radius: .7rem;
    background: var(--st-carte-2); color: var(--st-texte); cursor: pointer; }
.st-fichiers__depot:hover, .st-fichiers--survol .st-fichiers__depot { border-color: var(--st-accent); background: var(--st-accent-doux); }
.st-fichiers__depot-icone { font-size: 1.5rem; }
.st-fichiers__entree { display: none; }
.st-lien { background: none; border: 0; padding: 0; color: var(--st-accent-encre); text-decoration: underline; cursor: pointer; font: inherit; }

.st-visionneuse[x-cloak] { display: none !important; }
.st-visionneuse { position: fixed; inset: 0; z-index: 1001; display: flex; flex-direction: column; background: rgba(10, 14, 22, .88); }
.st-visionneuse__barre { display: flex; align-items: center; gap: .8rem; padding: .6rem 1rem; background: rgba(15, 20, 30, .95); color: #e5e7eb; }
.st-visionneuse__titre { flex: 1; min-width: 0; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-visionneuse__compte { color: #a3adbb; font-size: .85rem; }
.st-visionneuse__boutons { display: flex; gap: .4rem; }
.st-visionneuse__boutons button, .st-visionneuse__boutons a { display: inline-flex; align-items: center; height: 2rem; padding: 0 .7rem; border-radius: .5rem;
    border: 1px solid #3b4657; background: #273142; color: #e5e7eb; text-decoration: none; cursor: pointer; font-size: .85rem; }
.st-visionneuse__boutons button:hover, .st-visionneuse__boutons a:hover { background: #AFCA0B; border-color: #AFCA0B; color: #1f2a00; }
.st-visionneuse__corps { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.st-visionneuse__corps img, .st-visionneuse__corps video { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: .4rem; box-shadow: 0 10px 40px rgba(0, 0, 0, .5); background: #fff; }
.st-visionneuse__corps iframe { width: min(1200px, 100%); height: 100%; border: 0; border-radius: .4rem; background: #fff; }
.st-visionneuse__office { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
.st-visionneuse__message { color: #e5e7eb; text-align: center; }
.st-visionneuse__message a { color: #d4e66a; margin: 0 .5rem; }
@media (max-width: 700px) {
    .st-visionneuse__barre { flex-wrap: wrap; }
}
.st-fichiers__envoi-erreur { margin-top: .2rem; color: var(--st-danger); }
