/* Menu Above Hero - Base styles shared across hamburger, horizontal, vertical */
/* Uses variables from assets/css/freelance-template/global.css */

/* Header overlay on hero */
.site-header.menu-above-hero {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 0;
}

/* Hide site branding on desktop overlay only */
@media (min-width: 1281px) {
  .site-header.menu-above-hero .site-branding {  }
}


.site-header.menu-above-hero .site-branding  h1 {
  font-family: var(--font-secondary);
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary-dark);
  text-decoration: none;
  line-height: 1.15;
  margin-top: 0;
  margin-bottom: 0;
  text-align: center;
}

.site-header.menu-above-hero .site-branding  h3 {
  font-family: var(--font-primary);
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  color: var(--color-primary-dark);
  text-decoration: none;
  line-height: 1.15;
  margin-top: 0;
  margin-bottom: 0;
  text-align: center;
}

.site-header.menu-above-hero .site-branding {
  position: fixed;
  top: var(--spacing-sm);
  /* Center over the right overlay toolbar column */
  left: calc(
    /* toolbar right edge */
    ((100vw - 95vw) / 2 + var(--spacing-xl))
    /* move to toolbar center: + half toolbar width (fab size + padding*2) */
    + ((var(--fab-size-desktop) + 2 * var(--spacing-sm)) / 2)
    /* back by half logo width to center the logo itself */
    - (var(--hero-logo-size-desktop) / 2)
    /* optional fine-tune */
    + var(--hero-logo-nudge-x, 0px)
  );
  margin-bottom: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;  /* stack caption under logo */
  align-items: center;      /* center logo + text */
}

.site-header.menu-above-hero .site-branding img{
  width: var(--hero-logo-size-desktop);
  height: auto;
}

.site-header.menu-above-hero .site-branding p{
  margin-top: 0;
}



/* Top bar: pinned at very top over the slider */
.site-header.menu-above-hero .top-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1001;
  background-color: transparent;
  color: var(--color-white);
  padding: var(--spacing-xs) 0;
}
.site-header.menu-above-hero .top-bar a { color: var(--color-white); }

/* Keep contact info and socials on one line */
.site-header.menu-above-hero .top-bar .top-bar-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-md);
  flex-wrap: nowrap; /* force single line */
}

.site-header.menu-above-hero .top-bar .contact-info-mini {
  display: flex;
  align-items: center;
  gap: var(--spacing-lg);
  flex-wrap: nowrap;
  flex: 1 1 auto;         /* allow it to shrink */
  min-width: 0;           /* enable ellipsis */
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis; /* truncate if too long */
}

.site-header.menu-above-hero .top-bar .top-social-links {
  display: inline-flex;
  align-items: center;
  gap: var(--spacing-sm);
  margin-left: auto; /* pin to right */
  flex: none;        /* don't shrink icons */
}

/* Main navigation container overlays the hero */
.site-header.menu-above-hero .main-navigation {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 1002;
  /* push below top bar (approx 40px) */
  top: calc(40px + var(--spacing-sm));
  padding: 0 var(--spacing-lg);
}

/* Primary menu list reset */
.site-header.menu-above-hero #primary-menu,
.site-header.menu-above-hero .menu { /* WP might output .menu class */
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-header.menu-above-hero #primary-menu li { margin: 0; }
.site-header.menu-above-hero #primary-menu a {
  color: var(--color-white);
}

@media (max-width: 1280px) {
  .site-header.menu-above-hero .main-navigation .nav-menu,
  .site-header.menu-above-hero .main-navigation #primary-menu { display: none !important; }
  .site-header.menu-above-hero #primary-menu a { color: var(--color-text); }
}

.site-header.menu-above-hero #primary-menu a {
  text-decoration: none;
  font-weight: var(--font-weight-medium);
}

/* Menu toggle (button) base aesthetics */
.site-header.menu-above-hero .menu-toggle {
  /*
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--spacing-sm);
  background: rgba(0, 0, 0, 0.35);
  color: var(--color-white);
  border: 0;
  border-radius: var(--radius-lg);
  padding: var(--spacing-sm) var(--spacing-md);
  cursor: pointer;
  transition: background var(--transition-fast);
*/}
.site-header.menu-above-hero .menu-toggle:hover { background: rgba(0, 0, 0, 0.5); }

/* Unify hamburger icon with default header */
.site-header.menu-above-hero .menu-toggle .hamburger {
  display: inline-flex;
  flex-direction: column;
  gap: var(--spacing-xs);
}
.site-header.menu-above-hero .menu-toggle .hamburger .bar {
  width: 24px;
  height: 3px;
  background: currentColor;
  border-radius: var(--radius-full);
  transition: all var(--transition-normal);
}

@media (max-width: 1280px) {
  .site-header.menu-above-hero .menu-toggle {
    position: fixed;
    top: 12px;
    right: 12px;
    width: 56px;
    height: 56px;
    padding: 14px;
    border-radius: var(--radius-full);
    background: rgba(var(--color-primary-rgb), 1);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 16px rgba(0,0,0,0.25);
    z-index: 1600;
    border: 0;
  }
  .site-header.menu-above-hero .menu-toggle .hamburger .bar {
    width: 28px;
    height: 3px;
    background: #fff;
  }
}

/* Turn hamburger into a cross when open */
.site-header.menu-above-hero .menu-toggle[aria-expanded="true"] .hamburger .bar:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}
.site-header.menu-above-hero .menu-toggle[aria-expanded="true"] .hamburger .bar:nth-child(2) {
  opacity: 0;
}
.site-header.menu-above-hero .menu-toggle[aria-expanded="true"] .hamburger .bar:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}
