/* БАЗА: без фиксированной высоты карточки — весь контент виден */
.post-card {
    align-items: flex-start;
    background: #eceaea;
    border-radius: 16px;
    color: inherit;
    font-size: 18px;
    display: flex;
    gap: 16px;
    overflow: hidden;
    padding: 14px;

    /* чтобы вся карточка ловила наведение */
    cursor: pointer;
}

/* Превью: порог ширины + форма через aspect-ratio */
.post-card__thumb {
    border-radius: 12px;
    flex: 0 0 265px;
    min-width: 265px;
    width: 265px;
    aspect-ratio: 16 / 9;
    height: auto;
}

.post-card__img {
    border-radius: 8px;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;

    /* Ч/б по умолчанию, без странной прозрачности */
    filter: grayscale(1);
    opacity: 1;
    transition: filter .35s ease, transform .35s ease, opacity .2s ease;
}

/* На всякий случай убиваем любые глобальные ховеры с opacity */
.post-card__img:hover {
    opacity: 1;
}

/* Цвет включается при ховере на карточку ИЛИ на превью */
.post-card:hover .post-card__img,
.post-card__thumb:hover .post-card__img {
    filter: grayscale(0);
}

.post-card__body {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
    padding: 18px 0;
}

.post-card__title {
    font-weight: 600;
    line-height: 1.25;
    margin: 0;
}

.post-card__title a {
    color: inherit;
    text-decoration: none;
}

.post-card__title a:hover {
    text-decoration: underline;
}

.post-card__meta {
    align-items: baseline;
    display: flex;
    font-weight: 300;
    gap: 10px;
    opacity: .9;
    white-space: nowrap;
}

.post-card__author {
    margin-right: 12px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.post-card__tags {
    display: flex;
    flex-wrap: wrap;
    font-size: 14px;
    gap: 10px 12px;
    list-style: none;
    margin-top: auto;
    padding: 0;
}

.post-card__tags a {
    opacity: .9;
    text-decoration: none;
}

/* курсор обычный поверх ссылок тегов / автора */
.post-card__tags a,
.post-card__author a {
    cursor: pointer;
}

.post-card__tags a:hover {
    text-decoration: underline;
}

/* feature-variant */
.post-card--feature {
    display: flex;
    flex-direction: column;
}

.post-card--feature .post-card__thumb {
    border-radius: 0;
    flex: 0 0 auto;
    width: 100%;
    aspect-ratio: 16 / 9;
}

.post-card--feature .post-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.post-card--feature .post-card__body {
    padding: 16px 18px 18px;
}

/* compact при сужении — с «порогами» */
@media (max-width:1100px) {
    .post-card--compact .post-card__thumb {
        flex: 0 0 240px;
        min-width: 240px;
    }
}

@media (max-width:900px) {
    .post-card--compact {
        gap: 12px;
        padding: 12px;
    }

    .post-card--compact .post-card__thumb {
        flex: 0 0 220px;
        min-width: 220px;
    }
}

@media (max-width:640px) {
    .post-card--compact {
        flex-direction: column;
    }

    .post-card__body {
        padding: 0;
    }

    .post-card--compact .post-card__thumb {
        min-width: 0;
        width: 100%;
    }

    .post-card--compact .post-card__img {
        width: 100%;
        height: 100%;
        aspect-ratio: 16 / 9;
    }

    .post-card__title {
        font-size: 20px !important;
    }

    .post-card__meta {
        flex-wrap: wrap;
        white-space: normal;
        margin-bottom: 12px;
        font-size: 14px;
    }
}
