Schema for stores and groups of stores and companies
I would create a table store_group that represents the hierarchy of the groups using and adjacency model:

store_group (
   id integer primary key
   name text not null, -- maybe even unique?
   ... other attributes
   parent_group_id integer references store_group --- null for the "root"
)


If a group can be associated with only a single store group, make that an attribute of the store table:

store (
  id integer primary key, 
  group_id integer references store_group, 
  ... other attributes ...
) 


If group_id is null, the store does not belong to a group. 

If a store can belong to multiple groups, use a m:n relation:

store (
  id integer primary key, 
  ... other attributes ...
);

store_assignment (
  store_id integer not null references store,
  group_id integer not null references store_group,
  primary key (store_id, group_id)
);


And you obviously need a m:n relation between product and store:

store_product (
  product_id integer not null references product,
  store_id integer not null references store,
  primary key (product_id, store_id)
);