
<?php $__env->startSection('pageTitle', isset($pageTitle) ? $pageTitle : 'Document Title'); ?>
<?php $__env->startSection('meta_tags'); ?>
<?php echo SEO::generate(); ?>

<?php $__env->stopSection(); ?>
<?php $__env->startSection('content'); ?>
<section class="section department-single">
    <div class="container">
        <div class="row">
            <div class="col-12">
                <div class="d-flex justify-content-between align-items-center mb-4 flex-wrap">
                    <!-- Title -->
                    <h3 class="mb-0"><?php echo e($pageTitle); ?> | Bulletin Room</h3>
                    <!-- Breadcrumb -->
                    <nav aria-label="breadcrumb">
                        <ol class="breadcrumb bg-transparent mb-0 px-0">
                            <li class="breadcrumb-item"><a href="<?php echo e(url('/')); ?>">Home</a></li>
                            <li class="breadcrumb-item"><a href="<?php echo e(route('bulletin')); ?>">Bulletin</a></li>
                            <li class="breadcrumb-item active" aria-current="page"><?php echo e($pageTitle); ?></li>
                        </ol>
                    </nav>
                </div>
                <hr>
            </div>
        </div>
        <div class="row">
            <div class="col-lg-8">
                <!-- Blog Posts Section -->
                <section id="blog-posts" class="blog-posts">
                    <div class="container">
                        <div class="row gy-4">
                            <div class="card border-0 p-3">
                                <?php $__empty_1 = true; $__currentLoopData = $post; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $posts): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
                                <div class="row mb-4 align-items-stretch">
                                    <!-- Image -->
                                    <div class="col-md-4 d-flex p-3">
                                        <img src="<?php echo e(asset('/images/posts/resized/resized_' . $posts->featured_image)); ?>"
                                            class="img-fluid rounded-3 w-100 object-fit-cover"
                                            style="height: 100%; max-height: 250px; object-fit: cover;"
                                            alt="<?php echo e($posts->title ?? 'Post Image'); ?>">
                                    </div>

                                    <!-- Content -->
                                    <div class="col-md-8">
                                        <div class="card-body h-100 d-flex flex-column justify-content-between">
                                            <div>
                                                <h5 class="card-title fw-bold">
                                                    <a href="<?php echo e(route('read_post', $posts->slug)); ?>"><?php echo e($posts->title); ?></a>
                                                </h5>

                                                <div class="text-muted small mb-2 card-details">
                                                    <i class="icofont-ui-user"></i>
                                                    <a href="<?php echo e(route('author_posts', $posts->author->username)); ?>"><?php echo e($posts->author->name); ?></a> &nbsp;
                                                    <i class="mdi mdi-calendar-badge"></i> <?php echo e(date_formatter($posts->created_at)); ?> &nbsp;
                                                    <i class="icofont-category"></i>
                                                    <a href="<?php echo e(route('category_post', $posts->post_category->slug)); ?>" class="ml-1"><?php echo e($posts->post_category->name); ?></a>
                                                </div>

                                                <p class="card-text">
                                                    <?php echo Str::ucfirst(words($posts->content, 25)); ?>

                                                </p>
                                            </div>

                                            <div>
                                                <a href="<?php echo e(route('read_post', $posts->slug)); ?>">Read More...</a>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
                                <p><span class="text-danger">No post found for your search</span></p>
                                <?php endif; ?>
                            </div><!-- End blog posts list -->
                        </div>
                    </div>
                </section><!-- /Blog Posts Section -->

                <!-- Blog Pagination Section -->
                <section id="blog-pagination" class="blog-pagination section">

                    <div class="container">
                        <div class="d-flex justify-content-center">
                            <ul>
                                <li><a href="#"><i class="bi bi-chevron-left"></i></a></li>
                                <li><a href="#">1</a></li>
                                <li><a href="#" class="active">2</a></li>
                                <li><a href="#">3</a></li>
                                <li><a href="#">4</a></li>
                                <li>...</li>
                                <li><a href="#">10</a></li>
                                <li><a href="#"><i class="bi bi-chevron-right"></i></a></li>
                            </ul>
                        </div>
                    </div>

                </section><!-- /Blog Pagination Section -->
            </div>
            <div class="col-lg-4 sidebar">

                <div class="widgets-container">

                    <!-- Search Widget -->
                    <?php if (isset($component)) { $__componentOriginale6ac12e1b4c8ba8b88cc0f498d1979d5 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginale6ac12e1b4c8ba8b88cc0f498d1979d5 = $attributes; } ?>
<?php $component = App\View\Components\SidebarSearch::resolve([] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('sidebar-search'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\App\View\Components\SidebarSearch::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes([]); ?> <?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginale6ac12e1b4c8ba8b88cc0f498d1979d5)): ?>
<?php $attributes = $__attributesOriginale6ac12e1b4c8ba8b88cc0f498d1979d5; ?>
<?php unset($__attributesOriginale6ac12e1b4c8ba8b88cc0f498d1979d5); ?>
<?php endif; ?>
<?php if (isset($__componentOriginale6ac12e1b4c8ba8b88cc0f498d1979d5)): ?>
<?php $component = $__componentOriginale6ac12e1b4c8ba8b88cc0f498d1979d5; ?>
<?php unset($__componentOriginale6ac12e1b4c8ba8b88cc0f498d1979d5); ?>
<?php endif; ?>
                    <!--/Search Widget -->

                    <!-- Categories Widget -->
                    <?php
                    $grouped = sidebar_categories()->groupBy(fn($cat) => $cat->parent_category->name ?? 'Others');
                    ?>

                    <div class="categories-widget widget-item">
                        <h3 class="widget-title">Categories</h3>

                        <?php $__currentLoopData = $grouped; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $parentName => $categories): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                        <h6 class="mt-3"><strong><?php echo e($parentName); ?></strong></h6>
                        <ul class="ms-3">
                            <?php $__currentLoopData = $categories; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <li>
                                <a href="<?php echo e(route('category_post', $item->slug)); ?>">
                                    <?php echo e($item->name); ?> <span>(<?php echo e($item->posts_count); ?>)</span>
                                </a>
                            </li>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        </ul>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                    </div>

                    <!--/Categories Widget -->

                    <!-- Recent Posts Widget -->
                    <div class="recent-posts-widget widget-item">

                        <h3 class="widget-title">Recent Posts</h3>
                        <?php $__currentLoopData = sidebar_latest_posts(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $item): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>

                        <div class="post-item">
                            <img src="/images/posts/resized/resized_<?php echo e($item->featured_image); ?>" alt="<?php echo e($item->title); ?>" class="img-fluid" style="max-height: 100px; object-fit: cover;">
                            <div>
                                <h4 style="line-height: 1.5rem;"><a href="<?php echo e(route('read_post', $item->slug)); ?>"><?php echo e($item->title); ?></a></h4>
                                <time><?php echo e(date_formatter($item->created_at)); ?></li></time>
                            </div>
                        </div>
                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        <!-- End recent post item-->
                    </div><!--/Recent Posts Widget -->

                    <!-- Tags Widget -->
                    <div class="tags-widget widget-item">

                        <h3 class="widget-title">Tags</h3>
                        <ul>
                            <?php $__currentLoopData = getTags(); $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $tags): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                            <li><a href="<?php echo e(route('tag_posts', urlencode($tags))); ?>"><?php echo e($tags); ?></a></li>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        </ul>

                    </div><!--/Tags Widget -->

                </div>

            </div>
        </div>
    </div>
</section>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('front.layout.pages-layout', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH /home/pcdsedup/public_html/resources/views/front/pages/bulletin/search_posts.blade.php ENDPATH**/ ?>