/* Collectable card — sits on the narrow (1/3) side of the overview row,
   with large collectable images as the hero moment. */

.collectable-card {
  display: flex;
  flex-direction: column;
  padding: 1.1rem 1.25rem 1.25rem;
  border-radius: 18px;
  background: white;
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: var(--shadow-card);
}

.collectable-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.9rem;
}

.collectable-card-title {
  font-size: 0.85rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.01em;
}

.collectable-card-count {
  font-size: 0.72rem;
  font-weight: 700;
  color: #64748B;
  padding: 0.2rem 0.55rem;
  background: #F1F5F9;
  border-radius: 999px;
}

.collectable-stage {
  display: grid;
  grid-template-columns: 1fr 1.1fr 1fr;
  align-items: end;
  gap: 0.4rem;
  padding: 0.5rem 0.25rem 0.85rem;
}

.collectable-slot {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.35rem;
}

.collectable-image {
  width: 100%;
  max-width: 5.5rem;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  filter: drop-shadow(0 8px 10px rgba(15, 23, 42, 0.12));
  transition: transform 220ms ease;
}

.collectable-slot--current .collectable-image {
  animation: collectable-bob 3.6s ease-in-out infinite;
}

.collectable-slot--current:hover .collectable-image {
  transform: translateY(-3px) scale(1.04);
}

@keyframes collectable-bob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-3px); }
}

.collectable-image--ghost {
  filter: grayscale(1) brightness(0.85) opacity(0.35);
}

.collectable-image--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: #F1F5F9;
  color: #CBD5E1;
  font-size: 1.4rem;
  font-weight: 800;
  max-width: 4.5rem;
}

.collectable-image--xl {
  max-width: 7rem;
  margin-bottom: 0.5rem;
}

.collectable-slot-eyebrow {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #94A3B8;
}

.collectable-slot-name {
  font-size: 0.82rem;
  font-weight: 800;
  color: #0F172A;
  line-height: 1.15;
}

.collectable-slot--next .collectable-slot-name { color: #64748B; }

.collectable-trail {
  height: 2rem;
  display: flex;
  align-items: center;
  margin-bottom: 2.7rem;
}

.collectable-trail svg { width: 100%; height: 100%; display: block; }

.collectable-progress {
  margin-top: 0.3rem;
}

.collectable-progress-bar {
  height: 0.45rem;
  border-radius: 999px;
  background: #EEF2F7;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.05);
  overflow: hidden;
}

.collectable-progress-fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--color-brand-400), var(--color-brand-600));
  transition: width 600ms cubic-bezier(0.2, 0.7, 0.25, 1);
}

.collectable-progress-caption {
  margin-top: 0.5rem;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: #475569;
}

.collectable-progress-primary {
  display: inline-flex;
  align-items: baseline;
  gap: 0.3rem;
  white-space: nowrap;
}

.collectable-progress-remaining {
  font-weight: 800;
  color: #0F172A;
}

.collectable-progress-total {
  font-size: 0.66rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #94A3B8;
  white-space: nowrap;
}

/* Mini-gallery of every collectable (earned vs locked) at the base of the
   card. Fills the natural height gap next to the (taller) progress chart
   and gives the parent a concrete picture of the whole collection. */

.collectable-gallery {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed rgba(15, 23, 42, 0.08);
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.4rem;
}

.collectable-gallery-cell {
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: #F8FAFC;
  border: 1px solid rgba(15, 23, 42, 0.05);
  overflow: hidden;
  transition: transform 160ms ease, background-color 160ms ease, border-color 160ms ease;
}

.collectable-gallery-cell img {
  width: 74%;
  height: 74%;
  object-fit: contain;
}

.collectable-gallery-cell.is-earned {
  background: linear-gradient(155deg, #FFF8E1 0%, #FFECB3 100%);
  border-color: rgba(245, 158, 11, 0.3);
}

.collectable-gallery-cell.is-earned:hover {
  transform: translateY(-2px) scale(1.04);
  border-color: rgba(245, 158, 11, 0.6);
}

/* Earned cells that have a certificate attached — same amber treatment
   as the base earned state, but clickable with a subtle doc glyph. */
a.collectable-gallery-cell.has-certificate {
  position: relative;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

a.collectable-gallery-cell.has-certificate .collectable-gallery-cert {
  position: absolute;
  top: 3px;
  right: 3px;
  width: 16px;
  height: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.85);
  color: #1565C0;
  opacity: 0;
  transition: opacity 160ms ease;
  pointer-events: none;
}

a.collectable-gallery-cell.has-certificate:hover .collectable-gallery-cert {
  opacity: 1;
}

.collectable-gallery-cell.is-locked img {
  filter: grayscale(1) brightness(0.9) opacity(0.22);
}

/* Complete-collection state */
.collectable-complete {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 0.5rem 0 0.75rem;
  gap: 0.1rem;
}

.collectable-complete-title {
  font-size: 1rem;
  font-weight: 800;
  color: #0F172A;
  margin-top: 0.25rem;
}

.collectable-complete-sub {
  font-size: 0.72rem;
  color: #64748B;
}
