/* Skip to Content Link - Accessibility */
.skip-to-content {
    position: absolute;
    top: -40px;
    left: 0;
    background: #6a38ff;
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 0 0 4px 0;
    z-index: 10000;
    transition: top 0.3s;
}

.skip-to-content:focus {
    top: 0;
}

.compheader {
    height: 75px;
    width: 100%;
    background: rgba(44, 40, 45, 0.7);  /* Semi-transparent background */
    backdrop-filter: blur(10px);  /* Blur effect for glassmorphism */
    -webkit-backdrop-filter: blur(10px);  /* Safari support */
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: fixed;  /* Make header sticky */
    top: 28px;  /* Position below info-bar */
    left: 0;
    z-index: 1100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);  /* Enhanced shadow for depth */
    border-radius: 0 0 15px 15px;  /* Rounded bottom corners */
    border: 1px solid rgba(255, 255, 255, 0.1);  /* Subtle border for glass effect */
}

.logo {
    flex-shrink: 0;
    margin: 10px;
}

.logo-text {
    font-size: 28px;
    font-weight: bold;
    text-decoration: none;
    background: linear-gradient(135deg, #8b5cf6 0%, #c084fc 50%, #6a38ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 15px rgba(139, 92, 246, 0.4))
            drop-shadow(0 0 30px rgba(106, 56, 255, 0.3));
    animation: logoGlow 3s ease-in-out infinite;
    display: inline-block;
    letter-spacing: 1px;
}

@keyframes logoGlow {
    0%, 100% {
        filter: drop-shadow(0 0 15px rgba(139, 92, 246, 0.4))
                drop-shadow(0 0 30px rgba(106, 56, 255, 0.3));
    }
    50% {
        filter: drop-shadow(0 0 20px rgba(139, 92, 246, 0.6))
                drop-shadow(0 0 40px rgba(106, 56, 255, 0.5));
    }
}

/* Respect prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
    .logo-text {
        animation: none;
        filter: drop-shadow(0 0 15px rgba(139, 92, 246, 0.4))
                drop-shadow(0 0 30px rgba(106, 56, 255, 0.3));
    }
}

.logo img {
    max-height: 50px;
}

.nav-links {
    margin: 10px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-grow: 1;
    position: relative;
}

.nav-links ul {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav-links ul li {
    position: relative;
    display: inline-block;
    padding: 8px 8px;
    color: white;
}

.nav-links ul li a {
    color: white;
    text-decoration: none;
    font-size: 15px;
}

.nav-links ul li::after {
    content: '';
    width: 0%;
    height: 2px;
    background: #6a38ff;
    display: block;
    transition: width 0.3s ease;
}

.nav-links ul li:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #fff;
    padding: 10px;
    cursor: pointer;
    margin-left: auto;
    width: 30px;
    height: 20px;
    position: relative;
}

/* Hamburger icon bars - using absolute positioning for reliability */
.menu-toggle::before,
.menu-toggle::after,
.menu-toggle .bar {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;
    height: 3px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.menu-toggle::before {
    top: 0;
}

.menu-toggle .bar {
    top: 50%;
    transform: translateY(-50%);
}

.menu-toggle::after {
    bottom: 0;
}

#menu {
    display: flex;
    flex-direction: row;
}

@media (max-width: 700px) {
    .compheader {
        height: 75px;
    }

    .logo-text {
        font-size: 22px;  /* Slightly smaller on mobile */
    }

    .logo img {
        max-height: 40px;
    }

    .menu-toggle {
        display: flex;  /* Show hamburger icon on mobile */
    }

    .nav-links {
        flex-direction: row;
        align-items: center;
        width: auto;
        position: static;
    }

    #menu {
        display: none;
        flex-direction: column;
        position: fixed;
        top: 103px;  /* Position below fixed info-bar and header */
        right: 0;
        left: 0;
        background: #2c2c2c;
        z-index: 1099;
        padding: 10px 0;
        box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    }

    #menu.show {
        display: flex;
    }

    #menu li {
        width: 100%;
        padding: 12px 20px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.07);
    }

    #menu li:last-child {
        border-bottom: none;
    }

    #menu li a {
        font-size: 16px;
        display: block;
    }

    #menu li::after {
        display: none;
    }
}