<div class="container mt-4">
    <div class="d-flex justify-content-between align-items-center mb-4">
        <h2><i class="bi bi-list-task"></i> All Tasks</h2>
        <div>
           
        <a href="<?= BASE_URL ?>/lead/index" class="btn btn-secondary">
            <i class="bi bi-arrow-left"></i> Back to Leads
        </a>  
        </div>
       
    </div>
    <div class=" mt-5">
    <h2><i class="bi bi-upload me-2"></i> Import Leads from Excel</h2>
    
    <?php if (!empty($error)): ?>
        <div class="alert alert-danger"><?= htmlspecialchars($error) ?></div>
    <?php elseif (!empty($success)): ?>
        <div class="alert alert-success"><?= htmlspecialchars($success) ?></div>
    <?php endif; ?>

    <form method="post" enctype="multipart/form-data" action="<?= BASE_URL ?>/LeadController/import">
        <div class="mb-3">
            <label for="excel_file" class="form-label fw-semibold">Select Excel File (.xlsx)</label>
            <input type="file" name="excel_file" id="excel_file" accept=".xlsx" class="form-control shadow-sm" required>
        </div>
        <button type="submit" class="btn btn-primary shadow-sm">
            <i class="bi bi-arrow-bar-up"></i> Upload and Import
        </button>
    </form>
</div>
</div>
