/* CM dashboard v3.13.58 -- front-end only, no backend or GPS ingest changes */
.cm-dash-v2 .focus-live-page{max-width:1850px;padding-top:20px}
.cm-dash-v2 .focus-titlebar{margin-bottom:12px}
.cm-dash-v2 .focus-statusbar{margin-bottom:12px}
.cm-dash-toolbar{display:flex;justify-content:space-between;align-items:center;gap:16px;margin:5px 0 12px}
.cm-dash-toolbar>div:first-child{display:grid;gap:3px}
.cm-dash-toolbar strong{font-size:15px;color:#143e5b}
.cm-dash-toolbar span{font-size:12px;color:#728493}
.cm-dash-toolbar-actions{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.cm-dash-toolbar .btn{font-size:12px;padding:9px 13px}
.cm-dash-hint{margin:0 0 12px;border:1px dashed #98bfd6;border-radius:12px;background:#f0f8fc;padding:10px 14px;color:#24546e;font-size:12px;font-weight:750}
.cm-dashboard-widgets{display:grid;grid-template-areas:"main side-top" "main side-bottom";grid-template-columns:minmax(0,1.85fr) minmax(335px,.92fr);grid-template-rows:minmax(0,1fr) auto;gap:14px;align-items:stretch;margin-bottom:14px}
.cm-dashboard-widgets>.cm-widget:nth-child(1){grid-area:main}
.cm-dashboard-widgets>.cm-widget:nth-child(2){grid-area:side-top}
.cm-dashboard-widgets>.cm-widget:nth-child(3){grid-area:side-bottom}
.cm-dashboard-widgets>.cm-widget{min-width:0;position:relative}
.cm-dash-v2 .cm-widget-map{padding:0;overflow:hidden;display:flex;flex-direction:column}
.cm-dash-v2 .cm-widget-map .focus-card-head{padding:17px 19px 13px}
.cm-dash-v2 .cm-widget-map .focus-card-head h2{font-size:19px}
.cm-dash-v2 .cm-widget-map .focus-fleet-map{border:0;border-radius:0;box-shadow:none;flex:1;min-height:510px;height:min(67vh,720px)}
.cm-dash-v2 .cm-dashboard-widgets>.cm-widget-map:not(:first-child) .focus-fleet-map{height:260px;min-height:240px}
.cm-map-actions{display:flex;gap:8px;align-items:center;padding:0 18px 12px;flex-wrap:wrap}
.cm-map-actions .btn{font-size:11px;padding:7px 10px}
.cm-dash-v2 .cm-widget-list{padding:0;overflow:hidden;display:flex;flex-direction:column}
.cm-dash-v2 .cm-widget-list .focus-card-head{display:grid;grid-template-columns:minmax(0,1fr);gap:10px;padding:17px 16px 12px}
.cm-dash-v2 .cm-widget-list .focus-card-head h2{font-size:18px}
.cm-dash-v2 .cm-widget-list .focus-search{width:100%;min-width:0;max-width:none}
.cm-dash-v2 .cm-widget-list .focus-filter-drawer>summary{padding:9px 16px}
.cm-dash-v2 .cm-widget-list .fleet-filterbar{display:flex;flex-wrap:wrap;gap:8px;padding:12px}
.cm-dash-v2 .cm-widget-list .fleet-filterbar>label{min-width:130px;flex:1}
.cm-dash-v2 .cm-widget-list .fleet-filterbar>label>select{width:100%;min-width:0}
.cm-dash-v2 .cm-widget-list .fleet-filterbar .fleet-clear-btn{margin:auto 0 0}
.cm-quick-fleet{overflow-y:auto;overflow-x:hidden;min-height:140px;max-height:410px;overscroll-behavior:contain;scrollbar-color:#bad3e4 transparent;scrollbar-width:thin}
.cm-dashboard-widgets>.cm-widget-list:first-child .cm-quick-fleet{max-height:610px}
.cm-quick-vehicle{font:inherit;display:grid;grid-template-columns:10px minmax(0,1fr) auto;gap:10px;align-items:center;width:100%;padding:11px 13px;border:0;border-top:1px solid #ecf1f5;border-left:4px solid transparent;background:#fff;text-align:left;color:#244359;cursor:pointer;transition:background .14s}
.cm-quick-vehicle:hover{background:#f5fafe}
.cm-quick-vehicle.is-selected{background:#eaf5fc;border-left-color:#1769aa}
.cm-quick-vehicle:focus-visible{outline:3px solid #559cca;outline-offset:-3px}
.cm-quick-dot{width:9px;height:9px;border-radius:50%;background:#d65d52}
.cm-quick-dot.is-online{background:#20a372}
.cm-quick-dot.is-stale{background:#d99b37}
.cm-quick-dot.is-offline{background:#dc6259}
.cm-quick-vehicle-body{min-width:0;display:grid;gap:4px}
.cm-quick-vehicle-body strong{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:12px;color:#183c56}
.cm-quick-vehicle-body small{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:10px;color:#75899a}
.cm-quick-vehicle-right{text-align:right;min-width:86px;display:grid;gap:4px}
.cm-quick-vehicle-right strong{font-size:12px;color:#173f60}
.cm-quick-vehicle-right small{font-size:9px;color:#73869a;white-space:nowrap}
.cm-quick-empty{padding:30px 12px;text-align:center;color:#6d8090;font-size:12px}
.cm-dash-v2 .cm-widget-selected{align-self:stretch;padding:16px 17px}
.cm-dash-v2 .cm-widget-selected .focus-selected-top h2{font-size:18px}
.cm-dash-v2 .cm-widget-selected .focus-selected-chips{grid-template-columns:repeat(3,minmax(0,1fr));gap:6px;margin:10px 0}
.cm-dash-v2 .cm-widget-selected .focus-selected-chips>span{padding:7px 8px}
.cm-dash-v2 .cm-widget-selected .focus-selected-chips strong{font-size:11px}
.cm-widget-tools{display:none;align-items:center;justify-content:flex-end;gap:5px;background:#eaf5fc;border-bottom:1px solid #d6e7f3;padding:5px 12px;font-size:11px;color:#315c77}
.cm-layout-edit .cm-widget-tools{display:flex}
.cm-widget-handle{margin-right:auto;padding:5px 7px;border-radius:8px;font-weight:850;cursor:grab;user-select:none}
.cm-widget-handle:active{cursor:grabbing}
.cm-widget-move{border:1px solid #c4d9e8;background:#fff;color:#215a7d;border-radius:7px;padding:4px 10px;cursor:pointer;font-weight:850;font-size:13px}
.cm-widget-move:hover{background:#e8f4fa}
.cm-layout-edit .cm-widget{outline:2px dashed #95bcd5;outline-offset:-2px}
.cm-layout-edit .cm-widget.cm-drop-target{outline:3px solid #1769aa;outline-offset:-3px;background:#edf7fd}
.cm-dash-table-details{padding:0;margin:12px 0;overflow:hidden}
.cm-dash-table-details>summary{display:flex;justify-content:space-between;align-items:center;gap:12px;list-style:none;padding:14px 18px;cursor:pointer}
.cm-dash-table-details>summary::-webkit-details-marker{display:none}
.cm-dash-table-details>summary span:first-child{display:grid;gap:4px}
.cm-dash-table-details>summary strong{font-size:14px;color:#173b56}
.cm-dash-table-details>summary small{font-size:11px;color:#788b99}
.cm-dash-table-details[open] .summary-action{font-size:0}
.cm-dash-table-details[open] .summary-action:after{content:"Skr\00fd t";font-size:11px}
.cm-dash-table-details .focus-fleet-table-wrap{min-height:100px;max-height:540px;overflow:auto;border:0;border-top:1px solid #e2ebf1}
.cm-dash-table-details .focus-fleet-table{min-width:950px}
.cm-widget-map.cm-map-expanded{position:fixed;inset:78px 20px 20px;z-index:1300;box-shadow:0 12px 70px rgba(9,26,44,.33)}
.cm-widget-map.cm-map-expanded .focus-fleet-map,.cm-dashboard-widgets>.cm-widget-map.cm-map-expanded:not(:first-child) .focus-fleet-map{height:auto;min-height:0;flex:1}
body.cm-map-lock{overflow:hidden}
@media(max-width:1250px){
  .cm-dashboard-widgets{grid-template-columns:minmax(0,1.25fr) minmax(320px,.95fr)}
  .cm-dash-v2 .cm-widget-map .focus-fleet-map{height:560px;min-height:490px}
}
@media(max-width:970px){
  .cm-dashboard-widgets{grid-template-areas:none;grid-template-columns:minmax(0,1fr);grid-template-rows:auto;gap:12px}
  .cm-dashboard-widgets>.cm-widget:nth-child(n){grid-area:auto;min-height:0}
  .cm-dash-v2 .cm-widget-map .focus-fleet-map,.cm-dash-v2 .cm-dashboard-widgets>.cm-widget-map:not(:first-child) .focus-fleet-map{height:450px;min-height:450px}
  .cm-quick-fleet{max-height:360px}
  .cm-dash-toolbar{align-items:flex-start;flex-direction:column}
}
@media(max-width:580px){
  .cm-dash-v2 .focus-live-page{padding:12px}
  .cm-dash-toolbar-actions{width:100%}
  .cm-dash-toolbar-actions .btn{flex:1;padding:9px}
  .cm-dash-v2 .cm-widget-map .focus-fleet-map,.cm-dash-v2 .cm-dashboard-widgets>.cm-widget-map:not(:first-child) .focus-fleet-map{height:350px;min-height:350px}
  .cm-quick-vehicle{grid-template-columns:9px minmax(0,1fr) auto;gap:7px;padding:10px 8px}
  .cm-quick-vehicle-right{min-width:70px}
  .cm-widget-map.cm-map-expanded{inset:72px 5px 5px}
}
.cm-dash-toolbar-actions [hidden]{display:none!important}

/* v3.13.59 - explicit Mapy.com sharing, never an auth/token link */
.cm-dash-v2 .focus-selected-actions{flex-wrap:wrap}
.cm-dash-v2 .focus-selected-actions .btn{flex:1 1 43%;white-space:normal;text-align:center;min-width:120px;font-size:11px}
.cm-dash-v2 .focus-selected-actions [hidden]{display:none!important}
.cm-dash-v2 .focus-selected-actions .btn:disabled{opacity:.5;cursor:not-allowed}
.cm-map-share-info{font-size:11px;color:#718595;margin:8px 0 0;line-height:1.45}
.cm-table-map-share{display:inline-flex;align-items:center;margin-top:6px;border:0;background:transparent;color:#1769aa;font:inherit;font-size:11px;font-weight:750;padding:3px 0;cursor:pointer;text-align:left}
.cm-table-map-share:hover{text-decoration:underline}
.cm-table-map-share:focus-visible,.cm-map-popup-copy:focus-visible{outline:2px solid #247ab3;outline-offset:3px}
.cm-map-share-popup-actions{display:flex;flex-wrap:wrap;gap:7px;margin-top:10px;align-items:center}
.cm-map-share-popup-actions .cm-map-popup-copy,.cm-map-share-popup-actions a{background:#ecf5fa;border:1px solid #c8deec;color:#125b85;font-family:inherit;font-size:12px;font-weight:700;border-radius:7px;text-decoration:none;cursor:pointer;padding:7px 9px}
.cm-map-share-popup-actions .cm-map-popup-copy:hover,.cm-map-share-popup-actions a:hover{background:#dceefa}
.cm-map-share-coords{font-size:12px;color:#566e82;margin-top:4px;font-variant-numeric:tabular-nums}
@media(max-width:580px){.cm-dash-v2 .focus-selected-actions .btn{flex-basis:100%}}

/* v3.13.62: prominent last-known address, sharing the existing cached reverse geocoder. */
.cm-selected-address{display:grid;gap:5px;padding:11px 12px;border:1px solid #cfe3f0;border-radius:11px;background:#f2f9fe;margin:10px 0}
.cm-selected-address-head{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap}
.cm-selected-address-head>span{font-size:11px;font-weight:850;letter-spacing:.01em;color:#326987}
.cm-selected-address-head>small{font-size:10px;color:#648296;font-weight:700}
.cm-selected-address>strong{display:block;font-size:15px;line-height:1.35;color:#123e5a;overflow-wrap:anywhere}
.cm-selected-address-secondary{display:block;color:#678294;font-size:11px;line-height:1.4;overflow-wrap:anywhere}
.cm-map-popup-address{border-top:1px solid #dce9f2;border-bottom:1px solid #dce9f2;padding:8px 0;margin:8px 0 3px;line-height:1.4}
.cm-map-popup-address .fleet-location-main{font-size:12px;display:block;white-space:normal;overflow-wrap:anywhere}
.cm-map-popup-address .fleet-location-sub{font-size:11px;display:block;white-space:normal;overflow-wrap:anywhere;color:#758b9a}
@media(max-width:580px){.cm-selected-address-head{align-items:flex-start}.cm-selected-address>strong{font-size:14px}}

/* CM v3.13.63 - distinguish movement, stop, GPS age, comm delay and no contact. */
.cm-map-legend{display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;padding:9px 16px;background:#f7fafc;border-top:1px solid #e1ebf3;font-size:10px;font-weight:750;color:#38596f}
.cm-map-legend>span{display:inline-flex;align-items:center;gap:5px;white-space:nowrap}
.cm-map-legend small{color:#6b8192;font-size:10px;font-weight:500;flex-basis:100%}
.cm-map-legend i,.cm-quick-dot{--marker-color:#71859b;display:inline-block;width:10px;height:10px;border-radius:50%;background:var(--marker-color)}
.cm-map-legend .cm-leg-moving,.cm-quick-dot.is-moving{--marker-color:#15945c}
.cm-map-legend .cm-leg-stopped,.cm-quick-dot.is-stopped{--marker-color:#168ac0}
.cm-map-legend .cm-leg-gps-stale,.cm-quick-dot.is-gps-stale{--marker-color:#db9218}
.cm-map-legend .cm-leg-delayed,.cm-quick-dot.is-delayed{--marker-color:#8b8298}
.cm-map-legend .cm-leg-offline,.cm-quick-dot.is-offline{--marker-color:#71859b}
.cm-quick-dot.is-unknown{--marker-color:#b6bec9}
.cm-vehicle-pin{border:0!important;background:transparent!important;display:grid;place-items:center}
.cm-vehicle-pin-body{display:grid;place-items:center;width:34px;height:34px;border:3px solid #fff;box-shadow:0 2px 12px #203b5260;border-radius:13px;transform:rotate(0deg);color:white;background:var(--pin-color,#8191a1);transition:transform .12s}
.cm-vehicle-pin:hover .cm-vehicle-pin-body{transform:scale(1.13)}
.cm-vehicle-pin.cm-pin-selected{z-index:1000!important}
.cm-vehicle-pin.cm-pin-selected .cm-vehicle-pin-body{outline:3px solid #1b69ab;outline-offset:2px;width:39px;height:39px}
.cm-pin-moving{--pin-color:#15945c}.cm-pin-stopped{--pin-color:#168ac0}.cm-pin-gps-stale{--pin-color:#db9218}.cm-pin-delayed{--pin-color:#8b8298}.cm-pin-offline{--pin-color:#71859b}.cm-pin-unknown{--pin-color:#b6bec9}
.cm-fleet-state{display:inline-flex;align-items:center;gap:5px;max-width:100%;padding:4px 7px;border:1px solid transparent;border-radius:7px;font-size:10px;font-weight:800;letter-spacing:0;line-height:1.25;white-space:normal}
.cm-fleet-state>i{display:inline-block;width:7px;height:7px;flex:none;border-radius:50%;background:currentColor}
.cm-state-moving{color:#086d48;background:#e8f7ee;border-color:#cfecdc}.cm-state-stopped{color:#176a90;background:#e6f5fc;border-color:#c8e6f5}
.cm-state-gps-stale{color:#986100;background:#fff5df;border-color:#f2dfad}.cm-state-delayed{color:#675875;background:#f4f0f8;border-color:#e3daec}
.cm-state-offline{color:#506678;background:#edf1f5;border-color:#dbe3ea}.cm-state-unknown{color:#7d8792;background:#f2f3f5;border-color:#e4e8ed}
.cm-quick-vehicle-right{min-width:108px;max-width:145px}.cm-quick-vehicle-right small{white-space:normal;line-height:1.2}
.cm-dash-v2 .focus-selected-chips .cm-fleet-state{font-size:10px;padding:3px 5px}.cm-dash-v2 .focus-selected-chips span:first-child{min-width:0}
.cm-selected-state-explainer{font-size:11px;line-height:1.45;margin:8px 0;padding:10px 12px;border-radius:9px;background:#f3f7fa;color:#48647c;border-left:3px solid #9eafbd}
.cm-alert-moving{border-left-color:#15945c}.cm-alert-stopped{border-left-color:#168ac0}.cm-alert-gps-stale{border-left-color:#db9218}.cm-alert-delayed{border-left-color:#8b8298}
.cm-popup-status-note{font-size:11px;color:#536779;line-height:1.35;margin:5px 0}
.cm-address-map-link{display:inline-flex;align-items:center;gap:6px;text-decoration:none;color:#123e5a;font-size:15px;line-height:1.35;overflow-wrap:anywhere}
.cm-address-map-link:hover{text-decoration:underline;color:#1769aa}.cm-address-map-link[aria-disabled=true]{pointer-events:none;text-decoration:none}
.cm-copy-address-btn{font:inherit;font-size:11px;border:0;padding:2px 0;color:#1769aa;font-weight:750;background:transparent;cursor:pointer;text-align:left;justify-self:start}
.cm-copy-address-btn:hover{text-decoration:underline}.cm-copy-address-btn:disabled{opacity:.4;cursor:not-allowed}
@media(max-width:580px){.cm-map-legend{gap:7px 10px}.cm-quick-vehicle-right{min-width:84px;max-width:105px}}

.cm-pin-gps-no-speed{--pin-color:#6e98b9}.cm-quick-dot.is-gps-no-speed{--marker-color:#6e98b9}.cm-state-gps-no-speed{color:#365f7e;background:#edf5fb;border-color:#d5e7f2}

.cm-quick-dot.is-offline{background:#71859b}

/* v3.13.66: distinguish previously recorded movement in all dashboard widgets. */
.cm-quick-dot.is-last-moving,.cm-map-legend .cm-leg-last-moving{--marker-color:#d79a30}
.cm-pin-last-moving{--pin-color:#d79a30}
.cm-state-last-moving{color:#916010;background:#fff7e8;border-color:#efdcb7}
.cm-alert-last-moving{border-left-color:#d79a30}
