<?php if (isset($component)) { $__componentOriginalde7351e060091d622377605e583428b9 = $component; } ?>
<?php if (isset($attributes)) { $__attributesOriginalde7351e060091d622377605e583428b9 = $attributes; } ?>
<?php $component = Illuminate\View\AnonymousComponent::resolve(['view' => 'components.emails.layout','data' => ['subject' => 'Grant Submission Confirmation','headerTitle' => config('app.name'),'headerUrl' => route('user.dashboard')]] + (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag ? $attributes->all() : [])); ?>
<?php $component->withName('emails.layout'); ?>
<?php if ($component->shouldRender()): ?>
<?php $__env->startComponent($component->resolveView(), $component->data()); ?>
<?php if (isset($attributes) && $attributes instanceof Illuminate\View\ComponentAttributeBag): ?>
<?php $attributes = $attributes->except(\Illuminate\View\AnonymousComponent::ignoredParameterNames()); ?>
<?php endif; ?>
<?php $component->withAttributes(['subject' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute('Grant Submission Confirmation'),'headerTitle' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(config('app.name')),'headerUrl' => \Illuminate\View\Compilers\BladeCompiler::sanitizeComponentAttribute(route('user.dashboard'))]); ?>
<?php \Livewire\Features\SupportCompiledWireKeys\SupportCompiledWireKeys::processComponentKey($component); ?>


    <!-- Header -->
    <h1 style="margin:0 0 20px 0; font-size:28px; font-weight:700; color:#0369a1; text-align:center;">
        Grant Submission Confirmation
    </h1>

    <!-- Greeting -->
    <p style="margin:0 0 20px 0; font-size:16px; line-height:1.6; color:#333;">
        Hello <strong><?php echo e($grant->user->name); ?></strong>,
    </p>

    <!-- Intro -->
    <p style="margin:0 0 30px 0; font-size:16px; line-height:1.6; color:#555;">
        Thank you for submitting your grant application. Here are the details of your submission:
    </p>

    <!-- Grant Details -->
    <h2 style="color:#0369a1; margin-bottom:10px; font-size:18px; border-bottom:2px solid #0284c7; padding-bottom:4px;">
        Grant Details
    </h2>
    <table width="100%" cellpadding="10" cellspacing="0" style="border-collapse:collapse; font-size:14px;">
        <!-- Type -->
        <tr style="background:#f2f2f2; color:#0369a1;">
            <th align="left" style="padding:8px;">Grant Type</th>
            <td style="padding:8px;"><?php echo e(ucfirst($grant->type)); ?></td>
        </tr>

        <!-- Dynamic Title -->
        <tr>
            <th align="left" style="padding:8px;">Grant Title</th>
            <td style="padding:8px;">
                <?php echo e($grant->type === 'company' ? 'Company Grant Application' : 'Personal Grant Application'); ?>

            </td>
        </tr>

        <!-- Requested Amount -->
        <tr style="background:#f9f9f9;">
            <th align="left" style="padding:8px;">Requested Amount</th>
            <td style="padding:8px;">$<?php echo e(number_format($grant->amount, 2)); ?></td>
        </tr>

        <!-- Company: Project Details -->
        <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if($grant->type === 'company' && !empty($grant->metadata['project']['title'])): ?>
            <tr>
                <th align="left" style="padding:8px;">Project Name</th>
                <td style="padding:8px;"><?php echo e($grant->metadata['project']['title']); ?></td>
            </tr>
            <tr style="background:#f9f9f9;">
                <th align="left" style="padding:8px;">Project Description</th>
                <td style="padding:8px;"><?php echo e($grant->metadata['project']['description']); ?></td>
            </tr>
        <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

        <!-- Personal: Primary Purpose -->
        <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if($grant->type === 'personal' && !empty($grant->purposes)): ?>
            <tr style="background:#f2f2f2;">
                <th align="left" style="padding:8px;">Primary Purpose</th>
                <td style="padding:8px;"><?php echo e(ucwords(str_replace('_', ' ', $grant->purposes[0]))); ?></td>
            </tr>
        <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

        <!-- Optional: Additional Purposes -->
        <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(!empty($grant->purposes) && count($grant->purposes) > 1): ?>
            <tr style="background:#f9f9f9;">
                <th align="left" style="padding:8px;">Other Purposes</th>
                <td style="padding:8px;">
                    <?php echo e(implode(', ', array_map(fn($p) => ucwords(str_replace('_', ' ', $p)), array_slice($grant->purposes, 1)))); ?>

                </td>
            </tr>
        <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

        <!-- Organization Name -->
        <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(!empty($grant->metadata['organization']['name'])): ?>
            <tr style="background:#f2f2f2;">
                <th align="left" style="padding:8px;">Organization Name</th>
                <td style="padding:8px;"><?php echo e($grant->metadata['organization']['name']); ?></td>
            </tr>
        <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>

        <!-- Status -->
        <tr style="background:#f9f9f9;">
            <th align="left" style="padding:8px;">Status</th>
            <td style="padding:8px;"><?php echo e(ucfirst($grant->status)); ?></td>
        </tr>

        <!-- Submission Date -->
        <tr style="background:#f2f2f2;">
            <th align="left" style="padding:8px;">Submission Date</th>
            <td style="padding:8px;"><?php echo e($grant->created_at->format('Y-m-d H:i:s')); ?></td>
        </tr>
    </table>

    <!-- User Details -->
    <h2 style="color:#0369a1; margin-bottom:10px; font-size:18px; border-bottom:2px solid #0284c7; padding-bottom:4px;">
        User Details
    </h2>
    <table width="100%" cellpadding="10" cellspacing="0" style="border-collapse:collapse; font-size:14px;">
        <tr style="background:#f2f2f2; color:#0369a1;">
            <th align="left" style="padding:8px;">Full Name</th>
            <td style="padding:8px;"><?php echo e($grant->user->name); ?></td>
        </tr>
        <tr style="background:#f9f9f9;">
            <th align="left" style="padding:8px;">Email</th>
            <td style="padding:8px;"><?php echo e($grant->user->email); ?></td>
        </tr>
        <?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if BLOCK]><![endif]--><?php endif; ?><?php if(!empty($grant->contact_person)): ?>
            <tr style="background:#f2f2f2;">
                <th align="left" style="padding:8px;">Contact Person</th>
                <td style="padding:8px;">
                    <?php echo e($grant->contact_person ?? ($grant->metadata['contact']['contact_person'] ?? 'N/A')); ?>

                </td>
            </tr>
        <?php endif; ?><?php if(\Livewire\Mechanisms\ExtendBlade\ExtendBlade::isRenderingLivewireComponent()): ?><!--[if ENDBLOCK]><![endif]--><?php endif; ?>
    </table>

    <!-- Closing Note -->
    <p style="margin:30px 0 20px 0; font-size:16px; line-height:1.6; color:#555;">
        Your application is currently under review. You will receive a notification once it has been processed.
    </p>

    <!-- Footer -->
    <p style="font-size:13px; color:#888; text-align:center; line-height:1.5; margin-bottom:10px;">
        Date: <strong><?php echo e(now()->toDayDateTimeString()); ?></strong>
    </p>
    <p style="font-size:13px; color:#888; text-align:center; line-height:1.5; margin-bottom:20px;">
        This is an automated message. Please do not reply.
    </p>

    <p style="font-size:14px; color:#555; text-align:center; line-height:1.6;">
        Thank you for choosing <strong><?php echo e(config('app.name')); ?></strong>.<br>
        &mdash; The <?php echo e(config('app.name')); ?> Team
    </p>

 <?php echo $__env->renderComponent(); ?>
<?php endif; ?>
<?php if (isset($__attributesOriginalde7351e060091d622377605e583428b9)): ?>
<?php $attributes = $__attributesOriginalde7351e060091d622377605e583428b9; ?>
<?php unset($__attributesOriginalde7351e060091d622377605e583428b9); ?>
<?php endif; ?>
<?php if (isset($__componentOriginalde7351e060091d622377605e583428b9)): ?>
<?php $component = $__componentOriginalde7351e060091d622377605e583428b9; ?>
<?php unset($__componentOriginalde7351e060091d622377605e583428b9); ?>
<?php endif; ?>
<?php /**PATH /Users/macuser/Herd/Novabank/resources/views/emails/grants/confirmation.blade.php ENDPATH**/ ?>