Get all products which have both product category

Set include_children to false in the tax_query.

$args = array(
'post_type' => array( 'product', 'product_variation' ),

'tax_query' => array(
    array(
        'taxonomy'         => 'product_cat',
        'field'            => 'slug',
        'terms'            => array( 'shop', 'cat1' ),
        'include_children' => false,
        'operator'         => 'AND',
    )
)

);

See https://codex.wordpress.org/Class_Reference/WP_Query#Taxonomy_Parameters