
  #masonry {
    column-count: 4;
    column-gap: 1.5rem;
  }

  @media (max-width: 1200px) {
    #masonry {
      column-count: 3;
    }
  }

  @media (max-width: 768px) {
    #masonry {
      column-count: 2;
    }
  }

  @media (max-width: 576px) {
    #masonry {
      column-count: 1;
    }
  }

  .masonry-item {
    break-inside: avoid;
    margin-bottom: 1.5rem;
    transition: opacity 0.3s ease, transform 0.3s ease;
  }

  /* Filter Animation Helper */
  .masonry-item.hidden {
    display: none;
  }

  .masonry-item .card {
    border: none;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }

  .masonry-item .card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
  }

  .masonry-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.5s ease;
  }

  /* Filter Buttons */
  .gallery-filters {
    margin-bottom: 40px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
  }

  .filter-btn {
    padding: 8px 20px;
    border: 2px solid #e9ecef;
    background: #fff;
    color: #555;
    border-radius: 30px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    outline: none;
  }

  .filter-btn:hover,
  .filter-btn.active {
    background: #17a2b8;
    /* Teal Theme */
    border-color: #17a2b8;
    color: #fff;
    box-shadow: 0 4px 10px rgba(23, 162, 184, 0.3);
  }

  .img-caption {
    background: #fff;
    padding: 12px 15px;
    border-top: 1px solid #f0f0f0;
  }

  .img-category {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #17a2b8;
    font-weight: 700;
    display: block;
    margin-bottom: 3px;
  }

  .img-title {
    font-size: 14px;
    color: #333;
    font-weight: 600;
    margin: 0;
    line-height: 1.4;
  }