#top_menu.hidden,
main.ui_hidden #top_menu{
    opacity: 0;
    pointer-events: none;
}

#top_menu {
    position: absolute;
    left: 0px;
    top: 0px;
    right: 0;
    height: 148px;
    pointer-events: all;
    z-index: 102;
    white-space: nowrap;
    text-align: right;
    padding-right: 26px;
    transition: opacity 0.5s;
}

#top_menu > .item {
    position: relative;
    cursor: pointer;
    display: inline-block;
    z-index: 10;
    font-family: arial, sans-serif;
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    color: rgba(255,255,255,1);
    margin: 32px 26px;
    transition: color 0.3s;
    text-decoration: none;
    text-shadow: 0px 0px 5px rgba(0,0,0,0.6);
}

#top_menu > .item:before {
    content: '\2022';
    position: absolute;
    pointer-events: none;
    width: 52px;
    font-size: 26px;
    color: rgba(136,0,220,0.5);
    line-height: 26px;
    left: -52px;
    top: -3px;
    transition: color 0.3s;
}

#top_menu .hover_bg {
    position: absolute;
    left: 0px;
    top: 0px;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    opacity: 0;
    background-image: url(../images/svg/menu_top_gradient.svg);
    background-position: left top;
    background-size: 100% 100%;
    background-repeat: no-repeat;
    transition: opacity 0.3s;
}

#top_menu > .item.social div {
    position: absolute;
    opacity: 0;
    display: flex;
    flex-direction: row;
    left: 50%;
    top: 100%;
    width: auto;
    height: auto;
    max-height: 60px;
    background-color: rgba(136,0,220,0);
    border-radius: 4px;
    overflow: hidden;
    padding-top: 10px;
    transition: opacity 0.3s, max-height 0.3s, transform 0.3s;
    transform-origin: 50% top;
    transform: translateX(-202px) scale(0);
    border: 0px solid transparent;
    border-width: 6px 40px 40px 40px;
    padding: 2px;
}

#top_menu > .item:focus, #top_menu > .item:hover, #top_menu > .item.active {
    color: rgba(255,255,255,1);
    text-decoration: underline;
}

#top_menu > .item.social:hover div {
    opacity: 1;
    /* max-height: 60px; */
    transform: translateX(-202px) scale(1);
}

#top_menu > .item.social div .item {
    display: block;
    position: relative;
    width: 60px;
    height: 60px;
    cursor: pointer;
    background-color: rgba(136,0,220,1);
    transition: background-color 0.3s;
    margin-bottom: 1px;
    box-shadow: 0 0 2px rgb(0 0 0 / 20%);
}

#top_menu > .item.social div .item:first-child{
    border-top-left-radius: 4px;
    border-bottom-left-radius: 4px;
}

#top_menu > .item.social div .item:last-child{
    border-top-right-radius: 4px;
    border-bottom-right-radius: 4px;
}
    

#top_menu > .item.social div .item img {
    position: absolute;
    left: 50%;
    top: 50%;
    pointer-events: none;
    transform-origin: center;
    transform: translate(-50%,-50%) scale(1.0);
    transition: transform 0.3s;
}

@media (max-width: 600px) { 
    #top_menu {
        position: absolute;
        left: 0px;
        top: 60px;
        right: 0;
        height: 40px;
    }

    #top_menu > .item{
        margin: 13px 18px;
        font-size: 11px;
    }

    #top_menu > .item:before{
        width: 55px;
        font-size: 15px;
        left: -36px;
        top: -5px;        
    }

    #top_menu > .item.social div .item{
        width: 40px;
        height: 40px;        
    }

    #top_menu > .item.social div .item img{
        transform: translate(-50%,-50%) scale(0.6);
    }

    #top_menu > .item.social:hover div{
        transform: translateX(-98px) scale(1);
    }
}