/* Additions for the static copy (see tools/build.py). */

/* /photos masonry: slides are positioned by afwt.js */
.afwt-masonry { position: relative; }
.afwt-masonry .slide { cursor: zoom-in; overflow: hidden; }
.afwt-masonry .slide img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* Summary blocks ("Featured" / related posts) */
.afwt-summary-autogrid { display: grid; grid-template-columns: repeat(var(--afwt-cols, 3), minmax(0, 1fr)); gap: 20px; }
.afwt-summary-autogrid > .summary-item { position: static !important; width: auto !important; margin: 0 !important; }
.summary-item .summary-thumbnail img { display: block; width: 100%; height: auto; }

/* Static map images that replace the Google map blocks */
.afwt-map-block .sqs-block-content { position: relative; }
.afwt-map-block img { display: block; width: 100%; height: auto; }
.afwt-map-credit { position: absolute; right: 0; bottom: 0; margin: 0; padding: 1px 5px;
  font-size: 10px; line-height: 1.4; background: rgba(255, 255, 255, .8); color: #333; }
.afwt-map-credit a { color: inherit; }

/* Archived comments */
.afwt-comments { text-align: left; margin-top: 1.5em; }
.afwt-comments-note { font-size: .85em; opacity: .7; margin: 0 0 1.5em; }
.afwt-comment-list, .afwt-comment-list ol { list-style: none; margin: 0; padding: 0; }
.afwt-comment { padding: 1em 0; border-top: 1px solid rgba(0, 0, 0, .1); }
.afwt-comment .afwt-comment { margin-left: 2em; border-top: 0; padding-bottom: 0; }
.afwt-comment-meta { margin: 0 0 .4em; font-size: .85em; }
.afwt-comment-meta time { opacity: .7; }
.afwt-comment-body p { margin: 0 0 .6em; }

/* Lightbox */
.afwt-lightbox { position: fixed; inset: 0; z-index: 100000; display: none; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .97); }
.afwt-lightbox.open { display: flex; }
html.afwt-lightbox-open { overflow: hidden; }
.afwt-lightbox figure { margin: 0; max-width: calc(100vw - 120px); max-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.afwt-lightbox img { display: block; max-width: calc(100vw - 120px); max-height: calc(100vh - 80px); width: auto; height: auto; object-fit: contain; }
.afwt-lightbox figcaption { margin-top: 10px; font-size: 14px; color: #333; text-align: center; }
.afwt-lightbox button { position: absolute; border: 0; background: none; color: #222; cursor: pointer; font: 300 48px/1 sans-serif; padding: 10px 16px; }
.afwt-lightbox .afwt-lb-close { top: 10px; right: 10px; font-size: 40px; }
.afwt-lightbox .afwt-lb-prev { left: 4px; top: 50%; transform: translateY(-50%); }
.afwt-lightbox .afwt-lb-next { right: 4px; top: 50%; transform: translateY(-50%); }
.afwt-lightbox.single .afwt-lb-prev, .afwt-lightbox.single .afwt-lb-next { display: none; }
@media (max-width: 640px) {
  .afwt-lightbox figure, .afwt-lightbox img { max-width: 100vw; }
  .afwt-lightbox .afwt-lb-prev, .afwt-lightbox .afwt-lb-next { top: auto; bottom: 0; transform: none; }
}
