/* ============================================================
   FF Video Popup — card
   ============================================================ */
.ff-video-popup {
    height: 100%;
}

.ff-video-popup .vp-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    background: #ffffff;
    border: 1px solid rgba(16, 24, 40, 0.08);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(16, 24, 40, 0.06);
    cursor: pointer;
    transition: transform 300ms ease, box-shadow 300ms ease, border-color 300ms ease;
}

.ff-video-popup .vp-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 40px rgba(16, 24, 40, 0.12);
}

.ff-video-popup .vp-card:focus-visible {
    outline: 3px solid #0b2f8f;
    outline-offset: 3px;
}

/* --- Thumbnail --- */
.ff-video-popup .vp-thumb {
    position: relative;
    width: 100%;
    height: 230px;
    overflow: hidden;
}

.ff-video-popup .vp-thumb-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    background: linear-gradient(135deg, #0b2f8f 0%, #16306e 100%);
}

.ff-video-popup .vp-thumb img {
    position: absolute;
    inset: 0;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 400ms ease;
}

.ff-video-popup .vp-card:hover .vp-thumb img {
    transform: scale(1.05);
}

/* decorative inner frame */
.ff-video-popup .vp-frame {
    position: absolute;
    inset: 16px;
    z-index: 2;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 6px;
    pointer-events: none;
}

/* eyebrow label */
.ff-video-popup .vp-label {
    position: absolute;
    top: 26px;
    left: 30px;
    z-index: 3;
    color: #ffffff;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
}

/* play button */
.ff-video-popup .vp-play {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 3;
    transform: translate(-50%, -50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: #ffffff;
    color: #0b2f8f;
    font-size: 26px;
    line-height: 1;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    transition: transform 300ms ease, background-color 300ms ease, color 300ms ease;
}

.ff-video-popup .vp-card:hover .vp-play {
    transform: translate(-50%, -50%) scale(1.08);
}

.ff-video-popup .vp-play svg {
    width: 26px;
    height: 26px;
    fill: currentColor;
}

/* --- Body --- */
.ff-video-popup .vp-body {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: 8px;
    padding: 28px 30px 30px;
}

.ff-video-popup .vp-title {
    margin: 0;
    color: #16306e;
    font-size: 22px;
    line-height: 1.3;
}

.ff-video-popup .vp-link {
    color: #6b7280;
    font-size: 15px;
    transition: color 300ms ease;
}

.ff-video-popup .vp-card:hover .vp-link {
    color: #0b2f8f;
}

/* ============================================================
   Lightbox overlay (injected into <body> by the JS)
   ============================================================ */
.ff-vp-overlay {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(7, 12, 28, 0.88);
    opacity: 0;
    visibility: hidden;
    transition: opacity 250ms ease, visibility 250ms ease;
}

.ff-vp-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

.ff-vp-dialog {
    position: relative;
    width: 100%;
    max-width: 1040px;
    transform: scale(0.96);
    transition: transform 250ms ease;
}

.ff-vp-overlay.is-open .ff-vp-dialog {
    transform: scale(1);
}

.ff-vp-stage {
    position: relative;
    width: 100%;
    background: #000;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
}

/* aspect ratios */
.ff-vp-stage[data-ratio="169"] { aspect-ratio: 16 / 9; }
.ff-vp-stage[data-ratio="219"] { aspect-ratio: 21 / 9; }
.ff-vp-stage[data-ratio="43"]  { aspect-ratio: 4 / 3; }
.ff-vp-stage[data-ratio="11"]  { aspect-ratio: 1 / 1; }
.ff-vp-stage[data-ratio="916"] { aspect-ratio: 9 / 16; max-width: 420px; margin: 0 auto; }

.ff-vp-stage iframe,
.ff-vp-stage video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

/* fallback for browsers without aspect-ratio */
@supports not (aspect-ratio: 1 / 1) {
    .ff-vp-stage { padding-top: 56.25%; }
}

.ff-vp-close {
    position: absolute;
    top: -48px;
    right: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
    transition: background-color 200ms ease, transform 200ms ease;
}

.ff-vp-close:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: rotate(90deg);
}

html.ff-vp-lock,
body.ff-vp-lock {
    overflow: hidden;
}

/* --- Responsive --- */
@media (max-width: 767px) {
    .ff-video-popup .vp-label { top: 20px; left: 22px; }
    .ff-video-popup .vp-body { padding: 22px 22px 24px; }
    .ff-video-popup .vp-title { font-size: 19px; }
    .ff-vp-close { top: -44px; }
}
