/* Audit log UI improvements. */

/* Quick stats row above the grid */
.audit-stats {
    display: flex;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: linear-gradient(135deg, #f0f9ff 0%, #f5f3ff 100%);
    border: 1px solid #e0e7ff;
    border-radius: 8px;
    flex-wrap: wrap;
}
.audit-stat {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding-right: 1.5rem;
    border-right: 1px solid #c7d2fe;
}
.audit-stat:last-child { border-right: none; }
.audit-stat strong {
    font-size: 1.4rem;
    color: #4338ca;
    line-height: 1;
}
.audit-stat small {
    font-size: 0.75rem;
    color: #6b7280;
    margin-top: 4px;
}

/* Detail dialog — meta + diff */
.audit-detail-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 0.5rem;
    padding: 0.75rem;
    background: #f9fafb;
    border-radius: 6px;
    font-size: 0.9rem;
}

.audit-detail-diff {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
}
.audit-diff-col {
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.audit-diff-header {
    padding: 6px 10px;
    font-weight: 600;
    font-size: 0.85rem;
    border-bottom: 1px solid #e5e7eb;
}
.audit-diff-header--before {
    background: #fef2f2;
    color: #991b1b;
}
.audit-diff-header--after {
    background: #f0fdf4;
    color: #166534;
}
.audit-diff-content {
    flex: 1;
    margin: 0;
    padding: 10px 12px;
    font-family: 'Consolas', 'Monaco', monospace;
    font-size: 0.78rem;
    line-height: 1.45;
    max-height: 50vh;
    overflow: auto;
    white-space: pre;
    background: white;
}

@media (max-width: 700px) {
    .audit-detail-diff { grid-template-columns: 1fr; }
}
