/* Frontend Popup Styles */

.ppm-popup {
    position: fixed;
    z-index: 999999;
    display: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: ppm-fade-in 0.3s ease-out;
}

.ppm-popup.ppm-active {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Popup Content */
.ppm-popup-content {
    padding: 20px;
    flex: 1;
}

.ppm-popup-content p {
    margin: 0 0 10px 0;
}

.ppm-popup-content p:last-child {
    margin-bottom: 0;
}

/* Close Button */
.ppm-popup-close {
    position: absolute;
    background: rgba(0, 0, 0, 0.3);
    border: none;
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
    padding: 8px 12px;
    transition: background 0.2s;
    border-radius: 3px;
}

.ppm-popup-close:hover {
    background: rgba(0, 0, 0, 0.5);
}

/* Bottom Banner Style */
.ppm-popup-bottom-banner {
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    min-height: 60px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.ppm-popup-bottom-banner .ppm-popup-content {
    padding: 15px 60px 15px 20px;
    text-align: center;
}

.ppm-popup-bottom-banner .ppm-popup-close {
    top: 50%;
    right: 20px;
    transform: translateY(-50%);
}

/* Center Rectangle Style */
.ppm-popup-center-rectangle {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    border-radius: 8px;
}

.ppm-popup-center-rectangle .ppm-popup-content {
    padding: 30px;
}

.ppm-popup-center-rectangle .ppm-popup-close {
    top: 10px;
    right: 10px;
}

/* Top Left Corner Style */
.ppm-popup-top-left-corner {
    top: 20px;
    left: 20px;
    width: 300px;
    max-width: calc(100vw - 40px);
    border-radius: 8px;
}

.ppm-popup-top-left-corner .ppm-popup-content {
    padding: 20px 40px 20px 20px;
}

.ppm-popup-top-left-corner .ppm-popup-close {
    top: 10px;
    right: 10px;
}

/* Top Right Corner Style */
.ppm-popup-top-right-corner {
    top: 20px;
    right: 20px;
    width: 300px;
    max-width: calc(100vw - 40px);
    border-radius: 8px;
}

.ppm-popup-top-right-corner .ppm-popup-content {
    padding: 20px 40px 20px 20px;
}

.ppm-popup-top-right-corner .ppm-popup-close {
    top: 10px;
    right: 10px;
}

/* Bottom Left Corner Style */
.ppm-popup-bottom-left-corner {
    bottom: 20px;
    left: 20px;
    width: 300px;
    max-width: calc(100vw - 40px);
    border-radius: 8px;
}

.ppm-popup-bottom-left-corner .ppm-popup-content {
    padding: 20px 40px 20px 20px;
}

.ppm-popup-bottom-left-corner .ppm-popup-close {
    top: 10px;
    right: 10px;
}

/* Bottom Right Corner Style */
.ppm-popup-bottom-right-corner {
    bottom: 20px;
    right: 20px;
    width: 300px;
    max-width: calc(100vw - 40px);
    border-radius: 8px;
}

.ppm-popup-bottom-right-corner .ppm-popup-content {
    padding: 20px 40px 20px 20px;
}

.ppm-popup-bottom-right-corner .ppm-popup-close {
    top: 10px;
    right: 10px;
}

/* Animations */
@keyframes ppm-fade-in {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes ppm-slide-up {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes ppm-slide-down {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.ppm-popup-bottom-banner.ppm-active {
    animation: ppm-slide-up 0.4s ease-out;
}

.ppm-popup-top-left-corner.ppm-active,
.ppm-popup-top-right-corner.ppm-active {
    animation: ppm-slide-down 0.4s ease-out;
}

/* Overlay for center popup */
.ppm-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999998;
    display: none;
    animation: ppm-fade-in 0.3s ease-out;
}

.ppm-overlay.ppm-active {
    display: block;
}

/* Responsive Design */
@media (max-width: 768px) {
    .ppm-popup-center-rectangle {
        width: 95%;
    }
    
    .ppm-popup-top-left-corner,
    .ppm-popup-top-right-corner,
    .ppm-popup-bottom-left-corner,
    .ppm-popup-bottom-right-corner {
        width: calc(100vw - 20px);
        left: 10px;
        right: 10px;
    }
    
    .ppm-popup-top-right-corner {
        left: auto;
    }
    
    .ppm-popup-bottom-right-corner {
        left: auto;
    }
    
    .ppm-popup-bottom-banner .ppm-popup-content {
        padding: 15px 50px 15px 15px;
        font-size: 14px;
    }
    
    .ppm-popup-bottom-banner .ppm-popup-close {
        right: 10px;
        padding: 6px 10px;
        font-size: 20px;
    }
}

/* Print Styles - Hide popups when printing */
@media print {
    .ppm-popup,
    .ppm-overlay {
        display: none !important;
    }
}
