#menuPillContainer {
    position: fixed;
    z-index: 3;
    height: 100%;
    /* padding-left: 1rem; */
}

#menuPill {
    z-index: 3;
    margin-left: 1rem;
}

#menuPill .nav-link {
    /* override bootstrap colors */
    --bs-navbar-active-color: var(--ts-theme-400);
    --bs-navbar-hover-color: var(--ts-theme-200);
    --bs-nav-link-hover-color: var(--ts-theme-200);
    display: flex;
    align-items: center;
    padding: 0;
    max-width: 36px;
    transition: max-width 0.25s ease-in-out;
}

#menuPill .icon-container {
    padding: 0.5rem;
    background-color: rgba(0,0,0,0.7);
}

#menuPill .menu-label {
    max-width: 0%;
    white-space: nowrap;
    overflow: hidden;
}

@media (min-width: 768px) {

    .nav-tooltip {
        display: none;
    }

    main > section:not(#home) {
        padding-left: 180px;
        padding-right: 180px;
    }

    /* round the pill edges */
    #menuPill>.nav-item:nth-child(1) .icon-container {
        border-radius: 50% 50% 0 0;
        /* transition duration and delay */
        transition: border-radius 0.1s ease-out 0.25s;
    }

    /* don't round the top right cornet when first icon is selected */
    #menuPill > .nav-item:nth-child(1) .active .icon-container,
    #menuPill > .nav-item:nth-child(1) .nav-link:hover .icon-container{
        border-radius: 50% 0 0 0;
        transition: border-radius 0s ease-out 0s;
    }

    #menuPill >.nav-item:nth-last-child(1) .icon-container {
        border-radius: 0 0 50% 50%;
        /* transition duration and delay */
        transition: border-radius 0.1s ease-out 0.25s;
    }

    #menuPill > .nav-item:nth-last-child(1) .active .icon-container,
    #menuPill > .nav-item:nth-last-child(1) .nav-link:hover .icon-container{
        border-radius: 0 0 0 50%;
        transition: border-radius 0s ease-out 0s;
    }

    #menuPill .nav-link.active,
    #menuPill .nav-link:hover {
        max-width: 300px;
    }

    #menuPill .menu-label {
        background-color: rgba(0,0,0,0.7);
        /* top and bottom padding */
        padding: 0.5rem 0; 
        border-radius: 0 2rem 2rem 0;
        transition: max-width 0.25s ease-in-out,
        padding-right .25s ease-in-out;
    }

    #menuPill .nav-link.active .menu-label,
    #menuPill .nav-link:hover .menu-label {
        max-width: 100%;
        color: var(--ts-theme-200);
        padding-right: 1rem;
    }

    .menu-label-pointer {
        display: none;
    }
}

@media (max-width: 767.98px) {
    #menuPillContainer {
        top: 0;
        height: 4rem;
        width: 100vw;
        display: flex;
        justify-content: center;
    }

    #menuPill {
        flex-direction: row;
        align-items: center;
        margin-left: 0;
    }

    
    
    .nav-link.active {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    #menuPill .menu-label {
        display: none;
    }

    #menuPill .menu-label-pointer {
        display: none;
    }

    #menuPill .nav-link.active .menu-label-pointer {
        display: block;
        background-color: rgba(0,0,0,0.7);
        padding: 0.2rem;
        position: fixed;
        top: 52px;
        clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
        animation-name: fade-out;
        animation-duration: 4s;
        animation-fill-mode: forwards;
    }
    
    #menuPill .nav-link.active .menu-label {
        display: block;
        max-width: 100%;
        background-color: rgba(0,0,0,0.7);
        font-size: 0.7rem;
        padding: 0.2rem 0.35rem;
        margin-top: 0.2rem;
        border-radius: 0.4rem;
        position: fixed;
        top: 55px;
        animation-name: fade-out;
        animation-duration: 4s;
        animation-fill-mode: forwards;
    }

    @keyframes fade-out {
        0%{
            opacity: 1;
        }
        70% {
            opacity: 1;
        }
        100% {
            opacity: 0;
        }
    }

    #menuPill > .nav-item:nth-child(1) .icon-container {
        border-radius: 50% 0 0 50%;
    }

    #menuPill > .nav-item:nth-last-child(1) .icon-container {
        border-radius: 0 50% 50% 0;
    }

    .nav-tooltip {
        display: none;
    }
}