﻿
:root {
    /*--navy: #150e6e;*/ /* Variable for main color */
    /*--blue: #47b9de;*/ /* Variable for main color */
    --red: #d10d17;
    --navy: #2076ff; /* Variable for main color */
    --pblue: #000066;
    --blue: #17b9df; /* Variable for main color */
}


mobile-nav {
    z-index: 5;
}

/*------------Desktop Nav-----------*/


/* Mobile Nav */


/* Burger button styles */
.burger-btn {
    width: 30px;
    height: 22px;
    position: fixed;
    right: 20px;
    top: 20px;
    cursor: pointer;
    border: none;
    background: none;
    padding: 0;
    z-index: 10010;
    -webkit-transition: 0.5s all ease-out;
    -moz-transition: 0.5s all ease-out;
    -o-transition: 0.5s all ease-out;
}
    .burger-btn.active {
        width: 30px;
        height: 22px;
        position: fixed;
        right: 20px;
        top: 10px;
        cursor: pointer;
        border: none;
        background: none;
        padding: 0;
        z-index: 10010;
        -webkit-transition: 0.5s all ease-out;
        -moz-transition: 0.5s all ease-out;
        -o-transition: 0.5s all ease-out;
    }

    .burger-btn .bar {
        display: block;
        width: 100%;
        height: 4px;
        background-color: var(--navy);
        border-radius: 2px;
        position: absolute;
        left: 0;
        transition: all 0.3s ease;
    }

    /* Hover color */
    .burger-btn:hover .bar {
        background-color: var(--blue);
    }

.bar1 {
    top: 0;
}

.bar2 {
    top: 9px;
}

.bar3 {
    bottom: 0;
}

/* When open, transform bars into an X */
.burger-btn.open .bar1 {
    transform: rotate(45deg);
    top: 9px;
}

.burger-btn.open .bar2 {
    opacity: 0;
}

.burger-btn.open .bar3 {
    transform: rotate(-45deg);
    bottom: 9px;
}


/* Overlay */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 10000;
}

    .overlay.active {
        opacity: 1;
        pointer-events: auto;
    }

/* Mobile menu container */
.mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    padding-top:20px;
    height: 100%;
    width: 100vw;
    max-width: 400px;
    background: white;
    box-shadow: -2px 0 8px rgba(0,0,0,0.2);
    overflow: hidden;
    z-index: 10005;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    display: flex;
}

    .mobile-menu.active {
        transform: translateX(0);
    }

   /* .mobile-menu a, .mobile-menu a:link, .mobile-menu a:visited {
        color: var(--navy);
        font-family: "Ubuntu", sans-serif;
        font-weight:400;
        
    }*/
/* Each menu level (screen) */
.menu-level {
    min-width: 100%;
    padding: 1em;
    overflow-y: auto;
    transition: transform 0.3s ease;
    position: absolute;
    top: 0;
    bottom: 0;
    background: white;
    left: 0;
    transform: translateX(100%);
    /* Hide offscreen by default */
    visibility: hidden;
}

    .menu-level.active {
        transform: translateX(0);
        visibility: visible;
        position: relative;
    }

    /* When going forward, slide left */
    .menu-level.slide-in {
        animation: slideIn 0.3s forwards;
    }

    /* When going back, slide right */
    .menu-level.slide-out {
        animation: slideOut 0.3s forwards;
    }

@keyframes slideIn {
    from {
        transform: translateX(100%);
        visibility: visible;
    }

    to {
        transform: translateX(0);
    }
}

@keyframes slideOut {
    from {
        transform: translateX(0);
    }

    to {
        transform: translateX(100%);
        visibility: hidden;
    }
}

/* Back button */
.back-btn {
    background: none;
    border: none;
    font-size: 1.1em;
    cursor: pointer;
    margin-bottom: 1em;
    color: var(--navy);
    position: fixed;
    left: 10px;
    top: 0px;
    transition: color 0.3s ease;
}

    .back-btn:hover {
        color: var(--blue);
    }

        /* Arrow animation only */
        .back-btn:hover .back-arrow {
            animation: arrowWiggleLeft 1s ease infinite;
            display: inline-block; /* Needed to animate properly */
        }
@keyframes arrowWiggleLeft {
    0% {
        transform: translateX(0);
    }

    50% {
        transform: translateX(-5px);
    }
    /* Wiggle left for back arrow */
    100% {
        transform: translateX(0);
    }
}



/* Lists */
.menu-level ul {
    list-style: none;
    padding: 0;
    margin: 40px 0 0 0;
}

.menu-level li {
    display: flex; /* Make children (e.g. link and button) line up horizontally */
    align-items: center; /* Vertically center content */
    justify-content: space-between; /* Push button to the right */
    /*margin-bottom: 0.5em;*/
    border-bottom: solid 1px var(--navy);
    text-align: left;
    padding: 0.5em ;
    min-height:50px;
}

    /* Hover effect on the entire li */
    .menu-level li:hover {
        background-color: var(--navy);
    }

        /* Change link and button text to white when li is hovered */
        .menu-level li:hover a,
        .menu-level li:hover .submenu-btn {
            color: white;
        }

.menu-level li,
.menu-level a,
.menu-level .submenu-btn {
    transition: background-color 0.3s ease, color 0.3s ease;
}


.menu-level a {
    color: var(--navy);
    font-family: 'cardo-bold';
    /*text-transform:uppercase;*/
    font-weight: 500;
    text-decoration: none;
    flex: 1; /* Allow the link to take up available space */
}

/* Submenu buttons */
.submenu-btn {
    background: none;
    border: none;
    font-size: 1.2em;
    cursor: pointer;
    color: var(--navy);
    font-weight: bold;
    padding-left: 1em;
    display: inline-block; /* So transform affects it properly */
    transition: color 0.3s ease;
}


.menu-level li:hover .submenu-btn {
    animation: arrowWiggle 1s ease infinite;
}

@keyframes arrowWiggle {
    0% {
        transform: translateX(0);
    }

    50% {
        transform: translateX(10px);
    }

    100% {
        transform: translateX(0);
    }
}



