{{ 'section-banner-v6.css' | asset_url | stylesheet_tag }}

{%- assign reversed = section.settings.reversed -%}

<div class='banner-v249'>
  <div
    {% render 'section-attr' %}
  >
    {% render 'section-bg-image' %}
    <xo-container
      {% render 'section-layout' %}
    >
      <xo-animate xo-cascade>
        <xo-grid
          style='--xs:1;--lg:2;'
        >
          <div
            class='banner-v249__item'
            {%- if reversed -%}
              style='--order-xs: 1;--order-sm:1'
            {%- endif -%}
          >
            <xo-grid style='--xs:1;--sm:2;'>
              <div
                class='banner-v249__item-2'
                {%- if reversed -%}
                  style='--order-xs: 2;--order-sm:2'
                {%- endif -%}
              >
                <div class='{%- render 'hover-style' -%}'>
                  <a href='{{ section.settings.banner-1_link }}'>
                    <div class='banner-v249__img'>
                      {% render 'image', image: section.settings['image-1'] %}
                    </div>
                  </a>
                </div>
              </div>
              <div
                class='banner-v249__item-2'
                style='--bg: {{ section.settings.bg-1 }};'
              >
                <div class='banner-v249__content'>
                  <div
                    class='banner-v249__circle banner-v249__circle--right'
                    {%- if reversed -%}
                      style='left: auto; right: -15px;'
                    {%- else -%}
                      style='right: auto; left: -15px;'
                    {%- endif -%}
                  ></div>
                  <h3 class='banner-v249__title'>
                    <a href='{{ section.settings.banner-1_link }}'>{{ section.settings['title-1'] }}</a>
                  </h3>
                  <hr>
                  <a href='{{ section.settings.banner-1_link }}' class='banner-v249__subtitle'>{{ section.settings['subtitle-1'] }}</a>
                </div>
              </div>
            </xo-grid>
            <xo-grid style='--xs:1;--sm:2;'>
              <div
                class='banner-v249__item-2'
                {%- if reversed -%}
                {%- else -%}
                  style='--order-xs: 1;--order-sm:1'
                {%- endif -%}
              >
                <div class='{%- render 'hover-style' -%}'>
                  <a href='{{ section.settings.banner-2_link }}'>
                    <div class='banner-v249__img'>
                      {% render 'image', image: section.settings['image-2'] %}
                    </div>
                  </a>
                </div>
              </div>
              <div
                class='banner-v249__item-2'
                style='--bg: {{ section.settings.bg-2 }};'
              >
                <div class='banner-v249__content'>
                  <div
                    class='banner-v249__circle banner-v249__circle--left'
                    {%- if reversed -%}
                      style='right: auto; left: -15px;'
                    {%- else -%}
                      style='left: auto; right: -15px;'
                    {%- endif -%}
                  ></div>
                  <h3 class='banner-v249__title'>
                    <a href='{{ section.settings.banner-2_link }}'>{{ section.settings['title-2'] }}</a>
                  </h3>
                  <hr>
                  <a href='{{ section.settings.banner-2_link }}' class='banner-v249__subtitle'>{{ section.settings['subtitle-2'] }}</a>
                </div>
              </div>
            </xo-grid>
          </div>
          <div class='banner-v249__item'>
            <div class='banner-v249__item-wrap'>
              <div
                class='banner-v249__content'
                style='--bg: {{ section.settings.bg-3 }}; {%- if reversed -%} --right: 0; {%- else -%} --left: 0; {%- endif -%}'
              >
                <h3 class='banner-v249__title'>{{ section.settings['title-3'] }}</h3>
                <hr class='banner-v249__hr'>
                <a href='{{ section.settings.banner-3_link }}' class='banner-v249__subtitle'>{{ section.settings['subtitle-3'] }}</a>
              </div>
              <div class='{%- render 'hover-style' -%}'>
                <a href='{{ section.settings.banner-3_link }}'>
                  <div class='banner-v249__img'>
                    {% render 'image', image: section.settings['image-3'] %}
                  </div>
                </a>
              </div>
            </div>
          </div>
        </xo-grid>
      </xo-animate>
    </xo-container>
  </div>
</div>

{% schema %}
{
  "name": "t:sections.banner_v6.name",
  "settings": [
    {
      "type": "header",
      "content": "Setting layout"
    },
    {
      "type": "select",
      "id": "width",
      "label": "t:sections.all.width.label",
      "default": "box",
      "options": [
        {
          "value": "box",
          "label": "t:sections.all.width.options__1.label"
        },
        {
          "value": "wide",
          "label": "t:sections.all.width.options__2.label"
        },
        {
          "value": "fullwidth",
          "label": "t:sections.all.width.options__3.label"
        }
      ]
    },
    {
      "type": "checkbox",
      "id": "reversed",
      "default": false,
      "label": "t:sections.banner_v6.settings.reversed.label"
    },
    {
      "type": "header",
      "content": "t:sections.banner_v6.settings.header.content-1"
    },
    {
      "type": "image_picker",
      "id": "image-1",
      "label": "t:sections.banner_v6.settings.image.label",
      "info": "t:sections.banner_v6.settings.image.info"
    },
    {
      "type": "color",
      "id": "bg-1",
      "label": "t:sections.banner_v6.settings.background.label",
      "default": "#dce2c2"
    },
    {
      "type": "text",
      "id": "title-1",
      "label": "t:sections.banner_v6.settings.title.label",
      "default": "t:sections.banner_v6.settings.title.default",
      "info": "t:sections.banner_v6.settings.text.info"
    },
    {
      "type": "text",
      "id": "subtitle-1",
      "label": "t:sections.banner_v6.settings.subtitle.label",
      "default": "t:sections.banner_v6.settings.subtitle.default"
    },
    {
      "type": "url",
      "id": "banner-1_link",
      "label": "t:sections.banner_v6.settings.url.label",
      "default": "t:sections.banner_v6.settings.url.default"
    },
    {
      "type": "header",
      "content": "t:sections.banner_v6.settings.header.content-2"
    },
    {
      "type": "image_picker",
      "id": "image-2",
      "label": "t:sections.banner_v6.settings.image.label",
      "info": "t:sections.banner_v6.settings.image.info"
    },
    {
      "type": "color",
      "id": "bg-2",
      "label": "t:sections.banner_v6.settings.background.label",
      "default": "#e0c6b1"
    },
    {
      "type": "text",
      "id": "title-2",
      "label": "t:sections.banner_v6.settings.title.label",
      "default": "t:sections.banner_v6.settings.title.default",
      "info": "t:sections.banner_v6.settings.text.info"
    },
    {
      "type": "text",
      "id": "subtitle-2",
      "label": "t:sections.banner_v6.settings.subtitle.label",
      "default": "t:sections.banner_v6.settings.subtitle.default"
    },
    {
      "type": "url",
      "id": "banner-2_link",
      "label": "t:sections.banner_v6.settings.url.label",
      "default": "t:sections.banner_v6.settings.url.default"
    },
    {
      "type": "header",
      "content": "t:sections.banner_v6.settings.header.content-3"
    },
    {
      "type": "image_picker",
      "id": "image-3",
      "label": "t:sections.banner_v6.settings.image.label",
      "info": "t:sections.banner_v6.settings.image.info"
    },
    {
      "type": "color",
      "id": "bg-3",
      "label": "t:sections.banner_v6.settings.background.label",
      "default": "#9790a8"
    },
    {
      "type": "text",
      "id": "title-3",
      "label": "t:sections.banner_v6.settings.title.label",
      "default": "t:sections.banner_v6.settings.title.default",
      "info": "t:sections.banner_v6.settings.text.info"
    },
    {
      "type": "text",
      "id": "subtitle-3",
      "label": "t:sections.banner_v6.settings.subtitle.label",
      "default": "t:sections.banner_v6.settings.subtitle.default"
    },
    {
      "type": "url",
      "id": "banner-3_link",
      "label": "t:sections.banner_v6.settings.url.label",
      "default": "t:sections.banner_v6.settings.url.default"
    },
    {
      "type": "header",
      "content": "t:sections.banner_v6.settings.header.content-4"
    },
    {
      "type": "select",
      "id": "hover",
      "label": "t:sections.all.hover.label",
      "default": "hover1",
      "options": [
        {
          "value": "hover1",
          "label": "t:sections.all.hover.option__1.label"
        },
        {
          "value": "hover2",
          "label": "Style 02"
        },
        {
          "value": "hover3",
          "label": "Style 03"
        },
        {
          "value": "hover4",
          "label": "Style 04"
        },
        {
          "value": "hover5",
          "label": "Style 05"
        },
        {
          "value": "hover6",
          "label": "Style 06"
        }
      ]
    },
    {
      "type": "header",
      "content": "t:sections.all.heading.content"
    },
    {
      "type": "color_scheme",
      "id": "color_scheme",
      "label": "t:sections.all.color_scheme.label"
    },
    {
      "type": "color",
      "id": "background_color",
      "label": "t:sections.all.bg_color.label"
    },
    {
      "type": "color_background",
      "id": "background_gradient",
      "label": "t:sections.all.bg_gradient.label"
    },
    {
      "type": "image_picker",
      "id": "background_image_desktop",
      "label": "t:sections.all.background_image_desktop.label"
    },
    {
      "type": "image_picker",
      "id": "background_image_mobile",
      "label": "t:sections.all.background_image_mobile.label"
    },
    {
      "type": "checkbox",
      "id": "use_parallax",
      "label": "t:sections.all.use_parallax.label",
      "default": true
    },
    {
      "type": "number",
      "id": "padding_top",
      "label": "t:sections.all.padding_top.label",
      "default": 50
    },
    {
      "type": "number",
      "id": "padding_bottom",
      "label": "t:sections.all.padding_bottom.label",
      "default": 50
    }
  ],
  "presets": [
    {
      "name": "t:sections.banner_v6.presets.name"
    }
  ]
}
{% endschema %}
