/* Gmail-style global admin polish.
   Loaded via UNFOLD["STYLES"] so it applies to every admin page —
   including the dashboard, popups, and any view that bypasses our
   custom admin/base_site.html template chain. */

/* ─── Roboto + Material Symbols ─────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,400,0,0&display=swap');

/* ─── Font stack — Gmail's preference order ─────────────────── */
body, #container, #content, .module, button, input, select, textarea {
  font-family: "Google Sans Text", "Roboto", -apple-system, BlinkMacSystemFont,
               "Segoe UI", "Helvetica Neue", Arial, sans-serif !important;
}

/* ─── Body / surface palette ────────────────────────────────── */
body {
  background: #f6f8fc !important;
}
#container, #content, #content-main {
  background: transparent !important;
}
.module, #changelist, .results, .form-row, fieldset {
  background: #ffffff !important;
}
.module, #changelist {
  border-radius: 12px !important;
  border: 1px solid #e8eaed !important;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.04) !important;
  /* `overflow: hidden` would round corners cleanly but it kills
     `position: sticky` on every descendant. Use `clip` instead —
     clips overflowing content the same way visually, but does not
     create a new containing block for sticky positioning. Modern
     browsers only; older browsers fall back to no clip + sticky
     still works. */
  overflow: clip;
}

/* ─── Table styling — Gmail-ish density + sticky header ────
   Unfold's changelist table is <table id="result_list" class="result-list">
   — singular. Earlier rules targeting `.results` (plural) never matched,
   which is why the Gmail palette AND the sticky behavior both failed.
   Target the ID + class so we cover both Unfold and stock Django. */
#result_list { border-collapse: separate; border-spacing: 0; }
#result_list thead th,
.result-list thead th,
.results thead th {
  /* Darker than rows so the sticky header reads clearly distinct.
     Gmail uses near-#e8eaed border tones; #dadce0 nudges it darker
     so it visibly stands apart from any row background. */
  background: #e8eaed !important;
  color: #3c4043 !important;
  font-size: 11px !important;
  font-weight: 600 !important;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  padding: 10px 14px !important;
  border-bottom: 1px solid #bdc1c6 !important;
  /* CSS sticky kept here as a fallback; the real sticking happens
     via kb-sticky-thead.js, which clones the thead at top of viewport. */
  position: sticky !important;
  top: 0 !important;
  z-index: 5;
}
/* JS-cloned sticky header — make it visually even more distinct
   while floating (added shadow + slightly stronger background). */
table.kb-sticky-thead {
  background: #e8eaed !important;
  box-shadow: 0 4px 8px -2px rgba(60, 64, 67, 0.18) !important;
  border-bottom: 1px solid #9aa0a6 !important;
}
table.kb-sticky-thead th {
  background: #e8eaed !important;
}
/* Force the wrappers between the sticky <th> and the viewport to
   `overflow: visible` — Unfold's Tailwind classes set overflow on the
   result-list-wrapper, which would silently kill sticky positioning.
   The :has() rule catches the unnamed wrapper Unfold injects right
   around the table (`-mx-1 px-1 overflow-x-auto …`) — it has no id /
   class we can target by name, but it's the direct parent of #result_list. */
#changelist,
.result-list-wrapper,
.changelist-form-container,
#content-main,
#content {
  overflow: visible !important;
  overflow-x: visible !important;
  overflow-y: visible !important;
}
/* Unfold wraps #result_list in SimpleBar (a custom-scrollbar library that
   rebuilds the markup at runtime). The scroll container is its
   .simplebar-content-wrapper; the bar only shows when THAT element
   overflows. An earlier rule made the inner .simplebar-content scroll
   instead, which scrolled invisibly with no bar. So: inner content never
   scrolls, wrapper does, track stays visible. */
#changelist .simplebar-content { overflow: visible !important; }
#changelist .simplebar-content-wrapper { overflow-x: auto !important; }
#changelist .simplebar-track.simplebar-horizontal { visibility: visible !important; opacity: 1 !important; }
#changelist .simplebar-scrollbar::before { background: #6d28d9; opacity: 0.55; }
/* Six columns fit without a forced width; the wrapper still scrolls if a
   narrow window needs it. */
#result_list { min-width: 0; }
/* Unfold's pagination footer is sticky at the bottom and sat over the
   table's scrollbar. Nothing in it needs to float. */
#changelist *:has(> .paginator) { position: static !important; backdrop-filter: none !important; }
/* Icon glyphs must keep the icon font; a sidebar rule inherited Inter and
   the bottom user menu rendered the literal word "unfold_more". */
.material-symbols-outlined, .material-symbols-outlined * { font-family: "Material Symbols Outlined" !important; }
td.field-ladder_badge, td.field-review_evidence, td.field-status_pill { white-space: nowrap; }
#result_list tbody td,
.result-list tbody td,
.results tbody td {
  font-size: 13px !important;
  color: #202124 !important;
  padding: 10px 14px !important;
  border-bottom: 1px solid #f1f3f4 !important;
}
#result_list tbody tr:hover,
.result-list tbody tr:hover,
.results tbody tr:hover {
  background: #f1f3f4 !important;
}

/* ─── Links / accents — Gmail blue ──────────────────────────── */
a, a:visited { color: #1a73e8; text-decoration: none; }
a:hover { text-decoration: underline; }
/* Unfold renders filled buttons (e.g. the "Filters" toggle when a filter is
   active) as <a class="bg-primary-600 text-white">. The rule above outranks
   the Tailwind class on :visited, which turned them blue-on-purple. */
a.text-white, a.text-white:visited, a.text-white:hover { color: #fff !important; }

/* ─── Hide Unfold's '/' keyboard shortcut chip ──────────────── */
#toolbar form kbd,
#toolbar form [class*="shortcut"],
#content-main form kbd,
#changelist-search kbd,
.search kbd {
  display: none !important;
}

/* ─── Per-page #searchbar (Unfold's q= filter) — Gmail pill ────
   Unfold wraps the input in a <div> with its own border / shadow /
   rounded-corners. We strip those off the wrapper and apply the
   Gmail pill look there instead, so the input + submit button +
   shortcut chip all sit inside one clean rounded container. */
#toolbar #changelist-search > div {
  background: #f1f3f4 !important;
  border: 1px solid transparent !important;
  border-radius: 999px !important;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.04) !important;
  padding: 4px 14px !important;
  transition: all 0.12s !important;
}
#toolbar #changelist-search > div:focus-within {
  background: #ffffff !important;
  border-color: #dadce0 !important;
  box-shadow: 0 1px 6px rgba(32, 33, 36, 0.16) !important;
  outline: none !important;
}
/* Submit button — strip the button frame, keep the magnifier icon */
#searchbar-submit {
  background: transparent !important;
  border: 0 !important;
  padding: 0 !important;
  margin-right: 6px !important;
  cursor: pointer !important;
}
#searchbar-submit .material-symbols-outlined {
  color: #5f6368 !important;
  font-size: 20px !important;
}
/* Input — no frame, no own border, just floats inside the pill */
#searchbar {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  padding: 8px 4px !important;
  font-size: 14px !important;
  color: #202124 !important;
  height: auto !important;
}
#searchbar::placeholder {
  color: #5f6368 !important;
}
#searchbar:focus {
  outline: none !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

/* ─── Theme-editor matched-items table (used in items-pane + form) ─────
   The right-pane iframe loads this table at /items-pane/. CSS lives
   here so it ships globally — the iframe doesn't have access to the
   per-template <style> blocks. */
.kb-theme-match-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 0;
  font-size: 12px;
}
.kb-theme-match-table thead th {
  text-align: left;
  padding: 8px 10px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #5f6368;
  border-bottom: 1px solid #bdc1c6;
  background: #e8eaed;
  position: sticky;
  top: 0;
  z-index: 5;
}
.kb-theme-match-table tbody td {
  padding: 10px;
  border-bottom: 1px solid #f1f3f4;
  vertical-align: top;
}
.kb-theme-match-table tbody tr:hover { background: #f8f9fa; }
.kb-theme-match-table .kb-theme-match-title-cell { min-width: 180px; }
.kb-theme-match-table .kb-theme-match-title {
  color: #1a73e8 !important;
  font-weight: 600;
  text-decoration: none;
  display: block;
}
.kb-theme-match-table .kb-theme-match-title:hover { text-decoration: underline !important; }
.kb-theme-match-table .kb-theme-match-org {
  font-size: 11px;
  color: #5f6368;
  margin-top: 2px;
}
.kb-theme-match-table .kb-theme-match-cat-cell {
  width: 110px;
  white-space: nowrap;
}
.kb-theme-match-table .kb-theme-match-cat {
  display: inline-block;
  padding: 2px 8px;
  background: #ede9fe;
  color: #5b21b6;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  border: 1px solid transparent;
}
.kb-theme-match-table .kb-theme-match-cat.kb-theme-cat-match {
  background: #d1e7dd;
  color: #0a5c34;
  border-color: #34a853;
}
.kb-theme-match-table .kb-theme-match-tags-cell { min-width: 220px; }
.kb-theme-match-table .kb-theme-match-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
}

/* Tag chips inside the matched-items table */
.kb-tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 4px 2px 10px;
  background: #f1f3f4;
  color: #3c4043;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 500;
  border: 1px solid transparent;
}
/* Chip colour = kind of thing (same palette as the row page's
   "Will appear under" strip):
     purple        category            (one per row, a field)
     outlined grey format / place / metro (fields)
     green         interest tags       (editable)
     blue          outcome tags        (editable)                        */
.kb-tag-chip.kb-chip-cat   { background: #ede9fe; color: #5b21b6; font-weight: 700; }
.kb-tag-chip.kb-chip-field { background: #fff; color: #4b5563; border: 1px solid #d1d5db; font-weight: 600; }
.kb-tag-chip.kb-tag-interest { background: #ecfdf5; color: #047857; }
.kb-tag-chip.kb-tag-outcome  { background: #eff6ff; color: #1d4ed8; }
.kb-tag-chip.kb-tag-matched {
  background: #d1e7dd;
  color: #0a5c34;
  border-color: #34a853;
  font-weight: 700;
}
.kb-tag-x {
  background: transparent;
  border: 0;
  color: inherit;
  font-size: 14px;
  line-height: 1;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  cursor: pointer;
  opacity: 0.55;
}
.kb-tag-x:hover { opacity: 1; background: rgba(0,0,0,0.1); }
.kb-tag-add-input,
.kb-tag-add-select {
  border: 1px dashed #bdc1c6;
  background: #fff;
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 11px;
  color: #3c4043;
  width: 80px;
  outline: none;
}
.kb-tag-add-input:focus {
  border-style: solid;
  border-color: #1a73e8;
  width: 120px;
}

/* Tags column on the Opportunity changelist — chips wrap, X button
   removes, "+ tag" input adds via the kb-pane-search.js handlers. */
.kb-tags-cell {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  align-items: center;
  min-width: 230px;
  max-width: 300px;
}
.kb-tags-cell .kb-tag-chip { font-size: 10.5px; padding: 1px 3px 1px 8px; }
.kb-tags-cell .kb-tag-fixed { padding: 1px 8px; }
.kb-tags-cell .kb-tag-x { font-size: 12px; width: 14px; height: 14px; }
.kb-tags-cell .kb-tag-add-input {
  width: 60px;
  font-size: 10px;
  padding: 1px 8px;
}
.kb-tags-cell .kb-tag-add-select {
  width: auto;
  max-width: 84px;
  font-size: 10px;
  padding: 1px 4px;
  color: #6b7280;
  cursor: pointer;
}

/* Force result_list to fill the available width in drawer mode so
   the iframe doesn't show a column of empty space on the right. */
.kb-drawer-mode #result_list { width: 100% !important; }
.kb-drawer-mode .result-list-wrapper,
.kb-drawer-mode #changelist {
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* Selected theme row in the themes list — Gmail's selected-message
   blue background + strong left bar so the active selection is
   unmistakable. */
tr.kb-theme-row-selected td,
tr.kb-theme-row-selected th {
  background: #d2e3fc !important;
  font-weight: 600 !important;
  color: #174ea6 !important;
}
tr.kb-theme-row-selected td:first-child {
  border-left: 5px solid #1a73e8 !important;
  position: relative;
}
tr.kb-theme-row-selected td:first-child::after {
  content: "● editing";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  padding: 2px 8px;
  border-radius: 999px;
  background: #1a73e8;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

/* ─── Drawer mode (iframe-loaded admin pages) ─────────────────
   kb-pane-search.js stamps .kb-drawer-mode when the document
   is nested in a frame. CSS scoped to that class hides admin chrome
   the right pane shouldn't show — sidebar, top header, KPI strip,
   bulk bars, the nested drawer pane, etc. — so the iframe content
   shows just the table itself. */
.kb-drawer-mode #page > div:has(#nav-sidebar),
.kb-drawer-mode #main > div:first-child,
.kb-drawer-mode #header,
.kb-drawer-mode #branding,
.kb-drawer-mode #user-tools,
.kb-drawer-mode .breadcrumbs,
.kb-drawer-mode .kb-pane-search-row,
.kb-drawer-mode .kb-pane-search,
.kb-drawer-mode .kb-pane-report-btn,
.kb-drawer-mode .kb-kpi-strip,
.kb-drawer-mode .kb-page-header,
.kb-drawer-mode .kb-tabs,
.kb-drawer-mode .kb-detail-pane,
.kb-drawer-mode .kb-detail-backdrop,
.kb-drawer-mode .kb-detail-resize,
.kb-drawer-mode #kb-bulk-bar {
  display: none !important;
}
/* Keep wheel/trackpad scroll INSIDE the iframe. Without this the
   iframe's overscroll-behavior is `auto`, so when the cursor is over
   the right pane the scroll chains through to the parent document and
   moves the middle list instead of the pane content. `contain` stops
   the chain at the iframe boundary. Applied to the scroll root
   (.kb-drawer-mode is on <html> and <body>). */
.kb-drawer-mode {
  overscroll-behavior: contain;
}
.kb-drawer-mode #content,
.kb-drawer-mode body:has(.kb-detail-pane) #content {
  /* The second selector overrides the drawer partial's own
     `body:has(.kb-detail-pane) #content { max-width: calc(100% - 580px) }`
     rule, which is re-rendered INSIDE the iframe because
     _kb_drawer.html gets included in every change_list. Specificity
     (1,2,2) beats the offending (1,1,1) rule. */
  max-width: 100% !important;
  width: 100% !important;
  margin: 0 !important;   /* defeat Tailwind's mx-auto on .container */
  padding: 8px 12px !important;
}
/* The wrapper around #content — `<div class="@container px-4 pb-4 grow">` —
   adds 16px of horizontal padding from Tailwind's `px-4`. In drawer mode,
   strip it so the table can reach the iframe edges. */
.kb-drawer-mode #content,
.kb-drawer-mode #content::before,
.kb-drawer-mode .grow > .container,
.kb-drawer-mode [class*="@container"] {
  padding-left: 0 !important;
  padding-right: 0 !important;
}
.kb-drawer-mode #content-main {
  background: transparent !important;
  width: 100% !important;
  max-width: 100% !important;
}
/* Also wipe Tailwind's `container` constraint specifically — its
   max-widths kick in at sm/md/lg/xl breakpoints with higher
   specificity in some Unfold builds than the #content ID rule. */
.kb-drawer-mode .container {
  max-width: 100% !important;
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
}
/* Force every wrapper around the changelist table to span full iframe
   width. The earlier #result_list { width: 100% } wasn't enough because
   intermediate wrappers (.lg:rounded-b-default, .result-list-wrapper)
   had their own margin / padding / max-width that left empty gutters. */
.kb-drawer-mode #changelist,
.kb-drawer-mode .result-list-wrapper,
.kb-drawer-mode .result-list-wrapper > div,
.kb-drawer-mode .changelist-form-container {
  width: 100% !important;
  max-width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}
.kb-drawer-mode #result_list {
  width: 100% !important;
  table-layout: auto !important;
}

/* Belt-and-braces: in drawer mode, NUKE everything inside #content-main
   except the actual result-list-wrapper + the result_list table. This
   catches anything Unfold renders (filter tabs, KPI strip, search row,
   page header, etc.) that we don't want in the right pane and that
   the named-selector hides above might miss.

   CRITICAL: scope to `#content-main:has(#changelist)` so this ONLY
   fires on changelist drawers (Themes). Without the :has() guard it
   also matched change-FORM drawers — where the page is a <form>, not a
   #changelist — and hid the entire form, leaving the right pane blank
   except the floating submit bar. That regression (a86b35b) broke the
   opportunity AND flag detail drawers. The :has() guard keeps the
   changelist cleanup while letting change forms render. */
.kb-drawer-mode #content-main:has(#changelist) > *:not(#changelist) {
  display: none !important;
}
.kb-drawer-mode #changelist > *:not(.result-list-wrapper):not(.results):not(.changelist-form-container) {
  display: none !important;
}
.kb-drawer-mode .result-list-wrapper > *:not(:has(#result_list)) {
  display: none !important;
}
/* The first child of result-list-wrapper (`.grow.min-w-0`) wraps the
   table + a separate "search/filter" row. Hide that row. */
.kb-drawer-mode .result-list-wrapper > .grow > *:not(:has(#result_list)) {
  display: none !important;
}

/* ─── Inline AJAX toggle (kb-toggle) — shared by all admins ──────
   Click the checkbox → JS POSTs to the URL named on data-endpoint.
   Saving state shows a transient opacity dim; error pulses red.
   The label.data-row-id attribute carries the row's pk so the JS
   can build the right URL — see kb-pane-search.js for the handler. */
.kb-toggle {
  display: inline-block; position: relative;
  width: 38px; height: 22px;
  cursor: pointer; vertical-align: middle;
}
.kb-toggle input { display: none; }
.kb-toggle .kb-toggle-track {
  position: absolute; inset: 0;
  background: #dadce0; border-radius: 999px;
  transition: background 0.15s;
}
.kb-toggle .kb-toggle-track::before {
  content: ''; position: absolute;
  top: 3px; left: 3px; width: 16px; height: 16px;
  background: #fff; border-radius: 50%;
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
  transition: transform 0.15s;
}
.kb-toggle input:checked + .kb-toggle-track {
  background: #34a853;  /* Gmail green */
}
.kb-toggle input:checked + .kb-toggle-track::before {
  transform: translateX(16px);
}
.kb-toggle.kb-toggle-saving .kb-toggle-track { opacity: 0.6; }
.kb-toggle.kb-toggle-error .kb-toggle-track { background: #ea4335 !important; }

/* ─── Hide Unfold's purple bottom bulk-action bar ───────────────
   Replaced by our top sticky kb-bulk-bar. Unfold's wrapper has no
   semantic id we can target by name — find it via :has() through
   #changelist-actions-wrapper (the inner div with a stable id). */
body:has(.kb-bulk-bar) *:has(> #changelist-actions-wrapper),
body:has(.kb-bulk-bar) #changelist-actions-wrapper,
body:has(.kb-bulk-bar) #changelist-actions,
body:has(.kb-bulk-bar) .actions {
  display: none !important;
}

/* ─── change_form submit row → Gmail-style top sticky ────────
   Django's stock submit row sits at the BOTTOM of the form: Save,
   Save and continue editing, Save and add another, Delete (red).
   Move it to the TOP and restyle as flat icon+label buttons in
   the Gmail palette so it matches the rest of the admin. The actual
   <input> buttons are kept; only their visual is overridden.

   Selectors target Unfold's submit row markup (which extends the
   Django default). The fixed-position bar at top of #content stays
   sticky as you scroll the form. */
body:has(.submit-row) #content > .submit-row,
body:has(.submit-row) form > .submit-row,
form .submit-row {
  position: sticky;
  top: 0;
  z-index: 9;
  display: flex !important;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin: 0 0 18px 0 !important;
  padding: 10px 14px !important;
  background: #ffffff !important;
  border: 1px solid #dadce0 !important;
  border-radius: 12px !important;
  box-shadow: 0 1px 6px rgba(60, 64, 67, 0.08) !important;
}
form .submit-row input[type="submit"],
form .submit-row a.deletelink,
form .submit-row button {
  background: #fff !important;
  color: #202124 !important;
  border: 1px solid #dadce0 !important;
  border-radius: 8px !important;
  padding: 6px 14px !important;
  font-size: 13px !important;
  font-weight: 600 !important;
  font-family: inherit !important;
  text-transform: none !important;
  letter-spacing: normal !important;
  cursor: pointer !important;
  transition: all 0.12s !important;
  box-shadow: none !important;
  height: auto !important;
  line-height: 1.4 !important;
  text-shadow: none !important;
}
form .submit-row input[type="submit"]:hover,
form .submit-row a.deletelink:hover,
form .submit-row button:hover {
  background: #f1f3f4 !important;
  border-color: #1a73e8 !important;
  color: #1a73e8 !important;
}
/* Primary "Save" — Gmail-blue */
form .submit-row input[name="_save"] {
  background: #1a73e8 !important;
  border-color: #1a73e8 !important;
  color: #ffffff !important;
}
form .submit-row input[name="_save"]:hover {
  background: #1765c5 !important;
  border-color: #1765c5 !important;
  color: #ffffff !important;
}
/* Delete — keep destructive intent but quiet the 1990s red rectangle */
form .submit-row a.deletelink {
  background: #fff !important;
  color: #c5221f !important;
  border-color: #f6c1be !important;
}
form .submit-row a.deletelink:hover {
  background: #fce8e6 !important;
  color: #c5221f !important;
  border-color: #c5221f !important;
}

/* Push Unfold's "actions detail" bar (per-row top action buttons
   like Publish / Archive on the opportunity change_form) into the
   same visual treatment. */
.object-tools li a.button,
.object-tools li button {
  background: #fff !important;
  color: #1a73e8 !important;
  border: 1px solid #dadce0 !important;
  border-radius: 8px !important;
  padding: 6px 14px !important;
  font-weight: 600 !important;
  text-transform: none !important;
  letter-spacing: normal !important;
}
.object-tools li a.button:hover,
.object-tools li button:hover {
  background: #e8f0fe !important;
  border-color: #1a73e8 !important;
}

/* ─── Persistent middle-pane search bar (injected by kb-pane-search.js) ─── */
.kb-pane-search-row {
  margin: 0 0 16px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}
.kb-pane-search-row .kb-pane-search {
  flex: 1;
  margin: 0 !important;
}
.kb-pane-report-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: #ffffff;
  border: 1px solid #dadce0;
  border-radius: 999px;
  color: #1a73e8 !important;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none !important;
  transition: all 0.12s;
  white-space: nowrap;
}
.kb-pane-report-btn:hover {
  background: #e8f0fe;
  border-color: #1a73e8;
  text-decoration: none !important;
}
.kb-pane-report-btn .material-symbols-outlined {
  color: #1a73e8;
}

.kb-pane-search {
  margin: 0 0 16px 0;
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f1f3f4;
  border: 1px solid transparent;
  border-radius: 28px;
  padding: 6px 16px 6px 14px;
  transition: all 0.12s;
  box-shadow: 0 1px 2px rgba(60, 64, 67, 0.04);
}
.kb-pane-search:focus-within {
  background: #ffffff;
  border-color: #dadce0;
  box-shadow: 0 1px 6px rgba(32, 33, 36, 0.16);
}
.kb-pane-search .material-symbols-outlined {
  font-size: 22px;
  color: #5f6368;
}
.kb-pane-search input {
  flex: 1;
  background: transparent;
  border: 0;
  outline: none;
  font-size: 15px;
  color: #202124;
  padding: 8px 0;
  font-family: inherit;
}
.kb-pane-search input::placeholder {
  color: #5f6368;
}
.kb-pane-search button[type="submit"] {
  background: transparent;
  border: 0;
  cursor: pointer;
  color: #5f6368;
  padding: 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  transition: background 0.1s;
}
.kb-pane-search button[type="submit"]:hover {
  background: #e8eaed;
  color: #1a73e8;
}

/* ─── Two-axis verification chips (for HS × open) ───────────── */
.kb-ax { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 11px; font-weight: 700; white-space: nowrap; }
.kb-ax-hs-yes { background: #ecfdf5; color: #047857; }
.kb-ax-hs-no { background: #fef2f2; color: #b91c1c; }
.kb-ax-hs-unsure { background: #fffbeb; color: #b45309; }
.kb-ax-hs-unknown { background: #f3f4f6; color: #6b7280; }
.kb-ax-open-open { background: #ecfdf5; color: #047857; }
.kb-ax-open-opens { background: #eff6ff; color: #1d4ed8; }
.kb-ax-open-closed, .kb-ax-open-passed { background: #f3f4f6; color: #4b5563; }
.kb-ax-open-dead { background: #fef2f2; color: #b91c1c; }
.kb-ax-open-unknown { background: #fffbeb; color: #b45309; }
.kb-ax-why { margin-top: 3px; font-size: 11px; color: #6b7280; max-width: 260px; white-space: normal; }
.kb-ax-check { color: #92400e; background: #fffbeb; border: 1px solid #fde68a; border-radius: 6px; padding: 2px 6px; }
.kb-ax-check-fail { color: #991b1b; background: #fef2f2; border-color: #fecaca; }
.kb-ax-ok { color: #047857; font-weight: 600; }
.kb-ax-rec-publish { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.kb-ax-rec-hold { background: #fef3c7; color: #92400e; border: 1px solid #fcd34d; }
.kb-ax-rec-archive { background: #fee2e2; color: #991b1b; border: 1px solid #fca5a5; }


.kb-marks { display:flex; gap:4px; margin-top:4px; flex-wrap:wrap; }
.kb-mk { font-size:10.5px; padding:1px 6px; border-radius:999px; border:1px solid #d1d5db; color:#6b7280; background:#f9fafb; }
.kb-mk-pass { color:#047857; border-color:#a7f3d0; background:#ecfdf5; }
.kb-mk-check { color:#92400e; border-color:#fde68a; background:#fffbeb; font-weight:600; }
.kb-mk-unstated { color:#6b7280; border-style:dashed; }
