#freddy-cat{position:fixed;pointer-events:none;z-index:1;line-height:0;filter:drop-shadow(0 2px 1px #1b1b1b38);contain:layout style;will-change:left,top}
#freddy-cat svg{width:100%;height:auto;overflow:visible}
#freddy-cat .fc-walk{display:none;transform-origin:85px 75px;transform:scaleX(var(--face,1))}
#freddy-cat .fc-head{transform-origin:82px 87px;transition:transform 1s ease}
#freddy-cat .fc-body{transform-origin:80px 138px;animation:fc-breathe 4s ease-in-out infinite}
#freddy-cat .fc-tail{transform-origin:105px 132px;animation:fc-tail 5s ease-in-out infinite}
#freddy-cat .fc-eyes{transform-origin:82px 64px;animation:fc-blink 5.7s infinite}
#freddy-cat .fc-paw{transform-origin:96px 105px;transition:transform .7s}
#freddy-cat .fc-leg{transform-origin:96px 126px}
#freddy-cat .fc-closed,#freddy-cat .fc-yawn,#freddy-cat .fc-tongue,#freddy-cat .fc-zzz{opacity:0}
#freddy-cat[data-action="walk"] .fc-sit{display:none}
#freddy-cat[data-action="walk"] .fc-walk{display:block;animation:fc-step .46s ease-in-out infinite}
#freddy-cat[data-action="walk"] .fc-shadow{animation:fc-shadow .46s ease-in-out infinite}
#freddy-cat[data-action="walk"] .fw-l1,#freddy-cat[data-action="walk"] .fw-l3{animation:fc-leg-a .46s ease-in-out infinite alternate;transform-origin:58px 96px}
#freddy-cat[data-action="walk"] .fw-l2{animation:fc-leg-b .46s ease-in-out infinite alternate;transform-origin:87px 96px}
#freddy-cat[data-action="walk"] .fw-tail{animation:fc-walk-tail .8s ease-in-out infinite alternate;transform-origin:38px 88px}
#freddy-cat[data-action="look-left"] .fc-head{transform:translateX(-4px) rotate(-9deg)}
#freddy-cat[data-action="look-right"] .fc-head{transform:translateX(4px) rotate(9deg)}
#freddy-cat[data-action="groom"] .fc-paw{transform:translate(-10px,-13px) rotate(125deg)}
#freddy-cat[data-action="groom"] .fc-head{animation:fc-groom 1.1s ease-in-out infinite}
#freddy-cat[data-action="groom"] .fc-tongue{animation:fc-lick 1.1s infinite}
#freddy-cat[data-action="scratch"] .fc-head{transform:rotate(14deg)}
#freddy-cat[data-action="scratch"] .fc-leg{animation:fc-scratch .22s ease-in-out infinite alternate}
#freddy-cat[data-action="stretch"] .fc-body{animation:fc-stretch 4.2s ease-in-out}
#freddy-cat[data-action="yawn"] .fc-yawn{animation:fc-mouth 4.2s ease-in-out}
#freddy-cat[data-action="yawn"] .fc-head{transform:rotate(-8deg) translateY(-3px)}
#freddy-cat[data-action="sleep"] .fc-eyes,#freddy-cat[data-action="yawn"] .fc-eyes{opacity:0}
#freddy-cat[data-action="sleep"] .fc-closed,#freddy-cat[data-action="yawn"] .fc-closed{opacity:1}
#freddy-cat[data-action="sleep"] .fc-head{transform:translateY(6px) rotate(7deg)}
#freddy-cat[data-action="sleep"] .fc-zzz{animation:fc-dream 3s ease-in-out infinite}
#freddy-cat[data-action="sleep"] .fc-tail{animation-duration:12s}
body:not(.theme-day) #freddy-cat{filter:brightness(.72) saturate(.88) drop-shadow(0 2px 1px #0006)}
@keyframes fc-breathe{50%{transform:scaleY(1.015)}}
@keyframes fc-tail{50%{transform:rotate(-12deg)}}
@keyframes fc-blink{0%,43%,47%,100%{transform:scaleY(1)}45%{transform:scaleY(.06)}}
@keyframes fc-step{0%,100%{transform:scaleX(var(--face,1)) translateY(0)}50%{transform:scaleX(var(--face,1)) translateY(-4px)}}
@keyframes fc-shadow{50%{transform:scaleX(.84);opacity:.18}}
@keyframes fc-leg-a{from{transform:rotate(15deg)}to{transform:rotate(-17deg)}}
@keyframes fc-leg-b{from{transform:rotate(-17deg)}to{transform:rotate(15deg)}}
@keyframes fc-walk-tail{from{transform:rotate(-9deg)}to{transform:rotate(11deg)}}
@keyframes fc-groom{50%{transform:translateY(6px) rotate(12deg)}}
@keyframes fc-lick{35%,65%{opacity:1}0%,25%,80%,100%{opacity:0}}
@keyframes fc-scratch{from{transform:translate(4px,-24px) rotate(-35deg)}to{transform:translate(0,-32px) rotate(-55deg)}}
@keyframes fc-stretch{0%,100%{transform:scale(1)}40%,70%{transform:scale(.92,1.15)}}
@keyframes fc-mouth{0%,100%{opacity:0}25%,75%{opacity:1}}
@keyframes fc-dream{0%,100%{opacity:0;transform:translateY(0)}50%{opacity:.9;transform:translateY(-8px)}}
@media(prefers-reduced-motion:reduce){#freddy-cat *{animation:none!important;transition:none!important}}

/* v4: planted four-paw gait; each leg bends independently in SVG coordinates. */
#freddy-cat[data-action="walk"] .fc-walk{animation:none}
#freddy-cat[data-action="walk"] .fc-shadow{animation:none;transform:none}
#freddy-cat .fw-limb{fill:none;stroke:#e99b45;stroke-width:10;stroke-linecap:round;stroke-linejoin:round}
#freddy-cat .fw-sock{fill:none;stroke:#fff9e8;stroke-width:9;stroke-linecap:round}
#freddy-cat .fw-foot{fill:#fff9e8;stroke:#bc9565;stroke-width:.6}
#freddy-cat .fw-leg:nth-last-child(4),#freddy-cat .fw-leg:nth-last-child(2){filter:brightness(.87)}

#freddy-cat{transition:opacity .4s ease;will-change:opacity}
