{% trans_default_domain 'products' %}
{% set splitPrice = this.splitPrice %}
{% set offerUrl = this.offerUrl %}

{% if splitPrice or offerUrl %}
   <div {{ attributes }}>
      <div class="first-row-wrapper">
         <img src="{{ asset('web/build/icons/essox-payment.svg', 'webpack') }}" alt="Essox" class="img-responsive" width="90" height="21"
              loading="lazy"/>
         <div class="payment-info">
            {% if splitPrice %}
               <div>
                  <div class="text-with-icon">
                     <twig:ux:icon name="calendar" class="c-icon"/>
                     {{ 'essox.splitPayment'|trans }}
                  </div>
                  <div class="bold">
                     {{ splitPrice.parts }} x {{ splitPrice.price }} {{ this.currencySymbol }}
                  </div>
               </div>
            {% endif %}

            {% if offerUrl %}
               <div>
                  <div class="text-with-icon">
                     <twig:ux:icon name="calculator" class="c-icon"/>
                     {{ 'essox.installmentPurchase'|trans }}
                  </div>
                  <div>
                     <a href="{{ offerUrl }}" target="_blank">{{ 'essox.calculate'|trans }}</a>
                  </div>
               </div>
            {% endif %}
         </div>
      </div>
      <div>
         {{ 'essox.moreInfoText'|trans }}
         {% set moreInfoUrl = this.moreInfoUrl %}
         {% if moreInfoUrl %}
            <a href="{{ moreInfoUrl }}" target="_blank">{{ 'essox.moreInfoLink'|trans }}</a>
         {% endif %}
      </div>
   </div>
{% endif %}
