.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 30px;
    padding: 15px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.8);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.nav__link {
    color: #C1C0D8;
    text-decoration: none;
    font-family: Inter, sans-serif;
    font-size: 16px;
    transition: all 0.3s ease;
    position: relative;
    padding: 5px 0;
}

.nav__link::before,
.nav__link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    background-color: #4caf50;
    transition: width 0.3s ease;
    left: 0;
}

.nav__link::before {
    top: 0;
}

.nav__link::after {
    bottom: 0;
}

.nav__link:hover {
    color: #ffffff;
}

.nav__link:hover::before,
.nav__link:hover::after {
    width: 100%;
}
    position: relative;
    display: inline-block;
    padding: 12px 0;
    text-decoration: none;
    color: #C1C0D8;
    font-family: Inter, sans-serif;
    font-size: 18px;
    font-weight: 500;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.nav__link:hover {
    color: #fff;
    text-shadow: 0 0 8px rgba(0, 255, 128, 0.2);
}

/* Underline */
.nav__link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background: #00ff80;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
}

/* Overline */
.nav__link::before {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    top: 0;
    left: 50%;
    background: #00ff80;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
}

.nav__link:hover::after,
.nav__link:hover::before {
    width: 100%;
}

/* Active state */
.nav__link.active {
    color: #fff;
}

.nav__link.active::after,
.nav__link.active::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    left: 50%;
    background: #00ff80;
    transform: translateX(-50%);
}

.nav__link.active::after {
    bottom: 0;
}

.nav__link.active::before {
    top: 0;
}

/* Add subtle gradient to the lines */
.nav__link::after,
.nav__link::before {
    background: linear-gradient(90deg, transparent 0%, #00ff80 50%, transparent 100%);
}

/* Make Reddit link (middle item) have permanent hover state by default */
/* Update selector to target X/Twitter link */
.nav__link:nth-child(3) {
    color: #fff;
}

.nav__link:nth-child(3)::before,
.nav__link:nth-child(3)::after {
    width: 100%;
}

/* Rest of the hover states remain the same as they use the same nth-child(3) selector */
/* Override the default state when hovering other links */
.nav:hover .nav__link:nth-child(3)::before,
.nav:hover .nav__link:nth-child(3)::after {
    width: 0;
}

.nav:hover .nav__link:nth-child(3) {
    color: #C1C0D8;
}

/* Restore hover effects for all links when directly hovering */
.nav:hover .nav__link:hover {
    color: #fff;
}

.nav:hover .nav__link:hover::before,
.nav:hover .nav__link:hover::after {
    width: 100%;
}

/* Return to Reddit when leaving nav */
.nav:not(:hover) .nav__link:nth-child(3) {
    color: #fff;
}

.nav:not(:hover) .nav__link:nth-child(3)::before,
.nav:not(:hover) .nav__link:nth-child(3)::after {
    width: 100%;
}