.catitem {
    display: flex;
    align-items: left;
    flex-direction: column;
    padding: 10px;
    border-bottom: 1px solid #ccc;
}

.catitem:last-of-type {
    border-bottom: none;
}

.catitem .teamlink {
    font-size: 1.2rem;
    font-weight: 600;
    color: #333;
    text-decoration: none;
}

.catitem-member {
    flex: 1;
    display: flex;
    align-items: center;
    padding-left: 1em;
    font-size: 1rem;
}

.team-member {
    display: flex;
    align-items: center;
    padding: 5px 0;
}

.teams-category-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.teams-category-container .category-teammembers {
    display: grid;
    align-items: stretch;
    grid-template-columns: repeat(4, 1fr);
    grid-gap: 1.5rem;
}

.teams-embed-category {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 1.25rem;
    align-items: stretch;
}

.teams-embed-category .teammember {
    min-width: 0;
    min-height: 0;
    overflow: hidden;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    border-radius: 10px;
}

.teams-embed-category .teammember picture {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 4 / 3;
}

.teams-embed-category .teammember-link {
    display: block;
    padding: 0.75rem 1rem 1rem;
}

.teams-embed-category .teammember-link span.name {
    margin-right: 0;
}

.teammember {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 100px;
}

.teammember picture {
    width: 100%;
    height: clamp(300px, 30vw, 520px);
}

.teammember picture.no-teammember-image {
    background-color: rgb(228, 228, 228);
    border: 1px solid rgb(221, 221, 221);
}

.teammember picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.teammember-link {
    text-align: center;
}

.teammember-link span.name {
    font-weight: bold;
    margin-right: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px 0;
}

.teammember-link span.title {
    font-style: italic;
    color: #666;
}

.catitem-member img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
}

.catitem-member span {
    font-weight: normal;
}

p.backlink a {
    color: var(--brand-b-bg);
    text-decoration: none;
}

p.backlink a:hover {
    color: var(--brand-b-hilite);
    text-decoration: underline;
}

p.backlink {
    margin: 20px 0;
    font-size: 1rem;
}

@media (max-width: 1200px) {
    .teams-category-container .category-teammembers {
        grid-template-columns: repeat(3, 1fr);
    }

    .teammember picture {
        height: clamp(300px, 45vw, 520px);
    }
}

@media (max-width: 800px) {
    .teams-category-container .category-teammembers {
        grid-template-columns: repeat(2, 1fr);
    }

    .teammember picture {
        height: clamp(300px, 65vw, 520px);
    }
}

@media (max-width: 440px) {
    .teams-category-container .category-teammembers {
        grid-template-columns: repeat(1, 1fr);
    }

    .teammember picture {
        height: clamp(500px, 65vw, 520px);
    }

}

/* Team Member Page */

.teams-member-container picture {
    float: right;
    padding: 1rem 1rem 2rem 5rem;
}

.teams-member-container picture img {
    border-radius: 10px;
    max-width: 375px;
    width: 100%;
}

@media (max-width: 600px) {
    .teams-member-container picture {
        float: unset;
    }
}