<?php
 $portfolio = getContent('portfolio.content',true);
$portfolios = App\Models\Portfolio::where('status',1)->limit(5)->get();
$portfoliosCount = App\Models\Portfolio::where('status',1)->count();
?>
<!-- ==================== Our Projects Start Here ==================== -->
<section class="projects-area section-bg py-80">
    <div class="container">
        <div class="row">
            <div class="col-lg-7">
                <div class="">
                     <div class="section-heading">
                        <span class="subtitle"><?php echo e(__($portfolio->data_values->top_heading)); ?></span>
                         <h2 class="section-heading__title"><?php echo e(__($portfolio->data_values->heading)); ?></h2>
                         <p class="section-heading__desc mb-3"><?php echo e(__($portfolio->data_values->sub_heading)); ?></p>
                     </div>
                </div>
            </div>
        </div>
        <div class="row gy-4 align-items-center">
            <?php $__currentLoopData = $portfolios; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $index=>$item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
            <?php if($index % $portfoliosCount == 0 ): ?>
            <div class="col-lg-4 col-md-4">
                <div class="Our-Project">
                    <a href="<?php echo e(route('portfolio.details', ['slug' => slug($item->title), 'id' => $item->id])); ?>">
                        <img class="img-1" src="<?php echo e(getImage(getFilePath('portfolioImage').'/'.$item->image)); ?>" alt="image">
                        <div class="content">
                            <h4>
                                <?php if(strlen(__($item->title)) >20): ?>
                                <?php echo e(substr( __($item->title), 0,20).'...'); ?>

                                <?php else: ?>
                                <?php echo e(__($item->title)); ?>

                                <?php endif; ?>

                            </h4>
                            <span>
                                <?php if(strlen(__($item->sub_title)) >20): ?>
                                <?php echo e(substr( __($item->sub_title), 0,20).'...'); ?>

                                <?php else: ?>
                                <?php echo e(__($item->sub_title)); ?>

                                <?php endif; ?>
                            </span>
                        </div>
                    </a>
                </div>
            </div>
            <div class="col-lg-4 col-md-4">
                <div class="row gy-3">
                    <?php elseif($index % $portfoliosCount == 1): ?>
                    <div class="col-lg-12">
                        <div class="Our-Project">
                            <a href="<?php echo e(route('portfolio.details', ['slug' => slug($item->title), 'id' => $item->id])); ?>">
                                <img class="img-1" src="<?php echo e(getImage(getFilePath('portfolioImage').'/'.$item->image)); ?>" alt="image">
                                <div class="content">
                                    <h4>
                                        <?php if(strlen(__($item->title)) >20): ?>
                                        <?php echo e(substr( __($item->title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->title)); ?>

                                        <?php endif; ?>
                                    </h4>
                                    <span>
                                        <?php if(strlen(__($item->sub_title)) >20): ?>
                                        <?php echo e(substr( __($item->sub_title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->sub_title)); ?>

                                        <?php endif; ?>
                                    </span>
                                </div>
                            </a>
                        </div>
                    </div>
                    <?php elseif($index % $portfoliosCount == 2): ?>
                    <div class="col-lg-12">
                        <div class="Our-Project">
                            <a href="<?php echo e(route('portfolio.details', ['slug' => slug($item->title), 'id' => $item->id])); ?>">
                                <img class="img-1" src="<?php echo e(getImage(getFilePath('portfolioImage').'/'.$item->image)); ?>" alt="image">
                                <div class="content">
                                    <h4>
                                        <?php if(strlen(__($item->title)) >20): ?>
                                        <?php echo e(substr( __($item->title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->title)); ?>

                                        <?php endif; ?>
                                    </h4>
                                    <span>
                                        <?php if(strlen(__($item->Sub_title)) >20): ?>
                                        <?php echo e(substr( __($item->Sub_title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->Sub_title)); ?>

                                        <?php endif; ?>
                                    </span>
                                </div>
                            </a>
                        </div>
                    </div>
                </div>
            </div>
            <div class="col-lg-4 col-md-4">
                <div class="row gy-3">
                    <?php elseif($index % $portfoliosCount == 3): ?>

                    <div class="col-lg-12">
                        <div class="Our-Project">
                            <a href="<?php echo e(route('portfolio.details', ['slug' => slug($item->title), 'id' => $item->id])); ?>">
                                <img class="img-1" src="<?php echo e(getImage(getFilePath('portfolioImage').'/'.$item->image)); ?>" alt="image">
                                <div class="content">
                                    <h4>
                                        <?php if(strlen(__($item->title)) >20): ?>
                                        <?php echo e(substr( __($item->title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->title)); ?>

                                        <?php endif; ?>
                                    </h4>
                                    <span>
                                        <?php if(strlen(__($item->sub_title)) >20): ?>
                                        <?php echo e(substr( __($item->sub_title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->sub_title)); ?>

                                        <?php endif; ?>
                                    </span>
                                </div>
                            </a>
                        </div>
                    </div>
                    <?php else: ?>
                    <div class="col-lg-12">
                        <div class="Our-Project">
                            <a href="<?php echo e(route('portfolio.details', ['slug' => slug($item->title), 'id' => $item->id])); ?>">
                                <img class="img-1" src="<?php echo e(getImage(getFilePath('portfolioImage').'/'.$item->image)); ?>" alt="image">
                                <div class="content">
                                    <h4>
                                        <?php if(strlen(__($item->title)) >20): ?>
                                        <?php echo e(substr( __($item->title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->title)); ?>

                                        <?php endif; ?>
                                    </h4>
                                    <span>
                                        <?php if(strlen(__($item->sub_title)) >20): ?>
                                        <?php echo e(substr( __($item->sub_title), 0,20).'...'); ?>

                                        <?php else: ?>
                                        <?php echo e(__($item->sub_title)); ?>

                                        <?php endif; ?>
                                    </span>
                                </div>
                            </a>
                        </div>
                    </div>
                </div>
            </div>
            <?php endif; ?>
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
        </div>
    </div>
</section>
<!-- ==================== Our Projects us End Here ==================== -->
<?php /**PATH C:\xampp\htdocs\finbiz\application\resources\views/presets/default/sections/portfolio.blade.php ENDPATH**/ ?>