/**
 * Header customization for Olivero sub-theme.
 * Targeted at mobile behavior below the 75rem (1200px) breakpoint.
 */

@media (max-width: 74.9375rem) {
  /* 1. Sticky Behavior & Layout Root */
  .site-header {
    position: sticky;
    top: 0;
    z-index: 501;
    background-color: var(--color--white);
  }

  .site-header__fixable {
    position: relative;
    width: 100%;
  }

  /* 2. Background Unification (Gradient) */
  .site-header__inner {
    background-image: linear-gradient(
      160deg,
      var(--color--primary-50) 0%,
      var(--color--primary-40) 78.66%
    );
  }

  .site-header__inner__container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-block: var(--sp0-5);
  }

  /* 3. Branding & Typography */
  .site-branding {
    background: transparent;
  }

  .site-branding__text {
    display: flex;
    flex-direction: column;
    justify-content: center;
    line-height: 1.2;
  }

  .site-branding__name,
  .site-branding__slogan {
    margin: 0;
    white-space: nowrap;
    color: var(--color--white);
  }

  .site-branding__name a {
    color: var(--color--white);
    text-decoration: none;
  }

  /* 4. Responsive Font Scaling */
  .site-branding__name {
    font-size: 1.25rem;
  }

  .site-branding__slogan {
    font-size: 0.85rem;
  }

  @media (max-width: 37.5rem) {
    .site-branding__name {
      font-size: 1.1rem;
    }
    .site-branding__slogan {
      font-size: 0.75rem;
    }
  }

  @media (max-width: 25rem) {
    .site-branding__name {
      font-size: 0.95rem;
    }
    .site-branding__slogan {
      font-size: 0.7rem;
    }
  }

  /* 5. Mobile Navigation Button (Burger Menu) */
  .mobile-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding-inline-start: 2px;
    padding-inline-end: 12px;
  }

  /* Reset the button itself: remove white background and blue borders */
  .mobile-nav-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: auto;
    min-height: 44px;
    margin: 0;
    background-color: transparent !important; /* Force transparent */
    border: none !important; /* Remove the blue 3px border-top seen in devtools */
    box-shadow: none;
  }

/* 6. Burger Icon & Label Styling */

  /* Hide the "Menü" text label globally on mobile */
  .mobile-nav-button__label {
    display: none !important;
  }

  /* Closed State: White lines */
  .mobile-nav-button[aria-expanded="false"] .mobile-nav-button__icon,
  .mobile-nav-button[aria-expanded="false"] .mobile-nav-button__icon::before,
  .mobile-nav-button[aria-expanded="false"] .mobile-nav-button__icon::after {
    background-color: var(--color--white) !important;
    border-color: transparent !important;
  }

  /* Open State: Blue 'X' only */
  /* 1. Hide the middle horizontal bar */
  .mobile-nav-button[aria-expanded="true"] .mobile-nav-button__icon {
    background-color: transparent !important;
    border-color: transparent !important;
  }

  /* 2. Color the 'X' lines (top and bottom bars) blue */
  .mobile-nav-button[aria-expanded="true"] .mobile-nav-button__icon::before,
  .mobile-nav-button[aria-expanded="true"] .mobile-nav-button__icon::after {
    background-color: var(--color--primary-40) !important;
    border-color: transparent !important;
  }
