/* 沉浸式作业总览：地图连续铺底，文字与操作保持不透明。 */
body.monitor-compact .monitor-page {
  --scene-left:236px; --scene-right:268px; --scene-ui-top:82px; --scene-bottom:38px;
}
body.monitor-compact .monitor-page,
body.monitor-compact .monitor-page.single {
  position:relative; isolation:isolate; padding:12px; gap:12px; background:#020b1d;
}
body.monitor-compact .monitor-page .monitor-grid,
body.monitor-compact .monitor-page.single .monitor-grid {
  position:static; grid-template-columns:212px minmax(0,1fr) 244px;
  gap:12px; pointer-events:none; z-index:auto;
}
body.monitor-compact .monitor-page .map-panel {
  position:absolute; inset:0; z-index:0; width:100%; height:100%;
  border:0; border-radius:0; box-shadow:none; background:#020b1d;
  backdrop-filter:none; -webkit-backdrop-filter:none; pointer-events:auto;
}
body.monitor-compact .map-panel::after {
  content:""; position:absolute; inset:0; z-index:3; pointer-events:none;
  background:linear-gradient(180deg,#010819d6 0,transparent 130px,transparent calc(100% - 65px),#010819eb),
    linear-gradient(90deg,#02091c8f 0,transparent 31%,transparent 72%,#02091c8f 100%);
}
body.monitor-compact .monitor-stats,
body.monitor-compact .monitor-notice,
body.monitor-compact .monitor-strip,
body.monitor-compact .operation-info { position:relative; z-index:15; }
body.monitor-compact .monitor-stats { gap:18px; height:58px; flex-basis:58px; }
body.monitor-compact .monitor-stats .metric {
  position:relative; gap:13px; border:0; border-bottom:1px solid #4e94cd66;
  border-radius:0; padding:6px 16px;
  background:linear-gradient(90deg,#03112ef2,#071a39d9 72%,#07142bc4);
  backdrop-filter:blur(4px); -webkit-backdrop-filter:blur(4px);
  box-shadow:0 9px 25px #02101a25;
}
body.monitor-compact .monitor-stats .metric::after {
  content:""; position:absolute; right:0; bottom:-1px; width:30px; height:2px;
  background:linear-gradient(90deg,transparent,#69c4ff); pointer-events:none;
}
body.monitor-compact .metric-icon {
  width:38px; height:38px; flex-basis:38px; background:#0c24525c;
  border:1px solid #5894cd5c; border-radius:3px; color:#7acfff;
  transform:skewY(-4deg); box-shadow:inset 0 0 16px #1a5a941c;
}
body.monitor-compact .metric-icon svg { transform:skewY(4deg); }
body.monitor-compact .metric label { color:#aec5e3; font-size:11px; letter-spacing:.5px; }
body.monitor-compact .metric strong {
  font-family:Bahnschrift,"Microsoft YaHei UI",sans-serif; font-size:28px;
  font-weight:600; color:#e8f3ff; text-shadow:0 0 20px #459ed42b;
}
body.monitor-compact .metric small { font-family:"Microsoft YaHei UI",sans-serif; font-size:11px; color:#aac0dc; }
body.monitor-compact .fleet-panel,
body.monitor-compact .relation-panel {
  position:relative; z-index:20; pointer-events:auto; border:0;
  border-top:1px solid #5a9ed063; border-bottom:1px solid #4d7ca63d;
  border-radius:2px; background:linear-gradient(110deg,#06142de0,#020b20db);
  backdrop-filter:blur(5px); -webkit-backdrop-filter:blur(5px);
  box-shadow:0 8px 30px #00101c38;
}
body.monitor-compact .fleet-panel { grid-column:1; }
body.monitor-compact .relation-panel { grid-column:3; }
body.monitor-compact .fleet-panel::before,
body.monitor-compact .relation-panel::before {
  content:""; position:absolute; top:-1px; left:0; width:30px; height:2px;
  background:#66c3f5; box-shadow:0 0 9px #3a9dda3d; z-index:3; pointer-events:none;
}
body.monitor-compact .panel-head {
  background:linear-gradient(90deg,#183d6657,#10275124 80%);
  border-bottom-color:#7eade32e; min-height:40px; letter-spacing:.4px;
}
body.monitor-compact .fleet-tools { background:#030c201a; padding-block:10px; }
body.monitor-compact .fleet-tools input,
body.monitor-compact .fleet-tools select { background:#020d25e6; border-color:#477ba86b; }
body.monitor-compact .fleet-row { border-radius:0; border-bottom-color:#77a7d32b; }
body.monitor-compact .fleet-row:hover { background:#244e7c40; }
body.monitor-compact .fleet-row.active { background:linear-gradient(90deg,#14416f99,#10285470); border-color:transparent; border-left-color:#65c5ff; }
body.monitor-compact .fleet-row-main strong { font-weight:500; letter-spacing:.2px; }
body.monitor-compact .fleet-readings { color:#b1c6e1; }
body.monitor-compact .fleet-pagination,
body.monitor-compact .selected-footer { background:#030d23c4; border-top-color:#7193be2b; }
body.monitor-compact .selected-summary strong { font-family:Bahnschrift,"Microsoft YaHei UI",sans-serif; font-size:27px; color:#e9f3ff; }
body.monitor-compact .selected-summary label,
body.monitor-compact .location-caption,
body.monitor-compact .field-caption { color:#acbfdc; }
body.monitor-compact .relation-section h3 { color:#c0d8f4; font-weight:500; }
body.monitor-compact .truck-card {
  border:0; border-left:2px solid #61baf18c; border-radius:0;
  background:linear-gradient(90deg,#102c528a,#08183066); box-shadow:none;
}
body.monitor-compact .truck-card.gold { border-left-color:#f0c471b3; background:linear-gradient(90deg,#49382066,#261c1433); }
body.monitor-compact .truck-card.blue { border-left-color:#80b9ffb3; background:linear-gradient(90deg,#16365c80,#0b214b44); }
body.monitor-compact .truck-card-bottom { color:#bdcde2; }
body.monitor-compact .load-track { background:#020b20ed; height:4px; }
body.monitor-compact .load-bar-row strong { font-family:Bahnschrift,"Microsoft YaHei UI",sans-serif; }
body.monitor-compact .relation-empty { border-color:#5573985c; background:#05122a80; }
body.monitor-compact .map-toolbar { left:var(--scene-left); top:var(--scene-ui-top); }
body.monitor-compact .map-tools-top { right:var(--scene-right); top:var(--scene-ui-top); }
body.monitor-compact .map-overlay-title { left:var(--scene-left); top:calc(var(--scene-ui-top) + 42px); background:#030d24e6; border-left:2px solid #5faee38a; border-radius:0; padding:4px 9px; }
body.monitor-compact .map-toolbar .btn,
body.monitor-compact .map-tools-top .btn,
body.monitor-compact .map-controls .btn {
  border-radius:3px; border-color:#6795c570; background:#07182eea;
  backdrop-filter:blur(5px); -webkit-backdrop-filter:blur(5px); box-shadow:0 2px 8px #0003;
}
body.monitor-compact .map-toolbar .btn[aria-pressed="true"],
body.monitor-compact .map-controls .btn.primary { background:#15528eed; border-color:#6ac6fa; color:#eff7ff; }
body.monitor-compact .map-controls { right:var(--scene-right); bottom:calc(98px + var(--scene-info-height,0px)); }
body.monitor-compact .map-bottom { left:var(--scene-left); right:var(--scene-right); bottom:calc(64px + var(--scene-info-height,0px)); }
body.monitor-compact .map-bottom span { border:1px solid #6f92ba47; background:#020c20eb; border-radius:2px; }
body.monitor-compact .map-panel .amap-logo { left:var(--scene-left)!important; bottom:calc(36px + var(--scene-info-height,0px))!important; }
body.monitor-compact .map-panel .amap-copyright { left:calc(var(--scene-left) + 62px)!important; bottom:calc(36px + var(--scene-info-height,0px))!important; max-width:calc(100% - var(--scene-left) - var(--scene-right) - 62px); color:#f2f6f8; text-shadow:0 1px 2px #000; }
body.monitor-compact .monitor-strip {
  flex-basis:20px; min-height:20px; padding:0 2px; border:0; color:#b8d4e7;
  background:transparent; font-size:11px;
}
body.monitor-compact .operation-info { background:#06223bcc; border:1px solid #629fc757; border-radius:2px; }
body.monitor-compact .map-fallback { background:radial-gradient(ellipse at 50% 50%,#17476466,#071b32),#071b32; padding:150px calc(var(--scene-right) + 15px) 90px calc(var(--scene-left) + 15px); }
body.monitor-compact .map-marker.contextual .map-marker-symbol { width:27px; height:27px; border-color:#8aaacbbb; background:#0b1a32db; color:#c6d8e9; border-radius:50%; }
body.monitor-compact .map-marker.contextual .map-marker-symbol svg { width:19px; height:19px; }
body.monitor-compact .map-marker.related .map-marker-symbol { background:#0e2b50ee; border-width:1.5px; }
body.monitor-compact .map-marker.selected .map-marker-symbol { width:39px; height:39px; background:#103763f5; border-color:#85d3ff; box-shadow:0 0 0 5px #539cdd26,0 0 18px #4fa9ea38; }
body.monitor-compact .map-cluster { width:34px; height:34px; border-width:3px; color:#c6e5ff; background:#103365e6; border-color:#4d95cf8c; font-size:13px; box-shadow:0 0 0 4px #14345438; }
body.monitor-compact .monitor-page.focus-map { --scene-left:12px; --scene-right:12px; }
body.monitor-compact .monitor-page.focus-map .monitor-grid { grid-template-columns:minmax(0,1fr); }
/* 错误提示占用流内空间，不遮挡当前状态或设备选择。 */
body.monitor-compact .monitor-notice:not(:empty) { margin-bottom:0; }
body.monitor-compact .monitor-notice .error-banner { background:#472735ed; }
@media(min-width:1680px){
  body.monitor-compact .monitor-page { --scene-left:252px; --scene-right:288px; }
  body.monitor-compact .monitor-page .monitor-grid,body.monitor-compact .monitor-page.single .monitor-grid { grid-template-columns:228px minmax(0,1fr) 264px; }
}
@media(max-width:1199px){
  body.monitor-compact .monitor-page { --scene-left:12px; }
  body.monitor-compact .monitor-page .monitor-grid,body.monitor-compact .monitor-page.single .monitor-grid { grid-template-columns:minmax(0,1fr) 244px; }
  body.monitor-compact .relation-panel { grid-column:2; }
  body.monitor-compact .monitor-page.fleet-open:not(.focus-map) .fleet-panel {
    position:absolute; inset:calc(var(--scene-ui-top) + 42px) auto calc(62px + var(--scene-info-height,0px)) 12px;
    z-index:40; width:min(280px,calc(100% - 44px)); height:auto;
    background:#030d24f2; box-shadow:12px 0 35px #00111e66;
  }
}
@media(max-width:799px){
  body.monitor-compact .monitor-page { --scene-left:10px; --scene-right:10px; --scene-ui-top:78px; padding:10px; gap:10px; }
  body.monitor-compact .monitor-page .monitor-grid,body.monitor-compact .monitor-page.single .monitor-grid { grid-template-columns:minmax(0,1fr); }
  body.monitor-compact .monitor-stats { gap:10px; }
  body.monitor-compact .monitor-stats .metric { padding:6px 8px; gap:6px; }
  body.monitor-compact .metric-icon { flex-basis:26px; width:26px; height:30px; }
  body.monitor-compact .metric-icon svg { width:22px; height:22px; }
  body.monitor-compact .metric strong { font-size:23px; }
  body.monitor-compact .monitor-page.relations-open:not(.focus-map) .relation-panel {
    position:absolute; inset:calc(var(--scene-ui-top) + 42px) 10px calc(62px + var(--scene-info-height,0px)) auto;
    z-index:40; width:min(280px,calc(100% - 44px)); height:auto;
    background:#030d24f2; box-shadow:-12px 0 35px #00111e66;
  }
  body.monitor-compact .monitor-page.fleet-open .map-controls,
  body.monitor-compact .monitor-page.relations-open .map-controls,
  body.monitor-compact .monitor-page.fleet-open .map-tools-top,
  body.monitor-compact .monitor-page.relations-open .map-tools-top { display:none; }
}
@media(max-width:649px){
  body.monitor-compact .monitor-page { --scene-ui-top:132px; }
  body.monitor-compact .monitor-stats { height:112px; flex-basis:112px; gap:8px 12px; }
  body.monitor-compact .metric-icon { width:33px; flex-basis:33px; height:33px; }
  body.monitor-compact .monitor-stats .metric { padding:6px 10px; gap:9px; }
  body.monitor-compact .map-tools-top { top:calc(var(--scene-ui-top) + 42px); }
  body.monitor-compact .map-overlay-title { max-width:calc(100% - 126px); }
  body.monitor-compact .map-panel .amap-copyright { font-size:9px; }
  body.monitor-compact .monitor-strip { font-size:10px; }
  body.monitor-compact .map-fallback { padding:200px 20px 70px; }
}
@media(max-height:560px) and (min-width:650px){
  body.monitor-compact .monitor-page { --scene-ui-top:72px; }
  body.monitor-compact .monitor-stats { height:50px; flex-basis:50px; }
  body.monitor-compact .map-controls { display:flex; right:var(--scene-right); bottom:calc(98px + var(--scene-info-height,0px)); }
  body.monitor-compact .map-overlay-title { display:none; }
}
@media(prefers-reduced-transparency:reduce){
  body.monitor-compact .fleet-panel,body.monitor-compact .relation-panel { background:#04112a; backdrop-filter:none; }
}
@media(max-height:800px) and (min-width:650px){
  body.monitor-compact .monitor-page.single .map-controls { display:flex; flex-direction:row; gap:5px; }
}
/* 长设备名保留完整提示，避免挤压状态标签和关闭入口。 */
body.monitor-compact .relation-panel > .panel-head h2 { min-width:0; flex:1; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
body.monitor-compact .relation-panel > .panel-head .badge,
body.monitor-compact .relation-panel > .panel-head .relation-close { flex-shrink:0; }
