.wc-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.wc-popup-container {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    animation: popupSlideIn 0.3s ease-out;
}

@keyframes popupSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.wc-popup-header {
    padding: 20px 20px 0;
    position: relative;
}

.wc-popup-close {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.wc-popup-close:hover {
    color: #333;
}

.wc-popup-body {
    padding: 20px;
    text-align: center;
}

.wc-popup-message h3 {
    margin: 20px 0 15px;
    font-size: 24px;
    font-weight: 600;
}

.wc-popup-success h3 {
    color: #28a745;
}

.wc-popup-error h3 {
    color: #dc3545;
}

.wc-popup-icon {
    margin: 0 auto 20px;
    width: 80px;
    height: 80px;
}

/* Success Checkmark Animation */
.checkmark {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: block;
    stroke-width: 3;
    stroke: #28a745;
    stroke-miterlimit: 10;
    box-shadow: inset 0px 0px 0px #28a745;
    animation: fill 0.4s ease-in-out 0.4s forwards, scale 0.3s ease-in-out 0.9s both;
}

.checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 3;
    stroke-miterlimit: 10;
    stroke: #28a745;
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke: #28a745;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

.checkmark.animate .checkmark-circle,
.checkmark.animate .checkmark-check {
    animation-play-state: running;
}

/* Error Cross Animation */
.cross {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: block;
    stroke-width: 3;
    stroke: #dc3545;
    stroke-miterlimit: 10;
    box-shadow: inset 0px 0px 0px #dc3545;
    animation: fill-error 0.4s ease-in-out 0.4s forwards, scale 0.3s ease-in-out 0.9s both;
}

.cross-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 3;
    stroke-miterlimit: 10;
    stroke: #dc3545;
    fill: none;
    animation: stroke 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.cross-line {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke: #dc3545;
    stroke-width: 3;
    animation: stroke 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
}

.cross.animate .cross-circle,
.cross.animate .cross-line {
    animation-play-state: running;
}

@keyframes stroke {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes scale {
    0%, 100% {
        transform: none;
    }
    50% {
        transform: scale3d(1.1, 1.1, 1);
    }
}

@keyframes fill {
    100% {
        box-shadow: inset 0px 0px 0px 30px #28a745;
    }
}

@keyframes fill-error {
    100% {
        box-shadow: inset 0px 0px 0px 30px #dc3545;
    }
}

.wc-popup-details {
    margin: 20px 0;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    text-align: left;
}

.wc-popup-details p {
    margin: 10px 0;
    font-size: 14px;
    line-height: 1.5;
}

.wc-popup-details strong {
    color: #333;
}

.wc-popup-footer {
    padding: 0 20px 20px;
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.wc-popup-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    display: inline-block;
    transition: all 0.2s;
    min-width: 120px;
}

.wc-popup-btn {
    background: #6c757d;
    color: white;
}

.wc-popup-btn:hover {
    background: #5a6268;
    transform: translateY(-1px);
}

.wc-popup-btn-primary {
    background: #007cba;
    color: white;
}

.wc-popup-btn-primary:hover {
    background: #005a87;
}

/* Mobile Responsive */
@media (max-width: 480px) {
    .wc-popup-container {
        margin: 20px;
        width: calc(100% - 40px);
    }
    
    .wc-popup-footer {
        flex-direction: column;
    }
    
    .wc-popup-btn {
        width: 100%;
    }
    
    .wc-popup-icon {
        width: 60px;
        height: 60px;
    }
    
    .checkmark, .cross {
        width: 60px;
        height: 60px;
    }
    
    .wc-popup-message h3 {
        font-size: 20px;
    }
}

/* Loading Animation (Optional) */
.wc-popup-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.wc-popup-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007cba;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}