header.portal-header:has(.portal-current-plant){position:sticky!important;top:0;z-index:30}
.portal-header-inner.has-plant-title{display:grid;grid-template-columns:minmax(0,1fr) minmax(180px,1fr) minmax(0,1fr);align-items:center}
.has-plant-title>.portal-brand{grid-column:1;grid-row:1}
.has-plant-title>.portal-header-actions{grid-column:3;grid-row:1;justify-self:end}
.portal-current-plant{grid-column:2;grid-row:1;text-align:center;font-size:clamp(18px,1.5vw,25px);font-weight:700;line-height:1.3;overflow-wrap:anywhere;color:#fff;font-family:Arial,Helvetica,sans-serif;font-style:normal}
@media(max-width:1150px){.portal-header-inner.has-plant-title{grid-template-columns:minmax(0,1fr) auto;gap:10px}.has-plant-title>.portal-header-actions{grid-column:2}.portal-current-plant{grid-column:1/-1;grid-row:2;font-size:18px;padding-top:6px;border-top:1px solid #ffffff30}}
@media print{header.portal-header:has(.portal-current-plant){position:static!important}}

header.portal-header .portal-current-plant{color:#fff}
@media print{header.portal-header .portal-current-plant{color:#173044}}

/* Shared status and control typography, including individual plant pages. */
body main button,body main [role="button"]{font-family:Arial,Helvetica,sans-serif;font-style:normal}

/* Mobile header: brand left, compact stacked actions right, plant below. */
@media screen and (max-width:600px){
  body>.portal-header .portal-header-inner{
    display:grid;grid-template-columns:minmax(0,1fr) 104px;gap:8px 10px;
    width:100%;min-width:0;box-sizing:border-box;
  }
  .portal-header-inner>*{min-width:0;max-width:100%;box-sizing:border-box}
  .portal-header-inner>.portal-brand{
    grid-column:1;grid-row:1;display:flex;align-items:center;
    width:100%;margin:0;gap:6px;min-width:0;justify-self:start;
  }
  .portal-header-inner .portal-brand-logo{width:160px;max-width:100%;height:auto;max-height:54px;object-fit:contain;object-position:left center;flex-shrink:1}
  .portal-header-inner .portal-brand:has(.portal-brand-logo) .portal-brand-copy{display:none}
  .portal-header-inner .dv-brand-mark{width:28px;height:28px;flex:0 0 28px}
  .portal-header-inner .portal-brand-copy{min-width:0;flex:1}
  .portal-header-inner .portal-brand-copy strong{font-size:14px;white-space:nowrap;overflow-wrap:normal}
  .portal-header-inner .portal-brand-copy small{font-size:12px;white-space:normal;overflow-wrap:anywhere}
  .portal-header-inner>.portal-current-plant{
    grid-column:1/-1;grid-row:2;margin:0;padding:7px 0 0;
    font-size:17px;line-height:1.25;white-space:normal;overflow-wrap:anywhere;
  }
  .portal-header-inner>.portal-header-actions{
    grid-column:2;grid-row:1;justify-self:end;margin:0;width:104px;min-width:0;
    grid-template-columns:minmax(0,1fr);gap:4px;
  }
  .portal-header-inner .portal-header-actions>.portal-refresh{grid-column:1;grid-row:2;margin:0}
  .portal-header-inner .portal-header-actions>.portal-menu{grid-column:1;grid-row:1}
  .portal-header .portal-header-inner .portal-refresh button,.portal-header .portal-header-inner .portal-menu>summary{font-size:12px;padding:0 6px;gap:4px;height:44px;min-height:44px}
  .portal-header-inner .portal-header-actions>[data-sideview-refresh-status]{font-size:10px;overflow-wrap:anywhere}
  .portal-header-inner .portal-header-actions>*{min-width:0;max-width:100%;box-sizing:border-box}
  body>.portal-header .portal-menu .portal-menu-panel{
    width:min(340px,calc(100vw - 32px));max-width:calc(100vw - 32px);
    box-sizing:border-box;overflow-x:auto;
  }
  body>.portal-guest .portal-header-inner{display:flex;justify-content:center}
}

/* Compact shared header; manual refresh remains available inside the menu. */
body>header.portal-header{padding:10px 20px!important}
body>.portal-header .portal-header-inner{gap:6px 14px;min-height:44px}
body>.portal-header .portal-brand{margin:0;gap:8px;min-width:0}
body>.portal-header .portal-brand-logo{width:150px;max-width:100%;height:38px;object-fit:contain;object-position:left center}
body>.portal-header .dv-brand-mark{width:30px;height:30px;flex:0 0 30px}
body>.portal-header .portal-brand-copy strong{font-size:19px;line-height:1.1;white-space:nowrap}
body>.portal-header .portal-brand-copy small{display:none}
body>.portal-header .portal-brand:has(.portal-brand-logo) .portal-brand-copy{display:none}
body>.portal-header .portal-current-plant{font-size:18px;line-height:1.2}
body>.portal-header .portal-header-actions{display:flex;width:auto;min-width:0;gap:0;justify-self:end}
body>.portal-header .portal-menu>summary{width:96px;min-height:44px;height:44px;padding:0 10px;font-size:14px}
body>.portal-header .portal-menu-panel{top:calc(100% + 8px);max-height:calc(100dvh - 120px);overflow-y:auto}
body>.portal-header .portal-menu-refresh{padding:0 0 12px;border-bottom:1px solid #ffffff30;margin-bottom:12px}
body>.portal-header .portal-menu-refresh .portal-refresh{display:block;margin:0}
body>.portal-header .portal-menu-refresh [data-sideview-refresh-status]{display:block;margin-top:6px;font-size:11px;line-height:1.3;text-align:left}
html{scroll-padding-top:110px}
@media screen and (max-width:1150px){body>.portal-header .portal-current-plant{padding-top:5px;font-size:16px}}
@media screen and (max-width:600px){
 body>header.portal-header{padding:7px 12px!important}
 body>.portal-header .portal-header-inner{grid-template-columns:minmax(0,1fr) 82px;gap:4px 8px}
 body>.portal-header .portal-header-actions{width:82px}
 body>.portal-header .portal-menu>summary{width:82px;min-height:44px;height:44px;font-size:13px}
 body>.portal-header .portal-brand-logo{width:126px;height:32px;max-height:32px}
 body>.portal-header .dv-brand-mark{width:24px;height:24px;flex:0 0 24px}
 body>.portal-header .portal-brand-copy strong{font-size:17px;line-height:1.15}
 body>.portal-header .portal-current-plant{padding-top:5px;font-size:15px;line-height:1.25}
 body>main{margin-top:14px}
}
body>.portal-header .portal-header-inner{padding:0!important}

