/* === General Layout === */
.photo-gallery {
    width: 100%;
    height: 90vh;
    display: flex;
    flex-direction: row;
    overflow: hidden;
    background-color: #f8f9fa;
    align-items: stretch;
}

/* Left Box: Carousel + Story */
.gallery-left {
    display: flex;
    flex-direction: column;
    width: 70%;
    aspect-ratio: 3 / 2;
}

/* Carousel images: maintain aspect ratio and cover */
#photoCarousel img {
    width: 100%;
    height: auto;
    object-fit: cover;
}

.carousel-caption {
    top:10%;
    bottom: auto;
}

#gallery-summary {
    background-color: #191919;
    color: white;
    padding: 30px;
    display: flex;
    justify-content: center;
}

#gallery-summary p {
    height: 100%;
    margin: 0;
    font-family: 'Fira Sans Extra Condensed', sans-serif;
    font-size: 1rem;
}

/* Story area below carousel */
.photo-story {
    overflow-y: auto;
    padding: 0.5rem;
    font-family: 'Fira Sans Extra Condensed', sans-serif;
    font-size: 1rem;
    color: #333;
    width: 20%;    
}

/* Right Box: Control Bar */
.gallery-right {
    display: flex;
    flex-direction: column;
    width: 10%;
    padding: .5rem;
    border-left: 1px solid #ccc;
    box-sizing: border-box;
    background-color: #ffffff;
    font-family: 'Fira Sans Extra Condensed', sans-serif;
    font-size: 0.9rem;
}

/* Control bar labels and selects */
.gallery-right h5 {
    margin-bottom: 1rem;
    font-weight: 700;
}

.gallery-right label {
    font-weight: 500;
    margin-top: 0.5rem;
}

.gallery-right select.form-control {
    margin-bottom: 1rem;
    font-size: 0.9rem;
    padding: 0.25rem 0.5rem;
}

.gallery-right,
.photo-story {
  flex: 1 1 auto;
  overflow-y: auto; /* if content taller than image */
}

.filter-group {
    display: flex;
    flex-direction: column;
}

/* Carousel controls styling */
.carousel-control-prev-icon,
.carousel-control-next-icon {
    background-color: rgba(0,0,0,0.5);
    border-radius: 50%;
    width: 2rem;
    height: 2rem;
}

.carousel-item img {
    aspect-ratio: 6 / 4;
    object-fit: cover;
}

/* Scrollbar styling for story box */
.photo-story::-webkit-scrollbar {
    width: 8px;
}

.photo-story::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.photo-story::-webkit-scrollbar-thumb {
    background-color: #888;
    border-radius: 4px;
}

.photo-story::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Container spacing */
.smugmug-link-container {
  margin: 10px 0;
  text-align: center; /* Center inside gallery-right */
}

/* Button style */
.smugmug-link {
  display: inline-block;
  padding: 5px;
  background-color: #2c3e50; /* Dark slate */
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  border-radius: 6px;
  transition: background-color 0.3s, transform 0.2s;
}

.smugmug-link:hover {
  background-color: #34495e; /* Slightly lighter */
  transform: translateY(-2px); /* subtle lift */
}

/* Container spacing */
.photo-permission-container {
  margin: 10px 0;
  text-align: center;
}

/* Link style */
.photo-permission-link {
  display: inline-block;
  font-size: 0.8rem;
  color: #2c3e50;
  text-decoration: underline;
  transition: color 0.2s;
}

.photo-permission-link:hover {
  color: #34495e; /* subtle hover color */
}

.story-header {
    display: flex;
    align-items: center;
    font-size: 1.5rem; /* adjust if needed */
}

#audioButton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.25rem 0.5rem;
    font-size: 1rem;
    cursor: pointer;
}

.sidebar-divider {
  border: none;
  border-top: 1px solid #ccc;
  margin: 0.75rem 0;
}

#applyFiltersBtn.btn-primary {
  background-color: #0a58ca; /* darker blue for better contrast */
  color: #ffffff;           /* keep text pure white */
  font-weight: 600;         /* slightly bolder text */
  text-shadow: 0 1px 2px rgba(0,0,0,0.4); /* extra pop */
}

#gallery-summary p {
    width: 50%;
}

#gallery-summary {
    display: flex;
    justify-content: center;
    align-items: center;
}

#smugmuglink {
    color: white;
    text-decoration: underline;
}


/* Responsive adjustments */
@media (max-width: 769px) {
    .photo-gallery {
        flex-direction: column;
        height: auto;
    }

    .gallery-left {
        flex: 0 0 auto;
        width: 100%;
    }

    .gallery-right {
        flex: 0 0 auto;
        width: 100%;
        border-left: none;
        border-top: 1px solid #ccc;
        flex-direction: row;
        justify-content: space-around;
        padding: 0.5rem;
        order: -1;
        flex-wrap: wrap;
        align-items: center;
    }

      /* stop items from stretching */
    .gallery-right > * { flex: 0 0 auto; }

    /* kill Bootstrap’s 100% width on selects/inputs here */
    .gallery-right .form-control {
    width: auto !important;
    display: inline-block;
    }

    /* tidy labels so they sit inline */
    .gallery-right label {
    display: inline-block;
    margin: 0 .5rem 0 0;
    }

    .photo-story {
        column-count: 1;
        width: 100%;
    }
    .sidebar-divider {
      border: none;
      border-top: 1px solid #ccc;
      width: 100%;
      margin: 0.75rem 0;
      flex-basis: 100%; /* ensures it takes full width in flex row layout */
    }
}
