<?php
get_header();
?>
    <div class='clearfix'></div>

    <div class="single-pages">
        <div class="container">
            <div class="main-header">
                <h1><?php _e("<!--:en-->Search Result <!--:--><!--:ar-->نتائج البحث <!--:-->"); ?></h1></div>
            <div class="row">
                <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">

                    <h1>
                        <?php _e('<?php _e("<!--:en--> search result <!--:--><!--:ar--> نتيجة البحث        <!--:-->"); ?> ', 'm7md') ?>
                        { <?php /* Search Count */
                        $allsearch = new WP_Query("s=$s&showposts=-1");
                        $key = wp_specialchars($s, 1);
                        $count = $allsearch->post_count;
                        _e('');
                        _e('<span class="search-terms">');
                        echo $key;
                        _e('</span>');
                        _e(' } = ');
                        echo $count . ' ';
                        _e(' <?php _e("<!--:en--> Result! <!--:--><!--:ar-->   نتيجة !    <!--:-->"); ?> ');
                        wp_reset_query(); ?>
                    </h1>
                </div>


                <?php if (have_posts()) : ?>
                    <?php while (have_posts()) : the_post(); ?>
                        <div class="col-lg-4 mb-4">
                            <div class=" slider-banner-image-items"
                            >
                                <div class="slider-banner-image">
                                    <img src="<?php echo the_post_thumbnail_url('full'); ?>"
                                         alt="<?php the_title(); ?>"
                                         title="<?php the_title(); ?>"
                                         class="img-fluid">

                                </div>
                                <div class="slider-banner-content">
                                    <h4 class="slide-for-tit"><?php the_title(); ?></h4>
                                    <p class="slide-for-paragraph"> <?php
                                        echo wp_trim_words(get_the_content(), 25);
                                        ?> </p>
                                    <a href="<?php the_permalink(); ?>" class="main-hover">
                                        <?php echo _e('اقرأ المزيد', 'm7md') ?>
                                        <i class="fa-solid fa-arrow-left-long"></i>
                                    </a>
                                </div>
                            </div>
                        </div>
                    <?php endwhile; else : endif; ?>


            </div>
        </div>
    </div>


    <div class='clearfix'></div>


<?php get_footer(); ?>