// ARTICLE detail page — le ?id=N e renderiza post correspondente function ArticleApp() { const [lang, setLang] = useLang(); const t = mergeT(lang); const bp = t.blog_page; const params = new URLSearchParams(window.location.search); const id = parseInt(params.get("id") || "0", 10); const post = bp.posts[id]; const heroImgs = [ "https://images.unsplash.com/photo-1556909114-f6e7ad7d3136?w=1600&q=85&auto=format&fit=crop", "https://images.unsplash.com/photo-1600585154340-be6161a56a0c?w=1600&q=85&auto=format&fit=crop", "https://images.unsplash.com/photo-1581094794329-c8112a89af12?w=1600&q=85&auto=format&fit=crop", "https://images.unsplash.com/photo-1620626011761-996317b8d101?w=1600&q=85&auto=format&fit=crop", "https://images.unsplash.com/photo-1505691938895-1758d7feb511?w=1600&q=85&auto=format&fit=crop", "https://images.unsplash.com/photo-1552321554-5fefe8c9ef14?w=1600&q=85&auto=format&fit=crop", ]; if (!post) { return ( <>

{lang === "en" ? "Article not found" : "Artículo no encontrado"}

{lang === "en" ? "← Back to Blog" : "← Volver al Blog"}

); } // Body placeholder (pode ser ajustado depois adicionando "body" em cada post no i18n-pages.js) const defaultBody = post.body || (lang === "en" ? [ `${post.excerpt}`, `In Austin's competitive remodeling market, every detail matters. ${post.title} is more than just a project — it's an opportunity to elevate how your home looks, feels, and functions.`, `At Prospec & Design Remodeling, we approach each ${post.cat ? post.cat.toLowerCase() : "project"} with the same level of care: clear timelines, honest pricing, and craftsmanship that lasts. Our team has handled dozens of projects across Austin metro — from kitchen overhauls in Westlake to full-home builds in Cedar Park.`, `What separates a great remodel from a mediocre one is preparation. Before we touch a single wall, we walk through your space, understand how you live, and identify the practical wins. Sometimes the most impactful change isn't the most expensive one.`, `Materials matter too. We source from trusted local suppliers — never the cheapest, always the best value for your budget. Hardwood from Texas mills, fixtures with real warranties, finishes that will look as good in 10 years as the day we install them.`, `If you're considering a ${post.cat ? post.cat.toLowerCase() : "project"} for your Austin home, we'd love to talk. No pressure, no sales pitch — just a free consultation to understand your goals and tell you honestly what's possible.`, ] : [ `${post.excerpt}`, `En el competitivo mercado de remodelación de Austin, cada detalle cuenta. ${post.title} es más que un proyecto — es una oportunidad de elevar cómo se ve, se siente y funciona tu hogar.`, `En Prospec & Design Remodeling, abordamos cada ${post.cat ? post.cat.toLowerCase() : "proyecto"} con el mismo nivel de cuidado: cronogramas claros, precios honestos y artesanía que perdura. Nuestro equipo ha manejado decenas de proyectos en el área metropolitana de Austin — desde renovaciones de cocina en Westlake hasta construcciones completas en Cedar Park.`, `Lo que separa una gran remodelación de una mediocre es la preparación. Antes de tocar una sola pared, recorremos tu espacio, entendemos cómo vives e identificamos las mejoras prácticas. A veces el cambio más impactante no es el más caro.`, `Los materiales también importan. Compramos de proveedores locales confiables — nunca el más barato, siempre el mejor valor para tu presupuesto. Maderas de molinos de Texas, accesorios con garantías reales, acabados que se verán tan bien en 10 años como el día que los instalamos.`, `Si estás considerando ${post.cat ? "un " + post.cat.toLowerCase() : "un proyecto"} para tu hogar en Austin, nos encantaría conversar. Sin presión, sin discurso de ventas — solo una consulta gratuita para entender tus metas y decirte honestamente qué es posible.`, ]); return ( <>
{lang === "en" ? "By" : "Por"} {post.author} · {post.date} · {post.read}
{post.title}
{defaultBody.map((para, i) => (

{para}

))}
{/* Outros posts (sugestões) */}

{lang === "en" ? "Read more" : "Leer más"}

{bp.posts .map((p, i) => ({ p, i })) .filter(({ i }) => i !== id) .slice(0, 3) .map(({ p, i }) => ( {p.title}
{p.cat} · {p.date}

{p.title}

{p.excerpt}

{p.author} · {p.read}
))}
); } ReactDOM.createRoot(document.getElementById("app")).render();