<div class="container-fluid">
    <div class="row pb-3">
        <div class="col-md-2 col-sm-12 offset-md-1">
            <h3 class="wln-text-purple package-header">BLOG</h3>
            <hr style="border: solid 2px #d66325; "/>    
        </div>
    </div>
    <div class="row">
        <div class="col-md-11 col-sm-12 offset-md-1">
            <div class="card-deck owl-carousel owl-theme" id="sliding-cards-blogs">
                <?php foreach ($posts as $post) { ?>
                <div class="card img-box border-0 shadow-sm">
                    <?php 
                        $image_result = $image_service->get($post->thumbnail);
                        $image = new Image(
                            $image_result['id'],
                            $image_result['caption'],
                            $image_result['filename']
                        ); 
                    ?>
                    <img src="assets/images/<?php echo $image->filename; ?>" class="card-img-top img-fluid" alt="<?php echo $image->caption; ?>">
                    <div class="card-body">
                        <p> 
                            <i class="fas fa-calendar-alt mr-2"></i>
                            <?php echo date_format(date_create($post->created_at), "M d, Y"); ?>
                        </p>
                        <a href="blog/<?php echo $post->url; ?>">
                            <h4 class="card-title wln-text-purple"> <?php echo $post->title; ?></h4>
                        </a>
                    </div>
                </div>
                <?php } ?>
            </div>
        </div>
    </div>
</div>