<?php
require_once 'config/database.php';
$stmt = $pdo->prepare("SELECT * FROM pages WHERE slug = 'histoire-patrimoine'");
$stmt->execute();
$page = $stmt->fetch();
$content = $page ? $page['content'] : 'Contenu non trouvé.';
$title = $page ? $page['title'] : 'Histoire et Patrimoine';

include 'includes/header.php';
?>

<main class="min-h-screen py-16">
    <div class="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8">
        <h2 class="font-serif text-3xl md:text-4xl font-bold text-alsace-red mb-8 border-b-2 border-alsace-red pb-4">
            <?php echo htmlspecialchars($title); ?>
        </h2>
        <div class="bg-white rounded-xl shadow-md p-8 border border-gray-100 prose max-w-none">
            <?php echo $content; ?>
        </div>
    </div>
</main>

<?php include 'includes/footer.php'; ?>
