.popup-overlay {
    visibility: hidden;
}

.popup-content {
    visibility: hidden;
}

.popup-overlay.active {
    visibility: visible;
}

.popup-content.active {
    visibility: visible;
}


/* Modal Content */

.popup-background {
    background-color: rgba(51, 51, 51, 0.5);
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 99999999999999;
}

.popup-content {
    position: fixed;
    top: 50%;
    left: 50%;
    margin-top: -150px;
    margin-left: -250px;
    width: 500px;
    height: 300px;
    background-color: #fefefe;
    padding: 10px 25px;
    border: 1px solid #888;
    box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
    animation-name: animatetop;
    animation-duration: 0.4s;
    overflow-x: auto;
}

.popup-title {
    margin: 0 auto;
    text-align: center;
    font-size: 32px;
    font-weight: bold;
    line-height: 46px;
    border-bottom: 4px solid black;
    max-width: 200px;
    margin-bottom: 20px;
}

.popup-close,
.popup-close:focus {
    background-color: transparent;
    border: none;
    outline: 0;
    color: black;
    text-align: center;
    text-decoration: none;
    font-size: 45px;
    cursor: pointer;
    top: 50%;
    position: absolute;
    right: 50%;
    margin-right: -240px;
    margin-top: -140px;
}

@media(max-width:526px) {
    .popup-content {
        margin-left: -150px;
        width: 300px;
    }
    .popup-close {
        margin-right: -145px;
    }
}


/* Add Animation */

@keyframes animatetop {
    from {
        top: -300px;
        opacity: 0
    }
    to {
        top: 0;
        opacity: 1
    }
}