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 (
    255961, 255970, 260992, 261904, 285179, 
    285196, 295915, 315813, 141322, 163581, 
    183619, 210845, 223011, 225199, 236271, 
    238472, 253367, 285186, 285188, 295887, 
    308293, 308343, 308345, 317513
  ) 
  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.00155

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "21.63"
    },
    "grouping_operation": {
      "using_filesort": false,
      "table": {
        "table_name": "cscart_product_prices",
        "access_type": "range",
        "possible_keys": [
          "usergroup",
          "product_id",
          "lower_limit",
          "usergroup_id"
        ],
        "key": "usergroup",
        "used_key_parts": [
          "product_id",
          "usergroup_id",
          "lower_limit"
        ],
        "key_length": "9",
        "rows_examined_per_scan": 48,
        "rows_produced_per_join": 48,
        "filtered": "100.00",
        "cost_info": {
          "read_cost": "16.83",
          "eval_cost": "4.80",
          "prefix_cost": "21.63",
          "data_read_per_join": "1K"
        },
        "used_columns": [
          "product_id",
          "price",
          "percentage_discount",
          "lower_limit",
          "usergroup_id"
        ],
        "attached_condition": "((`unicomps`.`cscart_product_prices`.`lower_limit` = 1) and (`unicomps`.`cscart_product_prices`.`product_id` in (255961,255970,260992,261904,285179,285196,295915,315813,141322,163581,183619,210845,223011,225199,236271,238472,253367,285186,285188,295887,308293,308343,308345,317513)) and (`unicomps`.`cscart_product_prices`.`usergroup_id` in (0,1)))"
      }
    }
  }
}

Result

product_id price
141322 800.59000000
163581 620.34000000
183619 1227.10000000
210845 1233.19000000
223011 1429.61000000
225199 351.66000000
236271 265.20000000
238472 702.72000000
253367 10750.00000000
255961 480.00000000
255970 1545.79000000
260992 544.16000000
261904 1057.70000000
285179 6698.33000000
285186 424.51000000
285188 443.81000000
285196 6676.99000000
295887 2895.76000000
295915 482.40000000
308293 1041.91000000
308343 14313.60000000
308345 5431.98000000
315813 1435.57000000
317513 2311.44000000