/* Faregrounds Hub Mobile v2 — consolidated source of truth for screens <=850px.
   Overrides legacy compact-sidebar, sage overlay, and scheduler overflow rules. */
.hub-mobile-backdrop,.hub-drawer-top,.hub-mobile-brand{display:none}
.sched-mobile-navigation,.sched-mobile-manager{display:none}
@media(max-width:850px){
 html,body{max-width:100%;overflow-x:clip}
 body.hub-mobile-drawer-open{overflow:hidden;touch-action:none}
 .admin{display:block!important;grid-template-columns:minmax(0,1fr)!important;min-height:100dvh}
 .admin .workspace{width:100%;min-width:0!important;overflow-x:clip}
 .admin .content{width:100%;max-width:100%;box-sizing:border-box;padding:18px 15px calc(65px + env(safe-area-inset-bottom))!important}
 .admin .topbar{position:sticky;top:0;z-index:35;min-height:62px!important;height:auto;padding:9px 15px!important;gap:10px!important;background:#fff!important;border-bottom:1px solid #dce6dc!important;box-shadow:0 1px 8px rgba(24,53,34,.045)}
 .admin .hub-mobile-toggle{display:grid!important;place-items:center;width:44px!important;height:44px!important;min-width:44px;padding:0;border-radius:12px;background:#e9f2e9;color:#234e38;border:1px solid #cbddce}
 .admin .hub-mobile-toggle svg{width:20px;height:20px}
 .hub-mobile-brand{display:flex;flex-direction:column;gap:1px;line-height:1.2;min-width:0}
 .hub-mobile-brand strong{font-size:12px;color:#214a35;font-weight:850;letter-spacing:.12em}
 .hub-mobile-brand small{font-size:10px;color:#719078;font-weight:700;letter-spacing:.06em}
 .admin .topbar .breadcrumbs{display:none!important}
 .admin .topbar .top-actions{margin-left:auto;gap:5px;min-width:0;flex-wrap:nowrap!important}
 .admin .topbar #topSignout,.admin .topbar #employeeTopSignout,.admin .topbar .userpill{display:none!important}
 .admin .topbar .scope-chooser{max-width:125px;min-width:0;padding:4px 5px!important;min-height:42px}
 .admin .topbar .scope-chooser select{max-width:88px!important;min-width:0;overflow:hidden;text-overflow:ellipsis;font-size:11px!important}
 .admin .topbar #hubNoticeBell{width:40px;min-width:40px;height:40px;display:grid;place-items:center;padding:7px!important}
 .hub-mobile-backdrop:not([hidden]){display:block;position:fixed;inset:0;z-index:110;background:rgba(12,31,21,.55);border:0;border-radius:0;padding:0;margin:0;cursor:pointer}
 .hub-mobile-backdrop[hidden]{display:none!important}
 .admin .side{display:flex!important;position:fixed!important;inset:0 auto 0 0!important;top:0!important;bottom:0!important;left:0!important;right:auto!important;
   box-sizing:border-box!important;width:min(325px,85vw)!important;max-width:85vw!important;height:100dvh!important;min-height:0!important;
   z-index:120!important;flex-direction:column!important;align-items:stretch!important;gap:0!important;
   padding:calc(12px + env(safe-area-inset-top)) 14px calc(14px + env(safe-area-inset-bottom))!important;
   background:#eef3ec!important;color:#214932!important;border-right:1px solid #d4e2d3!important;box-shadow:12px 0 38px rgba(9,32,18,.21)!important;
   overflow-x:hidden!important;overflow-y:auto!important;overscroll-behavior:contain!important;
   transform:translate3d(-110%,0,0)!important;visibility:hidden;pointer-events:none;
   transition:transform .22s ease,visibility .22s ease!important;
 }
 .admin.hub-nav-open .side{transform:translate3d(0,0,0)!important;visibility:visible!important;pointer-events:auto}
 .admin .side>.wordmark{display:none!important}
 .hub-drawer-top{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-shrink:0;margin-bottom:22px;padding:5px 4px 15px;border-bottom:1px solid #d1dfd1}
 .hub-drawer-brand{font-size:14px;font-weight:900;letter-spacing:.11em;color:#1f4932;line-height:1.55}
 .hub-drawer-brand span{display:block;font-size:10px;letter-spacing:.13em;color:#6e8874}
 .hub-drawer-close{height:44px;width:44px;min-width:44px;display:grid;place-items:center;background:#fff;border:1px solid #cddfcc;border-radius:12px;color:#244d35;font-size:30px;line-height:1;cursor:pointer}
 .admin .side nav{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:18px!important;min-width:0!important;width:100%!important;overflow:visible!important}
 .admin .side .nav-group{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:5px!important;width:100%!important;min-width:0!important}
 .admin .side .nav-group-label{display:block!important;margin:0!important;padding:3px 10px 7px!important;letter-spacing:.11em!important;font-size:10px!important;color:#6b8874!important;font-weight:850!important}
 .admin .side .navitem{display:flex!important;align-items:center!important;justify-content:flex-start!important;
   width:100%!important;height:auto!important;min-height:46px!important;padding:11px 12px!important;margin:0!important;
   border-radius:12px!important;gap:12px!important;overflow:visible!important;white-space:normal!important;
   color:#345d45!important;background:transparent!important;text-align:left!important;font-size:14px!important;font-weight:750!important;line-height:1.35!important;
 }
 .admin .side .navitem .text,.admin .side .side-bottom .text{display:inline!important;font-size:14px!important;white-space:normal!important;visibility:visible!important;opacity:1!important;color:inherit!important}
 .admin .side .navitem svg,.admin .side .navitem .icon{flex:0 0 20px!important;width:20px!important;height:20px!important;opacity:1!important;color:inherit!important}
 .admin .side .navitem.active{background:#d4e7d6!important;color:#19492e!important;box-shadow:none!important;font-weight:850!important}
 .admin .side .navitem:hover{background:#dce9dc!important;color:#234e37!important}
 .admin .side .side-bottom{display:block!important;flex:0 0 auto;padding:14px 0 0!important;margin-top:auto!important;width:100%!important;border-top:1px solid #cfdbcd!important}
 .admin .side .side-bottom>.text{display:block!important;font-size:11px!important;padding:0 9px 9px;color:#66816d!important}
 .admin .side .side-bottom .navitem{border:1px solid #d7e4d7!important;background:#fff!important}
 .admin .side .wordmark small{display:none!important}
 .admin .page-heading h1{font-size:26px!important;overflow-wrap:anywhere}
 .admin .card{max-width:100%;box-sizing:border-box;min-width:0}
}
@media(max-width:760px){
 /* Avoid two parallel scheduling experiences on narrow screens. */
 #pageContent:has(.sched-mobile-navigation) .sched-head,
 #pageContent:has(.sched-mobile-navigation) .sched-week-nav,
 #pageContent:has(.sched-mobile-navigation) .sched-scroll{display:none!important}
 .sched-mobile-navigation{display:block;margin:0 0 18px;min-width:0}
 .sched-mobile-heading{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin:1px 0 15px}
 .sched-mobile-heading h1{font-size:29px!important;line-height:1.18;margin:4px 0 0!important;color:#193f2e;letter-spacing:-.035em}
 .sched-mobile-kicker{font-size:10px;letter-spacing:.10em;font-weight:850;color:#6d8974;text-transform:uppercase}
 .sched-mobile-history{min-height:40px;padding:8px 13px;white-space:nowrap;border:1px solid #d3e2d3;border-radius:11px;background:#fff;color:#365f46;font-weight:750;font-size:12px}
 .sched-mobile-prevnext{display:grid;grid-template-columns:46px minmax(0,1fr) 46px;align-items:center;gap:8px;margin:0 0 12px}
 .sched-mobile-prevnext button{height:46px;width:46px;display:grid;place-items:center;border:1px solid #d7e4d7;border-radius:12px;background:#fff;color:#2b5940;font-size:28px;line-height:1}
 .sched-mobile-prevnext strong{text-align:center;font-size:17px;font-weight:850;color:#244d35;white-space:nowrap;min-width:0}
 .sched-mobile-weeks{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:7px;width:100%;max-width:100%;min-width:0}
 .sched-mobile-week{display:flex;flex-direction:column;justify-content:center;gap:4px;align-items:center;min-width:0;padding:9px 3px;min-height:59px;
   border:1px solid #dce8dc;border-radius:11px;background:#fff;color:#526d57;cursor:pointer;text-align:center;overflow:hidden}
 .sched-mobile-week span{font-size:10px;font-weight:750;white-space:nowrap;letter-spacing:-.015em}
 .sched-mobile-week strong{font-size:12px;font-weight:850;color:#2d573d;white-space:nowrap}
 .sched-mobile-week.active{background:#e3f1e5;border-color:#7ea78a;box-shadow:inset 0 0 0 1px #7ea78a}
 .sched-mobile-week.active strong,.sched-mobile-week.active span{color:#1d5637}
 #pageContent:has(.sched-mobile-employee) .sched-metrics,
 #pageContent:has(.sched-mobile-employee) .sched-toolbar-v3{display:none!important}
 .sched-mobile-employee,.sched-mobile-manager{display:block!important;margin:12px 0 18px}
 .sched-mobile-summary{display:flex;justify-content:space-between;gap:8px;align-items:center;margin:0 0 13px!important;padding:0!important;flex-wrap:wrap}
 .sched-mobile-summary strong{font-size:17px!important;line-height:1.35;color:#1d4632}
 .sched-mobile-summary span{font-size:12px;color:#617d69}
 .sched-mobile-shift{margin:0 0 11px!important;padding:17px!important;border-radius:15px!important;border:1px solid #dce7dd!important;background:#fff!important;box-shadow:0 2px 12px rgba(32,67,43,.035)!important}
 .sched-mobile-date{align-items:flex-start!important}
 .sched-mobile-date strong{font-size:17px!important}
 .sched-mobile-date small{font-size:11px!important;text-align:right;line-height:1.4}
 .sched-mobile-time{font-size:clamp(18px,5.8vw,24px)!important;line-height:1.3!important;letter-spacing:-.045em!important;white-space:normal!important;overflow-wrap:anywhere}
 .sched-mobile-meta{font-size:13px!important;margin:0 0 12px!important}
 .sched-mobile-ack{display:inline-flex;align-items:center;padding:9px 12px;background:#e9f4e9;border-radius:9px;color:#285f3c;font-weight:750}
 .sched-mobile-shift [data-ack]{display:block;min-height:46px!important;border-radius:10px;width:100%;background:#e7f2e9;color:#214d35;border:1px solid #bed8c4;font-size:13px;font-weight:850}
 .sched-mobile-day{background:#fff;border:1px solid #dce8de;border-radius:15px;margin-bottom:11px;padding:14px}
 .sched-mobile-day-head{display:flex;justify-content:space-between;align-items:center;gap:10px;padding:0 0 10px;border-bottom:1px solid #edf1ec}
 .sched-mobile-day-head strong{font-size:15px;color:#214935}
 .sched-mobile-day-add{min-height:37px;background:#edf5ed;border:1px solid #d2e3d3;border-radius:9px;padding:7px 10px;color:#315b3e;font-size:12px;font-weight:800}
 .sched-mobile-manager-shift{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px;align-items:center;width:100%;padding:13px 0;background:#fff;border:0;border-bottom:1px solid #edf2ed;color:#1e4430;text-align:left;cursor:pointer}
 .sched-mobile-manager-shift:last-child{border-bottom:0;padding-bottom:1px}
 .sched-mobile-manager-shift>div{min-width:0;display:flex;flex-direction:column;gap:4px}
 .sched-mobile-manager-shift>div strong{font-size:14px;white-space:normal}
 .sched-mobile-manager-shift>div small{font-size:11px;color:#809484}
 .sched-mobile-manager-time{font-size:13px;font-weight:800;white-space:normal;text-align:right;max-width:170px;line-height:1.35}
 .sched-mobile-state{grid-column:1/-1;width:max-content;font-size:10px;font-weight:800;padding:4px 8px;border-radius:7px;background:#e8f4e9;color:#367147}
 .sched-mobile-state.draft{background:#fbf3df;color:#927036}
 .sched-mobile-no-shifts{font-size:12px;color:#92a095;margin:12px 0 1px}
 .sched-metrics{gap:7px!important;margin-bottom:14px!important}
 .sched-metrics>div{padding:10px 7px!important;min-width:0}
 .sched-metrics small{font-size:10px!important;line-height:1.35!important}
 .sched-metrics strong{font-size:20px!important}
 .sched-toolbar-v3{margin:12px 0!important;padding:12px!important;gap:10px!important}
 .sched-toolbar-left,.sched-toolbar-right{gap:8px!important;flex-wrap:wrap!important;width:100%}
 .sched-toolbar-right{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr) 42px;align-items:center;gap:7px}
 .sched-toolbar-right .sched-quiet-action,.sched-toolbar-right .sched-publish-action{min-width:0!important;padding:9px 6px!important;font-size:11px!important;white-space:normal!important;min-height:44px!important}
 .sched-toolbar-separator{display:none!important}
 .sched-more-v3{justify-self:end}
 .sched-more-v3>summary{height:44px!important;width:42px!important}
 .sched-inline-depts{max-width:100%;overflow-x:auto;min-width:0}
 .sched-dept-chip{padding:9px 12px!important;min-height:37px}
 .sched-bottom{grid-template-columns:minmax(0,1fr)!important;gap:10px!important}
 .sched-bottom .card{padding:16px!important}
 #pageContent:has(.sched-mobile-employee) .sched-bottom .card:last-child{display:none!important}
 .sched-history{margin:0 0 15px!important;padding:13px!important}
 .sched-history input{max-width:100%;width:auto}
 .sched-dialog{max-height:calc(100dvh - 28px)!important;overflow-y:auto!important;border-radius:18px!important}
}
@media(max-width:375px){
 .sched-mobile-week span{font-size:9px}
 .sched-mobile-week strong{font-size:11px}
 .sched-mobile-prevnext strong{font-size:15px}
 .admin .topbar .scope-chooser{max-width:105px}
}
@media(prefers-reduced-motion:reduce){.admin .side{transition:none!important}}

@media(max-width:760px){
 .sched-mobile-request{width:100%;min-height:46px;border-radius:11px;background:#eef5ee;border:1px solid #c8ddcc;color:#27583b;font-size:13px;font-weight:800;margin:5px 0 4px;cursor:pointer}
 .sched-mobile-request:active{background:#dfece1}
}

/* Scheduler weekly acknowledgment mobile layout */
@media(max-width:760px){
 .sched-view-tabs{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.35fr);gap:4px;margin:0 0 16px;border-bottom:1px solid #dce7dc;width:100%}
 .sched-view-tabs>button{min-width:0;width:100%;padding:10px 6px;min-height:48px;justify-content:center;white-space:normal;text-align:center;gap:6px;font-size:12px;line-height:1.35}
 .sched-ack-tab-count{flex:0 0 auto;min-width:20px;height:20px;padding:0 5px}
 .sched-week-acknowledge{align-items:stretch;flex-direction:column;gap:13px;margin:0 0 17px;padding:15px;border-radius:14px}
 .sched-week-acknowledge strong{font-size:16px}
 .sched-week-acknowledge small{font-size:12px}
 .sched-week-ack-button{width:100%;min-height:48px;font-size:13px}
 .sched-ack-confirmed{align-self:flex-start}
 .sched-ack-pane{margin:0 0 18px}
 .sched-ack-overview{align-items:flex-start;flex-direction:column;gap:11px;padding:16px}
 .sched-ack-overview h2{font-size:20px}
 .sched-ack-progress{padding:8px 10px}
 .sched-ack-departments{overflow-x:auto;flex-wrap:nowrap;max-width:100%;padding-bottom:3px;gap:7px}
 .sched-ack-departments .sched-dept-chip{white-space:nowrap;flex-shrink:0}
 .sched-ack-group{padding:14px;margin-bottom:10px}
 .sched-ack-person{gap:10px}
 .sched-ack-avatar{flex-basis:35px;width:35px;height:35px}
 .sched-ack-person-info strong{font-size:13px}
 .sched-ack-person-info small{font-size:11px}
 .sched-ack-status{font-size:10px;padding:6px 8px}
}

@media(max-width:760px){
 .sched-toolbar-v3 .sched-toolbar-right{display:flex!important;flex-wrap:wrap!important;align-items:stretch!important;justify-content:stretch!important;gap:8px!important}
 .sched-toolbar-v3 .sched-toolbar-right .sched-quiet-action,
 .sched-toolbar-v3 .sched-toolbar-right .sched-remove-action,
 .sched-toolbar-v3 .sched-toolbar-right .sched-publish-action,
 .sched-toolbar-v3 .sched-toolbar-right .sched-unpublish-action{flex:1 1 calc(50% - 8px)!important;min-width:0!important;min-height:46px!important;padding:10px 8px!important;font-size:12px!important;white-space:normal!important;text-align:center}
 .sched-toolbar-v3 .sched-toolbar-right .sched-unpublish-action:only-child{flex-basis:100%!important}
 .sched-toolbar-v3 .sched-toolbar-right .sched-more-v3{flex:0 0 44px!important;align-self:center}
 .sched-unpublish-warning{padding:13px}
 .sched-unpublish-intro{font-size:13px}
}
