.preheader {
    background: var(--color-primary);
}

.preheader .topline-message {
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
}

.topline-message p {
    margin: 0;
    color: white;
}

header {
    background: white;
    padding: 40px 0 15px 0;
    border-bottom: 3px solid var(--color-secondary);
    position: relative;
}

.header-innerwidth,
header > .innerwidth {
    position: relative;
}

header #block-base_theme-site-branding {
    width: 280px;
    height: 65px;
}

header .prefix-label {
    text-transform: uppercase;
    letter-spacing: 0.4px;
    font-size: 14px;
    color: #767676;
}

a.mobile-search {
    display: none;
}

/* @media (max-width: 880px) { */
@media (max-width: 880px) {
    header {
        position: fixed;
        z-index: 998;
        top: 0;
        left: 0;
        width: 100%;
        height: 93px;
        box-sizing: border-box;
        transition: 0.5s;
    }

    header img {
        transition: 0.5s;
    }

    body.scroll-down header {
        top: -93px;
    }

    body.scroll-up header {
        top: 0px;
    }

    a.mobile-search {
        display: block;
        position: absolute;
        top: -2px;
        right: 53px;
        width: 28px;
        height: 28px;
    }

}



/* Hamburger Logik */

.fh-menu-toggle,
.fh-hamburger {
  display: none;
}

/* @media (max-width: 768px) { */
@media (max-width: 880px) {

  .fh-menu-toggle {
    position: absolute;
    opacity: 0;
    pointer-events: none;
  }

  .fh-hamburger {
    color: black;
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    width: 40px;
    height: 40px;
    cursor: pointer;
    z-index: 30;
    position: absolute;
    top: -7px;
    right: -6px;
  }

  .fh-hamburger__bar {
    width: 28px;
    height: 2px;
    background: currentColor;
    border-radius: 10px;
    transition: transform 0.2s ease, opacity 0.2s ease;
  }

  /* Wrapper komplett ausblenden */
  .menues-wrapper {
    display: none;
    position: absolute;
    top: 100%;
    left: -10px;
    width: calc(100% + 20px);
    background: #fff;
    box-shadow: 0 20px 30px rgba(0, 0, 0, 0.1);
    border-radius: 0 0 12px 12px;
    z-index: 20;
    animation: fadeDown 0.2s ease forwards;
  }

  /* Bei aktivem Toggle sichtbar */
  .fh-menu-toggle:checked ~ .menues-wrapper {
    display: block;
  }

  /* Hamburger zu X */
  .fh-menu-toggle:checked + .fh-hamburger .fh-hamburger__bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .fh-menu-toggle:checked + .fh-hamburger .fh-hamburger__bar:nth-child(2) {
    opacity: 0;
  }
  .fh-menu-toggle:checked + .fh-hamburger .fh-hamburger__bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  /* Optional: Klick außerhalb schließt Menü (nur visuell, kein echtes Close) */
  .menues-wrapper::before {
    content: "";
    position: fixed;
    inset: 0;
    background: transparent;
    z-index: -1;
  }

  @keyframes fadeDown {
    from { opacity: 0; transform: translateY(-5px); }
    to { opacity: 1; transform: translateY(0); }
  }
}
