/* Livraisons — centre de contrôle du bureau (livraisons.js) : carte, soumission express, camions en direct, calendrier. */
.lv-head { align-items: flex-end; flex-wrap: wrap; gap: 12px; }
.lv-puces { display: flex; gap: 8px; flex-wrap: wrap; }
.lv-puce { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-2); border-radius: 999px; padding: 6px 14px; font-size: 13px; color: var(--muted); }
.lv-puce b { color: var(--text); font-size: 15px; } .lv-puce.rouge { border-color: var(--red); background: var(--red-bg); } .lv-puce.ambre { border-color: var(--amber); background: var(--amber-bg); }
.lv-point { width: 9px; height: 9px; border-radius: 50%; background: var(--faint); display: inline-block; }
.lv-puce.on .lv-point, .lv-live-t .lv-point { background: #22c55e; box-shadow: 0 0 0 0 rgba(34,197,94,.6); animation: lvPulse 1.6s infinite; }
@keyframes lvPulse { 70% { box-shadow: 0 0 0 9px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
.lv-scene { position: relative; height: clamp(520px, 72vh, 820px); border-radius: 16px; overflow: hidden; border: 1px solid var(--line-2); background: #0b0b0e; margin-top: 12px; }
#lv-map { position: absolute; inset: 0; }
#lv-map.lv-regle-on { cursor: crosshair; } #lv-map.lv-regle-on .maplibregl-canvas { cursor: crosshair; }
.lv-carte-err { padding: 30px; color: var(--amber); }
.lv-outils { position: absolute; top: 12px; left: 372px; display: flex; gap: 8px; z-index: 3; }
.lv-outil { background: rgba(13,13,15,.92); color: var(--text); border: 1px solid var(--line-2); border-radius: 10px; padding: 8px 12px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; backdrop-filter: blur(6px); }
.lv-outil:hover { border-color: var(--text); } .lv-outil.on { background: var(--amber); color: #000; border-color: var(--amber); } .lv-outil.off { opacity: .55; }
.lv-mesure { position: absolute; left: 372px; top: 56px; z-index: 3; background: rgba(13,13,15,.92); border: 1px solid var(--amber); border-radius: 10px; padding: 8px 12px; font-size: 13px; }
.lv-mesure button { margin-left: 8px; background: transparent; border: 0; color: var(--red-2); cursor: pointer; font: inherit; }
/* Panneau Soumission express */
.lv-panneau { position: absolute; top: 12px; left: 12px; bottom: 12px; width: 348px; z-index: 4; display: flex; flex-direction: column; background: rgba(13,13,15,.95); border: 1px solid var(--line-2); border-radius: 14px; backdrop-filter: blur(10px); box-shadow: 0 10px 40px rgba(0,0,0,.5); overflow: hidden; }
.lv-pan-t { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.lv-reduire { width: 28px; height: 28px; border-radius: 8px; border: 1px solid var(--line-2); background: transparent; color: var(--text); cursor: pointer; }
.lv-pan-c { padding: 4px 14px 14px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; }
.lv-etape { display: flex; align-items: center; gap: 8px; margin-top: 10px; } .lv-n { width: 22px; height: 22px; border-radius: 50%; background: var(--red); color: #fff; font-size: 12px; font-weight: 700; display: grid; place-items: center; }
.lv-recherche { display: flex; gap: 6px; } .lv-recherche .in { flex: 1; }
.lv-choix { display: flex; flex-direction: column; gap: 4px; } .lv-lieu { text-align: left; background: var(--panel-2); border: 1px solid var(--line-2); border-radius: 8px; padding: 6px 10px; color: inherit; cursor: pointer; font: inherit; font-size: 13px; } .lv-lieu:hover { border-color: var(--text); }
.lv-resultat { background: var(--panel-2); border-radius: 10px; padding: 10px 12px; }
.lv-kpis3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 6px; } .lv-kpis3 div { display: flex; flex-direction: column; } .lv-kpis3 span { font-size: 11px; } .lv-kpis3 b { font-size: 17px; }
.lv-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; } .lv-pan-c .f { margin: 0; } .lv-pan-c .f span { font-size: 12px; color: var(--muted); }
.lv-nouveau { display: flex; flex-direction: column; gap: 6px; } .lv-pick { position: relative; }
.lv-pan-c .vt-pick-list { position: absolute; left: 0; right: 0; z-index: 6; background: var(--panel); border-radius: 8px; }
.lv-lignes { display: flex; flex-direction: column; gap: 6px; } .lv-lignes label { display: grid; grid-template-columns: 1fr 100px; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); }
.lv-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line); } .lv-total b { font-size: 20px; }
.lv-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 8px; } .lv-actions .btn { justify-content: center; }
.lv-note { font-size: 11.5px; line-height: 1.4; }
/* Camions en direct */
.lv-live { position: absolute; top: 12px; right: 56px; z-index: 3; width: 250px; display: flex; flex-direction: column; gap: 8px; max-height: 60%; overflow-y: auto; }
.lv-live-vide, .lv-live-t { background: rgba(13,13,15,.92); border: 1px solid var(--line-2); border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; backdrop-filter: blur(6px); }
.lv-live-t { flex-direction: row; align-items: center; gap: 8px; }
.lv-carte-camion { text-align: left; background: rgba(13,13,15,.92); border: 1px solid #1c6b3c; border-radius: 12px; padding: 10px 12px; color: inherit; cursor: pointer; font: inherit; display: flex; flex-direction: column; gap: 3px; backdrop-filter: blur(6px); }
.lv-carte-camion.suivi { border-color: #22c55e; box-shadow: 0 0 0 2px rgba(34,197,94,.35); } .lv-eta b { color: #22c55e; font-size: 15px; }
.lv-camion { position: relative; width: 34px; height: 34px; display: grid; place-items: center; cursor: pointer; }
.lv-camion svg { width: 26px; height: 26px; fill: #22c55e; stroke: #fff; stroke-width: 1.6; filter: drop-shadow(0 1px 3px rgba(0,0,0,.6)); position: relative; }
.lv-halo { position: absolute; inset: 0; border-radius: 50%; background: rgba(34,197,94,.28); animation: lvHalo 1.8s ease-out infinite; }
@keyframes lvHalo { 0% { transform: scale(.5); opacity: .9; } 100% { transform: scale(1.9); opacity: 0; } }
.lv-camion-n { position: absolute; top: 34px; left: 50%; transform: translateX(-50%); background: #052e16; color: #bbf7d0; border: 1px solid #22c55e; border-radius: 999px; font-size: 11px; font-weight: 700; padding: 1px 7px; white-space: nowrap; }
.lv-pastille { width: 30px; height: 30px; border-radius: 50%; color: #fff; font: 700 15px/30px sans-serif; text-align: center; border: 2px solid #fff; box-shadow: 0 1px 5px rgba(0,0,0,.5); cursor: grab; }
.lv-pin { width: 28px; height: 28px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); background: var(--c); border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.5); cursor: pointer; padding: 0; display: grid; place-items: center; }
.lv-pin span { transform: rotate(45deg); color: #fff; font-weight: 700; font-size: 13px; }
.maplibregl-popup-content { background: #111114; color: #f2f2f4; border: 1px solid #33333b; border-radius: 12px; padding: 12px 14px; font-family: inherit; }
.maplibregl-popup-tip { border-top-color: #111114 !important; border-bottom-color: #111114 !important; } .lv-pop { display: flex; flex-direction: column; gap: 4px; font-size: 13px; } .lv-pop a { color: #7db1ff; }
/* Calendrier de la semaine */
.lv-cal { margin-top: 22px; } .lv-cal-t { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 10px; } .lv-cal-t h2, .lv-liste h2 { margin: 0; font-size: 18px; }
.lv-semaine { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(168px, 1fr); gap: 10px; overflow-x: auto; padding-bottom: 6px; }
.lv-col { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: flex; flex-direction: column; gap: 8px; min-height: 150px; }
.lv-col.auj { border-color: var(--blue); background: var(--blue-bg); } .lv-col.retard { border-color: var(--red); background: var(--red-bg); }
.lv-col-t { display: flex; align-items: baseline; gap: 6px; } .lv-col-t i { margin-left: auto; font-style: normal; font-weight: 700; color: var(--muted); }
.lv-ev { text-align: left; border: 1px solid var(--line-2); border-left: 4px solid var(--blue); background: var(--panel-2); border-radius: 8px; padding: 8px 10px; color: inherit; cursor: pointer; font: inherit; font-size: 13px; display: flex; flex-direction: column; gap: 2px; }
.lv-ev.ramassage { border-left-color: var(--amber); } .lv-ev.retard { border-left-color: var(--red); } .lv-ev:hover { border-color: var(--text); }
.lv-ev-h { font-weight: 700; } .lv-ev-p { align-self: flex-start; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 1px 8px; background: var(--amber-bg); color: var(--amber); }
.lv-ev-p.plan { background: var(--gray-bg); color: var(--muted); } .lv-ev-p.en_route { background: var(--blue-bg); color: var(--blue); } .lv-ev-p.arrive { background: var(--green-bg); color: var(--green); }
.lv-vide { text-align: center; padding: 12px 0; }
/* Détail */
.lv-liste { margin-top: 24px; } .lv-liste h2 { margin-bottom: 10px; }
.lv-ligne { display: grid; grid-template-columns: 96px 1fr auto; gap: 16px; align-items: start; background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--blue); border-radius: var(--radius); padding: 12px; margin-bottom: 10px; }
.lv-ligne.ramassage { border-left-color: var(--amber); } .lv-ligne.retard { border-left-color: var(--red); }
.lv-photo { width: 96px; height: 72px; border-radius: 8px; background: var(--panel-2); overflow: hidden; } .lv-photo img { width: 100%; height: 100%; object-fit: cover; }
.lv-corps { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.lv-tete { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; } .lv-type { font-weight: 700; } .lv-type.livraison { color: var(--blue); } .lv-type.ramassage { color: var(--amber); }
.lv-heure { font-weight: 600; } .lv-client { font-size: 15px; font-weight: 600; display: flex; gap: 10px; flex-wrap: wrap; align-items: baseline; } .lv-client a.faint { font-weight: 400; }
.lv-droite { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; min-width: 190px; } .lv-prix { text-align: right; display: flex; flex-direction: column; } .lv-prix b { font-size: 18px; }
.lv-chauf { display: flex; flex-direction: column; gap: 3px; width: 100%; } .lv-btns { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 980px) {
  .lv-scene { height: auto; display: flex; flex-direction: column; overflow: visible; background: transparent; border: 0; }
  #lv-map { position: relative; height: 56vh; border-radius: 14px; order: 1; } .lv-outils { left: 12px; top: auto; position: absolute; } .lv-mesure { left: 12px; }
  .lv-panneau { position: relative; inset: auto; width: auto; order: 2; margin-top: 10px; } .lv-live { position: relative; right: auto; top: auto; width: auto; order: 0; max-height: none; margin-bottom: 8px; }
  .lv-ligne { grid-template-columns: 1fr; } .lv-photo { width: 100%; height: 140px; } .lv-droite { align-items: stretch; } .lv-prix { text-align: left; }
}

.lv-live .btn { background: rgba(13,13,15,.92); color: var(--text); }
