@font-face {
    font-family: 'pixeldyundfrederick';
    src: url(/pixeldy_und_frederick_v02.woff);
    font-style: medium;
}

/* Base Styles */
html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100vh;
    overflow-x: hidden;
    font-family: 'pixeldyundfrederick', sans-serif;
    font-weight: normal;
    -webkit-font-smoothing: none;
    -moz-osx-font-smoothing: none;
    text-shadow: none;
    outline: none;
    color: chartreuse;
    background:rgb(253, 253, 250); /* Warm white with green tint */;
    text-rendering: pixelated;

}

#project-list {
    font-size: 48px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 20px; /* Space between items */
    margin-top: 160px; /* Space below header */
    margin-bottom: 60px; /* Space below footer */
    text-decoration: none;
    outline: none;
}

/* Project Navigation */
#project-navigation {
    color: chartreuse;
    margin-top: 100px;
    font-size: 20pt;
}

/* Header Elements */
#logo-container {
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 100;
    width: 350px;
    height: auto;
}

#navigation {
    display: inline-flex;
    width: auto;
    height: auto;
    gap: 40px;
    position: fixed;
    top: 40px;
    right: 30px;
    z-index: 100;
}

p {
    font-size: 36px;
}

h2 {
    color: rgb(127, 255, 0);
    text-decoration: none;
    font-weight: normal;
}

#project-navigation ul {
    list-style-type: none;
    padding: 60px;
    margin: 0;
}

#navigation h2 {
    margin: 0;
    padding: 0;
}

#navigation a,
#navigation .nav-btn,
#project-navigation a, #navigation .projects-selected {
    position: relative;
    color: rgb(127, 255, 0);
    text-decoration: none;
    font-size: 48px;
    font-weight: normal;
    transition:
        color 0.1s ease-in-out,
        filter ease-in-out 0.1s;
    background: none;
    border: none;
    font-family: inherit;
    cursor: pointer;
    padding: 0;
    outline: none;
    /* Remove underline for button by default, like anchor */
    text-decoration: none;
}

#navigation a:hover,
#navigation .nav-btn:hover,
#project-navigation a:hover {
    color: blue;
    filter: drop-shadow(2px 2px 4px blue);
    text-decoration: none;
}



/* Remove underline from .nav-btn if previously set */
.nav-btn {
    text-decoration: none;
}

#navigation .projects-selected {
    filter: drop-shadow(2px 2px 4px blue);
    color: blue;
    font-size: 48px;
    transition:
    color 0.1s ease-in-out,
    filter ease-in-out 0.1s;
}

#logo-container img{
    transition: 
        content 0.1s ease-in-out,
        filter ease-in-out 0.1s;
}

#logo-container img:hover {
    content: url('/MICHA_BIELER_hover.png');
    filter: drop-shadow(2px 2px 4px blue); /* Change image on hover */
}

.help {
    position: fixed;
    bottom: 20px;
    right: 35px;
    z-index: 1000;
}

#help-icon {
    cursor: pointer;
}

.back {
    position: fixed;
    bottom: 20px;
    right: 35px;
    z-index: 1000;
}

#back-icon {
    cursor: pointer;
}

/* Project Gallery */
#project-gallery {
    position: relative;
    width: 90vw;
height: 70vh; /* Smaller scattering area */
    margin: 160px auto 0;
    margin-bottom: 60px;
    overflow: visible;
    }

.project-item {
    position: absolute;
    max-width: 200px;
    max-height: 200px;
    filter: drop-shadow(2px 2px 4px rgba(0, 0, 73, 0.5)); /* Subtle drop shadow */
    transition: 
        transform 0.2s cubic-bezier(0.18, 0.89, 0.32, 1.28),
        filter 0.2s ease-out;
    transform-origin: center; /* Ensures even scaling */
    will-change: transform;
}

.project-item img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    image-rendering: crisp-edges;
}

.project-item:hover {
    transform: scale(1.1) !important; /* Slightly larger scale */
    filter: 
        drop-shadow(4px 4px 8px blue) 
        brightness(1.02); /* Subtle light effect */
    z-index: 1000;
}

   

    .project-item:hover img {
        animation: gentlePulse 2s infinite ease-in-out;
    }

/* Footer */
#copyright {
    position: sticky;
    bottom: 10px;
    left: 0;
    width: 100%;
    text-align: center;
    font-size: 16px;
    padding: 10px 0;
    z-index: 90;
    color: blue;
}

/* Popup Box */
#popup {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    border: 3px solid chartreuse;
    padding: 20px;
    padding-left: 40px;
    padding-right: 40px;
    z-index: 1000;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    text-align: center;
    width: auto;
    min-width: 200px;
    max-width: 90%;
    max-height: 90%;
    overflow-y: auto;
}

#popup.hidden {
    display: none;
}

#popup button {
    margin-top: 10px;
    padding: 5px 10px;
    cursor: pointer;
}

#contact-btn.active,
#contact-btn.active:hover {
    color: blue;
    filter: drop-shadow(2px 2px 4px blue);
    text-decoration: none;
}

#popup-text-contact a {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

/* Mobile Adjustments */
@media (max-width: 767px) {

    #logo-container {
        left: 50%;
        transform: translateX(-50%); /* Center horizontally */
    }

    #project-gallery {
        height: auto;
        margin-top: 160px; /* Adjusted margin for mobile */
        margin-bottom: 100px;
    }
    
    .project-item {
        max-width: 120px;
        max-height: 120px;
    }
    
    #navigation {
        position: fixed;
        display: flex;
        flex-direction: column; /* Stack items vertically */
        gap: 20px; /* Space between items */
        z-index: 1000; /* Ensure visibility */
        display: flex;
        bottom: 17px;
        top: unset;
        right: unset; /* Explicitly remove the right property */
        left: 20px;
        padding-bottom: 0px;
    }

    #navigation a,
    #navigation .nav-btn, #navigation .projects-selected {
        -webkit-writing-mode: sideways-lr;
        -ms-writing-mode: tb-rl;
        writing-mode: sideways-lr;
        transition: color 0.1s ease-in-out;
        padding: 0;
        margin: 0;
        display: inline-block;
    }

    #navigation h2 {
        padding: 0;
        margin: 0;
    }

    #navigation a:hover,
    #navigation .nav-btn:hover {
        color: blue;
    }
    

    .help {
        right: 20px;
    }

    .back {
        right: 20px;
    }

    footer {
        display: none; /* Hide the footer on mobile */
    }
}
