{% set image = page.media.images|first %}
{% set image_align = page.header.image_align|default('right')|replace({'align-': ''}) %}

<section class="section modular-text {{ page.header.class }}">
    <div class="container">
        <div class="columns align-{{ image_align }}">
            {% if image %}
                <div class="column">
                    {{ content|raw }}
                </div>
                <div class="column">
                    {{ image.html|raw }}
                </div>
            {% else %}
                <div class="column" style="grid-column: 1 / -1;">
                    {{ content|raw }}
                </div>
            {% endif %}
        </div>
    </div>
</section>
