/* Team section styling */
.team-grid {
    margin-top: var(--spacing-xl);
}

.team-member {
    display: flex;
    background-color: var(--background-medium);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.25);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: var(--spacing-xl);
}

.team-member:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

.team-photo {
    flex: 0 0 220px; /* Fixed width */
    background-color: var(--background-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.team-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%; /* Focus on face/upper body */
}

.photo-placeholder {
    width: 100%;
    height: 100%;
    min-height: 320px; /* Set minimum height */
    background-color: var(--background-light);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--secondary-text);
    font-weight: 500;
}

.team-info {
    flex: 1;
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left; /* Left-align text */
}

.team-title {
    color: var(--accent-blue);
    font-weight: 500;
    margin-bottom: var(--spacing-md);
}

.team-bio {
    font-size: 0.95rem;
    color: var(--secondary-text);
}

/* Advisory Committee Styles - Using same style as team members */
.advisory-grid {
    margin-top: var(--spacing-xl);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xl);
}

.advisor {
    display: flex;
    background-color: var(--background-medium);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.25);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.advisor:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

.advisor-photo {
    flex: 0 0 220px; /* Match team photo size */
    background-color: var(--background-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.advisor-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 30%;
}

.photo-placeholder.advisor-placeholder {
    min-height: 320px; /* Match team photo height */
}

.advisor-info {
    flex: 1;
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left;
}

.advisor-info h3 {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.advisor-title {
    color: var(--accent-blue);
    font-weight: 500;
    font-size: 0.95rem;
    margin-bottom: var(--spacing-md);
}

.advisor-bio {
    font-size: 0.95rem;
    color: var(--secondary-text);
    line-height: 1.6;
}

/* Responsive adjustments */
@media (max-width: 1100px) {
    .team-photo, .advisor-photo {
        flex: 0 0 200px; /* Adjusted for smaller screens */
    }
}

@media (max-width: 992px) {
    .advisory-grid {
        gap: var(--spacing-lg);
    }
}

@media (max-width: 768px) {
    .team-member, .advisor {
        flex-direction: column;
    }
    
    .team-photo, .advisor-photo {
        flex: 0 0 auto;
        width: 100%;
        /* Increased fixed height to maintain aspect ratio better */
        height: 350px;
    }
    
    .photo-placeholder, .photo-placeholder.advisor-placeholder {
        min-height: 250px;
    }
    
    .team-info, .advisor-info {
        padding: var(--spacing-lg);
    }
    
    .team-info h3, .advisor-info h3, 
    .team-title, .advisor-title {
        text-align: center; /* Center only the headings/titles on mobile */
    }
    
    .team-bio, .advisor-bio {
        text-align: left; /* Keep bios left-aligned even on mobile */
    }
}

/* Additional mobile fixes for iPhone and other small screens */
@media (max-width: 576px) {
    .advisory-grid {
        gap: var(--spacing-md);
    }
    
    /* Fix for smushed photos on iPhone */
    .team-photo, .advisor-photo {
        height: 400px;
        position: relative;
    }
    
    .team-photo img, .advisor-photo img {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        object-position: top center; /* Focus more on the face */
    }
}