/* ============================================
   PHOTO GALLERY — TILES MODE
   Auto-fill grid. The column width is pinned to
   --gallery-thumb-width; each cell's ratio (and
   thus its height) comes from --gallery-item-ratio,
   set by the engine from the aspect_ratio setting
   (defaults to 1/1). Pure CSS — no JS layout pass.
   ============================================ */

.photo-gallery__grid--tiles {
    grid-template-columns: repeat(auto-fill, minmax(0, var(--gallery-thumb-width)));
}

.photo-gallery--tiles .photo-gallery__item {
    aspect-ratio: var(--gallery-item-ratio, 1 / 1);
}
