﻿<!-- عرض رسائل الخطأ والنجاح -->

@if ($errors->any())
    <div class="alert alert-danger alert-dismissible fade show alert-persistent" role="alert" style="margin-bottom: 20p;">
        <strong>⚠️ حدثت أخطاء:</strong>
        <ul style="margin-bottom: 0;">
            @foreach ($errors->all() as $error)
                <li>{{ $error }}</li>
            @endforeach
        </ul>
        <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
    </div>
@endif

@if (session('success'))
    <div class="alert alert-success alert-dismissible fade show alert-auto-dismiss" role="alert">
        <strong>✅ نجح:</strong> {{ session('success') }}
        <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
    </div>
@endif

@if (session('error'))
    <div class="alert alert-danger alert-dismissible fade show alert-persistent" role="alert">
        <strong>❌ خطأ:</strong> {!! session('error') !!}
        <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
    </div>
@endif