/* =============================================
   Simple Popup Plugin — Front-end Styles
   ============================================= */

.spp-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    box-sizing: border-box;

    /* hidden by default — JS controls visibility */
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.spp-overlay.spp-visible {
    opacity: 1;
    pointer-events: all;
}

/* Popup box */
.spp-popup {
    position: relative;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.35);
    max-width: 560px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    padding: 32px 28px 28px;
    box-sizing: border-box;

    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.spp-overlay.spp-visible .spp-popup {
    transform: translateY(0);
}

/* Close button */
.spp-close {
    all: unset;
    position: absolute;
    top: 10px;
    right: 14px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: #555;
    padding: 0 !important;
    margin: 0 !important;
    transition: color 0.2s;
}
.spp-close:hover {
    color: #000;
}

/* Image */
.spp-image-wrap {
    text-align: center;
    margin-bottom: 18px;
}
.spp-image-wrap img.spp-popup-image,
.spp-image-wrap a img.spp-popup-image {
    max-width: 100%;
    height: auto;
    display: inline-block;
    border-radius: 4px;
}

/* Custom HTML content */
.spp-content {
    font-size: 15px;
    line-height: 1.6;
    color: #333;
}
.spp-content * {
    max-width: 100%;
}

/* CTA Button */
.spp-btn-wrap {
    margin-top: 20px;
    text-align: center;
}

.spp-btn {
    display: inline-block;
    width: 100%;
    padding: 14px 24px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    box-sizing: border-box;
    transition: opacity 0.2s;
    line-height: 1.3;
}

.spp-btn:hover {
    opacity: 0.88;
    text-decoration: none;
}

/* =============================================
   Branded Hero Template
   ============================================= */

/* Popup box overrides */
.spp-tpl-hero {
    background: #0A1628;
    color: #ffffff;
    padding: 0;
    max-width: 600px;
    overflow: hidden;
}

/* Close button — white on dark bg, full reset to fight theme overrides */
.spp-tpl-hero .spp-close {
    all: unset;
    position: absolute;
    top: 10px;
    right: 14px;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    line-height: 1;
    color: rgba(255, 255, 255, 0.75);
    cursor: pointer;
    text-shadow: 0 1px 4px rgba(0,0,0,.5);
    z-index: 10;
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    border-radius: 0;
    box-shadow: none;
    transition: color 0.2s;
}
.spp-tpl-hero .spp-close:hover {
    color: #ffffff;
    background: none;
    box-shadow: none;
}

/* Edge-to-edge hero image */
.spp-tpl-hero .spp-image-wrap {
    margin: 0;
    border-radius: 0;
    line-height: 0;
}
.spp-tpl-hero .spp-image-wrap img.spp-popup-image,
.spp-tpl-hero .spp-image-wrap a img.spp-popup-image {
    width: 100%;
    max-width: 100%;
    border-radius: 0;
    display: block;
}

/* Body section below the image */
.spp-hero-body {
    padding: 24px 32px 32px;
    text-align: center;
}

/* Text content */
.spp-tpl-hero .spp-content {
    color: rgba(255, 255, 255, 0.88);
    font-size: 15px;
    line-height: 1.65;
    text-align: center;
    margin-bottom: 0;
}

/* Style headlines and bold text inside the editor content */
.spp-tpl-hero .spp-content h1,
.spp-tpl-hero .spp-content h2,
.spp-tpl-hero .spp-content h3 {
    color: #ffffff;
    font-weight: 700;
    line-height: 1.25;
    margin-top: 0;
}

.spp-tpl-hero .spp-content strong,
.spp-tpl-hero .spp-content b {
    color: #ffffff;
}

/* Button wrap */
.spp-tpl-hero .spp-btn-wrap {
    margin-top: 22px;
    text-align: center;
}

/* Pill-shaped CTA button matching Fynn brand style */
.spp-tpl-hero .spp-btn {
    display: inline-block;
    width: auto;
    min-width: 220px;
    padding: 16px 40px;
    border-radius: 50px;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: 0.01em;
    box-shadow: 0 4px 20px rgba(59, 127, 232, 0.45);
    transition: opacity 0.2s, transform 0.15s, box-shadow 0.15s;
}
.spp-tpl-hero .spp-btn:hover {
    opacity: 1;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(59, 127, 232, 0.6);
}

/* Mobile adjustments */
@media (max-width: 480px) {
    .spp-popup {
        padding: 24px 18px 20px;
    }
    .spp-tpl-hero {
        padding: 0;
    }
    .spp-hero-body {
        padding: 20px 20px 26px;
    }
    .spp-tpl-hero .spp-btn {
        width: 100%;
        padding: 15px 24px;
        font-size: 16px;
    }
}
