/* global React */ const { useEffect, useRef, useState } = React; /* ============================================================ Cinematic Use Cases — scroll-driven family vignettes 8 scenes, each 100vh, alternating left/right image+artifact, with image-slot drop targets so real family photos land here. ============================================================ */ function CinematicUseCases() { const scenes = [ { id: "cycles", n: "01", eyebrow: "For her", head: "Her cycle. On her terms.", sub: "Track periods, symptoms, and patterns privately. Arogya links them to the rest of her health — so cycles aren't a footnote anymore.", photo: { id: "scene-cycles", placeholder: "Drop a photo — young woman, soft window light" }, side: "right", Artifact: CycleArtifact, }, { id: "meds", n: "02", eyebrow: "For Amma & Appa", head: "Every pill. Every dose. Even the ones grandma forgets to mention.", sub: "Forward a prescription, snap a strip, ask 'what are mom's medicines right now?' — Arogya knows.", photo: { id: "scene-meds", placeholder: "Drop a photo — close-up of medicines on a wooden table" }, side: "left", Artifact: MedicationArtifact, }, { id: "vaccines", n: "03", eyebrow: "For the kids", head: "Never miss a booster again.", sub: "Childhood schedule, travel shots, boosters at school age — all tracked, all reminded.", photo: { id: "scene-vaccines", placeholder: "Drop a photo — child at a clinic, warm light" }, side: "right", Artifact: VaccineArtifact, }, { id: "visit", n: "04", eyebrow: "Memory you can search", head: "What did the cardiologist say last March?", sub: "Every doctor visit captured — who, when, what was advised, what to follow up on. Searchable forever.", photo: { id: "scene-visit", placeholder: "Drop a photo — doctor's hands with a stethoscope" }, side: "left", Artifact: VisitArtifact, }, { id: "labs", n: "05", eyebrow: "Trends, not paper", head: "Appa's cholesterol over five years, in one chart.", sub: "Lab reports aren't files. They're a story over time. Arogya reads every PDF and plots the line.", photo: { id: "scene-labs", placeholder: "Drop a photo — elderly father reading the newspaper" }, side: "right", Artifact: LabArtifact, }, { id: "traditional", n: "06", eyebrow: "All systems, one memory", head: "Your vaidya, your homeopath, your GP — one timeline.", sub: "Indian families don't follow one system of medicine. Arogya remembers all of them, side by side.", photo: { id: "scene-traditional", placeholder: "Drop a photo — Ayurvedic herbs, mortar & pestle" }, side: "left", Artifact: TraditionalArtifact, }, { id: "symptoms", n: "07", eyebrow: "The invisible 80%", head: "That recurring cough since last winter.", sub: "Symptoms, home remedies, supplements, sleep — everything between doctor visits, finally captured.", photo: { id: "scene-symptoms", placeholder: "Drop a photo — woman pouring herself tea by a window" }, side: "right", Artifact: SymptomsArtifact, }, { id: "emergency", n: "08", eyebrow: "When seconds matter", head: "Everything a doctor needs, in ten seconds.", sub: "Blood group, allergies, current medicines, last hospital — one tap, one screen. Share with anyone you trust.", photo: { id: "scene-emergency", placeholder: "Drop a photo — family hands together" }, side: "left", Artifact: EmergencyArtifact, }, ]; return (
What Arogya remembers — in real life

Eight things every family is already tracking. Just not in one place.

Scroll through the moments that show up in real family life — and what Arogya does with them.

{scenes.map((s, i) => ( ))}
); } /* ============================================================ Scene shell ============================================================ */ function Scene({ idx, total, n, eyebrow, head, sub, photo, side, Artifact }) { const ref = useRef(null); const [active, setActive] = useState(false); useEffect(() => { const obs = new IntersectionObserver( ([entry]) => setActive(entry.intersectionRatio > 0.35), { threshold: [0, 0.35, 0.6, 1] } ); if (ref.current) obs.observe(ref.current); return () => obs.disconnect(); }, []); const photoFirst = side === "left"; return (
{/* counter rail */}
{n} / {String(total).padStart(2, "0")}
{/* photo side */}
{/* copy + artifact side */}
{eyebrow}

{head}

{sub}

); } function PhotoFrame({ photoId, placeholder }) { return (
{/* image-slot fills the frame; user drags a real photo onto it */}
); } /* ============================================================ ARTIFACTS — small product-mocks per scene ============================================================ */ const cardSx = { background: "var(--c-card)", border: "1px solid var(--c-line)", borderRadius: 18, padding: 20, boxShadow: "var(--shadow-sm)", }; function CycleArtifact() { // Cycle ring + day chips const days = ["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]; const states = ["light","mid","mid","heavy","mid","light","fertile"]; const colorMap = { light: "color-mix(in oklab, var(--c-accent) 30%, transparent)", mid: "color-mix(in oklab, var(--c-accent) 55%, transparent)", heavy: "var(--c-accent)", fertile:"color-mix(in oklab, var(--c-brand) 70%, transparent)", }; return (
Cycle · this month
Day 14 · fertile window
{/* ring */} 14 of 28
{days.map((d, i) => (
{d}
))}
cramps · day 1-2 regular
); } function MedicationArtifact() { const meds = [ { name: "Telmisartan", dose: "40 mg", time: "Morning", color: "var(--c-brand)" }, { name: "Metformin", dose: "500 mg", time: "After meals", color: "var(--c-slate)" }, { name: "Atorvastatin",dose: "10 mg", time: "Night", color: "var(--c-accent)" }, { name: "Vitamin D3", dose: "60K IU/wk", time: "Sunday", color: "#9b8cc9" }, ]; return (
Amma · current medicines
4 active
{meds.map((m, i) => (
{m.name}
{m.dose}
{m.time} ·
))}
Refill: Telmisartan runs out in 5 days
); } function VaccineArtifact() { const rows = [ { age: "Birth", v: "BCG, OPV, Hep B", done: true }, { age: "6 wks", v: "DTwP, Hib, IPV", done: true }, { age: "9 mo", v: "MMR", done: true }, { age: "5 yrs", v: "MMR booster", done: false, due: "Sep 14" }, { age: "10 yrs", v: "Tdap booster", done: false, due: "2027" }, ]; return (
Riya · vaccination schedule
1 due soon
{rows.map((r, i) => (
{r.age} {r.v} {r.done ? "✓ done" : `due ${r.due}`}
))}
); } function VisitArtifact() { return (
Search · "what did Dr. Mehta say"
3 results
14 MAR · DR. ARJUN MEHTA · CARDIOLOGY
"BP under control on Telmisartan 40mg. Continue. Recheck lipid profile in 3 months. Walk 30 min daily. Reduce salt."
+ 2 older visits 1 follow-up due
); } function LabArtifact() { const pts = [180, 192, 205, 198, 218, 234]; const max = 250, min = 150; const norm = pts.map(v => ((v - min) / (max - min))); const w = 280, h = 100; const path = norm.map((v, i) => `${i === 0 ? "M" : "L"} ${(i / (pts.length-1)) * w} ${h - v * h}`).join(" "); return (
Appa · total cholesterol
↑ +30% over 5 yrs
desirable < 200 {norm.map((v, i) => ( ))} {["2021","2022","2023","2024","2025","2026"].map((yr, i) => ( {yr} ))}
Worth flagging to Dr. Mehta next month — trend is steadily up.
); } function TraditionalArtifact() { const lanes = [ { system: "Allopathy", color: "var(--c-brand)", events: [{ x: 10, l: "Cardio" }, { x: 50, l: "Lipid panel" }, { x: 88, l: "Refill" }] }, { system: "Ayurveda", color: "var(--c-accent)", events: [{ x: 22, l: "Vaidya" }, { x: 70, l: "Panchakarma" }] }, { system: "Homeopathy", color: "#9b8cc9", events: [{ x: 35, l: "Consult" }, { x: 80, l: "Refill" }] }, { system: "Yoga", color: "var(--c-slate)", events: [{ x: 5, l: "Daily" }, { x: 30, l: "" }, { x: 55, l: "" }, { x: 78, l: "" }] }, ]; return (
Appa · all systems · last 6 months
4 systems
{lanes.map((lane, i) => (
{lane.system}
{lane.events.map((e, j) => ( ))}
))}
JanMarMayJul
); } function SymptomsArtifact() { const entries = [ { d: "Last winter", t: "Dry cough · 3 weeks", note: "Tulsi-ginger kadha · helped" }, { d: "Mar 14", t: "Acidity · evenings", note: "Cut down coffee · noted" }, { d: "Apr 02", t: "Headache · 2 days", note: "Crocin · resolved" }, { d: "Last week", t: "Cough · same as last yr",note: "Pattern flagged → see GP?" }, ]; return (
Your symptom journal
recurring pattern
{entries.map((e, i) => (
{e.d}
{e.t}
{e.note}
))}
); } function EmergencyArtifact() { return (
EMERGENCY CARD · AMMA
SHARE LINK · 24H
Tap to share with the ER doctor, your sibling, or a neighbour. Link auto-expires.
); } function Stat({ k, v, full }) { return (
{k}
{v}
); } window.AroScenes = { CinematicUseCases, _artifacts: { CycleMini, MedsMini, VaccineMini, VisitMini, LabMini, TradMini, SymptomsMini, EmergencyMini } }; /* ============================================================ Mini artifacts — denser, lighter versions of the full mocks for use in CompactUseCases. ~150-180px tall, no headers. ============================================================ */ const miniSx = { background: "color-mix(in oklab, var(--c-bg-2) 50%, transparent)", border: "1px solid var(--c-line)", borderRadius: 12, padding: 12, fontSize: 12, }; function CycleMini() { return (
14
Day 14 of 28
fertile window · regular
{[0.3,0.6,0.6,1,0.6,0.3,0.5].map((v, i) => ( ))}
); } function MedsMini() { const meds = [ { n: "Telmisartan", t: "AM", c: "var(--c-brand)" }, { n: "Metformin", t: "AM/PM",c: "var(--c-slate)" }, { n: "Atorvastatin",t: "PM", c: "var(--c-accent)" }, ]; return (
{meds.map((m, i) => (
{m.n} {m.t}
))}
↻ Refill in 5 days
); } function VaccineMini() { const rows = [ { v: "MMR", done: true }, { v: "DTwP booster", done: true }, { v: "Tdap booster", done: false, due: "Sep 14" }, ]; return (
{rows.map((r, i) => (
{r.v} {r.done ? "✓" : `due ${r.due}`}
))}
); } function VisitMini() { return (
14 MAR · DR. MEHTA · CARDIO
"BP under control. Recheck lipids in 3 months. Walk 30 min daily."
); } function LabMini() { const pts = [180, 192, 205, 198, 218, 234]; const max = 250, min = 150, w = 200, h = 60; const norm = pts.map(v => ((v - min) / (max - min))); const path = norm.map((v, i) => `${i === 0 ? "M" : "L"} ${(i / (pts.length-1)) * w} ${h - v * h}`).join(" "); return (
Cholesterol · 5 yrs ↑ +30%
{norm.map((v, i) => ( ))} 2021 2026
); } function TradMini() { const lanes = [ { s: "Allopathy", c: "var(--c-brand)", d: [12, 45, 80] }, { s: "Ayurveda", c: "var(--c-accent)", d: [25, 70] }, { s: "Homeopathy", c: "#9b8cc9", d: [35, 75] }, ]; return (
{lanes.map((l, i) => (
{l.s}
{l.d.map((x, j) => ( ))}
))}
); } function SymptomsMini() { return (
Cough · this week recurring
Same pattern as last winter. Arogya flagged it — maybe time to see Dr. Rao.
{[0.2,0.4,0.8,0.6,0.3,0.5,0.7].map((v, i) => ( ))}
); } function EmergencyMini() { return (
EMERGENCY · AMMA · B+
Allergies
Penicillin, Sulfa
Conditions
HTN, T2 DM
); }