@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@600;700;800&display=swap');
.client-dashboard-block{margin-bottom:18px}.client-dashboard-block .section{margin:0 0 14px}.client-dashboard-block .primary{width:auto;margin:0}.dashboard-list{display:grid;grid-template-columns:1fr;gap:10px}.dashboard-list .schedule-item{display:flex;align-items:center;justify-content:space-between;gap:16px}.dashboard-list strong{font:800 24px Manrope;color:var(--blue)}.client-dashboard-available{grid-template-columns:repeat(2,minmax(0,1fr))}@media(max-width:680px){.dashboard-list,.client-dashboard-available{grid-template-columns:1fr}.client-dashboard-block .section{align-items:flex-start;flex-wrap:wrap}.client-dashboard-block .section .primary{width:100%}.client-dashboard-block .table{min-width:690px}}
.badge.in_process{background:#e0eeff;color:#2864a4}
:root{--ink:#092d5d;--muted:#66717d;--line:#dfe6ee;--bg:#f5f8fb;--nav:#06346f;--blue:#003d82;--green:#69bd2a;--lime:#92d64d;--orange:#f0b323;--white:#fff}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font-family:'DM Sans',sans-serif}button,input,select,textarea{font:inherit}button{cursor:pointer;border:0}.brand-logo{display:flex;align-items:center}.brand-logo img{display:block;width:100%;height:auto}.on-blue{width:220px;background:#fff;border:1px solid #d6e1ec;border-radius:10px;padding:10px 12px;box-shadow:0 6px 18px #001f471f}.client-logo{background:#fff;border-color:#caddec;box-shadow:0 7px 20px #001f4740}.on-light{width:300px;margin-bottom:38px}.login{min-height:100vh;display:grid;grid-template-columns:1.15fr .85fr}.intro{padding:10vw;background:var(--nav);color:#fff;display:flex;flex-direction:column;justify-content:space-between;background-image:radial-gradient(circle at 80% 18%,#1760a3 0 3%,transparent 27%),linear-gradient(135deg,#06295b,#064a89)}.intro h1{font:800 clamp(38px,5vw,68px)/1.05 Manrope;max-width:700px;margin:0}.intro p{font-size:17px;color:#d7e5f6;max-width:490px}.login-card{display:flex;align-items:center;justify-content:center;padding:35px}.form-card{width:min(390px,100%)}h2{font:800 30px Manrope;margin:0 0 8px}.sub{color:var(--muted);margin:0 0 28px}.field{display:grid;gap:7px;margin:14px 0}.field label{font-size:13px;font-weight:700}.field input,.field select,.field textarea{border:1px solid #d4dee9;border-radius:10px;padding:12px;background:#fff;outline-color:var(--green)}textarea{min-height:76px;resize:vertical}.primary{background:var(--green);color:#072d5e;border-radius:10px;padding:12px 16px;font-weight:800;width:100%;margin-top:10px}.hint{margin-top:24px;padding:14px;border-radius:10px;background:#edf5e7;color:#315b1d;font-size:13px}.app-shell{display:grid;grid-template-columns:245px 1fr;min-height:100vh}.side{background:var(--nav);color:#d9e7f7;padding:25px 14px;display:flex;flex-direction:column}.side .brand-logo{margin:0 auto 42px}.nav button{display:flex;gap:12px;align-items:center;width:100%;padding:12px;margin:3px 0;border-radius:9px;background:transparent;color:inherit;text-align:left}.nav button.active,.nav button:hover{background:#175596;color:#fff}.logout{margin-top:auto;background:transparent;color:#d9e7f7;text-align:left;padding:12px}.content{padding:32px 4vw;max-width:1480px;width:100%}.top{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:28px}.eyebrow{text-transform:uppercase;letter-spacing:.1em;font-size:11px;color:#4f9b1d;font-weight:800}.top h1{font:800 30px Manrope;margin:5px 0}.user{color:var(--muted);font-size:14px}.metrics{display:grid;grid-template-columns:repeat(5,minmax(130px,1fr));gap:16px;margin-bottom:27px}.metric,.card{background:#fff;border:1px solid var(--line);border-radius:15px}.metric{padding:18px}.metric strong{display:block;font:800 28px Manrope;margin-top:8px}.metric small{color:var(--muted)}.section{display:flex;justify-content:space-between;align-items:center;margin:25px 0 14px}.section h3{margin:0;font:800 19px Manrope}.card{padding:20px}.grid{display:grid;grid-template-columns:repeat(3,minmax(230px,1fr));gap:16px}.vehicle{padding:0;overflow:hidden}.vehicle-art{height:104px;background:linear-gradient(135deg,#e3f2f9,#b8dbef);display:flex;align-items:center;justify-content:center;font-size:43px}.vehicle-body{padding:16px}.vehicle h3{font:800 17px Manrope;margin:4px 0}.meta{color:var(--muted);font-size:13px;margin:5px 0}.tags{display:flex;gap:6px;flex-wrap:wrap;margin:12px 0}.tag,.badge{font-size:11px;font-weight:700;padding:5px 8px;border-radius:20px;background:#edf4fa;color:#205382}.badge.pending{background:#fff3d9;color:#a76c00}.badge.approved,.badge.confirmed{background:#e7f5dd;color:#3e7c15}.badge.rejected,.badge.cancelled{background:#ffe5e5;color:#b53737}.badge.in_service{background:#e0eeff;color:#2864a4}.small-btn{background:#e6f4dc;color:#397f16;border-radius:8px;padding:9px 12px;font-weight:800}.table-wrap{overflow:auto}.table{width:100%;border-collapse:collapse;font-size:14px}.table th{text-align:left;color:var(--muted);font-size:11px;text-transform:uppercase;letter-spacing:.06em}.table td,.table th{padding:13px 8px;border-bottom:1px solid var(--line);white-space:nowrap}.actions{display:flex;gap:6px}.secondary{background:#edf3f9;color:#174d82;border-radius:8px;padding:8px 10px;font-weight:700}.danger{background:#fff0f0;color:#b53737;border-radius:8px;padding:8px 10px}.modal{position:fixed;inset:0;background:#052d60aa;display:flex;align-items:center;justify-content:center;padding:20px;z-index:3}.modal .card{width:min(650px,100%);max-height:90vh;overflow:auto}.modal-head{display:flex;justify-content:space-between;align-items:center}.modal h2{font-size:23px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:0 14px}.form-grid .wide{grid-column:1/-1}.close{background:#edf3f9;border-radius:50%;height:32px;width:32px}.notice{padding:12px 14px;margin:12px 0;border-radius:9px;background:#e6f4dc;color:#397f16}.notice.error{background:#ffe9e7;color:#a5362e}.empty{color:var(--muted);padding:24px;text-align:center}.schedule{display:grid;gap:10px}.schedule-item{border-left:3px solid var(--green);background:#f6fafc;padding:12px;border-radius:0 8px 8px 0}.assignment-columns{display:grid;grid-template-columns:1fr 1fr;gap:22px}.assignment-columns h4{margin:0 0 10px;font:800 15px Manrope}.assignment-choice{display:block;margin-bottom:8px;cursor:pointer}.priority-row{display:flex;align-items:center;gap:10px;min-height:52px;margin-bottom:8px;padding:9px 10px;border:1px solid var(--line);border-radius:9px;background:#fff}.priority-number{display:grid;place-items:center;width:27px;height:27px;border-radius:50%;background:#e6f4dc;color:#397f16}.priority-actions{display:flex;gap:5px;margin-left:auto}.priority-actions button{width:34px;padding:6px}.priority-actions button:disabled{opacity:.4;cursor:not-allowed}.mobile-nav{display:none}@media(max-width:900px){.metrics{grid-template-columns:repeat(3,1fr)}.grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:680px){.on-light{width:250px;margin-bottom:30px}.login{grid-template-columns:1fr}.intro{display:none}.app-shell{grid-template-columns:1fr}.side{display:none}.content{padding:22px 16px 80px}.mobile-nav{display:flex;position:fixed;bottom:0;inset-inline:0;z-index:2;background:var(--nav);justify-content:space-around;padding:7px}.mobile-nav button{background:transparent;color:#d7e4df;padding:8px;font-size:11px}.metrics{grid-template-columns:repeat(2,1fr);gap:10px}.metric{padding:14px}.metrics .metric:last-child{display:none}.grid{grid-template-columns:1fr}.form-grid{grid-template-columns:1fr}.form-grid .wide{grid-column:auto}.assignment-columns{grid-template-columns:1fr}.top{gap:8px}.top h1{font-size:25px}.table{font-size:12px}}
.client-vehicle-list{display:grid;gap:12px}.client-vehicle-card{display:grid;grid-template-columns:auto 1fr;gap:13px;align-items:start;padding:17px;border:1px solid var(--line);border-radius:12px;background:#fff;cursor:pointer}.client-vehicle-card:has(input:disabled){opacity:.66;background:#f8fafc}.client-vehicle-card input{margin-top:7px;accent-color:var(--green)}.client-vehicle-title{display:flex;align-items:center;gap:10px;margin-bottom:11px;font-size:16px}.client-vehicle-line{margin:5px 0;color:var(--ink)}.client-vehicle-line span{font-weight:700;color:var(--muted)}.client-vehicle-tech{margin-top:10px;font-size:13px;color:var(--muted)}
.modal .card.trip-request-dialog{width:min(920px,100%)}.trip-request-dialog .service-card{margin:20px 0;padding:18px;border:1px solid var(--line);border-radius:12px;background:#f9fbfd}.trip-request-dialog .service-card h3{margin:0 0 4px;font:800 18px Manrope}.trip-request-dialog .driver-label{display:block;color:var(--muted);margin-bottom:14px}.trip-request-dialog .serviceStopRow{display:grid;grid-template-columns:minmax(210px,1fr) minmax(250px,1.2fr) auto auto;gap:10px;align-items:center;margin:10px 0}.trip-request-dialog .serviceStopRow select,.trip-request-dialog .serviceStopRow textarea{width:100%;margin:0}.trip-request-dialog .serviceStopRow textarea{min-height:54px}.trip-request-dialog .stop-order-actions{display:flex;gap:4px}.trip-request-dialog .stop-order-actions button{width:34px;height:34px;padding:0}.trip-request-dialog .addServiceStop{margin-top:4px}.trip-request-dialog .service-list{display:grid;gap:4px}@media(max-width:680px){.modal .card.trip-request-dialog{width:100%}.trip-request-dialog .serviceStopRow{grid-template-columns:1fr auto}.trip-request-dialog .serviceStopRow textarea{grid-column:1/-1}.trip-request-dialog .stop-order-actions{grid-column:1}.trip-request-dialog .serviceStopRow .removeServiceStop{grid-column:2;grid-row:3}}
.modal .card.trip-summary-dialog{width:min(920px,100%)}.trip-summary-dialog .schedule{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}.trip-summary-dialog .schedule-item{min-height:104px}.trip-summary-dialog .summary-driver{color:var(--muted)}@media(max-width:680px){.trip-summary-dialog .schedule{grid-template-columns:1fr}}
.provider-trips-card{padding:20px 28px}.provider-trips-card .table{table-layout:fixed;min-width:760px}.provider-trips-card .table th:nth-child(1){width:9%}.provider-trips-card .table th:nth-child(2){width:18%}.provider-trips-card .table th:nth-child(3){width:24%}.provider-trips-card .table th:nth-child(4){width:15%}.provider-trips-card .table th:nth-child(5){width:34%}.provider-trips-card .table td{white-space:normal;vertical-align:middle}.provider-trips-card .actions{flex-wrap:wrap;align-items:center}.provider-trips-card .primary{width:auto;margin:0}.provider-trips-filter{max-width:300px}@media(max-width:680px){.provider-trips-card{padding:14px}.provider-trips-card .table{min-width:640px}}
.modal .card.trip-detail-dialog{width:min(980px,100%)}.trip-detail-dialog .schedule{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.trip-detail-dialog .schedule-item{min-height:0}.trip-detail-dialog .detail-wide{grid-column:1/-1}.trip-detail-dialog .delivery-detail-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin-top:10px}.trip-detail-dialog .delivery-detail{padding:11px;border:1px solid var(--line);border-radius:9px;background:#fff}.trip-detail-dialog .delivery-detail small{color:var(--muted)}@media(max-width:680px){.trip-detail-dialog .schedule,.trip-detail-dialog .delivery-detail-list{grid-template-columns:1fr}.trip-detail-dialog .detail-wide{grid-column:auto}}
.assigned-time{display:grid;grid-template-columns:1fr 1fr;gap:12px;max-width:360px;margin:12px 0}.assigned-time .field{margin:0}.request-date-summary{margin:0 0 14px;padding:12px;border-radius:9px;background:#edf4fa}.trip-request-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.trip-request-summary ol{margin:6px 0 0;padding-left:20px}.finance-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin:16px 0}.finance-metrics{grid-template-columns:repeat(5,minmax(140px,1fr))}.finance-filter{margin-bottom:16px}.provider-billing-table td,.provider-billing-table th{white-space:normal}.profile-card{max-width:820px}.e8-modal{z-index:20}@media(max-width:680px){.finance-grid{grid-template-columns:1fr}.finance-metrics{grid-template-columns:repeat(2,1fr)}.finance-metrics .metric:last-child{display:block}.finance-grid .table td,.finance-grid .table th{padding:10px 6px}.provider-billing-table{font-size:12px}.provider-billing-table td,.provider-billing-table th{white-space:normal;min-width:90px}.assigned-time{max-width:none}.trip-request-summary{grid-template-columns:1fr}}
.finance-tabs{display:flex;gap:8px;flex-wrap:wrap;margin:18px 0}.finance-tabs button{padding:10px 16px;border-radius:9px;background:#edf3f9;color:#174d82;font-weight:800}.finance-tabs button.active{background:#06346f;color:#fff}.finance-pages{display:grid;gap:16px}.finance-page{display:grid;gap:16px}.finance-page[hidden],.balance-page[hidden]{display:none!important}.finance-page-heading{display:flex;align-items:end;justify-content:space-between;gap:16px;margin:4px 0}.finance-page-heading h2{font-size:24px;margin:0}.finance-page-heading p{margin:0;color:var(--muted);font-size:14px}.finance-subtabs{margin:0}.balance-page{display:grid;gap:16px}@media(max-width:680px){.finance-page-heading{display:block}.finance-page-heading p{margin-top:6px}.finance-tabs{gap:6px}.finance-tabs button{padding:9px 12px;font-size:13px}}


/* === MOBILE RESPONSIVE V4 === */

@media(max-width:680px){

  html,
  body{
    width:100%;
    max-width:100%;
    overflow-x:hidden;
  }

  .app-shell,
  .content,
  #page{
    width:100%;
    min-width:0;
    max-width:100%;
  }

  .content{
    padding:16px 12px 95px;
  }

  .card,
  .form-grid,
  .field,
  .service-list,
  .service-card{
    min-width:0;
    max-width:100%;
  }

  /* MODALES */

  .modal{
    padding:8px;
    align-items:flex-start;
    overflow-y:auto;
  }

  .modal .card,
  .modal .card.trip-request-dialog,
  .modal .card.trip-detail-dialog,
  .modal .card.trip-summary-dialog{
    width:100%;
    max-width:100%;
    max-height:none;
    margin:8px 0 80px;
    padding:14px;
    overflow-x:hidden;
  }

  .modal-head{
    position:sticky;
    top:0;
    z-index:5;
    background:#fff;
    padding-bottom:8px;
  }

  /* INPUTS */

  .field input,
  .field select,
  .field textarea{
    width:100%;
    min-width:0;
    max-width:100%;
  }

  /* SOLICITAR VIAJE CLIENTE */

  .trip-request-dialog .service-card{
    padding:12px;
    margin:12px 0;
  }

  .trip-request-dialog .serviceStopRow{
    display:flex;
    flex-direction:column;
    align-items:stretch;
    gap:8px;
  }

  .trip-request-dialog .serviceStopRow select,
  .trip-request-dialog .serviceStopRow textarea{
    width:100%;
    max-width:100%;
  }

  .trip-request-dialog .stop-order-actions{
    display:flex;
    width:100%;
    gap:6px;
  }

  .trip-request-dialog .stop-order-actions button{
    flex:1;
    width:auto;
  }

  .trip-request-dialog .removeServiceStop{
    width:100%;
  }

  /* ACCIONES */

  .actions{
    width:100%;
    flex-wrap:wrap;
  }

  .actions select,
  .actions input,
  .actions textarea{
    flex:1 1 100%;
    min-width:0;
  }

  /* TABLAS GENERALES */

  .table-wrap{
    width:100%;
    max-width:100%;
    overflow-x:auto;
    -webkit-overflow-scrolling:touch;
  }

  .table{
    min-width:100%;
  }

  .table th,
  .table td{
    padding:10px 7px;
  }

  /* KPI */

  .metrics{
    grid-template-columns:1fr 1fr;
  }

  .metrics .metric:last-child{
    display:block;
  }

  /* HEADER */

  .top{
    flex-direction:column;
    align-items:flex-start;
  }

  .top .user{
    max-width:100%;
    overflow-wrap:anywhere;
  }

  /* FACTURACION EMPRESA */

  .company-billing-download{
    margin-bottom:14px;
  }

  .company-billing-download button{
    width:100%;
  }

  /* NAV INFERIOR */

  .mobile-nav{
    overflow-x:auto;
    justify-content:flex-start;
    gap:2px;
    padding:6px;
  }

  .mobile-nav button{
    flex:0 0 auto;
    min-width:76px;
  }


  /* =====================================================
     CLIENTE - ENTREGAS REALIZADAS
     TABLA -> TARJETAS MOVILES
     ===================================================== */

  #deliveriesBody{
    display:block;
    width:100%;
  }

  #deliveriesBody tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  #deliveriesBody td{
    display:grid;
    grid-template-columns:105px minmax(0,1fr);
    gap:10px;
    width:100%;
    padding:8px 0;
    white-space:normal;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  #deliveriesBody td:last-child{
    border-bottom:0;
  }

  #deliveriesBody td:nth-child(1)::before{
    content:'Fecha';
    font-weight:700;
    color:var(--muted);
  }

  #deliveriesBody td:nth-child(2)::before{
    content:'Chofer';
    font-weight:700;
    color:var(--muted);
  }

  #deliveriesBody td:nth-child(3)::before{
    content:'Entrega';
    font-weight:700;
    color:var(--muted);
  }

  #deliveriesBody td:nth-child(4)::before{
    content:'Observaciones';
    font-weight:700;
    color:var(--muted);
  }

  #deliveriesBody td:nth-child(5)::before{
    content:'Fotos';
    font-weight:700;
    color:var(--muted);
  }

  #deliveriesBody .secondary{
    width:100%;
  }

  #deliveriesBody
    + #deliveriesEmpty{
    width:100%;
  }

  #deliveriesBody{
    border:0;
  }

  #deliveriesBody tr td{
    min-width:0;
    max-width:100%;
  }

  /* ocultar encabezado solamente en Entregas */

  #deliveriesBody
    > tr:first-child{
    margin-top:0;
  }

  #page table:has(#deliveriesBody) thead{
    display:none;
  }

  #page table:has(#deliveriesBody){
    display:block;
    width:100%;
    min-width:0;
  }

}


/* === PROVIDER COMPANY MOBILE TABLE CARDS === */
@media(max-width:680px){

  /* VIAJES EMPRESA */
  #page table:has(.companyTripDriver),
  #page table:has(.companyTripRemito),

  /* CHOFERES EMPRESA */
  #page table:has(.companyDriverToggle),
  #page table:has(.companyDriverDelete),

  /* VEHICULOS EMPRESA */
  #page table:has(.companyVehicleToggle),
  #page table:has(.companyVehicleDelete){
    display:block;
    width:100%;
    min-width:0;
  }

  #page table:has(.companyTripDriver) thead,
  #page table:has(.companyTripRemito) thead,
  #page table:has(.companyDriverToggle) thead,
  #page table:has(.companyDriverDelete) thead,
  #page table:has(.companyVehicleToggle) thead,
  #page table:has(.companyVehicleDelete) thead{
    display:none;
  }

  #page table:has(.companyTripDriver) tbody,
  #page table:has(.companyTripRemito) tbody,
  #page table:has(.companyDriverToggle) tbody,
  #page table:has(.companyDriverDelete) tbody,
  #page table:has(.companyVehicleToggle) tbody,
  #page table:has(.companyVehicleDelete) tbody{
    display:block;
    width:100%;
  }

  #page table:has(.companyTripDriver) tr,
  #page table:has(.companyTripRemito) tr,
  #page table:has(.companyDriverToggle) tr,
  #page table:has(.companyDriverDelete) tr,
  #page table:has(.companyVehicleToggle) tr,
  #page table:has(.companyVehicleDelete) tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  #page table:has(.companyTripDriver) td,
  #page table:has(.companyTripRemito) td,
  #page table:has(.companyDriverToggle) td,
  #page table:has(.companyDriverDelete) td,
  #page table:has(.companyVehicleToggle) td,
  #page table:has(.companyVehicleDelete) td{
    display:grid;
    grid-template-columns:95px minmax(0,1fr);
    gap:10px;
    width:100%;
    min-width:0;
    padding:8px 0;
    white-space:normal;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  #page table:has(.companyTripDriver) td:last-child,
  #page table:has(.companyTripRemito) td:last-child,
  #page table:has(.companyDriverToggle) td:last-child,
  #page table:has(.companyDriverDelete) td:last-child,
  #page table:has(.companyVehicleToggle) td:last-child,
  #page table:has(.companyVehicleDelete) td:last-child{
    border-bottom:0;
  }

  /* VIAJES */
  #page table:has(.companyTripDriver) td:nth-child(1)::before,
  #page table:has(.companyTripRemito) td:nth-child(1)::before{
    content:'Viaje';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyTripDriver) td:nth-child(2)::before,
  #page table:has(.companyTripRemito) td:nth-child(2)::before{
    content:'Fecha';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyTripDriver) td:nth-child(3)::before,
  #page table:has(.companyTripRemito) td:nth-child(3)::before{
    content:'Cliente';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyTripDriver) td:nth-child(4)::before,
  #page table:has(.companyTripRemito) td:nth-child(4)::before{
    content:'Vehículo';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyTripDriver) td:nth-child(5)::before,
  #page table:has(.companyTripRemito) td:nth-child(5)::before{
    content:'Estado';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyTripDriver) td:nth-child(6)::before,
  #page table:has(.companyTripRemito) td:nth-child(6)::before{
    content:'Chofer';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyTripDriver) td:nth-child(7)::before,
  #page table:has(.companyTripRemito) td:nth-child(7)::before{
    content:'Acciones';
    font-weight:700;
    color:var(--muted);
  }

  /* CHOFERES */
  #page table:has(.companyDriverToggle) td:nth-child(1)::before,
  #page table:has(.companyDriverDelete) td:nth-child(1)::before{
    content:'Chofer';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyDriverToggle) td:nth-child(2)::before,
  #page table:has(.companyDriverDelete) td:nth-child(2)::before{
    content:'Teléfono';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyDriverToggle) td:nth-child(3)::before,
  #page table:has(.companyDriverDelete) td:nth-child(3)::before{
    content:'Usuario';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyDriverToggle) td:nth-child(4)::before,
  #page table:has(.companyDriverDelete) td:nth-child(4)::before{
    content:'Estado';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyDriverToggle) td:nth-child(5)::before,
  #page table:has(.companyDriverDelete) td:nth-child(5)::before{
    content:'Acciones';
    font-weight:700;
    color:var(--muted);
  }

  /* VEHICULOS */
  #page table:has(.companyVehicleToggle) td:nth-child(1)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(1)::before{
    content:'Categoría';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyVehicleToggle) td:nth-child(2)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(2)::before{
    content:'Vehículo';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyVehicleToggle) td:nth-child(3)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(3)::before{
    content:'Patente';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyVehicleToggle) td:nth-child(4)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(4)::before{
    content:'Capacidad';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyVehicleToggle) td:nth-child(5)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(5)::before{
    content:'Pallets';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyVehicleToggle) td:nth-child(6)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(6)::before{
    content:'Estado';
    font-weight:700;
    color:var(--muted);
  }

  #page table:has(.companyVehicleToggle) td:nth-child(7)::before,
  #page table:has(.companyVehicleDelete) td:nth-child(7)::before{
    content:'Acciones';
    font-weight:700;
    color:var(--muted);
  }

  /* controles */
  #page table:has(.companyTripDriver) select,
  #page table:has(.companyTripRemito) button,
  #page table:has(.companyDriverToggle) button,
  #page table:has(.companyDriverDelete) button,
  #page table:has(.companyVehicleToggle) button,
  #page table:has(.companyVehicleDelete) button{
    width:100%;
    max-width:100%;
  }

  .table-wrap{
    overflow-x:hidden;
  }
}


/* === COMPANY DRIVER ACTIONS MOBILE FIX === */
@media(max-width:680px){

  #page table:has(.companyDriverToggle) td:nth-child(5),
  #page table:has(.companyDriverDelete) td:nth-child(5){
    display:grid;
    grid-template-columns:95px minmax(0,1fr);
    align-items:start;
  }

  #page table:has(.companyDriverToggle) td:nth-child(5) > *,
  #page table:has(.companyDriverDelete) td:nth-child(5) > *{
    grid-column:2;
    width:100%;
    margin:0 0 8px 0;
  }

  #page table:has(.companyDriverToggle) td:nth-child(5)::before,
  #page table:has(.companyDriverDelete) td:nth-child(5)::before{
    grid-column:1;
    grid-row:1 / span 2;
  }

  #page table:has(.companyDriverToggle) .companyDriverToggle,
  #page table:has(.companyDriverDelete) .companyDriverToggle,
  #page table:has(.companyDriverToggle) .companyDriverDelete,
  #page table:has(.companyDriverDelete) .companyDriverDelete{
    width:100%;
    max-width:100%;
    display:block;
  }
}


/* === COMPANY ROUTE MOBILE CARDS V2 === */
@media(max-width:680px){

  /* solamente Empresa Proveedora: Viajes y Vehículos */
  #page[data-page-route="companyTrips"] .table-wrap,
  #page[data-page-route="companyVehicles"] .table-wrap{
    width:100%;
    max-width:100%;
    overflow-x:hidden;
  }

  #page[data-page-route="companyTrips"] table,
  #page[data-page-route="companyVehicles"] table{
    display:block;
    width:100%;
    min-width:0 !important;
    table-layout:auto !important;
  }

  #page[data-page-route="companyTrips"] thead,
  #page[data-page-route="companyVehicles"] thead{
    display:none;
  }

  #page[data-page-route="companyTrips"] tbody,
  #page[data-page-route="companyVehicles"] tbody{
    display:block;
    width:100%;
  }

  #page[data-page-route="companyTrips"] tbody tr,
  #page[data-page-route="companyVehicles"] tbody tr{
    display:block;
    width:100%;
    margin:0 0 12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  #page[data-page-route="companyTrips"] tbody td,
  #page[data-page-route="companyVehicles"] tbody td{
    display:grid;
    grid-template-columns:95px minmax(0,1fr);
    gap:10px;
    align-items:start;
    width:100%;
    min-width:0 !important;
    max-width:100%;
    padding:8px 0;
    white-space:normal !important;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  #page[data-page-route="companyTrips"] tbody td:last-child,
  #page[data-page-route="companyVehicles"] tbody td:last-child{
    border-bottom:0;
  }

  #page[data-page-route="companyTrips"] tbody td::before,
  #page[data-page-route="companyVehicles"] tbody td::before{
    content:attr(data-label);
    font-weight:700;
    color:var(--muted);
  }

  /* selects / botones */
  #page[data-page-route="companyTrips"] tbody td select,
  #page[data-page-route="companyTrips"] tbody td button,
  #page[data-page-route="companyVehicles"] tbody td select,
  #page[data-page-route="companyVehicles"] tbody td button{
    width:100%;
    max-width:100%;
    min-width:0;
  }

  #page[data-page-route="companyTrips"] .actions,
  #page[data-page-route="companyVehicles"] .actions{
    display:grid;
    grid-template-columns:1fr;
    width:100%;
    gap:7px;
  }

  #page[data-page-route="companyTrips"] tbody td:has(.actions),
  #page[data-page-route="companyVehicles"] tbody td:has(.actions){
    align-items:start;
  }

}


/* === COMPANY DRIVER TRIPS MOBILE CARDS === */
@media(max-width:680px){

  .table-wrap:has(.company-driver-trips-table){
    width:100%;
    max-width:100%;
    overflow-x:hidden;
  }

  .company-driver-trips-table{
    display:block;
    width:100%;
    min-width:0 !important;
  }

  .company-driver-trips-table thead{
    display:none;
  }

  .company-driver-trips-table tbody{
    display:block;
    width:100%;
  }

  .company-driver-trips-table tbody tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  .company-driver-trips-table tbody td{
    display:grid;
    grid-template-columns:100px minmax(0,1fr);
    gap:10px;
    width:100%;
    min-width:0 !important;
    padding:8px 0;
    white-space:normal !important;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  .company-driver-trips-table tbody td:last-child{
    border-bottom:0;
  }

  .company-driver-trips-table tbody td::before{
    content:attr(data-label);
    font-weight:700;
    color:var(--muted);
  }

  .company-driver-trips-table button,
  .company-driver-trips-table select{
    width:100%;
    max-width:100%;
  }

  .company-driver-trips-table .actions{
    display:grid;
    grid-template-columns:1fr;
    gap:7px;
    width:100%;
  }
}


/* === DELIVERY CAMERA LANDSCAPE MOBILE === */

#cameraBox{
  width:100%;
  max-width:640px;
  margin:14px auto 0;
}

#cameraPreview{
  display:block !important;
  width:100% !important;
  aspect-ratio:16 / 9;
  height:auto !important;
  max-height:none !important;
  object-fit:cover;
  object-position:center;
  margin:0 auto;
  background:#111;
}

#cameraBox .actions{
  justify-content:center;
  margin-top:12px;
}

#photoPreviews{
  width:100%;
  max-width:640px;
  margin-left:auto;
  margin-right:auto;
}

@media(max-width:680px){

  #deliveryForm{
    width:100%;
    max-width:100%;
  }

  #deliveryForm .field{
    width:100%;
    min-width:0;
  }

  #cameraBox{
    width:100%;
    max-width:100%;
    margin:12px auto 0;
  }

  #cameraPreview{
    width:100% !important;
    aspect-ratio:16 / 9;
    height:auto !important;
    object-fit:cover;
    object-position:center;
  }

  #cameraBox .actions{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:8px;
    width:100%;
  }

  #cameraBox .actions button{
    width:100%;
    min-width:0;
  }

  #photoPreviews{
    width:100%;
    max-width:100%;
    margin:12px auto;
  }
}


/* === DELIVERY CAMERA FLOW V2 === */

#deliveryForm #cameraBox{
  width:100%;
  margin:0 auto 12px;
}

#deliveryForm #cameraPreview{
  display:block !important;
  width:100% !important;
  aspect-ratio:16 / 9;
  height:auto !important;
  object-fit:cover;
  object-position:center;
}

#deliveryForm #photoCount{
  display:block;
  width:100%;
  text-align:center;
  margin:8px 0;
}

#deliveryForm #photoPreviews{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:8px;
  width:100%;
  margin:8px 0 16px;
}

#deliveryForm #photoPreviews .schedule-item{
  width:100%;
  min-width:0;
  margin:0;
}

#deliveryForm #photoPreviews img{
  width:100% !important;
  aspect-ratio:16 / 9 !important;
  height:auto !important;
  object-fit:cover !important;
}

#deliveryForm textarea[name="notes"]{
  width:100%;
  min-height:80px;
}

#deliveryForm #confirmDeliverySubmit{
  width:100%;
  margin-top:8px;
}

@media(max-width:680px){

  #deliveryForm #cameraPreview{
    aspect-ratio:16 / 9;
  }

  #deliveryForm #cameraBox .actions{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:8px;
  }

  #deliveryForm #photoPreviews{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}


/* === CLIENT TRIPS MOBILE CARDS === */
@media(max-width:680px){

  #clientTripsBody{
    display:block;
    width:100%;
  }

  #clientTripsBody tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  #clientTripsBody td{
    display:grid;
    grid-template-columns:100px minmax(0,1fr);
    gap:10px;
    width:100%;
    min-width:0 !important;
    padding:8px 0;
    white-space:normal !important;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  #clientTripsBody td:last-child{
    border-bottom:0;
  }

  #clientTripsBody td::before{
    content:attr(data-label);
    font-weight:700;
    color:var(--muted);
  }

  #clientTripsBody{
    border:0;
  }

  #clientTripsBody.closest{
    overflow-x:hidden;
  }

  table:has(#clientTripsBody){
    display:block;
    width:100%;
    min-width:0 !important;
  }

  table:has(#clientTripsBody) thead{
    display:none;
  }

  table:has(#clientTripsBody) tbody{
    width:100%;
  }

  table:has(#clientTripsBody) button{
    width:100%;
    margin:3px 0;
  }

  .table-wrap:has(#clientTripsBody){
    overflow-x:hidden;
  }
}


/* === CLIENT TRIPS MOBILE CARDS V2 === */
@media(max-width:680px){

  .table-wrap:has(.client-trips-table){
    overflow-x:hidden;
  }

  .client-trips-table{
    display:block;
    width:100%;
    min-width:0 !important;
  }

  .client-trips-table thead{
    display:none;
  }

  .client-trips-table tbody{
    display:block;
    width:100%;
  }

  .client-trips-table tbody tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  .client-trips-table tbody td{
    display:grid;
    grid-template-columns:100px minmax(0,1fr);
    gap:10px;
    width:100%;
    min-width:0 !important;
    padding:8px 0;
    white-space:normal !important;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  .client-trips-table tbody td:last-child{
    border-bottom:0;
  }

  .client-trips-table tbody td::before{
    content:attr(data-label);
    font-weight:700;
    color:var(--muted);
  }

  .client-trips-table button{
    width:100%;
    margin:3px 0;
  }
}


/* === PROVIDER COMPANY BILLING MOBILE SCROLL FIX === */
@media(max-width:680px){

  #page[data-page-route="companyBilling"] .table-wrap{
    width:100%;
    max-width:100%;
    overflow-x:auto !important;
    overflow-y:hidden;
    -webkit-overflow-scrolling:touch;
  }

  #page[data-page-route="companyBilling"] table{
    width:max-content;
    min-width:760px !important;
  }

  #page[data-page-route="companyBilling"] th,
  #page[data-page-route="companyBilling"] td{
    white-space:nowrap !important;
  }

  #page[data-page-route="companyBilling"] .company-billing-download{
    width:100%;
  }

}


/* === ADMIN WIDE TABLE MOBILE SCROLL FIX === */
@media(max-width:680px){

  #page[data-page-route="billing"] .table-wrap,
  #page[data-page-route="reservations"] .table-wrap,
  #page[data-page-route="clients"] .table-wrap{
    width:100%;
    max-width:100%;
    overflow-x:auto !important;
    overflow-y:hidden;
    -webkit-overflow-scrolling:touch;
    touch-action:pan-x pan-y;
  }

  #page[data-page-route="billing"] .table,
  #page[data-page-route="reservations"] .table,
  #page[data-page-route="clients"] .table{
    width:max-content;
    min-width:760px !important;
  }

  #page[data-page-route="billing"] th,
  #page[data-page-route="billing"] td,
  #page[data-page-route="reservations"] th,
  #page[data-page-route="reservations"] td,
  #page[data-page-route="clients"] th,
  #page[data-page-route="clients"] td{
    white-space:nowrap !important;
  }

}



@media(max-width:680px){

  .table-wrap:has(.admin-billing-mobile-table){
    overflow:visible !important;
    width:100%;
    max-width:100%;
  }

  .admin-billing-mobile-table{
    display:block;
    width:100%;
    min-width:0 !important;
  }

  .admin-billing-mobile-table thead{
    display:none;
  }

  .admin-billing-mobile-table tbody{
    display:block;
    width:100%;
  }

  .admin-billing-mobile-table tbody tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  .admin-billing-mobile-table tbody td{
    display:grid;
    grid-template-columns:100px minmax(0,1fr);
    gap:10px;
    align-items:start;
    width:100%;
    min-width:0 !important;
    max-width:100%;
    padding:8px 0;
    white-space:normal !important;
    overflow-wrap:anywhere;
    border-bottom:1px solid var(--line);
  }

  .admin-billing-mobile-table tbody td:last-child{
    border-bottom:0;
  }

  .admin-billing-mobile-table tbody td::before{
    content:attr(data-label);
    font-weight:700;
    color:var(--muted);
  }

  .admin-billing-mobile-table button,
  .admin-billing-mobile-table select{
    width:100%;
    max-width:100%;
  }
}


/* === ADMIN BILLING HORIZONTAL SCROLL FINAL === */
@media(max-width:680px){

  #page[data-page-route="billing"]{
    overflow-x:hidden;
  }

  #page[data-page-route="billing"] .table-wrap{
    display:block;
    width:100%;
    max-width:100%;
    overflow-x:auto !important;
    overflow-y:hidden !important;
    -webkit-overflow-scrolling:touch;
    touch-action:pan-x;
  }

  #page[data-page-route="billing"] .table-wrap > table{
    display:table !important;
    width:max-content !important;
    min-width:900px !important;
    table-layout:auto !important;
  }

  #page[data-page-route="billing"] .table-wrap thead{
    display:table-header-group !important;
  }

  #page[data-page-route="billing"] .table-wrap tbody{
    display:table-row-group !important;
  }

  #page[data-page-route="billing"] .table-wrap tr{
    display:table-row !important;
  }

  #page[data-page-route="billing"] .table-wrap th,
  #page[data-page-route="billing"] .table-wrap td{
    display:table-cell !important;
    white-space:nowrap !important;
    width:auto !important;
    min-width:auto !important;
  }

  #page[data-page-route="billing"] .table-wrap td::before{
    content:none !important;
  }
}


/* === ADMIN CATEGORIES MOBILE CARDS === */
@media(max-width:680px){

  .table-wrap:has(.admin-categories-table){
    width:100%;
    max-width:100%;
    overflow-x:hidden;
  }

  .admin-categories-table{
    display:block;
    width:100%;
    min-width:0 !important;
  }

  .admin-categories-table thead{
    display:none;
  }

  .admin-categories-table tbody{
    display:block;
    width:100%;
  }

  .admin-categories-table tbody tr{
    display:block;
    width:100%;
    margin-bottom:12px;
    padding:12px;
    border:1px solid var(--line);
    border-radius:12px;
    background:#fff;
  }

  .admin-categories-table tbody td{
    display:grid;
    grid-template-columns:115px minmax(0,1fr);
    gap:10px;
    width:100%;
    min-width:0 !important;
    padding:8px 0;
    white-space:normal !important;
    border-bottom:1px solid var(--line);
    overflow-wrap:anywhere;
  }

  .admin-categories-table tbody td:last-child{
    border-bottom:0;
  }

  .admin-categories-table tbody td::before{
    content:attr(data-label);
    font-weight:700;
    color:var(--muted);
  }

  .admin-categories-table button{
    width:100%;
    margin:3px 0;
  }
}




/* === ADMIN TRIPS MOBILE V4 === */

.admin-trips-mobile-cards{
  display:none;
}

@media(max-width:680px){

  .admin-trips-desktop-table{
    display:none !important;
  }

  .admin-trips-mobile-cards{
    display:block;
    width:100%;
  }

  .admin-trip-mobile-card{
    width:100%;
    box-sizing:border-box;
    margin:0 0 14px;
    padding:12px;
    background:#fff;
    border:1px solid var(--line);
    border-radius:12px;
    overflow:hidden;
  }

  .admin-trip-mobile-row{
    display:grid;
    grid-template-columns:110px minmax(0,1fr);
    gap:10px;
    width:100%;
    box-sizing:border-box;
    padding:8px 0;
    border-bottom:1px solid var(--line);
  }

  .admin-trip-mobile-label{
    min-width:0;
    font-weight:700;
    color:var(--muted);
    overflow-wrap:anywhere;
  }

  .admin-trip-mobile-value{
    min-width:0;
    max-width:100%;
    overflow-wrap:anywhere;
  }

  .admin-trip-mobile-value .badge{
    max-width:100%;
  }

  .admin-trip-mobile-actions{
    width:100%;
    padding-top:10px;
  }

  .admin-trip-mobile-actions-title{
    margin-bottom:8px;
    font-weight:700;
    color:var(--muted);
  }

  .admin-trip-mobile-buttons{
    display:grid;
    grid-template-columns:1fr;
    gap:8px;
    width:100%;
  }

  .admin-trip-mobile-buttons button{
    display:block;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
    margin:0 !important;
    padding:10px 12px !important;
    white-space:normal !important;
    text-align:center !important;
  }
}





/* === CLIENT TRIPS MOBILE CARDS V3 === */

.client-trips-mobile-cards{
  display:none;
}

@media(max-width:680px){

  .client-trips-desktop-table{
    display:none !important;
  }

  .client-trips-mobile-cards{
    display:block;
    width:100%;
  }

  .client-trip-mobile-card{
    width:100%;
    box-sizing:border-box;
    margin:0 0 14px;
    padding:12px;
    background:#fff;
    border:1px solid var(--line);
    border-radius:12px;
    overflow:hidden;
  }

  .client-trip-mobile-row{
    display:grid;
    grid-template-columns:110px minmax(0,1fr);
    gap:10px;
    width:100%;
    box-sizing:border-box;
    padding:8px 0;
    border-bottom:1px solid var(--line);
  }

  .client-trip-mobile-label{
    min-width:0;
    font-weight:700;
    color:var(--muted);
    overflow-wrap:anywhere;
  }

  .client-trip-mobile-value{
    min-width:0;
    max-width:100%;
    overflow-wrap:anywhere;
  }

  .client-trip-mobile-actions{
    width:100%;
    padding-top:10px;
  }

  .client-trip-mobile-actions-title{
    margin-bottom:8px;
    font-weight:700;
    color:var(--muted);
  }

  .client-trip-mobile-buttons{
    display:grid;
    grid-template-columns:1fr;
    gap:8px;
    width:100%;
  }

  .client-trip-mobile-buttons button{
    display:block !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
    margin:0 !important;
    padding:10px 12px !important;
    white-space:normal !important;
    text-align:center !important;
  }
}


/* === CLIENT TRIPS MOBILE FINAL V4 === */

.client-trips-mobile-final-v4{
  display:none;
}

@media(max-width:680px){

  .client-trips-desktop-table,
  .client-trips-mobile-cards{
    display:none !important;
  }

  .client-trips-mobile-final-v4{
    display:block !important;
    width:100%;
  }

  .client-trip-final-card{
    width:100%;
    box-sizing:border-box;
    margin:0 0 14px;
    padding:12px;
    background:#fff;
    border:1px solid var(--line);
    border-radius:12px;
    overflow:hidden;
  }

  .client-trip-final-row{
    display:grid;
    grid-template-columns:110px minmax(0,1fr);
    gap:10px;
    width:100%;
    padding:8px 0;
    box-sizing:border-box;
    border-bottom:1px solid var(--line);
  }

  .client-trip-final-label{
    font-weight:700;
    color:var(--muted);
  }

  .client-trip-final-value{
    min-width:0;
    overflow-wrap:anywhere;
  }

  .client-trip-final-actions{
    width:100%;
    padding-top:10px;
  }

  .client-trip-final-actions-title{
    font-weight:700;
    color:var(--muted);
    margin-bottom:8px;
  }

  .client-trip-final-buttons{
    display:flex;
    flex-direction:column;
    gap:8px;
    width:100%;
  }

  .client-trip-final-buttons button{
    display:block !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    margin:0 !important;
    box-sizing:border-box !important;
    padding:11px 12px !important;
    text-align:center !important;
    white-space:normal !important;
  }
}

/* === NATIVE DEVICE CAMERA === */

.native-camera-card{
  width:min(600px,calc(100vw - 20px));
}

#nativeCameraPreview{
  display:block;
  width:100%;
  max-height:65vh;
  object-fit:contain;
  background:#111;
  border-radius:10px;
}

.native-camera-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:12px;
}

.native-camera-actions button{
  width:100%;
  min-height:48px;
}


/* === NATIVE CAMERA PREVIEW = REAL CAPTURE === */

.native-camera-card{
  width:min(920px,calc(100vw - 12px)) !important;
  max-height:calc(100vh - 20px);
  overflow:auto;
}

.native-camera-preview-wrap{
  width:100%;
  max-height:72vh;
  background:#111;
  border-radius:12px;
  overflow:hidden;
  display:flex;
  align-items:center;
  justify-content:center;
}

#nativeCameraPreview{
  display:block;
  width:100%;
  height:auto;
  max-height:72vh;
  object-fit:contain;
  background:#111;
  border-radius:12px;
}

.native-camera-note{
  margin-top:8px;
  text-align:center;
}

.native-camera-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:12px;
}

.native-camera-actions button{
  width:100%;
  min-height:50px;
}

@media(max-width:680px){
  .native-camera-card{
    width:calc(100vw - 12px) !important;
  }

  .native-camera-preview-wrap{
    max-height:60vh;
  }

  #nativeCameraPreview{
    max-height:60vh;
  }
}

/* === DELIVERY PHOTO PREVIEWS FIX === */

#deliveryForm #photoPreviews{
  display:grid !important;
  grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  gap:10px !important;
  width:100% !important;
  margin:10px 0 14px !important;
}

.delivery-photo-preview-card{
  min-width:0;
  padding:8px;
  border:1px solid var(--line);
  border-radius:10px;
  background:#fff;
}

.delivery-photo-preview-card img{
  display:block !important;
  width:100% !important;
  height:auto !important;
  aspect-ratio:auto !important;
  max-height:220px !important;
  object-fit:contain !important;
  border-radius:7px;
  background:#f5f5f5;
}

.delivery-photo-preview-footer{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  margin-top:8px;
}

.delivery-photo-preview-footer button{
  min-height:38px;
}

.delivery-photo-empty{
  grid-column:1 / -1;
  padding:18px;
  text-align:center;
  color:var(--muted);
  border:1px dashed var(--line);
  border-radius:10px;
}

@media(max-width:680px){
  #deliveryForm #photoPreviews{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}

/* ==================================================
   CLIENT TRIP REQUEST REDESIGN
================================================== */

.trip-request-dialog{
  width:min(1080px,calc(100vw - 32px)) !important;
  max-height:94vh;
  overflow:auto;
  border-radius:18px !important;
  padding:28px !important;
}

.trip-request-dialog .modal-head{
  margin-bottom:24px;
}

.trip-request-dialog .modal-head h2{
  font-size:30px;
  font-weight:800;
  color:#102653;
}

.trip-request-form{
  display:flex;
  flex-direction:column;
  gap:22px;
}

.trip-request-date{
  max-width:520px;
}

.trip-request-date label{
  display:block;
  font-weight:700;
  color:#173d72;
  margin-bottom:8px;
}

.trip-request-date select{
  width:100%;
  min-height:56px;
  font-size:17px;
}

.trip-request-date small{
  display:block;
  margin-top:8px;
  color:#77839a;
}

.trip-request-services{
  display:flex;
  flex-direction:column;
  gap:18px;
}

.trip-request-service{
  border:1px solid #d9e4f2;
  border-radius:16px;
  overflow:hidden;
  background:#fff;
}

.trip-request-service-head{
  padding:26px 28px;
  background:
    linear-gradient(
      90deg,
      #f3f8ff,
      #ffffff
    );
}

.trip-request-service-head small{
  display:block;
  color:#3674c5;
  font-size:15px;
  font-weight:700;
  margin-bottom:5px;
}

.trip-request-service-head strong{
  display:block;
  color:#081f4d;
  font-size:30px;
  line-height:1.15;
}

.trip-request-row{
  display:grid;
  grid-template-columns:190px 1fr;
  gap:20px;
  padding:22px 28px;
  border-top:1px solid #e1e8f1;
}

.trip-request-row-label{
  font-weight:700;
  color:#173d72;
  padding-top:12px;
}

.trip-request-row-content{
  min-width:0;
}

.trip-request-time{
  max-width:210px;
}

.trip-request-row input,
.trip-request-row select{
  min-height:54px;
  border-radius:10px;
}

.trip-request-load-grid{
  display:grid;
  grid-template-columns:1fr 1.15fr;
  gap:10px;
}

.serviceStops{
  display:flex;
  flex-direction:column;
  gap:10px;
}

.serviceStopRow{
  display:grid;
  grid-template-columns:
    minmax(230px,1fr)
    minmax(260px,1fr)
    auto;
  gap:10px;
  align-items:center;
}

.serviceStopActions{
  display:flex;
  gap:7px;
}

.serviceStopActions button{
  min-width:46px;
  min-height:46px;
  padding:8px 11px;
}

.trip-request-add-stop{
  width:100%;
  margin-top:12px;
  min-height:58px;
  border:1px dashed #8fc3f5;
  border-radius:10px;
  background:#f5faff;
  color:#1261b7;
  font-weight:700;
}

.trip-request-summary-button{
  width:100%;
  min-height:64px;
  border-radius:12px;
  font-size:18px;
  font-weight:800;
}

@media(max-width:760px){

  .trip-request-dialog{
    width:calc(100vw - 12px) !important;
    padding:16px !important;
    border-radius:14px !important;
  }

  .trip-request-dialog .modal-head h2{
    font-size:24px;
  }

  .trip-request-service-head{
    padding:20px;
  }

  .trip-request-service-head strong{
    font-size:26px;
  }

  .trip-request-row{
    grid-template-columns:1fr;
    gap:8px;
    padding:18px;
  }

  .trip-request-row-label{
    padding-top:0;
  }

  .trip-request-time{
    max-width:none;
  }

  .trip-request-load-grid{
    grid-template-columns:1fr;
  }

  .serviceStopRow{
    grid-template-columns:1fr;
  }

  .serviceStopActions{
    display:grid;
    grid-template-columns:1fr 1fr 1fr;
  }

  .serviceStopActions button{
    width:100%;
  }

}


/* ==================================================
   TRIP REQUEST DETAILS BUTTON + MODAL
================================================== */

.trip-request-load-grid{
  display:block !important;
  width:100%;
}

.trip-request-load-grid .serviceLoad{
  width:100% !important;
}

.serviceStopRow{
  grid-template-columns:
    minmax(360px,1fr)
    auto
    auto !important;
  gap:10px;
  align-items:center;
}

.serviceStopRow .serviceStop{
  width:100%;
  min-width:0;
}

.serviceStopDetailsButton{
  min-height:54px;
  padding:0 18px;
  white-space:nowrap;
  border-radius:10px;
  font-weight:700;
}

.serviceStopDetailsButton.has-details{
  border-color:#9ad2a0;
  background:#f0fbf1;
  color:#16712a;
}

.serviceStopActions{
  display:flex;
  gap:6px;
  flex-shrink:0;
}

.delivery-details-dialog{
  width:min(680px,calc(100vw - 24px)) !important;
  border-radius:18px !important;
  padding:24px !important;
}

.delivery-details-dialog .modal-head{
  align-items:flex-start;
  margin-bottom:20px;
}

.delivery-details-dialog .modal-head h2{
  margin:0;
  font-size:24px;
  color:#102653;
}

.delivery-details-dialog .modal-head .sub{
  margin-top:5px;
}

#deliveryDetailsTextarea{
  width:100%;
  min-height:190px;
  resize:vertical;
  padding:16px;
  font-size:16px;
  line-height:1.5;
  border-radius:12px;
}

.delivery-details-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:10px;
  margin-top:18px;
}

.delivery-details-actions button{
  min-height:52px;
  width:100%;
}

/* =========================
   TABLET
========================= */

@media(max-width:900px){

  .serviceStopRow{
    grid-template-columns:
      minmax(0,1fr)
      auto !important;
  }

  .serviceStopActions{
    grid-column:1 / -1;
    display:grid;
    grid-template-columns:1fr 1fr 1fr;
  }

  .serviceStopDetailsButton{
    width:100%;
  }
}

/* =========================
   MOBILE
========================= */

@media(max-width:680px){

  .serviceStopRow{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:8px;
    padding:10px 0;
  }

  .serviceStopRow .serviceStop{
    width:100% !important;
    min-height:54px;
  }

  .serviceStopDetailsButton{
    width:100%;
    min-height:48px;
  }

  .serviceStopActions{
    grid-column:auto;
    display:grid;
    grid-template-columns:1fr 1fr 1fr;
    width:100%;
  }

  .serviceStopActions button{
    width:100%;
    min-height:46px;
  }

  .delivery-details-dialog{
    width:calc(100vw - 12px) !important;
    padding:18px !important;
    border-radius:14px !important;
  }

  #deliveryDetailsTextarea{
    min-height:220px;
    font-size:16px;
  }

  .delivery-details-actions{
    grid-template-columns:1fr;
  }

  .delivery-details-actions .primary{
    order:-1;
  }
}


/* ==================================================
   TRIP SUMMARY FINAL
================================================== */

.trip-summary-final-dialog{
  width:min(820px,calc(100vw - 24px)) !important;
  max-height:92vh;
  overflow:auto;
  border-radius:18px !important;
}

.trip-summary-final{
  display:flex;
  flex-direction:column;
  gap:16px;
}

.trip-summary-date{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:15px;
  padding:16px 18px;
  border-radius:12px;
  background:#edf5fc;
  color:#123766;
}

.trip-summary-date span{
  font-weight:700;
}

.trip-summary-date strong{
  font-size:17px;
}

.trip-summary-service{
  overflow:hidden;
  border:1px solid #dce6f1;
  border-radius:14px;
  background:#fff;
}

.trip-summary-service-head{
  padding:20px;
  background:
    linear-gradient(
      90deg,
      #f1f7fe,
      #ffffff
    );
}

.trip-summary-service-head small{
  display:block;
  margin-bottom:4px;
  color:#3978c5;
  font-weight:700;
}

.trip-summary-service-head strong{
  display:block;
  color:#0c2856;
  font-size:24px;
}

.trip-summary-service-head span{
  display:block;
  margin-top:6px;
  color:#68778e;
  font-size:14px;
}

.trip-summary-section{
  padding:17px 20px;
  border-top:1px solid #e4ebf3;
}

.trip-summary-label{
  display:block;
  margin-bottom:7px;
  color:#23528a;
  font-size:13px;
  font-weight:700;
  text-transform:uppercase;
  letter-spacing:.03em;
}

.trip-summary-section > strong{
  color:#152d51;
  line-height:1.45;
}

.trip-summary-stops{
  display:flex;
  flex-direction:column;
  gap:9px;
}

.trip-summary-stop{
  display:grid;
  grid-template-columns:32px 1fr;
  gap:10px;
  align-items:flex-start;
  padding:11px;
  border-radius:10px;
  background:#f8fafc;
}

.trip-summary-stop-number{
  display:flex;
  align-items:center;
  justify-content:center;
  width:30px;
  height:30px;
  border-radius:50%;
  background:#e5f1ff;
  color:#1764b6;
  font-weight:800;
}

.trip-summary-stop-body{
  min-width:0;
}

.trip-summary-stop-body strong{
  display:block;
  color:#182f52;
  line-height:1.4;
}

.trip-summary-stop-body small{
  display:block;
  margin-top:4px;
  color:#607087;
  line-height:1.4;
}

.trip-summary-confirm{
  width:100%;
  min-height:58px;
  margin-top:18px;
  border-radius:11px;
  font-size:17px;
  font-weight:800;
}

@media(max-width:680px){

  .trip-summary-final-dialog{
    width:calc(100vw - 12px) !important;
    padding:16px !important;
  }

  .trip-summary-date{
    align-items:flex-start;
    flex-direction:column;
    gap:3px;
  }

  .trip-summary-service-head{
    padding:17px;
  }

  .trip-summary-service-head strong{
    font-size:22px;
  }

  .trip-summary-section{
    padding:15px;
  }

}


/* PROVIDER BILLING HORIZONTAL SCROLL */
body .provider-billing-scroll{
  display:block;
  width:100%;
  max-width:100%;
  overflow-x:auto !important;
  overflow-y:hidden;
  -webkit-overflow-scrolling:touch;
}

body .provider-billing-scroll .table{
  width:max-content;
  min-width:100%;
  white-space:nowrap;
}

/* ADMIN PROVIDER COMPANIES TABLE V1 */
.admin-provider-companies-wrap{
  width:100%;
  max-width:100%;
  overflow-x:auto;
}

.admin-provider-companies-table{
  width:100% !important;
  min-width:1000px !important;
  table-layout:fixed;
}

.admin-provider-companies-table th,
.admin-provider-companies-table td{
  padding:14px 8px;
  vertical-align:middle;
  overflow-wrap:anywhere;
  white-space:normal;
}

.admin-provider-companies-table th:nth-child(1),
.admin-provider-companies-table td:nth-child(1){width:14%}

.admin-provider-companies-table th:nth-child(2),
.admin-provider-companies-table td:nth-child(2){width:11%}

.admin-provider-companies-table th:nth-child(3),
.admin-provider-companies-table td:nth-child(3){width:21%}

.admin-provider-companies-table th:nth-child(4),
.admin-provider-companies-table td:nth-child(4){width:12%}

.admin-provider-companies-table th:nth-child(5),
.admin-provider-companies-table td:nth-child(5){width:8%}

.admin-provider-companies-table th:nth-child(6),
.admin-provider-companies-table td:nth-child(6){width:8%}

.admin-provider-companies-table th:nth-child(7),
.admin-provider-companies-table td:nth-child(7){width:26%}

.admin-provider-companies-table td:last-child{
  white-space:normal;
}

.admin-provider-companies-table td:last-child button{
  width:auto !important;
  min-width:0 !important;
  display:inline-block !important;
  padding:10px 14px !important;
  margin:3px 6px 3px 0;
}

.admin-provider-companies-table td:last-child .actions{
  display:flex;
  gap:6px;
  flex-wrap:nowrap;
}

@media(max-width:900px){
  .admin-provider-companies-wrap{
    overflow-x:auto;
    -webkit-overflow-scrolling:touch;
  }

  .admin-provider-companies-table{
    min-width:1000px !important;
  }
}

.admin-provider-companies-table th{white-space:nowrap}

/* Individual providers have email in the second column. */
.admin-provider-individuals-table th:nth-child(2),
.admin-provider-individuals-table td:nth-child(2){width:21%}
.admin-provider-individuals-table th:nth-child(3),
.admin-provider-individuals-table td:nth-child(3){width:11%}
.modal > .card.provider-admin-dialog{width:min(1100px,100%)}
.provider-admin-dialog > .table-wrap{width:100%;max-height:none}

/* CLIENT DELIVERIES WIDTH V1 */
.client-deliveries-table{
  width:100% !important;
  min-width:0 !important;
  table-layout:fixed;
}

.client-deliveries-table th,
.client-deliveries-table td{
  white-space:normal !important;
  overflow-wrap:anywhere;
  vertical-align:top;
}

.client-deliveries-table th:nth-child(1),
.client-deliveries-table td:nth-child(1){width:12%}

.client-deliveries-table th:nth-child(2),
.client-deliveries-table td:nth-child(2){width:13%}

.client-deliveries-table th:nth-child(3),
.client-deliveries-table td:nth-child(3){width:38%}

.client-deliveries-table th:nth-child(4),
.client-deliveries-table td:nth-child(4){width:25%}

.client-deliveries-table th:nth-child(5),
.client-deliveries-table td:nth-child(5){width:12%}

/* CLIENT REQUEST VEHICLE LIST COMPACT V1 */

#clientFleet{
  margin-top:14px;
}

#clientFleet > .section{
  display:grid;
  grid-template-columns:1fr auto 1fr;
  align-items:center;
  gap:12px;
  margin:8px 0 4px;
}

#clientFleet > .section h3{
  grid-column:2;
  margin:0;
  text-align:center;
}

#clientFleet #continueTrip{
  grid-column:3;
  justify-self:end;
  margin:0;
}

#clientFleet > .sub{
  text-align:center;
  margin:4px 0 12px;
}

.client-vehicle-list{
  display:flex;
  flex-direction:column;
  gap:8px;
}

.client-vehicle-card{
  display:grid;
  grid-template-columns:34px 1fr;
  align-items:center;
  gap:8px;
  min-height:0;
  padding:10px 14px !important;
  margin:0 !important;
  border-radius:12px;
}

.client-vehicle-card > .tripVehicle{
  margin:0;
  justify-self:center;
  align-self:center;
}

.client-vehicle-card > div{
  min-width:0;
  text-align:center;
}

.client-vehicle-title{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  margin:0 0 4px;
}

.client-vehicle-title b{
  line-height:1.2;
}

.client-vehicle-line{
  margin:1px 0;
  line-height:1.25;
}

.client-vehicle-line span{
  font-weight:700;
}

.client-vehicle-tech{
  margin-top:4px;
  line-height:1.2;
  font-size:12px;
}

.priority-number{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:26px;
  height:26px;
  padding:0 7px;
  border-radius:999px;
}

@media(max-width:800px){
  #clientFleet > .section{
    grid-template-columns:1fr;
    text-align:center;
  }

  #clientFleet > .section h3,
  #clientFleet #continueTrip{
    grid-column:1;
    justify-self:center;
  }

  .client-vehicle-card{
    grid-template-columns:28px 1fr;
    padding:9px 10px !important;
  }
}

/* CLIENT VEHICLE DRIVER HIGHLIGHT */
.client-vehicle-title + .client-vehicle-line{
  font-weight:700;
  font-size:15px;
}

.client-vehicle-title + .client-vehicle-line span{
  font-weight:400;
}

/* ADMIN DASHBOARD COMPACT V1 */

.admin-dash-grid{
  gap:12px !important;
  margin:0 0 12px !important;
  align-items:stretch;
}

.admin-dash-card{
  padding:14px 16px !important;
  margin:0 !important;
  min-width:0;
}

.admin-dash-card h3{
  margin:0 0 10px !important;
  text-align:center;
  font-size:17px;
}

.admin-dash-card .sub{
  margin:8px 0 0 !important;
  text-align:center;
  line-height:1.3;
}

/* MÉTRICAS */
.admin-dash-card .metrics{
  gap:8px !important;
  margin:0 !important;
}

.admin-dash-card .metric{
  padding:10px 12px !important;
  min-height:0 !important;
  text-align:center;
}

.admin-dash-card .metric small{
  display:block;
  margin:0 0 3px !important;
  line-height:1.2;
}

.admin-dash-card .metric strong{
  display:block;
  line-height:1.15;
}

.operation-metrics{
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
}

.results-metrics{
  grid-template-columns:repeat(3,minmax(0,1fr)) !important;
}

.finance-summary-metrics{
  grid-template-columns:repeat(4,minmax(0,1fr)) !important;
}

/* TABLAS */
.admin-dash-table{
  width:100%;
  border-collapse:collapse;
}

.admin-dash-table th,
.admin-dash-table td{
  padding:8px 10px !important;
  line-height:1.25;
  vertical-align:middle;
}

.admin-dash-table th{
  font-size:12px;
}

.admin-dash-table td{
  font-size:13px;
}

/* Evita aire extra dentro de cards con tablas */
.admin-dash-card.table-wrap{
  padding-bottom:10px !important;
}

/* Separación general del último módulo */
#page > .admin-dash-card{
  margin-top:12px !important;
}

@media(max-width:1100px){
  .operation-metrics,
  .finance-summary-metrics{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }
}

@media(max-width:800px){
  .admin-dash-grid{
    grid-template-columns:1fr !important;
  }

  .operation-metrics,
  .results-metrics,
  .finance-summary-metrics{
    grid-template-columns:repeat(2,minmax(0,1fr)) !important;
  }

  .admin-dash-card{
    padding:12px !important;
  }
}

/* ADMIN DASHBOARD FIVE COLUMNS V1 */

.admin-dash-five-grid{
  display:grid;
  grid-template-columns:repeat(5,minmax(0,1fr));
  gap:10px;
  align-items:start;
  width:100%;
  margin:0;
}

.admin-dash-five-grid > .admin-dash-card{
  min-width:0;
  width:100%;
  height:100%;
  margin:0 !important;
  padding:12px !important;
}

.admin-dash-five-grid .admin-dash-card h3{
  text-align:center;
  margin:0 0 10px !important;
  font-size:15px;
  line-height:1.2;
}

/* métricas verticales dentro de cada columna */
.admin-dash-five-grid .metrics,
.admin-dash-five-grid .operation-metrics,
.admin-dash-five-grid .results-metrics,
.admin-dash-five-grid .finance-summary-metrics{
  display:grid !important;
  grid-template-columns:1fr !important;
  gap:6px !important;
}

.admin-dash-five-grid .metric{
  padding:8px 10px !important;
  text-align:center;
  min-width:0;
}

.admin-dash-five-grid .metric small{
  font-size:11px;
  line-height:1.15;
}

.admin-dash-five-grid .metric strong{
  font-size:15px;
  line-height:1.15;
  overflow-wrap:anywhere;
}

/* tablas compactas */
.admin-dash-five-grid .admin-dash-table{
  width:100%;
  table-layout:fixed;
}

.admin-dash-five-grid .admin-dash-table th,
.admin-dash-five-grid .admin-dash-table td{
  padding:6px 4px !important;
  font-size:11px;
  line-height:1.2;
  white-space:normal !important;
  overflow-wrap:anywhere;
  text-align:center;
}

.admin-dash-five-grid .sub{
  font-size:11px;
  line-height:1.25;
  margin:8px 0 0 !important;
  text-align:center;
}

@media(max-width:1350px){
  .admin-dash-five-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

@media(max-width:800px){
  .admin-dash-five-grid{
    grid-template-columns:1fr;
  }
}

/* ADMIN DASHBOARD ULTRA COMPACT V2 */

.admin-dash-five-grid{
  gap:6px !important;
}

.admin-dash-five-grid > .admin-dash-card{
  padding:8px 10px !important;
}

.admin-dash-five-grid .admin-dash-card h3{
  margin:0 0 5px !important;
  line-height:1.05 !important;
}

.admin-dash-five-grid .metrics,
.admin-dash-five-grid .operation-metrics,
.admin-dash-five-grid .results-metrics,
.admin-dash-five-grid .finance-summary-metrics{
  gap:4px !important;
}

.admin-dash-five-grid .metric{
  padding:6px 8px !important;
}

.admin-dash-five-grid .metric small{
  margin:0 0 1px !important;
  line-height:1.05 !important;
}

.admin-dash-five-grid .metric strong{
  margin:0 !important;
  line-height:1.05 !important;
}

.admin-dash-five-grid .sub{
  margin:4px 0 0 !important;
  line-height:1.1 !important;
}

.admin-dash-five-grid .admin-dash-table th,
.admin-dash-five-grid .admin-dash-table td{
  padding:4px 3px !important;
  line-height:1.05 !important;
}

.admin-dash-five-grid table{
  margin:0 !important;
}

.admin-dash-five-grid thead,
.admin-dash-five-grid tbody,
.admin-dash-five-grid tr{
  margin:0 !important;
}

/* selector de período superior */
#adminDashboardPeriod,
#adminDashboardReference{
  margin:0 !important;
}

.admin-dash-period-card{
  padding:10px 14px !important;
  margin-bottom:6px !important;
}

.admin-dash-period-card .field{
  margin:0 !important;
}

.admin-dash-period-card .sub{
  margin:5px 0 0 !important;
}

/* compactar cualquier section interna del dashboard */
.admin-dash-card .section{
  margin:0 0 5px !important;
}

.admin-dash-card p{
  margin-top:3px !important;
  margin-bottom:3px !important;
}

/* ADMIN DASHBOARD INLINE METRICS V3 */

.admin-dash-five-grid .admin-inline-metric{
  display:block !important;
  padding:7px 9px !important;
}

.admin-inline-metric-main{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  width:100%;
}

.admin-dash-five-grid .admin-inline-metric-main small{
  margin:0 !important;
  text-align:left;
  line-height:1.1 !important;
  font-size:12px;
}

.admin-dash-five-grid .admin-inline-metric-main strong{
  margin:0 !important;
  text-align:right;
  line-height:1 !important;
  font-size:18px;
  white-space:nowrap;
}

.admin-dash-five-grid .admin-inline-metric-extra{
  display:block;
  margin:2px 0 0 !important;
  text-align:right;
  font-size:10px !important;
  line-height:1.05 !important;
}

/* GRAFICO ADMIN */

.admin-dash-chart{
  margin-top:8px !important;
  padding:12px 14px !important;
}

.admin-dash-chart > .section{
  display:block !important;
  text-align:center;
  margin:0 0 5px !important;
}

.admin-dash-chart > .section > div{
  width:100%;
}

.admin-dash-chart h3{
  text-align:center !important;
  margin:0 0 3px !important;
}

.admin-dash-chart .sub{
  text-align:center !important;
  margin:0 !important;
}

.admin-dash-chart-legend{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:20px;
  flex-wrap:wrap;
  margin:7px 0 4px;
  font-size:12px;
}

.admin-dash-chart-scroll{
  width:100%;
  overflow-x:auto;
}

.admin-dash-chart-scroll svg{
  display:block;
  width:100%;
  min-width:700px;
  height:auto;
  margin:0 auto;
}

/* ADMIN DASHBOARD LARGE AMOUNTS V4 */

/* Resultados */
.admin-dash-five-grid .results-metrics
.admin-inline-metric-main strong,

/* Cobros y pagos */
.admin-dash-five-grid .finance-summary-metrics
.admin-inline-metric-main strong{
  font-size:14px !important;
  letter-spacing:-0.3px;
  white-space:nowrap;
  overflow:visible !important;
  text-overflow:clip !important;
}

/* valores especialmente largos */
.admin-dash-five-grid .finance-summary-metrics
.admin-inline-metric{
  padding-left:7px !important;
  padding-right:7px !important;
}



/* TRIP_EDIT_REORDER_STYLE_V2 */

.trip-edit-dialog{
  width:min(900px,calc(100vw - 24px));
  max-width:900px;
  max-height:calc(100vh - 24px);
  overflow:auto;
}

#clientTripEdit,
#clientTripEdit .field,
#editStops{
  min-width:0;
}

#editStops{
  display:grid;
  gap:8px;
  margin:8px 0 10px;
}

.trip-edit-stop{
  display:grid;
  grid-template-columns:
    34px minmax(0,1fr) auto;
  gap:8px;
  align-items:center;
  padding:8px;
  border:1px solid
    rgba(148,163,184,.22);
  border-radius:10px;
}

.trip-edit-order{
  text-align:center;
}

.trip-edit-main{
  min-width:0;
}

.trip-edit-main select{
  width:100%;
  min-width:0;
}

.trip-edit-actions{
  display:flex;
  align-items:center;
  gap:5px;
  flex-wrap:wrap;
}

.trip-edit-actions button{
  min-width:38px;
  margin:0;
}

.trip-edit-stop-confirmed{
  opacity:.78;
}

.trip-edit-locked{
  display:block;
  margin-top:4px;
}

@media(max-width:700px){

  .trip-edit-dialog{
    width:calc(100vw - 12px);
    max-height:calc(100vh - 12px);
  }

  .trip-edit-stop{
    grid-template-columns:
      28px minmax(0,1fr);
  }

  .trip-edit-actions{
    grid-column:2;
    justify-content:flex-start;
  }

  .trip-edit-actions .removeEditStop{
    flex:1;
  }
}


/* LOGOUT_ALWAYS_VISIBLE_V1 */

.side .nav{
  flex:1 1 auto;
}

.side .logout{
  position:sticky;
  bottom:12px;
  margin-top:auto;
  z-index:20;
}


/* CLIENT DASHBOARD OPERACION COMPACT V1 */
.client-dashboard-top-grid
.client-dashboard-block:first-child{
  padding:10px 14px !important;
}

.client-dashboard-top-grid
.client-dashboard-block:first-child
.section{
  margin:0 0 6px !important;
  padding:0 !important;
}

.client-dashboard-top-grid
.client-dashboard-block:first-child
.section h3{
  margin:0 !important;
}

.client-dashboard-top-grid
.client-dashboard-block:first-child
.dashboard-list{
  display:flex;
  flex-direction:column;
  gap:3px !important;
}

.client-dashboard-top-grid
.client-dashboard-block:first-child
.schedule-item{
  min-height:0 !important;
  padding:6px 8px !important;
  margin:0 !important;
  line-height:1.05 !important;
}

.client-dashboard-top-grid
.client-dashboard-block:first-child
.schedule-item span,
.client-dashboard-top-grid
.client-dashboard-block:first-child
.schedule-item strong{
  margin:0 !important;
  line-height:1.05 !important;
}

/* ===== MAPAS DE VIAJES ===== */

.trip-map{
  width:100%;
  height:300px;
  margin-top:14px;
  border:1px solid #dfe4ea;
  border-radius:14px;
  overflow:hidden;
  background:#f5f7fa;
}

.trip-map-small{
  height:240px;
}

@media(max-width:800px){
  .trip-map{
    height:260px;
  }

  .trip-map-small{
    height:220px;
  }
}

/* ===== SOLICITUD DE VIAJE · ASISTENTE POR REPARTO ===== */

.modal .card.trip-request-dialog{
  width:min(1180px,96vw);
}

.trip-request-services{
  display:block;
}

.trip-request-service{
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(380px,.9fr);
  column-gap:22px;
  row-gap:0;
  padding:0;
  overflow:hidden;
}

.trip-request-service[hidden]{
  display:none !important;
}

.trip-request-service-head{
  grid-column:1/-1;
}

.trip-request-service .trip-request-row{
  grid-column:1;
}

.trip-request-service .trip-map{
  grid-column:2;
  grid-row:2 / span 3;
  align-self:stretch;
  height:auto;
  min-height:390px;
  margin:18px 18px 18px 0;
}

.trip-request-wizard-status{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin:14px 0 10px;
  font-weight:800;
  color:#07356b;
}

.trip-request-wizard-actions{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  margin-top:18px;
}

.trip-request-wizard-actions button{
  min-width:140px;
}

.trip-request-summary-button[hidden]{
  display:none !important;
}

@media(max-width:900px){
  .trip-request-service{
    grid-template-columns:1fr;
  }

  .trip-request-service .trip-map{
    grid-column:1;
    grid-row:auto;
    height:260px;
    min-height:260px;
    margin:14px 12px 18px;
  }

  .trip-request-wizard-actions{
    flex-wrap:wrap;
  }

  .trip-request-wizard-actions button{
    flex:1;
  }
}

/* ===== SOLICITUD · WIZARD COMPACTO ===== */

.modal .card.trip-request-dialog{
  max-height:94vh;
  padding:22px 28px;
}

.trip-request-dialog .trip-request-date{
  margin-bottom:12px;
}

.trip-request-wizard-status{
  margin:8px 0 10px;
}

.trip-request-service{
  max-height:610px;
}

.trip-request-service-head{
  padding:16px 28px;
}

.trip-request-service .trip-request-row{
  padding:14px 28px;
}

.trip-request-service .trip-map{
  min-height:330px;
  height:calc(100% - 36px);
  max-height:430px;
}

.trip-request-service .serviceStops{
  max-height:260px;
  overflow-y:auto;
  overflow-x:hidden;
  padding-right:4px;
}

.trip-request-wizard-actions{
  margin-top:12px;
}

#tripRequestPrevious[hidden],
#tripRequestNext[hidden],
.trip-request-summary-button[hidden]{
  display:none !important;
}

@media(max-width:900px){
  .modal .card.trip-request-dialog{
    max-height:94vh;
    padding:16px;
  }

  .trip-request-service{
    max-height:none;
  }

  .trip-request-service .serviceStops{
    max-height:none;
    overflow:visible;
  }

  .trip-request-service .trip-map{
    height:240px;
    min-height:240px;
  }
}

/* ===== WIZARD · AJUSTE FINAL DOS COLUMNAS ===== */

.trip-request-wizard-status{
  justify-content:flex-start;
}

#tripRequestStepVehicle{
  display:none !important;
}

.trip-request-service{
  grid-template-columns:minmax(0,48%) minmax(0,52%);
  column-gap:0;
}

.trip-request-service-head{
  grid-column:1/-1;
}

.trip-request-service .trip-request-row{
  grid-column:1;
  min-width:0;
  padding:12px 24px;
}

.trip-request-row-label{
  width:155px;
  min-width:155px;
}

.trip-request-row-content{
  min-width:0;
  width:100%;
}

.trip-request-row input,
.trip-request-row select{
  max-width:100%;
  min-width:0;
}

.trip-request-service .serviceStops{
  width:100%;
  max-width:100%;
}

.trip-request-dialog .serviceStopRow{
  display:grid;
  grid-template-columns:minmax(0,1fr);
  gap:8px;
  width:100%;
  max-width:100%;
  margin:8px 0;
}

.trip-request-dialog .serviceStopRow select{
  width:100%;
  max-width:100%;
}

.trip-request-dialog .serviceStopActions{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}

.trip-request-dialog .serviceStopDetailsButton{
  width:auto;
}

.trip-request-dialog .serviceStopActions button{
  width:auto;
  min-width:42px;
}

.trip-request-service .trip-map{
  grid-column:2;
  grid-row:2 / span 3;
  width:calc(100% - 18px);
  min-width:0;
  margin:18px 18px 18px 0;
  min-height:330px;
  max-height:430px;
}

.trip-request-add-stop{
  width:100%;
  max-width:100%;
}

@media(max-width:900px){
  .trip-request-service{
    grid-template-columns:1fr;
  }

  .trip-request-service .trip-map{
    grid-column:1;
    grid-row:auto;
    width:auto;
    margin:14px 18px 18px;
  }

  .trip-request-row-label{
    width:auto;
    min-width:0;
  }
}

/* ===== SOLICITUD VIAJE · FIX DEFINITIVO COLUMNAS ===== */

.trip-request-service{
  display:grid !important;
  grid-template-columns:45% 55% !important;
  column-gap:0 !important;
  overflow:hidden !important;
}

.trip-request-service-head{
  grid-column:1 / -1 !important;
}

.trip-request-service .trip-request-row{
  grid-column:1 !important;
  width:100% !important;
  min-width:0 !important;
  box-sizing:border-box !important;
  padding:12px 18px !important;
  display:grid !important;
  grid-template-columns:125px minmax(0,1fr) !important;
  gap:12px !important;
}

.trip-request-row-label{
  width:auto !important;
  min-width:0 !important;
}

.trip-request-row-content{
  width:100% !important;
  min-width:0 !important;
  overflow:hidden !important;
}

.trip-request-row input,
.trip-request-row select{
  width:100% !important;
  max-width:100% !important;
  min-width:0 !important;
  box-sizing:border-box !important;
}

.trip-request-dialog .serviceStopRow{
  display:grid !important;
  grid-template-columns:minmax(0,1fr) !important;
  width:100% !important;
  max-width:100% !important;
  min-width:0 !important;
  gap:7px !important;
  margin:8px 0 !important;
}

.trip-request-dialog .serviceStopRow select{
  grid-column:1 !important;
  width:100% !important;
  min-width:0 !important;
}

.trip-request-dialog .serviceStopDetailsButton{
  grid-column:1 !important;
  width:100% !important;
  padding:8px 10px !important;
}

.trip-request-dialog .serviceStopActions{
  grid-column:1 !important;
  display:grid !important;
  grid-template-columns:1fr 1fr 1.5fr !important;
  gap:6px !important;
  width:100% !important;
}

.trip-request-dialog .serviceStopActions button{
  width:100% !important;
  min-width:0 !important;
  padding:8px 6px !important;
}

.trip-request-add-stop{
  width:100% !important;
  max-width:100% !important;
}

.trip-request-service .trip-map{
  grid-column:2 !important;
  grid-row:2 / span 3 !important;
  width:calc(100% - 16px) !important;
  height:auto !important;
  min-height:360px !important;
  max-height:440px !important;
  margin:16px 16px 16px 0 !important;
  box-sizing:border-box !important;
  position:relative !important;
  z-index:1 !important;
}

.trip-request-service > .trip-request-row{
  position:relative !important;
  z-index:2 !important;
}

@media(max-width:900px){
  .trip-request-service{
    grid-template-columns:1fr !important;
  }

  .trip-request-service .trip-request-row{
    grid-column:1 !important;
  }

  .trip-request-service .trip-map{
    grid-column:1 !important;
    grid-row:auto !important;
    width:auto !important;
    height:240px !important;
    min-height:240px !important;
    margin:12px 18px 18px !important;
  }
}

/* ===== REPARTO · DESCARGAS HORIZONTALES EN MEDIA COLUMNA ===== */

.trip-request-service{
  grid-template-columns:50% 50% !important;
}

.trip-request-service .trip-request-row{
  padding:12px 18px !important;
  grid-template-columns:120px minmax(0,1fr) !important;
}

.trip-request-dialog .serviceStopRow{
  display:grid !important;
  grid-template-columns:minmax(0,1fr) auto auto auto auto !important;
  gap:6px !important;
  align-items:center !important;
  width:100% !important;
  max-width:100% !important;
  margin:8px 0 !important;
}

.trip-request-dialog .serviceStopRow select{
  grid-column:auto !important;
  width:100% !important;
  min-width:0 !important;
  padding-left:10px !important;
  padding-right:28px !important;
}

.trip-request-dialog .serviceStopDetailsButton{
  grid-column:auto !important;
  width:auto !important;
  min-width:78px !important;
  padding:8px 10px !important;
  white-space:nowrap !important;
}

.trip-request-dialog .serviceStopActions{
  display:contents !important;
}

.trip-request-dialog .serviceStopActions button{
  width:38px !important;
  min-width:38px !important;
  height:38px !important;
  padding:0 !important;
}

.trip-request-dialog .serviceStopActions .danger{
  width:auto !important;
  min-width:72px !important;
  padding:0 9px !important;
}

.trip-request-service .serviceStops{
  max-height:270px !important;
  overflow-y:auto !important;
  overflow-x:hidden !important;
  padding-right:4px !important;
}

.trip-request-add-stop{
  width:100% !important;
  margin-top:8px !important;
}

.trip-request-service .trip-map{
  grid-column:2 !important;
  width:calc(100% - 16px) !important;
  margin:16px 16px 16px 0 !important;
  min-height:360px !important;
  max-height:440px !important;
}

@media(max-width:900px){
  .trip-request-dialog .serviceStopRow{
    grid-template-columns:minmax(0,1fr) auto auto !important;
  }

  .trip-request-dialog .serviceStopDetailsButton{
    grid-column:1 / -1 !important;
  }

  .trip-request-dialog .serviceStopActions{
    display:contents !important;
  }
}

/* ===== SOLICITUD VIAJE · PC COMPACTA ===== */

@media(min-width:1100px){

  .modal .card.trip-request-dialog{
    width:min(1480px,98vw) !important;
    max-height:96vh !important;
    padding:14px 18px !important;
  }

  .trip-request-dialog .trip-request-date{
    margin-bottom:6px !important;
  }

  .trip-request-dialog .trip-request-date label{
    margin-bottom:4px !important;
  }

  .trip-request-dialog .trip-request-date select{
    height:42px !important;
  }

  .trip-request-wizard-status{
    margin:4px 0 8px !important;
    font-size:14px !important;
  }

  .trip-request-service{
    grid-template-columns:58% 42% !important;
  }

  .trip-request-service-head{
    padding:8px 16px !important;
  }

  .trip-request-service-head small{
    font-size:12px !important;
  }

  .trip-request-service-head strong{
    font-size:24px !important;
  }

  .trip-request-service .trip-request-row{
    padding:6px 14px !important;
    grid-template-columns:115px minmax(0,1fr) !important;
    gap:8px !important;
    min-height:54px !important;
  }

  .trip-request-row-label{
    font-size:13px !important;
    line-height:1.2 !important;
  }

  .trip-request-row input,
  .trip-request-row select{
    height:38px !important;
    font-size:14px !important;
  }

  .trip-request-dialog .serviceStopRow{
    grid-template-columns:minmax(0,1fr) 68px 34px 34px 68px !important;
    gap:4px !important;
    margin:4px 0 !important;
  }

  .trip-request-dialog .serviceStopRow select{
    height:36px !important;
    font-size:13px !important;
  }

  .trip-request-dialog .serviceStopDetailsButton{
    min-width:68px !important;
    height:36px !important;
    padding:0 6px !important;
    font-size:12px !important;
  }

  .trip-request-dialog .serviceStopActions button{
    width:34px !important;
    min-width:34px !important;
    height:36px !important;
    font-size:12px !important;
  }

  .trip-request-dialog .serviceStopActions .danger{
    width:68px !important;
    min-width:68px !important;
    padding:0 5px !important;
  }

  .trip-request-service .serviceStops{
    max-height:none !important;
    overflow:visible !important;
    padding-right:0 !important;
  }

  .trip-request-add-stop{
    min-height:34px !important;
    padding:6px 10px !important;
    margin-top:4px !important;
    font-size:13px !important;
  }

  .trip-request-service .trip-map{
    min-height:300px !important;
    max-height:360px !important;
    height:100% !important;
    margin:8px 10px 8px 0 !important;
    width:calc(100% - 10px) !important;
  }

  .trip-request-wizard-actions{
    margin-top:8px !important;
  }

  .trip-request-wizard-actions button{
    height:42px !important;
  }
}

/* ===== SOLICITUD · BOTON AGREGAR SIEMPRE VISIBLE ===== */

@media(min-width:1100px){

  .trip-request-service{
    align-items:stretch !important;
  }

  .trip-request-service .trip-request-row:nth-of-type(3){
    min-height:0 !important;
    align-items:start !important;
  }

  .trip-request-service .trip-request-row:nth-of-type(3) .trip-request-row-content{
    display:flex !important;
    flex-direction:column !important;
    min-height:0 !important;
  }

  .trip-request-service .serviceStops{
    max-height:330px !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
    padding-right:4px !important;
    flex:1 1 auto !important;
  }

  .trip-request-add-stop{
    flex:0 0 auto !important;
    position:sticky !important;
    bottom:0 !important;
    z-index:5 !important;
    margin-top:6px !important;
    background:#f7fbff !important;
  }
}

/* ===== SOLICITUD · COMPACTA Y SIMETRICA ===== */

@media(min-width:1100px){

  .modal .card.trip-request-dialog{
    width:min(1540px,98.5vw) !important;
    padding:10px 16px !important;
  }

  .trip-request-service{
    grid-template-columns:58% 42% !important;
    align-items:stretch !important;
  }

  .trip-request-service-head{
    padding:6px 14px !important;
  }

  .trip-request-service-head strong{
    font-size:22px !important;
    line-height:1.1 !important;
  }

  .trip-request-service-head small{
    font-size:11px !important;
  }

  .trip-request-service .trip-request-row{
    padding:4px 12px !important;
    grid-template-columns:108px minmax(0,1fr) !important;
    gap:8px !important;
    min-height:44px !important;
  }

  .trip-request-row-label{
    font-size:12px !important;
    line-height:1.15 !important;
  }

  .trip-request-row input,
  .trip-request-row select{
    height:32px !important;
    min-height:32px !important;
    font-size:13px !important;
    padding-top:3px !important;
    padding-bottom:3px !important;
  }

  .trip-request-dialog .serviceStopRow{
    grid-template-columns:minmax(0,1fr) 64px 30px 30px 62px !important;
    gap:3px !important;
    margin:3px 0 !important;
    min-height:32px !important;
  }

  .trip-request-dialog .serviceStopRow select{
    height:32px !important;
    min-height:32px !important;
    font-size:12px !important;
  }

  .trip-request-dialog .serviceStopDetailsButton{
    height:32px !important;
    min-height:32px !important;
    min-width:64px !important;
    padding:0 4px !important;
    font-size:11px !important;
  }

  .trip-request-dialog .serviceStopActions button{
    width:30px !important;
    min-width:30px !important;
    height:32px !important;
    min-height:32px !important;
    padding:0 !important;
    font-size:12px !important;
  }

  .trip-request-dialog .serviceStopActions .danger{
    width:62px !important;
    min-width:62px !important;
    padding:0 3px !important;
    font-size:11px !important;
  }

  .trip-request-service .serviceStops{
    max-height:326px !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
    scrollbar-width:thin !important;
  }

  .trip-request-add-stop{
    height:30px !important;
    min-height:30px !important;
    padding:3px 8px !important;
    margin-top:4px !important;
    font-size:12px !important;
  }

  .trip-request-service .trip-map{
    min-height:420px !important;
    height:420px !important;
    max-height:420px !important;
    margin:6px 8px 6px 0 !important;
    width:calc(100% - 8px) !important;
    align-self:center !important;
  }

  .trip-request-wizard-status{
    margin:3px 0 6px !important;
  }

  .trip-request-wizard-actions{
    margin-top:6px !important;
  }

  .trip-request-wizard-actions button{
    height:36px !important;
    min-height:36px !important;
  }
}

/* ===== RESUMEN DE SOLICITUD COMPACTO ===== */

.trip-summary-modal{
  z-index:10050;
}

.modal .card.trip-summary-dialog{
  width:min(1440px,97vw);
  max-height:94vh;
  padding:14px 18px;
  display:flex;
  flex-direction:column;
  overflow:hidden;
}

.trip-summary-dialog .modal-head{
  flex:0 0 auto;
  margin-bottom:8px;
}

.trip-summary-dialog .modal-head h2{
  margin:0;
}

.trip-summary-content{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  display:grid;
  gap:10px;
  padding-right:4px;
}

.trip-summary-service{
  display:grid;
  grid-template-columns:minmax(0,58%) minmax(330px,42%);
  border:1px solid #dbe4ee;
  border-radius:12px;
  overflow:hidden;
  background:#fff;
  min-height:230px;
}

.trip-summary-info{
  min-width:0;
  padding:10px 14px;
  display:flex;
  flex-direction:column;
  gap:8px;
}

.trip-summary-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding-bottom:7px;
  border-bottom:1px solid #e6ebf0;
}

.trip-summary-head > div{
  display:flex;
  flex-direction:column;
  gap:2px;
}

.trip-summary-head small,
.trip-summary-load small,
.trip-summary-deliveries > small{
  font-size:11px;
  color:#697789;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.04em;
}

.trip-summary-head strong{
  font-size:18px;
  color:#07356b;
}

.trip-summary-head > span{
  background:#eef5fb;
  color:#07356b;
  border-radius:8px;
  padding:5px 9px;
  font-size:13px;
  font-weight:800;
}

.trip-summary-load{
  display:flex;
  gap:8px;
  align-items:center;
}

.trip-summary-load strong{
  font-size:13px;
}

.trip-summary-deliveries{
  min-height:0;
}

.trip-summary-stop-list{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:4px 10px;
  margin-top:5px;
}

.trip-summary-stop{
  display:flex;
  align-items:flex-start;
  gap:6px;
  min-width:0;
  font-size:12px;
  line-height:1.2;
}

.trip-summary-stop-number{
  flex:0 0 20px;
  width:20px;
  height:20px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:#07356b;
  color:#fff;
  font-size:10px;
  font-weight:800;
}

.trip-summary-stop > div{
  min-width:0;
}

.trip-summary-stop strong{
  display:block;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.trip-summary-stop small{
  display:block;
  margin-top:1px;
  color:#697789;
}

.trip-summary-map{
  width:100%;
  min-height:230px;
  height:100%;
  border-left:1px solid #dbe4ee;
}

.trip-summary-footer{
  flex:0 0 auto;
  display:flex;
  justify-content:space-between;
  gap:12px;
  padding-top:10px;
  margin-top:8px;
  border-top:1px solid #e1e7ed;
  background:#fff;
}

.trip-summary-footer button{
  min-width:180px;
  height:40px;
}

@media(max-width:900px){
  .modal .card.trip-summary-dialog{
    width:96vw;
    padding:12px;
  }

  .trip-summary-service{
    grid-template-columns:1fr;
  }

  .trip-summary-map{
    min-height:220px;
    height:220px;
    border-left:0;
    border-top:1px solid #dbe4ee;
  }

  .trip-summary-stop-list{
    grid-template-columns:1fr;
  }

  .trip-summary-footer button{
    flex:1;
    min-width:0;
  }
}

/* ===== RESUMEN SOLICITUD · PC ULTRA COMPACTO ===== */

@media(min-width:1100px){

  .modal .card.trip-summary-dialog{
    width:min(1580px,99vw) !important;
    height:min(900px,96vh) !important;
    max-height:96vh !important;
    padding:8px 12px !important;
  }

  .trip-summary-dialog .modal-head{
    margin-bottom:4px !important;
    min-height:38px !important;
  }

  .trip-summary-dialog .modal-head h2{
    font-size:20px !important;
    line-height:1.1 !important;
  }

  .trip-summary-dialog .modal-head .sub{
    margin:2px 0 0 !important;
    font-size:12px !important;
  }

  .trip-summary-content{
    gap:6px !important;
    padding-right:3px !important;
  }

  .trip-summary-service{
    grid-template-columns:62% 38% !important;
    min-height:175px !important;
    height:auto !important;
    border-radius:8px !important;
  }

  .trip-summary-info{
    padding:6px 9px !important;
    gap:4px !important;
  }

  .trip-summary-head{
    padding-bottom:4px !important;
    gap:8px !important;
  }

  .trip-summary-head small{
    font-size:9px !important;
  }

  .trip-summary-head strong{
    font-size:15px !important;
    line-height:1.05 !important;
  }

  .trip-summary-head > span{
    padding:3px 7px !important;
    font-size:11px !important;
  }

  .trip-summary-load{
    gap:5px !important;
    min-height:20px !important;
  }

  .trip-summary-load small,
  .trip-summary-deliveries > small{
    font-size:9px !important;
  }

  .trip-summary-load strong{
    font-size:11px !important;
  }

  .trip-summary-stop-list{
    grid-template-columns:
      repeat(3,minmax(0,1fr)) !important;

    gap:2px 8px !important;
    margin-top:3px !important;
  }

  .trip-summary-stop{
    gap:4px !important;
    font-size:10px !important;
    line-height:1.05 !important;
  }

  .trip-summary-stop-number{
    flex:0 0 16px !important;
    width:16px !important;
    height:16px !important;
    font-size:8px !important;
  }

  .trip-summary-stop strong{
    font-size:10px !important;
    line-height:1.05 !important;
  }

  .trip-summary-stop small{
    font-size:9px !important;
    line-height:1.05 !important;
  }

  .trip-summary-map{
    min-height:175px !important;
    height:100% !important;
  }

  .trip-summary-footer{
    padding-top:6px !important;
    margin-top:5px !important;
  }

  .trip-summary-footer button{
    height:36px !important;
    min-height:36px !important;
    min-width:170px !important;
    padding:5px 14px !important;
  }

  #backTripSummary{
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
  }

  #confirmTrip{
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
  }
}

/* ===== RESUMEN SOLICITUD V2 ===== */

.trip-summary-v2-modal{
  z-index:20000 !important;
}

.modal .card.trip-summary-v2-dialog{
  width:min(1580px,99vw) !important;
  height:min(920px,97vh) !important;
  max-height:97vh !important;
  padding:8px 12px !important;
  display:flex !important;
  flex-direction:column !important;
  overflow:hidden !important;
}

.trip-summary-v2-title{
  flex:0 0 auto;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:0 2px 6px;
}

.trip-summary-v2-title h2{
  margin:0;
  font-size:20px;
  line-height:1.1;
}

.trip-summary-v2-title small{
  font-size:11px;
  color:#718096;
}

.trip-summary-v2-body{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  display:grid;
  gap:5px;
  padding-right:3px;
}

.trip-summary-v2-service{
  display:grid;
  grid-template-columns:64% 36%;
  min-height:170px;
  border:1px solid #dbe4ee;
  border-radius:8px;
  overflow:hidden;
  background:#fff;
}

.trip-summary-v2-data{
  min-width:0;
  padding:5px 8px;
}

.trip-summary-v2-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:8px;
  border-bottom:1px solid #e5eaf0;
  padding-bottom:3px;
  margin-bottom:3px;
}

.trip-summary-v2-head > div{
  display:flex;
  flex-direction:column;
}

.trip-summary-v2-head small{
  font-size:9px;
  font-weight:800;
  color:#2d6eb5;
}

.trip-summary-v2-head strong{
  font-size:14px;
  line-height:1.05;
  color:#07356b;
}

.trip-summary-v2-head b{
  background:#eef5fb;
  border-radius:6px;
  padding:3px 7px;
  font-size:11px;
  color:#07356b;
}

.trip-summary-v2-load{
  display:flex;
  align-items:center;
  gap:6px;
  margin-bottom:4px;
}

.trip-summary-v2-load small{
  font-size:9px;
  text-transform:uppercase;
  font-weight:800;
  color:#66788a;
}

.trip-summary-v2-load strong{
  font-size:11px;
}

.trip-summary-v2-stops{
  display:grid;
  grid-template-columns:
    repeat(3,minmax(0,1fr));
  gap:2px 7px;
}

.trip-summary-v2-stop{
  display:flex;
  align-items:flex-start;
  gap:4px;
  min-width:0;
}

.trip-summary-v2-stop > span{
  flex:0 0 16px;
  width:16px;
  height:16px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:#07356b;
  color:#fff;
  font-size:8px;
  font-weight:800;
}

.trip-summary-v2-stop > div{
  min-width:0;
}

.trip-summary-v2-stop strong{
  display:block;
  font-size:10px;
  line-height:1.05;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.trip-summary-v2-stop small{
  display:block;
  font-size:8px;
  color:#6f7d8d;
  line-height:1.05;
}

.trip-summary-v2-map{
  min-height:170px;
  height:100%;
  border-left:1px solid #dbe4ee;
}

.trip-summary-v2-footer{
  flex:0 0 auto;
  display:flex;
  justify-content:space-between;
  gap:10px;
  padding-top:6px;
  margin-top:5px;
  border-top:1px solid #e1e7ed;
}

.trip-summary-v2-footer button{
  height:36px !important;
  min-height:36px !important;
  min-width:180px;
}

@media(max-width:900px){

  .modal .card.trip-summary-v2-dialog{
    width:96vw !important;
    padding:8px !important;
  }

  .trip-summary-v2-service{
    grid-template-columns:1fr;
  }

  .trip-summary-v2-stops{
    grid-template-columns:1fr;
  }

  .trip-summary-v2-map{
    height:210px;
    min-height:210px;
    border-left:0;
    border-top:1px solid #dbe4ee;
  }

  .trip-summary-v2-footer button{
    flex:1;
    min-width:0;
  }
}

/* ===== WIZARD · BOTONES INFERIORES ALINEADOS ===== */

.trip-request-wizard-actions{
  display:flex !important;
  width:100% !important;
  gap:10px !important;
  align-items:stretch !important;
}

.trip-request-wizard-actions button{
  flex:1 1 0 !important;
  width:auto !important;
  min-width:0 !important;
  height:38px !important;
  margin:0 !important;
}

.trip-request-wizard-actions button[hidden]{
  display:none !important;
}

/* Si queda un solo botón visible ocupa todo */
.trip-request-wizard-actions button:only-child{
  width:100% !important;
}


/* ===== SOLICITAR VIAJE · CABECERA COMPACTA PC ===== */

@media(min-width:1100px){

  .modal .card.trip-request-dialog{
    padding-top:8px !important;
  }

  .trip-request-dialog > .modal-head{
    margin-bottom:4px !important;
    min-height:34px !important;
  }

  .trip-request-dialog > .modal-head h2{
    margin:0 !important;
    font-size:22px !important;
    line-height:1.05 !important;
  }

  .trip-request-date{
    margin:0 0 4px !important;
    padding:0 !important;
    max-width:520px !important;
  }

  .trip-request-date label{
    margin:0 0 3px !important;
    font-size:12px !important;
  }

  .trip-request-date select{
    height:36px !important;
    min-height:36px !important;
    padding:4px 8px !important;
    font-size:13px !important;
  }

  .trip-request-date .sub,
  .trip-request-date p{
    margin:3px 0 0 !important;
    font-size:10px !important;
    line-height:1.1 !important;
  }

  .trip-request-wizard-status{
    margin:5px 0 5px !important;
    min-height:18px !important;
    font-size:12px !important;
  }

  .trip-request-service{
    margin-top:0 !important;
  }

  .trip-request-wizard-actions{
    margin-top:5px !important;
    padding-top:0 !important;
  }
}

/* ===== RESUMEN · FOOTER CENTRADO ===== */

.trip-summary-footer{
  display:grid !important;
  grid-template-columns:220px minmax(320px,520px) 220px !important;
  justify-content:center !important;
  align-items:center !important;
  gap:14px !important;
}

#backTripSummary{
  grid-column:1 !important;
  justify-self:center !important;
  width:180px !important;
}

#confirmTrip{
  grid-column:2 !important;
  justify-self:center !important;
  width:100% !important;
  max-width:520px !important;
}

@media(max-width:900px){
  .trip-summary-footer{
    display:flex !important;
    grid-template-columns:none !important;
  }

  #backTripSummary,
  #confirmTrip{
    width:auto !important;
    max-width:none !important;
  }
}

/* ===== CLIENTE · EDITAR VIAJE CON MAPA ===== */

@media(min-width:1000px){

  .modal .card.client-trip-edit-map-dialog{
    width:min(1350px,96vw) !important;
  }

  .client-trip-edit-map-dialog #clientTripEdit{
    display:grid !important;
    grid-template-columns:
      minmax(0,55%)
      minmax(380px,45%) !important;
    gap:10px 18px !important;
  }

  .client-trip-edit-map-dialog #clientTripEdit > .field,
  .client-trip-edit-map-dialog #clientTripEdit > #formmsg,
  .client-trip-edit-map-dialog #clientTripEdit > button{
    grid-column:1 !important;
  }

  .client-trip-edit-map{
    grid-column:2 !important;
    grid-row:1 / span 5 !important;

    width:100% !important;
    height:100% !important;
    min-height:430px !important;

    margin:0 !important;
    align-self:stretch !important;
  }
}


/* ===== CLIENTE · DETALLE CON MAPA ===== */

@media(min-width:1000px){

  .modal .card.client-trip-detail-map-dialog{
    width:min(1450px,97vw) !important;
  }

  .client-trip-detail-map-dialog{
    display:grid !important;
    grid-template-columns:
      minmax(0,58%)
      minmax(400px,42%) !important;
    column-gap:16px !important;
  }

  .client-trip-detail-map-dialog > .modal-head{
    grid-column:1/-1 !important;
  }

  .client-trip-detail-map-dialog > .schedule{
    grid-column:1 !important;
  }

  .client-trip-detail-map{
    grid-column:2 !important;
    grid-row:2 !important;

    width:100% !important;
    height:100% !important;
    min-height:480px !important;

    margin:0 !important;
  }

  .client-trip-detail-map-dialog > .actions{
    grid-column:1/-1 !important;
  }
}


@media(max-width:999px){

  .client-trip-edit-map,
  .client-trip-detail-map{
    height:260px !important;
    min-height:260px !important;
    margin-top:12px !important;
  }

}

/* ===== CLIENTE · DETALLE MAPA FIX V2 ===== */

.modal .card.client-trip-detail-map-dialog{
  width:min(1450px,97vw) !important;
  max-width:1450px !important;
}

.client-trip-detail-map{
  display:block !important;
  width:100% !important;
  height:480px !important;
  min-height:480px !important;
  margin:0 !important;
}

@media(min-width:1000px){

  .client-trip-detail-map-dialog{
    display:grid !important;
    grid-template-columns:minmax(0,58%) minmax(380px,42%) !important;
    gap:14px 16px !important;
    align-items:start !important;
  }

  .client-trip-detail-map-dialog > .modal-head{
    grid-column:1 / -1 !important;
  }

  .client-trip-detail-map-dialog > .schedule{
    grid-column:1 !important;
    grid-row:2 !important;
  }

  .client-trip-detail-map-dialog > .client-trip-detail-map{
    grid-column:2 !important;
    grid-row:2 !important;
    height:100% !important;
    min-height:480px !important;
  }

  .client-trip-detail-map-dialog > .actions{
    grid-column:1 / -1 !important;
  }
}

@media(max-width:999px){

  .client-trip-detail-map{
    height:300px !important;
    min-height:300px !important;
    margin-top:12px !important;
  }

}

/* ===== CLIENTE · DETALLE MAPA FIX V2 END ===== */

/* ===== CLIENTE · DETALLE VIAJE COMPACTO V3 ===== */

@media(min-width:1000px){

  .modal .card.client-trip-detail-map-dialog{
    width:min(1450px,97vw) !important;
    max-width:1450px !important;
    max-height:calc(100vh - 24px) !important;

    padding:14px 18px !important;
    overflow:hidden !important;

    grid-template-columns:minmax(0,58%) minmax(380px,42%) !important;
    grid-template-rows:auto minmax(0,1fr) auto !important;

    gap:10px 16px !important;
  }

  .client-trip-detail-map-dialog > .modal-head{
    margin:0 !important;
    padding:0 0 8px !important;
  }

  .client-trip-detail-map-dialog > .modal-head h2{
    margin:0 !important;
    font-size:23px !important;
    line-height:1.1 !important;
  }

  .client-trip-detail-map-dialog > .schedule{
    grid-column:1 !important;
    grid-row:2 !important;

    gap:8px 12px !important;
    margin:0 !important;
    align-content:start !important;

    min-height:0 !important;
  }

  .client-trip-detail-map-dialog .schedule-item{
    padding:9px 12px !important;
    min-height:0 !important;

    font-size:14px !important;
    line-height:1.22 !important;
  }

  .client-trip-detail-map-dialog .schedule-item b{
    line-height:1.15 !important;
  }

  .client-trip-detail-map-dialog .schedule-item small{
    font-size:12px !important;
    line-height:1.15 !important;
  }

  .client-trip-detail-map-dialog .delivery-detail-list{
    gap:7px 10px !important;
    margin-top:7px !important;
  }

  .client-trip-detail-map-dialog .delivery-detail{
    padding:7px 10px !important;
    min-height:0 !important;

    font-size:13px !important;
    line-height:1.18 !important;
  }

  .client-trip-detail-map-dialog .delivery-detail small{
    font-size:11px !important;
    line-height:1.1 !important;
  }

  .client-trip-detail-map-dialog > .client-trip-detail-map{
    grid-column:2 !important;
    grid-row:2 !important;

    height:100% !important;
    min-height:0 !important;
    max-height:calc(100vh - 105px) !important;

    margin:0 !important;
  }

  .client-trip-detail-map-dialog > .actions{
    grid-column:1/-1 !important;
    margin:0 !important;
    padding-top:2px !important;
  }

  .client-trip-detail-map-dialog > .actions button{
    padding:7px 14px !important;
  }

}


/* Admin Viajes: constrain the grid item and keep overflow inside the table. */
.content:has(.admin-trips-table-wrap){min-width:0;margin-inline:auto}
#page:has(.admin-trips-table-wrap){min-width:0;max-width:100%}
.admin-trips-table-wrap{
  width:100% !important;
  max-width:100% !important;
  min-width:0;
  overflow-x:auto !important;
}
.admin-trips-table{
  width:100% !important;
  min-width:760px !important;
  table-layout:fixed !important;
  font-size:12px !important;
}
.admin-trips-table th,.admin-trips-table td{
  padding:9px 7px !important;
  vertical-align:middle !important;
  white-space:normal !important;
  overflow-wrap:anywhere;
}
.admin-trips-table th:first-child{width:7%}
.admin-trips-table th.admin-trips-actions-cell{width:26%}
.admin-trips-actions{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:5px;
}
.admin-trips-table .admin-trips-actions button{
  flex:0 1 auto;
  width:auto !important;
  max-width:100%;
  margin:0 !important;
  padding:7px 9px !important;
  font-size:11px !important;
  white-space:normal !important;
}
/* Reuse the client layout while keeping long admin details scrollable. */
@media(min-width:1000px){
  .modal .card.admin-trip-detail-map-dialog{
    grid-template-columns:minmax(0,58fr) minmax(0,42fr) !important;
  }
  .admin-trip-detail-map-dialog > .schedule{overflow-y:auto;min-width:0}
}

/* === CLIENT ADDRESS SEARCHABLE COMBOBOX V1 === */

.address-combobox{
  position:relative;
  width:100%;
  min-width:0;
}

.address-combobox-input{
  width:100% !important;
  min-width:0 !important;
  box-sizing:border-box !important;
  padding-right:42px !important;
}

.address-combobox-toggle{
  position:absolute;
  top:50%;
  right:5px;
  transform:translateY(-50%);
  width:32px;
  height:32px;
  padding:0;
  border:0;
  background:transparent;
  color:#163f70;
  font-size:20px;
  line-height:1;
  cursor:pointer;
  z-index:2;
}

.address-combobox-native{
  position:absolute !important;
  width:1px !important;
  height:1px !important;
  opacity:0 !important;
  pointer-events:none !important;
  overflow:hidden !important;
}

.address-combobox-menu{
  position:absolute;
  left:0;
  right:0;
  top:calc(100% + 4px);
  z-index:10050;
  max-height:260px;
  overflow-y:auto;
  background:#fff;
  border:1px solid #ccd8e6;
  border-radius:10px;
  box-shadow:
    0 10px 30px rgba(18,45,77,.16);
  padding:5px;
}

.address-combobox-option{
  display:block;
  width:100%;
  padding:9px 10px;
  border:0;
  border-radius:7px;
  background:#fff;
  color:#123866;
  text-align:left;
  font:inherit;
  cursor:pointer;
}

.address-combobox-option:hover,
.address-combobox-option.selected{
  background:#edf5fd;
}

.address-combobox-empty{
  padding:10px;
  color:#6d7d90;
  font-size:13px;
}

.trip-request-dialog .serviceStopRow
.address-combobox{
  width:100%;
  min-width:0;
}

/* === CLIENT ADDRESS SEARCHABLE COMBOBOX V1 END === */

/* === CLIENT ADDRESS SEARCHABLE COMBOBOX V2 FIX === */

.address-combobox-toggle{
  top:0 !important;
  right:0 !important;
  transform:none !important;
  width:42px !important;
  height:100% !important;
  min-height:40px !important;
  border:0 !important;
  border-left:1px solid transparent !important;
  border-radius:0 9px 9px 0 !important;
  background:transparent !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  font-size:0 !important;
}

.address-combobox-toggle::after{
  content:"";
  width:8px;
  height:8px;
  border-right:2px solid #315a88;
  border-bottom:2px solid #315a88;
  transform:rotate(45deg) translateY(-2px);
}

.address-combobox.open
.address-combobox-toggle::after{
  transform:rotate(225deg) translate(-2px,-2px);
}

.address-combobox.open{
  z-index:10060;
}

.address-combobox-menu{
  z-index:10070 !important;
}

/* === CLIENT ADDRESS SEARCHABLE COMBOBOX V2 FIX END === */

/* === CLIENT ADDRESS SEARCHABLE COMBOBOX V3 PORTAL === */

.address-combobox-menu{
  position:fixed !important;
  z-index:999999 !important;
  margin:0 !important;
  box-sizing:border-box !important;
}

.address-combobox-menu[hidden]{
  display:none !important;
}

.address-combobox-option{
  min-height:38px;
  display:flex;
  align-items:center;
}

/* === CLIENT ADDRESS SEARCHABLE COMBOBOX V3 PORTAL END === */

/* === TRIP REQUEST INLINE ADDRESS CREATE V1 === */

.trip-request-address-toolbar{
  display:flex;
  justify-content:flex-end;
  align-items:center;
  gap:8px;
  flex-wrap:wrap;
  margin:0 0 12px;
}

.trip-request-address-toolbar button{
  width:auto;
}

@media(max-width:680px){
  .trip-request-address-toolbar{
    justify-content:stretch;
  }

  .trip-request-address-toolbar button{
    flex:1 1 100%;
  }
}

/* === TRIP REQUEST INLINE ADDRESS CREATE V1 END === */

/* === CLIENT TRIP REQUEST MOBILE RESPONSIVE V1 === */

@media(max-width:680px){

  .modal .card.trip-request-dialog{
    width:calc(100vw - 20px) !important;
    max-width:calc(100vw - 20px) !important;
    min-width:0 !important;
    max-height:calc(100vh - 20px) !important;
    margin:10px !important;
    padding:16px !important;
    overflow-x:hidden !important;
    overflow-y:auto !important;
    box-sizing:border-box !important;
  }

  .trip-request-form,
  .trip-request-services,
  .trip-request-service{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  .trip-request-service{
    display:block !important;
    padding:14px !important;
  }

  .trip-request-service-head{
    width:100% !important;
    margin-bottom:14px !important;
  }

  .trip-request-row{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    padding:12px 0 !important;
    box-sizing:border-box !important;
  }

  .trip-request-row-label{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    margin:0 0 7px !important;
  }

  .trip-request-row-content,
  .trip-request-load-grid,
  .trip-request-time,
  .trip-request-service .serviceStops{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  .trip-request-row input,
  .trip-request-row select,
  .address-combobox,
  .address-combobox-input{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  .trip-request-dialog .serviceStopRow{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:8px 0 14px !important;
  }

  .trip-request-dialog .serviceStopRow .address-combobox{
    width:100% !important;
    margin-bottom:7px !important;
  }

  .trip-request-dialog .serviceStopDetailsButton{
    width:100% !important;
    margin:0 0 7px !important;
  }

  .trip-request-dialog .serviceStopActions{
    display:grid !important;
    grid-template-columns:1fr 1fr 1.35fr !important;
    gap:6px !important;
    width:100% !important;
  }

  .trip-request-dialog .serviceStopActions button{
    width:100% !important;
    min-width:0 !important;
  }

  .trip-request-add-stop{
    width:100% !important;
    max-width:100% !important;
  }

  .trip-request-service .trip-map{
    display:block !important;
    position:relative !important;
    grid-column:auto !important;
    grid-row:auto !important;
    width:100% !important;
    max-width:100% !important;
    height:260px !important;
    min-height:260px !important;
    max-height:260px !important;
    margin:16px 0 0 !important;
    box-sizing:border-box !important;
    border-radius:12px !important;
  }

  .trip-request-date{
    width:100% !important;
    max-width:100% !important;
  }

  .trip-request-date select{
    width:100% !important;
    max-width:100% !important;
  }

  .trip-request-address-toolbar{
    display:grid !important;
    grid-template-columns:1fr !important;
    width:100% !important;
    gap:7px !important;
  }

  .trip-request-address-toolbar button{
    width:100% !important;
  }

  .trip-request-wizard-actions{
    width:100% !important;
  }

  .trip-request-wizard-actions button{
    max-width:100% !important;
  }
}

/* === CLIENT TRIP REQUEST MOBILE RESPONSIVE V1 END === */

/* === CLIENT TRIP REQUEST MOBILE RESPONSIVE V2 === */

@media(max-width:680px){

  .trip-request-row{
    display:block !important;
    padding:14px 0 !important;
  }

  .trip-request-row-label{
    display:block !important;
    width:100% !important;
    margin:0 0 8px !important;
    font-size:15px !important;
    line-height:1.25 !important;
  }

  .trip-request-row-content{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
  }

  .trip-request-time input,
  .trip-request-load-grid,
  .address-combobox,
  .address-combobox-input{
    width:100% !important;
    max-width:100% !important;
  }

  .trip-request-time input{
    min-height:42px !important;
  }

  .trip-request-dialog .serviceStopRow{
    display:block !important;
    width:100% !important;
  }

  .trip-request-dialog .serviceStopRow .address-combobox{
    width:100% !important;
    margin-bottom:8px !important;
  }

  .trip-request-dialog .serviceStopDetailsButton{
    width:100% !important;
    margin-bottom:8px !important;
  }

  .trip-request-dialog .serviceStopActions{
    display:grid !important;
    grid-template-columns:1fr 1fr 1.4fr !important;
    gap:6px !important;
    width:100% !important;
  }

  .trip-request-dialog .serviceStopActions button{
    width:100% !important;
    min-width:0 !important;
    padding:8px 6px !important;
    font-size:13px !important;
  }

  .trip-request-add-stop{
    width:100% !important;
    margin-top:8px !important;
  }

  .trip-request-service-head strong{
    font-size:22px !important;
    line-height:1.2 !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE RESPONSIVE V2 END === */

/* === CLIENT TRIP REQUEST MOBILE STACK V3 === */

@media(max-width:680px){

  .modal .card.trip-request-dialog
  .trip-request-service
  .trip-request-row{
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    grid-template-columns:none !important;
    grid-template-rows:none !important;
    width:100% !important;
    max-width:100% !important;
    gap:8px !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-service
  .trip-request-row-label{
    display:block !important;
    position:static !important;
    width:100% !important;
    max-width:100% !important;
    flex:none !important;
    margin:0 !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-service
  .trip-request-row-content{
    display:block !important;
    position:static !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    flex:none !important;
    margin:0 !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-service
  .trip-request-row-content > input,

  .modal .card.trip-request-dialog
  .trip-request-service
  .trip-request-row-content > select,

  .modal .card.trip-request-dialog
  .trip-request-service
  .address-combobox,

  .modal .card.trip-request-dialog
  .trip-request-service
  .address-combobox-input{
    width:100% !important;
    max-width:100% !important;
    box-sizing:border-box !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE STACK V3 END === */

/* === CLIENT TRIP REQUEST MOBILE STOPS V4 === */

@media(max-width:680px){

  .trip-request-service .serviceStops{
    position:relative !important;
    z-index:5 !important;
    overflow:visible !important;
    width:100% !important;
  }

  .trip-request-dialog .serviceStopRow{
    position:relative !important;
    z-index:6 !important;
    overflow:visible !important;
  }

  .trip-request-dialog .serviceStopActions{
    display:grid !important;
    grid-template-columns:1fr 1fr 1.4fr !important;
    gap:8px !important;
    width:100% !important;
    flex-wrap:nowrap !important;
  }

  .trip-request-dialog .serviceStopActions button{
    width:100% !important;
    min-width:0 !important;
    margin:0 !important;
    white-space:nowrap !important;
  }

  .trip-request-dialog .serviceStopActions .danger{
    grid-column:auto !important;
    grid-row:auto !important;
  }

  .trip-request-service .trip-map{
    position:relative !important;
    z-index:1 !important;
    clear:both !important;
    margin-top:22px !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE STOPS V4 END === */

/* === CLIENT TRIP REQUEST MOBILE STOPS V5 === */

@media(max-width:680px){

  .trip-request-service .serviceStops{
    display:flex !important;
    flex-direction:column !important;
    gap:18px !important;
  }

  .trip-request-dialog .serviceStopRow{
    display:flex !important;
    flex-direction:column !important;
    gap:8px !important;
    margin:0 !important;
    padding:0 0 16px !important;
    width:100% !important;
  }

  .trip-request-dialog .serviceStopActions{
    display:grid !important;
    grid-template-columns:1fr 1fr 1.4fr !important;
    gap:8px !important;
    width:100% !important;
  }

  .trip-request-add-stop{
    display:block !important;
    position:relative !important;
    clear:both !important;
    width:100% !important;
    margin:14px 0 0 !important;
    z-index:2 !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE STOPS V5 END === */

/* === CLIENT TRIP REQUEST MOBILE STOPS V6 FINAL === */

@media(max-width:680px){

  .modal .card.trip-request-dialog
  .trip-request-service
  .serviceStops{
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    gap:20px !important;

    position:static !important;
    width:100% !important;
    height:auto !important;
    min-height:0 !important;
    max-height:none !important;

    overflow:visible !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-service
  .serviceStopRow{
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;

    position:static !important;
    float:none !important;

    width:100% !important;
    height:auto !important;
    min-height:0 !important;
    max-height:none !important;

    gap:8px !important;
    margin:0 !important;
    padding:0 0 4px !important;

    overflow:visible !important;
  }

  .modal .card.trip-request-dialog
  .serviceStopRow
  .address-combobox{
    position:relative !important;
    width:100% !important;
    margin:0 !important;
  }

  .modal .card.trip-request-dialog
  .serviceStopDetailsButton{
    position:static !important;
    float:none !important;
    transform:none !important;

    display:block !important;
    width:100% !important;
    margin:0 !important;
  }

  .modal .card.trip-request-dialog
  .serviceStopActions{
    position:static !important;
    float:none !important;
    transform:none !important;

    display:grid !important;
    grid-template-columns:1fr 1fr 1.35fr !important;
    gap:8px !important;

    width:100% !important;
    height:auto !important;
    margin:0 !important;
  }

  .modal .card.trip-request-dialog
  .serviceStopActions button{
    position:static !important;
    float:none !important;
    transform:none !important;

    width:100% !important;
    min-width:0 !important;
    margin:0 !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-add-stop{
    position:static !important;
    float:none !important;
    transform:none !important;

    display:block !important;
    clear:both !important;

    width:100% !important;
    height:auto !important;

    margin:22px 0 0 !important;
    padding:12px !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-service
  .trip-map{
    position:relative !important;
    float:none !important;
    clear:both !important;

    width:100% !important;
    margin:24px 0 0 !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE STOPS V6 FINAL END === */

/* === CLIENT TRIP REQUEST MOBILE WIZARD ACTIONS V1 === */

@media(max-width:680px){

  .modal .card.trip-request-dialog
  .trip-request-wizard-actions{
    display:grid !important;
    grid-template-columns:1fr 1fr !important;
    gap:10px !important;
    width:100% !important;
    align-items:stretch !important;
    margin-top:18px !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-wizard-actions button{
    width:100% !important;
    min-width:0 !important;
    height:44px !important;
    min-height:44px !important;
    margin:0 !important;
    padding:0 10px !important;
    display:flex !important;
    align-items:center !important;
    justify-content:center !important;
    white-space:nowrap !important;
    line-height:1 !important;
    box-sizing:border-box !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-summary-button{
    grid-column:2 !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE WIZARD ACTIONS V1 END === */

/* === CLIENT TRIP REQUEST MOBILE FINAL BUTTONS V2 === */

@media(max-width:680px){

  .modal .card.trip-request-dialog
  .trip-request-wizard-actions{
    grid-template-columns:.9fr 1.1fr !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-summary-button{
    white-space:nowrap !important;
    font-size:14px !important;
    padding:0 8px !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE FINAL BUTTONS V2 END === */

/* === CLIENT TRIP REQUEST MOBILE FINAL BUTTONS V3 === */

@media(max-width:680px){

  .modal .card.trip-request-dialog
  .trip-request-wizard-actions{
    grid-template-columns:.7fr 1.3fr !important;
    gap:8px !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-wizard-actions button{
    font-size:13px !important;
    padding:0 6px !important;
  }

  .modal .card.trip-request-dialog
  .trip-request-summary-button{
    white-space:nowrap !important;
    overflow:hidden !important;
    text-overflow:clip !important;
  }

}

/* === CLIENT TRIP REQUEST MOBILE FINAL BUTTONS V3 END === */

/* === MOBILE SUMMARY CONFIRM BUTTON FIX === */

@media(max-width:680px){

  #confirmTrip{
    white-space:nowrap !important;
    font-size:12px !important;
    line-height:1 !important;
    padding:0 8px !important;
    min-width:0 !important;
  }

}

/* === MOBILE SUMMARY CONFIRM BUTTON FIX END === */

/* === REMITO OPERATION DETAIL LAYOUT FIX V1 === */

.client-trip-detail-map-dialog > .schedule,
.admin-trip-detail-map-dialog > .schedule{
  overflow-y:auto !important;
  overflow-x:hidden !important;
  min-height:0 !important;
  align-content:start !important;
}

.client-trip-detail-map-dialog .operation-admin,
.admin-trip-detail-map-dialog .operation-admin,
.trip-detail-dialog .operation-admin{
  grid-column:1 / -1 !important;
  width:100%;
  min-width:0;
  margin:4px 0 0;
  padding:12px 0 0;
  border-top:1px solid #d9e3ee;
}

.operation-admin h3{
  margin:0 0 10px;
  font-size:16px;
  line-height:1.2;
}

.operation-admin article{
  display:block;
  margin:0 0 8px;
  padding:10px 12px;
  border:1px solid #d9e3ee;
  border-radius:10px;
  background:#fff;
  line-height:1.3;
}

.operation-admin article:last-child{
  margin-bottom:0;
}

.operation-admin article b{
  display:block;
  margin-bottom:4px;
}

.operation-admin article p{
  margin:3px 0;
}

@media(min-width:1000px){
  .client-trip-detail-map-dialog .operation-admin,
  .admin-trip-detail-map-dialog .operation-admin{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:8px;
  }

  .client-trip-detail-map-dialog .operation-admin h3,
  .admin-trip-detail-map-dialog .operation-admin h3{
    grid-column:1 / -1;
  }

  .operation-admin article{
    margin:0;
  }
}

@media(max-width:999px){
  .operation-admin{
    display:block !important;
  }

  .operation-admin article{
    width:100%;
    box-sizing:border-box;
  }
}

/* === REMITO OPERATION DETAIL LAYOUT FIX V1 END === */

/* === REMITO DETAIL FINAL LAYOUT V2 === */

@media(min-width:1000px){

  .modal .card.client-trip-detail-map-dialog,
  .modal .card.admin-trip-detail-map-dialog{
    max-height:calc(100vh - 24px) !important;
    overflow:hidden !important;
  }

  .client-trip-detail-map-dialog > .schedule,
  .admin-trip-detail-map-dialog > .schedule{
    overflow-y:auto !important;
    overflow-x:hidden !important;
    padding-right:6px !important;
    max-height:calc(100vh - 115px) !important;
  }

  .client-trip-detail-map-dialog > .actions,
  .admin-trip-detail-map-dialog > .actions{
    position:relative !important;
    z-index:3 !important;
    background:#fff !important;
    padding-top:8px !important;
    margin-top:0 !important;
  }

  .client-trip-detail-map-dialog .operation-admin,
  .admin-trip-detail-map-dialog .operation-admin{
    padding-bottom:12px !important;
  }
}

/* === REMITO DETAIL FINAL LAYOUT V2 END === */

/* === REMITO COMPACT DESKTOP V3 === */

@media(min-width:1000px){

  .modal .card.client-trip-detail-map-dialog,
  .modal .card.admin-trip-detail-map-dialog,
  .modal .card.trip-detail-dialog{
    width:min(1380px,96vw) !important;
    max-width:1380px !important;
    max-height:calc(100vh - 16px) !important;
    padding:10px 14px !important;
    gap:8px 12px !important;
  }

  .client-trip-detail-map-dialog > .modal-head,
  .admin-trip-detail-map-dialog > .modal-head,
  .trip-detail-dialog > .modal-head{
    padding-bottom:4px !important;
    margin-bottom:0 !important;
  }

  .client-trip-detail-map-dialog > .modal-head h2,
  .admin-trip-detail-map-dialog > .modal-head h2,
  .trip-detail-dialog > .modal-head h2{
    font-size:21px !important;
    line-height:1.05 !important;
  }

  .client-trip-detail-map-dialog > .schedule,
  .admin-trip-detail-map-dialog > .schedule,
  .trip-detail-dialog > .schedule{
    gap:5px 8px !important;
    margin:0 !important;
    overflow:visible !important;
    max-height:none !important;
  }

  .client-trip-detail-map-dialog .schedule-item,
  .admin-trip-detail-map-dialog .schedule-item,
  .trip-detail-dialog .schedule-item{
    padding:6px 9px !important;
    font-size:12.5px !important;
    line-height:1.12 !important;
  }

  .client-trip-detail-map-dialog .schedule-item b,
  .admin-trip-detail-map-dialog .schedule-item b,
  .trip-detail-dialog .schedule-item b{
    font-size:12.5px !important;
    line-height:1.08 !important;
  }

  .client-trip-detail-map-dialog .schedule-item small,
  .admin-trip-detail-map-dialog .schedule-item small,
  .trip-detail-dialog .schedule-item small{
    font-size:10.5px !important;
    line-height:1.08 !important;
  }

  .client-trip-detail-map-dialog .operation-admin,
  .admin-trip-detail-map-dialog .operation-admin,
  .trip-detail-dialog .operation-admin{
    margin-top:3px !important;
    padding-top:7px !important;
    gap:5px !important;
  }

  .operation-admin h3{
    font-size:14px !important;
    margin:0 0 6px !important;
  }

  .operation-admin article{
    padding:7px 9px !important;
    font-size:12px !important;
    line-height:1.12 !important;
    min-height:0 !important;
  }

  .operation-admin article b{
    font-size:12px !important;
    margin-bottom:2px !important;
  }

  .operation-admin article p{
    margin:2px 0 !important;
    line-height:1.1 !important;
  }

  .client-trip-detail-map,
  .admin-trip-detail-map{
    min-height:0 !important;
    height:100% !important;
    max-height:calc(100vh - 82px) !important;
  }
}

/* === REMITO COMPACT DESKTOP V3 END === */

/* === REMITO LEFT COLUMN VERTICAL SCROLL V4 === */

@media(min-width:1000px){

  .modal .card.client-trip-detail-map-dialog,
  .modal .card.admin-trip-detail-map-dialog,
  .modal .card.trip-detail-dialog{
    max-height:calc(100vh - 18px) !important;
    overflow:hidden !important;
  }

  .client-trip-detail-map-dialog > .schedule,
  .admin-trip-detail-map-dialog > .schedule,
  .trip-detail-dialog > .schedule{
    max-height:calc(100vh - 90px) !important;
    overflow-y:auto !important;
    overflow-x:hidden !important;
    padding-right:8px !important;
    scrollbar-gutter:stable;
  }

  .client-trip-detail-map-dialog > .client-trip-detail-map,
  .admin-trip-detail-map-dialog > .client-trip-detail-map{
    position:sticky;
    top:0;
    align-self:start;
    max-height:calc(100vh - 90px) !important;
  }

}

/* === REMITO LEFT COLUMN VERTICAL SCROLL V4 END === */

/* === REMITO SCROLL LAYOUT FINAL V5 === */

@media(min-width:1000px){

  .modal .card.client-trip-detail-map-dialog,
  .modal .card.admin-trip-detail-map-dialog{
    height:calc(100vh - 24px) !important;
    max-height:calc(100vh - 24px) !important;

    display:grid !important;
    grid-template-columns:minmax(0,58%) minmax(380px,42%) !important;
    grid-template-rows:auto minmax(0,1fr) !important;

    gap:10px 16px !important;
    overflow:hidden !important;
  }

  .client-trip-detail-map-dialog > .modal-head,
  .admin-trip-detail-map-dialog > .modal-head{
    grid-column:1 / -1 !important;
    grid-row:1 !important;
  }

  .client-trip-detail-map-dialog > .schedule,
  .admin-trip-detail-map-dialog > .schedule{
    grid-column:1 !important;
    grid-row:2 !important;

    min-height:0 !important;
    height:100% !important;
    max-height:none !important;

    overflow-y:auto !important;
    overflow-x:hidden !important;

    padding-right:8px !important;
    align-content:start !important;
    scrollbar-gutter:stable;
  }

  .client-trip-detail-map-dialog > .client-trip-detail-map,
  .admin-trip-detail-map-dialog > .client-trip-detail-map{
    grid-column:2 !important;
    grid-row:2 !important;

    width:100% !important;
    height:100% !important;
    min-height:0 !important;
    max-height:none !important;

    margin:0 !important;
    position:relative !important;
  }

}

/* === REMITO SCROLL LAYOUT FINAL V5 END === */

/* === REMITO SCROLL ROWS FIX V6 === */

@media(min-width:1000px){

  .client-trip-detail-map-dialog > .schedule,
  .admin-trip-detail-map-dialog > .schedule{
    display:grid !important;

    grid-template-columns:
      repeat(2,minmax(0,1fr)) !important;

    grid-template-rows:none !important;
    grid-auto-rows:max-content !important;

    align-items:start !important;
    align-content:start !important;

    height:100% !important;
    min-height:0 !important;

    overflow-y:auto !important;
    overflow-x:hidden !important;
  }

  .client-trip-detail-map-dialog .schedule-item,
  .admin-trip-detail-map-dialog .schedule-item{
    min-height:max-content !important;
    height:auto !important;
    align-self:start !important;
  }

  .client-trip-detail-map-dialog .operation-admin,
  .admin-trip-detail-map-dialog .operation-admin{
    grid-column:1 / -1 !important;
    min-height:max-content !important;
    height:auto !important;
    align-self:start !important;
  }

}

/* === REMITO SCROLL ROWS FIX V6 END === */
