
Long shadow letters
Text, Scroll, 3D
Scroll inside the preview
A scroll animation in the premium style of product pieces: the dark glass card with the monthly plan of a made-up investing app, Halden, 300 euros a month for twenty years. Scrolling down the years go by from 2026 to 2046: the mint line of the value grows over the dashed lilac line of the deposits, the space between them, the growth, fills with a gradient, the cursor walks with the year on a pill that rolls digit by digit, three milestones pop on the curve on a spring and the portfolio slowly moves from stocks to bonds. At the end the plan starts.
A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN. The React and Vue tabs hold the same demo as a ready component, which switches its animations off when it leaves the page.
<!doctype html>
<!--
"Investment plan chart" from Animorio · https://animorio.com
License: free on your own sites and your clients’ sites, paid work included.
Not for resale, redistribution, templates or code collections · https://animorio.com/en/license/
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Halden monthly plan</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<!-- the monthly plan of a made-up investing app, Halden, on a dark glass card. The stage sticks while you scroll and
the scroll is the calendar of the plan: twenty years go by, the value line grows over the line of what you put
in, the year rolls on a pill, the milestones pop on the curve, the mix of the portfolio slides from stocks to
bonds as the goal gets near. At the end the plan starts. -->
<main>
<section class="years" data-years>
<div class="stage" data-stage>
<div class="light light--a" data-light-a aria-hidden="true"></div>
<div class="light light--b" data-light-b aria-hidden="true"></div>
<div class="grain" aria-hidden="true"></div>
<div class="frame" data-frame>
<article class="card" data-card>
<span class="card__glow" aria-hidden="true"></span>
<span class="card__rim" aria-hidden="true"></span>
<header class="head">
<span class="head__mark" aria-hidden="true">
<svg viewBox="0 0 16 16"><path d="M3 12.5l3.4-4 2.6 2.4L13 4.5"/><path d="M9.6 4.5H13v3.4"/></svg>
</span>
<div class="head__text">
<p class="head__title">Halden</p>
<p class="muted">Monthly plan · Balanced</p>
</div>
<span class="chip">€300<span class="muted"> / month</span></span>
</header>
<div class="value">
<p class="value__label muted">Projected value</p>
<p class="value__num" data-value>€1,000</p>
<p class="value__split">
<span class="split split--dep"><span class="muted">Deposits</span> <b data-dep>€1,000</b></span>
<span class="split split--grow"><span class="muted">Growth</span> <b data-grow>+€0</b></span>
</p>
</div>
<div class="chart" data-chart>
<div class="chart__plot" data-plot>
<span class="gl" data-gl style="--at:0.3333"><em>€50k</em></span>
<span class="gl" data-gl style="--at:0.6667"><em>€100k</em></span>
<span class="gl" data-gl style="--at:1"><em>€150k</em></span>
<span class="gl gl--base" data-gl style="--at:0"></span>
<svg class="chart__svg" viewBox="0 0 400 160" preserveAspectRatio="none" aria-hidden="true">
<defs>
<linearGradient id="grow" x1="0" y1="0" x2="0" y2="1">
<stop offset="0" stop-color="var(--mint)" stop-opacity="0.42"/>
<stop offset="1" stop-color="var(--mint)" stop-opacity="0.04"/>
</linearGradient>
<linearGradient id="dep" x1="0" y1="0" x2="0" y2="1">
<stop offset="0" stop-color="var(--lilac)" stop-opacity="0.26"/>
<stop offset="1" stop-color="var(--lilac)" stop-opacity="0.03"/>
</linearGradient>
</defs>
<path class="area area--dep" data-area-dep d=""/>
<path class="area area--grow" data-area-grow d=""/>
<path class="ln ln--dep" data-ln-dep d=""/>
<path class="ln ln--val" data-ln-val d=""/>
</svg>
<span class="ms" data-ms="10000"><span class="ms__tick"></span><span class="ms__tag">First €10k</span></span>
<span class="ms" data-ms="50000"><span class="ms__tick"></span><span class="ms__tag">€50k</span></span>
<span class="ms ms--goal" data-ms="120000"><span class="ms__tick"></span><span class="ms__tag">
<svg viewBox="0 0 16 16" aria-hidden="true"><path d="M4 8.4l2.6 2.6L12 5.4"/></svg>Goal</span></span>
<span class="cursor" data-cursor aria-hidden="true">
<span class="cursor__line"></span>
<span class="cursor__pt" data-pt></span>
<span class="pill" data-pill>
<span class="dg"><span class="dg__strip" data-dg><b>0</b><b>1</b><b>2</b><b>3</b><b>4</b><b>5</b><b>6</b><b>7</b><b>8</b><b>9</b></span></span><span class="dg"><span class="dg__strip" data-dg><b>0</b><b>1</b><b>2</b><b>3</b><b>4</b><b>5</b><b>6</b><b>7</b><b>8</b><b>9</b></span></span><span class="dg"><span class="dg__strip" data-dg><b>0</b><b>1</b><b>2</b><b>3</b><b>4</b><b>5</b><b>6</b><b>7</b><b>8</b><b>9</b></span></span><span class="dg"><span class="dg__strip" data-dg><b>0</b><b>1</b><b>2</b><b>3</b><b>4</b><b>5</b><b>6</b><b>7</b><b>8</b><b>9</b></span></span>
</span>
</span>
</div>
<div class="axis muted" aria-hidden="true"><span>2026</span><span>2031</span><span>2036</span><span>2041</span><span>2046</span></div>
</div>
<div class="mix">
<div class="mix__bar" aria-hidden="true">
<span class="seg seg--a" data-seg="0"></span>
<span class="seg seg--b" data-seg="1"></span>
<span class="seg seg--c" data-seg="2"></span>
</div>
<p class="mix__legend">
<span>Stocks <b data-pc="0">80%</b></span>
<span>Bonds <b data-pc="1">15%</b></span>
<span>Cash <b data-pc="2">5%</b></span>
</p>
</div>
<footer class="foot">
<div class="goal">
<p class="goal__row"><span class="muted" data-goal-word>Goal</span><b>€120,000</b></p>
<span class="goal__track"><span class="goal__fill" data-goal-fill></span></span>
</div>
<button class="btn" type="button" data-btn aria-pressed="false">
<span class="btn__fill" data-btn-fill aria-hidden="true"></span>
<span class="btn__face">
<span class="btn__words" data-btn-words>Start plan</span>
<svg class="btn__icon" viewBox="0 0 16 16" aria-hidden="true">
<path data-arrow d="M3.5 8h8.6M8.6 4.4L12.2 8l-3.6 3.6"/>
<path class="btn__check" data-check pathLength="1" d="M3.4 8.4l3 3 6.2-6.6"/>
</svg>
</span>
</button>
</footer>
</article>
</div>
</div>
</section>
<p class="sr" aria-live="polite" data-live></p>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/ScrollTrigger.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/lenis@1.3.26/dist/lenis.min.js"></script>
<script src="script.js"></script>
</body>
</html>Change values, colours and text with the controls and watch the animation respond live. Or write in the code yourself. Then download the folder with your changes.
87 values to change
With the Animorio connector, Claude Code, ChatGPT, Cursor or VS Code take it from here, guide included, and fit it into your project. Paste this request:
Take “Investment plan chart” from Animorio and fit it into my siteThe scroll drives a single GSAP timeline with ScrollTrigger and scrub: it carries a number from 0 to 240, the months from 2026 to 2046. The plan is worked out once at the start, month by month, with compound interest: on every update the month is read, even halfway, by interpolating between two.
The two lines and the two areas are SVG paths rebuilt on every update up to the current month, one point every two months: the growth area goes forward along the value line and back along the deposits line. The viewBox does not keep its proportions and the lines have vector-effect: non-scaling-stroke, so they stay thin at every size.
The cursor and its point sit at a fraction of the chart, width and height, so nothing needs recomputing on resize. Each milestone finds at the start the month the value reaches it and sits there; the scroll only decides when it is there, its entrance is a timed spring that can run backwards.
The year pill is made of four strips of digits: when the year changes, each column rolls on its own with back.out, the units a beat after the tens. Near the two edges the pill slides inwards so it never leaves the chart.
The bar is three pieces in a flex row: their shares, from 80/15/5 to 50/40/10 on a soft curve, become each one's flex-grow, and the percentages below update with them.
| Name | File | Default | What it changes |
|---|---|---|---|
RIDE | script.js | 1 | How much scroll the twenty years take: 2 is twice as long. |
MONTHLY | script.js | 300 | The euros put in every month. |
RATE | script.js | 6 | The plan's yearly return, in percent. |
ROLL | script.js | 0.5 | The seconds the digits of the year take to roll. |
POP | script.js | 2.2 | How far a milestone passes its size before it settles: 0 none. |
GLOW | script.js | 1 | How strong the two lights behind the card are. |
For the landing page of an investing app, an online bank, a pension fund or a savings plan: the section that tells, as you scroll, what a few euros a month become in twenty years and ends on the button to get started.
The same animation with adapted sizes: the value, the chart, the portfolio bar and the button are sized on the height too and the whole card fits in the box; under 360 pixels wide the deposits line goes away and the growth stays.
No long scroll and no movement: the card fades in with the twenty years already drawn, the milestones in place, the goal reached and the portfolio at 50/40/10; the button changes with a fade.
GSAP 3.15.0, ScrollTrigger 3.15.0, Lenis 1.3.26, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 11 KB; the libraries: GSAP + ScrollTrigger 45 KB, Lenis 5.3 KB.
Tested on 3 November 2026
Use it in your own projects and in your clients’ projects. Do not resell it or redistribute it as is. GSAP stays under its own Standard license. Full license.
Support Animorio
Animorio stays free thanks to the people who support it. If you like, buy us a coffee: it helps us make the next animations.
You asked for
We made it for you: it’s in the library, with the preview, the Playground and the code to copy.
An animation you can’t find, or a site to take apart in the journal: tell us which. We pick the next ones from here.
With your account’s email and password.
or with your email
You’re signed in as .
With your account, you can download the zip of every animation and every pack, for free.