SELECT 
  cscart_product_prices.product_id, 
  MIN(
    IF(
      cscart_product_prices.percentage_discount = 0, 
      cscart_product_prices.price, 
      cscart_product_prices.price - (
        cscart_product_prices.price * cscart_product_prices.percentage_discount
      )/ 100
    )
  ) AS price 
FROM 
  cscart_product_prices 
WHERE 
  cscart_product_prices.product_id IN (
    4373, 36464, 5575, 976, 5636, 4379, 6476, 
    3995, 38561, 21746, 23481, 16847, 1051, 
    36474, 3224, 2653, 975, 5726, 41437, 
    16416, 28162, 5405, 1358, 3989, 6470, 
    38136, 32286, 4372, 285, 1166, 5414, 
    38551
  ) 
  AND cscart_product_prices.lower_limit = 1 
  AND cscart_product_prices.usergroup_id IN (0, 1) 
GROUP BY 
  cscart_product_prices.product_id

Query time 0.00442

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "table": {
          "table_name": "cscart_product_prices",
          "access_type": "range",
          "possible_keys": [
            "usergroup",
            "product_id",
            "lower_limit",
            "usergroup_id"
          ],
          "key": "product_id",
          "key_length": "3",
          "used_key_parts": ["product_id"],
          "rows": 32,
          "filtered": 99.9960556,
          "index_condition": "cscart_product_prices.product_id in (4373,36464,5575,976,5636,4379,6476,3995,38561,21746,23481,16847,1051,36474,3224,2653,975,5726,41437,16416,28162,5405,1358,3989,6470,38136,32286,4372,285,1166,5414,38551)",
          "attached_condition": "cscart_product_prices.lower_limit = 1 and cscart_product_prices.usergroup_id in (0,1)"
        }
      }
    ]
  }
}

Result

product_id price
285 260000.0000
975 175000.0000
976 175000.0000
1051 3300000.0000
1166 1100000.0000
1358 119000.0000
2653 155000.0000
3224 129000.0000
3989 605000.0000
3995 1045000.0000
4372 1500000.0000
4373 925000.0000
4379 1150000.0000
5405 850000.0000
5414 415000.0000
5575 570000.0000
5636 700000.0000
5726 160000.0000
6470 170000.0000
6476 360000.0000
16416 325000.0000
16847 615000.0000
21746 475000.0000
23481 800000.0000
28162 405000.0000
32286 149000.0000
36464 2250000.0000
36474 1600000.0000
38136 270000.0000
38551 580000.0000
38561 352000.0000
41437 3749000.0000