// Milfers · App root — scroll reveal observer
function App() {
  React.useEffect(() => {
    const obs = new IntersectionObserver((entries) => {
      entries.forEach(e => { if (e.isIntersecting) e.target.classList.add('is-in'); });
    }, { threshold: 0.15, rootMargin: '0px 0px -50px 0px' });
    document.querySelectorAll('.reveal').forEach(el => obs.observe(el));
    return () => obs.disconnect();
  }, []);

  return (
    <>
      <Header />
      <Hero />
      <ReservaModal />
      {/* ticker traducido por idioma (sin tildes — tipografía display) */}
      <Ticker alt={false} words={window.MF_T.ticker.a} />
      <AboutSection />
      <MenuSection />
      <CheckerStrip ruby={false} />
      <Ticker alt={true} words={window.MF_T.ticker.b} />
      <MaduracionSection />
      <AlfabegaCard />
      <ReviewsSection />
      <ReservaSection />
      <Footer />
      <CartaModal />
      <LegalLayer />
      <WhatsAppFab />
    </>
  );
}

const root = ReactDOM.createRoot(document.getElementById('root'));
root.render(<App />);
