<?php if(get_user_pricing_by_id($id,'blog')==1 && is_active($id,'blog')==1): ?>
<?php if(!empty($posts)): ?>
	<div class="row line " id="blog">
		<div class="col-md-9 left_line pt-50">
			<div class="heading ">
				<h4 class="mi-heading"> <?= get_features_name('blog');?></h4>
			</div>
			<div class="service_slider mi-blog mb-50" >
				<?php foreach ($posts as $key=>$post) { ?>
					<div class=" " data-aos="fade-up" data-aos-delay="100">
						<div class="single-blog cv style_1">
							<div class="blog-img">
								<?php if($post['is_video']==0): ?>
										<img src="<?= base_url(html_escape($post['thumb']));?>" alt="">
									<?php else: ?>
										<div class="videoWrapper">
											<iframe src="<?= html_escape($post['thumb']);?>" frameborder="0"></iframe>
										</div>
									<?php endif;?>
								<div class="post-category">
									<a href="<?= base_url('category-post/'.$slug."/".html_escape($post['cat_slug'])); ?>"><?= html_escape($post['cat_name']);?></a>
								</div>
							</div>
							<div class="blog-content">
								<div class="blog-title">
									<h4><a href="<?= base_url('post/'.$slug."/".$post['slug']);?>"><?= character_limiter(html_escape($post['title']),30);?></a></h4>
									<div class="meta">
										<ul>
											<li><i class="fa fa-calendar"></i> <?= cl_format(html_escape($post['created_at']));?></li>
											<li><i class="fa fa-eye"></i> <?= html_escape($post['hit']);?></li>
										</ul>
									</div>
								</div>
								<div class="blog_post_details">
									<p><?= character_limiter(html_escape($post['overview']),80);?></p>
								</div>
								<a href="<?= base_url('post/'.$slug."/".$post['slug']);?>" class="box_btn btn_style_<?= get_user_info_by_slug($slug)['btn_style'];?>"><?= !empty(lang('see_more'))?lang('see_more'):"See More"?></a>
							</div>
						</div>
					</div>
				<?php } ?>

			</div>
			<div class="text-center mt-30 mb-20">
				<a href="<?php echo base_url('all-post/'.$slug); ?>" class="btn btn-info mi-btn btn_style_<?= get_user_info_by_slug($slug)['btn_style'];?>"><?= !empty(lang('see_more'))?lang('see_more'):"See More"?></a>
			</div>
		</div>	
	</div>
	<?php endif; ?>
<?php endif; ?>