@php
    $applicant_details = App\Models\Application::where('id', $id)->first();
    $applicant_instrucutor = App\Models\Instructors::where('id', $id)->first();
    $user = get_user_info($applicant_details->user_id);
    $user_photo = get_user_info($applicant_details->user_id)->photo;

    // Ensure the placeholder image path is correct
    $placeholder_image = asset('uploads/system/placeholder.png');
@endphp


<style>
    .instructor-info li:nth-last-child(1){
        border: none;
    }
    .instructor-info li{
        display: flex;
        align-content: center;
        justify-content: space-between;
        border-bottom: 1px solid var(--borderColor);
        padding: 16px 0;
    }
    .instructor-info li span:nth-child(1){
        font-size: 14px;
        font-weight: 600;
        color: var(--darkColor);
    }
    .instructor-info li span:nth-child(2){
        font-size: 14px;
        font-weight: 500;
        color: var(--grayColor);
    }
</style>

<div class="text-center mb-2">
    <img class="mr-2 rounded-circle image-100" src="{{ $user_photo ? asset($user_photo) : $placeholder_image }}" alt=""
        height="80">
</div>

<ul class="instructor-info">
    <li>
        <span>{{ get_phrase('Applicant') }}</span>
        <span>{{ $user->name }}</span>
    </li>
    <li>
        <span>{{ get_phrase('Email') }}</span>
        <span>{{ $user->email }}</span>
    </li>
    <li>
        <span>{{ get_phrase('NIDN') }}</span>
        <span>{{ $applicant_instrucutor->nidn ?? 'N/A' }}</span>
    </li>
    <li>
        <span>{{ get_phrase('Study Program') }}</span>
        <span>{{ $applicant_instrucutor->id_sms ?? 'N/A' }}</span>
    </li>
    <li>
        <span>{{ get_phrase('University') }}</span>
        <span>{{ $applicant_instrucutor->id_pt?? 'N/A' }}</span>
    </li>
    <li>
        <span>{{ get_phrase('Message') }}&nbsp</span>: &nbsp
        <span>{{ $applicant_details->description }}</span>
    </li>
    <li>
        <span>{{ get_phrase('Status') }}</span>
        @if ($applicant_details->status)
            <span class="badge bg-success">{{ get_phrase('Accepted') }}</span>
        @else
            <span class="badge bg-danger">{{ get_phrase('Pending') }}</span>
        @endif
    </li>
</ul>
