/* Popup Promo Advanced Styles */

.promo-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 999999;
    display: none;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    animation: fadeIn 0.4s ease-out;
}

.promo-popup-overlay.show {
    display: flex;
}

.promo-popup-container {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    animation: slideInUp 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.promo-popup-content {
    position: relative;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
    background: white;
}

.promo-popup-link-wrapper {
    display: block;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.promo-popup-link-wrapper:hover {
    transform: scale(1.02);
}

.promo-popup-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 16px;
    max-width: 800px;
    max-height: 600px;
    object-fit: contain;
}

.promo-popup-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #333;
    font-size: 18px;
    font-weight: bold;
    transition: all 0.3s ease;
    z-index: 1000001;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.promo-popup-close:hover {
    background: #fff;
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.promo-popup-close svg {
    width: 20px;
    height: 20px;
}

/* Animations */
@keyframes fadeIn {
    from { 
        opacity: 0; 
    }
    to { 
        opacity: 1; 
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(60px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes fadeOut {
    from { 
        opacity: 1; 
    }
    to { 
        opacity: 0; 
    }
}

@keyframes slideOutDown {
    from {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
    to {
        opacity: 0;
        transform: translateY(60px) scale(0.9);
    }
}

.promo-popup-overlay.fade-out {
    animation: fadeOut 0.3s ease-out forwards;
}

.promo-popup-overlay.fade-out .promo-popup-container {
    animation: slideOutDown 0.3s ease-out forwards;
}

/* Mobile responsive */
@media (max-width: 768px) {
    .promo-popup-container {
        max-width: 95vw;
        max-height: 85vh;
        margin: 20px;
    }
    
    .promo-popup-close {
        top: 8px;
        right: 8px;
        width: 35px;
        height: 35px;
    }
    
    .promo-popup-close svg {
        width: 16px;
        height: 16px;
    }
    
    .promo-popup-image {
        max-height: 70vh;
    }
}

@media (max-width: 480px) {
    .promo-popup-container {
        max-width: 98vw;
        margin: 10px;
    }
    
    .promo-popup-close {
        top: 6px;
        right: 6px;
        width: 32px;
        height: 32px;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .promo-popup-overlay,
    .promo-popup-container,
    .promo-popup-close,
    .promo-popup-link-wrapper {
        animation: none !important;
        transition: none !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .promo-popup-close {
        background: #000;
        color: #fff;
        border: 2px solid #fff;
    }
}