.project-item {
  transition: opacity 180ms ease, filter 180ms ease;
  cursor: pointer;
}

.project-item img {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-item:hover img {
  transform: scale(1.05);

}

.project-item.disabled {
  opacity: 0.35;
  filter: grayscale(100%);
  pointer-events: none;
  user-select: none;
  cursor: not-allowed;
}

.project-item img[data-src] {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: lazy-loading-shimmer 1.5s infinite;
  min-height: 200px;
}

@keyframes lazy-loading-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.project-item img.lazy-loaded {
  animation: lazy-fade-in 0.4s ease-in;
}

@keyframes lazy-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

.project-item img.lazy-error {
  background: #ffebee;
  border: 1px dashed #d32f2f;
}

.project-item.disabled a,
.project-item.disabled button {
  pointer-events: none;
}

.project-item[aria-disabled="true"] {
  outline: none;
}

.project-item p {
  margin-top: 1.94444444em;
  line-height: 1rem;
  text-align: center;
}

#project-detail {
  display: block;
  margin-bottom: 1.5rem;
}

#project-detail #project-title {
  margin-bottom: 0.5rem;
}

#project-detail #project-partners {
  margin-bottom: 1rem;
  font-size: 0.95rem;
  line-height: 1.5;
}

#project-detail .partners-label {
  font-weight: 500;
}

#project-detail .partners-list {
  color: var(--pink);
}

#project-detail #project-description {
  margin-bottom: 3rem;
  max-width: 60ch;
  line-height: 1.6rem;
}

#project-detail #project-images {
  display: block;
}

#project-detail .project-media-item {
  width: 100%;
  margin: 1rem 0;
}

#project-detail #project-image-grid {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  column-count: 1;
  column-gap: 1rem;
}

@media (min-width: 900px) {
	#project-detail #project-image-grid {
		column-count: 2;
	}
}

@media (min-width: 1400px) {
	#project-detail #project-image-grid {
		column-count: 3;
	}
}

#project-detail .project-image-item {
	display: inline-block;
	width: 100%;
	margin-bottom: 1rem;
	break-inside: avoid;
	page-break-inside: avoid;
}

#project-detail .project-image-item img {
	display: block;
	width: 100%;
	height: auto;
	object-fit: cover;
}

#project-detail .project-image-item video {
	display: block;
	width: 100%;
	height: auto;
}

/* Lightbox / Image Gallery Styles */
.lightbox {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background: rgba(0, 0, 0, 0.95);

/* ========== RESPONSIVE MEDIA QUERIES ========== */

/* Tablets */
@media (max-width: 768px) {
  #project-detail #project-description {
    max-width: 100%;
    line-height: 1.5rem;
    font-size: 0.95rem;
  }
  
  #project-detail #project-title {
    font-size: 1.8em;
  }
  
  #project-detail #project-partners {
    font-size: 0.9rem;
  }
  
  #project-detail #project-image-grid {
    column-count: 1;
    column-gap: 0.75rem;
  }
  
  .project-item p {
    font-size: 0.9rem;
    margin-top: 1rem;
  }
}

/* Mobile phones */
@media (max-width: 480px) {
  #project-detail {
    margin-bottom: 1rem;
  }
  
  #project-detail #project-title {
    font-size: 1.5em;
    margin-bottom: 0.3rem;
  }
  
  #project-detail #project-description {
    margin-bottom: 2rem;
    line-height: 1.4rem;
    font-size: 0.9rem;
  }
  
  #project-detail #project-partners {
    font-size: 0.85rem;
    margin-bottom: 0.75rem;
  }
  
  #project-detail #project-image-grid {
    column-gap: 0.5rem;
  }
  
  #project-detail .project-image-item {
    margin-bottom: 0.5rem;
  }
  
  .project-item {
    min-height: 200px;
  }
  
  .project-item p {
    font-size: 0.85rem;
    margin-top: 0.75rem;
  }
  
  .project-item img[data-src] {
    min-height: 150px;
  }
}
	z-index: 10000;
	opacity: 0;
	transition: opacity 0.3s ease;
}

.lightbox.active {
	display: flex;
	align-items: center;
	justify-content: center;
	opacity: 1;
}

.lightbox-content {
	position: relative;
	max-width: 90vw;
	max-height: 90vh;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
}

.lightbox-image {
	max-width: 100%;
	max-height: 85vh;
	width: auto;
	height: auto;
	object-fit: contain;
	display: block;
	user-select: none;
}

.lightbox-counter {
	color: white;
	font-size: 0.9rem;
	margin-top: 1rem;
	text-align: center;
	font-family: 'Pixelify Sans', monospace;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
	position: fixed;
	background: rgba(255, 255, 255, 0.1);
	color: white;
	border: 1px solid rgba(255, 255, 255, 0.3);
	font-size: 2rem;
	width: 50px;
	height: 50px;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	transition: background 0.2s ease, transform 0.2s ease;
	z-index: 10001;
	padding: 0;
	line-height: 1;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
	background: rgba(255, 255, 255, 0.2);
	transform: scale(1.1);
}

.lightbox-close {
	top: 20px;
	right: 20px;
	border-radius: 50%;
	font-size: 2.5rem;
}

.lightbox-prev {
	left: 20px;
	top: 50%;
	transform: translateY(-50%);
	border-radius: 4px;
}

.lightbox-prev:hover {
	transform: translateY(-50%) scale(1.1);
}

.lightbox-next {
	right: 20px;
	top: 50%;
	transform: translateY(-50%);
	border-radius: 4px;
}

.lightbox-next:hover {
	transform: translateY(-50%) scale(1.1);
}

/* Mobile adjustments */
@media (max-width: 768px) {
	.lightbox-close {
		top: 10px;
		right: 10px;
		width: 40px;
		height: 40px;
		font-size: 2rem;
	}
	
	.lightbox-prev,
	.lightbox-next {
		width: 40px;
		height: 40px;
		font-size: 1.5rem;
	}
	
	.lightbox-prev {
		left: 10px;
	}
	
	.lightbox-next {
		right: 10px;
	}
	
	.lightbox-image {
		max-height: 80vh;
	}
}

main > h1 {
	margin-bottom: 1rem;
}
