<!DOCTYPE html>

<?php if(!empty(Auth::guard('publisher')->user()->name)): ?>
    <html lang="<?php echo e(str_replace('_', '-', app()->getLocale())); ?>">
    <?php
        $data = UserSystemInfoHelper::site_settings();
        $user_notification = UserSystemInfoHelper::News_and_announcement();
        $all_offer = UserSystemInfoHelper::all_offer();
    ?>

    <head>
        <meta charset="utf-8">
        <meta name="viewport" content="width=device-width, initial-scale=1">

        <!-- CSRF Token -->
        <meta name="csrf-token" content="<?php echo e(csrf_token()); ?>">

        <title><?php echo e($data->site_name); ?> Publisher Panel</title>
        <link rel="apple-touch-icon" sizes="180x180" href="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>">
        <link rel="icon" type="image/png" sizes="32x32" href="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>">
        <link rel="icon" type="image/png" sizes="16x16" href="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>">
        <link rel="shortcut icon" type="image/x-icon" href="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>">
        <link rel="manifest" href="<?php echo e(config('app.url')); ?>/public/public/assets/img/favicons/manifest.json">
        <meta name="msapplication-TileImage" content="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>">
        <meta name="theme-color" content="#ffffff">

        <link rel="dns-prefetch" href="//fonts.gstatic.com">
        <link href="https://fonts.googleapis.com/css?family=Nunito" rel="stylesheet">

        
        <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css">

        <!-- Select2 css -->
        <link href="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/select2/css/select2.min.css"
            rel="stylesheet" type="text/css" />

        <!-- Daterangepicker css -->
        <link rel="stylesheet"
            href="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/daterangepicker/daterangepicker.css">

        <!-- Vector Map css -->
        <link rel="stylesheet"
            href="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/admin-resources/jquery.vectormap/jquery-jvectormap-1.2.2.css">

        <!-- Theme Config Js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/js/config.js"></script>

        <!-- App css -->
        <link href="<?php echo e(config('app.url')); ?>/public/public/assets/assets/css/app.min.css" rel="stylesheet"
            type="text/css" id="app-style" />

        <!-- Icons css -->
        <link href="<?php echo e(config('app.url')); ?>/public/public/assets/assets/css/icons.min.css" rel="stylesheet"
            type="text/css" />

        <link href="<?php echo e(config('app.url')); ?>/public/public/vendors/sweetalert2/sweetalert2.min.css" rel="stylesheet">

        <style>
            li.list-inline-item {
                transition: all .5s;
            }

            li.list-inline-item:hover {
                transform: scale(1.3);
            }

            .popover {
                --ct-popover-bg: #6da09c;
                --ct-popover-border-color: #6da09c;
            }

            .popover-body {
                color: white
            }
            #search-dropdown{
                height: 300px !important;
                overflow: auto;
            }
        </style>

    </head>


    <body>

        <!-- Begin page -->
        <div class="wrapper">


            <!-- ========== Topbar Start ========== -->
            <div class="navbar-custom">
                <div class="topbar container-fluid">
                    <div class="d-flex align-items-center gap-lg-2 gap-1">

                        <!-- Topbar Brand Logo -->
                        <div class="logo-topbar">
                            <!-- Logo light -->
                            <a href="<?php echo e(route('publisher.dashboard')); ?>" class="logo-light">
                                <span class="logo-lg">
                                    <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->logo); ?>" alt="logo">
                                </span>
                                <span class="logo-sm">
                                    <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>" alt="small logo">
                                </span>
                            </a>

                            <!-- Logo Dark -->
                            <a href="<?php echo e(route('publisher.dashboard')); ?>" class="logo-dark">
                                <span class="logo-lg">
                                    <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->logo); ?>" alt="dark logo">
                                </span>
                                <span class="logo-sm">
                                    <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>" alt="small logo">
                                </span>
                            </a>
                        </div>

                        <!-- Sidebar Menu Toggle Button -->
                        <button class="button-toggle-menu">
                            <i class="ri-menu-2-fill"></i>
                        </button>

                        <!-- Topbar Search Form -->
                        <div class="app-search dropdown d-none d-lg-block">
                            <form>
                                <div class="input-group">
                                    <input type="search" class="form-control dropdown-toggle" placeholder="Search..."
                                        id="top-search">
                                    <span class="ri-search-line search-icon"></span>
                                </div>
                            </form>

                            <?php if(Auth::guard('publisher')->user()->status === 'Active'): ?>
                                <div class="dropdown-menu dropdown-menu-animated dropdown-lg" id="search-dropdown">
                                    <?php $__currentLoopData = $all_offer; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $offer): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <a href="<?php echo e(route('publisher.offers-details', $offer->id)); ?>" class="dropdown-item notify-item">
                                            <div class="d-flex">
                                                <?php if($offer->preview_url != null || $offer->preview_url != ''): ?>
                                                    <img class="d-flex me-2 rounded" src="<?php echo e(asset('uploads')); ?>/<?php echo e($offer->preview_url); ?>" alt="Generic placeholder image" height="32">
                                                <?php else: ?>
                                                    <img width="50" class="d-flex me-2 rounded" src="https://cdn.textstudio.com/output/sample/normal/0/3/5/5/offer-logo-275-5530.png" alt="">
                                                <?php endif; ?>

                                                <div class="w-100">
                                                    <h5 class="m-0 fs-14"><?php echo e(\Illuminate\Support\Str::limit($offer->offer_name, 20)); ?></h5>
                                                    <span class="fs-10 mb-0"><?php echo e($offer->created_at); ?></span>
                                                </div>
                                            </div>
                                        </a>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </div>
                            <?php endif; ?>
                        </div>
                    </div>

                    <ul class="topbar-menu d-flex align-items-center gap-3">
                        <li class="dropdown d-lg-none">
                            <a class="nav-link dropdown-toggle arrow-none" data-bs-toggle="dropdown" href="#"
                                role="button" aria-haspopup="false" aria-expanded="false">
                                <i class="ri-search-line fs-22"></i>
                            </a>
                            <div class="dropdown-menu dropdown-menu-animated dropdown-lg p-0">
                                <form class="p-3">
                                    <input type="search" class="form-control" placeholder="Search ..."
                                        aria-label="Recipient's username">
                                </form>
                            </div>
                        </li>

                        <li class="dropdown">
                            <a class="nav-link dropdown-toggle arrow-none" data-bs-toggle="dropdown" href="#"
                                role="button" aria-haspopup="false" aria-expanded="false">
                                <img src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/images/flags/us.jpg"
                                    alt="user-image" class="me-0 me-sm-1" height="12">
                                <span class="align-middle d-none d-lg-inline-block">English</span> <i
                                    class="ri-arrow-down-s-line d-none d-sm-inline-block align-middle"></i>
                            </a>
                            <div class="dropdown-menu dropdown-menu-end dropdown-menu-animated">

                                <!-- item-->
                                <a href="javascript:void(0);" class="dropdown-item">
                                    <img src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/images/flags/germany.jpg"
                                        alt="user-image" class="me-1" height="12"> <span
                                        class="align-middle">German</span>
                                </a>

                                <!-- item-->
                                <a href="javascript:void(0);" class="dropdown-item">
                                    <img src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/images/flags/italy.jpg"
                                        alt="user-image" class="me-1" height="12"> <span
                                        class="align-middle">Italian</span>
                                </a>

                                <!-- item-->
                                <a href="javascript:void(0);" class="dropdown-item">
                                    <img src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/images/flags/spain.jpg"
                                        alt="user-image" class="me-1" height="12"> <span
                                        class="align-middle">Spanish</span>
                                </a>

                                <!-- item-->
                                <a href="javascript:void(0);" class="dropdown-item">
                                    <img src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/images/flags/russia.jpg"
                                        alt="user-image" class="me-1" height="12"> <span
                                        class="align-middle">Russian</span>
                                </a>

                            </div>
                        </li>

                        <li class="dropdown notification-list">
                            <a class="nav-link dropdown-toggle arrow-none" data-bs-toggle="dropdown" href="#"
                                role="button" aria-haspopup="false" aria-expanded="false">
                                <i class="ri-notification-3-line fs-22"></i>
                                <span class="noti-icon-badge"></span>
                            </a>
                            <div class="dropdown-menu dropdown-menu-end dropdown-menu-animated dropdown-lg py-0">
                                <div class="p-2 border-top-0 border-start-0 border-end-0 border-dashed border">
                                    <div class="row align-items-center">
                                        <div class="col">
                                            <h6 class="m-0 fs-16 fw-semibold"> Notification</h6>
                                        </div>
                                        <div class="col-auto">
                                            <a href="javascript: void(0);"
                                                class="text-dark text-decoration-underline">
                                                <small>Clear All</small>
                                            </a>
                                        </div>
                                    </div>
                                </div>

                                <div style="max-height: 300px;" data-simplebar>

                                    <?php $messages=UserSystemInfoHelper::get_all_messages('admin');?>
                                    <?php $__currentLoopData = $user_notification; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $notification): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                                        <a href="javascript:void(0);"
                                            class="dropdown-item p-0 notify-item unread-noti card m-0 shadow-none">
                                            <div class="card-body">
                                                <div class="d-flex align-items-center">
                                                    <div class="flex-shrink-0">
                                                        <div class="notify-icon bg-primary">
                                                            <i class="ri-message-3-line fs-18"></i>
                                                        </div>
                                                    </div>
                                                    <div class="flex-grow-1 text-truncate ms-2">
                                                        <h5 class="noti-item-title fw-semibold fs-14">
                                                            <?php echo e($notification->title); ?> <small
                                                                class="fw-normal text-muted float-end ms-1">1 min
                                                                ago</small></h5>
                                                        <small
                                                            class="noti-item-subtitle text-muted"><?php echo e($notification->description); ?></small>
                                                    </div>
                                                </div>
                                            </div>
                                        </a>
                                    <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
                                </div>

                                <!-- All-->
                                <a href="javascript:void(0);"
                                    class="dropdown-item text-center text-primary text-decoration-underline fw-bold notify-item border-top border-light py-2">
                                    View All
                                </a>

                            </div>
                        </li>

                       

                        <li class="d-none d-sm-inline-block">
                            <div class="nav-link" id="light-dark-mode">
                                <i class="ri-moon-line fs-22"></i>
                            </div>
                        </li>


                        <li class="d-none d-md-inline-block">
                            <a class="nav-link" href="" data-toggle="fullscreen">
                                <i class="ri-fullscreen-line fs-22"></i>
                            </a>
                        </li>

                        <li class="dropdown">
                            <a class="nav-link dropdown-toggle arrow-none nav-user px-2" data-bs-toggle="dropdown"
                                href="#" role="button" aria-haspopup="false" aria-expanded="false">
                                <span class="account-user-avatar">
                                    <img src="<?php echo e(UserSystemInfoHelper::publishar_image(Auth::guard('publisher')->user()->publisher_image)); ?>"
                                        alt="user-image" width="32" class="rounded-circle">
                                </span>
                                <span class="d-lg-flex flex-column gap-1 d-none">
                                    <h5 class="my-0"><?php echo e(Auth::guard('publisher')->user()->name); ?></h5>
                                    <h6 class="my-0 fw-normal">Publisher</h6>
                                </span>
                            </a>
                            <div class="dropdown-menu dropdown-menu-end dropdown-menu-animated profile-dropdown">
                                <!-- item-->
                                <div class=" dropdown-header noti-title">
                                    <h6 class="text-overflow m-0">Welcome !</h6>
                                </div>

                                <!-- item-->
                                <a href="<?php echo e(route('publisher.account-information')); ?>" class="dropdown-item">
                                    <i class="ri-account-circle-line fs-18 align-middle me-1"></i>
                                    <span>My Account</span>
                                </a>

                                <!-- item-->
                                <a href="<?php echo e(route('publisher.account-information')); ?>" class="dropdown-item">
                                    <i class="ri-settings-4-line fs-18 align-middle me-1"></i>
                                    <span>Settings</span>
                                </a>

                                <!-- item-->
                                <a href="<?php echo e(route('publisher.support')); ?>" class="dropdown-item">
                                    <i class="ri-customer-service-2-line fs-18 align-middle me-1"></i>
                                    <span>Support</span>
                                </a>

                                <!-- item-->
                                <a href="<?php echo e(route('publisher.logout')); ?>" onclick="event.preventDefault(); document.getElementById('publisher-logout-form').submit();" class="dropdown-item">
                                    <i class="ri-logout-box-line fs-18 align-middle me-1"></i>
                                    <span>Logout</span>
                                </a>
                                <form id="publisher-logout-form" action="<?php echo e(route('publisher.logout')); ?>"
                                    method="POST" class="d-none">
                                    <?php echo csrf_field(); ?>
                                </form>
                            </div>
                        </li>
                    </ul>
                </div>
            </div>
            <!-- ========== Topbar End ========== -->

            <!-- ========== Left Sidebar Start ========== -->
            <div class="leftside-menu">

                <!-- Brand Logo Light -->
                <a href="<?php echo e(route('publisher.dashboard')); ?>" class="logo logo-light">
                    <span class="logo-lg">
                        <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->logo); ?>" alt="logo">
                    </span>
                    <span class="logo-sm">
                        <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>" alt="small logo">
                    </span>
                </a>

                <!-- Brand Logo Dark -->
                <a href="<?php echo e(route('publisher.dashboard')); ?>" class="logo logo-dark">
                    <span class="logo-lg">
                        <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->logo); ?>" alt="dark logo">
                    </span>
                    <span class="logo-sm">
                        <img src="<?php echo e(asset('site_images')); ?>/<?php echo e($data->icon); ?>" alt="small logo">
                    </span>
                </a>
                <!-- Full Sidebar Menu Close Button -->
                <div class="button-close-fullsidebar">
                    <i class="ri-close-fill align-middle"></i>
                </div>

                <!-- Sidebar -left -->
                <div class="h-100" id="leftside-menu-container" data-simplebar>
                    <!-- Leftbar User -->
                    <div class="leftbar-user">
                        <a href="dashboard">
                            <img src="<?php echo e(UserSystemInfoHelper::publishar_image(Auth::guard('publisher')->user()->publisher_image)); ?>"
                                alt="user-image" height="42" class="rounded-circle shadow-sm">
                            <span class="leftbar-user-name mt-2"><?php echo e(Auth::guard('publisher')->user()->name); ?></span>
                        </a>
                    </div>

                    <!--- Sidemenu -->
                    <ul class="side-nav">
                        <?php if(Auth::guard('publisher')->user()->status == 'Active'): ?>
                            <li class="side-nav-item">
                                <a href="<?php echo e(route('publisher.dashboard')); ?>" class="side-nav-link">
                                    <i class="ri-dashboard-2-fill"></i>
                                    <span> Dashboard </span>
                                </a>
                            </li>

                            <li class="side-nav-item">
                                <a href="<?php echo e(route('publisher.show-smartlink')); ?>" class="side-nav-link">
                                    <i class="ri-links-line"></i>
                                    <span> Smart Link </span>
                                </a>
                            </li>
                            <?php if(Auth::guard('publisher')->user()->expert_mode == '1'): ?>
                                <li class="side-nav-item">
                                    <a data-bs-toggle="collapse" href="#cpa_offers" aria-expanded="false"
                                        aria-controls="sidebarEmail" class="side-nav-link">
                                        <i class="fa-solid fa-tags"></i>
                                        <span> CPA Offers </span>
                                        <span class="menu-arrow"></span>
                                    </a>
                                    <div class="collapse" id="cpa_offers">
                                        <ul class="side-nav-second-level">
                                            <li>
                                                <a href="<?php echo e(route('publisher.all-offers')); ?>">All Offers</a>
                                            </li>

                                            <li>
                                                <a href="<?php echo e(route('publisher.public-offers')); ?>">Public Offers</a>
                                            </li>
                                            <li>
                                                <a href="<?php echo e(route('publisher.my-offers')); ?>">My Offers</a>
                                            </li>
                                            <li>
                                                <a href="<?php echo e(route('publisher.new-offers')); ?>">New Offers</a>
                                            </li>
                                            <li>
                                                <a href="<?php echo e(route('publisher.top-offers')); ?>">Top Offers</a>
                                            </li>
                                        </ul>
                                    </div>
                                </li>
                            <?php endif; ?>
                   <!--           <li class="side-nav-item">
                                <a href="<?php echo e(route('publisher.view-performance')); ?>" class="side-nav-link">
                                    <i class="fa-solid fa-chart-pie"></i>
                                    <span> Reports </span>
                                </a>
                            </li>   -->
                            <li class="side-nav-item">
                                <a data-bs-toggle="collapse" href="#reports" aria-expanded="false"
                                    aria-controls="sidebarEmail" class="side-nav-link">
                                    <i class="fa-solid fa-chart-pie"></i>
                                    <span> Reports </span>
                                    <span class="menu-arrow"></span>
                                </a>
                                <div class="collapse" id="reports">
                                    <ul class="side-nav-second-level">
                                        <li>
                                            <a href="<?php echo e(route('publisher.view-performance')); ?>">Performance</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.reports')); ?>">Conversion Report</a>
                                        </li>
                                    <!--    <li>
                                            <a href="<?php echo e(route('publisher.daily-report')); ?>">Click Report</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.report-by-date')); ?>">Report By Date</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.report-by-device')); ?>">Report By Device</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.report-by-browser')); ?>">Report By Browser</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.report-by-country')); ?>">Report By Country</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.report-by-sid')); ?>">Report By SID</a>
                                        </li>  -->
                                    </ul>
                                </div>
                            </li>    
                            <li class="side-nav-item">
                                <a data-bs-toggle="collapse" href="#My_account" aria-expanded="false"
                                    aria-controls="sidebarEmail" class="side-nav-link">
                                    <i class="ri-shield-user-fill"></i>
                                    <span> My Account </span>
                                    <span class="menu-arrow"></span>
                                </a>
                                <div class="collapse" id="My_account">
                                    <ul class="side-nav-second-level">
                                        <li>
                                            <a href="<?php echo e(route('publisher.account-information')); ?>">Account
                                                Information</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.login-history')); ?>">Login History</a>
                                        </li>
                                    </ul>
                                </div>
                            </li>
                            <li class="side-nav-item">
                                <a href="<?php echo e(route('publisher.payment-history')); ?>" class="side-nav-link">
                                    <i class="ri-wallet-3-fill"></i>
                                    <span> Payment History </span>
                                </a>
                            </li>
                            <li class="side-nav-item">
                                <a href="<?php echo e(route('publisher.support')); ?>" class="side-nav-link">
                                    <i class="ri-customer-service-2-line"></i>
                                    <span> Support </span>
                                </a>
                            </li>
                        <?php endif; ?>
                        <li class="side-nav-item">
                            <a href="<?php echo e(route('publisher.chat', Auth::guard('publisher')->user()->affliate_manager_id)); ?>"
                                class="side-nav-link">
                                <i class="fa-solid fa-comments"></i>
                                <span> Chat </span>
                            </a>
                        </li>
                        <?php if(Auth::guard('publisher')->user()->status == 'Active'): ?>
                            <li class="side-nav-item">
                                <a data-bs-toggle="collapse" href="#postback" aria-expanded="false"
                                    aria-controls="sidebarEmail" class="side-nav-link">
                                    <i class="ri-arrow-go-back-fill"></i>
                                    <span> Postback </span>
                                    <span class="menu-arrow"></span>
                                </a>
                                <div class="collapse" id="postback">
                                    <ul class="side-nav-second-level">
                                        <li>
                                            <a href="<?php echo e(route('publisher.postback')); ?>">Global Postback</a>
                                        </li>
                                        <li>
                                            <a href="<?php echo e(route('publisher.send-postback')); ?>">Postback sent</a>
                                        </li>
                                    </ul>
                                </div>
                            </li>
                         <!--   <li class="side-nav-item">
                                <a href="<?php echo e(route('publisher.api')); ?>" class="side-nav-link">
                                    <i class="ri-code-s-slash-fill"></i>
                                    <span> API </span>
                                </a>
                            </li> -->
                        <?php endif; ?>
                    </ul>
                    <!--- End Sidemenu -->
                    <div class="clearfix"></div>
                    <?php

                        $idm = Auth::guard('publisher')->user()->affliate_manager_id;
                        $manager = App\Models\Affliate::where('id', $idm)->first();
                    ?>
                    <div class="server-time" style="text-align: center; margin-top: 0px; margin-bottom: 20px">
                        <p>Manager</p>
                        <img class="rounded-circle img-thumbnail" style="width: 70%; height: 177px; object-fit: cover"
                            src="<?php echo e(UserSystemInfoHelper::publishar_image($manager->photo)); ?>" alt=""
                            srcset="">
                        <p class="text-white" style="margin-top: -2.5rem">
                            <?php echo e(\Illuminate\Support\Str::limit($manager->name, 11)); ?></p>
                        <div class="mt-4">
                            <ul class="social-list list-inline mt-3 mb-0">
                                <li class="list-inline-item" data-bs-toggle="popover" data-bs-placement="bottom"
                                    data-bs-content="<?php echo e($manager->address); ?>" title=""
                                    aria-describedby="popover844820">
                                    <a href="javascript: void(0);"
                                        class="social-list-item border-primary text-primary"><i
                                            class="ri-skype-fill"></i></a>
                                </li>
                                <li class="list-inline-item" data-bs-toggle="popover" data-bs-placement="bottom"
                                    data-bs-content="<?php echo e($manager->email); ?>" title=""
                                    aria-describedby="popover844820">
                                    <a href="javascript: void(0);"
                                        class="social-list-item border-danger text-danger"><i
                                            class="ri-mail-fill"></i></a>
                                </li>
                                <li class="list-inline-item" data-bs-toggle="popover" data-bs-placement="bottom"
                                    data-bs-content="<?php echo e($manager->skype); ?>" title=""
                                    aria-describedby="popover844820">
                                    <a href="javascript: void(0);" class="social-list-item border-info text-info"><i
                                            class="ri-telegram-fill"></i></a>
                                </li>
                            </ul>
                        </div>
                    </div>
                </div>
            </div>
            <!-- ========== Left Sidebar End ========== -->

            <!-- ============================================================== -->
            <!-- Start Page Content here -->
            <!-- ============================================================== -->





            <div class="content-page">
                <div class="content">

                    <!-- Start Content-->
                    <?php if(Auth::guard('publisher')->user()->status === 'Active'): ?>
                        <?php echo $__env->yieldContent('content'); ?>
                    <?php else: ?>
                        <?php if(Request::url() === route('publisher.chat', Auth::guard('publisher')->user()->affliate_manager_id)): ?>
                            <?php echo $__env->yieldContent('content'); ?>
                        <?php else: ?>
                            <div class="card-body bg-light">
                                <div class="row justify-content-center">
                                    <div class="col-lg-10 col-xxl-12">
                                        <div class="card shadow-none mb-3"><img class="card-img-top"
                                                src="<?php echo e(config('app.url')); ?>/public/public/assets/img/icons/spot-illustrations/6.png"
                                                alt="" />
                                            <div class="card-body">
                                                <h3 class="fw-semi-bold">Hey Dude, Welcome to CPALIDER Network!</h3>
                                                <p>Currently Your account is <span
                                                        style="color:maroon;font-widht:bold;">Waiting for
                                                        Approval</span></p>
                                                <p>If you want to <span
                                                        style="color:green;font-width:bold;">Active</span> your account
                                                    then Your are Requested to Talk with Your Manager.</p>
                                                <p>Your Personal Account Manager <span
                                                        style="color:green;font-width:bold;">Email:</span>
                                                    SUPPORT@CPALIDER.COM</p>
                                                <div class="text-center">
                                                    <button class="btn btn-success btn-lg my-3" type="button"><a
                                                            href="<?php echo e(route('publisher.chat', Auth::guard('publisher')->user()->affliate_manager_id)); ?>"
                                                            style="text-decoration:none;color:white;">Talk
                                                            Now</a></button>
                                                    <div class="text-center">
                                                        <button class="btn btn-success btn-lg my-3" type="button"><a
                                                                href="#"
                                                                style="text-decoration:none;color:white;">Skype</a></button><small
                                                            class="d-block">For any issues faced, Please contact with
                                                            your <a
                                                                href="<?php echo e(route('publisher.chat', Auth::guard('publisher')->user()->affliate_manager_id)); ?>">Manager</a>.</small>
                                                    </div>
                                                </div>
                                            </div>

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

                    <?php endif; ?>
                    <!-- container -->

                </div>
                <!-- content -->

                <!-- Footer Start -->
                <footer class="footer">
                    <div class="container-fluid">
                        <div class="row">
                            <div class="col-md-6">
                                <script>
                                    document.write(new Date().getFullYear())
                                </script> © CPALIDER - CPALIDER.COM
                            </div>
                            <div class="col-md-6">
                                <div class="text-md-end footer-links d-none d-md-block">
                                    <a href="javascript: void(0);">About</a>
                                    <a href="javascript: void(0);">Support</a>
                                    <a href="javascript: void(0);">Contact Us</a>
                                </div>
                            </div>
                        </div>
                    </div>
                </footer>
                <!-- end Footer -->

            </div>

            <!-- ============================================================== -->
            <!-- End Page content -->
            <!-- ============================================================== -->

        </div>
        <!-- END wrapper -->




        <script src="https://code.jquery.com/jquery-3.6.4.min.js"></script>


        <!-- Vendor js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/js/vendor.min.js"></script>

        <!--  Select2 Plugin Js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/select2/js/select2.min.js"></script>

        <!-- Daterangepicker js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/daterangepicker/moment.min.js"></script>
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/daterangepicker/daterangepicker.js"></script>

        <!-- Apex Charts js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/apexcharts/apexcharts.min.js"></script>

        <!-- Vector Map js -->
        <script
            src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/admin-resources/jquery.vectormap/jquery-jvectormap-1.2.2.min.js">
        </script>
        <script
            src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/vendor/admin-resources/jquery.vectormap/maps/jquery-jvectormap-world-mill-en.js">
        </script>

        
        <script src="<?php echo e(config('app.url')); ?>/public/public/vendors/sweetalert2/sweetalert2.min.js"></script>

        <!-- Dashboard App js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/js/pages/demo.dashboard.js"></script>

        <!-- App js -->
        <script src="<?php echo e(config('app.url')); ?>/public/public/assets/assets/js/app.min.js"></script>
        <?php echo $__env->yieldContent('js'); ?>
        <script>
            $(function() {
                $('#offer_search_box').keyup(function() {
                    var text = $(this).val();
                    var csrf = $("meta[name=csrf-token]").attr("content");
                    $.ajax({
                        url: "<?php echo e(route('admin.search_offer_dashboard')); ?>",
                        type: 'post',
                        dataType: 'JSON',
                        headers: {
                            "X-CSRFToken": csrf
                        },
                        data: {
                            "_token": csrf,
                            'text': text,
                            'route': 'publisher'
                        },
                        success: function(result) {
                            $('.loader').fadeOut();
                            // console.log(result);
                            if (!result.status) {
                                Swal.fire('Failed', result.message, 'error');

                            } else {

                                $('#all_offers_results').empty();
                                // $('.emojiarea-editor').empty();
                                // $('#chat-message').val('');
                                // $('#chat-file-upload').val('');
                                $('#all_offers_results').append(result.data);


                            }
                        },

                    });
                });
            });

            function updateTime() {
                const timeElement = document.getElementById('time');
                const dateElement = document.getElementById('date');

                const now = new Date();
                const hours = now.getUTCHours();
                const minutes = now.getUTCMinutes();
                const seconds = now.getUTCSeconds();

                const ampm = hours >= 12 ? 'PM' : 'AM';
                const formattedHours = hours % 12 === 0 ? 12 : hours % 12;
                const formattedTime =
                    `${formatDigits(formattedHours)}:${formatDigits(minutes)}:${formatDigits(seconds)} ${ampm}`;
                timeElement.textContent = formattedTime;

                const months = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
                const day = now.getUTCDate();
                const month = months[now.getUTCMonth()];
                const year = now.getUTCFullYear();
                dateElement.textContent = `${day} ${month}, ${year} (UTC)`;
            }

            function formatDigits(value) {
                return value < 10 ? `0${value}` : value;
            }

            // Update time every second
            setInterval(updateTime, 1000);

            // Initial update
            updateTime();
        </script>

    </body>

    </html>
<?php endif; ?>
<?php /**PATH /home/admin/partner.cpalider.com/backend/resources/views/publisher/layout/dashboard.blade.php ENDPATH**/ ?>