ACF includes a copy of layout that is uses to create a new layout by copying these. When you are setting the layouts to collapse you are also setting these copies.
your selector should look something like this… I think, you may need to inspect the html to find them and target them, but this is the general idea
$('.layout').not('.clones .layout').addClass('-collapsed');