.ben-fig-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 30px;
}

.ben-fig-item {
    position: relative;
    overflow: hidden;
}

.ben-fig-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.3s ease;
}

/* Responsive Anpassungen */
@media (max-width: 1200px) {
    .ben-fig-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Desktop und Tablet: scrollbare Zeile, wenn mehr als sichtbare Spalten */
@media (min-width: 768px) {
    .ben-fig-grid.scrollable {
        display: flex;
        flex-wrap: nowrap;
        gap: 16px;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        padding-bottom: 8px;
    }

    .ben-fig-grid.scrollable .ben-fig-item {
        scroll-snap-align: start;
    }

    /* Desktop: 6 Spalten sichtbar */
    @media (min-width: 1200px) {
        .ben-fig-grid.scrollable .ben-fig-item {
            flex: 0 0 calc(16.6666% - 16px);
            max-width: calc(16.6666% - 16px);
        }
    }

    /* Tablet: 4 Spalten sichtbar */
    @media (max-width: 1200px) and (min-width: 768px) {
        .ben-fig-grid.scrollable .ben-fig-item {
            flex: 0 0 calc(25% - 16px);
            max-width: calc(25% - 16px);
        }
    }

    /* Scrollbar ausblenden */
    .ben-fig-grid.scrollable::-webkit-scrollbar {
        display: none;
    }
}

/* Mobile: 2-Spalten horizontales Scrollen */
@media (max-width: 768px) {
    .ben-fig-grid {
        display: flex;
        flex-wrap: nowrap;
        gap: 16px;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        padding-bottom: 8px;
    }

    .ben-fig-item {
        flex: 0 0 calc(50% - 8px);
        max-width: calc(50% - 8px);
        scroll-snap-align: start;
    }

    .ben-fig-grid::-webkit-scrollbar {
        display: none;
    }
}

/* Sehr kleine Geräte: größere Kachelgröße, bleibt horizontal scrollend */
@media (max-width: 480px) {
    .ben-fig-item {
        flex: 0 0 80%;
        max-width: 80%;
    }
}

/* Punkte-Leiste */
.ben-fig-dots {
    text-align: center;
    margin-top: 12px;
}

.ben-fig-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin: 0 4px;
    border-radius: 50%;
    background-color: #888; /* grau für inaktive Punkte */
    transition: background-color 0.3s ease;
}

.ben-fig-dot.active {
    background-color: #fff; /* weiß für aktiven Punkt */
}
