.mobile-menu-trigger,.mobile-room-select,.mobile-work-menu:not([open]) { display:none; }
@media (max-width:760px), (max-width:1000px) and (max-height:550px) {
  #stage {
    --rail-width:0px;
    --context-width:0px;
    --desk-bottom:0px;
    --header-height:calc(54px + env(safe-area-inset-top,0px));
  }
  #stage.has-mobile-navigation.staff-workspace { --header-height:calc(52px + env(safe-area-inset-top,0px)); }
  #stage > header,#stage #staff-masthead {
    padding-top:env(safe-area-inset-top,0px);
    padding-left:max(10px,env(safe-area-inset-left,0px));
    padding-right:max(10px,env(safe-area-inset-right,0px));
    min-width:0;
    gap:6px;
  }
  #stage > header .brand { min-width:0; gap:6px; }
  #stage > header .brand svg { width:23px; flex:none; }
  #stage > header .breadcrumb { display:none; }
  #stage > header .notification-button,#stage > header .profile { min-width:44px; min-height:44px; justify-content:center; }
  #stage > header .search { flex:1 1 9rem; width:auto; max-width:20rem; }
  #stage > header .search input { font-size:16px; }
  #stage > header .checkin { display:none; }
  #stage.company-floor-mode > header .checkin { display:flex; align-items:center; min-height:44px; margin-left:auto; }
  #stage:not(.staff-workspace):not(.company-floor-mode) > header .mobile-menu-trigger {
    display:inline-flex; align-items:center; justify-content:center;
    min-height:44px; min-width:44px; padding:0 7px; color:inherit; border:0;
    background:transparent; font:600 14px/1.3 var(--font-ui,system-ui); white-space:nowrap;
  }
  #stage.has-mobile-navigation #sidebar { display:none; }
  #stage.has-mobile-navigation #panel {
    left:0; right:0; bottom:0; top:var(--header-height); max-width:none; width:auto;
  }
  #stage #space-context { display:none; }
  #stage .map { left:0; right:0; top:var(--header-height); bottom:0; }
  #stage > .tour-button { display:none; }

  .mobile-work-menu[open] {
    position:fixed; inset:auto 0 0; margin:0 auto; box-sizing:border-box;
    width:min(100%,30rem); max-width:100%; max-height:calc(100dvh - 24px);
    overflow:auto; overscroll-behavior:contain; padding:14px max(16px,env(safe-area-inset-right,0px)) max(18px,env(safe-area-inset-bottom,0px)) max(16px,env(safe-area-inset-left,0px));
    background:#fff; color:#183978; border:1px solid #d4def3; border-radius:16px 16px 0 0;
    box-shadow:0 -6px 28px #10285a24;
  }
  .mobile-work-menu::backdrop { background:#10295164; }
  .mobile-menu-heading { display:flex; align-items:center; justify-content:space-between; margin-bottom:8px; }
  .mobile-menu-heading h2 { margin:0; font-size:18px; color:#142c5f; }
  .mobile-work-menu button { background:transparent; color:inherit; font:inherit; min-height:44px; }
  .mobile-menu-heading button { padding:5px 11px; color:#395db0; }
  .mobile-work-menu nav { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:6px; }
  .mobile-work-menu nav button { text-align:left; padding:8px 12px; border:1px solid #dce4f4; border-radius:6px; font-size:15px; }
  .mobile-work-menu nav button[aria-current] { color:#234fce; background:#edf2ff; border-color:#a8bff5; }
  .mobile-work-menu button:focus-visible,.mobile-menu-trigger:focus-visible { outline:2px solid #315bdd; outline-offset:-2px; }

  #stage .map-title { top:10px; left:max(14px,env(safe-area-inset-left,0px)); }
  #stage .map-title h1 { font-size:21px; line-height:1.25; }
  #stage .map-title p { margin:2px 0 0; font-size:12px; }
  #stage .map > .filters {
    position:absolute; top:69px; left:max(12px,env(safe-area-inset-left,0px)); right:max(12px,env(safe-area-inset-right,0px));
    width:auto; max-width:26rem; display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); align-items:stretch; gap:5px;
    pointer-events:none;
  }
  #stage .map > .filters > * { pointer-events:auto; }
  #stage .map > .filters > #home-floor-switch { grid-column:span 3; }
  #home-floor-switch label,#home-floor-switch select { width:100%; min-width:0; }
  #stage .map > .filters .mobile-room-select {
    display:block; grid-column:span 3; width:100%; min-width:0; appearance:auto; border:1px solid #9bb3fb;
    background:#234fda; border-radius:6px; padding:0 8px; color:white;
  }
  #stage .map > .filters select,#stage .sf-toolbar select,#stage .rm-toolbar select { min-height:44px; font-size:16px; }
  #stage .map > .filters select option,#stage .map > .filters select optgroup { color:#1e3d78; background:white; }
  #stage .map > .filters > span { grid-column:span 2; display:flex; align-items:center; justify-content:center; min-height:44px; padding:4px 2px; border-radius:6px; font-size:13px; white-space:nowrap; }
  #stage .map > .filters > span:focus-visible { outline:2px solid white; outline-offset:1px; }
  #stage .map > .filters > svg { display:none; }
  #stage .map > .home-personal[hidden] { display:none; }
  #stage .map > .home-personal { top:auto; left:max(12px,env(safe-area-inset-left,0px)); bottom:calc(67px + env(safe-area-inset-bottom,0px)); }
  #stage .map > .home-personal button { min-height:44px; }
  #stage .map .controls {
    width:max-content; max-width:calc(100% - 16px); left:50%; right:auto; transform:translateX(-50%);
    bottom:calc(7px + env(safe-area-inset-bottom,0px)); padding:2px 4px; min-height:46px;
    gap:2px; flex-wrap:nowrap; justify-content:center;
  }
  #stage .controls button,#stage .sf-camera button,#stage .rm-camera button { min-height:44px; min-width:44px; }
  #stage .controls #view { min-width:76px; }
  #stage .controls #reset { padding:0 7px; }
  #stage .controls output { min-width:4ch; }
  #stage :is(.sf-head,.rm-head,.sf-foot,.rm-foot) { left:max(12px,env(safe-area-inset-left,0px)); right:max(12px,env(safe-area-inset-right,0px)); }
  #stage :is(.sf-foot,.rm-foot) { padding-bottom:env(safe-area-inset-bottom,0px); }
  #stage .sf-camera,#stage .rm-camera { max-width:100%; gap:2px; padding:2px 4px; }
  #stage :is(.blueprint-footer,.server-room-footer) {
    padding-bottom:env(safe-area-inset-bottom,0px); left:max(10px,env(safe-area-inset-left,0px)); right:max(10px,env(safe-area-inset-right,0px));
  }
  #stage :is(.blueprint-controls,.server-controls) { max-width:100%; flex-wrap:nowrap; gap:2px; padding:2px 5px; }
  #stage :is(.blueprint-controls,.server-controls,.blueprint-pagination) button { min-height:44px; min-width:44px; }
  #stage .blueprint-popover { overscroll-behavior:contain; }
  #stage .blueprint-popover button { min-height:44px; }
  #stage #staff-masthead .sc-actions { gap:2px; }
  #stage #staff-masthead button { min-height:44px; }
  #stage #staff-masthead .sc-profile { min-width:44px; justify-content:center; }
}
@media (max-width:380px) {
  #stage > header .brand>div { display:none; }
}
@media (max-width:1000px) and (max-height:550px) and (min-width:560px) {
  #stage .map > .filters { left:auto; top:7px; width:min(56%,26rem); }
  #stage .map > .home-personal { bottom:calc(8px + env(safe-area-inset-bottom,0px)); }
  #stage .map .controls { left:auto; transform:none; right:max(10px,env(safe-area-inset-right,0px)); }
}
