/* Flat dumdum: the app's creature, drawn in plain shapes. No shading, no
   gloss. Built at 150x130 and scaled by flatdum.js. Moods are data-mood. */
.fd {
  --body: #26252f;
  --eye: #f7f6f2;
  --pupil: #15141b;
  --blush: rgba(255, 120, 150, .38);
  --mouth: #15141b;
  position: fixed; left: 0; top: 0; z-index: 5; width: 150px; height: 130px;
  transform-origin: 50% 100%; will-change: transform; pointer-events: auto; cursor: pointer;
  -webkit-tap-highlight-color: transparent; touch-action: manipulation;
}
.fd-shadow {
  position: absolute; left: 50%; bottom: -10px; width: 112px; height: 14px; margin-left: -56px;
  border-radius: 50%; background: rgba(20, 18, 30, .16); transform-origin: 50% 50%;
}
.fd-rig { position: absolute; inset: 0; transform-origin: 50% 100%; }
.fd-body {
  position: absolute; inset: 0; background: var(--body);
  border-radius: 48% 52% 54% 46% / 52% 50% 50% 48%;
  animation: fd-morph 9s ease-in-out infinite; transition: background-color .6s;
}
@keyframes fd-morph {
  0%, 100% { border-radius: 48% 52% 54% 46% / 52% 50% 50% 48%; }
  50% { border-radius: 52% 48% 47% 53% / 49% 53% 47% 51%; }
}
.fd-face { position: absolute; inset: 0; will-change: transform; }
.fd-eyes { position: absolute; top: 46px; left: 0; right: 0; display: flex; justify-content: center; gap: 24px; }
.fd-eye {
  position: relative; width: 20px; height: 20px; border-radius: 50%; background: var(--eye); overflow: hidden;
  transition: height .18s, width .18s, margin .18s, border-radius .18s;
}
.fd-pupil {
  position: absolute; left: 50%; top: 50%; width: 9px; height: 9px; margin: -4.5px 0 0 -4.5px;
  border-radius: 50%; background: var(--pupil); will-change: transform; transition: width .2s, height .2s, margin .2s;
}
.fd-pupil::after { content: ""; position: absolute; top: 1.5px; left: 1.6px; width: 2.6px; height: 2.6px; border-radius: 50%; background: #fff; }
.fd-cheek { position: absolute; top: 69px; width: 15px; height: 7px; border-radius: 50%; background: var(--blush); transition: opacity .4s, transform .4s; }
.fd-cheek.l { left: 36px; } .fd-cheek.r { right: 36px; }
.fd-mouth {
  position: absolute; left: 50%; top: 82px; width: 22px; height: 4px; margin-left: -11px;
  border-radius: 50%; background: var(--mouth); transform: scaleY(0); transform-origin: 50% 0;
  transition: transform .18s, height .18s, width .18s, margin .18s, border-radius .18s, background .18s;
}
/* A small smile line, shown in happy moods. */
.fd-smile {
  position: absolute; left: 50%; top: 78px; width: 16px; height: 8px; margin-left: -8px;
  border: 2.4px solid var(--mouth); border-top: 0; border-radius: 0 0 12px 12px; opacity: 0; transition: opacity .2s;
}

/* ---------- extras ---------- */
.fd-x { position: absolute; opacity: 0; transform: scale(.4); transition: opacity .25s, transform .35s cubic-bezier(.34,1.56,.64,1); pointer-events: none; }
.fd-bolt { top: -14px; right: 12px; width: 20px; height: 30px; fill: #ffc94d; }
.fd-dot { top: 4px; left: 14px; width: 13px; height: 13px; border-radius: 50%; background: #ff5470; box-shadow: 0 0 0 4px rgba(255, 84, 112, .22); }
.fd-key {
  top: -26px; left: 50%; margin-left: -17px; width: 34px; height: 28px; border-radius: 8px;
  background: #fff; color: #15141b; font: 800 15px/26px 'Bricolage Grotesque', sans-serif; text-align: center;
  box-shadow: 0 3px 0 rgba(20, 18, 30, .25);
}
.fd-zzz { top: -22px; right: 2px; font: 800 18px 'Bricolage Grotesque', sans-serif; color: var(--zzz, #8b86a3); letter-spacing: 1px; }
.fd-zzz i { font-style: normal; display: inline-block; animation: fd-zz 2.4s ease-in-out infinite; }
.fd-zzz i:nth-child(2) { font-size: 14px; animation-delay: .4s; } .fd-zzz i:nth-child(3) { font-size: 11px; animation-delay: .8s; }
@keyframes fd-zz { 0%, 100% { translate: 0 0; opacity: .35; } 50% { translate: 0 -7px; opacity: 1; } }
.fd-file { left: 50%; bottom: 14px; width: 20px; height: 24px; margin-left: -10px; border-radius: 3px 8px 3px 3px; background: var(--eye); opacity: 0; }
.fd-file::after { content: attr(data-kind); position: absolute; inset: auto 0 3px; font: 800 6.5px/1 Inter, sans-serif; color: var(--body); text-align: center; letter-spacing: .02em; }
.fd-ring { inset: -10px; border-radius: 50%; border: 3px dashed var(--ring, #8b86a3); animation: fd-spin 3s linear infinite; }
@keyframes fd-spin { to { rotate: 360deg; } }
.fd-drop { top: 30px; right: 18px; width: 8px; height: 11px; border-radius: 50% 50% 50% 50% / 65% 65% 35% 35%; background: #8fd3ff; }

/* ---------- moods ---------- */
.fd[data-mood="happy"] .fd-eye, .fd[data-mood="proud"] .fd-eye { height: 8px; margin-top: 4px; border-radius: 10px 10px 4px 4px; }
.fd[data-mood="happy"] .fd-pupil, .fd[data-mood="proud"] .fd-pupil { opacity: 0; }
.fd[data-mood="happy"] .fd-cheek, .fd[data-mood="proud"] .fd-cheek, .fd[data-mood="charge"] .fd-cheek { transform: scale(1.25); }
.fd[data-mood="happy"] .fd-smile, .fd[data-mood="proud"] .fd-smile, .fd[data-mood="charge"] .fd-smile, .fd[data-mood="idle"] .fd-smile { opacity: 1; }
.fd[data-mood="idle"] .fd-smile { opacity: .0; }

.fd[data-mood="hungry"] .fd-mouth, .fd[data-mood="eat"] .fd-mouth { transform: scaleY(1); width: 34px; margin-left: -17px; height: 24px; }
.fd[data-mood="hungry"] .fd-eye { width: 23px; height: 23px; }
.fd[data-mood="chew"] .fd-mouth { transform: scaleY(1); animation: fd-chew .45s ease-in-out infinite; }
@keyframes fd-chew { 0%, 100% { height: 4px; } 50% { height: 11px; } }
.fd[data-mood="travel"] .fd-mouth { transform: scaleY(1); width: 12px; height: 10px; margin-left: -6px; }
.fd[data-mood="travel"] .fd-eye { width: 22px; height: 22px; }

.fd[data-mood="startle"] .fd-eye { width: 26px; height: 26px; }
.fd[data-mood="startle"] .fd-pupil { width: 6px; height: 6px; margin: -3px 0 0 -3px; }
.fd[data-mood="startle"] .fd-mouth { transform: scaleY(1); width: 10px; height: 12px; margin-left: -5px; }
.fd[data-mood="startle"] .fd-key { opacity: 1; transform: none; }

.fd[data-mood="tired"] .fd-eye { height: 9px; margin-top: 8px; border-radius: 4px 4px 10px 10px; }
.fd[data-mood="tired"] .fd-drop { opacity: 1; transform: none; animation: fd-drip 2s ease-in infinite; }
@keyframes fd-drip { 0% { translate: 0 -4px; opacity: 0; } 30% { opacity: 1; } 100% { translate: 0 12px; opacity: 0; } }
.fd[data-mood="tired"] .fd-body { filter: saturate(.6) brightness(.92); }

.fd[data-mood="charge"] .fd-bolt { opacity: 1; transform: none; animation: fd-zap 1.2s ease-in-out infinite; }
@keyframes fd-zap { 0%, 100% { rotate: -8deg; } 50% { rotate: 8deg; scale: 1.12; } }

.fd[data-mood="mic"] .fd-dot, .fd[data-mood="camera"] .fd-dot { opacity: 1; transform: none; animation: fd-pulse 1.2s ease-in-out infinite; }
@keyframes fd-pulse { 50% { box-shadow: 0 0 0 7px rgba(255, 84, 112, .12); } }
.fd[data-mood="mic"] .fd-mouth { transform: scaleY(1); width: 8px; height: 3px; margin-left: -4px; }

.fd[data-mood="sleep"] .fd-eye { height: 3px; margin-top: 10px; }
.fd[data-mood="sleep"] .fd-pupil { opacity: 0; }
.fd[data-mood="sleep"] .fd-zzz { opacity: 1; transform: none; }

.fd[data-mood="work"] .fd-ring { opacity: .7; transform: none; }

.fd.holding .fd-file { opacity: .95; transform: none; }
.fd.sick .fd-body { background: #9cc77a; }
