<div class="page-margin video-player-page pt_homepg_whote_bg">
	<div class="owl-carousel pl_feat_vid_slider owl-theme">
		<?php if (!empty($pt->videos_array)) {
			foreach ($pt->videos_array as $key => $video_slide) {
		?>
			<div class="pl_feat_vid_slide">
				<div class="pt_fv_blur_img">
					<div style="background-image: url('<?php echo $video_slide->thumbnail; ?>');"></div>
				</div>
				<div class="container">
					<div class="top-video pl_feat_vid_slide_nav">
						<div class="row">
							<div class="pt_featured_video">
								<h4 title="{{LANG featured_video}}">
									<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-award"><circle cx="12" cy="8" r="7"></circle><polyline points="8.21 13.89 7 23 12 20 17 23 15.79 13.88"></polyline></svg>
								</h4>
								<div class="video-player">
									<a href="<?php echo($video_slide->url) ?>" data-load="?link1=watch&id=<?php echo(PT_Slug($video_slide->title, $video_slide->video_id)) ?>">
										<div class="thumbnail_holder"><img src="<?php echo $video_slide->thumbnail; ?>"></div>
									</a>
									<div class="video-title">
										<input type="hidden" value="<?php echo($video_slide->id) ?>" id="video-id">
										<div class="video_title_combo">
											<div class="video-big-title">
												<a href="<?php echo($video_slide->url) ?>" data-load="?link1=watch&id=<?php echo(PT_Slug($video_slide->title, $video_slide->video_id)) ?>"><?php echo $video_slide->title; ?></a>
											</div>
											<div class="video_info">
												<span class="video-views"><?php echo $video_slide->views; ?> {{LANG views}}</span>
												<span class="video-likes">
													<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="currentColor" d="M23,10C23,8.89 22.1,8 21,8H14.68L15.64,3.43C15.66,3.33 15.67,3.22 15.67,3.11C15.67,2.7 15.5,2.32 15.23,2.05L14.17,1L7.59,7.58C7.22,7.95 7,8.45 7,9V19A2,2 0 0,0 9,21H18C18.83,21 19.54,20.5 19.84,19.78L22.86,12.73C22.95,12.5 23,12.26 23,12V10M1,21H5V9H1V21Z" /></svg>&nbsp;<span class="likes" id="likes"><?php echo number_format($video_slide->likes); ?></span>&nbsp;&nbsp;
													<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="currentColor" d="M19,15H23V3H19M15,3H6C5.17,3 4.46,3.5 4.16,4.22L1.14,11.27C1.05,11.5 1,11.74 1,12V14A2,2 0 0,0 3,16H9.31L8.36,20.57C8.34,20.67 8.33,20.77 8.33,20.88C8.33,21.3 8.5,21.67 8.77,21.94L9.83,23L16.41,16.41C16.78,16.05 17,15.55 17,15V5C17,3.89 16.1,3 15,3Z" /></svg>&nbsp;<span class="likes" id="dislikes"><?php echo number_format($video_slide->dislikes); ?></span>
												</span>
											</div>
											<div class="publisher-element">
												<!--<div class="publisher-avatar pull-left hide-in-mobile-720">
												<a href="{{USER url}}" data-load="?link1=timeline&id={{USER username}}"><img src="{{USER avatar}}" alt="{{USER name}}"></a>
												</div>-->
												<div class="publisher-name">
													<a href="<?php echo $video_slide->owner->url; ?>" data-load="?link1=timeline&id=<?php echo $video_slide->owner->username; ?>"><?php echo $video_slide->owner->name_v; ?></a>
												</div>
												<div class="clear"></div>
											</div>
											<p class="feat_desc"><?php echo $video_slide->markup_description; ?></p>
										</div>
										<div class="clear"></div>
									</div>
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
		<?php }} ?>
	</div>
	
	<div class="pt_hmpg_contanr">
		<div class="pt_home_vid_content pt_sec_nav_cats">
			<div class="title">
				<h4><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="#2196F3" d="M11,13.5V21.5H3V13.5H11M12,2L17.5,11H6.5L12,2M17.5,13C20,13 22,15 22,17.5C22,20 20,22 17.5,22C15,22 13,20 13,17.5C13,15 15,13 17.5,13Z"></path></svg> {{LANG categories}}</h4>
			</div>
				
			<div class="pt_sec_nav_slide_prnt">
				<div <?php if ($pt->language_type == 'rtl') { ?>dir="rtl"<?php } ?> class="swiper-wrapper pt_sec_nav_slide">
					<div class="swiper-slide"><a class="active" href="{{LINK }}" data-load="?link1=home">{{LANG all}}</a></div>
					<?php foreach($pt->categories as $key => $category) {
							if (1) { ?>
						<div class="swiper-slide"><a class="" href="{{LINK videos/category/<?php echo $key?>}}" data-load="?link1=videos&page=category&id=<?php echo $key?>"><?php echo $category?></a></div>
					<?php } }?>
				</div>
				<button class="swiper-button-next"></button>
				<button class="swiper-button-prev"></button>
			</div>
		</div>
		
		<?php if ($pt->config->shorts_system == 'on') { ?>
        <div class="pt_home_vid_content">
			<div class="home-page-categories pt_hmpg_vidlst">
				<div class="title">
					<h4><svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 168.071 168.071" xml:space="preserve" style="color: blueviolet;"> <g> <g> <path opacity="0.5" style="fill: currentColor;" d="M154.932,91.819L42.473,27.483c-2.219-1.26-4.93-1.26-7.121-0.027 c-2.219,1.233-3.588,3.533-3.615,6.026L31.08,161.059c0,0,0,0,0,0.027c0,2.465,1.369,4.766,3.533,6.026 c1.123,0.63,2.355,0.959,3.615,0.959c1.205,0,2.438-0.301,3.533-0.931l113.116-63.214c2.219-1.26,3.588-3.533,3.588-6.053 c0,0,0,0,0-0.027C158.465,95.38,157.123,93.079,154.932,91.819z"></path> <g id="XMLID_15_"> <g> <path style="fill:currentColor;" d="M79.952,44.888L79.952,44.888c3.273-3.273,2.539-8.762-1.479-11.06l-7.288-4.171 c-2.75-1.572-6.212-1.109-8.452,1.128l0,0c-3.273,3.273-2.539,8.762,1.479,11.06l7.291,4.169 C74.25,47.589,77.712,47.126,79.952,44.888z"></path> <path style="fill:currentColor;" d="M133.459,65.285L99.103,45.631c-2.75-1.572-6.209-1.109-8.449,1.128l0,0 c-3.273,3.273-2.539,8.759,1.479,11.057l23.497,13.44L23.931,122.5l0.52-103.393l19.172,10.964 c2.722,1.558,6.152,1.098,8.367-1.12l0.104-0.104c3.24-3.24,2.514-8.674-1.463-10.95L21,0.948 c-2.219-1.26-4.93-1.26-7.121-0.027c-2.219,1.233-3.588,3.533-3.615,6.026L9.607,134.524c0,0,0,0,0,0.027 c0,2.465,1.369,4.766,3.533,6.026c1.123,0.63,2.355,0.959,3.615,0.959c1.205,0,2.438-0.301,3.533-0.931l113.116-63.214 c2.219-1.26,3.588-3.533,3.588-6.053c0,0,0,0,0-0.027C136.992,68.845,135.65,66.545,133.459,65.285z"></path> </g> </g> </g> </g></svg> {{LANG shorts}}
						<span class="view_more_link"><a href="{{LINK shorts}}" data-load="?link1=shorts&id=">{{LANG explore_more}}</a></span>
					</h4>
				</div>
				<div class="videos">
					<div class="row cus_story_slider">
						{{SHORTS_HTML}}
					</div>
				</div>
			</div>
			<div class="clear"></div>
        </div>
      <?php } ?>
        <div class="pt_home_vid_content">
			<div class="home-page-categories pt_hmpg_vidlst">
				<div class="title">
					<h4><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="#2196F3" d="M16.85 6.85l1.44 1.44-4.88 4.88-3.29-3.29c-.39-.39-1.02-.39-1.41 0l-6 6.01c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0L9.41 12l3.29 3.29c.39.39 1.02.39 1.41 0l5.59-5.58 1.44 1.44c.31.31.85.09.85-.35V6.5c.01-.28-.21-.5-.49-.5h-4.29c-.45 0-.67.54-.36.85z"></path></svg> {{LANG trending}}
						<span class="view_more_link"><a href="{{LINK videos/trending}}" data-load="?link1=videos&page=trending">{{LANG explore_more}}</a></span>
					</h4>
				</div>
				<div class="videos">
					<div class="row pt_no_vid_found_trend">
						{{TRENDING_LIST}}
					</div>
				</div>
			</div>
			<div class="clear"></div>
        </div>
		<hr class="pt_hmpg_hr">
        <div class="pt_home_vid_content">
			<div class="home-page-categories pt_hmpg_vidlst">
				<div class="title">
					<h4><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="#359b39" d="M6.4 9.2h.2c.77 0 1.4.63 1.4 1.4v7c0 .77-.63 1.4-1.4 1.4h-.2c-.77 0-1.4-.63-1.4-1.4v-7c0-.77.63-1.4 1.4-1.4zM12 5c.77 0 1.4.63 1.4 1.4v11.2c0 .77-.63 1.4-1.4 1.4-.77 0-1.4-.63-1.4-1.4V6.4c0-.77.63-1.4 1.4-1.4zm5.6 8c.77 0 1.4.63 1.4 1.4v3.2c0 .77-.63 1.4-1.4 1.4-.77 0-1.4-.63-1.4-1.4v-3.2c0-.77.63-1.4 1.4-1.4z"></path></svg> {{LANG top_videos}}
						<span class="view_more_link"><a href="{{LINK videos/top}}" data-load="?link1=videos&page=top">{{LANG explore_more}}</a></span>
					</h4>
				</div>
				<div class="videos">
					<div class="row pt_no_vid_found_top">
						{{TOP_LIST}}
						<div class="clear"></div>
					</div>
				</div>
			</div>
			<div class="clear"></div>
        </div>
        <?php if ($pt->config->live_video == 1 && $pt->have_live) { ?>
        <div class="pt_home_vid_content">
			<div class="home-page-categories pt_hmpg_vidlst">
				<div class="title">
					<h4><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="#f44336" d="M17,10.5L21,6.5V17.5L17,13.5V17A1,1 0 0,1 16,18H4A1,1 0 0,1 3,17V7A1,1 0 0,1 4,6H16A1,1 0 0,1 17,7V10.5M14,16V15C14,13.67 11.33,13 10,13C8.67,13 6,13.67 6,15V16H14M10,8A2,2 0 0,0 8,10A2,2 0 0,0 10,12A2,2 0 0,0 12,10A2,2 0 0,0 10,8Z"></path></svg> {{LANG live_videos}}
						<span class="view_more_link"><a href="{{LINK videos/live}}" data-load="?link1=videos&page=live">{{LANG explore_more}}</a></span>
					</h4>
				</div>
				<div class="videos">
					<div class="row pt_no_vid_found_top">
						{{LIVE_LIST}}
						<div class="clear"></div>
					</div>
				</div>
			</div>
			<div class="clear"></div>
        </div>
        <?php } ?>
        <?php if ($pt->config->show_articles == 'on') { ?>
        	<div class="pt_home_vid_content">
				<div class="home-page-categories pt_hmpg_vidlst">
					<div class="title">
						<h4><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="#3f51b5" d="M20,11H4V8H20M20,15H13V13H20M20,19H13V17H20M11,19H4V13H11M20.33,4.67L18.67,3L17,4.67L15.33,3L13.67,4.67L12,3L10.33,4.67L8.67,3L7,4.67L5.33,3L3.67,4.67L2,3V19A2,2 0 0,0 4,21H20A2,2 0 0,0 22,19V3L20.33,4.67Z"></path></svg> {{LANG articles}}
							<span class="view_more_link"><a href="{{LINK articles}}" data-load="?link1=articles">{{LANG explore_more}}</a></span>
						</h4>
					</div>
					<div class="articles-content pt_homep_articls">
						<div class="row">
							{{HTML_POSTS}}
							<div class="clear"></div>
						</div>
					</div>
				</div>
				<div class="clear"></div>
	        </div>
        <?php } ?>
		<hr class="pt_hmpg_hr">
 
		{{SUBSC_HTML}}

		<div class="pt_home_vid_content">
			<div class="home-page-categories pt_hmpg_vidlst">
				<div class="title">
					<h4><svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="#e91e63" d="M3 6c-.55 0-1 .45-1 1v13c0 1.1.9 2 2 2h13c.55 0 1-.45 1-1s-.45-1-1-1H5c-.55 0-1-.45-1-1V7c0-.55-.45-1-1-1zm17-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-8 12.5v-9l5.47 4.1c.27.2.27.6 0 .8L12 14.5z"></path></svg> {{LANG latest_videos}}
						<span class="view_more_link"><a href="{{LINK videos/latest}}" data-load="?link1=videos&page=latest">{{LANG explore_more}}</a></span>
					</h4>
				</div>
				<div class="videos pt_latest_vds">
					<div class="row">
						{{LATEST_LIST}}
						<div class="clear"></div>
					</div>
				</div>
			</div>
			<div class="clear"></div>
		</div>
		<hr class="pt_hmpg_hr">
		
		{{HOME_PAGE_VIDEOS}}
	</div>
</div>

<script>
var swiper = new Swiper('.pt_sec_nav_slide_prnt', {
	loop: false,
	slidesPerView: "auto",

	// Navigation arrows
	navigation: {
	    nextEl: '.swiper-button-next',
	    prevEl: '.swiper-button-prev',
	},
});

$(document).ready(function(){
	$(".pl_feat_vid_slider").owlCarousel({
		items:1,
		nav: true,
		dots: false,
		navContainer: '.pl_feat_vid_slide_nav',
		// dotsContainer: '.pl_feat_vid_slide_dots',
		navText: ['<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="currentColor" d="M20,11V13H8L13.5,18.5L12.08,19.92L4.16,12L12.08,4.08L13.5,5.5L8,11H20Z" /></svg>','<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"><path fill="currentColor" d="M4,11V13H16L10.5,18.5L11.92,19.92L19.84,12L11.92,4.08L10.5,5.5L16,11H4Z" /></svg>'],
		<?php if ($pt->language_type == 'rtl') { ?>
		rtl: true,
		<?php } ?>
	});
});

$(document).ready(function() {
if( !$.trim( $('.pt_no_vid_found_trend').html() ).length ) {
	$('.pt_no_vid_found_trend').html('<h5 class="empty_state"><svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" class="feather"><path fill="currentColor" d="M21 14.2V8.91c0-.89-1.08-1.34-1.71-.71L17 10.5V7c0-.55-.45-1-1-1h-5.61l8.91 8.91c.62.63 1.7.18 1.7-.71zM2.71 2.56c-.39.39-.39 1.02 0 1.41L4.73 6H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.21 0 .39-.08.55-.18l2.48 2.48c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L4.12 2.56c-.39-.39-1.02-.39-1.41 0z"/></svg> {{LANG no_videos_found_for_now}}</h5>');
};
});

$(document).ready(function() {
if( !$.trim( $('.pt_no_vid_found_top').html() ).length ) {
	$('.pt_no_vid_found_top').html('<h5 class="empty_state"><svg xmlns="http://www.w3.org/2000/svg" height="24" viewBox="0 0 24 24" width="24" class="feather"><path fill="currentColor" d="M21 14.2V8.91c0-.89-1.08-1.34-1.71-.71L17 10.5V7c0-.55-.45-1-1-1h-5.61l8.91 8.91c.62.63 1.7.18 1.7-.71zM2.71 2.56c-.39.39-.39 1.02 0 1.41L4.73 6H4c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h12c.21 0 .39-.08.55-.18l2.48 2.48c.39.39 1.02.39 1.41 0 .39-.39.39-1.02 0-1.41L4.12 2.56c-.39-.39-1.02-.39-1.41 0z"/></svg> {{LANG no_videos_found_for_now}}</h5>');
};
});

$(function () {
   $('#save-button').on('click', function(event) {
      event.preventDefault();
      var logged = $('#main-container').attr('data-logged');
      if (!logged) {
         window.location.href = "{{LINK login?to=<?php echo $pt->actual_link;?>}}";
         return false;
      }
      var video_id = $('#video-id').val();
      if ($(this).attr('saved')) {
         $(this).html('<i class="fa fa-floppy-o fa-fw"></i> {{LANG save}}');
         $(this).removeAttr('saved');
      } else {
         $(this).html('<i class="fa fa-check fa-fw"></i> {{LANG saved}}');
         $(this).attr('saved', 'true');
      }
      $.post('{{LINK aj/save-video}}', {video_id: video_id});
   });
});

<?php if ($pt->config->shorts_system == 'on') { ?>
$(document).ready(function(){
  $('.cus_story_slider').slick({
  infinite: false,
  slidesToShow: 6,
  <?php if ($pt->language_type == 'rtl') { ?>rtl: true,<?php } ?>
  slidesToScroll: 2,
  responsive: [
	{
      breakpoint: 1360,
      settings: {
        slidesToShow: 4
      }
    },
	{
      breakpoint: 1251,
      settings: {
        slidesToShow: 5
      }
    },
	{
      breakpoint: 1127,
      settings: {
        slidesToShow: 4
      }
    },
    {
      breakpoint: 992,
      settings: {
        slidesToShow: 4
      }
    },
	{
      breakpoint: 910,
      settings: {
        slidesToShow: 3
      }
    },
    {
      breakpoint: 705,
      settings: {
        slidesToShow: 2
      }
    },
	{
      breakpoint: 530,
      settings: {
        arrows: false,
		slidesToShow: 2,
		waitForAnimate: false,
      }
    },
    {
      breakpoint: 485,
      settings: {
        arrows: false,
		slidesToShow: 2,
		slidesToScroll: 1,
		waitForAnimate: false,
      }
    }
  ]
  });
});
<?php } ?>
</script>