/**
 * Mitglieder (Katalog + Detail).
 *
 * @package Osteuropa_Kolleg
 */

/*--------------------------------------------------------------
# Header
--------------------------------------------------------------*/
.mitglieder-header {
    margin: 60px 0 40px;
}

.mitglieder-header__title {
    color: #0E4194;
    font-family: "Source Sans 3", system-ui, sans-serif;
    font-size: 56px;
    font-weight: 400;
    line-height: 62px;
    margin: 0;
}

/*--------------------------------------------------------------
# Katalog-Grid
--------------------------------------------------------------*/
.mitglieder-catalog {
    margin: 40px 0 120px;
}

.mitglieder-catalog__grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 100px 60px;
}

@media (max-width: 767.98px) {
    .mitglieder-catalog__grid {
        grid-template-columns: 1fr;
        gap: 60px;
    }
}

.mitglied-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.2s ease;
}

.mitglied-card:after{
    content: "";
    position: absolute;
    right: -20px;
    bottom: -20px;
    display: flex;
    width: 41px;
    height: 41px;
    background-image: url("data:image/svg+xml,%3Csvg width='41' height='41' viewBox='0 0 41 41' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 0V41' stroke='%23C8D400' stroke-width='2'/%3E%3Cpath d='M0 20L41 20' stroke='%23C8D400' stroke-width='2'/%3E%3C/svg%3E");
    background-position: center;
    background-repeat: no-repeat;
    background-size: contain;
    transition: transform 0.2s ease;
}

.mitglied-card:hover:after {
    transform: rotate(180deg);
}

/* Логотип — фиксированная высота, даже если картинки нет. */
.mitglied-card__logo {
    min-height: 100px;
    display: flex;
    align-items: center;
}

.mitglied-card__logo--empty {
    /* оставляем пустое место — карточки выравниваются */
    visibility: hidden;
}

.mitglied-card__logo-img {
    max-height: 100px;
    max-width: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

.mitglied-card__title {
    color: #1d1d1b;
    font-family: "Source Sans 3", system-ui, sans-serif;
    font-size: 22px;
    font-weight: 400;
    line-height: 1.4;
    max-width: 420px;
}

.mitglied-card__institution{
    color: #000;
    font-family: "Source Sans 3";
    font-size: 24px;
    font-style: normal;
    font-weight: 400;
    line-height: 28px; /* 116.667% */
}
/*--------------------------------------------------------------
# Detail
--------------------------------------------------------------*/
.mitglieder-header {
    margin: 140px 0 20px 0;
}

.mitglied-detail__title {
    color: #0E4194;
    font-family: "Source Sans 3";
    font-size: 56px;
    font-style: normal;
    font-weight: 400;
    line-height: 62px; /* 110.714% */
}

.mitglied-detail {
    margin: 20px 0 90px 0;
}

.mitglied-detail__close {
    position: relative;
    top: 0;
    right: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    text-decoration: none;
    transition: transform 0.2s ease;
    z-index: 5;
}

.mitglied-detail__close:hover {
    transform: rotate(180deg);
}

.mitglied-detail__block {
    display: flex;
    gap: 130px;
    align-items: flex-start;
}

/* Если логотипа нет — контент занимает всю ширину без «пустой» колонки. */
.mitglied-detail__block--no-logo {
    /* без flex-логотипа body растянется сам, но ограничим разумно */
}

.mitglied-detail__logo {
    flex: 0 0 350px;
    max-width: 350px;
}

.mitglied-detail__logo-img {
    display: block;
    max-width: 100%;
    height: auto;
}

.mitglied-detail__body {
    flex: 1 1 auto;
    min-width: 0;
    max-width: 940px;
    padding-top: 25px;
}

.mitglied-detail__content {
    color: #000;
    font-family: "Source Sans 3";
    font-size: 24px;
    font-style: normal;
    font-weight: 400;
    line-height: 28px; /* 116.667% */
}

.mitglied-detail__content p {
    margin: 0 0 1em;
}

.mitglied-detail__content p:last-child {
    margin-bottom: 0;
}

/*--------------------------------------------------------------
# Контактный блок
--------------------------------------------------------------*/
.mitglied-detail__contacts {
    margin-top: 60px;
    color: #000;
    font-family: "Source Sans 3";
    font-size: 24px;
    font-style: normal;
    font-weight: 400;
    line-height: 28px; /* 116.667% */
}

.mitglied-detail__contacts p {
    margin: 0 0 20px;
}

.mitglied-detail__contacts p:last-child {
    margin-bottom: 0;
}

.mitglied-detail__contacts a {
    color: #000;
    font-family: "Source Sans 3";
    font-size: 24px;
    font-style: normal;
    font-weight: 400;
    line-height: 28px; /* 116.667% */
    text-decoration: none;
    text-underline-offset: 3px;
}

.mitglied-detail__contacts a:hover {
    text-decoration: underline;
}

/* Institution — rich_text, там могут быть <p>, <strong>, <em>. */
.mitglied-detail__institution {
    margin-bottom: 20px;
}

.mitglied-detail__institution p {
    margin: 0 0 0.4em;
}

.mitglied-detail__institution p:last-child {
    margin-bottom: 0;
}

.mitglied-detail__contact-person {
    margin-top: 40px !important;
}