/* ============================================================
   MZANZI HEADER — header.css
   All header / nav / topbar / mobile drawer styles
   ============================================================ */

/* ── LAYOUT HELPERS ── */
.mz-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── SEARCH OVERLAY ── */
.mz-search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(14,31,22,.97);
  z-index: 9990;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}
.mz-search-overlay.open {
  opacity: 1;
  visibility: visible;
}
.mz-search-close {
  position: absolute;
  top: 28px; right: 28px;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.2);
  background: none;
  color: rgba(255,255,255,.7);
  font-size: 1.1rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .25s;
}
.mz-search-close:hover { border-color: var(--gold); color: var(--gold); }
.mz-search-box { width: 100%; max-width: 600px; padding: 0 24px; }
.mz-search-box form {
  display: flex;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: 60px;
  overflow: hidden;
}
.mz-search-box input {
  flex: 1;
  padding: 18px 24px;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.05rem;
  font-family: var(--ff-b);
  outline: none;
}
.mz-search-box input::placeholder { color: rgba(255,255,255,.35); }
.mz-search-box button {
  width: 58px;
  background: var(--gold);
  border: none;
  color: #fff;
  font-size: .95rem;
  cursor: pointer;
  transition: background .25s;
  flex-shrink: 0;
}
.mz-search-box button:hover { background: var(--gold-light); }

/* ── MOBILE OVERLAY & DRAWER ── */
.mz-mobile-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.65);
  z-index: 99991;
  opacity: 0; visibility: hidden;
  transition: all .3s;
}
.mz-mobile-overlay.open { opacity: 1; visibility: visible; }

.mz-mobile-drawer {
  position: fixed;
  top: 0; right: -110%;
  width: 320px; height: 100vh;
  background: var(--forest);
  z-index: 99992;
  display: flex; flex-direction: column;
  transition: right .32s cubic-bezier(.4,0,.2,1);
  overflow: hidden;
}
.mz-mobile-drawer.open { right: 0; }

/* Full-width drawer on phones */
@media (max-width: 600px) {
  .mz-mobile-drawer {
    width: 100% !important;
    right: -100% !important;
  }
  .mz-mobile-drawer.open {
    right: 0 !important;
  }
}

.mz-drawer-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 22px 18px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  flex-shrink: 0;
}
.mz-drawer-logo { display: flex; align-items: center; }
.mz-drawer-logo .mz-logo-img { max-height: 44px; width: auto; }
.mz-drawer-logo .mz-logo-text {
  font-family: var(--ff-d);
  font-size: 1.4rem;
  font-weight: 700;
  color: #fff;
}
.mz-drawer-close {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1.5px solid rgba(255,255,255,.25);
  background: rgba(255,255,255,.08);
  color: rgba(255,255,255,.9);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  transition: all .25s;
  flex-shrink: 0;
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}
.mz-drawer-close:hover,
.mz-drawer-close:active { border-color: var(--gold); color: var(--gold); background: rgba(196,154,46,.15); }

.mz-drawer-nav { flex: 1; overflow-y: auto; padding: 12px 0; }
.mz-mobile-menu { list-style: none; padding: 0; margin: 0; }
.mz-mobile-menu > li {
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.mz-mobile-menu > li > a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 22px;
  color: rgba(255,255,255,.85);
  font-size: .9rem;
  font-weight: 500;
  text-decoration: none;
  transition: color .25s, background .25s;
}
.mz-mobile-menu > li > a:hover,
.mz-mobile-menu > li.mz-active > a { color: var(--gold); background: rgba(255,255,255,.03); }
.mz-sub-arrow {
  font-size: .65rem;
  transition: transform .25s;
  color: rgba(255,255,255,.4);
}
.mz-mobile-has-sub.open > a .mz-sub-arrow { transform: rotate(180deg); color: var(--gold); }

.mz-mobile-sub {
  display: none;
  list-style: none;
  padding: 4px 0 8px 0;
  background: rgba(0,0,0,.18);
  margin: 0;
}
.mz-mobile-has-sub.open .mz-mobile-sub { display: block; }
.mz-mobile-sub li a {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 22px 10px 36px;
  color: rgba(255,255,255,.6);
  font-size: .83rem;
  text-decoration: none;
  transition: color .2s, padding-left .2s;
}
.mz-mobile-sub li a:hover { color: var(--gold); padding-left: 42px; }
.mz-mobile-sub li a i { color: var(--gold); font-size: .7rem; flex-shrink: 0; }

.mz-drawer-footer {
  padding: 18px 22px 24px;
  border-top: 1px solid rgba(255,255,255,.08);
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
}
.mz-drawer-contact-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .82rem;
  color: rgba(255,255,255,.55);
  text-decoration: none;
  transition: color .25s;
}
.mz-drawer-contact-item:hover { color: var(--gold); }
.mz-drawer-contact-item i { color: var(--gold); width: 14px; text-align: center; }
.mz-drawer-social {
  display: flex;
  gap: 10px;
  margin-top: 4px;
}
.mz-drawer-social a {
  width: 34px; height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.15);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.55);
  font-size: .78rem;
  text-decoration: none;
  transition: all .25s;
}
.mz-drawer-social a:hover { background: var(--gold); border-color: var(--gold); color: #fff; }

/* ── SITE HEADER ── */
.mz-header, #mzHeader {
  position: fixed !important;
  top: 0 !important; left: 0 !important; right: 0 !important;
  z-index: 99990 !important;
  width: 100% !important;
  transition: background .3s, box-shadow .3s, top .3s;
}
/* On mobile: switch to sticky so browser chrome shifts don't break layout */
@media (max-width: 900px) {
  .mz-header, #mzHeader {
    position: sticky !important;
    top: 0 !important;
    left: auto !important;
    right: auto !important;
    width: 100% !important;
  }
}
/* Push down when WP admin bar is visible */
.admin-bar .mz-header,
.admin-bar #mzHeader { top: 32px !important; }
@media screen and (max-width: 782px) {
  .admin-bar .mz-header,
  .admin-bar #mzHeader { top: 46px !important; }
}
/* Admin bar sits above everything */
#wpadminbar { z-index: 99999 !important; }
/* Hide our topbar when admin bar is showing */
.admin-bar .mz-topbar { display: none !important; }
@media screen and (max-width: 782px) {
  .admin-bar .mz-header { top: 46px; }
}

/* ── TOPBAR ── */
.mz-topbar {
  background: var(--forest-mid);
  padding: 7px 0;
  font-size: .78rem;
  border-bottom: 1px solid rgba(255,255,255,.06);
  transition: height .3s, opacity .3s, padding .3s;
}
.mz-header.scrolled .mz-topbar {
  height: 0;
  padding: 0;
  opacity: 0;
  overflow: hidden;
  pointer-events: none;
}
.mz-topbar .mz-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.mz-topbar-left, .mz-topbar-right {
  display: flex;
  align-items: center;
  gap: 18px;
}
.mz-topbar-item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: rgba(255,255,255,.65);
  text-decoration: none;
  transition: color .25s;
}
.mz-topbar-item:hover { color: var(--gold); }
.mz-topbar-item i { color: var(--gold); font-size: .7rem; }
.mz-topbar-right a {
  color: rgba(255,255,255,.6);
  text-decoration: none;
  font-weight: 500;
  transition: color .25s;
}
.mz-topbar-right a:hover { color: var(--gold); }
.mz-topbar-social {
  display: flex;
  gap: 10px;
  padding-left: 10px;
  border-left: 1px solid rgba(255,255,255,.12);
}
.mz-topbar-social a {
  width: 24px; height: 24px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.18);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.55) !important;
  font-size: .65rem;
  transition: all .25s;
}
.mz-topbar-social a:hover {
  background: var(--gold);
  border-color: var(--gold);
  color: #fff !important;
}

/* ── MAIN NAVBAR ── */
.mz-navbar {
  background: rgba(14,31,22,.88);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid rgba(255,255,255,.07);
  transition: background .3s, box-shadow .3s;
}
.mz-header.scrolled .mz-navbar {
  background: rgba(11,26,16,.97);
  box-shadow: 0 4px 24px rgba(0,0,0,.32);
  border-bottom-color: rgba(196,154,46,.16);
}
.mz-navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 24px;
}

/* ── LOGO — icon + wordmark ── */
.mz-logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  transition: opacity .25s;
}
.mz-logo:hover { opacity: .88; }

/* ── LOGO — text only ── */
.mz-logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  text-decoration: none;
  transition: opacity .25s;
}
.mz-logo:hover { opacity: .85; }
.mz-logo-text {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.55rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: .04em;
  line-height: 1;
  white-space: nowrap;
}

/* Mobile drawer logo */
.mz-drawer-logo {
  display: flex;
  align-items: center;
  text-decoration: none;
}
.mz-drawer-logo .mz-logo-text {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.35rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: .04em;
  line-height: 1;
}

/* ── DESKTOP NAV ── */
.mz-desktop-nav { flex: 1; display: flex; justify-content: flex-end; }
.mz-nav-list {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0;
  margin: 0; padding: 0;
}
.mz-nav-item { position: relative; }
.mz-nav-item > a {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 14px;
  color: rgba(255,255,255,.88);
  font-size: .84rem;
  font-weight: 500;
  letter-spacing: .025em;
  text-decoration: none;
  border-radius: 5px;
  white-space: nowrap;
  transition: color .25s, background .25s;
}
.mz-nav-item > a:hover,
.mz-nav-item.mz-active > a {
  color: var(--gold);
  background: rgba(255,255,255,.06);
}
.mz-caret {
  font-size: .58rem;
  opacity: .6;
  transition: transform .25s, opacity .25s;
}
.mz-has-dropdown:hover > a .mz-caret,
.mz-has-dropdown:focus-within > a .mz-caret {
  transform: rotate(180deg);
  opacity: 1;
}

/* ── DROPDOWN ── */
.mz-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(6px);
  min-width: 260px;
  background: var(--forest);
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 10px;
  padding: 8px 0;
  list-style: none;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transition: all .25s cubic-bezier(.16,1,.3,1);
  box-shadow: 0 16px 50px rgba(0,0,0,.45), 0 0 0 1px rgba(255,255,255,.04);
  z-index: 990;
  /* Prevent gap between nav item and dropdown */
  pointer-events: none;
}
/* Invisible bridge so mouse can travel to dropdown */
.mz-dropdown::before {
  content: '';
  position: absolute;
  top: -12px; left: 0; right: 0;
  height: 12px;
}
.mz-has-dropdown:hover .mz-dropdown,
.mz-has-dropdown:focus-within .mz-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.mz-dropdown-divider {
  height: 1px;
  background: rgba(255,255,255,.07);
  margin: 6px 16px;
}
.mz-dropdown li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 18px;
  color: rgba(255,255,255,.78);
  font-size: .83rem;
  text-decoration: none;
  transition: color .2s, background .2s, padding-left .2s;
  line-height: 1.4;
}
.mz-dropdown li a:hover {
  color: var(--gold);
  background: rgba(255,255,255,.05);
  padding-left: 22px;
}
.mz-dropdown li a i {
  color: var(--gold);
  font-size: .7rem;
  flex-shrink: 0;
  width: 12px;
  text-align: center;
}

/* ── HEADER RIGHT ACTIONS ── */
.mz-nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.mz-search-toggle {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.22);
  background: none;
  color: rgba(255,255,255,.78);
  font-size: .82rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all .25s;
}
.mz-search-toggle:hover { border-color: var(--gold); color: var(--gold); }

.mz-book-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  background: var(--gold);
  color: #fff;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 5px;
  white-space: nowrap;
  transition: background .25s, transform .2s, box-shadow .2s;
}
.mz-book-btn:hover {
  background: var(--gold-light);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(184,144,46,.4);
}
.mz-book-btn i { font-size: .88rem; }

/* Hamburger */
.mz-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  background: none;
  border: none;
  cursor: pointer;
}
.mz-hamburger span {
  display: block;
  width: 23px; height: 2px;
  background: rgba(255,255,255,.88);
  border-radius: 2px;
  transition: all .28s;
}
.mz-hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.mz-hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.mz-hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* ── RESPONSIVE ── */
@media (max-width: 1080px) {
  .mz-nav-item > a { padding: 8px 10px; font-size: .8rem; }
}

@media (max-width: 900px) {
  .mz-desktop-nav { display: none; }
  .mz-hamburger { display: flex; }
  .mz-topbar { display: none !important; }
  .mz-book-btn span { display: none; }
  .mz-book-btn { padding: 9px 12px; }
  .mz-navbar-inner { height: 60px; }
}

@media (max-width: 480px) {
  .mz-book-btn { display: none; }
  .mz-container { padding: 0 16px; }
  .mz-navbar-inner { height: 58px; }
  .mz-header-spacer { height: 58px !important; }
}

/* Header offset handled by critical inline CSS */

/* ── KILL ANY LEFTOVER GOWILDS/ELEMENTOR HEADER OUTPUT ── */
/* If old header template renders, hide it */
.header-builder-frontend,
.wp-site-header:not(#mzHeader),
.gowilds-page-loading,
.canvas-mobile,
#gva-overlay { display: none !important; }

/* ── WHEN DRAWER IS OPEN — hide navbar actions so nothing bleeds ── */
body.drawer-open .mz-nav-actions,
body.drawer-open .mz-desktop-nav {
  visibility: hidden !important;
  pointer-events: none !important;
}

/* ══════════════════════════════════════════════════════
   MOBILE NAV — #mzMobileNav
   Completely independent from .mz-header.
   Fixed to top, full width, 60px tall. Zero conflicts.
   ══════════════════════════════════════════════════════ */

/* Hide desktop header on mobile */
@media (max-width: 900px) {
  .mz-header, #mzHeader {
    display: none !important;
  }
}

/* Hide mobile nav on desktop */
#mzMobileNav,
#mzMobileNavSpacer {
  display: none;
}

@media (max-width: 900px) {
  /* The fixed bar */
  #mzMobileNav {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    padding: 0 16px;
    background: rgba(11, 26, 16, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(196, 154, 46, 0.2);
    z-index: 99990;
    box-sizing: border-box;
  }

  /* Logo text */
  .mzm-logo {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 1.3rem;
    font-weight: 700;
    color: #fff;
    text-decoration: none;
    letter-spacing: 0.03em;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: calc(100% - 100px);
  }

  /* Right side buttons */
  .mzm-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
  }

  .mzm-search-btn,
  .mzm-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    background: none;
    border: none;
    color: rgba(255,255,255,0.88);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    border-radius: 8px;
    transition: background 0.2s;
  }
  .mzm-search-btn:active,
  .mzm-menu-btn:active {
    background: rgba(255,255,255,0.08);
  }

  /* Hamburger lines */
  .mzm-menu-btn {
    flex-direction: column;
    gap: 5px;
    padding: 10px;
  }
  .mzm-menu-btn span {
    display: block;
    width: 22px;
    height: 2px;
    background: rgba(255,255,255,0.88);
    border-radius: 2px;
    transition: all 0.25s;
    pointer-events: none;
  }

  /* Spacer pushes page content below the fixed bar */
  #mzMobileNavSpacer {
    display: block !important;
    width: 100%;
    height: 60px; /* fallback — JS sets exact value */
    flex-shrink: 0;
  }
}
