#toggle {
    -webkit-appearance: none;
}

.hrzButton > .button {
    position: fixed;
    z-index: 999;
    width: 96%;
    height: 33px;
    background: transparent; color:#fff !important;
    /* border-radius: 15px; */
    cursor: pointer;
    display: flex;
    justify-content: left;
    align-items: center;
    padding: 0 4px;
    overflow: hidden;
    transition: width 0.3s ease-in-out;
    /*border: 1px solid #222;*/
    bottom: 4px;
    left: 9px;
}

    

.hrzMenu .nav {
    opacity: 1;
    transition: all 0.5s ease-in-out;
    background: transparent;
    width: 100%;
    border-radius: 5px;
    transform: translateX(10%);
    padding: 10px;
    margin-left:-20px;
}

    .hrzMenu .nav ul {
        margin: 0;
        padding: 0;
        display: flex;
        flex-direction: row;
        justify-content: center;
        align-items: center;
    }

    .hrzMenu .nav li {
        opacity: 0;
        list-style: none;
    }

        .hrzMenu .nav li:nth-child(1) {
            transform-origin: bottom;
            animation: itop 300ms 300ms linear forwards;
        }

        .hrzMenu .nav li:nth-child(2) {
            transform-origin: bottom;
            animation: itop 300ms 400ms linear forwards;
        }

        .hrzMenu .nav li:nth-child(3) {
            transform-origin: bottom;
            animation: itop 300ms 500ms linear forwards;
        }

        .hrzMenu .nav li:nth-child(4) {
            transform-origin: bottom;
            animation: itop 300ms 600ms linear forwards;
        }
        .hrzMenu .nav li:nth-child(5) {
            transform-origin: bottom;
            animation: itop 300ms 600ms linear forwards;
        }

    .hrzMenu .nav a {
        transition: all 0.5s linear;
        text-decoration: none;
        color: #31859a;
        font-size: 20px;
        width: 45px;
        height: 26px;
        display: flex;
        align-items: center;
        justify-content: center;
        margin: 0 20px 0 0;
        border-radius: 15px;
    }

        .hrzMenu .nav a:hover {
            color: #fff;
            background: #1c1c1c;
            border-radius: 15px;
        }

#toggle:checked ~ label .nav {
    display: none;
    opacity: 0;
    transform: translateX(0);
}

#toggle:checked ~ .button:before {
    transform: rotate(90deg);
}

#toggle:checked ~ .button {
    width: 34px;
    transition: all 0.1s linear;
}

.hrzButton .hzlines {
    display: block;
    height: 21px;
    width: 22px;
    position: absolute;
    top: 6px;
    left: 2px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

    .hrzButton .hzlines .line {
        display: block;
        height: 3px;
        width: 100%;
        border-radius: 10px;
        background: #fff;
    }

    .hrzButton .hzlines .line1 {
        transform-origin: 0% 0%;
        transition: transform 0.4s ease-in-out;
    }

    .hrzButton .hzlines .line2 {
        transition: transform 0.2s ease-in-out;
    }

    .hrzButton .hzlines .line3 {
        transform-origin: 0% 100%;
        transition: transform 0.4s ease-in-out;
    }


#toggle:checked ~ .hrzMenu .hzlines .line1 {
    transform: rotate(0deg); /* Reset to initial state */
}

#toggle:checked ~ .hrzMenu .hzlines .line2 {
    transform: scaleY(1); /* Reset scale to normal */
}

#toggle:checked ~ .hrzMenu .hzlines .line3 {
    transform: rotate(0deg); /* Reset to initial state */
}


#toggle:not(:checked) ~ .hrzMenu .hzlines .line1 {
    transform: rotate(60deg);
}

#toggle:not(:checked) ~ .hrzMenu .hzlines .line2 {
    transform: scaleY(0);
}

#toggle:not(:checked) ~ .hrzMenu .hzlines {
    color: #f00 !important;
}

#toggle:not(:checked) ~ .hrzMenu .hzlines .line3 {
    transform: rotate(-60deg);
    color:#f00 !important;
}










@keyframes itop {
    0% {
        opacity: 0;
        transform: translateY(60px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Submenu Styling */
    .submenu {
    position: fixed;
    top: 0;
    left: -100%;
    width: 97%;
    height: 89vh;
    margin-top: 9vh;
    background-color: #333;
    color: white;
    transition: left 0.7s ease;
    padding: 20px;
    z-index: 1000;
    border-radius: 0px 10px 10px 0px;
}

    .submenu.open {
        left: 0;
    }

    .submenu .close-btn {
        color: #fff;
        background-color: #222;
        border: none;
        font-size: 20px;
        padding: 10px;
        border-radius: 5px;
        cursor: pointer;
        position: absolute;
        top: 10px;
        right: 10px;
    }

    .submenu a {
        display: block;
        color: #eeff00;
        font-size: 20px;
        margin-bottom: 10px;
        text-decoration: none;
    }

        .submenu a:hover {
            background-color: #444;
            padding: 5px;
        }



.menubutton {
    position: fixed;
    right: 0px;
    bottom: 80px;
    z-index: 99;
}

.submenu {
    display: none;
    position: absolute;
    background: #fff;
    padding: 10px;
    border: 1px solid #ccc;
}

    .submenu.show {
        display: block;
    }

    .submenu.hide {
        display: none;
    }

.close-btn {
    background: red;
    color: white;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
}
