/* =============================================================
   Document Inspector — tool-specific styles
   Built on the shared design system (styles.css).
   ============================================================= */

.di-source { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 16px 18px; margin-bottom: 14px; }
.di-source .grow { flex: 1 1 220px; min-width: 0; }
.di-source .ic { width: 18px; height: 18px; }

.di.droplit { outline: 2px dashed var(--brand); outline-offset: -8px; border-radius: 12px; }
.di-toast { position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(20px);
  background: #1f2430; color: #fff; padding: 10px 16px; border-radius: 10px; font-size: 14px; box-shadow: 0 8px 26px rgba(0,0,0,.28);
  opacity: 0; pointer-events: none; transition: opacity .18s, transform .18s; z-index: 60; max-width: 90vw; }
.di-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.di-toast.err { background: #7a1f1f; }

.di-block { display: flex; gap: 12px; align-items: center; padding: 16px 18px; }
.di-block-ico { font-size: 22px; }
.di-banner { display: flex; gap: 12px; align-items: center; padding: 16px 18px; }
.di-banner.ok { border-left: 4px solid #2e9e57; }
.di-banner-ico { font-size: 20px; color: #2e9e57; }
.di-banner-title { font-weight: 600; color: var(--text); }

/* ---- summary / action bar ---- */
.di-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; padding: 14px 18px; margin-bottom: 14px; }
.di-summary .grow { flex: 1 1 auto; }
.di-sum-text { font-size: 14px; color: var(--text); }
.di-sum-n { font-size: 20px; font-weight: 700; color: var(--brand); font-variant-numeric: tabular-nums; }
.di-selall { display: inline-flex; align-items: center; gap: 7px; font-size: 14px; color: var(--text); cursor: pointer; }

/* ---- groups ---- */
.di-group { padding: 6px 18px 10px; margin-bottom: 14px; }
.di-group-h { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--text-soft); font-weight: 700; padding: 12px 0 4px; }
.di-group-note { font-size: 12.5px; color: var(--text-soft); margin: 0 0 6px; line-height: 1.5; }

/* ---- rows ---- */
.di-row { display: grid; grid-template-columns: 26px minmax(180px, 1.2fr) minmax(0, 1fr) 92px; align-items: center;
  gap: 12px; padding: 11px 6px; border-top: 1px solid var(--border); cursor: pointer; }
.di-row:first-of-type { border-top: none; }
.di-cb { display: flex; justify-content: center; }
.di-cb input { width: 16px; height: 16px; cursor: pointer; }
.di-main { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.di-title { font-size: 14.5px; color: var(--text); font-weight: 600; display: flex; align-items: center; gap: 8px; }
.di-count { display: inline-flex; align-items: center; justify-content: center; min-width: 20px; height: 18px; padding: 0 6px;
  border-radius: 999px; background: var(--bg-elev); border: 1px solid var(--border); color: var(--text-soft);
  font-size: 11.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.di-desc { font-size: 12px; color: var(--text-soft); line-height: 1.45; }
.di-mid { min-width: 0; }
.di-detail { font-size: 12.5px; color: var(--text-soft); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.di-act { display: flex; justify-content: flex-end; }
.di-tag { font-size: 11px; font-weight: 600; padding: 2px 9px; border-radius: 999px; text-transform: lowercase; letter-spacing: .02em; white-space: nowrap; }
.di-tag.remove { background: #f3d9d4; color: #a3341c; }
.di-tag.reveal { background: #dfe6f7; color: #33499a; }
[data-theme="dark"] .di-tag.remove { background: #3a201a; color: #e79079; }
[data-theme="dark"] .di-tag.reveal { background: #1f2740; color: #93a8e6; }

.di-legal { margin-top: 22px; font-size: 12px; color: var(--text-soft); line-height: 1.6; }
.di-legal p { margin: 2px 0; }

@media (max-width: 640px) {
  .di-row { grid-template-columns: 24px 1fr 74px; }
  .di-mid { grid-column: 2 / 4; }
}
