﻿/* Overlay */
.fmm-popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.78);
    backdrop-filter: blur(6px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    animation: fadeIn .4s ease forwards;
    z-index: 9999;
}

/* Popup container */
.fmm-popup {
    background: #0b0b0b;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 18px;
    max-width: 75vw;
    padding: 3rem;
    width: 100%;
    padding: 2.5rem;
    position: relative;
    animation: slideUp .45s ease forwards;
    box-shadow: 0 30px 80px rgba(0,0,0,.6);
}


/* Close button */
.fmm-popup-close {
    position: absolute;
    top: 12px;
    right: 14px;
    font-size: 32px;
    z-index: 10;
    color: #fff;
    background: none;
    border: none;
    cursor: pointer;
    opacity: .7;
    transition: .2s;
}

    .fmm-popup-close:hover {
        opacity: 1;
        color: #a97bff;
    }


/* Render the FMM section like the popup */
.fmm-section-popup {
    background: rgba(0,0,0,0.0); /* stesso grigio del popup */
    border: none;
    border-radius: 0px; /* stesso raggio del popup */
    padding: 0;
    margin: auto;
    max-width: 1300px; /* opzionale per centrare come il popup */
    box-shadow: 0 25px 60px rgba(0,0,0,.0); /* simile al popup */
}

    /* Ensures internal elements respect the rounded shape */
    .fmm-section-popup img,
    .fmm-section-popup .fmm-image-wrapper {
        border-radius: 0px;
        overflow: hidden;
    }


/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(35px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Slight adjustments for popup version */
.popup-version .fmm-title {
    font-size: 2rem;
}

.popup-version .fmm-text {
    font-size: .95rem;
}

@media (max-width: 575.98px) {
    .fmm-popup {
        padding: 1.4rem;
    }
}


/* Mobile: spingi il popup più in basso e rendilo scrollabile */
@media (max-width: 576px) {
    .fmm-popup {
        margin-top: 3rem;
        margin-left: 1rem;
        margin-right: 1rem;
        max-height: calc(100vh - 11rem);
        overflow-y: auto;
        overflow-x: auto;
    }
}



