.about-grid {
    display: grid;
    grid-template-columns: 2.2fr 1fr;
    gap: 2rem;
    margin-bottom: 2.5rem;
}
.about-card {
    border-radius: 28px;
    padding: 1.8rem 2rem;
    border: 1px solid #deecf5;
    max-height: 500px;
    overflow: auto;
    scrollbar-width: thin;
}
.lab-card {
    border-radius: 28px;
    padding: 1.8rem 2rem;
    border: 1px solid #deecf5;
    overflow: auto;
    scrollbar-width: thin;
}
.about-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--secondary-color);
    margin-bottom: 1.2rem;
}
.about-title i {
    background: #004c7e;
    color: white;
    border-radius: 50%;
    padding: 8px;
    font-size: 1.2rem;
}
.about-card p {
    margin-bottom: 1rem;
    font-size: 0.98rem;
}
.partners-panel {
    background: white;
    border-radius: 28px;
    padding: 1.5rem 1.8rem;
    border: 1px solid #dbe9f2;
    box-shadow: 0 4px 12px rgba(0, 30, 60, 0.03);
}
.partners-panel h3 {
    font-size: 1.2rem;
    border-left: 4px solid #136b9c;
    padding-left: 1rem;
    margin-bottom: 1.2rem;
}
.partner-item {
    display: flex;
    align-items: center;
    gap: 2px;
    padding: 0.8rem 0;
    border-bottom: 1px dashed #cee2ef;
}
.partner-item i {
    width: 28px;
    color: #1c6c9f;
}

/* staff grid */
.section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 2.5rem 0 1.2rem;
}
.section-head h2 {
    font-size: 1.7rem;
    font-weight: 600;
    color: var(--secondary-color);
}
.section-head i {
    color: #346a8c;
    background: #e3f0fa;
    padding: 8px 12px;
    border-radius: 40px;
}
.staff-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1.2rem;
    margin-bottom: 2.2rem;
}
.staff-card {
    background: white;
    border-radius: 24px;
    padding: 1.2rem 0.8rem 0.8rem 1rem;
    border: 1px solid #d3e6f2;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
    transition: 0.2s;
}
.staff-card:hover {
    border-color: #87b9db;
}
.staff-name {
    font-weight: 700;
    font-size: 1rem;
}
.staff-role {
    font-size: 0.8rem;
    color: #567e9c;
    background: #ecf5fa;
    display: inline-block;
    padding: 0.2rem 0.8rem;
    border-radius: 20px;
    margin: 6px 0 4px;
}
.staff-icon {
    font-size: 1.8rem;
    color: #417eac;
    margin-bottom: 0.2rem;
}
.img-cell {
    flex: 0 0 85px;
    height: 125px;
    margin: 6px 6px 6px 6px;
    border-radius: 50%;
    background: #e7dbcf;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.05), inset 0 2px 4px #fff8ee;
    border: 3px solid #f5ebe2;
}

.img-cell img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    background: #cdb9a8;  /* warm fallback */
}

/* if image fails or is not set, we show an elegant initial */
.img-cell img[alt] {
    background: #bdaa99;
}

/* labs + equipment */
.lab-equip-row {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 1.8rem;
    margin: 2rem 0;
}
.lab-showcase {
    background: var(--light-color);
    border-radius: 30px;
    padding: 1.5rem 1.8rem;
}
.lab-showcase h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
}
.lab-icons {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    align-items: center;
}
.lab-icons span {
    background: white;
    padding: 0.4rem 1.2rem 0.4rem 1rem;
    border-radius: 40px;
    font-weight: 500;
    display: flex;
    gap: 8px;
    box-shadow: 0 2px 6px #cbdae6;
}
.equip-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem 1.2rem;
}
.equip-item {
    background: white;
    border-radius: 60px;
    padding: 0.6rem 1rem 0.6rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid #cddeec;
    font-weight: 500;
}
.equip-item i {
    background: #11537c;
    color: white;
    border-radius: 50%;
    padding: 4px;
    font-size: 0.7rem;
}

/* projects area — intramural / extramural */
.projects-tabs {
    display: flex;
    gap: 2.5rem;
    border-bottom: 2px solid #cee4f0;
    padding-bottom: 0.6rem;
    margin: 2.2rem 0 1.2rem;
}
.tab-active {
    font-weight: 700;
    color: #003459;
    border-bottom: 3px solid #d6436e;
    padding-bottom: 0.4rem;
}
.tab {
    color: #537b99;
    font-weight: 500;
}

.project-list {
    display: block;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.7rem 2rem;
    max-height: 450px;
    overflow-y: auto;
    padding-right: 1rem;
    background: #f9fdfe;
    border-radius: 24px;
    padding: 1.2rem 1.8rem;
}
.project-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #d3e2ed;
    padding: 0.4rem 0;
    font-size: 0.9rem;
}
.project-title {
    font-weight: 500;
}
.project-badge {
    font-size: 0.7rem;
    background: #d7ecdc;
    color: #05633e;
    padding: 0.2rem 0.8rem;
    border-radius: 40px;
}
.ongoing {
    background: #fff2d9;
    color: #a36100;
}
hr {
    border: none;
    border-top: 2px dotted #b7d3e7;
}
.projects-section {
    background: var(--light-color);
    border-radius:30px; 
    padding:1.5rem;
}
.projects-section-tabs {
    display:flex; 
    gap:15px; 
    align-items:center; 
    margin-bottom:1rem;
}


/* ----- About, Staff, & Labs Responsive ----- */

/* Tablets (Under 992px) */
@media (max-width: 992px) {
    .about-grid, 
    .lab-equip-row {
        grid-template-columns: 1fr; /* Stack sidebars/panels */
        gap: 1.5rem;
    }

    .about-card, 
    .lab-card {
        max-height: none; /* Allow content to flow naturally on tablets */
    }

    .equip-grid {
        grid-template-columns: 1fr 1fr; /* Keep 2 columns for equipment */
    }
}

/* Large Mobile (Under 768px) */
@media (max-width: 768px) {
    .section-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.8rem;
    }

    .staff-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 0.8rem;
    }

    /*.img-cell {
        flex: 0 0 70px;
        height: 100px; /* Scale down profile images */
        margin: 0 auto 10px; /* Center images on mobile */
    }*/

    .staff-card {
        text-align: center;
        padding: 1.2rem 0.5rem;
    }

    .projects-tabs {
        gap: 1.2rem;
        overflow-x: auto; /* Allow tabs to scroll if they get too long */
        padding-bottom: 0.8rem;
        -webkit-overflow-scrolling: touch;
    }

    .project-list {
        padding: 1rem;
    }

    .project-item {
        flex-direction: column; /* Stack project title and status badge */
        align-items: flex-start;
        gap: 6px;
        padding: 0.8rem 0;
    }
}

/* Small Mobile (Under 480px) */
@media (max-width: 480px) {
    .about-title {
        font-size: 1.3rem;
    }

    .about-card, .lab-card, .partners-panel, .projects-section, .lab-showcase {
        padding: 1.2rem; /* Reduce bulkiness */
        border-radius: 20px;
    }

    .equip-grid {
        grid-template-columns: 1fr; /* Equipment list goes single column */
    }

    .lab-icons {
        gap: 0.8rem;
    }

    .lab-icons span {
        width: 100%; /* Badges take full width */
        justify-content: center;
    }

    .staff-grid {
        grid-template-columns: 1fr 1fr; /* Two small columns for staff */
    }

    .staff-name {
        font-size: 0.9rem;
    }

    .staff-role {
        font-size: 0.7rem;
    }
}
