.gallery {
    columns: 4; /* Number of columns for the masonry layout */
  column-gap: 10px; /* Gap between columns */
  padding: 20px;
  }
  
  .showimg {
    display: inline-block; /* Ensures items flow into columns */
  margin-bottom: 10px;
  width: 100%; /* Full width within column */
  break-inside: avoid; /* Prevent breaking images between columns */
  }

  .showimg img {
    width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
  }

  /* Responsive adjustments */
@media (max-width: 1024px) {
    .image-item {
      flex: 1 1 30%; /* Three images per row on medium screens */
    }
  }
  
  @media (max-width: 768px) {
    .image-item {
      flex: 1 1 45%; /* Two images per row on mobile */
    }
  }