/**
 * DSGVO Cookie-Consent Banner Styles
 * Modernes, responsives Design für optimale Benutzererfahrung
 */

.gdpr-cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    z-index: 10000;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.gdpr-cookie-banner.show {
    transform: translateY(0);
}

.gdpr-banner-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.gdpr-banner-header h3 {
    margin: 0 0 10px 0;
    font-size: 1.4rem;
    font-weight: 600;
    color: #fff;
}

.gdpr-banner-header p {
    margin: 0 0 20px 0;
    font-size: 0.95rem;
    opacity: 0.9;
    line-height: 1.5;
}

.gdpr-cookie-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.gdpr-cookie-category {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
}

.gdpr-cookie-category:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.gdpr-category-info strong {
    display: block;
    margin-bottom: 5px;
    font-size: 0.95rem;
    color: #fff;
}

.gdpr-category-info p {
    margin: 0;
    font-size: 0.85rem;
    opacity: 0.8;
    line-height: 1.4;
}

/* Toggle Switch Styles */
.gdpr-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
    flex-shrink: 0;
    margin-top: 2px;
}

.gdpr-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.gdpr-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.3);
    transition: 0.3s;
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

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

input:checked + .gdpr-slider {
    background-color: #4CAF50;
    border-color: #4CAF50;
}

input:checked + .gdpr-slider:before {
    transform: translateX(26px);
}

input:disabled + .gdpr-slider {
    background-color: #4CAF50;
    opacity: 0.7;
    cursor: not-allowed;
}

input:disabled + .gdpr-slider:before {
    transform: translateX(26px);
}

/* Button Styles */
.gdpr-banner-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-bottom: 15px;
}

.gdpr-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    min-width: 140px;
    text-align: center;
}

.gdpr-btn-primary {
    background: linear-gradient(135deg, #4CAF50, #45a049);
    color: white;
    box-shadow: 0 4px 15px rgba(76, 175, 80, 0.3);
}

.gdpr-btn-primary:hover {
    background: linear-gradient(135deg, #45a049, #3d8b40);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
}

.gdpr-btn-secondary {
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: white;
    box-shadow: 0 4px 15px rgba(33, 150, 243, 0.3);
}

.gdpr-btn-secondary:hover {
    background: linear-gradient(135deg, #1976D2, #1565C0);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(33, 150, 243, 0.4);
}

.gdpr-btn-outline {
    background: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.6);
}

.gdpr-btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: white;
    transform: translateY(-2px);
}

.gdpr-banner-footer {
    text-align: center;
    opacity: 0.8;
}

.gdpr-banner-footer a {
    color: #fff;
    text-decoration: underline;
    transition: opacity 0.3s ease;
}

.gdpr-banner-footer a:hover {
    opacity: 0.8;
    color: #fff;
}

/* Cookie Settings Button (für Header/Footer) */
.cookie-settings-btn {
    background: none;
    border: 1px solid #ddd;
    color: #666;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.cookie-settings-btn:hover {
    background: #f8f9fa;
    border-color: #007bff;
    color: #007bff;
    text-decoration: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .gdpr-banner-content {
        padding: 15px;
    }
    
    .gdpr-cookie-categories {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .gdpr-cookie-category {
        padding: 12px;
    }
    
    .gdpr-banner-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .gdpr-btn {
        min-width: auto;
        width: 100%;
        margin-bottom: 5px;
    }
    
    .gdpr-banner-header h3 {
        font-size: 1.2rem;
    }
    
    .gdpr-banner-header p {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .gdpr-cookie-category {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .gdpr-switch {
        align-self: center;
    }
}

/* Animation für bessere UX */
@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.gdpr-cookie-banner.show {
    animation: slideUp 0.3s ease-out;
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .gdpr-cookie-banner {
        background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
    }
    
    .gdpr-cookie-category {
        background: rgba(255, 255, 255, 0.05);
        border-color: rgba(255, 255, 255, 0.1);
    }
    
    .gdpr-cookie-category:hover {
        background: rgba(255, 255, 255, 0.1);
    }
}

/* Accessibility */
.gdpr-btn:focus,
.gdpr-slider:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

.gdpr-switch input:focus + .gdpr-slider {
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5);
}

/* Cookie Settings Button in Footer */
.cookie-settings-button {
    background: none;
    border: none;
    color: inherit;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
    font-size: inherit;
    font-family: inherit;
}

.cookie-settings-button:hover {
    color: #ccc;
    text-decoration: none;
}

.cookie-settings-button:focus {
    outline: 2px solid #fff;
    outline-offset: 2px;
}

/* Print Styles */
@media print {
    .gdpr-cookie-banner {
        display: none;
    }
}