/* TOP NAVIGATION BAR */
.topnav{
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1050;
    background: rgba(0,0,0,0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    height: 60px;
}
.topnav-container{
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    padding: 0 24px;
    max-width: 100%;
}
.topnav-left{
    display: flex;
    align-items: center;
    gap: 30px;
}
.topnav-logo img{
    max-height: 32px;
}
.topnav-menu{
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 4px;
}
.topnav-menu li{
    position: relative;
}
.topnav-link{
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(255,255,255,0.7);
    font-size: 0.85rem;
    font-weight: 500;
    padding: 8px 14px;
    border-radius: 8px;
    text-decoration: none;
    transition: 0.2s;
    white-space: nowrap;
}
.topnav-link:hover{
    color: #fff;
    background: rgba(255,255,255,0.08);
}
.topnav-link i{
    font-size: 0.8rem;
}
.topnav-link .small{
    font-size: 0.6rem;
    opacity: 0.5;
}

/* DROPDOWN */
.topnav-dropdown-menu{
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 200px;
    max-height: 400px;
    overflow-y: auto;
    background: rgba(17,17,17,0.98);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 8px;
    padding-top: 16px;
    margin-top: 0;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    z-index: 1060;
}
.topnav-dropdown-menu::before{
    content: '';
    position: absolute;
    top: -10px;
    left: 0;
    right: 0;
    height: 10px;
}
.topnav-dropdown:hover .topnav-dropdown-menu{
    display: block;
}
.topnav-dropdown-menu a{
    display: block;
    color: rgba(255,255,255,0.7);
    font-size: 0.82rem;
    padding: 8px 12px;
    border-radius: 6px;
    text-decoration: none;
    transition: 0.2s;
}
.topnav-dropdown-menu a:hover{
    color: #fff;
    background: rgba(255,255,255,0.08);
}
.topnav-dropdown-menu::-webkit-scrollbar{
    width: 4px;
}
.topnav-dropdown-menu::-webkit-scrollbar-thumb{
    background: rgba(255,255,255,0.15);
    border-radius: 4px;
}

/* RIGHT SIDE */
.topnav-right{
    display: flex;
    align-items: center;
    gap: 16px;
}
.topnav-search{
    display: flex;
    align-items: center;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    padding: 0 12px;
    transition: 0.3s;
}
.topnav-search:focus-within{
    border-color: var(--cor-primaria, #e50914);
    background: rgba(255,255,255,0.08);
}
.topnav-search input{
    background: transparent;
    border: none;
    outline: none;
    color: #fff;
    font-size: 0.82rem;
    padding: 7px 8px;
    width: 160px;
}
.topnav-search input::placeholder{
    color: rgba(255,255,255,0.3);
}
.topnav-search button{
    background: none;
    border: none;
    color: rgba(255,255,255,0.4);
    cursor: pointer;
    padding: 4px;
}
.topnav-search button:hover{
    color: var(--cor-primaria, #e50914);
}

/* PROFILE */
.topnav-profile{
    position: relative;
}
.topnav-avatar img{
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.1);
    transition: 0.3s;
}
.topnav-avatar:hover img{
    border-color: var(--cor-primaria, #e50914);
}
.topnav-profile-menu{
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 180px;
    background: rgba(17,17,17,0.98);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 12px;
    padding: 8px;
    padding-top: 18px;
    margin-top: 0;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    z-index: 1060;
}
.topnav-profile-menu::before{
    content: '';
    position: absolute;
    top: -12px;
    left: 0;
    right: 0;
    height: 12px;
}
.topnav-profile:hover .topnav-profile-menu{
    display: block;
}
.topnav-profile-menu .profile-info{
    padding: 8px 12px 12px;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    margin-bottom: 6px;
}
.topnav-profile-menu .profile-info small{
    display: block;
    color: rgba(255,255,255,0.7);
    font-size: 0.8rem;
}
.topnav-profile-menu .profile-info .text-green{
    color: #0db616;
    font-size: 0.7rem;
}
.topnav-profile-menu .profile-info .text-red{
    color: #ec3406;
    font-size: 0.7rem;
}
.topnav-profile-menu a{
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(255,255,255,0.7);
    font-size: 0.82rem;
    padding: 8px 12px;
    border-radius: 6px;
    text-decoration: none;
    transition: 0.2s;
}
.topnav-profile-menu a:hover{
    color: #fff;
    background: rgba(255,255,255,0.08);
}
.topnav-profile-menu a i{
    width: 18px;
    font-size: 0.85rem;
}

/* MOBILE BUTTON */
.topnav-mobile-btn{
    display: none;
    background: none;
    border: none;
    color: #fff;
    font-size: 1.3rem;
    cursor: pointer;
    padding: 6px;
}

/* MOBILE DRAWER */
.mobile-drawer{
    position: fixed;
    top: 0;
    left: -280px;
    width: 280px;
    height: 100vh;
    background: #0a0a0a;
    z-index: 1100;
    transition: 0.3s ease;
    overflow-y: auto;
    border-right: 1px solid rgba(255,255,255,0.05);
}
.mobile-drawer.active{
    left: 0;
}
.mobile-drawer-header{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}
.mobile-drawer-header img{
    max-height: 28px;
}
.mobile-drawer-header button{
    background: none;
    border: none;
    color: rgba(255,255,255,0.6);
    font-size: 1.2rem;
    cursor: pointer;
}
.mobile-drawer-body{
    padding: 12px 0;
}
.mobile-drawer-link{
    display: flex;
    align-items: center;
    gap: 12px;
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
    padding: 12px 20px;
    text-decoration: none;
    transition: 0.2s;
}
.mobile-drawer-link:hover{
    background: rgba(255,255,255,0.05);
    color: #fff;
}
.mobile-drawer-link i{
    width: 20px;
    font-size: 0.9rem;
}
.mobile-drawer-section{
    color: var(--cor-primaria, #e50914);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 16px 20px 6px;
}
.mobile-drawer-sublink{
    display: block;
    color: rgba(255,255,255,0.6);
    font-size: 0.82rem;
    padding: 8px 20px 8px 36px;
    text-decoration: none;
    transition: 0.2s;
}
.mobile-drawer-sublink:hover{
    color: #fff;
    background: rgba(255,255,255,0.03);
}
.mobile-drawer-overlay{
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    z-index: 1090;
}
.mobile-drawer-overlay.active{
    display: block;
}

/* RESPONSIVE */
@media screen and (max-width: 991px){
    .topnav-menu{
        display: none;
    }
    .topnav-search{
        display: none;
    }
    .topnav-profile{
        display: none;
    }
    .topnav-mobile-btn{
        display: block;
    }
}
@media screen and (max-width: 480px){
    .topnav-container{
        padding: 0 14px;
    }
}
