/* Team layout */
.team-layout {
    height: 100vh;                      /* Full viewport height */
    overflow-y: auto;                   /* allow vertical scroll*/
    padding: 1rem 6rem 4rem 6rem;       /* top, right, bottom, left */
}
/* Fit for smart screens */
@media (max-width: 992px) {
    .team-layout {
        padding: 1rem 2.5rem 4rem 2.5rem;  /* usa 5% del ancho de la pantalla como margen lateral */
    }
}
/* Page title */
.team-title {
    font-size: 4rem;                    /* Large text size for visibility */
    font-weight: 700;                   /* Bold text */
    color: #1E1E1E;                     /* Dark gray text color */
    margin: 0 auto 2rem auto;           /* Center horizontally and add top/bottom space */
    text-align: center;                 /* Center the title */
    display: block;                     /* Ensure full-width block behavior */
}
/* Title section */
.team-title-section {
    width: 100%;                        /* Take full width of the page */
    display: flex;                      /* Use flex for robust centering */
    justify-content: center;            /* Center horizontally */
    align-items: center;                /* Center vertically within the section */
    padding: 1.5rem 3.5rem 0.5rem 3.5rem;   /* Padding around the title */
    margin-bottom: 0;                   /* Space below the title section */
}
/* Wrapper for Each Section (Title + Content) */
.team-content-section{
    display: flex; /* Horizontal layout for wide screens */
    justify-content: space-between; /* Space between title and content */
    align-items: flex-start; /* Aligns items to the top */
    margin: 2rem auto 3rem auto;  /* Top and bottom spacing, center horizontally */
    flex-wrap: wrap; /* Allows wrapping for smaller screens */
}


/* Section Title */
.team-section-title {
    width: 100%;
    font-size: 2.2rem; /* Large, clear title size */
    font-weight: 700; /* Bold title text */
    color: #111111; /* Dark gray text for contrast */
    letter-spacing: -0.02em;           /* ligera apertura para elegancia */
    display: block;
    margin-bottom: 0.8rem;
}
.team-section-subtitle {
    width: 100%;
    font-size: 1.5rem;                  /* Slightly larger than body text */
    font-weight: 600;                   /* Normal weight */
    color: #333333;                        /* Medium gray for contrast */
    letter-spacing: 0.01em;           /* sutil apertura */
    margin-top: 1rem;                 /* menos separación que el título */
    margin-bottom: 0.8rem;
    display: block;
    border-bottom: 1px solid #d9d9d9; /* más ligera que el título */
    font-style: italic;
    padding-bottom: 0.2rem;
}
/* Section Content (Members List) */
.team-section-content{
    font-size: 1.1rem; /* Slightly larger than default text */
    color: #333; /* Neutral dark text for readability */
}

/* === Team Member Name === */
.team-member-name{
    font-weight: 600; /* Slightly bold for emphasis */
    color: #555555; /* Same dark gray as title for consistency */
    font-size: 1.2rem; /* Slightly larger text for names */
    margin-bottom: 0.6rem;
    letter-spacing: 0.01rem;      /* Ligeramente más aireado */
}
.team-name-photo {
    font-weight: 600; /* Slightly bold for emphasis */
    color: #555555; /* Same dark gray as title for consistency */
    font-size: 1.2rem; /* Slightly larger text for names */
    margin-bottom: 0.6rem;
    display: block;
    letter-spacing: 0.01rem;      /* Ligeramente más aireado */
}
/* === Team Member Profession === */
.team-member-profession{
    font-style: italic; /* Italic to differentiate profession */
    color: #444; /* Slightly lighter gray for subtle contrast */
    font-size: 1rem;
    line-height: 1.4;
}
/* === Team Member University === */
.team-member-university{
    color: #555; /* Medium gray for neutral tone */
    font-size: 1rem; /* Standard text size */
    line-height: 1.4;
}
/* === Team Member University === */
.team-member-info{
    color: #555; /* Medium gray for neutral tone */
    font-size: 1rem; /* Standard text size */
    white-space: pre-line;        /* Interpret \n as line breaks */
    line-height: 1.4;
}
/* === Team Member University === */
.team-member-email{
    color: #0056b3;
    font-weight: 500;
    text-decoration: underline;
    cursor: pointer;
    font-size: 1rem; /* Standard text size */
}
.team-member-email:hover {
    color: #003d80;
}
/* Individual Team Member */
.team-member{
    margin-bottom: 0.8rem; /* Space between members */
    display: flex;
    flex-direction: column;
}
.team-photo {
    flex: 0 0 160px;              /* ancho fijo */
    height: 160px;
    object-fit: cover;            /* recorta sin distorsionar */
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 2px solid #f0f0f0;
    background-color: white;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.team-photo:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}
.team-info-photo {
    flex: 1;
    display: flex;
    flex-direction: column;
}
.team-member-photo {
    display: flex;
    flex-direction: row;          /* foto izquierda, texto derecha */
    align-items: flex-start;
    gap: 1.2rem;                  /* espacio entre foto y texto */
    margin-bottom: 1rem;
}
/* Responsive for small screens */
@media (max-width: 768px) {
    .team-section-title {
        font-size: 1.6rem; /* Slightly smaller title for mobile */
        margin-bottom: 0.5rem; /* Space below title */
    }
    .team-photo {
        width: 200px;
        height: 200px;
        margin-bottom: 0.8rem;
        display: block;
        margin-left: auto;
        margin-right: auto; /* centra solo la imagen */
    }
    .team-member-photo {
        flex-direction: column;  /* apila imagen y texto */
        align-items: stretch;    /* deja que el texto use todo el ancho */
        text-align: left;        /* texto alineado a la izquierda por defecto */
        gap: 0.8rem;             /* separación entre foto y texto */
    }
    .team-name-photo{
        text-align: center;
        width: 100%;
        display: block;
    }
    /* Title section */
    .team-title-section {
        padding: 1.5rem 0 0.5rem 0;   /* Padding around the title */
    }
    .team-content-section {
        flex-direction: column; /* Stack title and content vertically */
        gap: 1rem; /* Reduce space between stacked elements */
        justify-content: flex-start;
        align-items: stretch;
    }
    .team-info-photo {
        align-items: flex-start; /* alinea a la izquierda */
        text-align: left;
        padding-left: 0;
        margin-left: 0;
        width: 100%;
    }
}
