To track the expansion and collapse of summary/details elements in GA4, you can create Custom Events triggered by user interactions (e.g., clicks).Configure these events in GA4 to track the engagement, then use the Event Reports to analyze how users interact with these elements.