/* Mobile-only shell; tablet and desktop retain the existing navigation. */
.mobile-bottom-nav,.mobile-header-mark,.mobile-parent-back{display:none}
.mobile-navigation-sheet{box-sizing:border-box;width:min(520px,calc(100vw - 24px));max-height:calc(100dvh - 100px - env(safe-area-inset-bottom));padding:16px;border:1px solid #dce4e6;border-radius:10px;color:#18333a;background:#fff;overscroll-behavior:contain}
.mobile-navigation-sheet::backdrop{background:#18333a66}
.mobile-sheet-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}
.mobile-sheet-heading h2{margin:0;font-size:20px}
.mobile-sheet-heading button{min-width:44px;min-height:44px}
.mobile-destinations{display:grid;grid-template-columns:minmax(0,1fr);gap:4px;margin-top:12px}
.mobile-destinations>a,.mobile-destinations>button{display:flex;align-items:center;gap:12px;padding:12px;min-height:48px;text-align:left;text-decoration:none;border:0;border-radius:5px;background:white;color:#25434a;font:500 14px/1.4 Arial}
.mobile-destinations svg{flex:none;width:24px;height:24px}
.mobile-destinations [aria-current="page"]{background:#f8eef1;color:#800020;font-weight:700}
.mobile-utility-slot #mainNavMenu{display:flex;flex-wrap:wrap;gap:8px;margin:12px 0;min-width:0}
.mobile-utility-slot #mainNavMenu>.header-icon-button,.mobile-utility-slot .settings-menu-wrap>.header-icon-button{width:44px!important;height:44px!important;min-width:44px;min-height:44px}
.mobile-utility-slot #navAuthorizations,.mobile-utility-slot #navWorkflow,.mobile-utility-slot #dashboardHome,.mobile-utility-slot .program-header-actions{display:none!important}
.mobile-utility-slot #locationSwitcher{flex:1 1 100%;min-width:0}
.mobile-utility-slot #locationSwitcher>.app-nav-group-toggle{display:flex;width:100%;min-height:44px;gap:8px;align-items:center}
.mobile-utility-slot .location-switcher-name{display:block;flex:1}
.mobile-utility-slot .location-switcher-icon{width:24px;height:24px;flex:none}
.mobile-utility-slot .location-switcher-chevron{width:18px;height:18px}
.mobile-utility-slot .settings-dropdown,.mobile-utility-slot #locationSwitcher>.app-nav-dropdown{position:fixed!important;inset:auto 12px 90px!important;width:calc(100% - 24px)!important;max-width:none;max-height:55dvh;overflow:auto;z-index:2300;background:white}
@media screen and (max-width:760px){
 body.mobile-app-shell{padding-bottom:calc(84px + env(safe-area-inset-bottom))!important}
 .mobile-app-shell .app-shell-header>.app-top-row{display:none!important}
 .mobile-app-shell .app-shell-header>.app-module-nav{min-height:64px;padding:calc(8px + env(safe-area-inset-top)) 12px 8px;gap:8px!important}
 .mobile-app-shell .app-module-nav>.app-nav-identity,.mobile-app-shell .app-module-toggle,.mobile-app-shell .app-module-links{display:none!important}
 .mobile-app-shell .mobile-header-mark{display:block;width:36px;height:36px;flex:none;object-fit:contain}
 .mobile-app-shell .mobile-parent-back:not([hidden]){display:flex;align-items:center;justify-content:center;width:44px;height:44px;min-height:44px;padding:0;flex:none}
 .mobile-parent-back svg{width:24px;height:24px}
 .mobile-app-shell .app-module-nav #appPageTitle{font-size:18px;white-space:normal}
 .mobile-app-shell .app-compact-actions{margin-left:auto}
 .mobile-app-shell .mobile-bottom-nav:not([hidden]){display:flex;position:fixed;bottom:0;left:0;right:0;z-index:1500;min-height:64px;padding:4px 4px calc(4px + env(safe-area-inset-bottom));background:#fff;border-top:1px solid #dce4e6;justify-content:space-around;box-sizing:border-box}
 .mobile-bottom-nav>a,.mobile-bottom-nav>button{display:flex;flex:1 1 0;min-width:0;min-height:56px;flex-direction:column;align-items:center;justify-content:center;gap:4px;padding:5px 2px;border:0;border-radius:5px;background:white;text-decoration:none;color:#64747a;font:500 11px/1.3 Arial}
 .mobile-bottom-nav [hidden]{display:none!important}
 .mobile-bottom-nav svg{width:24px;height:24px;flex:none}
 .mobile-bottom-nav [aria-current="page"],.mobile-bottom-nav [aria-expanded="true"]{color:#800020;background:#fcf5f7}
 .mobile-bottom-nav :focus-visible,.mobile-destinations :focus-visible{outline:3px solid #800020;outline-offset:-3px}
 body.mobile-app-shell:has(dialog[open]:not(.mobile-navigation-sheet)) .mobile-bottom-nav{display:none!important}
 .mobile-app-shell .app-toast{transform:translateY(calc(-76px - env(safe-area-inset-bottom)));max-height:35dvh}
 .mobile-app-shell :is(main,.workspace,.document-setup){scroll-padding-bottom:calc(90px + env(safe-area-inset-bottom))}
}
@media print{.mobile-bottom-nav,.mobile-navigation-sheet,.mobile-header-mark,.mobile-parent-back{display:none!important}}

.mobile-app-shell .mobile-utility-slot #mainNavMenu.header-right{display:flex!important;visibility:visible!important;position:static!important;width:100%;max-height:none;overflow:visible;flex-wrap:wrap}

.mobile-dialog-back{display:none}
@media screen and (max-width:760px){.mobile-dialog-back{display:flex;align-items:center;justify-content:center;flex:0 0 44px;width:44px;height:44px;min-height:44px;padding:0;margin-right:8px}.mobile-dialog-back svg{width:24px;height:24px}dialog header:has(.mobile-dialog-back){display:flex;align-items:center;gap:8px}dialog header:has(.mobile-dialog-back)>h2{flex:1;min-width:0}}

/* Bottom destinations use plain icons, with color and weight for active state. */
.mobile-bottom-nav>a,.mobile-bottom-nav>button,.mobile-bottom-nav [aria-current="page"],.mobile-bottom-nav [aria-expanded="true"]{background:transparent!important;box-shadow:none!important}
.mobile-bottom-nav>a>svg,.mobile-bottom-nav>button>svg,.mobile-bottom-nav>a>span,.mobile-bottom-nav>button>span{background:transparent!important;background-image:none!important;border:0!important;border-radius:0!important;box-shadow:none!important}
.mobile-bottom-nav [aria-current="page"]>span,.mobile-bottom-nav [aria-expanded="true"]>span{font-weight:700}
.mobile-bottom-nav>a::before,.mobile-bottom-nav>a::after,.mobile-bottom-nav>button::before,.mobile-bottom-nav>button::after{content:none!important}

/* More uses the same three icon-only utility controls as the desktop bar. */
.mobile-app-shell .mobile-utility-slot #mainNavMenu>.header-icon-button,
.mobile-app-shell .mobile-utility-slot .settings-menu-wrap>.header-icon-button{display:inline-flex!important;align-items:center;justify-content:center;flex:0 0 44px!important;width:44px!important;height:44px!important;min-width:44px!important;padding:0!important;font-size:0!important;gap:0!important}
.mobile-app-shell .mobile-utility-slot #mainNavMenu>.header-icon-button::before,
.mobile-app-shell .mobile-utility-slot #mainNavMenu>.header-icon-button::after,
.mobile-app-shell .mobile-utility-slot .settings-menu-wrap>.header-icon-button::before,
.mobile-app-shell .mobile-utility-slot .settings-menu-wrap>.header-icon-button::after{content:none!important;display:none!important}
.mobile-utility-slot .header-icon-button>span{display:none!important}
.mobile-utility-slot .header-icon-button>svg{display:block;flex:none;width:24px;height:24px;margin:0}
.mobile-utility-slot #mainNavMenu>.settings-menu-wrap{flex:0 0 44px!important;width:44px!important;min-width:44px!important}

@media screen and (max-width:1030px){
 .app-module-links>.app-nav-group,.app-module-links>.app-nav-group>.app-nav-group-toggle,.app-module-links>.app-nav-onboarding,.app-nav-dropdown>a,.mobile-destinations>a,.mobile-destinations>button,.settings-dropdown>button{border-top:0!important;border-bottom:0!important;box-shadow:none!important}
 .app-module-links>.app-nav-group{border:0!important}
 .settings-dropdown>hr,.mobile-destinations>hr{display:none}
}

.mobile-app-shell .mobile-utility-slot #mainNavMenu>#navAuthorizations,
.mobile-app-shell .mobile-utility-slot #mainNavMenu>#navWorkflow,
.mobile-app-shell .mobile-utility-slot #mainNavMenu>#dashboardHome{display:none!important}

.mobile-onboarding-shortcut{display:flex;align-items:center;gap:10px;min-height:48px;padding:12px;margin-top:12px;border-radius:6px;background:#faf0f3;color:#800020;text-decoration:none;font:600 14px/1.4 Arial}
.mobile-onboarding-shortcut>svg{width:24px;height:24px;flex:none}
.mobile-menu-group{display:grid;gap:4px;margin:4px 0 12px;min-width:0}
.mobile-menu-group>h3{margin:8px 12px 4px;color:#64747a;font-size:12px;font-weight:700;line-height:1.5}
.mobile-menu-group>a,.mobile-menu-group>button{display:flex;align-items:center;gap:12px;min-height:48px;padding:12px;border:0;border-radius:5px;background:white;color:#25434a;text-align:left;text-decoration:none;font:500 14px/1.4 Arial}
.mobile-menu-group>a>svg,.mobile-menu-group>button>svg{width:24px;height:24px;flex:none}
.mobile-menu-group [aria-current="page"]{color:#800020;background:#fcf5f7;font-weight:700}
.mobile-utility-slot #mainNavMenu.header-right{box-sizing:border-box;padding:12px!important;border:1px solid #e1e6e8;border-radius:6px;box-shadow:none!important;background:#fff}

.mobile-app-shell .mobile-utility-slot #mainNavMenu.header-right{display:grid!important;grid-template-columns:44px 44px 44px minmax(0,1fr);justify-content:start;align-items:center;gap:8px!important}
.mobile-app-shell .mobile-utility-slot #locationSwitcher{grid-column:1/-1;width:100%;max-width:none;margin:0}
.mobile-app-shell .mobile-utility-slot #locationSwitcher>.app-nav-group-toggle{width:100%;max-width:none}

.mobile-app-shell .mobile-utility-slot{position:relative}
.mobile-app-shell .mobile-utility-slot #mainNavMenu.header-right{grid-template-columns:minmax(0,1fr) 44px}
.mobile-app-shell .mobile-utility-slot #locationSwitcher{grid-column:1}
.mobile-utility-toggle{display:flex;align-items:center;justify-content:center;grid-column:2;width:44px;min-width:44px;height:44px;min-height:44px;padding:0}
.mobile-utility-toggle[hidden]{display:none!important}
.mobile-utility-toggle svg{width:24px;height:24px}
.mobile-utility-menu{position:absolute;right:12px;top:calc(100% - 8px);z-index:2400;display:flex;gap:8px;align-items:center;padding:10px;border:1px solid #dce4e6;border-radius:6px;background:white;box-shadow:0 4px 12px #18333a18}
.mobile-utility-menu[hidden]{display:none!important}
.mobile-app-shell .mobile-utility-menu>.header-icon-button,.mobile-app-shell .mobile-utility-menu>.settings-menu-wrap>.header-icon-button{display:flex!important;align-items:center;justify-content:center;width:44px!important;min-width:44px;min-height:44px;height:44px!important;padding:0!important;font-size:0!important}
.mobile-utility-menu .header-icon-button::after,.mobile-utility-menu .header-icon-button::before{display:none!important;content:none!important}

.mobile-app-shell .mobile-utility-slot #locationSwitcher>.app-nav-group-toggle{box-sizing:border-box;padding-left:8px!important;padding-right:8px!important;gap:8px}

@media screen and (max-width:760px){
 .mobile-bottom-nav>a,.mobile-bottom-nav>button{display:grid!important;grid-template-rows:24px 16px;align-content:center;justify-items:center;align-items:end;gap:5px;padding:6px 2px}
 .mobile-bottom-nav>a>svg,.mobile-bottom-nav>button>svg{display:block;width:24px;height:24px;margin:0;align-self:end}
 .mobile-bottom-nav>a>span,.mobile-bottom-nav>button>span{display:block!important;position:static!important;min-width:0;width:auto;height:16px;margin:0;padding:0;font:500 11px/16px Arial;white-space:nowrap;align-self:start}
 .mobile-bottom-nav [data-destination="dashboard"]>svg,.mobile-bottom-nav [data-destination="workflow"]>svg{transform:translateY(1px)}
 .mobile-bottom-nav [data-destination="operations"]>svg,.mobile-bottom-nav [data-destination="more"]>svg{transform:translateY(2px)}
 .mobile-bottom-nav [aria-current="page"]>span{font-weight:700}
}

/* Keep nested-route selection visible on its bottom-navigation parent. */
@media screen and (max-width:760px){
 .mobile-bottom-nav>[aria-current="page"],.mobile-bottom-nav>[aria-expanded="true"]{color:#800020!important}
 .mobile-bottom-nav>[aria-current="page"]>svg,.mobile-bottom-nav>[aria-current="page"]>span,.mobile-bottom-nav>[aria-expanded="true"]>svg,.mobile-bottom-nav>[aria-expanded="true"]>span{color:#800020!important}
}
