
/* YOU MIGHT HAVE NOTICED CODE STYLING CHANGED SINCE THE LAST COMMIT?
 KNOWING THIS PAGE WAS AN OLD MESS AND CONSIDERING I DID NOT HAVE ANY ENERGY TO REDO IT I TRIED GIVING IT TO GEMINI 2.5 PRO:
 IT WAS PERFECT AND PERFECTLY ADAPTED TO THE PAGE'S STYLE AND MADE ADJUSTMENTS/FIXES EXACTLY HAS I WANTED IT.
 MANY DEVELOPERS WILL LOSE THEIR JOBS.... */

/* --- General Styles --- */
body {
    display: flex;
    flex-direction: column;
    height: 100vh;
    margin: 0;
}

header {
    top: 0 !important;
    opacity: 1 !important;
    animation: none !important;
    flex-shrink: 0; /* Prevents header from shrinking */
}

header .usable-wrapper h1.anim,
header .usable-wrapper .right-panel div.selected {
    opacity: 1 !important;
    animation: none !important;
}

/* --- Main Container --- */
.project-container {
    display: flex;
    flex-grow: 1; /* Allows main to take up remaining space */
    margin-top: 60px; /* Header height */
    overflow: hidden; /* Prevents overflow */
}

/* --- Side Navigation Bar --- */
.navbar {
    width: 300px;
    flex-shrink: 0;
    background: #2c2c2c;
    overflow-y: auto;
    padding: 20px 0;
    transition: transform 0.3s ease-in-out;
}

.navbar h4 {
    font-family: 'akira_expanded', sans-serif;
    margin: 20px 0 10px 15px;
    opacity: .7;
    letter-spacing: 2px;
    user-select: none;
    font-size: 1em;
    color: #a0a0a0;
}

.navbar .nav-item {
    display: flex;
    align-items: center;
    height: 40px;
    padding-left: 15px;
    font-family: 'SFProDisplay', sans-serif;
    font-weight: bold;
    font-size: 16px;
    cursor: pointer;
    transition: ease-out .2s background-color, ease-out .2s color;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.navbar .nav-item img {
    width: 24px;
    height: 24px;
    margin-right: 10px;
    transition: .2s ease-out transform;
}

.navbar .nav-item:hover {
    background-color: #3a3a3a;
    color: white;
}

.navbar .nav-item:active {
    background-color: #1d1d1d; 
}

.navbar .nav-item span {
    margin-left: auto;
    padding-right: 15px;
    font-weight: lighter;
    font-size: 14px;
    color: gray;
    font-style: italic;
}

/* --- Project Display Area --- */
.project-display {
    flex-grow: 1;
    position: relative;
    overflow-y: auto;
    padding: 40px;
}

.project-content {
    display: none; /* Hidden by default */
}

.project-content.active {
    display: block; /* Shown when active */
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.project-display h1 {
    font-family: 'SFProDisplay', sans-serif;
    font-size: 2.5rem;
    margin: 0 0 20px 0;
    border-bottom: 1px solid #444;
    padding-bottom: 10px;
}

.project-display h2.sub-heading {
    font-family: 'SFProDisplay', sans-serif;
    font-size: 1.8rem;
    margin-top: 40px;
}

.project-display p {
    line-height: 1.6;
    margin-bottom: 15px;
    max-width: 800px; /* For better readability */
}

.project-display p.caption {
    opacity: .7;
    font-style: italic;
    font-size: 0.9em;
}

.project-display a {
    text-decoration: underline;
    color: #8ab4f8;
    transition: background-color 0.2s, color 0.2s;
}

.project-display a:hover {
    background-color: #8ab4f8;
    text-decoration: none;
    color: black;
}

.project-display ul {
    list-style: square;
    padding-left: 20px;
}

.project-display img {
    cursor: pointer;
    margin-top: 30px;
    margin-right: 40px;
    height: auto;
    max-width: 100%; /* Ensures images scale down on small screens */
}

.project-display #Select {
    text-align: center;
    padding-top: 15vh;
}
.project-display #Select h1, 
.project-display #Select p {
    margin: 0 auto;
    padding-top: 10px;
}

/* --- Mobile Specific --- */
#mobile-back-button {
    display: none; /* Hidden by default */
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 20px;
    background-color: #3a3a3a;
    color: white;
    border: 1px solid #555;
    border-radius: 8px;
    cursor: pointer;
    z-index: 1001;
    font-family: 'SFProDisplay', sans-serif;
    font-size: 1rem;
}

/* --- Responsive Design --- */
@media only screen and (max-width: 900px) {
    .project-container {
        flex-direction: column;
    }

    .navbar {
        width: 100%;
        height: auto;
        padding: 0;
        margin-bottom: 0;
        border-bottom: 1px solid #444;
        z-index: 1000;
        display: block;
    }

    .project-display {
        padding: 25px;
        display: none; /* Hide content by default on mobile */
    }

    /* State for when a project is selected on mobile */
    body.mobile-project-view .navbar {
        display: none;
    }

    body.mobile-project-view .project-display {
        display: block;
    }

    body.mobile-project-view #mobile-back-button {
        display: block;
    }

    .project-display h1 {
        font-size: 2rem;
    }
}

@media only screen and (max-width: 640px) {
    .project-display img {
        margin-right: 0;
        width: 100%; /* Make images full-width on small mobile */
    }
}

@media only screen and (max-width: 500px) {
    .navbar .nav-item span {
        display: none; /* Hide project type on mobile to save space */
    }

    .project-display {
        padding: 15px;
    }

     .project-display h1 {
        font-size: 1.5rem;
    }

    .project-display p {
        font-size: 0.95rem;
    }
}