/* ----- VIDEO POPUP MODAL ----- */
.video-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(26, 59, 72, 0.92);
    backdrop-filter: blur(1px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0.25s, opacity 0.3s ease;
}

.video-modal.active {
    visibility: visible;
    opacity: 1;
}

.modal-content {
    position: relative;
    width: 90%;
    max-width: 1000px;
    background: #000;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    animation: scaleIn 0.35s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* close button */
.close-video {
    position: absolute;
    top: -40px;
    right: 0;
    background: rgba(0, 0, 0, 0.6);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    width: 40px;
    height: 40px;
    border-radius: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(4px);
    z-index: 10;
}

.close-video:hover {
    background: var(--gold);
    color: var(--deep-teal);
    transform: rotate(90deg);
}

/* responsive close button on small screens */
@media (max-width: 700px) {
    .close-video {
        top: 10px;
        right: 10px;
        background: rgba(0, 0, 0, 0.7);
    }
}

/* video wrapper (16:9) */
.video-wrapper {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    /* 16:9 aspect ratio */
    background: black;
}

.video-wrapper iframe,
.video-wrapper video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* caption / optional info */
.video-caption {
    background: rgba(0, 0, 0, 0.7);
    color: var(--gold-light);
    padding: 10px 16px;
    font-size: 0.8rem;
    text-align: center;
    letter-spacing: 0.5px;
}

/* accessibility & focus */
button:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
}