/* rentnbuy Sync Frontend Styles */

.rentnbuy-grid-section {
  width: 100%;
  margin: 0 auto;
}

/* Title with arrow link styling */
.rentnbuy-grid-section a.group:hover::after {
  width: 100%;
}

/* Slider controls styling - matching main app */
.rentnbuy-slider-controls-desktop,
.rentnbuy-slider-controls-mobile {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.rentnbuy-slider-prev,
.rentnbuy-slider-next {
  cursor: pointer;
  transition: all 0.2s ease;
}

.rentnbuy-slider-prev:disabled,
.rentnbuy-slider-next:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.rentnbuy-grid-wrapper {
  width: 100%;
  margin: 0 auto;
}

.rentnbuy-grid-wrapper .splide__slide {
  height: auto;
}

.rentnbuy-grid-wrapper .splide__list {
  display: flex;
  align-items: stretch;
}

.rentnbuy-grid-wrapper .splide__slide > div {
  height: 100%;
  display: flex;
  flex-direction: column;
}

/* Font family for Outfit font (matching main app) */
.rentnbuy-grid-section h1 {
  font-family: "Outfit", -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

.rentnbuy-grid-section p {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

/* Image Carousel Styles */
.rentnbuy-image-carousel {
  width: 100%;
  height: 100%;
  position: relative;
}

.rentnbuy-image-carousel .splide__track {
  height: 100%;
}

.rentnbuy-image-carousel .splide__list {
  height: 100%;
}

.rentnbuy-image-carousel .splide__slide {
  height: 100%;
}

.rentnbuy-image-carousel .splide__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Pagination dots for image carousel - prevent wrapping, with spacing */
.rentnbuy-image-carousel .splide__pagination {
  bottom: 0.75rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex !important;
  justify-content: center;
  align-items: center;
  flex-wrap: nowrap !important;
  gap: 0.4rem; /* Increased spacing between dots */
  max-width: calc(100% - 4rem); /* Leave space for arrows */
  padding: 0 1rem;
  overflow: visible;
}

.rentnbuy-image-carousel .splide__pagination__page {
  width: 0.35rem;
  height: 0.35rem;
  min-width: 0.35rem;
  min-height: 0.35rem;
  max-width: 0.35rem;
  max-height: 0.35rem;
  background: rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  margin: 0 !important;
  opacity: 0.7;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.rentnbuy-image-carousel .splide__pagination__page.is-active {
  background: #fff;
  opacity: 1;
  transform: scale(1.2);
}

/* Apply configurable badge color to pagination dots - allow inline styles to override */
.rentnbuy-image-carousel-pagination .splide__pagination__page {
  background: rgba(255, 255, 255, 0.5) !important;
}

.rentnbuy-image-carousel-pagination .splide__pagination__page.is-active {
  /* Inline style from JS will override this */
  background: var(--rentnbuy-badge-color, #22c55e);
  opacity: 1;
}

/* Image carousel navigation buttons */
.rentnbuy-image-carousel-prev,
.rentnbuy-image-carousel-next {
  transition: all 0.2s ease;
  display: none !important; /* Hidden by default, shown via JS on desktop */
}

@media (min-width: 768px) {
  .rentnbuy-image-carousel-prev,
  .rentnbuy-image-carousel-next {
    display: flex !important;
  }
}

.rentnbuy-image-carousel-prev:hover,
.rentnbuy-image-carousel-next:hover {
  background: rgba(255, 255, 255, 0.9) !important;
}

/* Icon sizing - ensure icons match PropertyCard style */
.rentnbuy-grid-section .size-6 {
  width: 1.5rem;
  height: 1.5rem;
  flex-shrink: 0;
}

.rentnbuy-grid-section .size-3 {
  width: 0.75rem;
  height: 0.75rem;
  overflow: visible; /* Allow icon to overflow container */
}

.rentnbuy-grid-section .size-4 {
  width: 1rem;
  height: 1rem;
  overflow: visible; /* Allow icon to overflow container */
}

/* Ensure SVG icons can resize properly */
.rentnbuy-grid-section svg.size-6 {
  width: 1.5rem !important;
  height: 1.5rem !important;
  max-width: 1.5rem;
  max-height: 1.5rem;
  display: block;
}

/* Ensure proper spacing for specs icons */
.rentnbuy-grid-section .flex.items-center.gap-1 {
  gap: 0.25rem;
}

.rentnbuy-grid-section .flex.items-center.gap-2 {
  gap: 0.5rem;
}
