.portfolio-gallery-wrap {
  position: relative;
  min-height: 280px;
}

.portfolio-loading {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  background: rgba(14, 14, 14, 0.72);
  backdrop-filter: blur(6px);
}

.portfolio-loading.hidden {
  display: none;
}

.portfolio-spinner {
  width: 44px;
  height: 44px;
  border: 2px solid rgba(197, 160, 89, 0.2);
  border-top-color: #c5a059;
  border-radius: 50%;
  animation: ff-portfolio-spin 0.75s linear infinite;
}

.portfolio-loading p {
  font-family: "Hanken Grotesk", sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(245, 242, 240, 0.65);
}

@keyframes ff-portfolio-spin {
  to {
    transform: rotate(360deg);
  }
}

#portfolio-grid.portfolio-grid--loading {
  opacity: 0.35;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

.gallery-item {
  transition: opacity 0.35s ease;
}

.portfolio-pagination {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.25rem;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(197, 160, 89, 0.12);
}

.portfolio-pagination.hidden {
  display: none;
}

.portfolio-pagination-info {
  font-size: 0.65rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.portfolio-pagination-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.portfolio-page-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.portfolio-page-btn,
.portfolio-page-num {
  font-family: "Hanken Grotesk", sans-serif;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border: 1px solid rgba(197, 160, 89, 0.35);
  background: rgba(13, 13, 13, 0.8);
  color: #f5f2f0;
  padding: 0.65rem 1rem;
  min-width: 2.5rem;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
}

.portfolio-page-num {
  padding: 0.65rem 0.85rem;
}

.portfolio-page-btn:hover:not(:disabled),
.portfolio-page-num:hover {
  border-color: #c5a059;
  color: #c5a059;
}

.portfolio-page-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.portfolio-page-num.active {
  background: rgba(197, 160, 89, 0.18);
  border-color: #c5a059;
  color: #c5a059;
}
