.liuyang-mascot {
  position: fixed;
  left: 18px;
  bottom: 86px;
  z-index: 996;
  width: min(260px, 28vw);
  min-width: 188px;
  pointer-events: none;
  --mascot-x: 0px;
  --mascot-y: 0px;
  --mascot-rotate: 0deg;
  transform: translate3d(var(--mascot-x), var(--mascot-y), 0) rotate(var(--mascot-rotate));
  transform-origin: 45% 100%;
  transition: transform 0.16s ease-out;
}

.liuyang-mascot.is-hidden {
  display: none;
}

.liuyang-mascot__image {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 14px 22px rgba(40, 26, 18, 0.2));
  pointer-events: auto;
  user-select: none;
  animation: liuyang-mascot-breathe 4.8s ease-in-out infinite;
}

.liuyang-mascot__close {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
  color: #7c4a34;
  font-size: 18px;
  line-height: 28px;
  text-align: center;
  box-shadow: 0 8px 18px rgba(91, 59, 34, 0.14);
  cursor: pointer;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.18s ease, transform 0.18s ease, background-color 0.18s ease;
  pointer-events: auto;
}

.liuyang-mascot:hover .liuyang-mascot__close,
.liuyang-mascot:focus-within .liuyang-mascot__close {
  opacity: 1;
  transform: translateY(0);
}

.liuyang-mascot__close:hover {
  background: #fff7ed;
}

@keyframes liuyang-mascot-breathe {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-7px);
  }
}

@media (max-width: 768px) {
  .liuyang-mascot {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .liuyang-mascot,
  .liuyang-mascot__image {
    animation: none;
    transition: none;
  }
}
