html {
    scroll-behavior: smooth;
}

/* Fade in animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

:root {
    --background: #ffffff;
    --main-text: #000000;
    --navigation: #1d3224;
    --links-accents: #155e89;
    --call-to-action-buttons: #155e89;
    --secondary-text: #2f672f;
    --borders-highlights: #155e89;
    --content-background: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

main {
    margin: 0;
    padding: 10px;
    padding-top: 130px;
    flex: 1 0 auto;
}


/* Mobile/Tablet: Make main full width for better space usage */
@media (max-width: 900px) {
    main {
        max-width: 100%;
        margin: 0 auto;
        padding: 0 10px;
        padding-top: 130px;
    }
    
    main:has(#home) {
        padding: 0;
        padding-top: 0;
    }
    
    #home.content-section {
        padding: 0;
        padding-top: 100px;
        margin: 0;
        width: 100%;
        min-height: calc(100vh - 100px);
        display: flex;
        flex-direction: column;
    }
    
    .home-hero-background {
        margin: 0;
        margin-top: 0;
        padding: 0;
        padding-top: 0;
        width: 100%;
        flex-shrink: 0;
    }
    
    #home .hero-cta {
        flex: 1;
        display: flex;
        align-items: center;
    }
}

/* Desktop: Adjust main content for left navbar and full viewport sections */
@media (min-width: 701px) {
    main {
        margin-left: 200px;
        margin-right: 0;
        padding: 0;
        width: calc(100vw - 200px);
        max-width: calc(100vw - 200px);
        display: flex;
        flex-direction: column;
    }
}


.content-section {
    margin: 40px auto;
    padding: 24px; 
    background-color: transparent;
    border: none;
    box-shadow: none;
    scroll-margin-top: 120px;
    border-radius: 8px;
    max-width: 70%;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

#home.content-section {
    max-width: 100%;
    margin: 0 !important;
    padding: 0 !important;
}

/* About page: 3-column grid that collapses to 1 */
.about-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    margin-top: 24px;
}

.about-card {
    padding: 24px;
    background-color: var(--background);
    border: 1px solid var(--borders-highlights);
    border-radius: 8px;
}

.about-card h3 {
    margin-top: 0;
    margin-bottom: 12px;
}

.about-card p,
.about-card ul {
    margin: 0 0 12px 0;
}

.about-card ul {
    padding-left: 1.2em;
}

@media (max-width: 900px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile/Tablet: Increase content section width for better space usage */
@media (max-width: 900px) {
    .content-section {
        max-width: 95%;
        padding-left: 0;
        padding-right: 0;
    }
}

/* Desktop: Remove old snap-scroll viewport constraints */
@media (min-width: 701px) {
    .content-section {
        width: 100%;
        max-width: 100%;
        margin: 40px 0;
        padding: 20px 40px;
        box-sizing: border-box;
    }
}


/* At 701-900px: Non-subsection sections should be centered and use available width */
@media (min-width: 701px) and (max-width: 900px) {
    .content-section:not(.subsection) {
        max-width: 95%;
        margin-left: auto;
        margin-right: auto;
    }
}

/* Above 1100px: Center content sections within the available space (accounting for navbar) */
@media (min-width: 1101px) {
    .content-section {
        max-width: 90%;
        margin-left: auto;
        margin-right: auto;
    }
}


.content-section.visible {
    opacity: 1;
    transform: translateY(0);
    animation: fadeIn 0.6s ease forwards;
}

#home {
    margin: 0;
    padding: 0;
    width: 100%;
}

/* Home Hero Background Section - Side by side layout */
.home-hero-background {
    position: relative;
    padding: 0;
    padding-bottom: 40px;
    margin: 0;
    overflow: visible;
    min-height: 450px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    padding-left: 40px;
    padding-right: 40px;
}

.home-hero-background::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 450px;
    height: calc(100vw - 200px);
    transform: translate(-50%, -50%) rotate(-90deg);
    background-image: url('./NeuoNur Website Photos-20250816T000453Z-1-001/NeuoNur Website Photos/(16).jpeg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.25;
    z-index: 0;
}

@media (max-width: 700px) {
    main:has(#home) {
        padding: 0 !important;
        padding-top: 0 !important;
    }
    
    #home.content-section {
        padding: 0 !important;
        padding-top: 0 !important;
        min-height: 100vh;
        display: flex;
        flex-direction: column;
    }
    
    .home-hero-background {
        flex-shrink: 0;
        height: 350px;
        margin: 0 !important;
        padding-top: 100px !important;
        flex-direction: column;
        gap: 20px;
        padding-left: 20px !important;
        padding-right: 20px !important;
    }
    
    .home-hero-background .home-title::after {
        display: none;
    }
    
    .home-hero-background .mission-statement {
        text-align: center;
    }
    
    .home-hero-background::before {
        width: 350px;
        height: 100vw;
    }
    
    #home .hero-cta {
        flex: 1;
        display: flex;
        align-items: center;
    }
}

.home-hero-background .home-title {
    z-index: 1;
    font-size: 2.8rem;
    font-weight: 700;
    margin: 0;
    color: #000;
    font-family: 'Merriweather', 'Georgia', serif;
    text-align: left;
    flex-shrink: 0;
    position: relative;
}

/* Divider line after title */
.home-hero-background .home-title::after {
    content: '';
    position: absolute;
    width: 2px;
    height: 200px;
    background-color: var(--borders-highlights);
    right: -21px;
    top: 50%;
    transform: translateY(-50%);
}

/* Desktop: Position content */
@media (min-width: 701px) {
    .home-hero-background {
        height: 450px;
    }
}

.home-hero-background .mission-statement {
    z-index: 1;
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--secondary-text);
    margin: 0;
    text-align: left;
    flex: 1;
    max-width: 600px;
}

#home .hero-cta {
    display: flex;
    gap: 20px;
    justify-content: center;
    align-items: center;
    flex: 1;
    padding: 0 40px;
}

/* Desktop: Layout */
@media (min-width: 701px) {
    #home {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        min-height: calc(100vh - 130px);
    }
    
    .home-hero-background {
        width: 100%;
        align-self: stretch;
        flex-shrink: 0;
    }
    
    #home .hero-cta {
        max-width: 900px;
        margin-left: auto;
        margin-right: auto;
        align-self: center;
        display: flex;
        justify-content: center;
        align-items: center;
    }
}

/* Home Section Two-Column Layout (Desktop only, above 900px) */
@media (min-width: 901px) {
    .home-container {
        display: flex;
        align-items: center;
        gap: 0;
        min-height: 600px;
        width: 100%;
        box-sizing: border-box;
        padding: 60px 0;
    }
    
    .home-left {
        flex: 1 1 0;
        text-align: right;
        padding-right: 30px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        box-sizing: border-box;
        min-width: 0;
        align-items: flex-end;
    }
    
    .home-title {
        font-size: 6rem;
        font-weight: 700;
        line-height: 1.1;
        margin-bottom: 48px;
        margin-top: 0;
        color: var(--secondary-text);
        font-family: 'Merriweather', 'Georgia', serif;
        text-align: right;
    }
    
    .home-title .title-line {
        display: block;
    }
    
    .mission-statement {
        font-size: 1.3rem;
        line-height: 1.7;
        color: var(--main-text);
        margin-top: 0;
        margin-bottom: 0;
        max-width: 100%;
        text-align: right;
    }
    
    .home-divider {
        width: 2px;
        background-color: var(--links-accents);
        flex-shrink: 0;
        margin: 0 20px;
        align-self: center;
        height: 75%;
        max-height: 75%;
    }
    
    .home-right {
        flex: 1 1 0;
        text-align: left;
        padding-left: 30px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        box-sizing: border-box;
        min-width: 0;
        align-items: flex-start;
    }
    
    .home-right h3 {
        font-size: 2.5rem;
        margin-bottom: 20px;
        margin-top: 0;
        text-align: left;
        width: 100%;
        color: var(--secondary-text);
    }
    
    .home-right .overview-grid {
        justify-content: flex-start;
        text-align: left;
        width: 100%;
        margin-bottom: 20px;
        margin-top: 0;
    }
    
    .home-right .overview-item {
        text-align: left;
        width: 100%;
    }
    
    .home-right .overview-item h4,
    .home-right .overview-item p {
        text-align: left;
    }
    
    .home-right .hero-cta {
        justify-content: flex-start;
        margin-top: 0;
        margin-bottom: 0;
        width: 100%;
    }
}

/* Team Carousel Styles */
.team-carousel-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
    width: 100%;
    max-width: 100%;
    margin: 40px auto;
    box-sizing: border-box;
    padding: 0 20px;
    min-height: 400px;
}

.team-carousel-wrapper {
    flex: 1;
    overflow: visible;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-width: 0;
}

.team-carousel-track {
    display: flex;
    gap: 20px;
    transition: transform 0.5s ease;
    align-items: center;
    justify-content: center;
    width: fit-content;
    max-width: 100%;
    margin: 0 auto;
}

.team-member-card {
    flex-shrink: 0;
    transition: all 0.3s ease;
}

/* Desktop: Active card (center) */
@media (min-width: 951px) {
    .team-carousel-track {
        justify-content: center;
        align-items: center;
    }
    
    .team-member-card.active {
        width: 500px;
        max-width: 500px;
        min-width: 500px;
        max-height: 350px;
        display: flex;
        gap: 25px;
        align-items: flex-start;
        padding: 25px;
        background-color: var(--content-background);
        border-radius: 12px;
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
        flex-shrink: 0;
        box-sizing: border-box;
    }
    
    .team-member-card:not(.active) {
        width: 100px;
        height: 100px;
        max-width: 100px;
        min-width: 100px;
        flex-shrink: 0;
        cursor: pointer;
        box-sizing: border-box;
    }
    
    .team-member-card:not(.active):hover {
        transform: scale(1.1);
    }
    
    .team-member-image.active-image {
        width: 160px;
        height: 160px;
        flex-shrink: 0;
    }
    
    .team-member-image.active-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 12px;
    }
    
    .team-member-image.thumbnail-image {
        width: 100%;
        height: 100%;
    }
    
    .team-member-image.thumbnail-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 50%;
        border: 3px solid var(--links-accents);
    }
    
    .team-member-info {
        flex: 1;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }
    
    .team-member-bio-preview {
        flex: 0 1 auto;
        margin-bottom: 10px;
        line-height: 1.5;
    }
    
    .team-member-name {
        font-size: 2rem;
        font-weight: 700;
        margin-bottom: 8px;
        color: var(--main-text);
    }
    
    .team-member-role {
        font-size: 1.2rem;
        color: var(--links-accents);
        margin-bottom: 16px;
        font-weight: 600;
    }
    
    .team-member-bio {
        font-size: 1rem;
        line-height: 1.6;
        color: var(--secondary-text);
    }
}

/* Mobile: Vertical layout */
@media (max-width: 950px) {
    .team-carousel-container {
        flex-direction: column;
        gap: 15px;
    }
    
    .team-carousel-wrapper {
        width: 100%;
    }
    
    .team-carousel-track {
        flex-direction: column;
        gap: 20px;
    }
    
    .team-member-card {
        width: 100%;
        max-width: 100%;
    }
    
    .team-member-card.active {
        display: flex;
        flex-direction: column;
        gap: 20px;
        padding: 20px;
        background-color: var(--content-background);
        border-radius: 12px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    }
    
    .team-member-card:not(.active) {
        display: none; /* Hide non-active cards on mobile */
    }
    
    .team-member-image.active-image {
        width: 150px;
        height: 150px;
        margin: 0 auto;
    }
    
    .team-member-image.active-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        border-radius: 50%;
    }
    
    .team-member-info {
        text-align: center;
    }
    
    .team-member-name {
        font-size: 1.5rem;
        font-weight: 700;
        margin-bottom: 8px;
        color: var(--main-text);
    }
    
    .team-member-role {
        font-size: 1rem;
        color: var(--links-accents);
        margin-bottom: 12px;
        font-weight: 600;
    }
    
    .team-member-bio {
        font-size: 0.95rem;
        line-height: 1.6;
        color: var(--secondary-text);
    }
}

.team-carousel-arrow {
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 1.5rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
    flex-shrink: 0;
    z-index: 10;
    position: relative;
}

.team-carousel-arrow:hover:not(:disabled) {
    background-color: var(--links-accents);
}

.team-carousel-arrow:disabled {
    background-color: #cccccc;
    color: #888888;
    cursor: not-allowed;
    opacity: 0.5;
}

/* Mobile: Change arrow direction */
@media (max-width: 950px) {
    .team-carousel-arrow {
        padding: 10px 16px;
        font-size: 1.2rem;
    }
    
    .team-carousel-left {
        font-size: 0;
        position: relative;
    }
    
    .team-carousel-left::before {
        content: '↑';
        font-size: 1.2rem;
        display: block;
    }
    
    .team-carousel-right {
        font-size: 0;
        position: relative;
    }
    
    .team-carousel-right::before {
        content: '↓';
        font-size: 1.2rem;
        display: block;
    }
}

/* Mobile: Keep original layout (below 900px) */
@media (max-width: 900px) {
    .home-container {
        display: block;
    }
    
    .home-left,
    .home-right {
        text-align: center;
        padding: 0;
    }
    
    .home-divider {
        display: none;
    }
    
    .home-title {
        font-size: 3rem;
        text-align: center;
    }
    
    .home-title .title-line {
        display: inline;
    }
    
    .home-title .title-line:first-child::after {
        content: '';
    }
    
    .mission-statement {
        font-size: 1.1rem;
        text-align: center;
    }
    
    .home-right h3 {
        text-align: center;
        font-size: 2rem;
    }
    
    .home-right .overview-grid {
        justify-content: center;
        text-align: center;
    }
    
    .home-right .overview-item {
        text-align: center;
    }
    
    .home-right .overview-item h4,
    .home-right .overview-item p {
        text-align: center;
    }
    
    .home-right .hero-cta {
        justify-content: center;
    }
    
    /* Home Hero Background - Mobile */
    .home-hero-background {
        height: 380px;
        margin: 0;
        padding: 100px 20px 40px 20px;
        flex-direction: column;
        gap: 30px;
    }
    
    #home.content-section {
        padding-top: 0;
    }
    
    .home-hero-background .home-title {
        font-size: 1.75rem;
    }
    
    .home-hero-background .home-title::after {
        display: none;
    }
    
    .home-hero-background .mission-statement {
        font-size: 1rem;
        text-align: center;
        max-width: 100%;
    }
}

.content-section > :first-child { margin-top: 0; }
.content-section > :last-child  { margin-bottom: 0; }

/* Overview Grid Base Styles */
.overview-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
    margin: 24px 0;
}

.overview-item {
    padding: 16px;
}

.overview-item h4 {
    font-size: 1.3rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.overview-item p {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--secondary-text);
}

/* Invert text colors for home section */
#home .home-title {
    color: #000;
}

#home .mission-statement {
    color: var(--main-text);
}

#home .home-right h3 {
    color: var(--main-text);
}

#home .overview-item h4 {
    color: var(--secondary-text);
}

#home .overview-item p {
    color: var(--main-text);
}

/* Desktop: Overview grid adjustments */
@media (min-width: 901px) {
    .home-right .overview-grid {
        gap: 16px;
    }
    
    .home-right .overview-item {
        padding: 12px 20px;
    }
    
    .home-right .overview-item h4 {
        font-size: 1.4rem;
        margin-bottom: 6px;
    }
    
    .home-right .overview-item p {
        font-size: 1.1rem;
        margin-bottom: 0;
    }
}

/* Hero CTA Button Container */
.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    align-items: center;
    margin-top: 32px;
    flex-wrap: wrap;
}

/* Desktop: Reduce hero-cta margin for viewport fitting */
@media (min-width: 701px) {
    .hero-cta {
        margin-top: 16px;
        gap: 12px;
    }
}

/* Primary CTA Button (Join Us) */
.cta-button {
    display: inline-block;
    padding: 14px 32px;
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    border: 2px solid var(--call-to-action-buttons);  
    cursor: pointer;
    min-width: 160px;  
    text-align: center;  
}

.cta-button:hover {
    background-color: var(--links-accents);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

/* Secondary CTA Button (Learn More) */
.cta-button.secondary {
    background-color: transparent;
    color: var(--call-to-action-buttons);
    border: 2px solid var(--call-to-action-buttons);
    box-shadow: 0 2px 8px rgba(21, 94, 137, 0.1);
}

.cta-button.secondary:hover {
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

/* Responsive adjustments for mobile */
@media (max-width: 700px) {
    .hero-cta {
        flex-direction: column;
        gap: 12px;
        margin-top: 24px;
    }
    
    .cta-button {
        width: 100%;
        max-width: 280px;
        padding: 12px 24px;
        font-size: 1rem;
    }
    
    /* Home Hero Background - Small Mobile */
    .home-hero-background {
        height: 350px;
        margin: 0 !important;
        padding: 100px 0 0 0 !important;
    }
    
    .home-hero-background .home-title {
        display: none;
        font-size: 1.4rem;
        top: 12px;
        left: 12px;
    }
    
    .home-hero-background .mission-statement {
        top: 60px;
        width: 95%;
        max-width: none;
        font-size: 0.95rem;
        padding: 0 12px;
    }
}

.project-spacer {
    height: 1rem;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    height: 100px;
    background: var(--navigation);
    border-bottom: 2px solid #088030;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
    overflow: visible;
    flex-shrink: 0;
}

/* Desktop: Left sidebar navbar */
@media (min-width: 701px) {
    .navbar {
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        top: 0;
        left: 0;
        width: 200px;
        height: 100vh;
        border-bottom: none;
        border-right: 2px solid #088030;
        box-shadow: 2px 0 8px rgba(0, 0, 0, .3);
        display: flex;
        overflow: hidden;
    }
}

.navbar-left {
    display: flex;
    justify-content:left;
    align-items: center;
    width: auto;
    flex-shrink: 1;
    min-width: 0;
    max-width: 60%;
}

/* Desktop: Stack navbar-left vertically */
@media (min-width: 701px) {
    .navbar-left {
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        width: 100%;
        max-width: 100%;
        padding: 20px 10px;
    }
}

.navbar-left .logo {
    width: 100px;
    height: auto;
    border-radius: 25%;
    padding: 15px;
}

/* Desktop: Adjust logo for vertical navbar - 70% of navbar width */
@media (min-width: 701px) {
    .navbar-left .logo {
        width: 70%;
        max-width: 140px;
        padding: 10px;
    }
}

.navbar-left .full-title {
    font-size: 2rem;
    color: #ffffff;
    padding: 0;
    font-family: 'Merriweather', 'Georgia', serif;
}

/* Desktop: Adjust title for vertical navbar */
@media (min-width: 701px) {
    .navbar-left .full-title {
        font-size: 1.3rem;
        text-align: center;
        margin-top: 10px;
        line-height: 1.2;
    }
}

.navbar h1 {
    padding: 15px;
}

.navbar-right {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    background: var(--navigation);
    height: 100%;
    padding: 10px;
    width: auto;
    color: var(--main-text);
    overflow: visible;
    flex-shrink: 0;
    flex-grow: 1;
    min-width: 0;
}

/* Desktop: Stack navbar-right vertically */
@media (min-width: 701px) {
    .navbar-right {
        flex-direction: column;
        justify-content: flex-start;
        align-items: stretch;
        width: 100%;
        padding: 10px 0;
        flex-grow: 1;
        flex-shrink: 1;
        min-height: 0;
        overflow: hidden;
    }
}

/* Navbar footer (desktop only) */
.navbar-footer {
    display: none;
}

@media (min-width: 701px) {
    .navbar-footer {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 15px 10px;
        margin-top: auto;
        border-top: 1px solid rgba(255, 255, 255, 0.2);
        gap: 8px;
    }
    
    .navbar-copyright {
        color: rgba(255, 255, 255, 0.7);
        font-size: 0.75rem;
        margin: 0;
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    }
    
    .navbar-linkedin-link {
        display: inline-flex;
        align-items: center;
        color: rgba(255, 255, 255, 0.8);
        text-decoration: none;
        font-size: 0.8rem;
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
        transition: color 0.2s;
    }
    
    .navbar-linkedin-link:hover {
        color: var(--links-accents);
        text-decoration: underline;
    }
}

.navbar-right a {
    color: #ffffff;
    padding: 10px;
    text-decoration: none;
    white-space: nowrap;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Desktop: Style vertical nav links */
@media (min-width: 701px) {
    .navbar-right a {
        display: block;
        padding: 12px 15px;
        text-align: left;
        border-radius: 4px;
        margin: 2px 10px;
    }
}

.navbar-right a:hover {
    background: var(--call-to-action-buttons);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .2);
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}

.nav-items a {
    color: #ffffff;
    padding: 10px;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 1;
    min-width: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* Desktop: Style nav-items links for vertical layout */
@media (min-width: 701px) {
    .nav-items a {
        display: block;
        padding: 12px 15px;
        text-align: left;
        white-space: normal;
        width: 100%;
        flex-shrink: 0;
    }
}

.nav-items a:hover {
    background: var(--call-to-action-buttons);
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .2);
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.7;
    color: var(--main-text);
    background-color: var(--background);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Merriweather', 'Georgia', serif;
    font-weight: 600;
    line-height: 1.3;
}

h2 {
    font-size: 2rem;
    color: var(--secondary-text);
    margin-bottom: 15px;
    border-bottom: 2px solid var(--borders-highlights);
    padding-bottom: 10px;
}

/* Desktop: Reduce heading margins for viewport fitting */
@media (min-width: 701px) {
    h2 {
        margin-bottom: 10px;
        padding-bottom: 6px;
        font-size: 1.8rem;
    }
}

h3 {
    font-size: 1.5rem;
    color: var(--secondary-text);
    margin-bottom: 12px;
}

/* Desktop: Reduce h3 margins for viewport fitting */
@media (min-width: 701px) {
    h3 {
        margin-bottom: 8px;
        font-size: 1.3rem;
    }
}

p {
    font-size: 1rem;
    color: var(--main-text);
    line-height: 1.7;
    margin-bottom: 15px;
}

/* Desktop: Reduce paragraph margins for viewport fitting */
@media (min-width: 701px) {
    p {
        margin-bottom: 10px;
        line-height: 1.6;
    }
}

.tab-buttons {
    display: flex;
    flex-direction: row;
    gap: 10px;
    margin: 5px 0px 5px 0px;
}

.tab-button {
    background-color: var(--call-to-action-buttons);
    color: var(--main-text);
    border: none;
    padding: 12px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.tab-button:hover{ 
    background-color: var(--links-accents);
    color: var(--content-background);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, .3);
}

.tab-button.active {
    background-color: var(--links-accents);
    color: var(--content-background);
    box-shadow: 0 2px 4px rgba(0, 0, 0, .3);
}

.tab-content {
    position: relative;
    overflow: visible;
    min-height: 400px;
}

.tab-panel {
    display: none;
    width: 100%;
    background: var(--content-background);
    box-sizing: border-box;
    border-radius: 8px;
}

.tab-panel.active {
    display: block;
}

.tab-panel ul{
    list-style-type: disc;
    margin-left: 1em;
}

.tab-panel ol {
    list-style-type: decimal ;
    margin-left: 1.2em;
}


@media (max-width: 700px) {
    .content-section {
        margin: 15px 0, 100px;
        padding: 20px;
    }
    
    #home.content-section {
        margin: 0 !important;
        padding: 0 !important;
        padding-top: 0 !important;
    }
    
    .home-hero-background {
        margin: 0 !important;
        margin-top: 0 !important;
        padding: 100px 0 0 0 !important;
    }

    h2 {
        font-size: 1.8rem;
    }

    h3 {
        font-size: 1.3rem;
    }

    .tab-buttons {
        flex-direction: column;   
        align-items: stretch;     
        gap: 8px;                
    }
    .tab-button {
        width: 100%;            
        font-size: 1rem;        
        padding: 10px;           
    }
    .tab-content {
        padding: 8px;
    }
    .tab-panel {
        padding: 10px;
        font-size: 0.97rem;
        line-height: 1.5;
        word-break: break-word;
    }

    .tab-panel ul,
    .tab-panel ol {
        padding-left: 1.2em;
    }

    .navbar {
        flex-direction: row !important;
        justify-content: space-between !important;
        align-items: center !important;
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: clamp(80px, 15vw, 100px) !important;
        padding: 0;
        border-bottom: 2px solid #088030 !important;
        border-right: none !important;
        box-shadow: 0 2px 8px rgba(0, 0, 0, .3) !important;
    }

    .navbar-left {
        flex-direction: row !important;
        justify-content: left !important;
        align-items: center !important;
        width: 50%;
        max-width: 60% !important;
        padding: 0 !important;
    }

    .navbar-left .logo {
        width: clamp(80px, 15vw, 100px);
        padding: 15px;
    }
    
    .navbar .full-title {
        font-size: clamp(1.2rem, 5vw, 2rem);
        padding: 5px;
        text-align: left !important;
        margin-top: 0 !important;
    }
    
    .navbar-right {
        flex-direction: row !important;
        justify-content: flex-end !important;
        align-items: center !important;
        width: 50%;
        padding: 5px;
        flex-grow: 1 !important;
        overflow: visible !important;
    }
    
    .navbar-right a {
        padding: 4px 0 4px;
        font-size: clamp(0.5rem, 2.2vw, 1.3rem);
        display: inline !important;
        text-align: left !important;
        margin: 0 !important;
    }
    
    .nav-items {
        flex-direction: row !important;
        justify-content: flex-end !important;
        gap: 10px !important;
    }
    
    .nav-items a {
        padding: 4px 0 4px;
        font-size: clamp(0.5rem, 2.2vw, 1.3rem);
        display: inline !important;
        white-space: nowrap !important;
        width: auto !important;
    }
    
    .nav-dropdown {
        display: block !important;
    }
    
    main {
        margin-left: 0 !important;
        margin-right: 0 !important;
        padding: 0 10px !important;
        padding-top: 130px !important;
        max-width: 100% !important;
    }
    
    main:has(#home) {
        padding: 0 !important;
        padding-top: 30px !important;
    }

    

    
}


/* Contact Section Styling */
#contact {
    text-align: center;
}

#contact > p {
    font-size: 1.1rem;
    margin-bottom: 30px;
    color: var(--main-text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

#contact a {
    color: var(--call-to-action-buttons);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
    padding: 2px 4px;
}

#contact a:hover {
    color: var(--links-accents);
    border-bottom-color: var(--call-to-action-buttons);
}

#contact form {
    max-width: 600px;
    margin: 0 auto;
    padding: 30px;
    background: rgba(21, 94, 137, 0.05);
    border-radius: 12px;
    border: 2px solid var(--borders-highlights);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

#contact label {
    display: block;
    margin-bottom: 8px;
    margin-top: 15px;
    font-weight: 600;
    color: var(--secondary-text);
    text-align: left;
    font-size: 0.95rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

#contact label:first-of-type {
    margin-top: 0;
}

#contact input,
#contact textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 5px;
    border: 2px solid var(--borders-highlights);
    border-radius: 8px;
    font-size: 16px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    box-sizing: border-box;
    background-color: var(--content-background);
    color: var(--main-text);
    transition: all 0.3s ease;
}

#contact input:focus,
#contact textarea:focus {
    outline: none;
    border-color: var(--call-to-action-buttons);
    box-shadow: 0 0 8px rgba(21, 94, 137, 0.2);
    transform: translateY(-1px);
}

#contact textarea {
    min-height: 140px;
    resize: vertical;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

#contact button[type="submit"] {
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    padding: 14px 40px;
    border: 2px solid var(--call-to-action-buttons);
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

#contact button[type="submit"]:hover {
    background-color: var(--links-accents);
    border-color: var(--links-accents);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

#contact #success-message {
    color: #155724;
    background-color: #d4edda;
    border: 2px solid #c3e6cb;
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    font-weight: 500;
}

#contact #error-message {
    color: #721c24;
    background-color: #f8d7da;
    border: 2px solid #f5c6cb;
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    font-weight: 500;
}

/* Footer - Mobile only */
footer {
    display: none;
    flex-shrink: 0;
}

@media (max-width: 700px) {
    footer {
        display: block;
        margin-top: auto;
        padding: 20px;
        background-color: var(--navigation);
        color: #ffffff;
        text-align: center;
        border-radius: 8px 8px 0 0;
    }
    
    footer p {
        color: #ffffff;
        margin: 5px 0;
    }
}

.linkedin-link {
    display: inline-flex;
    align-items: center;
    color: #ffffff;
    text-decoration: none;
    font-weight: 500;
    margin-top: 10px;
    transition: color 0.2s;
}

.linkedin-link:hover {
    color: var(--links-accents);
    text-decoration: underline;
}

.nav-items {
    display: flex;
    gap: 10px;
    flex-wrap: nowrap;
    overflow: visible;
    max-width: 100%;
    width: 100%;
    justify-content: flex-end;
}

/* Desktop: Stack nav items vertically */
@media (min-width: 701px) {
    .nav-items {
        flex-direction: column;
        gap: 5px;
        justify-content: flex-start;
        width: 100%;
        overflow: visible;
    }
}

/* Mobile: Hide nav-items when dropdown is active */
@media (max-width: 840px) {
    .nav-items:empty {
        display: none;
    }
}

.nav-dropdown {
    position: relative;
    display: block;
    padding: 10px;
}

/* Desktop: Hide dropdown on vertical navbar */
@media (min-width: 701px) {
    .nav-dropdown {
        display: none;
    }
}

/* Navbar dropdown for subsections - BASE STYLES */
.nav-item-with-dropdown {
    position: relative;
}

/* .nav-main-link inherits styles from .nav-items a */

.nav-subsection-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    background-color: var(--content-background);
    border: 2px solid var(--borders-highlights);
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
    z-index: 1001;
    margin-top: 0;
    overflow: hidden;
    pointer-events: none;
}

.nav-item-with-dropdown:hover .nav-subsection-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.nav-subsection-dropdown a {
    display: block;
    padding: 10px 15px;
    color: var(--main-text);
    text-decoration: none;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.95rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    transition: background-color 0.2s, color 0.2s;
}

.nav-subsection-dropdown a:last-child {
    border-bottom: none;
}

.nav-subsection-dropdown a:hover {
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
}

/* Desktop: Adjust dropdown for vertical navbar - show below within sidebar */
@media (min-width: 701px) {
    .nav-item-with-dropdown {
        width: 100%;
    }
    
    .nav-subsection-dropdown {
        position: static;
        left: auto;
        top: auto;
        width: 100%;
        min-width: 100%;
        margin: 0;
        transform: none;
        border: none;
        border-radius: 0;
        box-shadow: none;
        background-color: transparent;
        max-height: 0;
        opacity: 0;
        overflow: hidden;
        transition: max-height 0.3s ease, opacity 0.3s ease;
    }
    
    .nav-item-with-dropdown:hover .nav-subsection-dropdown {
        max-height: 500px;
        opacity: 1;
    }
    
    .nav-subsection-dropdown a {
        padding: 10px 15px 10px 30px;
        text-align: left;
        font-size: 0.9rem;
        background-color: rgba(0, 0, 0, 0.15);
        border-left: 3px solid var(--links-accents);
    }
}

.dropdown-toggle {
    background: var(--call-to-action-buttons);
    color: var(--main-text);
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    margin-left: 10px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.dropdown-toggle:hover {
    background: var(--links-accents);
    color: var(--content-background);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--navigation);
    border: 1px solid var(--borders-highlights);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .3);
    min-width: 150px;
    display: none;
    z-index: 10000;
}

.dropdown-menu.show {
    display: block;
}

.dropdown-menu a {
    display: block;
    padding: 10px 15px;
    color: #ffffff;
    text-decoration: none;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.dropdown-menu a:hover {
    background: var(--call-to-action-buttons);
}

.rotated-full-image {
    transform: rotate(-90deg);
    width: 30%;
    height: auto;
    margin: 0 auto 200px auto;
    border: 1px solid var(--secondary-text);
    background-color: var(--content-background);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
    display: block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.rotated-full-image:hover {
    transform: rotate(-90deg) scale(1.02);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .4);
}

.full-image {
    width: 30%;
    height: auto;
    margin: 0 auto 200px auto;
    border: 1px solid var(--secondary-text);
    background-color: var(--content-background);
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .3);
    display: block;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.full-image:hover {
    transform: scale(1.02); 
    box-shadow: 0 4px 12px rgba(0, 0, 0, .4);
}


.section-hero {
    width: 100%;
    max-height: 360px;
    object-fit: cover;
    border-radius: 12px;
    margin: 24px 0 32px 0;
    box-shadow: 0 4px 16px rgba(0,0,0,.12);
}

/* Desktop: Reduce section-hero margins for viewport fitting */
@media (min-width: 701px) {
    .section-hero {
        margin: 12px 0 16px 0;
        max-height: 280px;
    }
}


.media-block { 
    display: grid;
    grid-template-columns: 1.1fr 1fr; 
    gap: 24px;
    align-items: stretch; 
    margin: 16px 0; 
}

/* Desktop: Reduce media-block margins for viewport fitting */
@media (min-width: 701px) {
    .media-block {
        margin: 8px 0;
        gap: 16px;
    }
}


.media-block .content h2 {
    margin-bottom: 8px;
    padding-bottom: 6px;
}

.media-block + h3 {
    margin-top: 16px;
}

.media-block.reverse {
    grid-template-columns: 1fr 1.1fr; 
}

.media-block .media {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.media-block .media img {
    max-width: 100%;
    width: auto;
    max-height: 60%;
    height: auto;
    object-fit: contain;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0,0,0,.12);
}

.media-block .content {
    display: flex;
    flex-direction: column;
    justify-content: center; 
    gap: 12px;
    padding: 50px;
}

/* Desktop: Reduce media-block content padding for viewport fitting */
@media (min-width: 701px) {
    .media-block .content {
        padding: 20px 30px;
        gap: 8px;
    }
}

@media (max-width: 1700px) {
    .content-section {
        max-width: 80%;
    }
}

@media (max-width: 1300px) {
    .content-section {
        max-width: 90%;
    }
}

@media (max-width: 1100px) {
    .content-section {
        max-width: 100%;
    }
}

@media (max-width: 900px) {
    .media-block,
    .media-block.reverse,
    .subsection .media-block {
        grid-template-columns: 1fr !important;
        align-items: start; 
    }
    .media-block .content,
    .media-block .media,
    .subsection .media-block .content,
    .subsection .media-block .media {
        height: auto; 
    }
    .media-block .content {
        justify-content: flex-start;
    }
    .media-block .media img {
        max-width: 60%;
        transform: rotate(-90deg);
    }
    
    /* Keep horizontal images horizontal */
    .media-block.keep-horizontal .media img {
        transform: rotate(0deg);
        max-width: 100%;
    }
    /* Content section max-width is set in earlier media query */
    .media-block .content{
        padding: 10px;
    }
}

@media (max-width: 600px) {
    .content-section {
        max-width: 100%;
    }
    .media-block .content{
        padding: 10px;
    }
}

.rotate {
    transform: rotate(-90deg);
}

/* Community Activities Event List System */
.events-container {
    display: flex;
    gap: 24px;
    min-height: 400px;
}

/* Desktop: 30/70 split layout */
@media (min-width: 901px) {
    .events-container {
        flex-direction: row;
    }
    
    .events-list-panel {
        width: 30%;
        display: flex;
        flex-direction: column;
        border-right: 2px solid var(--borders-highlights);
        padding-right: 20px;
    }
    
    .event-details-panel {
        width: 70%;
        padding-left: 20px;
    }
}

/* Mobile: Vertical stacking */
@media (max-width: 900px) {
    .events-container {
        flex-direction: column;
    }
    
    .events-list-panel {
        width: 100%;
        order: 1;
    }
    
    .event-details-panel {
        width: 100%;
        order: 2;
        margin-top: 20px;
    }
}

/* Event List Panel */
.events-list-panel {
    display: flex;
    flex-direction: column;
    position: relative;
}

.event-arrow {
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-size: 18px;
    cursor: pointer;
    transition: background-color 0.2s, opacity 0.2s;
    z-index: 10;
    flex-shrink: 0;
}

.event-arrow:hover:not(:disabled) {
    background-color: var(--links-accents);
}

.event-arrow:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Desktop: Vertical carousel */
@media (min-width: 901px) {
    .events-list-wrapper {
        flex: 1;
        overflow-y: auto;
        overflow-x: hidden;
        scroll-behavior: smooth;
        scrollbar-width: thin;
        min-height: 0;
    }
    
    .events-list-wrapper::-webkit-scrollbar {
        width: 6px;
    }
    
    .events-list-wrapper::-webkit-scrollbar-track {
        background: transparent;
    }
    
    .events-list-wrapper::-webkit-scrollbar-thumb {
        background: rgba(0, 0, 0, 0.2);
        border-radius: 3px;
    }
    
    .events-list {
        list-style: none;
        padding: 0;
        margin: 0;
    }
    
    .event-item {
        padding: 16px;
        margin-bottom: 8px;
        background-color: var(--content-background);
        border: 2px solid var(--borders-highlights);
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.2s ease;
    }
    
    .event-item:hover {
        background-color: rgba(21, 94, 137, 0.1);
        border-color: var(--links-accents);
        transform: translateX(4px);
    }
    
    .event-item.active {
        background-color: var(--call-to-action-buttons);
        color: var(--content-background);
        border-color: var(--call-to-action-buttons);
    }
    
    .event-item-title {
        font-weight: 600;
        font-size: 1.1rem;
        margin-bottom: 4px;
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    }
    
    .event-item-date {
        font-size: 0.9rem;
        color: var(--secondary-text);
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    }
    
    .event-item.active .event-item-date {
        color: rgba(255, 255, 255, 0.9);
    }
}

/* Mobile: Horizontal carousel */
@media (max-width: 900px) {
    .events-list-panel {
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }
    
    .event-arrow {
        padding: 12px 8px;
        font-size: 20px;
    }
    
    /* Change arrow symbols to left/right on mobile */
    .event-arrow-up {
        font-size: 0;
        position: relative;
    }
    
    .event-arrow-up::before {
        content: '←';
        font-size: 20px;
        display: block;
    }
    
    .event-arrow-down {
        font-size: 0;
        position: relative;
    }
    
    .event-arrow-down::before {
        content: '→';
        font-size: 20px;
        display: block;
    }
    
    .events-list-wrapper {
        flex: 1;
        overflow-x: auto;
        overflow-y: hidden;
        scroll-behavior: smooth;
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
        -ms-overflow-style: none;
    }
    
    .events-list-wrapper::-webkit-scrollbar {
        display: none;
    }
    
    .events-list {
        list-style: none;
        padding: 0;
        margin: 0;
        display: flex;
        flex-direction: row;
        gap: 12px;
    }
    
    .event-item {
        padding: 12px 16px;
        background-color: var(--content-background);
        border: 2px solid var(--borders-highlights);
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.2s ease;
        flex-shrink: 0;
        min-width: 200px;
        scroll-snap-align: start;
    }
    
    .event-item:hover {
        background-color: rgba(21, 94, 137, 0.1);
        border-color: var(--links-accents);
    }
    
    .event-item.active {
        background-color: var(--call-to-action-buttons);
        color: var(--content-background);
        border-color: var(--call-to-action-buttons);
    }
    
    .event-item-title {
        font-weight: 600;
        font-size: 1rem;
        margin-bottom: 4px;
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    }
    
    .event-item-date {
        font-size: 0.85rem;
        color: var(--secondary-text);
        font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    }
    
    .event-item.active .event-item-date {
        color: rgba(255, 255, 255, 0.9);
    }
}

/* Event Details Panel */
.event-details-panel {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.event-details-content {
    padding: 20px;
}

.event-details-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--main-text);
    font-family: 'Merriweather', 'Georgia', serif;
}

.event-details-date {
    font-size: 1.1rem;
    color: var(--secondary-text);
    margin-bottom: 20px;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.event-details-description {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--main-text);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.event-details-description p {
    margin-bottom: 12px;
}

/* Projects List Layout */
.projects-list {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-top: 24px;
}

.project-item {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    padding: 24px;
    background-color: var(--content-background);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.project-item:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, .15);
    transform: translateY(-2px);
}

.project-image {
    flex: 0 0 300px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.project-image img {
    width: 100%;
    height: auto;
    max-height: 250px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .1);
}

.project-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.project-content h3 {
    margin: 0 0 8px 0;
    color: var(--secondary-text);
    font-size: 1.5rem;
    line-height: 1.3;
}

.project-content p {
    margin: 0;
    line-height: 1.7;
    color: var(--main-text);
}

/* Legacy project-preview styles (kept for backwards compatibility if needed) */
.project-preview {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 24px;
    align-items: center;
    padding: 20px;
    background-color: var(--content-background);
    border-radius: 8px;
}

.project-preview-image {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.project-preview-image img {
    width: 100%;
    height: auto;
    max-height: 450px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .15);
}

.project-preview-text {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.project-preview-text h4 {
    margin: 0;
    color: var(--secondary-text);
    font-size: 1.5rem;
}

.project-preview-text p {
    margin: 0;
    line-height: 1.6;
}

.learn-more-btn {
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.3s ease;
    width: fit-content;
}

.learn-more-btn:hover {
    background-color: var(--links-accents);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .3);
}

.modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 10001;
    overflow-y: auto;
    padding: 20px;
    animation: fadeIn 0.3s ease;
}

.modal-overlay.show {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 50px;
}

.modal-container {
    position: relative;
    background-color: var(--background);
    max-width: 900px;
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, .4);
    animation: slideUp 0.4s ease;
    margin-bottom: 50px;
    overflow: hidden;
}

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

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--call-to-action-buttons);
    color: var(--content-background);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    z-index: 10002;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close:hover {
    background-color: var(--links-accents);
    transform: rotate(90deg);
}

.modal-content {
    padding: 60px 40px 40px 40px;
    max-height: 80vh;
    overflow-y: auto;
    border-radius: 12px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.modal-content h2 {
    color: var(--secondary-text);
    margin-bottom: 20px;
    font-size: 2rem;
}

.modal-content h3 {
    color: var(--secondary-text);
    margin-top: 24px;
    margin-bottom: 12px;
    font-size: 1.5rem;
}

.modal-content h4 {
    color: var(--secondary-text);
    margin-top: 16px;
    margin-bottom: 8px;
    font-size: 1.25rem;
}

.modal-content p {
    line-height: 1.7;
    margin-bottom: 12px;
}

html {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.modal-content ul,
.modal-content ol {
    margin-left: 1.5em;
    margin-bottom: 16px;
}

/* Modal Image Carousel */
.modal-image-carousel {
    margin-top: 40px;
    padding-top: 30px;
    border-top: 2px solid var(--borders-highlights);
}

.modal-image-carousel h3 {
    margin-bottom: 20px;
    color: var(--secondary-text);
}

.image-carousel-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.image-tab-button {
    padding: 10px 20px;
    background-color: var(--call-to-action-buttons);
    color: var(--content-background);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

.image-tab-button:hover {
    background-color: var(--links-accents);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.image-tab-button.active {
    background-color: var(--links-accents);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.image-carousel-content {
    position: relative;
    min-height: 300px;
}

.image-carousel-panel {
    display: none;
    width: 100%;
}

.image-carousel-panel.active {
    display: block;
    animation: fadeIn 0.4s ease;
}

.image-carousel-panel img {
    width: 100%;
    height: auto;
    max-height: 600px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.image-carousel-intro {
    margin-bottom: 20px;
    color: var(--main-text);
    font-style: italic;
}

.image-description {
    margin-top: 15px;
    padding: 12px;
    background-color: rgba(21, 94, 137, 0.1);
    border-left: 3px solid var(--call-to-action-buttons);
    border-radius: 4px;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Read Bio Button */
.read-bio-btn {
    margin-top: 15px;
    padding: 10px 20px;
    background: var(--call-to-action-buttons);  /* Change this */
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.read-bio-btn:hover {
    background: var(--links-accents);  /* Change this */
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(83, 150, 121, 0.3);
}

/* Bio Modal Specific Styles */
.bio-modal-container {
    max-width: 700px;
}

.bio-modal-header {
    display: flex;
    gap: 25px;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid var(--accent-color);
}

.bio-modal-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.bio-modal-title h2 {
    margin: 0 0 8px 0;
    color: var(--main-text-color);
    font-size: 1.8rem;
}

.bio-modal-role {
    color: var(--accent-color);
    font-weight: 600;
    font-size: 1.1rem;
    margin: 0;
}

.bio-modal-body p {
    margin-bottom: 20px;
    line-height: 1.8;
    color: var(--main-text-color);
    font-size: 1rem;
}

.bio-modal-body p:last-child {
    margin-bottom: 0;
}

/* Responsive adjustments for modal image carousel */
@media (max-width: 600px) {
    .image-carousel-tabs {
        flex-direction: column;
    }
    
    .image-tab-button {
        width: 100%;
    }
    
    .image-carousel-panel img {
        max-height: 400px;
    }
    
    /* Bio Modal Mobile Adjustments */
    .bio-modal-header {
        flex-direction: column;
        text-align: center;
    }
    
    .bio-modal-image {
        width: 100px;
        height: 100px;
    }
    
    .bio-modal-title h2 {
        font-size: 1.5rem;
    }
    
    .bio-modal-role {
        font-size: 1rem;
    }
}

@media (max-width: 950px) {
    /* Projects List - Tablet/Small Desktop */
    .project-image {
        flex: 0 0 250px;
    }
    
    .project-content h3 {
        font-size: 1.3rem;
    }
}

@media (max-width: 800px) {
    /* Projects List - Mobile/Tablet Stacked */
    .project-item {
        flex-direction: column;
        gap: 20px;
        padding: 20px;
    }
    
    .project-image {
        flex: 0 0 auto;
        width: 100%;
    }
    
    .project-image img {
        max-height: 200px;
    }
    
    .learn-more-btn {
        width: 100%;
        text-align: center;
    }
}

@media (max-width: 700px) {
    /* Projects List - Small Mobile adjustments */
    .project-item {
        padding: 16px;
    }
}

@media (max-width: 900px) {
    
    /* Legacy project-preview - Mobile */
    .project-preview {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .project-preview-image img {
        max-height: 250px;
    }
}

@media (max-width: 700px) {
    .modal-content {
        padding: 50px 20px 20px 20px;
    }
    
    .modal-close {
        top: 10px;
        right: 10px;
        width: 35px;
        height: 35px;
        font-size: 24px;
    }
    
    .learn-more-btn {
        width: 100%;
        text-align: center;
    }
}

/* Mobile: Override for small screens and dropdown menu */
@media (max-width: 700px) {
    /* When NOT in dropdown menu, keep hover behavior */
    .nav-item-with-dropdown {
        position: relative;
    }
    
    .nav-subsection-dropdown {
        left: 0;
        top: 100%;
        min-width: 160px;
        margin-top: 0;
        margin-left: 0;
    }
    
    .nav-subsection-dropdown a {
        padding: 8px 12px;
        font-size: 0.85rem;
        white-space: nowrap;
    }
}

/* Dropdown menu specific styles (when items are inside .dropdown-menu) */
@media (max-width: 840px) {
    /* When inside dropdown menu, make it full width and click-based */
    .dropdown-menu .nav-item-with-dropdown {
        width: 100%;
        margin: 0;
    }
    
    /* Style the main link in dropdown menu */
    .dropdown-menu .nav-main-link {
        display: block;
        padding: 10px 15px;
        color: #ffffff;
        text-decoration: none;
        border-bottom: 1px solid var(--borders-highlights);
        cursor: pointer;
        position: relative;
    }
    
    .dropdown-menu .nav-main-link:hover {
        background-color: rgba(255, 255, 255, 0.1);
    }
    
    .dropdown-menu .nav-subsection-dropdown {
        position: static;
        display: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        border-radius: 0;
        margin: 0;
        padding: 0;
        background-color: rgba(0, 0, 0, 0.3);
        min-width: 100%;
        max-width: 100%;
        width: 100%;
        pointer-events: auto;
    }
    
    /* Disable hover behavior UNLESS expanded */
    .dropdown-menu .nav-item-with-dropdown:not(.expanded):hover .nav-subsection-dropdown {
        display: none !important;
    }
    
    /* When expanded, always show regardless of hover */
    .dropdown-menu .nav-item-with-dropdown.expanded .nav-subsection-dropdown {
        display: block !important;
    }
    
    .dropdown-menu .nav-subsection-dropdown a {
        display: block;
        padding: 12px 15px 12px 35px;
        font-size: 0.9rem;
        white-space: normal;
        color: #ffffff;
        text-decoration: none;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        transition: background-color 0.2s;
    }
    
    .dropdown-menu .nav-subsection-dropdown a:last-child {
        border-bottom: none;
    }
    
    .dropdown-menu .nav-subsection-dropdown a:hover {
        background-color: var(--call-to-action-buttons);
        color: var(--content-background);
    }
    
    /* Add indicator arrow to main link when in dropdown */
    .dropdown-menu .nav-main-link::after {
        content: ' ▶';
        font-size: 0.8rem;
        transition: transform 0.3s ease;
        display: inline-block;
        margin-left: 8px;
    }
    
    .dropdown-menu .nav-item-with-dropdown.expanded .nav-main-link::after {
        transform: rotate(90deg);
    }
}