/**
 * Owl Carousel Fallback Styles
 * 
 * Provides basic styling for carousel content when Owl Carousel
 * JavaScript initialization fails in Drupal 11.
 */

/* Basic fallback for failed Owl Carousel initialization */
.owl-carousel-fallback {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  overflow-x: auto;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.owl-carousel-fallback .apb-carousel-item {
  flex: 0 0 auto;
  min-width: 280px;
  max-width: 350px;
}

/* Responsive fallback */
@media (max-width: 768px) {
  .owl-carousel-fallback {
    flex-direction: column;
  }
  
  .owl-carousel-fallback .apb-carousel-item {
    min-width: 100%;
    max-width: 100%;
  }
}

/* Hide broken Owl Carousel controls */
.owl-carousel-fallback .owl-nav,
.owl-carousel-fallback .owl-dots {
  display: none;
}

/* Basic item styling for fallback */
.owl-carousel-fallback .apb-carousel-item-img {
  width: 100%;
  margin-bottom: 1rem;
}

.owl-carousel-fallback .apb-carousel-item-img img {
  width: 100%;
  height: auto;
  border-radius: 4px;
}

/* Loading state */
.owl-carousel:not(.owl-loaded):not(.owl-carousel-fallback) {
  opacity: 0.5;
  pointer-events: none;
}

.owl-carousel.owl-loaded,
.owl-carousel-fallback {
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.3s ease;
}

/* Enhanced accessibility for fallback */
.owl-carousel-fallback:focus-within {
  outline: 2px solid #0073aa;
  outline-offset: 2px;
}

/* Print styles */
@media print {
  .owl-carousel-fallback {
    display: block;
  }
  
  .owl-carousel-fallback .apb-carousel-item {
    display: block;
    width: 100%;
    max-width: 100%;
    margin-bottom: 20px;
    break-inside: avoid;
  }
} 