/* Full-canvas atlas cells retain a common scale. Offsets register atlas v2. */
.meddyRig { position:relative; display:block; width:var(--meddy-size,180px); max-width:100%; aspect-ratio:1; isolation:isolate; }
.meddyRig img { position:absolute; display:block; width:100%; height:100%; max-width:none; object-fit:contain; }
.meddyRig__body { left:-8.8%; top:0; z-index:1; }
.meddyRig__arm { left:4.7%; top:0; z-index:0; transform-origin:25% 54%; }
.meddyRig .meddyRig__eyes { z-index:2; width:5.5%; height:6.1%; }
.meddyRig__eye--left { left:37.3%; top:27.2%; }
.meddyRig__eye--right { left:57.1%; top:31.4%; }
.meddyRig .meddyRig__eyes--closed { visibility:hidden; height:4%; margin-top:1%; }
.meddyRig--animated .meddyRig__arm { animation:meddy-wave 2.8s ease-in-out infinite; }
.meddyRig--animated .meddyRig__eyes--open { animation:meddy-eyes-open 3.4s steps(1,end) infinite; }
.meddyRig--animated .meddyRig__eyes--closed { animation:meddy-eyes-closed 3.4s steps(1,end) infinite; }
@keyframes meddy-wave { 0%,55%,100% {transform:rotate(0)} 10%,30% {transform:rotate(12deg)} 20%,40% {transform:rotate(-12deg)} }
@keyframes meddy-eyes-open { 0%,91%,100% {visibility:visible} 92%,96% {visibility:hidden} }
@keyframes meddy-eyes-closed { 0%,91%,100% {visibility:hidden} 92%,96% {visibility:visible} }
@media(prefers-reduced-motion:reduce) { .meddyRig--animated .meddyRig__arm,.meddyRig--animated .meddyRig__eyes {animation:none} }
.meddyBoot { min-height:100dvh; display:grid; place-content:center; justify-items:center; background:#f6effa; color:#291459; font:700 20px/1.4 system-ui,sans-serif; }
.meddyBoot .meddyRig { --meddy-size:190px; }

/* Lower muzzle only; the nose, eyes and head remain independent. */
.meddyRig .meddyRig__mouth { z-index:3; left:42.2%; top:34.4%; width:13.3%; height:9.3%; clip-path:inset(18% 0 0); transform:rotate(8deg); visibility:hidden; }
.meddyRig:not([data-mouth]) .meddyRig__mouth--open,
.meddyRig[data-mouth="open"] .meddyRig__mouth--open,
.meddyRig[data-mouth="smile"] .meddyRig__mouth--smile,
.meddyRig[data-mouth="round"] .meddyRig__mouth--round { visibility:visible; }
.meddyRig--speaking .meddyRig__mouth--smile { animation:meddy-mouth-smile .72s steps(1,end) infinite; }
.meddyRig--speaking .meddyRig__mouth--open { animation:meddy-mouth-open .72s steps(1,end) infinite; }
.meddyRig--speaking .meddyRig__mouth--round { animation:meddy-mouth-round .72s steps(1,end) infinite; }
@keyframes meddy-mouth-smile { 0%,70%,100% {visibility:visible} 20%,55% {visibility:hidden} }
@keyframes meddy-mouth-open { 0%,40%,70%,100% {visibility:hidden} 20%,55% {visibility:visible} }
@keyframes meddy-mouth-round { 0%,55%,100% {visibility:hidden} 40% {visibility:visible} }
@media(prefers-reduced-motion:reduce) { .meddyRig--speaking .meddyRig__mouth {animation:none} }

#app-boot-loader { position: fixed; inset: 0; z-index: 10000; min-height: 100vh; min-height: 100dvh; }
.meddyBoot__dots { display: flex; align-items: center; justify-content: center; width: 64px; height: 48px; gap: 7px; }
.meddyBoot__dots i { width: 9px; height: 9px; border-radius: 50%; background: currentColor; animation: boot-dot 1.2s ease-in-out infinite; }
.meddyBoot__dots i:nth-child(2) { animation-delay: .15s; }
.meddyBoot__dots i:nth-child(3) { animation-delay: .3s; }
@keyframes boot-dot { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .meddyBoot__dots i { animation: none; } }
