{/* Header (nicht scrollend) */}
{icon && (
{icon}
)}
{title && (
{title}
)}
{!children && description && (
{description}
)}
{headerExtras && (
{headerExtras}
)}
{/* MAIN: Body + Sidebar – bekommt min-h-0 und nur der Body scrollt */}
{(bodyContent || sidebar) && (
{/* Linker Inhalt (scrollbar) */}
{bodyContent && (
{bodyContent}
)}
{/* Rechte Sidebar (nicht scrollbar, eigene interne Scroller möglich) */}
{sidebar && (
)}
)}
{/* Footer (immer sichtbar, außerhalb des scrollbaren Bereichs) */}
{footer ? (
footer
) : hasActions ? (
{primaryAction &&
renderActionButton(
primaryAction,
hasBothActions ? 'flex-1' : undefined,
)}
{secondaryAction &&
renderActionButton(
{ ...secondaryAction, variant: secondaryAction.variant ?? 'secondary' },
hasBothActions ? 'flex-1' : undefined,
)}
) : null}