/* MORPH — feature additions loaded after styles.css. */

.compare-wrap {
  width: 100%;
  display: grid;
  gap: 8px;
  justify-items: center;
}

.compare-stage {
  position: relative;
  display: grid;
  place-items: center;
  width: 100%;
  max-width: 560px;
  overflow: hidden;
  background: var(--checker) 0 0 / 14px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  cursor: ew-resize;
  touch-action: none;
}

.compare-stage > img,
.compare-before img {
  grid-area: 1 / 1;
  display: block;
  max-width: 100%;
  max-height: 360px;
  object-fit: contain;
}

.compare-before {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  clip-path: inset(0 50% 0 0);
}

.compare-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 2px;
  background: var(--cyan);
  box-shadow: 0 0 14px rgba(69, 240, 255, 0.6);
}

.compare-divider::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 42px;
  border: 1px solid var(--cyan);
  border-radius: 999px;
  background: var(--surface-2);
  transform: translate(-50%, -50%);
}

.compare-labels {
  width: min(100%, 560px);
  display: flex;
  justify-content: space-between;
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
  letter-spacing: 1px;
}

@media (max-width: 480px) {
  .batch-head,
  .target-row {
    grid-template-columns: 1fr;
  }

  .batch-head {
    flex-direction: column;
  }

  .batch-actions,
  .batch-actions .btn,
  .batch-item-actions,
  .batch-item-actions .btn {
    width: 100%;
  }

  .batch-item {
    grid-template-columns: 48px minmax(0, 1fr);
  }

  .batch-item-actions {
    grid-column: 1 / -1;
  }

  .compare-stage > img,
  .compare-before img {
    max-height: 300px;
  }
}
