.mod-youtube-video {
    padding: 36px 0;
}

.mod-youtube-video .video-heading {
    margin-bottom: 15px;
    font-size: 1.5em;
    font-weight: 600;
    text-align: center;
}
.mod-youtube-video .video-outer-wrap{
    margin: 0 auto;
}
.mod-youtube-video .video-container {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio (9/16 = 0.5625 = 56.25%) */
    height: 0;
    overflow: hidden;
    background: #000;
    margin: auto;
}

.mod-youtube-video .video-preview {
    cursor: pointer;
    position: relative;
}

.mod-youtube-video .video-thumbnail {
    position: relative;
    line-height: 0;
}
/* Make thumbnail and iframe fill the container */
.mod-youtube-video .video-thumbnail,
.mod-youtube-video .video-preview,
.mod-youtube-video .youtube-iframe-wrapper,
.mod-youtube-video .youtube-iframe-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.mod-youtube-video .video-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}

.mod-youtube-video .video-preview:hover .video-thumbnail img {
    transform: scale(1.03);
}

.mod-youtube-video .play-button {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: rgba(255, 0, 0, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(255, 0, 0, 0.3);
    z-index: 2;
}

.mod-youtube-video .play-button:hover {
    background: rgba(255, 0, 0, 1);
    transform: translate(-50%, -50%) scale(1.1);
    box-shadow: 0 6px 25px rgba(255, 0, 0, 0.4);
}

.mod-youtube-video .play-icon {
    width: 32px;
    height: 32px;
    color: white;
    margin-left: 4px; /* Centers the play triangle */
}

.mod-youtube-video .youtube-iframe-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
    height: 0;
}

.mod-youtube-video .youtube-iframe-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.mod-youtube-video .video-error {
    color: #d32f2f;
    text-align: center;
    padding: 20px;
    border: 1px solid #ffcdd2;
    background: #ffebee;
    border-radius: 4px;
}

/* Responsive */
@media (max-width: 768px) {
    .mod-youtube-video .play-button {
        width: 60px;
        height: 60px;
    }

    .mod-youtube-video .play-icon {
        width: 24px;
        height: 24px;
    }

    .mod-youtube-video .video-heading {
        font-size: 1.3em;
    }
}