.anth-home .anth-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(0, 1, 2, 0.72);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.anth-home .anth-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 24px;
  padding: 18px 0;
}

/* Todos os itens (logo, ícones, conta/login, hambúrguer) são filhos
   diretos de .anth-header-inner — sem wrappers de layout — então a
   ordem visual é só uma questão de `order`, igual em qualquer
   largura de tela. Isso evita de vez os bugs de reordenação que
   `display:contents` + wrappers intermediários vinham causando. */
.anth-home .anth-logo {
  order: 1;
}

.anth-home .anth-nav {
  order: 2;
}

.anth-home .anth-header-icons {
  order: 3;
  display: flex;
  align-items: center;
  gap: 10px;
}

.anth-home .anth-account-pill,
.anth-home .anth-btn-sm {
  order: 4;
}

.anth-home .anth-nav-toggle {
  order: 5;
}

.anth-home .anth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 64px;
  min-width: 0;
  overflow: hidden;
  flex-shrink: 1;
  color: var(--text);
  font-family: var(--serif);
  font-size: 19px;
  font-weight: 600;
  text-decoration: none;
}

.anth-home .anth-account-pill,
.anth-home .anth-btn-sm {
  flex-shrink: 0;
}

.anth-home .anth-logo svg {
  color: var(--teal);
  flex-shrink: 0;
  height: 100%;
  width: auto;
}

.anth-home .anth-logo-wordmark {
  height: 60%;
  width: auto;
  transition: filter 0.2s ease;
}

.anth-home .anth-nav {
  display: flex;
  align-items: center;
  gap: 36px;
}

.anth-home .anth-nav a {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--text-dim);
  text-decoration: none;
  white-space: nowrap;
}

.anth-home .anth-nav a:hover {
  color: var(--teal);
}

.anth-home .anth-btn-sm {
  padding: 9px 18px;
  font-size: 13px;
}

/* Botão hambúrguer — só existe visualmente abaixo do breakpoint.
   !important pra garantir que nada do tema (Customify) sobrescreva. */
.anth-home .anth-nav-toggle {
  display: none !important;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}

.anth-home .anth-nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.anth-home .anth-nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.anth-home .anth-nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.anth-home .anth-nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Breakpoint deliberadamente alto: em vez de deixar o nav quebrar em
   2 linhas e colidir com logo/ações (bug antigo), ele vira dropdown
   por hambúrguer bem antes de faltar espaço. */
@media (max-width: 1200px) {
  .anth-home .anth-nav {
    position: fixed;
    top: var(--anth-own-header-h, 64px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(0, 1, 2, 0.96);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid var(--border);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    z-index: 99;
    transition: max-height 0.25s ease, opacity 0.2s ease;
  }

  .anth-home .anth-nav.is-open {
    max-height: 70vh;
    opacity: 1;
    visibility: visible;
    overflow-y: auto;
  }

  .anth-home .anth-nav a {
    padding: 16px clamp(20px, 6vw, 32px);
    border-top: 1px solid rgba(255, 255, 255, 0.06);
  }

  .anth-home .anth-nav-toggle {
    display: inline-flex !important;
  }

  /* Tudo numa linha só, sempre — sem quebrar em 2 linhas. A logo é o
     único elemento elástico: ela cresce pra ocupar o espaço livre e
     encolhe (com o SVG/wordmark reduzindo proporcionalmente dentro
     dela) quando o espaço aperta, em vez de ficar por baixo de outra
     coisa. Os demais itens (ícones, conta/login, hambúrguer) mantêm o
     tamanho fixo; logo, ícones, conta e hambúrguer são todos filhos
     diretos de .anth-header-inner (sem wrapper), então ficam sempre
     na mesma linha. */
  .anth-home .anth-header-inner {
    flex-wrap: nowrap;
    gap: 8px;
  }

  .anth-home .anth-logo {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
  }

  .anth-home .anth-logo svg {
    max-width: 100%;
    object-fit: contain;
  }

  .anth-home .anth-header-icons,
  .anth-home .anth-account-pill,
  .anth-home .anth-btn-sm,
  .anth-home .anth-nav-toggle {
    flex-shrink: 0;
  }
}

/* Mobile (telas de celular): header fixo no topo, mais compacto na
   vertical (menos espaço sobrando acima/abaixo do símbolo) e logo
   reduzida pra não colidir com o botão "Entrar" / hambúrguer. Como
   position:fixed tira o header do fluxo normal, compensamos com
   padding-top no .anth-home (senão o hero sobe e fica embaixo do
   header). */
@media (max-width: 600px) {
  .anth-home .anth-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
  }

  .anth-home .anth-header-inner {
    padding: 8px 0;
    gap: 8px;
  }

  /* Mais área horizontal pro header nessa largura: reduz só o padding
     lateral do wrap do header (não mexe no resto do site). */
  .anth-home .anth-header .anth-wrap {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  .anth-home .anth-header-inner {
    min-height: 38px;
  }

  .anth-home .anth-logo {
    height: 38px;
    gap: 6px;
  }

  /* Só no mobile o wordmark escrito some — fica só o símbolo. No
     desktop/tablet ele continua igual a antes (isso tinha sido
     removido sem querer; aqui é a correção). */
  .anth-home .anth-logo-wordmark {
    display: none;
  }

  .anth-home .anth-account-pill,
  .anth-home .anth-btn-sm {
    flex-shrink: 0;
  }

  .anth-home .anth-btn-sm {
    padding: 8px 14px;
    font-size: 12.5px;
  }

  .anth-home .anth-nav-toggle {
    width: 30px;
    height: 30px;
  }

  /* Esse padding-top só deve empurrar o CONTEÚDO da home de verdade
     (hero etc.) pra baixo do header fixo. O mesmo wrapper .anth-home
     também é reaproveitado só pra IMPRIMIR o header nas páginas com
     header global (render_global_header(), em class-anthares-home.php)
     — nesse caso ele não envolve conteúdo nenhum, só o header, e esse
     padding vira um vão vazio sobrando entre o header e o conteúdo
     real da página (ex.: a caixa "Minha Conta"). Por isso escopamos
     pra fora de .anth-home--header-only, que é a classe extra que
     esse wrapper "só header" recebe. */
  .anth-home:not(.anth-home--header-only) {
    padding-top: 55px;
  }
}

.anth-home .anth-account-pill {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 14px 4px 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  text-decoration: none;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.anth-home .anth-account-pill:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.18);
}

.anth-home .anth-account-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #00d1b2;
}

.anth-home .anth-account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.anth-home .anth-account-avatar-fallback {
  color: #06231f;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.5px;
}

.anth-home .anth-account-info {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.anth-home .anth-account-name {
  color: #fff;
  font-weight: 600;
  font-size: 13.5px;
}

.anth-home .anth-account-role {
  color: #00d1b2;
  font-size: 11.5px;
  font-weight: 500;
}

/* ---------- Dropdown do menu nativo (sub-menu do WP) ---------- */

.anth-home .anth-nav .anth-nav-item {
  position: relative;
}

.anth-home .anth-nav .sub-menu {
  list-style: none;
  margin: 0;
  padding: 10px;
  position: absolute;
  top: calc(100% + 14px);
  left: 50%;
  transform: translateX(-50%);
  min-width: 220px;
  background: rgba(6, 10, 14, 0.98);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateX(-50%) translateY(6px);
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
  z-index: 20;
}

.anth-home .anth-nav .anth-nav-item:hover > .sub-menu,
.anth-home .anth-nav .anth-nav-item.is-open > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.anth-home .anth-nav .sub-menu li a {
  display: block;
  padding: 9px 12px;
  border-radius: 8px;
  text-transform: none;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  white-space: nowrap;
}

.anth-home .anth-nav .sub-menu li a:hover {
  background: rgba(0, 209, 178, 0.1);
  color: var(--teal);
}

/* O caret agora é um <button> irmão do <a>, não mais um <span> dentro
   dele — assim ele ganha um alvo de toque próprio (essencial no
   mobile/tablet, onde não existe :hover pra abrir o submenu) sem
   "sequestrar" o clique no texto do link, que continua navegando
   normalmente pro href. O desenho da seta é um ::after (borda em L
   rotacionada) centralizado dentro do botão; o botão em si só define
   a área clicável, maior que o desenho pra facilitar o toque. */
.anth-home .anth-nav .anth-nav-item-head {
  display: flex;
  align-items: center;
}

.anth-home .anth-nav button.anth-nav-caret {
  appearance: none;
  background: transparent;
  border: 0;
  margin: 0 0 0 -4px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  color: inherit;
  cursor: pointer;
  flex-shrink: 0;
}

.anth-home .anth-nav button.anth-nav-caret::after {
  content: "";
  display: block;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.2s ease;
}

.anth-home .anth-nav .has-children.is-open > .anth-nav-item-head > button.anth-nav-caret::after {
  transform: rotate(225deg);
}



/* ---------- Lupa de busca ---------- */

.anth-home .anth-ic2:hover {
  opacity: 0.7 !important;
}

.anth-home .anth-search-box {
  position: absolute;
  top: calc(100% + 14px);
  right: 24px;
  width: min(360px, calc(100vw - 48px));
  background: rgba(6, 10, 14, 0.98);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
  z-index: 30;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.anth-home .anth-search-box.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.anth-home .anth-search-box input {
  width: 100%;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text);
  font-size: 13.5px;
}

.anth-home .anth-search-box input:focus {
  outline: none;
  border-color: var(--teal);
}

/* ---------- Sino de notificações ---------- */

.anth-home .anth-notif {
  position: relative;
}

.anth-home .anth-notif-badge {
  position: absolute;
  top: -3px;
  right: -3px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #c0392b;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
  box-shadow: 0 0 0 2px #06040a;
}

.anth-home .anth-notif-panel {
  position: absolute;
  top: calc(100% + 14px);
  right: 0;
  width: 340px;
  max-width: calc(100vw - 48px);
  background: rgba(6, 10, 14, 0.98);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s ease;
  z-index: 30;
  overflow: hidden;
}

.anth-home .anth-notif-panel.is-open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.anth-home .anth-notif-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
}

.anth-home .anth-notif-marcar-todas {
  background: none;
  border: none;
  color: var(--teal);
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  padding: 0;
}

.anth-home .anth-notif-panel-list {
  max-height: 340px;
  overflow-y: auto;
}

.anth-home .anth-notif-item {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 12px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  text-decoration: none;
  cursor: pointer;
}

.anth-home .anth-notif-item:hover {
  background: rgba(255, 255, 255, 0.04);
}

.anth-home .anth-notif-item.is-unread {
  background: rgba(0, 209, 178, 0.06);
}

.anth-home .anth-notif-item.is-unread .anth-notif-item-msg::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--teal);
  margin-right: 7px;
}

.anth-home .anth-notif-item-msg {
  color: var(--text);
  font-size: 13px;
  line-height: 1.4;
}

.anth-home .anth-notif-item-time {
  color: var(--text-dim);
  font-size: 11px;
}

.anth-home .anth-notif-empty {
  padding: 20px 16px;
  color: var(--text-dim);
  font-size: 13px;
  text-align: center;
}

.anth-home .anth-notif-panel-footer {
  display: block;
  text-align: center;
  padding: 12px 16px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--teal);
  text-decoration: none;
  border-top: 1px solid var(--border);
}

.anth-home .anth-notif-panel-footer:hover {
  background: rgba(255, 255, 255, 0.04);
}

@media (max-width: 640px) {
  .anth-home .anth-search-box,
  .anth-home .anth-notif-panel {
    position: fixed;
    top: var(--anth-own-header-h, 64px);
    left: 50%;
    right: auto;
    width: calc(100vw - 32px);
    max-width: 340px;
    transform: translate(-50%, 6px);
  }

  .anth-home .anth-search-box.is-open,
  .anth-home .anth-notif-panel.is-open {
    transform: translate(-50%, 0);
  }
}

.anth-home .anth-nav > .anth-nav-item:first-child .anth-nav-item-head > a {
  color: var(--teal);
}

.anth-home .anth-logo svg {
  transition: filter 0.2s ease;
}

.anth-home .anth-logo:hover svg,
.anth-home .anth-logo:hover .anth-logo-wordmark {
  filter: brightness(1.4);
}