/* Interaction Log — action badges, batch chips, and the revert preview list. */

.audit-action {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
    line-height: 1.6;
    white-space: nowrap;
}

/* Suffix comes from the raw action value, not its label — see actionBadge()
   in js/audit-table.js. */
.audit-action-create  { background: #e6fffa; color: #234e52; }
.audit-action-update  { background: #ebf8ff; color: #2a4365; }
.audit-action-delete  { background: #fff5f5; color: #742a2a; }
.audit-action-restore { background: #f0fff4; color: #22543d; }
.audit-action-revert  { background: #faf5ff; color: #44337a; }

/* Batch chip — clicking it selects every row from the same request. */
.audit-batch-chip {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 11px;
    padding: 2px 6px;
    border: 1px solid #cbd5e0;
    border-radius: 4px;
    background: #f7fafc;
    color: #4a5568;
    cursor: pointer;
}

.audit-batch-chip:hover {
    border-color: #4299e1;
    color: #2b6cb0;
}

/* ── Revert preview ── */

#revert-confirm-modal .card {
    max-width: 720px;
}

/* The list can run long; keep it scrolling inside the dialog so the footer
   buttons stay reachable. */
.revert-preview {
    max-height: 55vh;
    overflow-y: auto;
}

.revert-summary {
    margin-bottom: 12px;
    color: #4a5568;
}

.revert-entry {
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    padding: 10px 12px;
    margin-bottom: 8px;
}

/* Wraps rather than squeezing the record name to one word per line when the
   dialog is narrow — the meta drops to its own row instead. */
.revert-entry-head {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 2px 12px;
    align-items: baseline;
    margin-bottom: 6px;
}

.revert-entry-title {
    font-weight: 600;
    min-width: 0;
    flex: 1 1 auto;
}

.revert-entry-meta {
    font-size: 12px;
    color: #718096;
    white-space: nowrap;
}

.revert-status {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.revert-status-ok      { color: #276749; }
.revert-status-partial { color: #975a16; }
.revert-status-skipped { color: #718096; }
.revert-status-error   { color: #c53030; }

.revert-field {
    font-size: 13px;
    padding: 3px 0;
    border-top: 1px dashed #edf2f7;
}

.revert-field-conflict {
    color: #975a16;
}

.revert-field-label {
    font-weight: 600;
}

.revert-note {
    font-size: 12px;
    color: #975a16;
    margin-top: 6px;
}

.revert-empty {
    color: #718096;
    font-style: italic;
}
