{% set firstHeading =  post.get_field('heading_1') %}
{% set secondHeading =  post.get_field('heading_2') %}
{% set thirdHeading =  post.get_field('heading_3') %}
{% set firstContent =  post.get_field('content_1') %}
{% set secondContent =  post.get_field('content_2') %}
{% set thirdContent =  post.get_field('content_3') %}

<section class="">
    <div class="container">
        <div class="block-text-3-cols-cols">
            {% if firstHeading is not empty or firstContent is not empty %}
                <article class="block-text-3-cols-col block-text-3-cols-col">
                    {% if firstHeading is not empty %}
                        <header class="block-text-3-cols-heading">
                            <h3>{{ firstHeading }}</h3>
                        </header>
                    {% endif %}
                    {% if firstContent is not empty %}
                        <div class="block-text-3-cols-content">
                            {{ firstContent }}
                        </div>
                    {% endif %}
                </article>
            {% endif %}

            {% if secondHeading is not empty or secondContent is not empty %}
                <article class="block-text-3-cols-col block-text-3-cols-col">
                    {% if secondHeading is not empty %}
                        <header class="block-text-3-cols-heading">
                            <h3>{{ secondHeading }}</h3>
                        </header>
                    {% endif %}
                    {% if secondContent is not empty %}
                        <div class="block-text-3-cols-content">
                            {{ secondContent }}
                        </div>
                    {% endif %}
                </article>
            {% endif %}

            {% if thirdHeading is not empty or thirdContent is not empty %}
                <article class="block-text-3-cols-col block-text-3-cols-col">
                    {% if thirdHeading is not empty %}
                        <header class="block-text-3-cols-heading">
                            <h3>{{ thirdHeading }}</h3>
                        </header>
                    {% endif %}
                    {% if thirdContent is not empty %}
                        <div class="block-text-3-cols-content">
                            {{ thirdContent }}
                        </div>
                    {% endif %}
                </article>
            {% endif %}
        </div>
    </div>
</section>