/* Overlay scuro di sfondo */
#calessio-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
}

/* Box del popup */
#calessio-popup-box {
    position: relative;
    background: #ffffff;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: calessioPopupFadeIn 0.3s ease;
}

@keyframes calessioPopupFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Pulsante X di chiusura */
#calessio-popup-close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 40px;
    height: 40px;
    background: #333333;
    color: #ffffff;
    border: none;
    border-radius: 50%;
    font-size: 28px;
    font-weight: bold;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    z-index: 10;
    padding: 0;
}

#calessio-popup-close:hover {
    background: #e74c3c;
    transform: scale(1.1);
}

#calessio-popup-close:focus {
    outline: 2px solid #3498db;
    outline-offset: 2px;
}

/* Contenuto del popup */
#calessio-popup-content {
    padding: 30px;
    padding-top: 50px;
}

/* Responsive - Tablet */
@media (max-width: 768px) {
    #calessio-popup-box {
        max-width: 90%;
    }
    
    #calessio-popup-content {
        padding: 25px;
        padding-top: 50px;
    }
}

/* Responsive - Mobile */
@media (max-width: 480px) {
    #calessio-popup-overlay {
        padding: 15px;
    }
    
    #calessio-popup-box {
        max-width: 100%;
        border-radius: 6px;
    }
    
    #calessio-popup-close {
        width: 36px;
        height: 36px;
        font-size: 24px;
        top: 8px;
        right: 8px;
    }
    
    #calessio-popup-content {
        padding: 20px;
        padding-top: 45px;
    }
}
