/**
 * COOKIE-CONSENT STYLES
 * DSGVO-konformes Design für Cookie-Einverständnis
 * Version: 1.0.0
 */

/* Cookie-Consent-Banner */
#cookie-consent-banner {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.cookie-consent-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.cookie-consent-modal {
    position: relative;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    animation: cookieModalSlideIn 0.3s ease-out;
}

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

.cookie-consent-header {
    padding: 24px 24px 16px;
    border-bottom: 1px solid #e5e7eb;
}

.cookie-consent-header h3 {
    margin: 0 0 8px 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #1f2937;
}

.cookie-consent-header p {
    margin: 0;
    color: #6b7280;
    font-size: 0.95rem;
    line-height: 1.5;
}

.cookie-consent-content {
    padding: 20px 24px;
}

.cookie-category {
    margin-bottom: 20px;
    padding: 16px;
    background: #f9fafb;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
}

.cookie-category:last-child {
    margin-bottom: 0;
}

.cookie-category-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.cookie-toggle {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
    flex-shrink: 0;
    margin-top: 2px;
}

.cookie-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 24px;
}

.cookie-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.cookie-toggle input:checked + .cookie-slider {
    background-color: #3b82f6;
}

.cookie-toggle input:checked + .cookie-slider:before {
    transform: translateX(24px);
}

.cookie-toggle input:disabled + .cookie-slider {
    background-color: #9ca3af;
    cursor: not-allowed;
}

.cookie-category-info h4 {
    margin: 0 0 4px 0;
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
}

.cookie-category-info p {
    margin: 0;
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.4;
}

.cookie-consent-actions {
    padding: 20px 24px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.cookie-consent-actions .btn {
    flex: 1;
    min-width: 120px;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.btn-secondary {
    background: #6b7280;
    color: white;
}

.btn-secondary:hover {
    background: #4b5563;
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: #6b7280;
    border: 1px solid #d1d5db;
}

.btn-outline:hover {
    background: #f9fafb;
    border-color: #9ca3af;
    transform: translateY(-1px);
}

.cookie-consent-footer {
    padding: 16px 24px 24px;
    display: flex;
    gap: 20px;
    justify-content: center;
}

.cookie-consent-footer a {
    color: #6b7280;
    text-decoration: none;
    font-size: 0.875rem;
    transition: color 0.2s ease;
}

.cookie-consent-footer a:hover {
    color: #3b82f6;
    text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 640px) {
    .cookie-consent-modal {
        margin: 10px;
        max-width: none;
    }
    
    .cookie-consent-actions {
        flex-direction: column;
    }
    
    .cookie-consent-actions .btn {
        flex: none;
        width: 100%;
    }
    
    .cookie-consent-footer {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .cookie-consent-modal {
        background: #1f2937;
        color: #f9fafb;
    }
    
    .cookie-consent-header {
        border-bottom-color: #374151;
    }
    
    .cookie-consent-header h3 {
        color: #f9fafb;
    }
    
    .cookie-consent-header p {
        color: #d1d5db;
    }
    
    .cookie-category {
        background: #374151;
        border-color: #4b5563;
    }
    
    .cookie-category-info h4 {
        color: #f9fafb;
    }
    
    .cookie-category-info p {
        color: #d1d5db;
    }
    
    .cookie-consent-actions {
        border-top-color: #374151;
    }
    
    .cookie-consent-footer a {
        color: #d1d5db;
    }
    
    .cookie-consent-footer a:hover {
        color: #60a5fa;
    }
}
