SELECT 
  category_id, 
  parent_id 
FROM 
  cscart_categories 
WHERE 
  parent_id IN(
    1165, 1166, 1156, 1167, 1157, 1168, 1169, 
    1170, 1158, 1171, 1172, 1173, 1153, 
    1174, 1159, 1160, 1161, 1175, 1176, 
    1154, 1155, 1163, 1164, 1162
  ) 
  AND category_id != 265

Query time 0.00056

JSON explain

{
  "query_block": {
    "select_id": 1,
    "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": 40,
      "filtered": 100,
      "index_condition": "cscart_categories.parent_id in (1165,1166,1156,1167,1157,1168,1169,1170,1158,1171,1172,1173,1153,1174,1159,1160,1161,1175,1176,1154,1155,1163,1164,1162)",
      "attached_condition": "cscart_categories.category_id <> 265"
    }
  }
}

Result

category_id parent_id
1156 1155
1157 1155
1158 1155
1159 1155
1160 1155
1161 1155
1162 1155
1165 1164
1166 1164
1167 1164
1168 1164
1169 1164
1170 1164
1171 1164
1172 1164
1173 1164
1174 1164
1175 1164
1176 1164