/* Relevel toolkit · stack-cards: the behaviour layer. The look lives in your own CSS (see demo.html). */
/* Always a flex column, so `gap` spaces the cards the same way stacked, plain (reduced motion) and without JS.
   Not a grid: in a grid each sticky card would be trapped in its own row. */
.rt-stack { display: flex; flex-direction: column; list-style: none; margin: 0; padding: 0; }
/* While stacking the items are sticky; the script sets each one's top. Never put overflow: hidden on an ancestor
   (it breaks sticky): use overflow: clip. */
.rt-stack.rt-stack-on > .rt-stack-item { position: sticky; }
.rt-stack-card { position: relative; }
/* The shade that dims a card as others cover it: colour it with --rt-stack-shade (the page background works well). */
.rt-stack-shade { position: absolute; inset: 0; z-index: 2; border-radius: inherit; background: var(--rt-stack-shade, #000); opacity: 0; pointer-events: none; }
.rt-stack-spacer { display: block; flex: none; margin: 0; padding: 0; list-style: none; }
