<section class="section top-bottom-padding case-studies bg-color--dark">
<div class="inner bottom-margin-2em">
<h2 class="h2--lg">{% if blogPost is defined %}Torq’s Case Studies{% else %}More Case Studies{% endif %}</h2>
</div>
<div data-aos="swipe-right" class="horizontal-overflow position-relative">
<div class="inner">
<div class="row">
{% set caseStudies = app_case_studies_get() %}
{% if caseStudies and caseStudies|length > 0 %}
{% for caseStudy in caseStudies %}
{% set caseStudyLink = caseStudy['slug'] %}
{% set currentPath = path(app.request.attributes.get('_route'), app.request.attributes.get('_route_params')) %}
{% set caseStudyPath = '/case-studies/' ~ caseStudyLink %}
{% if currentPath is not same as caseStudyPath %}
<div class="col col-lg-6 col-md-6 col-sm-6 col-xs-12 case-studies">
<a href="{{ caseStudyPath }}" class="card-link">
<div class="card--inner">
<div class="row no-gutter">
<div class="col-lg-4 col-md-4 col-sm-4 col-xs-4">
<div class="feat-img-container">
{% set caseStudyImage = caseStudy['featuredImage'] %}
{% if caseStudyImage is empty %}
{{ source("@torq_static/img/backgrounds/placeholder-image.svg") }}
{% else %}
<!-- TODO convert this to be a thumbnail so we aren't loading the original image -->
<img src="{{ caseStudyImage }}" class="img--object-cover" />
{% endif %}
</div>
</div>
<div class="col-lg-8 col-md-8 col-sm-8 col-xs-8">
<div class="padding-2em">
<div class="position-relative card-content-container">
<div class="absolute-top-right">
{{ source("@torq_static/img/icons/arrow-right.svg") }}
</div>
{# <div class="tag">
<p>Case study</p>
</div> #}
{% if caseStudy['solutions'] %}
<div class="tags">
<i class="fa fa-tag"></i> {{ caseStudy['solutions']|join(', ') }}
</div>
{% endif %}
<h3{% if not caseStudy['solutions'] %} style="max-width: calc(100% - 60px);"{% endif %}>{{ caseStudy['title'] }}</h3>
{% if caseStudy['description'] %}
<p>{{ caseStudy['description'] }}</p>
{% endif %}
</div>
</div>
</div>
</div>
</div>
</a>
</div>
{% endif %}
{% endfor %}
{% endif %}
</div>
</div>
</div>
</section>