<?php $__env->startSection('header', 'Profil Saya'); ?>

<?php $__env->startSection('content'); ?>
<div class="max-w-2xl mx-auto">
    <div class="bg-white rounded-3xl shadow-sm border border-gray-100 overflow-hidden">
        <div class="p-8 border-b border-gray-100 flex items-center">
            <div class="w-16 h-16 rounded-2xl bg-primary flex items-center justify-center text-white text-2xl font-black mr-4 shadow-lg shadow-primary/20">
                <?php echo e(substr($user->name, 0, 1)); ?>

            </div>
            <div>
                <h3 class="text-xl font-extrabold text-gray-800">Pengaturan Profil</h3>
                <p class="text-sm text-gray-500">Kelola informasi akun dan password Anda</p>
            </div>
        </div>

        <form action="<?php echo e(route('users.profile.update')); ?>" method="POST" class="p-8 space-y-8">
            <?php echo csrf_field(); ?>
            <?php echo method_field('PUT'); ?>

            <div class="space-y-6">
                <h4 class="text-xs font-black text-gray-400 uppercase tracking-[0.2em]">Informasi Dasar</h4>
                
                <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                    <div class="space-y-2">
                        <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Nama Lengkap</label>
                        <input type="text" name="name" value="<?php echo e(old('name', $user->name)); ?>" required
                            class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm">
                    </div>

                    <div class="space-y-2">
                        <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Email (User ID)</label>
                        <input type="email" name="email" value="<?php echo e(old('email', $user->email)); ?>" required
                            class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm">
                    </div>

                    <div class="space-y-2">
                        <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Email Pemulihan (Recovery)</label>
                        <input type="email" name="recovery_email" value="<?php echo e(old('recovery_email', $user->recovery_email)); ?>"
                            class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm"
                            placeholder="email@gmail.com">
                    </div>

                    <div class="space-y-2">
                        <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Nomor HP (WA)</label>
                        <input type="text" name="phone_number" value="<?php echo e(old('phone_number', $user->phone_number)); ?>"
                            class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm"
                            placeholder="0812xxxx">
                    </div>
                </div>

                <div class="p-4 bg-gray-50 rounded-2xl border border-dashed border-gray-200 grid grid-cols-2 gap-4">
                    <div>
                        <p class="text-[10px] font-bold text-gray-400 uppercase">Jabatan</p>
                        <p class="text-sm font-bold text-gray-700"><?php echo e($user->position ?? '-'); ?></p>
                    </div>
                    <div>
                        <p class="text-[10px] font-bold text-gray-400 uppercase">Desa Penugasan</p>
                        <p class="text-sm font-bold text-gray-700"><?php echo e($user->village ?? '-'); ?></p>
                    </div>
                </div>
            </div>

            <div class="space-y-6">
                <h4 class="text-xs font-black text-gray-400 uppercase tracking-[0.2em]">Keamanan</h4>
                
                <div class="space-y-2">
                    <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Password Saat Ini</label>
                    <input type="password" name="current_password"
                        class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm"
                        placeholder="Wajib diisi jika ingin mengubah password">
                </div>

                <div class="grid grid-cols-1 md:grid-cols-2 gap-6">
                    <div class="space-y-2">
                        <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Password Baru</label>
                        <input type="password" name="password"
                            class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm">
                    </div>

                    <div class="space-y-2">
                        <label class="text-xs font-bold text-gray-500 uppercase tracking-widest">Konfirmasi Password Baru</label>
                        <input type="password" name="password_confirmation"
                            class="w-full px-4 py-3 bg-gray-50 border border-gray-100 rounded-2xl focus:ring-2 focus:ring-primary focus:bg-white outline-none transition-all text-sm">
                    </div>
                </div>
            </div>

            <div class="pt-4">
                <button type="submit" class="w-full py-4 bg-primary hover:bg-primary/90 text-white rounded-2xl font-bold text-lg shadow-lg shadow-primary/30 transition-all hover:scale-[1.01] active:scale-95">
                    Simpan Perubahan Profil
                </button>
            </div>
        </form>
    </div>
</div>
<?php $__env->stopSection(); ?>

<?php echo $__env->make('layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/sumba001/public_html/pom500.sumbatengahkab.go.id/resources/views/users/profile.blade.php ENDPATH**/ ?>