/* V71 isolated image-preview experiment. The live root site is unchanged. */
/* Scrolling gallery captions are suppressed; only selected preview captions appear. */
.gallery-track .photo-item figcaption { display:none !important; }
.selected-photo { display:none; }
@media (min-width:900px) {
 .selected-photo.is-visible {
   display:flex; flex-direction:column; align-items:flex-start;
   position:absolute;
   z-index:2;
   left:22px; /* Match desktop SVG wordmark left edge. */
   top:22px;
   width:calc(var(--obituary-x, 66.6667%) - 22px - 112px);
   max-height:calc(100dvh - 22px - 24px);
   margin:0; pointer-events:auto; opacity:0;
   transition:opacity .65s ease;
 }
 body.obituary-open .selected-photo.is-visible { opacity:1; transition-delay:.85s; }
 body:not(.obituary-open) .selected-photo.is-visible { opacity:0; transition-delay:0s; }
 .selected-photo img {
   display:block;
   width:auto; height:auto;
   max-width:100%;
   max-height:calc(100dvh - 22px - 80px);
   object-fit:contain; object-position:left top;
   flex:0 1 auto;
 }
 .selected-photo figcaption {
   margin-top:10px; max-width:100%;
   color:#262626; font-size:calc(13px - 2pt); line-height:1.3;
 }
 .selected-photo figcaption:empty { display:none; }
}
@media(max-width:899px) { .selected-photo {display:none !important;} }

/* V73: keep the gallery and SVG hidden until the obituary/photo have faded
   out; then fade the main experience back in. Desktop test only. */
@media (min-width:900px) {
  body.preview-returning .gallery-viewport,
  body.preview-returning .wordmark {
    opacity:0 !important;
    pointer-events:none;
  }
}

/* V75: make the returning gallery and wordmark transition visible,
   including after the opening wordmark animation has completed. */
@media (min-width:900px) {
  body:not(.obituary-open) .gallery-viewport.is-ready { transition:opacity .8s ease; }
  body:not(.obituary-open) .wordmark.intro-complete { transition:opacity .8s ease; }
}

/* V76: align the SVG and preview image to the same 22px left inset. */
@media (min-width:900px) { .wordmark { left:22px; } }
