﻿/* Gallery-only presentation. Original photos and site-wide styles stay intact. */
#referenciak .project-grid,
#referenciak .project-grid.is-filtered {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: 1fr;
  gap: 24px;
}
#referenciak .project-grid .project {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  margin: 0;
  grid-column: auto;
  grid-row: auto;
  aspect-ratio: auto;
  border: 1px solid #30383e;
  background: #11161a;
}
#referenciak .project-grid .project-image-link {
  position: relative;
  inset: auto;
  display: block;
  flex: none;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: #171d21;
}
#referenciak .project-grid .project-image-link img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--cover-position, 50% 50%);
  filter: none;
}
#referenciak .project-grid .project figcaption {
  position: static;
  inset: auto;
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 20px;
  background: none;
}
#referenciak .project-grid .project figcaption > span {
  min-height: 28px;
  margin: 0 0 8px;
  font-size: 10px;
  line-height: 14px;
  letter-spacing: 1.2px;
}
#referenciak .project-grid .project figcaption > strong {
  min-height: 48px;
  margin: 0;
  font-size: 18px;
  line-height: 24px;
}
#referenciak .project-grid .project-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  gap: 10px;
  margin-top: 18px;
}
#referenciak .project-grid .project-details,
#referenciak .project-grid .project-quote {
  font-size: 11px;
  white-space: nowrap;
}
#referenciak .project-grid .project-quote {
  align-self: auto;
  margin: 0;
  text-align: center;
}
#referenciak .project-grid a:focus-visible {
  outline: 2px solid #edf1f3;
  outline-offset: -3px;
}
/* Project views always contain the whole image; only home covers are cropped. */
.reference-page .reference-photos .photo-zoom {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  aspect-ratio: 4 / 3;
  max-height: 76svh;
  overflow: hidden;
  background: #11161a;
}
.reference-page .reference-photos .photo-zoom img {
  width: 100%;
  height: 100%;
  max-height: 76svh;
  object-fit: contain;
}
@media (min-width: 761px) and (max-width: 1199px) {
  #referenciak .project-grid .project figcaption > strong { min-height: 72px; font-size: 16px; }
  #referenciak .project-grid .project-actions { flex-direction: column; align-items: stretch; gap: 4px; }
  #referenciak .project-grid .project-quote { width: 100%; }
}
@media (max-width: 760px) {
  #referenciak .project-grid,
  #referenciak .project-grid.is-filtered { grid-template-columns: minmax(0, 1fr); gap: 24px; }
}
@media (max-width: 359px) {
  #referenciak .project-grid .project-actions { flex-direction: column; align-items: stretch; gap: 4px; }
  #referenciak .project-grid .project-quote { width: 100%; }
}
