<x-app-layout>
    <div class="py-12 px-6 lg:px-12 bg-brand-50/30 min-h-screen">
        <div class="max-w-5xl mx-auto">
            <!-- Header Section -->
            <header class="mb-12 flex flex-col md:flex-row md:items-end justify-between gap-8">
                <div class="space-y-2">
                    <h2 class="font-display text-4xl font-black text-brand-950 tracking-tight italic uppercase">Konfirmasi Aktivasi</h2>
                    <p class="text-brand-400 text-[10px] font-black uppercase tracking-[0.2em] italic">Finalisasi Lisensi Digital — {{ $plan->name }} Edition</p>
                </div>
            </header>

            <div class="grid lg:grid-cols-12 gap-10">
                <!-- Instruction Card -->
                <div class="lg:col-span-4 bg-brand-950 rounded-[48px] p-10 text-white shadow-2xl shadow-brand-200 relative overflow-hidden group">
                    <div class="relative z-10 space-y-12">
                        <div class="space-y-2">
                            <h4 class="text-[10px] font-black uppercase tracking-[0.4em] text-white/40 italic">Protokol Transfer</h4>
                            <div class="h-1 w-12 bg-primary-600 rounded-full"></div>
                        </div>

                        <div class="space-y-8">
                            <div class="group/item">
                                <p class="text-[9px] font-black uppercase tracking-widest text-white/30 mb-2 italic">Lembaga Perbankan</p>
                                <p class="text-2xl font-display font-black group-hover:text-primary-500 transition-colors italic">BANK BCA</p>
                            </div>
                            <div class="group/item">
                                <p class="text-[9px] font-black uppercase tracking-widest text-white/30 mb-2 italic">Nomor Virtual Account</p>
                                <p class="text-3xl font-display font-black tracking-widest group-hover:text-primary-500 transition-colors italic leading-none">123-456-7890</p>
                            </div>
                            <div class="group/item">
                                <p class="text-[9px] font-black uppercase tracking-widest text-white/30 mb-2 italic">Entitas Penerima</p>
                                <p class="text-[13px] font-black uppercase tracking-tight group-hover:text-primary-500 transition-colors">PT LEASINGPRO INDO</p>
                            </div>
                        </div>

                        <div class="pt-10 border-t border-white/10">
                            <p class="text-[9px] font-black uppercase tracking-widest text-white/30 mb-2 italic">Valuasi Nominal</p>
                            <p class="text-5xl font-display font-black text-primary-500 tracking-tighter italic leading-none">Rp {{ number_format($plan->price, 0, ',', '.') }}</p>
                        </div>
                    </div>

                    <!-- Decor -->
                    <div class="absolute right-[-10%] bottom-[-10%] opacity-[0.05] pointer-events-none group-hover:scale-110 transition-transform duration-1000">
                        <svg class="w-64 h-64" fill="currentColor" viewBox="0 0 24 24"><path d="M12 2L3 5v6c0 5.55 3.84 10.74 9 12 5.16-1.26 9-6.45 9-12V5l-9-4z"></path></svg>
                    </div>
                </div>

                <!-- Form Section -->
                <div class="lg:col-span-8 premium-card p-12 bg-white relative overflow-hidden group">
                    <form action="{{ route('payment.store') }}" method="POST" enctype="multipart/form-data" class="space-y-10 relative z-10">
                        @csrf
                        <input type="hidden" name="plan_id" value="{{ $plan->id }}">
                        <input type="hidden" name="amount" value="{{ $plan->price }}">

                        <div class="grid grid-cols-1 md:grid-cols-2 gap-10">
                            <div class="space-y-3">
                                <label class="text-[10px] font-black text-brand-300 uppercase tracking-widest italic px-1">Identitas Pengirim (Sesuai Rekening)</label>
                                <input type="text" name="sender_name" required class="w-full px-8 py-5 rounded-[24px] border-brand-50 bg-brand-50/30 text-sm font-bold text-brand-950 focus:ring-primary-500 focus:border-primary-500 transition-all placeholder:text-brand-200" placeholder="E.g. Alexander Graham">
                            </div>

                            <div class="space-y-3">
                                <label class="text-[10px] font-black text-brand-300 uppercase tracking-widest italic px-1">Kronologi Transfer</label>
                                <input type="date" name="transfer_date" required class="w-full px-8 py-5 rounded-[24px] border-brand-50 bg-brand-50/30 text-sm font-bold text-brand-950 focus:ring-primary-500 focus:border-primary-500 transition-all">
                            </div>
                        </div>

                        <div class="space-y-4">
                            <label class="text-[10px] font-black text-brand-300 uppercase tracking-widest italic px-1">Unggah Artefak Digital (Bukti Transfer)</label>
                            <label class="group/upload block cursor-pointer transition-all duration-500">
                                <div class="relative overflow-hidden border-2 border-brand-50 border-dashed rounded-[40px] bg-brand-50/10 p-12 text-center group-hover/upload:border-primary-500 group-hover/upload:bg-white transition-all">
                                    <div class="relative z-10 space-y-6">
                                        <div class="w-20 h-20 bg-white border border-brand-50 rounded-[32px] flex items-center justify-center mx-auto text-brand-200 group-hover/upload:text-primary-600 group-hover/upload:scale-110 transition-all shadow-sm">
                                            <svg class="w-10 h-10" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2.5" d="M7 16a4 4 0 01-.88-7.903A5 5 0 1115.9 6L16 6a5 5 0 011 9.9M15 13l-3-3m0 0l-3 3m3-3v12"></path></svg>
                                        </div>
                                        <div class="space-y-1">
                                            <p class="text-[11px] font-black text-brand-950 uppercase tracking-widest">Pilih Gambar Bukti Transfer</p>
                                            <p class="text-[9px] font-black text-brand-300 uppercase tracking-[0.2em] italic">Format: PNG, JPG, JPEG (Max 2MB)</p>
                                        </div>
                                    </div>
                                    <input type="file" name="proof" required accept="image/*" class="hidden">
                                </div>
                            </label>
                        </div>

                        <div class="pt-6">
                            <button type="submit" class="w-full btn-primary !py-6 text-[11px] font-black uppercase tracking-[0.3em] shadow-2xl shadow-primary-200 hover:shadow-primary-300 transition-all active:scale-[0.98] italic">
                                Konfirmasi & Transmisi Data Aktivasi →
                            </button>
                        </div>
                    </form>

                    <div class="absolute right-[-10%] bottom-[-10%] opacity-[0.02] pointer-events-none group-hover:scale-110 transition-transform duration-1000">
                        <svg class="w-64 h-64" fill="currentColor" viewBox="0 0 24 24"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"></path></svg>
                    </div>
                </div>
            </div>

            <!-- Footer Compliance -->
            <div class="mt-16 text-center">
                <p class="text-[10px] font-black text-brand-300 uppercase tracking-widest italic group">
                    Pengerjaan Review Max 1x24 Jam. 
                    <a href="https://wa.me/XXXXXXXXXX" target="_blank" class="text-primary-600 hover:text-brand-950 transition-colors border-b-2 border-primary-50 hover:border-brand-950 ml-2">Monitor Via WhatsApp →</a>
                </p>
            </div>
        </div>
    </div>
</x-app-layout>
