// services-page.jsx: /services/ page root. Copy comes from services-data.js (+ content.js).
// Each service is a "scene": colour-blocked torn paper, taped reel playing a real clip, polaroid,
// spinning sticker badge, sticker deliverables and a film-strip storyboard for the process.
// One Engine loop reveals scenes (data-in), drives parallax (--py) and lights the lead words.
// Needs hero-fx.js, engine.js, ui-shared.jsx, service-shared.jsx (Collage, Chips, Storyboard, Finale), site-chrome.jsx.
// Per-scene look. reel = clip id in hero-fx.js (plays in the taped card), note = handwritten aside.
const SCENES = [
{ interest: 'UGC', reel: 'sephora', note: 'scripted, shot + edited by me', bg: 'var(--bg)' },
{ interest: 'Event coverage', reel: 'nyx', note: 'next day delivery', bg: 'color-mix(in oklab, var(--sun) 30%, var(--bg))' },
{ interest: 'Wedding coverage', reel: 'jude', note: 'every happy tear, kept', bg: 'color-mix(in oklab, var(--pop) 40%, var(--bg))' },
{ interest: 'Travel collaboration', reel: 'hotel-tramonto', note: 'make them want to book', bg: 'color-mix(in oklab, var(--blue) 15%, var(--bg))' },
];
function Scene({ svc, idx }) {
const sc = SCENES[idx], flip = idx % 2 === 1, num = String(idx + 1).padStart(2, '0');
const lm = svc.desc.match(/^(.+?[.!?])(\s|$)/), lead = lm ? lm[1] : svc.desc;
const before = svc.name.replace(svc.nameEm, '').trim();
const short = (SERVICES_HERO[idx] || {}).short || svc.name.toLowerCase();
return (
{before}
{svc.nameEm}
{svc.longDesc}
);
}
const SceneM = React.memo(Scene);
// Floating viewfinder dock: shows which scene you are in, jumps between them.
function Dock() {
const [st, setSt] = React.useState({ on: false, i: 0 });
React.useEffect(() => Engine.add(() => {
const els = Engine.qa(document, '[data-scene]'); if (!els.length) return;
const vh = innerHeight, f = els[0].getBoundingClientRect(), l = els[els.length - 1].getBoundingClientRect();
const on = f.top < vh * 0.55 && l.bottom > vh * 0.45;
let i = 0; els.forEach((el, k) => { if (el.getBoundingClientRect().top < vh * 0.5) i = k; });
setSt((s) => (s.on === on && s.i === i ? s : { on, i }));
}), []);
return (
);
}
function App() {
const rootRef = React.useRef(null);
useSceneEngine(rootRef);
return (
<>
{SERVICES_DATA.map((svc, i) => )}
>
);
}
ReactDOM.createRoot(document.getElementById('root')).render();