<?php $__template->layout('Layout.main'); ?>
<?php $__template->section('title'); ?>تسجيل رياضي — <?= e($member['full_name_ar']) ?><?php $__template->endSection(); ?>
<?php $__template->section('content'); ?>
<form method="POST" action="/members/<?= (int) $member['id'] ?>/sports">
    <?= csrf_field() ?>
    <div class="card" style="padding:20px;margin-bottom:20px;">
        <div style="display:grid;grid-template-columns:1fr 1fr;gap:15px;">
            <div class="form-group"><label class="form-label">اسم الرياضة <span style="color:#DC2626;">*</span></label><input type="text" name="sport_name" value="<?= e(old('sport_name')) ?>" class="form-input" required></div>
            <div class="form-group"><label class="form-label">اسم الاتحاد</label><input type="text" name="federation_name" value="<?= e(old('federation_name')) ?>" class="form-input"></div>
            <div class="form-group"><label class="form-label">رقم تسجيل الاتحاد</label><input type="text" name="federation_registration" value="<?= e(old('federation_registration')) ?>" class="form-input"></div>
            <div class="form-group"><label class="form-label">تاريخ التسجيل</label><input type="date" name="registration_date" value="<?= e(old('registration_date')) ?>" class="form-input"></div>
            <div class="form-group"><label class="form-label">سنوات الخدمة <span style="color:#DC2626;">*</span></label><input type="number" name="years_of_service" value="<?= e(old('years_of_service')) ?>" class="form-input" min="0" max="50" required><small style="color:#6B7280;">الحد الأدنى للتحويل لعضو عامل: 8 سنوات</small></div>
            <div class="form-group"><label class="form-label">أعلى مستوى تنافسي</label><input type="text" name="highest_competitive_level" value="<?= e(old('highest_competitive_level')) ?>" class="form-input"></div>
            <div class="form-group" style="grid-column:1/-1;"><label class="form-label">ملاحظات</label><textarea name="notes" class="form-textarea" rows="2"><?= e(old('notes')) ?></textarea></div>
        </div>
    </div>
    <button type="submit" class="btn btn-primary">تسجيل العضوية الرياضية</button>
    <a href="/members/<?= (int) $member['id'] ?>" class="btn btn-outline">إلغاء</a>
</form>
<?php $__template->endSection(); ?>