Hide collapsible tab when metafields are empty in Momentum theme

Im trying to hide the collasible tabs when emtpy. Im using the following metafields
{{ product.metafields.custom.shipping.value.tab_content }}

This is an example of a product with a metafield assign to it.
https://9livesracing.com/products/128i-big-wang-kit-07-13-e82?_pos=1&_psq=128i+Big+Wang+Kit+%2707-13+E82&_ss=e&_v=1.0

This is an example of a product with a no metafield assign to it.
https://9livesracing.com/products/add-on-swan-it-change-any-wang-kit-to-swan-mounting

Thank you

Hi @MikeCZ ,

You need a custom code to do that and we can help you

Thanks @BSSCommerce-TC , can you share the solution by replying to this comment?

Hi @MikeCZ ,

Let try insert below code at the end file theme.css and Save theme

div[data-name="custom-liquid"]:not(.pb-l.md\:pb-xl > p) {
    display: none !important;
}

Thank you for your response. Unfortunately, the code hides the shipping tab regardless of whether the tab is empty or populated with a metafield.