/* =========================================================
   HIGH VOLTAGE
   EL EQUIPO
   Sustituye al bloque "WHO" (.who) de styles.css
   ========================================================= */

.hv-team {
    position: relative;
    background-color: #000;
    color: #fff;
    padding: 110px 0 120px;
    overflow: hidden;
}

.hv-team .wrapper-main {
    max-width: 1180px;
}


/* =========================
   INTRO (mismo esquema que "Entrena en grupo")
   ========================= */

.hv-team__intro {
    display: grid;
    grid-template-columns: 1.3fr .7fr;
    gap: 60px;
    align-items: end;
    margin-bottom: 70px;
}

.hv-team__title {
    display: flex;
    flex-direction: column;

    font-size: 7.5rem;
    line-height: .78;
    letter-spacing: -.02em;

    color: #fff;
}

.hv-team__title span:last-child {
    color: var(--rojo);
}

.hv-team__lead {
    max-width: 380px;
    padding-bottom: 10px;

    font-family: 'Roboto', sans-serif;
    font-size: 1.3rem;
    font-weight: 400;
    line-height: 1.45;

    color: #e6e6e6;
}


/* =========================
   REJILLA: dos fichas iguales
   ========================= */

.hv-team__grid {
    position: relative;

    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}


/* =========================
   FICHA QUE GIRA
   ========================= */

.hv-team__card {
    position: relative;
    perspective: 1800px;
}

.hv-team__inner {
    position: relative;
    aspect-ratio: 4 / 5;

    transform-style: preserve-3d;
    transition: transform .8s cubic-bezier(.22, .61, .36, 1);
}

.hv-team__card.is-flipped .hv-team__inner {
    transform: rotateY(180deg);
}

@media (hover: hover) {
    .hv-team__card:hover .hv-team__inner {
        transform: rotateY(180deg);
    }
}

.hv-team__face {
    position: absolute;
    inset: 0;
    overflow: hidden;

    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* Botón invisible encima de toda la ficha */
.hv-team__toggle {
    position: absolute;
    inset: 0;
    z-index: 3;

    width: 100%;
    cursor: pointer;
    background: transparent;
    border: 0;
}

.hv-team__toggle:focus-visible {
    outline: 3px solid #fff;
    outline-offset: 4px;
}


/* =========================
   DELANTE: FOTO + NOMBRE
   ========================= */

.hv-team__front {
    background-color: var(--rojo);
}

.hv-team__photo {
    position: absolute;
    inset: 0;
    margin: 0;
}

.hv-team__photo img {
    display: block;
    width: 100%;
    height: 100%;

    object-fit: cover;
    object-position: center top;
}

/* Iniciales de reserva si todavía no hay foto */
.hv-team__photo.is-empty::before {
    content: attr(data-initials);

    position: absolute;
    inset: 0 0 25% 0;

    display: flex;
    align-items: center;
    justify-content: center;

    font-family: 'Bebas Neue', cursive;
    font-size: 11rem;
    line-height: 1;

    color: rgba(0, 0, 0, .25);
}

/* Degradado para que el nombre se lea sobre la foto */
.hv-team__front::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, .9) 0%, rgba(0, 0, 0, .55) 28%, rgba(0, 0, 0, 0) 55%);
    pointer-events: none;
}

.hv-team__badge {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 2;

    padding: 0 30px 26px;
}

.hv-team__role {
    display: inline-block;
    margin-bottom: 12px;
    padding: 5px 12px 4px;

    font-family: 'Roboto', sans-serif;
    font-size: .85rem;
    font-weight: 700;
    letter-spacing: .04em;

    color: #fff;
    background-color: var(--rojo);
}

.hv-team__name {
    display: flex;
    flex-direction: column;

    font-size: 5rem;
    line-height: .82;
    letter-spacing: -.01em;

    color: #fff;
}

/* Aviso "Experiencia" arriba a la derecha */
.hv-team__hint {
    position: absolute;
    top: 18px;
    right: 18px;
    z-index: 2;

    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 12px 6px 9px;

    font-family: 'Roboto', sans-serif;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .03em;

    color: #fff;
    background-color: #000;
}

.hv-team__hint svg {
    width: 15px;
    height: 15px;

    fill: none;
    stroke: currentColor;
    stroke-width: 2.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}


/* =========================
   DETRÁS: EXPERIENCIA
   ========================= */

.hv-team__back {
    transform: rotateY(180deg);

    display: flex;
    flex-direction: column;
    justify-content: flex-end;

    padding: 40px 34px 34px;

    background-color: var(--rojo);
    overflow-y: auto;
}

.hv-team__back .hv-team__role {
    align-self: flex-start;
    background-color: #000;
}

.hv-team__back-name {
    margin-bottom: 26px;

    font-size: 3.8rem;
    line-height: .85;

    color: #fff;
}

.hv-team__facts {
    list-style: none;
    margin: 0;
    padding: 0;

    border-top: 2px solid #fff;
}

.hv-team__facts li {
    padding: 14px 0;

    font-family: 'Roboto', sans-serif;
    font-size: 1rem;
    line-height: 1.45;

    color: #fff;
    border-bottom: 1px solid rgba(255, 255, 255, .35);
}

.hv-team__facts strong {
    display: block;

    font-size: 2.1rem;
    font-weight: 400;
    line-height: .95;
}


/* =========================
   RAYO ENTRE LAS DOS FICHAS
   ========================= */

.hv-team__rayo {
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 5;

    width: 92px;
    height: auto;

    transform: translate(-50%, -50%);
    pointer-events: none;

    fill: var(--rojo);
    stroke: #000;
    stroke-width: 4;
    stroke-linejoin: round;
}


/* =========================
   MOVIMIENTO REDUCIDO
   ========================= */

@media (prefers-reduced-motion: reduce) {
    .hv-team__inner {
        transition: none;
    }
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 1000px) {

    .hv-team__title {
        font-size: 6rem;
    }

    .hv-team__intro {
        grid-template-columns: 1fr .8fr;
        gap: 35px;
    }

    .hv-team__name {
        font-size: 3.8rem;
    }

    .hv-team__badge {
        padding: 0 22px 20px;
    }

    .hv-team__back {
        padding: 30px 24px 24px;
    }

    .hv-team__back-name {
        font-size: 3rem;
    }

    .hv-team__facts li {
        font-size: .92rem;
        padding: 11px 0;
    }

    .hv-team__facts strong {
        font-size: 2rem;
    }

    .hv-team__rayo {
        width: 72px;
    }
}


/* =========================================================
   MÓVIL
   ========================================================= */

@media (max-width: 768px) {

    .hv-team {
        padding: 80px 0 100px;
    }

    .hv-team__intro {
        display: block;
        margin-bottom: 50px;
    }

    .hv-team__title {
        font-size: 5.5rem;
        margin-bottom: 35px;
    }

    .hv-team__lead {
        font-size: 1.15rem;
    }

    .hv-team__grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    /* El rayo pasa a separar las dos fichas */
    .hv-team__rayo {
        position: relative;
        left: auto;
        top: auto;

        display: block;
        width: 60px;
        margin: -30px auto -30px;

        transform: none;
    }
}


/* =========================================================
   MÓVIL PEQUEÑO
   ========================================================= */

@media (max-width: 550px) {

    .hv-team {
        padding: 65px 0 85px;
    }

    .hv-team__title {
        font-size: 4.7rem;
        line-height: .8;
    }

    .hv-team__name {
        font-size: 3.6rem;
    }

    .hv-team__badge {
        padding: 0 20px 18px;
    }

    .hv-team__back {
        padding: 24px 20px 20px;
    }

    .hv-team__back-name {
        font-size: 2.6rem;
        margin-bottom: 16px;
    }

    .hv-team__facts li {
        font-size: .88rem;
        padding: 9px 0;
    }

    .hv-team__facts strong {
        font-size: 1.6rem;
    }
}