<header class="inner-header">
    <div class="nav_container">
        <!--Menu-->
        <section class="top_navbar">
            <div class="container">
                <div class="content">
                    <div class="row">
                        <div class="col-lg-6">
                            <div class="socail_icons">
                                @if(($settings['youtube'] ?? ''))
                                    <a target="_blank" href="{{($settings['youtube'] ?? '#')}}">
                                        <i class="bi bi-youtube"></i>
                                    </a>
                                @endif
                                @if(($settings['linkedin'] ?? ''))
                                    <a target="_blank" href="{{($settings['linkedin'] ?? '#')}}">
                                        <i class="bi bi-linkedin"></i>
                                    </a>
                                @endif
                                @if(($settings['snapchat'] ?? ''))
                                    <a target="_blank" href="{{($settings['snapchat'] ?? '#')}}">
                                        <i class="bi bi-snapchat"></i>
                                    </a>
                                @endif
                                @if(($settings['twitter'] ?? ''))
                                    <a target="_blank" href="{{($settings['twitter'] ?? '#')}}">
                                        <i class="bi bi-twitter"></i>
                                    </a>
                                @endif
                                @if(($settings['instagram'] ?? ''))
                                    <a target="_blank" href="{{($settings['instagram'] ?? '#')}}">
                                        <i class="bi bi-instagram"></i>
                                    </a>
                                @endif
                                @if(($settings['tiktok'] ?? ''))
                                    <a target="_blank" href="{{($settings['tiktok'] ?? '#')}}">
                                        <i class="bi bi-tiktok"></i>
                                    </a>
                                @endif
                                @if(($settings['facebook'] ?? ''))
                                    <a target="_blank" href="{{($settings['facebook'] ?? '#')}}">
                                        <i class="bi bi-facebook"></i>
                                    </a>
                                @endif
                            </div>
                        </div>
                        <div class="col-lg-6">
                            <div class="top_links text-end">
                                <a href="tel::{{($settings['site_phone'] ?? '+966-744522331')}}">
                                    <i class="bi bi-phone"></i>
                                    <span>{{($settings['site_phone'] ?? '+966-744522331')}}</span>
                                </a>
                                <a href="#">
                                    <i class="bi bi-geo-alt"></i>
                                    <span>{{($settings['site_address'] ?? '')}}</span>
                                </a>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </section>
        <nav class="navbar navbar-expand-lg navbar-dark">
            <div class="container align-items-start">
                <a class="navbar-brand" href="{{LaravelLocalization::getLocalizedURL($lang, route('home'), [], true)}}">
                    <img src="{{asset('assets/web/images/logo.svg')}}" alt="">
                </a>
                <button class="navbar-toggler" type="button" data-bs-toggle="collapse"
                        data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent"
                        aria-expanded="false" aria-label="Toggle navigation">
                    <span class="navbar-toggler-icon"></span>
                </button>
                <div class="collapse navbar-collapse mt-4" id="navbarSupportedContent">
                    <ul class="navbar-nav m-auto">
                        <li class="nav-item">
                            <a class="nav-link {{isActive(route('home'))}}" aria-current="page" href="{{LaravelLocalization::getLocalizedURL($lang, route('home'), [], true)}}">{{__('main.home')}} </a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="{{LaravelLocalization::getLocalizedURL($lang, route('aboutUs'), [], true)}}">{{__('abouts.head')}}</a>
                        </li>
                        <li class="nav-item dropdown">
                            <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-bs-toggle="dropdown" aria-expanded="false">
                                {{__('main.services')}}
                            </a>
                            <ul class="dropdown-menu" aria-labelledby="navbarDropdown">
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('consulting.consultingBookingForm'), [], true)}}">{{__('main.consultation')}}</a></li>
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('cases.index'), [], true)}}">{{__('main.issues')}}</a></li>
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('documentation.index'), [], true)}}">{{__('main.documentation')}}</a></li>
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('company.index'), [], true)}}">{{__('companyRequests.companies')}}</a></li>
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('other.index'), [], true)}}">{{__('otherRequests.others')}}</a></li>
                            </ul>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="{{route('home')}}#numbers">{{__('main.mattered_numbers')}}</a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link" href="{{route('home')}}#partners">{{__('partners.head')}}</a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link {{isActive(route('news.index'))}}" href="{{LaravelLocalization::getLocalizedURL($lang, route('news.index'), [], true)}}">{{__('articles.head')}}</a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link {{isActive(route('faq.index'))}}" href="{{LaravelLocalization::getLocalizedURL($lang, route('faq.index'), [], true)}}">{{__('faqs.head')}}</a>
                        </li>
                        <li class="nav-item">
                            <a class="nav-link {{isActive(route('contactUs'))}}" href="{{LaravelLocalization::getLocalizedURL($lang, route('contactUs'), [], true)}}">{{__('visitorMessages.head')}}</a>
                        </li>
                    </ul>
                    <div class="d-flex">
                        <div class="dropdown drop_noti">
                            <button class="butn bg-white me-3 dropdown-toggle" type="button" id="dropdownMenuButton1" data-bs-toggle="dropdown" aria-expanded="false">
                                <span class="text-dark me-1"> <i class="bi bi-person"></i>
                                    @if(auth()->check() && auth()->user()->role == 'user')
                                        {{wordLimit(auth()->user()->name, 1, '')}}
                                    @else
                                        {{__('members.login_register')}}
                                    @endif
                                </span>
                            </button>
                            @if(notifications())
                                <span class="ind"> <i class="bi bi-circle-fill"></i> </span>
                            @endif
                            <ul class="dropdown-menu" aria-labelledby="dropdownMenuButton1">
                                @if(auth()->check() && auth()->user()->role == 'user')
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.profile'), [], true)}}">{{__('members.my_profile')}}</a></li>
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.myConsulting'), [], true)}}">{{__('members.my_consulting')}}</a></li>
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.myDocumentations'), [], true)}}">{{__('members.my_documentations')}}</a></li>
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.caseRequestsAndUpdates'), [], true)}}">{{__('caseRequests.case_requests_and_updates')}}</a></li>
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.companyRequests'), [], true)}}">{{__('companyRequests.head')}}</a></li>
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.otherRequests'), [], true)}}">{{__('otherRequests.head')}}</a></li>
                                    {{--                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.caseUpdates'), [], true)}}">{{__('members.case_updates')}}</a></li>--}}
                                    <!--<li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.notifications'), [], true)}}">{{__('members.notifications')}} {!! notifications() ? '<i class="fa fa-bell text-danger"></i> <span class="text-danger notification_counter">'. notifications() .' </span>' : '' !!}</a></li>-->
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.notifications'), [], true)}}">{{__('members.notifications')}} {!! notifications() ? '<span class="text-danger notification_counter">'. notifications() .' </span>' : '' !!}</a></li>
                                    <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.logout'), [], true)}}">{{__('members.logout')}}</a></li>
                                @else
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.login'), [], true)}}">{{__('members.login')}}</a></li>
                                <li><a class="dropdown-item" href="{{LaravelLocalization::getLocalizedURL($lang, route('user.register'), [], true)}}">{{__('members.register')}}</a></li>
                                @endif
                            </ul>
                        </div>
                        @if($lang == 'ar')
                            <a href="{{LaravelLocalization::getLocalizedURL('en', null, [], true)}}" class="butn sub_butn">
                                <span> <i class="bi bi-globe me-1"></i> {{__('main.another_lang_short')}}</span>
                            </a>
                        @else
                            <a href="{{LaravelLocalization::getLocalizedURL('ar', null, [], true)}}" class="butn sub_butn">
                                <span> <i class="bi bi-globe me-1"></i> {{__('main.another_lang_short')}}</span>
                            </a>
                        @endif
                    </div>
                </div>
            </div>
        </nav>
    </div>
</header>
