if you insert data into isolated table, then I expect you have locking on tables in SELECT statement, as I see you have 3 tables here.
You can read more about INSERT … SELECT locking here: https://dev.mysql.com/doc/refman/8.0/en/innodb-locks-set.html
or to quote:
If the transaction isolation level is READ COMMITTED, InnoDB does the search on S as a consistent read (no locks). Otherwise, InnoDB sets shared next-key locks on rows from S . InnoDB has to set locks in the latter case: During roll-forward recovery using a statement-based binary log, every SQL statement must be executed in exactly the same way it was done originally.