

<?php $__env->startSection('title', 'Detail Siswa'); ?>

<?php $__env->startSection('content'); ?>
<div class="container-fluid">
    <!-- Breadcrumb -->
    <nav aria-label="breadcrumb" class="mb-3">
        <ol class="breadcrumb">
            <li class="breadcrumb-item">
                <a href="<?php echo e($student->ijazah_path ? route('admin-dinas.naik-jenjang') : route('admin-dinas.murid-baru')); ?>">
                    <?php echo e($student->ijazah_path ? 'Murid Naik Jenjang' : 'Murid Baru'); ?>

                </a>
            </li>
            <li class="breadcrumb-item active">Detail Siswa</li>
        </ol>
    </nav>

    <!-- Page Header -->
    <div class="d-flex justify-content-between align-items-center mb-4">
        <div>
            <h2 class="mb-1">
                <i class="bi bi-person-fill <?php echo e($student->ijazah_path ? 'text-success' : 'text-primary'); ?>"></i>
                Detail Siswa
            </h2>
            <p class="text-muted mb-0">Informasi lengkap siswa</p>
        </div>
        <a href="<?php echo e($student->ijazah_path ? route('admin-dinas.naik-jenjang') : route('admin-dinas.murid-baru')); ?>" class="btn btn-outline-secondary">
            <i class="bi bi-arrow-left me-1"></i> Kembali
        </a>
    </div>

    <div class="row">
        <!-- Main Content -->
        <div class="col-lg-8">
            <!-- Data Identitas -->
            <div class="card border-0 shadow-sm mb-4">
                <div class="card-header <?php echo e($student->ijazah_path ? 'bg-success' : 'bg-primary'); ?> text-white py-3">
                    <h5 class="mb-0">
                        <i class="bi bi-person-vcard me-2"></i>
                        Data Identitas
                    </h5>
                </div>
                <div class="card-body">
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">NIK</div>
                        <div class="col-md-8 fw-bold"><?php echo e($student->nik); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">NISN</div>
                        <div class="col-md-8 fw-bold"><?php echo e($student->nisn ?? '-'); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">NIS</div>
                        <div class="col-md-8"><?php echo e($student->nis); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Nama Lengkap</div>
                        <div class="col-md-8 fw-bold"><?php echo e($student->nama); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Tempat, Tanggal Lahir</div>
                        <div class="col-md-8">
                            <?php echo e($student->tempat_lahir); ?>, <?php echo e($student->tanggal_lahir->format('d F Y')); ?>

                            <span class="badge bg-info ms-2"><?php echo e($student->age); ?> tahun</span>
                        </div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Jenis Kelamin</div>
                        <div class="col-md-8"><?php echo e($student->jenis_kelamin == 'L' ? 'Laki-laki' : 'Perempuan'); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Agama</div>
                        <div class="col-md-8"><?php echo e($student->agama); ?></div>
                    </div>
                </div>
            </div>

            <!-- Data Orang Tua -->
            <div class="card border-0 shadow-sm mb-4">
                <div class="card-header bg-info text-white py-3">
                    <h5 class="mb-0">
                        <i class="bi bi-people me-2"></i>
                        Data Orang Tua
                    </h5>
                </div>
                <div class="card-body">
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Nama Ayah</div>
                        <div class="col-md-8 fw-bold"><?php echo e($student->nama_ayah); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Tahun Lahir Ayah</div>
                        <div class="col-md-8">
                            <?php if($student->tahun_lahir_ayah): ?>
                                <?php echo e($student->tahun_lahir_ayah); ?>

                                <span class="badge bg-secondary ms-2"><?php echo e(date('Y') - $student->tahun_lahir_ayah); ?> tahun</span>
                            <?php else: ?>
                                <span class="text-muted">-</span>
                            <?php endif; ?>
                        </div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Nama Ibu</div>
                        <div class="col-md-8 fw-bold"><?php echo e($student->nama_ibu); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Tahun Lahir Ibu</div>
                        <div class="col-md-8">
                            <?php if($student->tahun_lahir_ibu): ?>
                                <?php echo e($student->tahun_lahir_ibu); ?>

                                <span class="badge bg-secondary ms-2"><?php echo e(date('Y') - $student->tahun_lahir_ibu); ?> tahun</span>
                            <?php else: ?>
                                <span class="text-muted">-</span>
                            <?php endif; ?>
                        </div>
                    </div>
                </div>
            </div>

            <!-- Data Kontak -->
            <div class="card border-0 shadow-sm mb-4">
                <div class="card-header bg-warning text-dark py-3">
                    <h5 class="mb-0">
                        <i class="bi bi-telephone me-2"></i>
                        Data Kontak
                    </h5>
                </div>
                <div class="card-body">
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Alamat</div>
                        <div class="col-md-8"><?php echo e($student->alamat); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">No. HP/WA</div>
                        <div class="col-md-8">
                            <a href="https://wa.me/<?php echo e(preg_replace('/[^0-9]/', '', $student->phone)); ?>" target="_blank" class="text-decoration-none">
                                <i class="bi bi-whatsapp text-success me-1"></i><?php echo e($student->phone); ?>

                            </a>
                        </div>
                    </div>
                </div>
            </div>

            <!-- Data Pendidikan -->
            <div class="card border-0 shadow-sm mb-4">
                <div class="card-header bg-secondary text-white py-3">
                    <h5 class="mb-0">
                        <i class="bi bi-mortarboard me-2"></i>
                        Data Pendidikan
                    </h5>
                </div>
                <div class="card-body">
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Sekolah Asal</div>
                        <div class="col-md-8"><?php echo e($student->sekolah_asal ?? '-'); ?></div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Jenis Ketunaan</div>
                        <div class="col-md-8">
                            <?php if($student->disabilityType): ?>
                                <span class="badge bg-secondary"><?php echo e($student->disabilityType->name); ?></span>
                            <?php else: ?>
                                <span class="text-muted">-</span>
                            <?php endif; ?>
                        </div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Jenjang</div>
                        <div class="col-md-8">
                            <span class="badge <?php echo e($student->ijazah_path ? 'bg-success' : 'bg-primary'); ?> fs-6"><?php echo e($student->jenjang); ?></span>
                        </div>
                    </div>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Kelas</div>
                        <div class="col-md-8">
                            <span class="badge bg-info fs-6">Kelas <?php echo e($student->kelas); ?></span>
                        </div>
                    </div>
                    <?php if($student->ijazah_path): ?>
                    <div class="row mb-3">
                        <div class="col-md-4 text-muted">Ijazah</div>
                        <div class="col-md-8">
                            <a href="<?php echo e(Storage::url($student->ijazah_path)); ?>" target="_blank" class="btn btn-sm btn-outline-primary">
                                <i class="bi bi-file-earmark-pdf me-1"></i> Lihat Ijazah
                            </a>
                        </div>
                    </div>
                    <?php endif; ?>
                </div>
            </div>
        </div>

        <!-- Sidebar -->
        <div class="col-lg-4">
            <!-- School Info -->
            <div class="card border-0 shadow-sm mb-4">
                <div class="card-body text-center">
                    <i class="bi bi-building display-4 text-primary mb-3"></i>
                    <h5 class="mb-2"><?php echo e($student->school->name); ?></h5>
                    <p class="text-muted mb-0">NPSN: <?php echo e($student->school->npsn); ?></p>
                    <p class="text-muted mb-0 small"><?php echo e($student->school->address); ?></p>
                </div>
            </div>

            <!-- Status Badge -->
            <div class="card border-0 shadow-sm mb-4">
                <div class="card-body">
                    <h6 class="mb-3">Status</h6>
                    <div class="d-flex justify-content-between align-items-center mb-2">
                        <span class="text-muted">Kategori</span>
                        <span class="badge <?php echo e($student->ijazah_path ? 'bg-success' : 'bg-primary'); ?>">
                            <?php echo e($student->ijazah_path ? 'Naik Jenjang' : 'Murid Baru'); ?>

                        </span>
                    </div>
                    <div class="d-flex justify-content-between align-items-center mb-2">
                        <span class="text-muted">Status Aktif</span>
                        <span class="badge <?php echo e($student->is_active ? 'bg-success' : 'bg-danger'); ?>">
                            <?php echo e($student->is_active ? 'Aktif' : 'Tidak Aktif'); ?>

                        </span>
                    </div>
                    <div class="d-flex justify-content-between align-items-center">
                        <span class="text-muted">Tanggal Input</span>
                        <small><?php echo e($student->created_at->format('d/m/Y')); ?></small>
                    </div>
                </div>
            </div>

            <!-- Photo Placeholder -->
            <div class="card border-0 shadow-sm">
                <div class="card-body text-center">
                    <h6 class="mb-3">Foto Siswa</h6>
                    <?php if($student->photo): ?>
                        <img src="<?php echo e(Storage::url($student->photo)); ?>" alt="Foto <?php echo e($student->nama); ?>" class="img-fluid rounded">
                    <?php else: ?>
                        <div class="bg-light rounded p-5">
                            <i class="bi bi-person-circle display-1 text-muted"></i>
                            <p class="text-muted mt-2 mb-0 small">Belum ada foto</p>
                        </div>
                    <?php endif; ?>
                </div>
            </div>
        </div>
    </div>
</div>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.app', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH C:\xampp\htdocs\appsuper\resources\views/admin-dinas/murid/detail.blade.php ENDPATH**/ ?>