/* 70 · the worm: the invisible hand (module.worm). A fixed layer over the page that takes no pointer; only the bait
   itself can be touched. The thread is half a pixel and faint, so the hand is felt, not seen. The worm wears the
   brand rose with a fuzz of its softer shade; its fuzz turns once a beat and it blinks every two, so it stays in
   phase with every other loop on the page */
.rw-worm{position:fixed;inset:0;width:100%;height:100%;z-index:30;pointer-events:none;display:block;overflow:visible}
.rw-worm.is-done{visibility:hidden}
.rw-worm__thread{stroke:var(--mute);stroke-width:.5;stroke-linecap:round;opacity:.38}
.rw-worm__bait{pointer-events:auto;cursor:pointer;outline:none}
.rw-worm__hit{fill:transparent}
.rw-worm__ring{fill:none;stroke:var(--rose);stroke-width:1.2;opacity:0;transition:opacity var(--t1)}
.rw-worm__bait:focus-visible .rw-worm__ring{opacity:1}

/* the fuzz: round dashes round each segment make the fringe; sliding the dashes along makes the fur seem to twist.
   One dash period is 2.1, so a shift of 8.4 lands on the same picture and the loop has no seam */
.rw-worm__fuzz{fill:none;stroke:var(--rose-soft);stroke-width:2.4;stroke-linecap:round;stroke-dasharray:.6 1.5;opacity:.85;
  animation:rw-worm-fuzz var(--rw-beat) linear infinite;transition:opacity var(--t1)}
.rw-worm__bait:hover .rw-worm__fuzz{opacity:1}
@keyframes rw-worm-fuzz{to{stroke-dashoffset:-8.4}}

/* one tube: the rims sit under every fill, so only the silhouette is outlined; the sheen is a soft light down one
   side that rounds it */
.rw-worm__rim{fill:var(--rose-deep)}
.rw-worm__seg{fill:var(--rose)}
.rw-worm__sheen{fill:none;stroke:color-mix(in srgb,var(--rose) 40%,#fff);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;opacity:.55}
.rw-worm__eye{fill:var(--rose-dark)}
.rw-worm__eyes{transform-box:fill-box;transform-origin:center;animation:rw-worm-blink calc(var(--rw-beat) * 2) linear infinite}
@keyframes rw-worm-blink{0%,95%,100%{scale:1 1}97%{scale:1 .15}}

/* the phone's hand (Round 14, built for fools): the worm's head peeks up from the bottom edge beside "Free cards";
   it bobs once a beat and slides away as the deck nears */
.rw-worm-cue{position:fixed;left:50%;bottom:max(12px,env(safe-area-inset-bottom));z-index:30;display:flex;align-items:center;gap:8px;
  translate:-50% 0;padding:6px 14px 6px 8px;border-radius:999px;background:var(--rose);color:#fff;text-decoration:none;
  font:600 14px/1 system-ui,sans-serif;box-shadow:0 6px 18px -6px var(--rose-deep);transition:translate .4s,opacity .4s;
  animation:rw-worm-cue-bob var(--rw-beat) ease-in-out infinite}
.rw-worm-cue.is-done{translate:-50% 160%;opacity:0;pointer-events:none}
.rw-worm-cue__head{position:relative;width:22px;height:22px;border-radius:50%;background:var(--rose-soft);box-shadow:0 0 0 2px var(--rose-deep)}
.rw-worm-cue__head i{position:absolute;top:9px;width:4px;height:4px;border-radius:50%;background:var(--rose-dark)}
.rw-worm-cue__head i:first-child{left:5px}.rw-worm-cue__head i:last-child{right:5px}
.rw-worm-cue__text::after{content:" ↓"}
.rw-worm-cue:focus-visible{outline:2px solid var(--rose-deep);outline-offset:3px}
@keyframes rw-worm-cue-bob{0%,100%{margin-bottom:0}50%{margin-bottom:5px}}

@media (prefers-reduced-motion:reduce){.rw-worm__fuzz,.rw-worm__eyes,.rw-worm-cue{animation:none}}
@media print{.rw-worm,.rw-worm-cue{display:none}}
