:root {
  --dm-navy: #1C2448;
  --dm-navy-deep: #111936;
  --dm-gold: #d9ad45;
  --dm-white: #ffffff;
  --dm-header-blur: 18px;
  --dm-header-transition: 260ms cubic-bezier(.22,.72,.22,1);
  --dm-ocean-header-mobile-height: 0px;
  --dm-ocean-header-mobile-top: 0px;
}

/* ========================================================================== 
   DM Automação — Header flutuante
   OceanWP fornece apenas a estrutura. Nenhum container do tema fica visível.
   ========================================================================== */

/* Marca técnica usada pelo JavaScript: o header só é revelado depois que
   esta folha de estilos realmente foi aplicada. */
#site-header { --dm-header-css-ready: 1; }

/* A experiência DM não utiliza a Top Bar nativa do OceanWP. */
html body.dm-ocean-header-enabled #top-bar-wrap,
html body.dm-ocean-header-enabled #top-bar {
  display: none !important;
  height: 0 !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}



/*
 * O shell do OceanWP vira apenas um suporte técnico invisível.
 * Fica FIXO e fora do fluxo: nenhuma faixa do tema ocupa altura visual.
 */
html body.dm-ocean-header-enabled #outer-wrap #wrap #site-header,
html body.dm-ocean-header-enabled #site-header {
  position: fixed !important;
  top: 0 !important;
  right: 0 !important;
  left: 0 !important;
  z-index: 9999 !important;
  width: 100% !important;
  max-width: none !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 12px 0 7px !important;
  overflow: visible !important;
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
  pointer-events: none;
}

html body.admin-bar.dm-ocean-header-enabled #outer-wrap #wrap #site-header,
html body.admin-bar.dm-ocean-header-enabled #site-header {
  top: 32px !important;
}

/* Remove qualquer pintura/pseudo-elemento do shell OceanWP. */
html body.dm-ocean-header-enabled #site-header::before,
html body.dm-ocean-header-enabled #site-header::after {
  content: none !important;
  display: none !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

/*
 * Neutraliza todos os wrappers visuais conhecidos do OceanWP.
 * O ::before de #site-header-inner NÃO entra aqui porque ele é o card DM.
 */
html body.dm-ocean-header-enabled #site-header .container,
html body.dm-ocean-header-enabled #site-header .container.clr,
html body.dm-ocean-header-enabled #site-header .oceanwp-row,
html body.dm-ocean-header-enabled #site-header .clr,
html body.dm-ocean-header-enabled #site-header .header-top,
html body.dm-ocean-header-enabled #site-header .header-bottom,
html body.dm-ocean-header-enabled #site-header .header-middle,
html body.dm-ocean-header-enabled #site-header .header-wrap,
html body.dm-ocean-header-enabled #site-header .header-inner,
html body.dm-ocean-header-enabled #site-header .custom-header,
html body.dm-ocean-header-enabled #site-header-inner,
html body.dm-ocean-header-enabled #site-header-inner.container,
html body.dm-ocean-header-enabled #site-header-inner.clr,
html body.dm-ocean-header-enabled #site-navigation-wrap,
html body.dm-ocean-header-enabled #site-logo,
html body.dm-ocean-header-enabled .oceanwp-mobile-menu-icon {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
}

/* O shell não intercepta cliques; apenas os componentes reais do header recebem interação. */
html body.dm-ocean-header-enabled #site-header-inner {
  pointer-events: none;
}

html body.dm-ocean-header-enabled #site-logo,
html body.dm-ocean-header-enabled .dm-header-brand-copy,
html body.dm-ocean-header-enabled #site-navigation-wrap,
html body.dm-ocean-header-enabled .oceanwp-mobile-menu-icon,
html body.dm-ocean-header-enabled .dm-header-system-cta,
html body.dm-ocean-header-enabled #mobile-dropdown,
html body.dm-ocean-header-enabled #mobile-dropdown * {
  pointer-events: auto;
}

/* OceanWP / extensões podem adicionar classes sticky próprias: continuam invisíveis. */
html body.dm-ocean-header-enabled .is-sticky #site-header,
html body.dm-ocean-header-enabled #site-header.is-sticky,
html body.dm-ocean-header-enabled .sticky-header #site-header,
html body.dm-ocean-header-enabled .oceanwp-sticky-header-holder,
html body.dm-ocean-header-enabled .oceanwp-sticky-header-holder #site-header {
  background: transparent !important;
  background-color: transparent !important;
  background-image: none !important;
  border: 0 !important;
  box-shadow: none !important;
}

body.dm-ocean-header-enabled #site-header-inner {
  position: relative;
  isolation: isolate;
  display: flex;
  align-items: center;
  width: calc(100% - 40px) !important;
  max-width: 1240px !important;
  min-height: 72px;
  margin: 0 auto !important;
  padding: 0 144px 0 18px !important;
  box-sizing: border-box;
}

/* Único bloco visual principal do header. */
body.dm-ocean-header-enabled #site-header-inner::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 132px 0 0;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 20px;
  background: rgba(6,22,42,.94);
  box-shadow: 0 14px 38px rgba(9,14,38,.22);
  -webkit-backdrop-filter: blur(var(--dm-header-blur)) saturate(148%);
  backdrop-filter: blur(var(--dm-header-blur)) saturate(148%);
  transition:
    background-color var(--dm-header-transition),
    border-color var(--dm-header-transition),
    box-shadow var(--dm-header-transition),
    transform var(--dm-header-transition);
}

body.dm-ocean-header-scrolled #site-header-inner::before {
  background: rgba(6,22,42,.64);
  border-color: rgba(255,255,255,.18);
  box-shadow: 0 18px 44px rgba(9,14,38,.28);
}

/* Marca: logo + nome + slogan. */
body.dm-ocean-header-enabled #site-logo,
body.dm-ocean-header-enabled #site-logo #site-logo-inner {
  position: relative;
  z-index: 2;
  flex: 0 0 auto;
  height: 72px !important;
  line-height: 72px !important;
}

body.dm-ocean-header-enabled #site-logo {
  margin: 0 !important;
  padding: 0 !important;
}

body.dm-ocean-header-enabled #site-logo img {
  display: inline-block;
  width: auto;
  max-width: none;
  max-height: 52px !important;
  vertical-align: middle;
  transition: transform 180ms ease, max-height var(--dm-header-transition);
}

body.dm-ocean-header-enabled #site-logo a:hover img,
body.dm-ocean-header-enabled #site-logo a:focus img { transform: translateY(-1px); }

.dm-header-brand-copy {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
  margin: 0 0 0 13px;
  padding: 0 0 0 14px;
  border-left: 1px solid rgba(255,255,255,.16);
  color: #fff !important;
  line-height: 1.1;
  text-decoration: none !important;
  white-space: nowrap;
}

.dm-header-brand-copy:hover,
.dm-header-brand-copy:focus { color: #fff !important; }

.dm-header-brand-copy__name {
  display: block;
  overflow: hidden;
  color: #fff;
  font-size: 15px;
  font-weight: 760;
  letter-spacing: -.015em;
  text-overflow: ellipsis;
}

.dm-header-brand-copy__tagline {
  display: block;
  margin-top: 5px;
  overflow: hidden;
  color: rgba(255,255,255,.62);
  font-size: 9.5px;
  font-weight: 600;
  letter-spacing: .055em;
  text-transform: uppercase;
  text-overflow: ellipsis;
}

.dm-header-brand-copy__tagline i {
  margin: 0 3px;
  color: var(--dm-gold);
  font-style: normal;
}

/* Navegação do cartão principal. */
@media (min-width: 960px) {
  body.dm-ocean-header-enabled #site-navigation-wrap {
    position: relative;
    z-index: 2;
    display: flex !important;
    align-items: center;
    height: 72px !important;
    margin: 0 20px 0 auto !important;
    background: transparent !important;
  }

  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu {
    display: flex;
    align-items: center;
    gap: 5px;
    height: 100%;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
  }

  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li {
    display: flex;
    align-items: center;
    height: 100%;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
  }

  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li > a {
    position: relative;
    display: inline-flex !important;
    align-items: center;
    gap: 8px;
    height: 42px !important;
    min-height: 42px;
    padding: 0 12px !important;
    border: 1px solid transparent;
    border-radius: 12px;
    background: transparent !important;
    color: rgba(255,255,255,.78) !important;
    font-size: 13px;
    font-weight: 650;
    line-height: 1 !important;
    letter-spacing: .005em;
    text-transform: none;
    transition: color 180ms ease, background-color 180ms ease, border-color 180ms ease, transform 180ms ease;
  }

  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li > a:hover,
  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li > a:focus,
  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li.current-menu-item > a,
  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li.current_page_item > a,
  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li.current-menu-ancestor > a {
    color: #fff !important;
    border-color: rgba(255,255,255,.10);
    background: rgba(255,255,255,.075) !important;
    transform: translateY(-1px);
  }

  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li.current-menu-item > a::after,
  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li.current_page_item > a::after,
  body.dm-ocean-header-enabled #site-navigation-wrap .dropdown-menu > li.current-menu-ancestor > a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 4px;
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: var(--dm-gold);
    transform: translateX(-50%);
  }
}

/* SVGs modernos. */
.dm-header-menu-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  color: currentColor;
}

.dm-header-menu-icon svg,
.dm-header-system-cta__icon svg {
  display: block;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Login original some; CTA independente ocupa sua própria cápsula. */
body.dm-ocean-header-enabled li.dm-header-original-login-item { display: none !important; }

.dm-header-system-cta {
  position: absolute;
  z-index: 4;
  top: 50%;
  right: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 120px;
  height: 56px;
  padding: 0 16px;
  box-sizing: border-box;
  border: 1px solid rgba(255,255,255,.96);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(9,14,38,.20);
  color: var(--dm-navy) !important;
  font-size: 13px;
  font-weight: 760;
  line-height: 1;
  letter-spacing: .005em;
  text-decoration: none !important;
  transform: translateY(-50%);
  transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
}

.dm-header-system-cta:hover,
.dm-header-system-cta:focus {
  color: var(--dm-navy) !important;
  background: rgba(255,255,255,.95);
  box-shadow: 0 16px 34px rgba(9,14,38,.26);
  transform: translateY(calc(-50% - 2px));
}

.dm-header-system-cta__icon {
  display: inline-flex;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
}

/* Fallback sem backdrop-filter. */
@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  body.dm-ocean-header-enabled #site-header-inner::before { background: rgba(28,36,72,.97); }
}

/* ========================================================================== 
   Mobile — card flutuante + acesso separado, sem container OceanWP visível
   ========================================================================== */
.dm-ocean-header-spacer {
  display: none;
  width: 100%;
  height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  pointer-events: none;
}

@media (max-width: 959px) {
  body.dm-ocean-header-enabled #site-header {
    padding: 9px 0 6px !important;
  }

  body.dm-ocean-header-enabled.dm-ocean-header-mobile-fixed #site-header {
    position: fixed !important;
    top: var(--dm-ocean-header-mobile-top) !important;
    right: 0;
    left: 0;
    width: 100%;
    max-width: none;
    margin: 0;
    box-sizing: border-box;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
  }

  body.dm-ocean-header-mobile-fixed .dm-ocean-header-spacer {
    display: none !important;
    height: 0 !important;
  }

  body.dm-ocean-header-enabled #site-header-inner {
    width: calc(100% - 20px) !important;
    max-width: none !important;
    min-height: 64px;
    padding: 0 70px 0 12px !important;
  }

  body.dm-ocean-header-enabled #site-header-inner::before {
    inset: 0 60px 0 0;
    border-radius: 18px;
  }

  body.dm-ocean-header-enabled #site-logo,
  body.dm-ocean-header-enabled #site-logo #site-logo-inner {
    height: 64px !important;
    line-height: 64px !important;
  }

  body.dm-ocean-header-enabled #site-logo img { max-height: 42px !important; }

  .dm-header-brand-copy {
    max-width: calc(100vw - 205px);
    margin-left: 10px;
    padding-left: 10px;
  }

  .dm-header-brand-copy__name { font-size: 13px; }
  .dm-header-brand-copy__tagline {
    margin-top: 4px;
    font-size: 8px;
    letter-spacing: .035em;
  }

  body.dm-ocean-header-enabled .oceanwp-mobile-menu-icon {
    position: relative;
    z-index: 3;
    display: flex !important;
    align-items: center;
    height: 64px !important;
    margin: 0 0 0 auto !important;
    background: transparent !important;
  }

  body.dm-ocean-header-enabled .oceanwp-mobile-menu-icon a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 42px;
    padding: 0 !important;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 12px;
    background: rgba(255,255,255,.06) !important;
    color: #fff !important;
    line-height: 1 !important;
  }

  body.dm-ocean-header-enabled .mobile-menu .hamburger-inner,
  body.dm-ocean-header-enabled .mobile-menu .hamburger-inner::before,
  body.dm-ocean-header-enabled .mobile-menu .hamburger-inner::after {
    background-color: #fff !important;
  }

  .dm-header-system-cta {
    width: 52px;
    height: 52px;
    padding: 0;
    border-radius: 16px;
  }

  .dm-header-system-cta__label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
  }

  body.dm-ocean-header-enabled #mobile-dropdown {
    position: fixed !important;
    z-index: 9998;
    top: calc(var(--dm-ocean-header-mobile-top) + var(--dm-ocean-header-mobile-height) + 3px) !important;
    right: 10px;
    left: 10px;
    width: auto;
    max-height: calc(100dvh - var(--dm-ocean-header-mobile-top) - var(--dm-ocean-header-mobile-height) - 18px) !important;
    padding: 10px;
    box-sizing: border-box;
    overflow-x: hidden;
    overflow-y: auto;
    border: 1px solid rgba(255,255,255,.13) !important;
    border-radius: 18px;
    background: rgba(28,36,72,.96) !important;
    box-shadow: 0 18px 42px rgba(9,14,38,.30);
    -webkit-backdrop-filter: blur(18px) saturate(145%);
    backdrop-filter: blur(18px) saturate(145%);
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
  }

  body.dm-ocean-header-enabled #mobile-dropdown > ul,
  body.dm-ocean-header-enabled #mobile-dropdown .menu,
  body.dm-ocean-header-enabled #mobile-dropdown ul {
    width: 100%;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body.dm-ocean-header-enabled #mobile-dropdown ul li {
    width: 100%;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  body.dm-ocean-header-enabled #mobile-dropdown ul li > a {
    display: flex !important;
    align-items: center;
    gap: 11px;
    width: 100%;
    min-height: 52px;
    padding: 0 14px !important;
    box-sizing: border-box;
    border: 1px solid transparent !important;
    border-radius: 12px;
    background: transparent !important;
    color: rgba(255,255,255,.82) !important;
    font-size: 14px;
    font-weight: 650;
    line-height: 1.2 !important;
    text-decoration: none !important;
    transition: color 180ms ease, background-color 180ms ease, border-color 180ms ease;
  }

  body.dm-ocean-header-enabled #mobile-dropdown ul li > a:hover,
  body.dm-ocean-header-enabled #mobile-dropdown ul li > a:focus,
  body.dm-ocean-header-enabled #mobile-dropdown ul li.current-menu-item > a,
  body.dm-ocean-header-enabled #mobile-dropdown ul li.current_page_item > a,
  body.dm-ocean-header-enabled #mobile-dropdown ul li.current-menu-ancestor > a {
    color: #fff !important;
    border-color: rgba(255,255,255,.10) !important;
    background: rgba(255,255,255,.07) !important;
  }
}

@supports not (height: 100dvh) {
  @media (max-width: 959px) {
    body.dm-ocean-header-enabled #mobile-dropdown {
      max-height: calc(100vh - var(--dm-ocean-header-mobile-top) - var(--dm-ocean-header-mobile-height) - 18px) !important;
    }
  }
}

@media (max-width: 782px) {
  html body.admin-bar.dm-ocean-header-enabled #outer-wrap #wrap #site-header,
  html body.admin-bar.dm-ocean-header-enabled #site-header {
    top: 46px !important;
  }
}

@media (max-width: 520px) {
  .dm-header-brand-copy { max-width: calc(100vw - 190px); }
  .dm-header-brand-copy__tagline { display: none; }
}

@media (max-width: 390px) {
  body.dm-ocean-header-enabled #site-header-inner {
    width: calc(100% - 14px) !important;
    padding-left: 9px !important;
  }

  body.dm-ocean-header-enabled #site-logo img { max-height: 38px !important; }
  .dm-header-brand-copy {
    max-width: calc(100vw - 174px);
    margin-left: 8px;
    padding-left: 8px;
  }
  .dm-header-brand-copy__name { font-size: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  body.dm-ocean-header-enabled #site-header *,
  body.dm-ocean-header-enabled #site-header-inner::before,
  .dm-header-system-cta {
    transition: none !important;
  }
}
