{# VARIABLES #}
{% set bg_image_url = bg_image_url|default(false) %}
{% set wrapper_class = [
  'ciw',
  wrapper_class ? wrapper_class : ""
] %}
{% set container_class = [
  'container',
  container_class ? container_class : ""
] %}

{# TEMPLATE #}
{% if bg_image_url %}
<div {{ create_attribute().addClass(wrapper_class) }} >

  {% block container_bg_image %}
    {% include "@atoms/html5/image/image.twig" with { "url": bg_image_url, "alt": "Section background image", "img_class": 'cii' } only %}
  {% endblock %}

{% endif %}

  <div {{ create_attribute().addClass(container_class) }}>

    {% block container_content %}
      {{ children }}
    {% endblock %}

  </div>
{% if bg_image_url %}
</div>
{% endif %}
