#custom-gallery {
  margin: 0;
  padding: 20px;
  font-family: sans-serif;
  background: #f5f5f5;
  display: flex;
  gap: 20px;
  max-width: 1200px;
  margin: auto;
}

#custom-gallery .gallery-sidebar {
  width: 15%;
}

#custom-gallery .category-list {
  list-style: none;
  padding: 0;
  margin: 0;
  transition: transform 0.3s ease;
}

#custom-gallery .category-list li {
  cursor: pointer;
  padding: 10px;
  margin-bottom: 6px;
  background: #EBEBEB;
  color: #0A0700;
  border-radius: 4px;
  text-align: center;
  transition: background-color 0.3s ease, color 0.3s ease, transform 0.2s ease;
}

#custom-gallery .category-list li:hover {
  background: #FFC300;
  color: #fff;
  transform: scale(1.05);
}

#custom-gallery .category-list li.active {
  background: #FFC300;
  color: #fff;
  transform: scale(1.05);
}

#custom-gallery .gallery-content {
  width: 90%;
}

#custom-gallery .image-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  transition: grid-template-columns 0.3s ease;
}

#custom-gallery .gallery-item {
  display: none;
  height: 200px;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

#custom-gallery .gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

#custom-gallery .pagination {
  margin-top: 20px;
  text-align: center;
}

#custom-gallery .pagination button {
  margin: 0 4px;
  padding: 6px 12px;
  border: none;
  background: #ccc;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.2s ease;
}

#custom-gallery .pagination button:hover {
  background: #bbb;
  transform: scale(1.05);
}

#custom-gallery .pagination button.active {
  background: #FFC300;
  color: white;
  transform: scale(1.05);
}

/* Responsive */
@media (max-width: 768px) {
  #custom-gallery {
    flex-direction: column;
  }

  #custom-gallery .gallery-sidebar {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 10px;
    margin-bottom: 10px;
  }

  #custom-gallery .category-list {
    display: flex;
    flex-direction: row;
    gap: 10px;
    white-space: nowrap;
    overflow-x: auto;
    padding: 0 10px;
    scrollbar-width: none;
  }

  #custom-gallery .category-list::-webkit-scrollbar {
    display: none;
  }

  #custom-gallery .category-list li {
    flex: 0 0 auto;
    padding: 10px 16px;
    border-radius: 20px;
  }

  #custom-gallery .gallery-content {
    width: 100%;
  }

  #custom-gallery .image-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  #custom-gallery .gallery-item {
    height: 160px;
  }
}
