The Event Viewer entry is indeed more significant than Defender complaining about a random DLL. The screenshot shows a Defender Event ID 1116, which means Defender states the detection originated from Real-Time Protection while C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe was the process involved in the detection. That suggests that a PowerShell process was responsible for loading, creating, or accessing the DLL when Defender caught it.
The changing DLL name and changing temporary directory are also worth taking seriously. A legitimate application can certainly create random files under %TEMP%, so the random name alone is not proof of malware. However, if Defender removes the DLL, the same behavior occurs again after every reboot, and a PowerShell process is involved each time, something on the system may be repeatedly recreating the file. That could be a scheduled task, startup entry, service, WMI persistence mechanism, application updater, browser component, or an actual malware persistence mechanism.
I would not add an exclusion for the Temp directory, the DLL, or Heracles.A!MTB. That would potentially hide the behavior rather than solve it. Since you have already performed both a Full Scan and an Offline Scan, the next objective is to determine what is recreating the DLL. First, open Windows Security, go to Virus & threat protection, then Protection history, and open the detection. Look specifically for the Action taken, the affected item, and whether Defender says it was Quarantined, Removed, or Allowed. If it says Allowed or Remediation failed, that changes the urgency.
You can also run PowerShell as Administrator and execute Get-MpThreatDetection | Format-List *. This should give you more information about Defender's recorded detections, including the detection time, resources involved, and remediation status. You can also run Get-MpThreat | Format-List * to see the associated threat information.
The next step would be to identify the process that launches PowerShell at startup. Microsoft Sysinternals Autoruns is particularly useful for this. Run Autoruns as Administrator and examine the Logon, Scheduled Tasks, Services, WMI, and PowerShell-related entries. Look for anything that launches powershell.exe, especially commands containing -EncodedCommand, -WindowStyle Hidden, -ExecutionPolicy Bypass, IEX, DownloadString, Invoke-WebRequest, Start-BitsTransfer, or references to %TEMP%, AppData, or that particular random directory. Do not delete an entry simply because it uses PowerShell, because Windows and legitimate software use PowerShell extensively.
You can also check Scheduled Tasks directly with schtasks /query /fo LIST /v > "%USERPROFILE%\Desktop\tasks.txt" and then search the resulting file for powershell.exe, AppData, Temp, EncodedCommand, or other suspicious commands. If the malware is recreated immediately after reboot, a scheduled task or startup mechanism is one of the first things I would investigate.
Note that Event ID 1116 is the detection event, not necessarily the persistence mechanism. The powershell.exe tells us what process was involved when Defender detected the DLL, but Event Viewer generally does not tell us why that PowerShell process was started. The answer to that question is what you need to find.
If you can reproduce the problem once more, I would also capture the exact Defender detection from Protection History and the corresponding Event ID 1116 and 1117 entries. In particular, the Details tab of Event 1116, rather than only the General tab, may provide additional information.
If the above response helps answer your question, remember to "Accept Answer" so that others in the community facing similar issues can easily find the solution. Your contribution is highly appreciated.
hth
Marcin