Rating Distribution
@foreach(range(5, 1) as $rating)
@php
$count = $reviewsSummary['distribution'][$rating] ?? 0;
$total = $reviewsSummary['total'] ?? 1;
$percentage = $total > 0 ? round(($count / $total) * 100) : 0;
@endphp
{{ $rating }}
{{ $count }}
@endforeach