/* <extraction-result> : état vide, synthèse, champs, détails, comparaison. */

extraction-result { display: block; }
.result-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.result-head h2 { font-size: 18px; letter-spacing: -0.01em; }
.result-head p { font-size: 13px; color: var(--muted); margin-top: 2px; }

.empty-state { height: 100%; min-height: 370px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 14px; color: var(--muted); }
.empty-state .badge-icon { width: 48px; height: 48px; border-radius: 12px; background: var(--surface-2); display: grid; place-items: center; color: var(--faint); }
.empty-state .badge-icon .i { width: 24px; height: 24px; }
.empty-state h2 { font-size: 16px; color: var(--text); }
.empty-state ol { margin: 4px 0 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 14px; text-align: left; }
.empty-state li { display: flex; gap: 10px; align-items: center; }
@media (max-width: 960px) { .empty-state { min-height: 220px; } }

.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 1100px) { .tiles { grid-template-columns: 1fr 1fr; } .tiles .tile:first-child { grid-column: 1 / -1; } }
@media (max-width: 520px) { .tiles { grid-template-columns: 1fr; } }
.tile { border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; display: grid; gap: 4px; align-content: start; }
.tile-label { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.tile-value { display: flex; align-items: center; gap: 8px; font-size: 20px; font-weight: 650; letter-spacing: -0.01em; font-variant-numeric: tabular-nums; }
.tile-sub { font-size: 13px; color: var(--muted); }
.tone-ok { color: var(--ok); } .tone-warn { color: var(--warn); } .tone-bad { color: var(--bad); } .tone-none { color: var(--none); }
.bar { height: 4px; border-radius: 2px; background: var(--surface-2); overflow: hidden; margin-top: 6px; }
.bar span { display: block; height: 100%; border-radius: 2px; background: currentColor; }

.section-title { font-size: 14px; font-weight: 600; margin: 28px 0 10px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }

.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border: 1px solid var(--border); border-radius: 10px; overflow: hidden; margin: 0; }
@media (max-width: 720px) { .fields { grid-template-columns: 1fr; } }
.field { padding: 10px 8px 10px 14px; border-bottom: 1px solid var(--border); min-width: 0; display: flex; align-items: center; gap: 8px; }
.fields .field:nth-child(odd) { border-right: 1px solid var(--border); }
@media (max-width: 720px) { .fields .field:nth-child(odd) { border-right: 0; } }
.field-body { flex: 1; min-width: 0; }
.field dt { font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
.field dd { margin: 1px 0 0; font-weight: 500; overflow-wrap: anywhere; }
.field dd.none { color: var(--faint); font-weight: 400; }
.field.flag { background: var(--diff-bg); }
.fields .field:last-child, .fields.even .field:nth-last-child(2) { border-bottom: 0; }
@media (max-width: 720px) { .fields.even .field:nth-last-child(2) { border-bottom: 1px solid var(--border); } }

.kv { display: grid; grid-template-columns: 140px 1fr; gap: 4px 12px; }
@media (max-width: 520px) { .kv { grid-template-columns: 1fr; } .kv dt { margin-top: 6px; } }
.kv dt { color: var(--muted); } .kv dd { margin: 0; }
.signals { margin: 0; padding-left: 18px; color: var(--muted); }
pre, .mrz { font-family: var(--mono); font-size: 12.5px; background: var(--surface-2); border-radius: 8px; padding: 12px; margin: 0; overflow-x: auto; }
.mrz { letter-spacing: .08em; line-height: 1.7; white-space: pre; }
pre { max-height: 420px; }

.engines { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 720px) { .engines { grid-template-columns: 1fr; } }
.engine-card { border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; display: grid; gap: 10px; align-content: start; }
.engine-card h3 { font-size: 15px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.engine-card h3 span { font-size: 12px; font-weight: 400; color: var(--muted); }
.mini { display: grid; grid-template-columns: auto 1fr; gap: 6px 12px; font-size: 14px; }
.mini dt { color: var(--muted); } .mini dd { margin: 0; font-weight: 600; text-align: right; }
.cmp { width: 100%; border-collapse: collapse; font-size: 14px; }
.cmp th, .cmp td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; overflow-wrap: anywhere; }
.cmp thead th { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); font-weight: 600; background: var(--surface-2); }
.cmp tbody th { font-weight: 400; color: var(--muted); width: 32%; }
.cmp td { font-weight: 500; }
.cmp tr.diff th, .cmp tr.diff td { background: var(--diff-bg); }
.cmp tbody tr:last-child > * { border-bottom: 0; }
.table-wrap { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
@media (max-width: 640px) {
  .cmp thead { display: none; }
  .cmp, .cmp tbody, .cmp tr, .cmp th, .cmp td { display: block; width: 100%; }
  .cmp tr { padding: 8px 0; border-bottom: 1px solid var(--border); }
  .cmp tbody tr:last-child { border-bottom: 0; }
  .cmp th, .cmp td { border: 0; padding: 2px 12px; }
  .cmp tbody th { width: 100%; font-size: 12px; }
  .cmp td::before { content: attr(data-label) " · "; color: var(--muted); font-weight: 400; }
}
.none-val { color: var(--faint); font-weight: 400; }
