/**
 * TRC Video Popup + Sticky Section shortcode styling.
 * KAAM-33700 fix. Loaded conditionally by snippets/trc-video-popup-shortcode.php.
 */

/* ---------------- Sticky Section (replaces [ult_sticky_section]) ---------------- */
.trc-sticky-section {
    position: relative;
    width: 100%;
}
.trc-sticky-inner {
    position: sticky;
    top: var(--trc-sticky-top, 120px);
}
/* LIVE Ultimate VC Addons `data-mobile="no"` — disable sticky on mobile */
@media (max-width: 767px) {
    .trc-sticky-inner {
        position: static;
        top: auto;
    }
}

/* ---------------- Video Popup thumbnail (replaces [video_popup]) ---------------- */
.trc-video-popup {
    position: relative;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
}
.trc-vp-trigger {
    display: block;
    position: relative;
    width: 100%;
    text-decoration: none;
    line-height: 0;
    cursor: pointer;
}
.trc-vp-thumb {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    border-radius: 0;
}
.trc-vp-thumb-placeholder {
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, #1a3d63, #0d1f38);
    border-radius: 0;
}
.trc-vp-play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 68px;
    height: 48px;
    pointer-events: none;
    transition: transform 0.2s ease, opacity 0.2s ease;
}
.trc-vp-play svg {
    display: block;
    width: 100%;
    height: 100%;
}
.trc-vp-trigger:hover .trc-vp-play {
    transform: translate(-50%, -50%) scale(1.08);
}
.trc-vp-trigger:hover .trc-vp-play path {
    fill: #d43125;
    fill-opacity: 0.95;
}

/* ---------------- Lightbox ---------------- */
.trc-vp-lightbox {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 999998;
    align-items: center;
    justify-content: center;
    padding: 30px;
    box-sizing: border-box;
}
.trc-vp-lightbox[aria-hidden="false"] { display: flex; }

.trc-vp-lightbox-inner {
    position: relative;
    width: 100%;
    max-width: 960px;
    max-height: 100%;
}
.trc-vp-close {
    position: absolute;
    top: -40px;
    right: 0;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 40px;
    line-height: 1;
    cursor: pointer;
    padding: 0;
    width: 40px;
    height: 40px;
}
.trc-vp-close:hover { color: #d43125; }
.trc-vp-player {
    display: block;
    width: 100%;
    height: auto;
    max-height: 80vh;
    background: #000;
    border-radius: 0;
    outline: none;
}
body.trc-vp-open { overflow: hidden; }

@media (max-width: 600px) {
    .trc-vp-lightbox { padding: 15px; }
    .trc-vp-close { top: -32px; font-size: 32px; width: 32px; height: 32px; }
}
