.totems {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 18px;
  position: relative;
}
.totem {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0 0 14px;
  overflow: hidden;
  opacity: 0;
  transform: translateY(24px);
  transition:
    box-shadow 0.4s,
    border-color 0.4s,
    translate 0.4s var(--ease);
}
.totem.in {
  animation: enter 0.9s var(--ease) forwards;
}
.totem:hover {
  translate: 0 -4px;
}
@keyframes enter {
  to {
    opacity: 1;
    transform: none;
  }
}
.brand {
  padding: 16px 16px 2px;
  color: var(--ink);
  font-family: var(--head);
  font-weight: 800;
  font-stretch: 110%;
  font-size: 1.2rem;
  letter-spacing: 0.01em;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.rank {
  font-family: var(--head);
  font-weight: 700;
  background: var(--bg2);
  color: var(--muted);
  border-radius: 6px;
  min-width: 36px;
  text-align: center;
  padding: 2px 6px;
  font-size: 0.85rem;
}
.bd {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 9px;
  vertical-align: middle;
  position: relative;
  top: -1px;
}
.board {
  position: relative;
  margin: 14px 14px 8px;
  background: #0b0b0b;
  border-radius: 8px;
  padding: 12px 10px;
  display: flex;
  justify-content: center;
  align-items: baseline;
  box-shadow: inset 0 0 0 1px #222;
}
.digits {
  display: flex;
  font-family: "Bungee", Impact, sans-serif;
  font-size: 2.4rem;
  color: var(--led);
  text-shadow: 0 0 6px rgba(255, 176, 0, 0.35);
  height: 1.15em;
  line-height: 1.15em;
  overflow: hidden;
}
.col {
  display: flex;
  flex-direction: column;
  transition: transform 1.2s var(--ease);
}
.col span {
  height: 1.15em;
  text-align: center;
  width: 0.72em;
}
.sep {
  width: 0.35em;
  text-align: center;
}
.eur {
  color: var(--led);
  font-family: "Bungee", sans-serif;
  font-size: 1rem;
  margin-left: 6px;
  opacity: 0.8;
}
.meta {
  padding: 0 16px;
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
}
.trend {
  padding: 0 16px;
  margin: 4px 0 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink);
}
.trend[hidden] {
  display: none;
}
.lloc {
  padding: 0 16px;
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 0.82rem;
}
.lloc[hidden] {
  display: none;
}
.lloc a,
.enllac-boto {
  color: var(--ink);
  font-weight: 700;
}
.enllac-boto {
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}
.badge {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: -10px;
  translate: -50% 0;
  background: var(--led);
  color: #1a1200;
  font: 800 0.68rem/1 var(--head);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 5px 9px;
  border-radius: 999px;
  opacity: 0;
  scale: 0.8;
  transition:
    opacity 0.4s,
    scale 0.5s var(--ease);
  white-space: nowrap;
}
.totem.best {
  border-color: var(--led);
  box-shadow: 0 0 0 1px var(--led);
}
.totem.best .badge {
  opacity: 1;
  scale: 1;
}
.totem.best .board::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 8px;
  background: linear-gradient(
    100deg,
    transparent 30%,
    rgba(255, 176, 0, 0.16) 50%,
    transparent 70%
  );
  background-size: 250% 100%;
  animation: sheen 3.2s ease-in-out 1s infinite;
  pointer-events: none;
}
@keyframes sheen {
  0% {
    background-position: 120% 0;
  }
  60%,
  100% {
    background-position: -120% 0;
  }
}
.totem[hidden] {
  display: none;
}
.totem.swap .brand {
  animation: fade 0.6s var(--ease);
}
@media (max-width: 560px) {
  .digits {
    font-size: 2rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .totem {
    opacity: 1;
    transform: none;
  }
}
