/*
 * Lite YouTube Embed
 * Thumbnail + play button, iframe loads on click
 */

.lite-youtube {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%; /* 16:9 */
    background-color: #000;
    border-radius: var(--radius-md);
    overflow: hidden;
    cursor: pointer;
}

.lite-youtube::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 50%, rgba(0,0,0,0.4) 100%);
    z-index: 1;
    transition: opacity var(--transition-normal);
}

.lite-youtube:hover::before {
    opacity: 0.7;
}

.lite-youtube__thumbnail {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.lite-youtube__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    width: 68px;
    height: 48px;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
    transition: transform var(--transition-normal), opacity var(--transition-normal);
}

.lite-youtube:hover .lite-youtube__play {
    transform: translate(-50%, -50%) scale(1.1);
}

.lite-youtube__play svg {
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 2px 8px rgba(0,0,0,0.3));
}

/* When activated - show iframe */
.lite-youtube.activated {
    cursor: default;
}

.lite-youtube.activated::before {
    display: none;
}

.lite-youtube.activated .lite-youtube__thumbnail,
.lite-youtube.activated .lite-youtube__play {
    display: none;
}

.lite-youtube iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
}
