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 (
    6303, 6304, 5801, 5802, 5800, 5799, 5803, 
    5804, 7197, 7195, 7196, 7190, 7189, 
    7194, 7191, 5032, 5033, 7674, 7675, 
    6967, 6966, 6645, 6644, 6647, 6648, 
    4352, 4354, 5391, 5392, 5388, 5390, 
    5389, 5396, 5395, 5394, 5034, 5035, 
    5030, 5031, 5168, 5169, 6982, 6132, 
    7150, 7149, 7148, 7151, 6768
  ) 
  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.00125

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "34.51"
    },
    "grouping_operation": {
      "using_filesort": false,
      "table": {
        "table_name": "cscart_product_prices",
        "access_type": "range",
        "possible_keys": [
          "usergroup",
          "product_id",
          "lower_limit",
          "usergroup_id"
        ],
        "key": "product_id",
        "used_key_parts": [
          "product_id"
        ],
        "key_length": "3",
        "rows_examined_per_scan": 50,
        "rows_produced_per_join": 9,
        "filtered": "19.12",
        "index_condition": "(`dbggbern`.`cscart_product_prices`.`product_id` in (6303,6304,5801,5802,5800,5799,5803,5804,7197,7195,7196,7190,7189,7194,7191,5032,5033,7674,7675,6967,6966,6645,6644,6647,6648,4352,4354,5391,5392,5388,5390,5389,5396,5395,5394,5034,5035,5030,5031,5168,5169,6982,6132,7150,7149,7148,7151,6768))",
        "cost_info": {
          "read_cost": "33.55",
          "eval_cost": "0.96",
          "prefix_cost": "34.51",
          "data_read_per_join": "229"
        },
        "used_columns": [
          "product_id",
          "price",
          "percentage_discount",
          "lower_limit",
          "usergroup_id"
        ],
        "attached_condition": "((`dbggbern`.`cscart_product_prices`.`lower_limit` = 1) and (`dbggbern`.`cscart_product_prices`.`usergroup_id` in (0,1)))"
      }
    }
  }
}

Result

product_id price
4352 8.90000000
4354 19.90000000
5030 9.90000000
5031 9.90000000
5032 8.90000000
5033 10.90000000
5034 19.90000000
5035 19.90000000
5168 39.90000000
5169 39.90000000
5388 9.90000000
5389 9.90000000
5390 9.90000000
5391 6.90000000
5392 6.90000000
5394 19.90000000
5395 19.90000000
5396 19.90000000
5799 9.90000000
5800 9.90000000
5801 9.90000000
5802 9.90000000
5803 19.90000000
5804 19.90000000
6132 99.90000000
6303 12.90000000
6304 12.90000000
6644 9.90000000
6645 9.90000000
6647 12.90000000
6648 12.90000000
6768 34.90000000
6966 19.90000000
6967 19.90000000
6982 84.90000000
7148 11.90000000
7149 11.90000000
7150 11.90000000
7151 11.90000000
7189 9.90000000
7190 9.90000000
7191 12.90000000
7194 12.90000000
7195 19.90000000
7196 19.90000000
7197 24.90000000
7674 19.90000000
7675 19.90000000