/* VIDEO.CSS - Video page specific styles */

/* ==================== PAGE TITLE ==================== */

.page-title {
    text-align: center;
    margin-bottom: 60px;
}

.page-heading {
    font-size: 3.5rem;
    font-weight: 700;
    color: #000;
    line-height: 1.1;
}

.page-intro {
    max-width: 700px;
    margin: 20px auto 0;
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}


/* ==================== FEATURED VIDEO ==================== */

.video-featured {
    max-width: 1000px;
    margin: 0 auto 80px;
    padding-bottom: 60px;
    border-bottom: 1px solid #e0e0e0;
}

.video-embed {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background-color: #000;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.video-embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.video-details {
    margin-top: 30px;
}

.video-meta {
    display: flex;
    gap: 15px;
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 12px;
}

.video-source {
    color: #000;
    font-weight: 500;
}

.video-details h2 {
    font-size: 2rem;
    font-weight: 400;
    line-height: 1.3;
    margin-bottom: 15px;
    color: #000;
}

.video-details p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
}


/* ==================== SELF-HOSTED MP4 PLAYERS ==================== */

.video-library {
    margin-bottom: 80px;
    padding-bottom: 60px;
    border-bottom: 1px solid #e0e0e0;
}

/*
   Mixed dimensions: every card sets --ar (its video's shape, e.g. 9 / 16 or 16 / 9).
   All players share one target height (--player-h), so vertical, square and
   widescreen videos line up in a row, each at its own natural width.
*/

.video-grid--players {
    --player-h: min(560px, 70vh);
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 50px 40px;
}

.video-grid--players .video-card {
    --ar: 16 / 9;
    flex: 0 1 calc(var(--player-h) * (var(--ar)));
    max-width: 100%;
    min-width: 0;
}

.video-player {
    position: relative;
    width: 100%;
    aspect-ratio: var(--ar);
    background-color: #000;
    overflow: hidden;
    margin-bottom: 18px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.video-player video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    background-color: #000;
}

.video-player a {
    color: #fff;
}

@media (max-width: 767px) {
    .video-grid--players {
        --player-h: min(520px, 75vh);
        gap: 50px;
    }
}


/* ==================== MORE TO WATCH ==================== */

.video-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 50px;
    margin-bottom: 80px;
}

@media (min-width: 768px) {
    .video-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 40px;
    }
}

.video-card a {
    text-decoration: none;
    color: inherit;
    display: block;
}

.video-thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background-color: #f5f5f5;
    margin-bottom: 18px;
}

.video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s ease, opacity 0.3s ease;
}

/* Play badge */
.video-thumb::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 64px;
    height: 64px;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.7) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E") no-repeat 55% 50% / 28px;
    transition: background-color 0.3s ease;
}

.video-card a:hover .video-thumb img {
    transform: scale(1.05);
    opacity: 0.9;
}

.video-card a:hover .video-thumb::after {
    background-color: rgba(0, 0, 0, 0.9);
}

.video-card h3 {
    font-size: 1.3rem;
    font-weight: 400;
    line-height: 1.3;
    margin-bottom: 10px;
    color: #000;
}

.video-card a:hover h3 {
    color: #666;
}

.video-card p {
    font-size: 1rem;
    line-height: 1.7;
    color: #333;
}


/* ==================== RESPONSIVE ==================== */

@media (max-width: 767px) {
    .page-heading {
        font-size: 2.5rem;
    }

    .video-details h2 {
        font-size: 1.5rem;
    }
}
