/* dim data cells of disabled/archived rows but keep .actions full-strength so the toggle stays usable */
tr.row-archived td,
tr.row-disabled td {
  opacity: 0.55;
  color: var(--text-dim);
}
tr.row-archived td.actions,
tr.row-disabled td.actions {
  opacity: 1;
  color: inherit;
}

tr.row-shared td {
  font-weight: var(--fw-semibold);
  color: var(--success);
}
td .share-marker {
  width: 13px;
  height: 13px;
  vertical-align: -2px;
  color: var(--success-icon);
  stroke-width: 2.5px;
}
.icon-btn-on .lucide {
  stroke-width: 2.5px;
}

tr.state-pending   td { background: var(--state-pending-bg); }
tr.state-running   td { background: var(--state-running-bg); }
tr.state-succeeded td { background: var(--state-succeeded-bg); }
tr.state-failed    td { background: var(--state-failed-bg); }
tr.state-cancelled td { background: var(--state-cancelled-bg); color: var(--text-dim); }

td .state-pill {
  display: inline-block;
  font-size: var(--fs-xs);
  padding: 2px 8px;
  border-radius: var(--r-pill);
  font-weight: var(--fw-medium);
}
.state-pill.s-pending   { background: var(--pill-pending-bg);   color: var(--pill-pending-fg); }
.state-pill.s-running   { background: var(--pill-running-bg);   color: var(--pill-running-fg); }
.state-pill.s-succeeded { background: var(--pill-succeeded-bg); color: var(--pill-succeeded-fg); }
.state-pill.s-failed    { background: var(--pill-failed-bg);    color: var(--pill-failed-fg); }
.state-pill.s-cancelled { background: var(--pill-cancelled-bg); color: var(--pill-cancelled-fg); }

/* host fills #main and never scrolls itself; the .files-list inside is the sole scroller (mirrors #table-host) */
#catalog-host { overflow: hidden; height: 100%; background: var(--bg-app); }

/* flex column so the header/breadcrumbs/pager pin while only the list scrolls (mirrors .table-shell) */
.cat-pane {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: var(--page-pad-y) var(--page-pad-x);
}
.cat-pane > .cat-pane-header,
.cat-pane > .files-breadcrumbs,
.cat-pane > .cat-search-banner,
.cat-pane > .cat-pager,
.cat-pane > .hint { flex: none; }

.cat-title {
  font-size: var(--fs-xl);
  margin: 0;
  font-weight: var(--fw-semibold);
}

.cat-pane-header {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px; margin-bottom: var(--page-head-gap);
}
/* every catalog header control shares the one header-control height + text size */
.cat-pane-header .cat-search-input,
.cat-pane-header .pill-btn,
.cat-pane-header .primary {
  height: var(--control-h);
  box-sizing: border-box;
  font-size: var(--control-fs);
}
.cat-pane-header .page-headings { margin-right: auto; }
.cat-search {
  display: inline-flex; align-items: center; gap: 6px;
}
.cat-search-input {
  font: inherit; font-size: var(--fs-sm);
  padding: 5px 8px; border: 1px solid var(--border-input-cool); border-radius: var(--r-xs);
  background: var(--surface-raised); min-width: 220px;
}
.cat-search-input:focus { outline: none; border-color: var(--accent); }
.cat-search-all {
  font-size: var(--fs-sm);
}
.cat-search-banner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  background: var(--accent-soft-bg);
  border: 1px solid var(--border-list); border-radius: var(--r-sm);
  padding: 8px 12px; margin-bottom: 8px;
  font-size: var(--fs-sm);
}
.cat-search-banner strong { color: var(--text-mono-dark); }
.search-hit-row { cursor: pointer; }

/* shrink Lucide's default 24px <svg> so icons line up with adjacent text */
.lucide {
  width: 16px;
  height: 16px;
  stroke-width: 1.75;
  vertical-align: middle;
  flex-shrink: 0;
}
.files-icon .lucide { width: 16px; height: 16px; color: var(--text-secondary); }
.files-act .lucide { width: 16px; height: 16px; }
.pill-btn .lucide  { width: 14px; height: 14px; margin-right: 2px; }
.cat-pager .lucide { width: 14px; height: 14px; }
.cat-search-all { display: inline-flex; align-items: center; gap: 4px; }
.cat-write-actions .pill-btn { display: inline-flex; align-items: center; gap: 4px; }


.cat-write-actions {
  display: inline-flex; gap: 6px;
}
.cat-write-modal { min-width: 360px; }
.cat-write-modal input[type="text"],
.cat-write-modal input[type="file"] {
  width: 100%;
}
.upload-progress {
  list-style: none; margin: 8px 0 0; padding: 0;
  max-height: 240px; overflow-y: auto;
  border-top: 1px solid var(--divider);
}
.upload-progress li {
  display: flex; justify-content: space-between; gap: 12px;
  padding: 4px 0;
  font-size: var(--fs-sm);
  border-bottom: 1px solid var(--bg-app);
}
.upload-progress .up-name {
  font-family: var(--font-mono);
  word-break: break-all;
}

.cat-pane-header .primary {
  -webkit-appearance: none; appearance: none;
  background: var(--accent); color: var(--accent-fg); border: 1px solid var(--accent-hover);
  font: inherit; font-size: var(--fs-sm); padding: 6px 12px;
  border-radius: var(--r-sm); cursor: pointer;
}
.cat-pane-header .primary:hover { background: var(--accent-hover); border-color: var(--accent-active); }

.cat-page-size { font-size: var(--fs-sm); color: var(--text-secondary); }
.cat-page-size-select {
  font: inherit; font-size: var(--fs-sm);
  padding: 2px 6px; border: 1px solid var(--border-input-cool); border-radius: var(--r-xs);
  background: var(--surface-raised);
}

.cat-pager {
  display: flex; gap: 8px; align-items: center; justify-content: space-between;
  margin-top: 16px;
}
.cat-pager-nav { display: inline-flex; gap: 8px; }
.cat-pager button {
  -webkit-appearance: none; appearance: none;
  font: inherit; font-size: var(--fs-sm);
  padding: 6px 14px;
  background: var(--surface-raised); color: var(--text-strong);
  border: 1px solid var(--border-input-cool); border-radius: var(--r-sm);
  cursor: pointer;
}
.cat-pager button:hover:not(:disabled) { background: var(--surface-sunken); }
.cat-pager button:disabled { opacity: 0.4; cursor: default; }

.cat-viewer-img       { max-width: 100%; max-height: 70vh; object-fit: contain; align-self: center; }
.cat-viewer-pdf-frame { width: 100%; height: 70vh; border: none; }
.cat-viewer-html-frame {
  width: 100%; height: 70vh; border: 1px solid var(--border-input-cool);
  border-radius: var(--r-xs); background: #fff;
}
.cat-viewer-html-bar { display: flex; justify-content: flex-end; margin-bottom: 8px; }
.cat-viewer-html-toggle {
  font-size: var(--fs-sm); padding: 3px 10px;
  background: var(--surface-sunken); color: var(--text-secondary);
  border: 1px solid var(--border-input-cool); border-radius: var(--r-xs); cursor: pointer;
}
.cat-viewer-html-toggle:hover { color: var(--text-strong); border-color: var(--accent); }
.cat-viewer-map       { width: 100%; height: 70vh; border-radius: var(--r-xs); overflow: hidden; }
.cat-viewer-placeholder {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  min-height: 200px; padding: 32px;
  background: var(--surface-sunken); border: 1px dashed var(--border-input-cool); border-radius: var(--r-xs);
  color: var(--text-secondary);
}
.cat-viewer-spinner {
  width: 36px; height: 36px; margin-bottom: 12px;
  border: 3px solid var(--border-input-cool); border-top-color: var(--accent); border-radius: 50%;
  animation: cat-spin 0.9s linear infinite;
}
@keyframes cat-spin { to { transform: rotate(360deg); } }
.cat-viewer-csv {
  /* padding:0 so rows don't bleed above the sticky header; cell padding gives the inset */
  width: 100%; max-height: 70vh; overflow: auto; padding: 0;
}
.cat-viewer-csv table.data { font-size: var(--fs-sm); }
.cat-viewer-meta {
  width: 100%; max-height: 70vh; overflow: auto; padding: 12px 14px;
  font-size: var(--fs-sm);
  font-family: var(--font-mono);
}
.meta-tree { list-style: none; margin: 0; padding-left: 16px; }
.meta-tree.meta-root { padding-left: 0; }
.cat-viewer-meta li { padding: 1px 0; line-height: var(--lh-relaxed); }
.cat-viewer-meta summary { cursor: pointer; }
.meta-k { color: var(--text-secondary); }
.meta-k::after { content: ":"; margin-right: 6px; }
.meta-v { color: var(--text-strong); white-space: pre-wrap; word-break: break-word; }
.meta-null { color: var(--text-secondary); font-style: italic; }
.meta-badge { color: var(--text-secondary); margin-left: 6px; }
.cat-viewer-pre {
  width: 100%; max-height: 70vh; overflow: auto;
  background: var(--bg-terminal); color: var(--text-terminal);
  font-family: var(--font-mono);
  font-size: var(--fs-xs); padding: 12px;
  border-radius: var(--r-xs);
  white-space: pre-wrap; word-break: break-word;
}
.cat-viewer-truncated {
  margin: 0 0 8px; padding: 6px 10px;
  font-size: var(--fs-sm); color: var(--text-warn, #8a6d00);
  background: var(--bg-warn-soft, #fff7e0);
  border: 1px solid var(--border-warn, #e8d28a);
  border-radius: var(--r-xs);
}

.filter-search {
  display: flex; flex-direction: column; gap: 2px;
  font-size: var(--fs-sm);
}
.filter-search > span { font-size: var(--fs-xs); }
.filter-search input,
.filter-search select {
  font: inherit; padding: 4px 6px;
  border: 1px solid var(--border-input); border-radius: var(--r-xs);
  min-width: 180px;
  background: var(--surface-raised); color: var(--text);
}

.seg-toggle {
  display: inline-flex;
  align-self: flex-end;
  border: 1px solid var(--border-input);
  border-radius: var(--r-sm);
  overflow: hidden;
  background: var(--surface);
}
.seg-btn {
  font: inherit;
  font-size: var(--fs-sm);
  padding: 4px 11px;
  border: none;
  border-right: 1px solid var(--border-input);
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  white-space: nowrap;
}
.seg-btn:last-child { border-right: none; }
.seg-btn:hover { background: var(--surface-hover); }
.seg-btn.active { background: var(--accent); color: var(--accent-fg); }

th.sortable {
  cursor: pointer; user-select: none;
}
th.sortable:hover { background: var(--pill-hover-bg); }
th.sortable.active { background: var(--sort-active-bg); color: var(--accent-strong); }
.sort-arrow { font-size: var(--fs-micro); margin-left: 2px; }

.paginator {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 4px 4px;
  font-size: var(--fs-sm);
}
.paginator-controls { display: flex; align-items: center; gap: 8px; }
.paginator select { font: inherit; padding: 2px 4px; border: 1px solid var(--border-input); border-radius: var(--r-xs); background: var(--surface-raised); color: var(--text); }
.paginator .pill-btn[disabled] {
  opacity: 0.4; pointer-events: none;
}

.preview-modal {
  width: min(1100px, 96vw);
  max-height: 92vh;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.preview-modal-header {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--divider);
}
.preview-modal-title {
  flex: 1; font-size: var(--fs-sm);
  font-family: var(--font-mono);
  word-break: break-all;
}
.preview-modal-close {
  -webkit-appearance: none; appearance: none;
  border: 1px solid var(--pill-border); background: var(--pill-bg); color: var(--pill-fg);
  padding: 7px 13px; border-radius: var(--r-sm);
  font: inherit; font-size: var(--fs-sm); cursor: pointer;
}
.preview-modal-close:hover { background: var(--pill-hover-bg); color: var(--pill-hover-fg); border-color: var(--pill-hover-border); }
.preview-modal-body {
  flex: 1;
  min-height: 0;
  padding: 14px;
  /* overflow:hidden so the inner viewer is the sole scroller and its sticky thead pins correctly */
  overflow: hidden;
}
.preview-modal-body .cat-viewer-img { max-width: 100%; max-height: 76vh; object-fit: contain; display: block; margin: 0 auto; }
.preview-modal-body .cat-viewer-pdf-frame,
.preview-modal-body .cat-viewer-map { width: 100%; height: 76vh; border: none; }
/* leave headroom for the source/page toggle bar above the frame */
.preview-modal-body .cat-viewer-html-frame { width: 100%; height: calc(92vh - 108px); }
/* vh-based cap (a % height resolves against an indefinite flex parent) so the viewer scrolls instead of overgrowing the modal */
.preview-modal-body .cat-viewer-csv,
.preview-modal-body .cat-viewer-pre,
.preview-modal-body .cat-viewer-meta { max-height: calc(92vh - 68px); height: auto; }

/* AI description strip under the header — its own scroller, so it never pushes the preview out of the
   modal; `.has-about` reserves its height from the fixed-height previews below it. */
.cat-viewer-about {
  flex: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 10px 14px;
  padding: 10px 12px;
  max-height: 14vh;  /* +margins stays within the 16vh the previews below reserve via .has-about */
  overflow-y: auto;
  border: 1px solid var(--border);  /* frame the AI block itself, not the whole modal */
  border-radius: var(--r-sm);
  background: var(--surface-sunken);
  font-size: var(--fs-sm);
  line-height: 1.5;
  color: var(--text-secondary);
}
.preview-modal-body.has-about .cat-viewer-img,
.preview-modal-body.has-about .cat-viewer-pdf-frame,
.preview-modal-body.has-about .cat-viewer-map { max-height: calc(76vh - 16vh); height: calc(76vh - 16vh); }
.preview-modal-body.has-about .cat-viewer-img { height: auto; }
.preview-modal-body.has-about .cat-viewer-html-frame { height: calc(92vh - 108px - 16vh); }
.preview-modal-body.has-about .cat-viewer-csv,
.preview-modal-body.has-about .cat-viewer-pre,
.preview-modal-body.has-about .cat-viewer-meta { max-height: calc(92vh - 68px - 16vh); }

.src-modal { width: 97vw; height: 96vh; max-height: 96vh; }
.src-modal .src-body {
  flex: 1; min-height: 0;
  display: flex;
}
.src-tree {
  flex: 0 0 260px;
  overflow: auto;
  padding: 8px;
  border-right: 1px solid var(--divider);
  font-size: var(--fs-base);
}
.src-pane { flex: 1; min-width: 0; display: flex; flex-direction: column; overflow: hidden; }
.src-editor-host { flex: 1; min-height: 0; overflow: hidden; }
.src-editor-host .cm-editor { height: 100%; }
.src-trunc {
  padding: 6px 12px; font-size: var(--fs-sm);
  color: var(--text-muted); background: var(--surface-muted);
  border-bottom: 1px solid var(--divider);
}
.src-hint { padding: 24px; text-align: center; }
.src-dir > summary {
  cursor: pointer; list-style: none;
  display: flex; align-items: center; gap: 6px;
  padding: 3px 4px; border-radius: var(--r-xs);
}
.src-dir > summary::-webkit-details-marker { display: none; }
.src-dir > summary:hover { background: var(--surface-muted); }
.src-children { padding-left: 12px; }
.src-file {
  -webkit-appearance: none; appearance: none;
  border: 0; background: none; font: inherit; cursor: pointer;
  width: 100%; text-align: left;
  display: flex; align-items: center; gap: 6px;
  padding: 3px 4px; border-radius: var(--r-xs);
  color: inherit;
}
.src-file:hover { background: var(--surface-muted); }
.src-file.active { background: var(--accent-soft-bg); color: var(--accent-strong); }
.src-tree .lucide { width: 14px; height: 14px; flex: none; }
.src-tree .hidden, .src-pane .hidden { display: none; }

.files-breadcrumbs {
  /* top:0 — the header's bottom gap already separates it; keep only the gap to the list below */
  margin: 0 0 12px;
  font-size: var(--fs-base);
  display: flex; flex-wrap: wrap; align-items: center;
  background: var(--surface-raised);
  border: 1px solid var(--border-list); border-radius: var(--r-sm);
  padding: 8px 12px;
}
.files-crumb {
  color: var(--text-link); cursor: pointer; font-family: var(--font-mono);
}
.files-crumb:hover { text-decoration: underline; }
.files-up {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; margin-right: 8px; padding: 0;
  background: transparent; border: 1px solid var(--border-list); border-radius: var(--r-xs);
  color: var(--text-link); cursor: pointer;
}
.files-up:hover:not(:disabled) { background: var(--list-row-hover); }
.files-up:disabled { opacity: 0.4; cursor: default; }
.files-up .lucide { width: 15px; height: 15px; }
.files-list {
  list-style: none; margin: 0; padding: 0;
  background: var(--list-bg);
  border: 1px solid var(--list-border); border-radius: var(--list-radius);
  /* fill the pane's leftover height and scroll inside it so the page never grows (mirrors .data-scroll.data-list) */
  flex: 1 1 auto; min-height: 0;
  overflow: auto; overscroll-behavior: contain;
}
/* tighter actions gutter for browse rows (single ⋮) vs the wider default for multi-icon search hits */
.files-list-browse { --files-col-actions: 40px; }
.files-row {
  display: grid;
  /* tracks pinned to tokens (incl. fixed actions width) so columns align across per-row grids */
  grid-template-columns:
    24px 1fr
    var(--files-col-date)
    var(--files-col-size)
    var(--files-col-actions);
  gap: 12px; align-items: center;
  padding: 8px 12px;
  border-bottom: 1px solid var(--list-divider);
  font-size: var(--fs-base);
  /* -webkit- prefix required: Safari ignores the unprefixed property and word-selects on click */
  -webkit-user-select: none;
  user-select: none;
  cursor: default;
}
/* right-anchor actions so file rows (3 icons) and folder rows (1 icon) share the same gutter edge */
.files-row .files-actions { justify-content: flex-end; }
.files-row:last-child { border-bottom: none; }
.files-folder { cursor: pointer; }
.files-row:nth-child(even) { background: var(--list-row-alt); }
.files-row:hover { background: var(--list-row-hover); }
.files-header,
.files-header:hover {
  /* sticky inside the scrolling list so column labels stay put (mirrors the table's sticky thead) */
  position: sticky; top: 0; z-index: 1;
  background: var(--list-head-bg);
  border-bottom: 1px solid var(--list-border);
  font-size: var(--fs-sm);
  font-weight: var(--fw-semibold);
  color: var(--list-head-fg);
  cursor: default;
}
.files-header .files-cell { display: inline-flex; align-items: center; gap: 4px; }
.files-header .sortable {
  cursor: pointer;
  user-select: none;
}
.files-header .sortable:hover { color: var(--text-mono-dark); }
.files-header .sortable.is-active { color: var(--accent-strong); }
.files-header .ralign { justify-content: flex-end; }
.files-header .lucide { width: 12px; height: 12px; }
/* right-align numeric size cells under the right-aligned "Items / Size" header */
.files-row .files-size { text-align: right; }
.files-icon { font-size: var(--fs-md); }
.files-name {
  display: flex; flex-direction: column; gap: 2px;
  font-family: var(--font-mono); word-break: break-all;
}
/* name + share badge on one line so the globe sits beside the name, not stacked below */
.files-name-line {
  display: inline-flex; align-items: baseline; gap: 0;
  flex-wrap: wrap;
}
.files-subname {
  font-size: var(--fs-micro); color: var(--text-muted);
  font-family: var(--font-mono);
}
.files-size { font-size: var(--fs-xs); }
.files-date {
  font-size: var(--fs-xs);
  min-width: 64px;
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
.files-actions {
  display: inline-flex; align-items: center; gap: 6px;
}
.files-act {
  -webkit-appearance: none; appearance: none;
  background: transparent; border: 1px solid transparent;
  color: var(--text-secondary);
  font: inherit; font-size: var(--fs-md); line-height: 1;
  padding: 4px 6px; border-radius: var(--r-xs);
  cursor: pointer;
  transition: background 0.12s, color 0.12s, border-color 0.12s;
}
.files-act:hover:not(:disabled) { background: var(--surface-sunken); }
.files-act:focus-visible {
  outline: none; border-color: var(--accent);
}
.files-act.files-pv:hover:not(:disabled) { color: var(--accent); }
.files-act.files-dl:hover:not(:disabled) { color: var(--accent); }
.files-act.files-rm:hover:not(:disabled) {
  color: var(--danger); background: var(--danger-row-hover-bg);
}
.files-act:disabled,
.files-act.is-disabled {
  opacity: 0.4; cursor: not-allowed;
}

.files-row.files-folder, .files-row.files-file { cursor: pointer; }
.files-row.is-selected,
.files-row.is-selected:hover { background: var(--list-row-selected, var(--list-row-hover)); }
.files-row.is-selected::after {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--accent);
}
.files-row { position: relative; }

.cat-kebab {
  -webkit-appearance: none; appearance: none;
  background: transparent; border: 1px solid transparent;
  color: var(--text-secondary);
  padding: 4px 6px; border-radius: var(--r-xs); cursor: pointer; line-height: 1;
  opacity: 0; transition: opacity 0.12s, background 0.12s, border-color 0.12s;
}
.cat-kebab .lucide { width: 16px; height: 16px; }
.files-row:hover .cat-kebab,
.files-row.is-selected .cat-kebab,
.cat-kebab[aria-expanded="true"],
.cat-kebab:focus-visible { opacity: 1; }
.cat-kebab:hover { background: var(--surface-sunken); }
.cat-kebab:focus-visible { outline: none; border-color: var(--accent); }

.files-share-badge {
  display: inline-flex; align-items: center; align-self: center; margin-left: 6px;
  color: var(--accent);
}
.files-share-badge .lucide { width: 13px; height: 13px; }

.cat-row-menu {
  /* absolute (not fixed) so text keeps crisp sub-pixel AA instead of a composited layer's grayscale softening */
  position: absolute; z-index: 1200;
  min-width: 200px; max-width: min(360px, 92vw);
  /* cap to viewport and scroll internally so a tall menu near the bottom edge isn't clipped */
  max-height: calc(100vh - 16px); overflow-y: auto;
  background: var(--list-bg);
  border: 1px solid var(--list-border); border-radius: var(--list-radius);
  box-shadow: 0 6px 24px var(--shadow-dropdown);
  padding: 4px;
}
.cat-menu-item {
  display: flex; align-items: center; gap: 10px;
  width: 100%; text-align: left;
  background: transparent; border: none; border-radius: var(--r-xs);
  padding: 7px 10px; cursor: pointer; font: inherit; font-size: var(--fs-base);
  color: var(--text);
}
.cat-menu-item:hover:not([disabled]) { background: var(--list-row-hover); }
.cat-menu-item[disabled] { opacity: 0.7; cursor: default; }
.cat-menu-item.is-danger { color: var(--danger); }
.cat-menu-item.is-danger:hover:not([disabled]) { background: var(--danger-row-hover-bg); }
.cat-menu-item.is-checked .cat-menu-icon { color: var(--accent); }
.cat-menu-icon { display: inline-flex; }
.cat-menu-icon .lucide { width: 15px; height: 15px; }
.cat-menu-sep { height: 1px; margin: 4px 6px; background: var(--list-divider); }

.cat-share-url {
  display: flex; align-items: center; gap: 6px; padding: 6px 8px;
}
.cat-share-url-input {
  flex: 1; min-width: 0; font: inherit; font-size: var(--fs-xs);
  font-family: var(--font-mono);
  padding: 4px 6px; border: 1px solid var(--list-border); border-radius: var(--r-xs);
  background: var(--surface-sunken); color: var(--text-mono-dark);
}
.cat-share-copy {
  -webkit-appearance: none; appearance: none;
  background: transparent; border: 1px solid transparent; border-radius: var(--r-xs);
  color: var(--text-secondary); padding: 4px 6px; cursor: pointer; line-height: 1;
}
.cat-share-copy:hover { background: var(--surface-sunken); color: var(--accent); }
.cat-share-copy.is-copied { color: var(--accent); }
.cat-share-copy .lucide { width: 14px; height: 14px; }

.cat-share-master-off {
  display: flex; flex-direction: column; gap: 4px;
  padding: 6px 10px; font-size: var(--fs-xs); color: var(--text-muted);
}
.cat-share-master-link {
  align-self: flex-start;
  background: transparent; border: none; padding: 0; cursor: pointer;
  font: inherit; font-size: var(--fs-xs); color: var(--accent); text-decoration: underline;
}

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--primary-bg);
  color: var(--text-inverse);  /* always light: the toast pill stays dark navy in both themes */
  padding: 9px 16px;
  border-radius: var(--r-xs);
  box-shadow: 0 6px 16px var(--shadow-modal);
  font-size: var(--fs-base);
  opacity: 0;
  transition: opacity 0.18s, transform 0.18s;
  z-index: 200;
  pointer-events: none;
}
.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

