.nav-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    z-index: 101;
    pointer-events: none;
}

.nav {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: .5rem 1.2rem;
    pointer-events: none;
}

/* Magnetic Menu Button */
.menu-trigger {
    position: relative;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    pointer-events: auto;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    z-index: 10002;
}

.menu-trigger:hover {
    background: rgba(255, 60, 30, 0.1);
    border-color: var(--accent-color);
    transform: scale(1.1);
}

.menu-trigger:hover::before {
    left: 100%;
}

/* Hamburger Lines */
.hamburger {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 18px;
}

.hamburger-line {
    position: absolute;
    width: 100%;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    transform-origin: center;
}

.hamburger-line:nth-child(1) {
    top: 0;
}

.hamburger-line:nth-child(2) {
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
}

.hamburger-line:nth-child(3) {
    bottom: 0;
}

/* Active state */
.menu-trigger.active .hamburger-line:nth-child(1) {
    top: 50%;
    transform: translateY(-50%) rotate(45deg);
    background: var(--accent-color);
}

.menu-trigger.active .hamburger-line:nth-child(2) {
    opacity: 0;
    width: 0;
}

.menu-trigger.active .hamburger-line:nth-child(3) {
    bottom: 50%;
    transform: translateY(50%) rotate(-45deg);
    background: var(--accent-color);
}

/* Full-Screen Menu Overlay */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--primary-bg);
    z-index: 10001;
    opacity: 0;
    visibility: hidden;
    transition: all 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

.menu-overlay::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 80% 20%, rgba(255, 60, 30, 0.1), transparent 50%);
    opacity: 0;
    transition: opacity 0.8s ease;
}

body.light .menu-overlay::before {
    background: radial-gradient(circle at 80% 20%, rgba(255, 60, 30, 0.2), transparent 50%);
}

.menu-overlay.active::before {
    opacity: 1;
}

/* Animated Background Elements */
.menu-bg-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    overflow: hidden;
}

.menu-bg-circle {
    position: absolute;
    border-radius: 50%;
    border: 1px solid #ffffff0d;
    pointer-events: none;
}

body.light .menu-bg-circle {
    border-color: #0000002d;
}

.menu-bg-circle:nth-child(1) {
    width: 200px;
    height: 200px;
    top: 10%;
    right: 15%;
    animation: rotate-slow 20s infinite linear;
}

.menu-bg-circle:nth-child(2) {
    width: 400px;
    height: 400px;
    bottom: 10%;
    left: 10%;
    animation: rotate-slow 30s infinite linear reverse;
}

.menu-bg-circle:nth-child(3) {
    width: 100px;
    height: 100px;
    top: 60%;
    right: 30%;
    animation: float 6s infinite ease-in-out;
}

@keyframes rotate-slow {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-20px);
    }
}

/* Menu Content */
.menu-content {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 50px;
    overflow-y: auto;
}

.menu-main {
    max-width: 1200px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
    align-items: center;
}

/* Navigation Links */
.menu-nav {
    display: flex;
    flex-direction: column;
    gap: 20px;
    height: 90vh;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 1.2rem;
}

.menu-nav-item {
    opacity: 0;
    transform: translateY(50px);
    cursor: pointer;
    position: relative;
    /* overflow: hidden; */
}

.menu-nav-link {
    font-family: 'Instrument Serif', serif;
    font-size: clamp(40px, 6vw, 80px);
    font-style: italic;
    color: var(--text-primary);
    text-decoration: none;
    display: block;
    line-height: 1.2;
    position: relative;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.menu-nav-link::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-color);
    transition: width 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}

.menu-nav-item:hover .menu-nav-link {
    color: var(--accent-color);
    transform: translateX(20px);
}

.menu-nav-item:hover .menu-nav-link::before {
    width: 100%;
}

.menu-nav-number {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    color: var(--text-tertiary);
    margin-bottom: 10px;
    letter-spacing: 2px;
    opacity: 0;
    transform: translateX(-20px);
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
}

.menu-nav-item:hover .menu-nav-number {
    opacity: 1;
    transform: translateX(0);
    color: var(--accent-color);
}

/* Menu Info */
.menu-info {
    opacity: 0;
    transform: translateY(30px);
}

.menu-info-title {
    font-family: 'Instrument Serif', serif;
    font-size: 36px;
    font-style: italic;
    margin-bottom: 30px;
    color: var(--text-primary);
}

.menu-info-text {
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 400px;
}

.menu-contact {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.menu-contact-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid var(--border-color);
    cursor: pointer;
    transition: all 0.3s ease;
}

.menu-contact-item:hover {
    border-color: var(--accent-color);
    transform: translateX(10px);
}

.menu-contact-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    letter-spacing: 1px;
    color: var(--text-tertiary);
}

.menu-contact-value {
    font-size: 14px;
    color: var(--text-primary);
}

.menu-social {
    display: flex;
    gap: 30px;
    margin-top: 50px;
}

.menu-social-link {
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    letter-spacing: 1px;
    color: var(--text-tertiary);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.menu-social-link:hover {
    color: var(--accent-color);
    transform: translateY(-2px);
}

.menu-social-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--accent-color);
    transition: width 0.3s ease;
}

.menu-social-link:hover::after {
    width: 100%;
}

/* Responsive */
@media (max-width: 768px) {
    .nav{
        padding: .3rem .6rem;
    }

    .menu-trigger {
        width: 40px;
        height: 40px;
    }

    .menu-content{
        padding: 2rem;
    }

    .menu-main {
        grid-template-columns: 1fr;
        gap: 0px;
        text-align: left;
    }

    .menu-nav{
        gap: 2rem;
        justify-content: center;
    }

    .menu-nav-link {
        font-size: clamp(32px, 8vw, 60px);
    }

    .menu-info{
        display: none;
    }
}