/* =============================================
   ZWEISTUFIGER HEADER
   ① Topbar  ② Hauptnavigation  ③ Offcanvas
   ============================================= */

/* Sticky-Verhalten: gesamter Header bleibt oben */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
    /* Kein Gap zwischen Topbar und Hauptnav */
    line-height: 0;
}

.site-header>* {
    line-height: 1.5;
}

/* ① Obere dunkle Leiste */
.header-topbar {
    background-color: #2a2b2d;
    padding: 0.6rem 0;
    font-size: 0.8rem;
    line-height: 1;
}

.header-topbar__link {
    color: #e8e8e8;
    text-decoration: none;
    transition: color 0.15s;
}

.header-topbar__link:hover {
    color: #ffffff;
}

.header-topbar__lang-active {
    color: #4ecfb5;
    font-weight: 700;
}

.header-topbar__divider {
    color: #888;
}

/* ② Hauptnavigation */
.header-main {
    background-color: #fff;
    padding-top: 0;
    padding-bottom: 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.07);
}

.header-main__brand {
    margin: 0;
    padding: 0;
    line-height: 0;
    /* verhindert Lücke zwischen Topbar und Logo */
}

.header-main__logo {
    height: 74px;
    width: auto;
    display: block;
}

.header-main__link {
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #2f343a !important;
    padding: 1.6rem 0.85rem !important;
    position: relative;
    transition: color 0.15s;
}

/* Grüner Unterstrich-Hover-Effekt */
.header-main__link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0.85rem;
    right: 0.85rem;
    height: 2px;
    background-color: #23947f;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.2s ease;
}

.header-main__link:hover,
.header-main__link:focus {
    color: #23947f !important;
}

.header-main__link:hover::after,
.header-main__link:focus::after,
.header-main__link.active::after {
    transform: scaleX(1);
}

.header-main__link.active {
    color: #23947f !important;
}

/* Dropdown-Pfeil ausblenden, eigene Behandlung */
.header-main .dropdown-toggle::after {
    margin-left: 0.3em;
    vertical-align: 0.15em;
}

/* CTA Button */
.header-main__cta {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.5rem 1.25rem;
    white-space: nowrap;
}

/* Dropdown Menü */
.header-dropdown {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-top: 2px solid #23947f;
    border-radius: 0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    padding: 0.5rem 0;
    min-width: 240px;
    animation: dropdownFadeIn 0.15s ease;
}

@keyframes dropdownFadeIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.header-dropdown__item {
    font-size: 0.875rem;
    font-weight: 400;
    color: #2f343a;
    padding: 0.6rem 1.25rem;
    transition: background-color 0.12s, color 0.12s;
}

.header-dropdown__item:hover,
.header-dropdown__item:focus {
    background-color: rgba(35, 148, 127, 0.08);
    color: #23947f;
}

/* ③ Offcanvas (Mobile) */
.header-offcanvas {
    width: 300px;
    background-color: #fff;
}

.header-offcanvas .offcanvas-header {
    background-color: #2a2b2d;
    padding: 1rem 1.25rem;
}

.header-offcanvas .offcanvas-header .btn-close {
    filter: invert(1) grayscale(1) brightness(2);
}

.header-offcanvas__link {
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #2f343a;
    padding: 0.85rem 0.5rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.07);
    cursor: pointer;
}

.header-offcanvas__link:hover {
    color: #23947f;
}

.header-offcanvas__sublink {
    display: block;
    font-size: 0.875rem;
    color: #555;
    text-decoration: none;
    padding: 0.45rem 0.5rem;
    transition: color 0.12s;
}

.header-offcanvas__sublink:hover {
    color: #23947f;
}

.header-offcanvas__contact a {
    font-size: 0.875rem;
    color: #555;
    text-decoration: none;
}

.header-offcanvas__contact a:hover {
    color: #23947f;
}
