<?php $__env->startSection('title', 'Invoice & Receipt Templates'); ?>

<?php $__env->startSection('content'); ?>
<div class="max-w-4xl mx-auto space-y-6">
    <div class="flex items-center justify-between">
        <div>
            <h1 class="text-xl font-bold text-slate-900 dark:text-white">Invoice & Thermal Receipt Templates</h1>
            <p class="text-xs text-slate-500">Configure bilingual Arabic/English invoice layouts, POS thermal receipt paper sizes, and terms.</p>
        </div>
        <a href="<?php echo e(route('app.settings.billing.index')); ?>" class="px-4 py-2 bg-slate-200 dark:bg-slate-700 text-slate-700 dark:text-slate-200 font-semibold text-xs rounded-xl">Back to Billing</a>
    </div>

    <form action="<?php echo e(route('app.settings.invoice_design.update')); ?>" method="POST" class="bg-white dark:bg-slate-800 rounded-3xl p-6 border border-slate-200 dark:border-slate-700/60 shadow-sm space-y-6 text-xs">
        <?php echo csrf_field(); ?>

        <!-- Invoice Template (Requirements 35-36) -->
        <div class="space-y-4">
            <h3 class="font-bold text-slate-900 dark:text-white uppercase tracking-wider text-xs border-b border-slate-100 dark:border-slate-700 pb-2">A4 / A5 Invoice Template Settings</h3>

            <div class="grid grid-cols-1 md:grid-cols-2 gap-4">
                <div>
                    <label class="block font-semibold mb-1">Company Name in Arabic *</label>
                    <input type="text" name="arabic_company_name" dir="rtl" value="<?php echo e($invoiceSetting->arabic_company_name ?? 'مركز المدينة للطباعة والخدمات'); ?>" placeholder="اسم الشركة بالعربية" class="w-full px-3 py-2 bg-slate-50 dark:bg-slate-900 border border-slate-300 dark:border-slate-700 rounded-xl font-bold">
                </div>

                <div>
                    <label class="block font-semibold mb-1">Terms & Conditions</label>
                    <textarea name="terms_and_conditions" rows="2" placeholder="Government fees are non-refundable after application submission..." class="w-full p-3 bg-slate-50 dark:bg-slate-900 border border-slate-300 dark:border-slate-700 rounded-xl"><?php echo e($invoiceSetting->terms_and_conditions); ?></textarea>
                </div>
            </div>
        </div>

        <!-- POS Thermal Receipt Settings (Requirement 37) -->
        <div class="space-y-4">
            <h3 class="font-bold text-slate-900 dark:text-white uppercase tracking-wider text-xs border-b border-slate-100 dark:border-slate-700 pb-2">POS Thermal Receipt Settings</h3>

            <div class="grid grid-cols-1 md:grid-cols-2 gap-4">
                <div>
                    <label class="block font-semibold mb-1">Receipt Paper Size</label>
                    <select name="receipt_size" class="w-full px-3 py-2 bg-slate-50 dark:bg-slate-900 border border-slate-300 dark:border-slate-700 rounded-xl font-bold">
                        <option value="80mm_thermal" <?php echo e(($receiptSetting->receipt_size ?? '') === '80mm_thermal' ? 'selected' : ''); ?>>80mm Thermal Paper (Standard POS)</option>
                        <option value="58mm_thermal" <?php echo e(($receiptSetting->receipt_size ?? '') === '58mm_thermal' ? 'selected' : ''); ?>>58mm Thermal Paper (Mini POS)</option>
                        <option value="a4" <?php echo e(($receiptSetting->receipt_size ?? '') === 'a4' ? 'selected' : ''); ?>>A4 Standard Page</option>
                    </select>
                </div>

                <div>
                    <label class="block font-semibold mb-1">Receipt Header / Welcome Text</label>
                    <input type="text" name="header_text" value="<?php echo e($receiptSetting->header_text ?? 'Thank you for choosing Al Madina Typing Center'); ?>" class="w-full px-3 py-2 bg-slate-50 dark:bg-slate-900 border border-slate-300 dark:border-slate-700 rounded-xl">
                </div>
            </div>
        </div>

        <div class="flex justify-end pt-4 border-t border-slate-100 dark:border-slate-700">
            <button type="submit" class="px-6 py-2.5 bg-sky-600 hover:bg-sky-700 text-white font-bold rounded-xl shadow-sm">Save Print Templates</button>
        </div>
    </form>
</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\typingcenter\resources\views\tenant\settings\billing\design.blade.php ENDPATH**/ ?>