{{--
    Breadcrumb component with schema.org structured data.

    @param  \Illuminate\Support\Collection  $breadcrumbs
            Collection of objects with ->name and ->url properties.
--}}
@if(isset($breadcrumbs) && $breadcrumbs->isNotEmpty())
<nav class="flex items-center gap-1.5 flex-wrap text-sm text-neutral-400" aria-label="Breadcrumb">
    <a class="hover:text-white transition-colors" href="/">Home</a>
    @foreach($breadcrumbs as $crumb)
        <span class="opacity-40" aria-hidden="true">›</span>
        @if(!$loop->last)
            <a class="hover:text-white transition-colors" href="{{ $crumb->url }}">{{ $crumb->name }}</a>
        @else
            <span class="text-white/70">{{ $crumb->name }}</span>
        @endif
    @endforeach
</nav>
@endif
