/* Cookie Consent Banner Styles */
.cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-top: 3px solid #16a34a;
    box-shadow: 0 -10px 25px rgba(0, 0, 0, 0.1);
    z-index: 10000;
    transform: translateY(100%);
    transition: transform 0.3s ease-in-out;
    max-height: 90vh;
    overflow-y: auto;
}

.cookie-consent-banner.show {
    transform: translateY(0);
}

.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.5rem;
}

.cookie-consent-header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    gap: 1rem;
}

.cookie-icon {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: white;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.cookie-consent-header h3 {
    margin: 0;
    color: #1f2937;
    font-size: 1.5rem;
    font-weight: 600;
}

.cookie-consent-body p {
    color: #4b5563;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.cookie-types {
    margin: 1.5rem 0;
    border: 1px solid #e5e7eb;
    border-radius: 0.75rem;
    overflow: hidden;
}

.cookie-type {
    border-bottom: 1px solid #e5e7eb;
}

.cookie-type:last-child {
    border-bottom: none;
}

.cookie-type-header {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    background: #f9fafb;
}

.cookie-type-header h4 {
    margin: 0 0 0.25rem 0;
    color: #1f2937;
    font-size: 1rem;
    font-weight: 600;
}

.cookie-type-header p {
    margin: 0;
    color: #6b7280;
    font-size: 0.875rem;
    line-height: 1.4;
}

/* Custom Toggle Switch */
.cookie-toggle {
    position: relative;
    display: inline-block;
    width: 3rem;
    height: 1.5rem;
    flex-shrink: 0;
    margin-top: 0.125rem;
}

.cookie-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #d1d5db;
    transition: 0.3s;
    border-radius: 1.5rem;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 1.125rem;
    width: 1.125rem;
    left: 0.1875rem;
    bottom: 0.1875rem;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

input:checked+.toggle-slider {
    background-color: #16a34a;
}

input:checked+.toggle-slider:before {
    transform: translateX(1.5rem);
}

.toggle-slider.essential {
    background-color: #16a34a;
    cursor: not-allowed;
}

.toggle-slider.essential:before {
    transform: translateX(1.5rem);
}

/* Action Buttons */
.cookie-consent-actions {
    display: flex;
    gap: 0.75rem;
    margin: 1.5rem 0 1rem 0;
    flex-wrap: wrap;
    justify-content: center;
}

.cookie-consent-actions button {
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    transition: all 0.2s;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: none;
    text-decoration: none;
}

.btn-accept {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: white;
}

.btn-accept:hover {
    background: linear-gradient(135deg, #15803d, #16a34a);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.3);
}

.btn-reject {
    background: #f3f4f6;
    color: #6b7280;
    border: 1px solid #d1d5db;
}

.btn-reject:hover {
    background: #e5e7eb;
    color: #4b5563;
}

.btn-customize {
    background: #3b82f6;
    color: white;
}

.btn-customize:hover {
    background: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.btn-save {
    background: linear-gradient(135deg, #16a34a, #22c55e);
    color: white;
}

.btn-save:hover {
    background: linear-gradient(135deg, #15803d, #16a34a);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.3);
}

.cookie-consent-footer {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

.cookie-consent-footer a {
    color: #16a34a;
    text-decoration: none;
    font-weight: 500;
}

.cookie-consent-footer a:hover {
    text-decoration: underline;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .cookie-consent-content {
        padding: 1rem;
    }

    .cookie-consent-header {
        flex-direction: column;
        text-align: center;
        gap: 0.75rem;
    }

    .cookie-consent-header h3 {
        font-size: 1.25rem;
    }

    .cookie-consent-actions {
        flex-direction: column;
    }

    .cookie-consent-actions button {
        width: 100%;
        justify-content: center;
    }

    .cookie-type-header {
        flex-direction: column;
        gap: 0.75rem;
    }

    .cookie-toggle {
        align-self: flex-start;
    }
}

@media (max-width: 480px) {
    .cookie-consent-banner {
        max-height: 95vh;
    }

    .cookie-consent-content {
        padding: 0.75rem;
    }

    .cookie-icon {
        width: 2.5rem;
        height: 2.5rem;
        font-size: 1rem;
    }

    .cookie-consent-header h3 {
        font-size: 1.125rem;
    }
}

/* Animation for smooth appearance */
@keyframes slideUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.cookie-consent-banner.show {
    animation: slideUp 0.3s ease-out;
}

/* Focus styles for accessibility */
.cookie-consent-actions button:focus,
.cookie-toggle:focus-within {
    outline: 2px solid #16a34a;
    outline-offset: 2px;
}

.cookie-consent-footer a:focus {
    outline: 2px solid #16a34a;
    outline-offset: 2px;
    border-radius: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .cookie-consent-banner {
        border-top-width: 4px;
        background: white;
    }

    .toggle-slider {
        border: 2px solid #000;
    }

    input:checked+.toggle-slider {
        background-color: #000;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {

    .cookie-consent-banner,
    .toggle-slider,
    .toggle-slider:before,
    .cookie-consent-actions button {
        transition: none;
    }
}