.gestion-mobile { display: none; }
.dossier-lot-mobile { display: none !important; }
.stock-outils-mobile { display: none; }
.periode-choix-mobile { display: none; }
.gm-modal { width: min(560px, calc(100% - 24px)); max-height: calc(100dvh - 32px); overflow-y: auto; border: 1px solid #dce5df; border-radius: 8px; padding: 20px; color: #172d24; background: #fff; }
.gm-modal::backdrop { background: #102a2266; }
.gm-modal *, .gestion-mobile * { box-sizing: border-box; letter-spacing: 0; }
.gm-modal input, .gm-modal select, .gm-modal textarea, .gestion-mobile input, .gestion-mobile select { width: 100%; min-width: 0; min-height: 44px; border: 1px solid #cedbd3; border-radius: 6px; padding: 10px; font: inherit; background: #fff; color: #172d24; }
.gm-modal label, .gestion-mobile label { display: grid; gap: 6px; font-size: 13px; font-weight: 600; margin-bottom: 14px; min-width: 0; }
.gm-modal button, .gestion-mobile button, .gestion-mobile a { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 44px; min-width: 44px; padding: 10px 12px; border: 1px solid #d5e1da; border-radius: 6px; background: white; color: #20583c; font: inherit; font-size: 13px; font-weight: 600; text-decoration: none; cursor: pointer; white-space: normal; }
.gm-modal button:active, .gestion-mobile button:active { background: #e7f2ec; }
.gm-modal :focus-visible, .gestion-mobile :focus-visible { outline: 2px solid #187147; outline-offset: 3px; }
.gm-modal .gm-primaire, .gestion-mobile .gm-primaire { background: #117640; color: white; border-color: #117640; }
.gm-entete { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.gm-entete > div { min-width: 0; }
.gm-entete h2 { font-size: 22px; line-height: 1.3; margin: 0 0 5px; overflow-wrap: anywhere; }
.gm-entete p { font-size: 13px; line-height: 1.5; color: #59675f; margin: 0; }
.gm-entete > button { flex-shrink: 0; }
.gm-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 16px 0; }
.gm-form-deux { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.gm-form-trois { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.25fr); gap: 8px; }
.gm-form-ligne { border: 0; border-top: 1px solid #dce5df; padding: 12px 0; margin: 12px 0; min-width: 0; }
.gm-form-ligne legend { color: #657368; font-size: 12px; padding-right: 8px; }
.gm-form-ligne > button { display: flex; margin-left: auto; }
.gm-total { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; border-top: 1px solid #dce5df; font-size: 14px; }
.gm-total strong, .gm-total output { overflow-wrap: anywhere; text-align: right; }
.gm-erreur { font-size: 14px; color: #a43128; }
.gm-modal .gm-confirmation { display: flex; align-items: flex-start; gap: 10px; line-height: 1.5; }
.gm-modal .gm-confirmation input { flex: 0 0 22px; width: 22px; min-height: 22px; height: 22px; margin: 0; accent-color: #117640; }
.gm-modal p { overflow-wrap: anywhere; line-height: 1.5; }
.gm-livraison-ligne { display: grid; gap: 6px; padding: 14px 0; border-bottom: 1px solid #dce5df; font-size: 13px; overflow-wrap: anywhere; }
.gm-reception { padding: 12px 0; border-bottom: 1px solid #dce5df; font-size: 13px; overflow-wrap: anywhere; }
.gm-reception summary { min-height: 44px; padding: 10px 0; cursor: pointer; line-height: 1.5; }
.gm-reception summary span { display: block; color: #167247; font-weight: 600; margin-top: 4px; }
.gm-reception p { line-height: 1.5; }
@media (max-width: 720px) {
  .bande-actions .dossier-lot-mobile { display: flex !important; flex: 1 0 100%; flex-direction: row; min-height: 44px; }
  .gm-dossier-onglets { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; padding: 6px 0 16px; margin-bottom: 16px; border-bottom: 1px solid #dce5df; }
  .gestion-mobile .gm-dossier-onglets button { min-width: 0; padding: 10px 3px; font-size: 11.5px; }
  .gm-dossier-onglets button[aria-selected="true"] { background: #e7f2ec; color: #136036; box-shadow: inset 0 -2px #167247; }
  .gm-chronologie { list-style: none; padding: 0; margin: 16px 0; }
  .gm-chronologie li { display: grid; gap: 8px; padding: 16px 0 16px 14px; border-left: 2px solid #dce5df; border-bottom: 1px solid #edf2ef; overflow-wrap: anywhere; }
  .gm-chronologie time { font-size: 12px; color: #627067; }
  .gm-chronologie strong { font-size: 14px; }
  .gm-chronologie p { margin: 0; font-size: 13px; line-height: 1.5; }
  .gm-chronologie button { justify-self: start; }
  #lot-contenu > h3 { margin-top: 16px; }
  #lot-contenu li { font-size: 13px; line-height: 1.6; }
  .gm-document-lot { padding-bottom: 12px; border-bottom: 1px solid #dce5df; }
  #stock-achats-locaux:not([hidden]) { padding-top: 24px; margin-top: 24px; border-top: 1px solid #dce5df; }
}
@media (max-width: 720px) {
  #onglet-dashboard .entete-dashboard { display: block; order: 1; margin: 8px 0 16px; }
  #onglet-dashboard .entete-dashboard > div:first-child { display: none; }
  #onglet-dashboard .choix-dashboard { display: grid; grid-template-columns: 116px minmax(0, 1fr); gap: 12px; align-items: end; }
  #onglet-dashboard .choix-dashboard > label:first-of-type { display: none; }
  #onglet-dashboard .choix-dashboard label { margin: 0; font-size: 12px; min-width: 0; }
  #onglet-dashboard .choix-dashboard select, #onglet-dashboard .choix-dashboard input { min-height: 44px; width: 100%; min-width: 0; padding: 8px; font-size: 14px; border: 1px solid #dce5df; border-radius: 6px; background: white; }
  .periode-choix-mobile { display: flex; height: 44px; border: 1px solid #dce5df; border-radius: 6px; padding: 3px; background: #f4f7f5; }
  .periode-choix-mobile button { flex: 1; border: 0; border-radius: 4px; background: transparent; color: #57685d; font: 600 13px var(--police-texte); cursor: pointer; }
  .periode-choix-mobile button[aria-pressed="true"] { color: #14653b; background: white; box-shadow: 0 1px 4px #172d241a; }
  body { --fond: #ffffff; }
  #onglet-dashboard #pilotage-chair-dashboard, #onglet-dashboard #pilotage-pondeuses-dashboard { display: none; }
  .navigation-mobile-plus { background: #147940; box-shadow: 0 4px 12px #14794026; }
  .navigation-mobile-saisie { color: #147940; }
  .action-terrain-icone.production { color: #147940; background: #e7f2ec; }
  .gestion-mobile h3 { text-transform: none; }
  .stock-outils-mobile { display: grid; gap: 12px; margin: 16px 0; }
  .stock-outils-mobile input[type="search"] { width: 100%; min-width: 0; min-height: 44px; font-size: 16px; padding: 10px 12px; border: 1px solid #cedbd3; border-radius: 6px; }
  .stock-outils-mobile label { display: flex; align-items: center; gap: 8px; min-height: 44px; font-size: 14px; }
  .stock-outils-mobile input[type="checkbox"] { width: 20px; height: 20px; accent-color: #147940; }
  .gestion-mobile:not([hidden]) { display: block; padding-bottom: 20px; color: #172d24; }
  .gestion-mobile h3 { font-size: 16px; margin: 0 0 12px; }
  .gestion-mobile .gm-recherche { position: relative; display: flex; align-items: center; margin: 18px 0 10px; }
  .gm-recherche > svg { position: absolute; left: 12px; width: 18px; }
  .gestion-mobile .gm-recherche input { padding-left: 40px; font-size: 16px; }
  .gm-onglets { display: flex; flex-wrap: wrap; gap: 6px; padding-bottom: 16px; border-bottom: 1px solid #e3e9e5; }
  .gestion-mobile .gm-onglets button { border: 0; padding: 9px 11px; color: #56685d; }
  .gestion-mobile .gm-onglets [aria-pressed="true"] { background: #e7f2ec; color: #136036; box-shadow: inset 0 -2px #167247; }
  .gestion-mobile .gm-ligne { display: flex; width: 100%; text-align: left; justify-content: flex-start; padding: 15px 0; border: 0; border-bottom: 1px solid #e3e9e5; border-radius: 0; gap: 10px; background: transparent; }
  .gm-embleme { width: 36px; height: 40px; display: grid; place-items: center; background: #edf4ef; color: #22764d; border-radius: 6px; flex-shrink: 0; }
  .gm-ligne-texte { display: grid; gap: 5px; flex: 1; min-width: 0; }
  .gm-ligne-texte strong, .gm-ligne-texte small { overflow-wrap: anywhere; }
  .gm-ligne-texte small { color: #627067; font-size: 12px; font-weight: 400; line-height: 1.5; }
  .gm-ligne-fin { display: flex; align-items: flex-end; flex-direction: column; gap: 8px; max-width: 35%; text-align: right; overflow-wrap: anywhere; font-size: 12px; color: #255c41; }
  .gm-ligne-fin svg { width: 16px; height: 16px; }
  .gm-badge { justify-self: start; border-radius: 4px; padding: 4px 6px; background: #edf2f8; color: #365774; font-size: 11px; font-weight: 500; }
  .gm-chiffres { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; padding: 16px 0; border-top: 1px solid #e3e9e5; border-bottom: 1px solid #e3e9e5; }
  .gm-chiffres > div { display: grid; gap: 7px; min-width: 0; }
  .gm-chiffres small { color: #627067; font-size: 12px; }
  .gm-chiffres strong { font-size: 18px; overflow-wrap: anywhere; }
  .gm-chiffres > div + div { border-left: 1px solid #dce5df; padding-left: 16px; color: #8f4932; }
  .gm-tresorerie { padding: 18px 0; display: grid; gap: 8px; }
  .gm-tresorerie strong { font-size: 30px; overflow-wrap: anywhere; color: #166b42; }
  .gm-tresorerie span { font-size: 12px; color: #627067; }
  .gm-section { margin-top: 28px; padding-top: 20px; border-top: 1px solid #dce5df; }
  .gm-analyse { margin: 0 0 14px; padding-bottom: 20px; border-bottom: 1px solid #dce5df; }
  .gm-analyse > div { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .gestion-mobile .gm-analyse button { justify-content: flex-start; text-align: left; min-height: 62px; padding: 12px 10px; line-height: 1.4; }
  .gm-analyse button span { min-width: 0; overflow-wrap: anywhere; }
  .gm-section > button { display: flex; justify-content: flex-start; width: 100%; margin: 8px 0; }
  .gm-section label { margin-top: 16px; }
  .gm-contact { display: flex; gap: 16px; align-items: center; margin: 24px 0; overflow-wrap: anywhere; }
  .gm-avatar { display: grid; place-items: center; width: 56px; height: 56px; flex-shrink: 0; background: #e7f2ec; color: #167247; border-radius: 50%; font-size: 20px; font-weight: 700; }
  .gm-contact p, .gm-note { color: #5e6b64; font-size: 13px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; }
  .gm-infos { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 14px; font-size: 13px; padding: 16px 0; }
  .gm-infos dt { color: #627067; }.gm-infos dd { margin: 0; text-align: right; overflow-wrap: anywhere; }
  .gestion-mobile .gm-lien { border: 0; background: transparent; padding-left: 0; margin-top: 12px; }
  .gm-document-apercu { border-top: 3px solid #22764d; border-bottom: 1px solid #dce5df; padding: 20px 0; }
  .gm-document-marque { display: flex; gap: 10px; align-items: center; margin-bottom: 20px; }
  .gm-document-marque img { width: 32px; height: 32px; }.gm-document-marque strong { overflow-wrap: anywhere; }
  .gm-document-apercu > p { overflow-wrap: anywhere; font-size: 14px; line-height: 1.6; }
  .gm-ligne-article { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; border-top: 1px solid #e3e9e5; font-size: 13px; }
  .gm-ligne-article > div { display: grid; gap: 6px; min-width: 0; }.gm-ligne-article strong { overflow-wrap: anywhere; }.gm-ligne-article > strong { max-width: 40%; text-align: right; }.gm-ligne-article small { color: #627067; }
  .gm-vide { text-align: center; padding: 36px 12px; }.gm-vide > svg { width: 36px; height: 36px; color: #22764d; margin-bottom: 12px; }.gm-vide p { font-size: 14px; line-height: 1.6; color: #627067; }
  .gm-reglement { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; font-size: 13px; border-bottom: 1px solid #e3e9e5; }
  .gm-local { color: #627067; font-size: 12px; margin-top: 32px; }
  .gm-lot { border-bottom: 1px solid #dce5df; padding: 20px 0 8px; }.gm-lot .gm-entete { margin-bottom: 8px; }.gm-lot h3 { overflow-wrap: anywhere; }
  body:has(.gm-modal[open]) { overflow: hidden; }
  .gm-modal { padding: 16px; }.gm-modal input, .gm-modal select, .gm-modal textarea { font-size: 16px; }
}
