/* XIGMA ERP — mobile d'abord, couleurs de la marque */
:root {
  --noir: #1D1D1B; --jaune: #FFED00; --magenta: #DD0B4A; --vert: #14A681;
  --fond: #F5F5F2; --carte: #FFFFFF; --texte: #1D1D1B; --doux: #6B6B66; --ligne: #E3E3DE;
  --rayon: 14px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; background: var(--fond); color: var(--texte); padding-bottom: 76px; }
a { color: inherit; }

.barre { position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between;
  background: var(--noir); color: #fff; padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top)); }
.marque { display: flex; align-items: center; gap: 8px; font-weight: 800; letter-spacing: .08em; text-decoration: none; }
.logo { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: var(--jaune); color: var(--noir); font-weight: 900; }
.menu summary { list-style: none; cursor: pointer; font-size: 22px; padding: 4px 8px; }
.menu summary::-webkit-details-marker { display: none; }
.menu nav { position: absolute; right: 12px; top: 52px; background: var(--carte); color: var(--texte); border-radius: var(--rayon);
  box-shadow: 0 10px 30px rgba(0,0,0,.18); min-width: 230px; padding: 8px; display: grid; }
.menu nav a, .menu nav .lien { padding: 12px; border-radius: 10px; text-decoration: none; text-align: left; font: inherit; background: none; border: 0; width: 100%; cursor: pointer; }
.menu nav a:hover, .menu nav .lien:hover { background: var(--fond); }
.qui { padding: 8px 12px; font-size: 13px; color: var(--doux); border-bottom: 1px solid var(--ligne); margin-bottom: 4px; }

.page { max-width: 720px; margin: 0 auto; padding: 16px; }
h1 { font-size: 22px; margin: 4px 0 14px; }
h2 { font-size: 17px; margin: 22px 0 10px; }
.sous { color: var(--doux); font-size: 14px; margin-top: -8px; }

.carte { background: var(--carte); border-radius: var(--rayon); padding: 16px; box-shadow: 0 1px 2px rgba(0,0,0,.05); margin-bottom: 12px; }
.grille { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.chiffre { font-size: 22px; font-weight: 800; }
.libelle { font-size: 13px; color: var(--doux); }
.vert { color: var(--vert); } .magenta { color: var(--magenta); }

.tuiles { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.tuile { background: var(--carte); border-radius: var(--rayon); padding: 18px 14px; text-decoration: none; font-weight: 700;
  display: grid; gap: 6px; box-shadow: 0 1px 2px rgba(0,0,0,.05); border-left: 5px solid var(--jaune); }
.tuile small { font-weight: 400; color: var(--doux); }
.tuile.alerte-t { border-left-color: var(--magenta); }

.alerte { padding: 12px 14px; border-radius: 12px; margin-bottom: 12px; background: #E9F7F2; color: #0B6B53; }
.alerte.error { background: #FCE8EE; color: #9B0833; }
.alerte.warning { background: #FFF9C2; color: #5B5300; }

/* Formulaires */
form .champ { margin-bottom: 14px; }
label { display: block; font-weight: 600; font-size: 14px; margin-bottom: 6px; }
input[type=text], input[type=number], input[type=date], input[type=email], input[type=password], input[type=search], input[type=tel], input:not([type]), select, textarea {
  width: 100%; padding: 13px 12px; font: inherit; border: 1.5px solid var(--ligne); border-radius: 12px; background: #fff; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--noir); }
input[name=montant], input[name=montant_compte] { font-size: 26px; font-weight: 800; }
.aide { font-size: 12.5px; color: var(--doux); margin-top: 4px; }
.erreur { color: var(--magenta); font-size: 13px; margin-top: 4px; }
.errorlist { color: var(--magenta); font-size: 13px; padding-left: 18px; margin: 4px 0; }

.sens { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.sens label { margin: 0; }
.sens input { position: absolute; opacity: 0; }
.sens span { display: block; text-align: center; padding: 13px; border-radius: 12px; border: 1.5px solid var(--ligne); background: #fff; font-weight: 700; cursor: pointer; }
.sens input:checked + span.e { background: var(--vert); border-color: var(--vert); color: #fff; }
.sens input:checked + span.s { background: var(--magenta); border-color: var(--magenta); color: #fff; }

.btn { display: inline-block; width: 100%; padding: 15px; border: 0; border-radius: 12px; background: var(--noir); color: #fff;
  font: 700 16px/1 system-ui, sans-serif; cursor: pointer; text-align: center; text-decoration: none; }
.btn.jaune { background: var(--jaune); color: var(--noir); }
.btn.contour { background: transparent; color: var(--noir); border: 1.5px solid var(--noir); }
.btn.petit { width: auto; padding: 8px 12px; font-size: 13px; }
.actions { display: flex; gap: 8px; margin-top: 8px; }

/* Listes */
.liste { list-style: none; margin: 0; padding: 0; }
.liste li { background: var(--carte); border-radius: 12px; padding: 12px 14px; margin-bottom: 8px; display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: center; }
.liste .m { font-weight: 800; text-align: right; white-space: nowrap; }
.liste .d { font-size: 13px; color: var(--doux); }
.liste li.annule { opacity: .5; text-decoration: line-through; }
.badge { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--fond); }
.badge.ok { background: #E9F7F2; color: #0B6B53; } .badge.ko { background: #FCE8EE; color: #9B0833; }

table.tab { width: 100%; border-collapse: collapse; background: var(--carte); border-radius: var(--rayon); overflow: hidden; }
.tab th, .tab td { padding: 11px 12px; border-bottom: 1px solid var(--ligne); text-align: left; font-size: 14px; }
.tab td.n, .tab th.n { text-align: right; white-space: nowrap; }

/* Barre d'onglets du bas */
.onglets { position: fixed; bottom: 0; left: 0; right: 0; z-index: 10; display: flex; background: var(--carte);
  border-top: 1px solid var(--ligne); padding-bottom: env(safe-area-inset-bottom); }
.onglets a { flex: 1; text-align: center; padding: 8px 2px 10px; text-decoration: none; font-size: 11.5px; color: var(--doux); }
.onglets a i { display: block; font-style: normal; font-size: 20px; line-height: 1.3; }
.onglets a.actif { color: var(--noir); font-weight: 700; box-shadow: inset 0 3px 0 var(--jaune); }

.connexion { max-width: 380px; margin: 8vh auto; }
.connexion .logo { width: 56px; height: 56px; font-size: 28px; border-radius: 16px; margin: 0 auto 12px; }
.centre { text-align: center; }

/* Contacts & catalogue */
.entete { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.entete h1 { margin-bottom: 8px; }
.recherche { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin-bottom: 12px; }
.recherche:has(> :only-child) { grid-template-columns: 1fr; }
.btn.wa { background: #25D366; color: #fff; }
.champ.case label { display: flex; gap: 10px; align-items: center; font-weight: 500; }
.champ.case input { width: 20px; height: 20px; }
dl.infos { display: grid; grid-template-columns: 120px 1fr; gap: 6px 10px; margin: 0; font-size: 14.5px; }
dl.infos dt { color: var(--doux); }
dl.infos dd { margin: 0; }
.galerie { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.vignette { background: var(--carte); border-radius: var(--rayon); padding: 8px; text-decoration: none; display: grid; gap: 4px; align-content: start; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.vignette img, .sans-photo { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; background: var(--fond); }
.sans-photo { display: grid; place-items: center; font-size: 40px; font-weight: 800; color: var(--doux); }
.vignette strong { font-size: 14px; line-height: 1.25; }
.prix { font-size: 13.5px; font-weight: 700; }
.photos { display: flex; gap: 8px; overflow-x: auto; margin-bottom: 12px; }
.photos img { height: 220px; border-radius: var(--rayon); }

/* Catalogue : bascule Produits / Services */
.bascule { display: grid; grid-template-columns: 1fr 1fr; background: var(--carte); border-radius: 12px; padding: 4px; gap: 4px; margin-bottom: 10px; }
.bascule a { text-align: center; padding: 10px; border-radius: 9px; text-decoration: none; font-weight: 700; color: var(--doux); }
.bascule a span { font-weight: 500; font-size: 12px; background: var(--fond); border-radius: 99px; padding: 1px 7px; margin-left: 4px; }
.bascule a.actif { background: var(--noir); color: #fff; }
.bascule a.actif span { background: var(--jaune); color: var(--noir); }
.initiale { font-size: 40px; font-weight: 800; color: var(--doux); }

/* Produits : grille de cartes, image carrée recadrée */
.grille-produits { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .grille-produits { grid-template-columns: repeat(3, 1fr); } }
.carte-produit { background: var(--carte); border-radius: var(--rayon); overflow: hidden; text-decoration: none; display: flex; flex-direction: column; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.carte-produit .cadre { position: relative; aspect-ratio: 1 / 1; background: var(--fond); display: grid; place-items: center; overflow: hidden; }
.carte-produit .cadre img { width: 100%; height: 100%; object-fit: cover; display: block; }
.carte-produit .pastille { position: absolute; top: 8px; left: 8px; background: var(--jaune); }
.carte-produit .corps { padding: 10px 12px 12px; display: grid; gap: 4px; }
.carte-produit strong { font-size: 14.5px; line-height: 1.25; }
.carte-produit p, .ligne-service p { margin: 0; font-size: 13px; color: var(--doux); line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

/* Services : liste, image à gauche */
.liste-services { display: grid; gap: 8px; }
.ligne-service { display: grid; grid-template-columns: 84px 1fr auto; gap: 12px; align-items: center; background: var(--carte);
  border-radius: var(--rayon); padding: 10px; text-decoration: none; box-shadow: 0 1px 3px rgba(0,0,0,.06); }
.vignette-service { width: 84px; height: 84px; border-radius: 10px; overflow: hidden; background: var(--fond); display: grid; place-items: center; }
.vignette-service img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ligne-service .corps { display: grid; gap: 3px; min-width: 0; }
.ligne-service .fleche { font-size: 26px; color: var(--doux); padding-right: 4px; }

/* Fiche : grande photo + miniatures */
.galerie-fiche { margin-bottom: 12px; }
.galerie-fiche .principale { aspect-ratio: 4 / 3; background: #fff; border-radius: var(--rayon); overflow: hidden; display: grid; place-items: center; }
.galerie-fiche .principale img { width: 100%; height: 100%; object-fit: contain; display: block; }
.miniatures { display: flex; gap: 8px; margin-top: 8px; }
.miniatures button { width: 64px; height: 64px; padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; background: var(--fond); cursor: pointer; }
.miniatures button.actif { border-color: var(--noir); }
.miniatures img { width: 100%; height: 100%; object-fit: cover; display: block; }
.etapes { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 14.5px; }
.ligne-service .badge, .carte-produit .corps .badge { justify-self: start; }
.bandeau { display: block; text-decoration: none; }
.ligne-service.confirmer { grid-template-columns: 64px 1fr auto; }
.ligne-service.confirmer .vignette-service { width: 64px; height: 64px; }
.oui-non { display: grid; gap: 6px; }

/* Devis & commandes */
.bascule.defile { display: flex; overflow-x: auto; scrollbar-width: none; }
.bascule.defile a { flex: 1 0 auto; padding: 9px 12px; white-space: nowrap; }
.bascule.defile a small { font-weight: 500; font-size: 11px; background: var(--fond); border-radius: 99px; padding: 1px 6px; margin-left: 3px; }
.bascule.defile a.actif small { background: var(--jaune); color: var(--noir); }
.liste.commandes .montants { text-align: right; display: grid; justify-items: end; }
.liste.commandes .montants small { font-size: 12px; color: var(--magenta); font-weight: 600; }
.liste.commandes .montants small.vert { color: var(--vert); }
.retard { color: var(--magenta); font-weight: 700; }
.badge.statut { background: var(--fond); }
.badge.s-devis { background: #FFF9B8; color: #6B5F00; }
.badge.s-confirmee { background: #E6F0FB; color: #1F4E8A; }
.badge.s-en-production { background: #EFE6FB; color: #5B2C91; }
.badge.s-prete { background: #E9F7F2; color: #0B6B53; }
.badge.s-livree { background: var(--noir); color: #fff; }
.badge.s-annulee, .badge.s-devis-refuse { background: #FCE8EE; color: #9B0833; }
table.lignes { width: 100%; border-collapse: collapse; font-size: 14px; }
table.lignes th { text-align: left; font-size: 12px; color: var(--doux); font-weight: 600; padding: 4px 6px; border-bottom: 1px solid var(--ligne); }
table.lignes td { padding: 8px 6px; border-bottom: 1px solid var(--ligne); vertical-align: top; }
table.lignes td:not(:first-child), table.lignes th:not(:first-child) { text-align: right; white-space: nowrap; }
table.lignes tfoot td { border: 0; padding: 4px 6px; }
table.lignes tfoot td:first-child { text-align: right; color: var(--doux); }
table.lignes tfoot tr.total td { font-weight: 800; color: var(--noir); font-size: 15px; }
@media (max-width: 480px) { table.lignes .pu { display: none; } table.lignes { font-size: 13.5px; } }
table.lignes td:first-child { word-break: break-word; }
.btn.large { display: block; width: 100%; text-align: center; margin: 12px 0; }
.btn.vert-btn { background: var(--vert); color: #fff; }
.etapes-commande { margin: 12px 0; }
.etapes-commande .boutons { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.etapes-commande form { margin: 0; }
.etapes-commande details.annuler { margin-top: 12px; }
.etapes-commande details.annuler summary { cursor: pointer; color: var(--magenta); font-weight: 600; }
.etapes-commande details.annuler form { display: grid; gap: 8px; margin-top: 8px; }
.ligne-cmd { margin-bottom: 8px; }
.ligne-cmd .deux { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ligne-cmd .pied-ligne { display: flex; justify-content: space-between; align-items: center; font-weight: 700; }
.ligne-cmd .suppr { display: flex; gap: 6px; align-items: center; font-weight: 500; color: var(--magenta); }
.total-form { display: flex; justify-content: space-between; align-items: center; margin: 10px 0; font-size: 16px; }
.resultats { display: grid; gap: 4px; margin-top: 6px; }
.resultats button { text-align: left; padding: 10px 12px; border: 1px solid var(--ligne); border-radius: 10px; background: var(--carte); font: inherit; cursor: pointer; }
.resultats button:hover { border-color: var(--noir); }
.chiffre.petit-chiffre { font-size: 18px; }
.barre-txt { text-decoration: line-through; opacity: .6; }

/* Écran de vente (POS) */
.pos-bloc { margin-bottom: 10px; display: grid; gap: 8px; }
.pos-titre { display: flex; align-items: center; gap: 8px; font-weight: 800; }
.pos-titre span { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--noir); color: var(--jaune); font-size: 13px; }
.pos input, .pos select { width: 100%; }
.pos label { display: grid; gap: 4px; font-size: 13px; color: var(--doux); }
.client-choisi { display: flex; justify-content: space-between; align-items: center; background: #E9F7F2; border-radius: 10px; padding: 10px 12px; }
.client-choisi small { display: block; color: var(--doux); }
.nouveau-client { display: grid; gap: 8px; }
.oui-non-fne { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.oui-non-fne button, .oui-non-fne.radios label span { display: block; text-align: center; padding: 14px 8px; border: 2px solid var(--ligne); border-radius: 12px; background: var(--carte); font: inherit; font-weight: 800; cursor: pointer; }
.oui-non-fne button.actif, .oui-non-fne.radios input:checked + span { border-color: var(--noir); background: var(--noir); color: var(--jaune); }
.oui-non-fne.radios input { position: absolute; opacity: 0; }
.oui-non-fne.radios label { position: relative; }
.fne-details { display: grid; gap: 8px; }
.r-art { display: grid; gap: 6px; }
.r-art .art { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; text-align: left; padding: 8px; border: 1px solid var(--ligne); border-radius: 12px; background: var(--carte); font: inherit; cursor: pointer; }
.r-art .art:active { background: #FFF9B8; }
.r-art img, .r-art .ini { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; background: var(--fond); display: grid; place-items: center; font-weight: 800; color: var(--doux); }
.r-art .n small { display: block; color: var(--doux); font-size: 12px; }
.r-art .p { font-weight: 800; white-space: nowrap; }
.panier { display: grid; gap: 8px; }
.ligne-panier { border: 1px solid var(--ligne); border-radius: 12px; padding: 10px; display: grid; gap: 6px; background: #FCFCFA; }
.lp-haut { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.lp-x { border: 0; background: none; font-size: 18px; color: var(--magenta); cursor: pointer; }
.lp-bas { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; }
.qte { display: flex; align-items: center; border: 1px solid var(--ligne); border-radius: 10px; overflow: hidden; }
.qte button { width: 38px; height: 40px; border: 0; background: var(--fond); font-size: 18px; font-weight: 800; cursor: pointer; }
.qte input { width: 56px !important; border: 0 !important; text-align: center; padding: 0 !important; }
.lp-prix input { width: 100%; min-width: 90px; }
.lp-prix small { display: block; color: var(--doux); font-size: 11px; }
.lp-m { white-space: nowrap; }
.deux { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.puces { display: flex; flex-wrap: wrap; gap: 6px; }
.puces button { padding: 9px 12px; border: 2px solid var(--ligne); border-radius: 99px; background: var(--carte); font: inherit; font-weight: 700; cursor: pointer; }
.puces button.actif { border-color: var(--vert); background: #E9F7F2; color: #0B6B53; }
.pos-pied { position: sticky; bottom: 76px; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 10px; background: var(--noir); color: #fff; border-radius: 14px; padding: 10px 10px 10px 16px; margin-top: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.2); }
.pos-totaux { display: grid; } .pos-totaux small { color: #bbb; font-size: 12px; } .pos-totaux strong { font-size: 20px; color: var(--jaune); white-space: nowrap; }
.pos-pied .btn { white-space: nowrap; }
.button.lien, button.lien { border: 0; background: none; color: var(--noir); text-decoration: underline; font: inherit; cursor: pointer; padding: 4px 0; justify-self: start; }
.lien-carte { text-decoration: none; color: inherit; }
.tuile.vendre-t { background: var(--jaune); }
.joindre-fne { display: grid; gap: 6px; margin-top: 8px; }
details.annuler.carte form { display: grid; gap: 8px; margin-top: 8px; }

/* Aperçu de l'article choisi (devis) */
.apercu-art { display: grid; grid-template-columns: 72px 1fr; gap: 12px; align-items: start; background: var(--fond); border-radius: 12px; padding: 8px; margin-bottom: 10px; }
.apercu-art .img { width: 72px; height: 72px; border-radius: 10px; overflow: hidden; background: #fff; display: grid; place-items: center; font-size: 28px; font-weight: 800; color: var(--doux); }
.apercu-art img { width: 100%; height: 100%; object-fit: cover; display: block; }
.apercu-art .txt { display: grid; gap: 3px; min-width: 0; }
.apercu-art p { margin: 0; font-size: 13.5px; color: var(--texte); }
.apercu-art small { font-size: 12px; color: var(--doux); }
.ligne-vignette { display: flex; gap: 10px; align-items: flex-start; }
.ligne-vignette img, .ligne-vignette > span { width: 44px; height: 44px; border-radius: 8px; object-fit: cover; flex: none; background: var(--fond); display: grid; place-items: center; font-weight: 800; color: var(--doux); }
.ligne-vignette small { display: block; color: var(--doux); font-size: 12px; }
input.verrouille { background: var(--fond); color: var(--doux); }
details.finition { margin-top: 6px; }
details.finition summary { cursor: pointer; font-weight: 600; font-size: 14px; color: var(--noir); padding: 4px 0; }
details.finition[open] { background: #FFFBD6; border-radius: 10px; padding: 8px; }
small.finition { color: #6B5F00 !important; }
.apercu-art img { max-width: 72px; max-height: 72px; }

/* Suivi des commandes */
.frise { list-style: none; padding: 0; margin: 10px 0 12px; display: flex; overflow-x: auto; gap: 0; }
.frise li { flex: 1 0 70px; text-align: center; position: relative; font-size: 11.5px; color: var(--doux); padding-top: 18px; }
.frise li::before { content: ""; position: absolute; top: 7px; left: -50%; width: 100%; height: 3px; background: var(--ligne); z-index: 0; }
.frise li:first-child::before { display: none; }
.frise .pt { position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 3px solid var(--ligne); z-index: 1; }
.frise li.fait .pt { background: var(--vert); border-color: var(--vert); } .frise li.fait::before { background: var(--vert); }
.frise li.en-cours .pt { background: var(--jaune); border-color: var(--noir); } .frise li.en-cours { color: var(--noir); }
.frise li.en-cours::before { background: var(--vert); }
.frise b { display: block; font-weight: 600; } .frise small { display: block; }
.alerte-suivi { border-radius: 10px; padding: 9px 12px; margin-bottom: 6px; font-weight: 600; font-size: 14px; }
.alerte-suivi.rouge { background: #FCE8EE; color: #9B0833; } .alerte-suivi.orange { background: #FFF1DE; color: #8A4B00; } .alerte-suivi.jaune { background: #FFF9B8; color: #6B5F00; }
.liste.alertes li { border-left: 5px solid var(--ligne); }
.liste.alertes li.niv-rouge { border-left-color: var(--magenta); } .liste.alertes li.niv-orange { border-left-color: #F29100; } .liste.alertes li.niv-jaune { border-left-color: var(--jaune); }
.carte.etape { margin: 12px 0; border-left: 5px solid var(--jaune); display: grid; gap: 8px; }
.etape-titre { font-weight: 800; }
.boutons { display: flex; flex-wrap: wrap; gap: 8px; } .boutons form { margin: 0; }
form.pile { display: grid; gap: 8px; }
.alerte-verrou { border-left: 5px solid var(--magenta); }
.colonnes-suivi { display: grid; gap: 10px; }
@media (min-width: 900px) { .colonnes-suivi { grid-template-columns: repeat(5, 1fr); } }
.col-titre { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; }
.col .mini { display: block; padding: 8px 0; border-top: 1px solid var(--ligne); text-decoration: none; color: inherit; font-size: 14px; }
.col .mini small { display: block; color: var(--doux); }
.badge.s-proforma { background: #FFF9B8; color: #6B5F00; } .badge.s-devis-valide { background: #E6F0FB; color: #1F4E8A; }
.badge.s-bat-en-cours { background: #FFF1DE; color: #8A4B00; } .badge.s-proforma-refusee { background: #FCE8EE; color: #9B0833; }
.historique summary { cursor: pointer; } .historique ul { list-style: none; padding: 0; margin: 8px 0 0; }
.historique li { padding: 8px 0; border-top: 1px solid var(--ligne); font-size: 14px; } .historique small { color: var(--doux); }
.historique .detail { margin-top: 4px; font-size: 13px; color: var(--texte); background: var(--fond); border-radius: 8px; padding: 6px 8px; }
.bat-carte { border-left: 5px solid #F29100; margin: 12px 0; display: grid; gap: 8px; }
.bat-carte table.lignes td:last-child { text-align: right; white-space: nowrap; }
.total-bat { display: flex; justify-content: space-between; align-items: center; margin: 10px 0; border-left: 5px solid #F29100; }
.total-bat small { color: var(--doux); font-weight: 400; }
.bat-ligne { background: #FFF1DE; border-radius: 10px; padding: 6px 8px; }
.bat-ligne small { color: #8A4B00; }
details.corrections summary { cursor: pointer; color: var(--magenta); font-weight: 600; margin-top: 4px; }
details.corrections form { margin-top: 8px; }
.bat-ligne { display: grid; gap: 6px; }
.bat-ligne .prix-bat { font-weight: 700; }
.etape .oui-non-fne.radios label span { padding: 12px 6px; font-size: 14px; }

/* Atelier */
.liste.jobs li.urgent { border-left: 5px solid var(--magenta); }
.badge.s-a-faire { background: #FFF9B8; color: #6B5F00; } .badge.s-en-cours { background: #E6F0FB; color: #1F4E8A; }
.badge.s-chez-le-sous-traitant { background: #EFE6FB; color: #5B2C91; } .badge.s-controle-qualite { background: #FFF1DE; color: #8A4B00; }
.badge.s-termine { background: #E9F7F2; color: #0B6B53; } .badge.s-annule { background: #FCE8EE; color: #9B0833; }
.photo-resultat { width: 100%; max-height: 260px; object-fit: cover; border-radius: 12px; margin-top: 10px; }
a.alerte-suivi { display: block; text-decoration: none; }
.mini-liste { margin: 8px 0; padding-left: 18px; font-size: 14px; }
details.carte > summary { cursor: pointer; }
details.carte form { margin-top: 10px; }
.orange { color: #C26A00; }
input.recu { width: 80px !important; padding: 6px !important; margin-top: 4px; display: block; }
.liste.relances li.appel { border-left: 5px solid #F29100; }
.relance-actions { grid-column: 1 / -1; display: grid; gap: 6px; margin-top: 6px; }
.relance-actions .message { margin: 0; font-size: 13px; background: var(--fond); border-radius: 8px; padding: 8px; }
.relance-actions summary { cursor: pointer; font-size: 14px; font-weight: 600; }
code.jeton { display:block; word-break:break-all; background:#fff; padding:8px; border-radius:8px; margin-top:6px; }
.jauge { height: 6px; background: var(--fond); border-radius: 99px; overflow: hidden; margin-top: 6px; }
.jauge span { display: block; height: 100%; max-width: 100%; background: var(--vert); border-radius: 99px; }
.barre-ligne { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--ligne); font-size: 14px; }
.barre-ligne:first-of-type { border-top: 0; }
.barre-ligne small { color: var(--doux); }
pre.rapport { white-space: pre-wrap; font-size: 13px; background: var(--fond); padding: 10px; border-radius: 10px; }
.ligne-budget { display: grid; grid-template-columns: 1fr 110px auto; gap: 8px; align-items: center; padding: 6px 0; border-top: 1px solid var(--ligne); font-size: 14px; }
.ligne-budget input { padding: 8px !important; }
.carte.controle { border-left: 5px solid var(--jaune); display: grid; gap: 8px; }
.carte.controle.bloquant { border-left-color: var(--magenta); }
.consigne { background: var(--fond); border-radius: 8px; padding: 8px; font-size: 14px; margin: 0; }

/* Export comptable */
.periode { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; }
.periode label { display: flex; flex-direction: column; font-size: 13px; color: var(--doux); flex: 1 1 130px; }
.ligne-compte { display: grid; grid-template-columns: 1fr 100px; gap: 10px; align-items: center; padding: 6px 0; border-top: 1px solid var(--ligne); font-size: 14px; }
.ligne-compte input { padding: 8px !important; text-align: center; }
.alerte .puces { margin: 6px 0 0; padding-left: 18px; font-size: 14px; }
.ligne-cpt { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--ligne); font-size: 14px; }
.ligne-cpt:first-child { border-top: 0; }
.ligne-cpt small { display: block; color: var(--doux); font-size: 12px; margin-top: 2px; }
.ligne-cpt .droite { text-align: right; white-space: nowrap; }
.ligne-cpt.total { font-size: 15px; }
.boutons-col { display: grid; gap: 10px; margin-bottom: 14px; }
@media (min-width: 700px) { .boutons-col { grid-template-columns: repeat(3, 1fr); } }
