/* ── Inspiration gallery (inspiration.html only) ─────────────────────
   Justified rows: every photo keeps its own shape, so nothing gets
   cropped. Each .inspo-item sets --r (photo width ÷ height) in the HTML.
   Photos in a row share one height and the row fills the full width.
   No captions on the grid (Andrew, 2026-11-27); the lightbox still
   shows each photo's title from data-modal-label. */
.inspiration-grid {
  --row-h: 250px;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}
/* keeps the last row from stretching its photos to giant sizes */
.inspiration-grid::after { content: ""; flex-grow: 999; }

.inspiration-grid .inspo-item {
  --r: 1.333;
  flex: var(--r) 1 calc(var(--row-h) * var(--r));
  aspect-ratio: var(--r);
  grid-row: auto;
  grid-column: auto;
  border-radius: var(--radius-lg);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.28);
  transition: box-shadow var(--trans), transform var(--trans);
}
.inspiration-grid .inspo-item img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 600ms cubic-bezier(0.16, 1, 0.3, 1);
}
.inspiration-grid .inspo-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.4);
}
.inspiration-grid .inspo-item:hover img { transform: scale(1.04); }

/* Caption always visible (phones have no hover), stronger on hover */
.inspiration-grid .inspo-overlay {
  opacity: 1;
  background: linear-gradient(0deg, rgba(10, 18, 36, 0.88) 0%, rgba(10, 18, 36, 0.35) 28%, transparent 48%);
  padding: var(--space-4) var(--space-4) var(--space-3);
}
.inspiration-grid .inspo-item:hover .inspo-overlay {
  background: linear-gradient(0deg, rgba(10, 18, 36, 0.92) 0%, rgba(10, 18, 36, 0.45) 36%, transparent 60%);
}
.inspiration-grid .inspo-label {
  font-size: clamp(1rem, 0.9rem + 0.5vw, 1.3rem);
  line-height: 1.1;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.5);
}
.inspiration-grid .inspo-sublabel {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: max-height var(--trans), opacity var(--trans);
}
.inspiration-grid .inspo-item:hover .inspo-sublabel,
.inspiration-grid .inspo-item:focus-visible .inspo-sublabel {
  max-height: 2.5em;
  opacity: 1;
}

@media (max-width: 960px) {
  .inspiration-grid { --row-h: 200px; }
}
@media (max-width: 640px) {
  .inspiration-grid { --row-h: 118px; gap: var(--space-2); }
  .inspiration-grid .inspo-item { border-radius: var(--radius-md); }
  .inspiration-grid .inspo-overlay {
    padding: var(--space-2) var(--space-3);
    background: linear-gradient(0deg, rgba(10, 18, 36, 0.92) 0%, rgba(10, 18, 36, 0.5) 34%, transparent 58%);
  }
  .inspiration-grid .inspo-label { font-size: 0.95rem; letter-spacing: 0.04em; }
}
@media (prefers-reduced-motion: reduce) {
  .inspiration-grid .inspo-item,
  .inspiration-grid .inspo-item img { transition: none; }
  .inspiration-grid .inspo-item:hover,
  .inspiration-grid .inspo-item:hover img { transform: none; }
}

/* No titles in the big photo viewer either (Andrew, 2026-11-27).
   Hidden with CSS, not deleted: js/main.js still fills these elements,
   and the titles stay as screen-reader labels and image alt text. */
.inspo-modal-caption { display: none; }
