@props([
    'panel' => null,
])

@if (is_array($panel))
    <div class="space-y-2 rounded-xl border border-gray-200 bg-white p-4 dark:border-gray-700 dark:bg-gray-900/40">
        <div class="flex flex-wrap items-center gap-2">
            <p class="text-sm font-medium text-gray-900 dark:text-white">
                {{ $panel['label'] }}
            </p>
            <span
                @class([
                    'inline-flex rounded-md px-2 py-0.5 text-xs font-medium',
                    'bg-success-100 text-success-800 dark:bg-success-500/20 dark:text-success-200' => ($panel['badge_color'] ?? '') === 'success',
                    'bg-warning-100 text-warning-800 dark:bg-warning-500/20 dark:text-warning-200' => ($panel['badge_color'] ?? '') === 'warning',
                    'bg-danger-100 text-danger-800 dark:bg-danger-500/20 dark:text-danger-300' => ($panel['badge_color'] ?? '') === 'danger',
                ])
            >
                {{ $panel['method_label'] }}
            </span>
        </div>
        <p class="text-sm text-gray-700 dark:text-gray-200">
            {{ $panel['summary'] }}
        </p>
        <p class="text-sm text-gray-600 dark:text-gray-300">
            {{ $panel['detail'] }}
        </p>
    </div>
@endif
