.leaflet-pane,.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-tile-container,.leaflet-pane>svg,.leaflet-pane>canvas,.leaflet-zoom-box,.leaflet-image-layer,.leaflet-layer{position:absolute;left:0;top:0}.leaflet-container{overflow:hidden}.leaflet-tile,.leaflet-marker-icon,.leaflet-marker-shadow{-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-user-drag:none}.leaflet-tile::selection{background:transparent}.leaflet-safari .leaflet-tile{image-rendering:-webkit-optimize-contrast}.leaflet-safari .leaflet-tile-container{width:1600px;height:1600px;-webkit-transform-origin:0 0}.leaflet-marker-icon,.leaflet-marker-shadow{display:block}.leaflet-container .leaflet-overlay-pane svg{max-width:none!important;max-height:none!important}.leaflet-container .leaflet-marker-pane img,.leaflet-container .leaflet-shadow-pane img,.leaflet-container .leaflet-tile-pane img,.leaflet-container img.leaflet-image-layer,.leaflet-container .leaflet-tile{max-width:none!important;max-height:none!important;width:auto;padding:0}.leaflet-container img.leaflet-tile{mix-blend-mode:plus-lighter}.leaflet-container.leaflet-touch-zoom{-ms-touch-action:pan-x pan-y;touch-action:pan-x pan-y}.leaflet-container.leaflet-touch-drag{-ms-touch-action:pinch-zoom;touch-action:none;touch-action:pinch-zoom}.leaflet-container.leaflet-touch-drag.leaflet-touch-zoom{-ms-touch-action:none;touch-action:none}.leaflet-container{-webkit-tap-highlight-color:transparent}.leaflet-container a{-webkit-tap-highlight-color:rgba(51,181,229,.4)}.leaflet-tile{filter:inherit;visibility:hidden}.leaflet-tile-loaded{visibility:inherit}.leaflet-zoom-box{width:0;height:0;-moz-box-sizing:border-box;box-sizing:border-box;z-index:800}.leaflet-overlay-pane svg{-moz-user-select:none}.leaflet-pane{z-index:400}.leaflet-tile-pane{z-index:200}.leaflet-overlay-pane{z-index:400}.leaflet-shadow-pane{z-index:500}.leaflet-marker-pane{z-index:600}.leaflet-tooltip-pane{z-index:650}.leaflet-popup-pane{z-index:700}.leaflet-map-pane canvas{z-index:100}.leaflet-map-pane svg{z-index:200}.leaflet-vml-shape{width:1px;height:1px}.lvml{behavior:url(#default#VML);display:inline-block;position:absolute}.leaflet-control{position:relative;z-index:800;pointer-events:visiblePainted;pointer-events:auto}.leaflet-top,.leaflet-bottom{position:absolute;z-index:1000;pointer-events:none}.leaflet-top{top:0}.leaflet-right{right:0}.leaflet-bottom{bottom:0}.leaflet-left{left:0}.leaflet-control{float:left;clear:both}.leaflet-right .leaflet-control{float:right}.leaflet-top .leaflet-control{margin-top:10px}.leaflet-bottom .leaflet-control{margin-bottom:10px}.leaflet-left .leaflet-control{margin-left:10px}.leaflet-right .leaflet-control{margin-right:10px}.leaflet-fade-anim .leaflet-popup{opacity:0;-webkit-transition:opacity .2s linear;-moz-transition:opacity .2s linear;transition:opacity .2s linear}.leaflet-fade-anim .leaflet-map-pane .leaflet-popup{opacity:1}.leaflet-zoom-animated{-webkit-transform-origin:0 0;-ms-transform-origin:0 0;transform-origin:0 0}svg.leaflet-zoom-animated{will-change:transform}.leaflet-zoom-anim .leaflet-zoom-animated{-webkit-transition:-webkit-transform .25s cubic-bezier(0,0,.25,1);-moz-transition:-moz-transform .25s cubic-bezier(0,0,.25,1);transition:transform .25s cubic-bezier(0,0,.25,1)}.leaflet-zoom-anim .leaflet-tile,.leaflet-pan-anim .leaflet-tile{-webkit-transition:none;-moz-transition:none;transition:none}.leaflet-zoom-anim .leaflet-zoom-hide{visibility:hidden}.leaflet-interactive{cursor:pointer}.leaflet-grab{cursor:-webkit-grab;cursor:-moz-grab;cursor:grab}.leaflet-crosshair,.leaflet-crosshair .leaflet-interactive{cursor:crosshair}.leaflet-popup-pane,.leaflet-control{cursor:auto}.leaflet-dragging .leaflet-grab,.leaflet-dragging .leaflet-grab .leaflet-interactive,.leaflet-dragging .leaflet-marker-draggable{cursor:move;cursor:-webkit-grabbing;cursor:-moz-grabbing;cursor:grabbing}.leaflet-marker-icon,.leaflet-marker-shadow,.leaflet-image-layer,.leaflet-pane>svg path,.leaflet-tile-container{pointer-events:none}.leaflet-marker-icon.leaflet-interactive,.leaflet-image-layer.leaflet-interactive,.leaflet-pane>svg path.leaflet-interactive,svg.leaflet-image-layer.leaflet-interactive path{pointer-events:visiblePainted;pointer-events:auto}.leaflet-container{background:#ddd;outline-offset:1px}.leaflet-container a{color:#0078a8}.leaflet-zoom-box{border:2px dotted #38f;background:#ffffff80}.leaflet-container{font-family:Helvetica Neue,Arial,Helvetica,sans-serif;font-size:12px;font-size:.75rem;line-height:1.5}.leaflet-bar{box-shadow:0 1px 5px #000000a6;border-radius:4px}.leaflet-bar a{background-color:#fff;border-bottom:1px solid #ccc;width:26px;height:26px;line-height:26px;display:block;text-align:center;text-decoration:none;color:#000}.leaflet-bar a,.leaflet-control-layers-toggle{background-position:50% 50%;background-repeat:no-repeat;display:block}.leaflet-bar a:hover,.leaflet-bar a:focus{background-color:#f4f4f4}.leaflet-bar a:first-child{border-top-left-radius:4px;border-top-right-radius:4px}.leaflet-bar a:last-child{border-bottom-left-radius:4px;border-bottom-right-radius:4px;border-bottom:none}.leaflet-bar a.leaflet-disabled{cursor:default;background-color:#f4f4f4;color:#bbb}.leaflet-touch .leaflet-bar a{width:30px;height:30px;line-height:30px}.leaflet-touch .leaflet-bar a:first-child{border-top-left-radius:2px;border-top-right-radius:2px}.leaflet-touch .leaflet-bar a:last-child{border-bottom-left-radius:2px;border-bottom-right-radius:2px}.leaflet-control-zoom-in,.leaflet-control-zoom-out{font:700 18px Lucida Console,Monaco,monospace;text-indent:1px}.leaflet-touch .leaflet-control-zoom-in,.leaflet-touch .leaflet-control-zoom-out{font-size:22px}.leaflet-control-layers{box-shadow:0 1px 5px #0006;background:#fff;border-radius:5px}.leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABoAAAAaCAQAAAADQ4RFAAACf0lEQVR4AY1UM3gkARTePdvdoTxXKc+qTl3aU5U6b2Kbkz3Gtq3Zw6ziLGNPzrYx7946Tr6/ee/XeCQ4D3ykPtL5tHno4n0d/h3+xfuWHGLX81cn7r0iTNzjr7LrlxCqPtkbTQEHeqOrTy4Yyt3VCi/IOB0v7rVC7q45Q3Gr5K6jt+3Gl5nCoDD4MtO+j96Wu8atmhGqcNGHObuf8OM/x3AMx38+4Z2sPqzCxRFK2aF2e5Jol56XTLyggAMTL56XOMoS1W4pOyjUcGGQdZxU6qRh7B9Zp+PfpOFlqt0zyDZckPi1ttmIp03jX8gyJ8a/PG2yutpS/Vol7peZIbZcKBAEEheEIAgFbDkz5H6Zrkm2hVWGiXKiF4Ycw0RWKdtC16Q7qe3X4iOMxruonzegJzWaXFrU9utOSsLUmrc0YjeWYjCW4PDMADElpJSSQ0vQvA1Tm6/JlKnqFs1EGyZiFCqnRZTEJJJiKRYzVYzJck2Rm6P4iH+cmSY0YzimYa8l0EtTODFWhcMIMVqdsI2uiTvKmTisIDHJ3od5GILVhBCarCfVRmo4uTjkhrhzkiBV7SsaqS+TzrzM1qpGGUFt28pIySQHR6h7F6KSwGWm97ay+Z+ZqMcEjEWebE7wxCSQwpkhJqoZA5ivCdZDjJepuJ9IQjGGUmuXJdBFUygxVqVsxFsLMbDe8ZbDYVCGKxs+W080max1hFCarCfV+C1KATwcnvE9gRRuMP2prdbWGowm1KB1y+zwMMENkM755cJ2yPDtqhTI6ED1M/82yIDtC/4j4BijjeObflpO9I9MwXTCsSX8jWAFeHr05WoLTJ5G8IQVS/7vwR6ohirYM7f6HzYpogfS3R2OAAAAAElFTkSuQmCC);width:36px;height:36px}.leaflet-retina .leaflet-control-layers-toggle{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAQAAABvcdNgAAAEsklEQVR4AWL4TydIhpZK1kpWOlg0w3ZXP6D2soBtG42jeI6ZmQTHzAxiTbSJsYLjO9HhP+WOmcuhciVnmHVQcJnp7DFvScowZorad/+V/fVzMdMT2g9Cv9guXGv/7pYOrXh2U+RRR3dSd9JRx6bIFc/ekqHI29JC6pJ5ZEh1yWkhkbcFeSjxgx3L2m1cb1C7bceyxA+CNjT/Ifff+/kDk2u/w/33/IeCMOSaWZ4glosqT3DNnNZQ7Cs58/3Ce5HL78iZH/vKVIaYlqzfdLu8Vi7dnvUbEza5Idt36tquZFldl6N5Z/POLof0XLK61mZCmJSWjVF9tEjUluu74IUXvgttuVIHE7YxSkaYhJZam7yiM9Pv82JYfl9nptxZaxMJE4YSPty+vF0+Y2up9d3wwijfjZbabqm/3bZ9ecKHsiGmRflnn1MW4pjHf9oLufyn2z3y1D6n8g8TZhxyzipLNPnAUpsOiuWimg52psrTZYnOWYNDTMuWBWa0tJb4rgq1UvmutpaYEbZlwU3CLJm/ayYjHW5/h7xWLn9Hh1vepDkyf7dE7MtT5LR4e7yYpHrkhOUpEfssBLq2pPhAqoSWKUkk7EDqkmK6RrCEzqDjhNDWNE+XSMvkJRDWlZTmCW0l0PHQGRZY5t1L83kT0Y3l2SItk5JAWHl2dCOBm+fPu3fo5/3v61RMCO9Jx2EEYYhb0rmNQMX/vm7gqOEJLcXTGw3CAuRNeyaPWwjR8PRqKQ1PDA/dpv+on9Shox52WFnx0KY8onHayrJzm87i5h9xGw/tfkev0jGsQizqezUKjk12hBMKJ4kbCqGPVNXudyyrShovGw5CgxsRICxF6aRmSjlBnHRzg7Gx8fKqEubI2rahQYdR1YgDIRQO7JvQyD52hoIQx0mxa0ODtW2Iozn1le2iIRdzwWewedyZzewidueOGqlsn1MvcnQpuVwLGG3/IR1hIKxCjelIDZ8ldqWz25jWAsnldEnK0Zxro19TGVb2ffIZEsIO89EIEDvKMPrzmBOQcKQ+rroye6NgRRxqR4U8EAkz0CL6uSGOm6KQCdWjvjRiSP1BPalCRS5iQYiEIvxuBMJEWgzSoHADcVMuN7IuqqTeyUPq22qFimFtxDyBBJEwNyt6TM88blFHao/6tWWhuuOM4SAK4EI4QmFHA+SEyWlp4EQoJ13cYGzMu7yszEIBOm2rVmHUNqwAIQabISNMRstmdhNWcFLsSm+0tjJH1MdRxO5Nx0WDMhCtgD6OKgZeljJqJKc9po8juskR9XN0Y1lZ3mWjLR9JCO1jRDMd0fpYC2VnvjBSEFg7wBENc0R9HFlb0xvF1+TBEpF68d+DHR6IOWVv2BECtxo46hOFUBd/APU57WIoEwJhIi2CdpyZX0m93BZicktMj1AS9dClteUFAUNUIEygRZCtik5zSxI9MubTBH1GOiHsiLJ3OCoSZkILa9PxiN0EbvhsAo8tdAf9Seepd36lGWHmtNANTv5Jd0z4QYyeo/UEJqxKRpg5LZx6btLPsOaEmdMyxYdlc8LMaJnikDlhclqmPiQnTEpLUIZEwkRagjYkEibQErwhkTAKCLQEbUgkzJQWc/0PstHHcfEdQ+UAAAAASUVORK5CYII=);background-size:26px 26px}.leaflet-touch .leaflet-control-layers-toggle{width:44px;height:44px}.leaflet-control-layers .leaflet-control-layers-list,.leaflet-control-layers-expanded .leaflet-control-layers-toggle{display:none}.leaflet-control-layers-expanded .leaflet-control-layers-list{display:block;position:relative}.leaflet-control-layers-expanded{padding:6px 10px 6px 6px;color:#333;background:#fff}.leaflet-control-layers-scrollbar{overflow-y:scroll;overflow-x:hidden;padding-right:5px}.leaflet-control-layers-selector{margin-top:2px;position:relative;top:1px}.leaflet-control-layers label{display:block;font-size:13px;font-size:1.08333em}.leaflet-control-layers-separator{height:0;border-top:1px solid #ddd;margin:5px -10px 5px -6px}.leaflet-default-icon-path{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABkAAAApCAYAAADAk4LOAAAFgUlEQVR4Aa1XA5BjWRTN2oW17d3YaZtr2962HUzbDNpjszW24mRt28p47v7zq/bXZtrp/lWnXr337j3nPCe85NcypgSFdugCpW5YoDAMRaIMqRi6aKq5E3YqDQO3qAwjVWrD8Ncq/RBpykd8oZUb/kaJutow8r1aP9II0WmLKLIsJyv1w/kqw9Ch2MYdB++12Onxee/QMwvf4/Dk/Lfp/i4nxTXtOoQ4pW5Aj7wpici1A9erdAN2OH64x8OSP9j3Ft3b7aWkTg/Fm91siTra0f9on5sQr9INejH6CUUUpavjFNq1B+Oadhxmnfa8RfEmN8VNAsQhPqF55xHkMzz3jSmChWU6f7/XZKNH+9+hBLOHYozuKQPxyMPUKkrX/K0uWnfFaJGS1QPRtZsOPtr3NsW0uyh6NNCOkU3Yz+bXbT3I8G3xE5EXLXtCXbbqwCO9zPQYPRTZ5vIDXD7U+w7rFDEoUUf7ibHIR4y6bLVPXrz8JVZEql13trxwue/uDivd3fkWRbS6/IA2bID4uk0UpF1N8qLlbBlXs4Ee7HLTfV1j54APvODnSfOWBqtKVvjgLKzF5YdEk5ewRkGlK0i33Eofffc7HT56jD7/6U+qH3Cx7SBLNntH5YIPvODnyfIXZYRVDPqgHtLs5ABHD3YzLuespb7t79FY34DjMwrVrcTuwlT55YMPvOBnRrJ4VXTdNnYug5ucHLBjEpt30701A3Ts+HEa73u6dT3FNWwflY86eMHPk+Yu+i6pzUpRrW7SNDg5JHR4KapmM5Wv2E8Tfcb1HoqqHMHU+uWDD7zg54mz5/2BSnizi9T1Dg4QQXLToGNCkb6tb1NU+QAlGr1++eADrzhn/u8Q2YZhQVlZ5+CAOtqfbhmaUCS1ezNFVm2imDbPmPng5wmz+gwh+oHDce0eUtQ6OGDIyR0uUhUsoO3vfDmmgOezH0mZN59x7MBi++WDL1g/eEiU3avlidO671bkLfwbw5XV2P8Pzo0ydy4t2/0eu33xYSOMOD8hTf4CrBtGMSoXfPLchX+J0ruSePw3LZeK0juPJbYzrhkH0io7B3k164hiGvawhOKMLkrQLyVpZg8rHFW7E2uHOL888IBPlNZ1FPzstSJM694fWr6RwpvcJK60+0HCILTBzZLFNdtAzJaohze60T8qBzyh5ZuOg5e7uwQppofEmf2++DYvmySqGBuKaicF1blQjhuHdvCIMvp8whTTfZzI7RldpwtSzL+F1+wkdZ2TBOW2gIF88PBTzD/gpeREAMEbxnJcaJHNHrpzji0gQCS6hdkEeYt9DF/2qPcEC8RM28Hwmr3sdNyht00byAut2k3gufWNtgtOEOFGUwcXWNDbdNbpgBGxEvKkOQsxivJx33iow0Vw5S6SVTrpVq11ysA2Rp7gTfPfktc6zhtXBBC+adRLshf6sG2RfHPZ5EAc4sVZ83yCN00Fk/4kggu40ZTvIEm5g24qtU4KjBrx/BTTH8ifVASAG7gKrnWxJDcU7x8X6Ecczhm3o6YicvsLXWfh3Ch1W0k8x0nXF+0fFxgt4phz8QvypiwCCFKMqXCnqXExjq10beH+UUA7+nG6mdG/Pu0f3LgFcGrl2s0kNNjpmoJ9o4B29CMO8dMT4Q5ox8uitF6fqsrJOr8qnwNbRzv6hSnG5wP+64C7h9lp30hKNtKdWjtdkbuPA19nJ7Tz3zR/ibgARbhb4AlhavcBebmTHcFl2fvYEnW0ox9xMxKBS8btJ+KiEbq9zA4RthQXDhPa0T9TEe69gWupwc6uBUphquXgf+/FrIjweHQS4/pduMe5ERUMHUd9xv8ZR98CxkS4F2n3EUrUZ10EYNw7BWm9x1GiPssi3GgiGRDKWRYZfXlON+dfNbM+GgIwYdwAAAAASUVORK5CYII=)}.leaflet-container .leaflet-control-attribution{background:#fff;background:#fffc;margin:0}.leaflet-control-attribution,.leaflet-control-scale-line{padding:0 5px;color:#333;line-height:1.4}.leaflet-control-attribution a{text-decoration:none}.leaflet-control-attribution a:hover,.leaflet-control-attribution a:focus{text-decoration:underline}.leaflet-attribution-flag{display:inline!important;vertical-align:baseline!important;width:1em;height:.6669em}.leaflet-left .leaflet-control-scale{margin-left:5px}.leaflet-bottom .leaflet-control-scale{margin-bottom:5px}.leaflet-control-scale-line{border:2px solid #777;border-top:none;line-height:1.1;padding:2px 5px 1px;white-space:nowrap;-moz-box-sizing:border-box;box-sizing:border-box;background:#fffc;text-shadow:1px 1px #fff}.leaflet-control-scale-line:not(:first-child){border-top:2px solid #777;border-bottom:none;margin-top:-2px}.leaflet-control-scale-line:not(:first-child):not(:last-child){border-bottom:2px solid #777}.leaflet-touch .leaflet-control-attribution,.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{box-shadow:none}.leaflet-touch .leaflet-control-layers,.leaflet-touch .leaflet-bar{border:2px solid rgba(0,0,0,.2);background-clip:padding-box}.leaflet-popup{position:absolute;text-align:center;margin-bottom:20px}.leaflet-popup-content-wrapper{padding:1px;text-align:left;border-radius:12px}.leaflet-popup-content{margin:13px 24px 13px 20px;line-height:1.3;font-size:13px;font-size:1.08333em;min-height:1px}.leaflet-popup-content p{margin:1.3em 0}.leaflet-popup-tip-container{width:40px;height:20px;position:absolute;left:50%;margin-top:-1px;margin-left:-20px;overflow:hidden;pointer-events:none}.leaflet-popup-tip{width:17px;height:17px;padding:1px;margin:-10px auto 0;pointer-events:auto;-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg)}.leaflet-popup-content-wrapper,.leaflet-popup-tip{background:#fff;color:#333;box-shadow:0 3px 14px #0006}.leaflet-container a.leaflet-popup-close-button{position:absolute;top:0;right:0;border:none;text-align:center;width:24px;height:24px;font:16px/24px Tahoma,Verdana,sans-serif;color:#757575;text-decoration:none;background:transparent}.leaflet-container a.leaflet-popup-close-button:hover,.leaflet-container a.leaflet-popup-close-button:focus{color:#585858}.leaflet-popup-scrolled{overflow:auto}.leaflet-oldie .leaflet-popup-content-wrapper{-ms-zoom:1}.leaflet-oldie .leaflet-popup-tip{width:24px;margin:0 auto;-ms-filter:"progid:DXImageTransform.Microsoft.Matrix(M11=0.70710678, M12=0.70710678, M21=-0.70710678, M22=0.70710678)";filter:progid:DXImageTransform.Microsoft.Matrix(M11=.70710678,M12=.70710678,M21=-.70710678,M22=.70710678)}.leaflet-oldie .leaflet-control-zoom,.leaflet-oldie .leaflet-control-layers,.leaflet-oldie .leaflet-popup-content-wrapper,.leaflet-oldie .leaflet-popup-tip{border:1px solid #999}.leaflet-div-icon{background:#fff;border:1px solid #666}.leaflet-tooltip{position:absolute;padding:6px;background-color:#fff;border:1px solid #fff;border-radius:3px;color:#222;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none;box-shadow:0 1px 3px #0006}.leaflet-tooltip.leaflet-interactive{cursor:pointer;pointer-events:auto}.leaflet-tooltip-top:before,.leaflet-tooltip-bottom:before,.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{position:absolute;pointer-events:none;border:6px solid transparent;background:transparent;content:""}.leaflet-tooltip-bottom{margin-top:6px}.leaflet-tooltip-top{margin-top:-6px}.leaflet-tooltip-bottom:before,.leaflet-tooltip-top:before{left:50%;margin-left:-6px}.leaflet-tooltip-top:before{bottom:0;margin-bottom:-12px;border-top-color:#fff}.leaflet-tooltip-bottom:before{top:0;margin-top:-12px;margin-left:-6px;border-bottom-color:#fff}.leaflet-tooltip-left{margin-left:-6px}.leaflet-tooltip-right{margin-left:6px}.leaflet-tooltip-left:before,.leaflet-tooltip-right:before{top:50%;margin-top:-6px}.leaflet-tooltip-left:before{right:0;margin-right:-12px;border-left-color:#fff}.leaflet-tooltip-right:before{left:0;margin-left:-12px;border-right-color:#fff}@media print{.leaflet-control{-webkit-print-color-adjust:exact;print-color-adjust:exact}}


:root {
  /* ── Light "Operational" Design System ─────────────────────────────── */
  /* Surfaces */
  --bg: #f4f6f9;
  --bg-grain: #eef1f6;
  --surface: #ffffff;
  --surface-2: #f9fafb;
  --surface-3: #f3f4f6;
  /* Borders */
  --border: #e5e7eb;
  --border-2: #d1d5db;
  --border-3: #c7cdd6;
  /* Ink (text) */
  --ink: #111827;
  --ink-2: #374151;
  --ink-3: #6b7280;
  --ink-4: #9ca3af;
  --ink-5: #c2c7d0;
  /* Brand / semantic */
  --primary: #1e40af;
  --primary-hover: #1d3fa8;
  --primary-soft: #eff6ff;
  --primary-border: #bfdbfe;
  --accent: #d97706;
  --accent-soft: #fffbeb;
  --accent-border: #fde68a;
  --success: #059669;
  --success-soft: #ecfdf5;
  --success-border: #a7f3d0;
  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --danger-border: #fecaca;
  --info: #0891b2;
  --info-soft: #ecfeff;
  --info-border: #a5f3fc;
  --violet: #7c3aed;
  --violet-soft: #f5f3ff;
  --violet-border: #ddd6fe;
  /* Radii */
  --radius-sm: 5px;
  --radius: 8px;
  --radius-lg: 12px;
  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(16,24,40,0.05);
  --shadow-md: 0 4px 8px -2px rgba(16,24,40,0.08), 0 2px 4px -2px rgba(16,24,40,0.05);
  --shadow-lg: 0 12px 20px -4px rgba(16,24,40,0.10), 0 4px 8px -4px rgba(16,24,40,0.06);
  /* Fonts */
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: 'Fira Code', ui-monospace, 'Cascadia Code', Menlo, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body, #root { height: 100%; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
button { font-family: inherit; background: none; border: none; color: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }
.mono, .num, code { font-family: var(--mono); font-variant-numeric: tabular-nums; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── App shell ──────────────────────────────────────────────────────── */
.app {
  display: grid;
  grid-template-columns: 232px 1fr;
  grid-template-rows: 56px 1fr 30px;
  height: 100vh;
  background: var(--bg);
}
.topbar {
  grid-column: 1 / -1;
  display: flex; align-items: center; gap: 12px;
  padding: 0 16px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 50;
}
.statusbar {
  grid-column: 1 / -1;
  display: flex; align-items: center; gap: 18px;
  padding: 0 16px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  font-size: 11.5px;
  color: var(--ink-3);
}
.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  overflow-y: auto;
}
.main {
  overflow: auto;
  background: var(--bg);
}

/* ── Topbar ─────────────────────────────────────────────────────────── */
.brand { display: flex; align-items: center; gap: 10px; padding-right: 16px; border-right: 1px solid var(--border); height: 100%; flex-shrink: 0; }
.brand-mark {
  width: 32px; height: 32px; border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), #2851c8);
  display:flex; align-items:center; justify-content:center;
  box-shadow: 0 2px 6px rgba(30,64,175,0.35);
  color: #fff; font-weight: 700; font-size: 15px;
}
.brand-name { font-weight: 700; font-size: 15px; letter-spacing: -0.01em; color: var(--ink); white-space: nowrap; }
.brand-sub { color: var(--ink-3); font-size: 11px; white-space: nowrap; }

.topbar-breadcrumb { display: flex; align-items: center; gap: 8px; color: var(--ink-3); font-size: 13px; white-space: nowrap; flex-shrink: 0; }
.topbar-breadcrumb .sep { color: var(--ink-5); }
.topbar-breadcrumb .here { color: var(--ink); font-weight: 600; }

.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 8px; }

/* Search box */
.search {
  display: flex; align-items: center; gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--ink-3);
  font-size: 13px;
  min-width: 240px;
}
.search:focus-within { border-color: var(--primary-border); background: var(--surface); box-shadow: 0 0 0 3px rgba(30,64,175,0.10); }
.search input { border: none; background: transparent; outline: none; color: var(--ink); flex: 1; font-size: 13px; }
.search kbd {
  font-family: var(--mono); font-size: 10.5px;
  padding: 1px 6px; border-radius: 4px;
  border: 1px solid var(--border-2); background: var(--surface);
  color: var(--ink-3);
}

.lang-select {
  padding: 6px 8px; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--surface-2);
  color: var(--ink-2); font-size: 12.5px; font-weight: 600;
  cursor: pointer;
}
.lang-select:hover { border-color: var(--border-3); }

.icon-btn {
  width: 34px; height: 34px; border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-3);
  border: 1px solid transparent;
  transition: all 0.15s;
}
.icon-btn:hover { background: var(--surface-3); color: var(--ink); border-color: var(--border); }

.avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #3b5baf);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 600;
}

/* ── Sidebar ────────────────────────────────────────────────────────── */
.sidebar-brand-pad { padding: 0; }
.nav-section {
  padding: 16px 14px 6px;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--ink-4);
}
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 9px 12px; margin: 2px 8px;
  border-radius: var(--radius);
  color: var(--ink-2);
  font-size: 13.5px; font-weight: 500;
  cursor: pointer;
  position: relative;
  width: calc(100% - 16px);
  text-align: left;
  transition: all 0.15s;
}
.nav-item:hover { background: var(--surface-3); color: var(--ink); }
.nav-item.active {
  background: var(--primary-soft);
  color: var(--primary);
  font-weight: 600;
}
.nav-item.active::before {
  content: ''; position: absolute; left: -8px; top: 6px; bottom: 6px;
  width: 3px; background: var(--primary); border-radius: 0 3px 3px 0;
}
.nav-item .count {
  margin-left: auto;
  font-size: 11px;
  color: var(--ink-3);
  padding: 1px 7px;
  border-radius: 10px;
  background: var(--surface-3);
}
.nav-item.active .count { background: rgba(30,64,175,0.12); color: var(--primary); }
.nav-item svg { flex-shrink: 0; opacity: 0.9; }

.sidebar-footer {
  margin-top: auto;
  padding: 12px;
  border-top: 1px solid var(--border);
}
.site-card {
  padding: 8px 10px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex; align-items: center; gap: 8px;
  font-size: 12px;
}
.site-card .label { color: var(--ink-4); font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; }
.site-card .name { color: var(--ink-2); font-weight: 600; }
/* Auto-hide sidebar: floats over the content as an overlay, closed by picking
   a screen or clicking the backdrop. Stays in the DOM when shut, so the nav
   items are always the same nodes. */
.nav-pin-row { display: flex; align-items: center; gap: 8px; padding: 10px 12px 2px; }
.sidebar-floating {
  position: fixed; top: 56px; bottom: 30px; left: 0; width: 268px; z-index: 150;
  box-shadow: var(--shadow-lg);
}
.nav-backdrop {
  position: fixed; inset: 0; z-index: 140;
  background: rgba(15,23,42,.28);
}

/* ── Screen layout ──────────────────────────────────────────────────── */
.screen { min-height: 100%; padding: 20px 24px 40px; }
.screen-header {
  display: flex; align-items: flex-end; justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
  gap: 16px; flex-wrap: wrap;
}
.screen-title-wrap h1 {
  font-size: 22px; font-weight: 700; letter-spacing: -0.02em;
  color: var(--ink);
}
.screen-title-wrap .sub { color: var(--ink-3); font-size: 13.5px; margin-top: 4px; }
.screen-title-wrap .kicker {
  color: var(--primary); font-size: 11.5px; font-weight: 600;
  letter-spacing: 0.04em; text-transform: uppercase; margin-bottom: 4px;
}
.screen-actions { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.order-file-menu { position: relative; }
.order-file-options {
  position: absolute; top: calc(100% + 4px); right: 0; z-index: 40;
  min-width: 170px; padding: 4px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 8px 24px #0002;
}
.order-file-option {
  display: block; width: 100%; padding: 8px 12px; border: 0; border-radius: 4px;
  background: transparent; color: var(--ink); font: inherit; font-size: 12.5px;
  text-align: left; text-decoration: none; white-space: nowrap; cursor: pointer;
}
.order-file-option:hover, .order-file-option:focus-visible { background: var(--primary-soft); outline: 2px solid var(--primary); outline-offset: -2px; }

/* ── Buttons ────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 14px;
  border: 1px solid var(--border-2);
  background: var(--surface);
  border-radius: var(--radius);
  color: var(--ink-2);
  font-size: 13px; font-weight: 500;
  transition: all 0.15s;
  white-space: nowrap;
}
.btn:hover { border-color: var(--border-3); background: var(--surface-3); color: var(--ink); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary {
  background: var(--primary); color: #fff;
  border-color: var(--primary);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); color: #fff; }
.btn-accent { background: var(--accent); color: #fff; border-color: var(--accent); font-weight: 600; }
.btn-accent:hover { background: #b8650a; border-color: #b8650a; color: #fff; }
.btn-success { background: var(--success); color: #fff; border-color: var(--success); font-weight: 600; }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-ghost:hover { background: var(--surface-3); }
.btn-sm { padding: 5px 10px; font-size: 12px; }
.btn-xs { padding: 3px 8px; font-size: 11.5px; }
.btn-danger { color: var(--danger); border-color: var(--danger-border); background: var(--danger-soft); }
.btn-danger:hover { background: var(--danger); color: #fff; border-color: var(--danger); }

/* ── Cards ──────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.card-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  gap: 8px;
}
.card-title {
  font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--ink-3);
}
.card-body { padding: 16px; }
.card-tabs { display: flex; gap: 2px; align-items: center; }
.card-tab {
  padding: 4px 10px;
  font-size: 12px;
  color: var(--ink-3);
  border-radius: 5px;
  font-weight: 500;
}
.card-tab:hover { color: var(--ink); background: var(--surface-3); }
.card-tab.active { background: var(--primary-soft); color: var(--primary); }

/* ── KPI tile ───────────────────────────────────────────────────────── */
.kpi {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  display: flex; flex-direction: column;
  min-height: 96px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.kpi-label {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--ink-3);
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  margin-bottom: 8px;
}
.kpi-label .ico { width: 30px; height: 30px; border-radius: 8px; display:flex; align-items:center; justify-content:center; }
.kpi-value {
  font-family: var(--mono);
  font-size: 28px;
  font-weight: 600;
  color: var(--ink);
  line-height: 1;
  letter-spacing: -0.02em;
}
.kpi-value .unit { font-size: 14px; color: var(--ink-3); margin-left: 4px; font-weight: 400; }
.kpi-delta { margin-top: 8px; font-size: 11.5px; color: var(--ink-3); display: flex; align-items: center; gap: 6px; }
.kpi-delta .up { color: var(--success); font-weight: 600; }
.kpi-delta .down { color: var(--danger); font-weight: 600; }
.kpi-spark { position: absolute; right: 12px; bottom: 10px; width: 80px; height: 28px; opacity: 0.85; }
.kpi-accent::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0;
  width: 3px; background: var(--primary);
}

/* ── Grid helpers ───────────────────────────────────────────────────── */
.grid { display: grid; gap: 14px; }
.g-cols-2 { grid-template-columns: repeat(2, 1fr); }
.g-cols-3 { grid-template-columns: repeat(3, 1fr); }
.g-cols-4 { grid-template-columns: repeat(4, 1fr); }
.g-cols-5 { grid-template-columns: repeat(5, 1fr); }

/* ── Tables ─────────────────────────────────────────────────────────── */
table.data { width: 100%; border-collapse: collapse; font-size: 13px; }
table.data th {
  text-align: left;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--ink-3);
  padding: 9px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
  position: sticky; top: 0;
}
table.data td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  color: var(--ink-2);
  vertical-align: middle;
}
table.data tr:hover td { background: var(--surface-2); }
table.data tr:last-child td { border-bottom: none; }

/* ── Tags / pills ───────────────────────────────────────────────────── */
.tag {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 2px 9px;
  border-radius: 5px;
  font-size: 11.5px;
  font-weight: 600;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--ink-2);
}
.tag.amber { color: var(--accent); border-color: var(--accent-border); background: var(--accent-soft); }
.tag.blue  { color: var(--primary); border-color: var(--primary-border); background: var(--primary-soft); }
.tag.cyan  { color: var(--info); border-color: var(--info-border); background: var(--info-soft); }
.tag.green { color: var(--success); border-color: var(--success-border); background: var(--success-soft); }
.tag.red   { color: var(--danger); border-color: var(--danger-border); background: var(--danger-soft); }
.tag.violet{ color: var(--violet); border-color: var(--violet-border); background: var(--violet-soft); }
.tag.pink{ color: #db2777; border-color: #fbcfe8; background: #fdf2f8; }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 20px;
  font-size: 12px; font-weight: 500;
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--ink-2);
}
.pill-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--success); }
.pill-dot.amber { background: var(--accent); }
.pill-dot.red { background: var(--danger); }
.pill-dot.cyan { background: var(--info); }

/* ── Inputs ─────────────────────────────────────────────────────────── */
.input, input.input, select.input, textarea.input {
  padding: 8px 11px;
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-size: 13px;
  width: 100%;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.input:focus, input.input:focus, select.input:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(30,64,175,0.12);
}
.input::placeholder { color: var(--ink-4); }
select.input { cursor: pointer; }
.field { display: flex; flex-direction: column; gap: 4px; }
.field > label { font-size: 11.5px; font-weight: 600; color: var(--ink-3); }

/* small table-row inputs */
.input-sm { padding: 4px 4px !important; font-size: 12px !important; min-width: 0; text-align: center; }

/* Editable tables (with inline inputs): tighten cell padding so numeric
   values are not clipped to invisibility in the narrow side panels. */
table.data:has(.input-sm) th,
table.data:has(.input-sm) td { padding: 5px 3px; }
table.data:has(.input-sm) td:first-child,
table.data:has(.input-sm) th:first-child { padding-left: 8px; }
table.data:has(.input-sm) td:last-child,
table.data:has(.input-sm) th:last-child { padding-right: 8px; }
/* text-ish first column (ID) reads better left-aligned + a bit wider */
table.data:has(.input-sm) td:first-child .input-sm { text-align: left; min-width: 46px; }

/* Drop native number spinners on compact inputs — they steal horizontal room. */
input.input-sm[type="number"] { -moz-appearance: textfield; appearance: textfield; }
input.input-sm[type="number"]::-webkit-outer-spin-button,
input.input-sm[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* ── 3D stage ───────────────────────────────────────────────────────── */
.stage {
  position: relative;
  background:
    radial-gradient(ellipse at 50% 30%, rgba(30,64,175,0.04), transparent 70%),
    linear-gradient(180deg, #fbfcfe 0%, #eef2f8 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.stage-canvas { position: absolute; inset: 0; }
.stage-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(30,64,175,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(30,64,175,0.04) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse 70% 70% at center, black, transparent 95%);
}
.stage-chrome {
  position: absolute; top: 12px; left: 14px; right: 14px;
  display: flex; align-items: flex-start; justify-content: space-between;
  flex-wrap: wrap;
  pointer-events: none;
  z-index: 5;
  gap: 10px;
}
.stage-chrome > * { pointer-events: auto; }
.stage-hud {
  position: absolute; bottom: 12px; left: 14px; right: 14px;
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 12px; pointer-events: none;
  z-index: 5;
}
.stage-hud > * { pointer-events: auto; }
.hud-block {
  background: rgba(255,255,255,0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 11px;
  display: flex; flex-direction: column; gap: 2px;
  min-width: 92px;
  box-shadow: var(--shadow-sm);
}
.hud-lbl { font-size: 10px; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.05em; font-weight: 600; }
.hud-val { font-family: var(--mono); font-size: 15px; color: var(--ink); font-weight: 600; }
.axes {
  position: absolute; bottom: 14px; right: 14px;
  width: 56px; height: 56px; pointer-events: none;
}

/* ── Misc ───────────────────────────────────────────────────────────── */
.divider-v { width: 1px; background: var(--border); align-self: stretch; margin: 0 6px; }
.scroll { overflow: auto; }
.scroll::-webkit-scrollbar { width: 10px; height: 10px; }
.scroll::-webkit-scrollbar-thumb { background: var(--border-2); border-radius: 5px; border: 2px solid var(--surface); }
.scroll::-webkit-scrollbar-thumb:hover { background: var(--border-3); }
.scroll::-webkit-scrollbar-track { background: transparent; }

/* feed */
.feed { display: flex; flex-direction: column; }
.feed-row {
  display: grid; grid-template-columns: 64px 1fr auto;
  gap: 12px; align-items: center;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
.feed-row:last-child { border-bottom: none; }
.feed-time { font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.feed-text { color: var(--ink-2); }

/* progress / meter */
.progress { height: 6px; background: var(--surface-3); border-radius: 3px; overflow: hidden; position: relative; }
.progress-bar { position: absolute; left:0; top:0; bottom:0; background: var(--primary); border-radius: 3px; }

/* segmented */
.segmented { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border-2); border-radius: var(--radius); padding: 2px; gap: 2px; }
.seg {
  padding: 5px 12px; font-size: 12.5px; color: var(--ink-3); border-radius: 5px;
  font-weight: 500;
}
.seg.active { background: var(--surface); color: var(--primary); box-shadow: var(--shadow-sm); font-weight: 600; }
.seg:hover { color: var(--ink); }

/* switch toggle */
.switch { width: 38px; height: 22px; border-radius: 12px; background: var(--border-2); position: relative; transition: background 0.2s; cursor: pointer; }
.switch.on { background: var(--primary); }
.switch::after { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; background: #fff; top: 2px; left: 2px; transition: left 0.2s; box-shadow: var(--shadow-sm); }
.switch.on::after { left: 18px; }

/* meter row */
.meter { display: flex; align-items: center; gap: 10px; }
.meter-bar { flex: 1; height: 8px; background: var(--surface-3); border-radius: 4px; overflow: hidden; position: relative; }
.meter-fill { height: 100%; background: var(--primary); border-radius: 4px; transition: width 0.3s; }
.meter-fill.cyan { background: var(--info); }
.meter-fill.green { background: var(--success); }
.meter-fill.red { background: var(--danger); }
.meter-fill.amber { background: var(--accent); }
.meter-fill.violet { background: var(--violet); }
.meter-val { font-family: var(--mono); font-size: 12px; color: var(--ink-2); min-width: 50px; text-align: right; font-weight: 600; }

/* chart helpers */
.chart-grid { stroke: var(--border); stroke-width: 1; }
.chart-axis { font-family: var(--mono); font-size: 9.5px; fill: var(--ink-3); }
.chart-label { font-family: var(--sans); font-size: 10.5px; fill: var(--ink-2); }

/* alert / toast boxes */
.alert { padding: 12px 16px; border-radius: var(--radius); font-size: 13px; display: flex; align-items: center; gap: 10px; border: 1px solid; margin-bottom: 14px; }
.alert-error { background: var(--danger-soft); border-color: var(--danger-border); color: var(--danger); }
.alert-success { background: var(--success-soft); border-color: var(--success-border); color: var(--success); }
.alert-info { background: var(--info-soft); border-color: var(--info-border); color: var(--info); }
/* Not an error and not information: something the operator should see
   before running, like an item too large for every bin. */
.alert-warn { background: var(--accent-soft); border-color: var(--accent-border); color: var(--accent); }

/* scanning dots (loading) */
.dots { display: inline-flex; gap: 4px; }
.dots span { width: 5px; height: 5px; border-radius: 50%; background: currentColor; opacity: 0.35; animation: dot 1.2s infinite; }
.dots span:nth-child(2) { animation-delay: 0.2s; }
.dots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes dot { 0%,100% { opacity: 0.25; transform: scale(0.9); } 50% { opacity: 1; transform: scale(1.1); } }

/* spinner */
.spinner { width: 16px; height: 16px; border: 2px solid var(--border-2); border-top-color: var(--primary); border-radius: 50%; animation: spin 0.8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* layout utilities */
.row { display: flex; gap: 14px; }
.col { display: flex; flex-direction: column; gap: 14px; }
.flex { display: flex; }
.flex-1 { flex: 1; min-width: 0; }
.between { display:flex; align-items:center; justify-content:space-between; }
.center { display:flex; align-items:center; justify-content:center; }
.gap-4 { gap: 4px; } .gap-6 { gap: 6px; } .gap-8 { gap: 8px; } .gap-10 { gap: 10px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; }
.mt-4 { margin-top: 4px; } .mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mb-8 { margin-bottom: 8px; } .mb-12 { margin-bottom: 12px; }
.muted { color: var(--ink-3); }
.mono-xs { font-family: var(--mono); font-size: 11px; }
.ink2 { color: var(--ink-2); }
.ink3 { color: var(--ink-3); }
.ink4 { color: var(--ink-4); }
.bold { font-weight: 600; }
.amber { color: var(--accent); }
.blue { color: var(--primary); }
.cyan { color: var(--info); }
.green { color: var(--success); }
.red { color: var(--danger); }

/* fade-in */
@keyframes fadeUp { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.enter { animation: fadeUp 0.35s ease both; }
.enter-1 { animation-delay: 0.04s; } .enter-2 { animation-delay: 0.08s; } .enter-3 { animation-delay: 0.12s; } .enter-4 { animation-delay: 0.16s; }

/* Leaflet overrides for light theme */
.leaflet-container { background: #e8edf4; font-family: var(--sans); }
.leaflet-popup-content-wrapper { border-radius: var(--radius); box-shadow: var(--shadow-md); }
.leaflet-popup-content { margin: 10px 14px; font-size: 12.5px; color: var(--ink); }
.route-marker {
  background: var(--accent); color: #fff; border: 2px solid #fff;
  border-radius: 50%; width: 26px; height: 26px;
  display:flex; align-items:center; justify-content:center;
  font-weight: 700; font-size: 12px; font-family: var(--mono);
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.route-marker.depot { background: var(--primary); width: 32px; height: 32px; }

/* Responsive */
@media (max-width: 1024px) {
  .app { grid-template-columns: 60px 1fr; }
  .nav-item span:not(.count), .brand-name, .brand-sub, .nav-section { display: none; }
  .nav-item { justify-content: center; }
  .search { min-width: 160px; }
}
@media (max-width: 768px) {
  .app { grid-template-columns: 1fr; grid-template-rows: 56px 1fr 30px; }
  .sidebar { display: none; }
  .screen { padding: 16px; }
  .screen-header { flex-direction: column; align-items: flex-start; gap: 10px; }
  .grid { grid-template-columns: 1fr !important; }
  .kpi-value { font-size: 24px; }
  .search { display: none; }
}

/* a11y: focus + reduced motion */
*:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; border-radius: 3px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

/* Analytics uses measured events only; no external chart dependency. */
.screen-analytics { display: grid; gap: 16px; }
.analytics-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.analytics-header h1 { font-size: 20px; font-weight: 650; }
.analytics-controls { display: flex; gap: 8px; }
.analytics-controls select, .btn-refresh { padding: 7px 10px; border: 1px solid var(--border-2); border-radius: var(--radius); background: var(--surface); }
.analytics-controls select:focus-visible, .btn-refresh:focus-visible { outline: 2px solid var(--primary); }
.btn-refresh:hover { border-color: var(--primary); color: var(--primary); }
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
.kpi-card, .chart-card, .analytics-table { padding: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.kpi-label { color: var(--ink-3); font-size: 12px; }
.kpi-value { color: var(--ink); font-size: 22px; font-weight: 650; font-variant-numeric: tabular-nums; }
.kpi-unit { font-size: 12px; font-weight: 400; color: var(--ink-3); }
.charts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; }
.chart-card h3, .analytics-table h3 { font-size: 13px; margin-bottom: 12px; }
.analytics-bar-row { display: grid; grid-template-columns: minmax(85px, auto) 1fr 24px; align-items: center; gap: 8px; margin: 8px 0; font-size: 11px; }
.analytics-bar-track { height: 10px; background: var(--surface-3); border-radius: 6px; overflow: hidden; }
.analytics-bar { height: 100%; background: var(--primary); border-radius: 6px; }
.analytics-table { overflow-x: auto; }
.analytics-table table { width: 100%; border-collapse: collapse; font-size: 12px; text-align: left; }
.analytics-table th, .analytics-table td { padding: 8px; border-bottom: 1px solid var(--border); }
.analytics-table th { color: var(--ink-3); font-weight: 600; }
