/* Reseteo básico */
.how-work-content {
    background-color: #000;
    color: #fff;
    line-height: 2; /* Mayor separación entre líneas para legibilidad */
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Altura completa de la ventana */
    padding: 20px;
}

.how-work-container {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    max-width: 1600px; /* Ancho máximo del contenedor */
    width: 100%;
    gap: 60px; /* Mayor separación entre texto e imagen */
    opacity: 0; /* Comienza invisible */
    transform: translateY(30px); /* Desplazado hacia abajo */
    animation: fadeIn 1.5s ease-out forwards; /* Animación de aparición */
}

.how-work-text-section {
    flex: 1.2; /* El texto ocupa más espacio relativo */
    max-width: 50%; /* Ancho máximo del texto */
    text-align: left; /* Alineación a la izquierda */
}

.how-work-text-section h1 {
    color: #fdd835; /* Amarillo */
    margin-bottom: 20px;
    font-size: 2.5rem; /* Tamaño del título */
}

.how-work-text-section p {
    margin-bottom: 20px; /* Más espacio entre párrafos */
    font-size: 1.4rem; /* Tamaño del texto */
}

.how-work-image-section {
    flex: 1;
    max-width: 45%; /* Imagen ligeramente más grande */
    display: flex;
    justify-content: center;
    align-items: center;
}

.how-work-image-section img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.5); /* Sombra para un mejor diseño */
}

/* Animación de aparición */
@keyframes fadeIn {
    to {
        opacity: 1; /* Totalmente visible */
        transform: translateY(0); /* Posición original */
    }
}

/* Responsividad */
@media (max-width: 1024px) {
    .how-work-container {
        flex-direction: column; /* Cambia a diseño vertical */
        gap: 30px; /* Menor separación */
        margin-top: 60px;
    }

    .how-work-text-section {
        max-width: 90%; /* Ancho completo para texto */
    }

    .how-work-image-section {
        max-width: 90%; /* Ancho completo para imagen */
    }

    .how-work-text-section h1 {
        font-size: 2rem; /* Tamaño del título reducido */
    }

    .how-work-text-section p {
        font-size: 1.2rem; /* Tamaño del texto reducido */
    }
}

@media (max-width: 768px) {
    .how-work-text-section h1 {
        font-size: 1.8rem; /* Tamaño del título más pequeño */
    }

    .how-work-text-section p {
        font-size: 1rem; /* Tamaño del texto reducido */
    }
}

/* Estilos Generales */
.how-work-calidad {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #1A1A1A; /* Fondo oscuro */
    display: flex;
    justify-content: center;
    align-items: center; /* Alineado hacia la parte superior */
    min-height: 100vh;
    overflow-y: auto; /* Permite desplazamiento vertical */
}

/* Contenedor general */
.fases-calidad-content-wrapper {
    max-width: 90%;
    margin: 0 auto;
    padding: 20px;
    text-align: center;
}

/* Estilos del encabezado de texto */
.fases-calidad-header-text {
    color: #D4AF37; /* Color dorado */
    text-align: left;
    margin: 0px 80px 40px;
}

.fases-calidad-header-text h1 {
    font-size: 36px;
    font-weight: bold;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6); /* Sombra para legibilidad */
}

.fases-calidad-header-text p {
    font-size: 18px;
    line-height: 1.6;
    color: #fff;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.4); /* Sombra sutil */
}

.fases-calidad-container {
    display: flex;
    gap: 40px; /* Espacio entre tarjetas */
    justify-content: center;
    align-items: center; /* Alinea los elementos de la parte superior */
    flex-wrap: wrap; /* Responsividad */
    position: relative;
}

/* Barra de progreso */
.fases-calidad-progress-bar {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 4px;
    background-color: #1A1A1A;
    z-index: -1;
    transition: background-color 0.4s ease, left 0.8s ease, width 0.8s ease;
}

/* Ocultar barra de progreso en pantallas pequeñas */
@media (max-width: 768px) {
    .fases-calidad-progress-bar {
        display: none;
    }
}

.fases-calidad-progress-bar.visible {
    background-color: #1A1A1A;
}

.fases-calidad-progress-bar .fases-calidad-indicator {
    height: 100%;
    background-color: #D4AF37; /* Color dorado para la barra de progreso */
    width: 0%; /* La barra comienza en 0% */
    transition: width 1s ease;
}

/* Estilos de las tarjetas */
.fases-calidad-card {
    width: 22rem; /* Ancho fijo de las tarjetas */
    height: 30rem; /* Altura fija */
    background-color: #212121; /* Fondo oscuro para las tarjetas */
    border-radius: 1.5rem;
    border: #212121 0.2rem solid;
    transition: all 0.5s ease-in-out;
    box-shadow: 0.6rem 0.6rem 1rem #00000080;
    text-align: center;
    cursor: pointer;
    overflow: hidden;
    position: relative;
}

.fases-calidad-card:hover {
    transform: translateY(-3rem); /* Desplazamiento al hacer hover */
    border: #D4AF37 0.3em solid; /* Borde dorado al hacer hover */
    border-radius: 2.5rem 0 2.5rem 0; /* Borde redondeado diferente al hacer hover */
}

.fases-calidad-card:active {
    transform: scale(0.95) rotateZ(1.7deg); /* Efecto de escala y rotación */
}

/* Estilos del encabezado de las tarjetas */
.fases-calidad-card-header {
    padding: 15px 0;
    color: #D4AF37; /* Color dorado */
    font-weight: bold;
    font-size: 24px; /* Aumento del tamaño de fuente */
    position: relative;
    z-index: 2;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.6); /* Sombra para mejorar legibilidad */
}

/* Estilos del contenido de las tarjetas */
.fases-calidad-card-content {
    padding: 20px;
    font-size: 20px; /* Aumento del tamaño de fuente */
    line-height: 1.8;
    position: relative;
    z-index: 1;
    color: #fff; /* Color de texto blanco */
}

.fases-calidad-card-title {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px; /* Aumento del tamaño del título */
    margin-bottom: 15px;
    height: 80px;
    font-weight: bold;
    color: #D4AF37; /* Título en dorado */
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5); /* Sombra sutil */
}

.fases-calidad-card-content p {
    color: #fff;
    font-size: 18px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.4); /* Sombra para el texto */
}

/* Estilo de la tarjeta seleccionada */
.selected {
    border-color: #D4AF37; /* Borde dorado */
    transform: scale(1.05); /* Aumento sutil del tamaño */
}

/* Estilo para ocultar y mostrar las tarjetas seleccionadas */
.fases-calidad-card.hidden {
    opacity: 0.3;
    transform: scale(0.95);
    pointer-events: none;
    transition: all 0.3s ease-out; /* Transición acelerada para ocultar tarjetas */
}

/* Estilos para pantallas pequeñas (responsivo) */
@media (max-width: 768px) {
    .fases-calidad-container {
        padding: 45px 0 80px;
        gap: 20px; /* Menos espacio entre tarjetas */
        flex-direction: column; /* Apilar las tarjetas verticalmente */
        align-items: center; /* Centrar las tarjetas */
    }

    .fases-calidad-content-wrapper {
        padding-top: 60px;
    }
    

    .fases-calidad-header-text {
        margin: 0px 30px;
    }

    .fases-calidad-card {
        width: 90%; /* Ajusta el tamaño de las tarjetas a un porcentaje */
        max-width: 28rem; /* Limitar el tamaño máximo de las tarjetas */
        height: 480px; /* Altura automática para mantener las proporciones */
        margin-bottom: 20px; /* Espaciado entre las tarjetas */
    }

    .fases-calidad-card-header {
        font-size: 20px; /* Reducir tamaño del encabezado */
    }

    .fases-calidad-card-title {
        font-size: 18px; /* Reducir tamaño del título */
    }

    .fases-calidad-card-content {
        max-width: 90%; /* Aumentar el ancho del contenido */
        margin: 0 auto; /* Centrar el contenido */
    }
    .fases-calidad-card-content p {
        font-size: 16px; /* Reducir tamaño del contenido */
    }


    /* Añadir un efecto de zoom a la tarjeta tocada (solo para pantallas pequeñas) */
    .fases-calidad-card.zoomed {
        transform: scale(1.1); /* Aumento del tamaño de la tarjeta */
        z-index: 2; /* Asegura que la tarjeta tocada esté encima de las demás */
        transition: transform 0.3s ease-in-out;
    }
}

/* Configuración general */
.soms-container {
    background-color: #000000; /* Fondo negro */
    color: #E6E6E6; /* Texto gris claro */
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    flex-direction: column;
    overflow-x: hidden;
}

/* Contenedor */
.how-soms-container {
    width: 90%;
    max-width: 1200px;
    margin: 40px 0;
    text-align: left;
}

/* Título principal */
.how-soms-container h1 {
    font-size: 2.5rem; /* Tamaño relativo */
    color: #D4AF37; /* Dorado */
    margin-bottom: 1.25rem;
    font-weight: 700;
}

/* Descripción contextual */
.how-soms-container p {
    font-size: 1.125rem; /* Tamaño relativo */
    line-height: 1.6;
    color: #E6E6E6; /* Gris claro */
    margin-bottom: 2.5rem;
}

/* Tarjetas */
.how-soms-cards {
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    flex-wrap: wrap;
    margin-bottom: 2.5rem;
}

/* Animación de aparición */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Tarjeta */
.how-soms-card {
    position: relative;
    background-color: #1C1C1C; /* Negro suave */
    border: 2px solid #D4AF37; /* Borde dorado */
    border-radius: 12px;
    width: 20rem; /* Ajustar en base a diseño */
    height: 23.75rem; /* Ajustar en base a diseño */
    box-shadow: 0 6px 12px rgba(212, 175, 55, 0.2);
    overflow: hidden;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s ease;
    opacity: 0; /* Comienza invisible */
    animation: fadeInUp 1s forwards; /* Aparece con el efecto */
}

/* Efecto hover */
.how-soms-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 24px rgba(212, 175, 55, 0.4);
    background-color: rgba(212, 175, 55, 0.1); /* Dorado tenue */
}

/* Insignia circular con números */
.how-soms-circle {
    position: absolute;
    top: -1.25rem;
    left: 50%;
    transform: translateX(-50%);
    width: 5rem; /* Tamaño ajustado */
    height: 5rem; /* Tamaño ajustado */
    background-color: #D4AF37; /* Dorado */
    font-weight: bold;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.3);
}

.how-soms-circle p {
    padding-top: 1rem; /* Ajuste de espaciado */
    color: #FFFFFF; /* Blanco */
    font-size: 2rem; /* Ajuste relativo */
}

/* Contenido de la tarjeta */
.how-soms-card-content {
    margin-top: 4rem; /* Asegura separación de la insignia */
    padding: 1.25rem;
    color: #E6E6E6; /* Texto gris claro */
}

.how-soms-card-content h3 {
    color: #D4AF37; /* Título dorado */
    margin-bottom: 1rem;
    font-size: 1.375rem; /* Ajuste relativo */
    font-weight: 600;
}

.how-soms-card-content p {
    color: #E6E6E6; /* Gris claro */
    font-size: 1rem; /* Ajuste relativo */
    line-height: 1.6;
}

/* Diseño responsivo */
@media screen and (max-width: 768px) {
    .soms-container{
        height: auto;
    }

    .how-soms-card  {
        height: auto;
        padding: 10px;
    }

    .how-soms-cards {
        gap: 1.25rem;
    }

    .how-soms-card {
        width: 22rem; /* Ajuste de tamaño */
        height: 22rem; /* Ajuste de tamaño */
    }

    .how-soms-circle {
        padding-top: 30px;
    }

    .how-soms-card-content h3 {
        font-size: 1.25rem;
    }

    .how-soms-card-content p {
        font-size: 1rem;
    }
}

@media screen and (max-width: 480px) {
    .how-soms-card  {
        padding: 10px;
    }

    .how-soms-cards {
        gap: 1rem;
    }

    .how-soms-card {
        width: 18rem; /* Ajuste de tamaño */
        height: 20rem; /* Ajuste de tamaño */
    }

    .how-soms-circle {
        width: 4.5rem; /* Ajuste en pantallas pequeñas */
        height: 4.5rem; /* Ajuste en pantallas pequeñas */
    }

    .how-soms-circle p {
        font-size: 1.5rem; /* Ajuste en pantallas pequeñas */
    }

    .how-soms-card-content h3 {
        font-size: 1.125rem;
    }

    .how-soms-card-content p {
        font-size: 0.875rem;
    }
}

/* Estilos generales */
.team-leaders {
    font-family: 'Arial', sans-serif;
    background-color: #1f1f1f;
    color: white;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    flex-direction: column;
    line-height: 1.6;
}

.how-team-greetings-container {
    text-align: left;
    max-width: 1490px;
    margin: 0 auto;
    padding: 20px 320px 20px 20px;
}

.how-team-greetings-container h1 {
    color: #D4AF37;
    margin-bottom: 20px;
    font-size: 2.8rem;
    font-weight: bold;
}

.how-team-greetings-container p {
    font-size: 21px;
}

/* Estilos de la sección de tarjetas */
.how-team-container {
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
    padding: 20px;
    overflow-x: auto;
    gap: 20px;
}

.how-team-card {
    width: 350px;
    height: 500px;
    background: #333333;
    border-radius: 32px;
    padding: 3px;
    position: relative;
    box-shadow: 0px 70px 30px -50px rgba(96, 75, 74, 0.188);
    transition: all 0.5s ease-in-out;
    color: white;
    overflow: hidden;
    font-size: 1rem;
}

.how-team-card .how-team-profile-pic {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 3px;
    left: 3px;
    border-radius: 29px;
    z-index: 1;
    overflow: hidden;
    transition: all 0.5s ease-in-out;
}

.how-team-card .how-team-profile-pic img {
    object-fit: cover;
    width: 100%;
    height: 100%;
}

.how-team-card .how-team-bottom {
    position: absolute;
    bottom: 3px;
    left: 3px;
    right: 3px;
    background: #444444;
    top: 80%;
    border-radius: 29px;
    z-index: 2;
    box-shadow: rgba(96, 75, 74, 0.1882352941) 0px 5px 5px 0px inset;
    overflow: hidden;
    padding: 20px;
    transition: all 0.5s ease-in-out;
}

.how-team-card .how-team-bottom .how-team-content {
    color: white;
    max-height: 350px;
    overflow-y: auto;
    scrollbar-width: none;
}

.how-team-card .how-team-bottom .how-team-content::-webkit-scrollbar {
    display: none;
}

.how-team-card .how-team-bottom .how-team-content h3 {
    font-size: 2rem;
    font-weight: bold;
    margin: 20px 0;
    line-height: 1.4;
}

.how-team-card .how-team-bottom .how-team-content p {
    font-size: 1rem;
    margin-top: 1rem;
    line-height: 1.6;
}

.how-team-card .how-team-bottom .how-team-content p:first-of-type {
    color: #FFD700;
    font-weight: bold;
}

.how-team-card:hover {
    border-top-left-radius: 55px;
}

.how-team-card:hover .how-team-bottom {
    top: 20%;
    border-radius: 80px 29px 29px 29px;
    transition: all 0.5s ease-in-out 0.2s;
}

.how-team-card:hover .how-team-profile-pic {
    width: 120px;
    height: 120px;
    aspect-ratio: 1;
    top: 10px;
    left: 10px;
    border-radius: 50%;
    z-index: 3;
    border: 5px solid white;
    box-shadow: rgba(0, 0, 0, 0.8) 0px 0px 15px 5px;
    transition: all 0.5s ease-in-out;
}

/* Estilos para la instrucción (solo visible en pantallas pequeñas) */
.how-team-instructions {
    text-align: center;
    font-size: 10px;
    color: #D4AF37; /* Color dorado similar al que usas para el cargo */
    margin: 0;
    display: none; /* Ocultar por defecto */
    opacity: 0.5; /* Menos opacidad para hacerlo menos prominente */
}

/* Estilos para pantallas pequeñas */
@media screen and (max-width: 768px) {
    .team-leaders {
        height: auto;
    }

    .how-team-instructions {
        display: block; /* Mostrar en dispositivos con pantallas pequeñas */
    }
    
    .how-team-greetings-container {
        padding: 20px 40px;
    }

    .how-team-greetings-container h1 {
        font-size: 2.4rem;
    }
    
    .how-team-greetings-container p {
        font-size: 18px;
    }

    /* Ajustes para las tarjetas */
    .how-team-container {
        justify-content: center; /* Centrar las tarjetas en pantallas pequeñas */
        gap: 15px; /* Reducir el espacio entre tarjetas */
    }

    .how-team-card {
        width: 320px; /* Reducir el tamaño de las tarjetas */
        height: 480px; /* Reducir la altura de las tarjetas */
    }

    .how-team-card .how-team-bottom {
        padding: 15px; /* Reducir padding en la parte inferior */
    }

    .how-team-card .how-team-bottom .how-team-content h3 {
        font-size: 1.7rem; /* Reducir el tamaño del nombre */
    }

    .how-team-card .how-team-bottom .how-team-content p {
        font-size: 0.9rem; /* Reducir el tamaño de los textos */
    }

    .how-team-card .how-team-bottom .how-team-content p:first-of-type {
        font-size: 1rem; /* Asegurarse de que el cargo esté ligeramente destacado */
    }
}