#loginButtonMobile {
    padding: 10px 20px;
    font-size: 17px;
    background-color: #5b67e7;
    color: white;
    border: none;
    cursor: pointer;
    border-radius: 6px;
    width: 100%;
    text-align: center;
    transition: background-color 0.2s;
    font-weight: 700;
    font-family: "Lato", sans-serif;
}

#loginButtonMobile:hover {
    background: #717dff;
}

#avatarButtonMobile {
    width: 100%;
    text-align: left;
    padding: 10px 16px;
    background: none;
    border: none;
    color: white;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 6px;
    transition: 0.2s;
    font-weight: 700;
}

#avatarMobile {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

#usernameMobile {
    font-family: "Lato", sans-serif;
    font-weight: 700;
    float: left;
    ;
}

/* Mobile Dropdown Menu Styles */
#dropdownMenuMobile {
    display: none;
    position: absolute;
    top: 65px;
    background-color: #16171c;
    box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.5);
    border: none;
    z-index: 100;
    padding: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s linear 0.3s;
    width: 100%;
    text-align: center;
}

#dropdownMenuMobile.show {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s linear 0s;
}

#dropdownMenuMobile a {
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    display: block;
    font-weight: 700;
    transition: background-color 0.2s ease;
}

#dropdownMenuMobile a:hover {
    background-color: #333;
}

/* Dropdown menu styles */
#dropdownMenu {
    display: none;
    position: absolute;
    top: 55px;
    right: 0;
    background-color: #16171c;
    border-radius: 6px;
    width: 100%;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
    z-index: 100;
}

#dropdownMenu.show {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0s linear 0s;
}

#dropdownMenu a {
    color: white;
    text-decoration: none;
    display: block;
    text-align: center;
    padding: 5px;
    transition: background-color 0.2s ease;
    border-radius: 6px;
}

#dropdownMenu a:hover {
    background-color: #333;
    color: #00aaff;
    border-radius: 6px;
}

#dropdownMenu a:last-child {
    padding-bottom: 10px;
}

/* Hamburger (mobile) */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    background: transparent;
    border: none;
    cursor: pointer;
}

.hamburger span {
    width: 22px;
    height: 3px;
    background: #fff;
    border-radius: 2px;
}

.hamburger.open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.hamburger.open span:nth-child(2) {
    opacity: 0;
}

.hamburger.open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.hamburger:hover span {
    background: #00aaff;
}

/* ========== MOBILE DRAWER ========== */
.mobile-drawer {
    position: fixed;
    right: -100%;
    top: 0;
    width: 280px;
    height: 100vh;
    background: #16171c;
    color: #fff;
    transition: right .25s ease;
    z-index: 110;
    display: flex;
    flex-direction: column;
    border-left: 1px solid #222;
    box-shadow: -4px 0 24px rgba(0, 0, 0, 0.6);
    font-weight: 700;
    overflow-y: auto;
    align-items: left;
}

.mobile-drawer.open {
    right: 0;
}

.mobile-header {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    top: 40px;
    right: 10px;
    margin-bottom: 100px;
}

.mobile-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}

.mobile-brand img {
    height: 60px;
    width: auto;
}

.mobile-brand h2 {
    font-size: 1.5rem;
    margin: 0;
    color: #fff;
}

.mobile-links {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow: visible;
}

/* Mobile links & submenu */
.mobile-links a,
.mobile-sub-menu a {
    padding: 10px 16px;
    text-decoration: none;
    color: #fff;
    border-radius: 6px;
    transition: 0.2s;
    font-weight: 700;
}

.mobile-links a:hover,
.mobile-sub-menu a:hover,
#avatarButtonMobile:hover,
#dropdownMenuMobile a:hover {
    background: #222;
    color: #00aaff;
}

.mobile-sub {
    display: flex;
    flex-direction: column;
}

.mobile-sub-menu {
    display: none;
    flex-direction: column;
    padding-left: 0;
    background: #16171c;
    margin-top: 4px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.5);
}

.mobile-sub.open .mobile-sub-menu {
    display: flex;
    animation: fadeIn 0.2s ease forwards;
}

@keyframes fadeIn {
    0% {
        opacity: 0;
        transform: translateY(-5px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Submenu toggle button */
.mobile-sub-toggle {
    width: 100%;
    text-align: left;
    padding: 10px 16px;
    background: none;
    border: none;
    color: #fff;
    font-size: 0.95rem;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 6px;
    transition: 0.2s;
    font-weight: 700;
}

.mobile-sub-toggle:hover {
    background: #222;
    color: #00aaff;
}