/* Shared account controls; mobile overrides are screen-only. */
.mobile-dock{display:none}.app-dialog{width:min(500px,calc(100vw - 28px));max-width:calc(100vw - 28px);max-height:85dvh;overflow:auto;border:1px solid #d8e3da;border-radius:16px;padding:20px;color:#233e30;background:#fff;box-shadow:0 20px 80px #142d2740}
.app-dialog::backdrop{background:#132f2580}.app-dialog-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.app-dialog-head h2{font-size:20px;margin:0}.app-dialog-head button{width:44px;min-height:44px;border:0;border-radius:9px;background:#eef3ee;color:#234b36;font-size:18px;cursor:pointer}
.account-toggle{font:inherit;border:0;background:transparent;color:#174d3a;padding:5px 8px;cursor:pointer}.account-name{color:#6a7d70;font-size:13px}.account-link{display:flex;justify-content:space-between;padding:16px 12px;background:#f0f5ef;border:1px solid #dce6dd;border-radius:9px;color:#174d3a;text-decoration:none;font-size:14px;font-weight:600}
.install-help{margin:20px 0;font-size:13px;line-height:1.6;color:#607465}.install-help summary{cursor:pointer;padding:10px 0;color:#305940}.account-dialog #logout-form button{font:inherit;padding:12px 18px;border:1px solid #d6e1d8;border-radius:8px;background:#fff;color:#8c4233;min-height:44px;width:100%;cursor:pointer}
.activity-panel{max-width:960px;padding:24px;margin:0 auto}.activity-panel>p{font-size:13px;line-height:1.6;color:#617366}.activity-panel .activity-eyebrow{font-size:10px;letter-spacing:1.8px}.activity-controls{display:flex;align-items:end;gap:12px;margin:22px 0}.activity-controls label{display:grid;gap:6px;font-size:12px}.activity-controls select,.activity-controls button,#activity-more{min-height:44px;padding:8px 14px;border:1px solid #d3dfd4;border-radius:8px;background:#fff;color:#174d3a;font:inherit}.activity-panel ol{list-style:none;padding:0;margin:0}.activity-event{display:grid;grid-template-columns:1.5fr 1fr;gap:6px 16px;padding:16px 0;border-bottom:1px solid #e5ebe5;font-size:13px}.activity-event time{color:#576f5d;text-align:right}.activity-event>span{font-size:12px;color:#7b897e}#activity-more{margin-top:20px}
@media screen and (max-width:900px){
 html{scroll-padding-top:80px;-webkit-text-size-adjust:100%}body.ui-refresh{--phone-bottom:calc(72px + env(safe-area-inset-bottom));font-size:14px;min-width:0}
 body.ui-refresh .workspace{min-width:0}body.ui-refresh main{margin:0!important;max-width:100%;padding:14px max(12px,env(safe-area-inset-right)) calc(var(--phone-bottom) + 18px) max(12px,env(safe-area-inset-left))!important}
 body.ui-refresh .topbar{position:sticky;top:0;height:auto;min-height:58px;padding:calc(8px + env(safe-area-inset-top)) max(12px,env(safe-area-inset-right)) 8px max(12px,env(safe-area-inset-left));display:flex;flex-wrap:wrap;gap:8px;z-index:30}
 body.ui-refresh .topbar>div:first-child{flex:1;min-width:0}body.ui-refresh .topbar h1{font-size:14px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}body.ui-refresh .topbar .company-logo{width:74px}body.ui-refresh .topbar .divider{margin:0 8px}
 body.ui-refresh .environment{font-size:0;margin-left:auto;max-width:140px}.ui-refresh .environment #today,.ui-refresh .environment .read-only,.ui-refresh .environment>.dot{display:none}.ui-refresh .environment .account-toggle{font-size:12px;min-height:44px;max-width:130px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
 body.ui-refresh .workspace-actions{order:3;flex-basis:100%;justify-content:flex-start;gap:8px}.ui-refresh .workspace-actions button{min-height:40px;height:auto;font-size:12px;flex:1}
 .mobile-dock{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));position:fixed;bottom:0;left:0;right:0;z-index:40;padding:6px max(8px,env(safe-area-inset-right)) calc(6px + env(safe-area-inset-bottom)) max(8px,env(safe-area-inset-left));background:#fff;border-top:1px solid #d6e2d8;box-shadow:0 -3px 18px #213d2809}
 .mobile-dock a,.mobile-dock button{min-height:54px;border:0;border-radius:10px;background:transparent;color:#687d6d;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:3px;font:inherit;font-size:11px;text-decoration:none;cursor:pointer}.mobile-dock span{font-size:23px;line-height:25px}.mobile-dock [aria-current=page]{background:#e9f2eb;color:#174d3a;font-weight:700}
 .mobile-menu{padding:16px;max-height:calc(100dvh - 40px - env(safe-area-inset-top) - env(safe-area-inset-bottom))}.mobile-menu .app-dialog-head{position:sticky;top:-16px;background:#fff;padding:8px 0;z-index:1}
 body.ui-refresh .mobile-menu .page-nav{position:static;display:flex;flex-direction:column;width:100%;height:auto;border:0;padding:8px 0;margin:0;overflow:visible;background:#fff}
 .mobile-menu .ui-nav-toggle,.mobile-menu .ui-nav-foot{display:none!important}body.ui-refresh .mobile-menu .page-nav a,body.ui-refresh .mobile-menu .ui-nav-group-toggle{justify-content:flex-start;min-height:48px;font-size:14px;padding:12px;border-radius:9px;text-align:left}
 .mobile-menu .ui-nav-children{display:grid;grid-template-columns:1fr!important;border-left:2px solid #dfebe1;padding-left:12px;margin-left:18px}.mobile-menu .page-nav a>span,.mobile-menu .ui-nav-group-toggle>span,.mobile-menu .ui-nav-group-toggle>.ui-nav-chevron{display:inline!important}.mobile-menu .page-nav a{background:#fff}.mobile-menu .ui-nav-group{gap:4px}.mobile-menu .page-nav svg{width:20px;height:20px;flex-basis:20px}
 body.ui-refresh input:not([type=checkbox]):not([type=radio]):not([type=hidden]),body.ui-refresh select{font-size:16px!important;min-height:44px;height:auto;min-width:0;max-width:100%;padding:9px 10px}
 body.ui-refresh button.primary,body.ui-refresh .branch-button{min-height:44px;height:auto;font-size:14px;min-width:0;padding:10px 14px}
 body.ui-refresh .tabs,body.ui-refresh .auto-tabs:not(.ci-modes){flex-wrap:nowrap;overflow-x:auto;-webkit-overflow-scrolling:touch;gap:5px;padding:5px;max-width:100%}body.ui-refresh .tabs button,body.ui-refresh .auto-tabs:not(.ci-modes) button{flex:0 0 auto;min-height:44px;font-size:13px;padding:10px 13px}
 body.ui-refresh .searchbar{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:10px;padding:12px;position:static}body.ui-refresh .search-field{grid-column:1/-1;display:block;width:100%;min-width:0}body.ui-refresh .branch-field{width:auto;min-width:0;grid-column:1/-1}body.ui-refresh .branch-field>span{bottom:15px}body.ui-refresh .branch-field input{padding-right:125px!important}body.ui-refresh .searchbar label{font-size:12px;margin-bottom:5px}body.ui-refresh .branch-field label{display:block}body.ui-refresh .input-wrap input{padding-left:36px!important;padding-right:30px!important}body.ui-refresh .searchbar .refresh{min-height:44px;width:46px}body.ui-refresh .searchbar .primary{min-width:0;align-self:stretch}
 body.ui-refresh #results>.article-card{display:block;padding:14px;margin-top:12px}body.ui-refresh #results .article-title{display:block}body.ui-refresh #results .article-title h2{font-size:25px;white-space:normal;overflow-wrap:anywhere}body.ui-refresh #results .article-title p{font-size:14px;max-height:none;line-height:1.5}body.ui-refresh #results .article-meta{font-size:12px;gap:7px;display:flex;flex-direction:column}body.ui-refresh #results .article-right{max-width:none;align-items:flex-start;margin-top:10px;gap:4px}body.ui-refresh #results .load-time{font-size:11px;margin:0}
 body.ui-refresh #stock.metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}body.ui-refresh #results .metric{padding:12px;min-width:0}body.ui-refresh #results .metric-value{font-size:28px;overflow-wrap:anywhere}body.ui-refresh #results .metric-label{font-size:12px}body.ui-refresh #results .metric-note{font-size:10px}
 #screen-board{grid-template-columns:1fr;gap:10px}.screen-panel{padding:14px}.screen-panel-head h3{font-size:14px}.screen-panel-head .text-button{min-height:40px;font-size:12px}.screen-receipt-panel,.screen-sales-panel{grid-column:1}.screen-locations th,.screen-locations td{font-size:12px;padding:8px 2px}.screen-facts .screen-field{font-size:13px;padding:8px 0}.screen-facts strong{white-space:normal}.screen-field>span,.screen-receipt>span{font-size:12px}.screen-supplier{font-size:12px;padding:8px 0}.screen-supplier>span,.screen-receipt>small{white-space:normal}.screen-months{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}.screen-months>div{padding:9px}.screen-months dt{font-size:12px}.screen-sales-meta{flex-wrap:wrap;font-size:12px}
 #annual-inventory-summary{grid-template-columns:1fr;padding:12px}.annual-inventory-heading{display:block}.annual-inventory-heading h3{font-size:14px}.annual-inventory-heading p{font-size:11px}.annual-inventory-values{grid-template-columns:1fr;gap:8px}.annual-inventory-values>div{display:flex;border:0;padding:0;justify-content:space-between}.annual-inventory-values dt{font-size:12px}.screen-status{font-size:11px;line-height:1.5}
 .day-heading{flex-direction:column;align-items:stretch}.day-heading h2{font-size:22px;line-height:1.25}.day-heading form{display:grid;grid-template-columns:1fr 1fr;width:100%;gap:8px}.day-heading label{font-size:12px;min-width:0}.day-heading select{max-width:100%}.day-heading button{min-height:44px;height:auto;font-size:13px}.day-grid{height:auto!important;max-height:none;grid-template-columns:1fr;grid-template-rows:auto;gap:12px}.day-automation{grid-column:1;grid-row:auto}.day-card{padding:16px;min-height:160px}.day-card h3{font-size:15px}.day-value{font-size:30px}.day-sub{font-size:13px}.day-small{font-size:12px}.day-levels{grid-template-columns:repeat(2,minmax(0,1fr))}.day-level-name{font-size:11px}.day-card-foot{font-size:11px;flex-wrap:wrap}.day-card-foot a,.day-card-foot button,.day-backorders{min-height:40px;display:inline-flex;align-items:center}.day-livebar,.day-bottom{flex-wrap:wrap;font-size:11px;line-height:1.5}
 body.ui-refresh .auto-controls,body.ui-refresh .ci-controls,body.ui-refresh .list-filters{display:flex;flex-wrap:wrap;padding:12px;gap:12px}body.ui-refresh .auto-controls label,body.ui-refresh .list-filters label,body.ui-refresh .ci-controls form,body.ui-refresh .ci-controls label{width:100%;min-width:0;font-size:12px}body.ui-refresh .auto-controls select,body.ui-refresh .ci-controls input[type=search]{min-width:0;width:100%}.ci-toolbar input{min-width:0;width:100%}.ci-toolbar label,.pw-toolbar label,.list-toolbar label{min-width:0;max-width:100%;flex:1 1 180px}.auto-filterbar label{min-width:0;width:100%}.auto-metrics,#ci-metrics{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.auto-heading{flex-wrap:wrap}.auto-badge{white-space:normal}.auto-grid,.auto-planning-grid{grid-template-columns:1fr}.auto-heading p,.pw-note,.ci-note{font-size:12px;line-height:1.55}
 .pw-supplier-group>summary{flex-wrap:wrap;gap:8px;overflow-wrap:anywhere}.pw-supplier-group>summary .pw-supplier-net{min-width:0;margin-left:0;text-align:left;width:100%}.pw-order.pw-order-clean>summary{grid-template-columns:18px minmax(0,1fr)}.pw-order-net{grid-column:2;text-align:left}.pw-table-scroll,.table-scroll,.auto-table-wrap,.inventory-table-wrap,.mobile-table-scroll{max-width:100%;overflow-x:auto;-webkit-overflow-scrolling:touch;overscroll-behavior-x:contain}.mobile-table-scroll table{min-width:580px}.auto-table-wrap th,.auto-table-wrap td,.inventory-table-wrap th,.inventory-table-wrap td{font-size:12px!important;padding:10px!important}.sort-button{min-height:38px}.inventory-report-heading{overflow-wrap:anywhere}.list-pagination,.auto-pagination{flex-wrap:wrap;gap:8px}.auto-sort{margin-left:0}
 body.ui-refresh dialog:not(.print-preview-dialog){max-width:calc(100vw - 20px)!important;width:calc(100vw - 20px)!important;max-height:calc(100dvh - 30px - env(safe-area-inset-top) - env(safe-area-inset-bottom));margin:auto;padding:14px;box-sizing:border-box}#screen-dialog{padding:0!important}#screen-dialog-content{padding:10px}.screen-dialog-head{flex-wrap:wrap;padding:10px}.screen-dialog-head h2{font-size:16px}.screen-dialog-head button,.day-dialog-head button,.ci-dialog-head button{min-height:44px}.day-dialog-head h2{font-size:18px}#day-dialog-content{font-size:13px}.day-detail-metrics{grid-template-columns:1fr 1fr}.day-detail-filters{flex-direction:column}.day-detail-pages{flex-wrap:wrap}.day-position-grid{min-width:720px}.day-position-detail{min-width:700px}
 body.ui-refresh .supplier-filter{width:100%;min-width:0;grid-template-columns:1fr}body.ui-refresh .auto-controls input[type=date]{border:1px solid #d1ddc7;border-radius:7px;background:#fff;color:#304e39}
 body.ui-refresh #print-preview-dialog{padding:0!important}.print-preview-controls{flex-wrap:wrap;gap:8px;padding:12px;left:0}.print-preview-controls>div{flex:1 1 100%;min-width:0}.print-preview-controls h2{font-size:16px}.print-preview-controls button{flex:1;min-width:0;min-height:44px}.labels-workspace{grid-template-columns:minmax(0,1fr);padding:10px}.order-facts{grid-template-columns:repeat(2,minmax(0,1fr))}.order-totals{flex-wrap:wrap;gap:14px}.order-dialog-heading{flex-wrap:wrap;gap:8px}
 .activity-panel{padding:16px}.activity-event{grid-template-columns:1fr;gap:7px}.activity-event time{text-align:left}.activity-controls{flex-wrap:wrap}.activity-panel h2{font-size:24px}
}
@media screen and (min-width:901px){.mobile-table-scroll{display:contents}}
@media print{.mobile-dock,.mobile-menu,.account-dialog,.account-toggle{display:none!important}.mobile-table-scroll{display:contents}.activity-panel{border:0}}
