@import url('https://fonts.googleapis.com/css2?family=Schibsted+Grotesk:ital,wght@0,400..900;1,400..900&display=swap');

header .cabecalho {
    background-image: linear-gradient(#2f2f2f94, rgb(0 0 0)), url(../../img/header.jpg);
    background-size: cover;
    background-position: center;
    background-attachment: fixed;

    color: white;
    font-size: 48px;

    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-end;
    gap: 50px;

    width: 100%;
    height: 420px;
}

.cabecalho h1 {
    font-family: "Schibsted Grotesk", sans-serif;
    font-weight: bold;
    margin: 0;
    font-size: 3rem;
}

.cabecalho h2 {
    font-family: "Schibsted Grotesk", sans-serif;
    font-weight: lighter;
    margin: 0;
}

.cabecalho .logo-prefeitura {
    width: 200px;
}

.navegacao {
    display: flex;
    justify-content: center;

    font-size: 1.3rem;

    width: 100%;
    padding-bottom: 10px;

    .botao-navegacao {
        display: none;
    }

    ul {
        display: flex;
        gap: 65px;
        list-style: none;

        margin: 0;
        padding: 0;

        li {
            transition: var(--delay-default);

            a {
                position: relative;
                top: 0;
                line-height: 35px;

                display: grid;
                align-items: center;
                color: #d2d2d2;
                text-decoration: none;

                height: 100%;

                transition: var(--delay-default);

                &::after {
                    content: '';
                    position: absolute;
                    left: 0;
                    bottom: 0;
                    width: 0%;
                    height: 2px;
                    background-color: #65A138;
                    transition: var(--delay-default);
                }

                &:hover {
                    top: -5px;

                    &::after {
                        width: 100%;
                    }
                }

            }
        }

        li:nth-child(even) a::after {
            background-color: #EB4142;
        }
    }
}

@media (max-width: 768px) {
    header .cabecalho {
        gap: 30px;
    }

    .cabecalho h1 {
        padding-inline: 38px;
        padding-block: 5px;
        font-size: 1.8rem;
    }

    .cabecalho h2 {
        display: none;
    }

    .navegacao {
        width: 68%;
        max-width: 260px;

        z-index: 3;

        overflow: hidden;

        .botao-navegacao {
            display: unset;
            color: #ffffff;

            border: none;
            border-radius: 15px;

            font-size: 1rem;
            background-color: #33333385;
            backdrop-filter: blur(2px);
            width: 100%;
            height: 50px;
        }

        .links-de-navegacao {
            display: none;
            position: relative;

            &.show,
            &.hide {
                display: flex;
                align-items: center;
                flex-direction: column;
                gap: 5px;
                margin-top: 70px;

                position: absolute;

                background-color: #414141f0;
                backdrop-filter: blur(2px);

                width: 68%;
                max-width: 260px;

                border-radius: 15px;

                li {
                    text-align: center;
                    padding-block: 10px;

                    a {
                        width: 100%;
                        height: 100%;
                        padding-inline: 0;
                    }
                }
            }

            &.show {
                animation: showing-navigation var(--delay-default) forwards;
            }

            &.hide {
                animation: hidden-navigation var(--delay-default) forwards;
            }
        }
    }
}

@keyframes showing-navigation {
    0% {
        opacity: 0;
        transform: translateY(-20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes hidden-navigation {
    0% {
        opacity: 1;
        transform: translateY(0);
    }

    99% {
        opacity: 0;
        transform: translateY(-20px);
    }

    100% {
        display: none;
    }
}