/* Diff Checker — side-by-side inputs and the color-coded unified output. */

.diff-panes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.diff-pane-col {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.diff-pane-label {
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
}

.diff-pane { min-height: 200px; }

@media (max-width: 720px) {
  .diff-panes { grid-template-columns: 1fr; }
}

.diff-output {
  margin-top: 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  max-height: 480px;
  overflow: auto;
  font-family: var(--mono);
  font-size: 0.85rem;
  line-height: 1.55;
}

.diff-line {
  display: flex;
  gap: 10px;
  padding: 0 10px;
  white-space: pre-wrap;
  word-break: break-word;
}

.diff-marker {
  flex: 0 0 1ch;
  color: var(--muted);
  user-select: none;
  text-align: center;
}

.diff-text { flex: 1; min-width: 0; }

.diff-line.del {
  background: rgba(220, 38, 38, 0.1);
  color: #b91c1c;
}

.diff-line.del .diff-marker { color: #b91c1c; }

.diff-line.add {
  background: rgba(22, 163, 74, 0.1);
  color: #15803d;
}

.diff-line.add .diff-marker { color: #15803d; }

@media (prefers-color-scheme: dark) {
  .diff-line.del { background: rgba(248, 113, 113, 0.14); color: #fca5a5; }
  .diff-line.del .diff-marker { color: #fca5a5; }
  .diff-line.add { background: rgba(74, 222, 128, 0.12); color: #86efac; }
  .diff-line.add .diff-marker { color: #86efac; }
}
