/* IngeniShare (SHR_CSS) : charte v0.4, alignee sur SimplEdit a la demande de Benj (11/11).
   Fond blanc, bandeau blanc, tuiles ; bleu intense a la place du vert de SimplEdit.
   Polices auto-hebergees, licence OFL : Figtree (texte), Bricolage Grotesque (titres),
   IBM Plex Mono (petites lignes de donnees : echeances, compteurs).
   La couleur --accent est celle du client si elle est definie (/theme.css). */

@font-face { font-family: "Figtree"; src: url("polices/figtree-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("polices/figtree-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("polices/figtree-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("polices/figtree-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Bricolage Grotesque"; src: url("polices/bricolage-grotesque-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Bricolage Grotesque"; src: url("polices/bricolage-grotesque-latin-700-normal.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("polices/ibm-plex-mono-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  color-scheme: light;
  --accent: #1f56d6;                                         /* bleu intense IngeniShare */
  --accent-fonce: color-mix(in srgb, var(--accent) 80%, #000);
  --accent-texte: color-mix(in srgb, var(--accent) 88%, #000);
  --accent-doux: color-mix(in srgb, var(--accent) 9%, #fff);
  --fond: #ffffff;
  --surface: #ffffff;
  --trait: #e2e6ee;
  --trait-fort: #c9d0dc;
  --encre: #141a24;
  --encre-douce: #5a6476;
  --alerte: #b42318;
  --alerte-fond: #fdeceb;
  --rayon: 8px;
  --rayon-tuile: 14px;
  --texte: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --titres: "Bricolage Grotesque", "Figtree", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    color-scheme: dark;
    --accent-texte: color-mix(in srgb, var(--accent) 45%, #fff);
    --accent-doux: color-mix(in srgb, var(--accent) 22%, #10151d);
    --fond: #10151d;
    --surface: #161d28;
    --trait: #263142;
    --trait-fort: #354257;
    --encre: #e8edf5;
    --encre-douce: #9aa6b8;
    --alerte: #f4877d;
    --alerte-fond: #3a1a18;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--texte); font-size: 1rem; line-height: 1.5; color: var(--encre); background: var(--fond); }

a { color: var(--accent-texte); text-underline-offset: .18em; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 60%, transparent); outline-offset: 2px; }

h1, h2, h3 { font-family: var(--titres); font-weight: 700; letter-spacing: -.015em; }
h1 { font-size: 2rem; line-height: 1.15; margin: 0 0 1rem; }
h2 { font-size: 1.3rem; margin: 0 0 .5rem; }
p { margin: 0 0 .9rem; }

/* ------------------------------------------------------------ boutons et formulaires */

.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  font: inherit; font-weight: 600; color: #fff; background: var(--accent);
  border: 0; border-radius: var(--rayon); padding: .7rem 1.15rem; text-decoration: none; cursor: pointer;
}
.bouton:hover { background: var(--accent-fonce); }
a.bouton { color: #fff; }
.bouton-contour { color: var(--encre); background: var(--surface); border: 1px solid var(--trait-fort); }
.bouton-contour:hover { background: var(--accent-doux); }

.formulaire { display: grid; gap: 1.1rem; margin-top: .5rem; }
.formulaire-large { max-width: 40rem; }
.deux { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 420px) { .deux { grid-template-columns: 1fr; } }

.champ { display: grid; gap: .35rem; }
.champ > span:first-child { font-weight: 600; font-size: .95rem; }
.champ em { font-style: normal; font-weight: 400; color: var(--encre-douce); }
.champ input, .champ textarea, .champ select {
  font: inherit; color: var(--encre); background: var(--surface);
  border: 1px solid var(--trait-fort); border-radius: var(--rayon); padding: .65rem .8rem; width: 100%;
}
.champ input:focus-visible, .champ textarea:focus-visible, .champ select:focus-visible { border-color: var(--accent); }
.champ input[type="file"] { padding: .5rem; }
.champ .aide { font-size: .87rem; color: var(--encre-douce); }

.alerte { background: var(--alerte-fond); color: var(--alerte); border-left: 4px solid var(--alerte); border-radius: var(--rayon); padding: .7rem .9rem; margin: 0 0 1rem; }
.alerte ul { margin: 0; padding-left: 1.1rem; }

.rappel { border: 1px solid var(--trait); border-left: 4px solid var(--accent); background: var(--accent-doux); padding: 1rem 1.15rem; border-radius: var(--rayon); }
.rappel-titre { font-weight: 700; margin: 0 0 .5rem; }
.case { display: flex; gap: .7rem; align-items: flex-start; cursor: pointer; }
.case input { margin-top: .25rem; width: 1.1rem; height: 1.1rem; flex: none; accent-color: var(--accent); }

.actions { display: flex; align-items: center; gap: 1.25rem; }
.discret, .lien-discret { color: var(--encre-douce); }

.langue { margin: 0; }
.langue button, button.lien {
  font: inherit; font-size: .95rem; background: none; border: 0; padding: .25rem .4rem;
  color: var(--encre-douce); text-decoration: underline; text-underline-offset: .18em; cursor: pointer;
}
.langue button:hover, button.lien:hover { color: var(--encre); }

/* ------------------------------------------------------------ pages d acces */

.cadre { min-height: 100vh; display: grid; grid-template-columns: minmax(300px, 5fr) 7fr; }

.panneau {
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: clamp(1.5rem, 4vw, 3.5rem); color: #fff; background-color: var(--accent);
  background-image:
    repeating-linear-gradient(115deg, rgb(255 255 255 / .07) 0 2px, transparent 2px 46px),
    repeating-linear-gradient(65deg, rgb(0 0 0 / .10) 0 1px, transparent 1px 30px),
    linear-gradient(160deg, rgb(255 255 255 / .10), rgb(0 0 0 / .25));
}
.panneau-nom { font-family: var(--titres); font-size: clamp(2.4rem, 5.2vw, 4.6rem); font-weight: 700; line-height: 1; letter-spacing: -.03em; margin: 0 0 1rem; overflow-wrap: anywhere; }
.panneau-role { font-size: 1.1rem; margin: 0 0 2.5rem; max-width: 28ch; }
.panneau-heberge { font-size: .85rem; margin: 0; opacity: .85; }

.contenu { display: flex; flex-direction: column; padding: 1.25rem clamp(1.25rem, 4vw, 3rem) 3rem; background: var(--fond); }
.contenu-haut { display: flex; justify-content: flex-end; min-height: 2.5rem; }
.carte { width: 100%; max-width: 27rem; margin: auto; background: var(--surface); border: 1px solid var(--trait); border-radius: var(--rayon-tuile); padding: 2rem; }
.carte h1 { font-size: 1.7rem; }
.carte .intro { color: var(--encre-douce); }
.carte .qui { font-weight: 600; overflow-wrap: anywhere; }
.carte .bas { margin: 1.4rem 0 0; color: var(--encre-douce); font-size: .95rem; }

/* ------------------------------------------------------------ bandeau de l application */

.barre {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  padding: .7rem clamp(1rem, 4vw, 2.5rem); background: var(--surface); border-bottom: 1px solid var(--trait);
}
.barre-gauche { display: flex; align-items: center; gap: 1.75rem; flex-wrap: wrap; }
.barre-nom { font-family: var(--titres); font-weight: 700; font-size: 1.35rem; color: var(--encre); text-decoration: none; letter-spacing: -.02em; }
.menu { display: flex; gap: .25rem; margin: 0; padding: 0; list-style: none; }
.menu a { display: block; padding: .45rem .75rem; border-radius: var(--rayon); color: var(--encre-douce); font-weight: 600; text-decoration: none; }
.menu a:hover { color: var(--encre); background: var(--accent-doux); }
.menu a[aria-current="page"] { color: var(--accent-texte); background: var(--accent-doux); }
.barre-droite { display: flex; align-items: center; gap: .75rem; flex-wrap: wrap; justify-content: flex-end; }
.barre-droite form { margin: 0; }
.barre-qui { font-weight: 500; }
.pastille { display: inline-block; font-size: .8rem; font-weight: 600; color: var(--accent-texte); background: var(--accent-doux); border-radius: 999px; padding: .2rem .65rem; }
.barre .bouton-contour { padding: .45rem .9rem; font-size: .95rem; }

.page { max-width: 76rem; margin: 0 auto; padding: 2rem clamp(1rem, 4vw, 2.5rem) 4rem; }
.tete-page { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.tete-page h1 { margin: 0; }

/* ------------------------------------------------------------ tuiles de projets */

.tuiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1rem; margin: 0; padding: 0; list-style: none; }
.tuile {
  display: flex; flex-direction: column; gap: .6rem; height: 100%;
  padding: 1.25rem; background: var(--surface); border: 1px solid var(--trait); border-radius: var(--rayon-tuile);
  color: var(--encre); text-decoration: none;
}
a.tuile:hover { border-color: var(--trait-fort); box-shadow: 0 1px 0 var(--trait-fort); }
.tuile-tete { display: flex; align-items: center; gap: .85rem; }
.tuile-titre { font-family: var(--titres); font-weight: 600; font-size: 1.25rem; line-height: 1.2; overflow-wrap: anywhere; }
.tuile-texte { color: var(--encre-douce); margin: 0; overflow-wrap: anywhere; }
.tuile-donnee { font-family: var(--mono); font-size: .85rem; color: var(--accent-texte); margin-top: auto; }
.tuile-donnee.proche { color: var(--alerte); }
.tuile-nouvelle { border-style: dashed; border-color: var(--trait-fort); justify-content: center; align-items: flex-start; }
.tuile-nouvelle .plus { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 12px; background: var(--accent-doux); color: var(--accent-texte); font-size: 1.8rem; font-weight: 600; }

/* ------------------------------------------------------------ valise (icone de projet) */

.valise { flex: none; width: 56px; height: 56px; display: block; }
.valise-grande { width: 104px; height: 104px; }
.valise .poignee { fill: none; stroke: var(--accent); stroke-width: 4; stroke-linecap: round; }
.valise .corps { fill: var(--surface); stroke: var(--accent); stroke-width: 3; }
.valise .corps-plein { fill: var(--accent); stroke: var(--accent); stroke-width: 3; }
.valise .sangle { stroke: color-mix(in srgb, var(--accent) 35%, transparent); stroke-width: 2; }
.valise .initiales { fill: #fff; font-family: var(--titres); font-weight: 700; font-size: 19px; }

/* ------------------------------------------------------------ page de projet */

.projet-tete { display: flex; gap: 1.5rem; align-items: center; margin: 0 0 2rem; }
.projet-tete h1 { margin-bottom: .35rem; overflow-wrap: anywhere; }
.projet-description { max-width: 62ch; margin-bottom: .45rem; color: var(--encre-douce); }
.projet-echeance { font-family: var(--mono); font-size: .9rem; color: var(--accent-texte); margin: 0; }
.bloc { border: 1px solid var(--trait); border-radius: var(--rayon-tuile); padding: 1.25rem 1.4rem; margin-bottom: 1rem; }
.bloc p:last-child { margin-bottom: 0; }

.vide { border: 1px dashed var(--trait-fort); border-radius: var(--rayon-tuile); padding: 2.25rem 2rem; max-width: 42rem; }
.vide p { color: var(--encre-douce); }

/* ------------------------------------------------------------ pages neutres */

.neutre-cadre { max-width: 34rem; margin: 18vh auto 0; padding: 0 1.5rem; }
.neutre-cadre p { color: var(--encre-douce); }

/* ------------------------------------------------------------ mobile */

@media (max-width: 860px) {
  .cadre { grid-template-columns: 1fr; }
  .panneau { padding: 2rem 1.5rem 1.5rem; }
  .panneau-nom { font-size: 2.4rem; }
  .panneau-role { margin-bottom: 1rem; }
  .carte { margin-top: 1rem; padding: 1.5rem; }
  h1 { font-size: 1.6rem; }
}
@media (max-width: 560px) {
  .projet-tete { flex-direction: column; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* ------------------------------------------------------------ participants (v0.5) */

.succes { background: color-mix(in srgb, #1a7f4b 10%, var(--surface)); color: #146c3f; border-left: 4px solid #1a7f4b; border-radius: var(--rayon); padding: .7rem .9rem; margin: 0 0 1rem; }
@media (prefers-color-scheme: dark) { .succes { color: #7fd6a6; } }
.participants { list-style: none; margin: 0 0 1.25rem; padding: 0; }
.participants li { display: flex; flex-wrap: wrap; align-items: baseline; gap: .25rem 1rem; padding: .6rem 0; border-bottom: 1px solid var(--trait); }
.participants li:last-child { border-bottom: 0; }
.participants form { margin: 0 0 0 auto; }
.part-nom { font-weight: 600; overflow-wrap: anywhere; }
.part-info { color: var(--encre-douce); font-size: .92rem; }
.inviter { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 1.5rem; border-top: 1px solid var(--trait); padding-top: 1.25rem; }
.inviter h3 { font-size: 1.1rem; margin: 0; }
.inviter .bouton { justify-self: start; }
.champ-code { font-family: var(--mono); font-size: 1.6rem !important; letter-spacing: .35em; text-align: center; }
.inviter { align-items: start; }
.inviter .formulaire { align-content: start; margin-top: 0; }
.formulaire > .aide { font-size: .87rem; color: var(--encre-douce); margin: 0; }

/* ------------------------------------------------------------ v0.6 : collegues a cocher, gestionnaire, quitter */
.part-actions { display: flex; gap: .5rem; margin-left: auto; }
.part-actions form { margin: 0; }
.choix { border: 1px solid var(--trait-fort); border-radius: var(--rayon); background: var(--surface); }
.choix summary { cursor: pointer; padding: .65rem .8rem; font-weight: 600; }
.choix[open] summary { border-bottom: 1px solid var(--trait); }
.cases { list-style: none; margin: 0; padding: .4rem .8rem; max-height: 16rem; overflow-y: auto; }
.cases li { padding: .35rem 0; }
.cases .discret { font-size: .88rem; margin-left: .25rem; }
.quitter { margin-top: 1rem; border-top: 1px solid var(--trait); padding-top: 1rem; }
.quitter summary { cursor: pointer; color: var(--alerte); font-weight: 600; }
.quitter p { margin: .75rem 0; color: var(--encre-douce); }

/* ------------------------------------------------------------ fichiers (v0.7) */
.depot { margin-bottom: 1.25rem; }
.depot-champ { position: absolute; width: 1px; height: 1px; opacity: 0; }
.depot-zone { display: grid; gap: .3rem; justify-items: center; text-align: center; padding: 1.6rem 1rem; border: 2px dashed var(--trait-fort); border-radius: var(--rayon-tuile); background: var(--accent-doux); cursor: pointer; }
.depot-zone:hover, .depot.survol .depot-zone { border-color: var(--accent); }
.depot-champ:focus-visible + .depot-zone { outline: 3px solid color-mix(in srgb, var(--accent) 60%, transparent); outline-offset: 2px; }
.depot-titre { font-weight: 600; color: var(--accent-texte); }
.depot-suivi { list-style: none; margin: .75rem 0 0; padding: 0; }
.depot-suivi li { display: grid; grid-template-columns: minmax(0, 1fr) 9rem auto; gap: .75rem; align-items: center; padding: .35rem 0; font-size: .95rem; }
.depot-nom { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.depot-suivi progress { width: 100%; accent-color: var(--accent); }
.depot-suivi .reussi .depot-etat { color: #146c3f; }
.depot-suivi .echec .depot-etat { color: var(--alerte); }
.fichiers { list-style: none; margin: 0; padding: 0; }
.fichiers li { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem 1rem; padding: .7rem 0; border-bottom: 1px solid var(--trait); }
.fichiers li:last-child { border-bottom: 0; }
.fichiers form { margin: 0 0 0 auto; }
.fichier-nom { font-weight: 600; overflow-wrap: anywhere; flex: 1 1 100%; }
.fichier-info { color: var(--encre-douce); font-size: .92rem; }
.fichier-empreinte { font-family: var(--mono); font-size: .8rem; color: var(--encre-douce); }
.etat { font-weight: 600; }
.etat-sain { color: #146c3f; }
.etat-infecte { color: var(--alerte); }
.quota { font-family: var(--mono); font-size: .85rem; color: var(--encre-douce); margin: 1rem 0 0; }
@media (max-width: 560px) { .depot-suivi li { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------ explorateur (v0.8) */
.explo-tete { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.explo-tete h2 { margin: 0; }
.ariane { margin: .6rem 0 1rem; font-weight: 600; overflow-wrap: anywhere; }
.ariane span[aria-hidden] { color: var(--encre-douce); margin: 0 .2rem; }
.depot-zone { cursor: default; }
.depot-choix { display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center; margin: .3rem 0; }
.depot-choix .bouton { cursor: pointer; padding: .5rem .9rem; font-size: .95rem; }
.depot-champ:focus-visible + .depot-zone { outline: none; }
#c-fichiers:focus-visible ~ .depot-zone label[for="c-fichiers"], #c-dossier:focus-visible ~ .depot-zone label[for="c-dossier"] { outline: 3px solid color-mix(in srgb, var(--accent) 60%, transparent); }
.outils { display: flex; gap: .6rem; flex-wrap: wrap; align-items: flex-start; margin: 0 0 1rem; }
.outil summary { cursor: pointer; list-style: none; padding: .45rem .85rem; border: 1px solid var(--trait-fort); border-radius: var(--rayon); font-weight: 600; font-size: .95rem; background: var(--surface); }
.outil summary::-webkit-details-marker { display: none; }
.outil[open] summary { background: var(--accent-doux); }
.outil-danger summary { color: var(--alerte); }
.outil-form { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-top: .5rem; }
.outil-form input[type="text"] { font: inherit; padding: .5rem .7rem; border: 1px solid var(--trait-fort); border-radius: var(--rayon); background: var(--surface); color: var(--encre); min-width: 14rem; }
.outil-form span { color: var(--encre-douce); font-size: .92rem; max-width: 36ch; }
.outil-danger .bouton { background: var(--alerte); }
.explo-cadre { overflow-x: auto; border: 1px solid var(--trait); border-radius: var(--rayon); }
.explo { width: 100%; border-collapse: collapse; font-size: .95rem; }
.explo th { text-align: left; font-weight: 600; color: var(--encre-douce); padding: .6rem .75rem; border-bottom: 1px solid var(--trait); white-space: nowrap; background: var(--fond); }
.explo th a { color: inherit; }
.explo td { padding: .55rem .75rem; border-bottom: 1px solid var(--trait); vertical-align: middle; }
.explo tr:last-child td { border-bottom: 0; }
.explo tbody tr:hover { background: color-mix(in srgb, var(--accent) 4%, transparent); }
.explo td a { display: inline-flex; align-items: center; gap: .45rem; color: var(--encre); text-decoration: none; font-weight: 600; }
.explo td a:hover span { text-decoration: underline; text-underline-offset: .18em; }
.explo-nom { min-width: 16rem; }
.explo-nom .fichier-empreinte { display: block; margin-left: 1.9rem; }
.explo-taille { white-space: nowrap; font-family: var(--mono); font-size: .85rem; }
.ligne-dossier td a { color: var(--encre); }
.ico { width: 1.4rem; height: 1.4rem; flex: none; vertical-align: middle; }
.ico-dossier { fill: color-mix(in srgb, var(--accent) 75%, #fff); }
.ico-fichier { fill: var(--surface); stroke: var(--encre-douce); stroke-width: 1.4; }
.ico-pli { fill: none; stroke: var(--encre-douce); stroke-width: 1.4; }
.explo-actions { text-align: right; width: 3rem; }
.menu-fichier { position: relative; display: inline-block; }
.menu-fichier summary { list-style: none; cursor: pointer; padding: .1rem .55rem; border-radius: var(--rayon); font-weight: 700; }
.menu-fichier summary::-webkit-details-marker { display: none; }
.menu-fichier summary:hover, .menu-fichier[open] summary { background: var(--accent-doux); }
.menu-panneau { position: absolute; right: 0; z-index: 5; display: grid; gap: .6rem; min-width: 16rem; padding: .8rem; text-align: left; background: var(--surface); border: 1px solid var(--trait-fort); border-radius: var(--rayon); box-shadow: 0 6px 20px rgb(0 0 0 / .12); }
.menu-panneau form { display: grid; gap: .45rem; margin: 0; }
.menu-panneau select { font: inherit; padding: .4rem; border: 1px solid var(--trait-fort); border-radius: var(--rayon); background: var(--surface); color: var(--encre); width: 100%; }
.lien-danger { color: var(--alerte) !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
/* Correctifs v0.8 : bouton a contour lisible meme en lien ; menus de fichier non rognes. */
a.bouton.bouton-contour { color: var(--encre); }
.explo-cadre { overflow: visible; }
@media (max-width: 760px) {
  .explo-cadre { overflow-x: auto; }
  .menu-panneau { position: static; box-shadow: none; margin-top: .4rem; }
}

/* ------------------------------------------------------------ v0.9 : explorateur refondu */
.depot-zone { padding: 1rem; }
.explo-barre { display: flex; align-items: center; justify-content: space-between; gap: .75rem 1.5rem; flex-wrap: wrap; margin: 0 0 .75rem; padding: .55rem .75rem; background: var(--accent-doux); border-radius: var(--rayon); }
.ariane { display: flex; align-items: center; flex-wrap: wrap; gap: .3rem; margin: 0; font-weight: 600; font-size: 1.02rem; }
.ariane a { display: inline-flex; align-items: center; gap: .35rem; color: var(--accent-texte); }
.ariane [aria-current="page"] { color: var(--encre); }
.ariane-sep { color: var(--encre-douce); margin: 0 .15rem; }
.ico-petit { width: 1.15rem; height: 1.15rem; }
.ico-trait { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.modes { display: inline-flex; border: 1px solid var(--trait-fort); border-radius: var(--rayon); overflow: hidden; background: var(--surface); }
.modes a { padding: .35rem .75rem; font-size: .9rem; font-weight: 600; color: var(--encre-douce); text-decoration: none; }
.modes a + a { border-left: 1px solid var(--trait-fort); }
.modes a[aria-current="true"] { background: var(--accent); color: #fff; }
.explo th a { text-decoration: none; }
.explo th a:hover { text-decoration: underline; }
.ligne-retour td { padding: .35rem .75rem; }
.ligne-retour a { color: var(--accent-texte) !important; padding: .15rem .35rem; border-radius: var(--rayon); }
.ligne-retour a:hover { background: var(--accent-doux); }
/* Mode icones */
.explo-icones { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: .75rem; }
.explo-icones li { position: relative; }
.carte-explo { display: grid; justify-items: center; gap: .35rem; text-align: center; padding: 1rem .6rem .8rem; border: 1px solid var(--trait); border-radius: var(--rayon-tuile); color: var(--encre); text-decoration: none; height: 100%; }
a.carte-explo:hover { border-color: var(--trait-fort); background: color-mix(in srgb, var(--accent) 4%, transparent); }
.carte-explo .ico { width: 3rem; height: 3rem; }
.carte-retour { align-content: center; color: var(--accent-texte); }
.carte-nom { font-weight: 600; font-size: .92rem; overflow-wrap: anywhere; }
.carte-meta { font-size: .8rem; color: var(--encre-douce); }
.carte-li .menu-fichier { position: absolute; top: .3rem; right: .3rem; }
/* Mode colonnes */
.explo-colonnes { display: flex; overflow-x: auto; border: 1px solid var(--trait); border-radius: var(--rayon); min-height: 18rem; }
.colonne { list-style: none; margin: 0; padding: .35rem; flex: 0 0 16rem; max-height: 30rem; overflow-y: auto; border-right: 1px solid var(--trait); }
.colonne:last-child { flex: 1 0 16rem; border-right: 0; }
.colonne a, .colonne-inactif { display: flex; align-items: center; gap: .45rem; padding: .35rem .45rem; border-radius: 6px; color: var(--encre); text-decoration: none; font-size: .92rem; }
.colonne a span:not(.chevron), .colonne-inactif span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
.colonne a:hover { background: var(--accent-doux); }
.colonne a.ouvert { background: var(--accent); color: #fff; }
.colonne a.ouvert .ico-dossier { fill: #fff; }
.colonne-inactif { color: var(--encre-douce); }
.colonne-vide { padding: .5rem; font-size: .9rem; }
.chevron { color: inherit; opacity: .6; }
/* Voile de depot plein ecran */
.voile-depot { position: fixed; inset: 0; z-index: 50; display: none; place-items: center; background: color-mix(in srgb, var(--accent) 82%, transparent); color: #fff; pointer-events: none; }
.voile-depot.visible { display: grid; }
.voile-depot p { font-family: var(--titres); font-size: clamp(1.4rem, 3vw, 2.2rem); font-weight: 700; padding: 2.5rem 3rem; border: 3px dashed rgb(255 255 255 / .8); border-radius: 22px; margin: 1rem; text-align: center; }
/* Participants repliables */
.bloc-repliable > summary { display: flex; align-items: baseline; gap: .75rem; cursor: pointer; list-style: none; }
.bloc-repliable > summary::-webkit-details-marker { display: none; }
.bloc-repliable > summary h2 { margin: 0; }
.bloc-repliable > summary::before { content: "›"; font-size: 1.4rem; line-height: 1; color: var(--encre-douce); transition: transform .15s; display: inline-block; }
.bloc-repliable[open] > summary::before { transform: rotate(90deg); }
.bloc-repliable[open] > summary { margin-bottom: .75rem; }
.compteur { color: var(--encre-douce); font-size: .95rem; }

/* ------------------------------------------------------------ v0.10 : selection, jauge, raccourci */
.outil-lien { display: inline-block; padding: .45rem .85rem; border: 1px solid var(--trait-fort); border-radius: var(--rayon); font-weight: 600; font-size: .95rem; color: var(--encre); text-decoration: none; background: var(--surface); }
.outil-lien:hover { background: var(--accent-doux); }
.barre-selection { display: flex; align-items: flex-start; gap: .6rem; flex-wrap: wrap; margin: 0 0 .75rem; padding: .5rem .6rem; border: 1px dashed var(--trait-fort); border-radius: var(--rayon); }
.selection.a-selection .barre-selection { border-style: solid; border-color: var(--accent); background: var(--accent-doux); }
.sel-compte { align-self: center; font-weight: 600; color: var(--encre-douce); margin-right: .4rem; }
.selection.a-selection .sel-compte { color: var(--accent-texte); }
.barre-selection .bouton { padding: .45rem .85rem; font-size: .95rem; }
.barre-selection .bouton:disabled { opacity: .45; cursor: not-allowed; }
.sel-action-details.inactif { opacity: .45; pointer-events: none; }
.sel-confirmation { color: var(--alerte); font-size: .92rem; max-width: 40ch; }
.col-case { width: 2.4rem; text-align: center; }
.col-case input, .case-sel { width: 1.05rem; height: 1.05rem; accent-color: var(--accent); cursor: pointer; }
.ligne-fichier { cursor: default; user-select: none; }
.nom-fichier { display: inline-flex; align-items: center; gap: .45rem; font-weight: 600; }
.explo tr.coche td { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.carte-li { position: relative; }
.carte-li > .case-sel { position: absolute; top: .55rem; left: .55rem; z-index: 2; }
.carte-li.coche .carte-explo { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); }
.carte-fichier { cursor: default; user-select: none; }
.colonne-fichier { display: flex; align-items: center; gap: .45rem; padding: .35rem .45rem; border-radius: 6px; font-size: .92rem; cursor: default; }
.colonne-fichier span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; }
.colonne-fichier[data-telecharger]:hover { background: var(--accent-doux); }
/* Jauge d espace */
.projet-tete-jauge { flex-wrap: wrap; }
.projet-tete-jauge > div:not(.jauge) { flex: 1 1 22rem; }
.jauge { flex: 0 1 22rem; margin-left: auto; align-self: center; }
.jauge-ligne { display: flex; align-items: center; gap: .75rem; }
.jauge-svg { flex: 1; height: .7rem; display: block; }
.jauge-fond { fill: var(--trait); }
.jauge-autres { fill: color-mix(in srgb, var(--accent) 35%, var(--surface)); }
.jauge-projet { fill: var(--accent); }
.jauge-alerte .jauge-projet, .jauge-alerte .jauge-autres { fill: #c77700; }
.jauge-critique .jauge-projet, .jauge-critique .jauge-autres { fill: var(--alerte); }
.jauge-pct { font-family: var(--mono); font-weight: 600; font-size: 1rem; min-width: 3.2rem; text-align: right; }
.jauge-legende { margin: .35rem 0 0; font-size: .82rem; color: var(--encre-douce); }
.pastille-projet, .pastille-autres { display: inline-block; width: .6rem; height: .6rem; border-radius: 50%; margin: 0 .3rem 0 .1rem; vertical-align: baseline; }
.pastille-projet { background: var(--accent); }
.pastille-autres { background: color-mix(in srgb, var(--accent) 35%, var(--surface)); margin-left: .6rem; }

/* ------------------------------------------------------------ v0.11 */
.outils { align-items: center; }
.outil-droite { margin-left: auto; }
.depot-zone { gap: .5rem; }
.ajouter { position: relative; }
.ajouter > summary { list-style: none; cursor: pointer; }
.ajouter > summary::-webkit-details-marker { display: none; }
.ajouter-menu { position: absolute; left: 50%; transform: translateX(-50%); top: calc(100% + .35rem); z-index: 6; display: grid; min-width: 12rem; padding: .35rem; background: var(--surface); border: 1px solid var(--trait-fort); border-radius: var(--rayon); box-shadow: 0 6px 20px rgb(0 0 0 / .12); }
.ajouter-menu label { padding: .5rem .7rem; border-radius: 6px; cursor: pointer; font-weight: 600; text-align: left; }
.ajouter-menu label:hover { background: var(--accent-doux); }
.sans-cible select { opacity: .5; }
.notif { position: fixed; top: 1rem; right: 1rem; z-index: 60; display: flex; align-items: flex-start; gap: .75rem; max-width: min(28rem, calc(100vw - 2rem)); margin: 0; box-shadow: 0 8px 28px rgb(0 0 0 / .16); transition: opacity .3s, transform .3s; }
.notif.partie { opacity: 0; transform: translateY(-.5rem); }
.notif span { flex: 1; }
.notif-fermer { font: inherit; font-size: 1.25rem; line-height: 1; background: none; border: 0; color: inherit; cursor: pointer; padding: 0 .2rem; }
.notif.succes { background: color-mix(in srgb, #1a7f4b 12%, var(--surface)); }
.notif.alerte { background: var(--alerte-fond); }

/* ------------------------------------------------------------ v0.12 : projets termines */
.titre-section { font-size: 1.15rem; margin: 2.25rem 0 .9rem; color: var(--encre-douce); }
.tuile-echue { opacity: .8; border-style: dashed; }
.bandeau-alerte { margin: 0 0 1.5rem; padding: .9rem 1.1rem; border-left: 4px solid var(--alerte); background: var(--alerte-fond); color: var(--encre); border-radius: var(--rayon); }
.bandeau-alerte strong { color: var(--alerte); }

/* ------------------------------------------------------------ v0.13 : renommage, alertes */
.ancien-nom { font-family: var(--texte); font-size: .5em; font-weight: 400; color: var(--encre-douce); letter-spacing: 0; white-space: nowrap; }
.tuile-titre .ancien-nom { font-size: .72em; display: inline-block; }
.projet-tete h1 { display: flex; align-items: baseline; flex-wrap: wrap; gap: .2rem .6rem; }
.crayon { position: relative; display: inline-block; font-size: 1rem; }
.crayon > summary { list-style: none; cursor: pointer; padding: .3rem; border-radius: var(--rayon); color: var(--encre-douce); line-height: 0; }
.crayon > summary::-webkit-details-marker { display: none; }
.crayon > summary:hover, .crayon[open] > summary { background: var(--accent-doux); color: var(--accent-texte); }
.crayon-panneau { position: absolute; left: 0; top: calc(100% + .4rem); z-index: 20; width: min(34rem, 88vw); padding: 1.2rem; background: var(--surface); border: 1px solid var(--trait-fort); border-radius: var(--rayon-tuile); box-shadow: 0 10px 30px rgb(0 0 0 / .14); font-family: var(--texte); font-weight: 400; letter-spacing: 0; }
.crayon-titre { font-family: var(--titres); font-weight: 700; font-size: 1.15rem; margin: 0; }
.alertes { border: 1px solid var(--trait); border-radius: var(--rayon); padding: .9rem 1rem; margin: 0; display: grid; gap: .8rem; }
.alertes legend { font-weight: 600; padding: 0 .35rem; }
.alertes-reglages { display: grid; gap: .8rem; }
.horaires { display: grid; gap: .5rem; }
.horaires-titre { font-weight: 600; font-size: .95rem; }
.horaires-liste { display: flex; flex-wrap: wrap; gap: .5rem; }
.horaire { display: inline-flex; align-items: center; border: 1px solid var(--trait-fort); border-radius: var(--rayon); background: var(--surface); }
.horaire input { font: inherit; border: 0; background: transparent; color: var(--encre); padding: .4rem .5rem; }
.horaire-retirer { border: 0; background: none; color: var(--encre-douce); font-size: 1.1rem; padding: 0 .5rem; cursor: pointer; }
.horaire-libre { display: none; }
.horaire-ajouter { justify-self: start; }

/* ------------------------------------------------------------ v0.14 : administration, annonces, nouveautes */
[hidden] { display: none !important; }
.tuile { position: relative; }
.pastille-new { position: absolute; top: .7rem; right: .7rem; padding: .12rem .5rem; border-radius: 999px; background: var(--accent); color: #fff; font-size: .72rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.annonces { position: relative; margin: 0 0 1.5rem; padding: .85rem 3rem .85rem 1.1rem; border-left: 4px solid var(--accent); background: var(--accent-doux); border-radius: var(--rayon); }
.annonces ul { margin: 0; padding: 0; list-style: none; display: grid; gap: .45rem; }
.annonce a { color: var(--encre); text-decoration: none; }
.annonce a:hover { text-decoration: underline; }
.annonce-alerte a::before { content: "⏳ "; }
.annonce-info a::before { content: "👤 "; }
.annonces-fermer { position: absolute; top: .5rem; right: .6rem; border: 0; background: none; font-size: 1.3rem; line-height: 1; color: var(--encre-douce); cursor: pointer; }
.barre-logo { height: 2rem; width: auto; max-width: 12rem; display: block; object-fit: contain; }
.logo-apercu { margin: .3rem 0; }
.logo-apercu .barre-logo { height: 3rem; }
.crayon-tete { display: flex; align-items: center; justify-content: space-between; }
.crayon-fermer { border: 0; background: none; font-size: 1.4rem; line-height: 1; color: var(--encre-douce); cursor: pointer; padding: 0 .25rem; }
.crayon-panneau .actions { display: flex; align-items: center; gap: 1rem; }
.onglets { display: flex; gap: .3rem; flex-wrap: wrap; margin: 0 0 1.25rem; border-bottom: 1px solid var(--trait); }
.onglets a { padding: .6rem 1rem; color: var(--encre-douce); text-decoration: none; font-weight: 600; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.onglets a[aria-current="page"] { color: var(--accent-texte); border-bottom-color: var(--accent); }
.sous-ligne { display: block; font-size: .85rem; color: var(--encre-douce); }
.admin-actions { text-align: right; white-space: nowrap; }
.admin-actions form, .admin-actions details { display: inline-block; margin-left: .75rem; vertical-align: middle; }
.confirmer { position: relative; }
.confirmer > summary { list-style: none; cursor: pointer; }
.confirmer > summary::-webkit-details-marker { display: none; }
.confirmer-panneau { position: absolute; right: 0; top: calc(100% + .35rem); z-index: 15; width: min(24rem, 80vw); padding: 1rem; display: grid; gap: .6rem; text-align: left; white-space: normal; background: var(--surface); border: 1px solid var(--trait-fort); border-radius: var(--rayon); box-shadow: 0 8px 26px rgb(0 0 0 / .14); }
.confirmer-panneau p { margin: 0; }
.confirmer-panneau form { display: grid; gap: .55rem; margin: 0; }
.confirmer-panneau input[type="text"], .confirmer-panneau select { font: inherit; padding: .45rem .6rem; border: 1px solid var(--trait-fort); border-radius: var(--rayon); background: var(--surface); color: var(--encre); width: 100%; }
.bouton-danger { background: var(--alerte); }
.pastille-neutre { background: var(--fond); color: var(--encre-douce); }
.pastille-attente { background: #fff3d6; color: #8a5a00; }
.pastille-alerte { background: var(--alerte-fond); color: var(--alerte); }
.journal code { font-family: var(--mono); font-size: .8rem; }
.journal-detail { max-width: 28rem; overflow-wrap: anywhere; }
.ligne-refus td { background: color-mix(in srgb, var(--alerte) 6%, transparent); }
.jauge-large { max-width: 40rem; margin: 0; }

/* ------------------------------------------------------------ v0.15 : compte, double authentification, croix */
.barre-qui { color: var(--encre); text-decoration: none; font-weight: 600; }
.barre-qui:hover, .barre-qui[aria-current] { color: var(--accent-texte); text-decoration: underline; text-underline-offset: .2em; }
.panneau-fermer { position: absolute; top: .35rem; right: .45rem; border: 0; background: none; font-size: 1.3rem; line-height: 1; color: var(--encre-douce); cursor: pointer; padding: .1rem .3rem; border-radius: 6px; z-index: 2; }
.panneau-fermer:hover { background: var(--accent-doux); color: var(--encre); }
.confirmer-panneau, .ajouter-menu, .outil-form { position: relative; }
.confirmer-panneau { padding-top: 1.9rem; }
.ajouter-menu { padding-top: 1.8rem; }
details.outil > .outil-form { padding-right: 2rem; }
.champ-tete { display: flex; justify-content: space-between; align-items: baseline; font-weight: 600; }
.couleur-ligne { display: flex; align-items: center; gap: .75rem; }
input[type="color"] { width: 4.5rem; height: 2.6rem; padding: .2rem; border: 1px solid var(--trait-fort); border-radius: var(--rayon); background: var(--surface); cursor: pointer; flex: none; }
.couleur-ligne code { font-family: var(--mono); color: var(--encre-douce); }
.champ-code { font-family: var(--mono) !important; font-size: 1.5rem !important; letter-spacing: .35em; text-align: center; max-width: 14rem; }
.formulaire-ligne { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; align-items: end; }
.formulaire-ligne .actions { grid-column: 1 / -1; }
@media (max-width: 640px) { .formulaire-ligne { grid-template-columns: 1fr; } }
.mfa-actions { display: flex; flex-wrap: wrap; gap: .75rem 1.25rem; align-items: center; margin: .5rem 0 1rem; }
.sous-titre { font-size: 1rem; margin: 1.5rem 0 .3rem; }
.qr { width: 13rem; max-width: 70vw; margin: 1rem 0; padding: .6rem; background: #fff; border: 1px solid var(--trait); border-radius: var(--rayon); }
.qr svg { display: block; width: 100%; height: auto; }
.secret { font-family: var(--mono); background: var(--accent-doux); padding: .15rem .4rem; border-radius: 6px; }
.etapes { padding-left: 1.2rem; display: grid; gap: .3rem; }
.codes-secours { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr)); gap: .5rem; }
.codes-secours code { display: block; text-align: center; font-family: var(--mono); font-size: 1.1rem; padding: .5rem; border: 1px dashed var(--trait-fort); border-radius: var(--rayon); }

/* ------------------------------------------------------------ v0.16 : pages legales, pied, reglages */
.pied-legal { display: flex; flex-wrap: wrap; justify-content: center; gap: .4rem 1.4rem; padding: 2rem 1rem 2.5rem; font-size: .85rem; color: var(--encre-douce); }
.pied-legal a { color: var(--encre-douce); }
.pied-legal a:hover { color: var(--accent-texte); }
.contenu .pied-legal { padding: 1.5rem 0 0; }
.page-legale { max-width: 46rem; }
.legal h1 { margin-bottom: 1.5rem; }
.legal h2 { font-size: 1.15rem; margin: 1.8rem 0 .5rem; }
.legal p { line-height: 1.65; margin: 0 0 .8rem; }
.legal-version { margin-top: 2rem !important; color: var(--encre-douce); font-size: .9rem; }
.barre-reglages { display: inline-flex; align-items: center; padding: .3rem; border-radius: var(--rayon); color: var(--encre-douce); margin-left: .15rem; }
.barre-reglages:hover, .barre-reglages[aria-current] { background: var(--accent-doux); color: var(--accent-texte); }
.barre-reglages .ico { width: 1.25rem; height: 1.25rem; }

/* ------------------------------------------------------------ v0.17 */
.titre-ligne { display: flex; align-items: baseline; flex-wrap: wrap; gap: .4rem 1rem; margin-bottom: .6rem; }
.titre-ligne h2 { margin: 0; }
.pastille-ok { background: color-mix(in srgb, #1a7f4b 14%, var(--surface)); color: #146c3f; }

/* v0.24 : en colonne (ecran etroit), une base flexible devient une HAUTEUR : les 22rem de
   l en-tete et de la jauge creusaient de grands blancs sur iPhone (recette du 12/11). */
@media (max-width: 560px) {
  .projet-tete > *, .projet-tete-jauge > div:not(.jauge), .projet-tete .jauge { flex: 0 0 auto; width: 100%; margin-left: 0; }
  .projet-tete { gap: 1rem; margin-bottom: 1.25rem; }
  .outils { flex-wrap: wrap; }
  .outil-droite { margin-left: 0; }
}
/* Nombre de participants sur les tuiles. */
.tuile-participants { display: inline-flex; align-items: center; gap: .3rem; margin-top: .35rem; font-size: .85rem; color: var(--encre-douce); }
.tuile-participants .icone-personnes { flex: 0 0 auto; }
/* Rafraichir et Tout telecharger, groupes a droite ; Quitter en lien discret. */
.outil-droite { display: inline-flex; gap: .5rem; flex-wrap: wrap; }
.purge-reglage { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; font-size: .9rem; } .purge-reglage select { font: inherit; padding: .3rem .5rem; } .bouton-petit { padding: .35rem .8rem; font-size: .9rem; }
@media (max-width: 560px) { .projet-tete > *:first-child { width: auto; } }
/* Corbeille du proprietaire (v0.25), un peu a droite du crayon, en rouge. */
.corbeille { margin-left: .4rem; }
.corbeille > summary { color: var(--alerte); }
.corbeille > summary .ico-trait { stroke: var(--alerte); }
.corbeille > summary:hover { background: color-mix(in srgb, var(--alerte) 12%, transparent); }
