/* ==========================================================================
   nthdegreesearch Header Styles
   ========================================================================== */

/* -------------------------------------- */
/* HEADER (Desktop)
 * -------------------------------------- */
/* home */
header.site-header.header--mast.home-header {
    position: absolute;
    left: 0;
    right: 0;
    z-index: 99;
}

header.site-header.header--mast.home-header .header-nav .header-menu a {
  color: var(--wp--preset--color--white);
}

header.site-header.header--mast.home-header .header-burger span {
    background-color: var(--wp--preset--color--white);
}

header.site-header.header--mast.home-header .header-actions .btn-default-variant {
  background-color: transparent;
  border-color: var(--color-accent);
  color: var(--color-accent)
}
/* end home */
.site-header.header--mast {
  padding: 0;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 90px;
}

.header-logo a {
  font-family: var(--font-display);
  font-size: 24px;
  font-weight: 400;
  color: var(--color-primary);
  text-decoration: none;
}

.header-logo img {
  max-height: 42px;
  max-width: 100%;
  width: auto;
  height: auto;
  display: block;
}

/* Desktop menu */
.header-nav .header-menu {
  display: flex;
  gap: 40px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.header-nav .header-menu a {
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 16px;
  color: var(--color-primary);
  text-decoration: none;
}

.header-nav .header-menu a:hover {
  opacity: 0.8;
}

.header-actions {
  display: flex;
  gap: 12px;
}

/* Burger button (hidden by default) */
.header-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  width: 24px;
  height: 24px;
  background: none;
  border: none;
  cursor: pointer;
  gap: 4px;
}

.header-burger span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--color-primary);
  transition: 0.2s ease;
}

/* -------------------------------------- */
/* MOBILE NAVIGATION
 * Split into backdrop + drawer
 * -------------------------------------- */

.mobile-nav {
  position: fixed;
  inset: 0;
  z-index: 1000;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}

.mobile-nav__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(28, 28, 28, 0.3);
  backdrop-filter: blur(2px);
  opacity: 0;
  transition: opacity 0.2s ease-out;
}

.mobile-nav__drawer {
  position: relative;
  width: 80%;
  max-width: 340px;
  height: 100%;
  background: #fff;
  box-shadow: 4px 0 16px rgba(0, 0, 0, 0.05);
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: flex;
  flex-direction: column;
}

.mobile-nav.active {
  visibility: visible;
  opacity: 1;
  pointer-events: all;
}

.mobile-nav.active .mobile-nav__backdrop {
  opacity: 1;
}

.mobile-nav.active .mobile-nav__drawer {
  transform: translateX(0);
}

/* -------------------------------------- */
/* MOBILE NAV HEADER (logo + X button)
 * -------------------------------------- */

.mobile-nav__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.125rem 1.25rem;
}

.mobile-nav__header .custom-logo-link {
  line-height: 0;
}
.mobile-nav__header img.custom-logo {
  max-width: 151px;
}

.mobile-close {
  background: none;
  border: none;
  font-size: 35px;
  line-height: 1;
  cursor: pointer;
  color: #003E52;
  padding: 0;
}

/* -------------------------------------- */
/* MOBILE NAV CONTENT (menu + buttons)
 * -------------------------------------- */

.mobile-nav__content {
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  gap: 16px;
}

.mobile-menu {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  border-top: 1px solid #D7CFC5;
  border-bottom: 1px solid #D7CFC5;
}

.mobile-menu > li > a {
  font-family: var(--font-sans);
  font-weight: 500;
  color: var(--color-primary);
  text-decoration: none;
  display: block;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid #D7CFC5;
}

.mobile-menu > li:last-child > a {
  border-bottom: none;
}

.mobile-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 8px;
  padding: 0 1.25rem;
}

/* -------------------------------------- */
/* RESPONSIVE BEHAVIOR
 * -------------------------------------- */

/* Medium screens (1024px–1440px) */
@media (min-width: 1024px) and (max-width: 1440px) {
  .header-inner {
    height: 84px;
    gap: 30px;
  }

  .header-logo a {
    font-size: 22px;
  }

  .header-nav .header-menu {
    gap: 15px;
  }

  .header-nav .header-menu a {
    font-size: 13px;
    letter-spacing: 0.01em;
  }

  .header-actions .btn {
    padding: 10px 20px;
    font-size: 15px;
    border-radius: 6px;
  }

  .header-actions .btn--large {
    padding: 12px 22px;
    font-size: 15.5px;
    border-radius: 6px;
  }
}

/* Mobile breakpoint (≤1023px) */
@media (max-width: 1023px) {
  .header-nav,
  .header-actions {
    display: none;
  }

  .header-burger {
    display: flex;
  }

  .header-inner {
    height: 70px;
    padding: 0 24px;
  }

  .header-logo a,
  .header-logo img {
    font-size: 20px;
    max-height: 36px;
  }
}
