nav.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    padding: 1rem 2rem;
    background: rgba(5, 7, 12, 0.98);
    backdrop-filter: blur(10px) brightness(120%);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow:
        0 5px 25px rgba(0, 255, 234, 0.7),
        0 -3px 20px rgba(0, 255, 234, 0.5),
        0 0 15px rgba(255, 0, 255, 0.3);
}

.nav-center-container {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
    gap: 30px;
    justify-content: flex-start;
}

nav.navbar a {
    font-family: 'Share Tech Mono', monospace;
    color: #f0f0f0;
    text-decoration: none;
    margin: 0;
    padding: 8px 10px;
    transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    position: relative;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

nav.navbar a:visited {
    color: #f0f0f0;
}

nav.navbar a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #ff00ff;
    transition: all 0.3s ease-out;
    transform: translateX(-50%);
}

nav.navbar a:hover {
    color: #33ff99;
    transform: scale(1.05) translateY(-2px);
    text-shadow: 0 0 10px rgba(51, 255, 153, 0.8);
}

nav.navbar a:hover::after {
    width: 100%;
}

.menu-left {
    display: flex;
    align-items: center;
    gap: 25px;
    flex-wrap: wrap;
}

.menu-right {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.search-form {
    display: flex;
    align-items: center;
    background: #0d0f1b;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid #00ffea;
    box-shadow: 0 0 15px rgba(0, 255, 234, 0.4);
    transition: all 0.4s ease-in-out;
    flex: 1 1 250px;
    max-width: 400px;
}

.search-form:hover,
.search-form:focus-within {
    border-color: #ff00ff;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.8);
    transform: scale(1.01);
}

.search-form input[type="text"] {
    font-family: 'Share Tech Mono', monospace;
    padding: 10px 20px;
    border: none;
    outline: none;
    background: transparent;
    color: #fff;
    flex: 1 1 auto;
    min-width: 100px;
}

.search-form button {
    padding: 10px 15px;
    background: #00ffea;
    border: none;
    cursor: pointer;
    color: #101530;
    font-weight: 900;
    transition: all 0.3s;
    border-radius: 0 20px 20px 0;
}

.search-form button:hover {
    background: #ff00ff;
    box-shadow: 0 0 10px #ff00ff;
    color: #fff;
}

.avatar-profile {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #ff00ff;
    box-shadow: 0 0 15px rgba(255, 0, 255, 0.7);
    transition: all 0.3s;
    animation: pulse-border 4s infinite alternate;
}

@keyframes pulse-border {
    0% {
        border-color: #ff00ff;
        box-shadow: 0 0 15px rgba(255, 0, 255, 0.7);
    }

    50% {
        border-color: #00ffea;
        box-shadow: 0 0 25px rgba(0, 255, 234, 0.7);
    }

    100% {
        border-color: #ff00ff;
        box-shadow: 0 0 15px rgba(255, 0, 255, 0.7);
    }
}

.profile-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 5px 10px;
    border-radius: 10px;
    transition: all 0.3s;
    background: transparent;
    border: none;
    color: #fff;
    font-family: 'Orbitron', sans-serif;
}

.profile-btn:hover {
    background: rgba(51, 255, 153, 0.1);
    box-shadow: 0 0 10px rgba(51, 255, 153, 0.3);
}

.user-balance {
    color: #ffc107;
    font-weight: 700;
    font-size: 1rem;
    text-shadow: 0 0 8px #ffc107;
}

.username-text {
    font-weight: 600;
    color: #33ff99;
}

.create-post-btn {
    font-family: 'Orbitron', sans-serif;
    background: linear-gradient(90deg, #ff00ff, #ff0066);
    color: #fff;
    padding: 10px 20px;
    border-radius: 15px;
    font-weight: 700;
    box-shadow: 0 0 15px rgba(255, 0, 255, 0.8);
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.create-post-btn:hover {
    background: linear-gradient(90deg, #ff0066, #ff00ff);
    transform: scale(1.05) translateY(-3px);
    box-shadow: 0 0 25px rgba(255, 0, 255, 1);
}

.user-menu-wrapper {
    position: relative;
}

.user-menu {
    display: none;
    position: absolute;
    top: 120%;
    right: 0;
    left: auto !important;
    background: rgba(10, 15, 30, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 10px;
    padding: 5px 0;
    min-width: 220px;
    box-shadow: 0 0 30px rgba(0, 255, 234, 0.7);
    border: 2px solid #00ffea;
    z-index: 20;
}

.user-menu-wrapper.open .user-menu {
    display: block;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.user-menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.user-menu ul li a {
    font-family: 'Share Tech Mono', monospace;
    display: flex;
    align-items: center;
    color: #00ffea;
    text-decoration: none;
    padding: 10px 15px;
    font-weight: 500;
    border-radius: 0;
    transition: all 0.2s;
}

.user-menu ul li a:hover {
    background: rgba(0, 255, 234, 0.2);
    color: #fff;
    text-shadow: 0 0 8px rgba(0, 255, 234, 0.8);
    transform: translateX(5px);
}

@media (max-width: 900px) {
    nav.navbar {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
        padding: 1rem 1rem;
    }

    .nav-center-container {
        width: 100%;
        flex-wrap: wrap;
        gap: 10px;
        order: 2;
        justify-content: space-between;
    }

    .menu-left {
        width: 100%;
        justify-content: space-around;
        gap: 5px;
        order: 1;
        border-bottom: 1px dashed rgba(255, 255, 255, 0.1);
        padding-bottom: 10px;
    }

    .menu-left a {
        display: block;
        padding: 8px 5px;
        flex-grow: 1;
        text-align: center;
        margin: 0;
        font-size: 0.9em;
    }

    .menu-left a::after {
        height: 1px;
    }


    .menu-right {
        width: 100%;
        justify-content: space-between;
        gap: 10px;
        order: 1;
        margin-bottom: 0;
    }

    .create-post-btn {
        padding: 8px 15px;
        font-size: 0.9em;
    }

    .search-form {
        flex: 1 1 100%;
        max-width: none;
        order: 10;
        margin: 0;
        border-radius: 15px;
    }

    .search-form button {
        border-radius: 0 15px 15px 0;
    }

    .avatar-profile {
        width: 40px;
        height: 40px;
    }

    .user-menu {
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%);
        min-width: 95%;
    }
}