/* the heading must directly precede its Loop Grid. */
.bns-hide-if-next-loop-empty:not(:has(+ .elementor-widget-loop-grid .e-loop-item)) {
    display: none !important;
}


/* All FAQ content stays in HTML; JavaScript reveals batches of ten. */
.bns-faq-batch > .bns-faq-more {
    display: none !important;
}

.bns-faq-batch.bns-faq-pagination-ready > .bns-faq-more:not([hidden]) {
    display: block !important;
}

.bns-faq-batch .elementor-loop-container > .e-loop-item[hidden] {
    display: none !important;
}

.bns-faq-more .elementor-button-wrapper {
    display: flex;
    justify-content: center;
}

.elementor .bns-faq-more .elementor-button-wrapper .elementor-button {
    background: var(--bns-faq-button-background, #fff);
    border: 1px solid #d9dee8;
    border-radius: 0;
    color: var(--bns-faq-button-text, var(--e-global-color-secondary, #414141));
    font-size: 1rem;
    font-weight: 600;
    line-height: 1.25;
    max-width: 100%;
    padding: 0;
    transition: background-color 180ms ease, border-color 180ms ease, color 180ms ease;
    width: 240px;
}

.elementor .bns-faq-more .elementor-button-wrapper .elementor-button .elementor-button-content-wrapper {
    align-items: stretch;
    flex-direction: row;
    gap: 0;
    min-height: 54px;
    width: 100%;
}

.bns-faq-more .elementor-button-text {
    align-items: center;
    display: flex;
    flex: 1;
    justify-content: center;
    order: 1;
    padding: 14px 20px;
}

.bns-faq-more .elementor-button-icon {
    align-items: center;
    align-self: stretch;
    background: var(--bns-faq-button-accent, var(--e-global-color-accent, #2368ad));
    color: #fff;
    display: flex;
    flex: 0 0 54px;
    justify-content: center;
    margin: 0;
    order: 2;
}

.bns-faq-more .elementor-button-icon :is(svg, i) {
    height: 1.1em;
    transition: transform 180ms ease;
    width: 1.1em;
}

.elementor .bns-faq-more .elementor-button-wrapper .elementor-button:hover {
    background: var(--bns-faq-button-text, var(--e-global-color-secondary, #414141));
    border-color: var(--bns-faq-button-text, var(--e-global-color-secondary, #414141));
    color: #fff;
}

.bns-faq-more .elementor-button:hover .elementor-button-icon :is(svg, i) {
    transform: translateY(3px);
}

.bns-faq-more .elementor-button:focus-visible {
    outline: 2px solid var(--bns-faq-button-accent, var(--e-global-color-accent, #2368ad));
    outline-offset: 4px;
}

@media (prefers-reduced-motion: reduce) {
    .elementor .bns-faq-more .elementor-button-wrapper .elementor-button,
    .bns-faq-more .elementor-button-icon :is(svg, i) {
        transition: none;
    }

    .bns-faq-more .elementor-button:hover .elementor-button-icon :is(svg, i) {
        transform: none;
    }
}

/* Leere Abschnitte samt Abständen ausblenden. Layout bleibt in Elementor gestaltbar. */
.bns-faq-section:not(:has(.elementor-widget-loop-grid .e-loop-item)) {
    display: none !important;
}

.bns-faq-columns-2 .elementor-widget-loop-grid .elementor-loop-container {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 767px) {
    .bns-faq-columns-2 .elementor-widget-loop-grid .elementor-loop-container {
        grid-template-columns: minmax(0, 1fr);
    }
}
