You may try with the below CSS or PnP PowerShell.
CSS
div[class^="logoCell-119"]
{
display: none !important;
}
OR
img[src*='siteIcon'] { display: block;}
Note:
- Customizing or script editor web part is not supported in modern SharePoint online, so as an alternate we can deploy and make use of modern script editor web part.
How to inject custom CSS or javascript code in modern SharePoint Online?
We can use the modern script editor web part for this. The good thing is that we don't o need to develop this web part from the beginning, we can just deploy the modern script editor web part which is built on SPFx (alternate of classic script editor web part), we can get the modern script editor web part from here.
For details refer to the below article:
SharePoint Online, how to hide the SharePoint logo on a list using css or jquery
SharePoint Online Logo Link