:root{--nav:#0d2032;--blue:#1777d3;--bg:#f4f7fa;--border:#dce5ed;--text:#17232e;--muted:#71808e}
*{box-sizing:border-box}body{margin:0;font:14px/1.45 Segoe UI,Arial;background:var(--bg);color:var(--text)}a{color:var(--blue);text-decoration:none}.layout{display:grid;grid-template-columns:240px 1fr;min-height:100vh}aside{background:var(--nav);padding:20px;color:white;display:flex;flex-direction:column}.brand{display:flex;gap:10px;align-items:center}.brand img{width:50px;height:50px;object-fit:contain;background:white;border-radius:10px}.brand small,.brand b{display:block}.brand small{opacity:.7}nav{display:grid;gap:6px;margin-top:28px}nav a{color:#cbd8e4;padding:11px;border-radius:8px}nav a.active,nav a:hover{background:#1d3b54;color:#fff}aside form{margin-top:auto}button{padding:9px 12px;border:1px solid var(--border);border-radius:8px;background:#fff;cursor:pointer}.primary{background:var(--blue);color:#fff;border-color:var(--blue)}main header{height:66px;background:#fff;border-bottom:1px solid var(--border);display:flex;justify-content:space-between;align-items:center;padding:0 28px;font-size:18px}main section{padding:26px;max-width:1500px}.cards{display:grid;grid-template-columns:repeat(5,1fr);gap:14px}.card{background:white;border:1px solid var(--border);border-radius:14px;box-shadow:0 1px 2px #00000008}.metric{padding:18px}.metric span,.metric small,small,.muted{color:var(--muted);display:block}.metric strong{font-size:30px;display:block}.split{display:grid;grid-template-columns:1fr 2fr;gap:16px}.grid2{display:grid;grid-template-columns:1fr 1fr;gap:12px}.grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:14px}.form{padding:18px}.form input,.form select,.form textarea,label input,label select,label textarea{width:100%;padding:9px;border:1px solid #cbd6df;border-radius:7px;margin:5px 0 10px}.form textarea{min-height:80px}label{font-weight:600}.table{overflow:auto}table{width:100%;border-collapse:collapse}th,td{padding:11px 13px;border-bottom:1px solid var(--border);text-align:left;vertical-align:top}th{font-size:12px;color:var(--muted);text-transform:uppercase}.badge{padding:4px 8px;border-radius:999px;background:#edf2f6}.mini{display:grid;grid-template-columns:repeat(3,1fr);gap:5px;margin-top:8px}.mini input{min-width:0}.inline{display:flex;gap:5px}.lists{margin-top:16px}.login{min-height:100vh;display:grid;place-items:center}.login-card{width:min(430px,calc(100vw - 30px));background:#fff;border:1px solid var(--border);border-radius:18px;padding:28px}.full-logo{width:100%;max-width:320px;display:block;margin:auto}.alert{background:#fde9e7;color:#a3241b;padding:10px;border-radius:8px}.login-card input{width:100%;padding:10px;border:1px solid var(--border);border-radius:8px;margin:5px 0 13px}.login-card button{width:100%}
@media(max-width:1000px){.layout{grid-template-columns:1fr}aside{display:none}.cards,.grid3,.split{grid-template-columns:1fr 1fr}}

.geocode-success,.geocode-manual{background:#e4f5ea;color:#176b3a}
.geocode-review,.geocode-pending{background:#fff4d6;color:#7a5a00}
.geocode-failed{background:#fde9e7;color:#a3241b}
.error-text{color:#a3241b;max-width:360px}
.coordinate-form{grid-template-columns:repeat(2,minmax(120px,1fr));min-width:360px}

.danger{background:#fff;color:#a3241b;border-color:#d8a19b}.danger:hover{background:#fde9e7}

.portal-version{margin-top:auto;padding:18px 4px 8px;color:#8fa5b8;font-size:12px;text-align:center}
.login-version{margin-top:18px;text-align:center;color:var(--muted);font-size:12px}

.address-mode{display:flex;gap:10px;flex-wrap:wrap;margin:10px 0 14px}
.mode-option{display:flex;align-items:center;gap:8px;border:1px solid var(--border);border-radius:9px;padding:10px 12px;font-weight:600}
.mode-option input{width:auto;margin:0}
.new-address-fields{border:1px solid var(--border);border-radius:10px;padding:14px;margin:8px 0 14px;background:#f9fbfc}
.new-location-title{font-weight:700;margin-bottom:10px}
.address-grid{display:grid;grid-template-columns:2fr .7fr .7fr 1fr 1.5fr .55fr;gap:10px}
@media(max-width:1100px){.address-grid{grid-template-columns:1fr 1fr}}
@media(max-width:650px){.address-grid,.grid2{grid-template-columns:1fr}}

.page-actions{display:flex;justify-content:flex-end;gap:10px;margin-bottom:12px}
.button-link{display:inline-block;text-decoration:none;border:1px solid var(--border);background:#fff;color:var(--text);border-radius:8px;padding:10px 14px;font-weight:700}
.import-card{margin-bottom:18px}.import-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:10px}
.alert{padding:12px 14px;border-radius:9px;margin:10px 0 14px;border:1px solid var(--border)}
.alert.success{background:#eef9f1;border-color:#a8d5b2}.alert.error{background:#fff0ef;border-color:#dfaaa5}.alert.warn{background:#fff8e5;border-color:#e2ca83}
.stats-row{display:grid;grid-template-columns:repeat(5,minmax(120px,1fr));gap:10px;margin:15px 0}
.stat{border:1px solid var(--border);border-radius:9px;padding:12px;background:#fff}.stat b{font-size:22px;display:block}.stat span{font-size:12px;color:var(--muted)}
.import-preview small{display:block}.duplicate-row{opacity:.62}
@media(max-width:900px){.stats-row{grid-template-columns:1fr 1fr}.page-actions{justify-content:flex-start}}

.import-order{margin:14px 0;overflow:hidden}
.import-order-head{display:flex;justify-content:space-between;gap:12px;align-items:center;padding:13px 15px;border-bottom:1px solid var(--border)}
.import-order-head small{margin-top:3px}
.movement-pickup{background:#ffd84d;color:#5f4600;border:1px solid #e0b800}
.movement-delivery{background:#cfe7ff;color:#0b4f8a;border:1px solid #8fc3f5}
.settings-section{margin-top:22px}
.settings-add-grid{display:grid;grid-template-columns:.7fr 1.5fr 1fr .7fr auto;gap:10px;align-items:end}
.route-area-add-grid{display:grid;grid-template-columns:.7fr 1.2fr .9fr 1.2fr .7fr auto;gap:10px;align-items:end}
.settings-table{margin-top:12px}
.settings-table input,.settings-table select{width:100%;min-width:90px;padding:7px;border:1px solid #cbd6df;border-radius:7px}
.inline-actions{display:flex;gap:6px;align-items:center}
.inline-actions form{margin:0}
@media(max-width:1100px){
  .settings-add-grid,.route-area-add-grid{grid-template-columns:1fr 1fr}
}


/* v1.0.12 - split ritplanning */
.planning-new-trip{margin-bottom:14px}
.planning-new-trip summary{cursor:pointer;padding:4px 0}
.planning-new-trip-form{display:grid;grid-template-columns:repeat(4,minmax(150px,1fr));gap:10px;align-items:end;margin-top:14px}
.planning-new-trip-form .planning-notes{grid-column:span 3}
.planning-upper{margin-bottom:16px}
.planning-card-head,.planning-selected-head{display:flex;justify-content:space-between;gap:16px;align-items:flex-start;padding:4px 0 12px}
.planning-card-head h2,.planning-selected-head h2{margin-bottom:4px}
.planning-table-scroll,.planning-stop-scroll{overflow:auto;max-width:100%}
.trip-list-table tbody tr.trip-select-row{cursor:pointer}
.trip-list-table tbody tr.trip-select-row:hover{background:rgba(0,80,150,.05)}
.trip-list-table tbody tr.selected-trip-row{background:rgba(0,80,150,.10)}
.planning-add-order{padding:12px 0;border-top:1px solid var(--border);border-bottom:1px solid var(--border);margin-bottom:12px}
.planning-add-order form{display:flex;gap:10px;align-items:end}
.planning-add-order label{flex:1}
.planning-add-order select{width:100%}
.planning-linked-orders{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:8px 0 14px}
.planning-order-chip{display:inline-flex;align-items:center;gap:5px;padding:5px 8px;border:1px solid var(--border);border-radius:999px;background:#fff}
.planning-order-chip form{display:inline;margin:0}
.planning-order-chip button{border:0;background:transparent;padding:0 3px;font-size:18px;line-height:1;cursor:pointer}
.trip-stop-table{min-width:1050px}
.drag-col{width:34px}
.drag-handle{cursor:grab;font-size:20px;user-select:none;text-align:center}
.draggable-stop.dragging{opacity:.45}
.draggable-stop.drag-over{outline:2px dashed #73869a;outline-offset:-2px}
.nowrap{white-space:nowrap}
.button-link.small,.small{font-size:12px;padding:5px 8px}
.trip-stop-table small{display:block;margin-top:2px}
@media(max-width:1000px){
  .planning-new-trip-form{grid-template-columns:1fr 1fr}
  .planning-new-trip-form .planning-notes{grid-column:span 2}
  .planning-add-order form{flex-direction:column;align-items:stretch}
}


/* v1.0.13 - operationele adressen wijzigen */
.operational-address-row{cursor:default}
.operational-address-row:hover{background:rgba(0,80,150,.045)}
.operational-address-row td:first-child{border-left:3px solid rgba(0,80,150,.25)}
.address-edit-head{display:flex;align-items:flex-start;justify-content:space-between;gap:18px;margin-bottom:12px}
.address-edit-head h2{margin-bottom:4px}
.address-edit-form{max-width:1150px}
.address-line-grid{display:grid;grid-template-columns:minmax(280px,2fr) minmax(100px,.55fr) minmax(100px,.55fr);gap:12px}
.address-edit-actions{display:flex;gap:10px;align-items:center;margin-top:10px}
.address-geocode-summary{display:grid;grid-template-columns:1fr 1fr;gap:18px}
@media(max-width:850px){
  .address-line-grid,.address-geocode-summary{grid-template-columns:1fr}
}


/* v1.0.14 - dashboard serverstatus */
.dashboard-section-head{display:flex;justify-content:space-between;align-items:flex-end;gap:18px;margin-top:24px;margin-bottom:10px}
.dashboard-section-head h2{margin:0 0 3px}.dashboard-section-head p{margin:0}
.server-status-refresh{display:flex;gap:10px;align-items:center;color:var(--muted);font-size:12px}
.server-status-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-bottom:24px}
.server-status-card{padding:18px;min-width:0}
.server-card-title{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;margin-bottom:14px}
.server-card-title>div{display:flex;align-items:center;gap:11px;min-width:0}
.server-card-title h3{margin:0 0 2px;font-size:17px}
.server-icon{display:grid;place-items:center;width:38px;height:38px;border-radius:10px;background:#eef4f9;color:#365b78;font-size:18px;flex:0 0 auto}
.server-state{display:inline-flex;align-items:center;justify-content:center;padding:5px 10px;border-radius:999px;font-size:12px;font-weight:700;white-space:nowrap}
.server-state.online{background:#e4f5ea;color:#176b3a}
.server-state.warning{background:#fff4d6;color:#7a5a00}
.server-state.offline,.server-state.error{background:#fde9e7;color:#a3241b}
.server-version-line{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 0 13px;border-top:1px solid var(--border);border-bottom:1px solid var(--border)}
.server-version-line span{color:var(--muted)}
.service-status-list{display:grid;margin-top:5px}
.service-status-row{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:10px 0;border-bottom:1px solid var(--border)}
.service-status-row:last-child{border-bottom:0}
.service-status-row>div:first-child{display:grid;grid-template-columns:14px auto;column-gap:7px;align-items:center}
.service-status-row small{grid-column:2}
.status-dot{width:10px;height:10px;border-radius:50%;display:inline-block;background:#9ba7b2}
.status-dot.online{background:#2e9f57}.status-dot.warning{background:#d89b16}
.status-dot.offline,.status-dot.error{background:#cf4b3f}
.service-status-meta{display:flex;gap:12px;align-items:center;color:var(--muted);font-size:12px}
.service-version{font-weight:700;color:var(--text)}
.database-status-details{display:grid;grid-template-columns:1fr 1fr;gap:14px;padding-top:4px}
.database-status-details>div{padding:11px 12px;border:1px solid var(--border);border-radius:9px;background:#f9fbfc;min-width:0}
.database-status-details span{display:block;color:var(--muted);font-size:12px;margin-bottom:3px}
.database-status-details b{display:block;overflow-wrap:anywhere}
.server-error{margin-top:12px;padding:9px 11px;border-radius:8px;background:#fde9e7;color:#a3241b;font-size:12px}
.hidden{display:none!important}
@media(max-width:900px){
  .server-status-grid{grid-template-columns:1fr}
  .dashboard-section-head{align-items:flex-start;flex-direction:column}
}
@media(max-width:550px){
  .database-status-details{grid-template-columns:1fr}
  .server-status-refresh{align-items:flex-start;flex-direction:column}
}


/* v1.0.17 - vaste stopkleurcodering door de hele portal */
tr.movement-row-pickup > td{
  background:#fff8cf;
}
tr.movement-row-delivery > td{
  background:#edf6ff;
}
tr.movement-row-pickup:hover > td{
  background:#fff2a8;
}
tr.movement-row-delivery:hover > td{
  background:#dceeff;
}
tr.movement-row-pickup > td:first-child{
  border-left:4px solid #e0b800;
}
tr.movement-row-delivery > td:first-child{
  border-left:4px solid #4b9bd8;
}
.orders-customer-filter{
  display:grid;
  grid-template-columns:minmax(260px,1fr) minmax(320px,.65fr);
  gap:24px;
  align-items:end;
  margin-bottom:10px;
}
.orders-customer-filter h2{margin:0 0 4px}
.orders-customer-filter p{margin:0}
.orders-customer-filter form{margin:0}
.orders-customer-filter select{width:100%}
.orders-legend{
  display:flex;
  gap:18px;
  align-items:center;
  margin:8px 2px 12px;
  font-size:13px;
  color:var(--muted);
}
.orders-legend span{display:inline-flex;align-items:center;gap:7px}
.legend-swatch{
  width:18px;
  height:12px;
  border-radius:3px;
  border:1px solid var(--border);
}
.legend-swatch.pickup{background:#fff2a8;border-color:#e0b800}
.legend-swatch.delivery{background:#dceeff;border-color:#4b9bd8}
.table-section-head{
  display:flex;
  justify-content:space-between;
  gap:16px;
  align-items:flex-start;
  padding:0 0 12px;
}
.table-section-head h2{margin:0 0 4px}
.table-section-head p{margin:0}
.orders-stop-overview{margin-bottom:16px}
.orders-table-scroll{overflow:auto;max-width:100%}
.orders-stop-table{min-width:1150px}
.orders-bottom-grid{align-items:start}
.orders-new-order summary{cursor:pointer}
.orders-new-order form{margin-top:14px}
.orderbook-filters{display:flex;align-items:end;gap:12px;flex-wrap:wrap}.orderbook-filters label{min-width:170px;flex:1}.orderbook-filters button{margin-bottom:1px}.orderbook-group td{background:#e9f2fc;color:#173e69;padding:11px 15px}.orderbook-group td span{float:right;color:#55728f;font-size:.86rem}.orderbook-goods-detail>td{background:#f8fbff;padding:12px 18px}.orderbook-goods-detail table{margin-top:8px}.orderbook-goods-detail table td,.orderbook-goods-detail table th{padding:7px 10px}.orderbook-manual-goods{margin:15px 0;padding:16px;background:#f8fbff}.orderbook-manual-goods-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.orderbook-manual-goods-head h3{margin:0}.orderbook-manual-good{display:grid;grid-template-columns:2fr 1.2fr 75px 120px 90px 60px auto;align-items:end;gap:8px;padding:12px 0;border-bottom:1px solid #dce7f1}.orderbook-manual-good label{min-width:0}.orderbook-adr-toggle{display:flex;gap:5px;align-items:center}.orderbook-adr-toggle input{width:auto}.orderbook-manual-adr{grid-column:1/-1;display:flex;gap:12px;background:#eaf4ff;border-radius:8px;padding:9px}.orderbook-manual-adr[hidden]{display:none}@media(max-width:1050px){.orderbook-manual-good{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:900px){
  .orders-customer-filter{grid-template-columns:1fr}
}


/* v1.0.18 - grafische ritplanning */
.primary-link{background:#244d6d;color:#fff!important;border-color:#244d6d!important}
.planning-head-actions{display:flex;flex-wrap:wrap;gap:8px;justify-content:flex-end;align-items:center}
.graph-plan-toolbar{display:flex;justify-content:space-between;align-items:end;gap:14px;margin-bottom:10px}
.graph-plan-trip-select{min-width:320px;flex:1}
.graph-plan-trip-select select{width:100%}
.graph-plan-toolbar-actions{display:flex;gap:8px;align-items:center}
.graph-plan-status{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:12px}
.graph-trip-meta{display:flex;gap:12px;align-items:center;flex-wrap:wrap}
.graph-plan-grid{display:grid;grid-template-columns:minmax(250px,.8fr) minmax(420px,1.7fr) minmax(280px,.9fr);gap:12px;align-items:stretch}
.graph-plan-panel{min-width:0;padding:12px}
.graph-panel-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;margin-bottom:10px}
.graph-panel-head h2,.graph-map-head h2{margin:0 0 3px}
.graph-panel-head p{margin:0}
.graph-search{width:100%;margin-bottom:10px}
.graph-card-list{display:flex;flex-direction:column;gap:8px;max-height:680px;overflow:auto;padding-right:3px;min-height:120px}
.graph-shipment-card,.graph-route-card{border:1px solid var(--border);border-left-width:5px;border-radius:9px;padding:9px;background:#fff;display:flex;flex-direction:column;gap:3px}
.graph-shipment-card.pickup,.graph-route-card.pickup{border-left-color:#e0b800;background:#fffbea}
.graph-shipment-card.delivery,.graph-route-card.delivery{border-left-color:#4b9bd8;background:#f4f9ff}
.graph-card-topline{display:flex;justify-content:space-between;gap:8px;align-items:center}
.graph-shipment-card button,.graph-route-card button{margin-top:5px}
.graph-geocode-warning{color:#9a5d00;font-weight:700}
.graph-plan-map-card{min-width:0;padding:12px;display:flex;flex-direction:column}
.graph-map-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;margin-bottom:8px}
.graph-map-actions{display:flex;gap:7px}
.graph-route-metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin-bottom:8px}
.graph-route-metrics>div{border:1px solid var(--border);border-radius:8px;padding:7px 9px;background:#fafcfd}
.graph-route-metrics span{display:block;color:var(--muted);font-size:11px}
.graph-route-metrics b{display:block;font-size:17px;margin-top:2px}
#planning-map{height:610px;min-height:420px;border-radius:9px;border:1px solid var(--border);overflow:hidden}
.graph-route-card{display:grid;grid-template-columns:32px 1fr;gap:8px;cursor:grab}
.graph-route-card.dragging{opacity:.5}
.graph-route-sequence{width:30px;height:30px;border-radius:50%;display:grid;place-items:center;background:#263a4c;color:#fff;font-weight:800}
.graph-route-content{display:flex;flex-direction:column;gap:3px;min-width:0}
.route-list{outline:2px dashed transparent;outline-offset:4px}
.route-list:empty{outline-color:#b6c1ca}
.route-marker{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-weight:800;border:3px solid #fff;box-shadow:0 2px 8px rgba(0,0,0,.35)}
.route-marker.pickup{background:#ffd84d;color:#3f3200}
.route-marker.delivery{background:#58a9e6;color:#fff}
.route-popup{line-height:1.4}
.graph-save-status{padding-top:8px;min-height:20px}
.graph-empty{padding:20px;text-align:center;border:1px dashed var(--border);border-radius:8px}
@media(max-width:1250px){
  .graph-plan-grid{grid-template-columns:minmax(230px,.8fr) minmax(420px,1.5fr)}
  .graph-plan-route{grid-column:1/-1}
  .graph-plan-route .graph-card-list{max-height:360px}
}
@media(max-width:850px){
  .graph-plan-grid{grid-template-columns:1fr}
  .graph-plan-route{grid-column:auto}
  .graph-plan-toolbar,.graph-plan-status{align-items:stretch;flex-direction:column}
  .graph-plan-trip-select{min-width:0}
  #planning-map{height:480px}
}


/* v1.0.20 - compacte multi-route grafische planning */
.gp-toolbar{display:flex;gap:14px;align-items:end;justify-content:space-between;margin-bottom:8px}
.gp-date-form{margin:0}.gp-date-form label{margin:0}.gp-date-form input{min-width:160px}
.gp-toolbar-info{display:flex;gap:12px;align-items:center;flex-wrap:wrap}
.gp-toolbar-actions{display:flex;gap:7px;align-items:center;flex-wrap:wrap}
.gp-legend{margin:4px 2px 10px}
.gp-layout{display:grid;grid-template-columns:260px minmax(470px,1fr) 360px;gap:10px;align-items:start}
.gp-free-panel,.gp-map-panel,.gp-route-panel{min-width:0}
.gp-free-panel,.gp-map-panel{padding:10px}
.gp-panel-head,.gp-map-head{display:flex;justify-content:space-between;gap:8px;align-items:flex-start;margin-bottom:8px}
.gp-panel-head h2,.gp-map-head h2{margin:0 0 2px;font-size:16px}
.gp-panel-head p{margin:0;font-size:11px}
.gp-search{width:100%;padding:7px 9px;margin-bottom:7px;font-size:13px}
.gp-free-list{display:flex;flex-direction:column;gap:4px;max-height:690px;overflow:auto;padding-right:2px}
.gp-free-row{
  display:grid;grid-template-columns:4px minmax(0,1fr) 30px;gap:6px;align-items:stretch;
  padding:5px 5px 5px 0;border:1px solid #d8e0e7;border-radius:7px;background:#fff;
  color:#17212b;line-height:1.18;min-height:0
}
.gp-free-row.pickup{background:#fffbea}.gp-free-row.delivery{background:#f3f8ff}
.gp-free-row .gp-move-strip{border-radius:6px 0 0 6px}
.gp-free-row.pickup .gp-move-strip{background:#e0b800}.gp-free-row.delivery .gp-move-strip{background:#4b9bd8}
.gp-free-main{display:flex;flex-direction:column;gap:1px;min-width:0;font-size:11px}
.gp-free-main strong{font-size:12px;color:#17212b;white-space:normal;overflow-wrap:anywhere}
.gp-free-main span,.gp-free-main small{color:#425466;white-space:normal;overflow-wrap:anywhere}
.gp-row-title{display:flex;justify-content:space-between;gap:5px;align-items:center;min-width:0}
.gp-row-title b{font-size:11px;color:#17212b;overflow-wrap:anywhere}
.gp-type-text{font-size:9px;font-weight:800;letter-spacing:.03em;color:#263746!important}
.gp-warning-text{color:#925a00!important;font-weight:700}
.gp-quick-add,.gp-remove-stop{padding:0;width:28px;min-width:28px;height:28px;align-self:center;font-size:17px;line-height:1}
.gp-map-panel{position:sticky;top:8px}
.gp-map-actions{display:flex;gap:6px;flex-wrap:wrap}
#planning-map{height:690px;min-height:520px;border-radius:8px;border:1px solid #d8e0e7;overflow:hidden}
.gp-route-legend{display:flex;gap:5px;flex-wrap:wrap;margin:0 0 7px}
.gp-route-chip{display:inline-flex;align-items:center;gap:5px;padding:4px 7px;font-size:10px;border-radius:999px}
.gp-route-chip span{width:14px;height:4px;border-radius:4px}
.gp-route-chip.active{font-weight:800;border-width:2px}
.gp-routes-panel{display:flex;flex-direction:column;gap:7px;max-height:790px;overflow:auto;padding-right:2px}
#route-panels{display:flex;flex-direction:column;gap:7px}
.gp-route-panel{padding:8px;border-left:5px solid var(--route-color,#64748b)}
.gp-route-panel.active{outline:2px solid var(--route-color,#64748b);outline-offset:-2px}
.gp-route-head{display:grid;grid-template-columns:8px minmax(0,1fr) auto;gap:7px;align-items:center;cursor:pointer}
.gp-route-color{width:8px;height:34px;border-radius:5px}
.gp-route-title{display:flex;flex-direction:column;gap:1px;min-width:0}
.gp-route-title b{font-size:13px;color:#17212b}.gp-route-title small{font-size:10px;color:#536273;white-space:normal}
.gp-route-head-metrics{text-align:center}.gp-route-head-metrics b{display:block;font-size:14px}.gp-route-head-metrics small{font-size:9px}
.gp-route-controls{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:5px;margin:6px 0}
.gp-route-controls select,.gp-route-controls button{padding:5px 6px;font-size:10px;min-height:30px}
.gp-route-metric-line{display:flex;gap:10px;justify-content:space-between;padding:4px 1px 5px;border-bottom:1px solid #e5e9ed;font-size:10px;color:#536273}
.gp-route-metric-line b{color:#17212b}
.gp-stop-list{display:flex;flex-direction:column;gap:3px;padding-top:5px;min-height:34px}
.gp-stop-list.drag-target{outline:2px dashed var(--route-color,#64748b);outline-offset:2px;border-radius:6px}
.gp-stop-row{
  display:grid;grid-template-columns:25px minmax(0,1fr) 25px;gap:5px;align-items:center;
  padding:4px;border:1px solid #d8e0e7;border-radius:6px;color:#17212b;cursor:grab;line-height:1.15
}
.gp-stop-row.pickup{background:#fff8cf;border-left:4px solid #e0b800}
.gp-stop-row.delivery{background:#edf6ff;border-left:4px solid #4b9bd8}
.gp-stop-row.dragging{opacity:.45}
.gp-stop-seq{width:23px;height:23px;border-radius:50%;display:grid;place-items:center;background:#273849;color:#fff;font-weight:800;font-size:10px}
.gp-stop-main{display:flex;flex-direction:column;gap:1px;min-width:0;font-size:10px}
.gp-stop-main strong,.gp-stop-main b{color:#17212b;white-space:normal;overflow-wrap:anywhere}
.gp-stop-main span,.gp-stop-main small{color:#425466;white-space:normal;overflow-wrap:anywhere}
.gp-route-status{font-size:10px;padding-top:4px;min-height:14px;white-space:normal}
.gp-empty{padding:12px;text-align:center;border:1px dashed #cbd5df;border-radius:6px;font-size:11px}
.gp-map-marker{
  width:30px;height:30px;border-radius:50%;display:grid;place-items:center;
  font-weight:800;border:4px solid #333;box-shadow:0 2px 8px rgba(0,0,0,.35)
}
.gp-map-marker.pickup{background:#ffd84d;color:#3f3200}
.gp-map-marker.delivery{background:#58a9e6;color:#fff}
.gp-map-marker span{font-size:10px}
@media(max-width:1350px){
  .gp-layout{grid-template-columns:235px minmax(430px,1fr) 330px}
}
@media(max-width:1100px){
  .gp-layout{grid-template-columns:230px minmax(430px,1fr)}
  .gp-routes-panel{grid-column:1/-1;max-height:none}
  #route-panels{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  .gp-map-panel{position:static}
}
@media(max-width:780px){
  .gp-toolbar{align-items:stretch;flex-direction:column}
  .gp-layout{grid-template-columns:1fr}
  .gp-routes-panel{grid-column:auto}
  #route-panels{grid-template-columns:1fr}
  #planning-map{height:480px}
}


/* v1.0.21 - depots + opdracht bewerken */
.depots-layout{display:grid;grid-template-columns:minmax(330px,.72fr) minmax(600px,1.6fr);gap:14px;align-items:start}
.depot-new-form{position:sticky;top:8px}
.depot-flags{display:flex;gap:18px;flex-wrap:wrap;padding:8px 0}
.depot-flags label{display:flex;gap:7px;align-items:center}
.depot-start-badge{background:#e6edf4;color:#24394b;border:1px solid #9cabb8}
.depot-end-badge{background:#293a4b;color:#fff;border:1px solid #293a4b}
.row-inactive{opacity:.55}
.vehicle-depot-form{display:grid;grid-template-columns:1fr 1fr auto;gap:5px;margin-top:7px;align-items:end}
.vehicle-depot-form label{font-size:10px}.vehicle-depot-form select{font-size:11px;padding:5px}
.fleet-depot-warning{color:#9b5b00!important;font-weight:700}
.order-detail-head{display:flex;justify-content:space-between;gap:12px;align-items:center}.order-detail-head h2{margin:0}
.order-edit-toolbar{display:flex;justify-content:flex-end;margin-bottom:8px}
.order-edit-main{margin-bottom:16px}
.order-edit-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.order-edit-shipments{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
.order-shipment-edit{border-left:5px solid #8b99a5}
.order-shipment-edit.shipment-edit-pickup{border-left-color:#e0b800;background:#fffdf3}
.order-shipment-edit.shipment-edit-delivery{border-left-color:#4b9bd8;background:#f8fbff}
.order-shipment-edit-head{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}
.order-shipment-edit-head>div{display:flex;flex-direction:column}
.current-stop-address{font-size:11px;color:#536273;padding:6px 8px;background:#f6f8fa;border-radius:6px}
.fixed-depot-row>td{background:#eef2f5!important;color:#1c2c39;font-weight:600}
.fixed-depot-row>td:first-child{border-left:4px solid #344b5e}
.gp-depot-row{display:grid;grid-template-columns:28px minmax(0,1fr);gap:6px;align-items:center;padding:5px;border:1px solid #aebbc5;border-left:5px solid var(--route-color,#344b5e);border-radius:6px;background:#eef2f5;color:#17212b}
.gp-depot-lock{width:25px;height:25px;border-radius:6px;display:grid;place-items:center;background:#263a4c;color:#fff;font-size:11px}
.gp-fixed-depots-label{display:flex;align-items:center;font-size:10px;font-weight:700;color:#344b5e}
.gp-route-controls-fixed{grid-template-columns:minmax(0,1fr) auto}
.gp-map-depot-marker{width:34px;height:34px;border-radius:8px;display:grid;place-items:center;background:#17212b;color:#fff;font-weight:900;border:4px solid #333;box-shadow:0 2px 8px rgba(0,0,0,.35)}
@media(max-width:1100px){.depots-layout{grid-template-columns:1fr}.depot-new-form{position:static}.order-edit-shipments{grid-template-columns:1fr}}
@media(max-width:750px){.order-edit-grid{grid-template-columns:1fr}.vehicle-depot-form{grid-template-columns:1fr}}


/* ============================================================
   v1.0.23 - Grafische planning: leesbaarder en minder krap
   ============================================================ */

.gp-toolbar{
  gap:18px;
  padding:12px 14px;
  margin-bottom:10px;
}

.gp-toolbar-info{
  gap:18px;
  font-size:13px;
}

.gp-toolbar-actions{
  gap:9px;
}

.gp-toolbar-actions button,
.gp-toolbar-actions .button-link{
  min-height:36px;
  padding:7px 11px;
  font-size:12px;
}

.gp-legend{
  margin:7px 4px 12px;
  font-size:12px;
}

/* Meer ruimte voor de werkpanelen; kaart blijft dominant */
.gp-layout{
  grid-template-columns:
    minmax(320px, 350px)
    minmax(650px, 1fr)
    minmax(390px, 430px);
  gap:12px;
  align-items:start;
}

/* Linker kolom */
.gp-free-panel{
  padding:12px;
}

.gp-panel-head h2,
.gp-map-head h2{
  font-size:18px;
}

.gp-panel-head p{
  font-size:12px;
  line-height:1.35;
}

.gp-search{
  padding:9px 10px;
  font-size:14px;
  margin-bottom:9px;
}

.gp-free-list{
  gap:7px;
  max-height:720px;
  padding-right:4px;
}

.gp-free-row{
  grid-template-columns:5px minmax(0,1fr) 34px;
  gap:8px;
  padding:8px 7px 8px 0;
  border-radius:8px;
  line-height:1.28;
  min-height:72px;
}

.gp-free-main{
  gap:3px;
  font-size:12px;
}

.gp-free-main strong{
  font-size:13px;
  line-height:1.3;
}

.gp-free-main span,
.gp-free-main small{
  font-size:11px;
  line-height:1.28;
}

.gp-row-title b{
  font-size:12px;
}

.gp-type-text{
  font-size:10px;
}

.gp-quick-add,
.gp-remove-stop{
  width:32px;
  min-width:32px;
  height:32px;
  font-size:18px;
}

/* Kaart */
.gp-map-panel{
  padding:12px;
}

.gp-map-head{
  margin-bottom:10px;
}

.gp-map-actions{
  gap:8px;
}

.gp-map-actions button{
  min-height:34px;
  padding:6px 10px;
  font-size:11px;
}

.gp-route-legend{
  gap:7px;
  margin-bottom:9px;
}

.gp-route-chip{
  padding:5px 9px;
  font-size:11px;
}

#planning-map{
  height:720px;
  min-height:580px;
}

/* Rechter kolom */
.gp-routes-panel{
  max-height:790px;
  gap:10px;
  padding-right:4px;
}

#route-panels{
  gap:10px;
}

.gp-route-panel{
  padding:10px;
  border-left-width:6px;
}

.gp-route-head{
  grid-template-columns:10px minmax(0,1fr) auto;
  gap:9px;
}

.gp-route-color{
  width:10px;
  height:40px;
}

.gp-route-title{
  gap:3px;
}

.gp-route-title b{
  font-size:15px;
}

.gp-route-title small{
  font-size:11px;
  line-height:1.3;
}

.gp-route-head-metrics b{
  font-size:16px;
}

.gp-route-head-metrics small{
  font-size:10px;
}

.gp-route-controls{
  gap:7px;
  margin:8px 0;
}

.gp-route-controls select,
.gp-route-controls button{
  padding:7px 8px;
  font-size:11px;
  min-height:34px;
}

.gp-fixed-depots-label{
  font-size:11px;
}

.gp-route-metric-line{
  gap:14px;
  padding:6px 2px 7px;
  font-size:11px;
}

.gp-stop-list{
  gap:6px;
  padding-top:7px;
  min-height:40px;
}

.gp-stop-row{
  grid-template-columns:30px minmax(0,1fr) 30px;
  gap:7px;
  padding:7px;
  border-radius:7px;
  line-height:1.25;
  min-height:66px;
}

.gp-stop-seq{
  width:28px;
  height:28px;
  font-size:11px;
}

.gp-stop-main{
  gap:2px;
  font-size:11px;
}

.gp-stop-main b,
.gp-stop-main strong{
  font-size:12px;
  line-height:1.3;
}

.gp-stop-main span,
.gp-stop-main small{
  font-size:10.5px;
  line-height:1.28;
}

.gp-route-status{
  font-size:11px;
  padding-top:6px;
  min-height:18px;
}

/* Depotregels in ritten iets duidelijker */
.gp-depot-row{
  grid-template-columns:32px minmax(0,1fr);
  gap:8px;
  padding:7px;
  min-height:58px;
}

.gp-depot-lock{
  width:29px;
  height:29px;
  font-size:12px;
}

/* Scrollbars per werkpaneel */
.gp-free-list,
.gp-routes-panel{
  scrollbar-width:thin;
}

/* Bij iets smallere desktop: eerst kaart iets compacter, niet de tekst */
@media(max-width:1550px){
  .gp-layout{
    grid-template-columns:
      minmax(290px,320px)
      minmax(560px,1fr)
      minmax(350px,390px);
  }

  .gp-free-row{
    min-height:66px;
  }

  .gp-stop-row{
    min-height:60px;
  }
}

@media(max-width:1250px){
  .gp-layout{
    grid-template-columns:minmax(290px,330px) minmax(540px,1fr);
  }

  .gp-routes-panel{
    grid-column:1/-1;
    max-height:none;
  }

  #route-panels{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  .gp-map-panel{
    position:static;
  }
}

@media(max-width:850px){
  .gp-layout{
    grid-template-columns:1fr;
  }

  .gp-routes-panel{
    grid-column:auto;
  }

  #route-panels{
    grid-template-columns:1fr;
  }

  #planning-map{
    height:520px;
    min-height:420px;
  }
}


/* ============================================================
   v1.0.24 - planscherm zonder kaart + bulkselectie per depot
   ============================================================ */

/* Kaart is vanaf nu uitsluitend het tweede monitorscherm. */
.gp-workboard{
  display:grid;
  grid-template-columns:minmax(380px,430px) minmax(720px,1fr);
  gap:14px;
  align-items:start;
}

.gp-free-panel{
  position:sticky;
  top:8px;
  padding:13px;
  min-width:0;
}

.gp-free-filterbar{
  display:grid;
  grid-template-columns:minmax(0,1fr) 150px;
  gap:7px;
  margin-bottom:8px;
}

.gp-free-filterbar .gp-search{
  margin:0;
}

.gp-depot-filter{
  min-width:0;
  padding:9px 8px;
  font-size:13px;
}

.gp-bulkbar{
  display:flex;
  flex-wrap:wrap;
  gap:6px;
  align-items:center;
  padding:7px 0;
  border-top:1px solid #e1e6ea;
  border-bottom:1px solid #e1e6ea;
}

.gp-bulkbar button{
  padding:6px 8px;
  min-height:32px;
  font-size:11px;
}

.gp-select-visible-label{
  display:inline-flex;
  align-items:center;
  gap:6px;
  font-size:11px;
  font-weight:700;
  margin-right:auto;
}

.gp-selection-summary{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:center;
  min-height:34px;
  font-size:12px;
}

.gp-bulk-active-btn{
  width:100%;
  min-height:38px;
  margin-bottom:3px;
}

.gp-bulk-status{
  min-height:18px;
  font-size:11px;
  margin-bottom:5px;
}

.gp-free-list{
  max-height:690px;
  gap:7px;
}

.gp-free-row{
  grid-template-columns:5px 25px minmax(0,1fr) 34px;
  cursor:pointer;
  transition:border-color .12s ease, box-shadow .12s ease, background .12s ease;
}

.gp-free-check{
  display:grid;
  place-items:center;
  align-self:stretch;
  margin:0;
}

.gp-free-check input{
  width:17px;
  height:17px;
  margin:0;
}

.gp-free-row.selected{
  border-color:#61778a;
  box-shadow:inset 0 0 0 1px #61778a;
}

.gp-free-row.drag-batch{
  outline:2px dashed #39586e;
  outline-offset:-2px;
}

.gp-drag-badge{
  position:fixed;
  left:-10000px;
  top:-10000px;
  background:#203647;
  color:#fff;
  border:2px solid #fff;
  border-radius:8px;
  padding:8px 12px;
  font-size:13px;
  font-weight:800;
  box-shadow:0 4px 16px rgba(0,0,0,.28);
}

/* Rechter werkvlak gebruikt nu alle ruimte die de kaart eerder innam. */
.gp-routes-workspace{
  min-width:0;
}

.gp-routes-workspace-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;
  padding:11px 13px;
  margin-bottom:10px;
}

.gp-routes-workspace-head h2{
  margin:0 0 3px;
  font-size:18px;
}

.gp-routes-workspace-head p{
  margin:0;
  font-size:12px;
}

.gp-active-trip-indicator{
  white-space:nowrap;
  padding:7px 10px;
  border:1px solid #cfd8df;
  border-radius:8px;
  background:#f6f8fa;
  font-size:12px;
}

.gp-route-board{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px;
  align-items:start;
}

.gp-route-panel{
  min-width:0;
}

.gp-stop-list{
  max-height:560px;
  overflow:auto;
  padding-right:3px;
}

/* Niet meer nodig in hoofdplanscherm. */
.gp-map-panel{
  display:none!important;
}

/* Meer ruimte wanneer slechts één rit zichtbaar is. */
.gp-route-board > .gp-route-panel:only-child{
  max-width:none;
}

/* Routepanelen worden bij zeer brede schermen 3 kolommen. */
@media(min-width:1850px){
  .gp-workboard{
    grid-template-columns:440px minmax(0,1fr);
  }

  .gp-route-board{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }
}

@media(max-width:1350px){
  .gp-workboard{
    grid-template-columns:350px minmax(620px,1fr);
  }

  .gp-route-board{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

@media(max-width:1050px){
  .gp-workboard{
    grid-template-columns:1fr;
  }

  .gp-free-panel{
    position:static;
  }

  .gp-free-list{
    max-height:430px;
  }

  .gp-route-board{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

@media(max-width:760px){
  .gp-free-filterbar{
    grid-template-columns:1fr;
  }

  .gp-route-board{
    grid-template-columns:1fr;
  }

  .gp-routes-workspace-head{
    align-items:flex-start;
    flex-direction:column;
  }

  .gp-active-trip-indicator{
    white-space:normal;
  }
}

/* ============================================================
   v1.0.25 - Adrescontrole / geocoding
   ============================================================ */
.geocode-control-stats{
  display:grid;
  grid-template-columns:repeat(5,minmax(130px,1fr));
  gap:10px;
  margin-bottom:12px;
}
.geocode-stat{
  display:flex;
  justify-content:space-between;
  align-items:center;
  padding:13px 15px;
  color:var(--text);
}
.geocode-stat span{color:var(--muted);font-size:12px}
.geocode-stat b{font-size:22px}
.geocode-stat.active{outline:2px solid var(--blue);outline-offset:-2px}
.geocode-filters{
  display:grid;
  grid-template-columns:minmax(220px,1.6fr) repeat(3,minmax(150px,.8fr)) auto auto;
  gap:10px;
  align-items:end;
  margin-bottom:12px;
}
.geocode-filters label{margin:0}
.geocode-filter-check{
  display:flex;
  align-items:center;
  gap:7px;
  min-height:42px;
  white-space:nowrap;
}
.geocode-filter-check input{width:auto;margin:0}
.geocode-filter-actions{display:flex;gap:6px;align-items:center;padding-bottom:10px}
.geocode-list-card{overflow:hidden}
.geocode-list-head{
  display:flex;
  justify-content:space-between;
  gap:14px;
  align-items:center;
  padding:13px 15px;
  border-bottom:1px solid var(--border);
}
.geocode-list-head h2{margin:0 0 3px;font-size:17px}
.geocode-list-head p{margin:0}
.geocode-bulk-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.geocode-bulk-actions>label{display:flex;align-items:center;gap:6px;font-size:12px;white-space:nowrap}
.geocode-bulk-actions input{width:auto;margin:0}
.geocode-table-scroll{overflow:auto;max-height:690px}
.geocode-control-table{min-width:1180px}
.geocode-control-table th{position:sticky;top:0;background:#fff;z-index:2}
.geocode-check-col{width:38px;text-align:center}
.geocode-check-col input{width:17px;height:17px}
.geocode-issue-row.issue-failed td:first-child{border-left:4px solid #c94f45}
.geocode-issue-row.issue-review td:first-child{border-left:4px solid #d5a815}
.geocode-issue-row.issue-missing td:first-child{border-left:4px solid #7e8d9a}
.geocode-issue-row.issue-pending td:first-child{border-left:4px solid #5b8db8}
.geocode-issue-row.issue-unknown td:first-child{border-left:4px solid #8b65a9}
.geocode-issue-failed{background:#fde9e7;color:#a3241b}
.geocode-issue-review{background:#fff4d6;color:#7a5a00}
.geocode-issue-missing{background:#edf1f4;color:#445460}
.geocode-issue-pending{background:#eaf3fb;color:#2e628d}
.geocode-issue-unknown{background:#f2ebf7;color:#694683}
.geocode-found-address{max-width:340px;white-space:normal;margin-top:4px}
.geocode-row-actions{display:flex;gap:5px;align-items:center;flex-wrap:wrap;min-width:185px}
.geocode-inline-form{margin:0}
.geocode-approve-button{background:#eef9f1;color:#176b3a;border-color:#a8d5b2}
.geocode-empty-state{text-align:center;padding:34px!important}
.geocode-empty-state b,.geocode-empty-state small{display:block}
@media(max-width:1200px){
  .geocode-control-stats{grid-template-columns:repeat(3,1fr)}
  .geocode-filters{grid-template-columns:1fr 1fr 1fr}
  .geocode-filter-actions{padding-bottom:0}
}
@media(max-width:760px){
  .geocode-control-stats{grid-template-columns:1fr 1fr}
  .geocode-filters{grid-template-columns:1fr}
  .geocode-list-head{align-items:flex-start;flex-direction:column}
}


/* ============================================================
   v1.0.26 - vast 4x2 planscherm + horizontale navigatie
   ============================================================ */

/* Alleen het grafische planscherm gebruikt een horizontale bovenbalk. */
body.graphical-planning-page{
  height:100vh;
  overflow:hidden;
}

.graphical-planning-page .layout{
  display:grid;
  grid-template-columns:1fr;
  grid-template-rows:58px minmax(0,1fr);
  height:100vh;
  min-height:0;
}

.graphical-planning-page .layout > aside{
  grid-row:1;
  display:grid;
  grid-template-columns:auto minmax(0,1fr) auto auto;
  align-items:center;
  gap:18px;
  padding:6px 16px;
  min-height:58px;
  background:var(--nav);
}

.graphical-planning-page .layout > aside .brand{
  min-width:165px;
}

.graphical-planning-page .layout > aside .brand img{
  width:40px;
  height:40px;
  border-radius:8px;
}

.graphical-planning-page .layout > aside nav{
  display:flex;
  align-items:center;
  gap:4px;
  margin:0;
  min-width:0;
  overflow-x:auto;
  overflow-y:hidden;
  scrollbar-width:thin;
  white-space:nowrap;
}

.graphical-planning-page .layout > aside nav a{
  padding:8px 10px;
  border-radius:7px;
  font-size:12px;
  flex:0 0 auto;
}

.graphical-planning-page .layout > aside .portal-version{
  margin:0;
  padding:0;
  white-space:nowrap;
}

.graphical-planning-page .layout > aside form{
  margin:0;
}

.graphical-planning-page .layout > aside form button{
  padding:7px 10px;
  font-size:11px;
}

.graphical-planning-page .layout > main{
  grid-row:2;
  min-width:0;
  min-height:0;
  display:grid;
  grid-template-rows:48px minmax(0,1fr);
  overflow:hidden;
}

.graphical-planning-page main > header{
  height:48px;
  min-height:48px;
  padding:0 16px;
  font-size:16px;
}

.graphical-planning-page main > section{
  padding:10px 12px 12px;
  max-width:none;
  min-width:0;
  min-height:0;
  overflow:hidden;
  display:flex;
  flex-direction:column;
}

/* Bovenste bediening compact houden zodat de 4x2 planning maximaal hoog is. */
.graphical-planning-page .gp-toolbar{
  flex:0 0 auto;
  min-height:52px;
  margin:0 0 5px;
  padding:7px 10px;
  gap:10px;
}

.graphical-planning-page .gp-date-form label{
  font-size:11px;
}

.graphical-planning-page .gp-date-form input{
  margin:2px 0 0;
  padding:5px 7px;
  min-height:30px;
}

.graphical-planning-page .gp-toolbar-info{
  gap:10px;
  font-size:11px;
}

.graphical-planning-page .gp-toolbar-actions{
  gap:5px;
}

.graphical-planning-page .gp-toolbar-actions button,
.graphical-planning-page .gp-toolbar-actions .button-link{
  min-height:30px;
  padding:5px 8px;
  font-size:10.5px;
}

.graphical-planning-page .gp-legend{
  flex:0 0 auto;
  min-height:24px;
  margin:0 2px 5px;
  font-size:10.5px;
}

/* Linker open stops + rechter 4x2 raster vullen exact de resterende hoogte. */
.graphical-planning-page .gp-workboard{
  flex:1 1 auto;
  min-height:0;
  display:grid;
  grid-template-columns:minmax(330px,360px) minmax(0,1fr);
  gap:10px;
  overflow:hidden;
}

.graphical-planning-page .gp-free-panel{
  position:static;
  height:100%;
  min-height:0;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  padding:9px;
}

.graphical-planning-page .gp-panel-head{
  flex:0 0 auto;
  margin-bottom:5px;
}

.graphical-planning-page .gp-panel-head h2{
  font-size:15px;
}

.graphical-planning-page .gp-panel-head p{
  font-size:10px;
}

.graphical-planning-page .gp-free-filterbar,
.graphical-planning-page .gp-bulkbar,
.graphical-planning-page .gp-selection-summary,
.graphical-planning-page .gp-bulk-active-btn,
.graphical-planning-page .gp-bulk-status{
  flex:0 0 auto;
}

.graphical-planning-page .gp-free-filterbar{
  grid-template-columns:minmax(0,1fr) 135px;
  gap:5px;
  margin-bottom:5px;
}

.graphical-planning-page .gp-search,
.graphical-planning-page .gp-depot-filter{
  padding:6px 7px;
  min-height:30px;
  font-size:11px;
}

.graphical-planning-page .gp-bulkbar{
  padding:4px 0;
  gap:4px;
}

.graphical-planning-page .gp-bulkbar button{
  padding:4px 6px;
  min-height:27px;
  font-size:9.5px;
}

.graphical-planning-page .gp-select-visible-label{
  font-size:9.5px;
}

.graphical-planning-page .gp-selection-summary{
  min-height:25px;
  font-size:10px;
}

.graphical-planning-page .gp-bulk-active-btn{
  min-height:30px;
  padding:5px 7px;
  font-size:10px;
}

.graphical-planning-page .gp-bulk-status{
  min-height:12px;
  margin-bottom:2px;
  font-size:9px;
}

.graphical-planning-page .gp-free-list{
  flex:1 1 auto;
  min-height:0;
  max-height:none;
  overflow-y:auto;
  overflow-x:hidden;
  gap:4px;
  padding-right:3px;
}

.graphical-planning-page .gp-free-row{
  grid-template-columns:4px 22px minmax(0,1fr) 29px;
  min-height:57px;
  padding:5px 4px 5px 0;
  gap:5px;
}

.graphical-planning-page .gp-free-main{
  font-size:10px;
  gap:1px;
}

.graphical-planning-page .gp-free-main strong{
  font-size:11px;
}

.graphical-planning-page .gp-free-main span,
.graphical-planning-page .gp-free-main small{
  font-size:9.5px;
}

.graphical-planning-page .gp-row-title b{
  font-size:10px;
}

.graphical-planning-page .gp-type-text{
  font-size:8.5px;
}

.graphical-planning-page .gp-free-check input{
  width:15px;
  height:15px;
}

.graphical-planning-page .gp-quick-add{
  width:27px;
  min-width:27px;
  height:27px;
  font-size:15px;
}

/* Rechter paneel: 8 ritten exact 4 kolommen x 2 rijen. */
.graphical-planning-page .gp-routes-workspace{
  min-width:0;
  min-height:0;
  height:100%;
  display:grid;
  grid-template-rows:38px minmax(0,1fr);
  overflow:hidden;
}

.graphical-planning-page .gp-routes-workspace-head{
  min-height:38px;
  height:38px;
  margin:0 0 5px;
  padding:4px 8px;
}

.graphical-planning-page .gp-routes-workspace-head h2{
  margin:0;
  font-size:14px;
}

.graphical-planning-page .gp-routes-workspace-head p{
  font-size:9px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  max-width:760px;
}

.graphical-planning-page .gp-active-trip-indicator{
  padding:4px 7px;
  font-size:9.5px;
}

.graphical-planning-page .gp-route-board-4x2{
  min-width:0;
  min-height:0;
  height:100%;
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  grid-template-rows:repeat(2,minmax(0,1fr))!important;
  gap:7px;
  align-items:stretch;
  overflow:hidden;
}

.graphical-planning-page .gp-route-panel{
  min-width:0;
  min-height:0;
  height:100%;
  overflow:hidden;
  display:flex;
  flex-direction:column;
  padding:6px;
  border-radius:9px;
}

.graphical-planning-page .gp-route-head{
  flex:0 0 auto;
  grid-template-columns:7px minmax(0,1fr) auto;
  gap:5px;
  min-height:31px;
}

.graphical-planning-page .gp-route-color{
  width:7px;
  height:29px;
}

.graphical-planning-page .gp-route-title{
  gap:0;
}

.graphical-planning-page .gp-route-title b{
  font-size:11px;
}

.graphical-planning-page .gp-route-title small{
  font-size:8.5px;
  line-height:1.15;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.graphical-planning-page .gp-route-head-metrics b{
  font-size:12px;
}

.graphical-planning-page .gp-route-head-metrics small{
  font-size:7.5px;
}

.graphical-planning-page .gp-route-controls{
  flex:0 0 auto;
  margin:4px 0;
  gap:4px;
}

.graphical-planning-page .gp-fixed-depots-label{
  min-width:0;
  font-size:8.5px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

.graphical-planning-page .gp-route-controls button{
  padding:3px 5px;
  min-height:24px;
  font-size:8px;
  white-space:nowrap;
}

.graphical-planning-page .gp-route-metric-line{
  flex:0 0 auto;
  padding:3px 1px 4px;
  gap:6px;
  font-size:8.5px;
}

.graphical-planning-page .gp-stop-list{
  flex:1 1 auto;
  min-height:0;
  max-height:none;
  overflow-y:auto;
  overflow-x:hidden;
  padding:4px 2px 2px 0;
  gap:3px;
  scrollbar-width:thin;
}

.graphical-planning-page .gp-depot-row{
  flex:0 0 auto;
  grid-template-columns:23px minmax(0,1fr);
  min-height:39px;
  padding:4px;
  gap:4px;
}

.graphical-planning-page .gp-depot-lock{
  width:21px;
  height:21px;
  font-size:8px;
}

.graphical-planning-page .gp-stop-row{
  grid-template-columns:23px minmax(0,1fr) 23px;
  gap:4px;
  min-height:48px;
  padding:4px;
  line-height:1.14;
}

.graphical-planning-page .gp-stop-seq{
  width:21px;
  height:21px;
  font-size:8px;
}

.graphical-planning-page .gp-stop-main{
  gap:0;
  font-size:8.5px;
}

.graphical-planning-page .gp-stop-main b,
.graphical-planning-page .gp-stop-main strong{
  font-size:9px;
}

.graphical-planning-page .gp-stop-main span,
.graphical-planning-page .gp-stop-main small{
  font-size:8px;
  line-height:1.15;
}

.graphical-planning-page .gp-remove-stop{
  width:21px;
  min-width:21px;
  height:21px;
  padding:0;
  font-size:13px;
}

.graphical-planning-page .gp-route-status{
  flex:0 0 auto;
  min-height:10px;
  padding-top:2px;
  font-size:8px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}

/* Geen verticale pagina-scroll: uitsluitend open stops en ieder ritvlak scrollt. */
.graphical-planning-page .gp-free-list,
.graphical-planning-page .gp-stop-list{
  overscroll-behavior:contain;
}

/* We houden desktop bewust 4x2. Bij een lagere resolutie blijft het scherm
   bruikbaar door horizontale rasterruimte te behouden in plaats van alles
   onder elkaar te zetten. */
@media(max-width:1450px){
  .graphical-planning-page .gp-workboard{
    grid-template-columns:300px minmax(0,1fr);
  }

  .graphical-planning-page .gp-route-board-4x2{
    grid-template-columns:repeat(4,minmax(230px,1fr))!important;
    overflow-x:auto;
  }
}

@media(max-height:850px){
  .graphical-planning-page .layout{
    grid-template-rows:52px minmax(0,1fr);
  }

  .graphical-planning-page .layout > aside{
    min-height:52px;
    padding-top:4px;
    padding-bottom:4px;
  }

  .graphical-planning-page main > header{
    height:42px;
    min-height:42px;
  }

  .graphical-planning-page .layout > main{
    grid-template-rows:42px minmax(0,1fr);
  }

  .graphical-planning-page main > section{
    padding-top:7px;
  }

  .graphical-planning-page .gp-toolbar{
    min-height:45px;
  }

  .graphical-planning-page .gp-legend{
    min-height:20px;
  }

  .graphical-planning-page .gp-routes-workspace{
    grid-template-rows:33px minmax(0,1fr);
  }

  .graphical-planning-page .gp-routes-workspace-head{
    min-height:33px;
    height:33px;
  }
}


/* ============================================================
   v1.0.29 - 3x2 planning, stop edit, geocode warning, dialogs
   ============================================================ */

.gp-free-row.geocode-missing{
  background:#ffe8e8!important;
  border-color:#d92d20!important;
  box-shadow:inset 5px 0 0 #d92d20;
}
.gp-free-row.planning-exception{
  background:#ffe8e8!important;
  border-color:#d92d20!important;
  box-shadow:inset 5px 0 0 #d92d20;
}
.gp-free-row.planning-exception .gp-move-strip{background:#d92d20!important}
.gp-free-row.planning-exception .gp-warning-text{color:#a40000;font-weight:800}

.gp-free-row.geocode-missing .gp-move-strip{
  background:#d92d20!important;
}

.gp-free-row.geocode-missing .gp-warning-text{
  color:#a40000;
  font-weight:800;
}

.gp-free-actions,
.gp-stop-actions{
  display:flex;
  flex-direction:column;
  gap:3px;
  align-items:center;
  justify-content:center;
}

.gp-edit-stop{
  display:grid;
  place-items:center;
  width:27px;
  height:27px;
  border:1px solid #b9c4cd;
  border-radius:6px;
  background:#fff;
  color:#203647;
  text-decoration:none;
  font-size:14px;
  font-weight:800;
  box-sizing:border-box;
}

.gp-stop-actions .gp-edit-stop,
.gp-stop-actions .gp-remove-stop{
  width:23px;
  min-width:23px;
  height:23px;
}

.graphical-planning-page .gp-route-board-3x2{
  min-width:0;
  min-height:0;
  height:100%;
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  grid-template-rows:repeat(2,minmax(0,1fr))!important;
  gap:8px;
  align-items:stretch;
  overflow:hidden;
}

.graphical-planning-page .gp-stop-row{
  grid-template-columns:23px minmax(0,1fr) 26px;
}

.graphical-planning-page .gp-free-row{
  grid-template-columns:4px 22px minmax(0,1fr) 30px;
}

.gp-no-routes{
  grid-column:1/-1;
  align-self:start;
}

.gp-inline-alert{
  flex:0 0 auto;
  margin:0 0 5px;
  padding:7px 10px;
  font-size:11px;
}

.gp-dialog{
  width:min(520px,calc(100vw - 32px));
  border:0;
  border-radius:12px;
  padding:0;
}

.gp-dialog::backdrop{
  background:rgba(0,0,0,.5);
}

.gp-dialog form{
  padding:18px;
}

.gp-dialog-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
}

.gp-dialog-head h2{
  margin:0;
}

.gp-dialog-close{
  width:34px;
  height:34px;
  border-radius:7px;
  font-size:20px;
  padding:0;
}

.stop-geocode-status{
  padding:8px 10px;
  border-radius:7px;
  margin:8px 0 14px;
  font-size:12px;
}

.stop-geocode-status.good{
  background:#e7f6ec;
  border:1px solid #76b989;
}

.stop-geocode-status.bad{
  background:#ffe8e8;
  border:1px solid #d92d20;
  color:#8a0000;
}

.edi-danger-zone{
  margin-top:22px;
  border:2px solid #b42318;
}

.edi-danger-zone h2{
  color:#8a0000;
}

button.danger{
  background:#b42318;
  color:#fff;
  border-color:#b42318;
}

@media(max-width:1450px){
  .graphical-planning-page .gp-route-board-3x2{
    grid-template-columns:repeat(3,minmax(270px,1fr))!important;
    overflow-x:auto;
  }
}


/* ============================================================
   v1.1.0 - Driver App / POD / operationeel dashboard
   ============================================================ */

.driver-account-form{
  display:grid;
  grid-template-columns:1fr 1fr auto;
  gap:6px;
  margin-top:8px;
}
.driver-account-form input{min-width:0}
.driver-account-state{
  display:flex;
  flex-wrap:wrap;
  gap:7px;
  align-items:center;
  margin-top:6px;
  font-size:11px
}
.badge.good{background:#e4f6e9;color:#185b2b}
.badge.bad{background:#ffe7e5;color:#9b1c13}

.operations-cards{
  grid-template-columns:repeat(6,minmax(120px,1fr))
}
.metric-warning strong{color:#a15c00}
.metric-danger strong{color:#b42318}
.progress-inline{
  display:grid;
  grid-template-columns:auto minmax(80px,1fr);
  gap:8px;
  align-items:center
}
.progress-inline progress{
  width:100%;
  height:10px
}

.gp-live-status{
  display:inline-flex;
  width:max-content;
  padding:2px 6px;
  border-radius:999px;
  font-size:7.5px;
  font-weight:800;
  text-transform:uppercase;
  background:#edf1f4;
  color:#41505d
}
.gp-live-status.status-en_route{background:#fff1ce;color:#815600}
.gp-live-status.status-arrived{background:#dceeff;color:#0d558a}
.gp-live-status.status-completed{background:#dff4e5;color:#17632d}
.gp-live-status.status-skipped{background:#ffe2df;color:#9f1b12}

/* Driver shell */
body.driver-app{
  margin:0;
  min-height:100vh;
  background:#edf1f4;
  color:#14212b;
  font-family:Arial,sans-serif
}
.driver-topbar{
  position:sticky;
  top:0;
  z-index:50;
  height:62px;
  box-sizing:border-box;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding:8px 14px;
  background:#102536;
  color:#fff;
  box-shadow:0 2px 10px rgba(0,0,0,.16)
}
.driver-brand{
  display:flex;
  align-items:center;
  gap:9px;
  color:#fff;
  text-decoration:none
}
.driver-brand img{width:38px;height:38px;border-radius:8px}
.driver-brand span{display:flex;flex-direction:column}
.driver-brand small{font-size:10px;opacity:.75}
.driver-user{
  display:flex;
  align-items:center;
  gap:8px;
  font-size:11px
}
.driver-user form{margin:0}
.driver-user button{
  padding:6px 8px;
  font-size:10px;
  border-radius:6px
}
.driver-main{
  width:min(980px,100%);
  margin:0 auto;
  box-sizing:border-box;
  padding:16px 14px 36px
}
.driver-hero,
.driver-trip-header,
.driver-stop-detail-head{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:12px;
  margin-bottom:14px
}
.driver-hero h1,
.driver-trip-header h1,
.driver-stop-detail-head h1{
  margin:3px 0;
  line-height:1.1
}
.driver-hero p,
.driver-trip-header p,
.driver-stop-detail-head p{margin:4px 0;color:#5b6873}
.driver-eyebrow{
  font-size:10px;
  font-weight:800;
  text-transform:uppercase;
  letter-spacing:.08em;
  color:#657580
}
.driver-today{
  background:#fff;
  border:1px solid #d5dde3;
  padding:8px 10px;
  border-radius:8px;
  font-weight:700;
  font-size:12px
}
.driver-trip-grid{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:12px
}
.driver-trip-card{
  display:block;
  background:#fff;
  color:inherit;
  text-decoration:none;
  border:1px solid #d5dde3;
  border-left:6px solid #6d7c88;
  border-radius:12px;
  padding:14px;
  box-shadow:0 2px 8px rgba(15,35,50,.06)
}
.driver-trip-card.status-started{border-left-color:#e49b13}
.driver-trip-card.status-completed{border-left-color:#24964b}
.driver-trip-card-head{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:flex-start
}
.driver-trip-card h2{margin:2px 0;font-size:18px}
.driver-trip-card small{color:#6b7882}
.driver-status-pill{
  display:inline-flex;
  padding:5px 8px;
  border-radius:999px;
  background:#e8edf1;
  font-size:9px;
  font-weight:900;
  text-transform:uppercase
}
.driver-status-pill.large{font-size:10px;padding:7px 10px}
.driver-trip-route{
  display:flex;
  gap:8px;
  align-items:center;
  font-size:20px;
  margin:12px 0
}
.driver-trip-meta{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  color:#55636e;
  font-size:11px
}
.driver-progress{
  display:grid;
  gap:6px;
  margin-top:12px
}
.driver-progress div{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:baseline
}
.driver-progress div span{font-size:10px;color:#6a7680}
.driver-progress progress{
  width:100%;
  height:12px
}
.driver-progress.big{
  background:#fff;
  border:1px solid #d5dde3;
  border-radius:10px;
  padding:10px 12px;
  margin-bottom:10px
}
.driver-trip-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
  margin-bottom:10px
}
.driver-big-button{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:46px;
  padding:10px 15px;
  border-radius:9px;
  border:0;
  font-weight:800;
  text-decoration:none;
  cursor:pointer;
  box-sizing:border-box
}
.driver-primary{background:#1769aa;color:#fff}
.driver-secondary{background:#fff;color:#24323d;border:1px solid #bbc6ce}
.driver-success{background:#218b45;color:#fff}
.driver-location-state{
  font-size:10px;
  color:#697781
}
.driver-location-state.good{color:#218b45}
.driver-location-state.warn{color:#a45f00}
.driver-back{
  display:inline-block;
  margin-bottom:6px;
  font-size:11px;
  color:#1769aa;
  text-decoration:none;
  font-weight:700
}
.driver-depot-card,
.driver-stop-card{
  display:grid;
  grid-template-columns:36px minmax(0,1fr) auto;
  gap:10px;
  align-items:start;
  background:#fff;
  border:1px solid #d6dee4;
  border-radius:10px;
  padding:10px;
  margin-bottom:7px;
  color:inherit;
  text-decoration:none
}
.driver-depot-card{
  grid-template-columns:36px minmax(0,1fr);
  background:#e9eef2
}
.driver-depot-card div{display:flex;flex-direction:column;gap:2px}
.driver-depot-card span{font-size:10px;color:#66737d}
.driver-seq{
  display:grid;
  place-items:center;
  width:32px;
  height:32px;
  border-radius:50%;
  background:#213b4e;
  color:#fff;
  font-size:11px;
  font-weight:900
}
.driver-seq.depot{border-radius:7px;background:#102536}
.driver-stop-card.status-en_route{border-color:#e0aa39;background:#fffaf0}
.driver-stop-card.status-arrived{border-color:#3187c1;background:#f3f9fd}
.driver-stop-card.status-completed{border-color:#49a769;background:#f4fbf6}
.driver-stop-card.status-skipped{border-color:#d76056;background:#fff7f6}
.driver-stop-body{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:2px
}
.driver-stop-title{
  display:flex;
  justify-content:space-between;
  gap:6px;
  align-items:flex-start
}
.driver-stop-body span{font-size:11px;color:#4f5c66}
.driver-stop-body small{font-size:9.5px;color:#687681}
.driver-stop-type{
  display:inline-flex;
  flex:0 0 auto;
  padding:3px 6px;
  border-radius:5px;
  font-size:8px;
  font-weight:900
}
.driver-stop-type.pickup{background:#ffe694;color:#684e00}
.driver-stop-type.delivery{background:#dceeff;color:#0d558a}
.driver-stop-state{
  font-size:8px;
  font-weight:900;
  text-transform:uppercase;
  color:#687681
}
.driver-stop-primary-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin:10px 0 14px
}
.driver-stop-primary-actions form{margin:0}
.driver-detail-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:12px
}
.driver-panel{
  background:#fff;
  border:1px solid #d5dde3;
  border-radius:11px;
  padding:14px;
  margin-bottom:12px
}
.driver-panel h2{margin:0 0 10px;font-size:16px}
.driver-panel h3{margin:13px 0 5px;font-size:13px}
.driver-data{
  display:grid;
  gap:6px;
  margin:0
}
.driver-data div{
  display:grid;
  grid-template-columns:130px minmax(0,1fr);
  gap:8px;
  padding-bottom:5px;
  border-bottom:1px solid #edf0f2
}
.driver-data dt{
  font-size:10px;
  color:#66737d
}
.driver-data dd{
  margin:0;
  font-size:11px;
  font-weight:700
}
.driver-goods-list{display:grid;gap:6px}
.driver-goods-list>div{
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:3px 8px;
  border-bottom:1px solid #edf0f2;
  padding:5px 0
}
.driver-goods-list small{
  grid-column:1/-1;
  font-size:9px;
  color:#687681
}
.driver-pod-form{
  display:grid;
  gap:10px
}
.driver-pod-form label{
  display:grid;
  gap:4px;
  font-size:11px;
  font-weight:700
}
.driver-pod-form input,
.driver-pod-form select,
.driver-pod-form textarea{
  width:100%;
  box-sizing:border-box;
  padding:9px 10px;
  font-size:16px;
  border:1px solid #bac6ce;
  border-radius:7px
}
.driver-signature-block{
  display:grid;
  gap:6px
}
#signature-canvas{
  width:100%;
  height:170px;
  background:#fff;
  border:2px dashed #7d8991;
  border-radius:8px;
  touch-action:none
}
.driver-photo-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:7px
}
.driver-photo-grid img{
  width:100%;
  aspect-ratio:1.2;
  object-fit:cover;
  border-radius:7px
}
.driver-alert{
  padding:9px 11px;
  border-radius:8px;
  margin-bottom:10px;
  font-size:11px
}
.driver-alert.success{background:#e0f4e6;color:#1d6331}
.driver-alert.error{background:#ffe5e2;color:#8d1b12}
.driver-alert.warn{background:#fff2cf;color:#735000}
.driver-empty{
  background:#fff;
  border:1px dashed #c4cdd4;
  border-radius:10px;
  padding:24px;
  text-align:center
}
.driver-section-head{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px
}

/* POD */
body.pod-print-page{
  margin:0;
  background:#eceff1;
  color:#111;
  font-family:Arial,sans-serif
}
.pod-document{
  width:min(900px,calc(100% - 30px));
  margin:20px auto;
  background:#fff;
  padding:28px;
  box-sizing:border-box
}
.pod-header{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  border-bottom:2px solid #111;
  padding-bottom:12px
}
.pod-header h1{margin:0}
.pod-reference-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:8px;
  margin:14px 0
}
.pod-reference-grid div{
  border:1px solid #ccd2d6;
  padding:8px;
  display:flex;
  flex-direction:column;
  gap:3px
}
.pod-reference-grid span{font-size:10px;color:#687078}
.pod-section{
  border-top:1px solid #ccd2d6;
  padding-top:12px;
  margin-top:14px
}
.pod-table{width:100%;border-collapse:collapse}
.pod-table th,.pod-table td{
  border:1px solid #cfd5d8;
  padding:7px;
  text-align:left;
  font-size:11px
}
.pod-signature{
  max-width:360px;
  max-height:150px;
  border:1px solid #ccd2d6
}
.pod-photo-grid{
  display:grid;
  grid-template-columns:repeat(3,1fr);
  gap:8px
}
.pod-photo-grid img{
  width:100%;
  max-height:230px;
  object-fit:cover
}
.pod-footer{
  margin-top:16px;
  font-size:9px;
  color:#687078
}

@media(max-width:760px){
  .driver-user>span{display:none}
  .driver-main{padding:12px 10px 30px}
  .driver-trip-grid{grid-template-columns:1fr}
  .driver-detail-grid{grid-template-columns:1fr}
  .driver-hero,
  .driver-trip-header,
  .driver-stop-detail-head{align-items:flex-start}
  .driver-data div{grid-template-columns:105px minmax(0,1fr)}
  .driver-photo-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .driver-stop-title{flex-direction:column}
  .driver-stop-card{
    grid-template-columns:34px minmax(0,1fr);
  }
  .driver-stop-state{
    grid-column:2;
  }
  .operations-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
}

@media print{
  body.pod-print-page{background:#fff}
  .pod-document{
    width:100%;
    margin:0;
    padding:10mm
  }
  .pod-header button{display:none}
}


.gp-driver-select{
  min-width:110px;
  max-width:150px;
  padding:4px 5px;
  min-height:24px;
  font-size:8.5px;
  border-radius:5px;
  border:1px solid #c6d0d7;
  background:#fff;
}


/* ============================================================
   v1.1.1 - DEFINITIEVE FIXED SCREEN SHELL
   Deze regels staan bewust als laatste in app.css.
   ============================================================ */

/* ---------- gewone backoffice schermen ---------- */

html{
  height:100%;
}

body.app-body{
  width:100%;
  height:100%;
  min-width:0;
  min-height:0;
  margin:0;
  overflow:hidden!important;
}

body.app-body .app-shell{
  position:fixed!important;
  inset:0!important;
  width:auto!important;
  height:auto!important;
  min-width:0!important;
  min-height:0!important;
  overflow:hidden!important;

  display:grid!important;
  grid-template-columns:240px minmax(0,1fr)!important;
  grid-template-rows:minmax(0,1fr)!important;
}

/* vast menu */
body.app-body .app-sidebar{
  position:relative!important;
  inset:auto!important;
  width:auto!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-height:none!important;

  display:flex!important;
  flex-direction:column!important;

  overflow:hidden!important;
  padding:20px!important;
  z-index:50;
}

body.app-body .app-brand{
  flex:0 0 auto!important;
}

body.app-body .app-nav{
  flex:1 1 auto!important;
  min-width:0!important;
  min-height:0!important;

  display:grid!important;
  grid-auto-rows:max-content!important;
  align-content:start!important;

  overflow-x:hidden!important;
  overflow-y:auto!important;
  overscroll-behavior:contain;
  scrollbar-width:thin;

  margin-top:28px!important;
  padding-right:3px;
}

body.app-body .app-sidebar-footer{
  flex:0 0 auto!important;
  margin-top:auto;
}

body.app-body .app-sidebar-footer .portal-version{
  margin:0!important;
  padding:12px 4px 8px!important;
}

body.app-body .app-sidebar-footer form{
  margin:0!important;
}

body.app-body .app-sidebar-footer button{
  width:100%;
}

/* rechterzijde blijft volledig binnen viewport */
body.app-body .app-main{
  position:relative!important;
  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;

  overflow:hidden!important;

  display:grid!important;
  grid-template-columns:minmax(0,1fr)!important;
  grid-template-rows:66px minmax(0,1fr)!important;
}

/* statische kop */
body.app-body .app-header{
  position:relative!important;
  grid-column:1!important;
  grid-row:1!important;

  width:100%!important;
  height:66px!important;
  min-width:0!important;
  min-height:66px!important;
  max-height:66px!important;

  overflow:hidden!important;
  z-index:40;
}

/* ENIGE hoofdscroll voor gewone pagina's */
body.app-body .app-content{
  position:relative!important;
  grid-column:1!important;
  grid-row:2!important;

  width:100%!important;
  height:100%!important;
  min-width:0!important;
  min-height:0!important;
  max-width:none!important;

  overflow-x:auto!important;
  overflow-y:auto!important;
  overscroll-behavior:contain;
  scrollbar-gutter:stable;

  padding:26px!important;
}

/* inhoud mag nooit de gridkolom oprekken */
body.app-body .app-content > *{
  min-width:0;
  max-width:100%;
}

/* brede tabellen blijven binnen hoofdscroll */
body.app-body .app-content .table{
  max-width:100%;
}

/* ---------- grafische planner: bovenmenu vast ---------- */

body.app-body.graphical-planning-page .app-shell{
  grid-template-columns:minmax(0,1fr)!important;
  grid-template-rows:58px minmax(0,1fr)!important;
}

/* aside wordt de horizontale vaste bovenbalk */
body.app-body.graphical-planning-page .app-sidebar{
  grid-column:1!important;
  grid-row:1!important;

  width:100%!important;
  height:58px!important;
  min-height:58px!important;
  max-height:58px!important;

  display:grid!important;
  grid-template-columns:auto minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:14px!important;

  padding:5px 14px!important;
  overflow:hidden!important;
}

body.app-body.graphical-planning-page .app-brand{
  min-width:150px;
}

body.app-body.graphical-planning-page .app-brand img{
  width:40px;
  height:40px;
}

body.app-body.graphical-planning-page .app-nav{
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;

  min-width:0!important;
  min-height:0!important;

  margin:0!important;
  padding:0 2px!important;

  white-space:nowrap;
  overflow-x:auto!important;
  overflow-y:hidden!important;
}

body.app-body.graphical-planning-page .app-nav a{
  flex:0 0 auto;
  padding:7px 9px;
  font-size:11px;
}

body.app-body.graphical-planning-page .app-sidebar-footer{
  display:flex!important;
  align-items:center!important;
  gap:8px!important;
  margin:0!important;
  white-space:nowrap;
}

body.app-body.graphical-planning-page .app-sidebar-footer .portal-version{
  padding:0!important;
}

body.app-body.graphical-planning-page .app-sidebar-footer button{
  width:auto;
  padding:6px 8px;
  font-size:10px;
}

/* main staat onder de bovenbalk */
body.app-body.graphical-planning-page .app-main{
  grid-column:1!important;
  grid-row:2!important;

  width:100%!important;
  height:100%!important;

  grid-template-rows:48px minmax(0,1fr)!important;
}

body.app-body.graphical-planning-page .app-header{
  height:48px!important;
  min-height:48px!important;
  max-height:48px!important;
  padding:0 16px!important;
  font-size:16px!important;
}

body.app-body.graphical-planning-page .app-content{
  overflow:hidden!important;
  padding:10px 12px 12px!important;
}

/* Planner gebruikt alleen de bedoelde lokale scrollvlakken */
body.app-body.graphical-planning-page .gp-workboard{
  min-height:0!important;
  overflow:hidden!important;
}

body.app-body.graphical-planning-page .gp-free-panel,
body.app-body.graphical-planning-page .gp-routes-workspace,
body.app-body.graphical-planning-page .gp-route-panel{
  min-height:0!important;
  overflow:hidden!important;
}

body.app-body.graphical-planning-page .gp-free-list,
body.app-body.graphical-planning-page .gp-stop-list{
  min-height:0!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  overscroll-behavior:contain;
}

/* ---------- responsive backoffice ---------- */

/*
   Op smallere beheerschermen blijft het menu zichtbaar.
   We verkleinen het in plaats van het via de oude mediaquery te verbergen.
*/
@media(max-width:1100px){
  body.app-body:not(.graphical-planning-page) .app-shell{
    grid-template-columns:205px minmax(0,1fr)!important;
  }

  body.app-body:not(.graphical-planning-page) .app-sidebar{
    display:flex!important;
    padding:14px!important;
  }

  body.app-body:not(.graphical-planning-page) .app-nav a{
    padding:9px 8px;
    font-size:12px;
  }

  body.app-body:not(.graphical-planning-page) .app-content{
    padding:18px!important;
  }
}

@media(max-width:760px){
  body.app-body:not(.graphical-planning-page) .app-shell{
    grid-template-columns:175px minmax(0,1fr)!important;
  }

  body.app-body:not(.graphical-planning-page) .app-sidebar{
    display:flex!important;
    padding:10px!important;
  }

  body.app-body:not(.graphical-planning-page) .app-brand img{
    width:38px;
    height:38px;
  }

  body.app-body:not(.graphical-planning-page) .app-brand small{
    display:none;
  }

  body.app-body:not(.graphical-planning-page) .app-nav{
    margin-top:16px!important;
  }

  body.app-body:not(.graphical-planning-page) .app-nav a{
    padding:8px 6px;
    font-size:11px;
  }
}

/* lagere desktopresolutie */
@media(max-height:760px){
  body.app-body:not(.graphical-planning-page) .app-main{
    grid-template-rows:54px minmax(0,1fr)!important;
  }

  body.app-body:not(.graphical-planning-page) .app-header{
    height:54px!important;
    min-height:54px!important;
    max-height:54px!important;
  }

  body.app-body:not(.graphical-planning-page) .app-content{
    padding-top:16px!important;
    padding-bottom:16px!important;
  }

  body.app-body.graphical-planning-page .app-shell{
    grid-template-rows:52px minmax(0,1fr)!important;
  }

  body.app-body.graphical-planning-page .app-sidebar{
    height:52px!important;
    min-height:52px!important;
    max-height:52px!important;
  }

  body.app-body.graphical-planning-page .app-main{
    grid-template-rows:42px minmax(0,1fr)!important;
  }

  body.app-body.graphical-planning-page .app-header{
    height:42px!important;
    min-height:42px!important;
    max-height:42px!important;
  }
}


/* ============================================================
   v1.1.2 - Driver Mobile UX / package scanning
   ============================================================ */

body.driver-app{
  height:100dvh;
  min-height:100dvh;
  overflow:hidden;
  display:grid;
  grid-template-rows:72px minmax(0,1fr);
  font-size:17px;
  line-height:1.5;
}

.driver-topbar{
  position:relative;
  top:auto;
  height:72px;
  min-height:72px;
  padding:9px 14px;
}

.driver-brand img{
  width:46px;
  height:46px;
}

.driver-brand b{
  font-size:18px;
}

.driver-brand small{
  font-size:12px;
}

.driver-user{
  font-size:14px;
}

.driver-user button{
  min-height:44px;
  font-size:14px;
  padding:8px 11px;
}

.driver-main{
  width:min(980px,100%);
  height:100%;
  min-height:0;
  overflow-y:auto;
  overflow-x:hidden;
  -webkit-overflow-scrolling:touch;
  overscroll-behavior:contain;
  scroll-behavior:smooth;
  padding:14px 14px max(38px,env(safe-area-inset-bottom));
}

.driver-stop-screen{
  min-width:0;
  display:grid;
  gap:12px;
}

.driver-stop-summary{
  background:#fff;
  border:1px solid #d5dde3;
  border-radius:14px;
  padding:14px;
}

.driver-stop-summary-top,
.driver-stop-heading-row{
  display:flex;
  align-items:flex-start;
  gap:12px;
}

.driver-stop-summary-top{
  justify-content:space-between;
  margin-bottom:9px;
}

.driver-stop-heading-row{
  min-width:0;
}

.driver-stop-heading-row>div{
  min-width:0;
}

.driver-stop-heading-row h1{
  margin:0 0 5px;
  font-size:25px;
  line-height:1.15;
  overflow-wrap:anywhere;
}

.driver-stop-heading-row p{
  margin:0;
  font-size:18px;
  line-height:1.4;
  color:#47545e;
}

.driver-stop-number-big{
  flex:0 0 auto;
  width:48px;
  height:48px;
  display:grid;
  place-items:center;
  background:#102536;
  color:#fff;
  border-radius:12px;
  font-size:21px;
  font-weight:900;
}

.driver-stop-type{
  font-size:11px;
  padding:5px 8px;
}

.driver-back{
  font-size:15px;
  min-height:32px;
  display:inline-flex;
  align-items:center;
}

.driver-stage-strip{
  margin-top:14px;
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:6px;
}

.driver-stage-strip span{
  padding:8px 4px;
  border-radius:8px;
  background:#edf1f4;
  color:#687781;
  text-align:center;
  font-size:11px;
  font-weight:800;
}

.driver-stage-strip span.active{
  background:#dceeff;
  color:#0d558a;
}

.driver-stage-strip span.done{
  background:#dff4e5;
  color:#17632d;
}

.driver-stop-actionbar{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:9px;
}

.driver-stop-actionbar form{
  margin:0;
  display:flex;
}

.driver-stop-actionbar .driver-big-button{
  width:100%;
}

.driver-big-button{
  min-height:54px;
  font-size:17px;
  padding:11px 14px;
  border-radius:10px;
}

.driver-shipment-info{
  background:#fff;
  border:1px solid #d5dde3;
  border-radius:12px;
  overflow:hidden;
}

.driver-shipment-info summary{
  list-style:none;
  cursor:pointer;
  padding:14px;
  min-height:50px;
  font-size:17px;
  font-weight:800;
  display:flex;
  align-items:center;
  justify-content:space-between;
}

.driver-shipment-info summary::-webkit-details-marker{
  display:none;
}

.driver-shipment-info summary::after{
  content:"▾";
  font-size:16px;
}

.driver-shipment-info[open] summary::after{
  transform:rotate(180deg);
}

.driver-shipment-scroll{
  max-height:44dvh;
  overflow-y:auto;
  overscroll-behavior:contain;
  border-top:1px solid #e2e8ec;
  padding:12px 14px 16px;
}

.driver-data.large{
  font-size:16px;
}

.driver-data.large div{
  grid-template-columns:125px minmax(0,1fr);
  gap:10px;
  padding:8px 0;
}

.driver-data.large dt{
  font-size:14px;
}

.driver-data.large dd{
  font-size:16px;
  overflow-wrap:anywhere;
}

.driver-info-block h3{
  font-size:17px;
  margin:16px 0 7px;
}

.driver-info-block p{
  font-size:16px;
}

.driver-contact-button{
  display:block;
  margin-top:7px;
  padding:9px 10px;
  background:#f1f6fa;
  border-radius:8px;
  font-weight:700;
}

.driver-next-step{
  padding:18px;
  font-size:17px;
}

.driver-next-step h2{
  font-size:21px;
}

/* Pakketcontrole */
.driver-package-panel{
  background:#fff;
  border:2px solid #b7c9d8;
  border-radius:14px;
  overflow:hidden;
}

.driver-package-head{
  display:flex;
  justify-content:space-between;
  gap:14px;
  align-items:center;
  padding:15px;
}

.driver-package-head h2{
  margin:2px 0 3px;
  font-size:23px;
}

.driver-package-head p{
  margin:0;
  color:#5c6973;
  font-size:15px;
}

.driver-package-counter{
  flex:0 0 auto;
  min-width:72px;
  text-align:right;
  font-size:17px;
}

.driver-package-counter strong{
  font-size:31px;
}

.driver-package-progress{
  display:block;
  width:calc(100% - 30px);
  height:14px;
  margin:0 15px 14px;
}

.driver-scan-actions{
  padding:0 15px 14px;
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:9px;
}

.driver-manual-barcode{
  grid-column:1/-1;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:7px;
}

.driver-manual-barcode input{
  width:100%;
  min-width:0;
  min-height:52px;
  padding:10px 12px;
  font-size:18px;
  border:1px solid #aebdc8;
  border-radius:9px;
}

.driver-manual-barcode button{
  min-height:52px;
  font-size:16px;
  font-weight:800;
}

.driver-hidden-file{
  display:none!important;
}

.driver-scan-message{
  min-height:0;
  margin:0 15px 10px;
  padding:0;
  font-size:15px;
  font-weight:700;
}

.driver-scan-message:not(:empty){
  padding:9px 10px;
  border-radius:8px;
  background:#eef3f6;
}

.driver-scan-message.success{
  background:#e0f4e6;
  color:#1d6331;
}

.driver-scan-message.error{
  background:#ffe5e2;
  color:#8d1b12;
}

.driver-package-scroll{
  max-height:50dvh;
  min-height:120px;
  overflow-y:auto;
  overflow-x:hidden;
  overscroll-behavior:contain;
  border-top:1px solid #dfe6ea;
  border-bottom:1px solid #dfe6ea;
}

.driver-package-row{
  display:grid;
  grid-template-columns:44px minmax(0,1fr) auto;
  gap:11px;
  align-items:center;
  padding:13px 14px;
  border-bottom:1px solid #e3e9ed;
  background:#fff;
}

.driver-package-row:last-child{
  border-bottom:0;
}

.driver-package-row.complete{
  background:#f0faf3;
}

.driver-package-checkmark{
  width:42px;
  height:42px;
  display:grid;
  place-items:center;
  border:2px solid #97a9b6;
  border-radius:10px;
  font-size:20px;
  font-weight:900;
  color:#52616c;
  background:#fff;
}

.driver-package-row.complete .driver-package-checkmark{
  border-color:#2f9b51;
  background:#2f9b51;
  color:#fff;
}

.driver-package-body{
  min-width:0;
  display:flex;
  flex-direction:column;
  gap:4px;
}

.driver-package-body>b{
  font-size:17px;
  line-height:1.25;
  overflow-wrap:anywhere;
}

.driver-package-refs{
  display:flex;
  flex-direction:column;
  gap:2px;
  color:#5b6872;
  font-size:13px;
}

.driver-package-refs code{
  font-size:14px;
  color:#14212b;
  font-weight:800;
  overflow-wrap:anywhere;
}

.driver-package-qty{
  font-size:14px;
  color:#34444f;
}

.driver-package-controls{
  display:flex;
  flex-direction:column;
  gap:6px;
  align-items:stretch;
}

.driver-package-controls button{
  min-width:80px;
  min-height:42px;
  font-size:15px;
  font-weight:800;
  padding:7px 9px;
}

.driver-package-controls button[data-package-action="increment"],
.driver-package-controls button[data-package-action="decrement"]{
  min-width:44px;
  width:100%;
  font-size:21px;
}

.driver-package-row.complete .driver-package-toggle{
  background:#e7f5eb;
  color:#1f6f37;
  border-color:#8ac59b;
}

.driver-no-packages{
  padding:20px 15px;
  text-align:center;
}

.driver-package-footer{
  padding:13px 15px 15px;
  display:grid;
  gap:9px;
}

.driver-package-complete{
  display:none;
  padding:9px 10px;
  border-radius:8px;
  background:#e0f4e6;
  color:#1d6331;
  font-size:16px;
  font-weight:900;
  text-align:center;
}

.driver-package-complete.show{
  display:block;
}

.driver-finish-button{
  width:100%;
  font-size:19px;
}

.driver-finish-button:disabled{
  opacity:.45;
  cursor:not-allowed;
}

.driver-exception-button{
  min-height:46px;
  font-size:15px;
  background:#fff4d6;
  color:#745200;
  border-color:#dcc36f;
}

/* Dialogs */
.driver-dialog{
  width:min(620px,calc(100% - 20px));
  max-width:620px;
  max-height:calc(100dvh - 20px);
  border:0;
  border-radius:16px;
  padding:0;
  color:#14212b;
  overflow:hidden;
}

.driver-dialog::backdrop{
  background:rgba(8,19,28,.72);
}

.driver-dialog-head{
  min-height:67px;
  padding:12px 14px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  border-bottom:1px solid #d9e0e5;
}

.driver-dialog-head h2{
  margin:1px 0;
  font-size:22px;
}

.driver-dialog-close{
  flex:0 0 auto;
  width:46px;
  height:46px;
  padding:0;
  display:grid;
  place-items:center;
  font-size:29px;
}

.driver-scanner-dialog{
  background:#101a22;
  color:#fff;
}

.driver-scanner-dialog .driver-dialog-head{
  border-color:#384650;
}

.driver-scanner-video-wrap{
  position:relative;
  background:#000;
  aspect-ratio:3/4;
  max-height:65dvh;
  overflow:hidden;
}

#barcode-video{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
}

.driver-scan-frame{
  position:absolute;
  left:10%;
  right:10%;
  top:38%;
  height:24%;
  border:3px solid #fff;
  border-radius:14px;
  box-shadow:0 0 0 9999px rgba(0,0,0,.32);
  pointer-events:none;
}

#camera-status{
  margin:0;
  padding:11px 14px;
  font-size:15px;
  text-align:center;
}

.driver-scanner-dialog>.driver-big-button{
  width:calc(100% - 28px);
  margin:0 14px 14px;
}

.driver-complete-dialog form{
  height:min(780px,calc(100dvh - 20px));
  max-height:calc(100dvh - 20px);
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
  overflow:hidden;
}

.driver-close-stop-scroll{
  min-height:0;
  overflow-y:auto;
  overscroll-behavior:contain;
  padding:14px;
}

.driver-field{
  display:grid;
  gap:6px;
  margin-bottom:13px;
  font-size:16px;
  font-weight:800;
}

.driver-field input,
.driver-field select,
.driver-field textarea{
  width:100%;
  min-height:52px;
  margin:0;
  padding:10px 12px;
  font-size:18px;
  border:1px solid #aebdc8;
  border-radius:9px;
  background:#fff;
}

.driver-field textarea{
  min-height:90px;
  resize:vertical;
}

.driver-field small{
  font-size:13px;
  margin-top:-2px;
}

.driver-field.optional::after{
  content:"Niet verplicht bij deze afwijking";
  color:#71808e;
  font-size:12px;
  font-weight:500;
}

.driver-signature-block{
  display:grid;
  gap:8px;
  margin:4px 0 14px;
}

.driver-signature-title{
  display:flex;
  flex-direction:column;
  gap:2px;
}

.driver-signature-title b{
  font-size:17px;
}

.driver-signature-title span{
  font-size:13px;
  color:#65737d;
}

.driver-signature-block.optional{
  opacity:.72;
}

#signature-canvas{
  width:100%;
  height:210px;
  display:block;
  background:#fff;
  border:2px dashed #6e7e89;
  border-radius:10px;
  touch-action:none;
}

#clear-signature{
  min-height:44px;
  font-size:14px;
}

.driver-dialog-footer{
  border-top:1px solid #d9e0e5;
  padding:10px 14px max(10px,env(safe-area-inset-bottom));
  background:#fff;
}

.driver-dialog-footer .driver-big-button{
  width:100%;
  font-size:18px;
}

.driver-alert{
  font-size:16px;
  padding:11px 13px;
}

.driver-panel h2{
  font-size:21px;
}

/* smaller phones */
@media(max-width:600px){
  body.driver-app{
    grid-template-rows:66px minmax(0,1fr);
    font-size:16px;
  }

  .driver-topbar{
    height:66px;
    min-height:66px;
    padding:7px 10px;
  }

  .driver-brand img{
    width:42px;
    height:42px;
  }

  .driver-brand b{
    font-size:17px;
  }

  .driver-brand small{
    font-size:11px;
  }

  .driver-user button{
    min-height:42px;
    font-size:13px;
  }

  .driver-main{
    padding:10px 9px max(28px,env(safe-area-inset-bottom));
  }

  .driver-stop-summary{
    padding:12px;
  }

  .driver-stop-heading-row h1{
    font-size:23px;
  }

  .driver-stop-heading-row p{
    font-size:17px;
  }

  .driver-stage-strip span{
    font-size:10px;
    padding:7px 3px;
  }

  .driver-stop-actionbar{
    grid-template-columns:1fr;
  }

  .driver-scan-actions{
    grid-template-columns:1fr;
  }

  .driver-manual-barcode{
    grid-column:1;
    grid-template-columns:1fr;
  }

  .driver-package-row{
    grid-template-columns:42px minmax(0,1fr);
    align-items:start;
  }

  .driver-package-controls{
    grid-column:1/-1;
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  .driver-package-controls .driver-package-toggle{
    grid-column:1/-1;
  }

  .driver-package-scroll{
    max-height:46dvh;
  }

  .driver-shipment-scroll{
    max-height:38dvh;
  }

  .driver-dialog{
    width:calc(100% - 10px);
    max-height:calc(100dvh - 10px);
    border-radius:13px;
  }

  .driver-complete-dialog form{
    height:calc(100dvh - 10px);
    max-height:calc(100dvh - 10px);
  }

  #signature-canvas{
    height:190px;
  }
}

@media(max-width:380px){
  .driver-stop-heading-row{
    gap:9px;
  }

  .driver-stop-number-big{
    width:42px;
    height:42px;
    font-size:19px;
  }

  .driver-stop-heading-row h1{
    font-size:21px;
  }

  .driver-stop-heading-row p{
    font-size:16px;
  }

  .driver-stage-strip{
    gap:3px;
  }

  .driver-stage-strip span{
    font-size:9px;
  }
}


/* ============================================================
   v1.1.3 - robuuste Driver workflow zonder JS-afhankelijkheid
   ============================================================ */
.package-action-form{
  margin:0;
  display:contents;
}
.package-toggle-form{
  display:block;
}
.driver-camera-label{
  cursor:pointer;
  margin:0;
}
.driver-camera-label input{
  position:absolute;
  width:1px;
  height:1px;
  opacity:0;
  pointer-events:none;
}
.driver-photo-scan-form{
  display:grid;
  gap:6px;
}
.driver-photo-scan-form>button{
  min-height:44px;
  font-weight:700;
}
.driver-close-stop-native{
  scroll-margin-top:12px;
}
.driver-close-details{
  background:#fff;
  border:2px solid #b7c9d8;
  border-radius:14px;
  overflow:hidden;
}
.driver-close-details>summary{
  min-height:64px;
  padding:12px 14px;
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:10px;
  cursor:pointer;
  list-style:none;
  background:#f4f9fc;
}
.driver-close-details>summary::-webkit-details-marker{display:none}
.driver-close-details>summary span:first-child{
  display:flex;
  flex-direction:column;
}
.driver-close-details>summary small{
  font-size:11px;
  color:#687781;
}
.driver-close-details>summary b{
  font-size:20px;
}
.driver-close-arrow{
  font-size:30px;
  transition:transform .15s ease;
}
.driver-close-details[open] .driver-close-arrow{
  transform:rotate(90deg);
}
.driver-close-details .driver-close-stop-scroll{
  border-top:1px solid #d9e2e8;
}
.driver-signature-fallback{
  padding:10px;
  background:#fff8e5;
  border:1px solid #ead499;
  border-radius:9px;
}
.driver-finish-button[href]{
  text-decoration:none;
}
@media(max-width:600px){
  .driver-close-details>summary b{font-size:19px}
}


/* ============================================================
   v1.2.0 - planinstellingen, routeprofielen en ETA
   ============================================================ */
.planning-settings-intro{padding:16px 18px;margin-bottom:14px}
.planning-settings-intro h2{margin:0 0 4px}
.planning-settings-intro p{margin:0}
.planning-settings-grid{
  display:grid;grid-template-columns:1fr 1fr;gap:14px;align-items:start
}
.planning-settings-column{min-width:0;display:grid;gap:10px}
.planning-settings-head h2{margin:0}
.planning-settings-head p{margin:3px 0 0}
.profile-list{display:grid;gap:10px}
.profile-form{padding:14px}
.profile-form h3{margin:0 0 10px}
.profile-two,.profile-three{display:grid;gap:8px}
.profile-two{grid-template-columns:repeat(2,minmax(0,1fr))}
.profile-three{grid-template-columns:repeat(3,minmax(0,1fr))}
.profile-title-row{
  display:flex;align-items:flex-start;justify-content:space-between;
  gap:10px;margin-bottom:8px
}
.profile-title-row h3{margin:0}
.profile-active,.profile-default-check{
  display:flex!important;flex-direction:row!important;align-items:center;
  gap:6px!important
}
.profile-active input,.profile-default-check input{width:auto!important}
.profile-actions{display:flex;gap:7px;flex-wrap:wrap}
.planning-provider-note{margin-top:14px;padding:13px 15px}
.planning-provider-note p{margin:4px 0 0}
.gp-route-profile-select{
  min-width:110px;max-width:150px;padding:4px 5px;min-height:24px;
  font-size:8.5px;border-radius:5px;border:1px solid #c6d0d7;background:#fff
}
.gp-route-metric-line{grid-template-columns:repeat(4,minmax(0,1fr))!important}
.gp-stop-eta{color:#165ea4!important;font-weight:800}
.driver-route-note{
  background:#fff7d8;border:1px solid #e5ce79;border-radius:10px;
  padding:11px 13px;margin-bottom:10px
}
.driver-route-note b{font-size:16px}
.driver-route-note p{margin:5px 0 0;font-size:15px;white-space:pre-wrap}
.driver-trip-number{font-size:13px!important;color:#65737d!important}
.driver-stop-eta{
  display:block;margin:4px 0 1px;font-size:17px;color:#0d5f9e
}
.driver-planned-time{
  font-size:13px!important;color:#0d5f9e!important;font-weight:800
}
.driver-stop-detail-eta{
  margin-top:7px;display:inline-block;background:#dceeff;color:#0d558a;
  padding:5px 8px;border-radius:7px;font-size:16px;font-weight:900
}
@media(max-width:1100px){
  .planning-settings-grid{grid-template-columns:1fr}
}
@media(max-width:700px){
  .profile-two,.profile-three{grid-template-columns:1fr}
  .gp-route-metric-line{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}


/* ============================================================
   v2.0.0 - compacte beheerlayout
   ============================================================ */
body.app-body .app-shell{
  grid-template-columns:216px minmax(0,1fr)!important;
}
body.app-body .app-sidebar{
  padding:12px!important;
}
body.app-body .app-brand{
  gap:9px!important;
}
body.app-body .app-brand img{
  width:42px!important;
  height:42px!important;
}
body.app-body .app-brand b{font-size:15px!important}
body.app-body .app-brand small{font-size:10px!important}
body.app-body .app-nav{
  margin-top:12px!important;
  gap:2px!important;
  padding-right:2px!important;
}
body.app-body .app-nav a{
  padding:7px 9px!important;
  min-height:34px!important;
  border-radius:7px!important;
  font-size:12px!important;
}
.nav-group-label{
  margin:10px 8px 3px;
  color:rgba(255,255,255,.44);
  font-size:9px;
  font-weight:800;
  letter-spacing:.08em;
  text-transform:uppercase;
}
.nav-group-label:first-child{margin-top:2px}
body.app-body .app-main{
  grid-template-rows:56px minmax(0,1fr)!important;
}
body.app-body .app-header{
  height:56px!important;
  min-height:56px!important;
  max-height:56px!important;
  padding:0 16px!important;
}
body.app-body .app-content{
  padding:16px!important;
}
body.app-body .app-sidebar-footer .portal-version{
  padding:7px 3px 5px!important;
  font-size:9px!important;
}
body.app-body .app-sidebar-footer button{
  min-height:32px!important;
  padding:6px 8px!important;
}
body.app-body:not(.graphical-planning-page) .card,
body.app-body:not(.graphical-planning-page) .panel{
  border-radius:9px!important;
}
body.app-body:not(.graphical-planning-page) table th,
body.app-body:not(.graphical-planning-page) table td{
  padding-top:7px!important;
  padding-bottom:7px!important;
}
body.app-body:not(.graphical-planning-page) input,
body.app-body:not(.graphical-planning-page) select,
body.app-body:not(.graphical-planning-page) textarea{
  min-height:34px;
}
@media(max-width:1100px){
  body.app-body:not(.graphical-planning-page) .app-shell{
    grid-template-columns:190px minmax(0,1fr)!important;
  }
  body.app-body:not(.graphical-planning-page) .app-content{padding:12px!important}
}

/* v2.1.0 - tenant country access */
.gp-country-summary{padding-left:8px;border-left:1px solid #d7e0e6}
.gp-free-row.country-disabled{opacity:.55;filter:grayscale(.45);background:#f4f4f4}
.gp-free-row.country-disabled .gp-move-strip{background:#777!important}
.gp-free-row.country-disabled .gp-row-title b{text-decoration:line-through;text-decoration-thickness:1px}

/* ============================================================
   v2.2.6 - compacte rittegels + ritstops drawer + PDF ritlijst
   ============================================================ */
.graphical-planning-page .gp-routes-workspace{
  grid-template-rows:44px minmax(0,1fr);
}
.graphical-planning-page .gp-routes-workspace-head{
  min-height:44px;
  height:44px;
}
.graphical-planning-page .gp-route-board-3x2{
  gap:10px;
}
.graphical-planning-page .gp-route-panel{
  padding:10px;
  gap:7px;
  overflow:hidden!important;
}
.graphical-planning-page .gp-route-head{
  min-height:38px;
  grid-template-columns:8px minmax(0,1fr) auto;
  gap:7px;
}
.graphical-planning-page .gp-route-color{height:36px;width:8px}
.graphical-planning-page .gp-route-title b{font-size:13px}
.graphical-planning-page .gp-route-title small{font-size:9px}
.graphical-planning-page .gp-route-head-metrics b{font-size:15px}
.graphical-planning-page .gp-route-head-metrics small{font-size:8px}

.gp-route-card-fields{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:6px;
}
.gp-route-card-fields label{
  display:flex;
  flex-direction:column;
  gap:2px;
  margin:0;
  min-width:0;
}
.gp-route-card-fields label>span{
  font-size:8px;
  font-weight:800;
  color:#607080;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.gp-route-card-fields select{
  width:100%;
  min-width:0;
  min-height:30px;
  padding:4px 6px;
  font-size:10px;
}
.gp-route-duration-box{
  display:flex;
  justify-content:space-between;
  gap:8px;
  align-items:center;
  min-height:49px;
  padding:7px 9px;
  border:1px solid #d6e0e7;
  border-radius:8px;
  background:#f7fafc;
}
.gp-route-duration-box>div:first-child{
  display:flex;
  flex-direction:column;
  gap:1px;
}
.gp-route-duration-box>div:first-child>span{
  font-size:8px;
  font-weight:800;
  text-transform:uppercase;
  color:#607080;
}
.gp-route-duration-box .total-duration{
  font-size:18px;
  color:#18364a;
  line-height:1.05;
}
.gp-route-duration-sub{
  display:flex;
  flex-direction:column;
  gap:1px;
  text-align:right;
  font-size:8.5px;
  color:#5b6b78;
}
.gp-route-duration-sub b{color:#18364a}
.gp-route-dropzone{
  flex:1 1 auto;
  min-height:48px;
  border:1.5px dashed #aebdca;
  border-radius:8px;
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:2px;
  padding:7px;
  text-align:center;
  color:#607080;
  background:#fbfcfd;
  transition:.15s ease;
}
.gp-route-dropzone b{font-size:9px;color:#344b5e}
.gp-route-dropzone span{font-size:8px}
.gp-route-dropzone.drag-target{
  border-color:var(--route-color,#4b9bd8);
  box-shadow:inset 0 0 0 2px var(--route-color,#4b9bd8);
  background:#f0f8ff;
}
.gp-route-tile-actions{
  display:grid;
  grid-template-columns:1fr 1fr 1fr;
  gap:5px;
}
.gp-route-tile-actions button,
.gp-route-tile-actions .button-link{
  min-height:31px;
  padding:5px 6px;
  font-size:9px;
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  white-space:nowrap;
}
.gp-route-tile-actions .gp-trip-pdf{
  background:#eef6f0;
  border-color:#9dc8a7;
  color:#235a31;
}

.gp-trip-drawer[hidden]{display:none!important}
.gp-trip-drawer{
  position:fixed;
  top:58px;
  right:12px;
  bottom:12px;
  width:min(560px,calc(100vw - 40px));
  z-index:1500;
  display:flex;
  flex-direction:column;
  gap:8px;
  padding:12px;
  border:1px solid #bdc9d2;
  border-radius:12px;
  background:#fff;
  box-shadow:0 12px 44px rgba(20,42,58,.28);
}
.gp-trip-drawer-head{
  display:flex;
  justify-content:space-between;
  gap:12px;
  align-items:center;
  padding-bottom:7px;
  border-bottom:1px solid #e0e6ea;
}
.gp-trip-drawer-head small{
  display:block;
  font-size:9px;
  font-weight:800;
  color:#6d7d89;
  text-transform:uppercase;
}
.gp-trip-drawer-head h2{margin:1px 0 0;font-size:18px}
.gp-trip-drawer-close{
  width:34px;
  height:34px;
  padding:0;
  font-size:21px;
}
.gp-trip-drawer-meta{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  font-size:10px;
}
.gp-trip-drawer-meta span,
.gp-trip-drawer-meta b{
  padding:4px 7px;
  border-radius:6px;
  background:#eef3f6;
}
.gp-trip-drawer-list{
  flex:1 1 auto;
  min-height:0;
  overflow-y:auto;
  display:flex;
  flex-direction:column;
  gap:5px;
  padding-right:3px;
}
.gp-drawer-depot{
  display:flex;
  flex-direction:column;
  gap:2px;
  padding:8px 9px;
  border:1px solid #aebbc5;
  border-left:5px solid #344b5e;
  border-radius:7px;
  background:#eef2f5;
  font-size:10px;
}
.gp-drawer-depot span{color:#526273;font-size:9px}
.gp-trip-drawer .gp-stop-row{
  grid-template-columns:28px minmax(0,1fr) 64px;
  min-height:68px;
  padding:7px;
}
.gp-trip-drawer .gp-stop-main{font-size:10px;gap:2px}
.gp-trip-drawer .gp-stop-main b{font-size:10.5px}
.gp-trip-drawer .gp-stop-main span,
.gp-trip-drawer .gp-stop-main small{font-size:9px}
.gp-trip-drawer .gp-stop-seq{width:25px;height:25px;font-size:9px}
.gp-drawer-stop-actions{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:3px;
  align-content:center;
}
.gp-drawer-stop-actions button,
.gp-drawer-stop-actions .gp-edit-stop{
  width:28px;
  min-width:28px;
  height:25px;
  padding:0;
  font-size:12px;
}
.gp-trip-drawer-help{
  flex:0 0 auto;
  font-size:9px;
  padding-top:5px;
  border-top:1px solid #e0e6ea;
}

@media(max-width:1300px){
  .gp-route-card-fields{grid-template-columns:1fr}
  .graphical-planning-page .gp-route-board-3x2{
    grid-template-columns:repeat(3,minmax(240px,1fr))!important;
    overflow-x:auto;
  }
}

/* The planning navigation lives beside the board; the map has its own window. */
@media(min-width:901px){
  body.app-body.graphical-planning-page .app-shell{grid-template-columns:220px minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr)!important}
  body.app-body.graphical-planning-page .app-main{grid-column:2!important;grid-row:1!important}
  body.app-body.graphical-planning-page .app-sidebar{grid-column:1!important;grid-row:1!important;display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:12px;min-height:0!important;max-height:none!important;height:100%!important;padding:16px 12px!important;overflow-y:auto}
  .graphical-planning-page .layout > aside .brand{min-width:0}
  body.app-body.graphical-planning-page .app-sidebar nav{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:4px;white-space:normal;overflow:visible}
  body.app-body.graphical-planning-page .app-sidebar nav .nav-group-label{display:block!important}
  .graphical-planning-page .layout > aside nav a{font-size:13px;padding:9px 10px}
  .graphical-planning-page .app-sidebar-footer{margin-top:auto}
}

/* Relation-book theme shared with the approved DemoEXT portal style. */
.app-sidebar{background:#fff;color:#17324d;border-right:1px solid #d8e3ed}.app-sidebar .app-brand b{color:#134b7c}.app-sidebar .app-brand small,.app-sidebar .nav-group-label{color:#708499}.app-sidebar .app-nav a{color:#35516d}.app-sidebar .app-nav a:hover{background:#edf5fd}.app-sidebar .app-nav a.active{background:#e5f1ff;color:#0758ba}.app-header{background:#094783;color:#fff}.app-sidebar-footer{color:#708499}
