Group form fields using fieldset, accordion or a simple div wrapper. Groups can be nested (i.e. fields can be wrapped using a fieldset and then wrapped again with an accordion). You can change the background color, border and other more.
If you require conditional logic to hide/show groups, use the default Section field and add it before the start of the group. This allows you to hide/show the group fields depending on the conditional logic configured for the Section field.