{% import 'elements2024/macros/buttons.html.twig' as buttons %}
{% import 'elements2024/macros/title-block.html.twig' as blocks %}
<section class="relative py-8 lg:py-16 overflow-hidden">
<div class="container">
{{ blocks.titleBlock({
title: content.title,
description: content.description,
link: {
text: content.link_text,
href: content.link
}
})}}
<div class="swiper slider-3 mt-16 !overflow-visible">
<div class="swiper-wrapper" batch-children>
{% for item in content.services %}
<div class="services-item swiper-slide" style="width: clamp(288px,24vw,450px); aspect-ratio: calc(450 / 520)">
<div class="h-full" big-fade fade-trigger="batch">
<div class="absolute inset-0">
{# <img class="img-cover" src="{{ asset('frontend2024/dist/img/home/services/' ~ (loop.index0 % 3 + 1) ~ '.webp') }}" alt="{{ item.title }}"> #}
{# <img class="img-cover" src="{{ asset(item.thumbnail.url) | imagine_filter('1040x720') }}" alt="{{ item.title }}" loading="lazy"> #}
<img class="img-cover" src="{{ asset(item.thumbnail.url)}}" alt="{{ item.title }}" loading="lazy">
<div class="absolute inset-0 bg-dark/20"></div>
</div>
<div class="absolute bottom-0 left-0 right-0 text-white flex items-center justify-between p-8 cursor-default">
<h3 class="h2-5">{{ item.title }}</h3>
<svg class="w-8 h-8" viewbox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M2 16H30" stroke="currentColor" stroke-width="2"/>
<path d="M22 8L30 16L22 24" stroke="currentColor" stroke-width="2"/>
</svg>
</div>
<div class="services-item__hover">
<h3 class="h3 mb-auto">{{ item.title }}</h3>
<div class="mt-10">
<p class="p">{{ item.short_desc | raw }}</p>
<div class="mt-8">
<div class="btn-rounded btn__white">
<svg class="w-5 h-5" viewbox="0 0 20 20" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M1.25 10H18.75" stroke="currentColor"/>
<path d="M13.75 5L18.75 10L13.75 15" stroke="currentColor"/>
</svg>
<span>En savoir plus</span>
</div>
</div>
</div>
</div>
<a class="absolute inset-0" href="{{item.url}}">
<span class="sr-only">En savoir plus</span>
</a>
</div>
</div>
{% endfor %}
</div>
<!-- Prev button -->
<div class="swiper-btn-prev-wrapp">
{{ buttons.sliderPrev(true) }}
</div>
<!-- Next button -->
<div class="swiper-btn-next-wrapp">
{{ buttons.sliderNext(true) }}
</div>
</div>
</div>
</section>