/* global React, CONTENT */ const { useState, useEffect, useRef } = React; // ============= EXTERNAL LINKS ============= const URL_DISTRIBUTOR = 'https://enrollment.unicity.com/c/POLSKI'; const URL_SHOP = 'https://unicity.link/ad1e21faba'; const URL_CALL = 'https://calendar.google.com/calendar/u/0/appointments/schedules/AcZssZ0YH-YrMm8ViaATKiQ_LglFrD1AGpDCkxSofrMYPECks6qxHOPE70QCtOJduxlTT-judrBppnzq'; const extProps = { target: '_blank', rel: 'noopener noreferrer' }; // ============= ICONS (brand style: circular line icons) ============= function BIcon({ name, size = 56, color }) { const paths = { flask: <>, globe: <>, shield: , people: <>, }; return (
{paths[name] || paths.flask}
); } // Original circular infinity-style mark (NOT Unicity logo) function BrandMark({ size = 28, color }) { return ( ); } // ============= LANG BAR (floating) ============= function LangBar({ lang, setLang }) { return (
Unicity
); } // ============= NAV ============= function Nav({ lang, setLang }) { const [scrolled, setScrolled] = useState(false); const t = CONTENT[lang]; useEffect(() => { const onScroll = () => setScrolled(window.scrollY > 40); window.addEventListener('scroll', onScroll); onScroll(); return () => window.removeEventListener('scroll', onScroll); }, []); return ( ); } // ============= HERO ============= function Hero({ lang }) { const t = CONTENT[lang].hero; return (
{t.badge}

{t.h1Main} {t.h1Sub}

{t.lede}

{t.stats.map((s, i) => (
{s.num} {s.label}
))}
); } // ============= WHO WE ARE ============= function Who({ lang }) { const t = CONTENT[lang].who; return (
{t.eyebrow}

{t.h2}
{t.h2Italic}

{t.p1}

{t.facts.map((f, i) => (
{f.title}
{f.desc}
))}
); } // ============= PROBLEM ============= function Problem({ lang }) { const t = CONTENT[lang].problem; return (
{t.eyebrow}

{t.h2}
{t.h2Italic}

{t.p1}

{t.p2}

{t.stats.map((s, i) => (
{s.source}
{s.num}
{s.label}
))}
); } // ============= PRODUCTS ============= function Products({ lang }) { const t = CONTENT[lang].products; return (
{t.eyebrow}

{t.h2}
{t.h2Italic}

{t.p}

); } function ProductCard({ data, image, href, reveal, coral }) { return (
{data.name}
{data.name}®
{data.when}

{data.tag}

    {data.list.map((item, i) => (
  • 0{i + 1} {item}
  • ))}
{data.flavorsLabel}: {data.flavors.map(f => {f})}
); } // ============= DAILY RHYTHM ============= function Rhythm({ lang }) { const t = CONTENT[lang].rhythm; const [active, setActive] = useState(0); const sectionRef = useRef(null); const timerRef = useRef(null); useEffect(() => { const section = sectionRef.current; if (!section) return; const io = new IntersectionObserver((entries) => { entries.forEach(e => { if (e.isIntersecting) { if (!timerRef.current) { timerRef.current = setInterval(() => { setActive(a => (a + 1) % t.steps.length); }, 2600); } } else { if (timerRef.current) { clearInterval(timerRef.current); timerRef.current = null; } } }); }, { threshold: 0.3 }); io.observe(section); return () => { io.disconnect(); if (timerRef.current) clearInterval(timerRef.current); }; }, [t.steps.length]); const progressPct = (active / (t.steps.length - 1)) * 100; const certs = ['Halal', 'Kosher', 'Gluten Free', 'GMP Certified', 'LGC Informed Choice', 'Clean Label', '3rd Party Tested']; return (
{t.eyebrow}

{t.h2}

{t.p}

{t.steps.map((s, i) => (
{ if (timerRef.current) { clearInterval(timerRef.current); timerRef.current = null; } setActive(i); }} >
{s.time}
{s.title}
{s.desc}
))}
{certs.map(c => {c})}
); } // ============= VIDEOS (Instagram embeds) ============= const YT_PLAYLIST_ID = 'PLGXYTCmhclCt59z6ohURiZ8JZN178IuIq'; const YT_FIRST_VIDEO = 'Dq-076yCRDE'; function VideoCard({ v, i }) { const [playing, setPlaying] = useState(false); // Each card opens the playlist, each starting at its own index const embedSrc = `https://www.youtube.com/embed/${YT_FIRST_VIDEO}?list=${YT_PLAYLIST_ID}&index=${i + 1}&autoplay=1&rel=0&modestbranding=1`; const thumbSrc = `https://i.ytimg.com/vi/${YT_FIRST_VIDEO}/hqdefault.jpg`; return (
{playing ? (