:root {
    --cookie-primary: #2266FF;
    --cookie-primary-hover: #8A2CFF;
    --cookie-secondary: #22E6FF;
    --cookie-dark: #1A1A2E;
    --cookie-darker: #0F0F1A;
    --cookie-light: #E2E8F0;
    --cookie-gray: #64748B;
    --cookie-success: #10B981;
    --cookie-warning: #F59E0B;
    --cookie-danger: #EF4444;
}

/* ---------------------- */
/* Banner Container */
/* ---------------------- */
.cookie-banner {
    position: fixed;
    top: 50%;                /* Mittig vertikal */
    left: 50%;               /* Mittig horizontal */
    transform: translate(-50%, -50%);
    background: rgba(20, 20, 30, 0.95);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 1.5rem 2rem;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    z-index: 99999;
    max-width: 600px;
    text-align: center;
    animation: fadeIn 0.4s ease-out;
}

.cookie-banner.show {
    display: flex;
}

#openCookieSettings {
    margin-top: 10px;
    padding: 0.6rem 1.2rem;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

#openCookieSettings:hover {
    background: var(--secondary-color);
    border-color: var(--secondary-color);
    color: #fff;
}

/* Slide Animation */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translate(-50%, 40px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

/* ---------------------- */
/* Banner Actions + Buttons */
/* ---------------------- */
.cookie-banner-actions {
    display: flex;
    gap: 0.5rem;
}

.cookie-btn {
    padding: 0.6rem 1.2rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    white-space: nowrap;
}

/* Primary */
.cookie-btn-primary {
    background: linear-gradient(135deg, #8A2CFF, #22E6FF);
    color: white;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.cookie-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34,230,255,0.4);
}

/* Secondary */
.cookie-btn-secondary {
    background: rgba(255,255,255,0.08);
    color: #E2E8F0;
    border: 1px solid rgba(255,255,255,0.2);
}
.cookie-btn-secondary:hover {
    background: rgba(255,255,255,0.15);
}

/* Outline */
.cookie-btn-outline {
    background: transparent;
    color: #22E6FF;
    border: 1px solid #22E6FF;
}
.cookie-btn-outline:hover {
    background: #22E6FF;
    color: white;
}

/* ---------------------- */
/* Modal */
/* ---------------------- */
.cookie-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(5px);
    z-index: 10001;
    display: none;           /* Start: ausgeblendet */
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.cookie-modal.show {
    display: flex;           /* Statt "none" → anzeigen */
    animation: modalFadeIn 0.3s ease-out;
}

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

.cookie-modal-content {
    background: linear-gradient(135deg, var(--cookie-dark), var(--cookie-darker));
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    border: 1px solid rgba(138, 44, 255, 0.3);
    box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    animation: modalSlideIn 0.3s ease-out;
}
@keyframes modalSlideIn {
    from { opacity: 0; transform: translateY(20px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.cookie-modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.cookie-modal-header h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--cookie-light);
}
.cookie-modal-close {
    background: rgba(255,255,255,0.1);
    border: none;
    color: var(--cookie-light);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}
.cookie-modal-close:hover {
    background: rgba(255,255,255,0.2);
    transform: scale(1.1);
}

.cookie-modal-body {
    padding: 1rem 1.5rem 2rem;
}

/* Kategorien */
.cookie-category {
    margin-bottom: 1.5rem;
    padding: 1.2rem;
    background: rgba(255,255,255,0.05);
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.2s ease;
}
.cookie-category:hover {
    border-color: #2266FF;
    background: rgba(34,102,255,0.1);
}
.cookie-category-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--cookie-light);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Einheitliche Größe für die Kategorie-Icons */
.cookie-category-icon {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  margin-right: 10px;
  stroke: currentColor; /* gleiche Farbe wie Text */
}

/* Titel mit Icon sauber ausrichten */
.cookie-category-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 600;
}

.cookie-toggle {
    position: relative;
    width: 50px;
    height: 26px;
    background: #374151;
    border-radius: 13px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.cookie-toggle.disabled { opacity: 0.5; cursor: not-allowed; }
.cookie-toggle.active { background: #2266FF; }
.cookie-toggle-slider {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    background: white;
    border-radius: 50%;
    transition: transform 0.3s ease;
}
.cookie-toggle.active .cookie-toggle-slider {
    transform: translateX(24px);
}

/* ---------------------- */
/* Status Message */
/* ---------------------- */
.cookie-status-message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    color: white;
    z-index: 10002;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.cookie-status-message.show { transform: translateX(0); }
.cookie-status-message.success { background: var(--cookie-success); }
.cookie-status-message.error   { background: var(--cookie-danger); }
.cookie-status-message.warning { background: var(--cookie-warning); }

/* ---------------------- */
/* Responsive */
/* ---------------------- */
@media (max-width: 600px) {
    .cookie-banner {
        flex-direction: column;
        gap: 0.5rem;
        width: calc(100% - 2rem);
    }
    .cookie-banner-actions {
        flex-direction: column;
        width: 100%;
    }
    .cookie-banner .cookie-btn {
        width: 100%;
        text-align: center;
    }
}
