@push('styles') @endpush @php use App\Models\WalletEarnPlan; $earnPlans = WalletEarnPlan::query() ->active() ->orderBy('sort_order') ->with('currency') ->get(); $locale = $locale ?? app()->getLocale(); $earnEyebrow = !empty($data['subheading'][$locale]) ? $data['subheading'][$locale] : __('Grow your money'); $earnHeading = !empty($data['heading'][$locale]) ? $data['heading'][$locale] : __('Put your wallet to work'); $earnDesc = !empty($data['description'][$locale]) ? $data['description'][$locale] : __('Stake your funds and earn guaranteed returns. Flexible terms, transparent payouts, zero surprises.'); @endphp
{{-- Background orbs --}} {{-- Section header --}}
{{ $earnEyebrow }}

{!! nl2br(e($earnHeading)) !!}

{{ $earnDesc }}

{{-- Plans grid --}}
@if($earnPlans->isEmpty())

{{ __('No earning plans available at the moment.') }}

@else
@foreach($earnPlans as $earnIdx => $earnPlan) @php $isFeatured = $earnPlan->is_featured; $badgeLabel = $earnPlan->planBadgeLabel(); $currencyLabel = $earnPlan->currency_id ? $earnPlan->currency->code : __('All Wallets'); @endphp {{-- card-wrap holds the badge outside overflow:hidden --}}
{{-- Badge (positioned above the card) --}} @if($badgeLabel)
{{ $badgeLabel }}
@endif
{{-- Top section: icon + name + rate + pills --}}
@if($earnPlan->icon) {{ $earnPlan->name }} @else @endif
{{ $earnPlan->name }}
{{ $earnPlan->description ?: __('Earn scheduled rewards while your principal stays locked.') }}
{{-- Rate --}}
{{ number_format((float) $earnPlan->profit_rate, 2) }} % {{ $earnPlan->profit_type->label() }}
{{-- Pills --}}
{{ $currencyLabel }} {{ $earnPlan->durationLabel() }} {{ $earnPlan->payout_frequency->label() }}
{{-- Divider --}}
{{-- Body: details + bullets --}}
{{ $earnPlan->amountRangeLabel() }} @if($earnPlan->currency_id) {{ $earnPlan->currency->code }} @endif
{{ $earnPlan->payout_frequency->label() }} {{ __('payout') }}
{{ $earnPlan->return_principal ? __('Returned') : __('Not returned') }} {{ __('principal') }}
{{ $earnPlan->auto_approve ? __('Auto') : __('Manual') }} {{ __('approval') }}
{{ $earnPlan->currency_id ? $earnPlan->currency->code . ' ' . __('only') : __('All currencies') }}
{{ $earnPlan->auto_approve ? __('Auto-approved') : __('Manual review') }}
{{ $earnPlan->return_principal ? __('Principal returned') : __('Principal locked') }}
{{-- CTA --}}
@endforeach
@endif