/* dev17-vehicle4 — map-first single vehicle experience */
#vehicleDetailView{padding-bottom:28px}
.sf-vehicle-detail-shell{padding:24px!important;overflow:hidden}
.sf-vehicle-detail-shell>.sf-vehicle-hero{margin-bottom:10px;padding:13px 16px;gap:14px;box-shadow:none}.sf-vehicle-detail-shell .sf-vehicle-hero-icon{width:66px;height:66px}.sf-vehicle-detail-shell .sf-vehicle-hero-icon img{width:62px;height:62px}.sf-vehicle-detail-shell .sf-vehicle-hero-main h3{font-size:21px}.sf-vehicle-detail-shell .sf-vehicle-hero-chips{margin-top:7px}.sf-vehicle-detail-shell .sf-vehicle-hero-actions{display:none}
.sf-vehicle-detail-shell>.sf-vehicle-detail-actions{justify-content:flex-end;margin:0 0 8px!important;padding:0!important;border:0!important;min-height:0}.sf-vehicle-detail-shell>.sf-vehicle-detail-actions .sf-vehicle-title-legacy{display:none}
.sf-vehicle-meta{grid-template-columns:repeat(3,minmax(0,1fr));margin:12px 18px 0}
.sf-vehicle-meta .telemetry-card{min-height:72px;padding:12px 14px}
.sf-vehicle-meta .telemetry-card span{font-size:9px}.sf-vehicle-meta .telemetry-card strong{font-size:13px}
.sf-detail-fuel-link{margin:12px 18px 0}.sf-vehicle-status-section #detailFuelSummary{grid-template-columns:repeat(3,minmax(0,1fr));margin:12px 18px 0;gap:10px}.sf-vehicle-status-section #detailFuelSummary .telemetry-card{min-height:70px;padding:11px 12px}
.sf-vehicle-detail-shell>.vehicle-tabs{margin:0 0 16px}
.sf-vehicle-live-panel,.sf-vehicle-history-panel{display:grid;gap:18px}
.sf-vehicle-map-focus,.sf-history-map-focus,.sf-vehicle-status-section,.sf-trip-list-section{border:1px solid var(--sf-line,#dce8ea);border-radius:18px;background:#fff;overflow:hidden}
.sf-detail-section-head{display:flex;align-items:center;justify-content:space-between;gap:18px;padding:16px 18px;border-bottom:1px solid var(--sf-line,#dce8ea)}
.sf-detail-section-head.compact{padding:14px 18px}.sf-detail-section-head h4{margin:2px 0 0;font-size:17px}.sf-detail-section-head p{margin:4px 0 0;color:#607780;font-size:12px}
.sf-live-view-switch{flex:none}.sf-live-view-switch button{min-width:96px}.sf-live-view-switch button[aria-pressed="true"]{background:#e9f6f6;color:#146970;border-color:#b8dddd}
.sf-vehicle-map-stage{position:relative;background:#eaf2f4;min-height:560px}
#vehicleMap{height:560px!important;min-height:560px!important;border:0!important;border-radius:0!important}
.sf-follow-hud{position:absolute;left:18px;bottom:18px;z-index:3;display:flex;align-items:center;gap:12px;max-width:min(520px,calc(100% - 36px));padding:12px 14px;border:1px solid rgba(255,255,255,.42);border-radius:17px;background:rgba(20,31,36,.88);box-shadow:0 14px 36px rgba(12,30,37,.25);backdrop-filter:blur(14px);color:#fff}
.sf-follow-hud.hidden{display:none}.sf-follow-hud strong{font-size:27px;line-height:1;font-variant-numeric:tabular-nums}.sf-follow-hud .sf-follow-speed{display:flex;align-items:baseline;gap:4px;min-width:92px}.sf-follow-hud .sf-follow-speed span{font-size:11px;color:#cbd9dc}.sf-follow-hud .sf-follow-copy{display:grid;gap:2px;padding-left:12px;border-left:1px solid #ffffff2e}.sf-follow-hud .sf-follow-copy b{font-size:12px}.sf-follow-hud .sf-follow-copy span{font-size:10px;color:#cbd9dc}
.sf-vehicle-map-stage.sf-following:after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(180deg,rgba(10,25,32,.05),transparent 34%,rgba(10,25,32,.14));z-index:1}.sf-vehicle-map-stage.sf-following:before{content:"FOLLOW";position:absolute;right:16px;bottom:16px;z-index:2;padding:6px 9px;border-radius:999px;background:rgba(20,31,36,.72);color:#fff;font-size:9px;font-weight:850;letter-spacing:.1em;backdrop-filter:blur(10px);pointer-events:none}.sf-vehicle-map-stage.sf-follow-paused:before{content:"FOLLOW PAUSED · CLICK FOLLOW TO RECENTER";position:absolute;right:16px;bottom:16px;z-index:2;padding:6px 9px;border-radius:999px;background:rgba(20,31,36,.72);color:#fff;font-size:9px;font-weight:850;letter-spacing:.06em;backdrop-filter:blur(10px);pointer-events:none}
#vehicleLiveContextHost{padding:14px 16px;background:#fbfdfd;border-top:1px solid var(--sf-line,#dce8ea)}
#vehicleLiveContextHost .live-context{display:grid;grid-template-columns:repeat(2,minmax(0,1fr)) auto;gap:7px 18px;align-items:center;margin:0;padding:0;border:0;background:transparent}
#vehicleLiveContextHost .live-context p{margin:0;color:#4e6871;font-size:11px;line-height:1.45}
#vehicleLiveContextHost .live-context button{margin:0}.sf-vehicle-status-section{padding-bottom:16px}.sf-vehicle-status-section #vehicleTelemetry{grid-template-columns:repeat(6,minmax(0,1fr));padding:16px 18px 0}.sf-vehicle-status-section .telemetry-card{min-height:80px;padding:12px}.sf-vehicle-status-section .telemetry-card span{font-size:9px}.sf-vehicle-status-section .telemetry-card strong{font-size:16px}

/* History: map first, data second */
.sf-history-toolbar{display:flex;align-items:end;gap:10px;flex-wrap:wrap;padding:12px 14px;border:1px solid var(--sf-line,#dce8ea);border-radius:14px;background:#f8fbfc}.sf-history-toolbar input{width:190px}.sf-history-toolbar .subtle{margin-left:auto}
#historyMap{height:500px!important;min-height:500px!important;border:0!important;border-radius:0!important}
.sf-history-map-focus .playback-controls{margin:0;padding:12px 16px;border-top:1px solid var(--sf-line,#dce8ea);background:#fbfdfd}
.sf-history-map-focus .playback-controls input[type="range"]{flex:1;min-width:180px}
.sf-history-summary{grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}.sf-history-summary .telemetry-card{min-height:72px;padding:11px 13px}.sf-history-summary .telemetry-card span{font-size:9px}.sf-history-summary .telemetry-card strong{font-size:15px}
.sf-trip-list-section{padding-bottom:14px}.sf-history-table{margin:0 14px;max-width:calc(100% - 28px)}.sf-history-table table{font-size:12px}.sf-history-table th{padding:11px 10px}.sf-history-table td{padding:12px 10px}.sf-history-table .trip-street{min-width:250px;max-width:360px}.sf-history-table .trip-number{color:#146970}.sf-history-table .show-trip{white-space:nowrap}
.sf-stop-card{width:240px;padding:4px 2px 2px;color:#1e3037}.sf-stop-card-head{display:flex;align-items:center;gap:10px;margin-bottom:9px}.sf-stop-badge{width:44px;height:44px;display:grid;place-items:center;flex:none;clip-path:polygon(30% 0,70% 0,100% 30%,100% 70%,70% 100%,30% 100%,0 70%,0 30%);background:#d9413b;color:#fff;font-size:9px;font-weight:900;letter-spacing:.04em;border:2px solid #fff;box-shadow:0 0 0 1px #b62d29}.sf-stop-card h4{margin:0;font-size:14px}.sf-stop-card .sf-stop-duration{color:#607780;font-size:11px}.sf-stop-card p{margin:7px 0 0;font-size:11px;line-height:1.45}.sf-stop-card small{display:block;color:#78909a;margin-top:5px}

/* Vehicle editor */
.sf-vehicle-settings-dialog{width:min(760px,94vw);padding:0!important;overflow:hidden}.sf-vehicle-settings-dialog form{padding:22px}.sf-vehicle-settings-head{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;padding:22px;border-bottom:1px solid var(--sf-line,#dce8ea);background:#f8fbfc}.sf-vehicle-settings-head h3{margin:2px 0 4px}.sf-vehicle-settings-head p{margin:0;color:#607780;font-size:12px}.sf-vehicle-settings-head button{min-width:42px;padding:8px}.sf-vehicle-settings-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px 16px}.sf-vehicle-settings-icon{display:grid;grid-template-columns:96px minmax(0,1fr);gap:16px;align-items:center;margin:16px 0;padding:14px;border:1px solid var(--sf-line,#dce8ea);border-radius:14px;background:#f8fbfc}.sf-vehicle-settings-icon img{width:88px;height:88px}.sf-odometer-setting{margin-top:18px;padding-top:18px;border-top:1px solid var(--sf-line,#dce8ea)}.sf-odometer-setting .sf-odometer-readout{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin:10px 0 14px}.sf-odometer-readout div{padding:11px 12px;border:1px solid var(--sf-line,#dce8ea);border-radius:12px;background:#f8fbfc}.sf-odometer-readout span{display:block;font-size:9px;color:#607780;text-transform:uppercase;letter-spacing:.05em}.sf-odometer-readout strong{display:block;margin-top:3px}.sf-vehicle-settings-actions{display:flex;justify-content:flex-end;gap:10px;margin-top:18px}.sf-edit-vehicle{margin-left:6px}

/* Documents & installation share the same quiet card language */
.document-panel,.installation-panel{padding:4px 0 0!important}.sf-document-head{display:flex;justify-content:space-between;gap:18px;align-items:flex-start;padding:16px 0;border-bottom:1px solid var(--sf-line,#dce8ea)}.sf-document-head p{margin:4px 0 0;color:#607780;font-size:12px}.sf-document-uploader{display:grid;grid-template-columns:minmax(180px,.65fr) minmax(280px,1.35fr) auto;gap:12px;align-items:end;margin:18px 0;padding:16px;border:1px solid var(--sf-line,#dce8ea);border-radius:14px;background:#f8fbfc}.sf-document-uploader label{margin:0}.sf-document-list{display:grid;gap:10px}.sf-document-card{display:flex;align-items:center;gap:12px;padding:13px 14px;border:1px solid var(--sf-line,#dce8ea);border-radius:14px;background:#fff}.sf-document-icon{width:38px;height:38px;display:grid;place-items:center;border-radius:11px;background:#eaf6f6;color:#146970;font-weight:850}.sf-document-copy{min-width:0;flex:1}.sf-document-copy strong,.sf-document-copy small{display:block}.sf-document-copy strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.sf-document-copy small{color:#607780;margin-top:2px}.sf-document-actions{display:flex;gap:8px}.installation-panel .installation-head{padding-top:12px}.installation-panel #installationSummary{grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.installation-panel #installationSummary .telemetry-card{min-height:78px}.installation-record{box-shadow:none!important}

@media(max-width:1100px){.sf-vehicle-status-section #vehicleTelemetry{grid-template-columns:repeat(3,minmax(0,1fr))}.sf-vehicle-status-section #detailFuelSummary{grid-template-columns:repeat(3,minmax(0,1fr))}.sf-history-summary{grid-template-columns:repeat(3,minmax(0,1fr))}.sf-document-uploader{grid-template-columns:1fr 1fr}.sf-document-uploader button{grid-column:1/-1}.installation-panel #installationSummary{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.sf-vehicle-detail-shell{padding:14px!important}.sf-vehicle-detail-shell>.sf-vehicle-detail-actions{margin-bottom:6px!important}.sf-vehicle-meta{grid-template-columns:1fr;margin:10px 12px 0}.sf-detail-section-head{align-items:flex-start;flex-direction:column}.sf-live-view-switch{width:100%}.sf-live-view-switch button{flex:1}.sf-vehicle-map-stage,#vehicleMap{min-height:430px!important;height:430px!important}.sf-follow-hud{left:10px;bottom:10px;max-width:calc(100% - 20px)}#vehicleLiveContextHost .live-context{grid-template-columns:1fr}.sf-vehicle-status-section #vehicleTelemetry,.sf-history-summary{grid-template-columns:repeat(2,minmax(0,1fr))}.sf-vehicle-status-section #detailFuelSummary{grid-template-columns:1fr;margin:10px 12px 0}.sf-detail-fuel-link{margin:10px 12px 0}.sf-history-toolbar input{width:100%}.sf-history-toolbar .subtle{width:100%;margin-left:0}#historyMap{height:410px!important;min-height:410px!important}.sf-vehicle-settings-grid,.sf-document-uploader{grid-template-columns:1fr}.sf-vehicle-settings-icon{grid-template-columns:72px 1fr}.sf-vehicle-settings-icon img{width:68px;height:68px}.sf-odometer-setting .sf-odometer-readout{grid-template-columns:1fr}.sf-document-card{align-items:flex-start;flex-wrap:wrap}.sf-document-actions{width:100%}.installation-panel #installationSummary{grid-template-columns:1fr}}
