
.gallery {
    position: relative;
    max-width: 100%;
    margin: 4rem auto;
  }
  
  .gallery-viewport {
    position: relative; /* 🔥 very important so fades position correctly */
    overflow: hidden;
  }
  
  .fade-left, .fade-right {
    position: absolute;
    top: 0;
    width: 20%;
    height: 100%;
    z-index: 2;
    pointer-events: none; /* don't block clicks */
  }
  
  .fade-left {
    left: 0;
    background: linear-gradient(to right, var(--cream) 0%, rgb(255 255 255 / 0%) 100%);
  }
  
  .fade-right {
    right: 0;
    background: linear-gradient(to left, var(--cream) 0%, rgb(255 255 255 / 0%) 100%);
  }
  
  .gallery-track {
    display: flex;
    transition: transform 0.5s ease;
  }
  
  .gallery-track img {
    flex-shrink: 0;
    width: clamp(150px, 25vw, 300px);
    height: 300px;
    object-fit: cover;
    margin-right: 0.5%;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
  }
  
  .gallery-track img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 16px rgb(0 0 0 / 20%);
  }
  
  .gallery button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgb(255 246 230 / 0%);
    border: none;
    color: rgb(0 0 0);
    font-size: 2rem;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 3;
  }
  
  .gallery .prev {
    left: 0;
  }
  
  .gallery .next {
    right: 0;
  }
  
  .lightbox {
    display: none; /* hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgb(0 0 0 / 80%); /* dark overlay */
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
  }
  
  .lightbox img {
    max-width: 90%;
    max-height: 90%;
    box-shadow: 0 8px 24px rgb(0 0 0 / 30%);
    border-radius: 10px;
  }