/**
 * Cookie Consent Banner Styles
 * GDPR-compliant cookie consent UI
 */

/* Banner Container */
.cookie-consent-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: #f8fafc;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    z-index: 99999;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Lexend', -apple-system, BlinkMacSystemFont, sans-serif;
}

.cookie-consent-banner.visible {
    transform: translateY(0);
}

.cookie-consent-banner.hidden {
    display: none;
}

/* Banner Content Layout */
.cookie-consent-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

/* Text Content */
.cookie-consent-text {
    flex: 1;
    min-width: 280px;
}

.cookie-consent-text h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    font-weight: 600;
    color: #f8fafc;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-consent-text h4 i {
    color: #60a5fa;
}

.cookie-consent-text p {
    margin: 0;
    font-size: 0.875rem;
    color: #cbd5e1;
    line-height: 1.5;
}

.cookie-consent-text a {
    color: #60a5fa;
    text-decoration: none;
    transition: color 0.2s;
}

.cookie-consent-text a:hover {
    color: #93c5fd;
    text-decoration: underline;
}

/* Buttons Container */
.cookie-consent-buttons {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

/* Button Base Styles */
.cookie-consent-btn {
    padding: 0.625rem 1.25rem;
    border-radius: 8px;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: inherit;
    white-space: nowrap;
}

/* Accept All Button */
.cookie-consent-btn.accept-all {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.3);
}

.cookie-consent-btn.accept-all:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

/* Essential Only Button */
.cookie-consent-btn.essential-only {
    background: transparent;
    color: #e2e8f0;
    border: 1px solid #475569;
}

.cookie-consent-btn.essential-only:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: #64748b;
}

/* Customize Button */
.cookie-consent-btn.customize {
    background: transparent;
    color: #94a3b8;
    border: none;
    padding: 0.625rem 0.75rem;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.cookie-consent-btn.customize:hover {
    color: #e2e8f0;
}

/* Preferences Modal */
.cookie-preferences-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.cookie-preferences-modal.visible {
    opacity: 1;
    visibility: visible;
}

.cookie-preferences-content {
    background: #1e293b;
    border-radius: 16px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.cookie-preferences-header {
    padding: 1.5rem;
    border-bottom: 1px solid #334155;
}

.cookie-preferences-header h3 {
    margin: 0;
    font-size: 1.25rem;
    color: #f8fafc;
}

.cookie-preferences-header p {
    margin: 0.5rem 0 0 0;
    font-size: 0.875rem;
    color: #94a3b8;
}

.cookie-preferences-body {
    padding: 1.5rem;
}

/* Cookie Category */
.cookie-category {
    padding: 1rem;
    background: #0f172a;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.cookie-category:last-child {
    margin-bottom: 0;
}

.cookie-category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.cookie-category-info h4 {
    margin: 0;
    font-size: 0.9375rem;
    color: #f8fafc;
    font-weight: 500;
}

.cookie-category-info p {
    margin: 0.25rem 0 0 0;
    font-size: 0.8125rem;
    color: #94a3b8;
}

/* Toggle Switch */
.cookie-toggle {
    position: relative;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}

.cookie-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #475569;
    border-radius: 24px;
    transition: all 0.3s ease;
}

.cookie-toggle-slider::before {
    content: '';
    position: absolute;
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.cookie-toggle input:checked + .cookie-toggle-slider {
    background: #3b82f6;
}

.cookie-toggle input:checked + .cookie-toggle-slider::before {
    transform: translateX(20px);
}

.cookie-toggle input:disabled + .cookie-toggle-slider {
    opacity: 0.6;
    cursor: not-allowed;
}

.cookie-required-badge {
    font-size: 0.6875rem;
    color: #94a3b8;
    background: #334155;
    padding: 0.125rem 0.5rem;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Modal Footer */
.cookie-preferences-footer {
    padding: 1.5rem;
    border-top: 1px solid #334155;
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
}

/* Responsive */
@media (max-width: 640px) {
    .cookie-consent-banner {
        padding: 1rem;
    }

    .cookie-consent-content {
        flex-direction: column;
        text-align: center;
    }

    .cookie-consent-buttons {
        width: 100%;
        justify-content: center;
    }

    .cookie-consent-btn {
        flex: 1;
        min-width: 120px;
    }

    .cookie-preferences-content {
        max-height: 80vh;
    }
}
