There is a difference.
Block 5 is inserted as a pure Ad Inserter widget and consequently when it is hidden the code tries to hide also the widget itself – and here it is hidden.
However, block 3 doesn’t seem to be inserted as a pure Ad Inserter widget – there is some dynamically added code around the block which prevents the widget form being hidden:
<div id="block-16" class="sidebar-box widget_block clr">
<div class="wp-block-group">
<div class="wp-block-group__inner-container">
<div class="wp-block-columns">
<div class="wp-block-column" style="flex-basis: 100%; position: sticky; top: 7243.23px;">
<div class="widget ai_widget ai-viewport-1 ai-sticky-widget" style="">
AD INSERTER BLOCK 3 CODE
</div>
</div>
</div>
</div>
</div>
</div>
It seems that you are using some plugin for sticky widgets that adds this extra widget code.
Maybe CSS mode for Ad Inserter sticky widgets may work with your theme:
https://adinserter.pro/documentation/manual-insertion#widgets
In any case you can try to use the approach described in the post above (you may need to add some insertion delay e.g. 100 ms or wait for the element #block-16
).