/* ============================================
   taVideo - Карточки видео для листинга
   ============================================ */

/* Сетка видео - 3 колонки */
.taVideoGrid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

@media screen and (max-width: 991px) {
    .taVideoGrid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 575px) {
    .taVideoGrid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   Карточка видео
   ============================================ */
.taVideoCard {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.taVideoCard:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* ============================================
   Обложка видео
   ============================================ */
.taVideoCard__cover {
    display: block;
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #1a1a1a;
}

.taVideoCard__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.taVideoCard__cover:hover .taVideoCard__image {
    transform: scale(1.05);
}

/* Иконка Play поверх обложки */
.taVideoCard__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    background: rgba(0, 0, 0, 0.7);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 4;
}

.taVideoCard__play i {
    color: #fff;
    font-size: 24px;
    margin-left: 4px;
}

.taVideoCard__cover:hover .taVideoCard__play {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.1);
}

/* Плейсхолдер если нет превью */
.taVideoCard__placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    color: rgba(255, 255, 255, 0.3);
    font-size: 48px;
}

/* ============================================
   Бейджи статуса (pinned, featured, hidden)
   ============================================ */
.taVideoCard__badges {
    position: absolute;
    top: 10px;
    left: 10px;
    display: flex;
    gap: 5px;
    z-index: 5;
}

/* ============================================
   Тело карточки
   ============================================ */
.taVideoCard__body {
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    padding: 12px;
    gap: 8px;
}

/* ============================================
   Заголовок
   ============================================ */
.taVideoCard__title {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.4;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.taVideoCard__title a {
    color: inherit;
    text-decoration: none;
}

.taVideoCard__title a:hover {
    color: var(--theme-primary, #8BC34A);
}

/* Индикатор непрочитанного */
.taVideoCard__title .ipsItemStatus {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: baseline;
    margin-right: 6px;
    position: relative;
    top: -0.1em;
}

.taVideoCard__title .ipsItemStatus .fa-circle {
    font-size: 7px;
}

/* ============================================
   Мета-информация (автор + статистика)
   ============================================ */
.taVideoCard__footer {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-top: 10px;
    margin-top: auto;
    border-top: 1px solid rgba(128, 128, 128, 0.15);
    font-size: 13px;
}

.taVideoCard__author {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--theme-text_light, #666);
    min-width: 0;
}

.taVideoCard__author img {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    flex-shrink: 0;
}

.taVideoCard__author a {
    color: inherit;
    text-decoration: none;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.taVideoCard__author a:hover {
    color: var(--theme-primary, #8BC34A);
}

/* Статистика в мета-блоке */
.taVideoCard__meta .taStats--footer {
    flex-shrink: 0;
    font-size: 12px;
}

/* ========================================
   Видео в записи - ограничение ширины
   ======================================== */

.taVideoRecord .ipsEmbeddedVideo {
    max-width: 600px;
    width: 100% !important;
    max-width: 600px !important;
    height: auto !important;
    aspect-ratio: 16 / 9;
}

.taVideoRecord .ipsEmbeddedVideo:not( video ) {
    padding-bottom: 0 !important;
}

/* Бриф - стиль как у описания */
.taVideoRecord .ipsType_reset.ipsType_light {
    margin-top: 15px;
    font-size: 15px;
    line-height: 1.5;
    color: var(--theme-text_light, #666);
}

/* ============================================
   Адаптивность
   ============================================ */
@media screen and (max-width: 767px) {
    .taVideoCard__title {
        font-size: 14px;
    }
    
    .taVideoCard__body {
        padding: 10px;
    }
    
    .taVideoCard__play {
        width: 50px;
        height: 50px;
    }
    
    .taVideoCard__play i {
        font-size: 19px;
    }
}

@media screen and (max-width: 450px) {
    .taVideoCard__meta {
        flex-wrap: wrap;
    }
}