/*
 * Heart of Hope — Sanctuary‑Soft Header
 * Clean, stable, unclipped mobile slide‑down menu
 */

/* ---------------------------------------------------------
   HEADER WRAPPER
--------------------------------------------------------- */

.hoh-header {
  background: var(--hoh-white-bg);
  box-shadow: var(--hoh-shadow-soft);
  padding: var(--hoh-space-sm) 0;

  position: sticky;
  top: 0;

  /* Always above chat wrapper + composer + editor */
  z-index: 10000;
  width: 100%;
}

/* WordPress admin bar offset */
.admin-bar .hoh-header {
  top: 32px !important;
}

@media (max-width: 782px) {
  .admin-bar .hoh-header {
    top: 46px !important; /* taller mobile admin bar */
  }
}

/* ---------------------------------------------------------
   INNER LAYOUT
--------------------------------------------------------- */

.hoh-header-inner {
  max-width: var(--hoh-max-width-main);
  margin: 0 auto;
  padding: 0 var(--hoh-space-md);

  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ---------------------------------------------------------
   LOGO
--------------------------------------------------------- */

.hoh-logo img {
  height: 58px;
  width: auto;
  border-radius: var(--hoh-radius-sm);
}

/* ---------------------------------------------------------
   DESKTOP NAV
--------------------------------------------------------- */

.hoh-header-nav {
  display: block;
}

.hoh-nav-list a {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  text-decoration: none;
  color: var(--hoh-purple);

  font-family: var(--hoh-font-sans);
  font-weight: 500;
  font-size: 1rem;

  white-space: nowrap;
  padding: 8px 12px;
  border-radius: var(--hoh-radius-sm);

  transition: opacity 0.25s ease, background 0.25s ease;
}

.hoh-nav-list a:hover {
  background: var(--hoh-lavender-hover);
  opacity: 1;
}

/* ---------------------------------------------------------
   HAMBURGER (HIDDEN ON DESKTOP)
--------------------------------------------------------- */

.hoh-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;

  /* Above header content */
  z-index: 10001;
}

.hoh-hamburger span {
  display: block;
  width: 26px;
  height: 3px;
  background: var(--hoh-purple);
  margin: 5px 0;
  border-radius: 3px;
  transition: all 0.3s ease;
}

/* ---------------------------------------------------------
   MOBILE MODE (max-width: 900px)
--------------------------------------------------------- */

@media (max-width: 900px) {

  /* Hide desktop nav */
  .hoh-header-nav {
    display: none;
  }

  /* Show hamburger */
  .hoh-hamburger {
    display: block;
  }

  /* MOBILE MENU — base layout */
  .hoh-mobile-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;

    background: var(--hoh-glass-tint);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(10px);

    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;

    z-index: 9999;

    /* Hidden by default */
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.35s ease, opacity 0.25s ease;

    /* Visual breathing room */
    padding-top: 12px;
  }

  .hoh-mobile-menu::-webkit-scrollbar {
    display: none;
  }

  /* When JS toggles .open */
  .hoh-mobile-menu.open {
    max-height: 600px;
    opacity: 1;
  }

  /* Close button */
  .hoh-mobile-close {
    position: absolute;
    top: 14px;
    right: 14px;

    background: none;
    border: none;
    padding: 6px;

    font-size: 22px;
    line-height: 1;
    cursor: pointer;

    color: var(--hoh-purple);
    z-index: 10001;
  }

  /* Mobile nav container — defines horizontal rhythm */
  .hoh-mobile-nav {
    padding-left: var(--hoh-space-md);
    padding-right: var(--hoh-space-md);
  }

  /* NAV LIST */
  .hoh-mobile-nav-list {
    list-style: none;
    padding: var(--hoh-space-md) 0;
    margin: 0;

    display: flex;
    flex-direction: column;
    gap: var(--hoh-space-sm);
    align-items: center;
    text-align: center;
  }

  .hoh-mobile-nav-list a {
    display: block;
    width: 100%;
    max-width: 280px;
    margin: 0 auto;
    padding: 14px 20px;

    background: rgba(255, 255, 255, 0.6);
    border-radius: 12px;

    color: #4b0082 !important;
    font-size: 1.2rem;
    font-weight: 600;

    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
    transition: all 0.25s ease;
  }

  .hoh-mobile-nav-list a:hover {
    background: rgba(255, 255, 255, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.12);
  }
}
