.difference-layout {
  display: grid;
  gap: 18px;
}

.difference-top {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 16px;
}

.difference-board-card {
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
}

.difference-side-card {
  display: grid;
  gap: 14px;
  max-width: 1120px;
  width: 100%;
  margin: 0 auto;
}

.difference-stack {
  display: grid;
  gap: 16px;
}

.difference-board-status {
  margin-top: 0;
  margin-bottom: 14px;
}

.difference-image-card {
  position: relative;
  display: flex;
  justify-content: center;
  width: 100%;
  padding: 0;
  overflow: hidden;
  border-radius: 24px;
  border: 2px solid rgba(138, 180, 255, 0.22);
  background: rgba(9, 16, 30, 0.34);
  box-shadow: inset 0 10px 24px rgba(0, 0, 0, 0.2);
}

.difference-image {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
}

.difference-markers {
  position: absolute;
  inset: auto;
  pointer-events: none;
}

.difference-marker {
  position: absolute;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  border: 5px solid rgba(255, 89, 89, 0.96);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.2);
  background: rgba(255, 89, 89, 0.1);
}

.difference-image-card-wrong {
  animation: differenceMiss 220ms ease;
}

.difference-win-celebrate {
  animation: differenceWinCelebrate 520ms ease;
}

@keyframes differenceMiss {
  0% {
    transform: scale(1);
  }
  33% {
    transform: scale(0.992);
  }
  66% {
    transform: scale(1.006);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes differenceWinCelebrate {
  0% {
    transform: scale(0.92);
    opacity: 0.45;
  }
  60% {
    transform: scale(1.04);
    opacity: 1;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}

@media (min-width: 1080px) {
  .difference-stack {
    gap: 12px;
  }

  .difference-image-card {
    max-height: none;
  }

  .difference-image {
    max-height: none;
    object-fit: initial;
  }
}
