@php $tiles = [ ['icon' => 'calendar-8', 'color' => 'primary', 'value' => $today['total'], 'label' => trans('clinic.home.today_total'), 'sub' => trans('clinic.home.cancelled_count', ['count' => $today['cancelled']])], ['icon' => 'check-circle', 'color' => 'success', 'value' => $today['paid'], 'label' => trans('clinic.home.today_paid'), 'sub' => number_format($today['paid_amount'], 2)], ['icon' => 'time', 'color' => 'warning', 'value' => $today['unpaid'], 'label' => trans('clinic.home.today_unpaid'), 'sub' => number_format($today['unpaid_amount'], 2)], ['icon' => 'arrows-circle', 'color' => 'info', 'value' => $today['followups'], 'label' => trans('clinic.home.today_followups'), 'sub' => null], ]; @endphp

{{ trans('clinic.home.today_section') }} {{ now()->translatedFormat('l j F Y') }}

@foreach ($tiles as $tile)
{{ number_format($tile['value']) }} {{ $tile['label'] }} @if ($tile['sub'] !== null) {{ $tile['sub'] }} @endif
@endforeach
{{-- Status strip: count + amount per status. Each chip also filters today's table below. --}}
{{ trans('clinic.home.by_status') }}
@foreach ($today['by_status'] as $status => $row) @endforeach