/* General Styles */
.team-slider-section-v2 {
    font-family: 'Vazirmatn', sans-serif;
    direction: rtl;
    padding: 60px 20px;
    background-color: #f8f9fa;
    overflow: hidden;
}

.container-v2 {
    max-width: 1300px;
    margin: 0 auto;
    position: relative;
}

.section-title-v2 {
    text-align: center;
    font-size: 36px;
    font-weight: 700;
    color: #212529;
    margin-bottom: 10px;
}

.section-subtitle-v2 {
    text-align: center;
    font-size: 16px;
    color: #6c757d;
    margin-bottom: 50px;
}

/* Slider Wrapper */
.slider-wrapper-v2 {
    position: relative;
    width: 100%;
    margin: 0 auto;
}

.slider-v2 {
    display: flex;
    overflow-x: hidden; /* Hide horizontal scrollbar */
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    scroll-behavior: smooth;
    width: 100%;
}

.slide-item-v2 {
    flex: 0 0 100%; /* Default to 1 item per slide (mobile) */
    max-width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 15px; /* Padding for spacing between slides */
    box-sizing: border-box;
    scroll-snap-align: start;
}

.slide-content-v2 {
    display: flex;
    flex-direction: column; /* Default to stacked on mobile */
    background-color: #ffffff;
    border-radius: 18px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.07);
    overflow: hidden;
    max-width: 550px; /* Max width for content on mobile */
    width: 100%;
    transition: all 0.4s ease-in-out;
}

.member-image-v2 {
    width: 100%;
    height: 380px; /* Fixed height for image */
    overflow: hidden;
}

    .member-image-v2 img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        display: block;
    }

.member-info-v2 {
    padding: 30px;
    text-align: center;
}

    .member-info-v2 h3 {
        font-size: 28px;
        font-weight: 700;
        color: #2c3e50;
        margin-bottom: 5px;
    }

.position-v2 {
    display: block;
    font-size: 15px;
    color: #5b6df6;
    font-weight: 600;
    margin-bottom: 15px;
}

.bio-v2 {
    font-size: 15px;
    color: #6c757d;
    line-height: 1.8;
    margin-bottom: 25px;
}

.social-links-v2 {
    display: flex;
    justify-content: center;
    gap: 15px;
}

    .social-links-v2 a {
        color: #6c757d;
        font-size: 20px;
        transition: color 0.3s ease;
    }

        .social-links-v2 a:hover {
            color: #5b6df6;
        }

/* Slider Navigation */
.slider-nav-v2 {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
    gap: 15px;
}

.nav-btn-v2 {
    background-color: #ffffff;
    color: #343a40;
    border: none;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: background-color 0.3s ease, color 0.3s ease;
}

    .nav-btn-v2:hover {
        background-color: #5b6df6;
        color: #ffffff;
    }

.slider-dots-v2 {
    display: flex;
    gap: 10px;
}

.dot-v2 {
    width: 12px;
    height: 12px;
    background-color: #dee2e6;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

    .dot-v2.active {
        background-color: #5b6df6;
    }

/* Desktop Styles */
@media (min-width: 769px) {
    .slide-item-v2 {
        flex: 0 0 calc(25% - 30px); /* 4 items per slide, minus gap */
        max-width: calc(25% - 30px);
        margin: 0 15px; /* Add margin for gap */
    }

    .slider-wrapper-v2 {
        padding: 0 50px; /* Space for navigation buttons */
    }

    .slider-v2 {
        overflow: visible; /* Allow buttons to be outside */
    }

    .slide-content-v2 {
        flex-direction: row; /* Side-by-side on desktop */
        max-width: none; /* Remove max-width */
        align-items: center; /* Vertically align content */
    }

    .member-image-v2 {
        width: 50%; /* Image takes half the width */
        height: auto; /* Auto height to fit content */
        min-height: 450px; /* Minimum height */
    }

        .member-image-v2 img {
            height: 100%; /* Ensure image fills container */
        }

    .member-info-v2 {
        width: 50%; /* Info takes the other half */
        text-align: left; /* Align text left on desktop */
    }

    .bio-v2 {
        text-align: justify; /* Justify text */
    }

    .social-links-v2 {
        justify-content: flex-start; /* Align social links to the left */
    }

    .slider-nav-v2 {
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        transform: translateY(-50%);
        margin-top: 0;
        justify-content: space-between; /* Push buttons to edges */
        z-index: 10;
    }

    .nav-btn-v2.prev-v2 {
        position: relative; /* Override absolute */
        left: -20px; /* Position outside the slider wrapper */
    }

    .nav-btn-v2.next-v2 {
        position: relative; /* Override absolute */
        right: -20px; /* Position outside the slider wrapper */
    }

    .slider-dots-v2 {
        display: none; /* Hide dots on desktop, use buttons */
    }
}

/* Larger Desktop */
@media (min-width: 1200px) {
    .slide-item-v2 {
        flex: 0 0 calc(25% - 30px);
        max-width: calc(25% - 30px);
    }

    .member-image-v2 {
        min-height: 500px;
    }
}

/* Adjustments for specific icons if needed */
.fab.fa-telegram { /* You might need to adjust these based on Font Awesome versions */
    /* font-family: 'Font Awesome 5 Brands'; */
}

.fab.fa-whatsapp {
    /* font-family: 'Font Awesome 5 Brands'; */
}


/* Add Font Awesome CDN link in your HTML <head> */
/* <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css"> */

/* Mobile Styles (Default) */
.slide-item-v2 {
    flex: 0 0 100%; /* One slide per view */
    max-width: 100%;
    padding: 0 15px;
    box-sizing: border-box;
}

.slider-wrapper-v2 {
    width: 100%;
    max-width: 550px; /* Limit width on mobile */
    margin: 0 auto;
    padding: 0; /* No horizontal padding needed inside wrapper if items have padding */
}

.slider-v2 {
    /* Base styles handled above */
}

.slide-content-v2 {
    flex-direction: column; /* Stacked on mobile */
    align-items: center;
}

.member-image-v2 {
    width: 100%;
    height: 380px; /* Fixed height */
}

.member-info-v2 {
    width: 100%;
    text-align: center;
}

.slider-nav-v2 {
    margin-top: 30px;
    justify-content: center; /* Center nav on mobile */
}

.nav-btn-v2.prev-v2 {
    position: relative;
    left: auto;
    margin-left: 15px; /* Space from dots */
}

.nav-btn-v2.next-v2 {
    position: relative;
    right: auto;
    margin-right: 15px; /* Space from dots */
}

.slider-dots-v2 {
    display: flex; /* Show dots on mobile */
}

/* Desktop Styles (min-width: 769px) */
@media (min-width: 769px) {
    .slide-item-v2 {
        flex: 0 0 calc(25% - 30px); /* Approx 4 items, accounting for margin */
        max-width: calc(25% - 30px);
        margin: 0 15px; /* Add margin for gap */
        padding: 0; /* Remove padding from item itself */
    }

    .slider-wrapper-v2 {
        width: 100%;
        max-width: none; /* Full width on desktop */
        padding: 0 60px; /* Padding to accommodate nav buttons */
    }

    .slider-v2 {
        overflow: visible; /* Allow nav buttons to be outside */
    }

    .slide-content-v2 {
        flex-direction: row; /* Side-by-side */
        align-items: center;
        max-width: none; /* Allow full width */
    }

    .member-image-v2 {
        width: 50%; /* Image takes half width */
        height: auto; /* Adjust height */
        min-height: 450px; /* Minimum height */
    }

    .member-info-v2 {
        width: 50%; /* Info takes the other half */
        text-align: left; /* Align text left */
        padding-left: 40px; /* More padding */
    }

    .bio-v2 {
        text-align: justify; /* Justify text */
    }

    .social-links-v2 {
        justify-content: flex-start;
    }

    .slider-nav-v2 {
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        transform: translateY(-50%);
        margin-top: 0;
        justify-content: space-between; /* Push buttons to edges */
        z-index: 10;
    }

    .nav-btn-v2.prev-v2 {
        position: relative; /* Override absolute */
        left: -20px; /* Position outside wrapper */
        margin-left: 0;
    }

    .nav-btn-v2.next-v2 {
        position: relative; /* Override absolute */
        right: -20px; /* Position outside wrapper */
        margin-right: 0;
    }

    .slider-dots-v2 {
        display: none; /* Hide dots on desktop */
    }
}

/* Larger Desktop for better spacing */
@media (min-width: 1200px) {
    .slide-item-v2 {
        flex: 0 0 calc(25% - 30px); /* Ensure 4 items fit */
        max-width: calc(25% - 30px);
        margin: 0 15px;
    }

    .member-image-v2 {
        min-height: 500px; /* Slightly taller image */
    }
}