.tour-compact-gallery__grid:not(.justified-gallery) {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--space-xs);
}

.tour-compact-gallery__grid:not(.justified-gallery) > a {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: var(--radius-xs);
}

.tour-compact-gallery__grid:not(.justified-gallery) > a > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tour-compact-gallery__grid > a:focus-visible {
    z-index: 6;
    outline: 3px solid var(--primary);
    outline-offset: 3px;
}

.tour-compact-gallery__view-all {
    position: absolute;
    right: var(--space-xs);
    bottom: var(--space-xs);
    z-index: 5;
    display: inline-flex;
    align-items: center;
    gap: var(--space-2xs);
    max-width: calc(100% - (2 * var(--space-xs)));
    padding: var(--space-2xs) var(--space-xs);
    color: var(--light);
    font-size: var(--text-xs);
    font-weight: 700;
    line-height: 1.2;
    pointer-events: none;
}

.tour-compact-gallery__view-all svg {
    flex: 0 0 auto;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.75;
}

@media (max-width: 768px) {
    .tour-compact-gallery__grid:not(.justified-gallery) {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .tour-compact-gallery__view-all {
        right: var(--space-2xs);
        bottom: var(--space-2xs);
        max-width: calc(100% - (2 * var(--space-2xs)));
        padding: var(--space-2xs);
        font-size: var(--text-2xs);
    }
}
