/* ===================================
   COOKIE CONSENT BANNER - GDPR/RODO
   Modern, Mobile-First Design
   =================================== */

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

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

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Cookie Banner Text */
.cookie-consent-text {
    display: flex;
    align-items: start;
    gap: 1rem;
}

.cookie-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.cookie-consent-text p {
    color: #333;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

.cookie-consent-text a {
    color: var(--color-primary, #6B7F5C);
    text-decoration: underline;
    font-weight: 500;
}

.cookie-consent-text a:hover {
    color: var(--color-primary-dark, #4A5A3F);
}

/* Cookie Banner Buttons */
.cookie-consent-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

.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 ease;
    font-family: inherit;
    white-space: nowrap;
}

.cookie-btn-accept-all {
    background: var(--color-primary, #6B7F5C);
    color: white;
}

.cookie-btn-accept-all:hover {
    background: var(--color-primary-dark, #4A5A3F);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(107, 127, 92, 0.3);
}

.cookie-btn-reject-all {
    background: #f5f5f5;
    color: #333;
}

.cookie-btn-reject-all:hover {
    background: #e0e0e0;
}

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

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

/* Cookie Settings Modal */
.cookie-settings-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 10001;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cookie-settings-modal.visible {
    display: flex;
    opacity: 1;
}

.cookie-settings-content {
    background: white;
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.3s ease;
}

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

.cookie-settings-header {
    padding: 2rem;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cookie-settings-header h2 {
    font-size: 1.5rem;
    color: #333;
    margin: 0;
    font-family: var(--font-heading, 'Playfair Display', serif);
}

.cookie-settings-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.cookie-settings-close:hover {
    background: #f5f5f5;
    color: #333;
}

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

.cookie-category {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #f0f0f0;
}

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

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

.cookie-category h3 {
    font-size: 1.1rem;
    color: #333;
    margin: 0;
    font-weight: 600;
}

.cookie-category p {
    color: #666;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0;
}

.cookie-category-required {
    font-size: 0.8rem;
    color: #999;
    font-weight: 500;
}

/* 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.3s;
    border-radius: 26px;
}

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

.cookie-toggle input:checked + .cookie-toggle-slider {
    background-color: var(--color-primary, #6B7F5C);
}

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

.cookie-toggle input:disabled + .cookie-toggle-slider {
    opacity: 0.5;
    cursor: not-allowed;
}

.cookie-settings-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid #e0e0e0;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.cookie-btn-save {
    background: var(--color-primary, #6B7F5C);
    color: white;
    padding: 0.75rem 2rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.cookie-btn-save:hover {
    background: var(--color-primary-dark, #4A5A3F);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(107, 127, 92, 0.3);
}

/* Cookie Settings Link (Footer) */
.cookie-settings-link {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background: var(--color-primary, #6B7F5C);
    color: white;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    z-index: 999;
    display: none;
}

.cookie-settings-link.visible {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-settings-link:hover {
    background: var(--color-primary-dark, #4A5A3F);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

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

    .cookie-consent-text {
        flex-direction: column;
        gap: 0.75rem;
    }

    .cookie-icon {
        font-size: 1.5rem;
    }

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

    .cookie-consent-buttons {
        flex-direction: column;
    }

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

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

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

    .cookie-settings-footer {
        padding: 1rem 1.5rem;
        flex-direction: column;
    }

    .cookie-btn-save {
        width: 100%;
    }

    .cookie-settings-link {
        bottom: 80px;
        left: 10px;
        font-size: 0.85rem;
        padding: 0.6rem 0.8rem;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    .cookie-consent-banner,
    .cookie-settings-modal,
    .cookie-toggle-slider,
    .cookie-toggle-slider:before {
        transition: none;
    }

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

/* Print - Hide cookie banner */
@media print {
    .cookie-consent-banner,
    .cookie-settings-modal,
    .cookie-settings-link {
        display: none !important;
    }
}
