@charset "utf-8";

/* Mobile */
@media only screen and (min-width: 0px) {
    .header{
        position: sticky;
        top: 0;
        z-index: 1000;
        background-color: #273a62;
        display: flex;
        justify-content: center;
        align-items: center;
        height: 50px;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);       
    }
    .monolitus-scritta {
        background-image: url("../immagini/monolitus-scritta.svg");
        background-repeat: no-repeat;
        background-size: auto;
        height: 25px;
        width: 229px;
        opacity: 0;
        transition: opacity 0.7s linear;
    }
    .monolitus-scritta.visibile {
        opacity: 1;
    }
    .menu {
        max-height: 0;
        overflow: hidden;
        padding: 0;
        transition: max-height 0.4s ease, padding 0.3s ease;
    }
    .menu ul {
        list-style: none;
        display: flex;
        gap: 20px;
        text-transform: uppercase;
        font-size: 18px;
        padding-left: 20px;
        padding-right: 20px;
        flex-direction: column;
    }
    .menu a {
        color: #273a62;
        font-weight: 500;
    }
    .menu a:hover {
        text-decoration: underline;
    }

    #chk-menu-toggle:checked ~ .menu {
        max-height: 500px; /* abbastanza per il contenuto */
        padding: 10px 0;
    }
    .menu-toggle {
        display: block;
        font-size: 28px;
        background: none;
        border: none;
        color: black;
        cursor: pointer;
    }
    .icona-menu {
        position: relative;
        font-size: 32px;
        margin-top: 10px;
    }
    .icona-menu::after {
        content: "menu";
        display: inline-block;
        transition: transform 0.3s ease, opacity 0.3s ease;
        opacity: 1;
        transform: scale(1);
    }
    #chk-menu-toggle:checked + .menu-toggle .icona-menu::after {
        content: "close";
        transform: rotate(-180deg) scale(1.1);
        opacity: 1;
    }
}

/* Desktop */
@media only screen and (min-width: 769px) {
    .menu {
        display: block !important;
        margin-top: 40px;
        margin-bottom: 40px;
        max-height: unset;
    }
    .menu ul {
        flex-direction: row;
        justify-content: center;
        gap: 40px;
    }
    .menu-toggle {
        display: none;
    }
}