/* ── Carousel ── */
.nb-carousel-wrap {
  padding: 0 0 30px 0;
  background: transparent;
  overflow: hidden;
  user-select: none;
  position: relative;
}
.nb-carousel {
  position: relative;
  width: 100%;
  height: calc(var(--nb-h, 440px) + 80px);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: grab;
}
.nb-carousel.is-dragging { cursor: grabbing; }

.nb-slide {
  position: absolute;
  width:  var(--nb-w, 320px);
  height: var(--nb-h, 440px);
  border-radius: var(--nb-r, 20px);
  overflow: hidden;
  flex-shrink: 0;
  transition:
    transform  0.55s cubic-bezier(0.25, 1, 0.35, 1),
    opacity    0.55s cubic-bezier(0.25, 1, 0.35, 1),
    box-shadow 0.55s ease;
  will-change: transform, opacity;
  backface-visibility: hidden;
}

/* ── Image fit modes ── */
.nb-img-wrap { position: absolute; inset: 0; overflow: hidden; }
.nb-img-wrap.fit-auto img {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: auto; height: auto; max-width: none; max-height: none;
  display: block; pointer-events: none;
}
.nb-img-wrap.fit-contain img {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  max-width: 100%; max-height: 100%; width: auto; height: auto;
  display: block; pointer-events: none;
}
.nb-img-wrap.fit-cover img {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 100%; height: 100%;
  object-fit: cover; object-position: center center;
  display: block; pointer-events: none;
}
.nb-img-wrap.fit-custom img {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: var(--nb-img-w,100%); height: var(--nb-img-h,100%);
  object-fit: cover; object-position: center center;
  display: block; pointer-events: none;
}

/* ── Label ── */
.nb-slide-title {
  position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%);
  color: var(--nb-label-color,#fff);
  padding: 9px 20px; border-radius: 12px;
  font-size: var(--nb-label-size,15px);
  white-space: nowrap; backdrop-filter: blur(8px);
  pointer-events: none; z-index: 2;
  background: var(--nb-label-bg,rgba(0,0,0,0.55));
  transition: opacity 0.4s ease;
}
.nb-slide-title.nb-hidden { display: none; }

/* ── Nav buttons ── */
.nb-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: none; border: none;
  color: var(--nb-arrow-color,#d9a441);
  font-size: 34px; cursor: pointer;
  z-index: 100; padding: 10px 20px;
  line-height: 1; transition: opacity 0.2s;
}
.nb-btn:hover { opacity: 0.6; }
.nb-btn.prev  { left: 6px; }
.nb-btn.next  { right: 6px; }

/* ── Category filters ── */
.nb-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: flex-start;
  padding: 0 16px 24px;
  box-sizing: border-box;
}
.nb-filter-btn {
  padding: 8px 20px;
  border-radius: 100px;
  border: 1.5px solid var(--nb-filter-color, #1a3fff);
  background: transparent;
  color: var(--nb-filter-color, #1a3fff);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.22s, color 0.22s, transform 0.15s;
  white-space: nowrap;
  letter-spacing: 0.02em;
  line-height: 1.4;
}
.nb-filter-btn:hover {
  background: var(--nb-filter-color, #1a3fff);
  color: #fff;
  transform: translateY(-1px);
}
.nb-filter-btn.active {
  background: var(--nb-filter-color, #1a3fff);
  color: #fff;
}

/* Mobile masonry-style grid of pills */
@media (max-width: 768px) {
  .nb-filters {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 7px;
    padding: 0 14px 20px;
  }
  .nb-filter-btn {
    padding: 6px 14px;
    font-size: 12px;
  }
  /* Extra cats hidden until "more" is clicked */
  .nb-filter-btn.nb-cat-extra {
    display: none;
  }
  .nb-filter-btn.nb-cat-extra.nb-cat-visible {
    display: inline-block;
  }
  .nb-filter-more {
    padding: 6px 14px;
    border-radius: 100px;
    border: 1.5px dashed var(--nb-filter-color, #1a3fff);
    background: transparent;
    color: var(--nb-filter-color, #1a3fff);
    font-size: 12px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
    white-space: nowrap;
    font-weight: 500;
  }
  .nb-filter-more:hover {
    background: var(--nb-filter-color, #1a3fff);
    color: #fff;
  }
}

/* ── Lightbox ── */
.nb-lightbox {
  display: none; position: fixed; inset: 0;
  z-index: 99999; background: rgba(0,0,0,0.92);
  align-items: center; justify-content: center;
  backdrop-filter: blur(6px);
}
.nb-lightbox.active { display: flex; animation: nb-lb-in 0.25s ease; }
@keyframes nb-lb-in { from{opacity:0} to{opacity:1} }
.nb-lb-inner {
  position: relative; display: flex; align-items: center; justify-content: center;
  width: 100%; height: 100%; padding: 60px 80px; box-sizing: border-box;
}
.nb-lb-img-wrap { position: relative; display: flex; align-items: center; justify-content: center; }
.nb-lb-img-wrap img {
  max-width: 90vw; max-height: 85vh; width: auto; height: auto;
  border-radius: 16px; box-shadow: 0 30px 80px rgba(0,0,0,.7);
  display: block; object-fit: contain;
  animation: nb-img-in 0.3s cubic-bezier(0.33,1,0.68,1);
}
@keyframes nb-img-in { from{opacity:0;transform:scale(0.95)} to{opacity:1;transform:scale(1)} }
.nb-lb-title {
  position: absolute; bottom: -40px; left: 50%; transform: translateX(-50%);
  color: rgba(255,255,255,.65); font-size: 14px; white-space: nowrap;
}
.nb-lb-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15);
  color: #fff; font-size: 26px; width: 52px; height: 52px;
  border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s, transform 0.2s; z-index: 10;
}
.nb-lb-btn:hover { background: rgba(255,255,255,.18); transform: translateY(-50%) scale(1.08); }
.nb-lb-btn.prev { left: 20px; } .nb-lb-btn.next { right: 20px; }
.nb-lb-close {
  position: fixed; top: 20px; right: 24px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.15);
  color: #fff; font-size: 20px; width: 44px; height: 44px;
  border-radius: 50%; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s; z-index: 10;
}
.nb-lb-close:hover { background: rgba(200,50,50,.5); }
.nb-lb-counter {
  position: fixed; top: 24px; left: 50%; transform: translateX(-50%);
  color: rgba(255,255,255,.4); font-size: 13px; letter-spacing: .08em;
}
@media(max-width:768px){
  .nb-lb-inner{padding:60px 50px}
  .nb-lb-btn{width:40px;height:40px;font-size:20px}
  .nb-lb-btn.prev{left:8px} .nb-lb-btn.next{right:8px}
}
