/* ================================
   COOKIE BANNER - DSGVO-konform
   Ingenieurbüro Tajik
   ================================ */

/* Cookie Banner Container */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    padding: 2rem;
    z-index: 10000;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-top: 3px solid var(--primary-color);
}

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

.cookie-banner-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 2rem;
    align-items: center;
}

/* Cookie Icon */
.cookie-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    animation: cookiePulse 2s infinite;
}

@keyframes cookiePulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(37, 99, 235, 0);
    }
}

/* Cookie Content */
.cookie-content {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.cookie-text {
    flex: 1;
}

.cookie-text h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.cookie-text p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 0;
}

.cookie-text a {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.cookie-text a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

/* Cookie Buttons */
.cookie-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.cookie-btn {
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    white-space: nowrap;
}

.cookie-btn-accept {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.cookie-btn-accept:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.cookie-btn-decline {
    background: white;
    color: var(--text-primary);
    border: 2px solid #e5e7eb;
}

.cookie-btn-decline:hover {
    background: #f9fafb;
    border-color: var(--text-secondary);
}

.cookie-btn-settings {
    background: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.cookie-btn-settings:hover {
    background: var(--primary-color);
    color: white;
}

/* Cookie Settings Modal */
.cookie-settings-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 10001;
    padding: 2rem;
    overflow-y: auto;
}

.cookie-settings-modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

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

.cookie-settings-content {
    background: white;
    border-radius: 20px;
    max-width: 700px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cookie-settings-header {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    padding: 2rem;
    border-radius: 20px 20px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-settings-header h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
}

.cookie-settings-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cookie-settings-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.cookie-settings-body {
    padding: 2rem;
}

.cookie-category {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f9fafb;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
}

.cookie-category-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.cookie-category-header h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-category-header i {
    color: var(--accent-color);
}

.cookie-category-description {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.5rem;
}

.cookie-category-examples {
    color: var(--text-light);
    font-size: 0.85rem;
    font-style: italic;
}

/* Toggle Switch */
.cookie-toggle {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
}

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

.cookie-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 34px;
}

.cookie-toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
}

.cookie-toggle input:checked + .cookie-toggle-slider {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

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

.cookie-toggle.disabled .cookie-toggle-slider {
    background-color: #4ade80;
    cursor: not-allowed;
}

.cookie-toggle.disabled .cookie-toggle-slider::after {
    content: "Immer aktiv";
    position: absolute;
    right: -110px;
    top: 50%;
    transform: translateY(-50%);
    color: #4ade80;
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

/* Cookie Settings Footer */
.cookie-settings-footer {
    padding: 1.5rem 2rem;
    background: #f9fafb;
    border-radius: 0 0 20px 20px;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* Responsive Design */
@media (max-width: 768px) {
    .cookie-banner {
        padding: 1.5rem;
    }

    .cookie-banner-container {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .cookie-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .cookie-icon {
        display: none;
    }

    .cookie-text h3 {
        font-size: 1.1rem;
    }

    .cookie-text p {
        font-size: 0.9rem;
    }

    .cookie-buttons {
        width: 100%;
        flex-direction: column;
    }

    .cookie-btn {
        width: 100%;
        text-align: center;
    }

    .cookie-settings-modal {
        padding: 1rem;
    }

    .cookie-settings-content {
        border-radius: 15px;
    }

    .cookie-settings-header,
    .cookie-settings-body {
        padding: 1.5rem;
    }

    .cookie-settings-footer {
        flex-direction: column;
    }

    .cookie-settings-footer .cookie-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .cookie-banner {
        padding: 1rem;
    }

    .cookie-text h3 {
        font-size: 1rem;
    }

    .cookie-text p {
        font-size: 0.85rem;
    }

    .cookie-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

