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

<section class='banner-v9'>
  <div {% render 'section-attr' %}>
    <xo-container {% render 'section-layout' %}>
      <xo-grid>
        <div class='banner-v9__right' style='--md: 12; --lg: 3; background: {{ section.settings.background_text }} '>
          <div class='banner-v9__content'>
            {%- if section.settings.sub != blank -%}
              <div class='banner-v9__text'>{{ section.settings.sub }}</div>
            {%- endif -%}
            {%- if section.settings.price != blank -%}
              <div class='banner-v9__price'>
                {{ section.settings.price }}
              </div>
            {%- endif -%}
            {%- if section.settings.text != blank -%}
              <div class='banner-v9__sub'>{{ section.settings.text }}</div>
            {%- endif -%}
            <a href='{{ section.settings.url }}' class='banner-v9__button'>
              <div class='banner-v9__button-text'>{{ section.settings.button_text }}</div>
              <div class='banner-v9__arrow'>
                <svg viewBox='0 0 24 24' fill='none' xmlns='http://www.w3.org/2000/svg'>
                  <g id="SVGRepo_bgCarrier" stroke-width="0"></g><g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round"></g><g id="SVGRepo_iconCarrier"> <path d="M4 12H20M20 12L16 8M20 12L16 16" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"></path> </g>
                </svg>
              </div>
            </a>
          </div>
        </div>
        <div class='banner-v9__left' style='--md: 12; --lg: 9'>
          <div class='banner-v9__img'>
            {%- render 'image', image: section.settings.image -%}
          </div>
        </div>
      </xo-grid>
    </xo-container>
  </div>
</section>

{% schema %}
{
  "name": "t:sections.banner_v9.name",
  "tag": "section",
  "class": "section",
  "settings": [
    {
      "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": "header",
      "content": "Settings about"
    },
    {
      "type": "image_picker",
      "id": "image",
      "label": "t:sections.banner_v9.settings.image.label"
    },
    {
      "type": "richtext",
      "id": "text",
      "label": "t:sections.banner_v9.settings.text.label"
    },
    {
      "type": "text",
      "id": "price",
      "label": "t:sections.banner_v9.settings.price.label",
      "default": "20%"
    },
    {
      "type": "text",
      "id": "sub",
      "label": "t:sections.banner_v9.settings.sub.label"
    },
    {
      "type": "color",
      "id": "background_text",
      "label": "t:sections.banner_v9.settings.background_text.label",
      "default": "#151515"
    },
    {
      "type": "text",
      "id": "button_text",
      "label": "t:sections.banner_v9.settings.button_text.label",
      "default": "SHOP NOW"
    },
    {
      "type": "url",
      "id": "url",
      "label": "t:sections.banner_v9.settings.url.label",
      "default": "/collections/all"
    },
    {
      "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": "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_v9.presets.name"
    }
  ]
}
{% endschema %}
