SELECT 
  category_id, 
  parent_id 
FROM 
  cscart_categories 
WHERE 
  parent_id IN(
    23021, 22968, 22988, 22950, 22993, 23015, 
    23016, 23010, 22958, 22980, 22940, 
    22984
  ) 
  AND category_id != 1

Query time 0.00008

JSON explain

{
  "query_block": {
    "select_id": 1,
    "nested_loop": [
      {
        "table": {
          "table_name": "cscart_categories",
          "access_type": "range",
          "possible_keys": ["PRIMARY", "parent", "p_category_id"],
          "key": "parent",
          "key_length": "3",
          "used_key_parts": ["parent_id"],
          "rows": 72,
          "filtered": 100,
          "index_condition": "cscart_categories.parent_id in (23021,22968,22988,22950,22993,23015,23016,23010,22958,22980,22940,22984)",
          "attached_condition": "cscart_categories.category_id <> 1"
        }
      }
    ]
  }
}

Result

category_id parent_id
22941 22940
22942 22940
22943 22940
22944 22940
22945 22940
22946 22940
22947 22940
22948 22940
22949 22940
22951 22950
22952 22950
22953 22950
22954 22950
22955 22950
22956 22950
22957 22950
22959 22958
22960 22958
22961 22958
22962 22958
22963 22958
22964 22958
22965 22958
22966 22958
22967 22958
22969 22968
22970 22968
22971 22968
22972 22968
22973 22968
22974 22968
22975 22968
22976 22968
22977 22968
22978 22968
22979 22968
22981 22980
22982 22980
22983 22980
22985 22984
22986 22984
22987 22984
22989 22988
22990 22988
22991 22988
22992 22988
22994 22993
22995 22993
22996 22993
22997 22993
22998 22993
22999 22993
23000 22993
23001 22993
23002 22993
23003 22993
23004 22993
23005 22993
23006 22993
23007 22993
23008 22993
23009 22993
23011 23010
23012 23010
23013 23010
23014 23010
23017 23016
23018 23016
23019 23016
23020 23016