/* Light comes from the cat's prop and stays in the photo coordinate system. */
.edge-ritual{position:absolute;inset:0;z-index:3;pointer-events:none;overflow:hidden}.edge-ritual[hidden]{display:none!important}
.edge-ritual__note{position:absolute;left:0;right:0;bottom:0;padding:24px 20px 12px;background:linear-gradient(transparent,#180e26eb 35%);box-sizing:border-box;color:#f5e8cb;display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:4px 14px}
.edge-ritual__title{grid-row:1 / span 2;font:400 20px/1.4 SimSun,serif;color:#ffe2a6;white-space:nowrap}.edge-ritual__note strong{font-size:13px;font-weight:500}.edge-ritual__note small{grid-column:2;color:#e1d2ea;font-size:11px;line-height:1.5}.edge-ritual__note button{grid-column:3;grid-row:1 / span 2;pointer-events:auto;min-height:44px;padding:8px 12px;background:transparent;border:0;color:#eed9ad;text-decoration:underline;text-underline-offset:4px;cursor:pointer;font:inherit;font-size:12px;white-space:nowrap}.edge-ritual__note button:focus-visible{outline:2px solid #f4dba4;border-radius:8px}
.palm-stage[data-edge-waiting=true] .palm-stage__controls,.palm-stage[data-edge-waiting=true] .palm-stage__hint,.palm-stage[data-edge-waiting=true] .palm-stage__status{visibility:hidden}.palm-stage[data-edge-waiting=true] .palm-stage__canvas{pointer-events:none}.palm-stage[data-edge-waiting=true] .palm-stage__canvas>image:first-of-type{filter:brightness(.82) saturate(.9)}
.edge-palm-spell__thread{stroke:#ffdf8f;stroke-width:3;stroke-linecap:round;stroke-dasharray:5 9;vector-effect:non-scaling-stroke;filter:drop-shadow(0 0 5px #ffd48b);animation:edge-light-flow 1.4s linear infinite}
.edge-palm-spell__sweep{stroke:#fff0b9;stroke-width:5;vector-effect:non-scaling-stroke;stroke-linecap:round;filter:drop-shadow(0 0 7px #edd0ff)}
.edge-palm-spell__seed{fill:#fff4c3;filter:drop-shadow(0 0 9px #ffe1ad)}.edge-palm-spell__lens circle{fill:#21123728;stroke:#f4d28d;stroke-width:2.5;filter:drop-shadow(0 0 8px #ebcbff)}.edge-palm-spell__lens path{fill:none;stroke:#ffe3a3;stroke-width:2}.edge-palm-spell__lens text{font:20px SimSun,serif;fill:#fff2c3;stroke:#29172c;stroke-width:2;paint-order:stroke fill}.edge-palm-spell__motes{fill:#fff1b3;filter:drop-shadow(0 0 5px #ffd57e)}
.edge-palm-spell[data-ritual="1"] .edge-palm-spell__thread{stroke:#eac7ff}.edge-palm-spell[data-ritual="2"] .edge-palm-spell__thread{stroke-dasharray:2 12;animation-direction:reverse}.edge-palm-spell[data-ritual="2"] .edge-palm-spell__lens text{fill:#f0d6ff}
.palm-stage[data-edge-waiting=true] .cat-performer[data-action=point] .cp-arm-right{animation:edge-cat-point 2s ease-in-out infinite;transform-origin:230px 370px}
.edge-ritual[data-quiet=true] *,.palm-stage[data-paused=true] .edge-palm-spell *{animation-play-state:paused!important}.palm-stage:has(.edge-ritual[data-quiet=true]) .cat-performer *,.palm-stage:has(.edge-ritual[data-quiet=true]) .edge-palm-spell *{animation-play-state:paused!important}
.palm-stage[data-reduced-motion=true] .edge-palm-spell *{animation:none!important}
@keyframes edge-light-flow{to{stroke-dashoffset:-56}}@keyframes edge-cat-point{0%,100%{transform:rotate(-10deg)}50%{transform:rotate(-22deg)}}
@media(max-width:650px){.edge-ritual__note{padding:22px 12px 8px;gap:3px 8px}.edge-ritual__title{font-size:15px}.edge-ritual__note strong{font-size:11px}.edge-ritual__note small{font-size:10px}.edge-ritual__note button{padding:6px;font-size:11px}}
@media(prefers-reduced-motion:reduce){.edge-palm-spell *{animation:none!important}}

/* Palm symbols and wandering fireflies accompany the waiting cat. */
.edge-palm-spell__thread{stroke:#edd0ff;stroke-width:2;stroke-dasharray:none;opacity:.42;filter:drop-shadow(0 0 8px #d5a6f1);animation:none}
.edge-palm-spell__sweep{stroke:#dec4f0;stroke-width:16;opacity:.35;filter:blur(7px);stroke-linecap:round}
.edge-palm-spell__seed{fill:#e6c2ff;opacity:.22;filter:blur(12px)}
.edge-palm-spell__lens .edge-palm-spell__palm{fill:#fff0b3;stroke:none;filter:drop-shadow(0 0 7px #ffdea0) drop-shadow(0 0 16px #e9bcff);animation:edge-palm-float 3.2s ease-in-out infinite}
.edge-palm-spell__lens .edge-palm-spell__spark{fill:#fff1bf;stroke:none;opacity:.9;animation:edge-palm-spark 2.6s ease-in-out infinite}
.edge-palm-spell__mist{transform-origin:0 0;animation:edge-mist-turn 12s linear infinite}.edge-palm-spell__mist ellipse,.edge-palm-spell__lens .edge-palm-spell__mist path{fill:none;stroke:#dcb7f4;stroke-width:4;opacity:.4;filter:blur(3px)}
.edge-palm-spell__motes{fill:#fff1bc;filter:drop-shadow(0 0 5px #ffd990) drop-shadow(0 0 10px #efbaff)}
.edge-palm-spell[data-ritual="1"] .edge-palm-spell__mist{animation-direction:reverse}.edge-palm-spell[data-ritual="1"] .edge-palm-spell__thread{stroke:#ffdca4}.edge-palm-spell[data-ritual="2"] .edge-palm-spell__thread{stroke-dasharray:none}.edge-palm-spell[data-ritual="2"] .edge-palm-spell__mist{animation-duration:18s}
@keyframes edge-palm-float{0%,100%{transform:translateY(0) rotate(-12deg)}50%{transform:translateY(-5px) rotate(8deg)}}@keyframes edge-palm-spark{0%,100%{opacity:.35}50%{opacity:1}}@keyframes edge-mist-turn{to{transform:rotate(360deg)}}
.edge-palm-spell[data-ritual="3"] .edge-palm-spell__mist{animation-duration:8s;stroke:#f3d4f0}.edge-palm-spell[data-ritual="4"] .edge-palm-spell__palm{animation-duration:5s}.edge-palm-spell[data-ritual="4"] .edge-palm-spell__motes{fill:#fff0bd}.edge-palm-spell[data-ritual="5"] .edge-palm-spell__mist{opacity:.35}.edge-palm-spell[data-ritual="5"] .edge-palm-spell__motes{fill:#dfd4ff;filter:drop-shadow(0 0 6px #c5b1ee)}.edge-palm-spell[data-ritual="6"] .edge-palm-spell__palm{opacity:.7;animation-duration:6s}.edge-palm-spell[data-ritual="6"] .edge-palm-spell__thread{opacity:.2}
.palm-companion__light ellipse{fill:#edd0fb;opacity:.28;filter:blur(8px)}.palm-companion__light path{fill:none;stroke:#edd4a2;stroke-width:1.4;opacity:.65;filter:drop-shadow(0 0 5px #e8d0fb)}
.palm-stage[data-companion="touch"] .cp-paw-right,.palm-stage[data-companion="stroke"] .cp-paw-right{animation:palm-companion-paw 2.1s ease-in-out infinite;transform-origin:296px 420px}.palm-stage[data-companion="listen"] .cp-head{animation:palm-companion-listen 4s ease-in-out infinite;transform-origin:150px 100px}
@keyframes palm-companion-paw{0%,100%{transform:rotate(-3deg)}50%{transform:rotate(5deg)}}@keyframes palm-companion-listen{0%,100%{transform:rotate(-3deg)}50%{transform:rotate(3deg)}}
.palm-stage[data-companion] .palm-stage__hint{visibility:hidden}

/* Each ritual has its own light character, while keeping the photograph readable. */
.edge-palm-spell[data-style=fireflies] .edge-palm-spell__palm{opacity:.3}.edge-palm-spell[data-style=fireflies] .edge-palm-spell__mist{opacity:.2}.edge-palm-spell[data-style=fireflies] .edge-palm-spell__motes{fill:#ffe5a2;filter:drop-shadow(0 0 7px #ffcc83)}
.edge-palm-spell[data-style=book] .edge-palm-spell__mist{animation-duration:18s;animation-direction:reverse}.edge-palm-spell[data-style=book] .edge-palm-spell__motes{fill:#e8d3ff}.edge-palm-spell[data-style=book] .edge-palm-spell__thread{stroke:#f5d9ac}
.edge-palm-spell[data-style=mist] .edge-palm-spell__mist{animation-duration:8s}.edge-palm-spell[data-style=mist] .edge-palm-spell__sweep{stroke-width:24;filter:blur(10px)}
.edge-palm-spell[data-style=dew] .edge-palm-spell__mist{opacity:.2}.edge-palm-spell[data-style=dew] .edge-palm-spell__motes{fill:#e2dcff;filter:drop-shadow(0 0 6px #cdb5f4)}
.edge-palm-spell[data-style=quiet] .edge-palm-spell__thread{opacity:.16}.edge-palm-spell[data-style=quiet] .edge-palm-spell__mist{animation-duration:22s;opacity:.25}.edge-palm-spell[data-style=quiet] .edge-palm-spell__motes{opacity:.6}
.palm-stage[data-edge-waiting=true][data-edge-pose=quiet] .cp-head{animation:palm-companion-listen 4s ease-in-out infinite;transform-origin:150px 100px}
.edge-palm-spell__lens .edge-palm-spell__palm path{fill:none;stroke:#ffe2a6;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}.edge-palm-spell__lens .edge-palm-spell__palm .edge-palm-spell__hand{fill:#291b3426}.edge-palm-spell__lens .edge-palm-spell__palm .edge-palm-spell__creases{stroke:#f7d5b1;stroke-width:1.8;animation:edge-palm-ink 2.8s ease-in-out infinite}
.edge-palm-spell__scroll{display:none}.edge-palm-spell[data-style=book] .edge-palm-spell__hand{display:none}.edge-palm-spell[data-style=book] .edge-palm-spell__scroll{display:block}
@keyframes edge-palm-ink{0%,100%{opacity:.45}50%{opacity:1}}
