@props(['variant' => 'danger', 'size' => 'default']) @php $deadlineDate = \Carbon\Carbon::parse(config('payment-correction.deadline_date')); $gracePeriodDate = \Carbon\Carbon::parse(config('payment-correction.grace_deadline_date')); $now = now(); $isBeforeDeadline = $now->isBefore($deadlineDate); $isBeforeGracePeriod = $now->isBefore($gracePeriodDate); $isPastGracePeriod = $now->isAfter($gracePeriodDate); // Size variants $sizeClasses = [ 'sm' => 'fs-9', 'default' => 'fs-8', 'lg' => 'fs-7 fs-md-6', 'xl' => 'fs-6 fs-md-5' ]; $fontSize = $sizeClasses[$size] ?? $sizeClasses['default']; // Variant classes $variantClasses = [ 'danger' => 'bg-danger-subtle text-danger border-danger', 'warning' => 'bg-warning-subtle text-warning border-warning', 'info' => 'bg-info-subtle text-info border-info', 'primary' => 'bg-primary-subtle text-primary border-primary', ]; $cardClass = $variantClasses[$variant] ?? $variantClasses['danger']; @endphp
@if($isBeforeDeadline) ⚠️ Payment Deadline Approaching @elseif($isBeforeGracePeriod) 🚨 Grace Period Active @else ❌ Deadline Passed @endif

@if($isBeforeDeadline) {{-- BEFORE DEADLINE: Only show main deadline, no grace period mention --}} Payment Deadline: {{ $deadlineDate->format('F j, Y') }} at {{ $deadlineDate->format('g:i A') }} @elseif($isBeforeGracePeriod) {{-- AFTER DEADLINE: Reveal grace period as "last chance" --}} ⚠️ Main Deadline Missed!
Last Chance - Grace Period Ends: {{ $gracePeriodDate->format('F j, Y') }} at {{ $gracePeriodDate->format('g:i A') }} @else All deadlines have passed @endif

@if($isBeforeDeadline) {{-- BEFORE DEADLINE: Strong warning without mentioning grace period --}} Complete payment by {{ $deadlineDate->format('F j, Y') }} to avoid account restrictions or deletion. @elseif($isBeforeGracePeriod) {{-- GRACE PERIOD: Urgent warning --}} After {{ $gracePeriodDate->format('F j, Y') }}, your UID will be permanently deleted! @else UIDs that haven't completed payment have been deleted. @endif

@if(!$isPastGracePeriod)
@if($isBeforeDeadline) Time Until Deadline @else Grace Period Remaining @endif
--
Days
--
Hours
--
Mins
--
Secs
@endif
@once @push('scripts') @endpush @endonce