﻿$(document).ready(function(){
    var grid = $(".product-grid");
    if(grid.width() != null)
    {
        var temp = Math.round(grid.width()/214)
        $(".product-grid > .product-item").width(Math.floor((grid.width()-4 - temp)/temp))
    }
     $(window).resize(function() {
        var grid = $(".product-grid");
        if(grid.width() != null)
        {
            var temp = Math.round(grid.width()/214)
            $(".product-grid > .product-item").width(Math.floor((grid.width() - temp)/temp)-6)
        }
    });
   
});



