<?php
    $crt_builder_with_elementor_sliders = crt_builder_with_elementor_json_to_array(get_theme_mod('crt_manage_hero_slider'));
?>
<?php if(!empty($crt_builder_with_elementor_sliders)): ?>
    <?php foreach ( $crt_builder_with_elementor_sliders as $crt_builder_with_elementor_slider_item ) :
        $image_url = crt_builder_with_elementor_gtsicrf($crt_builder_with_elementor_slider_item, 'crt-builder-with-elementor-image-large', 'crt-builder-with-elementor-image-small');
    ?>
        <div class="hero__item">
            <div class="position-relative">
                <img class="hero__thumbnail <?php echo esc_attr('ratio219'); ?>" data-lazy="<?php echo esc_attr($image_url); ?>" alt="<?php echo esc_attr(''); ?>" style="" />
                <div class="hero__content position-absolute">
                    <h3 class="hero__title"><?php echo esc_html($crt_builder_with_elementor_slider_item['title']); ?></h3>
                    <div class="hero__button">
                        <a href="<?php echo esc_url($crt_builder_with_elementor_slider_item['link']); ?>"><?php echo esc_html($crt_builder_with_elementor_slider_item['subtitle']); ?></a>
                    </div>
                </div>
            </div>
        </div>
    <?php endforeach;  ?>
<?php endif; ?>
