<?php
if ( ! defined( 'ABSPATH' ) ) {
	exit;
}
$avi_lang = 'fr';
$is_fr    = true;

$avi_meta_title = 'Feuille de route produit — Avision';
$avi_meta_desc  = 'Ce que nous avons livré, ce que nous construisons et ce qui arrive ensuite.';
$avi_schema_json = array(
	'@context' => 'https://schema.org',
	'@type'    => 'WebPage',
	'name'     => 'Feuille de route produit — Avision',
	'url'      => 'https://avision.org/fr/feuille-de-route/',
);

if ( ! class_exists( 'Avision_Page_Template' ) ) {
	require_once AVISION_PLUGIN_DIR . 'includes/class-avision-page-template.php';
}

$hero = array();

Avision_Page_Template::render(
	'roadmap',
	$hero,
	static function () use ( $avi_schema_json ) {
		$timeline = array(
			array(
				'version' => 'v9.0',
				'text'    => 'Lancement production complet · Homologation API GBP · OAuth B2C + B2B · Guardian Vagues 1 et 2 en ligne',
			),
			array(
				'version' => 'v8.0',
				'text'    => 'Agency Fleet Dashboard · Facturation wholesale en masse · Dynamic Report Builder · Intégration AppSumo LTD',
			),
			array(
				'version' => 'v7.0',
				'text'    => 'Moteur AVI Intelligence · Base de connaissances RAG · QI 100 % · Trilingue EN/FR/ES',
			),
			array(
				'version' => 'v6.0',
				'text'    => 'Stripe complet · Guardian Mode 9 boucliers · Growth Radar · Fil Google Updates',
			),
			array(
				'version' => 'v5.0',
				'text'    => 'Pages marketing B2C + B2B · Tunnels tarifs · Demo Dashboard · Parcours audit local',
			),
			array(
				'version' => 'v1.0',
				'text'    => 'Fondations · Architecture plugin modulaire · Backend IA · Schéma base de données',
			),
		);
		?>
		<div class="avi-roadmap-page">
			<style>
				.avi-roadmap-page { background: #0A1628; color: #ffffff; font-family: inherit; line-height: 1.65; }
				.avi-roadmap-page * { box-sizing: border-box; }
				.avi-roadmap-page__inner { max-width: 1100px; margin: 0 auto; padding: 0 24px; }
				.avi-roadmap-page__hero { background: #0A1628; padding: 80px 0 40px; text-align: center; }
				.avi-roadmap-page__hero h1 { margin: 0 0 16px; font-size: 2.5rem; line-height: 1.15; font-weight: 800; color: #ffffff; }
				.avi-roadmap-page__hero p { margin: 0; max-width: 640px; margin-left: auto; margin-right: auto; font-size: 1.12rem; color: #94a3b8; }
				.avi-roadmap-page__columns { background: #0A1628; padding: 0 0 64px; }
				.avi-roadmap-page__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
				.avi-roadmap-page__card { background: #0f1e35; border-radius: 16px; padding: 32px; }
				.avi-roadmap-page__card h2 { margin: 0 0 20px; font-size: 1.2rem; font-weight: 800; color: #ffffff; }
				.avi-roadmap-page__badge { display: inline-block; margin-bottom: 20px; padding: 6px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.02em; }
				.avi-roadmap-page__badge--live { background: #1a3a1a; color: #4ade80; }
				.avi-roadmap-page__badge--progress { background: #1a2a3a; color: #60a5fa; }
				.avi-roadmap-page__badge--next { background: #2a1a3a; color: #c084fc; }
				.avi-roadmap-page__list { list-style: none; margin: 0; padding: 0; }
				.avi-roadmap-page__list li { position: relative; padding: 0 0 14px 22px; font-size: 0.98rem; line-height: 1.55; color: #ffffff; }
				.avi-roadmap-page__list li:last-child { padding-bottom: 0; }
				.avi-roadmap-page__list li::before { content: "✦"; position: absolute; left: 0; top: 0; font-weight: 700; }
				.avi-roadmap-page__list--amber li::before { color: #F59E0B; }
				.avi-roadmap-page__list--violet li::before { color: #6C3FC5; }
				.avi-roadmap-page__list--muted li { color: #94a3b8; }
				.avi-roadmap-page__list--muted li::before { color: #94a3b8; }
				.avi-roadmap-page__history { background: #0A1628; padding: 60px 0 0; }
				.avi-roadmap-page__history h2 { margin: 0 0 12px; text-align: center; font-size: 1.85rem; font-weight: 800; color: #ffffff; }
				.avi-roadmap-page__history-sub { margin: 0 0 40px; text-align: center; color: #94a3b8; font-size: 1rem; }
				.avi-roadmap-page__timeline { position: relative; max-width: 720px; margin: 0 auto; padding: 0 0 8px; }
				.avi-roadmap-page__timeline::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; background: #6C3FC5; transform: translateX(-50%); }
				.avi-roadmap-page__entry { position: relative; display: flex; align-items: flex-start; gap: 16px; padding: 0 0 28px  calc(50% + 20px); }
				.avi-roadmap-page__entry:last-child { padding-bottom: 0; }
				.avi-roadmap-page__dot { position: absolute; left: 50%; top: 6px; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: #6C3FC5; flex-shrink: 0; }
				.avi-roadmap-page__entry-body { min-width: 0; }
				.avi-roadmap-page__version { color: #F59E0B; font-weight: 700; font-size: 18px; line-height: 1.3; }
				.avi-roadmap-page__sep { color: #6C3FC5; }
				.avi-roadmap-page__desc { color: #ffffff; font-size: 15px; opacity: 0.9; line-height: 1.55; }
				.avi-roadmap-page__footer { background: #0A1628; padding: 40px 0 80px; text-align: center; font-size: 14px; color: #94a3b8; }
				@media (max-width: 1024px) {
					.avi-roadmap-page__grid { grid-template-columns: repeat(2, 1fr); }
					.avi-roadmap-page__hero h1 { font-size: 2.15rem; }
				}
				@media (max-width: 768px) {
					.avi-roadmap-page__hero { padding: 56px 0 32px; }
					.avi-roadmap-page__hero h1 { font-size: 1.85rem; }
					.avi-roadmap-page__grid { grid-template-columns: 1fr; }
					.avi-roadmap-page__columns { padding-bottom: 48px; }
					.avi-roadmap-page__history { padding-top: 48px; }
					.avi-roadmap-page__timeline { padding-left: 24px; }
					.avi-roadmap-page__timeline::before { left: 11px; transform: none; }
					.avi-roadmap-page__entry { padding: 0 0 24px 20px; }
					.avi-roadmap-page__dot { left: 11px; margin-left: -6px; }
				}
				@media (max-width: 480px) {
					.avi-roadmap-page__inner { padding: 0 16px; }
					.avi-roadmap-page__card { padding: 24px 20px; }
					.avi-roadmap-page__hero h1 { font-size: 1.55rem; }
					.avi-roadmap-page__history h2 { font-size: 1.55rem; }
				}
			</style>

			<section class="avi-roadmap-page__hero" aria-labelledby="avi-roadmap-hero-title">
				<div class="avi-roadmap-page__inner">
					<h1 id="avi-roadmap-hero-title">Ce que nous construisons</h1>
					<p>Livré, en cours et à venir — mis à jour au fil de l'eau.</p>
				</div>
			</section>

			<section class="avi-roadmap-page__columns" aria-label="Colonnes feuille de route">
				<div class="avi-roadmap-page__inner">
					<div class="avi-roadmap-page__grid">
						<article class="avi-roadmap-page__card">
							<h2>✅ En ligne aujourd'hui</h2>
							<span class="avi-roadmap-page__badge avi-roadmap-page__badge--live">En ligne</span>
							<ul class="avi-roadmap-page__list avi-roadmap-page__list--amber">
								<li>Guardian Mode — 9 boucliers actifs</li>
								<li>Growth Radar — suivi hebdo et quotidien des mots-clés</li>
								<li>Agency Fleet Dashboard — actions en masse, facturation wholesale</li>
								<li>AVI Intelligence — coach IA B2C + moteur flotte B2B</li>
								<li>API Google Business Profile — intégration officielle</li>
								<li>Liens de reporting client en lecture seule</li>
								<li>Grey Label — branding agence</li>
								<li>Fil Google Updates — dernières règles GBP</li>
								<li>Trilingue — anglais, français, espagnol</li>
							</ul>
						</article>
						<article class="avi-roadmap-page__card">
							<h2>🔄 En cours</h2>
							<span class="avi-roadmap-page__badge avi-roadmap-page__badge--progress">En cours</span>
							<ul class="avi-roadmap-page__list avi-roadmap-page__list--violet">
								<li>Territory Map — visualisez votre zone de domination locale, rue par rue</li>
								<li>UPSKILL Academy — modules de formation SEO local structurés</li>
								<li>AVI Knowledge Expansion — enrichissement continu de la base AVI avec règles GBP, insights sectoriels et mises à jour terrain</li>
								<li>Programme associations — accès et tarifs dédiés</li>
							</ul>
						</article>
						<article class="avi-roadmap-page__card">
							<h2>🔜 Prochainement</h2>
							<span class="avi-roadmap-page__badge avi-roadmap-page__badge--next">À venir</span>
							<ul class="avi-roadmap-page__list avi-roadmap-page__list--muted">
								<li>White Label — remplacement complet de la marque pour les agences</li>
								<li>Multi-établissements B2C — plusieurs fiches depuis un seul compte</li>
								<li>Programme de parrainage</li>
								<li>Langues supplémentaires</li>
							</ul>
						</article>
					</div>
				</div>
			</section>

			<section class="avi-roadmap-page__history" aria-labelledby="avi-roadmap-history-title">
				<div class="avi-roadmap-page__inner">
					<h2 id="avi-roadmap-history-title">Comment nous en sommes arrivés là</h2>
					<p class="avi-roadmap-page__history-sub">Chaque version livrée est un engagement tenu.</p>
					<div class="avi-roadmap-page__timeline">
						<?php foreach ( $timeline as $entry ) : ?>
							<div class="avi-roadmap-page__entry">
								<span class="avi-roadmap-page__dot" aria-hidden="true"></span>
								<div class="avi-roadmap-page__entry-body">
									<p class="avi-roadmap-page__desc">
										<span class="avi-roadmap-page__version"><?php echo esc_html( $entry['version'] ); ?></span>
										<span class="avi-roadmap-page__sep"> — </span>
										<?php echo esc_html( $entry['text'] ); ?>
									</p>
								</div>
							</div>
						<?php endforeach; ?>
					</div>
					<p class="avi-roadmap-page__history-sub" style="margin-top:48px;margin-bottom:0;">634 000+ lignes de code propriétaire, construites en 4 mois par un fondateur solo — le moteur derrière les 9 boucliers Guardian, le coach IA trilingue et Growth Radar.</p>
				</div>
			</section>

			<section class="avi-roadmap-page__footer" aria-label="Note feuille de route">
				<div class="avi-roadmap-page__inner">
					<p>Cette feuille de route reflète nos priorités actuelles et peut évoluer. Dernière mise à jour : mai 2026.</p>
				</div>
			</section>
		</div>
		<script type="application/ld+json"><?php echo wp_json_encode( $avi_schema_json, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE ); ?></script>
		<?php
	}
);
