@extends('temple.layouts.app') @section('content')
{{-- Page Header --}}

Notifications

Important updates regarding your temple account

{{-- Subscription Expiry Reminder (Styled as a premium alert) --}} @if ($daysRemaining >= 0 && $daysRemaining <= 2)
Subscription Expiry Reminder

@if ($daysRemaining == 2) Your temple registration/subscription will expire in 2 days. @elseif($daysRemaining == 1) Your temple registration/subscription will expire tomorrow. @elseif($daysRemaining == 0) Your temple registration/subscription expires today. @endif

Expiry Date: {{ $expiryDate->format('d M Y') }}
@endif {{-- Success Message --}} @if (session('success')) @endif {{-- Notifications List Card --}}
All Notifications @if ($unreadCount > 0) {{ $unreadCount }} New @endif
@if ($unreadCount > 0)
@csrf
@endif
@forelse($notifications as $notification) {{-- Notification Item --}}
{{-- Unread Indicator / Icon --}}
@if (!$notification->is_read)
@else
@endif
{{-- Content --}}
{{ $notification->title }} @if (!$notification->is_read) New @endif
{{ $notification->created_at->diffForHumans() }}

{{ $notification->message }}

{{ $notification->created_at->format('d M Y, h:i A') }} @if (!$notification->is_read)
@csrf
@else Read @endif
@empty @if (!($daysRemaining >= 0 && $daysRemaining <= 2)) {{-- Empty State --}}
You're all caught up!

No new notifications at the moment.

We'll notify you when something important happens.

@endif @endforelse
{{-- Optional: Add this to your CSS file or inside a @endsection