/* LES OUTILS DU GÉRANT (chantier F, 01/10/2026 ; FUSION-OUTILS-GERANT.md ; D-OG12, D-OG17, D-OG18) — « Donner des rues » et « Codes QR ».
   Le style clair (DESIGN § 2.6 ; FUSION-STYLE) : du blanc, des traits fins, une seule police, le NOIR pour l'action, l'ORANGE pour
   ce qu'on choisit, le vert pour ce qui est déjà à elle, le gris pour ce qui est à quelqu'un d'autre. Cibles de 48 px, 14 px au
   moins pour ce qu'on lit ; « moins de mouvement » : rien ne bouge.
   Le 02/10 (D-ST4), le style clair est retiré : le look jeu revient (ses jetons de base.css, clair ou sombre) ; les deux jetons que
   ces outils prenaient du style clair (--r-plein, --bord) reçoivent ici leur valeur du jeu. */
:root { --r-plein: 999px; --bord: var(--ligne); }

/* la ligne d'entrée (Terrain du Gérant, Mon équipe, sa fiche) : une icône ronde, comme les autres lignes de l'app */
.og-ico { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-plein); background: var(--surface-2); color: var(--encre); }
.og-ligne { margin-bottom: 12px; }

/* — à qui : la rangée des personnes (comme la rangée des stories) — */
.og-gens { display: flex; gap: 10px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity;
  margin: -6px -16px 4px; padding: 6px 16px 8px; scrollbar-width: none; }
.og-gens::-webkit-scrollbar { display: none; }
.og-p { flex: none; display: flex; flex-direction: column; align-items: center; gap: 6px; width: 72px; min-height: 96px; padding: 2px 0;
  border: 0; background: transparent; color: var(--encre); font: inherit; cursor: pointer; scroll-snap-align: start; }
.og-p-av { position: relative; display: inline-grid; place-items: center; padding: 3px; border-radius: var(--r-plein);
  box-shadow: 0 0 0 2px transparent; transition: box-shadow .15s ease, transform .12s ease; }
.og-p[aria-pressed="true"] .og-p-av { box-shadow: 0 0 0 2.5px var(--accent); }
.og-p:active .og-p-av { transform: scale(.94); }
.og-p:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 12px; }
.og-p-z { position: absolute; right: 3px; bottom: 7px; width: 14px; height: 14px; border-radius: var(--r-plein); background: var(--vert); border: 2.5px solid var(--surface); }
.og-p-nm { max-width: 72px; font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.og-p[aria-pressed="true"] .og-p-nm { font-weight: 800; }

/* le jour (D-OG18) : on donne pour AUJOURD'HUI */
.og-jour { margin: 0 0 6px; color: var(--gris); font-size: 14px; font-weight: 600; }

/* ses rues d'aujourd'hui (le trait vert de la carte) ; « Reprendre » (D-OG17) : un contour discret, jamais le bouton noir */
.og-sienne { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; color: var(--gris); font-size: 14px; min-width: 0; min-height: 48px; }
.og-sienne-n { flex: none; white-space: nowrap; }
.og-reprendre { flex: none; margin-left: auto; min-height: 48px; padding: 0 16px; border: 1px solid var(--bord); border-radius: var(--r-plein);
  background: var(--surface); color: var(--encre); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.og-reprendre:active { background: var(--surface-2); }
.og-sienne > span[data-libre] { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.og-sienne-p { flex: none; width: 18px; height: 5px; border-radius: 3px; background: var(--vert); }

/* — « Une rue » — */
.og-cherche { position: relative; margin: 0 0 8px; }
.og-loupe { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); display: flex; color: var(--gris); pointer-events: none; }
.og-q { width: 100%; height: 48px; padding: 0 14px 0 44px; border: 1px solid var(--ligne); border-radius: 12px; background: var(--surface-2);
  color: var(--encre); font: inherit; font-size: 16px; -webkit-appearance: none; appearance: none; }
.og-q::placeholder { color: var(--gris); }
.og-q:focus { outline: none; border-color: var(--encre); background: var(--surface); }
.og-q::-webkit-search-cancel-button { -webkit-appearance: none; }
.og-res-l { list-style: none; margin: 0 0 10px; padding: 0; border: 1px solid var(--ligne); border-radius: 14px; overflow: hidden; background: var(--surface); }
.og-res-l li + li { border-top: 1px solid var(--ligne); }
.og-res-b { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 52px; padding: 6px 10px 6px 14px; border: 0; background: transparent;
  color: var(--encre); font: inherit; text-align: left; cursor: pointer; }
.og-res-b:active { background: var(--surface-2); }
.og-res-b:disabled { opacity: .5; cursor: default; }
.og-res-t { flex: 1 1 auto; min-width: 0; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.og-res-s { flex: none; color: var(--gris); font-size: 14px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.og-res-plus { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: var(--r-plein); background: var(--surface-2); color: var(--encre); }
.og-res-b[aria-pressed="true"] .og-res-plus { background: var(--accent); color: var(--sur-accent); }
.og-res-vide { margin: 0 0 10px; color: var(--gris); font-size: 14px; }

/* — la carte — */
.og-carte { height: 44vh; min-height: 260px; max-height: 440px; }

/* — ce qu'on donne — */
.og-sel { min-height: 4px; }
.og-sel-l { margin: 2px 0 0; }
.og-sel-pt { display: block; width: 12px; height: 12px; margin: 0 6px; border-radius: var(--r-plein); background: var(--accent); box-shadow: 0 0 0 4px var(--accent-doux); }
.og-x { display: grid; place-items: center; width: 48px; height: 48px; margin-right: -8px; border: 0; border-radius: var(--r-plein); background: transparent; color: var(--gris); cursor: pointer; }
.og-x:active { background: var(--surface-2); }
.og-bas .nb:disabled { opacity: .42; box-shadow: none; }

/* — un bout : ses côtés, ses numéros, ses tours (d'un toucher chacun) — */
.og-feuille { padding-bottom: 6px; }
.og-cote { margin: 0 0 16px; }
.og-cote-t { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 0 0 8px; }
.og-cote-t b { font-size: 15px; font-weight: 800; }
.og-tout { min-height: 48px; padding: 0 16px; border: 1px solid var(--bord); border-radius: var(--r-plein); background: var(--surface); color: var(--encre);
  font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.og-nums { display: flex; flex-wrap: wrap; gap: 8px; }
.og-num { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 64px; min-height: 48px; padding: 0 12px;
  border: 1px solid var(--bord); border-radius: 12px; background: var(--surface); color: var(--encre); font: inherit; font-size: 15px; font-weight: 700;
  font-variant-numeric: tabular-nums; cursor: pointer; transition: background-color .12s ease, color .12s ease, transform .1s ease; }
.og-num[aria-pressed="true"] { background: var(--encre); border-color: var(--encre); color: var(--surface); }
.og-num:active { transform: scale(.96); }
.og-num:disabled { opacity: .38; text-decoration: line-through; cursor: default; }
.og-num small { font-size: 14px; font-weight: 600; opacity: .85; }
/* « OK » reste sous le pouce, même sur un long bout de rue (60 numéros) */
/* (le corps de la feuille a 20 px de rembourrage en bas : le bloc descend jusqu'au bord, rien ne passe dessous) */
.og-feuille-b { position: sticky; bottom: -20px; z-index: 1; display: grid; gap: 10px; margin: 4px -4px -20px; padding: 10px 4px calc(24px + env(safe-area-inset-bottom, 0px)); background: linear-gradient(to bottom, transparent, var(--surface) 12px); }

/* — les codes QR : le code et l'aperçu de son QR, marque par marque — */
.og-qr { padding: 12px 0 14px; border-bottom: 1px solid var(--ligne); }
.og-qr-m { display: block; margin: 0 0 8px; font-size: 15px; font-weight: 800; }
.og-qr-l { display: flex; align-items: center; gap: 12px; }
.og-qr-c { flex: 1 1 auto; min-width: 0; height: 52px; padding: 0 14px; border: 1px solid var(--bord); border-radius: 12px; background: var(--surface);
  color: var(--encre); font: inherit; font-size: 18px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; font-variant-numeric: tabular-nums; }
.og-qr-c::placeholder { text-transform: none; letter-spacing: 0; font-weight: 500; color: var(--gris); }
.og-qr-c:focus { outline: 2px solid var(--encre); outline-offset: 0; border-color: var(--encre); }
.og-qr--mauvais .og-qr-c { border-color: var(--ambre); }
.og-qr-img { flex: none; display: grid; place-items: center; width: 88px; height: 88px; padding: 6px; border: 1px solid var(--ligne); border-radius: 12px; background: #FFFFFF; }
.og-qr-img canvas, .og-qr-img img { width: 100% !important; height: 100% !important; image-rendering: pixelated; }
.og-qr-img--vide { background: var(--surface-2); }
/* code-du-leader (13/10) : sans code à lui, celui de son leader (prêté) : son QR pâli, la petite ligne dessous */
.og-qr-pret { margin: 6px 0 0; font-size: 14px; font-weight: 600; color: var(--gris); }
.og-qr:not(.og-qr--pret) .og-qr-pret { display: none; }
.og-qr--pret .og-qr-img { opacity: .5; }
.og-codes > .nb { margin-top: 18px; }

/* « C'est fait », après « Ajouter des personnes » (gerant.js · feuilleAjoutees) : « Texter » et le rond QR côte à côte, centrés,
   un espace entre eux ; « Texter » en pilule (le mot entier, jamais coupé « Text / er » dans un rond de 48 px : un défaut de main
   que ce chantier aurait doublé) */
.nv-ajoutees .nl-droite { display: flex; align-items: center; justify-content: flex-end; gap: 8px; max-width: none; }
.app--nova .nv-ajoutees .nv-texter { width: auto; min-width: 48px; padding: 0 16px; border-radius: var(--r-plein); font-size: 15px; font-weight: 700; white-space: nowrap; }

/* la tablette (iPad, Samsung) : la carte plus haute ; tout le bureau tient sur deux lignes (jamais coupé net au bord) */
@media (min-width: 700px) {
  .og-carte { height: 52vh; max-height: 560px; }
  .og-gens { gap: 12px 16px; flex-wrap: wrap; overflow-x: visible; }
}
@media (prefers-reduced-motion: reduce) {
  .og-p-av, .og-num { transition: none; }
  .og-p:active .og-p-av, .og-num:active { transform: none; }
}

/* ── chantier S (02/10, D-SM4 ; FUSION-HFF-SEMAINE.md) : LA SEMAINE — « Semaine · Aujourd'hui » (les segments d'avant le style clair,
   .nso--segments), « 🚪 N » sous chaque prénom (ambre : il lui en manquera avant la fin de la semaine), sa ligne « Sa semaine · 120 /
   600 · il reste 480 ». Les jetons de base.css d'avant le style clair seulement (le look jeu, D-ST4). */
.sm-modes { margin: 0 0 8px; }
.sm-reste { margin-top: -4px; font-size: 12px; font-weight: 700; color: var(--gris); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sm-reste--manque { color: var(--ambre-texte); }
.sm-sienne { flex-wrap: wrap; row-gap: 0; }
.sm-r { flex: none; white-space: nowrap; color: var(--encre); font-weight: 700; }
.sm-manque { flex: none; white-space: nowrap; padding: 2px 8px; border-radius: 999px; background: var(--ambre-doux); color: var(--ambre-texte); font-weight: 800; font-size: 13px; }
.sm-jour { margin-top: -4px; padding: 0 6px; border-radius: 999px; background: var(--ambre-doux); color: var(--ambre-texte); font-size: 11px; font-weight: 800; }
.og-p { min-height: 110px; }
.sm-gens { margin: 4px 0 12px; }
/* corrections du chantier S (D-SM6, D-SM20) : le passage (rues du jour, en gris) ; « Leur semaine » en tête de Mon équipe ; dans la
   carte d'une personne, « 🚪 il reste 480 · manque ven. » (ambre : il lui en manquera). Les jetons d'avant le style clair. */
.sm-reste--jour { color: var(--gris); font-weight: 600; }
/* D-TSC1-15 (la vérification de l'assemblage) : la ligne passe à la ligne — dans les cartes sur deux colonnes de la tablette, « Pas encore
   de portes cette … » était coupée */
.sm-me { display: block; margin-top: 2px; font-size: 13px; font-weight: 700; color: var(--gris); white-space: normal; overflow-wrap: anywhere; }
.sm-me--manque { color: var(--ambre-texte); }
/* REFAIRE LES PORTES (chantier 111) : « 🟠 170 » sous son prénom, « 🟠 170 à refaire » dans Sa semaine, ses absents qui lui restent (« Les enlever aussi ») —
   l'orange de « À relaper », à part du 1er nombre (les neuves) ; jamais une alerte */
:root { --sm-orange: #C2410C; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --sm-orange: #FDBA74; } }
:root[data-theme="dark"] { --sm-orange: #FDBA74; }
.sm-orange { margin-top: -4px; font-size: 12px; font-weight: 700; color: var(--sm-orange); white-space: nowrap; font-variant-numeric: tabular-nums; }
.sm-r--orange { color: var(--sm-orange); }
.og-absents { margin: 0; font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--encre); }
/* ── codes-postaux-ouverts (08/10, D-CPO1 à D-CPO6) : LES CODES POSTAUX — par quartier, chaque code (« H4C ») en grand, ses logements de
   blocs (🏢), ses portes (🚪), ce qui est fait (✓ %), son interrupteur (le même que la feuille des codes de Demain : .nv-inter,
   .nv-bascule) ; un quartier sans code ouvert, replié (un toucher l'ouvre). Le look jeu (les jetons de base.css), le moins de mots. */
.cp-resume { display: flex; align-items: baseline; gap: 8px; margin: 2px 2px 12px; color: var(--gris); font-size: 15px; font-variant-numeric: tabular-nums; }
.cp-resume b { color: var(--encre); font-family: var(--f-titre); font-size: 20px; font-weight: 800; }
.app--nova .cp-q { padding: 0; margin: 0 0 12px; overflow: hidden; }
.cp-q-tete { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 52px; padding: 10px 14px; border: 0; background: transparent; color: var(--encre); font: inherit; text-align: left; cursor: pointer; }
.cp-q-tete:disabled { cursor: default; opacity: 1; }
.cp-q-nom { flex: 1; min-width: 0; font-family: var(--f-titre); font-size: 19px; font-weight: 800; text-transform: uppercase; letter-spacing: .02em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cp-q-n { flex: none; font-weight: 800; font-variant-numeric: tabular-nums; }
.cp-q-b { flex: none; color: var(--gris); font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cp-q-v { flex: none; color: var(--gris); font-size: 14px; }
.cp-q--ferme .cp-q-nom { color: var(--gris); }
.cp-liste { border-top: 1px solid var(--ligne); }
.app--nova .cp-code { min-height: 64px; padding: 8px 14px; gap: 12px; }
.cp-c { flex: none; min-width: 58px; font-family: var(--f-titre); font-size: 26px; font-weight: 800; letter-spacing: .02em; line-height: 1; color: var(--encre); }
.app--nova .cp-code[aria-pressed="false"] .cp-c { color: var(--gris); }
.cp-n { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 14px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--encre); white-space: nowrap; }
.cp-fait { color: var(--vert); }
.app--nova .cp-code[aria-pressed="false"] .cp-n { color: var(--gris); }
.app--nova .cp-code[aria-pressed="false"] .cp-fait { color: var(--gris); }
.cp-t small { margin-top: 2px; font-size: 13px; }
.cp-code--occupe { opacity: .6; pointer-events: none; }
.cp-lien { margin: 10px 0 2px; }
/* la tuile « 📮 Codes postaux » : six outils au plus — 3 + 3 au téléphone (un mot de 54 px se couperait), une rangée à la tablette */
.app--nova .me-outils--6 { --me-n: 3; }
@media (min-width: 700px) { .app--nova .me-outils--6 { --me-n: 6; } }
.app--nova .cp-code .cp-fait--zero { color: var(--gris); }
