/* =====================================================================
   LUNAR HAZE — BUDDY (assets/css/buddy.css)  · added Oct 30 2026
   The bud in the bottom left corner of the shop pages (assets/js/buddy.js),
   his speech bubble, his moves (he's only ever in the corner), Puffy dropping by, and the
   Choose your Buddy window (Start > Settings).
   ===================================================================== */

/* ---------- where he sits ---------- */
.buddy { position: fixed; left: 10px; bottom: var(--bd-bottom, 62px); z-index: 58; width: 74px; transition: opacity .25s, transform .35s ease-in, bottom .2s ease; }   /* (bottom: moves with the Add to cart bar, same speed) */
@media (max-width: 720px) { .buddy { left: 2px; width: 60px; } }
.buddy .bd { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; position: relative; -webkit-tap-highlight-color: transparent; touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.buddy .bd:focus-visible { outline: 2px dashed var(--plum, #5E3F7A); outline-offset: 4px; border-radius: 50%; }
.buddy svg, .bd-visitor svg, .bds-bud svg { display: block; width: 100%; height: auto; overflow: visible; }
.bd-float { display: block; animation: bd-bob 3s ease-in-out infinite; }
@keyframes bd-bob { 50% { transform: translateY(-4px); } }
.bd-body { display: block; transition: translate .2s cubic-bezier(.3,1.3,.5,1), rotate .2s ease-out; }
.bd-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Coming onto the screen: he rolls in from the left edge and settles (Puffy floats in, Buddy rolls in, he's a bud) */
.buddy.bd-enter { animation: bd-enter .95s cubic-bezier(.22,.8,.3,1) both; }
@keyframes bd-enter { 0% { transform: translateX(-120px); opacity: 0; } 20% { opacity: 1; } 78% { transform: translateX(5px); } 100% { transform: none; } }
.buddy.bd-enter svg { animation: bd-enter-roll .95s cubic-bezier(.22,.8,.3,1) both; transform-origin: 50% 60%; }
@keyframes bd-enter-roll { 0% { transform: rotate(-330deg); } 78% { transform: rotate(6deg); } 88% { transform: scale(1.06,.94); } 100% { transform: none; } }
.buddy.bd-snap { transition: none !important; }

/* Phones: peeks in from the edge (like Puffy) until he talks */
.buddy.bd-tuck .bd-body { translate: -32% 0; rotate: 10deg; }

/* Ducked out for Puffy */
.buddy.bd-duck { transform: translateY(110px); opacity: 0; pointer-events: none; }

/* (Nov 5 2026) Puffy takes the corner. Poked in from My Mail: DUCK AND COVER. Buddy hides behind the taskbar
   off to the side (past Puffy's speech bubble) with just his eyes showing. Lower while Puffy storms, peeks up
   after ("Is it over?"). Summoned: a PUFF OF SMOKE rolls over Buddy and Puffy's there when it clears (assets/js/puffy.js). */
.buddy.bd-duck.bd-cover { opacity: 1; z-index: 49; translate: min(320px, calc(100vw - 82px)) 0; --cy: 46px; transform: translateY(var(--cy)); transition: transform .3s ease-in; animation: bd-hide .7s; }
/* (two steps you can see: he scoots out from under Puffy, then ducks behind the taskbar. Played as an animation, not a
   transition, so every browser shows it. Coming back is the same two steps in reverse, .bd-back) */
@keyframes bd-hide {
    0% { translate: 0 0; transform: none; z-index: 61; }
    48% { translate: min(320px, calc(100vw - 82px)) 0; transform: none; z-index: 61; animation-timing-function: ease-in; }
    50% { z-index: 49; }
    100% { translate: min(320px, calc(100vw - 82px)) 0; transform: translateY(var(--cy, 46px)); z-index: 49; }
}
.buddy.bd-duck.bd-cover.bd-cover-deep { --cy: 96px; transition: transform .35s ease-in; }
.buddy.bd-duck.bd-cover.bd-cover-peek { --cy: 22px; transition: transform .5s cubic-bezier(.3,1.4,.5,1); }
.buddy.bd-back { z-index: 49; transition: transform .3s ease-out, translate .35s cubic-bezier(.3,1.1,.5,1) .3s; }   /* (back out: pops up from behind the taskbar, then scoots home) */
.puffy.pf-wait, .buddy.bd-wait { animation-play-state: paused !important; }   /* (held on the first frame until the page has drawn them, then they play) */
.buddy.bd-cover .bd-dots { display: none !important; }
.buddy.bd-cover.bd-tuck .bd-body { translate: none; rotate: none; }   /* (phones: no edge-peek while he's hiding by the taskbar) */
.buddy.bd-cover .bd-bub { left: auto; right: 4px; } .buddy.bd-cover .bd-bub::after { left: auto; right: 22px; }
.buddy.bd-smoked { transform: scale(.6); opacity: 0; transition: opacity .35s .15s, transform .35s .15s; }
.pf-smoke { position: fixed; z-index: 61; width: 170px; height: 150px; pointer-events: none; }
.pf-smoke i { position: absolute; border-radius: 50%; background: radial-gradient(circle, #F4EEFF 0, #D9CCF0 55%, rgba(217,204,240,0) 72%); animation: pf-smoke 2.2s ease-in-out forwards; }
.pf-smoke i:nth-child(1) { left: 0; top: 40px; width: 100px; height: 100px; }
.pf-smoke i:nth-child(2) { left: 50px; top: 0; width: 110px; height: 110px; animation-delay: .1s; }
.pf-smoke i:nth-child(3) { left: 30px; top: 60px; width: 110px; height: 90px; animation-delay: .2s; }
@keyframes pf-smoke { 0% { transform: scale(.2); opacity: 0; } 30%, 55% { transform: scale(1); opacity: 1; } 100% { transform: scale(1.5) translateY(-30px); opacity: 0; } }
.puffy.pf-from-smoke:not(.pf-leave):not(.pf-blown) { animation: pf-from-smoke .9s ease-out both; }
@keyframes pf-from-smoke { 0%, 25% { opacity: 0; transform: scale(.8); } 70% { opacity: 1; transform: scale(1.06); } 100% { transform: none; } }
.puffy.pf-squish-in:not(.pf-leave):not(.pf-blown) { animation: pf-squish-in .45s cubic-bezier(.3,1.5,.5,1) both; transform-origin: 30px 100%; }
@keyframes pf-squish-in { 0% { transform: translateY(20px) scale(1.4, .4); opacity: .3; } 25% { opacity: 1; transform: scale(1.3, .7); } 60% { transform: scale(.92, 1.1); } 100% { transform: none; } }
@media (prefers-reduced-motion: reduce) {   /* (Reduce motion on: still show the swap, just gentler. Buddy's scoot stays, the same as him coming back) */
    .puffy.pf-squish-in:not(.pf-leave):not(.pf-blown) { animation: pf-fade-in .3s ease-out both; }
    .puffy.pf-from-smoke:not(.pf-leave):not(.pf-blown) { animation: pf-fade-in .5s ease-out .3s both; }
    .pf-smoke i { animation-name: pf-smoke-soft; }
}
@keyframes pf-fade-in { from { opacity: 0; } }
@keyframes pf-smoke-soft { 0% { opacity: 0; } 30%, 55% { opacity: 1; } 100% { opacity: 0; } }

/* ---------- face bits ---------- */
.bd-lids { transform-origin: 60px 65px; transform-box: view-box; animation: bd-blink 4.6s infinite; }
@keyframes bd-blink { 0%, 93%, 100% { transform: scaleY(1); } 96% { transform: scaleY(.1); } }
.bd-sleep { display: none; }
.bd.bd-nap .bd-lids { display: none; }
.bd.bd-nap .bd-sleep { display: inline; }
.bd.bd-nap::after { content: "z z"; position: absolute; right: -4px; top: -6px; font: 700 13px/1 var(--body, monospace); color: var(--plum, #5E3F7A); letter-spacing: 2px; animation: bd-z 2.4s ease-in-out infinite; }
@keyframes bd-z { 50% { transform: translateY(-5px); opacity: .55; } }
.bd-dust { opacity: 0; transition: opacity .4s; }
.bd.bd-dusty .bd-dust { opacity: 1; }

/* "…" dots: until the first tap, and when he knows something important */
.bd-dots { position: absolute; right: -8px; top: -6px; z-index: 2; display: none; gap: 3px; padding: 4px 7px; background: #FFFFFF; border: 2px solid var(--plum, #5E3F7A); border-radius: 10px; }
.bd-dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--plum, #5E3F7A); animation: bd-dot 1.2s infinite; }
.bd-dots i:nth-child(2) { animation-delay: .2s; } .bd-dots i:nth-child(3) { animation-delay: .4s; }
@keyframes bd-dot { 0%, 60%, 100% { opacity: .3; } 30% { opacity: 1; } }
.bd.bd-think .bd-dots { display: flex; }
.buddy:has(.bd-bub) .bd-dots { display: none !important; }   /* (never on top of his speech bubble) */
.buddy.bd-tuck .bd-dots { right: 2px; }

/* ---------- speech bubble ---------- */
.bd-bub { position: absolute; left: 8px; bottom: 100%; margin-bottom: 8px; width: max-content; max-width: min(260px, calc(100vw - 30px)); padding: 7px 11px; background: #FFFFFF; border: 2.5px solid var(--plum, #5E3F7A); border-radius: 12px; box-shadow: 2px 3px 0 rgba(43,42,94,.2); color: var(--ink, #2B2A5E); font: 700 13px/1.4 var(--body, monospace); text-align: left; z-index: 3; animation: bd-bub .22s ease-out; }
.bd-bub::after { content: ""; position: absolute; left: 22px; top: 100%; border: 7px solid transparent; border-top-color: var(--plum, #5E3F7A); }
@keyframes bd-bub { from { opacity: 0; transform: translateY(6px); } }
/* × in the corner of his bubble */
.bd-bub { padding-right: 30px; }
.bd-t { text-wrap: balance; }   /* (two lines come out about even, then the bubble hugs them: assets/js/buddy.js hug()) */
.bd-x { position: absolute; top: 3px; right: 4px; width: 22px; height: 22px; padding: 0; border: 0; border-radius: 50%; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M2 2l6 6M8 2l-6 6' stroke='%235E3F7A' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") center / 10px 10px no-repeat; font-size: 0; color: transparent; cursor: pointer; opacity: .65; -webkit-tap-highlight-color: transparent; }   /* (the × is drawn, so it sits dead center in its circle) */
.bd-x:hover, .bd-x:focus-visible { opacity: 1; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 10'%3E%3Cpath d='M2 2l6 6M8 2l-6 6' stroke='%235E3F7A' stroke-width='1.8' stroke-linecap='round'/%3E%3C/svg%3E") center / 10px 10px no-repeat, #F1E6FA; outline: none; }
.bd-x::before { content: ""; position: absolute; inset: -8px; }   /* (bigger tap area on phones) */
.bd-link { display: inline-block; margin-top: 5px; color: #4E7A2C; font-weight: 700; text-decoration: underline; }

/* ---------- moves ---------- */
.bd.bd-nod svg { animation: bd-nod .4s ease; }
@keyframes bd-nod { 40% { transform: translateY(3px) scale(1.04,.96); } }
.bd.bd-wave svg { animation: bd-wave 1s ease 2; }
@keyframes bd-wave { 25% { transform: rotate(-10deg); } 75% { transform: rotate(10deg); } }
.bd.bd-shake svg { animation: bd-shake .45s steps(2) 2; }
@keyframes bd-shake { 0% { transform: translateX(-3px) rotate(-4deg); } 100% { transform: translateX(3px) rotate(4deg); } }
.bd.bd-f-wiggle svg { animation: bd-wig .7s ease; }
@keyframes bd-wig { 20% { transform: rotate(-8deg); } 40% { transform: rotate(7deg); } 60% { transform: rotate(-5deg); } 80% { transform: rotate(3deg); } }
.bd.bd-f-stretch svg { transform-origin: 50% 95%; animation: bd-str 1.2s ease; }
@keyframes bd-str { 30%, 55% { transform: scale(.94,1.14); } 75% { transform: scale(1.06,.94); } }
.bd.bd-f-hop svg { animation: bd-hop .8s cubic-bezier(.3,1.5,.5,1); }
@keyframes bd-hop { 25% { transform: translateY(-14px); } 50% { transform: none; } 65% { transform: translateY(-6px); } 80% { transform: none; } }
.bd.bd-f-scoot { animation: bd-scoot 1.6s ease; }
@keyframes bd-scoot { 25%, 50% { transform: translateX(14px) rotate(25deg); } 100% { transform: none; } }
.bd.bd-squish svg { transform-origin: 50% 95%; animation: bd-squish .6s cubic-bezier(.3,1.6,.5,1); }
@keyframes bd-squish { 25% { transform: scale(1.18,.78); } 55% { transform: scale(.92,1.1); } 80% { transform: scale(1.03,.97); } }
.bd.bd-f-bored .bd-lids { animation: none; transform: scaleY(.45); }
.bd.bd-f-bored svg { animation: bd-bored 2.2s ease; }
@keyframes bd-bored { 30%, 70% { transform: translateY(3px) scale(1.04,.96); } }

/* rolls off along the taskbar, and back in */
.buddy.bd-rolling-off { animation: bd-off 1.7s cubic-bezier(.5,0,.9,.6) forwards; pointer-events: none; }
@keyframes bd-off { to { transform: translateX(calc(100vw + 40px)); } }
.buddy.bd-rolling-back { animation: bd-back 1.3s cubic-bezier(.2,.6,.4,1) both; }
@keyframes bd-back { from { transform: translateX(-120px); } }
.buddy.bd-rolling-off svg, .buddy.bd-rolling-back svg { animation: bd-spin .6s linear infinite; }
.buddy.bd-rolling-back svg { animation-iteration-count: 2; }
.buddy.bd-rolling-off .bd-body, .buddy.bd-rolling-back .bd-body { translate: none; rotate: none; }
.buddy.bd-rolling-off .bd-bub { display: none; }
@keyframes bd-spin { to { transform: rotate(360deg); } }

/* ---------- Puffy dropping by ---------- */
.bd-visitor { position: fixed; left: 118px; bottom: var(--bd-bottom, 62px); z-index: 57; width: 84px; transition: transform .9s cubic-bezier(.3,1,.4,1), opacity .6s; pointer-events: none; }
@media (max-width: 720px) { .bd-visitor { left: 96px; width: 74px; } }
.bd-visitor.bd-v-off { transform: translate(-220px, 40px); opacity: 0; }
.bd-visitor.bd-v-up { transform: translate(60px, -260px); opacity: 0; }
.bd-visitor .bd-bub { max-width: min(240px, calc(100vw - 110px)); padding-right: 11px; }   /* (Nov 10 2026: Puffy visiting has no × on his bubble, so no extra room for one) */


/* ---------- Choose your Buddy (Start > Settings) ---------- */
.bds-win { width: min(440px, 100%); }
.bds-panel { padding: 14px; border: 3px solid; border-color: #FFFFFF var(--lav-dark, #C9AEE6) var(--lav-dark, #C9AEE6) #FFFFFF; background: #FFFFFF; }
.bds-stage { position: relative; display: grid; place-items: center; height: 180px; overflow: hidden; border: 3px solid; border-color: var(--lav-dark, #C9AEE6) #FFFFFF #FFFFFF var(--lav-dark, #C9AEE6); background: radial-gradient(circle at 50% 120%, rgba(159,210,122,.35), transparent 60%), #F6FBEF; }
.bds-bud { display: block; width: 112px; margin-top: -8px; animation: bd-bob 3s ease-in-out infinite; }
.bds-locked svg { filter: grayscale(1) brightness(1.15); opacity: .55; }
.bds-shadow { position: absolute; bottom: 22px; left: 50%; width: 86px; height: 12px; margin-left: -43px; border-radius: 50%; background: rgba(43,42,94,.12); }
.bds-count { position: absolute; top: 8px; left: 10px; color: #6C8A4F; font: 700 11px var(--body, monospace); }
.bds-lock { position: absolute; top: 8px; right: 10px; max-width: calc(100% - 64px); white-space: normal; text-align: center; padding: 2px 8px; border: 2px solid var(--lav-dark, #C9AEE6); background: #F1E6FA; color: var(--plum, #5E3F7A); font: 700 11px var(--body, monospace); }
.bds-name { margin: 12px 0 2px; color: #3A2440; font: 800 23px var(--display, serif); font-variation-settings: "SOFT" 100, "WONK" 1; }
.bds-desc { min-height: 3em; margin: 0; font-size: 13.5px; }
.bds-nav, .bds-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 12px; }
.bds-foot { justify-content: flex-end; }
.bds-b { padding: 6px 12px; border: 3px solid; border-color: var(--bevel-out, #FFFFFF #C9AEE6 #C9AEE6 #FFFFFF); background: #F8F1FD; color: var(--ink, #2B2A5E); font: 700 13px var(--body, monospace); cursor: pointer; }
.bds-b:active { border-color: var(--bevel-in, #C9AEE6 #FFFFFF #FFFFFF #C9AEE6); }
.bds-b[disabled] { opacity: .45; cursor: default; }
.bds-ok { min-width: 80px; background: var(--lime, #E1F66B); }
.bds-dots { display: flex; gap: 5px; }
.bds-dots i { width: 11px; height: 11px; border-radius: 50%; border: 2px solid var(--plum, #5E3F7A); }
.bds-dots i.on { outline: 2px solid var(--plum, #5E3F7A); outline-offset: 2px; }

/* Typed "buddy" on a page he isn't on: he rolls across the bottom of the screen */
.buddy.bd-cross { left: -80px; bottom: 58px; animation: bd-cross 3s linear forwards; }
@keyframes bd-cross { to { transform: translateX(calc(100vw + 160px)); } }
.buddy.bd-cross svg { animation: bd-spin .7s linear infinite; }

/* ---------- 4:20 (assets/js/buddy.js "4:20") ---------- */
/* Puffy's page: Puffy comes fully out of his peek, his own bubble hidden for the minute */
.puffy.bd-duo .pf-bubble { display: none !important; }
.puffy.bd-duo .pf-cloud { translate: none !important; rotate: none !important; }
/* Buddy as the guest next to Puffy: rolls over from the right */
.buddy.bd-guest { z-index: 61; }
.buddy.bd-enter-r { animation: bd-enter-r 1.3s cubic-bezier(.22,.8,.3,1) both; }
@keyframes bd-enter-r { 0% { transform: translateX(calc(100vw - 60px)); } 80% { transform: translateX(-5px); } 100% { transform: none; } }
.buddy.bd-enter-r svg { animation: bd-enter-r-roll 1.3s cubic-bezier(.22,.8,.3,1) both; transform-origin: 50% 60%; }
@keyframes bd-enter-r-roll { 0% { transform: rotate(420deg); } 80% { transform: rotate(-6deg); } 90% { transform: scale(1.06,.94); } 100% { transform: none; } }
.bd-420say { position: fixed; z-index: 62; width: 0; height: 0; }
.bd-420say .bd-bub { left: 0; bottom: 0; margin-bottom: 0; max-width: min(260px, calc(100vw - 24px)); }
/* Phones: the time, since the taskbar has no clock */
.bd-420chip { margin-left: auto; padding: 4px 10px; border: 2px solid #9DB33A; border-radius: 12px; background: #F2FFE8; color: #2F7A2C; font: 700 13px var(--body, monospace); white-space: nowrap; box-shadow: 0 0 10px #9BF27A; transform: translateY(60px); transition: transform .45s cubic-bezier(.3,1.5,.5,1); }
.bd-420chip.on { transform: none; }
html:has(.task-checkout:not([hidden])) .bd-420chip { display: none; }   /* (the cart's Checkout button is there) */

@media (prefers-reduced-motion: reduce) {
    .buddy *, .buddy, .bds-bud, .bd-visitor { animation: none !important; transition: none !important; }
}

/* ===== His birthday, April 20th (buddy.js "HIS BIRTHDAY"). Preview: ?bday ===== */
.bd-hat { transform-origin: 60px 28px; animation: bd-hat 2.4s ease-in-out infinite; }
@keyframes bd-hat { 50% { transform: rotate(-7deg); } }
.pf-party { transform-origin: 56px 10px; transform: rotate(10deg); animation: pf-party 2.4s ease-in-out infinite; }
@keyframes pf-party { 50% { transform: rotate(4deg); } }
.buddy .bd-spark { position: absolute; color: #FFE27A; font-size: 12px; line-height: 1; text-shadow: 0 0 6px #fff; pointer-events: none; opacity: 0; animation: bd-tw 1.8s ease-in-out infinite; }
.buddy .bd-spark:nth-of-type(1) { left: -4px; top: 30%; }
.buddy .bd-spark:nth-of-type(2) { right: -6px; top: 42%; animation-delay: .6s; }
.buddy .bd-spark:nth-of-type(3) { left: 44%; top: -14px; animation-delay: 1.2s; }
.buddy.bd-tuck .bd-spark { display: none; }
@keyframes bd-tw { 0%, 100% { opacity: 0; transform: scale(.4); } 50% { opacity: 1; transform: scale(1); } }
.bd-confetti { position: fixed; inset: 0; z-index: 59; pointer-events: none; overflow: hidden; }
.bd-confetti i { position: absolute; top: -12px; width: 7px; height: 11px; border-radius: 2px; animation: bd-fall linear forwards; }
@keyframes bd-fall { to { transform: translateY(105vh) rotate(560deg); } }

/* ===== Blown around (rocket + Clear the haze) and End Task (buddy.js "HE REACTS TO THE PAGE") ===== */
.buddy.bd-flung, .buddy.bd-pushed, .buddy.bd-burning, .buddy.bd-rolling-back { transition: none; }
.buddy.bd-flung .bd-body, .buddy.bd-pushed .bd-body { translate: none; rotate: none; }
.buddy .bd.bd-jolt svg { animation: bd-jolt .3s ease-out; }
@keyframes bd-jolt { 40% { transform: translateY(-7px) scale(.92,1.1); } }
.buddy.bd-flung { animation: bd-fling 1.05s cubic-bezier(.45,.05,.55,.95) forwards; pointer-events: none; }
@keyframes bd-fling { to { transform: translate(-90px, -380px) rotate(-420deg); } }
.buddy.bd-pushed { animation: bd-push 1.4s cubic-bezier(.4,0,.8,.5) forwards; pointer-events: none; }
@keyframes bd-push { to { transform: translateX(calc(100vw + 40px)) rotate(720deg); } }
.buddy.bd-away { opacity: 0; pointer-events: none; transform: translateX(-140px); transition: none; }
.buddy.bd-burning { pointer-events: none; }
.buddy.bd-burning .bd-float { animation: none; }
.buddy.bd-burning .bd-dots { display: none; }
.bd-wisp { position: absolute; bottom: 30%; width: 8px; height: 8px; border-radius: 50%; background: #B8B2C9; pointer-events: none; animation: bd-wisp 1.6s ease-out forwards; }
@keyframes bd-wisp { 0% { opacity: 0; } 20% { opacity: .85; } 100% { opacity: 0; transform: translate(var(--dx, 0), -70px) scale(2.6); } }
.bd-ash { position: fixed; left: 10px; bottom: var(--bd-bottom, 62px); z-index: 57; width: 74px; pointer-events: none; transition: opacity .8s, transform .8s; }
@media (max-width: 720px) { .bd-ash { left: 2px; width: 60px; } }
.bd-ash svg { display: block; width: 100%; }
.bd-ash.bd-ash-go { opacity: 0; transform: translateX(30px); }
.bd-huff { position: absolute; right: -4px; top: 6px; font-size: 14px; pointer-events: none; animation: bd-huff 1.2s ease-out forwards; }
@keyframes bd-huff { 0% { opacity: 0; } 30% { opacity: 1; } 100% { opacity: 0; transform: translate(10px, -14px) scale(1.4); } }

/* ===== Hover for 10 seconds (computers): Buddy gets shy, Puffy poses ===== */
.buddy .bd.bd-shy svg { animation: bd-shy .9s ease-in-out forwards; }
@keyframes bd-shy { 30% { transform: translateX(-3px) rotate(-6deg); } 60% { transform: translateX(2px) rotate(4deg); } 100% { transform: translateX(-4px) rotate(-5deg) scale(.95); } }
.puffy.pf-posing .pf-cloud svg { transform-origin: 50% 90%; animation: pf-pose 1s cubic-bezier(.3,1.4,.5,1) forwards; }
@keyframes pf-pose { 40% { transform: rotate(-8deg) scale(1.08); } 100% { transform: rotate(-6deg) scale(1.06); } }
.puffy.pf-posing .pf-cloud::before, .puffy.pf-posing .pf-cloud::after { content: "✦"; position: absolute; z-index: 2; color: #FFE27A; font-size: 15px; text-shadow: 0 0 6px #fff; pointer-events: none; animation: bd-tw 1.2s ease-in-out infinite; }
.puffy.pf-posing .pf-cloud::before { left: -6px; top: 4px; }
.puffy.pf-posing .pf-cloud::after { right: -4px; top: -8px; animation-delay: .5s; }
.pf-flash { position: fixed; inset: 0; z-index: 9990; background: #fff; pointer-events: none; animation: pf-flash .4s ease-out forwards; }
@keyframes pf-flash { 0% { opacity: 0; } 20% { opacity: .55; } 100% { opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
    .bd-hat, .pf-party, .buddy .bd-spark { animation: none; }
    .buddy .bd-spark { opacity: .8; }
    .bd-confetti { display: none; }
    .buddy .bd.bd-jolt svg, .bd-wisp, .bd-huff, .buddy .bd.bd-shy svg, .puffy.pf-posing .pf-cloud svg { animation: none; }
    .pf-flash { display: none; }
}

/* (Nov 16 2026) the real Puffy steps out of sight while the visiting Puffy is here (assets/js/buddy.js hideRealPuffy) */
body > .puffy.bd-pf-away { opacity: 0 !important; pointer-events: none !important; transition: opacity .4s; }

/* (Nov 17 2026) a special color they just unlocked, the first time they see it in Choose your Buddy */
.bds-lock.bds-new { border-color: #9DB02E; background: var(--lime, #E1F66B); color: var(--ink, #2B2A5E); animation: bds-new-pop .5s cubic-bezier(.3,1.5,.5,1) both; }
@keyframes bds-new-pop { from { transform: scale(.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .bds-lock.bds-new { animation: none; } }
