<?php require __DIR__ . '/../layouts/header.php'; $lang=current_lang(); ?>
<div class="container">
  <h4 class="mb-3"><i class="fa-solid fa-book-open me-2"></i><?= e($lang==='ar'?'وقائع المؤتمر':'Conference Proceedings') ?></h4>

  <div class="card border-0 shadow-sm">
    <div class="card-body">
      <div class="table-responsive">
        <table class="table align-middle">
          <thead><tr><th>#</th><th><?= e($lang==='ar'?'العنوان':'Title') ?></th><th>DOI</th><th><?= e($lang==='ar'?'تاريخ النشر':'Published') ?></th></tr></thead>
          <tbody>
          <?php foreach(($rows??[]) as $r): ?>
            <tr>
              <td><?= e((string)$r['id']) ?></td>
              <td class="fw-bold"><?= e($lang==='ar'?(string)$r['title_ar']:(string)$r['title_en']) ?></td>
              <td class="text-muted"><?= e((string)($r['doi']??'')) ?></td>
              <td class="text-muted"><?= e((string)($r['published_at']??'')) ?></td>
            </tr>
          <?php endforeach; ?>
          <?php if(empty($rows)): ?><tr><td colspan="4" class="text-center text-muted py-4">—</td></tr><?php endif; ?>
          </tbody>
        </table>
      </div>
    </div>
  </div>
</div>
<?php require __DIR__ . '/../layouts/footer.php'; ?>
