/* Portail en ligne : connexion et code reçu par e-mail (planche A du 14/11/2026, maquettes/portail/connexion.html),
   barre du compte dans l'outil. Chargée après /static/style.css, dont elle reprend les jetons (--encre, --bleu,
   --mgo-bleu, --mgo-vert, --fond, --ombre) et les classes .btn, .erreur. */

/* Boîte de connexion : blanche, sur le dégradé MGO de la page */
.porte { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 16px; }
.porte-boite { width: 100%; max-width: 360px; background: var(--blanc); border-radius: 16px; box-shadow: var(--ombre); padding: 26px 24px 22px; }
.porte-boite > img { display: block; width: 96px; height: 72px; object-fit: contain; margin: 0 auto 8px; }
.porte-boite h1 { text-align: center; font-size: 22px; margin: 0 0 18px; color: var(--bleu); }
.porte-boite form { margin: 0; }
.porte-boite label { display: block; font-size: 13px; color: var(--gris); margin: 0 0 4px; }
.porte-boite input:not([type=hidden]) { display: block; width: 100%; font: inherit; font-size: 15px; color: var(--encre); padding: 10px 12px; margin: 0 0 14px; border: 1px solid var(--filet); border-radius: 10px; background: #FBFDFE; }
.porte-boite input:focus-visible { outline: 2px solid var(--bleu); outline-offset: 1px; border-color: var(--bleu); }
.porte-boite input.code { text-align: center; font-size: 24px; font-weight: 700; letter-spacing: .4em; padding-left: calc(12px + .4em); font-variant-numeric: tabular-nums; }
.porte-boite .btn { width: 100%; justify-content: center; font-size: 15px; padding: 11px 16px; margin-top: 4px; }
.porte-boite .aide { text-align: center; color: var(--gris); font-size: 14px; margin: 0 0 16px; }
.porte-boite .erreur { margin: 0 0 16px; font-size: 14px; }
.porte-boite .info { margin: 0 0 16px; font-size: 14px; border: 1px solid var(--mgo-vert); background: #F3F8EC; border-radius: 10px; padding: 12px 14px; }
.porte-boite .petit { text-align: center; font-size: 13px; margin: 14px 0 0; }
.porte-boite .petit a, .porte-boite .lien { color: var(--lien); }
.porte-boite .indesirables { color: var(--gris); }
.porte-boite .indesirables + .petit { margin-top: 4px; } /* « Renvoyer le code » juste sous « Pas reçu ? » */
.porte-boite .lien { background: none; border: 0; padding: 0; font: inherit; text-decoration: underline; cursor: pointer; }
.porte-boite .lien:focus-visible { outline: 2px solid var(--bleu); outline-offset: 2px; }
.porte-signe { margin: 18px 0 0; font-size: 12px; color: var(--gris); }

/* Barre du compte, à droite de la barre du haut de l'outil */
.compte { display: flex; align-items: center; gap: 10px; }
.compte .av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; flex: none; color: var(--encre); font-weight: 800; font-size: 12px; letter-spacing: .03em; background: linear-gradient(135deg, var(--mgo-bleu), var(--mgo-vert)); }
.compte .nom { font-size: 13px; color: var(--gris); white-space: nowrap; }
.compte form { margin: 0; }
.compte .btn { font-size: 12px; padding: 6px 12px; }

/* Menu « Mes outils » : <details> natif, une liste qui s'ouvre sous le bouton */
.outils { position: relative; }
.outils summary { list-style: none; cursor: pointer; font-size: 13px; font-weight: 600; color: var(--encre); padding: 6px 12px; border: 1px solid var(--filet); border-radius: 999px; background: var(--blanc); }
.outils summary::-webkit-details-marker { display: none; }
.outils summary::after { content: "▾"; margin-left: 6px; font-size: 11px; }
.outils[open] summary { border-color: var(--bleu); }
.outils summary:focus-visible, .outils a:focus-visible { outline: 2px solid var(--bleu); outline-offset: 2px; }
.outils ul { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; min-width: 240px; margin: 0; padding: 6px; list-style: none; background: var(--blanc); border: 1px solid var(--filet); border-radius: 12px; box-shadow: var(--ombre); }
.outils li a { display: block; padding: 9px 12px; border-radius: 8px; font-size: 14px; color: var(--encre); text-decoration: none; }
.outils li a:hover { background: var(--sable); }

/* Tableau de bord : une tuile par outil (planche A du 14/11, maquettes/portail/tableau-de-bord.html) */
.sprite { position: absolute; }
.bonjour { font-size: 22px; font-weight: 700; color: var(--bleu); margin: 0 0 2px; letter-spacing: -.01em; }
.date { color: var(--gris); font-size: 13px; margin: 0 0 18px; }
.tuiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; }
.tuile { background: var(--blanc); border-radius: 16px; box-shadow: var(--ombre); padding: 16px; display: flex; flex-direction: column; gap: 10px; min-height: 168px; }
.tuile .ic { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--mgo-bleu), var(--bleu)); }
.tuile.admin .ic { background: linear-gradient(135deg, #8a9aa6, var(--encre)); }
.tuile h2 { font-size: 16px; margin: 0; }
.tuile .k { font-size: 13.5px; color: var(--gris); }
.tuile .k b { color: #C2410C; font-size: 15px; }
.tuile .k .ok { color: var(--vert, #467A1C); }
.tuile .ouvrir { margin-top: auto; align-self: flex-start; font-size: 13px; font-weight: 600; border-radius: 999px; padding: 6px 13px; background: var(--encre); color: #fff; text-decoration: none; }
.tuile .ouvrir:focus-visible { outline: 2px solid var(--bleu); outline-offset: 2px; }
svg.i { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }

@media (max-width: 720px) {
  .compte { margin-left: auto; }
  .outils ul { right: auto; left: 0; } /* le bouton est au milieu de la ligne : la liste s'ouvre vers la droite, dans l'écran */ /* la signature, qui poussait la barre à droite, est masquée */
  .compte .nom { display: none; }
}

/* Choisir son mot de passe : l'adresse du compte, en lecture seule (aide les gestionnaires de mots de passe) */
.porte-boite input[readonly] { color: var(--gris); background: var(--sable); }

/* Comptes et accès (planche C du 14/11, maquettes/portail/comptes-c.html) : tout est préfixé .acces, la page de l'outil
   a déjà ses propres .liste, .etat, .note, .champ et .carte. */
.page.acces { max-width: 1240px; padding: 24px 16px 48px; }
.acces svg.i { width: 18px; height: 18px; stroke-width: 1.9; }
.acces .tete { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-bottom: 18px; }
.acces .tete h1 { font-size: 24px; margin: 0; letter-spacing: -.02em; color: var(--bleu); }
.acces .tete .sous { color: var(--gris); font-size: 14px; flex-basis: 100%; margin: -6px 0 0; order: 3; }
.acces .tete .push { margin-left: auto; order: 2; }
.acces .info, .acces .erreur { margin: 0 0 16px; font-size: 14px; border-radius: 10px; padding: 12px 14px; }
.acces .info { border: 1px solid var(--mgo-vert); background: #F3F8EC; }
.acces .carte { background: var(--blanc); border-radius: 16px; box-shadow: var(--ombre); padding: 18px; margin: 0; min-width: 0; }
.acces .carte h2 { font-size: 16px; margin: 0; }
.acces .btn { gap: 7px; font-size: 13.5px; border: 2px solid var(--encre); background: var(--encre); color: #fff; padding: 6px 14px; }
.acces .btn.gd { font-size: 15px; padding: 10px 20px; }
.acces .btn.sec { background: var(--blanc); color: var(--encre); }
.acces .btn.dng { background: var(--blanc); color: var(--ecart); border-color: var(--ecart); }
.acces .btn[disabled] { opacity: .45; cursor: not-allowed; }
.acces .btn:focus-visible, .acces input:focus-visible { outline: 3px solid var(--mgo-bleu); outline-offset: 2px; }
.acces .acts { display: flex; flex-wrap: wrap; gap: 6px; grid-column: 2 / -1; }
.acces .acts form { margin: 0; }
.acces .etat { display: inline-flex; align-items: center; gap: 5px; margin: 0; font-size: 12.5px; font-weight: 700; border-radius: 999px; padding: 2px 10px 2px 7px; border: 2px solid; white-space: nowrap; }
.acces .etat svg.i { width: 14px; height: 14px; stroke-width: 2.2; }
.acces .etat.actif { color: var(--vert); border-color: var(--vert); background: #F1F8E9; }
.acces .etat.invite { color: var(--lien); border-style: dashed; background: #EEF7FB; }
.acces .etat.bloque { color: #fff; border-color: var(--ecart); background: var(--ecart); }
.acces .etat.desactive { color: var(--gris); border-color: #9AA5AD; background: repeating-linear-gradient(135deg, #F1F3F4 0 6px, #E6E9EB 6px 12px); text-decoration: line-through; text-decoration-thickness: 1px; }
.acces .badge { display: inline-block; font-size: 11.5px; font-weight: 700; letter-spacing: .02em; color: #fff; background: var(--bleu); border-radius: 6px; padding: 1px 7px; vertical-align: 1px; }
.acces .badge.adm { background: var(--sable); color: var(--bleu); border: 1px solid #B8D3DF; }
.acces .chips { display: flex; flex-wrap: wrap; gap: 4px; }
.acces .chip { font-size: 12.5px; background: var(--sable); color: var(--bleu); border-radius: 8px; padding: 1px 8px; }
.acces .chip.vide { background: transparent; color: var(--gris); font-style: italic; padding: 0; }
.acces .mute { color: var(--gris); font-size: 13px; }
.acces .nom { font-weight: 700; }
.acces .note { display: block; width: auto; min-height: 0; margin: 0; padding: 0; border: 0; background: none; font-size: 12.5px; color: var(--gris); }
.acces .champ { display: flex; flex-direction: column; gap: 3px; margin: 0; font-size: 13px; font-weight: 600; color: var(--bleu); min-width: 0; }
.acces .champ input { font: inherit; font-size: 15px; font-weight: 400; color: var(--encre); border: 2px solid var(--filet); border-radius: 10px; padding: 8px 10px; background: var(--blanc); width: 100%; min-width: 0; }
.acces .champ input:focus { border-color: var(--mgo-bleu); }
.acces .cases { border: 0; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; font-size: 14px; min-width: 0; }
.acces .cases legend { font-size: 13px; font-weight: 600; color: var(--bleu); padding: 0; margin-bottom: 4px; }
.acces .cases label { display: flex; align-items: center; gap: 8px; font-weight: 400; color: var(--encre); }
.acces .cases input { width: 18px; height: 18px; margin: 0; accent-color: var(--encre); flex: none; }
/* Nouveau compte : prénom, nom, puis l'adresse, plus longue ; la fiche ouverte : prénom et nom seulement.
   Pas « .deux » : style.css en a déjà un (les deux volets de la page du lot, hauteur de l'écran). */
.acces .gform { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 2fr); gap: 12px; }
.acces .gform.identite { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 640px; }
.acces .gcases { display: flex; flex-wrap: wrap; gap: 12px 40px; margin: 14px 0; align-items: flex-start; }
.acces .gbtn { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.acces .hautform { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.acces .groupe { margin-top: 22px; }
.acces .groupe > h2 { display: flex; align-items: center; gap: 8px; font-size: 15px; margin: 0 0 8px; color: var(--bleu); }
.acces .groupe > h2 .n { font-size: 12px; background: var(--encre); color: #fff; border-radius: 999px; padding: 0 8px; }
.acces .groupe.alerte > h2 { color: var(--ecart); }
.acces .groupe.alerte > h2 .n { background: var(--ecart); }
.acces .liste { background: var(--blanc); border: 0; border-radius: 16px; box-shadow: var(--ombre); padding: 2px 18px; overflow: visible; max-height: none; }
.acces .lg { display: grid; grid-template-columns: 40px minmax(0, 1.6fr) minmax(0, 1.2fr) 112px; gap: 8px 14px; align-items: center; padding: 12px 0; border-top: 1px solid var(--filet); scroll-margin-top: 16px; }
.acces .lg:first-child { border-top: 0; }
.acces .lg .av { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 13px; background: linear-gradient(135deg, var(--mgo-bleu), var(--mgo-vert)); }
.acces .lg .av.gr { background: linear-gradient(135deg, #8A9AA6, var(--encre)); }
.acces .lg .qui { min-width: 0; }
.acces .lg .qui .mute { display: block; overflow-wrap: anywhere; }
.acces .lg .dc { font-size: 13px; color: var(--gris); margin-top: 2px; }
.acces .lg .mod { grid-column: 2 / -1; border-top: 1px dashed var(--filet); padding-top: 12px; margin: 0; }
.acces .lg .mod .erreur { margin-top: 0; }
.acces .tout { margin: 10px 0 0; font-size: 13px; }
.acces .tout a { color: var(--lien); }
.acces .jour { list-style: none; margin: 0; padding: 0; }
.acces .jour li { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 9px 0; border-top: 1px solid var(--filet); font-size: 14px; }
.acces .jour li:first-child { border-top: 0; }
.acces .jour .q { font-weight: 700; }
.acces .jour .t { color: var(--gris); font-size: 12.5px; white-space: nowrap; grid-row: 1 / span 2; grid-column: 2; align-self: center; text-align: right; }
@media (max-width: 1100px) {
  .acces .gform { grid-template-columns: 1fr 1fr; }
  .acces .gform > .champ:nth-child(3) { grid-column: 1 / -1; } /* l'adresse sur toute la ligne : pas de trou */
}
@media (max-width: 760px) {
  .acces .tete h1 { font-size: 21px; }
  .acces .jour li { grid-template-columns: 1fr; }
  .acces .jour .t { grid-row: auto; grid-column: 1; text-align: left; }
}
@media (max-width: 620px) {
  .acces .gform, .acces .gform.identite { grid-template-columns: 1fr; }
  .acces .lg { grid-template-columns: 40px minmax(0, 1fr); }
  .acces .lg .et { grid-column: 2; }
  .acces .lg .out, .acces .lg .acts, .acces .lg .mod { grid-column: 1 / -1; }
  .acces .liste { padding: 2px 14px; }
}
