/* ===================================
   Cookie Consent Bar - GDPR Compliant
   =================================== */

/* Cookie Banner Container */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
  padding: 24px;
  box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.3);
  z-index: 99999;
  transform: translateY(100%);
  opacity: 0;
  transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
  font-family: 'Inter Tight', sans-serif;
}

.cookie-consent.show {
  transform: translateY(0);
  opacity: 1;
}

.cookie-consent-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

/* Cookie Icon */
.cookie-consent-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, #40C6C3 0%, #33a3a0 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  animation: cookie-bounce 2s ease-in-out infinite;
}

.cookie-consent-icon svg {
  width: 28px;
  height: 28px;
  color: white;
}

@keyframes cookie-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

/* Cookie Content */
.cookie-consent-content {
  flex: 1;
  min-width: 280px;
}

.cookie-consent-title {
  font-size: 18px;
  font-weight: 700;
  color: white;
  margin: 0 0 8px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cookie-consent-text {
  font-size: 14px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.8);
  margin: 0;
}

.cookie-consent-text a {
  color: #40C6C3;
  text-decoration: underline;
  transition: color 0.2s ease;
}

.cookie-consent-text a:hover {
  color: #33a3a0;
}

/* Cookie Actions */
.cookie-consent-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* Buttons */
.cookie-btn {
  padding: 12px 24px;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
  font-family: 'Inter Tight', sans-serif;
}

.cookie-btn-accept {
  background: linear-gradient(135deg, #40C6C3 0%, #33a3a0 100%);
  color: white;
  box-shadow: 0 4px 12px rgba(64, 198, 195, 0.3);
}

.cookie-btn-accept:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(64, 198, 195, 0.4);
}

.cookie-btn-reject {
  background: rgba(255, 255, 255, 0.1);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.cookie-btn-reject:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

.cookie-btn-settings {
  background: transparent;
  color: rgba(255, 255, 255, 0.7);
  padding: 12px 16px;
  text-decoration: underline;
}

.cookie-btn-settings:hover {
  color: white;
}

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

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

.cookie-settings-content {
  background: white;
  border-radius: 20px;
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  animation: modal-slide-up 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes modal-slide-up {
  from {
    transform: translateY(50px) scale(0.95);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

/* Modal Header */
.cookie-settings-header {
  padding: 24px;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cookie-settings-header h2 {
  margin: 0;
  font-size: 24px;
  font-weight: 700;
  color: #1f2937;
}

.cookie-settings-close {
  width: 32px;
  height: 32px;
  border: none;
  background: #f3f4f6;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.cookie-settings-close:hover {
  background: #e5e7eb;
  transform: rotate(90deg);
}

.cookie-settings-close svg {
  width: 18px;
  height: 18px;
  color: #6b7280;
}

/* Modal Body */
.cookie-settings-body {
  padding: 24px;
}

.cookie-settings-intro {
  font-size: 14px;
  line-height: 1.6;
  color: #6b7280;
  margin-bottom: 24px;
}

/* Cookie Category */
.cookie-category {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 16px;
  transition: all 0.2s ease;
}

.cookie-category:hover {
  border-color: #40C6C3;
  box-shadow: 0 4px 12px rgba(64, 198, 195, 0.1);
}

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

.cookie-category-title {
  font-size: 16px;
  font-weight: 700;
  color: #1f2937;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.cookie-category-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cookie-category-badge.required {
  background: #fef3c7;
  color: #92400e;
}

.cookie-category-badge.optional {
  background: #dbeafe;
  color: #1e40af;
}

.cookie-category-description {
  font-size: 13px;
  line-height: 1.6;
  color: #6b7280;
  margin: 0;
}

/* Toggle Switch */
.cookie-toggle {
  position: relative;
  width: 48px;
  height: 26px;
  background: #d1d5db;
  border-radius: 13px;
  cursor: pointer;
  transition: background 0.3s ease;
}

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

.cookie-toggle.active {
  background: linear-gradient(135deg, #40C6C3 0%, #33a3a0 100%);
}

.cookie-toggle-slider {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  background: white;
  border-radius: 50%;
  transition: transform 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.cookie-toggle.active .cookie-toggle-slider {
  transform: translateX(22px);
}

/* Modal Footer */
.cookie-settings-footer {
  padding: 24px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

/* Responsive */
@media (max-width: 768px) {
  .cookie-consent-container {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .cookie-consent-actions {
    width: 100%;
  }

  .cookie-btn {
    flex: 1;
    text-align: center;
  }

  .cookie-settings-content {
    margin: 10px;
  }

  .cookie-settings-header h2 {
    font-size: 20px;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  .cookie-settings-content {
    background: #1f2937;
  }

  .cookie-settings-header {
    border-bottom-color: #374151;
  }

  .cookie-settings-header h2 {
    color: white;
  }

  .cookie-settings-close {
    background: #374151;
  }

  .cookie-settings-close:hover {
    background: #4b5563;
  }

  .cookie-settings-close svg {
    color: #d1d5db;
  }

  .cookie-settings-intro {
    color: #d1d5db;
  }

  .cookie-category {
    border-color: #374151;
    background: #111827;
  }

  .cookie-category:hover {
    border-color: #40C6C3;
  }

  .cookie-category-title {
    color: white;
  }

  .cookie-category-description {
    color: #d1d5db;
  }

  .cookie-settings-footer {
    border-top-color: #374151;
  }
}
