SELECT 
  cscart_products_categories.product_id, 
  GROUP_CONCAT(
    IF(
      cscart_products_categories.link_type = "M", 
      CONCAT(
        cscart_products_categories.category_id, 
        "M"
      ), 
      cscart_products_categories.category_id
    )
  ) AS category_ids, 
  product_position_source.position AS position 
FROM 
  cscart_products_categories 
  INNER JOIN cscart_categories ON cscart_categories.category_id = cscart_products_categories.category_id 
  AND cscart_categories.company_id = 3 
  AND (
    cscart_categories.usergroup_ids = '' 
    OR FIND_IN_SET(
      0, cscart_categories.usergroup_ids
    ) 
    OR FIND_IN_SET(
      1, cscart_categories.usergroup_ids
    )
  ) 
  AND cscart_categories.status IN ('A', 'H') 
  LEFT JOIN cscart_products_categories AS product_position_source ON cscart_products_categories.product_id = product_position_source.product_id 
  AND product_position_source.category_id = 961 
WHERE 
  cscart_products_categories.product_id IN (
    430, 9470, 10705, 9457, 8862, 8860, 11485, 
    8861, 10945, 8864, 10188, 10353, 8875, 
    8869, 10355, 10222, 8870, 8868, 1655, 
    516, 10078, 8863, 388, 395, 8873, 10163, 
    10212, 523, 517, 8871, 10210, 9821, 
    8877, 9823, 10206, 9871, 396, 9825, 
    10164, 10165, 10183, 10181, 10961, 
    1646
  ) 
GROUP BY 
  cscart_products_categories.product_id

Query time 0.00443

Explain
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE cscart_products_categories range PRIMARY,pt,product_id_idx,category_id_idx,product_category_idx,category_product_idx pt 3 550 Using index condition
1 SIMPLE cscart_categories eq_ref PRIMARY,c_status,p_category_id,idx_category_id PRIMARY 3 mahm3t_cs443.cscart_products_categories.category_id 1 Using where
1 SIMPLE product_position_source eq_ref PRIMARY,pt,product_id_idx,category_id_idx,product_category_idx,category_product_idx PRIMARY 6 const,mahm3t_cs443.cscart_products_categories.product_id 1

Result

product_id category_ids position
388 746,961,963,967 0
395 965,746,961,964,968 0
396 965,746,961,967 0
430 927,961,963,967 0
516 924,961,963,967 0
517 924,961,963,967 0
523 924,961,963,967 0
1646 746,961,964,967 0
1655 746,961,963,970 0
8860 747,961,963,966 0
8861 747,961,963,967 0
8862 747,961,964,966 0
8863 747,961,964,967 0
8864 747,961,963,966 0
8868 747,961,964,966 0
8869 747,961,964,966 0
8870 747,961,964,966 0
8871 747,961,963,966 0
8873 747,961,964,966 0
8875 747,961,963,966,970 0
8877 747,961,964,966,970 0
9457 924,961,964,967 0
9470 927,961,963,969 0
9821 747,961,964,966 0
9823 747,961,964,967 0
9825 904,961,964,967 0
9871 746,961,963,967 0
10078 747,961,964,966 0
10163 746,961,964,968 0
10164 746,961,965,967 0
10165 746,961,964,967 0
10181 746,961,963,968 0
10183 746,961,963,968 0
10188 746,961,964,967 0
10206 747,961,964,966 0
10210 747,961,964,966,970 0
10212 747,961,964,966 0
10222 904,961,964,968 0
10353 746,961,964,967 0
10355 746,961,964,967 0
10705 927,961,964,967 0
10945 747,961,964,966 0
10961 904,961,963,967 0
11485 746,961,967,964 0