:root {
  --ink: #242938; --muted: #788091; --blue: #5964e6; --teal: #109b7c;
  --line: #e8eaf0; --bg: #f6f7fa; --danger: #cf4961; --sidebar: 196px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", system-ui, sans-serif;
  font-size: 13px; color: var(--ink); font-synthesis: none;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); line-height: 1.6; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 36px; padding: 8px 13px;
  border: 1px solid #e0e4eb; border-radius: 8px; background: #fff; color: var(--ink); cursor: pointer;
  white-space: nowrap; font-weight: 500; transition: background .16s, border-color .16s, box-shadow .16s; }
button:hover { background: #f4f5fd; border-color: #c8cef3; }
button:disabled { opacity: .45; cursor: not-allowed; box-shadow: none; }
:is(button, input, select, textarea, summary, a, [tabindex]):focus-visible { outline: 3px solid #8993f6; outline-offset: 3px; }
button.primary { background: var(--blue); border-color: var(--blue); color: #fff; box-shadow: 0 3px 8px #5964e618; }
button.primary:hover { background: #4652d4; }
button.small { min-height: 29px; padding: 5px 10px; font-size: 12px; }
button.text { min-height: 28px; padding: 4px 3px; background: transparent; border: 0; color: var(--blue); box-shadow: none; font-size: 12px; }
button.danger { border-color: #f0cfd6; color: #bd3450; background: #fff7f9; }
button.danger:hover { background: #ffeaf0; }
button.danger-text { color: var(--danger); }
button.icon-button { width: 33px; height: 33px; min-height: 33px; padding: 6px; flex: none; }
button.full { width: 100%; }
.icon { display: inline-block; width: 18px; height: 18px; flex: none; vertical-align: middle; }
button .icon { width: 16px; height: 16px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 25px; line-height: 1.4; letter-spacing: -.04em; font-weight: 680; }
h2 { font-size: 14px; font-weight: 650; }
h3 { font-size: 13px; }
strong { font-weight: 600; }
.muted { font-size: 12px; color: var(--muted); line-height: 1.65; }
.accent { color: var(--blue); font-weight: 600; }
.mono { font-family: Inter, "SFMono-Regular", Consolas, monospace; font-variant-numeric: tabular-nums; letter-spacing: -.2px; }
.eyebrow { font-size: 10px; letter-spacing: .12em; color: var(--muted); margin-bottom: 4px; }
.brand { display: flex; align-items: center; gap: 11px; white-space: nowrap; }
.brand-mark { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 11px; background: #5964e6; color: white; }
.brand-mark .icon { width: 25px; height: 25px; }
.brand > div { display: flex; flex-direction: column; line-height: 1.35; }
.brand strong { font-size: 19px; font-weight: 750; letter-spacing: -.6px; }
.brand > div > span { font-size: 10px; color: var(--muted); letter-spacing: .06em; margin-top: 2px; }
.topbar { position: fixed; inset: 0 0 auto; z-index: 1100; height: 68px; display: flex; align-items: center; padding: 0 26px;
  background: #fffffff5; border-bottom: 1px solid var(--line); gap: 32px; backdrop-filter: blur(12px); }
.top-brand { width: calc(var(--sidebar) - 20px); flex: none; display: flex; gap: 12px; align-items: center; }
.top-breadcrumb { display: flex; align-items: center; gap: 10px; color: #a0a5b1; font-size: 12px; }
.top-breadcrumb > span { color: #555d70; }
.top-breadcrumb .icon { width: 12px; height: 12px; }
.top-meta { margin-left: auto; display: flex; align-items: center; gap: 19px; }
#stream-state { color: #697486; font-size: 11px; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #18ad8f; flex: none; }
.dot.offline { background: #a5adbb; }
.account { display: flex; align-items: center; gap: 9px; padding-left: 18px; border-left: 1px solid var(--line); }
.account > div { display: flex; flex-direction: column; line-height: 1.4; }
.account strong { font-size: 12px; }
.account > div > span { font-size: 10px; color: var(--muted); }
.avatar { width: 32px; height: 32px; display: inline-grid; place-items: center; background: #eeeffd; color: var(--blue); border-radius: 10px; flex: none; font-size: 13px; }
.sidebar { position: fixed; top: 68px; left: 0; bottom: 0; z-index: 1050; width: var(--sidebar); padding: 25px 14px 15px;
  background: #191e30; display: flex; flex-direction: column; overflow: auto; }
.nav-section { color: #747d99; font-size: 10px; letter-spacing: .08em; padding: 0 14px; margin: 4px 0 10px; }
.nav-section:not(:first-child) { margin-top: 25px; }
.nav-button { width: 100%; min-height: 42px; border: 0; padding: 10px 14px; margin: 2px 0; justify-content: flex-start; gap: 12px;
  color: #a4adc4; background: transparent; font-size: 12px; font-weight: 450; }
.nav-button:hover { background: #242b43; color: white; }
.nav-button.active { background: #5964e6; color: #fff; box-shadow: 0 4px 14px #10142733; }
.nav-button > .icon { width: 17px; height: 17px; }
.nav-count { margin-left: auto; border-radius: 5px; padding: 0 5px; background: #df7183; color: #fff; font-size: 10px; }
.sidebar-foot { margin-top: auto; padding: 28px 12px 0; color: #8994ad; }
.sidebar-device { display: flex; align-items: center; gap: 8px; padding-bottom: 14px; margin-bottom: 14px; border-bottom: 1px solid #2b3147; font-size: 11px; }
.sidebar-device .icon { width: 14px; }
.deployment-label { display: flex; align-items: center; gap: 7px; font-size: 11px; }
.version { display: block; margin-top: 5px; font-size: 9px; color: #65708d; }
.mobile-menu, .nav-scrim { display: none; }
.workspace { margin: 68px 0 0 var(--sidebar); padding: 27px 28px 40px; min-width: 0; outline: none; }
.workspace > * { max-width: 1800px; margin-left: auto; margin-right: auto; }
.pagehead { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 23px; }
.pagehead .muted { margin-top: 4px; }
.actions, .button-row, .row { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.actions { justify-content: flex-end; }
.button-row { gap: 9px; }
.row { justify-content: space-between; }
.live-timestamp { font-size: 11px; color: #8990a1; margin-right: 4px; font-variant-numeric: tabular-nums; }
.stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin-bottom: 22px; }
.stats.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.stat { display: flex; justify-content: space-between; align-items: center; min-width: 0; min-height: 102px; padding: 18px 19px;
  text-align: left; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 3px 8px #202f5703; }
.stat:hover { background: white; box-shadow: 0 5px 18px #2833590a; }
.stat p { color: #727b8e; font-size: 12px; margin-bottom: 6px; }
.stat strong { display: block; color: #262d42; font-size: 30px; line-height: 1.1; font-weight: 650; font-variant-numeric: tabular-nums; letter-spacing: -.7px; }
.stat em { font-size: 15px; color: #a2a9b8; font-style: normal; font-weight: 450; }
.stat small { display: block; font-size: 10px; color: var(--muted); margin-top: 8px; }
.stat-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 11px; background: #eef0ff; color: var(--blue); }
.stat-icon .icon { width: 20px; height: 20px; }
.stat.teal .stat-icon { background: #e5f7f1; color: var(--teal); }
.stat.violet .stat-icon { background: #f0ecff; color: #9263d7; }
.stat.orange .stat-icon { background: #fff3e6; color: #d59834; }
.stat.red .stat-icon { background: #fff0f2; color: #d76072; }
.stat.gray .stat-icon { background: #f0f2f6; color: #9ca4b6; }
.panel { min-width: 0; border: 1px solid var(--line); border-radius: 12px; background: white; box-shadow: 0 3px 9px #24386402; overflow: hidden; }
.panel-head { display: flex; justify-content: space-between; align-items: center; min-height: 55px; padding: 14px 18px; gap: 12px; border-bottom: 1px solid #eef0f5; }
.panel-head h2 { display: flex; align-items: center; gap: 8px; }
.panel-head h2 .icon { width: 16px; height: 16px; color: #8992aa; }
.panel-body { padding: 17px 18px; min-width: 0; }
.workspace > .panel { margin-bottom: 20px; }
.monitor-grid { display: grid; grid-template-columns: minmax(0, 1fr) 316px; gap: 18px; align-items: stretch; margin-bottom: 19px; }
.monitor-lower { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 18px; }
.map-panel > .panel-body { padding: 0; }
.map-head-actions { display: flex; align-items: center; gap: 8px; }
.map-panel.expanded { position: fixed; inset: 86px 22px 22px calc(var(--sidebar) + 22px); z-index: 1080; box-shadow: 0 20px 100px #11182a40; }
.map-panel.expanded .panel-body { height: calc(100% - 62px); }
.map-panel.expanded #live-map, .map-panel.expanded .coordinate-map { height: 100%; }
.coordinate-map { height: 446px; position: relative; isolation: isolate; overflow: hidden; background: #dbe4e7; }
.map-canvas { height: 100%; width: 100%; z-index: 0; font: inherit; }
.map-label { position: absolute; top: 15px; left: 15px; z-index: 800; display: flex; align-items: center; gap: 6px;
  padding: 7px 11px; border-radius: 7px; background: #ffffffeb; color: #384354; font-size: 11px; box-shadow: 0 2px 9px #151f3620; pointer-events: none; }
.map-label .icon { width: 13px; height: 13px; }
.map-tools { position: absolute; top: 15px; right: 14px; z-index: 800; display: flex; flex-direction: column; gap: 6px; }
.map-tools button { background: #fffffff5; box-shadow: 0 2px 6px #10203c17; font-size: 10px; }
.map-tools .small { width: 34px; padding: 5px 2px; flex-direction: column; gap: 1px; }
.map-tools .active { background: #5964e6; color: white; }
.map-footer { position: absolute; z-index: 800; bottom: 22px; right: 0; display: flex; align-items: center; gap: 8px;
  background: #ffffffd9; color: #5c6778; font-size: 9px; border-radius: 5px 0 0 0; padding: 3px 8px; }
.map-retry { display: none; }
.tiles-failed .map-retry { display: inline-flex; min-height: 20px; font-size: 10px; }
.tiles-failed .map-source-state { color: #b2641d; }
.leaflet-control-attribution { max-width: min(85vw, 520px); font-size: 8px !important; line-height: 1.35 !important; color: #64717c; }
.leaflet-control-scale { margin-bottom: 9px !important; }
.leaflet-control-scale-line { background: #ffffffb8; font-size: 9px; border-color: #657085; }
.geo-marker { border: 0; background: transparent; }
.geo-point { width: 29px; height: 29px; display: grid; place-items: center; background: #ffffffed; border: 2px solid #fff; color: #414c63; border-radius: 10px; box-shadow: 0 2px 10px #17253f50; }
.geo-point .icon { width: 16px; height: 16px; }
.geo-point.selected { background: #edab4c; color: white; box-shadow: 0 0 0 6px #edab4c35; }
.geo-point.disabled { opacity: .5; }
.geo-robot { position: relative; display: block; width: 34px; height: 34px; }
.geo-robot-symbol { display: grid; place-items: center; width: 34px; height: 34px; border: 2px solid white; border-radius: 50%; background: #5964e6; color: white; box-shadow: 0 2px 10px #141f3740; }
.geo-robot.selected .geo-robot-symbol { box-shadow: 0 0 0 7px #8c96ff50, 0 2px 10px #141f3740; }
.geo-robot.stale .geo-robot-symbol { background: #8392a5; }
.geo-robot-label { position: absolute; top: 40px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; align-items: center;
  white-space: nowrap; background: white; color: #28304a; font-size: 10px; line-height: 1.4; padding: 6px 9px; border-radius: 6px; box-shadow: 0 3px 12px #112f4140; }
.geo-robot-label b { font-size: 9px; color: #199573; padding-left: 6px; border-left: 1px solid #e5e8ed; }
.geo-popup { font: 12px/1.7 Inter, "Microsoft YaHei", sans-serif; min-width: 150px; }
.geo-popup p { margin: 3px 0 !important; font-size: 11px; color: #748098; }
.leaflet-popup-content { margin: 12px 15px; }
.leaflet-popup-content-wrapper { border-radius: 9px; }
.device-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 20px; max-height: 126px; overflow: auto; padding: 2px; }
.device-tab { min-height: 28px; padding: 5px 9px; font-size: 10px; color: #828a9d; border-color: #e9edf4; }
.device-tab.active { background: #eff0fd; color: #4e5ccf; border-color: #cdd2f8; }
.device-tab .dot { width: 5px; height: 5px; }
.robot-card-intro { display: flex; align-items: center; gap: 11px; margin-bottom: 15px; }
.robot-avatar { width: 48px; height: 48px; border-radius: 13px; background: #eef0fe; color: #6470e5; display: grid; place-items: center; flex: none; }
.robot-avatar .icon { width: 31px; height: 31px; }
.robot-avatar.offline { color: #9aa3b4; background: #f0f2f6; }
.robot-card-status { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.robot-card-status > strong { font-size: 14px; overflow-wrap: anywhere; }
.robot-card-intro > .online { font-size: 10px; }
.robot-card-status .badge { align-self: flex-start; }
.online { display: inline-flex; align-items: center; gap: 5px; color: #12947a; font-size: 11px; white-space: nowrap; }
.online i { width: 5px; height: 5px; background: currentColor; border-radius: 50%; }
.online.offline { color: #9aa3b3; }
.badge { display: inline-flex; align-items: center; justify-content: center; font-size: 10px; padding: 3px 7px; line-height: 1.55; border-radius: 5px; color: #768297; background: #f0f3f7; white-space: nowrap; font-weight: 500; }
.badge.blue { color: #5365c8; background: #eef1ff; }
.badge.green { color: #158b72; background: #eaf7f2; }
.badge.orange { color: #b88426; background: #fff5e5; }
.badge.red { color: #c25264; background: #fff0f2; }
.badge.gray { color: #8590a4; background: #f2f4f8; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 14px 19px; align-items: center; margin: 0; }
.kv dt { color: #9299a7; font-size: 11px; }
.kv dd { margin: 0; min-width: 0; text-align: right; font-size: 12px; overflow-wrap: anywhere; }
.kv dd .battery { justify-content: flex-end; }
.task-link { max-width: 175px; overflow: hidden; text-overflow: ellipsis; display: inline-block !important; vertical-align: middle; font-size: 10px !important; }
.battery { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #21927b; font-variant-numeric: tabular-nums; }
.battery.low { color: #d59129; }
.battery meter { width: 48px; height: 12px; appearance: none; }
.battery meter::-webkit-meter-bar { background: #e7f2ed; height: 5px; border: 0; border-radius: 2px; }
.battery meter::-webkit-meter-optimum-value { background: #35ad92; border-radius: 2px; }
.battery meter::-webkit-meter-suboptimum-value, .battery meter::-webkit-meter-even-less-good-value { background: #dea44c; }
.battery meter::-moz-meter-bar { background: #35ad92; border-radius: 2px; }
.robot-controls { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 19px; padding-top: 14px; border-top: 1px solid #f0f2f6; }
.robot-controls:empty { display: none; }
.mini-foot { margin-top: 15px; padding-top: 11px; border-top: 1px solid #f1f3f8; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.mini-foot .muted { font-size: 10px; }
.dual-queue { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 19px; }
.dual-queue > div + div { border-left: 1px solid #edf0f5; padding-left: 19px; }
.queue-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 9px; font-size: 12px; }
.queue-heading .badge { padding: 0 6px; }
.queue-list { display: flex; flex-direction: column; gap: 2px; }
.queue-item { display: flex; align-items: center; gap: 9px; padding: 11px 0; min-width: 0; }
.queue-number { width: 24px; height: 24px; flex: none; display: grid; place-items: center; background: #f0f2fe; color: #6a77d5; font-size: 10px; border-radius: 6px; }
.queue-number.green { color: #45a98e; background: #eef8f4; }
.queue-copy { flex: 1; min-width: 0; }
.queue-copy strong { font-size: 11px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.queue-copy small { display: block; font-size: 9px; color: #9aa2b1; }
.queue-item > .badge { font-size: 9px; padding: 2px 5px; }
.queue-item .battery { font-size: 10px; }
.queue-item .battery meter { display: none; }
.empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 9px; min-height: 120px; padding: 24px 12px; color: #a9b1c1; text-align: center; }
.empty .icon { width: 30px; height: 30px; color: #c3cbd9; }
.empty strong { color: #98a2b3; font-size: 12px; font-weight: 450; }
.empty p { color: #aab2c0; font-size: 11px; }
.dual-queue .empty { min-height: 127px; }
.table-wrap { width: 100%; overflow: auto; scrollbar-width: thin; scrollbar-color: #dce1ec transparent; }
.table { width: 100%; border-collapse: collapse; text-align: left; font-size: 12px; }
.table th { padding: 12px 12px; white-space: nowrap; color: #959caa; font-size: 10px; font-weight: 500; border-bottom: 1px solid var(--line); background: #fafbfd; }
.table td { padding: 13px 12px; vertical-align: middle; border-bottom: 1px solid #f0f2f6; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #fcfcff; }
.table td .muted { font-size: 10px; margin-top: 2px; }
.table td .button-row { flex-wrap: nowrap; }
.table td > .mono { white-space: nowrap; font-size: 11px; }
.compact-table th { font-size: 10px; padding: 8px 5px; }
.compact-table td { padding: 12px 5px; }
.compact-table td > div > .mono { font-size: 11px; }
.compact-table .muted { font-size: 10px; }
.compact-table th:last-child, .compact-table td:last-child { text-align: right; }
.compact-table .button-row { justify-content: flex-end; }
.id-short { display: inline-block; max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: middle; }
.cell-with-icon { display: flex; align-items: center; gap: 10px; }
.cell-icon { display: inline-grid; place-items: center; width: 33px; height: 33px; border-radius: 8px; background: #f0f2fc; color: #7985c7; flex: none; }
.tabs { display: flex; align-items: center; gap: 20px; margin: -2px 0 17px; border-bottom: 1px solid #edf0f5; overflow-x: auto; }
.tabs button { min-height: 41px; padding: 0 3px 12px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; font-size: 12px; color: #99a1ae; background: transparent; }
.tabs button.active { color: var(--blue); border-color: var(--blue); font-weight: 600; }
.toolbar { display: flex; align-items: flex-end; gap: 12px; flex-wrap: wrap; margin-bottom: 22px; }
.toolbar .field { margin-bottom: 0; flex: 1; min-width: 120px; max-width: 230px; }
.toolbar .field:first-child { max-width: 330px; flex: 1.7; }
.toolbar > button { height: 37px; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 15px; min-width: 0; }
.field > label { font-size: 11px; color: #737d92; font-weight: 500; }
input, select, textarea { min-width: 0; width: 100%; padding: 9px 11px; border: 1px solid #e1e5ed; border-radius: 7px; background: #fff; color: #30374b; outline: none; }
input::placeholder, textarea::placeholder { color: #afb5c2; font-size: 11px; }
input[readonly] { color: #99a2b3; background: #fafbfd; }
input[type='checkbox'], input[type='radio'] { width: 15px; height: 15px; padding: 0; accent-color: var(--blue); cursor: pointer; }
input:disabled { cursor: not-allowed; }
input[type='date'] { min-width: 130px; }
textarea { resize: vertical; min-height: 79px; }
.checkbox-field { flex-direction: row-reverse; justify-content: flex-end; align-items: center; gap: 9px; padding-top: 14px; }
.checkbox-field > label { cursor: pointer; }
.bulk-actions { margin-top: 13px; padding-top: 16px; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 9px; }
.pagination { display: flex; justify-content: space-between; align-items: center; margin-top: 18px; gap: 15px; }
.pagination button { min-height: 31px; padding: 6px 10px; font-size: 11px; }
.pagination .muted { font-size: 11px; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-bottom: 22px; }
.robot-card .panel-head .badge { font-size: 10px; }
.robot-card .panel-body { padding: 20px; }
.robot-card .kv { gap: 15px 12px; }
.simulator { width: 100%; font-size: 11px; }
summary { cursor: pointer; color: #8c95a8; font-size: 11px; }
.simulator summary { padding: 6px 0; }
.simulator .button-row { margin-top: 9px; }
.simulator .icon { width: 13px; height: 13px; margin-right: 4px; }
.list-tools { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; gap: 16px; }
.search-box { display: flex; align-items: center; position: relative; flex: 1; max-width: 390px; }
.search-box .icon { position: absolute; left: 12px; width: 14px; color: #a1aabd; }
.search-box input { padding-left: 35px; }
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-bottom: 20px; }
.split .kv { gap: 17px 20px; }
.split .panel-body > div > button { margin-top: 22px; }
.role-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-bottom: 22px; }
.role-card { display: flex; align-items: center; gap: 13px; padding: 20px; border: 1px solid var(--line); background: #fff; border-radius: 10px; }
.role-card .muted { font-size: 10px; margin-top: 4px; }
.alarm-summary { display: flex; align-items: center; gap: 11px; padding: 15px 18px; background: #fff9f0; border: 1px solid #f1e8d9; border-radius: 10px; margin-bottom: 22px; color: #b88b42; }
.alarm-summary > .muted { margin-left: auto; color: #bb9d6e; }
.chart-legend { display: flex; justify-content: center; align-items: center; gap: 18px; padding: 3px 0 20px; }
.legend-button { border: 0; background: transparent; font-size: 11px; min-height: 25px; padding: 3px; gap: 7px; }
.legend-button[aria-pressed='false'] { opacity: .4; }
.legend-dot { width: 8px; height: 8px; display: inline-block; border-radius: 3px; background: #586be3; }
.legend-dot.teal, .chart-bar.teal { background: #36b799; fill: #36b799; }
.legend-dot.gray, .chart-bar.gray { background: #bdc5d5; fill: #bdc5d5; }
.chart-bar.blue { fill: #7483eb; }
.trend-chart { width: 100%; height: 290px; display: block; overflow: visible; }
.axis-label { fill: #9ca5b5; font-size: 10px; }
.bar-number { fill: #74819b; font-size: 9px; }
.loading { min-height: 320px; display: flex; align-items: center; justify-content: center; gap: 11px; color: #929bb0; }
.spinner { width: 19px; height: 19px; border: 2px solid #e2e6f8; border-top-color: #7381e5; border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.error { color: #c34863; font-size: 12px; line-height: 1.8; margin: 9px 0; }
.error:empty { display: none; }
#toast { position: fixed; left: 50%; top: 82px; z-index: 3000; display: flex; align-items: center; gap: 10px; max-width: calc(100vw - 30px);
  transform: translate(-50%, -14px); opacity: 0; visibility: hidden; padding: 12px 18px; border: 1px solid #deeee7; border-radius: 10px;
  color: #448873; background: white; box-shadow: 0 8px 30px #14243820; transition: opacity .18s, transform .18s; font-size: 12px; }
#toast.visible { transform: translate(-50%, 0); opacity: 1; visibility: visible; }
#toast.error { border-color: #f1d9df; color: #c65269; }
dialog { width: min(540px, calc(100vw - 36px)); max-height: calc(100vh - 60px); padding: 0; margin: auto; border: 1px solid #eceff5;
  border-radius: 15px; box-shadow: 0 25px 100px #14234340; background: #fff; color: var(--ink); }
dialog::backdrop { background: #1b263455; backdrop-filter: blur(3px); }
.dialog-header { display: flex; align-items: center; justify-content: space-between; padding: 22px 24px; gap: 16px; border-bottom: 1px solid var(--line); }
.dialog-header .eyebrow { display: none; }
.dialog-header h2 { font-size: 18px; }
.dialog-body { padding: 24px; overflow-y: auto; }
.dialog-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2px 16px; }
.dialog-fields:has(> :only-child) { grid-template-columns: 1fr; }
.dialog-fields > .field:has(textarea) { grid-column: 1 / -1; }
.dialog-footer { display: flex; justify-content: flex-end; align-items: center; gap: 10px; padding-top: 22px; }
.form-hint { color: #929aab; font-size: 11px; margin-bottom: 19px; }
.delete-label { font-size: 17px; color: #48526b; margin-bottom: 15px; overflow-wrap: anywhere; }
.detail-drawer { position: fixed; inset: 0 0 0 auto; height: 100dvh; max-height: 100dvh; width: min(650px, 100vw); border-radius: 16px 0 0 16px; margin: 0; }
.detail-drawer .dialog-body { padding: 26px; }
.detail-overview { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 25px; }
.detail-number { display: block; margin-top: 4px; font-size: 25px; font-variant-numeric: tabular-nums; }
.order-progress { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 20px 0 27px; }
.progress-step { position: relative; display: flex; flex-direction: column; gap: 6px; align-items: center; text-align: center; color: #a0a9bb; }
.progress-step:before { content: ''; position: absolute; height: 2px; background: #edf0f6; top: 13px; right: 50%; width: 100%; }
.progress-step:first-child:before { display: none; }
.progress-step i { position: relative; z-index: 1; display: grid; place-items: center; width: 27px; height: 27px; background: #f3f5f9; border: 3px solid white; border-radius: 50%; font-style: normal; font-size: 9px; }
.progress-step.done i { color: white; background: #7987df; }
.progress-step.done:before { background: #c7d0f6; }
.progress-step i .icon { width: 13px; height: 13px; }
.progress-step strong { font-size: 10px; color: #7b87a1; }
.progress-step small { font-size: 9px; }
.delivery-route { display: flex; justify-content: space-between; align-items: center; gap: 15px; border: 1px solid #edf0f5; border-radius: 10px; padding: 20px 17px; margin-bottom: 25px; }
.delivery-route > div { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.delivery-route strong { flex-basis: 100%; margin-top: 4px; font-size: 13px; }
.delivery-route small { color: #929caf; font-size: 10px; }
.delivery-route > .icon { color: #b1b9cd; }
.route-dot { width: 6px; height: 6px; border-radius: 50%; background: #8a9cba; }
.route-dot.end { background: #76bea9; }
.section-heading { margin: 27px 0 20px; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 18px; border-left: 1px solid #e5eaf3; }
.timeline li { position: relative; margin-bottom: 22px; }
.timeline li:before { content: ''; position: absolute; left: -23px; top: 5px; width: 8px; height: 8px; background: #99a7d7; border-radius: 50%; box-shadow: 0 0 0 3px #fff; }
.timeline strong { font-size: 11px; }
.timeline time { font-size: 10px; color: #9da7b8; }
.timeline p { color: #929bae; font-size: 11px; margin-top: 4px; }
.technical-detail { margin-top: 20px; border-top: 1px solid #eef0f5; padding-top: 14px; }
pre { overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; background: #f7f8fb; border-radius: 7px; padding: 15px; font: 11px/1.6 Consolas, monospace; color: #66738c; }
.point-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; margin-bottom: 20px; max-height: 230px; overflow-y: auto; }
.point-option { position: relative; display: flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 8px; padding: 12px 9px; cursor: pointer; min-width: 0; }
.point-option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.point-option:focus-within { outline: 2px solid #8592ec; outline-offset: 2px; }
.point-option.selected { border-color: #8b97ea; background: #f7f8ff; }
.point-icon { width: 31px; height: 31px; flex: none; border-radius: 8px; color: #c0934d; background: #fff4e5; display: grid; place-items: center; }
.point-icon.blue { color: #7285c3; background: #eef2ff; }
.point-copy { min-width: 0; flex: 1; }
.point-copy strong { display: block; font-size: 11px; overflow-wrap: anywhere; }
.point-copy small { display: none; }
.radio-indicator { width: 15px; height: 15px; border: 1px solid #d8ddeb; border-radius: 50%; color: transparent; display: grid; place-items: center; }
.radio-indicator .icon { width: 10px; height: 10px; }
.selected .radio-indicator { background: #707ee1; border-color: #707ee1; color: white; }
.input-counter { display: block; font-size: 9px; color: #aeb6c5; text-align: right; margin: -11px 1px 12px; }
.skip-link { position: fixed; top: -80px; left: 10px; z-index: 4000; padding: 10px; background: white; color: var(--blue); }
.skip-link:focus { top: 10px; }
.login-header { position: absolute; top: 32px; left: 5%; right: 5%; display: flex; justify-content: space-between; align-items: center; }
.login-secure { color: #8c95aa; display: flex; align-items: center; gap: 7px; font-size: 11px; }
.login { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 60px; align-items: center; max-width: 1150px; margin: auto; padding: 120px 40px 80px; }
.login-intro { position: relative; }
.login-kicker { font-size: 10px; letter-spacing: .17em; color: #8790ae; display: flex; align-items: center; gap: 8px; margin-bottom: 18px; }
.login-intro h1 { font-size: 38px; line-height: 1.5; color: #323b65; font-weight: 680; }
.login-tagline { display: flex; align-items: center; gap: 13px; font-size: 11px; color: #9ca4b7; margin-top: 17px; }
.login-tagline i { width: 2px; height: 2px; border-radius: 50%; background: #a7aec1; }
.login-art { display: block; width: 78%; height: 210px; object-fit: contain; object-position: left; margin: 17px 0 9px; mix-blend-mode: multiply; }
.login-features { display: flex; flex-wrap: wrap; gap: 20px; font-size: 10px; color: #9da6ba; }
.login-features > span { display: flex; align-items: center; gap: 6px; }
.login-features .icon { width: 14px; height: 14px; color: #9daae1; }
.login-box { padding: 38px; border-radius: 18px; border: 1px solid #e5e9f4; box-shadow: 0 17px 50px #5c6b9c0d; background: #fff; }
.login-box-icon { display: grid; place-items: center; width: 40px; height: 40px; background: #f0f2ff; color: #7c88dc; border-radius: 12px; margin-bottom: 19px; }
.login-box h2 { font-size: 22px; color: #3c4765; }
.login-box > p { margin: 7px 0 28px; }
.login-form .field { margin-bottom: 19px; }
.login-form input { height: 43px; padding-left: 40px; }
.with-icon { position: relative; }
.with-icon > .icon { position: absolute; left: 13px; bottom: 13px; width: 16px; color: #a1abc0; }
.password-eye { position: absolute; right: 7px; bottom: 5px; border: 0; color: #9ca5b9; background: transparent; }
.login-form .password-eye { background: transparent; }
.login-submit { height: 42px; margin-top: 12px; justify-content: space-between; padding-left: 20px; padding-right: 20px; }
.login-footnote { margin-top: 24px; color: #a6aebf; font-size: 10px; display: flex; align-items: center; gap: 6px; justify-content: center; }
.login-footnote .icon { width: 12px; height: 12px; }
.login-footer { position: absolute; bottom: 23px; left: 5%; right: 5%; display: flex; justify-content: space-between; color: #b1b8c8; font-size: 9px; }
@media (min-width: 1700px) {
  :root { --sidebar: 210px; font-size: 14px; }
  .workspace { padding: 32px 36px; }
  .monitor-grid { grid-template-columns: minmax(0, 1fr) 355px; }
  .coordinate-map { height: 490px; }
  .live-fleet-panel .panel-body { padding: 22px; }
  .cards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 1250px) {
  :root { --sidebar: 175px; }
  .workspace { padding: 23px 20px 35px; }
  .topbar { padding: 0 20px; gap: 18px; }
  .top-breadcrumb { display: none; }
  .monitor-grid { grid-template-columns: minmax(0, 1fr) 285px; gap: 15px; }
  .stat { padding: 17px 14px; min-height: 92px; }
  .stat-icon { width: 30px; height: 30px; }
  .stat strong { font-size: 27px; }
  .stats { gap: 10px; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dual-queue { gap: 10px; }
  .dual-queue > div + div { padding-left: 12px; }
  .queue-item { gap: 5px; }
  .queue-number { width: 21px; height: 21px; }
}
@media (max-width: 1000px) {
  .topbar { padding: 0 20px; height: 62px; }
  .top-brand { width: auto; }
  .top-meta { gap: 14px; }
  .mobile-menu { display: inline-flex !important; }
  .sidebar { top: 62px; transform: translateX(-100%); width: 205px; transition: transform .2s; }
  .sidebar.open { transform: translateX(0); }
  .nav-scrim { position: fixed; inset: 62px 0 0; border: 0; background: #16203755; z-index: 1040; border-radius: 0; }
  .menu-open .nav-scrim { display: block; }
  .workspace { margin: 62px 0 0; }
  .map-panel.expanded { inset: 77px 15px 15px; }
  .monitor-grid { grid-template-columns: minmax(0, 1fr) 284px; }
  .stats { gap: 9px; }
  .stat-icon { display: none; }
  .role-card { padding: 15px; }
  .monitor-lower { grid-template-columns: 1fr; }
  .queue-item { gap: 10px; }
  .dual-queue { gap: 23px; }
  .dual-queue > div + div { padding-left: 23px; }
  .login { gap: 35px; }
  .login-intro h1 { font-size: 32px; }
  .login-box { padding: 30px; }
}
@media (max-width: 700px) {
  .workspace { padding: 20px 14px 30px; }
  .topbar { padding: 0 14px; gap: 8px; }
  .top-meta { gap: 9px; }
  .account { padding-left: 10px; }
  .account > div, .top-alarm, #stream-state, .brand > div > span { display: none !important; }
  .brand strong { font-size: 17px; }
  .brand-mark { width: 31px; height: 31px; border-radius: 9px; }
  .brand-mark .icon { width: 23px; height: 23px; }
  .brand { gap: 8px; }
  .top-brand { gap: 9px; }
  .pagehead { align-items: flex-start; margin-bottom: 18px; gap: 10px; }
  h1 { font-size: 23px; }
  .pagehead .muted { font-size: 10px; }
  .pagehead .actions { gap: 7px; }
  .actions button { min-height: 32px; padding: 7px 9px; font-size: 11px; }
  .live-timestamp { display: none; }
  .stats { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 9px; margin-bottom: 18px; }
  .stat { padding: 14px; min-height: 85px; }
  .stat strong { font-size: 26px; }
  .stat p { font-size: 10px; margin-bottom: 7px; }
  .stat em { font-size: 12px; }
  .stats > .stat:nth-child(4), .stats > .stat:nth-child(5) { grid-column: auto; }
  .stats.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .monitor-grid { grid-template-columns: 1fr; gap: 16px; margin-bottom: 16px; }
  .coordinate-map { height: 355px; }
  .panel-head { min-height: 50px; padding: 12px 14px; }
  .panel-body { padding: 15px; }
  .panel-head h2 { font-size: 13px; }
  .panel-head .muted { font-size: 10px; }
  .live-fleet-panel .kv { grid-template-columns: max-content minmax(0, 1fr); }
  .device-tabs { flex-wrap: nowrap; overflow-x: auto; max-height: none; padding: 3px; margin-bottom: 17px; }
  .device-tab { flex: none; }
  .robot-card-intro { margin-bottom: 15px; }
  .robot-controls { margin-top: 16px; }
  .monitor-lower { gap: 16px; }
  .cards, .split, .role-cards { grid-template-columns: 1fr; gap: 15px; }
  .cards { margin-bottom: 16px; }
  .robot-card .panel-body { padding: 17px; }
  .toolbar { gap: 9px; margin-bottom: 15px; }
  .toolbar .field { min-width: 115px; flex: 1; max-width: none; }
  .toolbar .field:first-child { flex-basis: 100%; max-width: none; }
  .toolbar .field:has(input[name='user_id']) { min-width: 100px; }
  .toolbar > button { min-height: 31px; height: 33px; }
  .tabs { gap: 16px; margin-bottom: 15px; }
  .tabs button { font-size: 11px; min-height: 34px; }
  .responsive-table, .responsive-table tbody { display: block; width: 100%; }
  .responsive-table thead { display: none; }
  .responsive-table tbody tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 13px; border: 1px solid #e7eaf2; border-radius: 9px; padding: 14px; margin-bottom: 10px; }
  .responsive-table td { display: block; min-width: 0; padding: 0; border: 0; overflow-wrap: anywhere; font-size: 11px; }
  .responsive-table td:before { content: attr(data-label); display: block; font-size: 9px; color: #a8afbc; margin-bottom: 3px; }
  .responsive-table td:last-child { grid-column: 1 / -1; border-top: 1px solid #eef1f6; padding-top: 7px; margin-top: 2px; }
  .responsive-table td:last-child .button-row { justify-content: flex-end; }
  .responsive-table td:last-child:before { display: none; }
  .orders-data td:first-child:has(input) { grid-column: 1 / -1; display: flex; justify-content: flex-end; }
  .orders-data td:first-child:has(input):before { display: none; }
  .id-short { max-width: 100%; }
  .pagination { margin-top: 13px; align-items: flex-start; }
  .pagination .button-row { gap: 5px; }
  .pagination button { font-size: 10px; padding: 5px 7px; }
  .pagination .muted { font-size: 10px; }
  .alarm-summary { flex-wrap: wrap; font-size: 11px; gap: 7px; }
  .alarm-summary > .muted { display: none; }
  .role-card .muted { font-size: 11px; }
  .list-tools { gap: 10px; }
  .list-tools .muted { font-size: 10px; white-space: nowrap; }
  .chart-legend { gap: 13px; }
  .trend-chart { height: 240px; }
  dialog { width: calc(100vw - 24px); max-height: calc(100dvh - 36px); border-radius: 13px; }
  .dialog-header { padding: 18px; }
  .dialog-header h2 { font-size: 17px; }
  .dialog-body { padding: 18px; }
  .dialog-fields { gap: 0 12px; }
  .detail-drawer { border-radius: 0; width: 100vw; max-height: 100dvh; }
  .detail-drawer .dialog-body { padding: 18px; }
  .detail-number { font-size: 23px; }
  .progress-step strong { font-size: 9px; }
  .progress-step small { font-size: 8px; }
  .delivery-route { padding: 15px; }
  .delivery-route strong { font-size: 11px; }
  .point-options { grid-template-columns: 1fr 1fr; }
  .login { display: flex; flex-direction: column; justify-content: center; padding: 90px 20px 65px; }
  .login-intro { display: none; }
  .login-box { width: 100%; max-width: 410px; padding: 29px; }
  .login-header { top: 24px; left: 22px; right: 22px; }
  .login-secure { display: none; }
  .login-footer { left: 22px; right: 22px; bottom: 18px; }
}
@media (max-width: 370px) {
  .workspace { padding: 16px 10px 25px; }
  .brand strong { font-size: 15px; }
  .brand-mark { display: none; }
  .top-meta { gap: 7px; }
  .pagehead { flex-wrap: wrap; }
  .pagehead .actions { width: 100%; justify-content: flex-start; }
  .stat { padding: 12px 10px; }
  .stat strong { font-size: 23px; }
  .dual-queue { grid-template-columns: 1fr; gap: 15px; }
  .dual-queue > div + div { padding-left: 0; border-left: 0; border-top: 1px solid #edf0f5; padding-top: 14px; }
  .point-options { grid-template-columns: 1fr; }
  .dialog-fields { grid-template-columns: 1fr; }
  .detail-overview { gap: 8px; }
  .detail-number { font-size: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
