/*
 * Our Team (page-templates/ourteam.php, page 89) restyled after the new home page (MILESTONES #20).
 * The intro band, the "WORK WITH US" title, the counter, the registration and the headquarters are shared blocks
 * (site-components.css; the people photo with "Become Ambassador" is the same block as on Contact); here the team
 * ([shortcode_show_our_team], the ourteampost posts in template-parts/teammate_item_tpl.php) as cards. The old rules
 * of this page only (.teammate-item, .id-our-team, .page-template-ourteam, #ourteam-extra-title) were removed from the
 * Divi copies; .parallelogram (also the news list) and #our-team-summary (one rule with #top-ambassadors-summary,
 * Contact) stay there.
 */

/* ---------- Team: one card per person, three per row, the last row centred. */

body.amg-skin #page-container #our-team-summary {
    display: block;
    margin: 0;
    padding: clamp(40px, 4.6vw, 72px) 0 clamp(16px, 2vw, 32px);
    background: linear-gradient(180deg, var(--amg-soft-blue) 0%, var(--amg-soft) 55%, #fff 100%);
}

body.amg-skin #page-container #our-team-summary-inner {
    --amg-team-gap: clamp(18px, 2vw, 28px);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: var(--amg-team-gap);
    width: min(100% - 32px, 1180px);
    max-width: none;
    margin: 0 auto;
}

body.amg-skin #page-container #our-team-summary .teammate-item {
    flex: 0 1 calc((100% - 2 * var(--amg-team-gap)) / 3);
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: clamp(24px, 2.6vw, 36px) clamp(20px, 2.2vw, 30px);
    border: 1px solid var(--amg-line);
    border-radius: var(--amg-radius-lg);
    background: #fff;
    box-shadow: var(--amg-shadow-sm);
    text-align: center;
}

/* The photo: a circle with the brand parallelogram behind its top right edge (as before, in the home colours). */
body.amg-skin #page-container #our-team-summary .image-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 220px;
    max-width: 100%;
    height: 200px;
    margin-bottom: 22px;
}

body.amg-skin #page-container #our-team-summary .parallelogram {
    top: 0;
    right: 22px;
    width: 92px;
    height: 104px;
    border: 0;
    border-radius: 6px;
    background: var(--amg-navy);
}

body.amg-skin #page-container #our-team-summary .image-container-inner {
    position: relative;
    display: flex;
    width: 168px;
    height: 168px;
    overflow: hidden;
    border-radius: 50%;
    background: var(--amg-soft-blue);
    box-shadow: 0 0 0 6px #fff;
}

body.amg-skin #page-container #our-team-summary .image-container-inner .teammate-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

body.amg-skin #page-container #our-team-summary .item-name {
    margin: 0;
    padding: 0;
    color: var(--amg-navy);
    font-family: var(--amg-font);
    font-size: 20px;
    font-weight: 800;
    line-height: 1.3;
}

body.amg-skin #page-container #our-team-summary .item-country {
    margin-top: 6px;
    color: var(--amg-blue);
    font-family: var(--amg-font);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .1em;
    line-height: 1.4;
    text-transform: uppercase;
}

body.amg-skin #page-container #our-team-summary .item-content {
    margin: 16px 0 0;
    padding: 0;
    color: var(--amg-text);
    font-family: var(--amg-font);
    font-size: 15px;
    line-height: 1.65;
}

body.amg-skin #page-container #our-team-summary .item-contact {
    margin-top: auto;
    padding-top: 16px;
}

body.amg-skin #page-container #our-team-summary .item-contact:empty {
    display: none;
}

body.amg-skin #page-container #our-team-summary .item-contact a {
    font-size: 15px;
}

@media (max-width: 991px) {
    body.amg-skin #page-container #our-team-summary .teammate-item {
        flex-basis: calc((100% - var(--amg-team-gap)) / 2);
    }
}

@media (max-width: 600px) {
    body.amg-skin #page-container #our-team-summary .teammate-item {
        flex-basis: 100%;
    }
}
