<?php $__env->startSection('title'); ?>
    <title><?php echo e(!empty($category) ? $category->meta_title : 'Tổng hợp các kiến thức, kinh nghiệm quản lý nhà trọ - ITRO'); ?></title>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('meta'); ?>


    <meta property="og:url" content="<?php echo e(url()->current()); ?>"/>
    <meta property="og:type" content="website"/>
    <meta property="og:title" content="<?php echo e(!empty($category) ? $category->meta_title : 'Tổng hợp các kiến thức, kinh nghiệm quản lý nhà trọ - ITRO'); ?>"/>
    <meta property="og:description"
          content="<?php echo e(!empty($category) ? $category->meta_description : 'Tổng hợp tất cả các kiến thức, các kinh nghiệm hữu ích dành cho chủ nhà trọ. Các kinh nghiệm quản lý nhà trọ, các mô hình kinh doanh nhà trọ...'); ?>"/>
    <meta property="og:image" content="https://quanlynhatro.com/frontend3/assets/img/logo.png"/>

    <meta name='dmca-site-verification' content='OVl5UDY0M0NyNFRHMGpQT3RhTGFCQT090'/>
    <meta name="yandex-verification" content="4fa39a76cda86dcd"/>
    <meta name="msvalidate.01" content="56882A3F1EB152F4873F9FFE797640F1"/>
    <link rel='canonical' expr:href='data:blog.url'/>
    <meta name="revisit-after" content="1 days">
    <!-- Start Shema.org -->
    <script type="application/ld+json">
    {
        "@context": "http://schema.org",
        "@type": "PostalAddress",
        "addressLocality": "Thanh Xuân",
        "addressRegion": "Viet Nam",
        "postalCode":"100000",
        "streetAddress": "Tầng 4, tháp T1, toà nhà Times Tower, 35 Lê Văn Lương, Thanh Xuân, Hà Nội"
    }



    </script>
    <!-- End Shema.org -->

<?php $__env->stopSection(); ?>

<?php $__env->startSection('content'); ?>
    <?php echo $__env->make('frontend3.header_landing', \Illuminate\Support\Arr::except(get_defined_vars(), array('__data', '__path')))->render(); ?>

    <div class="block-breadcrumb">
        <div class="container">
            <nav class="nav-breadcrumb" aria-label="breadcrumb">
                <ol class="breadcrumb">
                    <li class="breadcrumb-item"><a href="/">Trang chủ</a></li>
                    <li class="breadcrumb-item"><a href="/blog">Blog</a></li>
                    <?php if(isset($category)): ?>
                        <li class="breadcrumb-item active" aria-current="page"><?php echo e(optional($category)->name); ?></li>
                    <?php else: ?>

                    <?php endif; ?>
                </ol>
            </nav>
        </div>
    </div>
    <div class="block-blog">
        <div class="container">
            <div class="block-blog__wrap">
                <div class="block-blog">
                    <?php if(isset($featuredBlogs)): ?>
                        <?php if($featuredBlogs->count() > 0): ?>
                            <div class="block-blog__featured-posts">
                                <div id="carouselFeaturedBlogPost" class="carousel slide carousel-fade"
                                     data-ride="carousel">
                                    <ol class="carousel-indicators">
                                        <li data-target="#carouselFeaturedBlogPost" data-slide-to="0"
                                            class="active"></li>
                                        <li data-target="#carouselFeaturedBlogPost" data-slide-to="1"></li>
                                    </ol>
                                    <div class="carousel-inner">
                                        <?php $__currentLoopData = $featuredBlogs; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $featuredBlog): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <div class="carousel-item  <?php if($loop->index == 0): ?> active <?php endif; ?>">
                                                <a href="<?php echo e(url('blog/' . $featuredBlog->slug)); ?>"
                                                   class="single-featured-post">
                                                    <div class="post__photo h-rtg h-rtg--r31">
                                                        <div class="h-rtg__inner h-bg-cover"
                                                             style="background-image: url('<?php echo e($featuredBlog->image_url); ?>')"></div>
                                                    </div>
                                                    <div class="post__content">
                                                        <h3 class="post__content__title"><?php echo e($featuredBlog->title); ?></h3>
                                                        <div class="post__content__excerpt"><?php echo e(\Illuminate\Support\Str::words(strip_tags(html_entity_decode($featuredBlog->content)))); ?></div>
                                                    </div>
                                                </a>
                                            </div>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                    </div>
                                    <a class="carousel-control carousel-control-prev" href="#carouselFeaturedBlogPost"
                                       role="button" data-slide="prev">
                                        <i class="mdi mdi-chevron-left"></i>
                                    </a>
                                    <a class="carousel-control carousel-control-next" href="#carouselFeaturedBlogPost"
                                       role="button" data-slide="next">
                                        <i class="mdi mdi-chevron-right"></i>
                                    </a>
                                </div>


                                <?php endif; ?>
                                <?php endif; ?>
                            </div>
                            <div class="block-blog__list-posts">
                                <div class="row">
                                    <?php $__currentLoopData = $blogs; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $blog): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <div class="col-12 col-sm-6 col-md-4">
                                            <div class="block-blog__single-post">
                                                <div class="post__photo h-rtg h-rtg--r32">
                                                    <a href="<?php echo e(url('blog/' . $blog->slug)); ?>"
                                                       class="h-rtg__inner bg-color-grey-200"><img
                                                                src="<?php echo e($blog->image_url); ?>" alt=""
                                                                class="ht-img-obj-cover"></a>
                                                </div>
                                                <div class="post__content">
                                                    <?php if($blog->is_sale): ?>
                                                        <?php if($blog->sale_status != App\Models\Blog::SALE_NO_TIME): ?>
                                                            <div class="post__tag">

                                                                <div class="tag-post-status">
                                                                    <?php if($blog->sale_status == App\Models\Blog::SALE_ONGOING): ?>
                                                                        <span class="badge badge--orange">Đang diễn ra</span>
                                                                    <?php elseif($blog->sale_status == App\Models\Blog::SALE_END): ?>
                                                                        <span class="badge badge--teal">Đã kết thúc</span>
                                                                    <?php elseif($blog->sale_status == App\Models\Blog::SALE_END): ?>
                                                                        <span class="badge badge--blue">Sắp diễn ra</span>
                                                                    <?php endif; ?>
                                                                </div>
                                                                <div class="tag-post-time active">
                                                                    <?php echo e(optional($blog->start_date)->format('d/m')); ?>

                                                                    - <?php echo e(optional($blog->end_date)->format('d/m')); ?>

                                                                </div>
                                                            </div>
                                                        <?php endif; ?>
                                                    <?php endif; ?>
                                                    <h3 class="post__content__title"><a
                                                                href="<?php echo e(url('blog/'. $blog->slug)); ?>"><?php echo e($blog->title); ?></a>
                                                    </h3>
                                                    <div class="post__content__meta ht-oneline">
                                                        <?php if(!empty($blog->category_first)): ?>
                                                            <span><a href="<?php echo e(url('blog/danh-muc/'. $blog->slug)); ?>"><?php echo e($blog->categories_text); ?></a></span>
                                                        <?php endif; ?>
                                                        <span><?php echo e($blog->created_at->format('d/m/Y')); ?></span>
                                                    </div>
                                                    <div class="post__content__descr"><?php echo e(\Illuminate\Support\Str::words(strip_tags(html_entity_decode($blog->content)))); ?></div>
                                                </div>
                                            </div>
                                        </div>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </div>
                            </div>
                            <div class="d-flex justify-content-center mt-3">
                                <nav class="nav-pagination">
                                    <?php echo $blogs->appends(request()->except(['page','_token']))->onEachSide(4)->links('vendor.pagination.new_ui_pagination'); ?>

                                </nav>
                            </div>
                </div>
            </div>
        </div>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('quanlynhatro.landing_layout', \Illuminate\Support\Arr::except(get_defined_vars(), array('__data', '__path')))->render(); ?>