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 (
    50698, 50699, 50695, 50671, 50684, 50676, 
    50673, 50348, 50264, 50524, 50527, 
    50305, 50345, 50517, 50612, 50214, 
    50302, 50341, 50417, 50605, 50650, 
    50630, 50244, 50347, 50349, 50621, 
    50626, 50326, 50276, 50278
  ) 
  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.10344

JSON explain

{
  "query_block": {
    "select_id": 1,
    "filesort": {
      "sort_key": "cscart_product_prices.product_id",
      "temporary_table": {
        "nested_loop": [
          {
            "table": {
              "table_name": "cscart_product_prices",
              "access_type": "ref",
              "possible_keys": [
                "usergroup",
                "product_id",
                "lower_limit",
                "usergroup_id"
              ],
              "key": "lower_limit",
              "key_length": "3",
              "used_key_parts": ["lower_limit"],
              "ref": ["const"],
              "rows": 25327,
              "filtered": 19.72063637,
              "attached_condition": "cscart_product_prices.lower_limit <=> 1 and cscart_product_prices.product_id in (50698,50699,50695,50671,50684,50676,50673,50348,50264,50524,50527,50305,50345,50517,50612,50214,50302,50341,50417,50605,50650,50630,50244,50347,50349,50621,50626,50326,50276,50278) and cscart_product_prices.usergroup_id in (0,1)"
            }
          }
        ]
      }
    }
  }
}

Result

product_id price
50214 650000.0000
50244 166000.0000
50264 175000.0000
50276 480000.0000
50278 360000.0000
50302 480000.0000
50305 950000.0000
50326 690000.0000
50341 390000.0000
50345 590000.0000
50347 1150000.0000
50348 2100000.0000
50349 3200000.0000
50417 45000.0000
50517 290000.0000
50524 430000.0000
50527 275000.0000
50605 305000.0000
50612 160000.0000
50621 50000.0000
50626 95000.0000
50630 170000.0000
50650 305000.0000
50671 180000.0000
50673 50000.0000
50676 55000.0000
50684 100000.0000
50695 0.0000
50698 656000.0000
50699 656000.0000