:root {
  --bg: #F7F5F1;
  --panel: #FFFFFF;
  --ink-1: #1B1B1F;
  --ink-2: #51525A;
  --ink-3: #84858E;
  --line: #E5E2DC;
  --accent: #1F3A5F;
  --accent-soft: #E6EBF2;
  --ok: #2F7E4D;
  --ok-soft: #DDF0E3;
  --warn: #B5651D;
  --warn-soft: #F8E9D5;
  --alert: #9E2B2B;
  --alert-soft: #F4D9D9;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  background: var(--bg);
  color: var(--ink-1);
  line-height: 1.5;
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

/* SIDEBAR */
.sidebar {
  background: var(--panel);
  border-right: 1px solid var(--line);
  padding: 28px 18px;
  display: flex;
  flex-direction: column;
  gap: 22px;
}

.brand {
  display: flex; align-items: center; gap: 10px;
  padding: 0 6px;
}

.logo {
  width: 36px; height: 36px;
  background: var(--accent);
  color: white;
  border-radius: 9px;
  display: grid; place-items: center;
  font-weight: 700;
  font-size: 16px;
}

.brand-name {
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

nav { display: flex; flex-direction: column; gap: 2px; flex: 1; }

.nav-link {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  border-radius: 7px;
  color: var(--ink-2);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  position: relative;
  transition: 0.15s;
}

.nav-link:hover { background: var(--bg); color: var(--ink-1); }
.nav-link.active { background: var(--accent-soft); color: var(--accent); }

.nav-icon {
  font-size: 13px;
  width: 18px; display: inline-block; text-align: center;
  color: var(--ink-3);
}

.nav-link.active .nav-icon { color: var(--accent); }

.badge {
  margin-left: auto;
  background: var(--alert);
  color: white;
  font-size: 11px;
  padding: 1px 7px;
  border-radius: 10px;
  font-weight: 600;
}

.profile {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 8px;
  border-top: 1px solid var(--line);
}

.avatar {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, #C2A878, #8B6F47);
  color: white;
  border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 600; font-size: 13px;
}

.profile-name { font-size: 13px; font-weight: 600; }
.profile-role { font-size: 11px; color: var(--ink-3); }

/* MAIN */
main { padding: 28px 40px 60px; max-width: 1280px; }

header {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: 28px;
}

.breadcrumb { font-size: 12px; color: var(--ink-3); margin-bottom: 4px; }
h1 { font-size: 26px; font-weight: 600; letter-spacing: -0.02em; }

.header-actions { display: flex; gap: 10px; }

.btn-primary, .btn-secondary {
  padding: 9px 16px;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  border: 1px solid transparent;
  transition: 0.15s;
}

.btn-primary {
  background: var(--accent);
  color: white;
  border-color: var(--accent);
}
.btn-primary:hover { background: #2A4D7A; }

.btn-secondary {
  background: transparent;
  color: var(--ink-2);
  border-color: var(--line);
}
.btn-secondary:hover { background: var(--panel); }

.btn-link {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
}
.btn-link:hover { text-decoration: underline; }

/* KPIs */
.kpis {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 26px;
}

.kpi {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 18px 20px;
}

.kpi-label { font-size: 12px; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; }
.kpi-value { font-size: 32px; font-weight: 600; letter-spacing: -0.02em; margin: 6px 0 4px; }
.kpi-value.alert { color: var(--alert); }
.kpi-sub { font-size: 12px; color: var(--ink-3); }
.kpi-sub a { color: var(--accent); text-decoration: none; font-weight: 500; }

/* CARDS */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 22px;
  margin-bottom: 18px;
}

.card-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 16px;
}

.card-header h3 {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.card-header a {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
}

.grid-2 {
  display: grid; grid-template-columns: 3fr 2fr;
  gap: 18px; margin-bottom: 18px;
}

/* TABLES */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.data-table th {
  text-align: left;
  font-weight: 600;
  color: var(--ink-3);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
}

.data-table td {
  padding: 12px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.data-table tr:last-child td { border-bottom: none; }
.data-table tr.clickable { cursor: pointer; }
.data-table tr.clickable:hover { background: var(--bg); }

.cell-sub { font-size: 11px; color: var(--ink-3); margin-top: 2px; }

/* PILLS */
.pill {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
}
.pill.ok { background: var(--ok-soft); color: var(--ok); }
.pill.warn { background: var(--warn-soft); color: var(--warn); }
.pill.alert { background: var(--alert-soft); color: var(--alert); }

/* TASK LIST */
.task-list { list-style: none; }
.task-list li {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.task-list li:last-child { border-bottom: none; }

.task-icon {
  width: 28px; height: 28px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-weight: 700;
  font-size: 13px;
  flex-shrink: 0;
}
.task-icon.alert { background: var(--alert-soft); color: var(--alert); }
.task-icon.info { background: var(--accent-soft); color: var(--accent); }
.task-icon.ok { background: var(--ok-soft); color: var(--ok); }

.task-list li > div:nth-child(2) { flex: 1; }
.task-sub { font-size: 11px; color: var(--ink-3); margin-top: 2px; }

/* ACTIVITY BARS */
.activity-bars { display: flex; flex-direction: column; gap: 12px; }
.bar-row { display: grid; grid-template-columns: 200px 1fr; gap: 14px; align-items: center; }
.bar-label { font-size: 13px; color: var(--ink-2); }
.bar-track {
  background: var(--bg);
  border-radius: 4px;
  height: 22px;
  position: relative;
  border: 1px solid var(--line);
}
.bar-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 3px;
  color: white;
  font-size: 11px;
  font-weight: 600;
  padding: 0 8px;
  display: flex; align-items: center;
  min-width: 36px;
}
.bar-fill.ok { background: var(--ok); }
.bar-fill.warn { background: var(--warn); }

/* AUDIOGRAMA (canvas-like) */
.audiogram {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 20px;
}

.audio-side {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px;
  background: var(--panel);
}

.audio-title {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink-3);
  margin-bottom: 12px;
}

.audio-chart {
  position: relative;
  height: 220px;
  border-left: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

/* EXAM COMPARISON */
.exam-matrix {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 16px;
}

.exam-matrix th, .exam-matrix td {
  padding: 8px;
  text-align: center;
  border: 1px solid var(--line);
}

.exam-matrix th {
  background: var(--bg);
  font-weight: 600;
  color: var(--ink-2);
  font-size: 11px;
}

.exam-matrix .freq-col { text-align: left; font-weight: 600; }

.delta-positive { background: #F4D9D9; color: var(--alert); font-weight: 600; }
.delta-mild { background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.delta-stable { color: var(--ink-3); }
.delta-improve { background: var(--ok-soft); color: var(--ok); font-weight: 600; }

/* CLASSIFICATION SUGGESTION */
.suggestion {
  background: var(--bg);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  padding: 16px;
  border-radius: 6px;
  margin-top: 18px;
}

.suggestion-header {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 8px;
}

.suggestion-tag {
  background: var(--accent);
  color: white;
  padding: 3px 10px;
  border-radius: 11px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.suggestion-body {
  font-size: 14px;
  color: var(--ink-1);
  margin-bottom: 8px;
}

.suggestion-rule {
  font-size: 12px;
  color: var(--ink-3);
  margin-bottom: 12px;
  font-family: monospace;
}

.suggestion-actions { display: flex; gap: 8px; }

/* DROPZONE */
.dropzone {
  border: 2px dashed var(--line);
  border-radius: 10px;
  padding: 60px 20px;
  text-align: center;
  background: var(--panel);
  transition: 0.2s;
}
.dropzone:hover { border-color: var(--accent); background: var(--accent-soft); }
.dropzone-icon { font-size: 40px; color: var(--ink-3); margin-bottom: 12px; }
.dropzone-text { font-size: 16px; font-weight: 500; }
.dropzone-sub { font-size: 13px; color: var(--ink-3); margin-top: 4px; }

/* TIMELINE */
.timeline {
  position: relative;
  margin-top: 20px;
  padding-left: 20px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 5px;
  top: 8px;
  bottom: 8px;
  width: 1px;
  background: var(--line);
}

.timeline-item {
  position: relative;
  padding-bottom: 22px;
}

.timeline-dot {
  position: absolute;
  left: -20px;
  top: 6px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--panel);
  border: 2px solid var(--accent);
}

.timeline-item.alert .timeline-dot { border-color: var(--alert); }
.timeline-item.warn .timeline-dot { border-color: var(--warn); }

.timeline-date { font-size: 12px; color: var(--ink-3); font-weight: 600; }
.timeline-title { font-size: 14px; font-weight: 500; margin: 2px 0 4px; }
.timeline-detail { font-size: 12px; color: var(--ink-2); }

/* AUDITORIA */
.audit-row {
  display: grid;
  grid-template-columns: 120px 1fr 100px 160px;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  align-items: center;
}

.audit-time { color: var(--ink-3); font-size: 12px; }
.audit-event { color: var(--ink-1); }
.audit-event strong { font-weight: 600; }
.audit-actor { color: var(--ink-2); }
.audit-hash { font-family: monospace; font-size: 11px; color: var(--ink-3); }

/* RESPONSIVE */
@media (max-width: 900px) {
  body { grid-template-columns: 1fr; }
  .sidebar { display: none; }
  main { padding: 18px; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
  .grid-2 { grid-template-columns: 1fr; }
}

/* ─────── extra components ─────── */

/* FILTER BAR */
.filterbar {
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
  align-items: center;
  flex-wrap: wrap;
}
.search {
  flex: 1; min-width: 260px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 7px;
  font-size: 13px;
  background: var(--panel);
  font-family: inherit;
}
.search:focus { outline: none; border-color: var(--accent); }
.filter-select {
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  font-size: 13px;
  background: var(--panel);
  cursor: pointer;
  font-family: inherit;
  color: var(--ink-2);
}

.card.no-pad { padding: 0; overflow: hidden; }
.card.no-pad .data-table { padding: 0; }
.card.no-pad .data-table th { padding-left: 22px; padding-right: 22px; padding-top: 14px; padding-bottom: 10px; background: var(--bg); }
.card.no-pad .data-table td { padding-left: 22px; padding-right: 22px; }

.data-table .num { text-align: right; }
.data-table th.num { text-align: right; }
.data-table .mono { font-family: ui-monospace, "SF Mono", "Roboto Mono", monospace; font-size: 12px; color: var(--ink-2); }

.pill.accent { background: var(--accent-soft); color: var(--accent); }

.table-footer {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 22px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--ink-3);
  background: var(--bg);
}
.pagination { display: flex; gap: 4px; }
.pg-btn {
  width: 28px; height: 28px;
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 5px;
  cursor: pointer;
  font-size: 12px;
  color: var(--ink-2);
}
.pg-btn:hover:not(:disabled) { border-color: var(--accent); }
.pg-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.pg-btn.pg-active { background: var(--accent); color: white; border-color: var(--accent); }

/* EMPRESA HEADER (drill-down) */
.entity-header {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 22px 26px;
  margin-bottom: 18px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
}
.entity-title { font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }
.entity-meta { font-size: 13px; color: var(--ink-3); margin-top: 4px; display: flex; gap: 14px; flex-wrap: wrap; }
.entity-meta span:not(:last-child)::after { content: '·'; margin-left: 14px; color: var(--ink-3); }
.entity-actions { display: flex; gap: 8px; }

/* TABS */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 18px;
}
.tab {
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
}
.tab:hover { color: var(--ink-1); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }

/* MICRO STATS ROW */
.micro-stats {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-bottom: 18px;
}
.micro-stat {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px 16px;
}
.ms-label { font-size: 11px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--ink-3); font-weight: 600; }
.ms-value { font-size: 22px; font-weight: 600; margin-top: 4px; letter-spacing: -0.01em; }
.ms-delta { font-size: 11px; margin-top: 2px; }
.ms-delta.up { color: var(--alert); }
.ms-delta.down { color: var(--ok); }
.ms-delta.flat { color: var(--ink-3); }

/* DROPZONE QUEUE */
.queue-table { font-size: 13px; }
.queue-row {
  display: grid;
  grid-template-columns: 32px 2fr 1fr 100px 130px;
  gap: 14px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.queue-row:last-child { border-bottom: none; }
.queue-icon {
  width: 28px; height: 28px;
  background: var(--accent-soft); color: var(--accent);
  border-radius: 6px;
  display: grid; place-items: center;
  font-size: 11px; font-weight: 700;
}
.queue-icon.done { background: var(--ok-soft); color: var(--ok); }
.queue-icon.processing { background: var(--warn-soft); color: var(--warn); }
.queue-file { font-weight: 500; }
.queue-sub { font-size: 11px; color: var(--ink-3); margin-top: 2px; }
.progress {
  width: 100%; height: 6px;
  background: var(--bg);
  border-radius: 3px;
  overflow: hidden;
}
.progress-bar {
  height: 100%; background: var(--accent);
  border-radius: 3px;
}

/* REVISÃO QUEUE — case cards */
.case-list { display: flex; flex-direction: column; gap: 12px; }
.case-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
  padding: 18px 20px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: start;
}
.case-card.alert { border-left-color: var(--alert); }
.case-card.warn { border-left-color: var(--warn); }
.case-card.ok { border-left-color: var(--ok); }

.case-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.case-name { font-size: 15px; font-weight: 600; }
.case-meta { font-size: 12px; color: var(--ink-3); }
.case-body { font-size: 13px; color: var(--ink-2); margin-bottom: 10px; }
.case-rule { font-size: 12px; color: var(--ink-3); font-family: ui-monospace, monospace; padding: 6px 10px; background: var(--bg); border-radius: 5px; margin-top: 8px; }
.case-actions { display: flex; flex-direction: column; gap: 6px; min-width: 140px; }

/* TIMELINE ENHANCED (worker) */
.worker-summary {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 18px;
  margin-bottom: 18px;
}
.worker-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 22px;
}
.worker-photo {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, #C2A878, #8B6F47);
  border-radius: 50%;
  display: grid; place-items: center;
  color: white;
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 14px;
}
.worker-name { font-size: 18px; font-weight: 600; }
.worker-role { font-size: 13px; color: var(--ink-3); margin-bottom: 14px; }
.worker-attr { display: flex; justify-content: space-between; font-size: 13px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.worker-attr:last-child { border-bottom: none; }
.worker-attr-label { color: var(--ink-3); }

/* AUDIOGRAM PLOT (SVG) */
.audiogram-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin: 22px 0;
}
.audiogram-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 14px;
}
.audiogram-card h4 {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--ink-2);
}
.audiogram-svg { width: 100%; height: auto; }

/* DOCUMENTS LIST */
.doc-list { display: flex; flex-direction: column; gap: 10px; }
.doc-item {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 16px 20px;
  display: grid;
  grid-template-columns: 38px 1fr auto auto;
  gap: 16px;
  align-items: center;
}
.doc-thumb {
  width: 38px; height: 46px;
  background: linear-gradient(180deg, #F4F1EA, #E5E2DC);
  border: 1px solid var(--line);
  border-radius: 4px;
  position: relative;
}
.doc-thumb::after {
  content: 'PCA';
  position: absolute; bottom: 4px; left: 0; right: 0;
  text-align: center;
  font-size: 8px; font-weight: 600;
  color: var(--ink-3);
}
.doc-title { font-weight: 600; font-size: 14px; }
.doc-sub { font-size: 12px; color: var(--ink-3); margin-top: 2px; }

/* AUDIT LIST */
.audit-list {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.audit-list .audit-head {
  display: grid;
  grid-template-columns: 140px 1fr 120px 180px;
  gap: 16px;
  background: var(--bg);
  padding: 12px 22px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 600;
  color: var(--ink-3);
  border-bottom: 1px solid var(--line);
}
.audit-list .audit-row {
  grid-template-columns: 140px 1fr 120px 180px;
  padding: 12px 22px;
}

/* RULES EDITOR */
.rules-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 18px;
}
.rules-list {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
.rules-list h3 { padding: 16px 18px; font-size: 13px; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; border-bottom: 1px solid var(--line); }
.rule-link {
  display: block;
  padding: 12px 18px;
  font-size: 14px;
  color: var(--ink-2);
  text-decoration: none;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.rule-link:hover { background: var(--bg); color: var(--ink-1); }
.rule-link.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; border-left: 3px solid var(--accent); padding-left: 15px; }
.rule-sub { font-size: 11px; color: var(--ink-3); display: block; margin-top: 2px; }

.rule-editor {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 26px;
}
.rule-editor h2 { font-size: 18px; margin-bottom: 4px; }
.rule-editor .rule-source { font-size: 12px; color: var(--ink-3); margin-bottom: 22px; }

.form-group { margin-bottom: 18px; }
.form-label { font-size: 12px; font-weight: 600; color: var(--ink-3); text-transform: uppercase; letter-spacing: 0.04em; display: block; margin-bottom: 6px; }
.form-input, .form-textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  font-size: 14px;
  background: var(--bg);
  font-family: inherit;
}
.form-input:focus, .form-textarea:focus { outline: none; border-color: var(--accent); background: var(--panel); }
.form-textarea { min-height: 80px; font-family: ui-monospace, monospace; font-size: 13px; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.toggle {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px;
  color: var(--ink-2);
  cursor: pointer;
}
.toggle input { display: none; }
.toggle .switch {
  width: 32px; height: 18px;
  background: var(--line);
  border-radius: 10px;
  position: relative;
  transition: 0.2s;
}
.toggle .switch::after {
  content: ''; position: absolute;
  top: 2px; left: 2px;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: white;
  transition: 0.2s;
}
.toggle input:checked + .switch { background: var(--accent); }
.toggle input:checked + .switch::after { left: 16px; }

.rule-divider { border: none; border-top: 1px solid var(--line); margin: 22px 0; }

/* INFO BANNER */
.info-banner {
  background: var(--accent-soft);
  border: 1px solid #c9d4e3;
  border-radius: 8px;
  padding: 14px 18px;
  font-size: 13px;
  color: var(--accent);
  margin-bottom: 18px;
  display: flex; gap: 12px;
  align-items: center;
}
.info-banner-icon { font-size: 18px; }
.info-banner.warn { background: var(--warn-soft); border-color: #e8d2b1; color: var(--warn); }
.info-banner.alert { background: var(--alert-soft); border-color: #e2b6b6; color: var(--alert); }

/* MATRIZ AUDIOMÉTRICA com diff */
.matrix-wrap { overflow-x: auto; }
.matrix {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin-top: 12px;
}
.matrix th, .matrix td {
  padding: 8px 10px;
  text-align: center;
  border: 1px solid var(--line);
  min-width: 50px;
}
.matrix th {
  background: var(--bg);
  font-weight: 600;
  color: var(--ink-2);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.matrix th.row-head, .matrix td.row-head { text-align: left; background: var(--bg); font-weight: 600; min-width: 100px; }
.matrix .ear-head { background: var(--accent); color: white; }
.matrix .delta-bad { background: #F4D9D9; color: var(--alert); font-weight: 700; }
.matrix .delta-mild { background: var(--warn-soft); color: var(--warn); font-weight: 600; }
.matrix .delta-stable { color: var(--ink-2); }
.matrix .delta-improve { background: var(--ok-soft); color: var(--ok); font-weight: 600; }


/* --- Adições para suporte às páginas dinâmicas (25/05) --- */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  padding: 4px 0;
}
.kpi {
  background: #fbf8f2;
  padding: 16px 18px;
  border-radius: 8px;
  border: 1px solid var(--line);
}
.tl-item {
  display: grid;
  grid-template-columns: 90px 18px 1fr;
  gap: 12px;
  padding: 10px 0;
  align-items: start;
  border-bottom: 1px dashed var(--line);
}
.tl-item:last-child { border-bottom: none; }
.tl-date { font-size: 12px; color: var(--ink-3); font-weight: 600; padding-top: 2px; }
.tl-dot {
  width: 12px; height: 12px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: white;
  margin-top: 4px;
}
.tl-dot.last { background: var(--accent); }
.tl-body { font-size: 13px; line-height: 1.5; }
.rule-cite {
  background: #fbf6e9;
  border-left: 3px solid var(--warn-ink, #c87);
  padding: 12px 14px;
  border-radius: 0 4px 4px 0;
  font-size: 12px;
  line-height: 1.6;
}
/* pill alert variant */
.pill.alert {
  background: rgba(180, 50, 50, 0.13);
  color: var(--alert);
}
