﻿. /* =========================
   CARD CONTAINER
========================= */
.video-card {
    background: #111;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
    margin-bottom: 20px;
    position: relative;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.4);
}


/* =========================
   MEDIA WRAPPER
========================= */
.video-thumb-wrapper {
    position: relative;
    background: #000; /* prevents white flash */
    overflow: hidden;
}

/* loader */
.video-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    background: rgba(0,0,0,0.35);
    opacity: 0;
    transition: opacity .2s;
}

.video-card.loading .video-loading {
    opacity: 1;
}

/* fade in player */
.video-player iframe {
    opacity: 0;
    transition: opacity .35s ease;
}

.video-card.playing .video-player iframe {
    opacity: 1;
}
/* =========================
   THUMBNAIL
========================= */
.video-thumb {
    width: 100%;
    display: block;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.video-card:hover .video-thumb {
    transform: scale(1.06);
    filter: brightness(0.85);
}

/* hide thumbnail when playing */
.video-card.playing .video-thumb {
    opacity: 0;
}


/* =========================
   VIDEO PLAYER
========================= */
.video-player {
    position: absolute;
    inset: 0;
    z-index: 2;
}

    .video-player iframe,
    .video-player video {
        width: 100%;
        height: 100%;
        border: 0;
        object-fit: cover;
        border-radius: 14px;
        background: #000;
    }


/* =========================
   OVERLAY (PLAY BUTTON)
========================= */
.video-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(to top, rgba(0,0,0,.7), transparent);
    z-index: 3;
    transition: opacity 0.3s ease;
}

/* hide overlay when playing */
.video-card.playing .video-overlay {
    opacity: 0;
    pointer-events: none;
}


/* =========================
   PLAY BUTTON
========================= */
.play-button {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 20px rgba(255, 0, 0, 0.3);
    transition: transform 0.25s ease, background 0.25s ease;
}

    .play-button i {
        font-size: 42px;
        color: #fff;
        margin-left: 3px;
    }

.video-thumb-wrapper:hover .play-button {
    transform: scale(1.1);
    background: rgba(255, 0, 0, 1);
}


/* =========================
   EXPAND BUTTON
========================= */
.expand-button {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 4;
    transition: background 0.3s ease;
}

    .expand-button i {
        color: #fff;
        font-size: 18px;
    }

    .expand-button:hover {
        background: rgba(0,0,0,0.75);
    }


/* =========================
   INFO SECTION
========================= */
.video-info {
    background: rgba(17,17,17,0.95);
    padding: 12px 16px;
    color: #eee;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.video-title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 4px;
}

.video-meta {
    font-size: 0.85rem;
    color: #aaa;
}
/* Responsive Play Button Scaling */
@media (max-width: 1024px) {
    .play-button {
        width: 60px;
        height: 60px;
    }

        .play-button i {
            font-size: 32px;
        }
}

@media (max-width: 768px) {
    .play-button {
        width: 50px;
        height: 50px;
    }

        .play-button i {
            font-size: 26px;
        }
}

@media (max-width: 480px) {
    .play-button {
        width: 42px;
        height: 42px;
    }

        .play-button i {
            font-size: 22px;
        }

    .expand-button {
        width: 30px;
        height: 30px;
        top: 8px;
        right: 8px;
    }

        .expand-button i {
            font-size: 14px;
        }
}
