<?php $__env->startSection('content'); ?>
    <section id="hero_banner">
        <div class="section-one-image">
            <div class="container-fluid banner_h d-flex align-items-center max_width">
                <div class="row w-100 justify-content-center">
                    <div class="col-xxl-11 col-lg-11 col-md-12 col-12">
                        <div class="row">
                            <div class="col-lg-6">
                                <div class="content_banner pt-md-5 pt-3">
                                    <h2><?php echo e($data->section_one_heading); ?>

                                    </h2>
                                    <p><?php echo e(strip_tags($data->section_one_description)); ?>

                                    </p>
                                    <?php if(!Auth::check()): ?>
                                        <div class="navbar-buttons" style="display: block !important">
                                            <a data-bs-toggle="modal" data-bs-target="#registerModal"
                                                class="btn bttn1 rounded-pill fontbtnnb">
                                                <?php echo e($data->section_one_button_text); ?>

                                            </a>
                                        </div>
                                    <?php endif; ?>

                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </section>
    <style>
        .section-one-image {
            background: url('<?php echo e(asset($data->section_one_image)); ?>');
            background-size: cover;
            background-position: center;
        }

        @media (max-width: 767px) {
            .section-one-image {
                background-size: contain;
                background-position: center;
                background-repeat: no-repeat;
                background-size: 100%;


            }
        }
    </style>
    
    

    






    





    <?php if(auth()->guard()->check()): ?>
        <section id="book-slider">
            <div class="container-fluid max_width">
                <div class="row d-flex justify-content-center align-items-center">
                    <div class="col-xxl-11 col-lg-11 col-md-12 col-12">
                        <div class="row d-flex justify-content-center align-items-center my-md-4 my-3">
                            <div class="row d-flex justify-content-end align-items-center my-md-4 my-3">
                                <div class="col-lg-3 col-md-4 col-12 px-0">
                                    <div class="search-title text-start text-lg-end text-md-end pt-md-2 me-md-4">
                                        <h6><?php echo e($data->search_filter_heading); ?></h6>
                                    </div>
                                </div>
                                <div class="col-lg-4 col-md-6 col-12 px-0">
                                    <div class="search_country_index text-lg-end text-md-end text-end">
                                        <?php
                                            // $selectedCountry = old('country', $profile->country ?? '');

                                            $countries = [
                                                'Afghanistan' => 'Afghanistan',
                                                'Albania' => 'Albania',
                                                'Algeria' => 'Algeria',
                                                'Andorra' => 'Andorra',
                                                'Angola' => 'Angola',
                                                'Antigua and Barbuda' => 'Antigua and Barbuda',
                                                'Argentina' => 'Argentina',
                                                'Armenia' => 'Armenia',
                                                'Australia' => 'Australia',
                                                'Austria' => 'Austria',
                                                'Azerbaijan' => 'Azerbaijan',
                                                'Bahamas' => 'Bahamas',
                                                'Bahrain' => 'Bahrain',
                                                'Bangladesh' => 'Bangladesh',
                                                'Barbados' => 'Barbados',
                                                'Belarus' => 'Belarus',
                                                'Belgium' => 'Belgium',
                                                'Belize' => 'Belize',
                                                'Benin' => 'Benin',
                                                'Bhutan' => 'Bhutan',
                                                'Bolivia' => 'Bolivia',
                                                'Bosnia and Herzegovina' => 'Bosnia and Herzegovina',
                                                'Botswana' => 'Botswana',
                                                'Brazil' => 'Brazil',
                                                'Brunei' => 'Brunei',
                                                'Bulgaria' => 'Bulgaria',
                                                'Burkina Faso' => 'Burkina Faso',
                                                'Burundi' => 'Burundi',
                                                'Cabo Verde' => 'Cabo Verde',
                                                'Cambodia' => 'Cambodia',
                                                'Cameroon' => 'Cameroon',
                                                'Canada' => 'Canada',
                                                'Central African Republic' => 'Central African Republic',
                                                'Chad' => 'Chad',
                                                'Chile' => 'Chile',
                                                'China' => 'China',
                                                'Colombia' => 'Colombia',
                                                'Comoros' => 'Comoros',
                                                'Congo (Congo-Brazzaville)' => 'Congo (Congo-Brazzaville)',
                                                'Costa Rica' => 'Costa Rica',
                                                'Croatia' => 'Croatia',
                                                'Cuba' => 'Cuba',
                                                'Cyprus' => 'Cyprus',
                                                'Czechia' => 'Czechia',
                                                'Democratic Republic of the Congo' =>
                                                    'Democratic Republic of the Congo',
                                                'Denmark' => 'Denmark',
                                                'Djibouti' => 'Djibouti',
                                                'Dominica' => 'Dominica',
                                                'Dominican Republic' => 'Dominican Republic',
                                                'Ecuador' => 'Ecuador',
                                                'Egypt' => 'Egypt',
                                                'El Salvador' => 'El Salvador',
                                                'Equatorial Guinea' => 'Equatorial Guinea',
                                                'Eritrea' => 'Eritrea',
                                                'Estonia' => 'Estonia',
                                                'Eswatini' => 'Eswatini',
                                                'Ethiopia' => 'Ethiopia',
                                                'Fiji' => 'Fiji',
                                                'Finland' => 'Finland',
                                                'France' => 'France',
                                                'Gabon' => 'Gabon',
                                                'Gambia' => 'Gambia',
                                                'Georgia' => 'Georgia',
                                                'Germany' => 'Germany',
                                                'Ghana' => 'Ghana',
                                                'Greece' => 'Greece',
                                                'Grenada' => 'Grenada',
                                                'Guatemala' => 'Guatemala',
                                                'Guinea' => 'Guinea',
                                                'Guinea-Bissau' => 'Guinea-Bissau',
                                                'Guyana' => 'Guyana',
                                                'Haiti' => 'Haiti',
                                                'Honduras' => 'Honduras',
                                                'Hungary' => 'Hungary',
                                                'Iceland' => 'Iceland',
                                                'India' => 'India',
                                                'Indonesia' => 'Indonesia',
                                                'Iran' => 'Iran',
                                                'Iraq' => 'Iraq',
                                                'Ireland' => 'Ireland',
                                                'Israel' => 'Israel',
                                                'Italy' => 'Italy',
                                                'Jamaica' => 'Jamaica',
                                                'Japan' => 'Japan',
                                                'Jordan' => 'Jordan',
                                                'Kazakhstan' => 'Kazakhstan',
                                                'Kenya' => 'Kenya',
                                                'Kiribati' => 'Kiribati',
                                                'Kuwait' => 'Kuwait',
                                                'Kyrgyzstan' => 'Kyrgyzstan',
                                                'Laos' => 'Laos',
                                                'Latvia' => 'Latvia',
                                                'Lebanon' => 'Lebanon',
                                                'Lesotho' => 'Lesotho',
                                                'Liberia' => 'Liberia',
                                                'Libya' => 'Libya',
                                                'Liechtenstein' => 'Liechtenstein',
                                                'Lithuania' => 'Lithuania',
                                                'Luxembourg' => 'Luxembourg',
                                                'Madagascar' => 'Madagascar',
                                                'Malawi' => 'Malawi',
                                                'Malaysia' => 'Malaysia',
                                                'Maldives' => 'Maldives',
                                                'Mali' => 'Mali',
                                                'Malta' => 'Malta',
                                                'Marshall Islands' => 'Marshall Islands',
                                                'Mauritania' => 'Mauritania',
                                                'Mauritius' => 'Mauritius',
                                                'Mexico' => 'Mexico',
                                                'Micronesia' => 'Micronesia',
                                                'Moldova' => 'Moldova',
                                                'Monaco' => 'Monaco',
                                                'Mongolia' => 'Mongolia',
                                                'Montenegro' => 'Montenegro',
                                                'Morocco' => 'Morocco',
                                                'Mozambique' => 'Mozambique',
                                                'Myanmar' => 'Myanmar',
                                                'Namibia' => 'Namibia',
                                                'Nauru' => 'Nauru',
                                                'Nepal' => 'Nepal',
                                                'Netherlands' => 'Netherlands',
                                                'New Zealand' => 'New Zealand',
                                                'Nicaragua' => 'Nicaragua',
                                                'Niger' => 'Niger',
                                                'Nigeria' => 'Nigeria',
                                                'North Korea' => 'North Korea',
                                                'North Macedonia' => 'North Macedonia',
                                                'Norway' => 'Norway',
                                                'Oman' => 'Oman',
                                                'Pakistan' => 'Pakistan',
                                                'Palau' => 'Palau',
                                                'Palestine' => 'Palestine',
                                                'Panama' => 'Panama',
                                                'Papua New Guinea' => 'Papua New Guinea',
                                                'Paraguay' => 'Paraguay',
                                                'Peru' => 'Peru',
                                                'Philippines' => 'Philippines',
                                                'Poland' => 'Poland',
                                                'Portugal' => 'Portugal',
                                                'Qatar' => 'Qatar',
                                                'Romania' => 'Romania',
                                                'Russia' => 'Russia',
                                                'Rwanda' => 'Rwanda',
                                                'Saint Kitts and Nevis' => 'Saint Kitts and Nevis',
                                                'Saint Lucia' => 'Saint Lucia',
                                                'Saint Vincent and the Grenadines' =>
                                                    'Saint Vincent and the Grenadines',
                                                'Samoa' => 'Samoa',
                                                'San Marino' => 'San Marino',
                                                'Sao Tome and Principe' => 'Sao Tome and Principe',
                                                'Saudi Arabia' => 'Saudi Arabia',
                                                'Senegal' => 'Senegal',
                                                'Serbia' => 'Serbia',
                                                'Seychelles' => 'Seychelles',
                                                'Sierra Leone' => 'Sierra Leone',
                                                'Singapore' => 'Singapore',
                                                'Slovakia' => 'Slovakia',
                                                'Slovenia' => 'Slovenia',
                                                'Solomon Islands' => 'Solomon Islands',
                                                'Somalia' => 'Somalia',
                                                'South Africa' => 'South Africa',
                                                'South Korea' => 'South Korea',
                                                'South Sudan' => 'South Sudan',
                                                'Spain' => 'Spain',
                                                'Sri Lanka' => 'Sri Lanka',
                                                'Sudan' => 'Sudan',
                                                'Suriname' => 'Suriname',
                                                'Sweden' => 'Sweden',
                                                'Switzerland' => 'Switzerland',
                                                'Syria' => 'Syria',
                                                'Taiwan' => 'Taiwan',
                                                'Tajikistan' => 'Tajikistan',
                                                'Tanzania' => 'Tanzania',
                                                'Thailand' => 'Thailand',
                                                'Timor-Leste' => 'Timor-Leste',
                                                'Togo' => 'Togo',
                                                'Tonga' => 'Tonga',
                                                'Trinidad and Tobago' => 'Trinidad and Tobago',
                                                'Tunisia' => 'Tunisia',
                                                'Turkey' => 'Turkey',
                                                'Turkmenistan' => 'Turkmenistan',
                                                'Tuvalu' => 'Tuvalu',
                                                'Uganda' => 'Uganda',
                                                'Ukraine' => 'Ukraine',
                                                'United Arab Emirates' => 'United Arab Emirates',
                                                'United Kingdom' => 'United Kingdom',
                                                'United States' => 'United States',
                                                'Uruguay' => 'Uruguay',
                                                'Uzbekistan' => 'Uzbekistan',
                                                'Vanuatu' => 'Vanuatu',
                                                'Vatican City' => 'Vatican City',
                                                'Venezuela' => 'Venezuela',
                                                'Vietnam' => 'Vietnam',
                                                'Yemen' => 'Yemen',
                                                'Zambia' => 'Zambia',
                                                'Zimbabwe' => 'Zimbabwe',
                                            ];
                                        ?>
                                        <select id="CountryMain" class="form-select">
                                            <option value="">Select Country</option>
                                            <?php $__currentLoopData = $countries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $country): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                <option value="<?php echo e($country); ?>"><?php echo e($country); ?></option>
                                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                        </select>
                                    </div>
                                </div>
                            </div>
                            <div class="col-lg-6 col-md-6 col-7">
                                <div class="top-title">
                                    <h4 class="mb-0"><?php echo e($data->second_section_heading); ?></h4>
                                </div>
                            </div>
                            <div class="col-lg-6 col-md-6 col-5">
                                <div class="view_all text-lg-end text-md-end text-end">
                                    <a href="" data-bs-toggle="modal" data-bs-target="#bookListModal" class="">
                                        <?php echo e($data->second_section_button_text); ?> <i class="fa-solid fa-angle-right ms-4"></i></a>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="row d-flex justify-content-center align-items-center">
                    <div class="col-xxl-10 col-lg-10 col-md-12 col-12">
                        <div id="list-book" class="owl-carousel owl-theme">
                            <?php $__currentLoopData = $bookCovers; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $cover): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                <div class="item" data-country="<?php echo e($cover->country); ?>">
                                    <div class="card border-0">
                                        <a href="javascript:void(0);" data-bs-toggle="modal"
                                            data-bs-target="#bookModal2<?php echo e($cover->id); ?>">
                                            <img src="<?php echo e(asset('website/images/Book_sample 1.jpg')); ?>"
                                                class="book-img img-fluid" alt="Book Cover" />
                                        </a>
                                        <div class="card-body py-1 px-0">
                                            <?php
                                                $desc = $cover->short_description ?? '';

                                                // Split by new lines
                                                $lines = preg_split('/\r\n|\r|\n/', $desc);

                                                // Clean each line: remove dash, trim spaces, remove empty lines
                                                $lines = collect($lines)
                                                    ->map(function ($line) {
                                                        return trim(ltrim($line, '-'));
                                                    })
                                                    ->filter();
                                            ?>

                                            <?php if($lines->isNotEmpty()): ?>
                                                <ul class="ps-3 mb-0">
                                                    <?php $__currentLoopData = $lines; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $line): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                        <li class="small">
                                                            <p class="text-start mb-0"><?php echo e($line); ?></p>
                                                        </li>
                                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                                </ul>
                                            <?php else: ?>
                                                <p class="card-text text-center pt-1">No description available.</p>
                                            <?php endif; ?>


                                            <h6 class="text-center mt-3"> My favorite quote</h3>

                                                <p>&ldquo; <?php echo e($cover->favorite_quotes); ?> &rdquo;</p>

                                        </div>



                                    </div>
                                </div>
                            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                        </div>
                        <div id="no-books-message" class="text-center py-4 fs-4" style="display: none;">
                            <p>No books available for the selected country.</p>
                        </div>
                    </div>
                </div>
            </div>
        </section>
    <?php endif; ?>



    <section id="section_3rd">
        <div class="container-fluid max_width pt-md-4 pt-3 pb-2">
            <div class="row d-flex justify-content-center align-items-center pt-2">
                <div class="col-xxl-11 col-lg-11 col-md-12 col-12">
                    <div class="row equal-height">
                        <!-- Left Image Column -->
                        <div class="col-lg-6 col-md-6 px-0">
                            <div class="image_3rdsec h-100">
                                <img src="<?php echo e(asset($data->third_section_image)); ?>" class="img-fluid" alt="" />
                            </div>
                        </div>

                        <!-- Right Content Column -->
                        <div class="col-lg-6 col-md-6 backg d-flex justify-content-center align-items-center">
                            <div class="col-lg-9 col-md-10 py-md-4 py-3">
                                <div class="content3rdsec pe-xxl-5 pe-xl-4">
                                    <h2><?php echo e($data->third_section_heading); ?></h2>
                                    <p>
                                        <?php echo e($data->third_section_description); ?>

                                    </p>
                                </div>
                            </div>
                        </div>
                        <!-- End Right -->
                    </div>
                </div>
            </div>
        </div>
    </section>



    <section id="slider-search">
        <div class="container-fluid">
            <!-- ModalToggle1bookdetails -->
            <?php $__currentLoopData = $bookCovers; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $cover): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                




                <!-- ModalToggle2 -->
                <div class="modal fade" id="bookModal2<?php echo e($cover->id); ?>" tabindex="-1"
                    aria-labelledby="bookModalLabel<?php echo e($cover->id); ?>" aria-hidden="true">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/images/Book_sample 1.jpg')); ?>"
                                                        alt="Book" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <p>Intrigued?</p>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>

                            <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                <div class="row">
                                    <div class="col-lg-6 col-md-6 col-6">
                                        <button class="back-btn" data-bs-target="#bookModal<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <div class="col-lg-6 col-md-6 col-6 text-end">
                                        <button class="back-btn" data-bs-target="#bookModal3<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Next
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>


                <!-- ModalToggle3 -->
                <div class="modal fade" id="bookModal3<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel3" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/images/Book_sample 1.jpg')); ?>"
                                                        alt="Book" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <p>Would you like to unpack the book?</p>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <!-- <div class="modal-footer">
                                                                                                                                                                                                                                        <button class="btn btn-primary" data-bs-target="#exampleModalToggle" data-bs-toggle="modal">Back</button>
                                                                                                                                                                                                                                    </div> -->
                            <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                <div class="row">
                                    <div class="col-lg-6 col-md-6 col-6">
                                        <button class="back-btn" data-bs-target="#bookModal2<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <div class="col-lg-6 col-md-6 col-6 text-end">
                                        <button class="back-btn" data-bs-target="#bookModal4<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Next
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- ModalToggle4 -->
                <div class="modal fade" id="bookModal4<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel3" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/uploads/book_covers/' . $cover->book_cover)); ?>"
                                                        alt="Book" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <h6><?php echo e($cover->book_name ?? 'Book Name'); ?></h6>
                                                    <span class="">Author:
                                                        <?php echo e($cover->author_name ?? 'Author Name'); ?></span>
                                                </div>
                                                <div class="row d-flex justify-content-center align-items-center mt-4">
                                                    <div class="col-6 text-md-start text-end">
                                                        <div class="whis-list">
                                                            <a href="#"><i class="fa-regular fa-heart me-3"></i></a>
                                                            <span class="like-count"
                                                                id="like-count-book-<?php echo e($cover->id); ?>">
                                                                <?php echo e($cover->book_likes); ?>

                                                            </span>
                                                        </div>
                                                    </div>
                                                    <div
                                                        class="col-6 d-flex justify-content-md-start justify-content-start">
                                                        <div class="col-6 text-center">
                                                            <?php
                                                                $alreadyLikedBook = in_array($cover->id, $likedBookIds);
                                                            ?>
                                                            <button type="button" class="back-btn like-btn"
                                                                data-id="<?php echo e($cover->id); ?>" data-type="book"
                                                                <?php if($alreadyLikedBook): ?> style="display: none;" <?php endif; ?>>
                                                                Bookmark
                                                            </button>

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


                            </div>
                            <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                <div class="row">
                                    <div class="col-lg-6 col-md-6 col-6">
                                        <button class="back-btn" data-bs-target="#bookModal3<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <div class="col-lg-6 col-md-6 col-6 text-end">
                                        <button class="back-btn" data-bs-target="#bookModal5<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Next
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>

                </div>
                <!-- ModalToggle5 -->
                <div class="modal fade" id="bookModal5<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel5" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/uploads/book_covers/' . $cover->book_cover)); ?>"
                                                        alt="Book" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <p>
                                                        Would you like to know the person who read this
                                                        book?
                                                    </p>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>

                            <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                <div class="row">
                                    <div class="col-lg-6 col-md-6 col-6">
                                        <button class="back-btn" data-bs-target="#bookModal4<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <div class="col-lg-6 col-md-6 col-6 text-end">
                                        <button class="back-btn" data-bs-target="#bookModal6<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Next
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- ModalToggle6 -->
                <div class="modal fade" id="bookModal6<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel6" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">
                                                Blind Date with a Book&nbsp;&nbsp;
                                                <?php if($cover->verification_status == 'verified'): ?>
                                                    <span class="badge bg-success badge-sm">Verified</span>
                                                <?php else: ?>
                                                    <span class="badge bg-warning badge-sm">Unverified</span>
                                                <?php endif; ?>
                                            </h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/uploads/profile_images/' . $cover->profile_photo)); ?>"
                                                        alt="profile" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <h5><?php echo e($cover->nickname ?? ' Name'); ?></h5>
                                                    <span><?php echo e($cover->country ?? 'Country'); ?></span>
                                                </div>
                                                <div class="content_book mt-lg-5 mt-md-4 mt-3 text-md-start text-center">
                                                    <h5><?php echo e($cover->book_name ?? 'Book Name'); ?></h5>
                                                    <span>Author: <?php echo e($cover->author_name ?? 'Author Name'); ?></span>
                                                </div>
                                                <div class="row d-flex justify-content-center align-items-center mt-4">
                                                    <div class="col-6 text-md-start text-end">
                                                        <div class="whis-list ">
                                                            <a href="#"><i class="fa-regular fa-heart me-3"></i></a>
                                                            <span class="like-count"
                                                                id="like-count-profile-<?php echo e($cover->id); ?>">
                                                                <?php echo e($cover->prfile_likes); ?>

                                                            </span>
                                                        </div>
                                                    </div>
                                                    <div
                                                        class="col-6 d-flex justify-content-md-start justify-content-start">
                                                        <?php
                                                            $alreadyLiked = in_array($cover->id, $likedProfileIds);
                                                        ?>
                                                        <button type="button" class="back-btn like-btn"
                                                            data-id="<?php echo e($cover->id); ?>" data-type="profile"
                                                            <?php if($alreadyLiked): ?> style="display: none;" <?php endif; ?>>
                                                            Like
                                                        </button>

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

                            <div class="modal-footer pt-md-3 border-0 d-block mb-1 mb-md-3">
                                <div class="row">
                                    <div class="col-lg-6 col-md-6 col-6">
                                        <button class="back-btn" data-bs-target="#bookModal5<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <div class="col-lg-6 col-md-6 col-6 text-end">
                                        <button class="back-btn" data-bs-target="#bookModal7<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Next
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- ModalToggle7 -->
                <div class="modal fade" id="bookModal7<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel7" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/uploads/profile_images/' . $cover->profile_photo)); ?>"
                                                        alt="profile" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <p>Would you like to talk to <?php echo e($cover->nickname); ?>?</p>
                                                    <!-- <span>Author: Claudia Alves</span> -->
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>

                            <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                <div class="row">
                                    <div class="col-lg-6 col-md-6 col-6">
                                        <button class="back-btn" data-bs-target="#bookModal6<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <?php if(Auth::check() &&
                                            (!Auth::user()->subscription_expiry_date ||
                                                \Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->isPast())): ?>
                                        
                                        <div class="col-lg-6 col-md-6 col-6 text-end">
                                            <button class="back-btn" data-bs-target="#bookModal8<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Next
                                            </button>
                                        </div>
                                    <?php else: ?>
                                        
                                        <div class="col-lg-6 col-md-6 col-6 text-end">
                                            <button class="back-btn" data-bs-target="#bookModal10<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Next
                                            </button>
                                        </div>
                                    <?php endif; ?>

                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <?php if(Auth::check() &&
                        (!Auth::user()->subscription_expiry_date ||
                            \Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->isPast())): ?>
                    <!-- Show Modals ONLY IF trial is NOT active -->

                    <!-- ModalToggle8 -->
                    <div class="modal fade" id="bookModal8<?php echo e($cover->id); ?>" aria-hidden="true"
                        aria-labelledby="exampleModalToggleLabel8" tabindex="-1">
                        <div class="modal-dialog modal-dialog-centered">
                            <div class="modal-content">
                                <div class="modal-body">
                                    <div class="row d-flex justify-content-center align-items-center">
                                        <div class="col-xxl-10 col-lg-10 col-md-11 col-12">
                                            <div class="top-title">
                                                
                                                <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                                <?php if(Auth::check() &&
                                                        Auth::user()->subscription_expiry_date &&
                                                        \Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->isPast()): ?>
                                                    <div class="alert alert-warning text-center">
                                                        Your trial has expired. Please buy a new plan</a>
                                                    </div>
                                                <?php endif; ?>
                                            </div>
                                            <div
                                                class="row d-flex justify-content-center align-items-center gx-5 pt-md-3 gy-4">
                                                <div class="col-lg-5 col-md-5 col-12">
                                                    <div class="detail_book_img_subcription text-lg-end">
                                                        <img src="<?php echo e(asset('website/uploads/profile_images/' . $cover->profile_photo)); ?>"
                                                            alt="profile" class="img-fluid w-100" />
                                                    </div>
                                                </div>
                                                <div class="col-lg-7 col-md-7 col-12">
                                                    <!-- <div class="content_book pt-3 pt-lg-0">
                                                                                                                                                                                                                                                                            <img src="assets/images/Frame 427319595.png" alt="">
                                                                                                                                                                                                                                                                        </div> -->

                                                    <div class="membership mb-4">
                                                        <div class="row d-flex justify-content-center align-items-start">
                                                            <div class="col-lg-12">
                                                                <div class="member-card">
                                                                    <div class="row">
                                                                        <div class="col-6">
                                                                            <div class="member-tile">
                                                                                <h4> <?php echo e($preference->subcription_heading_free ?? ''); ?>

                                                                                </h4>
                                                                            </div>
                                                                        </div>
                                                                        <div class="col-6 text-end">
                                                                            <form
                                                                                id="start-trial-formd-<?php echo e($cover->id); ?>">
                                                                                <?php echo csrf_field(); ?>
                                                                                <button type="submit"
                                                                                    class="back-btn py-2">Start
                                                                                    Trial</button>
                                                                            </form>


                                                                            
                                                                        </div>
                                                                        <div class="member-detail">
                                                                            <div class="member-time mb-3">
                                                                                <span> <?php echo $preference->subcription_sub_heading_free ?? ''; ?></span>
                                                                            </div>
                                                                            <p class="mb-0">
                                                                                <?php echo $preference->subcription_description_free ?? ''; ?>

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

                                                    <div class="membership">
                                                        <div class="row d-flex justify-content-center align-items-start">
                                                            <div class="col-lg-`12">
                                                                <div class="member-card">
                                                                    <div class="row">
                                                                        <div class="col-6">
                                                                            <div class="member-tile">
                                                                                <h4><?php echo e($preference->subcription_heading); ?>

                                                                                </h4>
                                                                            </div>
                                                                        </div>
                                                                        
                                                                        <div class="member-detail">
                                                                            <div class="member-time mb-3">
                                                                                <span> <?php echo $preference->subcription_sub_heading ?? ''; ?></span>
                                                                            </div>
                                                                            <p class="mb-0">
                                                                                <?php echo $preference->subcription_description ?? ''; ?>

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

                                <div class="modal-footer pt-md-5 pt-3 border-0 d-block mb-1 mb-md-3">
                                    <div class="row">
                                        <div class="col-lg-6 col-md-6 col-6">
                                            <button class="back-btn" data-bs-target="#bookModal7<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Back
                                            </button>
                                        </div>
                                        <div class="col-lg-6 col-md-6 col-6 text-end">
                                            <?php
                                                $isActive = false;

                                                if (
                                                    isset($latestSubscription) &&
                                                    $latestSubscription->subscription_start &&
                                                    now()->lt(
                                                        \Carbon\Carbon::parse($latestSubscription->subscription_end),
                                                    )
                                                ) {
                                                    $isActive = true;
                                                } elseif (
                                                    Auth::check() &&
                                                    Auth::user()->subscription_expiry_date &&
                                                    \Carbon\Carbon::parse(
                                                        Auth::user()->subscription_expiry_date,
                                                    )->isFuture()
                                                ) {
                                                    $isActive = true;
                                                }
                                            ?>
                                            <?php if($isActive): ?>
                                                <button class="back-btn" data-bs-target="#bookModal9<?php echo e($cover->id); ?>"
                                                    data-bs-toggle="modal">
                                                    Next
                                                </button>
                                            <?php endif; ?>
                                        </div>

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

                    <!-- ModalToggle9 -->
                    <div class="modal fade" id="bookModal9<?php echo e($cover->id); ?>" aria-hidden="true"
                        aria-labelledby="exampleModalToggleLabel9" tabindex="-1">
                        <div class="modal-dialog modal-dialog-centered">
                            <div class="modal-content">
                                <div class="modal-body">
                                    <div class="row d-flex justify-content-center align-items-center">
                                        <div class="col-xxl-8 col-lg-8 col-md-11 col-12">
                                            <div class="top-title">
                                                
                                                <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                            </div>
                                            <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                                <div class="col-lg-5 col-md-5 col-12">
                                                    <div class="detail_book_img text-lg-end">
                                                        <img src="<?php echo e(asset('website/uploads/profile_images/' . $cover->profile_photo)); ?>"
                                                            alt="profile" class="img-fluid w-100" />
                                                    </div>
                                                </div>
                                                <div class="col-lg-7 col-md-7 col-12">
                                                    <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                        <?php if(Auth::check() &&
                                                                Auth::user()->subscription_expiry_date &&
                                                                !\Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->isPast()): ?>
                                                            <p>Your trial expires on:
                                                                <?php echo e(\Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->format('F d, Y')); ?>

                                                            </p>
                                                        <?php elseif(Auth::check() &&
                                                                Auth::user()->subscription_expiry_date &&
                                                                \Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->isPast()): ?>
                                                            <p>Your trial has expired. Please <a
                                                                    data-bs-target="#bookModal8<?php echo e($cover->id); ?>">buy a
                                                                    new
                                                                    plan</a>.</p>
                                                        <?php else: ?>
                                                            <p>You have not started your trial yet.</p>
                                                        <?php endif; ?>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>

                                <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                    <div class="row">
                                        <div class="col-lg-6 col-md-6 col-6">
                                            <button class="back-btn" data-bs-target="#bookModal8<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Back
                                            </button>
                                        </div>
                                        <div class="col-lg-6 col-md-6 col-6 text-end">
                                            <button class="back-btn" data-bs-target="#bookModal10<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Next
                                            </button>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                <?php endif; ?>
                <!-- ModalToggle10 -->
                <div class="modal fade" id="bookModal10<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel10" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/uploads/profile_images/' . $cover->profile_photo)); ?>"
                                                        alt="profile" class="img-fluid w-100" />
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0 text-md-start text-center">
                                                    <p>Talk to <?php echo e($cover->nickname); ?></p>
                                                    <!-- <span>Author: Claudia Alves</span> -->
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </div>

                            <div class="modal-footer mb-1 mb-md-3 border-0 d-block pt-0">
                                <div class="row">
                                    <?php if(Auth::check() &&
                                            (!Auth::user()->subscription_expiry_date ||
                                                \Carbon\Carbon::parse(Auth::user()->subscription_expiry_date)->isPast())): ?>
                                        <div class="col-lg-6 col-md-6 col-6">
                                            <button class="back-btn" data-bs-target="#bookModal9<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Back
                                            </button>
                                        </div>
                                    <?php else: ?>
                                        <div class="col-lg-6 col-md-6 col-6">
                                            <button class="back-btn" data-bs-target="#bookModal7<?php echo e($cover->id); ?>"
                                                data-bs-toggle="modal">
                                                Back
                                            </button>
                                        </div>
                                    <?php endif; ?>
                                    <div class="col-lg-6 col-md-6 col-6 text-end">
                                        <button class="back-btn" data-bs-target="#bookModal11<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Next
                                        </button>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- ModalToggle11 -->
                <div class="modal fade" id="bookModal11<?php echo e($cover->id); ?>" aria-hidden="true"
                    aria-labelledby="exampleModalToggleLabel11" tabindex="-1">
                    <div class="modal-dialog modal-dialog-centered">
                        <div class="modal-content">
                            <div class="modal-body">
                                <div class="row d-flex justify-content-center align-items-center">
                                    <div class="col-xxl-7 col-lg-7 col-md-11 col-12">
                                        <div class="top-title">
                                            
                                            <h2 class="mb-4 mt-2">Blind Date with a Book</h2>
                                        </div>
                                        <div class="row d-flex justify-content-center align-items-center gx-5 pt-md-3">
                                            <div class="col-lg-5 col-md-5 col-12">
                                                <div class="detail_book_img text-lg-end">
                                                    <img src="<?php echo e(asset('website/uploads/profile_images/' . $cover->profile_photo)); ?>"
                                                        alt="profile" class="img-fluid w-100" />
                                                </div>

                                                <div
                                                    class="row d-flex justify-content-center pt-3 align-items-center d-md-none d-block">
                                                    <div class="col-lg-4 col-md-4 col-4">
                                                        <div class="result-points">
                                                            <p>Requests to talk
                                                                <?php echo e($chatUserCounts[$cover->user_id] ?? 0); ?></p>
                                                        </div>
                                                    </div>

                                                    <div class="col-lg-4 col-md-6 col-4">
                                                        <div class="result-points">
                                                            <p id="like-count-book-<?php echo e($cover->id); ?>">
                                                                Bookmark
                                                                <?php echo e($cover->book_likes); ?></p>
                                                        </div>
                                                    </div>
                                                    <div class="col-lg-4 col-md-6 col-4">
                                                        <div class="result-points">
                                                            <p id="like-count-profile-<?php echo e($cover->id); ?>">
                                                                Profile likes <?php echo e($cover->prfile_likes); ?></p>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                            <div class="col-lg-7 col-md-7 col-12">
                                                <div class="content_book pt-3 pt-lg-0">
                                                    <!-- Chat Box -->
                                                    <div class="chat-box mb-3 p-3 border rounded bg-light"
                                                        id="chat-box-<?php echo e($cover->user_id); ?>"
                                                        style="height: 250px; overflow-y: auto;">
                                                        <!-- Messages will appear here -->
                                                    </div>

                                                    <!-- Input Group -->
                                                    <?php
                                                        $isSelf = auth()->check() && auth()->id() == $cover->user_id;
                                                    ?>

                                                    <div class="input-group">
                                                        <input type="text" class="form-control chat-input"
                                                            data-receiver="<?php echo e($cover->user_id); ?>"
                                                            placeholder="<?php echo e($isSelf ? 'You cannot message yourself.' : ($hasActiveSubscription ? 'Type your message...' : 'please Subscribe.')); ?>"
                                                            <?php echo e(!$hasActiveSubscription || $isSelf ? 'disabled' : ''); ?>>

                                                        <button class="btn back-btn p-2 send-bttn"
                                                            data-receiver="<?php echo e($cover->user_id); ?>"
                                                            data-authenticated="<?php echo e(auth()->check() ? '1' : '0'); ?>"
                                                            <?php echo e(!$hasActiveSubscription || $isSelf ? 'disabled' : ''); ?>>
                                                            Send
                                                        </button>
                                                    </div>




                                                </div>
                                            </div>


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

                            <div class="modal-footer pt-0 border-0 d-block mb-1 mb-md-3">
                                <div class="row d-flex justify-content-center align-items-center pt-2">
                                    <div class="col-lg-3 col-md-3 col-6 text-start">
                                        <button class="back-btn" data-bs-target="#bookModal10<?php echo e($cover->id); ?>"
                                            data-bs-toggle="modal">
                                            Back
                                        </button>
                                    </div>
                                    <div class="col-lg-6 col-md-6 col-7 text-center d-md-block d-none">
                                        <div class="row d-flex justify-content-center align-items-center ">
                                            <div class="col-lg-4 col-md-4 col-12">
                                                <div class="result-points">
                                                    <p>Requests to talk <?php echo e($chatUserCounts[$cover->user_id] ?? 0); ?></p>
                                                </div>
                                            </div>

                                            <div class="col-lg-4 col-md-6 col-12">
                                                <div class="result-points">
                                                    <p id="like-count-book-<?php echo e($cover->id); ?>">
                                                        Bookmark
                                                        <?php echo e($cover->book_likes); ?></p>
                                                </div>
                                            </div>
                                            <div class="col-lg-4 col-md-6 col-12">
                                                <div class="result-points">
                                                    <p id="like-count-profile-<?php echo e($cover->id); ?>">
                                                        Profile likes <?php echo e($cover->prfile_likes); ?></p>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="col-lg-3 col-md-3 col-6 text-end">
                                        <a href="/profile#chats" class="back-btn" id="goToChatTab">
                                            All Chats
                                        </a>

                                    </div>

                                </div>
                            </div>

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

                <!-- ModalToggle12 -->
                
            <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>

            <div class="modal fade" id="bookListModal" tabindex="-1" aria-labelledby="bookListModalLabel"
                aria-hidden="true">
                <div class="modal-dialog modal-dialog-centered">
                    <div class="modal-content">
                        <!-- <div class="modal-header">
                                                                                                                                                                                                                                                                  <h5 class="modal-title mb-4" id="exampleModalLabel">Register For Exclusive Offers</h5>
                                                                                                                                                                                                                                                                  <button type="button" class="btn-close mb-4" data-bs-dismiss="modal" aria-label="Close"></button>                                                                                                                                                           </div> -->
                        <div class="modal-body pb-0">
                            <div class="row d-flex justify-content-center align-items-center mt-3 mb-4">
                                <div class="col-xxl-11 col-lg-11 col-md-11 col-12">
                                    <div class="top-title mb-2">
                                        <h2 class="mb-4">Blind Date with a Book</h2>
                                    </div>
                                    <div class="row d-flex justify-content-center align-items-center my-4">
                                        <div class="col-lg-5 col-md-4 col-12">
                                            <div class="top-title text-start text-lg-end text-md-end">
                                                <h6 class="mb-md-0 mb-2">Search by Location</h6>
                                            </div>
                                        </div>
                                        <div class="col-lg-7 col-md-7 col-12">
                                            <div class="search_country text-lg-end text-md-end text-end">
                                                <select id="CountryModal" class="form-select">
                                                    <option value="">Select Country</option>
                                                    <?php $__currentLoopData = $countries; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $country): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                        <option value="<?php echo e($country); ?>"><?php echo e($country); ?>

                                                        </option>
                                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                                </select>

                                            </div>
                                        </div>
                                    </div>
                                    <div id="book-search" class="owl-carousel owl-theme py-2">
                                        <?php $__currentLoopData = $bookCovers; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $cover): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                            <div class="item " data-country="<?php echo e($cover->country); ?>">
                                                <div class="card border-0">
                                                    <a href=""data-bs-target="#bookModal2<?php echo e($cover->id); ?>"
                                                        data-bs-toggle="modal">
                                                        <img src="<?php echo e(asset('website/images/Book_sample 1.jpg')); ?>"
                                                            class="book-img img-fluid" alt="Book Cover" />
                                                    </a>

                                                    <div class="card-body py-1 px-0">
                                                        <?php
                                                            $desc = $cover->short_description ?? '';
                                                            $chunks = collect(str_word_count($desc, 2))
                                                                ->chunk(ceil(count(str_word_count($desc, 2)) / 3))
                                                                ->map(function ($chunk) {
                                                                    return implode(' ', $chunk->all());
                                                                });
                                                        ?>

                                                        <?php if($chunks->isNotEmpty()): ?>
                                                            <ul class="ps-3 mb-0">
                                                                <?php $__currentLoopData = $chunks; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $line): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                                                    <li class="small">
                                                                        <p class="text-start mb-0"><?php echo e($line); ?>

                                                                        </p>
                                                                    </li>
                                                                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                                            </ul>
                                                        <?php else: ?>
                                                            <p class="card-text text-center pt-1">No description available.
                                                            </p>
                                                        <?php endif; ?>

                                                        <h6 class="text-center mt-3"> My favorite quote</h3>

                                                            <p>&ldquo; <?php echo e($cover->favorite_quotes); ?> &rdquo;</p>

                                                    </div>
                                                </div>
                                            </div>
                                        <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>


                                    </div>
                                    <div id="no-books-modal-message" class="text-center py-4 fs-5"
                                        style="display: none;">
                                        <p>No books available for the selected country.</p>
                                    </div>


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

<?php echo $__env->make('website.layouts.app', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH /home2/gccdemo/public_html/repositories/blinddate/resources/views/website/index.blade.php ENDPATH**/ ?>