SELECT 
  COUNT(
    DISTINCT(cscart_pages.page_id)
  ) 
FROM 
  cscart_pages 
  LEFT JOIN cscart_page_descriptions ON cscart_pages.page_id = cscart_page_descriptions.page_id 
  AND cscart_page_descriptions.lang_code = 'en' 
  LEFT JOIN cscart_seo_names ON cscart_seo_names.object_id = cscart_pages.page_id 
  AND cscart_seo_names.type = 'a' 
  AND cscart_seo_names.dispatch = '' 
  AND cscart_seo_names.lang_code = 'en' 
WHERE 
  1 
  AND cscart_pages.parent_id IN (7) 
  AND cscart_pages.status IN ('A') 
  AND cscart_pages.page_type IN ('B') 
  AND (
    cscart_pages.usergroup_ids = '' 
    OR FIND_IN_SET(0, cscart_pages.usergroup_ids) 
    OR FIND_IN_SET(1, cscart_pages.usergroup_ids)
  ) 
  AND (
    cscart_pages.use_avail_period = 'N' 
    OR (
      cscart_pages.use_avail_period = 'Y' 
      AND cscart_pages.avail_from_timestamp <= 1737176700 
      AND (
        cscart_pages.avail_till_timestamp >= 1737176700 
        OR cscart_pages.avail_till_timestamp = 0
      )
    )
  ) 
ORDER BY 
  cscart_pages.timestamp desc

Query time 0.00052

JSON explain

{
  "query_block": {
    "select_id": 1,
    "cost_info": {
      "query_cost": "3.08"
    },
    "nested_loop": [
      {
        "table": {
          "table_name": "cscart_pages",
          "access_type": "ref",
          "possible_keys": [
            "parent_id"
          ],
          "key": "parent_id",
          "used_key_parts": [
            "parent_id"
          ],
          "key_length": "3",
          "ref": [
            "const"
          ],
          "rows_examined_per_scan": 3,
          "rows_produced_per_join": 0,
          "filtered": "4.76",
          "cost_info": {
            "read_cost": "2.10",
            "eval_cost": "0.03",
            "prefix_cost": "2.70",
            "data_read_per_join": "362"
          },
          "used_columns": [
            "page_id",
            "parent_id",
            "status",
            "page_type",
            "timestamp",
            "usergroup_ids",
            "use_avail_period",
            "avail_from_timestamp",
            "avail_till_timestamp"
          ],
          "attached_condition": "((`satishecarter_dec_setup_001`.`cscart_pages`.`status` = 'A') and (`satishecarter_dec_setup_001`.`cscart_pages`.`page_type` = 'B') and ((`satishecarter_dec_setup_001`.`cscart_pages`.`usergroup_ids` = '') or find_in_set(0,`satishecarter_dec_setup_001`.`cscart_pages`.`usergroup_ids`) or find_in_set(1,`satishecarter_dec_setup_001`.`cscart_pages`.`usergroup_ids`)) and ((`satishecarter_dec_setup_001`.`cscart_pages`.`use_avail_period` = 'N') or ((`satishecarter_dec_setup_001`.`cscart_pages`.`use_avail_period` = 'Y') and (`satishecarter_dec_setup_001`.`cscart_pages`.`avail_from_timestamp` <= 1737176700) and ((`satishecarter_dec_setup_001`.`cscart_pages`.`avail_till_timestamp` >= 1737176700) or (`satishecarter_dec_setup_001`.`cscart_pages`.`avail_till_timestamp` = 0)))))"
        }
      },
      {
        "table": {
          "table_name": "cscart_page_descriptions",
          "access_type": "eq_ref",
          "possible_keys": [
            "PRIMARY"
          ],
          "key": "PRIMARY",
          "used_key_parts": [
            "page_id",
            "lang_code"
          ],
          "key_length": "9",
          "ref": [
            "satishecarter_dec_setup_001.cscart_pages.page_id",
            "const"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 0,
          "filtered": "100.00",
          "using_index": true,
          "cost_info": {
            "read_cost": "0.14",
            "eval_cost": "0.03",
            "prefix_cost": "2.87",
            "data_read_per_join": "552"
          },
          "used_columns": [
            "page_id",
            "lang_code"
          ]
        }
      },
      {
        "table": {
          "table_name": "cscart_seo_names",
          "access_type": "ref",
          "possible_keys": [
            "PRIMARY",
            "dispatch"
          ],
          "key": "PRIMARY",
          "used_key_parts": [
            "object_id",
            "type",
            "dispatch",
            "lang_code"
          ],
          "key_length": "206",
          "ref": [
            "satishecarter_dec_setup_001.cscart_pages.page_id",
            "const",
            "const",
            "const"
          ],
          "rows_examined_per_scan": 1,
          "rows_produced_per_join": 0,
          "filtered": "100.00",
          "using_index": true,
          "cost_info": {
            "read_cost": "0.18",
            "eval_cost": "0.03",
            "prefix_cost": "3.08",
            "data_read_per_join": "248"
          },
          "used_columns": [
            "object_id",
            "type",
            "dispatch",
            "lang_code"
          ]
        }
      }
    ]
  }
}

Result

COUNT(DISTINCT(cscart_pages.page_id))
3