/* Editorial team cards: separators between rows, not beneath the final row. */
.qb-team-section .qb-team-card {
    align-content: center;
    grid-template-columns: 140px minmax(0, 1fr);
    gap: 26px;
    min-height: 0;
    padding: 0 0 28px;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #ffffff38;
}

.qb-team-section .qb-team-card:last-child {
    border-bottom: 0;
}

@media (min-width: 901px) {
    .qb-team-section .qb-team-card:nth-last-child(2):nth-child(odd) {
        border-bottom: 0;
    }
}

.qb-team-section .qb-team-portrait {
    align-self: center;
    aspect-ratio: 3 / 4;
}

.qb-team-section .qb-team-copy {
    align-self: center;
    padding: 0;
}

.qb-team-section .qb-team-copy h3 {
    margin: 0 0 7px;
}

.qb-team-section .qb-team-bio {
    margin: 18px 0 0;
}

@media (max-width: 600px) {
    .qb-team-section .qb-team-card {
        grid-template-columns: 112px minmax(0, 1fr);
        gap: 16px;
    }
}

@media (max-width: 420px) {
    .qb-team-section .qb-team-card {
        grid-template-columns: 90px minmax(0, 1fr);
    }
}

/* Match the section behind real photos; keep the theme's empty-profile artwork. */
.qb-team-card .qb-team-portrait:has(img) {
    background: inherit;
}

/* Only the team photo is reframed; card type and spacing remain theme-owned. */
.qb-team-portrait .qb-team-photo-frame {
    position: absolute;
    top: 50%;
    left: 0;
    display: block;
    width: 100%;
    aspect-ratio: 3 / 4;
    max-height: 100%;
    overflow: hidden;
    transform: translateY(-50%);
}

.qb-team-portrait .qb-team-photo-frame img {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: var(--qb-team-x, 50%) var(--qb-team-y, 30%);
    transform: scale(var(--qb-team-scale, 1));
    transform-origin: var(--qb-team-x, 50%) var(--qb-team-y, 30%);
}
