/* =========================================
   Dogs list - Page displays dogs in grid
   ========================================= */

   /* dog-list.css */

.page-heading {
  text-align: center;
  font-size: 2rem;
  margin: 2rem 0 0.5rem 0;
}
/* Grid layout */
.dog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  padding: 2rem;
  max-width: 1400px;
  margin: 0 auto;
}

/* Card styling */
.dog-card {
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease;
  position: relative;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  -webkit-user-select: none;
  user-select: none;
}

/* Carousel wrapper */
.carousel-wrapper {
  position: relative;
}

/* Carousel track */
.photo-carousel {
  display: flex;
  overflow-x: scroll;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  width: 100%;
}

.photo-carousel::-webkit-scrollbar {
  display: none;
}

/* Image/video styles */
.photo-carousel img,
.photo-carousel video {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  flex-shrink: 0;
  border-bottom: 1px solid #eee;
}

/* Mobile: disable momentum scrolling and smooth scroll to prevent overshooting */
@media (max-width: 768px) {
  .photo-carousel {
    -webkit-overflow-scrolling: auto;
    scroll-behavior: auto;
  }
}

@media (min-width: 768px) {
  .photo-carousel img,
  .photo-carousel video {
    aspect-ratio: 1.27 / 1;
  }
}

/* Hover buttons - show on hover for non-touch devices */
.carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #ddd;
  font-size: 1.2rem;
  color: #333;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  color: --var(--color-secondary);
  opacity: 0;
  pointer-events: none;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Non-touch devices: show arrows on hover at all screen sizes */
@media (hover: hover) {
  .dog-card:hover .carousel-btn {
    opacity: 1;
    pointer-events: auto;
  }
}

/* Touch devices: hide arrows completely, allow native swiping */
@media (hover: none) {
  .carousel-btn {
    display: none;
  }

  .click-left,
  .click-right {
    pointer-events: none !important; /* allow touch/swipe events to pass through */
  }

  .dog-card:active {
    transform: scale(0.98);
    opacity: 0.95;
  }
}

.prev-btn {
  left: 10px;
}

.next-btn {
  right: 10px;
}

/* Optional photo indicator badge */
.photo-indicator {
  position: absolute;
  top: 8px;
  right: 12px;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  font-size: 0.75rem;
  padding: 3px 8px;
  border-radius: 12px;
  z-index: 2;
  opacity: 0; /* start hidden */
  transition: opacity 0.3s ease;
}


.dog-card:hover .photo-indicator {
  opacity: 1;
}


.carousel-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.carousel-dots .dot {
  width: 8px;
  height: 8px;
  background: #d0d0d0;
  border-radius: 50%;
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-dots .dot.active {
  background: var(--color-primary);
  width: 24px;
  border-radius: 4px;
}

.carousel-dots .dot:hover {
  background: rgba(255, 255, 255, 0.8);
}

/* Card content */
.dog-card-content {
  padding: 1rem;
}

.dog-name-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.dog-name {
  font-size: 1.3rem;
  font-weight: 600;
  margin: 0;
  color: #333;
  flex: 1;
}

.dog-age-gender {
  font-size: 13px;
  font-weight: 500;
  color: #555;
  margin: 0 0 0.4rem 0;
  letter-spacing: 0.3px;
}

.dog-breed,
.dog-location,
.dog-waiting {
  font-size: 14px;
  color: #666;
  margin: 0 0 0.4rem 0;
}

.dog-rescue {
  font-size: 10px;
  color: #999;
  margin: 0.6rem 0 0 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Status tag */
.dog-status {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  border-radius: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.dog-status.available {
  background: rgba(76, 175, 80, 0.2);
  color: #2e7d32;
}

.dog-status.reserved {
  background: rgba(255, 193, 7, 0.2);
  color: #f57f17;
}

.dog-status.adopted {
  background: rgba(100, 100, 100, 0.2);
  color: #424242;
}




/* =========================================
   Control click zones for photo carousel
   ========================================= */

.click-zone {
  position: absolute;
  top: 0;
  height: 100%;
  width: 25%;
  z-index: 2;
  cursor: pointer;
}

/* Always present, but transparent by default */
.click-left,
.click-right {
  position: absolute;
  top: 0;
  height: 100%;
  width: 25%;
  z-index: 2;
  pointer-events: auto; /* ensure they still receive clicks */
  background: transparent;
  transition: background 0.3s ease;
}

/* Optional debug colors - remove later */
.click-left {
  left: 0;
}

.click-right {
  right: 0;
}

/* Left zone: fade from black to transparent */
.carousel-wrapper:hover .click-left {
  background: linear-gradient(to right, rgba(0, 0, 0, 0.1), transparent);
  cursor: pointer;
}

/* Right zone: fade from black to transparent */
.carousel-wrapper:hover .click-right {
  background: linear-gradient(to left, rgba(0, 0, 0, 0.1), transparent);
  cursor: pointer;
}

/* Aug 2026 - "no dogs yet" onboarding message, shown in place of the dog
   grid when the database has zero dogs (dog list page + homepage featured
   section). Styled as a soft card so it reads as an intentional message
   rather than an empty page. */
.no-dogs-message {
  grid-column: 1 / -1;
  text-align: center;
  max-width: 560px;
  margin: 2rem auto;
  padding: 2.5rem 2rem;
  background-color: var(--color-background-muted);
  border-radius: 1rem;
}

.no-dogs-message h3 {
  font-size: 1.25rem;
  color: var(--color-secondary);
  margin-bottom: 1rem;
}

.no-dogs-message p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--color-text-main);
  margin-bottom: 1rem;
}

.no-dogs-message p:last-child {
  margin-bottom: 0;
}

.no-dogs-message .no-dogs-cta {
  display: inline-block;
  padding: 0.6rem 1.5rem;
  background-color: var(--color-primary);
  color: var(--color-text-light);
  border-radius: 0.5rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}

.no-dogs-message .no-dogs-cta:hover {
  background-color: #ff5630;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 110, 74, 0.3);
}

.no-dogs-message .no-dogs-followup {
  margin-top: 1.5rem;
  margin-bottom: 0;
}