/* protein-types plugin styles: entry section "Protein type" and the
 * protein-types browse pages. Design tokens only (styles.css :root);
 * square 1px tags, no pills, no shadows. */

/* Evidence tag: 1px border, 2px radius, 12px text. */
.pt-tag {
  display: inline-block;
  min-width: 2.6em;
  margin: 0 3px 0 0;
  padding: 0 4px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: var(--surface);
  color: var(--ink);
  font: 600 11.5px/17px var(--sans);
  letter-spacing: 0;
  text-align: center;
  vertical-align: 1px;
  white-space: nowrap;
}
button.pt-tag { cursor: pointer; }
button.pt-tag:hover { border-color: var(--teal); color: var(--teal-dark); }
button.pt-tag[aria-expanded="true"] { border-color: var(--teal); background: var(--teal-soft); color: var(--teal-dark); }
button.pt-tag:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 1px; }
/* Tier 1 (experimental, literature) in ink weight; inferred tiers secondary. */
.pt-tag[data-class="experimental"], .pt-tag[data-class="curated_literature"] { border-color: var(--ink); }
.pt-tag[data-class="homology"], .pt-tag[data-class="structure"], .pt-tag[data-class="orthology"],
.pt-tag[data-class="prediction"], .pt-tag[data-class="derived"] { color: var(--ink-soft); font-weight: 400; }

/* ---------------- entry section ---------------- */
.protein-types .pt-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 14px;
  margin: 0 0 10px;
  padding: 0;
  border: 0;
  font-size: 13px;
}
.protein-types .pt-filter legend { float: left; margin: 0 6px 0 0; padding: 0; color: var(--ink-soft); font-weight: 600; }
.protein-types .pt-filter label { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; cursor: pointer; }
.protein-types .pt-filter input { margin: 0; accent-color: var(--teal); }
.protein-types .pt-group { margin: 0 0 12px; }
.protein-types .pt-group h3 {
  margin: 0 0 4px;
  padding: 0 0 2px;
  border-bottom: 1px solid var(--line-soft);
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
}
.protein-types .pt-group h4 { margin: 6px 0 2px; color: var(--ink-soft); font-size: 12.5px; font-weight: 600; }
.protein-types .pt-list { margin: 0; padding: 0; list-style: none; }
.protein-types .pt-row {
  padding: 3px 0;
  border-bottom: 1px solid var(--line-soft);
  font-size: 13.5px;
  line-height: 1.5;
}
.protein-types .pt-row:last-child { border-bottom: 0; }
.protein-types .pt-path { margin-right: 8px; }
.protein-types .pt-path a { color: var(--ink); text-decoration: none; }
.protein-types .pt-path > a:last-of-type { font-weight: 600; }
.protein-types .pt-path a:hover, .protein-types .pt-path a:focus-visible { color: var(--teal); text-decoration: underline; }
.pt-sep { color: var(--ink-soft); }
/* Short catalytic-residue marker after the label path ("ROPK · pseudokinase"). */
.protein-types .pt-activity { color: var(--ink-soft); font-size: 13px; white-space: nowrap; }
.protein-types .pt-activity.pt-pseudo, .pt-pseudo { color: var(--ink); }
.protein-types .pt-tags { white-space: nowrap; }
.protein-types .pt-refs { margin-left: 6px; color: var(--ink-soft); font-size: 12.5px; }
.protein-types .pt-evidence {
  margin: 4px 0 4px 0;
  padding: 4px 0 4px 10px;
  border-left: 2px solid var(--line);
  font-size: 12.5px;
}
.protein-types .pt-evidence ul { margin: 2px 0 0; padding: 0 0 0 16px; }
.protein-types .pt-evidence li { margin: 0 0 4px; overflow-wrap: anywhere; }
.protein-types .pt-evidence-head { margin: 0; color: var(--ink-soft); }
.protein-types .pt-owner { font-weight: 600; }
.protein-types .pt-source { color: var(--ink-soft); }
.protein-types .pt-caption { margin-top: 6px; }
/* One line under the evidence filter: what bold and grey tags mean. */
.protein-types .pt-tier-note { margin: 0 0 10px; }
.protein-types .pt-filter + .pt-tier-note { margin-top: -4px; }

/* ---------------- browse pages ---------------- */
/* Search box and group jump links stay visible while the tables scroll. */
.pt-page .pt-browsebar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 20px;
  margin: 0 0 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.pt-page .pt-find { display: flex; align-items: center; gap: 8px; flex: 0 1 30em; min-width: 0; }
.pt-page .pt-find label { font-size: 13px; font-weight: 600; white-space: nowrap; }
.pt-page .pt-find input[type="search"] { flex: 1 1 auto; width: auto; min-width: 8em; }
.pt-page .pt-find-count { color: var(--ink-soft); font-size: 12.5px; white-space: nowrap; }
.pt-page .pt-toc { display: flex; flex: 1 1 32em; flex-wrap: wrap; gap: 2px 14px; margin: 0; font-size: 13px; line-height: 1.6; }
.pt-page .pt-toc a { white-space: nowrap; }
.pt-page .pt-toc a[hidden] { display: none; }
.pt-page .pt-group-section { scroll-margin-top: 96px; }
.pt-page #ptMembersSection { scroll-margin-top: 8px; }
.pt-page mark.pt-hit { padding: 0; background: var(--teal-soft); color: inherit; }
.pt-page .pt-empty[hidden], .pt-page section[hidden] { display: none; }

/* Evidence legend: one line per tag; the tag toggles the count filter. */
.pt-page .pt-legend { margin: 0 0 6px; font-size: 13px; }
.pt-page .pt-legend-head { margin: 0 0 4px; }
.pt-page .pt-legend-hint { color: var(--ink-soft); font-size: 12.5px; }
.pt-page .pt-legend ul {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 25em), 1fr));
  gap: 2px 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.pt-page .pt-legend li { line-height: 1.55; }
.pt-page .pt-legend-name { font-weight: 600; }
.pt-page .pt-legend-text { color: var(--ink-soft); }
.pt-page button.pt-toggle-tag {
  height: auto;
  min-width: 3.4em;
  padding: 0 4px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  background: var(--surface);
  font: 600 11.5px/17px var(--sans);
  line-height: 17px;
}
.pt-page button.pt-toggle-tag[data-class="homology"], .pt-page button.pt-toggle-tag[data-class="structure"],
.pt-page button.pt-toggle-tag[data-class="orthology"], .pt-page button.pt-toggle-tag[data-class="prediction"],
.pt-page button.pt-toggle-tag[data-class="derived"] { color: var(--ink-soft); font-weight: 400; }
.pt-page button.pt-toggle-tag[data-class="experimental"], .pt-page button.pt-toggle-tag[data-class="curated_literature"] { color: var(--ink); border-color: var(--ink); }
.pt-page button.pt-toggle-tag:hover:not(:disabled) { border-color: var(--teal); color: var(--teal-dark); }
.pt-page button.pt-toggle-tag[aria-pressed="true"] { border-color: var(--teal); background: var(--teal-soft); color: var(--teal-dark); font-weight: 600; }
.pt-page .pt-legend [data-clear-evidence][hidden] { display: none; }
.pt-page .pt-actions { margin: 0 0 16px; gap: 8px; }
.pt-page .pt-group-section h2 .tool-count { font-weight: 400; color: var(--ink-soft); font-size: 13px; }
.pt-page .pt-tree { table-layout: auto; }
.pt-page .pt-tree td { vertical-align: top; }
.pt-page .pt-tree-label { min-width: 16em; }
.pt-page .pt-tree-label a { color: var(--ink); }
.pt-page .pt-tree-label a:hover { color: var(--teal); }
.pt-page .pt-depth-1 .pt-tree-label a { font-weight: 600; }
.pt-page .pt-depth-2 .pt-tree-label { padding-left: 28px; }
.pt-page .pt-depth-3 .pt-tree-label { padding-left: 48px; }
.pt-page .pt-depth-4 .pt-tree-label { padding-left: 68px; }
.pt-page button.pt-toggle {
  width: 18px;
  height: 18px;
  min-height: 0;
  margin: 0 4px 0 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--surface);
  color: var(--teal-dark);
  font: 600 13px/16px var(--mono);
  vertical-align: 1px;
}
.pt-page button.pt-toggle::before { content: "+"; }
.pt-page button.pt-toggle[aria-expanded="true"]::before { content: "\2212"; }
.pt-page .pt-toggle-space { display: inline-block; flex: 0 0 auto; width: 22px; }
.pt-page .pt-tree-item { display: inline-flex; align-items: baseline; }
.pt-page .pt-tree-item button.pt-toggle { flex: 0 0 auto; align-self: flex-start; margin-top: 1px; }
.pt-page .pt-sub { color: var(--ink-soft); font-size: 12px; }
.pt-page .pt-evidence-cell { white-space: normal; line-height: 1.9; }
.pt-page .pt-count { display: inline-block; margin-right: 6px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.pt-page .pt-facts th { width: 12em; }
.pt-page .pt-facts td { overflow-wrap: anywhere; }
.pt-page .pt-member-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 18px;
  margin: 0 0 8px;
  font-size: 13px;
}
.pt-page .pt-filter { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin: 0; padding: 0; border: 0; }
.pt-page .pt-filter legend { float: left; margin: 0 4px 0 0; padding: 0; color: var(--ink-soft); font-weight: 600; }
.pt-page .pt-filter label { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; cursor: pointer; }
.pt-page .pt-activity-filter { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
.pt-page .pt-activity-filter select { width: auto; max-width: 22em; }
.pt-page .pt-download {
  margin-left: auto;
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--teal);
  text-decoration: none;
  white-space: nowrap;
}
.pt-page .pt-download:hover { border-color: var(--teal); text-decoration: underline; }
.pt-page .pt-members td { vertical-align: top; }
.pt-page .pt-members .pt-name { min-width: 14em; }
.pt-page .pt-members .pt-toxodb { min-width: 14em; }
.pt-page .pt-members .pt-evidence-cell { white-space: nowrap; line-height: 1.45; }
.pt-page .pt-members .pt-conflict { display: block; color: var(--orange); font-size: 12.5px; }
.pt-page .pt-members tr.pt-disagree td:first-child { border-left: 2px solid var(--orange); }
.pt-page .pt-with { margin: 0 0 8px; font-size: 13px; }
.pt-page .pt-with[hidden] { display: none; }
.pt-page .pt-overlap-table { width: auto; min-width: min(100%, 760px); }
.pt-page .pt-overlap-table td:first-child { min-width: 14em; }
.pt-page .pt-overlaps h2 .tool-count, .pt-page #ptMembersSection h2 .tool-count { font-weight: 400; color: var(--ink-soft); font-size: 13px; }
/* Enzymes group: one line per family screened for catalytic residues. */
.pt-page .pt-status-head { margin: 14px 0 4px; }
.pt-page .pt-status-list { margin: 0; padding: 0; list-style: none; font-size: 13px; }
.pt-page .pt-status-list li { padding: 5px 10px; border-bottom: 1px solid var(--line-soft); line-height: 1.5; overflow-wrap: anywhere; }
.pt-page .pt-status-list li:first-child { border-top: 1px solid var(--line); }
.pt-page a.pt-status-family { color: var(--ink); font-weight: 600; }
.pt-page a.pt-status-family:hover { color: var(--teal); }
.pt-page .pt-status-counts { font-variant-numeric: tabular-nums; }

@media (max-width: 900px) {
  .pt-page .pt-download { margin-left: 0; }
  .pt-page .pt-browsebar { gap: 6px 12px; padding: 6px 0; }
  .pt-page .pt-find { flex: 1 1 100%; }
  /* One scrolling line of group links keeps the bar short on phones. */
  .pt-page .pt-toc { flex: 1 1 100%; flex-wrap: nowrap; overflow-x: auto; padding-bottom: 2px; }
  .pt-page .pt-group-section { scroll-margin-top: 84px; }
  .pt-page .pt-activity-filter { flex-wrap: wrap; max-width: 100%; white-space: normal; }
  .pt-page .pt-activity-filter select { min-width: 0; max-width: 100%; }
  .pt-page .pt-tree-label { min-width: 11em; }
  .pt-page .pt-depth-2 .pt-tree-label { padding-left: 18px; }
  .pt-page .pt-depth-3 .pt-tree-label { padding-left: 30px; }
  .pt-page .pt-depth-4 .pt-tree-label { padding-left: 42px; }
  .protein-types .pt-refs { display: block; margin-left: 0; }
}

/* Pseudoenzyme caveat next to catalytic annotations (pseudoenzyme.js, clue-card.js, homology.js) */
.pz-note { margin: 4px 0 8px; padding-left: 8px; border-left: 2px solid var(--orange, #9a5b13); color: var(--ink, #1f2a30); font-size: 13px; line-height: 1.45; }
.pz-note.pz-neutral { border-left-color: var(--line, #d9dfe2); color: var(--ink-soft, #56656c); }
.pz-mark { color: var(--orange, #9a5b13); font-size: 12.5px; white-space: nowrap; }
.pz-mark::before { content: "· "; color: var(--ink-soft, #56656c); }

/* Help dialog entry */
.pt-help .pt-help-tags { margin: 4px 0; padding-left: 0; list-style: none; columns: 2 300px; column-gap: 24px; }
.pt-help .pt-help-tags li { margin: 0 0 3px; break-inside: avoid; }
.pt-home-count { white-space: nowrap; }

/* Candidate types: calibrated predictions, shown as tentative text. */
.protein-types .pt-candidates { margin-top: 12px; padding-left: 10px; border-left: 2px dashed var(--line); color: var(--ink-soft); }
.protein-types .pt-candidates h3 { color: var(--ink-soft); font-weight: 600; margin: 0 0 2px; }
.protein-types .pt-candidate-caption { margin: 0 0 6px; font-size: 12.5px; color: var(--ink-soft); }
.protein-types .pt-candidate-list { list-style: none; margin: 0; padding: 0; }
.protein-types .pt-candidate { margin: 0 0 6px; overflow-wrap: anywhere; }
.protein-types .pt-candidate-family { color: var(--ink-soft); font-weight: 600; }
.protein-types .pt-candidate-meta { color: var(--ink-soft); }
.protein-types .pt-candidate-hit { display: block; font-size: 12.5px; color: var(--ink-soft); }
