/* LVL29 theme 8 header 
   SECTION: HEADER — START
   ============================================================ */
/* =========================================================
   HEADER
   ========================================================= */

/* --- Squeeze contract (main.js adjustHeaderVisibility) ---
   The JS measures .inner-header against the summed widths of its children and
   hides them one by one — .header-contact, then .header_cta, then .header-menu —
   by adding .hidden. Two things below are load-bearing, not cosmetic:
   1. .hidden must actually hide, or the JS toggles a class that does nothing.
   2. Children must not wrap or shrink, or the measured width never exceeds the
      container and the squeeze never triggers at all. */
.hidden {
  display: none !important;
}

._header .inner-header {
  flex-wrap: nowrap;
}

/* Spacing between header blocks is margin, NOT flex gap, on purpose: the JS
   measures offsetWidth + marginLeft + marginRight and is blind to gap. With gap
   the header overflowed before the squeeze ever thought it was full. */
._header .inner-header > * {
  flex-shrink: 0;
  margin-left: 12px;
  margin-right: 12px;
}

._header .inner-header > *:first-child {
  margin-left: 0;
}

._header .inner-header > *:last-child {
  margin-right: 0;
}

/* Logo left, everything else (menu, CTA buttons, burger) grouped right.
   An auto margin rather than justify-content because the container has to stay
   space-between-neutral for the squeeze above: an auto margin absorbs exactly
   the free space, so getOuterWidth() sums to the container width while the
   header still fits, and collapses to 0 the moment it does not — at which point
   the sum becomes the true content width and the squeeze fires as intended. */
._header .inner-header > .header-menu {
  margin-left: auto;
}

._header ul.main-menu {
  flex-wrap: nowrap;
}

._header ul.main-menu li.menu-item .menu-item-link {
  white-space: nowrap;
}

/* --- Shell --- */
._header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 18px 0;
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.75) 0%,
    rgba(0, 0, 0, 0) 100%
  );
  transition: all 0.3s ease;
}

/* sticky state — main.js adds .collapsed past 100px of scroll */
._header.collapsed {
  padding: 10px 0;
  background: #382f2d;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}

._header .inner-header {
  align-items: center;
  justify-content: space-between;
  min-height: 70px;
}

/* --- Logo --- */
._header .logo-wrapper {
  display: flex;
  align-items: center;
}

._header .logo-wrapper a.logo {
  display: inline-flex;
  align-items: center;
  line-height: 1;
}

._header .logo-wrapper a.logo img {
  height: 56px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  object-position: left center;
  transition: all 0.3s ease;
}

._header .logo-wrapper a.sticky-logo {
  display: none;
}

._header.collapsed .logo-wrapper a.main-logo {
  display: none;
}

._header.collapsed .logo-wrapper a.sticky-logo {
  display: inline-flex;
}

._header.collapsed .logo-wrapper a.logo img {
  height: 44px;
}

/* --- Main menu --- */
._header ul.main-menu {
  display: flex;
  align-items: center;
  gap: 4px;
}

._header ul.main-menu li.menu-item .menu-item-link {
  display: block;
  padding: 10px 12px;
  transition: color 0.3s ease;
}

/* --- Phone block --- */
._header .phone-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

._header .calling-icon {
  display: flex;
  align-items: center;
  font-size: 1.25rem;
}

._header .contact-heading {
  display: block;
  text-transform: capitalize;
  line-height: 1.2;
}

._header .contact-number {
  margin: 0;
  font-weight: 600;
  line-height: 1.2;
  white-space: nowrap;
}

._header .divider {
  padding-left: 21px;
  opacity: 0.5;
}

._header .header-contact {
  display: none!important;
  align-items: center;
}

/* --- CTA buttons --- */
._header .header-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

._header .header-btn {
  padding: 10px 22px;
  white-space: nowrap;
}

/* --- Burger — always visible, last item on the right --- */
._header .hamburger-menu {
  display: flex;
  align-items: center;
}

._header .menu_trigger {
  position: relative;
  width: 35px;
  height: 24px;
  cursor: pointer;
}

/* bars take their colour from the text-color-* classes in the markup */
._header .menu_trigger span {
  position: absolute;
  right: 0;
  display: block;
  height: 3px;
  background-color: currentColor;
  transition: all 0.3s ease;
}

._header .menu_trigger span:nth-child(1) {
  top: 0;
  width: 35px;
}

._header .menu_trigger span:nth-child(2) {
  top: 50%;
  width: 25px;
  transform: translateY(-50%);
}

._header .menu_trigger span:nth-child(3) {
  bottom: 0;
  width: 35px;
}

._header .menu_trigger:hover span {
  width: 35px;
}

/* open state — main.js adds .menu_active */
._header .menu_trigger.menu_active span:nth-child(1) {
  top: 50%;
  width: 35px;
  transform: translateY(-50%) rotate(45deg);
}

._header .menu_trigger.menu_active span:nth-child(2) {
  opacity: 0;
}

._header .menu_trigger.menu_active span:nth-child(3) {
  bottom: auto;
  top: 50%;
  width: 35px;
  transform: translateY(-50%) rotate(-45deg);
}

/* ============================================================
   SECTION: HEADER — END
   ============================================================ */

/* ============================================================
   SECTION: MOBILE MENU PANEL — START
   ============================================================ */
/* =========================================================
   MOBILE MENU PANEL
   Layout, colours and responsive behaviour all come from
   assets/css/component-common.css — do not restate them here.
   Only the few hooks that file does not define live below.
   ========================================================= */

/* .bg-white is on the panel in the markup but is defined in neither
   component-common.css nor dynamic-styles.css (which has .bg-light). */
.mobile-menu-wrap.bg-white {
  background-color: #ffffff;
}

/* Submenus stay open by default (no accordion, no trigger arrow), which is
   also component-common.css's own default — its rule to hide a closed submenu
   is commented out there. Nothing to add here.

.mobile-menu-wrap ul.main-menu ul.sub-menu {
  display: none;
}
*/

/* component-common.css has no rule for the divider between the contact
   block and the CTA buttons. */
.menu-devider {
  height: 1px;
  margin: 25px 0;
  background: rgba(80, 44, 30, 0.2);
}


/* ============================================================
   SECTION: MOBILE MENU PANEL — END
