<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title>Claim <?php echo e($claim->reference_number); ?></title>
    <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css" rel="stylesheet">
</head>
<body class="bg-light">

<div class="container my-4">

<div class="card shadow-sm">

    
    <div class="card-header bg-white">
        <h5 class="mb-0">Approved Claim – Underwriter Review</h5>
        <small class="text-muted">
            Reference: <?php echo e($claim->reference_number); ?>

        </small>
    </div>

    <div class="card-body small">

        
        <p>
            <strong>Status:</strong>
            <span class="badge bg-success">Approved</span>
        </p>

        <hr>

        
        <h6 class="text-primary">Policy Holder</h6>
        <p><strong>Name:</strong> <?php echo e($claim->policyHolder->name); ?> <?php echo e($claim->policyHolder->surname); ?></p>
        <p><strong>National ID:</strong> <?php echo e($claim->policyHolder->national_id); ?></p>
        <p><strong>Phone:</strong> <?php echo e($claim->policyHolder->cell_number); ?></p>

        <hr>

        
        <h6 class="text-primary">Claimant</h6>
        <p><strong>Name:</strong> <?php echo e($claim->claimant_full_name); ?></p>
        <p><strong>National ID:</strong> <?php echo e($claim->claimant_national_id ?? 'N/A'); ?></p>
        <p><strong>Phone:</strong> <?php echo e($claim->claimant_phone ?? 'N/A'); ?></p>
        <p><strong>Relationship:</strong> <?php echo e($claim->relationship_to_policyholder); ?></p>

        <hr>

        
        <h6 class="text-primary">Deceased Details</h6>
        <p><strong>Name:</strong> <?php echo e($claim->deceased_full_name); ?></p>
        <p><strong>National ID:</strong> <?php echo e($claim->deceased_national_id); ?></p>
        <p><strong>Gender:</strong> <?php echo e($claim->deceased_gender); ?></p>
        <p><strong>Date of Birth:</strong> <?php echo e($claim->deceased_date_of_birth); ?></p>
        <p><strong>Type:</strong> <?php echo e($claim->deceased_type); ?></p>

        <hr>

        
        <h6 class="text-primary">Claim Information</h6>
        <p><strong>Date of Death:</strong> <?php echo e($claim->date_of_death); ?></p>
        <p><strong>Cause of Death:</strong> <?php echo e($claim->cause_of_death); ?></p>
        <p><strong>Remarks:</strong> <?php echo e($claim->remarks ?? 'N/A'); ?></p>

        <hr>

        
        <h6 class="text-primary">Payout Summary</h6>
        <p><strong>Sum Assured:</strong> <?php echo e(number_format($sumAssured, 2)); ?></p>
        <p><strong>Percentage Applied:</strong> <?php echo e($percentageApplied); ?>%</p>
        <p class="fw-bold text-success">
            <strong>Amount Payable:</strong> <?php echo e(number_format($amountPayable, 2)); ?>

        </p>

        <hr>

        
        <h6 class="text-primary">Documents</h6>

        <?php if($claim->documents->isEmpty()): ?>
            <p class="text-muted">No documents uploaded.</p>
        <?php else: ?>
            <ul class="list-group list-group-sm">
                <?php $__currentLoopData = $claim->documents; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $doc): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
                    <li class="list-group-item d-flex justify-content-between">
                        <?php echo e($doc->document_type); ?>

                        <a href="<?php echo e(asset($doc->document_path)); ?>" target="_blank">
                            View
                        </a>
                    </li>
                <?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
            </ul>
        <?php endif; ?>

        <hr>

        
        <?php if($claim->action_at): ?>
            <p class="small text-muted">
                Approved on <?php echo e($claim->action_at); ?> <br>
                Approved by <?php echo e(optional($claim->actionBy)->name ?? 'System'); ?>

            </p>
        <?php endif; ?>

    </div>
</div>

<p class="text-center mt-3 text-muted" style="font-size:12px">
    Secure read-only access for underwriting purposes.
</p>

</div>
</body>
</html>
<?php /**PATH C:\WORK-STATION\MBBS\Insurance-Version Controls\03-01-2026\resources\views/claims/underwriter-view.blade.php ENDPATH**/ ?>