/* Photos Page Styles */

.photos-page-header {
  background: #3a1f46;
  padding: 15px 0;
  margin-top: 100px;
  margin-bottom: 40px;
  position: relative;
  overflow: visible;
  box-shadow: 0 4px 12px rgba(58, 31, 70, 0.3);
}

.photos-page-title-container {
  display: flex;
  align-items: center;
  gap: 15px;
  position: relative;
}

.photos-icon-large {
  position: absolute;
  left: -90px;
  top: 0;
  transform: translateY(-55%);
  width: 200px;
  height: 200px;
  object-fit: contain;
  z-index: 10;
}

.photos-page-title {
  font-weight: 950;
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: white;
  margin: 0;
  margin-left: 150px;
}

/* Photos Grid */
.photos-page-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 40px;
  padding: 0;
}

.photos-page-card {
  position: relative;
  background: transparent;
  border-radius: 0;
  overflow: visible;
  aspect-ratio: 4/3;
  cursor: pointer;
  perspective: 1000px;
}

.photos-page-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
  width: 100%;
  height: 100%;
}

.photos-page-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.6s ease;
  transform-style: preserve-3d;
}

.photos-page-card:hover .photos-page-card-inner {
  transform: rotateX(180deg);
}

.photos-page-card-front,
.photos-page-card-back {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.photos-page-card-front {
  background: #000;
  z-index: 2;
  transform: rotateX(0deg);
  overflow: hidden;
}

.photos-page-card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.photos-page-card-back {
  background: #ff8670;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
  transform: rotateX(180deg);
}

/* Conteúdo do verso (back) */
.photo-back-icon {
  width: 45px;
  height: 45px;
  border: 3px solid #3a1f46;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
}

.photo-back-icon svg {
  width: 22px;
  height: 22px;
  fill: #3a1f46;
}

.photo-back-title {
  font-size: 14px;
  font-weight: 900;
  line-height: 1.2;
  margin: 0 0 10px 0;
  color: #3a1f46;
  text-transform: uppercase;
  text-align: center;
  word-break: break-word;
}

.photo-back-date {
  font-size: 20px;
  font-weight: 700;
  margin: 0;
  color: white;
}

/* Empty State */
.photos-page-empty {
  text-align: center;
  padding: 60px 20px;
  color: #666;
  font-size: 1.1rem;
}

/* Photo Gallery in Show Page */
.photo-gallery {
  /* increased top and lateral padding for a roomier white area */
  padding: 0 60px 40px 60px;
}

.about-radio-left .about-radio-header {
  padding: 40px 40px 30px 40px;
}

/* Main Image with Navigation */
.photo-gallery-main {
  position: relative;
  margin-bottom: 20px;
}

.photo-gallery-main-image {
  width: 100%;
  background: #000;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.photo-gallery-main-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.gallery-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: 5px solid #ff8670;
  width: 60px;
  height: 70px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  transition: all 0.3s ease;
}

.gallery-btn:hover {
  background: rgba(255, 134, 112, 0.1);
  border-color: #ff8670;
}

.gallery-btn svg {
  width: 36px;
  height: 36px;
  fill: #ff8670;
}

.gallery-btn-prev {
  left: -20px;
}

.gallery-btn-next {
  right: -20px;
}

/* Carousel de Thumbnails */
.photo-gallery-carousel {
  position: relative;
  padding: 0;
}

.photo-gallery-carousel-wrapper {
  width: 100%;
  overflow: hidden;
  padding: 0;
}

.photo-gallery-carousel-track {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 5px 0;
}

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

.photo-gallery-thumbnail {
  flex: 0 0 auto;
  width: calc((100% - 30px) / 4);
  aspect-ratio: 1;
  cursor: pointer;
  border: 3px solid transparent;
  transition: none;
  overflow: hidden;
  box-sizing: border-box;
}

.photo-gallery-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.carousel-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: 5px solid #ff8670;
  width: 60px;
  height: 70px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  z-index: 10;
}

.carousel-nav-btn:hover {
  background: rgba(255, 134, 112, 0.1);
  border-color: #ff8670;
}

.carousel-nav-btn.prev {
  left: -25px;
}

.carousel-nav-btn.next {
  right: -25px;
}

.carousel-nav-btn svg {
  width: 36px;
  height: 36px;
  fill: #ff8670;
}

/* Pagination */
.photos-pagination {
  margin: 40px 0 60px 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .photos-icon-large {
    left: -70px;
    width: 180px;
    height: 180px;
  }

  .photos-page-title {
    margin-left: 120px;
  }

  .photos-page-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
  }

  .photos-page-card {
    aspect-ratio: 4/3;
  }

  .suggested-photos-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .photo-gallery-thumbnail {
    width: calc(50% - 5px);
  }

  .gallery-btn {
    display: none;
  }

  .carousel-nav-btn {
    display: none;
  }

  .photo-gallery-carousel {
    padding: 0;
  }

  .photo-gallery-carousel-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .photo-gallery-carousel-track {
    padding: 5px;
  }
}

@media (max-width: 768px) {
  .photo-gallery {
    padding: 0;
  }

  .photo-gallery-main {
    display: none;
  }

  .photo-gallery-carousel {
    padding: 0;
    margin: 0;
  }

  .photo-gallery-carousel-wrapper {
    overflow-x: scroll;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

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

  .photo-gallery-carousel-track {
    display: flex;
    gap: 0;
    padding: 0;
  }

  .photo-gallery-thumbnail {
    flex: 0 0 100%;
    width: 100%;
    min-width: 100%;
    aspect-ratio: 16 / 10;
    border: none;
    scroll-snap-align: start;
    scroll-snap-stop: always;
  }

  .photo-gallery-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
  }

  .photo-gallery-thumbnail.active {
    border: none;
  }

  .photos-page-header {
    margin-top: 20px;
    padding: 20px 0;
  }

  .photos-icon-large {
    display: none;
  }

  .photos-page-title {
    margin-left: 0;
    font-size: 1rem;
    padding: 0 20px;
  }

  .photos-page-grid {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .photos-page-card {
    aspect-ratio: 4/3;
  }

  .photo-gallery {
    padding: 0 20px 20px 20px;
  }

  .about-radio-left .about-radio-header {
    padding: 30px 20px 20px 20px;
  }

  .photo-gallery-thumbnail {
    width: calc(50% - 5px);
  }

  .gallery-btn {
    display: none;
  }

  .carousel-nav-btn {
    display: none;
  }

  .photo-gallery-carousel {
    padding: 0;
  }
}

@media (max-width: 480px) {
  .photos-page-title {
    font-size: 0.9rem;
  }

  .photo-gallery-thumbnail {
    width: calc(50% - 5px);
  }

  .gallery-btn {
    display: none;
  }

  .carousel-nav-btn {
    display: none;
  }

  .photo-gallery-carousel {
    padding: 0;
  }
}
