Files
hyperframes/docs/public/catalog/blocks/app-showcase.json
Miguel Ángel 536165b6ef feat(catalog): play the real composition on catalog pages (#3168)
* feat(catalog): play the real composition on catalog pages

Catalog previews were uploaded MP4s, published by hand to the CDN. Each page
now embeds the composition itself, running in <hyperframes-player>, so a
preview is the block rather than a recording of it.

The composition is delivered as JSON under docs/public/catalog, and the player
is mounted inside an iframe. Both are forced: the docs host publishes only JSON
and images out of docs/public, and its MDX renderer strips unknown custom
elements, so a player written into the page never reaches the DOM and an .html
payload 404s in production.

Assets are inlined as data URIs, which sidesteps the file-type restriction for
fonts, scripts and models alike. 164 of 168 items build a payload; the rest
keep their MP4 and say so.

* chore: rebuild docs preview

* chore: route isolation probe

* chore: drop the route isolation probe page

* chore: probe which asset types the docs host publishes

* refactor(catalog): host preview assets instead of inlining them

Fonts were being base64'd into every payload that used them, so a handful of
files cost tens of megabytes in the repository to say the same thing over and
over. Assets are now written once, content-addressed, under
docs/public/catalog/assets and linked.

Which types can be hosted was settled by fetching one file of each from a
deployed preview: woff2, wav, mp4, svg and the image formats are published,
glb is not. Types the host drops still travel inside the payload, because a
link that 404s is worse than a larger payload.

Also fixes the four type errors the scripts typecheck caught, all of them
unchecked index access on a split() result.

* refactor(catalog): share preview assets instead of repeating them

* style: format the asset module
2026-08-10 17:54:48 -04:00

1 line
33 KiB
JSON
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{"html":"<!doctype html>\n<html lang=\"en\">\n <head>\n <meta charset=\"UTF-8\" />\n <meta name=\"viewport\" content=\"width=1920, height=1080\" />\n <title>app-showcase</title>\n <style>\n * {\n margin: 0;\n padding: 0;\n box-sizing: border-box;\n }\n html,\n body {\n margin: 0;\n width: 1920px;\n height: 1080px;\n overflow: hidden;\n background-color: #0a0a0f;\n }\n </style>\n </head>\n <body>\n <div\n data-composition-id=\"app-showcase\"\n data-width=\"1920\"\n data-height=\"1080\"\n data-start=\"0\"\n data-duration=\"5.5\"\n >\n <!-- Background -->\n <div class=\"s3-bg\" id=\"s3Bg\"></div>\n <div class=\"s3-bg-glow\" id=\"s3BgGlow\"></div>\n\n <!-- Stage wrapper for ambient scale -->\n <div class=\"s3-stage\" id=\"s3Stage\">\n <!-- ═══════════════════════════════════════\n LEFT PHONE — Lifestyle / Motivational\n ═══════════════════════════════════════ -->\n <div class=\"s3-phone s3-phone-left\" id=\"s3PhoneLeft\">\n <div class=\"s3-bezel\">\n <div class=\"s3-notch\"></div>\n <div class=\"s3-screen s3-screen-left\">\n <!-- Abstract exercise shapes -->\n <div class=\"left-shapes\">\n <svg viewBox=\"0 0 304 400\" xmlns=\"http://www.w3.org/2000/svg\" fill=\"none\">\n <!-- Abstract running figure — geometric -->\n <circle cx=\"152\" cy=\"80\" r=\"28\" fill=\"#271f15\" opacity=\"0.15\" />\n <line\n x1=\"152\"\n y1=\"108\"\n x2=\"152\"\n y2=\"200\"\n stroke=\"#271f15\"\n stroke-width=\"6\"\n stroke-linecap=\"round\"\n opacity=\"0.15\"\n />\n <line\n x1=\"152\"\n y1=\"145\"\n x2=\"115\"\n y2=\"175\"\n stroke=\"#271f15\"\n stroke-width=\"6\"\n stroke-linecap=\"round\"\n opacity=\"0.15\"\n />\n <line\n x1=\"152\"\n y1=\"145\"\n x2=\"195\"\n y2=\"165\"\n stroke=\"#271f15\"\n stroke-width=\"6\"\n stroke-linecap=\"round\"\n opacity=\"0.15\"\n />\n <line\n x1=\"152\"\n y1=\"200\"\n x2=\"120\"\n y2=\"260\"\n stroke=\"#271f15\"\n stroke-width=\"6\"\n stroke-linecap=\"round\"\n opacity=\"0.15\"\n />\n <line\n x1=\"152\"\n y1=\"200\"\n x2=\"190\"\n y2=\"255\"\n stroke=\"#271f15\"\n stroke-width=\"6\"\n stroke-linecap=\"round\"\n opacity=\"0.15\"\n />\n <!-- Decorative arcs -->\n <path\n d=\"M60 300 Q152 240 244 300\"\n stroke=\"#e4fa72\"\n stroke-width=\"3\"\n fill=\"none\"\n opacity=\"0.5\"\n />\n <path\n d=\"M40 330 Q152 260 264 330\"\n stroke=\"#e4fa72\"\n stroke-width=\"2\"\n fill=\"none\"\n opacity=\"0.3\"\n />\n </svg>\n </div>\n <div class=\"left-bottom\">\n <div class=\"left-tagline\" id=\"s3Tagline\">Unleash Full Potential</div>\n <div class=\"left-cta\">START NOW</div>\n </div>\n </div>\n </div>\n </div>\n\n <!-- ═══════════════════════════════════════\n CENTER PHONE — Dashboard (Hero)\n ═══════════════════════════════════════ -->\n <div class=\"s3-phone s3-phone-center\" id=\"s3PhoneCenter\">\n <div class=\"s3-bezel\">\n <div class=\"s3-notch\"></div>\n <div class=\"s3-screen s3-screen-center\">\n <!-- Header -->\n <div class=\"center-header\">\n <div class=\"center-avatar\">JM</div>\n <div class=\"center-user-info\">\n <div class=\"center-name\">James Medrano</div>\n <div class=\"center-subtitle\">Premium Member</div>\n </div>\n <div class=\"center-bell\">\n <svg viewBox=\"0 0 20 20\" width=\"20\" height=\"20\" fill=\"none\">\n <path\n d=\"M10 2a5 5 0 00-5 5v3l-1.5 2.5h13L15 10V7a5 5 0 00-5-5z\"\n stroke=\"#7c857c\"\n stroke-width=\"1.4\"\n stroke-linejoin=\"round\"\n />\n <path\n d=\"M8 16.5a2 2 0 004 0\"\n stroke=\"#7c857c\"\n stroke-width=\"1.4\"\n stroke-linecap=\"round\"\n />\n <circle cx=\"14\" cy=\"5\" r=\"3\" fill=\"#e4fa72\" />\n </svg>\n </div>\n </div>\n\n <!-- Weekly Goal -->\n <div class=\"center-goal\">\n <div class=\"goal-label\">Weekly Goal</div>\n <div class=\"goal-ring-wrap\">\n <svg class=\"goal-ring\" viewBox=\"0 0 140 140\">\n <circle\n class=\"ring-track\"\n cx=\"70\"\n cy=\"70\"\n r=\"52\"\n fill=\"none\"\n stroke=\"#333\"\n stroke-width=\"10\"\n />\n <circle\n class=\"ring-fill\"\n id=\"s3Ring\"\n cx=\"70\"\n cy=\"70\"\n r=\"52\"\n fill=\"none\"\n stroke=\"#e4fa72\"\n stroke-width=\"10\"\n stroke-linecap=\"round\"\n transform=\"rotate(-90 70 70)\"\n />\n </svg>\n <div class=\"goal-count\">\n <span class=\"goal-num\">2</span>\n <span class=\"goal-sep\">/</span>\n <span class=\"goal-den\">3</span>\n </div>\n </div>\n <div class=\"goal-days\">\n <span class=\"day done\">M</span>\n <span class=\"day done\">T</span>\n <span class=\"day\">W</span>\n <span class=\"day\">T</span>\n <span class=\"day\">F</span>\n <span class=\"day\">S</span>\n <span class=\"day\">S</span>\n </div>\n </div>\n\n <!-- Your Progress -->\n <div class=\"center-progress\">\n <div class=\"progress-header\">\n <span class=\"progress-title\">Your Progress</span>\n <span class=\"progress-link\">See all</span>\n </div>\n <div class=\"progress-bars\">\n <div class=\"bar-row\">\n <div class=\"bar-icon\">\n <svg viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\">\n <path\n d=\"M8 2l1.5 3H13l-2.5 2 1 3L8 8.5 4.5 10l1-3L3 5h3.5z\"\n fill=\"#e4fa72\"\n />\n </svg>\n </div>\n <div class=\"bar-info\">\n <span class=\"bar-name\">Running</span>\n <span class=\"bar-val\">5.2 km</span>\n </div>\n <div class=\"bar-track\"><div class=\"bar-value bar-v1\" id=\"s3Bar1\"></div></div>\n </div>\n <div class=\"bar-row\">\n <div class=\"bar-icon\">\n <svg viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\">\n <circle cx=\"8\" cy=\"8\" r=\"5\" stroke=\"#e4fa72\" stroke-width=\"2\" />\n </svg>\n </div>\n <div class=\"bar-info\">\n <span class=\"bar-name\">Cycling</span>\n <span class=\"bar-val\">12.8 km</span>\n </div>\n <div class=\"bar-track\"><div class=\"bar-value bar-v2\" id=\"s3Bar2\"></div></div>\n </div>\n <div class=\"bar-row\">\n <div class=\"bar-icon\">\n <svg viewBox=\"0 0 16 16\" width=\"14\" height=\"14\" fill=\"none\">\n <rect\n x=\"3\"\n y=\"6\"\n width=\"10\"\n height=\"6\"\n rx=\"1\"\n stroke=\"#e4fa72\"\n stroke-width=\"1.5\"\n />\n <path d=\"M6 6V4a2 2 0 014 0v2\" stroke=\"#e4fa72\" stroke-width=\"1.5\" />\n </svg>\n </div>\n <div class=\"bar-info\">\n <span class=\"bar-name\">Strength</span>\n <span class=\"bar-val\">45 min</span>\n </div>\n <div class=\"bar-track\"><div class=\"bar-value bar-v3\" id=\"s3Bar3\"></div></div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <!-- ═══════════════════════════════════════\n RIGHT PHONE — Calories Data\n ═══════════════════════════════════════ -->\n <div class=\"s3-phone s3-phone-right\" id=\"s3PhoneRight\">\n <div class=\"s3-bezel\">\n <div class=\"s3-notch\"></div>\n <div class=\"s3-screen s3-screen-right\">\n <div class=\"right-header\">\n <div class=\"right-title\">Burned Calories</div>\n <div class=\"right-value\">740 <span class=\"right-unit\">kcal</span></div>\n </div>\n\n <div class=\"right-graph-wrap\">\n <svg class=\"right-graph\" viewBox=\"0 0 260 130\" xmlns=\"http://www.w3.org/2000/svg\">\n <!-- Grid lines -->\n <line\n x1=\"10\"\n y1=\"25\"\n x2=\"250\"\n y2=\"25\"\n stroke=\"#d9e0bc\"\n stroke-width=\"0.5\"\n opacity=\"0.5\"\n />\n <line\n x1=\"10\"\n y1=\"55\"\n x2=\"250\"\n y2=\"55\"\n stroke=\"#d9e0bc\"\n stroke-width=\"0.5\"\n opacity=\"0.5\"\n />\n <line\n x1=\"10\"\n y1=\"85\"\n x2=\"250\"\n y2=\"85\"\n stroke=\"#d9e0bc\"\n stroke-width=\"0.5\"\n opacity=\"0.5\"\n />\n <line\n x1=\"10\"\n y1=\"115\"\n x2=\"250\"\n y2=\"115\"\n stroke=\"#d9e0bc\"\n stroke-width=\"0.5\"\n opacity=\"0.5\"\n />\n <!-- Area fill -->\n <path\n class=\"graph-area\"\n id=\"s3GraphArea\"\n d=\"M10,105 L50,80 90,90 130,45 170,60 210,25 250,35 250,115 10,115 Z\"\n fill=\"#e4fa72\"\n opacity=\"0.15\"\n />\n <!-- Line -->\n <polyline\n class=\"graph-line\"\n id=\"s3GraphLine\"\n points=\"10,105 50,80 90,90 130,45 170,60 210,25 250,35\"\n fill=\"none\"\n stroke=\"#e4fa72\"\n stroke-width=\"2.5\"\n stroke-linecap=\"round\"\n stroke-linejoin=\"round\"\n />\n <!-- Dots -->\n <circle class=\"graph-dot\" cx=\"10\" cy=\"105\" r=\"3.5\" fill=\"#e4fa72\" />\n <circle class=\"graph-dot\" cx=\"50\" cy=\"80\" r=\"3.5\" fill=\"#e4fa72\" />\n <circle class=\"graph-dot\" cx=\"90\" cy=\"90\" r=\"3.5\" fill=\"#e4fa72\" />\n <circle class=\"graph-dot\" cx=\"130\" cy=\"45\" r=\"3.5\" fill=\"#e4fa72\" />\n <circle class=\"graph-dot\" cx=\"170\" cy=\"60\" r=\"3.5\" fill=\"#e4fa72\" />\n <circle class=\"graph-dot\" cx=\"210\" cy=\"25\" r=\"3.5\" fill=\"#e4fa72\" />\n <circle class=\"graph-dot\" cx=\"250\" cy=\"35\" r=\"3.5\" fill=\"#e4fa72\" />\n </svg>\n <div class=\"right-labels\">\n <span>Mon</span><span>Tue</span><span>Wed</span><span>Thu</span><span>Fri</span\n ><span>Sat</span><span>Sun</span>\n </div>\n </div>\n\n <div class=\"right-stats\">\n <div class=\"stat-pill\">\n <span class=\"stat-dot\" style=\"background: #e4fa72\"></span>\n <span class=\"stat-label\">Active</span>\n <span class=\"stat-num\">540</span>\n </div>\n <div class=\"stat-pill\">\n <span class=\"stat-dot\" style=\"background: #7c857c\"></span>\n <span class=\"stat-label\">Rest</span>\n <span class=\"stat-num\">200</span>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n\n <style>\n @import url(\"https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;700&display=swap\");\n\n [data-composition-id=\"app-showcase\"] {\n position: relative;\n width: 1920px;\n height: 1080px;\n overflow: hidden;\n font-family: \"DM Sans\", sans-serif;\n color: #271f15;\n }\n\n /* ── Background ── */\n [data-composition-id=\"app-showcase\"] .s3-bg {\n position: absolute;\n inset: 0;\n background: linear-gradient(160deg, #f1f2ec 0%, #e8ecda 40%, #f1f2ec 100%);\n }\n [data-composition-id=\"app-showcase\"] .s3-bg-glow {\n position: absolute;\n width: 900px;\n height: 900px;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n background: radial-gradient(circle, rgba(228, 250, 114, 0.18) 0%, transparent 70%);\n border-radius: 50%;\n }\n\n /* ── Stage ── */\n [data-composition-id=\"app-showcase\"] .s3-stage {\n position: absolute;\n inset: 0;\n transform-origin: center center;\n }\n\n /* ── Phones ── */\n [data-composition-id=\"app-showcase\"] .s3-phone {\n position: absolute;\n width: 320px;\n height: 650px;\n top: 215px;\n left: 800px;\n }\n [data-composition-id=\"app-showcase\"] .s3-phone-center {\n z-index: 30;\n }\n [data-composition-id=\"app-showcase\"] .s3-phone-left {\n z-index: 20;\n }\n [data-composition-id=\"app-showcase\"] .s3-phone-right {\n z-index: 20;\n }\n\n /* ── Bezel ── */\n [data-composition-id=\"app-showcase\"] .s3-bezel {\n width: 100%;\n height: 100%;\n border-radius: 42px;\n background: #271f15;\n padding: 8px;\n box-shadow:\n 0 24px 64px rgba(39, 31, 21, 0.35),\n 0 4px 16px rgba(39, 31, 21, 0.15);\n position: relative;\n overflow: hidden;\n }\n [data-composition-id=\"app-showcase\"] .s3-notch {\n position: absolute;\n top: 8px;\n left: 50%;\n transform: translateX(-50%);\n width: 100px;\n height: 26px;\n background: #271f15;\n border-radius: 0 0 18px 18px;\n z-index: 5;\n }\n\n /* ── Screens ── */\n [data-composition-id=\"app-showcase\"] .s3-screen {\n width: 100%;\n height: 100%;\n border-radius: 36px;\n overflow: hidden;\n position: relative;\n }\n\n /* Left screen */\n [data-composition-id=\"app-showcase\"] .s3-screen-left {\n background: linear-gradient(160deg, #d9e0bc 0%, #c8d4a0 50%, #b8c78a 100%);\n display: flex;\n flex-direction: column;\n justify-content: flex-end;\n }\n [data-composition-id=\"app-showcase\"] .left-shapes {\n position: absolute;\n top: 40px;\n left: 0;\n width: 100%;\n height: 400px;\n display: flex;\n align-items: center;\n justify-content: center;\n }\n [data-composition-id=\"app-showcase\"] .left-shapes svg {\n width: 200px;\n height: 280px;\n }\n [data-composition-id=\"app-showcase\"] .left-bottom {\n padding: 0 28px 40px;\n position: relative;\n z-index: 2;\n }\n [data-composition-id=\"app-showcase\"] .left-tagline {\n font-size: 28px;\n font-weight: 700;\n color: #271f15;\n line-height: 1.15;\n margin-bottom: 16px;\n letter-spacing: -0.02em;\n }\n [data-composition-id=\"app-showcase\"] .left-cta {\n display: inline-block;\n background: #271f15;\n color: #e4fa72;\n font-size: 13px;\n font-weight: 700;\n letter-spacing: 0.08em;\n padding: 10px 28px;\n border-radius: 24px;\n }\n\n /* Center screen */\n [data-composition-id=\"app-showcase\"] .s3-screen-center {\n background: #1a1a1a;\n padding: 42px 22px 22px;\n display: flex;\n flex-direction: column;\n gap: 18px;\n }\n\n [data-composition-id=\"app-showcase\"] .center-header {\n display: flex;\n align-items: center;\n gap: 10px;\n }\n [data-composition-id=\"app-showcase\"] .center-avatar {\n width: 40px;\n height: 40px;\n border-radius: 50%;\n background: linear-gradient(135deg, #e4fa72, #d9e0bc);\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 15px;\n font-weight: 700;\n color: #271f15;\n flex-shrink: 0;\n }\n [data-composition-id=\"app-showcase\"] .center-user-info {\n flex: 1;\n }\n [data-composition-id=\"app-showcase\"] .center-name {\n font-size: 18px;\n font-weight: 700;\n color: #f1f2ec;\n line-height: 1.2;\n }\n [data-composition-id=\"app-showcase\"] .center-subtitle {\n font-size: 12px;\n font-weight: 400;\n color: #7c857c;\n margin-top: 1px;\n }\n [data-composition-id=\"app-showcase\"] .center-bell {\n flex-shrink: 0;\n }\n\n /* Weekly Goal */\n [data-composition-id=\"app-showcase\"] .center-goal {\n background: #242424;\n border-radius: 20px;\n padding: 18px 16px;\n display: flex;\n flex-direction: column;\n align-items: center;\n gap: 12px;\n }\n [data-composition-id=\"app-showcase\"] .goal-label {\n font-size: 15px;\n font-weight: 500;\n color: #7c857c;\n align-self: flex-start;\n }\n [data-composition-id=\"app-showcase\"] .goal-ring-wrap {\n position: relative;\n width: 130px;\n height: 130px;\n }\n [data-composition-id=\"app-showcase\"] .goal-ring {\n width: 100%;\n height: 100%;\n }\n [data-composition-id=\"app-showcase\"] .ring-track {\n opacity: 0.3;\n }\n [data-composition-id=\"app-showcase\"] .goal-count {\n position: absolute;\n inset: 0;\n display: flex;\n align-items: center;\n justify-content: center;\n gap: 2px;\n }\n [data-composition-id=\"app-showcase\"] .goal-num {\n font-size: 36px;\n font-weight: 700;\n color: #e4fa72;\n }\n [data-composition-id=\"app-showcase\"] .goal-sep {\n font-size: 24px;\n font-weight: 400;\n color: #7c857c;\n margin: 0 2px;\n }\n [data-composition-id=\"app-showcase\"] .goal-den {\n font-size: 24px;\n font-weight: 400;\n color: #7c857c;\n }\n [data-composition-id=\"app-showcase\"] .goal-days {\n display: flex;\n gap: 8px;\n }\n [data-composition-id=\"app-showcase\"] .day {\n width: 28px;\n height: 28px;\n border-radius: 50%;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 11px;\n font-weight: 500;\n color: #7c857c;\n background: #1a1a1a;\n }\n [data-composition-id=\"app-showcase\"] .day.done {\n background: #e4fa72;\n color: #271f15;\n font-weight: 700;\n }\n\n /* Progress section */\n [data-composition-id=\"app-showcase\"] .center-progress {\n flex: 1;\n display: flex;\n flex-direction: column;\n gap: 12px;\n }\n [data-composition-id=\"app-showcase\"] .progress-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n }\n [data-composition-id=\"app-showcase\"] .progress-title {\n font-size: 15px;\n font-weight: 500;\n color: #f1f2ec;\n }\n [data-composition-id=\"app-showcase\"] .progress-link {\n font-size: 12px;\n font-weight: 400;\n color: #e4fa72;\n }\n [data-composition-id=\"app-showcase\"] .progress-bars {\n display: flex;\n flex-direction: column;\n gap: 12px;\n }\n [data-composition-id=\"app-showcase\"] .bar-row {\n display: flex;\n align-items: center;\n gap: 10px;\n }\n [data-composition-id=\"app-showcase\"] .bar-icon {\n width: 28px;\n height: 28px;\n border-radius: 8px;\n background: #2a2a2a;\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n }\n [data-composition-id=\"app-showcase\"] .bar-info {\n width: 70px;\n flex-shrink: 0;\n }\n [data-composition-id=\"app-showcase\"] .bar-name {\n display: block;\n font-size: 12px;\n font-weight: 500;\n color: #f1f2ec;\n line-height: 1.2;\n }\n [data-composition-id=\"app-showcase\"] .bar-val {\n display: block;\n font-size: 10px;\n font-weight: 400;\n color: #7c857c;\n }\n [data-composition-id=\"app-showcase\"] .bar-track {\n flex: 1;\n height: 8px;\n background: #2a2a2a;\n border-radius: 4px;\n overflow: hidden;\n }\n [data-composition-id=\"app-showcase\"] .bar-value {\n height: 100%;\n border-radius: 4px;\n background: #e4fa72;\n width: 0%;\n }\n\n /* Right screen */\n [data-composition-id=\"app-showcase\"] .s3-screen-right {\n background: #f1f2ec;\n padding: 42px 20px 24px;\n display: flex;\n flex-direction: column;\n gap: 14px;\n }\n [data-composition-id=\"app-showcase\"] .right-header {\n display: flex;\n flex-direction: column;\n gap: 4px;\n }\n [data-composition-id=\"app-showcase\"] .right-title {\n font-size: 14px;\n font-weight: 500;\n color: #7c857c;\n }\n [data-composition-id=\"app-showcase\"] .right-value {\n font-size: 40px;\n font-weight: 700;\n color: #271f15;\n line-height: 1;\n letter-spacing: -0.03em;\n }\n [data-composition-id=\"app-showcase\"] .right-unit {\n font-size: 20px;\n font-weight: 400;\n color: #7c857c;\n }\n\n [data-composition-id=\"app-showcase\"] .right-graph-wrap {\n flex: 1;\n display: flex;\n flex-direction: column;\n gap: 6px;\n }\n [data-composition-id=\"app-showcase\"] .right-graph {\n width: 100%;\n flex: 1;\n }\n [data-composition-id=\"app-showcase\"] .right-labels {\n display: flex;\n justify-content: space-between;\n padding: 0 6px;\n font-size: 10px;\n font-weight: 400;\n color: #7c857c;\n }\n\n [data-composition-id=\"app-showcase\"] .right-stats {\n display: flex;\n gap: 12px;\n }\n [data-composition-id=\"app-showcase\"] .stat-pill {\n display: flex;\n align-items: center;\n gap: 6px;\n background: #e8ecda;\n border-radius: 20px;\n padding: 8px 14px;\n }\n [data-composition-id=\"app-showcase\"] .stat-dot {\n width: 8px;\n height: 8px;\n border-radius: 50%;\n flex-shrink: 0;\n }\n [data-composition-id=\"app-showcase\"] .stat-label {\n font-size: 12px;\n font-weight: 400;\n color: #7c857c;\n }\n [data-composition-id=\"app-showcase\"] .stat-num {\n font-size: 13px;\n font-weight: 700;\n color: #271f15;\n }\n </style>\n\n <script src=\"https://cdn.jsdelivr.net/npm/gsap@3.14.2/dist/gsap.min.js\"></script>\n <script>\n (function () {\n var S = '[data-composition-id=\"app-showcase\"] ';\n window.__timelines = window.__timelines || {};\n var tl = gsap.timeline({ paused: true });\n\n // ── SVG setup ──\n var graphLine = document.querySelector(S + \"#s3GraphLine\");\n var graphLen = graphLine.getTotalLength();\n gsap.set(graphLine, { strokeDasharray: graphLen, strokeDashoffset: graphLen });\n\n var graphArea = document.querySelector(S + \"#s3GraphArea\");\n gsap.set(graphArea, { opacity: 0 });\n\n var graphDots = document.querySelectorAll(S + \".graph-dot\");\n gsap.set(graphDots, { opacity: 0, scale: 0 });\n\n var CIRC = 2 * 3.14159265 * 52;\n gsap.set(S + \"#s3Ring\", { strokeDasharray: CIRC, strokeDashoffset: CIRC });\n\n // ── Initial states ──\n gsap.set(S + \".s3-bg\", { opacity: 0 });\n gsap.set(S + \".s3-bg-glow\", { opacity: 0 });\n // Center phone: starts scaled down + hidden\n gsap.set(S + \"#s3PhoneCenter\", { opacity: 0, scale: 0.85 });\n // Side phones: start stacked behind center (same position), hidden\n gsap.set(S + \"#s3PhoneLeft\", { opacity: 0, x: 0, rotation: 0 });\n gsap.set(S + \"#s3PhoneRight\", { opacity: 0, x: 0, rotation: 0 });\n gsap.set(S + \".bar-value\", { width: \"0%\" });\n gsap.set(S + \"#s3Tagline\", { opacity: 0, y: 20 });\n gsap.set(S + \".left-cta\", { opacity: 0, y: 12 });\n\n // ════════════════════════════════════\n // BUILD PHASE (02s)\n // ════════════════════════════════════\n\n // Background\n tl.to(S + \".s3-bg\", { opacity: 1, duration: 0.8, ease: \"power1.out\" }, 0);\n tl.to(S + \".s3-bg-glow\", { opacity: 1, duration: 1.2, ease: \"power1.out\" }, 0.2);\n\n // Center phone — scales up first\n tl.to(\n S + \"#s3PhoneCenter\",\n {\n scale: 1,\n opacity: 1,\n duration: 0.7,\n ease: \"back.out(1.4)\",\n },\n 0.2,\n );\n\n // Side phones: opacity matches center (0.7s, back.out), fan starts at 0.1\n tl.to(S + \"#s3PhoneLeft\", { opacity: 1, duration: 0.7, ease: \"back.out(1.4)\" }, 0.3);\n tl.to(\n S + \"#s3PhoneLeft\",\n {\n x: -340,\n rotation: -12,\n duration: 1.2,\n ease: \"expo.out\",\n },\n 0.3,\n );\n\n tl.to(S + \"#s3PhoneRight\", { opacity: 1, duration: 0.7, ease: \"back.out(1.4)\" }, 0.4);\n tl.to(\n S + \"#s3PhoneRight\",\n {\n x: 340,\n rotation: 12,\n duration: 1.2,\n ease: \"expo.out\",\n },\n 0.4,\n );\n\n // ════════════════════════════════════\n // BREATHE PHASE (24s)\n // ════════════════════════════════════\n\n // Progress ring fills to 2/3\n tl.to(\n S + \"#s3Ring\",\n {\n strokeDashoffset: CIRC * (1 - 2 / 3),\n duration: 1.2,\n ease: \"circ.out\",\n },\n 1.8,\n );\n\n // Activity bars stagger in\n tl.to(S + \"#s3Bar1\", { width: \"75%\", duration: 0.8, ease: \"power3.out\" }, 2.1);\n tl.to(S + \"#s3Bar2\", { width: \"50%\", duration: 0.8, ease: \"power3.out\" }, 2.3);\n tl.to(S + \"#s3Bar3\", { width: \"90%\", duration: 0.8, ease: \"power3.out\" }, 2.5);\n\n // Graph line draws on\n tl.to(\n graphLine,\n {\n strokeDashoffset: 0,\n duration: 1.4,\n ease: \"sine.inOut\",\n },\n 2.0,\n );\n\n // Graph area fades in\n tl.to(graphArea, { opacity: 0.15, duration: 0.8, ease: \"power1.out\" }, 2.6);\n\n // Graph dots pop in\n tl.to(\n graphDots,\n {\n opacity: 1,\n scale: 1,\n duration: 0.3,\n ease: \"back.out(2)\",\n stagger: { each: 0.06, ease: \"power2.in\" },\n },\n 3.0,\n );\n\n // Tagline and CTA on left phone\n tl.to(\n S + \"#s3Tagline\",\n {\n opacity: 1,\n y: 0,\n duration: 0.6,\n ease: \"power2.out\",\n },\n 2.2,\n );\n tl.to(\n S + \".left-cta\",\n {\n opacity: 1,\n y: 0,\n duration: 0.5,\n ease: \"power2.out\",\n },\n 2.5,\n );\n\n // Ambient slow scale push\n tl.to(\n S + \"#s3Stage\",\n {\n scale: 1.02,\n duration: 3.5,\n ease: \"sine.inOut\",\n },\n 2.0,\n );\n\n // ════════════════════════════════════\n // RESOLVE PHASE (45.5s)\n // ════════════════════════════════════\n\n // Subtle glow pulse on lime accent elements\n tl.to(S + \".ring-fill\", { opacity: 0.65, duration: 0.6, ease: \"sine.inOut\" }, 4.0);\n tl.to(S + \".ring-fill\", { opacity: 1, duration: 0.6, ease: \"sine.inOut\" }, 4.6);\n\n tl.to(S + \".bar-value\", { opacity: 0.7, duration: 0.6, ease: \"sine.inOut\" }, 4.1);\n tl.to(S + \".bar-value\", { opacity: 1, duration: 0.6, ease: \"sine.inOut\" }, 4.7);\n\n tl.to(graphLine, { opacity: 0.65, duration: 0.6, ease: \"sine.inOut\" }, 4.05);\n tl.to(graphLine, { opacity: 1, duration: 0.6, ease: \"sine.inOut\" }, 4.65);\n\n window.__timelines[\"app-showcase\"] = tl;\n })();\n </script>\n </div>\n </body>\n</html>\n"}