/* Work / antique detail pages */

.item-detail {
  max-width: 920px;
  margin-left: auto;
  margin-right: auto;
  padding-bottom: 48px;
}

.item-detail-back {
  display: inline-block;
  font-family: var(--font-display);
  font-size: var(--fs-small);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 20px;
  text-decoration: none;
  color: var(--link);
}

.item-detail-back:hover {
  color: var(--link-hover);
}

.item-detail h1 {
  font-family: var(--font-display);
  font-size: var(--fs-h2);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  margin: 0 0 24px;
  color: var(--heading);
}

.item-detail-hero {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--rule-light);
  overflow: hidden;
  margin-bottom: 28px;
  max-height: calc(100vh - 260px);
  max-height: calc(100dvh - 260px);
  background: var(--bg);
}

.item-detail-hero img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: calc(100vh - 260px);
  max-height: calc(100dvh - 260px);
  object-fit: contain;
}

.item-detail-section {
  margin-bottom: 28px;
}

.item-detail-section h2 {
  font-family: var(--font-display);
  font-size: var(--fs-small);
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 12px;
  color: var(--heading);
}

.item-detail-description {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.65;
  color: var(--text);
  margin: 0;
  white-space: pre-wrap;
}

.item-detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.item-detail-gallery figure {
  margin: 0;
  border: 1px solid var(--rule-light);
  overflow: hidden;
}

.item-detail-gallery img {
  width: 100%;
  display: block;
  aspect-ratio: 1;
  object-fit: cover;
}

.item-detail-gallery-item.is-video {
  display: flex;
  align-items: stretch;
}

.item-detail-gallery-video {
  width: 100%;
  display: block;
  aspect-ratio: 1;
  object-fit: cover;
  background: #111;
}
