/* Team Section Styles */
.team__section {
    padding: 5rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    box-sizing: border-box;
    background-color: #ffffff;
}

.team__title {
    text-transform: uppercase;
    position: relative;
    z-index: 1;
    margin: 2em auto 1.3em auto;
    width: 100%;
    color: #fff;
    text-align: center;
    /* font-size inherited from h2 in main.css */
}

.team__title::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgb(189 208 255);
    width: 100vw;
    height: 30px;
    opacity: 0.8;
    z-index: -1;
}

.team__grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    width: 100%;
}

.team__card {
    flex: 0 1 280px; /* Base width for each card */
    background-color: #ffffff;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}   


@media (max-width: 768px) {
    .team__grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns on tablets */
    }
    
}

@media (max-width: 480px) {
    .team__grid {
        grid-template-columns: 1fr; /* Stack on mobile */
    }
}


.team__img-container {
    width: 100%;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    position: relative;
    background-color: #f4f4f4; /* Placeholder color before image loads */
    overflow: hidden;
}

.team__img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Ensures image covers area without distortion */
    filter: grayscale(100%); /* Black and white filter */
    transition: transform 0.5s ease, filter 0.5s ease;
}



/* Mirror the first team member's image */
.team__card:first-child .team__img {
    transform: scaleX(-1);
}


.team__content {
    padding: 1rem; /* Reduced padding */
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.team__name {
    font-size: 2.2rem; 
    color: #1e367b;
    margin-bottom: 0.3rem;
    font-weight: 600;
}

.team__role {
    font-size: 1.3rem; /* Reduced font size */
    color: #666;
    margin-bottom: 0.8rem;
    font-style: italic;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.team__desc {
    font-size: 1.1rem; /* Reduced font size */
    line-height: 1.4;
    color: #444;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.team__email {
    font-size: 1.3rem; /* Reduced font size */
    color: #1e367b;
    margin-bottom: 1rem;
    font-weight: 500;
    text-decoration: none;
}



@media (max-width: 768px) {
    .team__email {
        font-size: 0.8em;
    }
    
}

.team__btn {
    background-color: transparent;
    color: #1e367b;
    border: none;
    padding: 0.6rem 2rem; 
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.3s ease, transform 0.2s ease;
    border-radius: 5px;
    width: 13px;
}


.team__img[src*="LogoID.png"] {
    object-fit: contain;
    padding: 1rem; /* Reduced padding */
    background-color: #ffffff;
}

@media (max-width: 768px) {
    .team__section {
        padding: 2rem 1rem !important;
    }

    .team__grid {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem !important; /* Minimal gap */
    }

    .team__card {
        flex: 0 1 100px; /* Small fixed width for phone centering */
        border-radius: 1px; /* Smaller Border Radius */
    }

    .team__img-container {
        padding-top: 100%; /* Keep 1:1 Aspect Ratio */
    }

    .team__img[src*="LogoID.png"] {
        padding: 0.2rem !important;
    }

    .team__content {
        padding: 0.5rem !important; /* Minimal padding */
    }

    .team__name {
        font-size: 0.8rem !important; /* Micro size */
        margin-bottom: 0.2rem;
    }


    @media (max-width: 768px) {
        
        .team__role 
        {
            font-size: 0.8rem !important;
            margin-bottom: 0.3rem;
        }
    
    
}

    .team__desc {
        display: none !important; /* Hide description to minimize space */
    }


    .team__btn {
        padding: 0.2rem 0.5rem !important;
        font-size: 0.7rem !important;
        margin-top: 0.2rem;
    }
}
