/* Header styles for Breneker Home Care */

.bhc-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--color-surface);
  box-shadow: var(--shadow-sm);
}

.bhc-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: var(--space-3);
  gap: var(--space-4);
}

.bhc-header__brand {
  display: flex;
  align-items: center;
}

.bhc-header__logo-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  color: inherit;
}

.bhc-header__logo-mark {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--color-primary-soft);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
}

.bhc-header__logo-mark i {
  font-size: 1.1rem;
}

.bhc-header__logo-text {
  display: flex;
  flex-direction: column;
}

.bhc-header__logo-name {
  font-size: var(--fs-lg);
  font-weight: 600;
  line-height: 1.2;
}

.bhc-header__logo-tagline {
  font-size: var(--fs-xs);
  color: var(--color-text-muted);
}

/* Navigation */

.bhc-header__nav {
  display: flex;
  align-items: center;
}

.bhc-header__nav-list {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}

.bhc-header__nav-link {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--gray-700);
  padding-inline: 0.25rem;
  padding-block: 0.2rem;
  border-radius: var(--radius-full);
}

.bhc-header__nav-link:hover,
.bhc-header__nav-link:focus-visible {
  color: var(--color-primary);
  /*background-color: var(--color-primary-soft);*/
}

.bhc-header__nav-item--cta .bhc-header__nav-link--cta {
  font-size: var(--fs-sm);
  padding-inline: 1.1rem;
  padding-block: 0.5rem;
  color: white !important;
}

/* Mobile toggle */

.bhc-header__toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  border: 1px solid var(--gray-200);
  background-color: var(--color-surface);
  color: var(--gray-800);
}

.bhc-header__toggle:hover {
  background-color: var(--gray-100);
}

.bhc-header__toggle:focus-visible {
  outline: 2px solid var(--color-primary);
  outline-offset: 2px;
}

.bhc-header__toggle-bar {
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background-color: currentColor;
  transition: transform var(--transition-normal), opacity var(--transition-normal);
}

/* Mobile nav default (no-JS friendly): show nav, hide toggle on larger screens */

@media (max-width: 767px) {
  .bhc-header__nav {
    position: absolute;
    inset-inline: 0;
    top: 100%;
    background-color: var(--color-surface);
    box-shadow: var(--shadow-md);
    border-top: 1px solid var(--gray-100);
    transform-origin: top;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transition: max-height var(--transition-slow), opacity var(--transition-normal), visibility var(--transition-normal);
  }

  .bhc-header__nav-list {
    flex-direction: column;
    align-items: stretch;
    padding: var(--space-3) var(--space-4) var(--space-4);
  }

  .bhc-header__nav-item--cta {
    margin-top: var(--space-2);
  }

  .bhc-header__nav-link {
    display: block;
    padding-block: 0.5rem;
  }

  .bhc-header__toggle {
    display: inline-flex;
  }

  /* When JS adds open class */
  .bhc-header--nav-open .bhc-header__nav {
    max-height: 340px;
    opacity: 1;
    visibility: visible;
    padding: 10px 20px;
  }

  .bhc-header--nav-open .bhc-header__toggle-bar:nth-child(1) {
    transform: translateY(6px) rotate(45deg);
  }

  .bhc-header--nav-open .bhc-header__toggle-bar:nth-child(2) {
    opacity: 0;
  }

  .bhc-header--nav-open .bhc-header__toggle-bar:nth-child(3) {
    transform: translateY(-6px) rotate(-45deg);
  }
}

@media (min-width: 768px) {
  .bhc-header__toggle {
    display: none;
  }
}
