/* for cookie consent banner */
.cookie-consent-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(135deg, #232936 0%, #1a1f2e 100%);
  color: #f3f4f8;
  padding: 1rem 0;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
  border-top: 2px solid #ffb347;
  z-index: 1050;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.cookie-consent-banner.hide {
  transform: translateY(100%);
}

.cookie-consent-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.cookie-consent-text {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
}

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

.cookie-message h4 {
  margin: 0 0 0.25rem 0;
  font-size: 1.1rem;
  font-weight: 600;
  color: #fff;
}

.cookie-message p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.4;
  color: #b0b3c2;
}

.cookie-message a {
  color: #ffb347;
  text-decoration: none;
  font-weight: 500;
}

.cookie-message a:hover {
  color: #ff9f43;
  text-decoration: underline;
}

.cookie-consent-actions {
  display: flex;
  gap: 0.75rem;
  flex-shrink: 0;
}

.cookie-consent-actions .btn {
  font-size: 0.875rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.2s ease;
}

.cookie-btn-accept {
  background: #ffb347 !important;
  border-color: #ffb347 !important;
  color: #232936 !important;
}

.cookie-btn-accept:hover {
  background: #ff9f43 !important;
  border-color: #ff9f43 !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(255, 179, 71, 0.3);
}

.cookie-btn-decline {
  background: transparent !important;
  border-color: #6c757d !important;
  color: #6c757d !important;
}

.cookie-btn-decline:hover {
  background: #6c757d !important;
  color: #fff !important;
}

.cookie-btn-settings {
  background: transparent !important;
  border-color: #b0b3c2 !important;
  color: #b0b3c2 !important;
}

.cookie-btn-settings:hover {
  background: #b0b3c2 !important;
  color: #232936 !important;
}

/* Cookie Settings Modal Styles */
.cookie-category {
  background: rgba(255, 179, 71, 0.05);
  border: 1px solid rgba(255, 179, 71, 0.1);
  border-radius: 0.5rem;
  padding: 1rem;
}

.cookie-category h6 {
  font-weight: 600;
}

.cookie-category .form-switch .form-check-input {
  background-color: #6c757d;
  border-color: #6c757d;
}

.cookie-category .form-switch .form-check-input:checked {
  background-color: #ffb347;
  border-color: #ffb347;
}

.cookie-category .form-switch .form-check-input:focus {
  box-shadow: 0 0 0 0.25rem rgba(255, 179, 71, 0.25);
}

/* Success Toast */
.cookie-success-toast {
  position: fixed;
  top: 20px;
  right: 20px;
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: white;
  padding: 0.75rem 1.25rem;
  border-radius: 0.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  z-index: 1060;
  transform: translateX(400px);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-weight: 500;
}

.cookie-success-toast.show {
  transform: translateX(0);
}

.cookie-success-toast.hide {
  transform: translateX(400px);
}

.toast-content {
  display: flex;
  align-items: center;
}

/* Responsive Design */
@media (max-width: 768px) {
  .cookie-consent-content {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

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

  .cookie-consent-actions {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }

  .cookie-consent-actions .btn {
    font-size: 0.8rem;
    padding: 0.4rem 0.8rem;
  }

  .cookie-message h4 {
    font-size: 1rem;
  }

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

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

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

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

  .cookie-consent-actions .btn {
    flex: 1;
    min-width: 80px;
  }

  .cookie-success-toast {
    right: 10px;
    left: 10px;
    transform: translateY(-100px);
  }

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

  .cookie-success-toast.hide {
    transform: translateY(-100px);
  }
}

/* Dark theme adjustments */
[data-bs-theme="dark"] .cookie-consent-banner {
  background: linear-gradient(135deg, #232936 0%, #1a1f2e 100%);
  border-top-color: #ffb347;
}

[data-bs-theme="light"] .cookie-consent-banner {
  background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
  color: #232936;
  border-top-color: #ffb347;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
}

[data-bs-theme="light"] .cookie-message h4 {
  color: #232936;
}

[data-bs-theme="light"] .cookie-message p {
  color: #6c757d;
}

[data-bs-theme="light"] .cookie-category {
  background: rgba(255, 179, 71, 0.08);
  border-color: rgba(255, 179, 71, 0.15);
}

/* Cookie preferences link in footer */
.cookie-preferences-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #b0b3c2;
  text-decoration: none;
  font-size: 0.9rem;
  transition: color 0.2s ease;
}

.cookie-preferences-link:hover {
  color: #ffb347;
  text-decoration: none;
}

.cookie-preferences-link i {
  font-size: 1rem;
}

/* Animation for cookie icon */
@keyframes cookieBounce {
  0%,
  20%,
  53%,
  80%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  40%,
  43% {
    transform: translate3d(0, -8px, 0);
  }
  70% {
    transform: translate3d(0, -4px, 0);
  }
  90% {
    transform: translate3d(0, -2px, 0);
  }
}

.cookie-icon:hover {
  animation: cookieBounce 1s ease-in-out;
}

/* Accessibility improvements */
.cookie-consent-banner:focus-within {
  outline: 2px solid #ffb347;
  outline-offset: 2px;
}

.cookie-consent-actions .btn:focus {
  box-shadow: 0 0 0 0.25rem rgba(255, 179, 71, 0.25);
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .cookie-consent-banner {
    border-top-width: 3px;
  }

  .cookie-consent-actions .btn {
    border-width: 2px;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .cookie-consent-banner,
  .cookie-success-toast,
  .cookie-consent-actions .btn {
    transition: none;
  }

  .cookie-icon:hover {
    animation: none;
  }
}
