/* Component structure consumes theme.css; keep visual values in that file. */
:root {
  font-family: var(--font-sans);
  color: var(--text);
  background: var(--bg);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html { min-width: var(--viewport-min); overflow-x: hidden; background: var(--bg); }

body {
  margin: 0;
  min-width: var(--viewport-min);
  min-height: 100vh;
  position: relative;
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  background: var(--bg);
  font-weight: var(--font-weight-regular);
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
}

button,
input,
select,
textarea { font: inherit; }

button,
a,
input,
select,
textarea { -webkit-tap-highlight-color: transparent; }

button,
a { color: inherit; }

button { cursor: pointer; }

button:disabled { cursor: not-allowed; }

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
dialog:focus-visible {
  outline: none;
  box-shadow: var(--focus);
}

a { text-decoration-thickness: 1px; text-underline-offset: 3px; }

.skip-link {
  position: fixed;
  z-index: var(--layer-skip);
  top: 8px;
  left: 8px;
  padding: var(--space-8) var(--space-12);
  color: var(--on-accent);
  background: var(--accent-dark);
  border-radius: var(--radius-small);
  transform: translateY(-160%);
  transition: transform var(--duration-fast) ease;
}

.skip-link:focus { transform: translateY(0); }

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -var(--space-1) !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.app-shell { width: min(100%, var(--page-max)); margin: 0 auto; padding: var(--page-padding); }

.app-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-24);
  margin-bottom: var(--space-21);
}

.brand-block { display: flex; align-items: center; gap: var(--space-12); min-width: 0; }

.brand-mark {
  display: grid;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  place-items: center;
  color: var(--on-accent);
  font-size: var(--font-size-icon-sm);
  font-weight: var(--font-weight-strong);
  background: var(--accent);
  border-radius: var(--radius-large);
  box-shadow: var(--shadow-brand);
}

.brand-block h1 { font-weight: var(--font-weight-bold); margin: 0; font-size: var(--font-size-brand); line-height: var(--line-height-brand); letter-spacing: var(--tracking-brand); }
.brand-block p { margin: var(--space-5) 0 0; color: var(--muted); font-size: var(--font-size-caption); }

.header-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: var(--space-8) var(--space-16);
  min-width: 0;
  color: var(--muted);
  font-size: var(--font-size-caption);
  text-align: right;
}

.runtime-meta { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-8) var(--space-12); }

.status-dot { display: inline-flex; align-items: center; gap: var(--space-5); white-space: nowrap; }
.status-dot::before { width: 7px; height: 7px; content: ""; background: var(--subtle); border-radius: var(--radius-round); }
.status-running::before { background: var(--accent); box-shadow: var(--status-ring-normal); }
.status-cooling::before,
.status-pending::before { background: var(--warning); box-shadow: var(--status-ring-warning); }
.status-error::before { background: var(--danger); box-shadow: var(--status-ring-danger); }

.tab-bar {
  display: flex;
  gap: var(--space-4);
  overflow-x: auto;
  border-bottom: var(--stroke-width) solid var(--border-strong);
  scrollbar-width: thin;
}

.tab {
  position: relative;
  flex: 0 0 auto;
  min-height: 42px;
  padding: var(--space-10) var(--space-17);
  color: var(--muted);
  font-size: var(--font-size-body);
  font-weight: var(--font-weight-semibold);
  white-space: nowrap;
  background: transparent;
  border: 0;
  border-radius: var(--radius-small) var(--radius-small) 0 0;
}

.tab::after { position: absolute; right: 12px; bottom: -1px; left: 12px; height: 2px; content: ""; background: transparent; }
.tab:hover { color: var(--accent-dark); background: var(--tab-hover-bg); }
.tab.is-active { color: var(--accent-dark); }
.tab.is-active::after { background: var(--accent); }

.main-content { min-height: 580px; padding-top: var(--space-24); }
.tab-panel[hidden] { display: none; }

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-18);
  margin-bottom: var(--space-19);
}

.toolbar-heading { align-items: center; }
.panel-heading h2 { font-weight: var(--font-weight-bold); margin: 0; font-size: var(--font-size-heading); line-height: var(--line-height-heading); letter-spacing: var(--tracking-heading); }
.panel-hint { margin: var(--space-5) 0 0; color: var(--muted); font-size: var(--font-size-caption); }

.search-field {
  display: flex;
  align-items: center;
  width: min(100%, 320px);
  min-width: 220px;
  color: var(--subtle);
  background: var(--surface);
  border: var(--stroke-width) solid var(--border-strong);
  border-radius: var(--radius-small);
}

.search-field:focus-within { border-color: var(--accent); box-shadow: var(--focus); }
.search-icon { padding-left: var(--space-10); font-size: var(--font-size-icon-md); line-height: 1; transform: translateY(-1px); }
.search-field input { width: 100%; padding: var(--space-9) var(--space-10) var(--space-9) var(--space-7); color: var(--text); background: transparent; border: 0; outline: 0; }
.search-field input::placeholder { color: var(--placeholder); }

.action-toolbar { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: var(--space-8); margin-bottom: var(--space-13); }
.compact-actions { margin-bottom: 0; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--button-height);
  padding: var(--button-padding);
  color: var(--text);
  font-size: var(--button-font-size);
  font-weight: var(--button-font-weight);
  line-height: var(--line-height-control);
  white-space: nowrap;
  background: var(--surface);
  border: var(--stroke-width) solid var(--border-strong);
  border-radius: var(--button-radius);
  transition: background-color var(--duration-fast) ease, border-color var(--duration-fast) ease, color var(--duration-fast) ease;
}

.button:hover:not(:disabled) { border-color: var(--border-hover); background: var(--surface-hover); }
.button:active:not(:disabled) { transform: translateY(1px); }
.button-primary { color: var(--on-accent); background: var(--accent); border-color: var(--accent); }
.button-primary:hover:not(:disabled) { color: var(--on-accent); background: var(--accent-dark); border-color: var(--accent-dark); }
.button-secondary { color: var(--accent-dark); }
.button-ghost { color: var(--muted); background: transparent; border-color: transparent; }
.button-ghost:hover:not(:disabled) { color: var(--accent-dark); background: var(--accent-soft); border-color: var(--accent-soft); }
.button-danger { color: var(--danger); background: var(--surface); border-color: var(--danger-border); }
.button-danger:hover:not(:disabled) { color: var(--danger-hover); background: var(--danger-soft); border-color: var(--danger-border-hover); }
.button:disabled { color: var(--disabled-text); background: var(--disabled-bg); border-color: var(--disabled-border); }
.button-small { min-height: var(--button-height-small); padding: var(--space-5) var(--space-10); font-size: var(--font-size-caption); }
.button-lock { padding-left: var(--space-4); color: var(--subtle); }

.inline-note {
  display: block;
  margin: 0 0 var(--space-14);
  padding: var(--space-8) var(--space-10);
  color: var(--warning);
  font-size: var(--font-size-caption);
  background: var(--warning-soft);
  border-left: var(--stroke-emphasis) solid var(--warning-border);
}

.bulk-toolbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-9);
  min-height: 39px;
  margin-bottom: var(--space-10);
  padding: var(--space-6) var(--space-8) var(--space-6) var(--space-12);
  color: var(--muted);
  background: var(--accent-soft);
  border: var(--stroke-width) solid var(--selection-border);
  border-radius: var(--radius-small);
}

.bulk-toolbar > span { margin-right: auto; font-size: var(--font-size-caption); font-weight: var(--font-weight-semibold); }

.table-frame {
  width: 100%;
  overflow-x: auto;
  background: var(--surface);
  border: var(--stroke-width) solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.data-table { width: 100%; min-width: var(--table-min); border-collapse: collapse; table-layout: auto; }
#products-table { min-width: var(--products-table-min); }
.data-table th,
.data-table td { height: var(--table-row-height); padding: var(--table-cell-padding); border-bottom: var(--stroke-width) solid var(--table-divider); text-align: left; vertical-align: middle; }
.data-table th { color: var(--muted); font-size: var(--table-header-font-size); font-weight: var(--font-weight-bold); white-space: nowrap; background: var(--table-header-bg); }
.data-table td { color: var(--text); font-size: var(--table-font-size); }
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:hover:not(.empty-row) { background: var(--surface-tinted); }
.data-table .select-column { width: 42px; padding-right: var(--space-4); padding-left: var(--space-13); }
.data-table .row-action-column { width: 58px; text-align: right; }
.data-table.list-nowrap td { white-space: nowrap; }
.data-table .sticky-action-column { position: sticky; right: 0; background: var(--surface); }
.data-table th.sticky-action-column { background: var(--table-header-bg); }
.data-table tbody tr:hover:not(.empty-row) .sticky-action-column { background: var(--surface-tinted); }
.table-text-button { padding: 0; border: 0; background: transparent; color: inherit; font: inherit; text-align: left; cursor: pointer; }
.table-text-button:not(:disabled):hover { color: var(--accent-dark); }
.table-text-button:disabled { cursor: default; }

.data-table td:first-of-type input[type="checkbox"],
.data-table th:first-of-type input[type="checkbox"] { accent-color: var(--accent); }

.sort-button {
  display: inline-flex;
  align-items: center;
  gap: var(--space-5);
  padding: 0;
  color: inherit;
  font-size: inherit;
  font-weight: inherit;
  background: transparent;
  border: 0;
}

.header-info { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 14px; height: 14px; border: 1px solid currentColor; border-radius: 50%; color: var(--muted); font-size: 10px; line-height: 1; font-weight: var(--font-weight-semibold); cursor: help; }

.sortable:hover .sort-button { color: var(--accent-dark); }
.sort-indicator { display: inline-block; width: 12px; height: 12px; color: var(--accent); }
.sortable[aria-sort="ascending"] .sort-indicator::after { content: "↑"; }
.sortable[aria-sort="descending"] .sort-indicator::after { content: "↓"; }

.list-title,
.product-name-button,
.link-button { max-width: var(--list-title-max); padding: 0; overflow: hidden; color: var(--accent-dark); font-weight: var(--font-weight-semibold); text-align: left; text-overflow: ellipsis; white-space: nowrap; background: transparent; border: 0; }
button.list-title:hover,
.product-name-button:hover,
.link-button:hover { text-decoration: underline; }
.cell-muted { color: var(--muted); }
.metric-incomplete { display: inline-flex; white-space: nowrap; align-items: center; gap: var(--space-5); }
.quality-flag { display: inline-block; white-space: nowrap; flex-shrink: 0; padding: var(--space-2) var(--space-5); color: var(--warning); font-size: var(--font-size-tiny); font-weight: var(--font-weight-semibold); line-height: var(--line-height-control); background: var(--warning-soft); border-radius: var(--radius-badge); }
.quality-text { color: var(--muted); font-size: var(--font-size-meta); font-weight: var(--font-weight-medium); }

.state-label { display: inline-flex; align-items: center; gap: var(--space-5); font-size: var(--font-size-caption); font-weight: var(--font-weight-semibold); white-space: nowrap; }
.state-label::before { width: 6px; height: 6px; content: ""; border-radius: var(--radius-round); }
.state-normal { color: var(--accent-dark); }.state-normal::before { background: var(--accent); }
.state-pending { color: var(--warning); }.state-pending::before { background: var(--warning-dot); }
.state-error { color: var(--danger); }.state-error::before { background: var(--danger); }
.state-delisted { color: var(--muted); }.state-delisted::before { background: var(--delisted-dot); }

.row-actions { display: flex; justify-content: flex-end; }
.icon-button { width: 30px; height: 30px; padding: 0; color: var(--muted); font-size: var(--font-size-icon-lg); line-height: 1; background: transparent; border: var(--stroke-width) solid transparent; border-radius: var(--radius-small); }
.icon-button:hover { color: var(--text); background: var(--surface-muted); border-color: var(--border); }
.row-menu { position: relative; }
.row-menu summary { display: grid; width: 28px; height: 28px; place-items: center; color: var(--muted); font-size: var(--font-size-icon-sm); cursor: pointer; list-style: none; border-radius: var(--radius-small); }
.row-menu summary::-webkit-details-marker { display: none; }
.row-menu summary:hover { color: var(--accent-dark); background: var(--accent-soft); }
.row-menu[open] summary { color: var(--accent-dark); background: var(--accent-soft); }
.row-menu-list { position: fixed; margin: 0; inset: auto; z-index: var(--layer-menu); min-width: var(--menu-min-width); max-width: calc(100vw - 16px); max-height: calc(100vh - 16px); overflow-y: auto; padding: var(--space-5); background: var(--surface); border: var(--stroke-width) solid var(--border); border-radius: var(--radius-small); box-shadow: var(--shadow-menu); }
.row-menu-list button { display: block; width: 100%; padding: var(--space-8) var(--space-9); color: var(--text); font-size: var(--font-size-caption); text-align: left; background: transparent; border: 0; border-radius: var(--radius-menu-item); }
.row-menu-list button:hover { color: var(--accent-dark); background: var(--accent-soft); }
.row-menu-list button.danger-action { color: var(--danger); }

.empty-row td { height: var(--empty-row-height); text-align: center; }
.empty-state { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: var(--space-6); color: var(--muted); text-align: center; }
.empty-state strong { color: var(--text); font-size: var(--font-size-body); }
.empty-state span { max-width: 440px; font-size: var(--font-size-caption); }
.large-empty { min-height: var(--empty-min-height); margin-top: var(--space-14); background: var(--surface); border: var(--stroke-width) dashed var(--border-strong); border-radius: var(--radius); }
.table-footer { display: flex; align-items: center; justify-content: space-between; gap: var(--space-12); min-height: 38px; padding: var(--space-9) var(--space-2) 0; color: var(--muted); font-size: var(--font-size-caption); }

.modal-fields { display: grid; gap: var(--space-11); }
.form-layout { display: grid; align-items: start; gap: var(--space-20); }
.two-column-form { grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr); max-width: var(--form-max); }
.form-card,
.info-panel,
.section-panel,
.chart-panel { padding: var(--panel-padding); background: var(--surface); border: var(--stroke-width) solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.form-card { display: flex; flex-direction: column; gap: var(--space-11); }
.form-section-title { color: var(--text); font-size: var(--font-size-body); font-weight: var(--font-weight-strong); }
.field-label,
.compact-field > span { display: block; color: var(--muted); font-size: var(--font-size-caption); font-weight: var(--font-weight-semibold); }
.column-filter-editor input:not([type="checkbox"]),
.modal-fields input,
.modal-fields select,
.modal-fields textarea,
.production-inline,
#tikhub-key,
#model-form input:not([type="checkbox"]),
.form-card textarea,
.form-card input[type="url"],
.form-card input[type="number"],
.form-card select,
.form-card input[type="date"],
.settings-card textarea { width: 100%; padding: var(--space-9) var(--space-10); color: var(--text); background: var(--surface); border: var(--stroke-width) solid var(--border-strong); border-radius: var(--radius-small); outline: 0; }
.column-filter-editor input:not([type="checkbox"]):focus,
.modal-fields input:focus,
.modal-fields select:focus,
.modal-fields textarea:focus,
.production-inline:focus,
.form-card textarea:focus,
.form-card input:focus,
.form-card select:focus { border-color: var(--accent); box-shadow: var(--focus); }
.form-card textarea, .modal-fields textarea { resize: vertical; }
.product-input-heading { display:flex; flex-wrap:wrap; align-items:baseline; gap:var(--space-8); }
.form-help { color: var(--muted); font-size: var(--font-size-caption); }
.form-actions { display: flex; align-items: center; flex-wrap: wrap; justify-content: flex-end; gap: var(--space-8); }
.form-status { min-height: 20px; color: var(--muted); font-size: var(--font-size-caption); }
.form-status.success { color: var(--accent-dark); }.form-status.error { color: var(--danger); }
.info-panel { display: flex; flex-direction: column; gap: var(--space-12); background: var(--surface-tinted); box-shadow: none; }
.rule-list { display: grid; gap: var(--space-10); margin: 0; padding-left: var(--space-17); color: var(--muted); font-size: var(--font-size-caption); }
.notice-block { display: grid; gap: var(--space-4); margin-top: auto; padding: var(--space-11); color: var(--muted); background: var(--accent-soft); border-radius: var(--radius-small); }
.notice-block strong { color: var(--accent-dark); font-size: var(--font-size-caption); }.notice-block span { font-size: var(--font-size-caption); }

.analysis-controls { display: flex; align-items: flex-end; flex-wrap: wrap; gap: var(--space-10); }
.compact-field { display: grid; gap: var(--space-4); min-width: 132px; }
.compact-field select,
.compact-field input { min-height: var(--button-height); padding: var(--space-7) var(--space-9); color: var(--text); background: var(--surface); border: var(--stroke-width) solid var(--border-strong); border-radius: var(--radius-small); }
.compact-field select:focus,
.compact-field input:focus { outline: 0; border-color: var(--accent); box-shadow: var(--focus); }
.range-toolbar { display: flex; gap: var(--space-4); margin-bottom: var(--space-13); }
.detail-main .range-toolbar { flex-wrap: wrap; }
.detail-main .range-button { white-space: nowrap; flex-shrink: 0; }
.range-button,
.filter-button { padding: var(--space-6) var(--space-12); color: var(--muted); font-size: var(--font-size-caption); font-weight: var(--font-weight-semibold); background: var(--surface); border: var(--stroke-width) solid var(--border); border-radius: var(--radius-small); }
.range-button:hover,
.range-button.is-active,
.filter-button:hover,
.filter-button.is-active { color: var(--accent-dark); background: var(--accent-soft); border-color: var(--filter-border); }
.analysis-summary { display: grid; grid-template-columns: minmax(170px, 2fr) repeat(3, minmax(110px, 1fr)); gap: var(--space-1); margin-bottom: var(--space-16); background: var(--border); border: var(--stroke-width) solid var(--border); border-radius: var(--radius); overflow: hidden; }
.analysis-summary > div { display: grid; gap: var(--space-3); min-height: 66px; padding: var(--space-12) var(--space-15); background: var(--surface); }
.summary-label { color: var(--muted); font-size: var(--font-size-meta); }.analysis-summary strong { overflow: hidden; font-size: var(--font-size-summary); text-overflow: ellipsis; white-space: nowrap; }
.analysis-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: var(--space-16); align-items: start; }
.analysis-column { display: grid; gap: var(--space-14); min-width: 0; }
.chart-panel { min-height: var(--chart-panel-min-height); padding-bottom: var(--space-12); }
.section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-12); margin-bottom: var(--space-12); }
.section-heading h3 { font-weight: var(--font-weight-bold); margin: 0; font-size: var(--font-size-body); }.chart-canvas { width: 100%; height: var(--chart-height); }
.nested-table-frame { box-shadow: none; }.compact-table { min-width: var(--compact-table-min); }.compact-table th, .compact-table td { height: var(--table-row-height-compact); padding: var(--space-7) var(--space-10); }
.compact-table .empty-row td { height: 100px; }

.settings-stack { display: grid; gap: var(--space-16); max-width: var(--settings-max); }
.settings-card { gap: var(--space-14); }.settings-card .section-heading { align-items: center; margin-bottom: 0; }
.settings-fields { display: grid; grid-template-columns: repeat(3, minmax(150px, 1fr)); gap: var(--space-12); }
.settings-fields .compact-field { gap: var(--space-5); }.settings-foot { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--space-12); color: var(--muted); font-size: var(--font-size-caption); }
.checkbox-field { display: inline-flex; align-items: center; gap: var(--space-8); color: var(--text); font-size: var(--font-size-body-sm); font-weight: var(--font-weight-semibold); }.checkbox-field input { width: 16px; height: 16px; accent-color: var(--accent); }
.copy-area { min-height: 110px; color: var(--muted) !important; font-family: var(--font-mono); font-size: var(--font-size-caption); line-height: var(--line-height-code); resize: vertical; }
.maintenance-row { display: flex; align-items: center; justify-content: space-between; gap: var(--space-12); color: var(--muted); font-size: var(--font-size-caption); }

.log-filter-bar { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-bottom: var(--space-12); }
.pagination-footer { align-items: center; }.pagination-controls { display: flex; align-items: center; gap: var(--space-8); }.pagination-controls span { min-width: 60px; text-align: center; }

.app-modal { width: min(var(--modal-width), calc(100% - 32px)); max-height: min(var(--modal-max-height), calc(100vh - 40px)); padding: 0; color: var(--text); background: var(--surface); border: var(--stroke-width) solid var(--border-strong); border-radius: var(--radius-large); box-shadow: var(--shadow-modal); }
.app-modal::backdrop { background: var(--backdrop); }
.modal-shell { display: flex; flex-direction: column; max-height: min(var(--modal-max-height), calc(100vh - 40px)); }
.modal-header { display: flex; align-items: center; justify-content: space-between; gap: var(--space-12); padding: var(--space-15) var(--space-18) var(--space-12); border-bottom: var(--stroke-width) solid var(--border); }.modal-header h2 { font-weight: var(--font-weight-bold); margin: 0; font-size: var(--font-size-modal); }
.modal-body { overflow: auto; padding: var(--space-17) var(--space-18); }.modal-actions { display: flex; justify-content: flex-end; gap: var(--space-8); padding: var(--space-12) var(--space-18); border-top: var(--stroke-width) solid var(--border); }
.modal-copy { white-space: pre-wrap; word-break: break-word; }.modal-meta { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-10) var(--space-16); margin-bottom: var(--space-15); }.modal-meta div { display: grid; gap: var(--space-3); }.modal-meta dt { color: var(--muted); font-size: var(--font-size-meta); }.modal-meta dd { margin: 0; font-size: var(--font-size-body-sm); font-weight: var(--font-weight-semibold); word-break: break-word; }
.preview-table { min-width: var(--preview-table-min); }.preview-table .selected-row { background: var(--accent-soft); }.modal-table-frame { overflow-x: auto; border: var(--stroke-width) solid var(--border); border-radius: var(--radius-small); }
.detail-layout { display: grid; grid-template-columns: var(--cover-size) minmax(0, 1fr); gap: var(--space-16); align-items: start; }.detail-cover { display: block; width: var(--cover-size); height: var(--cover-size); object-fit: cover; background: var(--image-placeholder); border: var(--stroke-width) solid var(--border); border-radius: var(--radius-small); }.detail-cover.is-failed { display: grid; place-items: center; color: var(--muted); font-size: var(--font-size-caption); object-fit: initial; }.detail-main h3 { font-weight: var(--font-weight-bold); margin: 0 0 var(--space-7); font-size: var(--font-size-detail); }.detail-chart { height: var(--detail-chart-height); margin-top: var(--space-14); }.detail-section-title { margin: var(--space-17) 0 var(--space-8); font-size: var(--font-size-body-sm); }

.toast-region { position: fixed; z-index: var(--layer-toast); right: 18px; bottom: 18px; display: grid; gap: var(--space-8); width: min(360px, calc(100vw - 36px)); pointer-events: none; }.toast { padding: var(--space-11) var(--space-13); color: var(--text); font-size: var(--font-size-caption); background: var(--surface); border: var(--stroke-width) solid var(--border-strong); border-left: var(--stroke-emphasis) solid var(--accent); border-radius: var(--radius-small); box-shadow: var(--shadow-toast); }.toast.error { border-left-color: var(--danger); }.toast.warning { border-left-color: var(--warning); }

@media (max-width: 900px) {
  .app-shell { padding: var(--page-padding-tablet); }
  .app-header { align-items: flex-start; flex-direction: column; gap: var(--space-14); }
  .header-meta { justify-content: flex-start; text-align: left; }
  .two-column-form,
  .analysis-grid { grid-template-columns: 1fr; }
  .analysis-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .settings-fields { grid-template-columns: repeat(2, minmax(150px, 1fr)); }
}

@media (max-width: 600px) {
  body { font-size: var(--font-size-body-sm); }
  .app-shell { padding: var(--page-padding-mobile); }
  .main-content { padding-top: var(--space-18); }
  .panel-heading,
  .toolbar-heading { align-items: stretch; flex-direction: column; }
  .search-field { width: 100%; min-width: 0; }
  .empty-row td { text-align: left; }
  .empty-row .empty-state { position: sticky; left: 14px; width: calc(100vw - 60px); }
  .action-toolbar { justify-content: flex-start; }
  .button { min-height: var(--button-height-mobile); }
  .form-card, .info-panel, .section-panel, .chart-panel { padding: var(--panel-padding-mobile); }
  .analysis-controls { align-items: stretch; flex-direction: column; }
  .compact-field { width: 100%; }
  .analysis-summary { grid-template-columns: 1fr 1fr; }
  .analysis-summary > div { min-height: 60px; padding: var(--space-10); }
  .settings-fields { grid-template-columns: 1fr; }
  .settings-foot, .maintenance-row { align-items: flex-start; flex-direction: column; }
  .settings-foot .form-actions { width: 100%; justify-content: flex-start; }
  .detail-layout { grid-template-columns: minmax(0, 1fr); }.detail-cover { width: var(--cover-size-mobile); height: var(--cover-size-mobile); }
  .modal-body { padding: var(--space-14); }.modal-actions { padding: var(--space-10) var(--space-14); }
  .modal-meta { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; }
}

.reading-history .data-table { min-width: var(--history-table-min); }

.detail-link { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }

/* Red薯台 workbench shell. Business components above keep their existing
 * density and semantic tokens; these rules only define the navigation frame. */
.app-shell { width: min(100%, var(--page-max)); padding: var(--page-padding); }
.app-header { margin-bottom: var(--space-18); }
.nav-drawer-toggle { display: none; width: 34px; height: 34px; padding: 0; color: var(--accent-dark); background: var(--accent-soft); border: var(--stroke-width) solid var(--selection-border); border-radius: var(--radius-small); }
.workspace-layout { display: grid; grid-template-columns: 224px minmax(0, 1fr); gap: var(--space-24); align-items: start; }
.workspace-sidebar { position: sticky; top: var(--space-16); display: grid; gap: var(--space-14); min-width: 0; padding: var(--space-14); background: var(--surface); border: var(--stroke-width) solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); }
.primary-nav,
.secondary-nav { display: grid; gap: var(--space-4); min-width: 0; }
.primary-nav-item,
.secondary-nav-item,
.secondary-page-item { display: flex; align-items: center; justify-content: space-between; gap: var(--space-8); width: 100%; min-height: 36px; padding: var(--space-8) var(--space-10); color: var(--muted); font-size: var(--font-size-body-sm); font-weight: var(--font-weight-semibold); text-align: left; background: transparent; border: var(--stroke-width) solid transparent; border-radius: var(--radius-small); }
.primary-nav-item:hover:not(:disabled),
.secondary-nav-item:hover:not(:disabled),
.secondary-page-item:hover:not(:disabled) { color: var(--accent-dark); background: var(--surface-muted); }
.primary-nav-item.is-active,
.secondary-page-item.is-active,
.secondary-nav-item.is-leaf.is-active { color: var(--accent-dark); background: var(--accent-soft); border-color: var(--selection-border); }
.primary-nav-item.is-active { font-weight: var(--font-weight-bold); }
.primary-nav-item:disabled,
.secondary-nav-item:disabled,
.secondary-page-item:disabled { color: var(--disabled-text); }
.secondary-nav-section { display: grid; gap: var(--space-3); }
.secondary-nav-item { color: var(--text); font-size: var(--font-size-caption); }
.secondary-page-list { display: grid; gap: var(--space-2); padding-left: var(--space-10); }
.secondary-page-item { min-height: 32px; padding: var(--space-6) var(--space-8); font-size: var(--font-size-caption); font-weight: var(--font-weight-medium); }
.planned-badge { flex: 0 0 auto; color: var(--subtle); font-size: var(--font-size-tiny); font-weight: var(--font-weight-medium); }
.workspace-main { min-width: 0; }
.content-toolbar { display: flex; align-items: center; justify-content: space-between; gap: var(--space-12); min-height: 29px; margin-bottom: var(--space-8); }
.breadcrumbs { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-7); min-width: 0; color: var(--muted); font-size: var(--font-size-caption); }
.breadcrumb-separator { color: var(--subtle); }
.breadcrumb-page { color: var(--text); font-weight: var(--font-weight-semibold); }
.route-notice { flex: 0 1 auto; max-width: 52%; padding: var(--space-6) var(--space-9); color: var(--warning); font-size: var(--font-size-caption); background: var(--warning-soft); border: var(--stroke-width) solid var(--warning-border); border-radius: var(--radius-small); }
.tertiary-tabs { max-width: 100%; margin-bottom: 0; }
.list-filter-tabs { max-width: 100%; flex-shrink: 0; margin-bottom: var(--space-20); }
.main-content:has(> .tab-panel:not([hidden]) > .list-filter-tabs) { padding-top: 0; }
.main-content { min-width: 0; min-height: 580px; padding-top: var(--space-20); }
.nav-drawer-backdrop { display: none; }

@media (max-width: 900px) {
  .workspace-layout { grid-template-columns: 196px minmax(0, 1fr); gap: var(--space-16); }
  .workspace-sidebar { padding: var(--space-10); }
  .content-toolbar { align-items: flex-start; flex-direction: column; }
  .route-notice { max-width: 100%; }
}

@media (max-width: 600px) {
  .app-shell { padding: var(--page-padding-mobile); }
  .app-header { align-items: center; flex-direction: row; gap: var(--space-10); margin-bottom: var(--space-14); }
  .brand-block { gap: var(--space-8); }
  .nav-drawer-toggle { display: inline-grid; flex: 0 0 auto; place-items: center; }
  .header-meta { flex: 1 1 auto; justify-content: flex-end; min-width: 0; font-size: var(--font-size-meta); }
  .runtime-meta { justify-content: flex-end; gap: var(--space-4) var(--space-8); }
  .runtime-label { display: none; }
  .workspace-layout { display: block; }
  .workspace-sidebar { position: fixed; z-index: 40; top: 0; bottom: 0; left: 0; display: block; width: min(84vw, 300px); height: 100dvh; padding: var(--space-16) var(--space-12); overflow-y: auto; border-radius: 0 var(--radius) var(--radius) 0; box-shadow: var(--shadow-menu); transform: translateX(-110%); transition: transform var(--duration-fast) ease; }
  .workspace-sidebar.is-open { transform: translateX(0); }
  .primary-nav { margin-top: var(--space-10); }
  .nav-drawer-backdrop { position: fixed; z-index: 35; inset: 0; display: block; pointer-events: none; background: var(--backdrop); opacity: 0; transition: opacity var(--duration-fast) ease; }
  .nav-drawer-backdrop.is-visible { pointer-events: auto; opacity: 1; }
  .workspace-main { width: 100%; min-width: 0; }
  .content-toolbar { margin-bottom: var(--space-6); }
  .breadcrumbs { max-width: 100%; }
  .tertiary-tabs, .list-filter-tabs { width: 100%; max-width: 100%; overflow-x: auto; }
  .list-filter-tabs { margin-bottom: var(--space-16); }
  .tertiary-tabs .tab, .list-filter-tabs .tab { min-height: 39px; padding-right: var(--space-12); padding-left: var(--space-12); }
  .main-content { min-height: 0; padding-top: var(--space-16); }
}

/* Accordion submenus stay with their parent and share the theme spacing. */
.primary-nav-group { min-width: 0; }
.primary-nav-group > .secondary-nav { margin: var(--space-4) 0 var(--space-8) var(--space-10); padding-left: var(--space-8); border-left: var(--stroke-width) solid var(--border); }

.shop-name { white-space: nowrap; }

/* Standard lists scroll inside the table, keeping navigation and controls visible. */
.app-shell:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) { height: 100dvh; display: flex; flex-direction: column; }
.app-shell:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) > .app-header { flex-shrink: 0; }
.workspace-layout:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) { flex: 1; min-height: 0; align-items: stretch; }
.workspace-main:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) { height: 100%; min-height: 0; display: flex; flex-direction: column; }
.workspace-main:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) > .content-toolbar,
.workspace-main:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) > .tertiary-tabs { flex-shrink: 0; }
.main-content:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) { flex: 1; min-height: 0; overflow: auto; }
.tab-panel:not([hidden]):has(> :is(.list-page, .knowledge-root)) { height: 100%; }
.list-page { height: 100%; display: flex; flex-direction: column; }
.list-page > :not(.table-frame) { flex-shrink: 0; }
.list-page > .table-frame { flex: 1 1 auto; min-height: 120px; overflow: auto; overscroll-behavior: contain; }
.list-page > .table-frame > .data-table > thead > tr > th { position: sticky; top: 0; z-index: 2; }
.list-page > .table-frame > .data-table > thead > tr > th.sticky-action-column { z-index: 3; }
@media (min-width: 601px) {
  .workspace-layout:has(.tab-panel:not([hidden]) > :is(.list-page, .knowledge-root)) > .workspace-sidebar { top: 0; max-height: 100%; height: fit-content; overflow-y: auto; }
}

/* Notes-owned TikHub forms and bounded response preview. */
.tikhub-fields { margin-top: var(--space-16); flex-wrap: wrap; }
.tikhub-fields .compact-field { flex: 1 1 260px; min-width: 0; }
.tikhub-fields .tikhub-tall-field { grid-column: 1 / -1; width: 100%; }
.tikhub-tall-field textarea { height: 150px; min-height: 60px; resize: vertical; width: 100%; box-sizing: border-box; }
.tikhub-result { white-space: pre-wrap; overflow-wrap: anywhere; max-height: 65vh; overflow: auto; font-size: var(--font-size-caption); }
#panel-notes-query > .settings-card + .settings-card { margin-top: var(--space-16); }

/* Notes board: preserve readable columns inside a horizontal scroll region. */
.notes-table { min-width: 1900px; }
.list-cover,
.notes-cover { display: block; width: var(--list-cover-size); height: var(--list-cover-size); padding: 0; overflow: hidden; border: 0; border-radius: var(--radius-small); cursor: pointer; }
.list-cover img,
.notes-cover img { display: block; width: var(--list-cover-size); height: var(--list-cover-size); object-fit: cover; }
.notes-lines { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; height: 40px; line-height: 20px; white-space: normal; overflow: hidden; overflow-wrap: anywhere; }
.notes-title { width: 200px; }
.list-title-multiline { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; height: var(--list-title-multiline-height); line-height: var(--list-title-multiline-line-height); white-space: normal; overflow-wrap: anywhere; }
.notes-body { width: 230px; }
.notes-tags { width: 160px; }
.notes-author { width: 100px; overflow: hidden; text-overflow: ellipsis; }
.notes-link { display: block; width: 110px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.notes-gallery { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-start; justify-content: center; }
.notes-gallery img { width: 360px; max-width: 100%; height: auto; object-fit: contain; }
.app-modal:has(.notes-gallery) { width: min(820px, calc(100% - 32px)); }

/* Collected creator profiles share the notes toolbar and touch controls. */
.creators-table { min-width: 1150px; }
.creators-name { max-width: 180px; overflow: hidden; text-overflow: ellipsis; }

.tikhub-queue-items { list-style: none; padding: 0; max-height: 360px; overflow: auto; }
.tikhub-queue-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.tikhub-queue-row span { min-width: 0; overflow-wrap: anywhere; }
.tikhub-queue-row button { flex-shrink: 0; }

/* Selection library uses the shared list skin and existing image sizes. */
.library-links { display: flex; flex-direction: column; gap: 4px; }
.library-picker-search { width: 100%; margin-bottom: 12px; }

/* Global model configuration keeps fields and actions on a single scrollable row. */
.model-config-row { display: flex; align-items: end; gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.model-config-row .field { display: flex; flex-direction: column; gap: 8px; flex: 1 0 130px; min-width: 0; }
.model-config-row .field:nth-child(2) { flex: 2 0 230px; }
.model-config-row input:not([type="checkbox"]) { width: 100%; min-width: 0; }
.model-actions { display: flex; align-items: center; gap: 10px; flex-shrink: 0; height: 40px; }
/* Global enable/disable control: model settings is the visual baseline. */
.switch-field { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; color: var(--text); font-size: var(--font-size-body); font-weight: var(--font-weight-regular); cursor: pointer; }
input[type="checkbox"][role="switch"] { appearance: none; -webkit-appearance: none; flex: 0 0 36px; width: 36px; height: 22px; min-height: 22px; margin: 0; padding: 0; border: 0; border-radius: 20px; background: var(--border-strong); position: relative; cursor: pointer; box-shadow: none; }
input[type="checkbox"][role="switch"]::after { content: ""; position: absolute; width: 16px; height: 16px; top: 3px; left: 3px; border-radius: 50%; background: var(--on-accent); }
input[type="checkbox"][role="switch"]:checked { background: var(--accent); }
input[type="checkbox"][role="switch"]:checked::after { left: 17px; }
input[type="checkbox"][role="switch"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; box-shadow: none; }
input[type="checkbox"][role="switch"]:disabled { opacity: .5; cursor: not-allowed; }
.switch-field:has(input:disabled) { cursor: not-allowed; }
.switch-field > span { min-width: 0; overflow-wrap: anywhere; }


/* Production content sizes and semantic status colors; table skin stays shared. */
.production-edit-cell { min-width: 100px; min-height: 36px; }
.production-inline { width: 220px; min-height: 36px; }
.production-status-control { position: relative; }
.production-status-menu { position: absolute; top: calc(100% + 6px); right: 0; z-index: 30; display: grid; gap: 4px; min-width: 110px; }
.production-status-menu[hidden] { display: none; }
.production-status-tag { display: inline-block; padding: 4px 10px; border-radius: 6px; white-space: nowrap; }
.production-status-0 { background: var(--production-in-progress-bg); color: var(--production-in-progress-text); }
.production-status-1 { background: var(--production-completed-bg); color: var(--production-completed-text); }
.production-status-2 { background: var(--production-listed-bg); color: var(--production-listed-text); }
.production-status-3 { background: var(--production-delisted-bg); color: var(--production-delisted-text); }
.production-status-4 { background: var(--production-archived-bg); color: var(--production-archived-text); }
.production-gallery { display: flex; flex-wrap: wrap; gap: 12px; }
.production-image-tile { position: relative; width: 200px; max-width: 100%; }
.production-image-tile img { display: block; width: 200px; max-width: 100%; height: auto; }
.production-image-delete { position: absolute; top: 4px; right: 4px; }
.production-image-order { display: flex; gap: 6px; margin-top: 4px; }
.production-dropzone { display: block; padding: 20px; border: 1px dashed var(--border-strong); border-radius: 8px; cursor: pointer; }
.production-dropzone input { display: block; max-width: 100%; margin-top: 10px; }
.production-clear-confirm { margin-top: 16px; }
.production-benchmark-option { display: flex; gap: 10px; align-items: center; margin-block: 8px; }
.production-benchmark-option input { width: auto; }

.shop-name-multiline { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; max-height: var(--list-title-multiline-height); line-height: var(--list-title-multiline-line-height); white-space: normal; overflow: hidden; overflow-wrap: anywhere; text-overflow: ellipsis; }

/* Library content widths; two-line truncation uses shared list variants. */
#library-table .list-title { width: var(--list-title-max); }
#library-table .shop-name { width: 100px; }

/* Production column content widths; all truncation uses shared two-line variants. */
#production-table .production-name { width: 140px; }
#production-table .production-title { width: 260px; }
#production-table .production-detail { width: 160px; }
#production-table .production-time { width: 100px; }
#production-table .production-shop, #production-table .production-shop .shop-name { width: 120px; }
.production-benchmark-cell { min-width: 110px; cursor: pointer; }
.production-benchmark-edit { display: block; width: 100%; min-height: 24px; }

#production-table .production-id, #draft-table .draft-id { width: 100px; -webkit-line-clamp: 3; height: calc(3 * var(--list-title-multiline-line-height)); }

/* Library attachments: content controls only, using the shared table skin. */
.library-files-cell { min-width: 100px; cursor: pointer; }
.library-files-open { width: 100px; min-height: 36px; }
.library-file-dropzone { display: block; padding: 24px; border: 1px dashed var(--border-strong); border-radius: 8px; cursor: pointer; }
.library-file-dropzone.is-dragging { border-color: var(--accent); }
.library-file-dropzone input { display: block; max-width: 100%; margin-top: 12px; }
.library-file-row { display: flex; align-items: baseline; gap: 12px; margin-block: 12px; }
.library-file-row a { overflow-wrap: anywhere; min-width: 0; }
.library-file-row span { flex-shrink: 0; }

.library-file-info { display: flex; flex: 1; flex-wrap: wrap; gap: 10px; min-width: 0; }
.library-file-actions { display: flex; flex-shrink: 0; gap: 6px; margin-left: auto; }
.library-file-confirm { margin-top: 16px; overflow-wrap: anywhere; }
.library-file-confirm button { margin-right: 8px; }
@media (max-width: 600px) { .library-file-row { flex-wrap: wrap; } .library-file-info { flex-basis: 100%; } }

/* Generated-note column content; shared list skin remains authoritative. */
#draft-table .production-edit-cell { width: 140px; }
#draft-table td:nth-child(8) .production-edit-cell { width: 240px; }
#draft-table td:nth-child(9) .production-edit-cell { width: 200px; }
#draft-table .production-time { width: 110px; }

/* Shared list pager keeps controls reachable on narrow screens. */
.pagination-footer { flex-wrap: wrap; }
.pagination-footer > span { white-space: nowrap; }
@media (max-width: 640px) {
  .pagination-footer { gap: 6px 12px; }
  .pagination-footer .pagination-controls { order: 3; flex: 0 0 100%; justify-content: center; }
}

/* Team access uses the same cards, tabs and list skin as the workbench. */
.auth-layout { max-width: 440px; margin: 10vh auto; padding: 20px; }
.auth-layout .modal-fields { display: grid; gap: 16px; }
.member-scope { max-width: 240px; }
.token-secret { width: 100%; overflow-wrap: anywhere; }
[data-permission][hidden], .app-shell[hidden] { display: none !important; }

.app-header .brand-block { flex-shrink: 0; }
.session-controls { display: flex; align-items: center; gap: var(--space-8); min-width: 0; }
#session-identity { overflow-wrap: anywhere; }
#session-logout { flex-shrink: 0; min-height: 26px; padding: var(--space-4) var(--space-8); color: var(--muted); font: inherit; background: var(--surface-muted); border-color: transparent; border-radius: var(--radius-small); }
#session-logout:hover { color: var(--accent-dark); background: var(--accent-soft); }
@media (max-width: 600px) {
  .app-header { flex-wrap: wrap; gap: 8px 12px; }
  .app-header .brand-block { flex: 1 0 100%; }
  .brand-block h1 { white-space: nowrap; }
  .app-header .header-meta { flex: 1 1 120px; }
}

/* Shared table-header filter; popovers reuse the row-menu top layer. */
.header-filter summary { display: inline-flex; width: auto; gap: 6px; font: inherit; white-space: nowrap; }
.header-filter.is-filtered summary { color: var(--accent-dark); }
.header-filter-icon { width: 11px; height: 11px; background: currentColor; clip-path: polygon(0 0, 100% 0, 60% 45%, 60% 100%, 40% 80%, 40% 45%); }
.header-filter .row-menu-list { min-width: 190px; }
.header-filter .member-scope { display: flex; flex-direction: column; align-items: stretch; gap: 8px; padding: 6px; font-weight: normal; }

/* Shared column filter controls and active conditions. */
.list-filter-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 12px; }
.list-filter-bar[hidden], .filter-option[hidden] { display: none; }
.filter-chip { border: 1px solid var(--border); border-radius: var(--radius-small); color: var(--accent-dark); background: var(--accent-soft); padding: 6px 9px; max-width: 100%; overflow-wrap: anywhere; text-align: left; }
.filters-clear { margin-left: auto; }
.data-table th .header-filter[data-filter-key] { display: inline-block; margin-left: 5px; vertical-align: middle; }
.data-table th .header-filter[data-filter-key] summary { width: 24px; height: 28px; justify-content: center; }
.column-filter-editor { display: flex; flex-direction: column; gap: 10px; min-width: 220px; max-width: calc(100vw - 48px); padding: 8px; color: var(--text); font-weight: normal; font-size: var(--font-size-caption); }
.column-filter-editor input[type=search], .column-filter-editor input[type=date] { width: 100%; min-width: 0; }
.column-filter-editor .field { display: grid; gap: 5px; }
.filter-options { max-height: 240px; overflow: auto; }
.filter-option { display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 4px; white-space: normal; overflow-wrap: anywhere; }
.filter-option input { flex: 0 0 auto; }
.column-filter-actions, .filter-shortcuts { display: flex; gap: 6px; padding: 4px 8px; }
.header-filter .row-menu-list .column-filter-actions button, .header-filter .row-menu-list .filter-shortcuts button { width: auto; text-align: center; }
.header-filter .row-menu-list .column-filter-actions .button-primary { background: var(--accent); color: white; }
.filter-mobile-trigger { display: none; }
.all-list-filters { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
@media (max-width: 640px) {
  .filter-mobile-trigger:not([hidden]) { display: inline-flex; }
  .toolbar-heading:has(.filter-mobile-trigger:not([hidden])) { flex-direction: row; flex-wrap: wrap; gap: 8px; }
  .toolbar-heading:has(.filter-mobile-trigger:not([hidden])) .action-toolbar { flex-basis: 100%; }
  .toolbar-heading:has(.filter-mobile-trigger:not([hidden])) .search-field { flex: 1 1 200px; width: auto; min-width: 0; }
  .filter-chip { font-size: var(--font-size-caption); }
}

/* Project skills declare only column/content dimensions; shared table skin applies. */
#project-skills-table th:nth-child(2) { min-width: 200px; }
#project-skills-table .skill-description { width: 300px; min-height: 36px; }
#project-skills-table th:nth-child(4),
#project-skills-table th:nth-child(6),
#project-skills-table th:nth-child(7) { min-width: 120px; }

/* Prompt content dimensions; shared list skin and single-line title apply. */
#prompts-table th:nth-child(2) { min-width: 200px; }
#prompts-table .prompt-content { width: 360px; min-height: 36px; }
#prompts-table th:nth-child(4),
#prompts-table th:nth-child(5) { min-width: 120px; }

/* The common filter entry is also available without a table header. */
.filter-mobile-trigger.filter-toolbar-trigger { display:inline-flex; }
/* Media list content shares the fixed footer/scroll region contract. */
.tab-panel:not([hidden]):has(> .list-page[data-list-layout="media"]) { display:flex; flex-direction:column; min-height:0; }
.tab-panel > .list-page[data-list-layout="media"] { height:auto; flex:1; min-height:0; }
.list-page[data-list-layout="media"] > .list-card-frame { flex:1 1 auto; min-height:120px; overflow:auto; overscroll-behavior:contain; }
.toolbar-heading:has(.filter-toolbar-trigger) { justify-content:flex-start; }
.toolbar-heading:has(.filter-toolbar-trigger) > .action-toolbar { margin-left:auto; }
