header {
    background-color: #222;
}

header .center {
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
}

.logo {
    width: var(--logo);
}

nav ul {
    display: flex;
}

nav a {
    display: block;
    color: #fff;
    font-size: 17px;
    padding: 20px 15px;
    position: relative;
}

nav a::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    background-color: #000;
    width: 100%;
    height: 0;
}

nav a:hover {
    background-color: #4f4f4f;
    color: #ccc;
}

nav a:hover::before {
    height: 8px;
    transition: .3s;
}

.searchBar {
    width: var(--searchBar);
    display: flex;
}

#search {
    width: calc(var(--searchBar) - var(--button));
    height: var(--button);
    background-color: transparent;
    color: #fff;
    font-size: 14px;
    border-bottom: 2px solid #fff;
}

#search::placeholder {
    color: #ddd;
}

#go {
    width: var(--button);
    height: var(--button);
    border-bottom: 2px solid #fff;
}

#go img {
    transform: scale(.85);
}

.PEBtn {
    width: var(--button);
    height: var(--button);
    display: none;
}


@media screen and (max-width:769px) {
    header .center {
        justify-content: space-around;
        z-index: 99;
        height: 20px;
    }

    .PEBtn {
        display: block;
    }
    .logo img{
        height: 20px;
        object-fit: contain;
    }
    nav,
    .searchBar {
        width: 100%;
        height: 100vh;
        transition: .3s;
        transform: translateX(-100%);
        position: absolute;
        top: 0;
        left: 0;
        padding: 60px 5px 0;
        background-color: #222;
    }

    nav ul {
        flex-direction: column;
    }
    .PEBtn img{
        height: 20px;
        object-fit: contain;
    }
    .offBtn {
        position: absolute;
        top: 5px;
        right: 5px;
    }

    .open_state {
        transform: translateX(0);
    }
}