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 (
    8663, 8779, 8562, 8627, 8657, 8689, 8619, 
    8766, 8838, 8936, 10020, 8910, 8731, 
    10167, 8916, 8573, 8655, 8568, 8601, 
    8667, 8618, 8536, 8566, 8776
  ) 
  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.00085

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "16.81"
    },
    "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": 24,
        "rows_produced_per_join": 4,
        "filtered": "19.99",
        "index_condition": "(`softwarepirmam_hewadelivard_cscart_4`.`cscart_product_prices`.`product_id` in (8663,8779,8562,8627,8657,8689,8619,8766,8838,8936,10020,8910,8731,10167,8916,8573,8655,8568,8601,8667,8618,8536,8566,8776))",
        "cost_info": {
          "read_cost": "16.33",
          "eval_cost": "0.48",
          "prefix_cost": "16.81",
          "data_read_per_join": "115"
        },
        "used_columns": [
          "product_id",
          "price",
          "percentage_discount",
          "lower_limit",
          "usergroup_id"
        ],
        "attached_condition": "((`softwarepirmam_hewadelivard_cscart_4`.`cscart_product_prices`.`lower_limit` = 1) and (`softwarepirmam_hewadelivard_cscart_4`.`cscart_product_prices`.`usergroup_id` in (0,1)))"
      }
    }
  }
}

Result

product_id price
8536 83000.00000000
8562 75000.00000000
8566 181000.00000000
8568 45000.00000000
8573 59000.00000000
8601 98000.00000000
8618 32000.00000000
8619 39000.00000000
8627 38000.00000000
8655 23000.00000000
8657 26000.00000000
8663 21000.00000000
8667 46000.00000000
8689 49000.00000000
8731 28000.00000000
8766 59000.00000000
8776 62000.00000000
8779 46000.00000000
8838 36000.00000000
8910 36000.00000000
8916 48000.00000000
8936 29000.00000000
10020 150000.00000000
10167 10000.00000000