/* Cookie Consent Banner & Modal - GDPR Compliant */

/* Banner Animations */
@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideDown {
    from {
        transform: translateY(0);
        opacity: 1;
    }
    to {
        transform: translateY(100%);
        opacity: 0;
    }
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    z-index: 10000;
    animation: slideUp 0.4s ease-out;
}

.cookie-banner-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
    display: flex;
    gap: 2rem;
    align-items: center;
    justify-content: space-between;
}

.cookie-banner-text {
    flex: 1;
}

.cookie-banner-text h3 {
    font-family: var(--font-serif, 'Playfair Display', serif);
    font-size: 1.3rem;
    margin: 0 0 0.75rem 0;
    color: #2c2c2c;
}

.cookie-banner-text p {
    margin: 0 0 0.5rem 0;
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
}

.cookie-policy-link {
    font-size: 0.85rem !important;
    color: #4B0082 !important;
}

.cookie-banner-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.cookie-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
}

.cookie-btn-primary {
    background: #4B0082;
    color: white;
}

.cookie-btn-primary:hover {
    background: #6a1fa8;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(75, 0, 130, 0.3);
}

.cookie-btn-secondary {
    background: #f0f0f0;
    color: #2c2c2c;
}

.cookie-btn-secondary:hover {
    background: #e0e0e0;
}

.cookie-btn-tertiary {
    background: transparent;
    color: #4B0082;
    border: 2px solid #4B0082;
}

.cookie-btn-tertiary:hover {
    background: #4B0082;
    color: white;
}

/* Cookie Settings Modal */
.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.cookie-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.cookie-modal-content {
    position: relative;
    background: white;
    border-radius: 16px;
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUpModal 0.3s ease-out;
}

@keyframes slideUpModal {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cookie-modal-header {
    padding: 2rem 2rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-modal-header h2 {
    font-family: var(--font-serif, 'Playfair Display', serif);
    font-size: 1.5rem;
    margin: 0;
    color: #2c2c2c;
}

.cookie-modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #999;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.2s;
}

.cookie-modal-close:hover {
    color: #2c2c2c;
}

.cookie-modal-body {
    padding: 2rem;
    overflow-y: auto;
}

.cookie-option {
    margin-bottom: 2rem;
}

.cookie-option-header {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.cookie-option-info h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
    color: #2c2c2c;
}

.cookie-option-info p {
    margin: 0;
    font-size: 0.9rem;
    color: #666;
    line-height: 1.6;
}

.cookie-always-active {
    font-size: 0.85rem;
    color: #999;
    font-weight: normal;
}

.cookie-change-notice {
    margin-top: 2rem;
    padding: 1rem;
    background: #fef3c7;
    border-left: 4px solid #f59e0b;
    border-radius: 4px;
    font-size: 0.9rem;
    color: #78350f;
}

.cookie-modal-footer {
    padding: 1rem 2rem 2rem;
    border-top: 1px solid #f0f0f0;
}

.cookie-modal-footer .cookie-btn {
    width: 100%;
    padding: 1rem;
}

/* Toggle Switch */
.cookie-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
    flex-shrink: 0;
}

.cookie-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 26px;
}

.cookie-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.cookie-switch input:checked + .cookie-slider {
    background-color: #4B0082;
}

.cookie-switch input:checked + .cookie-slider:before {
    transform: translateX(24px);
}

.cookie-switch input:disabled + .cookie-slider {
    background-color: #4B0082;
    opacity: 0.5;
    cursor: not-allowed;
}

/* Responsive */
@media (max-width: 768px) {
    .cookie-banner-content {
        flex-direction: column;
        padding: 1.5rem;
        gap: 1.5rem;
    }
    
    .cookie-banner-buttons {
        width: 100%;
        flex-direction: column;
    }
    
    .cookie-btn {
        width: 100%;
        text-align: center;
    }
    
    .cookie-modal-content {
        width: 95%;
        max-height: 90vh;
    }
    
    .cookie-modal-header,
    .cookie-modal-body,
    .cookie-modal-footer {
        padding: 1.5rem;
    }
    
    .cookie-option-header {
        flex-direction: column;
        gap: 0.75rem;
    }
}
