/* Halloween Words: game-specific styles
   (shared look: ../shared/base.css, Halloween theme: ../shared/halloween/theme.css) */

/* ---------- Characters ---------- */

.chars {
  --size: clamp(110px, 21vmin, 190px);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(12px, 2.6vmin, 28px);
  max-width: calc(var(--size) * 4 + clamp(12px, 2.6vmin, 28px) * 3 + 1px);
}

.chars.learn {
  --size: clamp(100px, 18vmin, 160px);
}

.char {
  width: var(--size);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 8px;
  border: 4px solid transparent;
  border-radius: 28px;
  background: linear-gradient(180deg, var(--card-light), var(--card));
  box-shadow: 0 6px 0 rgba(0, 0, 0, 0.3);
  transition: transform 0.1s, opacity 0.25s;
}

.char:active {
  transform: translateY(4px);
}

.char svg {
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  overflow: visible;
  animation: float 3s ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}

.char-word {
  font-size: calc(var(--size) * 0.15); /* sized to the card so SKELETON fits in capitals */
  line-height: 1.1;
}

.char.appear {
  animation: appear 0.35s ease-out backwards;
  animation-delay: var(--appear-delay, 0s);
}

.char.cheer {
  animation: happy 0.8s ease-in-out;
}

.char.right {
  border-color: var(--hint);
  animation: happy 0.8s ease-in-out;
}

.char.faded {
  opacity: 0.35;
}

.char.hint {
  animation: char-glow 1s ease-in-out infinite;
}
/* ---------- Animations ---------- */

@keyframes char-glow {
  0%, 100% { box-shadow: 0 6px 0 rgba(0, 0, 0, 0.3), 0 0 0 0 var(--hint); }
  50% { box-shadow: 0 6px 0 rgba(0, 0, 0, 0.3), 0 0 0 10px var(--hint); }
}

/* 16 stars on the end screen: keep them on one line */
.end-stars {
  font-size: clamp(24px, 4.4vmin, 44px);
  letter-spacing: 2px;
}

