.wp-block-jm-team-view {
    --jm-team-view-gap: 28px;
    --jm-team-view-visible-desktop: 3;
    --jm-team-view-visible-tablet: 2;
    --jm-team-view-visible: var(--jm-team-view-visible-desktop);
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.jm-team-view__viewport {
    overflow: hidden;
    width: 100%;
    padding-bottom: 18px;
    box-sizing: border-box;
}

.jm-team-view__track {
    display: flex;
    gap: var(--jm-team-view-gap);
    align-items: stretch;
    will-change: transform;
    touch-action: pan-y;
    user-select: none;
}

.jm-team-view__viewport.is-dragging {
    cursor: grabbing;
}

.jm-team-view__slide {
    flex: 0 0 calc((100% - (var(--jm-team-view-visible) - 1) * var(--jm-team-view-gap)) / var(--jm-team-view-visible));
    min-width: 0;
}

.jm-team-view-card {
    display: grid;
    min-height: 100%;
    min-width: 0;
    overflow: hidden;
    border-radius: 22px;
    border: 1px solid #d9d4ca;
    background: transparent;
    box-shadow: none;
}

.jm-team-view-card__media {
    position: relative;
    width: clamp(112px, 40%, 156px);
    aspect-ratio: 4 / 5;
    margin: 22px auto 0;
    border-radius: 18px;
    overflow: hidden;
    background: linear-gradient(135deg, #dfe7df 0%, #f6f3e9 100%);
}

.jm-team-view-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.jm-team-view-card__media--empty {
    display: flex;
    align-items: center;
    justify-content: center;
}

.jm-team-view-card__media-placeholder {
    color: #6b7280;
    font-size: 14px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.jm-team-view-card__content {
    display: grid;
    gap: 10px;
    padding: 20px 20px 24px;
    min-width: 0;
}

.jm-team-view-card__role {
    color: #8f9b9f;
    font-size: 13px;
    line-height: 1.1;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    min-width: 0;
    overflow-wrap: anywhere;
}

.jm-team-view-card__name {
    margin: 0;
    color: #356f79;
    font-size: clamp(1.55rem, 1vw + 1.05rem, 2rem);
    line-height: 1.2;
    font-weight: 400;
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
}

.jm-team-view-card__bio {
    color: #51575b;
    font-size: 16px;
    line-height: 1.5;
    min-width: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
}

.jm-team-view-card__bio p {
    margin: 0;
}

.jm-team-view__nav {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 20px;
}

.jm-team-view__button {
    width: 50px;
    height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 999px;
    background: #356f79;
    color: #ffffff;
    cursor: pointer;
    box-shadow: 0 8px 16px rgba(32, 80, 88, 0.18);
    transition: transform 160ms ease, opacity 160ms ease, background-color 160ms ease;
}

.jm-team-view__button:hover:not(:disabled) {
    transform: translateY(-1px);
    background: #2c626b;
}

.jm-team-view__button:disabled {
    opacity: 0.45;
    cursor: default;
}

@media (max-width: 1100px) {
    .wp-block-jm-team-view {
        --jm-team-view-visible: var(--jm-team-view-visible-tablet);
    }
}

@media (max-width: 782px) {
    .wp-block-jm-team-view {
        --jm-team-view-gap: 16px;
        --jm-team-view-visible: 1;
    }

    .jm-team-view__slide {
        flex-basis: 100%;
    }

    .jm-team-view__viewport {
        padding-bottom: 14px;
    }

    .jm-team-view-card {
        border-radius: 18px;
    }

    .jm-team-view-card__media {
        width: clamp(104px, 34vw, 140px);
        margin-top: 18px;
    }

    .jm-team-view-card__content {
        padding: 16px 16px 18px;
    }

    .jm-team-view-card__name {
        font-size: clamp(1.35rem, 6vw, 1.7rem);
    }

    .jm-team-view-card__bio {
        font-size: 15px;
    }

    .jm-team-view__nav {
        justify-content: center;
        margin-top: 16px;
    }

    .jm-team-view__button {
        width: 44px;
        height: 44px;
    }
}