/* ============================================================
   SGW V470 - MENU SUPERIOR FINAL
   Base: V469 consolidada.
   Objetivos:
   - impedir retorno da compactacao microscopica V453/V460/V461;
   - manter todos os itens grandes e enquadrados no desktop;
   - usar labels curtos no desktop medio;
   - scroll horizontal somente quando a largura realmente exigir;
   - manter dropdowns acima do conteudo e menu fixo.
   ============================================================ */

html.sgw469-nav-owner{
  --sgw470-head-h:112px;
}

html.sgw469-nav-owner body.sgw453-provider-server,
html.sgw469-nav-owner body.sgw450-provider{
  --v450-head-h:var(--sgw470-head-h) !important;
  padding-top:var(--sgw470-head-h) !important;
}

/* Shell nunca pode ser deslocado/reduzido por estilos legados. */
html.sgw469-nav-owner #sgw450TopShell{
  position:fixed !important;
  top:0 !important;
  left:0 !important;
  right:0 !important;
  bottom:auto !important;
  width:100vw !important;
  max-width:100vw !important;
  height:var(--sgw470-head-h) !important;
  min-height:var(--sgw470-head-h) !important;
  margin:0 !important;
  transform:none !important;
  overflow:visible !important;
  z-index:2147483000 !important;
  box-sizing:border-box !important;
}

/* Primeira linha */
html.sgw469-nav-owner #sgw450TopShell .sgw450-navrow{
  height:58px !important;
  min-height:58px !important;
  grid-template-columns:170px minmax(0,1fr) !important;
  gap:6px !important;
  padding:0 10px !important;
  box-sizing:border-box !important;
}

/* Navegacao usa os wrappers reais criados pela V453. */
html.sgw469-nav-owner #sgw450TopShell .sgw450-nav{
  display:flex !important;
  align-items:center !important;
  justify-content:space-between !important;
  width:100% !important;
  min-width:0 !important;
  max-width:none !important;
  height:58px !important;
  gap:3px !important;
  overflow-x:hidden !important;
  overflow-y:visible !important;
}

html.sgw469-nav-owner #sgw450TopShell .sgw450-navitem{
  flex:1 1 auto !important;
  min-width:0 !important;
  max-width:none !important;
  position:relative !important;
}

/* Neutraliza TODOS os seletores de compactacao antigos, inclusive classes
   adicionadas historicamente aos proprios links/botoes. */
html.sgw469-nav-owner #sgw450TopShell .sgw450-navlink,
html.sgw469-nav-owner #sgw450TopShell .sgw450-navbutton,
html.sgw469-nav-owner #sgw450TopShell .sgw460-nav-item,
html.sgw469-nav-owner #sgw450TopShell .sgw461-trigger,
html.sgw469-nav-owner #sgw450TopShell.sgw453-compact .sgw450-navlink,
html.sgw469-nav-owner #sgw450TopShell.sgw453-compact .sgw450-navbutton,
html.sgw469-nav-owner #sgw450TopShell.sgw453-ultra .sgw450-navlink,
html.sgw469-nav-owner #sgw450TopShell.sgw453-ultra .sgw450-navbutton,
html.sgw469-nav-owner #sgw450TopShell.sgw460-nav-compact .sgw460-nav-item,
html.sgw469-nav-owner #sgw450TopShell.sgw460-nav-ultra .sgw460-nav-item,
html.sgw469-nav-owner #sgw450TopShell.sgw461-compact .sgw460-nav-item,
html.sgw469-nav-owner #sgw450TopShell.sgw461-compact .sgw461-trigger,
html.sgw469-nav-owner #sgw450TopShell.sgw461-ultra .sgw460-nav-item,
html.sgw469-nav-owner #sgw450TopShell.sgw461-ultra .sgw461-trigger{
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  width:100% !important;
  min-width:0 !important;
  height:42px !important;
  min-height:42px !important;
  padding:0 6px !important;
  gap:5px !important;
  border-radius:10px !important;
  font-size:12px !important;
  font-weight:800 !important;
  line-height:1 !important;
  letter-spacing:-.01em !important;
  white-space:nowrap !important;
  box-sizing:border-box !important;
}

/* Label nunca fica com fonte herdada de 7/8px. */
html.sgw469-nav-owner #sgw450TopShell .sgw453-navlabel{
  display:inline-block !important;
  min-width:0 !important;
  font:inherit !important;
  line-height:1 !important;
  white-space:nowrap !important;
}

/* Icone/caret permanecem visiveis inclusive se uma classe ultra sobreviver. */
html.sgw469-nav-owner #sgw450TopShell .sgw450-navicon,
html.sgw469-nav-owner #sgw450TopShell.sgw453-ultra .sgw450-navicon{
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  flex:0 0 auto !important;
  min-width:14px !important;
  font-size:14px !important;
  transform:none !important;
}
html.sgw469-nav-owner #sgw450TopShell .sgw450-caret,
html.sgw469-nav-owner #sgw450TopShell.sgw453-ultra .sgw450-caret{
  display:inline-block !important;
  flex:0 0 auto !important;
  font-size:8px !important;
}

/* Marca */
html.sgw469-nav-owner #sgw450TopShell .sgw450-brand{
  min-width:0 !important;
  height:48px !important;
  gap:8px !important;
}
html.sgw469-nav-owner #sgw450TopShell .sgw450-logo{
  width:38px !important;
  height:38px !important;
  min-width:38px !important;
  font-size:11px !important;
}
html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy b{
  font-size:11.5px !important;
  line-height:1.1 !important;
  white-space:nowrap !important;
}
html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy small{
  font-size:9.5px !important;
  line-height:1.1 !important;
}

/* Segunda linha permanece enquadrada na altura total do shell. */
html.sgw469-nav-owner #sgw450TopShell .sgw450-utilrow{
  height:54px !important;
  min-height:54px !important;
  padding:6px 12px !important;
  box-sizing:border-box !important;
}

/* Dropdown fixo na viewport, sem ser cortado pelo nav. */
html.sgw469-nav-owner #sgw450TopShell .sgw450-dropdown{
  position:fixed !important;
  top:58px !important;
  min-width:250px !important;
  max-width:360px !important;
  max-height:calc(100vh - 72px) !important;
  overflow-y:auto !important;
  overflow-x:hidden !important;
  z-index:2147483200 !important;
}
html.sgw469-nav-owner #sgw450TopShell .sgw450-dropdown a{
  min-height:39px !important;
  padding:9px 11px !important;
  font-size:12px !important;
}

/* Telas largas: labels completos e menu maior. */
@media(min-width:1501px){
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navrow{
    grid-template-columns:190px minmax(0,1fr) !important;
    gap:8px !important;
    padding-left:14px !important;
    padding-right:14px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav{
    gap:5px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navlink,
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navbutton,
  html.sgw469-nav-owner #sgw450TopShell .sgw460-nav-item,
  html.sgw469-nav-owner #sgw450TopShell .sgw461-trigger{
    font-size:13.5px !important;
    padding-left:8px !important;
    padding-right:8px !important;
  }
}

/* Desktop medio: labels curtos, mas fonte continua grande. */
@media(min-width:1101px) and (max-width:1500px){
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navrow{
    grid-template-columns:160px minmax(0,1fr) !important;
    gap:3px !important;
    padding-left:7px !important;
    padding-right:7px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy b{
    font-size:10.5px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav{
    gap:2px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navlink,
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navbutton,
  html.sgw469-nav-owner #sgw450TopShell .sgw460-nav-item,
  html.sgw469-nav-owner #sgw450TopShell .sgw461-trigger{
    font-size:11.5px !important;
    padding-left:4px !important;
    padding-right:4px !important;
  }
}

/* 901-1100: nao encolhe; permite rolagem horizontal. */
@media(min-width:901px) and (max-width:1100px){
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navrow{
    grid-template-columns:140px minmax(0,1fr) !important;
    padding:0 6px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy b{
    font-size:10px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav{
    justify-content:flex-start !important;
    overflow-x:auto !important;
    scrollbar-width:none !important;
    -webkit-overflow-scrolling:touch !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav::-webkit-scrollbar{
    display:none !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navitem{
    flex:0 0 auto !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navlink,
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navbutton{
    width:auto !important;
    font-size:11.5px !important;
    padding:0 7px !important;
  }
}

/* Celular/tablet: menu continua fixo e legivel, com scroll horizontal. */
@media(max-width:900px){
  html.sgw469-nav-owner{
    --sgw470-head-h:104px;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navrow{
    height:52px !important;
    min-height:52px !important;
    grid-template-columns:92px minmax(0,1fr) !important;
    padding:0 5px !important;
    gap:3px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy{
    display:none !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand{
    justify-content:center !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav{
    height:52px !important;
    justify-content:flex-start !important;
    gap:3px !important;
    overflow-x:auto !important;
    scrollbar-width:none !important;
    -webkit-overflow-scrolling:touch !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav::-webkit-scrollbar{
    display:none !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navitem{
    flex:0 0 auto !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navlink,
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navbutton,
  html.sgw469-nav-owner #sgw450TopShell .sgw460-nav-item,
  html.sgw469-nav-owner #sgw450TopShell .sgw461-trigger{
    width:auto !important;
    height:40px !important;
    min-height:40px !important;
    font-size:11px !important;
    padding:0 7px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-utilrow{
    height:52px !important;
    min-height:52px !important;
    padding:6px 7px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-dropdown{
    top:52px !important;
    left:6px !important;
    right:6px !important;
    width:auto !important;
    max-width:none !important;
    max-height:calc(100vh - 64px) !important;
  }
}


/* ============================================================
   SGW V474 - ENQUADRAMENTO REAL 1101-1350
   Evidencia visual: viewport ~1255px cortava "Config.".
   Mantem a fonte 11.5px; economiza marca/gaps e usa labels curtos.
   ============================================================ */
@media(min-width:1101px) and (max-width:1350px){
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navrow{
    grid-template-columns:146px minmax(0,1fr) !important;
    gap:1px !important;
    padding-left:4px !important;
    padding-right:4px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand{
    gap:5px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-logo{
    width:34px !important;
    height:34px !important;
    min-width:34px !important;
    font-size:10px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy b{
    font-size:9.8px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-brand-copy small{
    font-size:8.5px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-nav{
    gap:1px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navlink,
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navbutton,
  html.sgw469-nav-owner #sgw450TopShell .sgw460-nav-item,
  html.sgw469-nav-owner #sgw450TopShell .sgw461-trigger{
    font-size:11.5px !important;
    padding-left:3px !important;
    padding-right:3px !important;
    gap:3px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-navicon{
    min-width:12px !important;
    font-size:12px !important;
  }
  html.sgw469-nav-owner #sgw450TopShell .sgw450-caret{
    font-size:7px !important;
  }
}
