/* ==========================================================================
   Layout: Team
   Header (label + heading + prev/next nav) + Swiper card slider.
   Card hover reveals "View details" overlay. Click opens modal.
   ========================================================================== */

/* Section ----------------------------------------------------------------- */

.pb-tm {
    padding: 80px 16px;
}

/* Inner ------------------------------------------------------------------- */

.pb-tm__inner {
    max-width: 1280px;
    margin: 0 auto;
}

/* Header ------------------------------------------------------------------ */

.pb-tm__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 48px;
}

.pb-tm__label {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 15px;
    line-height: 160%;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-invisible);
    margin: 0 0 16px;
}

.pb-tm__heading {
    font-family: var(--second-family);
    font-weight: 550;
    font-size: 36px;
    line-height: 128%;
    letter-spacing: -0.02em;
    color: var(--text-bold);
    margin: 0;
}
.pb-tm__card-photo{
    height: 300px;
    border-radius: 8px;
}
/* Navigation buttons ------------------------------------------------------ */

.pb-tm__nav {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}
.pb-tm__card{

}

.pb-tm__nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: var(--base-white);
    border: 1px solid var(--base-border-black);
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    flex-shrink: 0;
    box-shadow: 0 1px 8px 0 rgba(0,0,0,.01), 0 6px 17px 0 rgba(0,0,0,.01), 0 15px 40px 0 rgba(0,0,0,.02);
}

.pb-tm__nav-btn:hover {
    border-color: var(--brand-blue-300, #93b5fd);
    box-shadow: 0 4px 16px 0 rgba(47,108,250,.10);
}

.pb-tm__nav-btn.swiper-button-disabled {
    opacity: 0.35;
    cursor: default;
    pointer-events: none;
}

/* Swiper ------------------------------------------------------------------ */

.pb-tm__swiper {
    overflow: visible;
    position: relative;
}

.pb-tm__peek {
    display: none;
}

@media (min-width: 769px) {
    .pb-tm__peek {
        position: absolute;
        top: 0;
        display: flex;
        gap: 24px;
        pointer-events: none;
    }
    .pb-tm__peek--left {
        right: calc(100% + 24px);
    }
    .pb-tm__peek--right {
        left: calc(100% + 24px);
    }
    .pb-tm__peek .pb-tm__card {
        cursor: default;
    }
}

.pb-tm__slide {
    width: 300px;
}

/* Card -------------------------------------------------------------------- */

.pb-tm__slide {
    display: flex;
}

.pb-tm__card {
    border: 1px solid var(--base-border-black, rgba(0,0,0,.08));
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    width: 100%;
    text-decoration: none;
    transition: box-shadow 0.25s ease;
    box-shadow: 0 1px 8px 0 rgba(0, 0, 0, 0.01), 0 6px 17px 0 rgba(0, 0, 0, 0.01), 0 15px 40px 0 rgba(0, 0, 0, 0.02);
background: var(--base-white);
border: 1px solid var(--base-border-black);
border-radius: 8px;
padding: 12px 12px 16px;
}

.pb-tm__card:hover {
    box-shadow: 0 8px 32px 0 rgba(0,0,0,.10);
}

/* Card photo -------------------------------------------------------------- */

.pb-tm__card-photo {
    position: relative;
    overflow: hidden;
    aspect-ratio: 4/5;
    background: linear-gradient(6deg, #3571FB -36.84%, rgba(53, 113, 251, 0.00) 109.23%);
/* filter: blur(45.796607971191406px); */

    flex-shrink: 0;
}
.pb-tm__modal-photo{
    background: linear-gradient(6deg, #3571FB -36.84%, rgba(53, 113, 251, 0.00) 109.23%) !important;
}

.pb-tm__card-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: filter 0.25s ease;
}

.pb-tm__card:hover .pb-tm__card-photo img {
    filter: blur(4px);
}

/* Hover overlay */

.pb-tm__card-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 24px;
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
}

.pb-tm__card:hover .pb-tm__card-overlay {
    opacity: 1;
}

.pb-tm__view-btn {
    display: inline-flex;
    align-items: center;
    background: #fff;
    border-radius: 8px;
    padding: 10px 20px;
    font-family: var(--font-family);
    font-weight: 600;
    font-size: 14px;
    line-height: 143%;
    color: var(--text-bold);
    box-shadow: 0 2px 12px 0 rgba(0,0,0,.12);
    white-space: nowrap;
}

/* Card info --------------------------------------------------------------- */

.pb-tm__card-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 16px 0 16px;
}

.pb-tm__card-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.pb-tm__card-name {
    font-family: var(--second-family);
    font-weight: 600;
    font-size: 16px;
    line-height: 150%;
    letter-spacing: 0.01em;
    color: var(--text-bold);
    /* white-space: nowrap; */
    overflow: hidden;
    /* text-overflow: ellipsis; */
}

.pb-tm__card-position {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 14px;
    line-height: 157%;
    color: var(--text-base);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* LinkedIn icon (shared: card + modal) ------------------------------------ */

.pb-tm__linkedin {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    opacity: 1;
    transition: opacity 0.2s ease;
}

.pb-tm__linkedin:hover {
    opacity: 0.75;
}

/* Mobile grid — hidden on desktop ----------------------------------------- */

.pb-tm__mobile-grid {
    display: none;
}

/* Modal ------------------------------------------------------------------- */

.pb-tm__modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 16px;
}

/* display controlled by JS — .is-open/.is-closing only drive animation */

/* Backdrop: fade + blur */
.pb-tm__modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.40);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.35s ease;
}

.pb-tm__modal.is-open .pb-tm__modal-backdrop {
    opacity: 1;
}

.pb-tm__modal.is-closing .pb-tm__modal-backdrop {
    opacity: 0;
}

/* Modal box: slide up from bottom */
.pb-tm__modal-box {
    position: relative;
    z-index: 1;
    background: var(--base-white);
    width: 100%;
    max-width:  630px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 24px 80px 0 rgba(0,0,0,.18);
    transform: translateY(80px);
    opacity: 0;
    transition: transform 0.38s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.38s ease;
    border-radius: 16px;
padding: 24px 24px 48px;
}

.pb-tm__modal.is-open .pb-tm__modal-box {
    transform: translateY(0);
    opacity: 1;
}

.pb-tm__modal.is-closing .pb-tm__modal-box {
    transform: translateY(80px);
    opacity: 0;
}

/* Modal header */

.pb-tm__modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--base-border-black, rgba(0,0,0,.08));
}

.pb-tm__modal-title {
    font-family: var(--second-family);
    font-weight: 600;
    font-size: 18px;
    line-height: 133%;
    color: var(--text-bold);
}

.pb-tm__modal-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.2s ease;
}

.pb-tm__modal-close:hover {
    background: rgba(0,0,0,.06);
}

/* Modal photo */

.pb-tm__modal-photo {
    height: 236px;
    overflow: hidden;
    background: #f0f3ff;
     border-radius: 8px;
         display: flex;
    align-items: center;
    justify-content: center;
}

.pb-tm__modal-photo img {
    display: block;
    width: auto;
    object-fit: cover;
    object-position: center;
    height: 100%;
}
.alignCenter{
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}
/* Modal body */

.pb-tm__modal-body {
    padding: 48px 0 0 0;
}

.pb-tm__modal-name-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 6px;
}

.pb-tm__modal-name {
    font-family: var(--second-family);
    font-weight: 550;
    font-size: 36px;
    line-height: 128%;
    letter-spacing: -0.02em;
    background: linear-gradient(169deg, rgba(0, 5, 25, 0.9) 0%, #000519 50%, rgba(0, 5, 25, 0.9) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin: 0;
}

.pb-tm__modal-position {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 18px;
    line-height: 156%;
    color: var(--text-subtlest);
    margin: 0 0 24px;
}

.pb-tm__modal-bio {
    font-family: var(--font-family);
    font-weight: 500;
    font-size: 16px;
    line-height: 150%;
    letter-spacing: 0.01em;
    color: var(--text-subtlest);
    margin: 0;
}

/* Responsive -------------------------------------------------------------- */

@media (max-width: 768px) {
    .pb-tm {
        padding: 56px 16px;
        overflow: visible;
    }

    .pb-tm__header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
        margin-bottom: 32px;
    }

    .pb-tm__label {
        font-size: 12px;
        line-height: 133%;
        margin-bottom: 12px;
    }

    .pb-tm__heading {
        font-size: 28px;
        line-height: 129%;
    }

    /* Hide Swiper, show nav on mobile */
    .pb-tm__swiper { display: none !important; }
    .pb-tm__nav    { display: none; }

    /* Mobile 2-column grid */
    .pb-tm__mobile-grid {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    /* Modal as bottom sheet */
    .pb-tm__modal {
        align-items: flex-end;
        padding: 0;
    }

    .pb-tm__modal-box {
        max-width: 100%;
        width: 100%;
        border-radius: 20px 20px 0 0;
        max-height: 88vh;
        padding: 20px 20px calc(32px + env(safe-area-inset-bottom));
        /* On mobile: animate via transform only, no opacity fade */
        transform: translateY(100%);
        opacity: 1;
        transition: transform 0.38s cubic-bezier(0.32, 0.72, 0, 1);
    }

    .pb-tm__modal.is-open .pb-tm__modal-box {
        transform: translateY(0);
        opacity: 1;
    }

    .pb-tm__modal.is-closing .pb-tm__modal-box {
        transform: translateY(100%);
        opacity: 1;
    }

    /* Backdrop: no blur on mobile for performance */
    .pb-tm__modal-backdrop {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .pb-tm__modal-header {
        padding-bottom: 16px;
    }

    .pb-tm__modal-body {
        padding-top: 24px;
    }

    .pb-tm__modal-name {
        font-size: 26px;
        line-height: 131%;
    }

    .pb-tm__modal-photo {
        height: 200px;
    }
    .pb-tm__card-photo{
        height: 164px;
    }
    .pb-tm__card-info{
        padding: 4px 8px;
    }
    .pb-tm__card{
        position: relative;
    }
    .pb-tm__card-info .pb-tm__linkedin{
        position: absolute;
        box-shadow: 0 1px 5px 0 rgba(0, 0, 0, 0.01), 0 4px 12px 0 rgba(0, 0, 0, 0.01), 0 10px 27px 0 rgba(0, 0, 0, 0.02);
        background: var(--base-white);
        border: 0.67px solid var(--base-border-black);
        border-radius: 4px;
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        top: 16px;
        right: 16px;
    }
    .pb-tm__card{
        padding:8px;
    }
    .pb-tm__card-photo{
        margin-bottom: 8px;
    }
    .pb-tm__card-name{
        font-family: var(--second-family);
font-weight: 600;
font-size: 16px;
line-height: 150%;
letter-spacing: 0.01em;
color: var(--base-black);
    }
    .pb-tm__card-position{
        font-family: var(--font-family);
font-weight: 500;
font-size: 14px;
line-height: 157%;
letter-spacing: 0.02em;
color: var(--text-subtlest);
    }
}
