/* SAGAZ R352 • ações do menu global.
   Extraído do comportamento aprovado de /solucoes/ na R351.
   Somente navegação responsiva, sem tocar hero, imagens ou textos. */
@media (max-width: 980px) {
  html body.public-shell-page .site-header .links > .mobile-nav-actions {
    display: none !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .mobile-nav-actions {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    align-items: stretch !important;
    gap: 10px !important;
    flex: 0 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    overflow: visible !important;
    margin: 6px 0 0 !important;
    padding: 10px 0 0 !important;
    box-sizing: border-box !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .mobile-nav-actions > a {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 9px !important;
    flex: 0 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: 48px !important;
    box-sizing: border-box !important;
    border-radius: 12px !important;
    padding: 10px 12px !important;
    font-size: 14px !important;
    line-height: 1.3 !important;
    font-weight: 900 !important;
    text-decoration: none !important;
    white-space: normal !important;
  }
  html body.public-shell-page .site-header.nav-open .mobile-nav-actions > .mobile-nav-diagnostic {
    background: #c8f25c !important;
    color: #062f38 !important;
    border: 1px solid transparent !important;
  }
  html body.public-shell-page .site-header.nav-open .mobile-nav-actions > .mobile-nav-central {
    background: transparent !important;
    border: 1px solid rgba(247, 242, 230, 0.34) !important;
    color: #f7f2e6 !important;
  }
  html body.public-shell-page .site-header.nav-open .mobile-nav-central svg {
    display: block !important;
    flex: 0 0 18px !important;
    width: 18px !important;
    max-width: 18px !important;
    min-width: 18px !important;
    height: 18px !important;
    max-height: 18px !important;
    min-height: 18px !important;
    overflow: visible !important;
    fill: none !important;
    stroke: currentColor !important;
    stroke-width: 2 !important;
  }
}

/* R352 tablet: 761-980px inherits a desktop menu on some templates.
   Convert every route to the same dark responsive drawer as the mobile.
   Scope strictly to OPEN navigation; never alter photographic heroes. */
@media (min-width:761px) and (max-width:980px) {
  html body.public-shell-page .site-header {
    position: sticky !important;
    z-index: 1000 !important;
    background: #f8f6f0 !important;
  }
  html body.public-shell-page .site-header .nav-menu-toggle {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    flex: 0 0 auto !important;
    width: auto !important;
    min-width: 100px !important;
    max-width: none !important;
    height: 44px !important;
    min-height: 44px !important;
    padding: 0 14px !important;
    border: 0 !important;
    border-radius: 12px !important;
    background: #0b4854 !important;
    color: #f7f2e6 !important;
    font-size: 13px !important;
    font-weight: 800 !important;
    white-space: nowrap !important;
    box-sizing: border-box !important;
  }
  html body.public-shell-page .site-header.nav-open .nav-menu-toggle {
    background: #46691a !important;
  }
  html body.public-shell-page .site-header.nav-open .links {
    display: flex !important;
    position: fixed !important;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
    left: 16px !important;
    right: 16px !important;
    top: 72px !important;
    bottom: 12px !important;
    width: calc(100vw - 32px) !important;
    max-width: calc(100vw - 32px) !important;
    height: calc(100dvh - 84px) !important;
    max-height: calc(100dvh - 84px) !important;
    margin: 0 !important;
    padding: 18px 18px 32px !important;
    gap: 10px !important;
    box-sizing: border-box !important;
    border-radius: 0 0 14px 14px !important;
    background: #063943 !important;
    color: #f7f2e6 !important;
    box-shadow: 0 18px 38px rgba(0,0,0,.20) !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    overscroll-behavior: contain !important;
    z-index: 1001 !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .nav-dropdown {
    display: grid !important;
    position: relative !important;
    flex: 0 0 auto !important;
    grid-template-columns: minmax(0,1fr) 52px !important;
    align-items: stretch !important;
    width: 100% !important;
    max-width: 100% !important;
    min-height: 58px !important;
    height: auto !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
    border-radius: 12px !important;
    border: 1px solid rgba(247,242,230,.18) !important;
    background: rgba(11,72,84,.76) !important;
    color: #f7f2e6 !important;
    overflow: hidden !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .nav-dropdown > .nav-context-link {
    display: flex !important;
    align-items: center !important;
    flex: 0 1 auto !important;
    width: auto !important;
    min-width: 0 !important;
    height: 56px !important;
    min-height: 56px !important;
    padding: 12px 18px !important;
    box-sizing: border-box !important;
    background: transparent !important;
    color: #f7f2e6 !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    opacity: 1 !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .nav-dropdown > .nav-caret {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 auto !important;
    width: 52px !important;
    min-width: 52px !important;
    height: 56px !important;
    min-height: 56px !important;
    background: transparent !important;
    color: #c8f25c !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .nav-dropdown > .nav-dropdown-menu:not([hidden]) {
    display: grid !important;
    position: static !important;
    grid-column: 1 / -1 !important;
    width: calc(100% - 20px) !important;
    margin: 0 10px 10px !important;
    padding: 8px !important;
    background: #0b4854 !important;
    border: 1px solid rgba(247,242,230,.15) !important;
    border-radius: 8px !important;
    box-sizing: border-box !important;
  }
  html body.public-shell-page .site-header.nav-open .links > .nav-dropdown > .nav-dropdown-menu[hidden] {
    display: none !important;
  }
  html body.public-shell-page .site-header.nav-open .links > a:not(.mobile-nav-diagnostic):not(.mobile-nav-central) {
    display: flex !important;
    flex: 0 0 auto !important;
    align-items: center !important;
    width: 100% !important;
    height: 54px !important;
    min-height: 54px !important;
    padding: 12px 18px !important;
    margin: 0 !important;
    background: rgba(11,72,84,.76) !important;
    border: 1px solid rgba(247,242,230,.18) !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
    color: #f7f2e6 !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    text-decoration: none !important;
    opacity: 1 !important;
  }
}

/* Tablet drawer has a stronger legacy position:absolute selector on non-PRESENCE
   pages; match global shell specificity so the panel is consistently viewport-
   anchored across pages, without affecting navigation while closed. */
@media (min-width:761px) and (max-width:980px) {
  html body.public-shell-page.sagaz-global-r345 .site-header.site-header.nav-open .links.links {
    position: fixed !important;
    top: 72px !important;
    bottom: 12px !important;
    left: 16px !important;
    right: 16px !important;
    width: calc(100vw - 32px) !important;
    height: calc(100dvh - 84px) !important;
    min-height: calc(100dvh - 84px) !important;
    max-height: calc(100dvh - 84px) !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    z-index: 1001 !important;
  }
}
