/* Site pop-up */
.site-popup[hidden] {
    display: none !important;
}

.site-popup {
    position: fixed;
    inset: 0;
    z-index: 100080;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    box-sizing: border-box;
}

.site-popup__overlay {
    position: absolute;
    inset: 0;
    background: rgba(3, 7, 13, 0.78);
    backdrop-filter: blur(4px);
}

.site-popup__dialog {
    position: relative;
    z-index: 2;
    width: min(860px, 100%);
    max-height: calc(100vh - 48px);
    margin: 0;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 24px 80px rgba(0, 45, 114, 0.22);
    display: flex;
    flex-direction: column;
    transform: translateY(8px) scale(0.98);
    opacity: 0;
    transition: transform 0.28s ease, opacity 0.28s ease;
}

.site-popup__dialog--video,
.site-popup__dialog--video-link,
.site-popup__dialog--pdf {
    width: min(960px, 100%);
}

.site-popup.is-visible .site-popup__dialog {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.site-popup__close {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 3;
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 50%;
    background: rgba(0, 45, 114, 0.72);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.site-popup__close:hover {
    background: rgba(0, 45, 114, 0.92);
    transform: scale(1.04);
}

.site-popup__body {
    padding: 28px 28px 24px;
    overflow: auto;
}

.site-popup__title {
    margin: 0 0 18px;
    font-size: clamp(1.15rem, 2vw, 1.45rem);
    line-height: 1.35;
    font-weight: 700;
    color: var(--theme, #002D72);
    padding-right: 48px;
}

.site-popup__media {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* YouTube / Vimeo */
.site-popup__embed {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 8px;
    background: #0b0f16;
}

.site-popup__embed--video {
    aspect-ratio: 16 / 9;
}

.site-popup__embed--pdf {
    height: min(72vh, 560px);
    min-height: 360px;
}

.site-popup__embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

/* Yüklenen görsel */
.site-popup__image {
    display: block;
    width: 100%;
    height: auto;
    max-height: min(72vh, 640px);
    object-fit: contain;
    border-radius: 8px;
    background: #f5f7fb;
}

/* Yüklenen video dosyası */
.site-popup__video {
    display: block;
    width: 100%;
    max-height: min(72vh, 640px);
    aspect-ratio: 16 / 9;
    border-radius: 8px;
    background: #000;
    object-fit: contain;
}

.site-popup__external-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 120px;
    padding: 24px;
    border-radius: 8px;
    background: var(--theme-muted-bg, #E8EEF7);
    color: var(--theme, #002D72);
    font-weight: 600;
    text-align: center;
    word-break: break-word;
    text-decoration: none;
}

.site-popup__external-link:hover {
    color: var(--theme, #002D72);
    background: #dce6f5;
}

.site-popup__actions {
    margin-top: 20px;
    display: flex;
    justify-content: center;
}

.site-popup__cta.theme-btn {
    text-decoration: none;
}

body.site-popup-open {
    overflow: hidden;
}

body.site-popup-open .mouseCursor {
    display: none !important;
}

@media (max-width: 767.98px) {
    .site-popup {
        padding: 12px;
    }

    .site-popup__dialog,
    .site-popup__dialog--video,
    .site-popup__dialog--video-link,
    .site-popup__dialog--pdf {
        width: 100%;
        max-height: calc(100vh - 24px);
    }

    .site-popup__body {
        padding: 20px 16px 16px;
    }

    .site-popup__embed--pdf {
        height: min(58vh, 420px);
        min-height: 280px;
    }

    .site-popup__image,
    .site-popup__video {
        max-height: min(58vh, 480px);
    }
}
