/* Claim–Evidence Map — page-specific styles only; shared primitives live in /assets/css/ai-tools.css and tools.css */
.cem-load { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px; margin-top: 14px; }
.cem-load .ait-drop small { font-size: 12.5px; }
.cem-job { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 12px; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
.cem-job progress { width: min(320px, 100%); height: 14px; accent-color: var(--m); }

.cem-filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px 18px; align-items: start; margin-bottom: 14px; }
.cem-filters select { min-height: 40px; max-width: 100%; }
.cem-checks { display: flex; flex-direction: column; gap: 4px; font-size: 14px; color: var(--ink-2); }
.cem-checks label { display: flex; align-items: center; gap: 8px; min-height: 40px; cursor: pointer; }
.cem-checks input { width: 20px; height: 20px; accent-color: var(--m); flex: none; }

.cem-claims, .cem-list, .cem-qs { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 14px; }
.cem-qs { list-style: decimal; padding-left: 1.4em; gap: 10px; font-size: 15px; color: var(--ink-2); max-width: 78ch; }
.cem-claim, .cem-note, .cem-sum-item { border: 2px solid var(--line-2); background: #fff; padding: 14px 16px; min-width: 0; }
.cem-claim.is-active { border-color: var(--m-side); box-shadow: inset 6px 0 0 var(--m); }
.cem-claim-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 12px; }
.cem-claim-head h4 { font: 850 1rem/1.3 var(--display); font-stretch: 106%; margin: 0; color: var(--ink); overflow-wrap: anywhere; }
.cem-claim-text { font-size: 15.5px; line-height: 1.55; color: var(--ink); margin: 8px 0 10px; overflow-wrap: anywhere; }
.cem-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.cem-chips .ait-tag { white-space: normal; max-width: 100%; line-height: 1.4; padding: 3px 8px; overflow-wrap: anywhere; }
.cem-details { margin-top: 8px; }
.cem-details > summary { cursor: pointer; font-size: 14px; font-weight: 750; color: var(--m-ink); min-height: 40px; display: flex; align-items: center; }
.cem-ev-list { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 12px; }
.cem-ev-item { border-left: 4px solid var(--line-2); padding: 4px 0 4px 12px; min-width: 0; }
.cem-ev-head { font-size: 13px; color: var(--ink-3); font-weight: 700; margin: 0 0 4px; overflow-wrap: anywhere; }
.cem-ev-head b { color: var(--ink); }
.cem-ev-text { font-size: 14.5px; color: var(--ink-2); margin: 0 0 4px; overflow-wrap: anywhere; }
.cem-sum-item .cem-ev-text, .cem-note .ait-note { margin-top: 2px; }
.cem-note p { margin: 0 0 6px; }
.cem-note a { text-decoration: underline; text-underline-offset: 2px; overflow-wrap: anywhere; }

.cem-paper { max-height: 560px; overflow: auto; border: 2px solid var(--line-2); background: #fff; padding: 14px 16px; min-width: 0; }
.cem-sec { font: 850 0.95rem/1.3 var(--display); color: var(--ink); margin: 16px 0 4px; }
.cem-sec:first-child { margin-top: 0; }
.cem-para { font-size: 15px; line-height: 1.65; color: var(--ink-2); margin: 0 0 10px; overflow-wrap: anywhere; }
.cem-plain { font-size: 14px; color: var(--ink-3); margin: 0 0 10px; overflow-wrap: anywhere; }
.cem-s[tabindex="0"] { cursor: pointer; text-decoration: underline dotted; text-underline-offset: 3px; }
.cem-s.cem-claim { background: var(--m-soft); color: var(--ink); box-shadow: inset 0 -3px 0 var(--m); }
.cem-s.cem-ev { color: #123f8c; text-decoration: underline; text-decoration-color: #123f8c; text-underline-offset: 3px; }
.cem-s.cem-on { outline: 3px solid var(--ink); outline-offset: 1px; }

.cem-map-wrap { margin-top: 14px; overflow-x: auto; border: 2px solid var(--line-2); background: #fff; padding: 8px; }
.cem-svg { display: block; width: 100%; min-width: 640px; height: auto; color: var(--ink-3); }
.cem-svg rect { fill: #fff; stroke: var(--line-2); stroke-width: 2; }
.cem-node { cursor: pointer; }
.cem-node:focus { outline: none; }
.cem-node:focus-visible rect { stroke: var(--ink); stroke-width: 3; }
.cem-node.is-on rect { fill: var(--m-soft); stroke: var(--m-side); stroke-width: 3; }
.cem-svg-h { font: 800 12px var(--font-ui); fill: var(--ink-3); }
.cem-svg-t { font: 600 13px var(--font-ui); fill: var(--ink); }

@media (max-width: 520px) {
  .cem-claim, .cem-note, .cem-sum-item { padding: 12px 12px; }
  .cem-paper { padding: 12px; }
}
