/**
 * Cookie Popup Styles
 * Modern, responsive design with smooth animations
 */

/* Overlay */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 20px;
}

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

/* Popup Container */
.wp-cookie-popup {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9) translateY(20px);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), 
                opacity 0.3s ease;
}

.wp-cookie-popup.active {
    transform: scale(1) translateY(0);
    opacity: 1;
}

/* Close Button */
.popup-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: transparent;
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: all 0.2s ease;
    z-index: 10;
    padding: 0;
}

.popup-close:hover {
    background: #f0f0f0;
    color: #333;
    transform: rotate(90deg);
}

.popup-close:active {
    transform: rotate(90deg) scale(0.95);
}

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

/* Popup Content */
.popup-content {
    padding: 40px 30px 30px;
}

/* Typography Defaults */
.popup-content h1,
.popup-content h2,
.popup-content h3 {
    margin-top: 0;
    margin-bottom: 16px;
    color: #1a1a1a;
    line-height: 1.3;
}

.popup-content h1 {
    font-size: 28px;
    font-weight: 700;
}

.popup-content h2 {
    font-size: 24px;
    font-weight: 600;
}

.popup-content h3 {
    font-size: 20px;
    font-weight: 600;
}

.popup-content p {
    margin: 0 0 16px;
    color: #555;
    line-height: 1.6;
    font-size: 16px;
}

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

.popup-content a {
    color: #0066cc;
    text-decoration: none;
    transition: color 0.2s ease;
}

.popup-content a:hover {
    color: #0052a3;
    text-decoration: underline;
}

/* Button Styles */
.popup-content .popup-accept,
.popup-content .popup-button,
.popup-content button[type="submit"],
.popup-content input[type="submit"],
.popup-content .wp-block-button__link {
    display: inline-block;
    background: #0066cc;
    color: #ffffff;
    border: none;
    padding: 14px 32px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    margin-top: 8px;
}

.popup-content .popup-accept:hover,
.popup-content .popup-button:hover,
.popup-content button[type="submit"]:hover,
.popup-content input[type="submit"]:hover,
.popup-content .wp-block-button__link:hover {
    background: #0052a3;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}

.popup-content .popup-accept:active,
.popup-content .popup-button:active,
.popup-content button[type="submit"]:active,
.popup-content input[type="submit"]:active,
.popup-content .wp-block-button__link:active {
    transform: translateY(0);
}

/* Form Elements */
.popup-content input[type="text"],
.popup-content input[type="email"],
.popup-content textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.2s ease;
    margin-bottom: 12px;
    box-sizing: border-box;
}

.popup-content input[type="text"]:focus,
.popup-content input[type="email"]:focus,
.popup-content textarea:focus {
    outline: none;
    border-color: #0066cc;
}

/* Images */
.popup-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 16px 0;
}

/* Lists */
.popup-content ul,
.popup-content ol {
    margin: 16px 0;
    padding-left: 24px;
    color: #555;
}

.popup-content li {
    margin-bottom: 8px;
    line-height: 1.6;
}

/* Custom Scrollbar */
.wp-cookie-popup::-webkit-scrollbar {
    width: 8px;
}

.wp-cookie-popup::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 0 16px 16px 0;
}

.wp-cookie-popup::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.wp-cookie-popup::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* Mobile Responsive */
@media screen and (max-width: 768px) {
    .popup-overlay {
        padding: 16px;
    }
    
    .wp-cookie-popup {
        border-radius: 12px;
        max-height: 85vh;
    }
    
    .popup-content {
        padding: 32px 20px 20px;
    }
    
    .popup-close {
        top: 12px;
        right: 12px;
        width: 32px;
        height: 32px;
    }
    
    .popup-content h1 {
        font-size: 24px;
    }
    
    .popup-content h2 {
        font-size: 20px;
    }
    
    .popup-content h3 {
        font-size: 18px;
    }
    
    .popup-content p {
        font-size: 15px;
    }
    
    .popup-content .popup-accept,
    .popup-content .popup-button,
    .popup-content button[type="submit"],
    .popup-content input[type="submit"] {
        width: 100%;
        padding: 12px 24px;
        font-size: 15px;
    }
}

/* Small mobile devices */
@media screen and (max-width: 480px) {
    .popup-overlay {
        padding: 12px;
    }
    
    .popup-content {
        padding: 28px 16px 16px;
    }
}

/* Dark mode support (optional) */
@media (prefers-color-scheme: dark) {
    .wp-cookie-popup {
        background: #1e1e1e;
        color: #e0e0e0;
    }
    
    .popup-close {
        color: #b0b0b0;
    }
    
    .popup-close:hover {
        background: #2a2a2a;
        color: #ffffff;
    }
    
    .popup-content h1,
    .popup-content h2,
    .popup-content h3 {
        color: #ffffff;
    }
    
    .popup-content p,
    .popup-content li {
        color: #c0c0c0;
    }
    
    .popup-content input[type="text"],
    .popup-content input[type="email"],
    .popup-content textarea {
        background: #2a2a2a;
        border-color: #404040;
        color: #e0e0e0;
    }
    
    .popup-content input[type="text"]:focus,
    .popup-content input[type="email"]:focus,
    .popup-content textarea:focus {
        border-color: #0066cc;
    }
}

/* Accessibility */
.popup-close:focus-visible {
    outline: 2px solid #0066cc;
    outline-offset: 2px;
}

.popup-content button:focus-visible,
.popup-content input:focus-visible,
.popup-content a:focus-visible {
    outline: 2px solid #0066cc;
    outline-offset: 2px;
}
