/* extension styles: trace (CMD-KYCLAB/009-FINAL-DEV). Classes only (no inline styles); 390 px first: one column, min-width:0 on every grid / flex child, long ids wrap. */
.trc-search .cb{min-width:0;}
.trc-form{display:grid;grid-template-columns:minmax(0,2fr) minmax(0,1fr) auto;gap:12px;align-items:end;min-width:0;}
.trc-form>*{min-width:0;}
.trc-kt select{width:100%;min-width:0;}
.trc-go{display:flex;align-items:flex-end;}
.trc-results{display:flex;flex-direction:column;gap:16px;margin-top:16px;min-width:0;}
.trc-results>*{min-width:0;}
.trc-summary{display:flex;flex-wrap:wrap;gap:8px;align-items:center;}
.trc-stepper{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(8,minmax(0,1fr));gap:8px;}
.trc-step{min-width:0;}
.trc-stepbtn{width:100%;min-width:0;display:flex;flex-direction:column;align-items:center;gap:3px;padding:10px 6px;border:1px solid var(--line);border-radius:12px;background:var(--surface);color:var(--ink-3);cursor:pointer;font:inherit;text-align:center;}
.trc-stepbtn:focus-visible{outline:2px solid var(--accent);outline-offset:2px;}
.trc-step.has .trc-stepbtn{color:var(--ink);border-color:var(--accent);}
.trc-step.gap:not(.has) .trc-stepbtn{border-style:dashed;}
.trc-sn{width:24px;height:24px;border-radius:50%;border:2px solid var(--line-2);display:flex;align-items:center;justify-content:center;font-weight:700;font-size:12px;}
.trc-step.has .trc-sn{border-color:var(--accent);color:var(--accent-ink);}
.trc-sl{font-size:12.5px;font-weight:600;overflow-wrap:anywhere;}
.trc-sc,.trc-sh,.trc-sg{font-size:11.5px;overflow-wrap:anywhere;}
.trc-sh{color:var(--review);}
.trc-sg{color:var(--review);font-weight:600;}
.trc-toggle{display:flex;gap:8px;flex-wrap:wrap;}
.trc-toggle button[aria-pressed="true"]{border-color:var(--accent);color:var(--accent-ink);font-weight:700;}
.trc-stages{display:flex;flex-direction:column;gap:16px;min-width:0;}
.trc-stage{min-width:0;scroll-margin-top:12px;}
.trc-stage .cb{min-width:0;}
.trc-nodes{min-width:0;}
.trc-node{min-width:0;}
.trc-node.root>.trc-top .trc-title{color:var(--accent-ink);}
.trc-top{display:flex;flex-wrap:wrap;gap:8px;align-items:center;min-width:0;}
.trc-title{overflow-wrap:anywhere;}
.trc-ref{overflow-wrap:anywhere;word-break:break-word;font-size:12.5px;color:var(--ink-2);}
.trc-chips{display:flex;flex-wrap:wrap;gap:6px;}
.trc-more summary{cursor:pointer;font-size:12.5px;font-weight:600;color:var(--ink-2);}
.trc-more[open] summary{margin-bottom:8px;}
.trc-facts{display:grid;grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:8px 16px;margin:0 0 8px;}
.trc-facts>dt,.trc-facts>dd{min-width:0;overflow-wrap:anywhere;}
.trc-facts dt{font-size:11.5px;color:var(--ink-3);}
.trc-facts dd{margin:0;}
.trc-h3{font-size:13px;margin:10px 0 6px;}
.trc-id code,.trc-via{font-family:var(--code);font-size:12px;overflow-wrap:anywhere;word-break:break-word;}
.trc-links{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px;min-width:0;}
.trc-links li{min-width:0;overflow-wrap:anywhere;}
.trc-links li.removed{opacity:.75;}
.trc-open{align-self:flex-start;}
.trc-gaps{list-style:none;margin:0 0 12px;padding:0;display:flex;flex-direction:column;gap:8px;}
.trc-gap{display:flex;flex-wrap:wrap;gap:8px;align-items:baseline;padding:8px 10px;border:1px dashed var(--review);border-radius:10px;min-width:0;}
.trc-gaptext{flex:1 1 220px;min-width:0;overflow-wrap:anywhere;}
.trc-subjects,.trc-cands{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:8px;}
.trc-cand{display:flex;flex-wrap:wrap;gap:8px;align-items:center;justify-content:space-between;padding:8px 10px;border:1px solid var(--line);border-radius:10px;min-width:0;}
.trc-candtxt{min-width:0;overflow-wrap:anywhere;}
@media (max-width:900px){.trc-stepper{grid-template-columns:repeat(4,minmax(0,1fr));}}
@media (max-width:560px){
  .trc-form{grid-template-columns:minmax(0,1fr);}
  .trc-go .btn{width:100%;justify-content:center;}
  .trc-stepper{grid-template-columns:repeat(2,minmax(0,1fr));}
  .trc-facts{grid-template-columns:minmax(0,1fr);}
}
