/* Meu Portal SaaS v2.9.1 — HEADER PREMIUM UNIVERSAL
 * Split brand / navigation / search. Loaded LAST after 34 theme styles.
 * Critical: no header piece can overlap another; long nav scrolls in its OWN track.
 */
.portal-site .portal-smallstrip .public-container>span:first-child{min-width:0;overflow-wrap:anywhere}
.portal-site .portal-smallstrip .public-container>span:last-child{flex-shrink:0}
.portal-site .mps-header-v291{position:relative;z-index:30;overflow:visible;isolation:isolate}
.portal-site .mps-header-v291>.public-container{min-width:0}
.portal-site .mps-header-v291 .mps-header-brand{
  display:flex;flex-direction:row;align-items:center;justify-content:space-between;
  gap:clamp(12px,3vw,40px);min-height:100px;padding:clamp(14px,2vw,24px) 0;
  margin:0;position:relative;max-width:100%;text-align:left
}
.portal-site .mps-header-v291 .mps-header-brand .portal-logo{
  flex:0 1 auto;max-width:min(100%,660px);min-width:0;
  position:static;transform:none;overflow-wrap:anywhere;
  font-size:clamp(27px,3.3vw,48px);line-height:1.07
}
.portal-site .mps-header-v291 .mps-header-brand .portal-logo img{max-width:100%;max-height:75px;object-fit:contain}
.portal-site .mps-header-v291 .mps-brand-tagline{
  flex:0 1 265px;min-width:0;max-width:265px;position:static;
  display:block;text-align:right;overflow-wrap:anywhere;
  font-size:clamp(11px,1vw,13px);line-height:1.5;opacity:.8
}
.portal-site .mps-header-v291 .mps-header-toolbar{
  display:grid;grid-template-columns:minmax(0,1fr) clamp(210px,22%,285px);
  align-items:stretch;gap:clamp(10px,1.45vw,18px);
  width:100%;min-width:0;padding:0 0 14px;
}
.portal-site .mps-header-v291 .mps-header-navigation{
  min-width:0;max-width:100%;position:relative;align-self:stretch;
}
.portal-site .mps-header-v291 .mps-header-navigation>.public-nav{
  position:relative;display:flex;flex-direction:row;align-items:center;
  flex-wrap:nowrap;justify-content:flex-start;gap:2px;
  width:100%;max-width:100%;min-width:0;min-height:51px;
  padding-inline:4px;margin:0;overflow-x:auto;overflow-y:hidden;
  white-space:nowrap;overscroll-behavior-x:contain;
  scroll-behavior:smooth;scrollbar-width:thin;
  border-radius:10px;transform:none;
}
.portal-site .mps-header-v291 .public-nav>a{
  flex:0 0 auto;display:inline-flex;align-items:center;justify-content:center;
  min-height:44px;padding:11px clamp(10px,1vw,16px);
  max-width:280px;font-size:clamp(10px,.83vw,12px);line-height:1.25;
  white-space:nowrap;overflow:hidden;text-overflow:ellipsis;
}
.portal-site .mps-header-v291 .mps-header-search{
  width:100%;height:51px;min-height:51px;max-width:100%;min-width:0;
  display:flex;flex-wrap:nowrap;align-items:stretch;justify-content:space-between;
  align-self:start;margin:0;padding:0;position:relative;z-index:1;
  border-radius:10px;box-sizing:border-box;
}
.portal-site .mps-header-v291 .mps-header-search input{
  flex:1 1 auto;width:100%;min-width:0;max-width:none;
  padding:10px 12px 10px 15px;font-size:13px;color:var(--premium-ink,#172536);
  background:transparent;overflow:hidden;text-overflow:ellipsis;
}
.portal-site .mps-header-v291 .mps-header-search button{
  flex:0 0 48px;display:grid;place-items:center;min-width:48px;
  border-left:1px solid color-mix(in srgb,var(--premium-ink,#26334a) 12%,transparent);
  font-size:23px;line-height:1;
}
.portal-site .mps-header-v291 .mps-header-search:focus-within{
  outline:2px solid var(--brand);outline-offset:2px;
}
/* Header variants keep palette and decoration, but NEVER override structural tracks. */
.portal-site.nav-pop .mps-header-v291 .mps-header-brand,
.portal-site.nav-stadium .mps-header-v291 .mps-header-brand,
.portal-site.nav-newspaper .mps-header-v291 .mps-header-brand,
.portal-site.nav-centered .mps-header-v291 .mps-header-brand{
  flex-direction:row;align-items:center;justify-content:space-between;
  text-align:left;min-height:100px;padding:18px 0;gap:22px
}
.portal-site.nav-pop .mps-header-v291 .mps-header-brand .portal-logo{
  text-align:left;position:static;font-size:clamp(29px,3.5vw,49px)
}
.portal-site.nav-pop .mps-header-v291 .mps-header-navigation>.public-nav,
.portal-site.nav-stadium .mps-header-v291 .mps-header-navigation>.public-nav,
.portal-site.nav-newspaper .mps-header-v291 .mps-header-navigation>.public-nav{
  transform:none;min-height:51px
}
.portal-site.premium-dark .mps-header-v291 .mps-header-search input{color:var(--premium-ink,#fff)}
.portal-site.premium-dark .mps-header-v291 .mps-header-search input::placeholder{color:color-mix(in srgb,var(--premium-ink,#fff) 66%,transparent)}
/* Tablet: move lengthy navigation to an independent dropdown, never over the search. */
@media(max-width:1100px){
  .portal-site .mps-header-v291 .mps-header-toolbar{grid-template-columns:minmax(0,1fr) minmax(220px,320px);gap:12px}
  .portal-site.mps-nav-enhanced .mps-header-v291 .mps-mobile-nav-toggle{
    display:flex;align-items:center;gap:10px;margin:0;width:max-content;max-width:100%;
    min-height:51px;padding:11px 16px;border-radius:10px;
    border:1px solid var(--signature-separator,#dce3eb);
    background:var(--premium-surface,#fff);color:var(--premium-ink,#15243a);
    font-weight:850;cursor:pointer;text-align:left;
  }
  .portal-site.mps-nav-enhanced .mps-header-v291 .mps-header-navigation>.public-nav{display:none}
  .portal-site.mps-nav-enhanced .mps-header-v291 .mps-header-navigation>.public-nav.mps-nav-open{
    display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch;
    position:absolute;left:0;right:auto;top:calc(100% + 8px);
    width:min(650px,calc(100vw - 40px));max-width:calc(100vw - 40px);
    max-height:min(68vh,520px);overflow-x:hidden;overflow-y:auto;
    padding:12px;gap:6px;margin:0;z-index:50;
    white-space:normal;transform:none;
    border:1px solid var(--signature-separator,#dce3eb);
    background:var(--premium-surface,#fff);
    color:var(--premium-ink,#15243a);
    border-radius:14px;box-shadow:0 22px 48px #0711243b;
  }
  .portal-site.mps-nav-enhanced .mps-header-v291 .mps-header-navigation>.public-nav.mps-nav-open>a{
    min-width:0;width:100%;max-width:none;min-height:44px;
    justify-content:flex-start;white-space:normal;overflow-wrap:anywhere;text-align:left;
    padding:12px 14px;border-radius:8px;font-size:12px;
  }
  .portal-site .mps-header-v291 .mps-header-brand{min-height:86px}
}
/* Phones: brand, search, navigation each have their OWN full-width row. */
@media(max-width:640px){
  .portal-site .mps-header-v291 .mps-header-brand,
  .portal-site.nav-pop .mps-header-v291 .mps-header-brand,
  .portal-site.nav-centered .mps-header-v291 .mps-header-brand,
  .portal-site.nav-stadium .mps-header-v291 .mps-header-brand,
  .portal-site.nav-newspaper .mps-header-v291 .mps-header-brand{
    min-height:70px;flex-wrap:nowrap;align-items:center;padding:13px 0;gap:9px
  }
  .portal-site .mps-header-v291 .mps-brand-tagline{display:none}
  .portal-site .mps-header-v291 .mps-header-toolbar{
    display:flex;flex-direction:column;align-items:stretch;gap:9px;padding-bottom:14px;
  }
  .portal-site .mps-header-v291 .mps-header-search{order:0;width:100%;height:48px;min-height:48px}
  .portal-site .mps-header-v291 .mps-header-search input{
    width:100%;min-width:0;max-width:none;font-size:14px
  }
  .portal-site .mps-header-v291 .mps-header-navigation{order:1;width:100%;min-width:0}
  .portal-site.mps-nav-enhanced .mps-header-v291 .mps-mobile-nav-toggle{
    width:100%;justify-content:flex-start;min-height:46px
  }
  .portal-site.mps-nav-enhanced .mps-header-v291 .mps-header-navigation>.public-nav.mps-nav-open{
    width:100%;max-width:100%;grid-template-columns:minmax(0,1fr);top:calc(100% + 6px)
  }
  .portal-site .mps-header-v291 .mps-header-navigation>.public-nav{scrollbar-width:auto}
  .portal-site .mps-header-v291 .mps-header-brand .portal-logo{font-size:clamp(25px,8vw,39px)}
  .portal-site .mps-header-v291 .mps-header-brand .portal-logo img{max-height:54px}
}
@media(prefers-reduced-motion:reduce){
  .portal-site .mps-header-v291 .public-nav{scroll-behavior:auto}
}
