.gallery-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

/* Gallery grid styles */
.galleries-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  box-sizing: border-box;
}

.gallery-card {
  border-radius: 12px;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.gallery-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.gallery-card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.gallery-content {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  background-color: var(--pico-card-background-color);
}

.gallery-name {
  margin: 0 0 0.75rem 0;
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.3;
}

.breadcrumbs {
  top: -3rem;
  position: relative;
  display: block;
  padding-left: 1rem;
}

.bi {
  padding-right: 5px;
}

/* Gallery view styles */
.back-link {
  display: inline-block;
  margin: 1rem;
  text-decoration: none;
  color: #333;
  font-weight: 500;
}

.back-link:hover {
  text-decoration: underline;
}

.gallery-info {
  margin: 1rem 0 2.5rem;
}

.gallery-title {
  margin-bottom: 0;
}

.gallery-tags {
  margin-left: 0.5rem;
}

.gallery-description {
  margin: 1rem 0;
}

/* new mansory css   */

#mansory-wraper {
  margin: 0 auto;
  box-sizing: border-box;
}

#masonry-container {
  width: 100%;
  margin: 0;
  box-sizing: border-box;
}
.masonry-item {
  position: relative; /* IMPORTANT FOR LAZY LOADING XDD */
}

.masonry-item.after-layout {
  position: absolute;
}

.masonry-item-content {
  position: relative;
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
}
.masonry-item a {
  position: relative;
  top: 0;
  left: 0;
  width: 100%;
  height: 0px;
  display: block;
  margin-bottom: 100%; /* IMPORTANT FOR LAZY LOADING XDD */
}

.masonry-item.after-layout div a {
  margin-bottom: 0; /* IMPORTANT FOR LAZY LOADING XDD */
}

.masonry-item a:has(img.loaded) {
  height: 100%; /* IMPORTANT FOR LAZY LOADING XDD */
}

.masonry-item img {
  position: relative;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  display: block;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.masonry-item img.loaded {
  opacity: 1;
}
.placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    110deg,
    var(--pico-muted-border-color, #ececec) 30%,
    var(--pico-form-element-background-color, #f5f5f5) 50%,
    var(--pico-muted-border-color, #ececec) 60%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s linear infinite;
}
@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}
