/**
 * Antra Team Flip Card - Style 3
 * Horizontal flip (rotates on Y axis)
 */

/* =============================================
   Flip Card Container
   Higher specificity to override theme styles
   ============================================= */

li.team-style-3 .team-block.team-flipcard-wrapper {
    perspective: 1200px;
    overflow: visible;
    background: transparent;
    border: none;
    box-shadow: none;
}

li.team-style-3 .team-block.team-flipcard-wrapper .team-flipcard-inner {
    position: relative;
    width: 100%;
    transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    transform-style: preserve-3d;
}

/* Trigger flip on hover */
li.team-style-3 .team-block.team-flipcard-wrapper:hover .team-flipcard-inner {
    transform: rotateY(180deg);
}

/* =============================================
   Front & Back Faces (shared)
   ============================================= */

li.team-style-3 .team-flipcard-front,
li.team-style-3 .team-flipcard-back {
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
}

/* =============================================
   Front Face
   ============================================= */

li.team-style-3 .team-flipcard-front {
    position: relative;
    z-index: 2;
}

/* Ensure no overflow hidden from theme on parent elements */
li.team-style-3 .team-flipcard-front .team-transition {
    overflow: visible;
}

/* =============================================
   Back Face - absolute over front
   ============================================= */

li.team-style-3 .team-flipcard-back {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    transform: rotateY(180deg);
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #1a1a2e;
    color: #ffffff;
    overflow: hidden;
    box-sizing: border-box;
}

/* =============================================
   Back Face Inner Content
   ============================================= */

li.team-style-3 .team-flipcard-back .team-flipcard-back-inner {
    padding: 30px 25px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    height: 100%;
    width: 100%;
    overflow-y: auto;
    box-sizing: border-box;
}

/* Back - Title */
li.team-style-3 .team-flipcard-back .team-loop-title {
    margin-bottom: 5px;
}

li.team-style-3 .team-flipcard-back .team-loop-title a {
    color: inherit;
    text-decoration: none;
}

li.team-style-3 .team-flipcard-back .team-loop-title a:hover {
    opacity: 0.8;
}

/* Back - Job */
li.team-style-3 .team-flipcard-back .team-loop-job {
    opacity: 0.8;
    margin-bottom: 15px;
}

/* Back - Biography */
li.team-style-3 .team-flipcard-back .team-bio {
    opacity: 0.9;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 0.9em;
}

li.team-style-3 .team-flipcard-back .team-bio p {
    margin: 0 0 10px;
}

li.team-style-3 .team-flipcard-back .team-bio p:last-child {
    margin-bottom: 0;
}

/* Back - Social icons */
li.team-style-3 .team-flipcard-back .object_socials_list {
    list-style: none;
    padding: 0;
    margin: 10px 0 0;
    display: flex;
    gap: 12px;
    justify-content: center;
}

li.team-style-3 .team-flipcard-back .object_socials_list a {
    color: inherit;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

li.team-style-3 .team-flipcard-back .object_socials_list a:hover {
    opacity: 1;
}

/* =============================================
   Touch device support
   ============================================= */

li.team-style-3 .team-block.team-flipcard-wrapper:focus-within .team-flipcard-inner {
    transform: rotateY(180deg);
}

/* =============================================
   Accessibility: reduced motion
   ============================================= */

@media (prefers-reduced-motion: reduce) {
    li.team-style-3 .team-block.team-flipcard-wrapper .team-flipcard-inner {
        transition: none;
    }
}
