My website features a Bootstrap accordion that I have organized into a two-column layout using the following CSS:
#accordion {
column-count: 2;
}
.card {
margin: 0px 20px 20px 20px;
break-inside: avoid-column;
-webkit-column-break-inside: avoid;
}
a{
display:block;
}
The issue arises when expanding items in the second column. Some items in the first column jump back, especially on pages with a larger number of items, making it difficult for users to interact with them effectively.
I opted for the two-column layout due to the dynamic nature of the content generated by PHP, which can vary in the number of accordions and items.
Is there a solution to prevent these jumping behavior when expanding items across columns?