/*
==========
= HEADER =
==========
 */

/*Header stuff (Navigation, Logo etc.)*/

header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    background-color: #fff;
    min-height: 81px;
    border-bottom: 3px solid transparent;
    transition: all 0.2s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
@media screen and (min-width: 768px) {
    header {
        padding-top: 30px;
        padding-bottom: 30px;
        min-height: 128px;
        border-bottom: 6px solid transparent;
    }
}
.scrolled_a_bit header {
    border-color: var(--black);
}
.nav-up {
    top: -200px;
}
.nav_is_open .nav-up {
    top: 0;
}
header > .frame {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    display: block;
    text-decoration: none;
    width: 56px;
    height: 56px;
    z-index: 10;
}
@media screen and (min-width: 768px) {
    .logo {
        width: 69px;
        height: 69px;
    }
}
/*Main-Nav*/

.main-nav-container {
    height: 0;
    z-index: 9;
    visibility: hidden;
    opacity: 0;
    overflow: hidden;
    background-color: #fff;
    transition: opacity 0.25s ease-in-out;
}

.nav_is_open .main-nav-container {
    position: fixed;
    visibility: visible;
    height: 100vh;
    height: 100dvh;
    opacity: 1;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
}

.main-nav-container > .main-nav {
    padding: 0;
    position: relative;
    top: 78px;
}
@media screen and (min-width: 768px) {
    .main-nav-container > .main-nav {
        top: 129px;
    }
}
.main-nav-container > .main-nav > ul {
    border-top: 3px solid var(--black);
    width: 100%;
    right: 0;
    position: absolute;
}
@media screen and (min-width: 768px) {
    .main-nav-container > .main-nav > ul {
        border-top: 6px solid var(--black);
    }
}
.main-nav li {
    list-style: none;
    text-align: right;
    border-bottom: 3px solid var(--black);
}
.main-nav-ul > li {
    display: flex;
    justify-content: flex-end;
}
.main-nav-ul > li > a {
    opacity: 1;
    transition: opacity 0.3s;
    max-width: 500px;
}
/* .main-nav-ul:has(> li.current-menu-ancestor) > li:not(.current-menu-ancestor) > a,
.main-nav-ul:has(> li.current-menu-item) > li:not(.current-menu-item) > a {
    opacity: 0.5;
} */
.main-nav a {
    font-family: var(--sans);
    font-weight: 900;
    font-size: 22px;
    line-height: 26px;
    letter-spacing: 0.03em;
    display: inline-block;
    text-align: center;
    padding-top: 0;
    padding-bottom: 0;
    padding-right: 21px;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
    width: 100%;
    text-align: right;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    min-height: 74px;
    line-height: 1;
}
@media screen and (min-width: 768px) {
    .main-nav a {
        padding-right: 41px;
    }
}
@media (hover: hover) {
    .main-nav a:hover {
        color: var(--accent);
    }
}
.main-nav .current-menu-ancestor > a,
.main-nav .current-menu-item > a {
    background-color: var(--black);
    color: var(--white);
}

.sub-menu {
    width: 50%;
    position: absolute;
    top: 6px;
    text-align: left;
    opacity: 0;
    pointer-events: none;
    left: 0;
    width: 50%;
    top: 0;
}
.main-nav .current-menu-ancestor .sub-menu,
.main-nav .current-menu-item .sub-menu {
    opacity: 1;
    pointer-events: all;
    background-color: var(--white);
    z-index: 2;
}
.sub-menu a {
    display: block;
    width: 100%;
    text-align: left;
    display: flex;
    justify-content: flex-start;
    align-items: center;
    padding-left: 24px;
    min-height: 74px;
}
@media screen and (min-width: 768px) {
    .sub-menu a {
        padding-left: 41px;
    }
}
.sub-menu li {
    position: relative;
}
.sub-menu li:after {
    content: "";
    display: block;
    position: absolute;
    bottom: -3px;
    left: 100%;
    width: 100%;
    height: 3px;
    background-color: var(--black);
    pointer-events: none;
}
/* Animate Menu Button */

.top-wave,
.bottom-wave {
    transition: transform 0.2s ease, opacity 0.2s ease;
    transform: translateX(0);
    opacity: 1;
}

/* Wenn Navigation aktiv ist */
body.nav_is_open .top-wave {
    transform: translateX(-20px);
    opacity: 0;
}

body.nav_is_open .bottom-wave {
    transform: translateX(20px);
    opacity: 0;
}

.menu-btn {
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    width: 48px;
    height: 56px;
    border: none;
    background-color: transparent !important;
    outline: none;
}

@media screen and (min-width: 768px) {
    .menu-btn {
        width: 65px;
        height: 69px;
    }
}
