:root { --bg: #f4f5f7; --card: #fff; --text: #1f2937; --muted: #6b7280; --line: #e5e7eb; --brand: #1f3a5f; --link: #1d6fa5; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
header { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; padding: 10px 20px; background: var(--brand); color: #fff; }
header a { color: #dbe7f5; text-decoration: none; margin-right: 12px; }
header a.active, header a:hover { color: #fff; font-weight: 600; }
.brand { margin-right: 12px; }
main { max-width: 1280px; margin: 0 auto; padding: 16px 20px 40px; }
h1 { font-size: 22px; margin: 8px 0 14px; }
h2 { font-size: 15px; margin: 0 0 8px; }
a { color: var(--link); }
table { width: 100%; border-collapse: collapse; background: var(--card); border-radius: 6px; overflow: hidden; margin-bottom: 18px; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: #f9fafb; font-weight: 600; font-size: 13px; }
td.post { max-width: 420px; }
.muted { color: var(--muted); font-size: 12px; }
.card { background: var(--card); border-radius: 6px; padding: 14px 16px; margin-bottom: 16px; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.stat .label { color: var(--muted); font-size: 12px; } .stat .value { font-size: 24px; font-weight: 700; } .stat .value.small { font-size: 15px; }
.charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(380px, 1fr)); gap: 12px; }
.chart-box { position: relative; height: 220px; }
.badge { display: inline-block; padding: 1px 8px; border-radius: 10px; font-size: 12px; background: #eef1f5; }
.level-critical { background: #fde2e1; color: #a61b1b; } .level-viral, .level-spike { background: #fdebd3; color: #9a4b00; }
.level-negative_spike { background: #efe3f7; color: #6b2a8f; } .level-watch { background: #fff6d6; color: #7a5d00; }
.status-active, .status-resolved { background: #dcf5e4; color: #146c2e; } .status-paused, .status-acknowledged { background: #e3ecfb; color: #1e4fa3; }
.status-client-disabled, .status-new { background: #f1f1f1; color: #555; }
.approval-pending { background: #fdecc8; color: #8a5300; } .approval-approved { background: #dcf5e4; color: #146c2e; } .approval-rejected { background: #f9dede; color: #9b1c1c; }
.sentiment-negative { background: #fde2e1; color: #a61b1b; } .sentiment-positive { background: #dcf5e4; color: #146c2e; }
.flash { background: #dcf5e4; color: #146c2e; padding: 8px 12px; border-radius: 6px; margin-bottom: 12px; }
.error { background: #fde2e1; color: #a61b1b; padding: 8px 12px; border-radius: 6px; margin-bottom: 12px; }
.filters, .sorts { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; margin-bottom: 12px; }
.sorts a { padding: 2px 8px; border-radius: 10px; text-decoration: none; } .sorts a.active { background: var(--brand); color: #fff; }
form.stack { display: grid; gap: 8px; max-width: 520px; } form.inline { display: inline; }
label { display: grid; gap: 3px; font-size: 13px; color: #374151; }
input, select, textarea { font: inherit; padding: 6px 8px; border: 1px solid #cbd5e1; border-radius: 4px; background: #fff; }
button { font: inherit; padding: 5px 12px; border: 1px solid #1f3a5f; background: #1f3a5f; color: #fff; border-radius: 4px; cursor: pointer; }
button:hover { opacity: .9; } .actions button { margin: 0 4px 4px 0; }
details pre { white-space: pre-wrap; max-width: 520px; font-size: 12px; }
code { font-size: 12px; background: #f3f4f6; padding: 1px 4px; border-radius: 3px; }
@media (max-width: 700px) { table { display: block; overflow-x: auto; } .charts { grid-template-columns: 1fr; } }

.sev-P1 { background: #c0392b; color: #fff; } .sev-P2 { background: #e67e22; color: #fff; }
.sev-P3 { background: #f1c40f; color: #333; } .sev-P4 { background: #dfe3e8; color: #333; }
.cl-trending { background: #fdecc8; color: #8a5300; } .cl-new { background: #e3ecfb; color: #1e4fa3; } .cl-cooling { background: #eef1f5; color: #555; }
.verdict-relevant { background: #dcf5e4; color: #146c2e; } .verdict-not_relevant { background: #f9dede; color: #9b1c1c; } .verdict-duplicate { background: #eef1f5; color: #555; }
button.small { font-size: 11px; padding: 2px 6px; }
.settings tr.overridden td:first-child { border-left: 3px solid var(--accent, #2f6fde); }
