
                            <form action="{{ route('exams.index') }}" method="GET">
                                <div class="course-grid__search course-grid__single">
                                    <div class="course-grid__title-box">
                                        <h3 class="course-grid__title">Search Exams</h3>
                                        <div class="course-grid__title-shape-1">
                                            <img src="{{ asset('images/shapes/course-grid-title-shape-1.png') }}" alt="">
                                        </div>
                                    </div>
                                    <div class="course-grid__search-form">
                                           <div class="row">
                                        <div class="col-8"><input type="search" name="search" class="form-control" placeholder="Search by name or code" value="{{ request('search') }}"></div>
                                        <div class="col-4"><button type="submit" class="btn btn-primary"><i class="icon-search"></i> Search</button></div>
                                    </div>
                                        
                                        
                                    </div>
                                </div>

                                <div class="course-grid__skill course-grid__single">
                                    <div class="course-grid__title-box">
                                        <h3 class="course-grid__title">Filters</h3>
                                        <div class="course-grid__title-shape-1">
                                            <img src="{{ asset('images/shapes/course-grid-title-shape-1.png') }}" alt="">
                                        </div>
                                    </div>
                                    <ul class="list-unstyled course-grid__list-item">
                                        <li>
                                            <label class="custom-checkbox">
                                                <input type="checkbox" name="popular" value="1" {{ request('popular') ? 'checked' : '' }} onchange="this.form.submit()">
                                                <span class="checkmark"></span>
                                                <span class="radio-text">Popular exams only</span>
                                            </label>
                                        </li>
                                    </ul>
                                </div>
                            </form>


                            @if($popularExams->count())
                                <div class="course-grid__search course-grid__single mt-4">
                                    <div class="course-grid__title-box">
                                        <h3 class="course-grid__title">Popular Exams</h3>
                                        <div class="course-grid__title-shape-1">
                                            <img src="{{ asset('images/shapes/course-grid-title-shape-1.png') }}" alt="">
                                        </div>
                                    </div>
                                    <ul class="list-unstyled course-grid__list-item">
                                        @foreach($popularExams as $popular)
                                            <li>
                                                <a href="{{ route('exams.show', $popular->slug) }}">{{ $popular->name }}</a>
                                            </li>
                                        @endforeach
                                    </ul>
                                </div>
                            @endif
                                               
@include('layouts.components.contact')