<div class="resp-slider-container">
	<div class="slider responsive">
	<?php 					
		while($list->have_posts()): $list->the_post();
		global $product, $post;
		$class = ( $product->get_price_html() ) ? '' : 'item-nonprice';
		$start_time = get_post_meta( $post->ID, '_sale_price_dates_from', true );
		$countdown_time = get_post_meta( $post->ID, '_sale_price_dates_to', true );	
		$forginal_price = get_post_meta( $post->ID, '_regular_price', true );	
		$fsale_price = get_post_meta( $post->ID, '_sale_price', true );	
		$symboy = get_woocommerce_currency_symbol( get_woocommerce_currency() );
		$date = sw_timezone_offset( $countdown_time );
	?>
		<div class="item <?php echo esc_attr( $class ) ?> product clearfix">
			<div class="item-wrap">
				<?php do_action( 'woocommerce_before_shop_loop_item_title' ); ?>									
				<div class="item-content">
					<?php woocommerce_template_loop_rating(); ?>
					<?php emarket_template_loop_product_title(); ?>
					<?php woocommerce_template_loop_price(); ?>
					<!-- add to cart, wishlist, compare -->
					<?php //do_action( 'woocommerce_after_shop_loop_item' ); ?>
				
					<?php 
						if( $product->get_stock_quantity() != 0 ){ 
						$available 	 = $product->get_stock_quantity();
						$total_sales = get_post_meta( $post->ID, 'total_sales', true );
						$bar_width 	 = intval( $available ) / intval( $available + $total_sales ) * 100;
					?>
					<div class="sales-bar clearfix">
						<div class="sales-bar-total">
							<span style="width: <?php echo esc_attr( $bar_width . '%' ); ?>"></span>
						</div>
					</div>
					<div class="stock-sold"><?php esc_html_e( 'Sold: ', 'emarket' ) ?><span><?php echo $total_sales; ?></span></div>
					<?php } ?>
					<div class="product-countdown" data-date="<?php echo esc_attr( $date ); ?>" data-price="<?php echo esc_attr( $symboy.$forginal_price ); ?>" data-starttime="<?php echo esc_attr( $start_time ); ?>" data-cdtime="<?php echo esc_attr( $countdown_time ); ?>" data-id="<?php echo 'product_'.$widget_id.$post->ID; ?>"></div>	
					<div class="item-bottom-content">
						<?php
							woocommerce_template_loop_add_to_cart();
							emarket_product_addcart_mid();
						?>
					</div>
				</div>
			</div>
		</div>
	<?php endwhile; wp_reset_postdata();?>
	</div>
</div>