/* Navbar für ALLE ANDEREN SEITEN - immer sichtbar */

#navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    /* UNTERSCHIED: Immer sichtbar */
    transform: translateY(0);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.2rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    z-index: 102;
}

.nav-logo img {
    height: 40px;
    width: auto;
    object-fit: contain;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    align-items: center;
}

.nav-links > a,
.nav-dropdown {
    color: #fff;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 400;
    transition: all 0.3s ease;
    letter-spacing: 0.01em;
    position: relative;
}

.nav-links > a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #0071e3, #9333ea);
    transition: width 0.3s ease;
}

.nav-links > a:hover {
    color: #9333ea;
}

.nav-links > a:hover::after {
    width: 100%;
}

/* Dropdown Styles */
.nav-dropdown {
    position: relative;
    cursor: pointer;
}

.nav-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 400;
    letter-spacing: 0.01em;
    transition: all 0.3s ease;
}

.nav-dropdown-toggle:hover {
    color: #9333ea;
}

.dropdown-arrow {
    font-size: 0.7rem;
    transition: transform 0.3s ease;
}

.nav-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 15px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 0.5rem 0;
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(-10px);
    transition: all 0.3s ease;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

/* Unsichtbare Brücke über den 15px Gap */
.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -15px;
    left: 0;
    right: 0;
    height: 15px;
    background: transparent;
}

.nav-dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
}

.dropdown-menu a {
    display: block;
    padding: 0.8rem 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    position: relative;
}

.dropdown-menu a::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 3px;
    background: linear-gradient(180deg, #0071e3, #9333ea);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.dropdown-menu a:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.dropdown-menu a:hover::before {
    opacity: 1;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 102;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 2px;
    background: #fff;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(7px, 7px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Body Scroll Lock when Mobile Menu is Open */
body.menu-open {
    overflow: hidden;
    position: fixed;
    width: 100%;
}

/* Responsive Design */
@media (max-width: 968px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: 100%;  /* Geändert von 300px zu 100% */
        background: rgba(0, 0, 0, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        align-items: flex-start;
        padding: 6rem 2rem 2rem;
        gap: 0;
        transform: translateX(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border-left: 1px solid rgba(255, 255, 255, 0.1);
        overflow-y: auto;
        will-change: transform;
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .nav-links > a,
    .nav-dropdown {
        width: 100%;
        padding: 1rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .nav-links > a::after {
        display: none;
    }

    .nav-links > a:hover {
        color: #fff;
    }

    .nav-links > a:active {
        color: #9333ea;
    }

    /* Mobile Dropdown */
    .nav-dropdown {
        display: flex;
        flex-direction: column;
    }

    .nav-dropdown-toggle {
        width: 100%;
        justify-content: space-between;
        padding: 0;
    }

    .nav-dropdown-toggle:hover {
        color: #fff;
    }

    .dropdown-arrow {
        transition: transform 0.3s ease;
    }

    .nav-dropdown.active .dropdown-arrow {
        transform: rotate(180deg);
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        background: transparent;
        border: none;
        box-shadow: none;
        padding: 0;
        margin-top: 0.5rem;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    /* Entferne die unsichtbare Brücke auf Mobile */
    .dropdown-menu::before {
        display: none;
    }

    .nav-dropdown.active .dropdown-menu {
        max-height: 300px;
    }

    .dropdown-menu a {
        padding: 0.8rem 0 0.8rem 1.5rem;
        font-size: 0.85rem;
        color: rgba(255, 255, 255, 0.7);
    }

    .dropdown-menu a::before {
        width: 2px;
    }

    .dropdown-menu a:hover {
        background: transparent !important;
        color: rgba(255, 255, 255, 0.7) !important;
        padding-left: 1.5rem !important;
    }

    .dropdown-menu a:hover::before {
        opacity: 0 !important;
    }

    .dropdown-menu a:active {
        color: #9333ea !important;
    }

    .dropdown-menu a:active::before {
        opacity: 1 !important;
    }
}

@media (max-width: 480px) {
    .nav-container {
        padding: 1rem 1.5rem;
    }

    .nav-logo img {
        height: 35px;
    }
}

@media (hover: hover) and (pointer: fine) {
    /* Desktop Hover bleibt aktiv */
}

@media (hover: none) and (pointer: coarse) {
    .dropdown-menu a:hover {
        background: transparent !important;
        color: rgba(255, 255, 255, 0.7) !important;
        padding-left: 1.5rem !important;
    }
    
    .dropdown-menu a:hover::before {
        opacity: 0 !important;
    }
}