
    :root{
      --dark:#111827;
      --dark2:#1f2937;
      --blue:#2563eb;
      --cyan:#06b6d4;
      --green:#10b981;
      --orange:#f59e0b;
      --red:#ef4444;
      --purple:#8b5cf6;
      --soft:#f3f6fb;
      --card:#ffffff;
      --border:#dbe3ef;
      --muted:#64748b;
      --ink:#0f172a;
    }

    *{ box-sizing:border-box; }

    body{
      background:linear-gradient(135deg,#f8fafc,#eef4ff);
      font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
      color:var(--ink);
    }

    .sidebar{
      position:fixed;
      inset:0 auto 0 0;
      width:280px;
      background:#111827;
      color:white;
      padding:22px;
      z-index:20;
      border-right:4px solid var(--blue);
      transition:width .25s ease, transform .25s ease;
    }

    body.menu-collapsed .sidebar{ width:82px; }
    body.menu-collapsed .brand-text,
    body.menu-collapsed .nav-label,
    body.menu-collapsed .sidebar-footer{ display:none; }
    body.menu-collapsed .main{ margin-left:82px; }
    body.menu-collapsed .nav-btn{ text-align:center; padding:13px 8px; }

    .brand{
      display:flex;
      align-items:center;
      justify-content:space-between;
      gap:12px;
      margin-bottom:28px;
      border-bottom:1px solid rgba(255,255,255,.12);
      padding-bottom:18px;
    }

    .brand-left{ display:flex; align-items:center; gap:12px; }

    .brand-icon{
      width:46px;
      height:46px;
      border-radius:0;
      background:linear-gradient(135deg,var(--blue),var(--cyan));
      display:flex;
      align-items:center;
      justify-content:center;
      font-size:1.45rem;
      box-shadow:8px 8px 0 rgba(37,99,235,.18);
      flex:0 0 auto;
    }

    .menu-toggle{
      border:1px solid rgba(255,255,255,.25);
      background:transparent;
      color:white;
      width:36px;
      height:36px;
      display:flex;
      align-items:center;
      justify-content:center;
      border-radius:0;
    }

    .menu-toggle:hover{ background:rgba(255,255,255,.08); }

    .menu-open-fab{
      position:fixed;
      left:18px;
      top:18px;
      width:44px;
      height:44px;
      display:none;
      align-items:center;
      justify-content:center;
      border:0;
      background:linear-gradient(135deg,var(--blue),var(--cyan));
      color:white;
      z-index:50;
      box-shadow:6px 6px 0 rgba(15,23,42,.16);
      font-size:1.2rem;
    }

    body.menu-collapsed .menu-open-fab{ display:flex; }
    body.menu-collapsed .brand .menu-toggle{ display:none; }

    .nav-btn{
      width:100%;
      border:1px solid transparent;
      background:transparent;
      color:#cbd5e1;
      text-align:left;
      padding:13px 14px;
      border-radius:0;
      margin-bottom:8px;
      font-weight:800;
      transition:.18s;
      display:flex;
      align-items:center;
      gap:10px;
    }

    .nav-btn:hover,
    .nav-btn.active{
      background:#1d4ed8;
      color:white;
      border-color:#60a5fa;
      transform:translateX(3px);
    }

    .main{
      margin-left:280px;
      padding:28px;
      transition:margin-left .25s ease;
    }

    .topbar{
      background:white;
      border-radius:0;
      padding:18px 22px;
      box-shadow:10px 10px 0 rgba(37,99,235,.08);
      border:1px solid var(--border);
      margin-bottom:22px;
      display:flex;
      justify-content:space-between;
      align-items:center;
      gap:16px;
    }

    .premium-card{
      background:white;
      border:1px solid var(--border);
      border-radius:0;
      box-shadow:10px 10px 0 rgba(15,23,42,.05);
    }

    .table thead th{
      font-size:.78rem;
      color:#475569;
      text-transform:uppercase;
      letter-spacing:.05em;
      border-bottom:2px solid var(--border);
      background:#f8fafc;
    }

    .table td{ vertical-align:middle; }

    .form-control,
    .form-select{
      border-radius:0;
      border-color:#cbd5e1;
    }

    .form-control:focus,
    .form-select:focus{
      border-color:var(--blue);
      box-shadow:0 0 0 .18rem rgba(37,99,235,.12);
    }

    .btn-rounded,
    .btn,
    .action-btn{
      border-radius:0!important;
      font-weight:700;
    }

    .action-btn{ font-size:.82rem; margin:2px; }

    .badge{ border-radius:0; padding:.45rem .6rem; }
    .badge-soft-success{background:#d1fae5;color:#065f46}
    .badge-soft-danger{background:#fee2e2;color:#991b1b}
    .badge-soft-blue{background:#dbeafe;color:#1e40af}
    .badge-soft-orange{background:#ffedd5;color:#9a3412}
    .badge-soft-purple{background:#ede9fe;color:#6d28d9}

    .pill{
      display:inline-flex;
      align-items:center;
      gap:6px;
      padding:6px 10px;
      border-radius:0;
      background:#e0f2fe;
      color:#075985;
      font-size:.85rem;
      font-weight:800;
      margin:3px;
      border-left:4px solid var(--cyan);
    }

    .password-box{
      background:#f8fafc;
      border:1px dashed #64748b;
      border-radius:0;
      padding:12px;
      font-family:monospace;
      font-weight:800;
      color:#0f172a;
    }

    .sub-card,
    .destination-card{
      border:1px solid var(--border);
      border-left:5px solid var(--blue);
      border-radius:0;
      background:#fff;
      padding:16px;
      margin-bottom:14px;
      box-shadow:6px 6px 0 rgba(15,23,42,.04);
    }

    .small-label{
      font-size:.76rem;
      color:#64748b;
      font-weight:900;
      text-transform:uppercase;
      letter-spacing:.04em;
      margin-bottom:3px;
    }

    .agenda-grid{
      display:grid;
      grid-template-columns:repeat(7,1fr);
      gap:12px;
    }

    .vacation-calendar{
      display:grid;
      grid-template-columns:repeat(7,1fr);
      gap:8px;
    }

    .vacation-day{
      min-height:112px;
      background:#fff;
      border:1px solid var(--border);
      padding:8px;
      cursor:pointer;
      transition:.15s;
      position:relative;
      font-size:.78rem;
    }

    .vacation-day:hover{
      border-color:var(--blue);
      box-shadow:5px 5px 0 rgba(37,99,235,.12);
    }

    .vacation-day.selected{
      border:2px solid var(--blue);
      background:#eff6ff;
    }

    .vacation-day.empty-month{
      opacity:.35;
      background:#f8fafc;
    }

    .vacation-day-number{
      font-weight:900;
      margin-bottom:4px;
      font-size:.9rem;
    }

    .vacation-count{
      display:inline-flex;
      align-items:center;
      justify-content:center;
      min-width:28px;
      height:28px;
      background:var(--blue);
      color:white;
      font-weight:900;
      font-size:.8rem;
      margin-top:6px;
    }

    .vacation-mini-list{
      display:flex;
      flex-direction:column;
      gap:5px;
      margin-top:8px;
    }

    .vacation-mini{
      padding:4px 5px;
      font-size:.62rem;
      font-weight:800;
      background:#dbeafe;
      border-left:4px solid var(--blue);
      color:#1e3a8a;
      line-height:1.08;
    }

    .vacation-mini:nth-child(2n){
      background:#dcfce7;
      border-left-color:var(--green);
      color:#065f46;
    }

    .vacation-mini:nth-child(3n){
      background:#ffedd5;
      border-left-color:var(--orange);
      color:#9a3412;
    }

    .vacation-mini:nth-child(4n){
      background:#ede9fe;
      border-left-color:var(--purple);
      color:#5b21b6;
    }

    .vacation-prereq{
      padding:28px;
      border:1px dashed #94a3b8;
      background:#f8fafc;
      color:#475569;
      font-weight:800;
      text-align:center;
    }

    .vacation-calendar-head{
      display:grid;
      grid-template-columns:repeat(7,1fr);
      gap:8px;
      margin-bottom:8px;
    }

    .vacation-calendar-head div{
      background:#111827;
      color:white;
      padding:8px;
      font-size:.78rem;
      font-weight:900;
      text-align:center;
      text-transform:uppercase;
    }

    .agenda-day{
      background:#fff;
      border:1px solid var(--border);
      border-radius:0;
      min-height:280px;
      padding:12px;
      box-shadow:6px 6px 0 rgba(15,23,42,.04);
    }

    .agenda-day-title{
      font-weight:900;
      margin-bottom:10px;
      padding-bottom:8px;
      border-bottom:2px solid var(--border);
      text-transform:capitalize;
    }

    .event-card{
      border-radius:0;
      padding:10px;
      margin-bottom:10px;
      font-size:.82rem;
    }

    .event-travail{border-left:5px solid #16a34a;background:#dcfce7}
    .event-conge{border-left:5px solid #2563eb;background:#dbeafe}
    .event-arret{border-left:5px solid #dc2626;background:#fee2e2}
    .event-indispo{border-left:5px solid #f97316;background:#ffedd5}
    .event-formation{border-left:5px solid #7c3aed;background:#ede9fe}
    .event-vacances{border-left:5px solid #14b8a6;background:#ccfbf1}
    .event-maintenance{border-left:5px solid #f97316;background:#ffedd5}
    .event-reserve{border-left:5px solid #2563eb;background:#dbeafe}
    .event-panne{border-left:5px solid #dc2626;background:#fee2e2}
    .event-controle{border-left:5px solid #7c3aed;background:#ede9fe}

    .empty-state{
      text-align:center;
      color:#64748b;
      padding:34px;
      background:#f8fafc;
      border:1px dashed #cbd5e1;
    }

    .modal-content{
      border-radius:0;
      border:1px solid var(--border);
      box-shadow:12px 12px 0 rgba(15,23,42,.12);
    }

    .modal-header{ border-bottom:1px solid #eef2f7; }
    .modal-footer{ border-top:1px solid #eef2f7; }

    #passwordModal{ z-index:1085; }
    .modal-backdrop.password-backdrop{ z-index:1080; }

    .confirm-note{
      background:#fff7ed;
      border-left:5px solid var(--orange);
      padding:10px 12px;
      font-size:.9rem;
      color:#9a3412;
      margin-bottom:12px;
    }

    .wizard-section{
      border:1px solid var(--border);
      background:#fff;
      padding:16px;
      margin-bottom:14px;
      box-shadow:6px 6px 0 rgba(15,23,42,.04);
    }

    .wizard-title{
      display:flex;
      align-items:center;
      gap:10px;
      font-weight:900;
      margin-bottom:12px;
      color:#0f172a;
    }

    .wizard-title span{
      width:28px;
      height:28px;
      background:linear-gradient(135deg,var(--blue),var(--cyan));
      color:#fff;
      display:inline-flex;
      align-items:center;
      justify-content:center;
      font-size:.85rem;
      font-weight:900;
    }

    .hint-box{
      background:#eff6ff;
      border-left:5px solid var(--blue);
      padding:10px 12px;
      color:#1e3a8a;
      font-size:.88rem;
      font-weight:700;
    }

    .switch-line{
      display:flex;
      align-items:center;
      gap:10px;
      padding:10px 12px;
      background:#f8fafc;
      border:1px solid var(--border);
      height:100%;
    }

    .stat-tile{
      background:white;
      border:1px solid var(--border);
      padding:16px;
      box-shadow:7px 7px 0 rgba(15,23,42,.06);
      border-left:6px solid var(--blue);
    }

    .stat-tile div{
      font-size:2rem;
      font-weight:900;
      line-height:1;
    }

    .stat-tile span{
      color:var(--muted);
      font-weight:800;
      font-size:.85rem;
      text-transform:uppercase;
    }

    .stat-blue{border-left-color:var(--blue)}
    .stat-green{border-left-color:var(--green)}
    .stat-orange{border-left-color:var(--orange)}
    .stat-red{border-left-color:var(--red)}

    .dashboard-map{
      height:560px;
      border:1px solid var(--border);
      background:#e5e7eb;
      position:relative;
      overflow:hidden;
    }

    .leaflet-container{
      height:100%;
      width:100%;
      font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;
    }

    .leaflet-popup-content-wrapper,
    .leaflet-popup-tip{
      border-radius:0;
      box-shadow:6px 6px 0 rgba(15,23,42,.16);
    }

    .map-panel{
      border:1px solid var(--border);
      background:#fff;
      padding:12px;
      margin-top:12px;
      box-shadow:6px 6px 0 rgba(15,23,42,.05);
    }

    .gps-dot{
      width:18px;
      height:18px;
      border-radius:50%;
      background:var(--orange);
      border:3px solid #fff;
      box-shadow:0 0 0 5px rgba(245,158,11,.25);
    }

    .school-dot,
    .destination-dot{
      width:18px;
      height:18px;
      background:var(--blue);
      border:3px solid #fff;
      box-shadow:0 0 0 4px rgba(37,99,235,.22);
    }

    .destination-dot{
      background:var(--green);
      box-shadow:0 0 0 4px rgba(16,185,129,.22);
    }

    .map-point{
      position:absolute;
      width:20px;
      height:20px;
      transform:translate(-50%,-50%);
      border:3px solid white;
      box-shadow:0 0 0 3px rgba(15,23,42,.16);
    }

    .map-point.school{background:var(--blue)}
    .map-point.destination{background:var(--green)}
    .map-point.vehicle{background:var(--orange); border-radius:50%}

    .map-route{
      position:absolute;
      height:4px;
      background:linear-gradient(90deg,var(--blue),var(--green));
      transform-origin:left center;
      opacity:.55;
    }

    .dash-vacation-card{
      border:1px solid var(--border);
      border-left:6px solid var(--blue);
      padding:14px;
      margin-bottom:12px;
      background:#fff;
      box-shadow:6px 6px 0 rgba(15,23,42,.04);
      cursor:pointer;
    }

    .dash-vacation-card.active{
      border-left-color:var(--orange);
      background:#fff7ed;
    }

    .dash-vacation-card.late{
      border-left-color:var(--red);
      background:#fff1f2;
    }

    .progress-square{
      height:10px;
      background:#e5e7eb;
      overflow:hidden;
    }

    .progress-square > div{
      height:100%;
      background:linear-gradient(90deg,var(--blue),var(--cyan));
    }

    .login-screen{
      position:fixed;
      inset:0;
      z-index:2000;
      display:flex;
      align-items:center;
      justify-content:center;
      padding:24px;
      background:
        linear-gradient(135deg,rgba(37,99,235,.92),rgba(6,182,212,.78)),
        radial-gradient(circle at top left,#ffffff 0,#f8fafc 30%,#e0f2fe 100%);
    }

    .login-screen.d-none{ display:none!important; }

    .login-card{
      width:min(480px,100%);
      background:white;
      border:1px solid var(--border);
      box-shadow:14px 14px 0 rgba(15,23,42,.25);
      padding:28px;
    }

    .login-brand{
      display:flex;
      align-items:center;
      gap:14px;
      margin-bottom:22px;
      padding-bottom:18px;
      border-bottom:2px solid var(--border);
    }

    .login-brand h1{
      font-size:1.8rem;
      font-weight:900;
      margin:0;
      letter-spacing:-.04em;
    }

    .login-brand p{
      margin:0;
      color:var(--muted);
      font-weight:700;
    }

    body:not(.is-authenticated) .sidebar,
    body:not(.is-authenticated) .main,
    body:not(.is-authenticated) .menu-open-fab{
      display:none!important;
    }

    @media(max-width:980px){
      .sidebar{ position:relative; width:100%; min-height:auto; }
      body.menu-collapsed .sidebar{ width:100%; }
      body.menu-collapsed .brand-text,
      body.menu-collapsed .nav-label,
      body.menu-collapsed .sidebar-footer{ display:inline; }
      .main,
      body.menu-collapsed .main{ margin-left:0; padding:16px; }
      .topbar{ flex-direction:column; align-items:flex-start; }
      .agenda-grid{ grid-template-columns:1fr; }
    }
 
/* =========================================================
   ONGLET DEVIS & FACTURES + MODALE BPU MARCHÉ
   ========================================================= */

#view-billing .premium-card{
  overflow:hidden;
}

#view-billing .stat-tile{
  min-height:96px;
  display:flex;
  flex-direction:column;
  justify-content:center;
  align-items:flex-start;
  padding:16px;
  border:1px solid var(--border);
  box-shadow:6px 6px 0 rgba(15,23,42,.04);
}

#view-billing .stat-tile div{
  font-size:1.45rem;
  font-weight:950;
  line-height:1.05;
  letter-spacing:-.04em;
}

#view-billing .stat-tile span{
  font-size:.76rem;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.05em;
  margin-top:6px;
}

.stat-blue{ background:#eff6ff; border-left:6px solid var(--blue)!important; color:#1e3a8a; }
.stat-green{ background:#ecfdf5; border-left:6px solid var(--green)!important; color:#065f46; }
.stat-orange{ background:#fff7ed; border-left:6px solid var(--orange)!important; color:#9a3412; }
.stat-red{ background:#fff1f2; border-left:6px solid var(--red)!important; color:#991b1b; }

#billingSummary{
  border:1px solid var(--border);
  background:#f8fafc;
  padding:14px;
  font-weight:800;
}

.billing-summary-grid{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:10px;
}

.billing-summary-item{
  background:white;
  border:1px solid var(--border);
  padding:12px;
  box-shadow:4px 4px 0 rgba(15,23,42,.04);
}

.billing-summary-item small{
  display:block;
  color:var(--muted);
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.04em;
  margin-bottom:4px;
}

.billing-summary-item strong{
  font-size:1.15rem;
  font-weight:950;
}

#billingTable tr.grouped-line td,
#billingHistoryTable tr.grouped-line td,
#bpuTable tr.grouped-line td{
  background:#f8fafc;
}

.billing-unit-badge{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:7px 9px;
  background:#e0f2fe;
  border-left:4px solid var(--cyan);
  color:#075985;
  font-size:.78rem;
  font-weight:900;
}

.document-status{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:7px 9px;
  font-size:.78rem;
  font-weight:900;
  border-left:4px solid var(--blue);
  background:#eff6ff;
  color:#1e40af;
}

.document-status.sent{ background:#ecfdf5; color:#065f46; border-left-color:var(--green); }
.document-status.draft{ background:#fff7ed; color:#9a3412; border-left-color:var(--orange); }
.document-status.cancelled{ background:#fee2e2; color:#991b1b; border-left-color:var(--red); }

#bpuModal .modal-dialog{
  max-width:1180px;
}

#bpuModal .modal-header{
  background:linear-gradient(135deg,#f8fafc,#eef4ff);
  border-bottom:2px solid var(--border);
}

#bpuModal .modal-title{
  letter-spacing:-.02em;
}

#bpuModal .modal-body{
  background:#f8fafc;
}

#bpuModal .modal-footer{
  background:white;
}

#bpuModal .wizard-section{
  background:white;
  border:1px solid var(--border);
  border-left:6px solid var(--blue);
  padding:18px;
  margin-bottom:16px;
  box-shadow:8px 8px 0 rgba(15,23,42,.04);
}

#bpuModal .wizard-section:nth-of-type(2){ border-left-color:var(--cyan); }
#bpuModal .wizard-section:nth-of-type(3){ border-left-color:var(--green); }
#bpuModal .wizard-section:nth-of-type(4){ border-left-color:var(--orange); }
#bpuModal .wizard-section:nth-of-type(5){ border-left-color:var(--purple); }

#bpuModal .wizard-title{
  display:flex;
  align-items:center;
  gap:10px;
  font-weight:950;
  color:#0f172a;
  margin-bottom:14px;
  letter-spacing:-.02em;
}

#bpuModal .wizard-title span{
  width:30px;
  height:30px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(135deg,var(--blue),var(--cyan));
  color:white;
  font-size:.85rem;
  font-weight:950;
  box-shadow:5px 5px 0 rgba(37,99,235,.16);
}

#bpuDestinations{
  min-height:210px;
  font-weight:700;
}

#bpuDestinations option{
  padding:8px 10px;
}

#bpuDestinations option:checked{
  background:linear-gradient(135deg,var(--blue),var(--cyan));
  color:white;
}

#bpuModal .input-group-text{
  border-radius:0;
  border-color:#cbd5e1;
  background:#f8fafc;
  font-weight:900;
}

#bpuModal .switch-line{
  height:100%;
  align-items:flex-start;
  border:1px solid var(--border);
  background:#f8fafc;
  padding:14px;
  box-shadow:5px 5px 0 rgba(15,23,42,.04);
}

#bpuModal .switch-line:hover{
  border-color:var(--blue);
  background:#eff6ff;
}

#bpuModal .switch-line input{
  margin-top:4px;
  flex:0 0 auto;
}

#bpuModal .switch-line label{
  cursor:pointer;
  line-height:1.25;
}

#bpuModal .switch-line strong{
  font-weight:950;
}

#bpuModal .form-check-input{
  border-radius:0;
  border-color:#94a3b8;
}

#bpuModal .form-check-input:checked{
  background-color:var(--blue);
  border-color:var(--blue);
}

.bpu-destination-list{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}

.bpu-destination-chip{
  display:inline-flex;
  align-items:center;
  padding:5px 8px;
  background:#e0f2fe;
  color:#075985;
  border-left:4px solid var(--cyan);
  font-size:.75rem;
  font-weight:900;
}

.bpu-price-mini{
  font-weight:950;
  color:#0f172a;
  white-space:nowrap;
}

.bpu-empty{
  padding:24px;
  text-align:center;
  background:#f8fafc;
  border:1px dashed #cbd5e1;
  color:var(--muted);
  font-weight:800;
}

@media(max-width:1200px){
  .billing-summary-grid{
    grid-template-columns:repeat(2,1fr);
  }
}

@media(max-width:768px){
  #view-billing .stat-tile{
    min-height:82px;
  }

  .billing-summary-grid{
    grid-template-columns:1fr;
  }

  #bpuModal .modal-dialog{
    margin:0;
    max-width:none;
    height:100%;
  }

  #bpuModal .modal-content{
    min-height:100%;
  }

  #bpuModal .modal-footer{
    position:sticky;
    bottom:0;
    z-index:5;
    box-shadow:0 -8px 20px rgba(15,23,42,.08);
  }

  #bpuModal .modal-footer .btn{
    width:100%;
  }
}

.provider-logo-preview{
  min-width:120px;
  min-height:70px;
  border:1px dashed #94a3b8;
  background:#f8fafc;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight:800;
  color:#64748b;
  padding:8px;
}
.provider-logo-preview img{max-width:160px;max-height:75px;object-fit:contain;}

/* UX devis / factures - version propre */
.billing-hero{ border-left:5px solid var(--blue); }
#view-billing .premium-card{ overflow:hidden; }
#view-billing .stat-tile div{ font-size:1.25rem; }
#view-billing .table td,#view-billing .table th{ font-size:.82rem; }
#billingHistoryTable tr:hover,#billingTable tr:hover{ background:#f8fbff; }
.billing-summary-clean .stat-tile{ min-height:82px; }

/* =====================================================
   AGENDA MENSUEL CHAUFFEURS / VÉHICULES - V2
   ===================================================== */
.agenda-weekdays{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.agenda-weekday-chip input{ display:none; }
.agenda-weekday-chip span{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:48px;
  padding:8px 12px;
  border:1px solid var(--border);
  background:#fff;
  font-weight:800;
  cursor:pointer;
}
.agenda-weekday-chip input:checked + span{
  background:#111827;
  color:#fff;
  border-color:#111827;
  box-shadow:5px 5px 0 rgba(37,99,235,.13);
}
.agenda-preview-box{
  border:1px dashed #bfdbfe;
  background:#eff6ff;
  padding:12px;
  min-height:48px;
}
.agenda-preview-dates{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  max-height:124px;
  overflow:auto;
}
.agenda-date-pill{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:7px 10px;
  background:#fff;
  border:1px solid #bfdbfe;
  font-weight:800;
  font-size:.86rem;
}
.agenda-date-pill button{
  border:0;
  background:#fee2e2;
  color:#991b1b;
  font-weight:900;
  line-height:1;
  width:20px;
  height:20px;
}
.agenda-legend{
  display:flex;
  gap:16px;
  flex-wrap:wrap;
  font-size:.9rem;
  color:var(--muted);
  font-weight:700;
}
.legend-dot{
  display:inline-block;
  width:10px;
  height:10px;
  margin-right:6px;
  vertical-align:middle;
}
.agenda-dot-manual{ background:#2563eb; }
.agenda-dot-vacation{ background:#10b981; }
.agenda-month-grid{
  display:grid;
  grid-template-columns:repeat(7,minmax(150px,1fr));
  gap:10px;
}
.agenda-month-head{
  background:#111827;
  color:#fff;
  padding:10px;
  text-align:center;
  font-weight:900;
  border:1px solid #111827;
}
.agenda-month-day{
  background:#fff;
  border:1px solid var(--border);
  min-height:170px;
  padding:10px;
  box-shadow:5px 5px 0 rgba(15,23,42,.04);
}
.agenda-month-day.is-muted{
  background:#f8fafc;
  opacity:.45;
}
.agenda-month-day.is-today{
  outline:3px solid #bfdbfe;
}
.agenda-month-date{
  display:flex;
  justify-content:space-between;
  align-items:center;
  margin-bottom:8px;
  border-bottom:1px solid #e5e7eb;
  padding-bottom:6px;
}
.agenda-month-date strong{
  font-size:1.15rem;
}
.agenda-month-date span{
  color:var(--muted);
  font-weight:800;
  font-size:.78rem;
}
.agenda-empty-day{
  color:#94a3b8;
  font-size:.85rem;
  font-weight:700;
  padding:8px;
  border:1px dashed #e2e8f0;
  text-align:center;
}
.agenda-event-card,
.agenda-vacation-card{
  margin-bottom:8px;
  border-radius:0;
  font-size:.86rem;
}
.agenda-vacation-card{
  background:#ecfdf5;
  border-left:5px solid #10b981;
}
.agenda-event-card{
  border-left:5px solid #2563eb;
}
@media (max-width:1200px){
  .agenda-month-grid{ grid-template-columns:repeat(2,minmax(220px,1fr)); }
  .agenda-month-head{ display:none; }
}
@media (max-width:768px){
  .agenda-month-grid{ grid-template-columns:1fr; }
}

/* Agenda exports */
.agenda-export-actions{
  display:flex;
  gap:8px;
  justify-content:flex-end;
  flex-wrap:wrap;
}

/* V14 - dashboard itinéraire autocar */
.route-mini-line{
  display:grid;
  grid-template-columns:1fr;
  gap:4px;
  padding:9px 10px;
  border:1px dashed var(--border);
  background:#f8fafc;
  font-size:.82rem;
  font-weight:700;
  color:#334155;
}
.route-summary-grid{
  display:grid;
  grid-template-columns:repeat(4,minmax(0,1fr));
  gap:8px;
}
.route-summary-grid div{
  border:1px solid var(--border);
  background:#f8fafc;
  padding:10px;
}
.route-summary-grid span{
  display:block;
  font-size:.72rem;
  text-transform:uppercase;
  font-weight:900;
  color:var(--muted);
}
.route-summary-grid strong{
  display:block;
  font-size:1.05rem;
  color:var(--ink);
}
.coach-route-panel{
  border-left:5px solid var(--blue);
}
@media(max-width:768px){
  .route-summary-grid{ grid-template-columns:repeat(2,minmax(0,1fr)); }
}

/* =====================================================
   24 - DASHBOARD PREMIUM DISPATCH UX
   ===================================================== */
.dash-hero{padding:22px;display:flex;justify-content:space-between;gap:18px;align-items:center;background:linear-gradient(135deg,#0f172a,#1d4ed8);color:#fff;border:0;overflow:hidden;position:relative}.dash-hero:after{content:"";position:absolute;right:-80px;top:-90px;width:230px;height:230px;background:rgba(255,255,255,.12);transform:rotate(35deg)}.dash-title{font-weight:950;margin:4px 0 2px;font-size:1.65rem}.dash-subtitle{margin:0;color:rgba(255,255,255,.76)}.dash-hero .section-kicker{color:#93c5fd;letter-spacing:.12em}.dash-hero-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end;position:relative;z-index:1}.dash-filter-chip{border:1px solid rgba(255,255,255,.26);background:rgba(255,255,255,.08);color:#fff;padding:9px 12px;font-weight:900;border-radius:0;display:inline-flex;align-items:center;gap:7px}.dash-filter-chip:hover,.dash-filter-chip.active{background:#fff;color:#0f172a}.dash-filter-panel{box-shadow:10px 10px 0 rgba(15,23,42,.06)}.dashboard-premium-kpis{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}.premium-kpi{background:#fff;border:1px solid var(--border);box-shadow:8px 8px 0 rgba(37,99,235,.06);padding:16px;min-height:108px;display:flex;flex-direction:column;justify-content:space-between;position:relative;overflow:hidden}.premium-kpi:before{content:"";position:absolute;left:0;top:0;width:5px;height:100%;background:#2563eb}.premium-kpi.orange:before{background:#f59e0b}.premium-kpi.red:before{background:#ef4444}.premium-kpi.blue:before{background:#1d4ed8}.premium-kpi.cyan:before{background:#06b6d4}.premium-kpi span{font-size:.78rem;color:#64748b;font-weight:900;text-transform:uppercase;letter-spacing:.04em}.premium-kpi strong{font-size:2rem;line-height:1;font-weight:950;color:#0f172a}.premium-kpi small{color:#64748b;font-weight:700}.dash-list-card,.dash-map-card{box-shadow:12px 12px 0 rgba(15,23,42,.05)}.dashboard-premium-list{display:flex;flex-direction:column;gap:12px;max-height:680px;overflow:auto;padding-right:3px}.premium-dispatch-card{background:#fff;border:1px solid #e2e8f0;box-shadow:6px 6px 0 rgba(15,23,42,.04);padding:15px;cursor:pointer;transition:.18s;border-left:6px solid #f59e0b}.premium-dispatch-card:hover{transform:translateY(-2px);box-shadow:8px 10px 0 rgba(15,23,42,.07)}.premium-dispatch-card.active{border-color:#2563eb;background:linear-gradient(180deg,#fff,#eff6ff)}.premium-dispatch-card.critical{border-left-color:#ef4444}.premium-dispatch-card.unassigned{border-left-color:#64748b}.dispatch-card-head{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}.dispatch-time{font-weight:950;color:#0f172a;display:flex;gap:7px;align-items:center}.premium-status-pill{font-size:.72rem;font-weight:950;padding:6px 9px;border-radius:0;text-transform:uppercase;letter-spacing:.03em}.premium-status-planifie{background:#fef3c7;color:#92400e}.premium-status-annulee{background:#fee2e2;color:#991b1b}.premium-status-validee-chauffeur{background:#dcfce7;color:#166534}.premium-status-facturee{background:#dbeafe;color:#1e40af}.premium-status-payee{background:#cffafe;color:#155e75}.dispatch-route{display:grid;grid-template-columns:1fr;gap:5px;margin-bottom:12px}.route-point{display:flex;gap:10px;align-items:flex-start}.route-point strong{display:block;line-height:1.15}.route-point small{display:block;color:#64748b;font-size:.78rem;margin-top:2px}.route-point .dot{width:13px;height:13px;display:inline-block;flex:0 0 13px;margin-top:3px;background:#2563eb}.route-point .dot.end{background:#10b981}.route-line{width:2px;height:14px;background:#cbd5e1;margin-left:5.5px}.dispatch-meta-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;background:#f8fafc;border:1px solid #e2e8f0;padding:10px;margin:10px 0}.dispatch-meta-grid div{min-width:0}.dispatch-meta-grid span{display:block;font-size:.7rem;color:#64748b;font-weight:900;text-transform:uppercase}.dispatch-meta-grid strong{display:block;font-size:.82rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dispatch-progress-wrap{display:flex;align-items:center;gap:10px}.dispatch-progress{height:9px;background:#e2e8f0;flex:1;overflow:hidden}.dispatch-progress span{display:block;height:100%;background:linear-gradient(90deg,#2563eb,#06b6d4)}.dispatch-progress-wrap small{color:#64748b;font-weight:700;white-space:nowrap}.dispatch-actions{display:flex;gap:7px;justify-content:flex-end;margin-top:12px;flex-wrap:wrap}.premium-map{min-height:430px;border:1px solid #dbe3ef;box-shadow:inset 0 0 0 1px rgba(255,255,255,.6)}.premium-empty{display:flex;flex-direction:column;align-items:center;gap:6px;padding:34px!important}.premium-empty i{font-size:2rem;color:#2563eb}.premium-empty strong{font-size:1.05rem}@media(max-width:1200px){.dashboard-premium-kpis{grid-template-columns:repeat(3,1fr)}}@media(max-width:768px){.dash-hero{align-items:flex-start;flex-direction:column}.dashboard-premium-kpis{grid-template-columns:repeat(2,1fr)}.dispatch-meta-grid{grid-template-columns:repeat(2,1fr)}.dashboard-premium-list{max-height:none}.premium-map{min-height:330px}}@media(max-width:480px){.dashboard-premium-kpis{grid-template-columns:1fr}.dispatch-meta-grid{grid-template-columns:1fr}.dash-filter-chip{width:100%;justify-content:center}.dash-hero-actions{width:100%}}

/* =====================================================
   24 - DASHBOARD PREMIUM DISPATCH UX
   ===================================================== */
.dash-hero{padding:22px;display:flex;justify-content:space-between;gap:18px;align-items:center;background:linear-gradient(135deg,#0f172a,#1d4ed8);color:#fff;border:0;overflow:hidden;position:relative}.dash-hero:after{content:"";position:absolute;right:-80px;top:-90px;width:230px;height:230px;background:rgba(255,255,255,.12);transform:rotate(35deg)}.dash-title{font-weight:950;margin:4px 0 2px;font-size:1.65rem}.dash-subtitle{margin:0;color:rgba(255,255,255,.76)}.dash-hero .section-kicker{color:#93c5fd;letter-spacing:.12em}.dash-hero-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end;position:relative;z-index:1}.dash-filter-chip{border:1px solid rgba(255,255,255,.26);background:rgba(255,255,255,.08);color:#fff;padding:9px 12px;font-weight:900;border-radius:0;display:inline-flex;align-items:center;gap:7px}.dash-filter-chip:hover,.dash-filter-chip.active{background:#fff;color:#0f172a}.dash-filter-panel{box-shadow:10px 10px 0 rgba(15,23,42,.06)}.dashboard-premium-kpis{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:12px}.premium-kpi{background:#fff;border:1px solid var(--border);box-shadow:8px 8px 0 rgba(37,99,235,.06);padding:16px;min-height:108px;display:flex;flex-direction:column;justify-content:space-between;position:relative;overflow:hidden}.premium-kpi:before{content:"";position:absolute;left:0;top:0;width:5px;height:100%;background:#2563eb}.premium-kpi.orange:before{background:#f59e0b}.premium-kpi.red:before{background:#ef4444}.premium-kpi.blue:before{background:#1d4ed8}.premium-kpi.cyan:before{background:#06b6d4}.premium-kpi span{font-size:.78rem;color:#64748b;font-weight:900;text-transform:uppercase;letter-spacing:.04em}.premium-kpi strong{font-size:2rem;line-height:1;font-weight:950;color:#0f172a}.premium-kpi small{color:#64748b;font-weight:700}.dash-list-card,.dash-map-card{box-shadow:12px 12px 0 rgba(15,23,42,.05)}.dashboard-premium-list{display:flex;flex-direction:column;gap:12px;max-height:680px;overflow:auto;padding-right:3px}.premium-dispatch-card{background:#fff;border:1px solid #e2e8f0;box-shadow:6px 6px 0 rgba(15,23,42,.04);padding:15px;cursor:pointer;transition:.18s;border-left:6px solid #f59e0b}.premium-dispatch-card:hover{transform:translateY(-2px);box-shadow:8px 10px 0 rgba(15,23,42,.07)}.premium-dispatch-card.active{border-color:#2563eb;background:linear-gradient(180deg,#fff,#eff6ff)}.premium-dispatch-card.critical{border-left-color:#ef4444}.premium-dispatch-card.unassigned{border-left-color:#64748b}.dispatch-card-head{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:12px}.dispatch-time{font-weight:950;color:#0f172a;display:flex;gap:7px;align-items:center}.premium-status-pill{font-size:.72rem;font-weight:950;padding:6px 9px;border-radius:0;text-transform:uppercase;letter-spacing:.03em}.premium-status-planifie{background:#fef3c7;color:#92400e}.premium-status-annulee{background:#fee2e2;color:#991b1b}.premium-status-validee-chauffeur{background:#dcfce7;color:#166534}.premium-status-facturee{background:#dbeafe;color:#1e40af}.premium-status-payee{background:#cffafe;color:#155e75}.dispatch-route{display:grid;grid-template-columns:1fr;gap:5px;margin-bottom:12px}.route-point{display:flex;gap:10px;align-items:flex-start}.route-point strong{display:block;line-height:1.15}.route-point small{display:block;color:#64748b;font-size:.78rem;margin-top:2px}.route-point .dot{width:13px;height:13px;display:inline-block;flex:0 0 13px;margin-top:3px;background:#2563eb}.route-point .dot.end{background:#10b981}.route-line{width:2px;height:14px;background:#cbd5e1;margin-left:5.5px}.dispatch-meta-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;background:#f8fafc;border:1px solid #e2e8f0;padding:10px;margin:10px 0}.dispatch-meta-grid div{min-width:0}.dispatch-meta-grid span{display:block;font-size:.7rem;color:#64748b;font-weight:900;text-transform:uppercase}.dispatch-meta-grid strong{display:block;font-size:.82rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.dispatch-progress-wrap{display:flex;align-items:center;gap:10px}.dispatch-progress{height:9px;background:#e2e8f0;flex:1;overflow:hidden}.dispatch-progress span{display:block;height:100%;background:linear-gradient(90deg,#2563eb,#06b6d4)}.dispatch-progress-wrap small{color:#64748b;font-weight:700;white-space:nowrap}.dispatch-actions{display:flex;gap:7px;justify-content:flex-end;margin-top:12px;flex-wrap:wrap}.premium-map{min-height:430px;border:1px solid #dbe3ef;box-shadow:inset 0 0 0 1px rgba(255,255,255,.6)}.premium-empty{display:flex;flex-direction:column;align-items:center;gap:6px;padding:34px!important}.premium-empty i{font-size:2rem;color:#2563eb}.premium-empty strong{font-size:1.05rem}@media(max-width:1200px){.dashboard-premium-kpis{grid-template-columns:repeat(3,1fr)}}@media(max-width:768px){.dash-hero{align-items:flex-start;flex-direction:column}.dashboard-premium-kpis{grid-template-columns:repeat(2,1fr)}.dispatch-meta-grid{grid-template-columns:repeat(2,1fr)}.dashboard-premium-list{max-height:none}.premium-map{min-height:330px}}@media(max-width:480px){.dashboard-premium-kpis{grid-template-columns:1fr}.dispatch-meta-grid{grid-template-columns:1fr}.dash-filter-chip{width:100%;justify-content:center}.dash-hero-actions{width:100%}}

/* =====================================================
   V17 - DASHBOARD : CARDS ETA + MODAL CARTE PREMIUM
   ===================================================== */
.dashboard-premium-list .premium-dispatch-card{ cursor:pointer; }
.dispatch-eta-pill{
  display:inline-flex; align-items:center; gap:7px;
  width:fit-content; max-width:100%;
  margin:10px 0 6px;
  padding:8px 10px;
  background:linear-gradient(135deg,#eff6ff,#ecfeff);
  border:1px solid #bfdbfe;
  color:#0f172a;
  font-weight:900;
  font-size:.86rem;
  box-shadow:5px 5px 0 rgba(37,99,235,.08);
}
.dispatch-actions .btn-dark{ box-shadow:4px 4px 0 rgba(15,23,42,.14); }
.route-modal-content{ border:0; border-radius:0; overflow:hidden; box-shadow:0 30px 80px rgba(15,23,42,.35); }
.route-modal-header{ background:linear-gradient(135deg,#ffffff,#f8fafc); border-bottom:1px solid #e2e8f0; }
.route-modal-grid{ display:grid; grid-template-columns:minmax(0,1.45fr) minmax(340px,.8fr); gap:18px; align-items:stretch; }
.dashboard-route-modal-map{ height:620px; min-height:420px; border:1px solid #dbe3ef; background:#eef4ff; box-shadow:10px 10px 0 rgba(37,99,235,.08); }
.route-modal-panel{ height:100%; }
.route-loading{ background:#f8fafc; border:1px dashed #cbd5e1; padding:18px; display:flex; flex-direction:column; gap:4px; }
.route-modal-summary{ display:grid; grid-template-columns:repeat(2,1fr); gap:10px; margin-bottom:14px; }
.route-modal-summary>div{ background:#f8fafc; border:1px solid #e2e8f0; padding:13px; box-shadow:5px 5px 0 rgba(15,23,42,.04); }
.route-modal-summary span,.route-modal-lines span{ display:block; color:#64748b; font-size:.76rem; font-weight:800; text-transform:uppercase; letter-spacing:.04em; }
.route-modal-summary strong{ display:block; margin-top:4px; font-size:1.15rem; }
.route-modal-section{ background:white; border:1px solid #e2e8f0; padding:14px; margin-bottom:12px; box-shadow:6px 6px 0 rgba(37,99,235,.05); }
.route-modal-section h6{ font-weight:950; margin-bottom:10px; }
.route-modal-step{ display:flex; align-items:flex-start; gap:10px; padding:8px 0; }
.route-modal-step small{ display:block; color:#64748b; }
.route-modal-lines{ display:grid; gap:10px; }
.live-soon{ background:linear-gradient(135deg,#eff6ff,#f8fafc); }
.live-soon p{ margin:0; color:#475569; }
@media (max-width: 992px){
  .route-modal-grid{ grid-template-columns:1fr; }
  .dashboard-route-modal-map{ height:420px; }
}

/* V20 - reset propre de la carte modale dashboard */
.route-map-placeholder{
  min-height:420px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:6px;
  background:linear-gradient(135deg,#f8fafc,#eef4ff);
  border:1px dashed #cbd5e1;
  color:#334155;
  text-align:center;
}
.route-map-placeholder small{ color:#64748b; }

/* V20 - reset propre de la carte modale dashboard */
.route-map-placeholder{
  min-height:420px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:6px;
  background:linear-gradient(135deg,#f8fafc,#eef4ff);
  border:1px dashed #cbd5e1;
  color:#334155;
  text-align:center;
}
.route-map-placeholder small{ color:#64748b; }

/* V23 - mot de passe oublié au-dessus de l’écran de connexion */
#passwordResetModal{z-index:2305!important;}
body.forgot-password-open .modal-backdrop.show{z-index:2290!important;}


/* =====================================================
   LYNK TRANSPORT - DA OFFICIELLE + RESPONSIVE V3
   ===================================================== */
:root{
  --dark:#11263A;
  --dark2:#31506A;
  --blue:#008DFF;
  --cyan:#008DFF;
  --green:#198754;
  --orange:#008DFF;
  --red:#dc3545;
  --purple:#5B7CA3;
  --soft:#E8EEF4;
  --silver:#AEB8C2;
  --white:#FFFFFF;
  --ink:#11263A;
  --muted:#6E8094;
  --border:#D7E0E8;
  --card:#FFFFFF;
}

html, body{
  background:#EEF3F8 !important;
  color:var(--ink) !important;
  font-family:'Inter', Arial, sans-serif !important;
}

h1,h2,h3,h4,h5,h6,
.section-kicker,
.wizard-title,
.modal-title{
  font-family:'Sora','Montserrat','Inter',Arial,sans-serif !important;
}

/* Menu clair pour que le logo officiel ressorte */
.sidebar{
  background:linear-gradient(180deg,#F7FAFD 0%,#E8EEF4 100%) !important;
  color:var(--ink) !important;
  border-right:1px solid #D7E0E8 !important;
  box-shadow:8px 0 28px rgba(17,38,58,.08) !important;
}

.brand{
  border-bottom:1px solid #D7E0E8 !important;
  padding-bottom:16px !important;
  margin-bottom:20px !important;
  align-items:center !important;
}

.brand-left{
  width:100%;
  background:transparent !important;
  border:0 !important;
  box-shadow:none !important;
  padding:0 !important;
  min-height:auto !important;
  justify-content:flex-start !important;
}

.brand-logo-sidebar{
  width:205px !important;
  max-width:100% !important;
  height:auto !important;
  display:block !important;
}

.brand-logo-login{
  width:70px !important;
  height:auto !important;
  display:block !important;
}

.brand-icon{
  background:#fff !important;
  box-shadow:none !important;
}

.menu-toggle{
  background:#FFFFFF !important;
  color:var(--dark) !important;
  border:1px solid #D7E0E8 !important;
  box-shadow:none !important;
}

.menu-toggle:hover{
  background:#E8EEF4 !important;
}

.menu-open-fab{
  background:#FFFFFF !important;
  color:var(--dark) !important;
  border:1px solid #D7E0E8 !important;
  box-shadow:0 10px 24px rgba(17,38,58,.14) !important;
}

.nav-btn{
  color:#31506A !important;
  background:transparent !important;
  border:1px solid transparent !important;
  border-left:4px solid transparent !important;
  font-weight:800 !important;
}

.nav-btn i{
  color:#31506A !important;
}

.nav-btn:hover,
.nav-btn.active{
  background:#FFFFFF !important;
  color:#11263A !important;
  border-color:#D7E0E8 !important;
  border-left-color:#008DFF !important;
  box-shadow:0 8px 18px rgba(17,38,58,.08) !important;
  transform:none !important;
}

.nav-btn:hover i,
.nav-btn.active i{
  color:#008DFF !important;
}

.sidebar-footer{
  border-top:1px solid #D7E0E8 !important;
}

body.menu-collapsed .brand-left{
  justify-content:center !important;
}

body.menu-collapsed .brand-logo-sidebar{
  width:44px !important;
}

/* Login */
.login-screen{
  background:linear-gradient(180deg,#FFFFFF 0%,#EEF3F8 100%) !important;
}

.login-card{
  background:#FFFFFF !important;
  border:1px solid #D7E0E8 !important;
  box-shadow:0 18px 50px rgba(17,38,58,.10) !important;
  border-radius:0 !important;
}

.login-brand{
  align-items:center !important;
  gap:16px !important;
}

.hint-box{
  background:#F7FAFD !important;
  color:#31506A !important;
}

/* Surfaces */
.topbar,
.premium-card,
.modal-content,
.kpi-card,
.vacation-card,
.billing-panel,
.billing-history-card,
.sub-card,
.destination-card,
.hint-box{
  background:#FFFFFF !important;
  color:#11263A !important;
  border:1px solid #D7E0E8 !important;
  border-radius:0 !important;
  box-shadow:0 12px 28px rgba(17,38,58,.06) !important;
}

.text-muted,
small,
.small{
  color:#6E8094 !important;
}

/* Dashboard : correction blanc sur blanc */
#view-dashboard,
#view-dashboard *{
  color:#11263A;
}

#view-dashboard .text-muted,
#view-dashboard small,
#view-dashboard .small,
#view-dashboard p{
  color:#6E8094 !important;
}

#view-dashboard .section-kicker,
#view-dashboard .dashboard-kicker,
#view-dashboard .eyebrow{
  color:#008DFF !important;
}

#view-dashboard .premium-card,
#view-dashboard .dashboard-hero,
#view-dashboard .dashboard-filters,
#view-dashboard .dashboard-list,
#view-dashboard .dashboard-map-panel,
#view-dashboard .dashboard-shell,
#view-dashboard .dashboard-clean,
#view-dashboard .dashboard-section{
  background:#FFFFFF !important;
  color:#11263A !important;
  border:1px solid #D7E0E8 !important;
}

#view-dashboard h1,
#view-dashboard h2,
#view-dashboard h3,
#view-dashboard h4,
#view-dashboard h5,
#view-dashboard strong,
#view-dashboard label,
#view-dashboard .fw-bold{
  color:#11263A !important;
}

#view-dashboard .btn-primary,
#view-dashboard .filter-chip.active,
#view-dashboard .dash-chip.active,
#view-dashboard .dashboard-chip.active{
  background:#008DFF !important;
  border-color:#008DFF !important;
  color:#FFFFFF !important;
}

#view-dashboard .filter-chip,
#view-dashboard .dash-chip,
#view-dashboard .dashboard-chip{
  background:#FFFFFF !important;
  border:1px solid #D7E0E8 !important;
  color:#31506A !important;
}

#dashboardVacationList{
  color:#11263A !important;
}

#dashboardVacationList .vacation-card,
#dashboardVacationList [class*="card"]{
  background:#FFFFFF !important;
  color:#11263A !important;
  border:1px solid #D7E0E8 !important;
  border-left:5px solid #008DFF !important;
}

#dashboardVacationList .route,
#dashboardVacationList .route strong,
#dashboardVacationList .vac-title,
#dashboardVacationList .time,
#dashboardVacationList .status{
  color:#11263A !important;
}

#dashboardVacationList .info,
#dashboardVacationList .bottom,
#dashboardVacationList .eta,
#dashboardVacationList .meta,
#dashboardVacationList .muted,
#dashboardVacationList small{
  color:#6E8094 !important;
}

/* Statuts et accents */
.vacation-card.status-planifie,
.status-planifie{ border-left-color:#008DFF !important; }

.vacation-card.status-annulee,
.status-annulee{ border-left-color:#dc3545 !important; }

.vacation-card.status-validee,
.vacation-card.status-validee_chauffeur,
.status-validee,
.status-validee_chauffeur{ border-left-color:#198754 !important; }

.vacation-card.status-facturee,
.status-facturee{ border-left-color:#31506A !important; }

.vacation-card.status-payee,
.status-payee{ border-left-color:#008DFF !important; background:#F2F9FF !important; }

/* Tableaux et formulaires */
.table{
  color:#11263A !important;
}

.table thead th{
  background:#F7FAFD !important;
  color:#31506A !important;
  border-bottom:2px solid #D7E0E8 !important;
}

.table td{
  color:#11263A !important;
}

.form-control,
.form-select{
  border-radius:0 !important;
  border:1px solid #CFD9E2 !important;
  background:#FFFFFF !important;
  color:#11263A !important;
  min-height:44px;
}

.form-control:focus,
.form-select:focus{
  border-color:#008DFF !important;
  box-shadow:0 0 0 .2rem rgba(0,141,255,.12) !important;
}

.btn,
.btn-rounded,
.action-btn{
  border-radius:0 !important;
  font-weight:800 !important;
}

.btn-primary{
  background:#008DFF !important;
  border-color:#008DFF !important;
  color:#FFFFFF !important;
}

.btn-primary:hover{
  background:#0077D8 !important;
  border-color:#0077D8 !important;
}

.btn-outline-primary{
  color:#008DFF !important;
  border-color:#008DFF !important;
}

.btn-outline-primary:hover{
  color:#FFFFFF !important;
  background:#008DFF !important;
  border-color:#008DFF !important;
}

/* Responsive mobile premium */
@media (max-width: 991.98px){
  body{
    padding-bottom:76px !important;
  }

  .sidebar{
    position:fixed !important;
    left:0 !important;
    right:0 !important;
    top:auto !important;
    bottom:0 !important;
    width:100% !important;
    height:72px !important;
    padding:8px 8px env(safe-area-inset-bottom) 8px !important;
    display:flex !important;
    align-items:center !important;
    gap:6px !important;
    overflow-x:auto !important;
    z-index:1050 !important;
    border-right:0 !important;
    border-top:1px solid #D7E0E8 !important;
    box-shadow:0 -8px 28px rgba(17,38,58,.12) !important;
  }

  .brand,
  .sidebar-footer,
  .menu-toggle,
  .menu-open-fab{
    display:none !important;
  }

  .nav-btn{
    min-width:76px !important;
    height:56px !important;
    padding:6px 8px !important;
    margin:0 !important;
    display:flex !important;
    flex-direction:column !important;
    justify-content:center !important;
    align-items:center !important;
    gap:2px !important;
    font-size:.68rem !important;
    border-left:0 !important;
    border-bottom:3px solid transparent !important;
    white-space:nowrap !important;
  }

  .nav-btn i{
    font-size:1.18rem !important;
  }

  .nav-btn.active{
    border-left-color:transparent !important;
    border-bottom-color:#008DFF !important;
  }

  .nav-label{
    display:block !important;
    max-width:70px;
    overflow:hidden;
    text-overflow:ellipsis;
  }

  .main{
    margin-left:0 !important;
    padding:12px !important;
  }

  .topbar{
    position:sticky !important;
    top:0 !important;
    z-index:100 !important;
    margin:-12px -12px 14px -12px !important;
    padding:14px 12px !important;
    flex-direction:column !important;
    align-items:flex-start !important;
    gap:10px !important;
  }

  .topbar h1,
  #pageTitle{
    font-size:1.25rem !important;
    line-height:1.25 !important;
  }

  #pageSubtitle{
    font-size:.82rem !important;
  }

  #topbarActions{
    width:100% !important;
  }

  #topbarActions .btn{
    width:100% !important;
  }

  .premium-card{
    padding:14px !important;
  }

  .table-responsive,
  .table-wrap{
    overflow-x:auto !important;
    -webkit-overflow-scrolling:touch !important;
  }

  table{
    min-width:760px;
  }

  .modal-dialog{
    margin:0 !important;
    max-width:100% !important;
    min-height:100vh !important;
  }

  .modal-content{
    min-height:100vh !important;
    border:0 !important;
  }

  .modal-body{
    max-height:calc(100vh - 130px) !important;
    overflow:auto !important;
  }

  .dashboard-kpi,
  .kpi-grid,
  .stats-grid,
  .billing-clean-grid,
  .dashboard-premium-grid,
  .dashboard-grid{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:12px !important;
  }

  #dashboardVacationList .vacation-card{
    padding:14px !important;
  }

  .vac-top,
  .info,
  .bottom{
    flex-direction:column !important;
    align-items:flex-start !important;
    gap:6px !important;
  }

  .route{
    flex-wrap:wrap !important;
    line-height:1.25 !important;
  }
}

@media (max-width: 575.98px){
  .nav-btn{
    min-width:68px !important;
    font-size:.62rem !important;
  }

  .nav-label{
    max-width:62px;
  }

  .form-control,
  .form-select,
  .btn{
    min-height:46px !important;
    font-size:.95rem !important;
  }

  .login-card{
    margin:10px !important;
    padding:20px !important;
  }

  .login-brand{
    align-items:flex-start !important;
  }

  .brand-logo-login{
    width:56px !important;
  }
}


/* =====================================================
   LYNK FINAL UX FIXES
   ===================================================== */

/* Connexion : logo horizontal uniquement */
.login-brand{
  justify-content:center !important;
  text-align:center !important;
}

.brand-logo-login-horizontal{
  width:260px !important;
  max-width:100% !important;
  height:auto !important;
  display:block !important;
  margin:0 auto 4px auto !important;
}

/* Cache l'ancien bloc compte test s'il reste en cache HTML */
.login-card .hint-box{
  display:none !important;
}

/* Bouton aujourd'hui / filtres dashboard : texte visible */
#view-dashboard button,
#view-dashboard .btn,
#view-dashboard .filter-chip,
#view-dashboard .dash-chip,
#view-dashboard .dashboard-chip{
  color:#11263A !important;
}

#view-dashboard .btn-primary,
#view-dashboard .filter-chip.active,
#view-dashboard .dash-chip.active,
#view-dashboard .dashboard-chip.active{
  color:#FFFFFF !important;
}

/* Forcer le bouton Aujourd'hui à rester lisible */
#view-dashboard button[onclick*="Today"],
#view-dashboard button[onclick*="today"],
#view-dashboard button[onclick*="resetDashboardFilters"],
#view-dashboard .btn-outline-secondary{
  background:#FFFFFF !important;
  color:#11263A !important;
  border-color:#D7E0E8 !important;
}

/* Suppression visuelle de la card doublon tableau de bord si elle est injectée */
#view-dashboard .premium-card:has(h1:first-child, h2:first-child, h3:first-child, h4:first-child, h5:first-child){
  /* conservé vide : compat limitée, règles précises dessous */
}

#view-dashboard .dashboard-duplicate-title,
#view-dashboard .dashboard-title-card{
  display:none !important;
}

/* Masque uniquement une card qui contient le texte doublon exact quand le navigateur supporte :has */
#view-dashboard .premium-card:has(h1, h2, h3, h4, h5):has(p){
  /* ne pas masquer toutes les cards : surcharge annulée volontairement */
}

/* Bouton déconnexion mobile */
.mobile-logout-btn{
  display:none !important;
}

@media (max-width: 991.98px){
  .mobile-logout-btn{
    display:flex !important;
  }

  .mobile-logout-btn i{
    color:#dc3545 !important;
  }

  .mobile-logout-btn .nav-label{
    color:#31506A !important;
  }

  .brand-logo-login-horizontal{
    width:230px !important;
  }
}

/* Desktop : garder la déconnexion classique du footer */
@media (min-width: 992px){
  .mobile-logout-btn{
    display:none !important;
  }
}

/* Responsive login */
@media (max-width: 575.98px){
  .brand-logo-login-horizontal{
    width:220px !important;
  }
}


/* =====================================================
   LYNK - CORRECTIONS UI TABLEAU DE BORD / VACATIONS / DEVIS
   ===================================================== */

/* Supprime le doublon visuel du titre du tableau de bord */
body.is-dashboard-view .topbar{
  display:none !important;
}

/* Garde un bon espacement quand le topbar dashboard est masqué */
body.is-dashboard-view .main{
  padding-top:24px !important;
}

/* Bouton Aujourd'hui lisible */
#view-dashboard .btn-outline-secondary,
#view-dashboard button[onclick*="resetDashboardFilters"]{
  background:#FFFFFF !important;
  color:#11263A !important;
  border:1px solid #AEB8C2 !important;
  box-shadow:none !important;
}

#view-dashboard .btn-outline-secondary i,
#view-dashboard button[onclick*="resetDashboardFilters"] i{
  color:#11263A !important;
}

/* Tableau vacations : actions propres */
#view-vacations table{
  min-width:1320px;
}

#view-vacations th.text-end,
#view-vacations td.text-end{
  text-align:left !important;
}

.vacation-actions-cell{
  min-width:245px;
  vertical-align:top !important;
}

.vac-status-inline{
  margin-bottom:8px;
}

.vac-actions-compact{
  display:grid;
  grid-template-columns:repeat(2, minmax(105px, 1fr));
  gap:6px;
  align-items:stretch;
}

.vac-actions-compact .btn{
  width:100%;
  margin:0 !important;
  min-height:34px;
  padding:6px 8px !important;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:6px;
  white-space:nowrap;
  font-size:.78rem !important;
  line-height:1.1;
}

.vac-actions-compact .btn-outline-secondary:disabled{
  opacity:.45;
  background:#F7FAFD !important;
  color:#6E8094 !important;
}

.vac-actions-compact .btn-warning{
  background:#FFC107 !important;
  border-color:#FFC107 !important;
  color:#11263A !important;
}

.vac-actions-compact .btn-outline-danger{
  background:#FFFFFF !important;
  color:#dc3545 !important;
  border-color:#dc3545 !important;
}

.vac-actions-compact .btn-outline-danger:hover{
  background:#dc3545 !important;
  color:#FFFFFF !important;
}

/* Historique devis : si un bouton payé reste injecté sur un devis, on le masque visuellement */
tr:has(td .badge):has(button) button:has(+ .never){ display:none; }

@media (max-width: 991.98px){
  body.is-dashboard-view .main{
    padding-top:12px !important;
  }

  .vac-actions-compact{
    grid-template-columns:1fr;
  }

  .vacation-actions-cell{
    min-width:175px;
  }

  .vac-actions-compact .btn span{
    display:inline;
  }
}


/* =====================================================
   LYNK - FINITIONS UI V2
   ===================================================== */

/* Dashboard cards plus compactes */
.dashboard-premium-kpis{
  display:grid !important;
  grid-template-columns:repeat(6, minmax(0,1fr)) !important;
  gap:10px !important;
}

.premium-kpi{
  min-height:84px !important;
  padding:12px 14px !important;
  box-shadow:0 8px 18px rgba(17,38,58,.05) !important;
}

.premium-kpi span{
  font-size:.76rem !important;
  margin-bottom:2px !important;
}

.premium-kpi strong{
  font-size:1.75rem !important;
  line-height:1 !important;
}

.premium-kpi small{
  font-size:.8rem !important;
}

.dashboard-premium-list .premium-dispatch-card{
  padding:14px 18px !important;
  margin-bottom:10px !important;
}

.dispatch-card-head{
  margin-bottom:8px !important;
}

.dispatch-route{
  gap:8px !important;
  margin-bottom:10px !important;
}

.dispatch-route .route-point small{
  font-size:.78rem !important;
  line-height:1.25 !important;
}

.dispatch-meta-grid{
  display:grid !important;
  grid-template-columns:repeat(4, minmax(0,1fr)) !important;
  gap:8px !important;
  margin-bottom:10px !important;
}

.dispatch-meta-grid > div{
  padding:10px 12px !important;
}

.dispatch-progress-wrap{
  margin-top:6px !important;
}

.dispatch-progress-wrap small{
  font-size:.78rem !important;
}

.dispatch-actions{
  display:flex !important;
  gap:8px !important;
  flex-wrap:wrap !important;
  justify-content:flex-end !important;
  margin-top:10px !important;
}

.dispatch-actions .btn{
  min-height:36px !important;
  padding:6px 12px !important;
  font-weight:800 !important;
}

/* Bouton carte visible */
.dispatch-actions .btn-dark{
  background:#008DFF !important;
  border-color:#008DFF !important;
  color:#FFFFFF !important;
  box-shadow:none !important;
}
.dispatch-actions .btn-dark i{
  color:#FFFFFF !important;
}
.dispatch-actions .btn-dark:hover{
  background:#0077D8 !important;
  border-color:#0077D8 !important;
  color:#FFFFFF !important;
}

/* Table devis/factures plus cohérente */
#view-billing .table thead th{
  vertical-align:middle !important;
}

#view-billing #billingTable td,
#view-billing #billingHistoryTable td{
  vertical-align:middle !important;
}

#view-billing #billingTable td:nth-child(2){
  white-space:nowrap !important;
}

.billing-actions-cell{
  white-space:nowrap !important;
  min-width:180px !important;
}

.billing-actions-cell .btn{
  margin-left:6px !important;
}
.billing-actions-cell .btn:first-child{
  margin-left:0 !important;
}

@media (max-width: 1200px){
  .dashboard-premium-kpis{
    grid-template-columns:repeat(3, minmax(0,1fr)) !important;
  }
  .dispatch-meta-grid{
    grid-template-columns:repeat(2, minmax(0,1fr)) !important;
  }
}

@media (max-width: 991.98px){
  .dashboard-premium-kpis{
    grid-template-columns:repeat(2, minmax(0,1fr)) !important;
  }
  .premium-kpi{
    min-height:76px !important;
  }
  .dashboard-premium-list .premium-dispatch-card{
    padding:12px 14px !important;
  }
  .dispatch-meta-grid{
    grid-template-columns:1fr !important;
  }
  .dispatch-actions{
    justify-content:flex-start !important;
  }
  .dispatch-actions .btn{
    flex:1 1 100% !important;
  }
}


/* LYNK - fix visibilité bouton carte + dashboard compact */
.dispatch-actions .btn-dark,
.dispatch-actions .btn-dark i{background:#008DFF!important;border-color:#008DFF!important;color:#fff!important;}
.dashboard-premium-kpis{gap:10px!important;}
.premium-kpi{min-height:84px!important;padding:12px 14px!important;}
.dashboard-premium-list .premium-dispatch-card{padding:14px 18px!important;}


/* =====================================================
   LYNK - SÉLECTION VACATIONS DEVIS / FACTURES
   ===================================================== */
#billingVacationSelectionPanel{
  border-left:5px solid #008DFF !important;
}

.billing-selection-table{
  min-width:980px;
}

.billing-selection-table td,
.billing-selection-table th{
  vertical-align:middle !important;
}

.billing-selection-table .form-check-input{
  width:1.2rem;
  height:1.2rem;
  border-radius:0 !important;
  cursor:pointer;
}

.billing-selection-table .billing-line-mode{
  min-width:170px;
}

.billing-total-grid{
  display:grid !important;
  grid-template-columns:repeat(6,minmax(0,1fr)) !important;
  gap:12px !important;
}

.billing-total-card{
  border:1px solid #D7E0E8 !important;
  background:#FFFFFF !important;
  padding:14px !important;
  box-shadow:0 8px 18px rgba(17,38,58,.05) !important;
}

.billing-total-card span{
  display:block;
  font-size:.72rem;
  text-transform:uppercase;
  font-weight:800;
  color:#6E8094;
  letter-spacing:.03em;
  margin-bottom:4px;
}

.billing-total-card strong{
  color:#11263A;
  font-size:1.15rem;
}

.billing-total-card.highlight{
  background:#EEF6FF !important;
  border-color:#A8D3FF !important;
}

.billing-total-card.revision{
  background:#F7FBFF !important;
}

@media(max-width:1200px){
  .billing-total-grid{grid-template-columns:repeat(3,minmax(0,1fr)) !important;}
}
@media(max-width:768px){
  .billing-total-grid{grid-template-columns:1fr !important;}
}


/* =====================================================
   LYNK - DEVIS FACTURES SIMPLE
   ===================================================== */
#billingVacationSelectionPanel{display:none!important;}
#billingSimpleSelectionPanel{
  border-left:5px solid #008DFF!important;
}
.billing-simple-table{
  min-width:900px;
}
.billing-simple-table td,
.billing-simple-table th{
  vertical-align:middle!important;
}
.billing-simple-table .form-check-input{
  width:1.15rem;
  height:1.15rem;
  border-radius:0!important;
}
.billing-used-row{
  opacity:.65;
  background:#f8fafc!important;
}
.billing-simple-summary{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:12px;
}
.billing-simple-summary > div{
  background:#fff;
  border:1px solid #D7E0E8;
  padding:14px;
  box-shadow:0 8px 18px rgba(17,38,58,.05);
}
.billing-simple-summary span{
  display:block;
  color:#6E8094;
  font-size:.72rem;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.03em;
  margin-bottom:4px;
}
.billing-simple-summary strong{
  color:#11263A;
  font-size:1.22rem;
}
@media(max-width:1100px){
  .billing-simple-summary{grid-template-columns:repeat(2,minmax(0,1fr));}
}
@media(max-width:700px){
  .billing-simple-summary{grid-template-columns:1fr;}
}


/* =====================================================
   LYNK - ACCÈS CHAUFFEUR
   ===================================================== */
.driver-access-box{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  border:1px solid #D7E0E8;
  background:#F7FAFD;
  padding:12px;
}
.driver-access-box strong{
  color:#11263A;
}
#driverGeneratedPasswordBox{
  background:#fff;
  border:1px dashed #008DFF;
  color:#11263A;
  font-family:Inter, Arial, sans-serif;
}
@media(max-width:768px){
  .driver-access-box{
    flex-direction:column;
    align-items:flex-start;
  }
  .driver-access-box .btn{
    width:100%;
  }
}


/* =====================================================
   LYNK - DEVIS/FACTURES : VACATIONS UTILISÉES MASQUÉES
   ===================================================== */
#billingSimpleSelectionPanel small.text-muted{
  line-height:1.35;
}
.billing-simple-summary > div:nth-child(3){
  background:#F7FAFD;
}


/* =====================================================
   LYNK - LOGIQUE DEVIS PUIS FACTURE
   ===================================================== */
#billingSelectionHelpText{
  display:block;
  max-width:900px;
}
.billing-simple-summary > div:nth-child(3),
.billing-simple-summary > div:nth-child(4){
  background:#F7FAFD;
}

/* V17 - autocomplétion adresse / priorité des cartes */
.lynk-address-suggestions{
  position:absolute;left:0;right:0;top:100%;z-index:7000;background:#fff;border:1px solid #dbe3ef;box-shadow:0 18px 40px rgba(15,23,42,.18);max-height:260px;overflow:auto;margin-top:4px
}
.lynk-address-suggestions button{display:block;width:100%;text-align:left;background:#fff;border:0;border-bottom:1px solid #eef2f7;padding:10px 12px;color:#0f172a}
.lynk-address-suggestions button:hover{background:#eff6ff}
.lynk-address-suggestions strong{display:block;font-weight:900;font-size:.9rem}.lynk-address-suggestions small{display:block;color:#64748b;margin-top:2px}
.leaflet-container,.leaflet-pane,.leaflet-map-pane,.leaflet-control-container{z-index:1!important}.modal,.modal-backdrop,.offcanvas,.dropdown-menu,.topbar,.sidebar{z-index:5000!important}

/* =====================================================
   V18 - voile noir / autocomplétion française
===================================================== */
.modal-backdrop.show{ opacity:.12!important; background:#0f172a!important; }
body:not(.modal-open) > .modal-backdrop{ display:none!important; pointer-events:none!important; }
.lynk-address-suggestions{ z-index:9000!important; border:1px solid #bfdbfe!important; box-shadow:0 18px 44px rgba(15,23,42,.18)!important; }
.lynk-address-suggestions .lynk-address-empty{ padding:12px; font-weight:800; color:#64748b; background:#fff; }
.lynk-address-suggestions button strong{ color:#0f172a; }
.lynk-address-suggestions button small{ color:#475569; }

/* =====================================================
   V19 - correction définitive voile noir + z-index modales
   Le backdrop Bootstrap est désactivé dans l'app gestion car il passait
   au-dessus des grandes modales métier et bloquait les clics.
===================================================== */
body > .modal-backdrop,
.modal-backdrop,
.modal-backdrop.show,
.modal-backdrop.fade,
.modal-backdrop.fade.show{
  display:none!important;
  opacity:0!important;
  pointer-events:none!important;
  background:transparent!important;
  position:static!important;
  z-index:-1!important;
}
body.modal-open{
  overflow:auto!important;
  padding-right:0!important;
}
.modal{
  z-index:12000!important;
  background:transparent!important;
  pointer-events:auto!important;
}
.modal-dialog,
.modal-content{
  position:relative!important;
  z-index:12010!important;
}
.lynk-address-suggestions-v19{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:100%!important;
  z-index:13000!important;
  background:#fff!important;
  border:1px solid #93c5fd!important;
  box-shadow:0 18px 44px rgba(15,23,42,.20)!important;
  max-height:300px!important;
  overflow:auto!important;
  margin-top:4px!important;
}
.lynk-address-suggestions-v19 button{
  display:block!important;
  width:100%!important;
  text-align:left!important;
  background:#fff!important;
  border:0!important;
  border-bottom:1px solid #eef2f7!important;
  padding:11px 13px!important;
  color:#0f172a!important;
}
.lynk-address-suggestions-v19 button:hover{ background:#eff6ff!important; }
.lynk-address-suggestions-v19 strong{ display:block!important; font-weight:900!important; font-size:.9rem!important; }
.lynk-address-suggestions-v19 small{ display:block!important; color:#475569!important; margin-top:2px!important; }
.lynk-address-suggestions-v19 .lynk-address-empty{ padding:12px!important; font-weight:800!important; color:#64748b!important; }
.leaflet-container,
.leaflet-pane,
.leaflet-map-pane,
.leaflet-control-container{ z-index:1!important; }

/* V20 - autocomplétion adresse française visible dans les modales */
.lynk-address-suggestions-v20{position:absolute!important;left:0!important;right:0!important;top:100%!important;z-index:20000!important;background:#fff!important;border:1px solid #93c5fd!important;box-shadow:0 18px 44px rgba(15,23,42,.22)!important;max-height:280px!important;overflow:auto!important;margin-top:4px!important;}
.lynk-address-suggestions-v20 button{display:block!important;width:100%!important;text-align:left!important;background:#fff!important;border:0!important;border-bottom:1px solid #e2e8f0!important;padding:10px 12px!important;color:#0f172a!important;}
.lynk-address-suggestions-v20 button:hover{background:#eff6ff!important;}
.lynk-address-suggestions-v20 strong{display:block!important;font-weight:900!important;}
.lynk-address-suggestions-v20 small{display:block!important;color:#475569!important;margin-top:2px!important;}
.lynk-address-suggestions-v20 .lynk-address-empty{padding:12px!important;font-weight:800!important;color:#64748b!important;}

/* V22 - suggestions adresse au-dessus des modales */
.lynk-address-suggestions-v22{
  position:absolute!important;left:0!important;right:0!important;top:100%!important;z-index:30000!important;
  background:#fff!important;border:1px solid #93c5fd!important;box-shadow:0 18px 44px rgba(15,23,42,.22)!important;
  max-height:300px!important;overflow:auto!important;margin-top:4px!important;border-radius:12px!important;
}
.lynk-address-suggestions-v22 button{display:block!important;width:100%!important;text-align:left!important;background:#fff!important;border:0!important;border-bottom:1px solid #e2e8f0!important;padding:10px 12px!important;color:#0f172a!important;}
.lynk-address-suggestions-v22 button:hover{background:#eff6ff!important;}
.lynk-address-suggestions-v22 strong{display:block!important;font-weight:900!important;font-size:.9rem!important;}
.lynk-address-suggestions-v22 small{display:block!important;color:#475569!important;margin-top:2px!important;}
.lynk-address-suggestions-v22 .lynk-address-empty{padding:12px!important;font-weight:800!important;color:#64748b!important;background:#fff!important;}
.modal-backdrop{display:none!important;opacity:0!important;pointer-events:none!important;}
.modal{background:rgba(15,23,42,.10)!important;}

/* =====================================================
   V23 - Calcul trajet ancienne version + autocomplétion FR
===================================================== */
.lynk-address-suggestions-v23{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:100%!important;
  z-index:30000!important;
  background:#fff!important;
  border:1px solid #93c5fd!important;
  box-shadow:0 18px 44px rgba(15,23,42,.22)!important;
  max-height:290px!important;
  overflow:auto!important;
  margin-top:4px!important;
}
.lynk-address-suggestions-v23 button{display:block!important;width:100%!important;text-align:left!important;background:#fff!important;border:0!important;border-bottom:1px solid #e2e8f0!important;padding:10px 12px!important;color:#0f172a!important;}
.lynk-address-suggestions-v23 button:hover{background:#eff6ff!important;}
.lynk-address-suggestions-v23 strong{display:block!important;font-weight:900!important;font-size:.9rem!important;}
.lynk-address-suggestions-v23 small{display:block!important;color:#475569!important;margin-top:2px!important;}
.lynk-address-suggestions-v23 .lynk-address-empty{padding:12px!important;font-weight:800!important;color:#64748b!important;background:#fff!important;}
body > .modal-backdrop{display:none!important;opacity:0!important;pointer-events:none!important;}
.modal{z-index:20000!important;}

/* V24 - autocomplétion adresse française au-dessus des modales */
.lynk-address-suggestions-v24{position:absolute;left:0;right:0;top:calc(100% + 4px);z-index:7000;background:#fff;border:1px solid rgba(15,23,42,.14);border-radius:14px;box-shadow:0 18px 42px rgba(15,23,42,.18);max-height:260px;overflow:auto;padding:6px}
.lynk-address-suggestions-v24 button{width:100%;border:0;background:transparent;text-align:left;padding:9px 10px;border-radius:10px;display:block;color:#0f172a}
.lynk-address-suggestions-v24 button:hover{background:#eef6ff}
.lynk-address-suggestions-v24 strong{display:block;font-size:.92rem}
.lynk-address-suggestions-v24 small{display:block;color:#64748b;font-size:.78rem;margin-top:2px}
.lynk-address-suggestions-v24 .lynk-address-empty{padding:10px;color:#64748b;font-size:.86rem}

/* V29 dashboard carte : numéros cliquables + vraie position GPS uniquement */
.ops-route-number{cursor:pointer!important;box-shadow:0 8px 18px rgba(15,23,42,.25)!important;border:3px solid #fff!important}
.ops-route-number:hover{transform:scale(1.08)}
.ops-map-dot.bus:not(.live):not(.stale){display:none!important}


/* Card discrète des versions service worker - Gestion desktop uniquement */
.lynk-sw-version-card{
  margin-top:12px;
  padding:10px 11px;
  border:1px solid rgba(21,39,61,.10);
  background:rgba(255,255,255,.58);
  box-shadow:0 8px 18px rgba(17,38,58,.045);
  color:#31506A;
  font-size:10px;
  line-height:1.2;
}
.lynk-sw-version-card-title{
  margin-bottom:7px;
  color:rgba(21,39,61,.52);
  font-size:9px;
  font-weight:900;
  letter-spacing:.06em;
  text-transform:uppercase;
}
.lynk-sw-version-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  padding:4px 0;
  border-top:1px solid rgba(21,39,61,.07);
}
.lynk-sw-version-row:first-of-type{border-top:0;}
.lynk-sw-version-row span{
  color:rgba(21,39,61,.58);
  font-weight:800;
}
.lynk-sw-version-row strong{
  max-width:135px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  color:#15273D;
  font-weight:900;
  text-align:right;
}
body.menu-collapsed .lynk-sw-version-card{display:none!important;}
@media (max-width: 991.98px){
  .lynk-sw-version-card,
  .lynk-sw-version-badge{display:none!important;}
}


/* Version réellement remontée par les comptes client/sous-compte */
.lynk-client-version-chip{
  display:inline-flex;align-items:center;gap:5px;
  max-width:180px;padding:4px 8px;border:1px solid rgba(36,104,250,.16);
  background:rgba(36,104,250,.06);color:#15273D;font-size:11px;font-weight:800;
  line-height:1.1;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.lynk-client-version-chip.is-empty{background:#f8fafc;border-color:#e2e8f0;color:#94a3b8;font-weight:700}
.lynk-client-version-date{display:block;margin-top:4px;color:#94a3b8;font-size:10px;font-weight:700;line-height:1.1}


/* FIX V166 - menu gestion : versions visibles + scroll interne desktop */
@media (min-width: 992px){
  .sidebar{
    height:100vh !important;
    height:100dvh !important;
    max-height:100vh !important;
    max-height:100dvh !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
    -webkit-overflow-scrolling:touch;
    padding-bottom:18px !important;
    scrollbar-width:thin;
    scrollbar-color:rgba(21,39,61,.22) transparent;
  }
  .sidebar::-webkit-scrollbar{width:6px;}
  .sidebar::-webkit-scrollbar-track{background:transparent;}
  .sidebar::-webkit-scrollbar-thumb{background:rgba(21,39,61,.18);}
  .sidebar::-webkit-scrollbar-thumb:hover{background:rgba(21,39,61,.28);}
  .sidebar-footer{
    margin-top:18px !important;
    padding-top:14px !important;
    padding-bottom:8px !important;
  }
  .lynk-sw-version-card{
    width:100%;
    margin-top:10px !important;
    margin-bottom:4px !important;
    padding:8px 10px !important;
    background:rgba(255,255,255,.72) !important;
  }
  .lynk-sw-version-card-title{
    margin-bottom:5px !important;
    font-size:8.5px !important;
  }
  .lynk-sw-version-row{
    padding:3px 0 !important;
    gap:6px !important;
  }
  .lynk-sw-version-row strong{
    max-width:120px !important;
    direction:ltr;
  }
}


/* Versions utilisées - clients / sous-comptes / chauffeurs */
.lynk-client-sub-version-summary{
  margin-top:6px;
  font-size:10.5px;
  line-height:1.2;
  font-weight:800;
  color:#64748b;
  max-width:260px;
}
.lynk-client-sub-version-summary i{color:#2468FA;margin-right:4px;}

/* FIX V166 - sous-comptes : version en vraie colonne dans le modal */
.lynk-subaccounts-table-wrap{
  border:1px solid rgba(21,39,61,.08);
  background:#fff;
  overflow:hidden;
}
.lynk-subaccounts-table{margin-bottom:0;}
.lynk-subaccounts-table thead th{
  font-size:10px;
  text-transform:uppercase;
  letter-spacing:.08em;
  color:#64748b;
  background:#f8fafc;
  border-bottom:1px solid rgba(21,39,61,.08);
  white-space:nowrap;
}
.lynk-subaccounts-table tbody td{
  vertical-align:middle;
  border-color:rgba(21,39,61,.06);
}
.lynk-sub-version-cell{min-width:190px;}
.lynk-sub-dest-row td{
  background:#fbfdff;
  padding-top:10px;
  padding-bottom:12px;
}
.lynk-sub-dest-row + tr td{border-top:1px solid rgba(21,39,61,.10);}
@media (max-width: 991.98px){
  .lynk-subaccounts-table{min-width:920px;}
}


/* Version appli utilisée dans le modal sous-comptes */
.lynk-subaccount-card{
  border:1px solid rgba(21,39,61,.12);
  background:#fff;
  padding:16px;
  margin-bottom:14px;
}
.lynk-subaccount-head{
  display:grid;
  grid-template-columns: 1.05fr 1.35fr .9fr .45fr .95fr auto;
  gap:14px;
  align-items:center;
}
.lynk-subaccount-col{min-width:0;}
.lynk-subaccount-col span,
.lynk-subaccount-col strong{word-break:break-word;}
.lynk-subaccount-version-col .lynk-client-version-chip{
  display:inline-flex;
  max-width:100%;
  align-items:center;
  gap:5px;
  font-size:11px;
  font-weight:700;
  padding:4px 7px;
  border:1px solid rgba(36,104,250,.18);
  background:rgba(36,104,250,.08);
  color:#15273D;
  white-space:normal;
}
.lynk-subaccount-version-col .lynk-client-version-chip.is-empty{
  border-color:rgba(21,39,61,.10);
  background:rgba(21,39,61,.04);
  color:rgba(21,39,61,.55);
}
.lynk-subaccount-version-col .lynk-client-version-date{
  display:block;
  margin-top:3px;
  color:rgba(21,39,61,.55);
  font-size:10px;
  line-height:1.2;
}
.lynk-subaccount-actions{display:flex;gap:8px;justify-content:flex-end;white-space:nowrap;}
.lynk-sub-dest-row-card{margin-top:14px;border-top:1px solid rgba(21,39,61,.10);padding-top:14px;}
.lynk-sub-dest-toggle{width:100%;display:flex;align-items:center;justify-content:space-between;text-align:left;border:1px solid rgba(21,39,61,.10);background:#f8fafc;padding:12px 14px;color:#15273D;}
.lynk-sub-dest-toggle small{color:#607086;font-weight:700;}
.lynk-sub-dest-content{display:none;padding:14px 0 0;}
.lynk-subaccount-card.is-open .lynk-sub-dest-content{display:block;}
.lynk-subaccount-card.is-open .lynk-sub-dest-toggle i{transform:rotate(180deg);}
@media (max-width: 1100px){
  .lynk-subaccount-head{grid-template-columns:1fr 1fr;}
  .lynk-subaccount-actions{justify-content:flex-start;}
}


/* FIX V179 - version utilisée visible dans les cards sous-comptes */
.lynk-subaccount-version-line{
  display:flex;
  align-items:center;
  gap:10px;
  margin-top:10px;
  padding-top:10px;
  border-top:1px solid rgba(21,39,61,.08);
}
.lynk-subaccount-version-line .small-label{
  margin:0;
  min-width:145px;
  color:rgba(21,39,61,.58);
  text-transform:uppercase;
  letter-spacing:.04em;
  font-size:10px;
  font-weight:800;
}
.lynk-subaccount-version-line .lynk-client-version-date{
  margin-left:4px;
}
@media(max-width:768px){
  .lynk-subaccount-version-line{
    align-items:flex-start;
    flex-direction:column;
    gap:5px;
  }
}


/* V180 - version appli dans le modal sous-comptes, à côté de la colonne Droit */
.sub-card .lynk-sub-version-chip{
  display:inline-flex;
  align-items:center;
  gap:5px;
  max-width:100%;
  padding:4px 7px;
  border:1px solid rgba(36,104,250,.18);
  background:rgba(36,104,250,.08);
  color:#15273D;
  font-size:11px;
  font-weight:800;
  line-height:1.15;
  white-space:normal;
}
.sub-card .lynk-sub-version-chip.is-empty{
  border-color:rgba(21,39,61,.10);
  background:rgba(21,39,61,.04);
  color:rgba(21,39,61,.55);
}
.sub-card .lynk-sub-version-date{
  display:block;
  margin-top:3px;
  color:rgba(21,39,61,.55);
  font-size:10px;
  font-weight:700;
  line-height:1.2;
}
.sub-card .lynk-sub-actions-col{
  display:flex;
  justify-content:flex-end;
  gap:6px;
  flex-wrap:wrap;
}
@media (max-width: 991.98px){
  .sub-card .lynk-sub-actions-col{justify-content:flex-start;}
}

.lynk-client-bulk-switch{border:1px solid #dbe3ef;background:#f8fbff;padding:12px 14px 12px 44px;margin-top:2px}.lynk-client-bulk-switch .form-check-label{font-weight:800;color:#15273D}

/* V191 - affectation globale vacations */
.global-assign-preview{border:1px solid #dbe3ef;background:#f8fafc;padding:10px;max-height:420px;overflow:auto}
.global-assign-preview .table{margin-bottom:0;background:#fff}
#btnGlobalAssignVacations{white-space:nowrap}

/* V193 - affectation globale ciblée */
.global-assign-v193 .modal-content{border:0;box-shadow:0 28px 80px rgba(21,39,61,.22)}
.global-assign-v193 .modal-header{background:#15273D;color:#fff;border-bottom:0}
.global-assign-v193 .modal-title{font-weight:950;letter-spacing:-.02em}
.global-assign-v193 .btn-close{filter:invert(1);opacity:.8}
.global-assign-v193-hero{border:1px solid rgba(36,104,250,.18);background:linear-gradient(135deg,#F4F8FB,#fff);padding:14px 16px;display:flex;align-items:center;gap:10px;color:#15273D}
.global-assign-v193-hero strong{display:block;font-weight:950;font-size:1rem}.global-assign-v193-hero small{display:block;color:#64748b;font-weight:750;margin-top:2px}
.global-assign-v193 .form-label{font-weight:900;color:#15273D;font-size:.78rem;text-transform:uppercase;letter-spacing:.04em}.global-assign-v193 .form-control,.global-assign-v193 .form-select{border-radius:0;border-color:#dbe3ef;font-weight:800}.global-assign-v193 .form-check-input{border-radius:0}.global-assign-v193 .form-check-input:checked{background-color:#2468FA;border-color:#2468FA}
.global-assign-v193 #globalAssignCount{display:flex;align-items:baseline;gap:3px;color:#15273D}.global-assign-v193 #globalAssignCount span{font-size:1.08rem;font-weight:950}
.ga-v193-toolbar{display:grid;grid-template-columns:minmax(260px,.9fr) 1.4fr;gap:12px;margin-bottom:12px}.ga-v193-action-summary{border:1px solid #dbe3ef;background:#fff;padding:12px;display:flex;gap:11px;align-items:flex-start;box-shadow:6px 6px 0 rgba(15,23,42,.04)}.ga-v193-action-summary i{font-size:1.25rem}.ga-v193-action-summary strong{display:block;color:#15273D;font-weight:950}.ga-v193-action-summary small{display:block;color:#64748b;font-weight:750;margin-top:2px}.ga-v193-action-summary.ok{border-left:5px solid #16a34a}.ga-v193-action-summary.ok i{color:#16a34a}.ga-v193-action-summary.warning{border-left:5px solid #f59e0b;background:#fffbeb}.ga-v193-action-summary.warning i{color:#d97706}
.ga-v193-select-actions{display:flex;align-items:center;justify-content:flex-end;gap:7px;flex-wrap:wrap}.ga-v193-select-actions .btn{border-radius:0;font-weight:900}.ga-v193-table-wrap{border:1px solid #dbe3ef;background:#fff;max-height:520px;overflow:auto}.ga-v193-table{margin:0}.ga-v193-table thead th{position:sticky;top:0;z-index:2;background:#15273D;color:#fff;border-color:#24384f;font-size:.72rem;text-transform:uppercase;letter-spacing:.04em}.ga-v193-table tbody tr{border-left:5px solid transparent}.ga-v193-table tbody tr.selected{border-left-color:#2468FA;background:#f8fbff}.ga-v193-table tbody tr.warning{border-left-color:#f59e0b;background:#fffaf0}.ga-v193-table td{vertical-align:middle}.ga-v193-table td strong{display:block;color:#15273D;font-weight:900}.ga-v193-table td small{display:block;color:#64748b;font-weight:750}.ga-v193-slot{display:inline-flex;border:1px solid #dbe3ef;background:#F4F8FB;padding:5px 8px;font-weight:950;color:#15273D}.ga-v193-check{width:18px;height:18px;border-radius:0;cursor:pointer}.ga-v193-warnings{display:flex;flex-direction:column;gap:5px}.ga-v193-warnings span{border:1px solid #fde68a;background:#fffbeb;color:#92400e;padding:5px 7px;font-size:.76rem;font-weight:850;line-height:1.25}.ga-v193-warnings i{margin-right:4px}.ga-v193-ok{display:inline-flex;align-items:center;gap:5px;border:1px solid #bbf7d0;background:#f0fdf4;color:#166534;padding:5px 8px;font-weight:900;font-size:.78rem}.global-assign-empty{border:1px dashed #dbe3ef;background:#fff;display:flex;align-items:center;gap:10px;padding:18px;color:#15273D}.global-assign-empty i{font-size:1.6rem;color:#2468FA}.global-assign-empty strong{display:block}.global-assign-empty small{display:block;color:#64748b}
@media(max-width:992px){.ga-v193-toolbar{grid-template-columns:1fr}.ga-v193-select-actions{justify-content:flex-start}.ga-v193-table{min-width:940px}}


/* V252 - Informations terminal / application chauffeur */
.lynk-driver-device-chip,.lynk-driver-app-native,.lynk-driver-app-pwa{white-space:nowrap}
.lynk-driver-app-native{background:#eef6ff;border-color:#bfdbfe;color:#1d4ed8}
.lynk-driver-app-pwa{background:#f5f3ff;border-color:#ddd6fe;color:#6d28d9}
.lynk-driver-gps-badge{display:inline-flex;align-items:center;gap:5px;padding:5px 8px;border-radius:999px;font-size:11px;font-weight:800;line-height:1;border:1px solid transparent;white-space:nowrap}
.lynk-driver-gps-badge.is-ok{background:#ecfdf3;border-color:#bbf7d0;color:#15803d}
.lynk-driver-gps-badge.is-bad{background:#fff1f2;border-color:#fecdd3;color:#be123c}
.lynk-driver-gps-badge.is-unknown{background:#fffbeb;border-color:#fde68a;color:#a16207}
.lynk-driver-gps-badge.is-na{background:#f8fafc;border-color:#e2e8f0;color:#64748b}


/* V314 - modale client + droit depot planning sous-compte */
#clientModal .modal-dialog{width:min(960px,calc(100vw - 32px))!important;max-width:960px!important;min-height:0!important;margin:1.5rem auto!important}
#clientModal .modal-content{min-height:0!important;overflow:hidden!important}
#clientModal .modal-body{max-height:calc(100vh - 155px)!important;overflow-y:auto!important}
#clientModal .lynk-v87-access-card{width:calc(100% - var(--bs-gutter-x));max-width:calc(100% - var(--bs-gutter-x));flex:0 0 calc(100% - var(--bs-gutter-x));margin-left:calc(var(--bs-gutter-x)*.5);margin-right:calc(var(--bs-gutter-x)*.5);min-width:0;overflow:hidden}
#clientModal .lynk-v87-pass-line{grid-template-columns:minmax(0,1fr) auto auto!important}
#clientModal .lynk-v87-pass-box{min-width:0!important;max-width:100%!important}
.lynk-sub-planning-permission-v314{display:flex;align-items:center;justify-content:space-between;gap:16px;border:1px solid #dbe3ef;background:#f8fbff;padding:11px 13px;min-height:56px}
.lynk-sub-planning-permission-v314 .form-check-input{width:2.7rem;height:1.35rem;cursor:pointer}
@media(max-width:991.98px){#clientModal .modal-dialog{width:calc(100vw - 24px)!important;max-width:calc(100vw - 24px)!important;min-height:0!important;margin:12px auto!important}#clientModal .modal-content{min-height:0!important}#clientModal .modal-body{max-height:calc(100vh - 135px)!important}.lynk-sub-planning-permission-v314{align-items:flex-start}}
@media(max-width:650px){#clientModal .lynk-v87-pass-line{grid-template-columns:1fr!important}}
