@extends('layouts.app')

@section('title', 'Submission Successful')

@section('content')
<section class="py-24">
    <div class="max-w-md mx-auto px-4 sm:px-6 lg:px-8 text-center">
        <div class="w-20 h-20 bg-green-100 rounded-full flex items-center justify-center mx-auto mb-6">
            <svg class="w-10 h-10 text-green-600" fill="none" stroke="currentColor" viewBox="0 0 24 24"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 13l4 4L19 7"/></svg>
        </div>
        <h1 class="text-3xl font-bold text-gray-900 mb-4">Submission Successful!</h1>
        
        @if(session('submission_code'))
        <div class="bg-gray-50 rounded-xl p-6 mb-6">
            <p class="text-sm text-gray-500 mb-2">Your Submission Code</p>
            <p class="text-2xl font-bold text-primary-600">{{ session('submission_code') }}</p>
            <p class="text-sm text-gray-500 mt-4">Please save this code to check your submission status.</p>
        </div>
        @endif

        @if(session('message'))
        <p class="text-gray-600 mb-6">{{ session('message') }}</p>
        @else
        <p class="text-gray-600 mb-6">Thank you for your submission. We will review it and notify you via email at <strong>{{ session('email') }}</strong>.</p>
        @endif
         <p class="text-gray-600 mb-6">Please check your inbox or spam folder for the confirmation email.</p> ⁠
        <div class="flex flex-col sm:flex-row gap-4">
            <a href="{{ route('submission.check') }}" class="flex-1 py-3 bg-primary-600 text-white font-semibold rounded-lg hover:bg-primary-700 transition">
                Check Status
            </a>
            <a href="{{ route('home') }}" class="flex-1 py-3 border border-gray-300 text-gray-700 font-semibold rounded-lg hover:bg-gray-50 transition">
                Back to Home
            </a>
        </div>
    </div>
</section>
@endsection
