﻿.video-library {
    --video-accent: #198754;
    padding: 24px 0 48px;
}

.video-library-header {
    margin-bottom: 24px;
}

.video-search {
    position: relative;
    max-width: 560px;
    margin: 22px 0;
}

    .video-search input {
        width: 100%;
        padding: 13px 16px 13px 44px;
        border: 1px solid #dee2e6;
        border-radius: 12px;
        font-size: 1rem;
    }

    .video-search .search-icon {
        position: absolute;
        left: 15px;
        top: 50%;
        transform: translateY(-50%);
        color: #6c757d;
    }

.video-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
}

.video-category {
    border: 1px solid #dee2e6;
    border-radius: 30px;
    padding: 8px 16px;
    background: white;
    color: #343a40;
    cursor: pointer;
    font-size: .9rem;
    transition: all .2s ease;
}

    .video-category:hover {
        border-color: var(--video-accent);
        color: var(--video-accent);
    }

    .video-category.active {
        background: var(--video-accent);
        color: white;
        border-color: var(--video-accent);
    }

    .video-category .count {
        margin-left: 5px;
        opacity: .75;
        font-size: .8rem;
    }

.video-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.video-card {
    min-width: 0;
    border: 1px solid #e9ecef;
    border-radius: 14px;
    overflow: hidden;
    background: white;
    transition: transform .2s ease, box-shadow .2s ease;
}

    .video-card:hover {
        transform: translateY(-4px);
        box-shadow: 0 10px 28px rgba(0, 0, 0, .09);
    }

.video-thumbnail {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #e9ecef;
    overflow: hidden;
    cursor: pointer;
}

    .video-thumbnail img {
        width: 100%;
        height: 100%;
        display: block;
        object-fit: cover;
        transition: transform .3s ease;
    }

.video-card:hover .video-thumbnail img {
    transform: scale(1.04);
}

.video-play-button {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 58px;
    height: 42px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 12px;
    background: rgba(220, 0, 0, .94);
    color: white;
    font-size: 21px;
    transition: transform .2s ease;
    pointer-events: none;
}

.video-card:hover .video-play-button {
    transform: translate(-50%, -50%) scale(1.1);
}

.video-card-body {
    padding: 17px;
}

.video-card-category {
    display: inline-block;
    margin-bottom: 9px;
    color: var(--video-accent);
    font-size: .78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.video-card-title {
    font-size: 1.05rem;
    font-weight: 650;
    line-height: 1.4;
    margin: 0 0 9px;
    overflow-wrap: anywhere;
}

.video-card-description {
/*    color: #6c757d;
    font-size: .9rem;
    line-height: 1.55;
    margin: 0;
    overflow-wrap: anywhere;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;*/
}

.video-results {
    color: #6c757d;
    font-size: .9rem;
    margin-bottom: 18px;
}

.video-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    background: #f8f9fa;
    border-radius: 14px;
    color: #6c757d;
}

    .video-empty h3 {
        color: #343a40;
        margin-bottom: 8px;
    }

#videoPlayerModal .modal-dialog {
    max-width: 1000px;
}

.video-player-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

    .video-player-frame iframe {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        border: 0;
    }

@@media (max-width: 991px) {
    .video-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px;
    }
}

@@media (max-width: 575px) {
    .video-library {
        padding-top: 16px;
    }

    .video-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .video-card-body {
        padding: 14px;
    }
}
