:root {
  color-scheme: light;
  --blue: #2563eb;
  --sky: #0ea5e9;
  --cyan: #22d3ee;
  --danger: #e11d48;
  --text: #132033;
  --soft: #334b66;
  --muted: #66788f;
  --line: rgba(37, 99, 235, 0.14);
  --line-strong: rgba(37, 99, 235, 0.42);
  --glass: rgba(255, 255, 255, 0.56);
  --glass-strong: rgba(255, 255, 255, 0.72);
  --shadow: rgba(47, 83, 117, 0.13);
  --radius: 22px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  background:
    radial-gradient(circle at 12% 8%, rgba(37, 99, 235, 0.14), transparent 28rem),
    radial-gradient(circle at 88% 16%, rgba(14, 165, 233, 0.13), transparent 30rem),
    radial-gradient(circle at 55% 88%, rgba(34, 211, 238, 0.09), transparent 26rem),
    linear-gradient(135deg, #f4f9ff 0%, #e9f4fc 45%, #f8fbff 100%);
  overflow-x: hidden;
}

body::before,
body::after {
  position: fixed;
  inset: 0;
  z-index: -1;
  content: "";
  pointer-events: none;
}

body::before {
  background:
    linear-gradient(rgba(37, 99, 235, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(37, 99, 235, 0.06) 1px, transparent 1px),
    linear-gradient(115deg, transparent 0 44%, rgba(14, 165, 233, 0.11) 44% 44.25%, transparent 44.25% 100%);
  background-size: 44px 44px, 44px 44px, 100% 100%;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.58), transparent 86%);
}

body::after {
  background:
    radial-gradient(circle at 28% 24%, rgba(255, 255, 255, 0.65), transparent 18rem),
    radial-gradient(circle at 74% 4%, rgba(37, 99, 235, 0.07), transparent 22rem);
}

.admin-login-screen {
  min-height: 100vh;
  padding: 32px;
  display: none;
  align-items: center;
  justify-content: center;
}

.admin-login-locked .admin-login-screen {
  display: flex;
}

.admin-login-locked .admin-shell {
  display: none;
}

.admin-login-ready .admin-login-screen {
  display: none;
}

.admin-login-card {
  width: min(440px, calc(100vw - 36px));
  padding: 28px;
  border-radius: 28px;
  display: grid;
  gap: 24px;
  position: relative;
  overflow: hidden;
}

.admin-login-card::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  background:
    linear-gradient(115deg, rgba(37, 99, 235, 0.12), transparent 34%),
    radial-gradient(circle at 86% 10%, rgba(14, 165, 233, 0.18), transparent 15rem);
}

.admin-login-card > * {
  position: relative;
  z-index: 1;
}

.admin-login-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.admin-login-brand > span {
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 28px;
  font-weight: 950;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
  box-shadow: 0 14px 28px rgba(37, 99, 235, 0.22);
}

.admin-login-brand b {
  display: block;
  color: #102033;
  font-size: 20px;
  font-weight: 950;
}

.admin-login-brand small {
  color: #7d8ea6;
  font-size: 13px;
  font-weight: 800;
}

.admin-login-title {
  display: grid;
  gap: 10px;
}

.admin-login-title h1 {
  color: #102033;
  font-size: 42px;
  line-height: 1;
  letter-spacing: 0;
}

.admin-login-title p {
  color: #66788f;
  font-size: 15px;
  line-height: 1.6;
}

.admin-login-form {
  display: grid;
  gap: 14px;
}

.admin-login-form label {
  display: grid;
  gap: 8px;
}

.admin-login-form label span {
  color: #334b66;
  font-size: 13px;
  font-weight: 900;
}

.admin-login-form input {
  width: 100%;
  min-height: 48px;
  border: 1px solid rgba(37, 99, 235, 0.13);
  border-radius: 16px;
  padding: 0 15px;
  color: #102033;
  outline: none;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 10px 24px rgba(47, 83, 117, 0.06);
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.admin-login-form input:focus {
  border-color: rgba(37, 99, 235, 0.5);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.09), 0 12px 28px rgba(37, 99, 235, 0.1);
}

.admin-login-message {
  min-height: 20px;
  color: #e11d48;
  font-size: 13px;
  font-weight: 850;
}

.admin-login-submit {
  width: 100%;
  min-height: 48px;
  margin-top: 2px;
  font-size: 15px;
}

button,
input,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.admin-shell {
  width: min(1480px, calc(100% - 32px));
  margin: 24px auto;
  display: grid;
  gap: 18px;
}

.glass-panel,
.category-manager,
.editor-panel,
.list-card,
.search-field,
.front-search,
.front-card,
.drop-zone,
.glass-modal {
  border: 1px solid rgba(255, 255, 255, 0.66);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.58), rgba(255, 255, 255, 0.32)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.06), rgba(255, 255, 255, 0.08) 48%, rgba(14, 165, 233, 0.06));
  box-shadow: 0 18px 50px var(--shadow), inset 0 1px 0 rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(28px) saturate(1.24);
  -webkit-backdrop-filter: blur(28px) saturate(1.24);
}

.admin-head {
  min-height: 132px;
  padding: 26px;
  border-radius: 24px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.status-line {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #0f766e;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

.status-line i {
  width: 9px;
  height: 9px;
  border-radius: 99px;
  background: linear-gradient(135deg, var(--blue), var(--sky));
  box-shadow: 0 0 18px rgba(37, 99, 235, 0.55);
}

h1,
p {
  margin: 0;
}

.title-block h1 {
  margin-top: 8px;
  font-size: clamp(30px, 4vw, 54px);
  line-height: 1.02;
  color: #102033;
  letter-spacing: 0;
}

.title-block p {
  margin-top: 12px;
  color: var(--muted);
}

.admin-actions,
.toolbar,
.form-row,
.panel-title,
.modal-head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.admin-actions {
  justify-content: flex-end;
}

.workspace {
  min-height: 720px;
  border-radius: 24px;
  padding: 18px;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 18px;
}

.side-rail,
.main-area {
  min-width: 0;
}

.side-rail {
  display: grid;
  align-content: start;
  gap: 16px;
}

.side-section {
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.54);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.34);
}

.side-title,
.category-manager summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  color: var(--soft);
  font-weight: 800;
}

.side-title b,
.count-badge,
.panel-title span {
  min-width: 28px;
  padding: 4px 9px;
  border-radius: 99px;
  color: #1554d1;
  font-size: 12px;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(37, 99, 235, 0.15);
}

.filter-list,
.sortable-list,
.section-list {
  display: grid;
  gap: 10px;
}

.filter-list {
  margin-top: 12px;
}

.filter-list .sub-filter {
  grid-template-columns: minmax(72px, 1fr) 52px;
  gap: 8px;
}

.filter-list .sub-filter span {
  grid-column: 1;
  min-width: 0;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  writing-mode: horizontal-tb;
}

.filter-list .sub-filter b {
  grid-column: 2;
  width: 52px;
  min-width: 52px;
  justify-self: end;
  text-align: right;
}

.filter-btn,
.ghost-action,
.primary-action,
.card-actions button,
.select-toggle,
.input-clear {
  min-height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: #1554d1;
  background: rgba(255, 255, 255, 0.66);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82), 0 8px 20px rgba(37, 99, 235, 0.08);
  transition: transform 160ms ease, background 160ms ease, color 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.filter-btn {
  width: 100%;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  text-align: left;
}

.sub-filter-divider,
.front-filter-divider,
.category-tree-divider {
  margin: 10px 12px 6px;
  min-height: 24px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: #8390a3;
  font-size: 12px;
  font-weight: 900;
}

.sub-filter-divider::before,
.sub-filter-divider::after,
.front-filter-divider::before,
.front-filter-divider::after,
.category-tree-divider::before,
.category-tree-divider::after {
  content: "";
  height: 1px;
  flex: 1 1 auto;
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.08), rgba(37, 99, 235, 0.28));
}

.sub-filter-divider::before,
.front-filter-divider::before,
.category-tree-divider::before {
  max-width: 18px;
}

.sub-filter-divider::after,
.front-filter-divider::after,
.category-tree-divider::after {
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.28), rgba(14, 165, 233, 0.06));
}

.sub-filter-divider.is-line-only,
.front-filter-divider.is-line-only {
  min-height: 10px;
  margin: 1px 14px 2px;
  padding: 0;
  gap: 0;
  font-size: 0;
  line-height: 0;
}

.sub-filter-divider.is-line-only::before,
.front-filter-divider.is-line-only::before {
  display: none;
}

.sub-filter-divider.is-line-only::after,
.front-filter-divider.is-line-only::after {
  height: 1px;
  flex: 1 1 auto;
  background: #e4ebf5;
}

.sub-filter-region {
  min-height: 38px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--soft);
  font-weight: 900;
}

.sub-filter-region b {
  min-width: 28px;
  color: #8491a5;
  font-size: 13px;
  text-align: right;
}

.filter-btn:hover,
.filter-btn.is-active,
.ghost-action:hover,
.primary-action:hover,
.card-actions button:hover,
.select-toggle:hover {
  color: #fff;
  border-color: rgba(37, 99, 235, 0.72);
  background: linear-gradient(135deg, var(--blue), var(--sky));
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.22), inset 0 1px 0 rgba(255, 255, 255, 0.34);
  transform: translateY(-1px);
}

.ghost-action,
.primary-action {
  min-height: 40px;
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 800;
}

.primary-action {
  color: #fff;
  border-color: rgba(37, 99, 235, 0.68);
  background: linear-gradient(135deg, var(--blue), var(--sky));
}

.icon-only {
  width: 42px;
  padding: 0;
}

.ghost-action svg,
.primary-action svg {
  width: 17px;
  height: 17px;
}

.category-manager {
  padding: 14px;
  border-radius: 20px;
}

.category-manager summary {
  list-style: none;
  cursor: pointer;
}

.category-manager summary::-webkit-details-marker {
  display: none;
}

.category-manager small {
  color: var(--muted);
}

.category-form {
  margin: 12px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 8px;
}

.category-create-form {
  grid-template-columns: minmax(120px, 0.62fr) minmax(160px, 0.8fr) minmax(160px, 0.8fr) minmax(220px, 1fr) 42px;
  align-items: center;
}

.category-create-form [hidden] {
  display: none;
}

.category-create-hint {
  margin: -4px 0 10px;
  padding: 8px 10px;
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 14px;
  color: #57708d;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.5;
  background: rgba(255, 255, 255, 0.36);
}

.category-list-title {
  margin: 12px 0 8px;
  color: #294665;
  font-size: 12px;
  font-weight: 900;
}

dialog.category-settings-dialog {
  width: min(1220px, calc(100vw - 40px));
  max-height: min(840px, calc(100vh - 48px));
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 251, 255, 0.94));
}

.category-settings-dialog > .modal-head {
  margin: 0;
  padding: 22px 28px 14px;
}

dialog.site-settings-dialog {
  width: min(560px, calc(100vw - 40px));
}

.category-settings-body {
  display: grid;
  gap: 10px;
  max-height: calc(100vh - 150px);
  overflow: auto;
  padding-right: 4px;
}

.category-settings-grid {
  display: grid;
  grid-template-columns: minmax(300px, 0.78fr) minmax(0, 1.22fr);
  gap: 14px;
  align-items: start;
}

.category-settings-grid .sortable-list {
  display: grid;
  gap: 8px;
}

.category-manager-shell {
  display: grid;
  grid-template-columns: minmax(420px, 0.92fr) minmax(520px, 1.08fr);
  gap: 16px;
  padding: 0 18px 18px;
  min-height: 620px;
}

.category-list-panel,
.category-editor-panel {
  min-width: 0;
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 16px 40px rgba(47, 83, 117, 0.08);
  overflow: hidden;
}

.category-panel-head,
.category-editor-head {
  min-height: 62px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(37, 99, 235, 0.09);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.category-panel-head > div {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #102033;
}

.category-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

.category-panel-head strong,
.category-editor-head strong {
  color: #102033;
  font-size: 17px;
  font-weight: 900;
}

.category-panel-head span svg {
  width: 16px;
  height: 16px;
  color: #7b8da6;
}

.category-add-btn {
  min-height: 40px;
  padding: 0 14px;
}

.category-tree {
  height: 508px;
  padding: 12px 14px;
  overflow: auto;
}

.category-tree-row {
  display: grid;
  grid-template-columns: 22px 22px 34px minmax(0, 1fr) 34px 30px 30px;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  margin-bottom: 4px;
  padding: 4px 8px;
  border: 1px solid transparent;
  border-radius: 10px;
  color: #425a78;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.category-tree-row.level-2 {
  margin-left: 28px;
}

.category-tree-row.level-3 {
  margin-left: 58px;
}

.category-tree-row.is-selected {
  color: #1554d1;
  border-color: rgba(37, 99, 235, 0.14);
  background: rgba(37, 99, 235, 0.08);
}

.category-tree-row.is-hidden {
  opacity: 0.55;
}

.category-tree-row.is-dragging {
  opacity: 0.72;
  box-shadow: 0 14px 30px rgba(37, 99, 235, 0.13);
}

.category-tree-row.is-divider-row {
  position: relative;
  min-height: 28px;
  border-color: transparent;
  background: transparent;
}

.category-tree-row.is-divider-row .tree-name {
  overflow: visible;
  color: #6e7f96;
  font-size: 13px;
  font-weight: 900;
}

.category-tree-row.is-divider-row .tree-name::after {
  content: "";
  height: 1px;
  min-width: 56px;
  flex: 1 1 auto;
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.34), rgba(14, 165, 233, 0.05));
}

.category-tree-row.is-divider-row .tree-icon {
  color: #0ea5e9;
  background: rgba(14, 165, 233, 0.08);
}

.category-tree-row.is-divider-row .tree-badge {
  color: #7b8da6;
  background: rgba(226, 232, 240, 0.68);
}

.tree-drag,
.tree-toggle,
.tree-name,
.tree-action {
  min-height: 30px;
  border: 0;
  background: transparent;
  color: currentColor;
  box-shadow: none;
}

.tree-drag,
.tree-toggle,
.tree-action {
  width: 30px;
  padding: 0;
  display: grid;
  place-items: center;
  border-radius: 8px;
}

.tree-action:hover,
.tree-toggle:hover {
  background: rgba(37, 99, 235, 0.08);
}

.tree-toggle.is-empty {
  opacity: 0.22;
  pointer-events: none;
}

.tree-drag {
  cursor: grab;
  color: #8da0b7;
}

.tree-name {
  min-width: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: flex-start;
  text-align: left;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-weight: 850;
}

.tree-name-kicker {
  flex: 0 0 auto;
  padding: 2px 7px;
  border-radius: 999px;
  color: #1554d1;
  font-size: 11px;
  font-weight: 900;
  background: rgba(37, 99, 235, 0.1);
}

.tree-icon {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.07);
}

.tree-icon img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.tree-icon svg,
.editor-icon-preview svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tree-badge {
  min-width: 26px;
  padding: 4px 8px;
  border-radius: 8px;
  text-align: center;
  color: #71839c;
  font-size: 12px;
  font-weight: 850;
  background: #f1f5f9;
}

.category-tree-footer {
  min-height: 58px;
  margin: 0;
  padding: 10px 14px;
  border-top: 1px solid rgba(37, 99, 235, 0.09);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(255, 255, 255, 0.72);
}

.category-tree-tip {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #7b8da6;
  font-size: 13px;
  font-weight: 750;
}

.category-save-order-btn {
  flex: 0 0 auto;
  min-height: 36px;
  padding: 0 14px;
}

.category-editor-form {
  height: 100%;
  max-height: calc(100vh - 168px);
  padding: 0 24px;
  display: grid;
  gap: 16px;
  overflow: auto;
}

.category-editor-head {
  margin: 0 -24px;
  padding-inline: 24px;
}

.category-editor-head span {
  padding: 4px 10px;
  border-radius: 999px;
  color: #1554d1;
  font-size: 12px;
  font-weight: 850;
  background: rgba(37, 99, 235, 0.08);
}

.category-editor-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.category-editor-head-actions .ghost-action {
  min-height: 30px;
  padding: 0 11px;
}

.category-editor-info {
  min-height: 42px;
  padding: 10px 12px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.06);
  border: 1px solid rgba(37, 99, 235, 0.12);
  font-size: 13px;
  font-weight: 800;
}

.category-editor-form label,
.icon-uploader {
  display: grid;
  gap: 8px;
}

.category-editor-form label > span,
.icon-uploader > span {
  color: #102033;
  font-size: 13px;
  font-weight: 900;
}

.category-editor-form label b {
  color: #e11d48;
}

.parent-category-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.icon-uploader-row {
  display: grid;
  grid-template-columns: 72px auto minmax(0, 1fr);
  align-items: center;
  gap: 14px;
}

.editor-icon-preview {
  width: 72px;
  height: 72px;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: #f8fbff;
  overflow: hidden;
}

.editor-icon-preview img {
  width: 46px;
  height: 46px;
  object-fit: contain;
}

.editor-icon-preview svg {
  width: 34px;
  height: 34px;
}

.icon-uploader-row small {
  color: #8da0b7;
  font-size: 12px;
  font-weight: 750;
}

.status-switch {
  grid-template-columns: auto 0 42px auto;
  align-items: center;
  gap: 10px;
}

.status-switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.status-switch i {
  width: 42px;
  height: 24px;
  border-radius: 999px;
  position: relative;
  background: #dbe5f0;
  transition: background 160ms ease;
}

.status-switch i::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  content: "";
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 2px 8px rgba(47, 83, 117, 0.22);
  transition: transform 160ms ease;
}

.status-switch input:checked + i {
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
}

.status-switch input:checked + i::after {
  transform: translateX(18px);
}

.status-switch em {
  color: #5f728c;
  font-style: normal;
  font-weight: 800;
}

.category-editor-actions {
  position: sticky;
  bottom: 0;
  z-index: 3;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin: 8px -24px 0;
  padding: 14px 24px;
  border-top: 1px solid rgba(37, 99, 235, 0.09);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(247, 251, 255, 0.98));
  box-shadow: 0 -12px 24px rgba(47, 83, 117, 0.06);
}

.category-settings-dialog .category-editor-form {
  margin: 0;
  padding: 0 24px;
}

.category-settings-dialog .category-editor-form .category-editor-head {
  margin: 0 -24px;
  padding: 14px 24px;
}

.category-settings-dialog select:disabled {
  color: #73849b;
  background: #f4f7fb;
  box-shadow: none;
  cursor: not-allowed;
}

.site-form {
  margin-top: 12px;
  display: grid;
  gap: 10px;
}

.site-modal-form {
  margin-top: 0;
}

.site-form label {
  display: grid;
  gap: 6px;
}

.site-form span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.site-form .primary-action {
  justify-content: center;
}

.category-pill {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 34px;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(255, 255, 255, 0.46);
  box-shadow: 0 10px 24px rgba(47, 83, 117, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.child-category-pill {
  grid-template-columns: 34px 44px minmax(0, 1fr) 34px;
}

.child-category-pill.is-third-level {
  margin-left: 18px;
  border-color: rgba(37, 99, 235, 0.18);
  background: rgba(255, 255, 255, 0.38);
}

.category-level-badge {
  min-height: 30px;
  padding: 0 8px;
  border-radius: 999px;
  display: inline-grid;
  place-items: center;
  color: #1554d1;
  font-size: 11px;
  font-weight: 900;
  background: rgba(37, 99, 235, 0.08);
  border: 1px solid rgba(37, 99, 235, 0.12);
}

.child-category-pill .category-major-select {
  grid-column: 3;
}

.child-category-pill .delete-category {
  grid-column: 4;
  grid-row: 1;
}

.child-category-pill .category-parent-select {
  grid-column: 1 / 3;
  grid-row: 2;
}

.child-category-pill .category-name-input {
  grid-column: 3 / -1;
  grid-row: 2;
}

.child-category-pill .category-icon-preview {
  grid-column: 1;
  grid-row: 3;
}

.child-category-pill .category-icon-upload {
  grid-column: 2 / 4;
  grid-row: 3;
  min-width: 0;
  padding: 0 10px;
}

.major-pill {
  grid-template-columns: 34px minmax(0, 1fr) minmax(118px, 0.7fr) 38px 70px 34px;
}

.category-settings-dialog .major-pill {
  grid-template-columns: 34px minmax(0, 1fr) 38px 70px 34px;
}

.category-icon-preview {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #5e6e84;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(37, 99, 235, 0.14);
  overflow: hidden;
}

.category-icon-preview img {
  width: 22px;
  height: 22px;
  object-fit: contain;
}

.category-icon-upload {
  min-height: 38px;
  padding: 0 10px;
  justify-content: center;
  font-size: 12px;
}

.category-pill.is-dragging {
  opacity: 0.72;
  transform: scale(1.025);
  border-color: rgba(37, 99, 235, 0.42);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.08), 0 18px 40px rgba(37, 99, 235, 0.16);
}

.drag-handle {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 12px;
  color: #1554d1;
  background: rgba(255, 255, 255, 0.62);
}

.delete-category,
.danger-btn {
  border-color: rgba(225, 29, 72, 0.44) !important;
  color: var(--danger) !important;
}

.delete-category:hover,
.danger-btn:hover {
  color: #fff !important;
  background: linear-gradient(135deg, rgba(225, 29, 72, 0.92), rgba(244, 63, 94, 0.86)) !important;
}

.main-area {
  display: grid;
  align-content: start;
  gap: 16px;
}

.toolbar {
  align-items: stretch;
  justify-content: flex-end;
}

.search-field {
  flex: 1 1 320px;
  min-height: 66px;
  padding: 10px 14px;
  border-radius: 18px;
  display: grid;
  gap: 4px;
}

.search-field span,
.admin-form span,
.form-field > span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

input,
textarea,
select {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 16px;
  outline: none;
  color: var(--text);
  background: rgba(255, 255, 255, 0.54);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.76), 0 8px 20px rgba(58, 98, 138, 0.08);
  backdrop-filter: blur(14px) saturate(1.14);
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input,
select {
  min-height: 42px;
  padding: 0 14px;
}

select {
  cursor: pointer;
  appearance: auto;
}

textarea {
  min-height: 92px;
  padding: 12px 14px;
  resize: vertical;
}

input:focus,
textarea:focus,
select:focus,
.select-toggle:focus-visible {
  border-color: rgba(37, 99, 235, 0.5);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1), 0 0 24px rgba(14, 165, 233, 0.12);
}

input::placeholder,
textarea::placeholder {
  color: rgba(83, 104, 128, 0.62);
}

.clear-wrap {
  position: relative;
  display: block;
  min-width: 0;
}

.clear-wrap input,
.clear-wrap textarea {
  padding-right: 44px;
}

.input-clear {
  position: absolute;
  right: 8px;
  top: 50%;
  z-index: 2;
  width: 26px;
  min-height: 26px;
  height: 26px;
  padding: 0;
  display: none;
  align-items: center;
  justify-content: center;
  transform: translateY(-50%);
  border-color: rgba(37, 99, 235, 0.2);
  font-size: 16px;
  line-height: 1;
}

.category-pill .clear-wrap {
  width: 100%;
}

.clear-wrap.has-value .input-clear {
  display: flex;
}

.clear-wrap textarea + .input-clear {
  top: 22px;
}

.editor-panel,
.list-card {
  padding: 16px;
  border-radius: var(--radius);
}

.panel-title {
  justify-content: space-between;
  margin-bottom: 14px;
}

.list-panel-title {
  display: grid;
  grid-template-columns: auto minmax(260px, 1fr) auto;
  align-items: center;
  gap: 14px;
}

.list-panel-title:not(:has(.search-field)) {
  display: flex;
}

.list-search-field {
  min-height: 52px;
  padding: 7px 12px;
}

.panel-title strong {
  color: #102033;
  font-size: 18px;
}

.admin-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.admin-form label,
.form-field {
  position: relative;
  min-width: 0;
  display: grid;
  gap: 7px;
}

.admin-form .wide {
  grid-column: 1 / -1;
}

.image-editor-field .clear-wrap {
  width: 100%;
}

.upload-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}

.upload-preview {
  width: min(240px, 100%);
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 18px;
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  background: rgba(255, 255, 255, 0.46);
  box-shadow: 0 12px 28px rgba(47, 83, 117, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.upload-preview[hidden] {
  display: none;
}

.upload-preview img {
  width: 70px;
  height: 70px;
  border-radius: 14px;
  object-fit: cover;
  box-shadow: 0 8px 16px rgba(37, 99, 235, 0.12);
}

.upload-preview span {
  color: #1554d1;
  font-size: 13px;
  font-weight: 900;
}

.toggle-field {
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(255, 255, 255, 0.58);
  border-radius: 999px;
  grid-template-columns: auto 1fr;
  align-items: center;
  background: rgba(255, 255, 255, 0.4);
}

.toggle-field input {
  width: 18px;
  min-height: 18px;
}

.select-toggle {
  width: 100%;
  min-height: 42px;
  padding: 0 14px;
  text-align: left;
}

.select-panel {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(100% + 8px);
  z-index: 5;
  display: grid;
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(247, 251, 255, 0.88)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(14, 165, 233, 0.04));
  box-shadow: 0 18px 44px rgba(47, 83, 117, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(24px) saturate(1.16);
}

.choice {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--soft);
  font-size: 13px;
}

.choice input {
  width: 16px;
  min-height: 16px;
}

.progress-track {
  --progress: 0%;
  min-width: 180px;
  height: 36px;
  padding: 5px;
  border-radius: 999px;
  display: inline-grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 8px;
  color: #1554d1;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.68);
}

.progress-track[hidden] {
  display: none;
}

.progress-track i {
  position: relative;
  height: 10px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(37, 99, 235, 0.09);
}

.progress-track i::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: var(--progress);
  content: "";
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--sky));
  box-shadow: 0 0 16px rgba(37, 99, 235, 0.24);
}

.progress-track em {
  min-width: 42px;
  color: #1554d1;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}

.category-section {
  display: grid;
  gap: 10px;
}

.category-section + .category-section {
  padding-top: 18px;
  border-top: 1px solid rgba(37, 99, 235, 0.12);
}

.section-head {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #102033;
  font-weight: 900;
}

.section-head::after {
  flex: 1;
  height: 1px;
  content: "";
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.28), transparent);
}

.item-grid {
  display: grid;
  gap: 10px;
}

.software-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  min-height: 96px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.08), rgba(255, 255, 255, 0.08) 48%, rgba(14, 165, 233, 0.08));
  box-shadow: 0 14px 38px rgba(47, 83, 117, 0.09), inset 0 1px 0 rgba(255, 255, 255, 0.78);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.software-row:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.25);
  box-shadow: 0 22px 58px rgba(37, 99, 235, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

.app-icon {
  position: relative;
  width: 58px;
  height: 58px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 22px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--blue), var(--sky));
  box-shadow: 0 10px 24px rgba(47, 83, 117, 0.12);
  transition: transform 180ms ease;
}

.software-row:hover .app-icon {
  transform: scale(1.05);
}

.icon-zoom {
  position: absolute;
  left: 64px;
  top: -18px;
  z-index: 6;
  width: 112px;
  height: 112px;
  border-radius: 26px;
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px) scale(0.94);
  color: #fff;
  background: inherit;
  box-shadow: 0 26px 70px rgba(39, 75, 112, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(24px) saturate(1.2);
  transition: opacity 140ms ease, transform 140ms ease, visibility 140ms ease;
}

.app-icon:hover .icon-zoom {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.card-main {
  min-width: 0;
}

.card-main strong {
  display: block;
  color: #102033;
  font-size: 17px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-main p {
  margin-top: 5px;
  color: var(--muted);
  line-height: 1.55;
}

.meta-row {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.tag {
  padding: 4px 9px;
  border-radius: 999px;
  color: #31506f;
  font-size: 12px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(37, 99, 235, 0.12);
}

.card-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}

.card-actions button {
  min-width: 70px;
  padding: 0 13px;
  font-weight: 800;
}

.glass-modal {
  width: min(640px, calc(100vw - 32px));
  padding: 0;
  border-radius: 24px;
  color: var(--text);
}

.glass-modal::backdrop {
  background: rgba(211, 229, 246, 0.46);
  backdrop-filter: blur(8px);
}

.glass-modal form {
  margin: 0;
  padding: 18px;
}

.modal-head {
  justify-content: space-between;
  margin-bottom: 16px;
}

.modal-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.drop-zone {
  min-height: 210px;
  padding: 28px;
  border-radius: 22px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
  border-style: dashed;
}

.drop-zone input {
  display: none;
}

.drop-zone svg {
  width: 42px;
  height: 42px;
  color: var(--blue);
}

.drop-zone strong {
  color: #102033;
  font-size: 20px;
}

.drop-zone.is-dragging {
  border-color: rgba(37, 99, 235, 0.55);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.76), rgba(255, 255, 255, 0.48)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(14, 165, 233, 0.08));
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.08), 0 18px 50px rgba(37, 99, 235, 0.16);
}

.front-shell {
  width: min(1480px, calc(100% - 32px));
  min-height: calc(100vh - 48px);
  margin: 24px auto;
  display: grid;
  grid-template-columns: 290px minmax(0, 1fr);
  gap: 18px;
}

.front-sidebar,
.front-main {
  border-radius: 24px;
}

.front-sidebar {
  position: sticky;
  top: 24px;
  height: calc(100vh - 48px);
  min-width: 0;
  min-height: 680px;
  padding: 20px;
  align-self: start;
  display: grid;
  align-content: start;
  gap: 18px;
  overflow-x: hidden;
}

.brand {
  min-height: 76px;
  padding: 0 0 22px;
  border-radius: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #e4ebf5;
}

.brand > span:last-child {
  display: grid;
  align-content: center;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 26px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--blue), var(--sky));
  box-shadow: none;
}

.brand-mark.has-logo {
  overflow: hidden;
  padding: 3px;
  background: rgba(255, 255, 255, 0.62);
}

.brand-mark.has-logo img {
  width: 100%;
  height: 100%;
  border-radius: 13px;
  object-fit: cover;
}

.brand strong {
  display: block;
  color: #102033;
  font-size: 21px;
  line-height: 1.12;
}

.brand small {
  display: block;
  margin-top: 4px;
  color: #8a96a8;
  font-size: 14px;
  font-weight: 700;
}

.front-side-section {
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  gap: 0;
  min-height: 0;
}

.factory-sidebar .side-title {
  margin-top: 0;
  min-height: 34px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) 42px;
  align-items: center;
  gap: 8px;
  color: #34445c;
  font-size: 17px;
  font-weight: 700;
}

.factory-sidebar .side-title .side-title-icon {
  grid-column: 1;
}

.factory-sidebar .side-title #frontNavTitle {
  grid-column: 2;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.factory-sidebar .side-title b {
  grid-column: 3;
  justify-self: end;
  min-width: 0;
  padding: 0;
  border: 0;
  color: #a0aabc;
  font-size: 13px;
  font-weight: 600;
  text-align: right;
  background: transparent;
}

.sidebar-footer-link {
  margin-top: auto;
  padding: 20px 16px 0;
  border-top: 1px solid #e4ebf5;
  min-height: 70px;
  display: flex;
  align-items: center;
  gap: 13px;
  color: #3f4f66;
  font-size: 16px;
  font-weight: 650;
  text-decoration: none;
  transition: color 180ms ease, background 180ms ease;
}

.sidebar-footer-link:hover {
  color: #1677ff;
  background: transparent;
}

.sub-filter .sidebar-item-icon {
  color: #5e6e84;
}

.sub-filter:hover .sidebar-item-icon,
.sub-filter.is-active .sidebar-item-icon {
  color: #1677ff;
}

.front-search {
  min-height: 52px;
  padding: 6px 10px 6px 14px;
  border-radius: 18px;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}

.front-search svg {
  width: 18px;
  height: 18px;
  color: #1554d1;
}

.front-search input {
  min-height: 38px;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.front-search .clear-wrap {
  min-width: 0;
}

.front-search-sticky {
  position: sticky;
  top: 0;
  z-index: 60;
  overflow: hidden;
  isolation: isolate;
  padding: 14px 12px 12px;
  margin: -14px -12px 4px;
  border-radius: 20px;
  border-bottom: 1px solid rgba(37, 99, 235, 0.1);
  background: #f3f8ff;
  box-shadow: 0 12px 24px rgba(47, 83, 117, 0.06);
  backdrop-filter: blur(18px) saturate(1.14);
}

.front-search-main {
  width: min(860px, 82%);
  min-height: 58px;
  margin: 0;
  padding: 8px 12px 8px 18px;
  border-color: rgba(37, 99, 235, 0.38);
  border-radius: 999px;
  grid-template-columns: 24px minmax(0, 1fr);
  box-shadow:
    0 9px 17px rgba(37, 99, 235, 0.08),
    0 4px 8px rgba(15, 23, 42, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.front-search-main:focus-within {
  border-color: rgba(37, 99, 235, 0.68);
  box-shadow:
    0 0 0 3px rgba(37, 99, 235, 0.1),
    0 10px 19px rgba(37, 99, 235, 0.09),
    0 4px 9px rgba(15, 23, 42, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.front-search-main svg {
  width: 20px;
  height: 20px;
}

.front-search-main input {
  min-height: 42px;
  font-size: 17px;
  font-weight: 800;
}

.front-search-main input::placeholder {
  font-weight: 500;
}

.front-discovery {
  width: min(980px, 92%);
  margin-top: 10px;
  display: grid;
  gap: 8px;
}

.discovery-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
}

.discovery-row strong {
  color: #31506f;
  font-size: 13px;
  white-space: nowrap;
}

.discovery-list {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  overflow-x: auto;
  scrollbar-width: none;
}

.discovery-list::-webkit-scrollbar {
  display: none;
}

.discovery-chip {
  min-height: 30px;
  padding: 5px 10px;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  color: #31506f;
  font-size: 12px;
  font-weight: 900;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78), 0 7px 16px rgba(47, 83, 117, 0.06);
  cursor: pointer;
}

.discovery-chip:hover {
  color: #fff;
  border-color: rgba(37, 99, 235, 0.42);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.9), rgba(14, 165, 233, 0.82));
}

.hot-chip i {
  min-width: 17px;
  height: 17px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 10px;
  font-style: normal;
  background: linear-gradient(135deg, #2563eb, #0ea5e9);
}

.hot-chip b {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: 999px;
  color: #1554d1;
  background: rgba(37, 99, 235, 0.1);
}

.hot-chip:hover b {
  color: #fff;
  background: rgba(255, 255, 255, 0.22);
}

.new-chip::before {
  content: "新";
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 11px;
  background: linear-gradient(135deg, #0ea5e9, #22c55e);
}

.front-filters {
  display: grid;
  gap: 3px;
  min-height: 0;
  min-width: 0;
  align-content: start;
  overflow-x: hidden;
  overflow-y: auto;
  overflow-anchor: none;
  padding-right: 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(96, 112, 137, 0.24) transparent;
}

.front-filters:hover {
  scrollbar-color: rgba(96, 112, 137, 0.24) transparent;
}

.front-filters::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

.front-filters::-webkit-scrollbar-track {
  background: transparent;
}

.front-filters::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(96, 112, 137, 0);
  transition: background-color 220ms ease;
}

.front-filters:hover::-webkit-scrollbar-thumb {
  background: rgba(96, 112, 137, 0.24);
}

.front-filters:hover::-webkit-scrollbar-thumb:hover {
  background: rgba(96, 112, 137, 0.34);
}


.factory-tree {
  display: grid;
  gap: 3px;
  min-width: 0;
  align-content: start;
}

.sub-filter-list {
  margin-left: 0;
  padding-left: 0;
  border-left: 0;
  display: grid;
  gap: 3px;
  min-width: 0;
  align-content: start;
}

.sub-filter-list.is-flat {
  margin-left: 0;
  padding-left: 0;
  border-left: 0;
  gap: 3px;
}

.sub-filter {
  position: relative;
  width: 100%;
  min-width: 0;
  height: 50px;
  min-height: 50px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: 12px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) 42px;
  align-items: center;
  gap: 10px;
  color: #3f4f66;
  font-size: 16px;
  font-weight: 650;
  text-align: left;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease, border-color 180ms ease;
}

.sub-filter.is-major {
  margin-top: 0;
  color: #3f4f66;
  font-size: 16px;
  background: transparent;
  border-color: transparent;
}

.sub-filter.is-level2 {
  height: 50px;
  min-height: 50px;
  padding: 0 14px;
  color: #3f4f66;
  font-size: 16px;
  background: transparent;
  box-shadow: none;
}

.sub-filter.is-recommend {
  padding: 0 14px;
  gap: 10px;
}

.sub-filter.is-recommend .sidebar-item-label {
  flex: 0 1 auto;
}

.sub-filter.has-children .sidebar-item-label::after {
  content: "\203A";
  display: inline-block;
  margin-left: 6px;
  color: #9aa8bb;
  font-size: 16px;
  transform: translateY(-1px);
  transition: transform 160ms ease, color 160ms ease;
}

.sub-filter.has-children.is-expanded .sidebar-item-label::after {
  color: #1677ff;
  transform: translateY(-1px) rotate(90deg);
}

.sub-filter.is-child {
  margin-left: 0;
  height: 50px;
  min-height: 50px;
  font-size: 16px;
}

.sub-filter.is-level3 {
  margin-left: 0;
  height: 50px;
  min-height: 50px;
  font-size: 16px;
}

.sub-filter.is-group-start {
  margin-top: 9px;
}

.sub-filter.is-group-start::after {
  content: "";
  position: absolute;
  top: -5px;
  left: 14px;
  right: 14px;
  height: 1px;
  background: #e4ebf5;
}

.front-filter-divider {
  margin: 12px 14px 8px;
  padding: 0;
  border-top: 0;
  color: #708199;
  letter-spacing: 0;
}

.front-region-title {
  min-width: 0;
  min-height: 34px;
  margin-top: 10px;
  padding: 9px 0 0;
  border-top: 1px solid rgba(215, 226, 240, 0.65);
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) 42px;
  align-items: center;
  gap: 8px;
  color: #34445c;
  font-size: 17px;
  font-weight: 700;
}

.sub-filter-list > .front-region-title:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

.front-region-title .sidebar-item-icon {
  grid-column: 1;
  width: 24px;
  height: 24px;
  margin-left: -1px;
  flex-basis: 24px;
  color: #263b57;
}

.front-region-title .sidebar-item-icon svg {
  width: 24px;
  height: 24px;
}

.front-region-title b {
  grid-column: 3;
  justify-self: end;
  min-width: 0;
  margin-left: 0;
  color: #a0aabc;
  font-size: 13px;
  font-weight: 600;
  text-align: right;
}

.sub-filter:hover,
.sub-filter.is-active {
  color: #1677ff;
  border-color: transparent;
  background: #f5f9ff;
  transform: none;
}

.sub-filter.is-active {
  border-color: #dcebff;
  background: #f2f8ff;
}

.sub-filter.is-active::before {
  content: "";
  position: absolute;
  left: -1px;
  top: 10px;
  bottom: 10px;
  width: 3px;
  border-radius: 4px;
  background: #1677ff;
}

.sub-filter b {
  grid-column: 3;
  justify-self: end;
  flex: 0 0 auto;
  min-width: 0;
  margin-left: 0;
  padding: 0;
  border-radius: 0;
  color: #8491a5;
  font-size: 15px;
  font-weight: 650;
  text-align: right;
  background: transparent;
}

.sub-filter.is-active b {
  color: #1677ff;
}

.sub-filter.is-search-empty {
  color: #a8b3c3;
  opacity: .56;
  cursor: default;
}

.sub-filter.is-search-empty .sidebar-item-icon,
.sub-filter.is-search-empty b {
  color: #a8b3c3;
}

.sub-filter.is-search-empty:hover {
  color: #a8b3c3;
  border-color: transparent;
  background: transparent;
}

.front-filters .sub-filter.has-icon {
  grid-template-columns: 22px minmax(0, 1fr) 42px;
}

.front-filters .sub-filter.is-iconless {
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 8px;
}

.sub-filter.is-iconless.is-level2 {
  height: 47px;
  min-height: 47px;
  padding-left: 26px;
}

.sub-filter.is-iconless.is-level3 {
  height: 47px;
  min-height: 47px;
  padding-left: 43px;
}

.side-rail .sub-filter span,
.side-rail .sub-filter-region span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.front-filters .sub-filter.has-icon b {
  grid-column: 3;
}

.front-filters .sub-filter.is-iconless b {
  grid-column: 2;
  width: 42px;
  min-width: 42px;
  justify-self: end;
  text-align: right;
}

.favorites-filter {
  margin-top: 15px;
}

.sidebar-favorites {
  align-self: end;
  flex: 0 0 auto;
}

.favorites-filter::after {
  content: "";
  position: absolute;
  top: -8px;
  left: 14px;
  right: 14px;
  height: 1px;
  background: rgba(215, 226, 240, 0.82);
}

.favorites-filter .sidebar-item-icon svg {
  fill: none;
  transition: fill 180ms ease, transform 180ms ease;
}

.favorites-filter.is-active .sidebar-item-icon svg {
  fill: currentColor;
}

.sidebar-item-icon,
.side-title-icon,
.sidebar-footer-icon {
  grid-column: 1;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  display: inline-grid;
  place-items: center;
  color: currentColor;
}

.sidebar-item-icon svg,
.side-title-icon svg,
.sidebar-footer-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.sidebar-item-icon img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  display: block;
}

.sidebar-item-label {
  grid-column: 2;
  min-width: 0;
  flex: 0 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sub-filter.is-iconless .sidebar-item-label {
  grid-column: 1;
  min-width: 0;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  writing-mode: horizontal-tb;
}

.front-main {
  min-height: 860px;
  padding: 22px;
}

.front-hero {
  min-height: 210px;
  padding: 8px 6px 22px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 1px solid rgba(37, 99, 235, 0.1);
}

.front-hero h1 {
  margin-top: 12px;
  color: #102033;
  font-size: clamp(40px, 6vw, 82px);
  line-height: 0.96;
  letter-spacing: 0;
}

.front-hero p {
  max-width: 620px;
  margin-top: 16px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.7;
}

.featured-strip {
  margin-top: -38px;
  padding-bottom: 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.front-sections,
.front-category-section {
  display: grid;
  gap: 16px;
}

.front-category-section + .front-category-section {
  padding-top: 20px;
  border-top: 1px solid rgba(37, 99, 235, 0.12);
}

.front-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: 12px;
}

.front-card {
  min-height: 260px;
  padding: 16px;
  border-radius: 22px;
  display: grid;
  align-content: space-between;
  gap: 14px;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.front-card:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.28);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.68), rgba(255, 255, 255, 0.38)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.1), rgba(255, 255, 255, 0.08) 48%, rgba(14, 165, 233, 0.08));
  box-shadow: 0 22px 58px rgba(37, 99, 235, 0.14), inset 0 1px 0 rgba(255, 255, 255, 0.86);
}

.front-card.is-featured {
  min-height: 220px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.42)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.14), rgba(14, 165, 233, 0.09));
}

.front-card-top {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.front-card h2 {
  margin: 0;
  color: #102033;
  font-size: 18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.front-card-top p,
.front-summary {
  color: var(--muted);
}

.front-summary {
  line-height: 1.65;
}

.front-card-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.front-card-bottom > span {
  color: #31506f;
  font-size: 13px;
  font-weight: 900;
}

.empty-state {
  margin-top: 24px;
  padding: 24px;
  border-radius: 22px;
  color: var(--muted);
  text-align: center;
  background: rgba(255, 255, 255, 0.44);
  border: 1px solid rgba(255, 255, 255, 0.62);
}

.factory-shell {
  width: min(1720px, calc(100% - 18px));
  min-height: calc(100vh - 48px);
  margin: 24px auto;
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 18px;
}

.factory-sidebar,
.factory-main {
  border-radius: 24px;
}

.factory-sidebar {
  position: sticky;
  top: 24px;
  height: calc(100vh - 48px);
  min-height: 680px;
  padding: 24px;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  align-content: stretch;
  gap: 22px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(221, 231, 245, 0.95);
  box-shadow: 0 16px 40px rgba(64, 96, 140, 0.08);
  backdrop-filter: blur(18px) saturate(1.08);
}

.factory-main {
  min-height: 820px;
  padding: 16px;
}

.factory-hero {
  min-height: 150px;
  padding: 4px 4px 18px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.factory-hero h1 {
  margin-top: 12px;
  color: #102033;
  font-size: clamp(34px, 4vw, 58px);
  line-height: 1;
}

.factory-hero p {
  max-width: 720px;
  margin-top: 12px;
  color: var(--muted);
  line-height: 1.7;
}

.factory-grid {
  margin-top: -7px;
  display: grid;
  gap: 26px;
}

.category-section {
  display: grid;
  gap: 14px;
  scroll-margin-top: 104px;
}

.category-divider {
  display: grid;
  grid-template-columns: auto auto minmax(40px, 1fr);
  align-items: center;
  gap: 10px;
  color: #102033;
}

.category-divider::after {
  content: "";
  height: 1px;
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.34), rgba(14, 165, 233, 0.08));
}

.category-divider h2 {
  font-size: 18px;
  line-height: 1.2;
}

.major-section {
  margin-top: 6px;
  gap: 0;
}
.major-section {
  display: none;
}


.major-section + .category-section {
  padding-top: 0;
  border-top: 0;
}

.major-section .category-divider::after {
  display: none;
}

.major-section .category-divider h2 {
  font-size: 21px;
  color: #0f3f73;
}

.promoted-section .category-divider h2 {
  font-size: 21px;
  color: #0f3f73;
}

.major-section .category-items {
  display: none;
}

.category-divider span {
  min-width: 28px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #1554d1;
  font-size: 12px;
  font-weight: 900;
  text-align: center;
  background: rgba(37, 99, 235, 0.09);
}

.category-items {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.layout-compact .category-items {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 10px;
}

.layout-wide .category-items {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.layout-scroll,
.layout-marquee {
  overflow: hidden;
}

.layout-scroll .category-items,
.layout-marquee .category-items {
  width: max-content;
  display: flex;
  grid-template-columns: none;
  transform: translate3d(0, 0, 0);
  will-change: transform;
  backface-visibility: hidden;
  contain: layout paint;
}

.layout-scroll .category-items {
  width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scroll-behavior: smooth;
  scrollbar-width: none;
}

.category-section.has-horizontal-controls {
  position: relative;
}

.horizontal-page-btn {
  position: absolute;
  z-index: 8;
  top: calc(50% + 20px);
  width: 38px;
  height: 46px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: 999px;
  display: none;
  place-items: center;
  color: #2563eb;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  cursor: pointer;
  transform: translateY(-50%);
  transition: opacity 180ms ease, transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.has-horizontal-controls.has-scrollable-row .horizontal-page-btn {
  display: grid;
  opacity: 0.72;
}

.has-horizontal-controls.has-scrollable-row:hover .horizontal-page-btn {
  opacity: 1;
}

.horizontal-page-btn:hover {
  border-color: rgba(37, 99, 235, 0.38);
  background: rgba(255, 255, 255, 0.96);
  transform: translateY(-50%) scale(1.04);
}

.horizontal-page-btn svg {
  width: 20px;
  height: 20px;
}

.horizontal-page-prev {
  left: 8px;
}

.horizontal-page-next {
  right: 8px;
}

.layout-scroll .category-items::-webkit-scrollbar {
  display: none;
}

.layout-marquee .category-items {
  animation: recommendMarquee 220s linear infinite;
}

.layout-marquee .category-items:hover {
  animation-play-state: paused;
}

.layout-scroll .factory-card,
.layout-marquee .factory-card {
  width: min(284px, calc((100vw - 270px) / 5));
  min-width: 210px;
  flex: 0 0 auto;
}

.layout-scroll .factory-card,
.layout-marquee .factory-card {
  width: calc((100% - var(--scroll-gap-total, 56px)) / var(--scroll-cols, 5));
  min-width: 0;
}

.layout-marquee .factory-card {
  border-color: rgba(255, 255, 255, 0.36);
  background: transparent;
  box-shadow: none;
  transform: translate3d(0, 0, 0);
}

.layout-marquee .factory-image,
.layout-marquee .factory-image-frame {
  box-shadow: none;
}

@keyframes recommendMarquee {
  from {
    transform: translate3d(0, 0, 0);
  }

  to {
    transform: translate3d(calc(-50% - 7px), 0, 0);
  }
}

.factory-card {
  position: relative;
  min-height: 260px;
  padding: 2px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 20px;
  overflow: hidden;
  display: grid;
  grid-template-rows: 1fr auto;
  gap: 8px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.78), rgba(255, 255, 255, 0.58)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.025), rgba(255, 255, 255, 0.08));
  box-shadow: 0 12px 30px rgba(47, 83, 117, 0.075), inset 0 1px 0 rgba(255, 255, 255, 0.9);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.recommend-hot .factory-card::before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  z-index: 3;
  width: 0;
  height: 0;
  border-top: 54px solid rgba(125, 211, 252, 0.9);
  border-right: 54px solid transparent;
  filter: drop-shadow(0 6px 10px rgba(14, 165, 233, 0.14));
}

.recommend-hot .factory-card::after {
  content: "\1F525";
  position: absolute;
  top: 0;
  left: 1px;
  z-index: 4;
  font-size: 30px;
  line-height: 1;
  filter: drop-shadow(0 3px 6px rgba(15, 23, 42, 0.16));
  pointer-events: none;
}

.factory-card:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.3);
  box-shadow: 0 18px 44px rgba(37, 99, 235, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.92);
}

.factory-card.is-disabled {
  cursor: default;
}

.factory-card.is-disabled .factory-card-body span {
  color: #d8174b;
}

.factory-image {
  min-height: 0;
  aspect-ratio: 1 / 1;
  padding: 0;
  border-radius: 18px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: transparent;
  border: 0;
  box-shadow:
    0 7px 13px rgba(37, 99, 235, 0.12),
    0 3px 7px rgba(15, 23, 42, 0.07);
}

.factory-image-frame {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 15px;
  overflow: hidden;
  background: linear-gradient(135deg, #f7faff, #eef5ff);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.72);
}

.factory-image-frame::after {
  content: none;
}

.factory-image.small {
  width: 98px;
  min-height: 78px;
  height: 78px;
  aspect-ratio: auto;
  padding: 5px;
  border-radius: 16px;
}

.factory-image-frame img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 15px;
}

.factory-image-frame img:not([src]) {
  opacity: 0;
}

.image-preview-btn {
  position: absolute;
  z-index: 3;
  top: 8px;
  right: 8px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.13);
  backdrop-filter: blur(10px);
  cursor: pointer;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 160ms ease, transform 160ms ease, background 160ms ease;
}

.image-preview-btn svg {
  width: 18px;
  height: 18px;
}

.factory-card:hover .image-preview-btn,
.image-preview-btn:focus-visible {
  opacity: 1;
  transform: translateY(0);
}

.image-preview-btn:hover {
  background: rgba(255, 255, 255, 0.94);
}

.favorite-toggle {
  position: absolute;
  z-index: 4;
  top: 8px;
  right: 8px;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.76);
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #62758e;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.13);
  backdrop-filter: blur(10px);
  cursor: pointer;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 160ms ease, color 180ms ease, background 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.factory-image-frame.has-preview-action .favorite-toggle {
  top: 50px;
}

.favorite-toggle::before {
  content: "";
  position: absolute;
  inset: -5px;
  border-radius: inherit;
}

.favorite-toggle svg {
  width: 18px;
  height: 18px;
  fill: transparent;
  stroke-width: 2;
  transition: fill 180ms ease, transform 180ms ease;
}

.favorite-toggle:hover {
  color: #d98900;
  border-color: rgba(245, 158, 11, 0.34);
  background: rgba(255, 250, 235, 0.96);
}

.factory-card:hover .favorite-toggle,
.favorite-toggle:focus-visible {
  opacity: 1;
  transform: translateY(0);
}

.favorite-toggle:active svg {
  transform: scale(0.84);
}

.favorite-toggle.is-favorite {
  color: #d98900;
  border-color: rgba(245, 158, 11, 0.38);
  background: rgba(255, 248, 224, 0.96);
}

.favorite-toggle.is-favorite svg {
  fill: currentColor;
}

.lucide-loader-circle {
  animation: localIconSpin 800ms linear infinite;
}

@keyframes localIconSpin {
  to { transform: rotate(360deg); }
}

.favorite-toggle:focus-visible,
.favorites-filter:focus-visible {
  outline: 3px solid rgba(22, 119, 255, 0.28);
  outline-offset: 2px;
}

.factory-card.accessory-card .factory-image,
.factory-card.accessory-card .factory-image-frame {
  background: #fff;
}

.factory-card.accessory-card .factory-image-frame img {
  object-fit: contain;
}

.factory-placeholder {
  width: 100%;
  min-height: inherit;
  height: 100%;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: #1554d1;
  text-align: center;
}

.factory-placeholder svg {
  width: 30px;
  height: 30px;
  opacity: 0.72;
}

.image-preview-dialog {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  padding: 28px;
  box-sizing: border-box;
}

.image-preview-dialog[hidden] {
  display: none;
}

.image-preview-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(23, 37, 55, 0.46);
  backdrop-filter: blur(10px);
}

.image-preview-panel {
  position: relative;
  z-index: 1;
  width: min(78vw, 1180px);
  max-width: calc(100vw - 56px);
  max-height: calc(100vh - 56px);
  margin: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 24px;
  display: grid;
  grid-template-rows: auto auto auto auto;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 26px 80px rgba(15, 23, 42, 0.25);
  box-sizing: border-box;
}

.image-preview-head {
  min-height: 70px;
  padding: 0 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid rgba(226, 234, 245, 0.86);
}

.image-preview-title {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 13px;
  color: #102033;
}

.image-preview-title strong {
  flex: 0 0 auto;
  font-size: 17px;
  font-weight: 900;
}

.image-preview-title i {
  width: 1px;
  height: 18px;
  background: #d8e3f1;
}

.image-preview-title span {
  min-width: 0;
  color: #7890ab;
  font-size: 15px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.image-preview-stage {
  position: relative;
  height: min(54vh, 620px);
  min-height: 330px;
  margin: 20px 26px 0;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f5f7fa;
  overflow: hidden;
}

.image-preview-canvas {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 0;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #f5f7fa;
}

.image-preview-canvas img {
  display: block;
  width: var(--reference-image-width, auto);
  height: var(--reference-image-height, auto);
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  border-radius: 14px;
  background: #f5f7fa;
  opacity: 1;
  transition: opacity 180ms ease;
}

.image-preview-dialog.is-loading .image-preview-canvas img {
  opacity: 0.18;
}

.image-preview-loading,
.image-preview-error {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  place-items: center;
  color: #7890ab;
  font-size: 14px;
  font-weight: 800;
  pointer-events: none;
}

.image-preview-loading {
  opacity: 0;
}

.image-preview-dialog.is-loading .image-preview-loading {
  opacity: 1;
}

.image-preview-error {
  color: #e11d48;
  background: rgba(255, 255, 255, 0.72);
}

.image-preview-dialog:not(.is-error) .image-preview-error {
  display: none;
}

.image-preview-nav {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 54px;
  height: 54px;
  padding: 0;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 14px 32px rgba(31, 69, 116, 0.16);
  transform: translateY(-50%);
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.image-preview-nav svg {
  width: 27px;
  height: 27px;
}

.image-preview-nav:hover {
  background: #eef6ff;
  box-shadow: 0 18px 38px rgba(37, 99, 235, 0.2);
  transform: translateY(-50%) scale(1.04);
}

.image-preview-prev {
  left: 18px;
}

.image-preview-next {
  right: 18px;
}

.image-preview-thumbs-wrap {
  min-width: 0;
  margin: 16px 26px 0;
  min-height: 84px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 34px;
  align-items: center;
  gap: 10px;
}

.image-preview-thumbs {
  min-width: 0;
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 2px 0 4px;
  scrollbar-width: none;
  scroll-behavior: smooth;
}

.image-preview-thumbs::-webkit-scrollbar {
  display: none;
}

.image-preview-thumb {
  flex: 0 0 112px;
  width: 112px;
  height: 78px;
  padding: 3px;
  border: 1px solid rgba(214, 224, 238, 0.95);
  border-radius: 9px;
  display: grid;
  place-items: center;
  background: #f8fbff;
  box-shadow: none;
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.image-preview-thumb:hover {
  border-color: rgba(37, 99, 235, 0.32);
  background: #f2f7ff;
}

.image-preview-thumb.is-active {
  border: 2px solid #2563eb;
  background: #fff;
}

.image-preview-thumb img {
  width: 100%;
  height: 100%;
  border-radius: 6px;
  display: block;
  object-fit: cover;
}

.image-preview-thumb-more {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #425a78;
  background: transparent;
}

.image-preview-thumb-more:hover {
  color: #2563eb;
  background: #eef6ff;
}

.image-preview-thumb-more svg {
  width: 20px;
  height: 20px;
}

.image-preview-foot {
  min-height: 112px;
  padding: 20px 30px 26px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.image-preview-foot div {
  min-width: 0;
  display: grid;
  gap: 10px;
}

.image-preview-foot strong {
  max-width: 560px;
  color: #22324a;
  font-size: 28px;
  line-height: 1.15;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.image-preview-foot div > span {
  color: #2563eb;
  font-size: 26px;
  line-height: 1;
  font-weight: 950;
}

.image-preview-foot p {
  flex: 0 0 auto;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 9px;
  color: #8798ad;
  font-size: 15px;
  font-weight: 800;
}

.image-preview-foot p svg {
  width: 18px;
  height: 18px;
  color: #2563eb;
}

.image-preview-close {
  position: static;
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  display: grid;
  place-items: center;
  color: #51677f;
  background: #f1f5f9;
  box-shadow: none;
  cursor: pointer;
  z-index: 2;
  transition: background 160ms ease, color 160ms ease;
}

.is-previewing-image {
  overflow: hidden;
}

.image-preview-close:hover {
  color: #2563eb;
  background: #eaf3ff;
}

.image-preview-close svg {
  width: 20px;
  height: 20px;
}

@media (max-height: 820px) {
  .image-preview-panel {
    grid-template-rows: auto auto auto auto;
  }

  .image-preview-head {
    min-height: 58px;
  }

  .image-preview-stage {
    margin-top: 14px;
    height: min(46vh, 460px);
    min-height: 260px;
  }

  .image-preview-canvas {
    height: 100%;
    min-height: 0;
  }

  .image-preview-thumb {
    flex-basis: 94px;
    width: 94px;
    height: 64px;
  }

  .image-preview-foot {
    min-height: 86px;
    padding-block: 14px 18px;
  }

  .image-preview-foot strong {
    font-size: 23px;
  }

  .image-preview-foot div > span {
    font-size: 22px;
  }
}

@media (max-width: 900px) {
  .image-preview-dialog {
    padding: 14px;
  }

  .image-preview-panel {
    width: calc(100vw - 28px);
    max-width: calc(100vw - 28px);
    border-radius: 20px;
  }

  .image-preview-head,
  .image-preview-foot {
    padding-inline: 18px;
  }

  .image-preview-stage,
  .image-preview-thumbs-wrap {
    margin-inline: 16px;
  }

  .image-preview-nav {
    width: 44px;
    height: 44px;
  }

  .image-preview-prev {
    left: 10px;
  }

  .image-preview-next {
    right: 10px;
  }

  .image-preview-foot {
    align-items: start;
    display: grid;
  }
}

.factory-placeholder strong {
  max-width: 90%;
  color: #102033;
  font-size: 26px;
  line-height: 1.2;
  word-break: break-word;
}

.factory-placeholder span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.factory-card-body {
  min-height: 66px;
  padding: 0 6px 6px;
  display: grid;
  align-content: center;
  gap: 5px;
  text-align: center;
}

.factory-card-body strong {
  color: #102033;
  font-size: 18px;
  line-height: 1.35;
}

.factory-card-body span {
  color: #102033;
  font-size: 18px;
  font-weight: 800;
}

.factory-card-body .name-main,
.factory-card-body .name-meta {
  display: block;
}

.factory-card-body .name-main {
  word-break: break-word;
}

.factory-card-body .name-meta {
  color: #102033;
  font-size: 18px;
  line-height: 1.35;
}

.factory-card-body .name-meta i {
  display: block;
  font-style: normal;
  white-space: nowrap;
}

.factory-card.accessory-card .factory-card-body {
  width: 100%;
  justify-items: center;
  align-items: center;
  gap: 6px;
  text-align: center;
}

.factory-card.accessory-card .accessory-card-divider {
  display: block;
  width: 105%;
  height: 2px;
  margin-left: auto;
  margin-right: auto;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(205, 215, 228, 0.18) 16%,
    rgba(195, 207, 222, 0.58) 36%,
    rgba(182, 197, 216, 0.9) 50%,
    rgba(195, 207, 222, 0.58) 64%,
    rgba(205, 215, 228, 0.18) 84%,
    transparent 100%
  );
}

.factory-card.accessory-card .name-main {
  display: grid;
  justify-self: center;
  width: 100%;
  gap: 2px;
  text-align: center;
}

.factory-card.accessory-card .accessory-model,
.factory-card.accessory-card .accessory-name-text {
  display: block;
  width: 100%;
  line-height: 1.2;
  white-space: nowrap;
}

.factory-card.accessory-card .accessory-model {
  color: #111111;
  font-size: 19px;
  font-weight: 900;
}

.factory-card.accessory-card .accessory-name-text {
  overflow: hidden;
  color: #111111;
  font-size: 13px;
  font-weight: 700;
}

.factory-card.is-disabled.accessory-card .accessory-model,
.factory-card.is-disabled.accessory-card .accessory-name-text {
  color: #111111;
}

.factory-card.accessory-card .accessory-price {
  display: block;
  justify-self: center;
  width: 100%;
  color: #ef4444;
  font-size: 19px;
  font-weight: 900;
  line-height: 1.2;
  text-align: center;
}

.factory-card.accessory-card.is-disabled .accessory-price {
  color: #ef4444;
}

.section-load-more {
  width: max-content;
  min-width: 176px;
  min-height: 38px;
  margin: 12px auto 0;
  padding: 0 18px;
  border: 1px solid rgba(37, 99, 235, 0.28);
  border-radius: 999px;
  color: #1554d1;
  font-size: 14px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: 0 10px 24px rgba(37, 99, 235, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  cursor: pointer;
}

.section-load-more:hover {
  color: #0f4fc7;
  border-color: rgba(37, 99, 235, 0.42);
  background: #fff;
}

.factory-admin-grid {
  display: grid;
  gap: 10px;
}

.admin-factory-card {
  display: grid;
  grid-template-columns: 98px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 12px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 20px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.52), rgba(255, 255, 255, 0.28)),
    linear-gradient(135deg, rgba(37, 99, 235, 0.07), rgba(14, 165, 233, 0.05));
  box-shadow: 0 14px 38px rgba(47, 83, 117, 0.09), inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.admin-load-more-card {
  display: flex;
  justify-content: center;
  padding: 16px;
}

.admin-load-more-card .ghost-action {
  min-width: 220px;
  justify-content: center;
}

.admin-factory-main {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.admin-factory-main strong {
  color: #102033;
  font-size: 16px;
}

.admin-factory-main span {
  color: #1554d1;
  font-size: 13px;
  font-weight: 900;
}

.admin-factory-main .click-count {
  width: max-content;
  padding: 3px 9px;
  border: 1px solid rgba(37, 99, 235, 0.16);
  border-radius: 999px;
  color: #1554d1;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
  background: rgba(37, 99, 235, 0.07);
}

.admin-factory-main small {
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

@media (max-width: 1100px) {
  .workspace {
    grid-template-columns: 1fr;
  }

  .side-rail {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .front-shell {
    grid-template-columns: 1fr;
  }

  .front-sidebar {
    position: static;
    height: auto;
    min-height: 0;
  }

  .featured-strip {
    grid-template-columns: 1fr;
    margin-top: 0;
  }

  .factory-shell {
    grid-template-columns: 1fr;
  }

  .factory-sidebar {
    position: static;
    height: auto;
    min-height: 0;
  }

  .category-items {
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  }

  .category-manager-shell {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .category-tree {
    height: 360px;
  }
}

@media (max-width: 760px) {
  .admin-shell {
    width: min(100% - 20px, 1480px);
    margin: 10px auto;
  }

  .admin-head,
  .workspace {
    padding: 14px;
    border-radius: 20px;
  }

  .admin-head {
    display: grid;
  }

  .admin-actions,
  .toolbar,
  .side-rail {
    display: grid;
    grid-template-columns: 1fr;
  }

  .admin-form,
  .modal-form {
    grid-template-columns: 1fr;
  }

  dialog.category-settings-dialog {
    width: calc(100vw - 18px);
  }

  .category-manager-shell {
    padding: 0 10px 10px;
    gap: 10px;
  }

  .category-panel-head,
  .category-editor-head {
    display: grid;
    align-items: start;
  }

  .category-tree-row {
    grid-template-columns: 20px 20px 30px minmax(0, 1fr) 28px 28px 28px;
    gap: 5px;
    padding-inline: 6px;
  }

  .category-tree-row.level-2 {
    margin-left: 14px;
  }

  .category-tree-row.level-3 {
    margin-left: 28px;
  }

  .parent-category-row,
  .icon-uploader-row {
    grid-template-columns: 1fr;
  }

  .list-panel-title {
    grid-template-columns: 1fr auto;
  }

  .list-search-field {
    grid-column: 1 / -1;
    order: 2;
  }

  .software-row {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .app-icon {
    width: 52px;
    height: 52px;
    border-radius: 16px;
  }

  .card-actions {
    grid-column: 1 / -1;
    justify-content: stretch;
  }

  .card-actions button {
    flex: 1;
  }

  .front-shell {
    width: min(100% - 20px, 1480px);
    margin: 10px auto;
  }

  .front-sidebar,
  .front-main {
    padding: 14px;
    border-radius: 20px;
  }

  .front-hero {
    display: grid;
    min-height: auto;
  }

  .front-card-grid {
    grid-template-columns: 1fr;
  }

  .front-card-bottom {
    grid-template-columns: 1fr;
  }

  .front-card-bottom .primary-action {
    width: 100%;
  }

  .factory-shell {
    width: min(100% - 20px, 1600px);
    margin: 10px auto;
  }

  .factory-sidebar,
  .factory-main {
    padding: 14px;
    border-radius: 20px;
  }

  .factory-hero {
    display: grid;
    min-height: auto;
  }

  .front-search-main,
  .front-discovery {
    width: 100%;
  }

  .discovery-row {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .factory-grid {
    grid-template-columns: 1fr;
  }

  .category-items {
    grid-template-columns: 1fr;
  }

  .admin-factory-card {
    grid-template-columns: 78px minmax(0, 1fr);
  }

  .admin-factory-card .card-actions {
    grid-column: 1 / -1;
  }

  .factory-image.small {
    width: 78px;
  }
}

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


/* ????/??????????????????????? */
.layout-scroll .category-items,
.layout-marquee .category-items {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  overflow-x: auto !important;
  overflow-y: visible;
  scroll-behavior: smooth;
  scrollbar-width: none;
  animation: none !important;
  transform: none !important;
  contain: layout paint;
}

.layout-scroll .category-items::-webkit-scrollbar,
.layout-marquee .category-items::-webkit-scrollbar {
  display: none;
}

.layout-scroll .factory-card,
.layout-marquee .factory-card {
  width: calc((100% - var(--scroll-gap-total, 56px)) / var(--scroll-cols, 5)) !important;
  min-width: 0 !important;
  flex: 0 0 auto;
}


/* ?????????????????????????????? */
.front-filters {
  scrollbar-width: thin;
  scrollbar-color: transparent transparent;
}

.front-filters:hover {
  scrollbar-color: rgba(96, 112, 137, 0.24) transparent;
}

.front-filters::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

.front-filters::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(96, 112, 137, 0);
  transition: background-color 220ms ease;
}

.front-filters:hover::-webkit-scrollbar-thumb {
  background: rgba(96, 112, 137, 0.24);
}

.front-filters:hover::-webkit-scrollbar-thumb:hover {
  background: rgba(96, 112, 137, 0.34);
}

/* final override: ????????????????????????? */
.category-section.has-horizontal-controls .horizontal-page-btn {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  min-height: 42px !important;
  padding: 0 !important;
  border-radius: 50% !important;
  display: grid !important;
  opacity: 0 !important;
  pointer-events: none !important;
  place-items: center !important;
}

.category-section.has-horizontal-controls.has-scrollable-row:hover .horizontal-page-btn {
  opacity: 1 !important;
  pointer-events: auto !important;
}

.category-section.has-horizontal-controls .horizontal-page-btn:hover {
  transform: translateY(-50%) scale(1.04) !important;
}

.category-section.has-horizontal-controls .horizontal-page-btn svg {
  width: 20px !important;
  height: 20px !important;
}

/* final override: ??????????????????????? */
@media (min-width: 1101px) {
  .factory-shell {
    width: min(2600px, calc(100% - clamp(48px, 5vw, 80px))) !important;
    gap: clamp(16px, 1.25vw, 20px) !important;
  }

  .category-section.layout-grid .category-items,
  .recommend-section.layout-grid .category-items {
    justify-content: start !important;
    grid-template-columns: repeat(auto-fill, minmax(clamp(230px, 14.5vw, 320px), 1fr)) !important;
  }

  .category-section.layout-compact .category-items {
    justify-content: start !important;
    grid-template-columns: repeat(auto-fill, minmax(clamp(210px, 13vw, 290px), 1fr)) !important;
  }

  .category-section.layout-wide .category-items {
    justify-content: start !important;
    grid-template-columns: repeat(auto-fill, minmax(clamp(280px, 17vw, 380px), 1fr)) !important;
  }
}

/* 搜索框只保留外层边框高亮，避免输入框与容器叠加成粗光圈 */
.front-page #frontSearch:focus,
.front-page #frontSearch:focus-visible {
  outline: none !important;
  box-shadow: none !important;
}

.front-page .front-search-row:focus-within {
  border-color: var(--front-primary);
  box-shadow: 0 4px 14px rgba(31, 91, 155, 0.08);
}

@media (min-width: 1500px) and (max-width: 2199px) {
  .category-section.layout-grid .category-items,
  .recommend-section.layout-grid .category-items {
    grid-template-columns: repeat(auto-fill, minmax(clamp(210px, 13vw, 300px), 1fr)) !important;
  }
}

@media (min-width: 2200px) {
  .category-section.layout-grid .category-items,
  .recommend-section.layout-grid .category-items {
    grid-template-columns: repeat(auto-fill, minmax(clamp(290px, 13vw, 360px), 1fr)) !important;
  }
}

/* final override: ?????????? */
.section-load-more-area {
  width: 100%;
  margin: 24px auto 48px;
  display: grid;
  justify-items: center;
  gap: 18px;
  text-align: center;
}

.section-load-more-area.is-complete {
  margin-top: 32px;
  margin-bottom: 44px;
}

.section-load-summary {
  margin: 0;
  color: #7f90aa;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.5;
}

/* 前台分类：每个分类使用独立卡片，取消标题分割线 */
.front-page .factory-main {
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
}

.front-page .factory-grid {
  gap: 18px;
}

.front-page .category-section:not(.major-section) {
  padding: 22px;
  border: 1px solid rgba(221, 231, 245, 0.92);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 14px 36px rgba(64, 96, 140, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px) saturate(1.06);
}

.front-page .category-section:not(.major-section) + .category-section:not(.major-section) {
  padding-top: 22px;
  border-top: 1px solid rgba(221, 231, 245, 0.92);
}

.front-page .category-section:not(.major-section) .category-divider {
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  justify-content: stretch;
}

.front-page .category-section:not(.major-section) .category-divider::after {
  display: none;
}

.favorites-page {
  padding: 22px;
  border: 1px solid rgba(221, 231, 245, 0.92);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 14px 36px rgba(64, 96, 140, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px) saturate(1.06);
}

.favorite-day-group + .favorite-day-group {
  margin-top: 30px;
  padding-top: 30px;
  border-top: 1px solid rgba(183, 201, 224, 0.62);
}

.favorite-day-header {
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #102033;
}

.favorite-day-header h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.3;
}

.favorite-day-header span {
  min-width: 28px;
  padding: 4px 8px;
  border-radius: 999px;
  color: #1554d1;
  font-size: 12px;
  font-weight: 900;
  text-align: center;
  background: rgba(37, 99, 235, 0.09);
}

.favorites-page.is-empty {
  min-height: 430px;
  display: grid;
  place-items: center;
}

.favorites-empty-state {
  max-width: 430px;
  padding: 48px 24px;
  display: grid;
  justify-items: center;
  gap: 10px;
  color: #6f8198;
  text-align: center;
}

.favorites-empty-icon {
  width: 64px;
  height: 64px;
  margin-bottom: 6px;
  border: 1px solid rgba(245, 158, 11, 0.24);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #d98900;
  background: rgba(255, 248, 224, 0.82);
}

.favorites-empty-icon svg {
  width: 28px;
  height: 28px;
}

.favorites-empty-state strong {
  color: #24364d;
  font-size: 20px;
}

.favorites-empty-state p {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
}

.category-layout-control {
  position: relative;
  grid-column: 4;
  justify-self: end;
}

.category-layout-trigger {
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid rgba(37, 99, 235, 0.16);
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: #58708d;
  background: rgba(247, 250, 255, 0.9);
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease;
}

.category-layout-trigger:hover,
.category-layout-trigger[aria-expanded="true"] {
  color: #1769e8;
  border-color: rgba(37, 99, 235, 0.34);
  background: #fff;
}

.category-layout-trigger svg {
  width: 19px;
  height: 19px;
}

.category-layout-menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + 8px);
  right: 0;
  width: 286px;
  padding: 14px;
  border: 1px solid rgba(211, 224, 242, 0.96);
  border-radius: 16px;
  color: #102033;
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 42px rgba(47, 79, 121, 0.18);
}

.category-layout-menu strong {
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
}

.category-layout-options {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}

.category-layout-option {
  min-height: 34px;
  padding: 0 8px;
  border: 1px solid rgba(211, 224, 242, 0.96);
  border-radius: 9px;
  color: #526985;
  font-size: 13px;
  font-weight: 800;
  background: #f7faff;
  cursor: pointer;
}

.category-layout-option:hover,
.category-layout-option.is-active {
  color: #fff;
  border-color: #1877ed;
  background: #1877ed;
}

.category-layout-menu small {
  display: block;
  margin-top: 10px;
  color: #8292a8;
  font-size: 12px;
}

@media (min-width: 1101px) {
  .category-section.has-user-columns .category-items {
    grid-template-columns: repeat(var(--category-columns), minmax(0, 1fr)) !important;
  }
}

@media (max-width: 1100px) {
  .category-layout-control {
    display: none;
  }
}

@media (max-width: 720px) {
  .front-page .category-section:not(.major-section) {
    padding: 16px;
    border-radius: 20px;
  }

  .front-page .category-section:not(.major-section) + .category-section:not(.major-section) {
    padding-top: 16px;
  }

  .favorites-page {
    padding: 16px;
    border-radius: 20px;
  }

  .favorite-day-group + .favorite-day-group {
    margin-top: 22px;
    padding-top: 22px;
  }
}

.section-load-summary strong {
  color: #647895;
  font-weight: 700;
}

.section-load-more {
  width: clamp(300px, 28vw, 360px);
  height: 56px;
  padding: 0 28px;
  border: 1px solid rgba(37, 99, 235, 0.26);
  border-radius: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: #1d66e5;
  font-size: 17px;
  font-weight: 800;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: 0 8px 22px rgba(37, 99, 235, 0.07), inset 0 1px 0 rgba(255, 255, 255, 0.92);
  cursor: pointer;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.section-load-more:hover {
  color: #1554d1;
  border-color: rgba(37, 99, 235, 0.4);
  background: rgba(239, 246, 255, 0.92);
  transform: translateY(-1px);
}

.section-load-more:active {
  transform: translateY(0);
}

.section-load-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.09);
}

.section-load-icon svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}


.baidu-config-note {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 14px;
  background: rgba(37, 99, 235, 0.07);
  color: #31527a;
  font-size: 13px;
  line-height: 1.5;
}

.baidu-config-note svg {
  width: 18px;
  height: 18px;
  color: #2563eb;
  flex: 0 0 auto;
}

.baidu-config-form small {
  display: block;
  margin-top: 6px;
  color: #7184a3;
  font-size: 12px;
}

.baidu-config-switch {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
}

.baidu-config-actions {
  align-items: center;
}


.baidu-sync-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid rgba(37, 99, 235, 0.16);
  border-radius: 16px;
  background: rgba(248, 251, 255, 0.78);
}

.baidu-sync-panel > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #0f2742;
}

.baidu-sync-panel > div:first-child span {
  color: #2563eb;
  font-size: 13px;
  font-weight: 700;
}

.baidu-sync-panel > div:first-child span.is-error {
  color: #dc2626;
}

.baidu-sync-panel p {
  margin: 0;
  color: #7184a3;
  font-size: 13px;
  line-height: 1.5;
}

.baidu-sync-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}


.front-search-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(860px, 100%);
}

.front-search-row .front-search-main {
  flex: 1 1 auto;
  min-width: 0;
  width: auto;
}

.image-search-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 48px;
  padding: 0 18px;
  border: 1px solid rgba(37, 99, 235, 0.26);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.78);
  color: #1764df;
  font-weight: 800;
  white-space: nowrap;
  box-shadow: 0 14px 34px rgba(37, 99, 235, 0.12);
  cursor: pointer;
}

.image-search-action:hover {
  border-color: rgba(37, 99, 235, 0.46);
  background: rgba(239, 246, 255, 0.96);
}

.image-search-action:disabled {
  cursor: wait;
  opacity: 0.72;
}

.image-search-action svg {
  width: 18px;
  height: 18px;
}

.image-search-section {
  min-height: 360px;
}

.image-search-divider {
  gap: 10px;
}

.image-search-clear {
  margin-left: auto;
  border: 1px solid rgba(37, 99, 235, 0.22);
  border-radius: 999px;
  background: rgba(255,255,255,.8);
  color: #2563eb;
  font-weight: 800;
  padding: 7px 12px;
  cursor: pointer;
}

.image-search-message {
  margin: -6px 0 16px;
  color: #607596;
  font-weight: 700;
}

@media (max-width: 900px) {
  .front-search-row {
    flex-direction: column;
    align-items: stretch;
  }
  .image-search-action {
    width: 100%;
  }
}


/* final search bar ui 20260706 */
.front-search-sticky {
  overflow: visible;
}

.front-search-row {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 42px 54px;
  align-items: center;
  gap: 0;
  width: min(980px, 100%);
  min-height: 58px;
  padding: 5px 6px 5px 0;
  border: 1.5px solid rgba(37, 99, 235, 0.58);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow:
    0 12px 28px rgba(37, 99, 235, 0.10),
    inset 0 1px 0 rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(16px) saturate(1.12);
}

.front-search-row:focus-within {
  border-color: rgba(37, 99, 235, 0.78);
  box-shadow:
    0 0 0 3px rgba(37, 99, 235, 0.10),
    0 14px 32px rgba(37, 99, 235, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.98);
}

.front-search-mode {
  height: 48px;
  padding: 0 16px 0 18px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #355276;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
  border-right: 1px solid rgba(37, 99, 235, 0.16);
}

.front-search-mode svg {
  width: 15px;
  height: 15px;
  color: #7b8da8;
}

.front-search-row .front-search-main {
  width: auto;
  min-height: 48px;
  padding: 0 12px 0 16px;
  border: 0;
  border-radius: 0;
  display: flex;
  align-items: center;
  box-shadow: none;
  background: transparent;
}

.front-search-row .front-search-main input {
  width: 100%;
  min-height: 44px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #10233d;
  font-size: 16px;
  font-weight: 800;
  outline: none;
}

.front-search-row .front-search-main input::placeholder {
  color: #9aa8bb;
  font-size: 14px;
  font-weight: 500;
}

.front-search-icon-btn,
.front-search-submit {
  border: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.front-search-icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: transparent;
  color: #8ea0b9;
}

.front-search-icon-btn:hover {
  background: rgba(37, 99, 235, 0.08);
  color: #2563eb;
}

.front-search-icon-btn:disabled {
  cursor: wait;
  opacity: 0.72;
}

.front-search-icon-btn svg {
  width: 20px;
  height: 20px;
}

.front-search-submit {
  width: 50px;
  height: 46px;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.25);
}

.front-search-submit:hover {
  filter: brightness(1.04);
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.30);
}

.front-search-submit svg {
  width: 22px;
  height: 22px;
}

.image-search-action {
  display: none;
}

@media (max-width: 900px) {
  .front-search-row {
    grid-template-columns: 1fr 42px 50px;
    padding-left: 12px;
  }

  .front-search-mode {
    display: none;
  }
}


.front-search-clear-btn {
  width: 28px;
  height: 28px;
  border: 1px solid rgba(37, 99, 235, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  color: #2563eb;
  font-size: 18px;
  line-height: 1;
  font-weight: 700;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.front-search-clear-btn.is-visible {
  display: inline-flex;
}

/* Recognition feedback samples */
.recognition-feedback-launcher {
  position: fixed;
  right: max(24px, env(safe-area-inset-right));
  bottom: max(24px, env(safe-area-inset-bottom));
  z-index: 920;
  min-height: 52px;
  padding: 0 20px;
  border: 1px solid rgba(37, 99, 235, .2);
  border-radius: 999px;
  background: #2563eb;
  color: #fff;
  box-shadow: 0 14px 34px rgba(37, 99, 235, .32);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  font: inherit;
  font-size: 14px;
  font-weight: 900;
  cursor: pointer;
  transition: background-color .18s ease, box-shadow .18s ease, opacity .18s ease;
}
.recognition-feedback-launcher:hover {
  background: #1d4ed8;
  box-shadow: 0 16px 38px rgba(37, 99, 235, .4);
}
.recognition-feedback-launcher:focus-visible,
.recognition-feedback-dialog button:focus-visible {
  outline: 3px solid rgba(14, 165, 233, .32);
  outline-offset: 2px;
}
.recognition-feedback-launcher svg { width: 20px; height: 20px; }
.recognition-feedback-dialog {
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  overflow: hidden;
  box-sizing: border-box;
}
.recognition-feedback-dialog::backdrop { background: rgba(15, 31, 54, .5); backdrop-filter: blur(3px); }
.recognition-feedback-shell {
  width: min(1064px, 100%);
  height: 100dvh;
  margin-left: auto;
  display: flex;
  align-items: stretch;
}
.recognition-feedback-drawer {
  flex: 0 0 min(520px, 100%);
  width: min(520px, 100%);
  height: 100dvh;
  margin-left: auto;
  background: #fff;
  color: #10233d;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  box-shadow: -22px 0 54px rgba(15, 31, 54, .18);
  animation: recognitionFeedbackEnter .24s ease-out both;
}
.recognition-feedback-guide {
  color: #10233d;
  box-sizing: border-box;
}
.recognition-feedback-guide--desktop {
  flex: 0 0 520px;
  width: 520px;
  margin: auto 24px auto 0;
  padding: 24px;
  border: 1px solid rgba(208, 224, 241, .95);
  border-radius: 24px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 24px 70px rgba(15, 31, 54, .22);
  animation: recognitionFeedbackGuideEnter .28s ease-out both;
}
.recognition-feedback-guide--mobile { display: none; }
.recognition-feedback-guide-head { display: flex; align-items: center; gap: 12px; }
.recognition-feedback-guide-icon { flex: 0 0 44px; width: 44px; height: 44px; border-radius: 14px; background: #e8f1ff; color: #2563eb; display: grid; place-items: center; }
.recognition-feedback-guide-icon svg { width: 23px; height: 23px; }
.recognition-feedback-guide-head div { min-width: 0; }
.recognition-feedback-guide-head strong { display: block; color: #10233d; font-size: 18px; line-height: 1.35; }
.recognition-feedback-guide-head p { margin: 3px 0 0; color: #607596; font-size: 12px; font-weight: 700; line-height: 1.5; }
.recognition-feedback-guide-examples { margin-top: 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.recognition-feedback-guide-example { min-width: 0; margin: 0; border: 1px solid #dde7f2; border-radius: 17px; background: #fff; overflow: hidden; }
.recognition-feedback-guide-picture { position: relative; height: 246px; background: #eef2f6; overflow: hidden; }
.recognition-feedback-guide-picture img { width: 100%; height: 100%; display: block; object-fit: cover; }
.recognition-feedback-guide-picture > span { position: absolute; top: 10px; left: 10px; min-height: 30px; padding: 0 10px; border-radius: 999px; display: inline-flex; align-items: center; gap: 5px; color: #fff; font-size: 12px; font-weight: 900; }
.recognition-feedback-guide-picture > span svg { width: 15px; height: 15px; stroke-width: 3; }
.recognition-feedback-guide-example.is-wrong .recognition-feedback-guide-picture > span { background: #dc2626; }
.recognition-feedback-guide-example.is-correct .recognition-feedback-guide-picture > span { background: #059669; }
.recognition-feedback-guide-example figcaption { min-height: 100px; padding: 12px; }
.recognition-feedback-guide-example figcaption strong,
.recognition-feedback-guide-example figcaption small { display: block; }
.recognition-feedback-guide-example figcaption strong { color: #172b46; font-size: 13px; line-height: 1.45; }
.recognition-feedback-guide-example figcaption small { margin-top: 5px; color: #657a96; font-size: 11px; font-weight: 650; line-height: 1.55; }
.recognition-feedback-guide-example.is-wrong { border-color: #f2c9cd; }
.recognition-feedback-guide-example.is-correct { border-color: #bce4d5; }
.recognition-feedback-guide-tip { margin: 14px 0 0; padding: 12px 14px; border-radius: 14px; background: #eef6ff; color: #315679; display: flex; align-items: flex-start; gap: 9px; font-size: 12px; line-height: 1.55; }
.recognition-feedback-guide-tip > svg { flex: 0 0 18px; width: 18px; height: 18px; margin-top: 1px; color: #2563eb; }
.recognition-feedback-guide-tip strong { display: block; color: #1d4ed8; }
@keyframes recognitionFeedbackEnter { from { transform: translateX(28px); opacity: .65; } to { transform: translateX(0); opacity: 1; } }
@keyframes recognitionFeedbackGuideEnter { from { transform: translateX(18px); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
.recognition-feedback-head {
  min-height: 132px;
  padding: 24px 24px 20px;
  border-bottom: 1px solid #dbe6f4;
  background: linear-gradient(145deg, #f7fbff 0%, #eef6ff 100%);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.recognition-feedback-kicker { color: #2563eb; font-size: 12px; font-weight: 900; letter-spacing: .08em; }
.recognition-feedback-head h2 { margin: 5px 0 4px; color: #10233d; font-size: 24px; line-height: 1.25; }
.recognition-feedback-head p { margin: 0; color: #607596; font-size: 13px; line-height: 1.55; font-weight: 650; }
.recognition-feedback-close {
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid #cbdcf0;
  border-radius: 14px;
  background: #fff;
  color: #456383;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}
.recognition-feedback-close:hover { border-color: #93b7e5; color: #1d4ed8; background: #f8fbff; }
.recognition-feedback-close svg { width: 20px; height: 20px; }
.recognition-feedback-body { min-height: 0; overflow-y: auto; padding: 22px 24px 30px; }
.recognition-feedback-step + .recognition-feedback-step { margin-top: 24px; padding-top: 24px; border-top: 1px solid #e2eaf4; }
.recognition-feedback-step-title { display: flex; align-items: flex-start; gap: 11px; margin-bottom: 14px; }
.recognition-feedback-step-title > b {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  border-radius: 9px;
  background: #2563eb;
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 13px;
}
.recognition-feedback-step-title div { min-width: 0; }
.recognition-feedback-step-title strong,
.recognition-feedback-step-title span { display: block; }
.recognition-feedback-step-title strong { color: #172b46; font-size: 15px; }
.recognition-feedback-step-title span { margin-top: 3px; color: #71839d; font-size: 12px; line-height: 1.45; }
.recognition-feedback-search {
  min-height: 48px;
  padding: 0 14px;
  border: 1.5px solid #c8d8eb;
  border-radius: 14px;
  background: #fff;
  display: flex;
  align-items: center;
  gap: 9px;
}
.recognition-feedback-search:focus-within { border-color: #2563eb; }
.recognition-feedback-search svg { width: 19px; height: 19px; color: #7186a2; }
.recognition-feedback-search input { min-width: 0; flex: 1; height: 44px; padding: 0; border: 0; border-radius: 0; outline: 0; background: transparent; box-shadow: none; backdrop-filter: none; color: #10233d; font: inherit; font-size: 16px; font-weight: 750; }
.recognition-feedback-search input:focus { border: 0; outline: 0; box-shadow: none; }
.recognition-feedback-search input::placeholder { color: #97a6ba; font-weight: 500; }
.recognition-feedback-results {
  max-height: 300px;
  margin-top: 8px;
  padding: 6px;
  border: 1px solid #d7e2ef;
  border-radius: 15px;
  background: #fff;
  overflow-y: auto;
  box-shadow: 0 14px 32px rgba(28, 54, 86, .12);
}
.recognition-feedback-results[hidden], .recognition-feedback-selected[hidden], .recognition-feedback-preview[hidden] { display: none; }
.recognition-feedback-results button {
  width: 100%;
  min-height: 68px;
  padding: 7px;
  border: 0;
  border-radius: 11px;
  background: #fff;
  color: inherit;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  text-align: left;
  cursor: pointer;
}
.recognition-feedback-results button:hover,
.recognition-feedback-results button:focus-visible { background: #eef6ff; }
.recognition-feedback-result-image {
  position: relative;
  width: 54px;
  height: 54px;
  border-radius: 10px;
  background: #edf2f7;
  color: #91a2b8;
  display: grid;
  place-items: center;
  overflow: hidden;
}
.recognition-feedback-result-image > svg { width: 21px; height: 21px; }
.recognition-feedback-result-image > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: #edf2f7; }
.recognition-feedback-result-image.is-missing { background: #f1f5f9; }
.recognition-feedback-results span { min-width: 0; }
.recognition-feedback-results strong,
.recognition-feedback-results b,
.recognition-feedback-results small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recognition-feedback-results strong { color: #111827; font-size: 14px; }
.recognition-feedback-results b { margin-top: 2px; color: #334b68; font-size: 12px; font-weight: 700; }
.recognition-feedback-results small { margin-top: 3px; color: #7b8da5; font-size: 11px; }
.recognition-feedback-empty { padding: 22px 12px; color: #71839c; text-align: center; font-size: 13px; font-weight: 700; }
.recognition-feedback-selected {
  min-height: 112px;
  margin-top: 10px;
  padding: 10px;
  border: 1.5px solid rgba(37, 99, 235, .34);
  border-radius: 16px;
  background: #f1f7ff;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}
.recognition-feedback-selected img { width: 92px; height: 92px; border-radius: 13px; object-fit: cover; background: #e7eef7; }
.recognition-feedback-selected div { min-width: 0; }
.recognition-feedback-selected span,
.recognition-feedback-selected strong,
.recognition-feedback-selected p,
.recognition-feedback-selected small { display: block; margin: 0; }
.recognition-feedback-selected span { color: #2563eb; font-size: 11px; font-weight: 850; }
.recognition-feedback-selected strong { margin-top: 4px; color: #0f172a; font-size: 19px; }
.recognition-feedback-selected p { margin-top: 2px; color: #314763; font-size: 12px; font-weight: 700; line-height: 1.4; }
.recognition-feedback-selected small { margin-top: 5px; color: #71839d; font-size: 11px; }
.recognition-feedback-selected > button { min-height: 40px; padding: 0 11px; border: 1px solid #bdd1ea; border-radius: 11px; background: #fff; color: #315d91; font: inherit; font-size: 12px; font-weight: 850; cursor: pointer; }
.recognition-feedback-upload-step.is-disabled { opacity: .55; }
.recognition-feedback-dropzone {
  width: 100%;
  min-height: 158px;
  padding: 18px;
  border: 1.5px dashed #9bb8db;
  border-radius: 17px;
  background: #f8fbff;
  color: #1f3f65;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 5px;
  font: inherit;
  cursor: pointer;
  transition: border-color .18s ease, background-color .18s ease;
}
.recognition-feedback-dropzone:hover:not(:disabled), .recognition-feedback-dropzone.is-dragover { border-color: #2563eb; background: #eef6ff; }
.recognition-feedback-dropzone:disabled { cursor: not-allowed; }
.recognition-feedback-upload-icon { width: 44px; height: 44px; margin-bottom: 4px; border-radius: 14px; background: #e4efff; color: #2563eb; display: grid; place-items: center; }
.recognition-feedback-upload-icon svg { width: 23px; height: 23px; }
.recognition-feedback-dropzone strong { font-size: 14px; }
.recognition-feedback-dropzone small { color: #71839d; font-size: 12px; line-height: 1.5; }
.recognition-feedback-preview { margin-top: 10px; padding: 10px; border: 1px solid #d6e2f0; border-radius: 14px; background: #fff; }
.recognition-feedback-preview-head { margin-bottom: 9px; padding: 0 2px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.recognition-feedback-preview-head strong,
.recognition-feedback-preview-head span { display: block; }
.recognition-feedback-preview-head strong { color: #172b46; font-size: 12px; }
.recognition-feedback-preview-head span { color: #71839d; font-size: 11px; }
.recognition-feedback-preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.recognition-feedback-preview-item { position: relative; min-width: 0; min-height: 76px; margin: 0; padding: 8px 42px 8px 8px; border: 1px solid #e0e8f2; border-radius: 12px; background: #f8fbff; display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 8px; align-items: center; }
.recognition-feedback-preview-item img { width: 58px; height: 58px; border-radius: 9px; object-fit: cover; background: #eef2f7; }
.recognition-feedback-preview-item div { min-width: 0; }
.recognition-feedback-preview-item strong,
.recognition-feedback-preview-item span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recognition-feedback-preview-item strong { color: #172b46; font-size: 11px; }
.recognition-feedback-preview-item span { margin-top: 4px; color: #71839d; font-size: 10px; }
.recognition-feedback-preview-item button { position: absolute; top: 17px; right: 6px; width: 40px; height: 40px; padding: 0; border: 1px solid #f1c5c8; border-radius: 11px; background: #fff5f5; color: #dc2626; display: grid; place-items: center; cursor: pointer; touch-action: manipulation; }
.recognition-feedback-preview-item button svg { width: 17px; height: 17px; }
.recognition-feedback-status { min-height: 22px; margin: 16px 0 0; padding: 0 2px; color: #607596; font-size: 12px; font-weight: 750; line-height: 1.55; }
.recognition-feedback-status[data-state="error"] { color: #b91c1c; }
.recognition-feedback-status[data-state="warning"] { color: #a16207; }
.recognition-feedback-status[data-state="success"] { color: #047857; }
.recognition-feedback-status[data-state="loading"] { color: #1d4ed8; }
.recognition-feedback-footer { min-height: 78px; padding: 14px 24px max(14px, env(safe-area-inset-bottom)); border-top: 1px solid #dbe6f2; background: rgba(255,255,255,.96); display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 10px; align-items: center; }
.recognition-feedback-footer button { min-height: 48px; border-radius: 14px; font: inherit; font-size: 14px; font-weight: 900; cursor: pointer; }
.recognition-feedback-cancel { border: 1px solid #cbd9e9; background: #fff; color: #46617f; }
.recognition-feedback-submit { border: 0; background: #2563eb; color: #fff; display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.recognition-feedback-submit:disabled { opacity: .45; cursor: not-allowed; }
.recognition-feedback-submit svg { width: 19px; height: 19px; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0,0,0,0) !important; white-space: nowrap !important; border: 0 !important; }
@media (max-width: 1100px) {
  .recognition-feedback-shell { width: min(520px, 100%); }
  .recognition-feedback-guide--desktop { display: none; }
  .recognition-feedback-guide--mobile { display: block; margin: 20px 0 0; padding: 13px; border: 1px solid #d6e3f2; border-radius: 16px; background: #f8fbff; }
  .recognition-feedback-guide--mobile + .recognition-feedback-step { margin-top: 18px; padding-top: 18px; border-top: 1px solid #e2eaf4; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-head { gap: 9px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-icon { flex-basis: 36px; width: 36px; height: 36px; border-radius: 11px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-icon svg { width: 20px; height: 20px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-head strong { font-size: 14px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-head p { font-size: 11px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-examples { margin-top: 12px; gap: 8px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-picture { height: 126px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-picture > span { top: 7px; left: 7px; min-height: 25px; padding: 0 8px; font-size: 10px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-example figcaption { min-height: 74px; padding: 9px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-example figcaption strong { font-size: 11px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-example figcaption small { display: none; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-tip { margin-top: 9px; padding: 9px 10px; font-size: 11px; }
  .recognition-feedback-guide--mobile .recognition-feedback-guide-tip strong { display: inline; margin-right: 4px; }
}
@media (max-width: 600px) {
  .recognition-feedback-launcher { right: max(14px, env(safe-area-inset-right)); bottom: max(16px, env(safe-area-inset-bottom)); width: 52px; padding: 0; }
  .recognition-feedback-launcher span { display: none; }
  .recognition-feedback-drawer { width: 100%; }
  .recognition-feedback-head { min-height: 118px; padding: 18px 16px 16px; }
  .recognition-feedback-head h2 { font-size: 21px; }
  .recognition-feedback-body { padding: 18px 16px 24px; }
  .recognition-feedback-selected { grid-template-columns: 76px minmax(0, 1fr); }
  .recognition-feedback-selected img { width: 76px; height: 76px; }
  .recognition-feedback-selected > button { grid-column: 1 / -1; }
  .recognition-feedback-footer { grid-template-columns: 92px minmax(0, 1fr); padding-left: 16px; padding-right: 16px; }
  .recognition-feedback-preview-head { align-items: flex-start; flex-direction: column; gap: 2px; }
  .recognition-feedback-preview-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .recognition-feedback-drawer, .recognition-feedback-guide--desktop { animation: none; }
  .recognition-feedback-launcher, .recognition-feedback-dropzone { transition: none; }
}
.recognition-feedback-admin-summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 18px 12px; color: #58708e; font-size: 13px; font-weight: 800; }
.recognition-feedback-admin-list { max-height: 520px; margin: 0 18px 18px; border: 1px solid #dce6f1; border-radius: 16px; overflow-y: auto; background: #fff; }
.recognition-feedback-admin-row { min-height: 84px; padding: 10px 12px; border-bottom: 1px solid #e6edf5; display: grid; grid-template-columns: 64px minmax(180px, 1.4fr) auto minmax(150px, .8fr) auto; gap: 12px; align-items: center; }
.recognition-feedback-admin-row:last-child { border-bottom: 0; }
.recognition-feedback-admin-row.is-deleted { opacity: .58; }
.recognition-feedback-admin-row > img { width: 64px; height: 64px; border-radius: 12px; object-fit: cover; background: #edf2f7; }
.recognition-feedback-admin-copy { min-width: 0; }
.recognition-feedback-admin-copy strong, .recognition-feedback-admin-copy span, .recognition-feedback-admin-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.recognition-feedback-admin-copy strong { color: #172b46; font-size: 14px; }
.recognition-feedback-admin-copy span { margin-top: 3px; color: #405a78; font-size: 12px; font-weight: 750; }
.recognition-feedback-admin-copy small { margin-top: 5px; color: #7b8da5; font-size: 11px; }
.recognition-feedback-admin-status { padding: 6px 9px; border-radius: 999px; font-size: 11px; font-weight: 900; white-space: nowrap; }
.recognition-feedback-admin-status.is-success { background: #dcfce7; color: #047857; }
.recognition-feedback-admin-status.is-danger { background: #fee2e2; color: #b91c1c; }
.recognition-feedback-admin-status.is-pending { background: #fef3c7; color: #a16207; }
.recognition-feedback-admin-status.is-disabled { background: #e2e8f0; color: #475569; }
.recognition-feedback-admin-engines span { display: block; color: #607590; font-size: 11px; font-weight: 750; line-height: 1.6; }
.recognition-feedback-admin-actions { display: flex; justify-content: flex-end; gap: 6px; }
.recognition-feedback-admin-actions .is-danger { color: #b91c1c; border-color: #f3c6c8; }
.recognition-feedback-admin-empty { padding: 32px 18px; color: #71839c; text-align: center; font-size: 13px; font-weight: 750; }
.recognition-feedback-admin-empty.is-error { color: #b91c1c; }
@media (max-width: 1200px) {
  .recognition-feedback-admin-row { grid-template-columns: 58px minmax(0, 1fr) auto; }
  .recognition-feedback-admin-row > img { width: 58px; height: 58px; }
  .recognition-feedback-admin-engines { grid-column: 2 / 3; }
  .recognition-feedback-admin-actions { grid-column: 3 / 4; }
}

.front-search-clear-btn:hover {
  background: rgba(239, 246, 255, 0.98);
  border-color: rgba(37, 99, 235, 0.42);
}

.front-search-row {
  grid-template-columns: auto minmax(0, 1fr) 30px 42px 54px;
}

@media (max-width: 900px) {
  .front-search-row {
    grid-template-columns: 1fr 30px 42px 50px;
  }
}


/* final search align 20260706 */
.front-search-sticky {
  display: flex;
  justify-content: center;
  background: transparent !important;
  border-bottom: 0 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

.front-search-row {
  margin-inline: auto;
  grid-template-columns: auto minmax(0, 1fr) 42px 54px;
}

.front-search-row:has(.front-search-clear-btn.is-visible) {
  grid-template-columns: auto minmax(0, 1fr) 30px 42px 54px;
}

.front-search-clear-btn {
  display: none;
}

.front-search-clear-btn.is-visible {
  display: inline-flex;
}

@media (max-width: 900px) {
  .front-search-row {
    grid-template-columns: 1fr 42px 50px;
  }
  .front-search-row:has(.front-search-clear-btn.is-visible) {
    grid-template-columns: 1fr 30px 42px 50px;
  }
}


/* final search solid bg 20260706 */
.front-search-row {
  background: #ffffff !important;
  backdrop-filter: none !important;
}

.front-search-row .front-search-main,
.front-search-mode,
.front-search-icon-btn {
  background-color: #ffffff;
}


.image-search-float {
  position: fixed;
  right: 24px;
  top: 24px;
  bottom: auto;
  z-index: 220;
  width: 280px;
  height: auto;
  min-width: 136px;
  max-width: min(45vw, calc(100vw - 24px));
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 20px;
  background: #ffffff;
  box-shadow: 0 18px 46px rgba(15, 35, 80, 0.20);
  overflow: hidden;
  user-select: none;
  display: grid;
  grid-template-rows: 48px auto auto;
}

.image-search-float[hidden] {
  display: none;
}

.image-search-float.is-dragging,
.image-search-float.is-resizing {
  box-shadow: 0 22px 58px rgba(15, 35, 80, 0.26);
}

.image-search-float-head {
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 12px 0 16px;
  background: linear-gradient(135deg, #f6f9ff 0%, #edf6ff 100%);
  color: #17365d;
  cursor: grab;
  border-bottom: 1px solid rgba(37, 99, 235, 0.10);
}

.image-search-float.is-dragging .image-search-float-head,
.image-search-float.is-dragging .image-search-float-body {
  cursor: grabbing;
}

.image-search-float-head strong {
  font-size: 14px;
  font-weight: 900;
  letter-spacing: 0;
}

.image-search-float-close {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border: 1px solid rgba(37, 99, 235, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.image-search-float-close svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.image-search-float-close:hover {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff;
  transform: scale(1.03);
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.26);
}

.image-search-float-close:active {
  transform: scale(0.96);
}

.image-search-float-body {
  width: calc(var(--reference-image-box-width, 320px) + 24px);
  height: calc(var(--reference-image-box-height, 450px) + 24px);
  min-height: 0;
  max-height: calc(var(--reference-image-box-height, 450px) + 24px);
  box-sizing: border-box;
  padding: 12px;
  background: #f5f7fa;
  cursor: grab;
  display: flex;
  align-items: center;
  justify-content: center;
}

.image-search-float-body img,
.reference-image {
  display: block;
  width: var(--reference-image-width, auto);
  height: var(--reference-image-height, auto);
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-position: center;
  border-radius: 14px;
  background: #ffffff;
  -webkit-user-drag: none;
}

.image-search-lowres-hint {
  display: none;
  margin: 0;
  padding: 0 14px 10px;
  color: #8a5a0a;
  font-size: 12px;
  line-height: 1.35;
  background: #ffffff;
}

.image-search-float.is-lowres .image-search-lowres-hint {
  display: block;
}

.image-search-float.is-image-error .image-search-float-body {
  min-height: 160px;
}

.image-search-resize-handle {
  position: absolute;
  right: 4px;
  bottom: 4px;
  width: 26px;
  height: 26px;
  border: 0;
  border-radius: 0 0 16px 0;
  background: transparent;
  cursor: nwse-resize;
  color: rgba(37, 99, 235, 0.72);
}

.image-search-resize-handle::before,
.image-search-resize-handle::after {
  content: "";
  position: absolute;
  right: 6px;
  bottom: 7px;
  width: 13px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(135deg);
}

.image-search-resize-handle::after {
  right: 6px;
  bottom: 12px;
  width: 8px;
  opacity: 0.62;
}

.image-search-resize-handle:hover {
  color: #0ea5e9;
}

@media (max-width: 900px) {
  .image-search-float {
    right: 12px;
    top: 12px;
    max-width: calc(100vw - 24px);
  }
}


/* final search edge fix 20260706 */
.factory-card img {
  -webkit-user-drag: none;
}

.front-search-row {
  overflow: hidden;
  box-sizing: border-box;
  padding-left: 0 !important;
}

.front-search-mode {
  align-self: stretch;
  height: auto !important;
  min-height: 48px;
  padding-left: 20px !important;
  margin-left: 0 !important;
  border-radius: 22px 0 0 22px;
  background: #ffffff !important;
}

.front-search-row .front-search-main {
  background: #ffffff !important;
}


/* final image search and admin icon upload polish 20260706 */
#factoryDesc,
.image-search-message,
.image-search-clear {
  display: none !important;
}

#editorIconUpload {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 112px;
  white-space: nowrap;
  visibility: visible !important;
  opacity: 1 !important;
}

.icon-uploader-row {
  grid-template-columns: 72px max-content minmax(0, 1fr) !important;
}


/* final image search loading 20260706 */
.image-search-loading {
  grid-column: 1 / -1;
  min-height: 260px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 16px;
  color: #17365d;
  font-weight: 900;
}

.image-search-loading strong {
  font-size: 18px;
  letter-spacing: 0;
}

.image-search-loading span {
  position: relative;
  width: min(280px, 62vw);
  height: 6px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.12);
}

.image-search-loading span i {
  position: absolute;
  inset: 0 auto 0 0;
  width: 42%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb, #0ea5e9);
  animation: image-search-loading-slide 1.05s ease-in-out infinite;
}

@keyframes image-search-loading-slide {
  0% { transform: translateX(-110%); }
  100% { transform: translateX(250%); }
}


/* admin unified layout 20260706 */
body.admin-login-ready {
  min-height: 100vh;
  overflow-x: hidden;
}

.admin-shell.admin-layout-shell {
  width: min(100%, 1920px);
  max-width: none;
  margin: 0 auto;
  padding: 20px 24px;
  display: grid;
  grid-template-columns: 244px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
}

.admin-sidebar-shell {
  position: sticky;
  top: 20px;
  height: calc(100vh - 40px);
  min-height: 620px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 48px rgba(42, 92, 170, 0.10);
  backdrop-filter: blur(18px);
  padding: 18px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.admin-sidebar-brand {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding: 8px 4px 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.20);
}

.admin-sidebar-logo {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
  font-weight: 900;
  font-size: 20px;
  background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
  box-shadow: 0 10px 22px rgba(37, 99, 235, 0.22);
}

.admin-sidebar-brand strong,
.admin-user-meta strong {
  display: block;
  color: #13253d;
  font-size: 15px;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.admin-sidebar-brand span,
.admin-user-meta span {
  display: block;
  margin-top: 2px;
  color: #7b8ca8;
  font-size: 12px;
}

.admin-sidebar-nav {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 16px 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.30) transparent;
}

.admin-sidebar-section + .admin-sidebar-section {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
}

.admin-sidebar-section p {
  margin: 0 0 8px;
  padding: 0 10px;
  color: #70819e;
  font-size: 12px;
  font-weight: 800;
}

.admin-sidebar-item,
.admin-sidebar-front {
  width: 100%;
  height: 42px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: #41536e;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .18s ease, color .18s ease, box-shadow .18s ease;
}

.admin-sidebar-item svg,
.admin-sidebar-front svg,
.admin-page-header svg,
.admin-card-head svg,
.admin-user-avatar svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
  flex: 0 0 auto;
}

.admin-sidebar-item:hover,
.admin-sidebar-front:hover {
  background: rgba(37, 99, 235, 0.06);
  color: #2563eb;
}

.admin-sidebar-item.is-active {
  background: rgba(37, 99, 235, 0.11);
  color: #0969f2;
  box-shadow: inset 3px 0 0 #1e78ff;
}

.admin-sidebar-user {
  margin-top: auto;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) 34px;
  gap: 10px;
  align-items: center;
  padding: 12px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 16px;
  background: rgba(248, 251, 255, 0.78);
}

.admin-user-avatar {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #eff6ff;
  color: #2563eb;
}

.admin-user-logout {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(37, 99, 235, 0.16);
  border-radius: 10px;
  background: #fff;
  color: #56708f;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.admin-sidebar-front {
  margin-top: 10px;
  justify-content: center;
  border: 1px solid rgba(37, 99, 235, 0.16);
  background: rgba(255, 255, 255, 0.70);
}

.admin-main-shell {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.admin-main-shell > .admin-head {
  display: none !important;
}

.admin-page-header {
  min-height: 92px;
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.80);
  box-shadow: 0 18px 48px rgba(42, 92, 170, 0.10);
  backdrop-filter: blur(18px);
  padding: 22px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.admin-page-title-block h1 {
  margin: 0;
  color: #102033;
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: 0;
}

.admin-page-title-block p {
  margin: 8px 0 0;
  color: #60748f;
  font-size: 14px;
}

.admin-page-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.admin-save-state {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #64748b;
  font-size: 13px;
  white-space: nowrap;
}

.admin-save-state i {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #22c55e;
  box-shadow: 0 0 0 4px rgba(34, 197, 94, .12);
}

.admin-pages {
  min-width: 0;
}

.admin-page {
  display: none !important;
}

.admin-page.is-active {
  display: block !important;
}

.admin-page-sheets.is-active .workspace {
  display: grid;
  width: 100%;
  max-width: none;
  margin: 0;
}

.admin-settings-page {
  position: static !important;
  inset: auto !important;
  width: 100% !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
  color: inherit;
}

.admin-settings-page::backdrop {
  display: none;
}

.admin-settings-page > .modal-head {
  display: none !important;
}

.admin-settings-page > form,
.admin-settings-page > .category-manager-shell {
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 48px rgba(42, 92, 170, 0.10);
  backdrop-filter: blur(18px);
}

.admin-page-baidu > form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, .7fr);
  gap: 18px;
  padding: 20px;
}

.admin-page-baidu .baidu-config-note,
.admin-page-baidu .baidu-config-actions {
  grid-column: 1 / -1;
}

.admin-page-baidu .baidu-sync-panel {
  display: none !important;
}

.admin-page-site > form {
  padding: 22px;
}

.admin-page-categories > .category-manager-shell {
  width: 100%;
  height: min(720px, calc(100vh - 170px));
  max-width: none;
  display: grid;
  grid-template-columns: minmax(360px, .8fr) minmax(420px, 1fr);
}

.admin-content-card {
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 48px rgba(42, 92, 170, 0.10);
  backdrop-filter: blur(18px);
  padding: 22px;
  margin-bottom: 18px;
}

.admin-card-head {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  margin-bottom: 16px;
}

.admin-card-head > div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #102033;
}

.admin-card-head strong {
  font-size: 17px;
}

.admin-card-head p {
  margin: 0;
  color: #64748b;
  font-size: 13px;
}

.admin-card-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.shimo-sync-hero {
  position: relative;
  overflow: hidden;
}

.shimo-sync-hero::after {
  position: absolute;
  width: 260px;
  height: 260px;
  right: -110px;
  top: -140px;
  border-radius: 50%;
  content: "";
  pointer-events: none;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.14), transparent 68%);
}

.shimo-sync-status-row,
.shimo-sync-actions,
.shimo-sync-state {
  display: flex;
  align-items: center;
}

.shimo-sync-status-row {
  position: relative;
  z-index: 1;
  justify-content: space-between;
  gap: 20px;
}

.shimo-sync-actions {
  gap: 10px;
  flex-wrap: wrap;
}

.shimo-sync-state {
  gap: 12px;
  min-height: 52px;
}

.shimo-sync-state-dot {
  width: 12px;
  height: 12px;
  flex: 0 0 12px;
  border-radius: 50%;
  background: #64748b;
  box-shadow: 0 0 0 6px rgba(100, 116, 139, 0.12);
}

.shimo-sync-state > div {
  display: grid;
  gap: 2px;
}

.shimo-sync-state span {
  color: var(--muted);
  font-size: 12px;
}

.shimo-sync-state strong {
  color: var(--text);
  font-size: 17px;
}

.shimo-sync-state.is-success .shimo-sync-state-dot {
  background: #16a34a;
  box-shadow: 0 0 0 6px rgba(22, 163, 74, 0.12);
}

.shimo-sync-state.is-queued .shimo-sync-state-dot,
.shimo-sync-state.is-running .shimo-sync-state-dot {
  background: var(--blue);
  box-shadow: 0 0 0 6px rgba(37, 99, 235, 0.13);
}

.shimo-sync-state.is-failed .shimo-sync-state-dot {
  background: var(--danger);
  box-shadow: 0 0 0 6px rgba(225, 29, 72, 0.12);
}

.shimo-sync-actions button {
  min-height: 44px;
}

.shimo-sync-actions button svg[data-lucide="loader-circle"] {
  animation: shimo-sync-spin 900ms linear infinite;
}

.shimo-sync-notice {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-top: 18px;
  padding: 12px 14px;
  color: #334155;
  font-size: 13px;
  line-height: 1.6;
  border: 1px solid rgba(37, 99, 235, 0.15);
  border-radius: 14px;
  background: rgba(239, 246, 255, 0.78);
}

.shimo-sync-notice svg {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin-top: 1px;
  color: var(--blue);
}

.shimo-sync-grid {
  display: grid;
  grid-template-columns: minmax(320px, 0.72fr) minmax(520px, 1.28fr);
  gap: 18px;
}

.shimo-sync-grid .admin-content-card {
  margin-bottom: 0;
}

.shimo-sync-details {
  display: grid;
  gap: 0;
  margin: 0;
}

.shimo-sync-details > div {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 12px 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
}

.shimo-sync-details > div:last-child {
  border-bottom: 0;
}

.shimo-sync-details dt {
  color: var(--muted);
  font-size: 13px;
}

.shimo-sync-details dd {
  margin: 0;
  color: var(--text);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.shimo-sync-details a {
  color: var(--blue);
  text-decoration: none;
}

.shimo-sync-details a:hover {
  text-decoration: underline;
}

.shimo-sync-metrics {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.shimo-change-panel {
  margin-top: 18px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 16px;
  background: rgba(248, 250, 252, 0.72);
  overflow: hidden;
}

.shimo-change-head {
  min-height: 54px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.shimo-change-head strong,
.shimo-change-head span { display: block; }
.shimo-change-head strong { color: var(--text); font-size: 14px; }
.shimo-change-head span { margin-top: 2px; color: var(--muted); font-size: 12px; }
.shimo-change-list { max-height: 520px; overflow-y: auto; }
.shimo-change-table-head,
.shimo-change-row {
  display: grid;
  grid-template-columns: minmax(82px, .55fr) minmax(180px, 1.45fr) minmax(120px, .9fr) minmax(260px, 2fr);
  gap: 14px;
  align-items: center;
}
.shimo-change-table-head {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 9px 14px;
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  background: #f1f5f9;
}
.shimo-change-row {
  min-height: 68px;
  padding: 10px 14px;
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(255, 255, 255, 0.82);
}
.shimo-change-code { color: #0f172a; font-size: 14px; font-variant-numeric: tabular-nums; }
.shimo-change-name { min-width: 0; }
.shimo-change-name > span { display: block; color: #1e293b; font-size: 13px; line-height: 1.45; overflow-wrap: anywhere; }
.shimo-change-name > small { margin-top: 5px; display: flex; flex-wrap: wrap; gap: 5px; }
.shimo-change-category,
.shimo-change-description { color: #475569; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.shimo-change-description > span { display: block; }
.shimo-image-compare {
  display: grid;
  grid-template-columns: minmax(86px, 1fr) 22px minmax(86px, 1fr);
  gap: 8px;
  align-items: center;
  max-width: 300px;
  margin-top: 9px;
}
.shimo-image-compare figure { min-width: 0; margin: 0; }
.shimo-image-compare figcaption {
  margin-bottom: 4px;
  color: #64748b;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
}
.shimo-image-compare figure > div {
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 10px;
  background: #f8fafc;
}
.shimo-image-compare img { width: 100%; height: 100%; object-fit: cover; }
.shimo-image-arrow { display: grid; place-items: center; color: #2563eb; }
.shimo-image-arrow svg { width: 16px; height: 16px; }
.shimo-image-missing { padding: 6px; color: #94a3b8; font-size: 10px; line-height: 1.35; text-align: center; }
.shimo-change-tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  color: #334155;
  font-size: 11px;
  font-weight: 750;
  background: #e2e8f0;
}
.shimo-change-tag.is-added { color: #166534; background: #dcfce7; }
.shimo-change-tag.is-removed { color: #9f1239; background: #ffe4e6; }
.shimo-change-tag.is-image { color: #1d4ed8; background: #dbeafe; }
.shimo-change-tag.is-price { color: #9a3412; background: #ffedd5; }
.shimo-change-tag.is-name,
.shimo-change-tag.is-category { color: #6b21a8; background: #f3e8ff; }
.shimo-change-empty { padding: 28px 16px; color: #64748b; font-size: 13px; text-align: center; }

.material-sync-metrics {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.shimo-sync-error {
  margin-top: 14px;
  padding: 12px 14px;
  color: #9f1239;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre-wrap;
  border: 1px solid rgba(225, 29, 72, 0.18);
  border-radius: 14px;
  background: rgba(255, 241, 242, 0.9);
}

@keyframes shimo-sync-spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 1120px) {
  .shimo-sync-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .shimo-sync-status-row {
    align-items: stretch;
    flex-direction: column;
  }

  .shimo-sync-actions > button {
    flex: 1 1 180px;
  }

  .shimo-sync-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .shimo-change-table-head { display: none; }
  .shimo-change-list { max-height: none; }
  .shimo-change-row {
    grid-template-columns: minmax(70px, .45fr) minmax(0, 1.55fr);
    gap: 6px 12px;
    align-items: start;
    padding: 13px 14px;
  }
  .shimo-change-code { grid-row: 1 / span 3; }
  .shimo-change-category::before { content: "分类："; color: #94a3b8; }
  .shimo-change-description { color: #334155; }
  .shimo-image-compare { max-width: 250px; }
}

@media (prefers-reduced-motion: reduce) {
  .shimo-sync-actions button svg[data-lucide="loader-circle"] {
    animation: none;
  }
}

.front-initial-loading {
  grid-column: 1 / -1;
  display: grid;
  gap: 18px;
  min-height: 360px;
  padding: 18px 0 32px;
}

.front-initial-loading-head {
  display: grid;
  gap: 5px;
  color: #10213a;
}

.front-initial-loading-head strong {
  font-size: 18px;
}

.front-initial-loading-head span {
  color: #64748b;
  font-size: 13px;
}

.front-initial-loading-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
  align-items: start;
}

.front-initial-loading-grid i {
  display: block;
  aspect-ratio: 0.78;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 18px;
  background: linear-gradient(100deg, rgba(226, 232, 240, 0.65) 20%, rgba(248, 250, 252, 0.95) 42%, rgba(226, 232, 240, 0.65) 64%);
  background-size: 220% 100%;
  animation: front-initial-loading-shimmer 1.15s ease-in-out infinite;
}

.front-page .factory-card.is-archived {
  border-color: rgba(148, 163, 184, 0.38);
  background: rgba(248, 250, 252, 0.94);
}

.front-page .factory-card.is-archived .factory-image-frame img {
  filter: saturate(0.72);
}

.material-archived-badge {
  position: absolute;
  z-index: 3;
  top: 10px;
  left: 10px;
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  color: #9f1239;
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
  line-height: 1;
  border: 1px solid rgba(225, 29, 72, 0.2);
  border-radius: 999px;
  background: rgba(255, 241, 242, 0.94);
  box-shadow: 0 6px 16px rgba(159, 18, 57, 0.1);
}

@keyframes front-initial-loading-shimmer {
  to { background-position: -180% 0; }
}

@media (max-width: 900px) {
  .front-initial-loading-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .front-initial-loading-grid i:nth-child(n + 5) {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .front-initial-loading-grid i {
    animation: none;
  }
}

.admin-status-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.admin-status-grid > div {
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 16px;
  background: #f8fbff;
  padding: 16px;
}

.admin-status-grid span,
.admin-account-card span {
  display: block;
  color: #64748b;
  font-size: 12px;
}

.admin-status-grid strong {
  display: block;
  margin-top: 6px;
  color: #102033;
  font-size: 20px;
}

.admin-account-card {
  display: flex;
  align-items: center;
  gap: 14px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 16px;
  background: #f8fbff;
  padding: 16px;
  margin-bottom: 16px;
}

body[data-admin-page="importExport"] .admin-page-header,
body[data-admin-page="sync"] .admin-page-header,
body[data-admin-page="accounts"] .admin-page-header,
body[data-admin-page="site"] .admin-page-header,
body[data-admin-page="baidu"] .admin-page-header,
body[data-admin-page="categories"] .admin-page-header,
body[data-admin-page="sheets"] .admin-page-header,
body[data-admin-page="new"] .admin-page-header {
  display: flex;
}

@media (max-width: 1360px) {
  .admin-shell.admin-layout-shell {
    grid-template-columns: 224px minmax(0, 1fr);
    gap: 18px;
    padding: 16px 20px;
  }
  .admin-page-baidu > form {
    grid-template-columns: 1fr;
  }
  .admin-page-categories > .category-manager-shell {
    grid-template-columns: minmax(310px, .9fr) minmax(380px, 1fr);
  }
}

@media (max-width: 1040px) {
  .admin-shell.admin-layout-shell {
    grid-template-columns: 1fr;
  }
  .admin-sidebar-shell {
    position: static;
    height: auto;
    min-height: 0;
  }
  .admin-sidebar-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    overflow: visible;
  }
  .admin-page-header {
    align-items: flex-start;
    flex-direction: column;
  }
  .admin-page-categories > .category-manager-shell {
    grid-template-columns: 1fr;
    height: auto;
  }
}


/* admin layout width guard 20260706 */
.admin-layout-shell *,
.admin-layout-shell *::before,
.admin-layout-shell *::after {
  box-sizing: border-box;
}

.admin-settings-page input,
.admin-settings-page select,
.admin-settings-page textarea,
.admin-page input,
.admin-page select,
.admin-page textarea {
  max-width: 100%;
  min-width: 0;
}

.admin-page-categories .category-editor-form,
.admin-page-categories .category-editor-form label,
.admin-page-categories .category-editor-form .form-row,
.admin-page-categories .parent-category-row {
  min-width: 0;
  max-width: 100%;
}

.admin-page-categories .category-editor-panel,
.admin-page-categories .category-list-panel {
  min-width: 0;
}


/* admin switch width fix 20260706 */
.admin-layout-shell .status-switch input[type="checkbox"] {
  width: 42px !important;
  min-width: 42px !important;
  max-width: 42px !important;
  justify-self: end;
}


/* admin baidu settings card polish 20260706 */
.admin-page-baidu .baidu-config-note,
.admin-page-baidu .baidu-sync-panel,
.admin-page-baidu label,
.admin-page-baidu .baidu-config-actions {
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  padding: 16px;
}

.admin-page-baidu .baidu-config-note {
  background: #eef5ff;
}

.admin-page-baidu .baidu-sync-panel {
  display: block !important;
  grid-column: 1 / -1;
  margin: 0;
}

.admin-page-baidu .baidu-config-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-page-baidu .baidu-config-switch {
  min-height: 92px;
}


/* admin baidu dashboard sections 20260706 */
.admin-page-baidu > form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(360px, .9fr);
  gap: 18px;
  padding: 0;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.admin-config-card {
  min-width: 0;
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 48px rgba(42, 92, 170, 0.10);
  backdrop-filter: blur(18px);
  padding: 18px;
}

.admin-config-card-wide {
  grid-column: 1 / -1;
}

.admin-config-grid {
  display: grid;
  gap: 14px;
}

.admin-config-grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.baidu-api-card .baidu-config-note,
.baidu-api-card .baidu-config-actions {
  grid-column: 1 / -1;
}

.baidu-api-status-grid,
.baidu-sync-stat-grid,
.admin-readonly-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.baidu-sync-stat-grid {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.admin-readonly-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 0;
}

.admin-readonly-grid-compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.baidu-api-status-grid > div,
.baidu-sync-stat-grid > div,
.admin-readonly-grid > div {
  min-width: 0;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 16px;
  background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
  padding: 14px;
}

.baidu-api-status-grid span,
.baidu-sync-stat-grid span,
.admin-readonly-grid span {
  display: block;
  color: #71829d;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 7px;
}

.baidu-api-status-grid strong,
.baidu-sync-stat-grid strong,
.admin-readonly-grid strong {
  display: block;
  color: #102033;
  font-size: 14px;
  line-height: 1.4;
  word-break: break-word;
}

.baidu-api-status-grid strong.is-error {
  color: #dc2626;
}

.baidu-float-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 180px;
  gap: 14px;
  align-items: start;
}

.baidu-float-card .admin-card-head {
  grid-column: 1 / -1;
}

.baidu-float-preview {
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 18px;
  background: #f5f8fc;
  padding: 12px;
}

.baidu-float-preview > div {
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 16px;
  background: #fff;
  padding: 10px;
  box-shadow: 0 10px 24px rgba(15, 35, 80, 0.08);
}

.baidu-float-preview span {
  display: block;
  color: #17365d;
  font-size: 12px;
  font-weight: 900;
  margin-bottom: 8px;
}

.baidu-float-preview img {
  display: block;
  width: 100%;
  max-height: 150px;
  object-fit: contain;
}

.admin-page-baidu .baidu-sync-panel {
  margin-top: 16px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 18px;
  background: #f8fbff;
}

@media (max-width: 1360px) {
  .admin-config-grid-2,
  .baidu-api-status-grid,
  .baidu-sync-stat-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .baidu-float-card {
    grid-template-columns: 1fr;
  }
  .baidu-float-preview {
    max-width: 260px;
  }
}

@media (max-width: 900px) {
  .admin-page-baidu > form,
  .admin-readonly-grid,
  .admin-config-grid-2,
  .baidu-api-status-grid,
  .baidu-sync-stat-grid {
    grid-template-columns: 1fr;
  }
}


/* admin site settings sections 20260706 */
.admin-page-site > form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  padding: 0;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
}

.site-base-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 18px;
  align-items: start;
}

.site-base-card .admin-card-head {
  grid-column: 1 / -1;
}

.site-base-card .admin-config-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.site-save-actions {
  grid-column: 1 / -1;
}

.site-logo-field {
  grid-column: 1 / -1;
}

.site-logo-upload-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.site-logo-upload-row button {
  min-height: 38px;
  padding: 0 14px;
}

.site-logo-upload-row > span {
  flex: 1 1 280px;
  color: #71829d;
  font-size: 12px;
  font-weight: 700;
}

.site-logo-upload-row > span.is-success {
  color: #047857;
}

.site-logo-upload-row > span.is-error {
  color: #dc2626;
}

.site-logo-clear {
  color: #64748b;
}

.site-preview-card {
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 18px;
  background: linear-gradient(180deg, #f8fbff 0%, #ffffff 100%);
  padding: 16px;
}

.site-preview-card > span {
  display: block;
  color: #71829d;
  font-size: 12px;
  font-weight: 800;
  margin-bottom: 12px;
}

.site-preview-card > div {
  display: grid;
  grid-template-columns: 50px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.site-preview-card b {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, #2563eb 0%, #0ea5e9 100%);
  font-size: 20px;
}

.site-preview-card b.has-logo {
  overflow: hidden;
  padding: 3px;
  background: rgba(255, 255, 255, 0.72);
}

.site-preview-card b.has-logo img {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 11px;
  object-fit: contain;
}

.site-preview-card strong,
.site-preview-card em {
  grid-column: 2;
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.site-preview-card strong {
  color: #102033;
  font-style: normal;
  font-size: 16px;
}

.site-preview-card em {
  margin-top: -14px;
  color: #71829d;
  font-size: 12px;
  font-style: normal;
}

@media (max-width: 1360px) {
  .admin-page-site > form,
  .site-base-card,
  .site-base-card .admin-config-grid {
    grid-template-columns: 1fr;
  }
  .site-preview-card {
    max-width: 360px;
  }
}


/* admin import export cards 20260706 */
.admin-page-import-export {
  display: none;
}

.admin-page-import-export.is-active {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.admin-import-layout {
  display: grid;
  gap: 16px;
}

.admin-page-import-export .admin-readonly-grid,
.admin-page-import-export .admin-status-grid {
  margin: 0;
}

.admin-export-status {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 1360px) {
  .admin-page-import-export.is-active {
    grid-template-columns: 1fr;
  }
}


/* admin sheets and category search polish 20260706 */
.admin-page-sheets.is-active .workspace {
  grid-template-columns: 204px minmax(0, 1fr);
  gap: 18px;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  padding: 0 !important;
  max-width: 100%;
  overflow-x: clip;
}

body[data-admin-page="sheets"] {
  overflow-x: hidden;
}

body[data-admin-page="sheets"] .admin-head {
  display: none !important;
}

.admin-shell:has(.admin-page-sheets.is-active) > .admin-head {
  display: none !important;
}

.admin-page-sheets.is-active .admin-page-header {
  display: none !important;
}

body[data-admin-page="sheets"] .admin-page-header {
  display: none !important;
}

.admin-page-sheets.is-active .workspace.sheet-filter-collapsed {
  grid-template-columns: 56px minmax(0, 1fr);
}

.admin-inner-card,
.admin-page-sheets .side-rail,
.admin-page-sheets .editor-panel,
.admin-page-sheets .list-card {
  border: 1px solid rgba(148, 163, 184, 0.20) !important;
  border-radius: 22px !important;
  background: rgba(255, 255, 255, 0.88) !important;
  box-shadow: 0 18px 48px rgba(42, 92, 170, 0.10) !important;
  backdrop-filter: blur(18px);
}

.admin-page-sheets .side-rail {
  height: calc(100vh - 158px);
  position: sticky;
  top: 132px;
  overflow: hidden;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto;
  transition: width .18s ease, padding .18s ease;
}

.admin-page-sheets .side-rail.is-collapsed {
  padding-left: 8px !important;
  padding-right: 8px !important;
}

.admin-page-sheets .side-rail.is-collapsed .admin-inner-card-head,
.admin-page-sheets .side-rail.is-collapsed .side-title,
.admin-page-sheets .side-rail.is-collapsed .sheet-filter-rail-search,
.admin-page-sheets .side-rail.is-collapsed .filter-list {
  opacity: 0;
  pointer-events: none;
}

.admin-page-sheets .main-area {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.admin-page-sheets .sheet-form-drawer {
  position: fixed !important;
  top: 0;
  right: 0;
  z-index: 130;
  width: min(420px, 36vw);
  max-width: 460px;
  min-width: 360px;
  height: 100vh;
  margin: 0 !important;
  border-radius: 22px 0 0 22px !important;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateX(calc(100% + 28px));
  opacity: 0;
  pointer-events: none;
  transition: transform .22s ease, opacity .18s ease, box-shadow .22s ease;
}

.admin-page-sheets .sheet-form-drawer.is-open {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
  box-shadow: -24px 0 60px rgba(15, 35, 80, .18) !important;
}

.admin-page-sheets .sheet-form-drawer .sheet-drawer-head {
  margin: 0;
  padding: 22px 22px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(148, 163, 184, .16);
  background: rgba(255, 255, 255, .94);
}

.admin-page-sheets .sheet-form-drawer .sheet-drawer-head > div {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.admin-page-sheets .sheet-form-drawer .sheet-drawer-head span {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.admin-page-sheets .sheet-form-drawer .sheet-drawer-head em {
  max-width: 280px;
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
  font-weight: 750;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-page-sheets .sheet-form-drawer .panel-title {
  flex: 0 0 auto;
  margin: 0;
  padding: 10px 22px 0;
  border-bottom: 0;
  min-height: auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.admin-page-sheets .sheet-form-drawer .panel-title strong {
  display: none;
}

.admin-page-sheets .sheet-form-drawer .panel-title #saveMessage {
  display: none;
}

.admin-page-sheets .sheet-form-drawer .admin-form {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  display: grid;
  grid-template-columns: 1fr;
  align-content: start;
  gap: 18px;
  padding: 18px 22px 104px;
}

.admin-page-sheets .sheet-form-drawer .admin-form label,
.admin-page-sheets .sheet-form-drawer .admin-form .form-field {
  grid-column: 1 / -1;
  gap: 8px;
}

.admin-page-sheets .sheet-form-drawer .admin-form label > span,
.admin-page-sheets .sheet-form-drawer .admin-form .form-field > span {
  color: #334b66;
  font-size: 13px;
  font-weight: 900;
}

.admin-page-sheets .sheet-form-drawer .admin-form input,
.admin-page-sheets .sheet-form-drawer .admin-form select,
.admin-page-sheets .sheet-form-drawer .admin-form textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid rgba(37, 99, 235, .14);
  border-radius: 13px;
  background: #fff;
  box-shadow: 0 10px 22px rgba(47, 83, 117, .05);
}

.admin-page-sheets .sheet-form-drawer .image-editor-field {
  padding-top: 2px;
}

.admin-page-sheets .sheet-form-drawer .upload-row {
  display: grid;
  grid-template-columns: 1fr;
}

.admin-page-sheets .sheet-form-drawer #uploadImageBtn {
  width: 100%;
  min-height: 46px;
  justify-content: center;
  border-style: dashed;
}

.admin-page-sheets .sheet-form-drawer .upload-preview {
  width: 100%;
  grid-template-columns: 86px minmax(0, 1fr);
  border-radius: 16px;
  background: #f8fbff;
}

.admin-page-sheets .sheet-form-drawer .upload-preview img {
  width: 86px;
  height: 86px;
}

.admin-page-sheets .sheet-form-drawer .form-row.wide {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 3;
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin: 0;
  padding: 16px 22px;
  background: rgba(255,255,255,.98);
  border-top: 1px solid rgba(148, 163, 184, .18);
  backdrop-filter: blur(12px);
}

.admin-page-sheets .sheet-form-drawer .form-row.wide .save-progress {
  grid-column: 1 / -1;
}

.admin-page-sheets .sheet-form-drawer .form-row.wide .primary-action,
.admin-page-sheets .sheet-form-drawer .form-row.wide .ghost-action {
  min-height: 44px;
  justify-content: center;
}

.admin-page-sheets .sheet-drawer-open::after {
  display: none;
}

.admin-inner-card-head,
.admin-sheet-card-kicker {
  padding-bottom: 14px;
  margin-bottom: 14px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.admin-inner-card-head > div,
.admin-sheet-card-kicker > div {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #102033;
}

.admin-inner-card-head strong,
.admin-sheet-card-kicker strong {
  font-size: 16px;
  font-weight: 900;
}

.admin-inner-card-head p,
.admin-sheet-card-kicker p {
  margin: 6px 0 0;
  color: #64748b;
  font-size: 12px;
  line-height: 1.45;
}

.admin-page-sheets .side-rail .admin-inner-card-head p,
.admin-page-sheets .list-card > .admin-sheet-card-kicker {
  display: none;
}

.admin-page-sheets .side-rail .admin-inner-card-head {
  margin-bottom: 12px;
  padding-bottom: 12px;
}

.admin-inner-card-head svg,
.admin-sheet-card-kicker svg,
.category-tree-search svg {
  width: 18px;
  height: 18px;
  stroke: currentColor;
  stroke-width: 2;
  fill: none;
}

.admin-page-sheets .filter-list {
  overflow-y: auto;
  max-height: none;
  min-height: 0;
  padding-right: 4px;
}

.admin-page-sheets .side-section {
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
}

.sheet-filter-rail-search {
  height: 38px;
  margin: 0 0 12px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 13px;
  background: #f8fbff;
  color: #60748f;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
}

.sheet-filter-rail-search:focus-within {
  background: #fff;
  border-color: rgba(37, 99, 235, 0.5);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10);
}

.sheet-filter-rail-search svg {
  width: 16px;
  height: 16px;
}

.sheet-filter-rail-search input {
  width: 100%;
  min-width: 0;
  border: 0 !important;
  outline: 0;
  background: transparent !important;
  box-shadow: none !important;
  padding: 0 !important;
  font-size: 13px;
  color: #102033;
}

.admin-page-sheets .sheet-filter-rail-search {
  width: 100% !important;
  min-width: 0 !important;
  height: 40px !important;
  margin: 0 0 12px !important;
  padding: 0 10px !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
}

.admin-page-sheets .sheet-filter-rail-search svg {
  flex: 0 0 16px !important;
  width: 16px !important;
  height: 16px !important;
}

.admin-page-sheets .sheet-filter-rail-search input {
  flex: 1 1 auto !important;
  width: auto !important;
  min-width: 0 !important;
  height: 38px !important;
  line-height: 38px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.sheet-filter-rail-footer {
  padding-top: 12px;
  border-top: 1px solid rgba(148, 163, 184, .16);
}

.sheet-filter-rail-footer .ghost-action {
  width: 100%;
  justify-content: center;
}

.admin-page-sheets .editor-panel,
.admin-page-sheets .list-card {
  padding: 20px !important;
}

.admin-page-sheets .list-card {
  display: grid;
  gap: 12px;
}

.admin-page-sheets .list-panel-title {
  margin: 0;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(148, 163, 184, .14);
}

.admin-page-sheets .list-panel-title strong {
  font-size: 20px;
  letter-spacing: 0;
}

.admin-page-sheets .sheet-batch-bar[hidden] {
  display: none !important;
}

.admin-page-sheets .factory-admin-grid {
  --sheet-list-columns: 34px minmax(220px, 1.8fr) minmax(90px, .8fr) 64px 56px 84px 120px 116px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  min-width: 0;
}

.admin-page-sheets .list-card,
.admin-page-sheets .admin-sheet-list-card {
  min-width: 0;
  max-width: 100%;
}

.admin-page-sheets .sheet-list-header {
  display: grid;
  grid-template-columns: var(--sheet-list-columns);
  gap: 12px;
  align-items: center;
  padding: 0 12px 2px;
  color: #70819a;
  font-size: 12px;
  font-weight: 900;
}

.admin-page-sheets .admin-factory-card {
  min-height: 78px;
  display: grid;
  grid-template-columns: var(--sheet-list-columns);
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 14px;
}

@media (max-width: 1440px) {
  .admin-page-sheets .factory-admin-grid {
    --sheet-list-columns: 30px minmax(150px, 1.4fr) 72px 52px 44px 68px 92px 92px;
  }

  .admin-page-sheets .sheet-list-header,
  .admin-page-sheets .admin-factory-card {
    gap: 8px;
    padding-left: 10px;
    padding-right: 10px;
  }

  .admin-page-sheets .admin-factory-card .card-actions {
    gap: 6px;
  }

  .admin-page-sheets .admin-factory-card .card-actions > button,
  .admin-page-sheets .sheet-row-more summary {
    min-height: 32px;
    padding-inline: 9px;
    font-size: 12px;
  }
}

.admin-page-sheets .sheet-card-select {
  position: relative !important;
  width: 28px;
  height: 28px;
}

.admin-page-sheets .sheet-card-select input {
  position: absolute !important;
  inset: 0 !important;
}

.admin-page-sheets .admin-factory-card .factory-image.small,
.admin-page-sheets .admin-factory-card .factory-image-frame {
  width: 62px;
  height: 48px;
  min-height: 48px;
  border-radius: 12px;
}

.admin-page-sheets .admin-factory-card .factory-image-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.admin-page-sheets .admin-factory-main {
  min-width: 0;
  display: block;
}

.admin-page-sheets .sheet-info-line {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.admin-page-sheets .sheet-info-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.admin-page-sheets .sheet-info-copy strong,
.admin-page-sheets .sheet-info-copy span,
.admin-page-sheets .sheet-row-cell strong,
.admin-page-sheets .sheet-row-cell span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-page-sheets .sheet-info-copy strong {
  font-size: 14px;
  color: #10213a;
  font-weight: 900;
}

.admin-page-sheets .sheet-info-copy span,
.admin-page-sheets .sheet-row-cell span {
  color: #64748b;
  font-size: 12px;
  font-weight: 750;
}

.admin-page-sheets .sheet-info-copy b {
  color: #2563eb;
  font-weight: 900;
}

.admin-page-sheets .sheet-row-cell {
  min-width: 0;
  display: grid;
  gap: 2px;
  color: #10213a;
  font-size: 13px;
  font-weight: 850;
}

.admin-page-sheets .sheet-category-cell strong {
  color: #17365d;
}

.admin-page-sheets .sheet-status-stack {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 5px;
  overflow: hidden;
}

.admin-page-sheets .sheet-status-pill {
  min-height: 24px;
  max-width: 100%;
  padding: 0 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  color: #64748b;
  background: #f1f5f9;
  font-size: 12px;
  font-weight: 900;
}

.admin-page-sheets .sheet-status-pill.is-ok { color: #14845d; background: #e9f8f1; }
.admin-page-sheets .sheet-status-pill.is-info { color: #2563eb; background: #eef5ff; }
.admin-page-sheets .sheet-status-pill.is-danger { color: #dc2626; background: #fff1f2; }
.admin-page-sheets .sheet-status-pill.is-warn { color: #b45309; background: #fff7ed; }
.admin-page-sheets .sheet-status-pill.is-muted { color: #64748b; background: #f1f5f9; }

@media (max-width: 1440px) {
  .admin-page-sheets .sheet-status-stack .sheet-status-pill:nth-child(n+2) {
    display: none;
  }
}

.admin-page-sheets .admin-factory-card .card-actions > button {
  min-height: 34px;
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 999px;
  background: #fff;
  color: #2563eb;
  padding: 0 12px;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.admin-page-sheets .admin-factory-card .card-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  position: relative;
}

.admin-page-sheets .sheet-row-more {
  position: relative;
}

.admin-page-sheets .sheet-row-more summary {
  list-style: none;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 999px;
  background: #fff;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.admin-page-sheets .sheet-row-more summary::-webkit-details-marker {
  display: none;
}

.admin-page-sheets .sheet-row-more summary svg {
  width: 16px;
  height: 16px;
}

.admin-page-sheets .sheet-row-more > div {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 20;
  min-width: 176px;
  padding: 8px;
  border: 1px solid rgba(148, 163, 184, .22);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 16px 40px rgba(15, 35, 80, .18);
}

.admin-page-sheets .sheet-row-more button {
  width: 100%;
  min-height: 34px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #263b5c;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  padding: 0 10px;
  font-size: 13px;
  font-weight: 850;
  cursor: pointer;
}

.admin-page-sheets.is-active .factory-admin-grid {
  --sheet-list-columns: 30px minmax(150px, 1.4fr) 72px 52px 44px 68px 92px 92px;
}

.admin-page-sheets.is-active .admin-factory-card {
  min-height: 78px !important;
  display: grid !important;
  grid-template-columns: var(--sheet-list-columns) !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 8px 10px !important;
}

.admin-page-sheets.is-active .admin-factory-card .admin-factory-main {
  min-width: 0 !important;
  display: block !important;
  padding: 0 !important;
  gap: 0 !important;
}

.admin-page-sheets.is-active .admin-factory-card .factory-image.small,
.admin-page-sheets.is-active .admin-factory-card .factory-image-frame {
  width: 62px !important;
  height: 48px !important;
  min-height: 48px !important;
}

.admin-page-sheets.is-active .admin-factory-card .sheet-info-line {
  display: grid !important;
  grid-template-columns: 62px minmax(0, 1fr) !important;
  gap: 10px !important;
  align-items: center !important;
}

.admin-page-sheets.is-active .admin-factory-card .card-actions {
  height: 34px !important;
  min-height: 34px !important;
  display: inline-flex !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 6px !important;
}

.admin-page-sheets.is-active .admin-factory-card .card-actions > button,
.admin-page-sheets.is-active .sheet-row-more summary {
  height: 32px !important;
  min-height: 32px !important;
  padding: 0 10px !important;
  font-size: 12px !important;
  white-space: nowrap !important;
}

.admin-page-sheets .sheet-row-more button:hover {
  color: #2563eb;
  background: #f3f7ff;
}

.admin-page-sheets .sheet-row-more .danger-btn {
  color: #dc2626;
  box-shadow: none;
  border-top: 1px solid rgba(220,38,38,.12);
  margin-top: 4px;
  padding-top: 4px;
  background: transparent;
}

.admin-page-sheets .sheet-list-pagination {
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid rgba(148, 163, 184, .16);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  color: #64748b;
  font-size: 13px;
  font-weight: 800;
}

.admin-page-sheets .sheet-list-pagination label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.admin-page-sheets .sheet-list-pagination select,
.admin-page-sheets .sheet-page-jump input {
  min-height: 34px;
  border: 1px solid rgba(148, 163, 184, .24);
  border-radius: 10px;
  background: #fff;
  color: #263b5c;
  font-weight: 800;
}

.admin-page-sheets .sheet-page-jump input {
  width: 64px;
  padding: 0 8px;
}

.admin-page-sheets .sheet-page-numbers {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.admin-page-sheets .sheet-page-number {
  min-width: 34px;
  height: 34px;
  border: 1px solid rgba(37,99,235,.16);
  border-radius: 999px;
  background: #fff;
  color: #2563eb;
  font-size: 13px;
  font-weight: 900;
  cursor: pointer;
}

.admin-page-sheets .sheet-page-number.is-active {
  background: #2563eb;
  color: #fff;
  border-color: #2563eb;
}

.admin-page-sheets .admin-list-state-card {
  grid-template-columns: 1fr;
  min-height: 96px;
  align-items: center;
}

.category-tree-search {
  height: 42px;
  margin: 0 16px 12px;
  border: 1px solid rgba(148, 163, 184, 0.24);
  border-radius: 14px;
  background: #f8fbff;
  color: #60748f;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
}

.category-tree-search:focus-within {
  border-color: rgba(37, 99, 235, 0.55);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10);
  background: #fff;
}

.category-tree-search input {
  border: 0 !important;
  outline: 0;
  background: transparent !important;
  box-shadow: none !important;
  height: 38px;
  padding: 0 !important;
  font-size: 13px;
  color: #102033;
}

.category-tree-row[hidden] {
  display: none !important;
}

.category-tree.is-filtering {
  padding-top: 4px;
}

@media (max-width: 1360px) {
  .admin-page-sheets.is-active .workspace {
    grid-template-columns: 192px minmax(0, 1fr);
  }
  .admin-page-sheets.is-active .workspace.sheet-filter-collapsed {
    grid-template-columns: 56px minmax(0, 1fr);
  }
}

@media (max-width: 1040px) {
  .admin-page-sheets.is-active .workspace {
    grid-template-columns: 1fr;
  }
  .admin-page-sheets .side-rail {
    position: static;
    height: auto;
  }
  .admin-page-sheets .filter-list {
    max-height: 360px;
  }
  .admin-page-sheets .sheet-form-drawer {
    width: min(92vw, 420px);
    min-width: 0;
  }
}


/* admin truthful empty states 20260706 */
.admin-empty-feature-card {
  min-height: 280px;
}

.admin-empty-state {
  margin-top: 22px;
  min-height: 168px;
  border: 1px dashed rgba(37, 99, 235, 0.24);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(248, 251, 255, 0.94), rgba(239, 247, 255, 0.72));
  display: grid;
  place-items: center;
  gap: 8px;
  padding: 28px;
  text-align: center;
  color: #48627f;
}

.admin-empty-state strong {
  color: #17365d;
  font-size: 17px;
  font-weight: 950;
}

.admin-empty-state span {
  max-width: 680px;
  color: #6d819a;
  font-size: 13px;
  line-height: 1.7;
}


/* admin import report 20260706 */
.admin-import-report {
  margin-top: 14px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 14px;
  background: rgba(239, 247, 255, 0.82);
  padding: 12px 14px;
  color: #35506c;
  font-size: 13px;
  line-height: 1.6;
}

.admin-import-report[hidden] {
  display: none;
}


/* admin sheet advanced filters 20260707 */
.sheet-advanced-filters {
  position: sticky;
  top: 84px;
  z-index: 20;
  margin: 0 0 6px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  display: grid;
  gap: 10px;
}

.sheet-filter-head {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) minmax(270px, auto) auto;
  align-items: center;
  gap: 12px;
  min-height: 46px;
}

.sheet-filter-head > div:first-child {
  display: none;
  align-items: center;
  gap: 8px;
  color: #17365d;
  font-weight: 950;
}

.sheet-filter-head-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.sheet-quick-filters {
  min-width: 0;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.sheet-quick-filters label {
  min-width: 86px;
  display: grid;
  gap: 4px;
}

.sheet-quick-filters span {
  color: #64748b;
  font-size: 11px;
  font-weight: 850;
  line-height: 1;
}

.sheet-quick-filters select {
  width: 100%;
  height: 34px;
  min-height: 34px;
  border: 1px solid rgba(37, 99, 235, .14);
  border-radius: 10px;
  padding: 0 10px;
  color: #17365d;
  background: #fff;
  outline: none;
  box-shadow: 0 8px 18px rgba(47, 83, 117, .05);
}

.sheet-main-search-field {
  min-height: 42px;
  padding: 5px 12px;
  border-radius: 14px;
  background: #fff;
  border-color: rgba(37, 99, 235, .16);
}

.sheet-filter-head .sheet-main-search-field {
  width: 100%;
  max-width: 460px;
  justify-self: stretch;
}

@media (max-width: 1500px) {
  .sheet-filter-head {
    grid-template-columns: minmax(210px, 1fr) minmax(250px, auto) auto;
    gap: 10px;
  }

  .sheet-quick-filters label {
    min-width: 78px;
  }

  .sheet-filter-head-actions .ghost-action.compact {
    padding-inline: 10px;
  }
}

.sheet-filter-head em {
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  background: #eaf2ff;
  color: #2563eb;
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.sheet-filter-head .ghost-action.is-active {
  color: #2563eb;
  border-color: rgba(37, 99, 235, .32);
  background: #eef5ff;
}

.sheet-filter-head i,
.sheet-filter-head svg {
  width: 17px;
  height: 17px;
  color: #2563eb;
}

.ghost-action.compact {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 13px;
}

.sheet-filter-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(130px, 1fr));
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(37, 99, 235, .12);
  border-radius: 14px;
  background: rgba(248, 251, 255, .88);
}

.sheet-filter-grid[hidden] {
  display: none !important;
}

.sheet-filter-grid label {
  display: grid;
  gap: 6px;
}

.sheet-filter-grid span {
  color: #66788f;
  font-size: 12px;
  font-weight: 850;
}

.sheet-filter-grid select {
  width: 100%;
  height: 40px;
  border: 1px solid rgba(37, 99, 235, 0.13);
  border-radius: 12px;
  padding: 0 12px;
  color: #17365d;
  background: #fff;
  outline: none;
}

.sheet-filter-grid select:focus {
  border-color: rgba(37, 99, 235, 0.5);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}

@media (max-width: 1500px) {
  .sheet-filter-grid {
    grid-template-columns: repeat(3, minmax(140px, 1fr));
  }
}

@media (max-width: 900px) {
  .sheet-filter-grid {
    grid-template-columns: 1fr;
  }
}


/* admin sheet batch actions 20260707 */
.sheet-batch-bar {
  position: sticky;
  top: 142px;
  z-index: 19;
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid rgba(37, 99, 235, .16);
  border-radius: 12px;
  background: rgba(238, 246, 255, .96);
  box-shadow: 0 10px 24px rgba(37, 99, 235, .08);
  overflow-x: auto;
  scrollbar-width: none;
}
.sheet-batch-bar::-webkit-scrollbar { display: none; }
.sheet-batch-bar > span { flex: 0 0 auto; min-height: 32px; display: inline-flex; align-items: center; padding: 0 12px; border-radius: 999px; background: rgba(37, 99, 235, 0.08); color: #2563eb; font-size: 13px; font-weight: 900; }
.sheet-batch-bar .ghost-action.compact,
.sheet-batch-bar .primary-action.compact,
.sheet-batch-bar .danger-btn.compact {
  flex: 0 0 auto;
  min-height: 32px;
  height: 32px;
  padding: 0 11px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}
.sheet-batch-bar .danger-btn.compact {
  color: #dc2626;
  background: #fff;
  border: 1px solid rgba(220, 38, 38, .26);
  box-shadow: none;
}
.primary-action.compact { min-height: 34px; padding: 0 12px; border-radius: 999px; font-size: 13px; }
.sheet-card-select { position: absolute; top: 12px; left: 12px; z-index: 3; width: 28px; height: 28px; cursor: pointer; }
.sheet-card-select input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.sheet-card-select span { width: 28px; height: 28px; border-radius: 10px; display: grid; place-items: center; border: 1px solid rgba(37, 99, 235, 0.28); background: rgba(255, 255, 255, 0.92); box-shadow: 0 8px 18px rgba(47, 83, 117, 0.14); }
.sheet-card-select span::after { content: ""; width: 10px; height: 6px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translateY(-1px); opacity: 0; }
.sheet-card-select input:checked + span { border-color: #2563eb; background: linear-gradient(135deg, #2563eb, #0ea5e9); }
.sheet-card-select input:checked + span::after { opacity: 1; }
.admin-factory-card { position: relative; }
.admin-factory-card.is-selected { border-color: rgba(37, 99, 235, 0.55); box-shadow: 0 16px 36px rgba(37, 99, 235, 0.14); }

.bulk-sheet-category-dialog {
  width: min(420px, calc(100vw - 32px));
  border: 0;
  padding: 0;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 28px 90px rgba(15, 35, 80, .28);
}

/* sheet management reference alignment 20260708 */
.admin-page-sheets.is-active .workspace,
.admin-page-sheets.is-active .workspace.sheet-management-layout,
.admin-page-sheets.is-active .sheet-management-body {
  display: grid !important;
  grid-template-columns: 260px minmax(0, 1fr) !important;
  gap: 16px !important;
  align-items: start !important;
  max-width: 100% !important;
  overflow-x: clip !important;
}

.admin-page-sheets.is-active .workspace.sheet-filter-collapsed {
  grid-template-columns: 48px minmax(0, 1fr) !important;
}

.admin-page-sheets .side-rail {
  width: 260px !important;
  min-width: 0 !important;
  height: calc(100dvh - 152px) !important;
  position: static !important;
  top: auto !important;
  display: grid !important;
  grid-template-rows: auto auto minmax(0, 1fr) auto !important;
  overflow: hidden !important;
  padding: 16px !important;
  transition: width .16s ease, padding .16s ease, opacity .16s ease !important;
}

.admin-page-sheets .side-rail.is-collapsed {
  width: 48px !important;
  padding: 10px 6px !important;
}

.admin-page-sheets .side-rail .admin-inner-card-head {
  margin-bottom: 10px !important;
  padding-bottom: 10px !important;
}

.admin-page-sheets .filter-list {
  min-width: 0 !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding-right: 4px !important;
}

.admin-page-sheets .filter-list .sub-filter,
.admin-page-sheets .filter-list .sub-filter-region {
  min-width: 0 !important;
  width: 100% !important;
  display: grid !important;
  grid-template-columns: minmax(88px, 1fr) 46px !important;
  align-items: center !important;
  column-gap: 8px !important;
  padding-left: 14px !important;
  padding-right: 12px !important;
}

.admin-page-sheets .filter-list .sub-filter-region {
  min-height: 42px !important;
  justify-content: initial !important;
  color: #17365d !important;
  font-size: 15px !important;
  font-weight: 900 !important;
}

.admin-page-sheets .filter-list .sub-filter span,
.admin-page-sheets .filter-list .sub-filter-region span {
  grid-column: 1 !important;
  min-width: 0 !important;
  max-width: 100% !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  writing-mode: horizontal-tb !important;
  word-break: keep-all !important;
  overflow-wrap: normal !important;
  justify-self: start !important;
  text-align: left !important;
}

.admin-page-sheets .filter-list .sub-filter-region span {
  min-width: 88px !important;
}

.admin-page-sheets .filter-list .sub-filter b,
.admin-page-sheets .filter-list .sub-filter-region b {
  grid-column: 2 !important;
  justify-self: end !important;
  flex: 0 0 auto !important;
  min-width: 46px !important;
  max-width: 46px !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  text-align: right !important;
}

.admin-page-sheets .list-card {
  min-width: 0 !important;
  overflow: visible !important;
  padding: 18px !important;
}

.admin-page-sheets .list-panel-title {
  display: grid !important;
  grid-template-columns: auto minmax(0, 1fr) auto auto !important;
  align-items: center !important;
  gap: 12px !important;
}

.admin-page-sheets .sheet-list-title-actions {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
}

.admin-page-sheets .sheet-list-add-button {
  min-height: 40px !important;
  padding: 0 18px !important;
  border-radius: 999px !important;
  color: #fff !important;
  border-color: rgba(37, 99, 235, .8) !important;
  background: linear-gradient(135deg, #2563eb, #0ea5e9) !important;
  box-shadow: 0 12px 28px rgba(37, 99, 235, .22) !important;
}

.admin-page-sheets .sheet-advanced-filters,
.admin-page-sheets .sheet-batch-bar {
  position: static !important;
  top: auto !important;
  z-index: auto !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
}

.admin-page-sheets .sheet-advanced-filters {
  margin: 0 !important;
  display: grid !important;
  gap: 10px !important;
}

.admin-page-sheets .sheet-filter-head {
  display: grid !important;
  grid-template-columns: minmax(260px, 1fr) auto auto !important;
  align-items: end !important;
  gap: 10px !important;
  min-height: 40px !important;
}

.admin-page-sheets .sheet-main-search-field {
  height: 40px !important;
  min-height: 40px !important;
  flex: initial !important;
  max-width: none !important;
  min-width: 0 !important;
  padding: 0 12px !important;
  border: 1px solid rgba(148, 163, 184, .28) !important;
  border-radius: 10px !important;
  background: #fff !important;
  box-shadow: none !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.admin-page-sheets .sheet-main-search-field > span {
  display: none !important;
}

.admin-page-sheets .sheet-main-search-field svg,
.admin-page-sheets .sheet-main-search-field i {
  flex: 0 0 16px !important;
  width: 16px !important;
  height: 16px !important;
  color: #64748b !important;
}

.admin-page-sheets .sheet-main-search-field input {
  flex: 1 1 auto !important;
  height: 38px !important;
  min-height: 38px !important;
  width: 100% !important;
  min-width: 0 !important;
  border: 0 !important;
  outline: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  padding: 0 !important;
  font-size: 13px !important;
  color: #102033 !important;
}

.admin-page-sheets .sheet-main-search-field .clear-wrap {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  height: 100% !important;
  display: flex !important;
  align-items: center !important;
}

.admin-page-sheets .sheet-main-search-field .clear-wrap input {
  position: static !important;
  flex: 1 1 auto !important;
  width: 100% !important;
  height: 38px !important;
  min-height: 38px !important;
}

.admin-page-sheets .sheet-main-search-field .input-clear {
  right: 2px !important;
}

.admin-page-sheets .sheet-quick-filters {
  justify-content: flex-end !important;
  gap: 8px !important;
}

.admin-page-sheets .sheet-quick-filters label {
  min-width: 104px !important;
  gap: 4px !important;
}

.admin-page-sheets .sheet-quick-filters select,
.admin-page-sheets .sheet-filter-grid select {
  height: 40px !important;
  min-height: 40px !important;
  border-radius: 10px !important;
  box-shadow: none !important;
}

.admin-page-sheets .sheet-filter-head-actions {
  flex-wrap: nowrap !important;
  gap: 8px !important;
}

.admin-page-sheets .sheet-filter-head-actions .ghost-action.compact,
.admin-page-sheets .sheet-batch-bar .ghost-action.compact,
.admin-page-sheets .sheet-batch-bar .primary-action.compact,
.admin-page-sheets .sheet-batch-bar .danger-btn.compact {
  height: 40px !important;
  min-height: 40px !important;
  border-radius: 999px !important;
}

.admin-page-sheets .sheet-filter-grid {
  position: static !important;
  grid-template-columns: repeat(4, minmax(130px, 1fr)) !important;
  box-shadow: none !important;
}

.admin-page-sheets .sheet-batch-bar {
  margin: 0 !important;
  background: rgba(238, 246, 255, .88) !important;
}

.admin-page-sheets .factory-admin-grid {
  --sheet-list-columns: 42px minmax(220px, 1.65fr) minmax(130px, 1fr) 72px 58px 78px 74px 140px !important;
  min-width: 0 !important;
  overflow: visible !important;
}

.admin-page-sheets.is-active .factory-admin-grid {
  --sheet-list-columns: 42px minmax(220px, 1.65fr) minmax(130px, 1fr) 72px 58px 78px 74px 140px !important;
}

.admin-page-sheets .sheet-list-header,
.admin-page-sheets .admin-factory-card,
.admin-page-sheets.is-active .admin-factory-card {
  grid-template-columns: var(--sheet-list-columns) !important;
  column-gap: 12px !important;
}

.admin-page-sheets .sheet-list-header {
  padding: 0 10px 4px !important;
}

.admin-page-sheets .admin-factory-card,
.admin-page-sheets.is-active .admin-factory-card {
  min-height: 78px !important;
  max-width: 100% !important;
  padding: 8px 10px !important;
  overflow: visible !important;
}

.admin-page-sheets .admin-factory-card .card-actions,
.admin-page-sheets.is-active .admin-factory-card .card-actions {
  min-width: 0 !important;
  justify-content: center !important;
  display: inline-flex !important;
  gap: 8px !important;
}

.admin-page-sheets .sheet-status-stack {
  min-width: 0 !important;
  gap: 5px !important;
}

.admin-page-sheets .sheet-status-stack .sheet-status-pill:nth-child(n+2) {
  display: none !important;
}

.admin-page-sheets .sheet-status-pill {
  max-width: 100% !important;
}

.admin-page-sheets .sheet-row-more {
  position: relative !important;
}

.admin-page-sheets .sheet-row-more > .sheet-row-more-panel {
  position: absolute !important;
  top: calc(100% + 8px) !important;
  left: auto !important;
  right: 0 !important;
  z-index: 500 !important;
  width: 178px !important;
  min-width: 178px !important;
}

.admin-page-sheets .sheet-form-drawer {
  width: min(430px, calc(100vw - 24px)) !important;
  max-width: 430px !important;
  min-width: min(400px, calc(100vw - 24px)) !important;
  height: 100dvh !important;
  display: flex !important;
  flex-direction: column !important;
}

.admin-page-sheets .sheet-form-drawer .sheet-drawer-head {
  flex: 0 0 auto !important;
}

.admin-page-sheets .sheet-form-drawer .admin-form {
  flex: 1 1 auto !important;
  min-height: 0 !important;
  overflow-y: auto !important;
  padding: 18px 22px 96px !important;
}

.admin-page-sheets .sheet-form-drawer .form-row.wide {
  grid-template-columns: 1fr 1fr !important;
  flex: 0 0 auto !important;
}

.admin-page-sheets .sheet-form-drawer .form-row.wide .primary-action {
  order: 2 !important;
}

.admin-page-sheets .sheet-form-drawer .form-row.wide .ghost-action {
  order: 1 !important;
}

.admin-page-sheets .sheet-form-drawer .upload-row {
  min-height: 136px !important;
  padding: 18px !important;
  border: 1px dashed rgba(37, 99, 235, .36) !important;
  border-radius: 18px !important;
  background: #f8fbff !important;
  place-items: center !important;
  gap: 10px !important;
  cursor: pointer !important;
  transition: border-color .16s ease, background .16s ease, box-shadow .16s ease !important;
}

.admin-page-sheets .sheet-form-drawer .upload-row::before {
  content: "点击上传或拖拽图片到此处";
  color: #2563eb;
  font-size: 14px;
  font-weight: 900;
}

.admin-page-sheets .sheet-form-drawer .upload-row::after {
  content: "支持 JPG、PNG、WEBP，上传成功后自动回填图片路径";
  color: #8aa0ba;
  font-size: 12px;
  font-weight: 750;
}

.admin-page-sheets .sheet-form-drawer .upload-row.is-dragging {
  border-color: #2563eb !important;
  background: #eef5ff !important;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .10) !important;
}

.admin-page-sheets .sheet-form-drawer .upload-row.is-uploading {
  cursor: progress !important;
}

.admin-page-sheets .sheet-form-drawer #uploadImageBtn {
  width: auto !important;
  min-height: 38px !important;
  border-style: solid !important;
  background: #fff !important;
}

@media (max-width: 1440px) {
  .admin-page-sheets .sheet-filter-head {
    grid-template-columns: minmax(220px, 1fr) auto auto !important;
  }

  .admin-page-sheets .sheet-quick-filters label {
    min-width: 94px !important;
  }

  .admin-page-sheets .factory-admin-grid,
  .admin-page-sheets.is-active .factory-admin-grid {
    --sheet-list-columns: 34px minmax(190px, 1.5fr) minmax(104px, .9fr) 58px 48px 74px 70px 122px !important;
  }

  .admin-page-sheets .sheet-list-header,
  .admin-page-sheets .admin-factory-card,
  .admin-page-sheets.is-active .admin-factory-card {
    column-gap: 8px !important;
  }

  .admin-page-sheets .sheet-status-stack .sheet-status-pill:nth-child(n+2) {
    display: none !important;
  }
}

.admin-page-sheets.is-active .sheet-form-drawer.is-open,
body .admin-page-sheets .sheet-form-drawer.is-open {
  transform: translateX(0) !important;
  opacity: 1 !important;
  pointer-events: auto !important;
}

.bulk-sheet-category-dialog::backdrop {
  background: rgba(15, 23, 42, .24);
  backdrop-filter: blur(8px);
}

.bulk-sheet-category-shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}

.bulk-sheet-category-shell header,
.bulk-sheet-category-shell footer {
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid rgba(148, 163, 184, .16);
}

.bulk-sheet-category-shell footer {
  border-top: 1px solid rgba(148, 163, 184, .16);
  border-bottom: 0;
  justify-content: flex-end;
}

.bulk-sheet-category-shell header strong {
  display: block;
  color: #10213a;
  font-size: 18px;
  font-weight: 900;
}

.bulk-sheet-category-shell header span,
.bulk-sheet-category-shell main p {
  color: #64748b;
  font-size: 13px;
}

.bulk-sheet-category-shell main {
  padding: 18px;
  display: grid;
  gap: 14px;
}

.bulk-sheet-category-shell label {
  display: grid;
  gap: 8px;
  color: #334155;
  font-size: 13px;
  font-weight: 800;
}

.bulk-sheet-category-shell select {
  min-height: 42px;
  border: 1px solid rgba(148, 163, 184, .24);
  border-radius: 12px;
  background: #fff;
  padding: 0 12px;
  color: #10213a;
  font-weight: 800;
}


/* admin operation logs 20260707 */
.operation-log-toolbar {
  display: grid;
  grid-template-columns: minmax(150px, 190px) minmax(120px, 150px) minmax(220px, 1fr) auto;
  gap: 12px;
  align-items: end;
  margin-top: 14px;
}
.operation-log-toolbar label { display: grid; gap: 7px; color: #516581; font-size: 12px; font-weight: 800; }
.operation-log-toolbar select,
.operation-log-toolbar input { width: 100%; min-height: 38px; border: 1px solid rgba(37, 99, 235, 0.16); border-radius: 12px; background: #fff; color: #17233d; padding: 0 12px; outline: none; }
.operation-log-status { margin: 14px 0 10px; color: #64748b; font-size: 13px; font-weight: 800; }
.operation-log-table-wrap { overflow-x: auto; border: 1px solid rgba(37, 99, 235, 0.12); border-radius: 14px; background: rgba(255, 255, 255, 0.72); }
.operation-log-table { width: 100%; border-collapse: collapse; min-width: 980px; }
.operation-log-table th,
.operation-log-table td { padding: 12px 14px; border-bottom: 1px solid rgba(148, 163, 184, 0.16); text-align: left; vertical-align: top; font-size: 13px; color: #263850; }
.operation-log-table th { background: rgba(239, 246, 255, 0.86); color: #315071; font-weight: 900; }
.operation-log-table td strong { display: block; margin-top: 3px; color: #0f2746; }
.operation-log-detail {
  max-width: 320px;
  display: grid;
  gap: 7px;
}
.operation-log-detail pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  font-family: inherit;
  color: #607089;
  line-height: 1.5;
}
.operation-log-detail.is-collapsed pre {
  max-height: 78px;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(180deg, #000 62%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 62%, transparent 100%);
}
.operation-log-toggle {
  justify-self: start;
  height: 28px;
  padding: 0 11px;
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: 999px;
  background: #fff;
  color: #2563eb;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}
.operation-log-toggle:hover {
  background: #eff6ff;
  border-color: rgba(37, 99, 235, 0.38);
}
.operation-log-empty {
  color: #94a3b8;
}
.operation-log-result { display: inline-flex; min-width: 52px; justify-content: center; padding: 5px 9px; border-radius: 999px; background: rgba(100, 116, 139, 0.10); color: #475569; font-size: 12px; }
.operation-log-result.is-success { background: rgba(14, 165, 233, 0.12); color: #0369a1; }
.operation-log-result.is-failed { background: rgba(239, 68, 68, 0.10); color: #dc2626; }
@media (max-width: 900px) { .operation-log-toolbar { grid-template-columns: 1fr; } }

/* sheet management final reference polish 20260709 */
body[data-admin-page="sheets"] {
  overflow: hidden !important;
}

body[data-admin-page="sheets"] .admin-shell {
  height: 100dvh !important;
  overflow: hidden !important;
}

body[data-admin-page="sheets"] .admin-main {
  min-height: 0 !important;
  overflow: hidden !important;
}

.admin-page-sheets.is-active {
  min-height: 0 !important;
  overflow: hidden !important;
}

.admin-page-sheets.is-active .workspace,
.admin-page-sheets.is-active .workspace.sheet-management-layout,
.admin-page-sheets.is-active .sheet-management-body {
  height: calc(100dvh - 44px) !important;
  min-height: 0 !important;
  align-items: stretch !important;
  grid-template-columns: 260px minmax(0, 1fr) !important;
  gap: 16px !important;
}

.admin-page-sheets .side-rail,
.admin-page-sheets .list-card {
  height: calc(100dvh - 44px) !important;
  max-height: calc(100dvh - 44px) !important;
  min-height: 0 !important;
}

.admin-page-sheets .side-rail {
  padding: 15px !important;
  grid-template-rows: auto auto minmax(0, 1fr) auto !important;
}

.admin-page-sheets .side-rail .admin-inner-card-head {
  margin-bottom: 8px !important;
  padding-bottom: 10px !important;
}

.admin-page-sheets .sheet-filter-rail-search {
  height: 36px !important;
  margin-bottom: 10px !important;
  border-radius: 12px !important;
}

.admin-page-sheets .filter-list {
  display: grid !important;
  align-content: start !important;
  gap: 4px !important;
  min-height: 0 !important;
  padding-right: 6px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}

.admin-page-sheets .filter-list .sub-filter,
.admin-page-sheets .filter-list .sub-filter-region {
  min-height: 38px !important;
  height: 38px !important;
  padding: 0 11px !important;
  grid-template-columns: minmax(92px, 1fr) 44px !important;
  column-gap: 8px !important;
  border-radius: 11px !important;
  font-size: 14px !important;
}

.admin-page-sheets .filter-list .sub-filter-region {
  margin-top: 3px !important;
  font-size: 14px !important;
  font-weight: 900 !important;
}

.admin-page-sheets .filter-list .sub-filter-region:first-of-type {
  margin-top: 0 !important;
}

.admin-page-sheets .filter-list .sub-filter b,
.admin-page-sheets .filter-list .sub-filter-region b {
  min-width: 44px !important;
  max-width: 44px !important;
  color: #7890ad !important;
}

.admin-page-sheets .list-card {
  display: grid !important;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto !important;
  gap: 10px !important;
  padding: 16px !important;
  overflow: hidden !important;
}

.admin-page-sheets .list-panel-title {
  min-height: 38px !important;
  padding-bottom: 10px !important;
  border-bottom: 1px solid rgba(148, 163, 184, .16) !important;
  grid-template-columns: auto minmax(0, 1fr) auto !important;
}

.admin-page-sheets .list-panel-title strong {
  font-size: 19px !important;
}

.admin-page-sheets #visibleCount {
  justify-self: end !important;
  max-width: 360px !important;
  min-height: 28px !important;
  padding: 0 12px !important;
  border: 1px solid rgba(37, 99, 235, .16) !important;
  border-radius: 999px !important;
  background: rgba(239, 246, 255, .84) !important;
  color: #2563eb !important;
  font-size: 12px !important;
  font-weight: 850 !important;
}

.admin-page-sheets .sheet-list-title-actions {
  justify-self: end !important;
}

.admin-page-sheets .sheet-list-add-button {
  min-height: 38px !important;
  padding: 0 16px !important;
}

.admin-page-sheets .sheet-advanced-filters {
  gap: 8px !important;
}

.admin-page-sheets .sheet-filter-head {
  grid-template-columns: minmax(220px, 1fr) auto auto !important;
  gap: 8px !important;
  align-items: end !important;
}

.admin-page-sheets .sheet-main-search-field {
  height: 38px !important;
  min-height: 38px !important;
  border-radius: 11px !important;
  padding: 0 11px !important;
}

.admin-page-sheets .sheet-main-search-field input,
.admin-page-sheets .sheet-main-search-field .clear-wrap input {
  height: 36px !important;
  min-height: 36px !important;
}

.admin-page-sheets .sheet-quick-filters {
  gap: 7px !important;
}

.admin-page-sheets .sheet-quick-filters label {
  min-width: 94px !important;
}

.admin-page-sheets .sheet-quick-filters select,
.admin-page-sheets .sheet-filter-grid select,
.admin-page-sheets .sheet-filter-head-actions .ghost-action.compact,
.admin-page-sheets .sheet-batch-bar .ghost-action.compact,
.admin-page-sheets .sheet-batch-bar .primary-action.compact,
.admin-page-sheets .sheet-batch-bar .danger-btn.compact {
  height: 36px !important;
  min-height: 36px !important;
}

.admin-page-sheets .sheet-filter-grid {
  gap: 8px !important;
  padding: 10px !important;
  border-radius: 12px !important;
}

.admin-page-sheets .sheet-batch-bar {
  min-height: 40px !important;
  padding: 6px 10px !important;
  border-radius: 12px !important;
}

.admin-page-sheets .factory-admin-grid {
  min-height: 0 !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  align-content: start !important;
  gap: 8px !important;
  padding-right: 5px !important;
  scrollbar-gutter: stable !important;
}

.admin-page-sheets .sheet-list-header {
  position: sticky !important;
  top: 0 !important;
  z-index: 20 !important;
  min-height: 30px !important;
  padding: 0 10px 6px !important;
  background: rgba(248, 252, 255, .96) !important;
  backdrop-filter: blur(10px) !important;
}

.admin-page-sheets .admin-factory-card,
.admin-page-sheets.is-active .admin-factory-card {
  min-height: 70px !important;
  padding: 7px 10px !important;
  border-radius: 13px !important;
  align-items: center !important;
}

.admin-page-sheets .sheet-info-line {
  grid-template-columns: 54px minmax(0, 1fr) !important;
  gap: 10px !important;
  align-items: center !important;
}

.admin-page-sheets .admin-factory-card .factory-image.small,
.admin-page-sheets .admin-factory-card .factory-image-frame {
  width: 54px !important;
  height: 42px !important;
  border-radius: 9px !important;
}

.admin-page-sheets .sheet-info-copy {
  gap: 2px !important;
}

.admin-page-sheets .sheet-info-copy strong {
  font-size: 13px !important;
  line-height: 1.25 !important;
}

.admin-page-sheets .sheet-info-copy span,
.admin-page-sheets .sheet-row-cell span {
  font-size: 11px !important;
}

.admin-page-sheets .sheet-status-pill {
  min-height: 22px !important;
  padding: 0 8px !important;
  border-radius: 999px !important;
  font-size: 11px !important;
  font-weight: 850 !important;
  box-shadow: none !important;
}

.admin-page-sheets .admin-factory-card .card-actions,
.admin-page-sheets.is-active .admin-factory-card .card-actions {
  gap: 6px !important;
}

.admin-page-sheets .admin-factory-card .card-actions > button,
.admin-page-sheets.is-active .admin-factory-card .card-actions > button,
.admin-page-sheets .sheet-row-more summary {
  height: 30px !important;
  min-height: 30px !important;
  min-width: 0 !important;
  padding: 0 10px !important;
  border-color: rgba(37, 99, 235, .16) !important;
  border-radius: 999px !important;
  background: rgba(255, 255, 255, .88) !important;
  box-shadow: none !important;
  font-size: 12px !important;
}

.admin-page-sheets .sheet-row-more > .sheet-row-more-panel {
  z-index: 80 !important;
  width: 168px !important;
  min-width: 168px !important;
  border-radius: 14px !important;
  box-shadow: 0 18px 50px rgba(15, 35, 80, .16) !important;
}

.admin-page-sheets .sheet-list-pagination {
  flex: 0 0 auto !important;
  min-height: 36px !important;
  margin-top: 2px !important;
  padding-top: 8px !important;
  border-top: 1px solid rgba(148, 163, 184, .14) !important;
}

@media (max-width: 1440px) {
  .admin-page-sheets.is-active .workspace,
  .admin-page-sheets.is-active .workspace.sheet-management-layout,
  .admin-page-sheets.is-active .sheet-management-body {
    grid-template-columns: 250px minmax(0, 1fr) !important;
    gap: 14px !important;
  }

  .admin-page-sheets .side-rail {
    width: 250px !important;
  }

  .admin-page-sheets .factory-admin-grid,
  .admin-page-sheets.is-active .factory-admin-grid {
    --sheet-list-columns: 34px minmax(170px, 1.25fr) minmax(86px, .7fr) 46px 42px 58px 52px 124px !important;
  }
}


/* recycle bin management */
.admin-trash-card {
  display: grid;
  gap: 18px;
}

.trash-summary {
  width: fit-content;
  padding: 9px 14px;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 999px;
  color: #24518a;
  font-size: 13px;
  font-weight: 800;
  background: rgba(37, 99, 235, 0.06);
}

.trash-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(148, 163, 184, 0.20);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
}

.trash-table {
  width: 100%;
  min-width: 900px;
  border-collapse: collapse;
  color: #102033;
  font-size: 13px;
}

.trash-table th,
.trash-table td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  text-align: left;
  vertical-align: middle;
}

.trash-table th {
  color: #60718c;
  font-size: 12px;
  font-weight: 900;
  background: rgba(239, 246, 255, 0.88);
}

.trash-table tbody tr:hover {
  background: rgba(37, 99, 235, 0.035);
}

.trash-table td strong,
.trash-table td small {
  display: block;
}

.trash-table td strong {
  color: #102033;
  font-size: 14px;
  font-weight: 900;
}

.trash-table td small {
  margin-top: 4px;
  color: #7b8da8;
  font-weight: 800;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 3px 10px;
  border-radius: 999px;
  color: #1554d1;
  font-size: 12px;
  font-weight: 900;
  background: rgba(37, 99, 235, 0.09);
}

.status-pill.muted {
  color: #64748b;
  background: rgba(100, 116, 139, 0.10);
}

.trash-actions {
  display: flex;
  gap: 8px;
  white-space: nowrap;
}

.danger-btn.compact,
.ghost-action.compact {
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
}

.admin-empty-state.compact {
  min-height: 120px;
  padding: 20px;
}


/* shared confirm dialog */
.admin-confirm-dialog {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: grid;
  place-items: center;
  padding: 24px;
  width: 100vw;
  max-width: none;
  height: 100vh;
  max-height: none;
  margin: 0;
  border: 0;
  background: transparent;
  color: inherit;
}

.admin-confirm-dialog::backdrop {
  background: transparent;
}

.admin-confirm-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.36);
  backdrop-filter: blur(8px);
}

.admin-confirm-panel {
  position: relative;
  width: min(460px, calc(100vw - 40px));
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 14px;
  padding: 22px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 26px 70px rgba(15, 35, 80, 0.28);
}

.admin-confirm-panel.is-wide {
  width: min(720px, calc(100vw - 40px));
}

.admin-confirm-icon {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.10);
}

.admin-confirm-icon.is-danger {
  color: #dc2626;
  background: rgba(220, 38, 38, 0.10);
}

.admin-confirm-icon svg {
  width: 22px;
  height: 22px;
}

.admin-confirm-copy strong {
  display: block;
  color: #102033;
  font-size: 18px;
  font-weight: 900;
}

.admin-confirm-copy p {
  margin: 8px 0 0;
  color: #60718c;
  font-size: 14px;
  line-height: 1.7;
}

.admin-rich-dialog .admin-confirm-copy {
  min-width: 0;
}

.admin-rich-dialog-body {
  margin-top: 8px;
  display: grid;
  gap: 12px;
  color: #60718c;
  font-size: 14px;
  line-height: 1.65;
}

.admin-rich-dialog-body p {
  margin: 0;
}

.admin-dialog-warn {
  padding: 9px 11px;
  border: 1px solid rgba(245, 158, 11, .28);
  border-radius: 12px;
  background: #fff7ed;
  color: #b45309 !important;
  font-weight: 800;
}

.admin-dialog-field {
  display: grid;
  gap: 8px;
}

.admin-dialog-field span {
  color: #405673;
  font-size: 13px;
  font-weight: 900;
}

.admin-dialog-field textarea {
  width: 100%;
  resize: vertical;
  min-height: 86px;
  border: 1px solid rgba(147, 183, 255, .4);
  border-radius: 14px;
  padding: 11px 12px;
  background: #f8fbff;
  color: #102033;
  font: inherit;
  outline: none;
}

.admin-dialog-field textarea:focus {
  border-color: rgba(37, 99, 235, .58);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, .1);
}

.crop-help-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.crop-help-grid section {
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(147, 183, 255, .26);
  border-radius: 16px;
  background: rgba(248, 251, 255, .88);
}

.crop-help-grid section:last-child {
  grid-column: 1 / -1;
}

.crop-help-grid strong {
  display: block;
  margin-bottom: 8px;
  color: #102033;
  font-size: 14px;
  font-weight: 900;
}

.crop-help-grid ol,
.crop-help-grid ul {
  margin: 0;
  padding-left: 18px;
}

.crop-help-grid li + li {
  margin-top: 5px;
}

.admin-confirm-actions {
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 4px;
}


/* data sync precheck */
.admin-sync-check-card {
  display: grid;
  gap: 16px;
}

.sync-check-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sync-check-actions span {
  color: #71829a;
  font-size: 13px;
  font-weight: 800;
}

.sync-check-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.sync-check-card {
  min-height: 86px;
  display: grid;
  align-content: center;
  gap: 8px;
  padding: 16px;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
}

.sync-check-card span {
  color: #60718c;
  font-size: 12px;
  font-weight: 900;
}

.sync-check-card strong {
  color: #102033;
  font-size: 25px;
  font-weight: 950;
}

.sync-check-card.is-ok {
  border-color: rgba(22, 163, 74, 0.18);
  background: rgba(240, 253, 244, 0.72);
}

.sync-check-card.is-warn {
  border-color: rgba(245, 158, 11, 0.24);
  background: rgba(255, 251, 235, 0.82);
}

.sync-check-card.is-danger {
  border-color: rgba(220, 38, 38, 0.22);
  background: rgba(254, 242, 242, 0.82);
}

.sync-check-report {
  white-space: pre-line;
  padding: 15px 16px;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 16px;
  color: #24518a;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.8;
  background: rgba(239, 246, 255, 0.82);
}

.sync-check-report.is-warn {
  border-color: rgba(245, 158, 11, 0.26);
  color: #8a5a0a;
  background: rgba(255, 251, 235, 0.86);
}

.sync-check-report.is-danger {
  border-color: rgba(220, 38, 38, 0.24);
  color: #9f1239;
  background: rgba(255, 241, 242, 0.86);
}

@media (max-width: 1180px) {
  .sync-check-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 680px) {
  .sync-check-grid {
    grid-template-columns: 1fr;
  }
}


.sync-baidu-source {
  padding: 12px 14px;
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 14px;
  color: #24518a;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.65;
  background: rgba(239, 246, 255, 0.78);
}

.sync-baidu-grid {
  margin-top: 2px;
}

.sync-baidu-actions {
  align-items: center;
}

.sync-baidu-button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.sync-failure-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
}

.sync-failure-table {
  width: 100%;
  min-width: 820px;
  border-collapse: collapse;
}

.sync-failure-table th,
.sync-failure-table td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.86);
  text-align: left;
  vertical-align: middle;
  color: #21354f;
  font-size: 13px;
}

.sync-failure-table th {
  color: #60718c;
  font-size: 12px;
  font-weight: 900;
  background: rgba(248, 251, 255, 0.92);
}

.sync-failure-table td strong,
.sync-failure-table td span {
  display: block;
}

.sync-failure-table td strong {
  color: #102033;
  font-weight: 900;
}

.sync-failure-table td span {
  margin-top: 3px;
  color: #71829a;
  font-size: 12px;
  font-weight: 800;
}

.sync-failure-table tr:last-child td {
  border-bottom: 0;
}

.sync-failure-muted {
  color: #8a98ad !important;
  font-size: 12px;
  font-weight: 800;
}

@media (max-width: 760px) {
  .sync-baidu-button-group {
    display: grid;
    grid-template-columns: 1fr;
    width: 100%;
  }
}


.backup-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.backup-status,
.backup-warning {
  padding: 12px 14px;
  border-radius: 14px;
  color: #24518a;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.65;
  background: rgba(239, 246, 255, 0.78);
  border: 1px solid rgba(37, 99, 235, 0.14);
}

.backup-warning {
  color: #8a5a0a;
  background: rgba(255, 251, 235, 0.86);
  border-color: rgba(245, 158, 11, 0.26);
}

.backup-table-wrap {
  width: 100%;
  overflow-x: auto;
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.82);
}

.backup-table {
  width: 100%;
  min-width: 720px;
  border-collapse: collapse;
}

.backup-table th,
.backup-table td {
  padding: 13px 14px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.86);
  text-align: left;
  color: #21354f;
  font-size: 13px;
}

.backup-table th {
  color: #60718c;
  font-size: 12px;
  font-weight: 900;
  background: rgba(248, 251, 255, 0.92);
}

.backup-table td strong {
  color: #102033;
  font-weight: 900;
}

.backup-table tr:last-child td {
  border-bottom: 0;
}


.admin-accounts-card,
.admin-permission-card {
  min-width: 0;
}

.accounts-status {
  margin: 0 0 14px;
  color: #58708d;
  font-size: 13px;
  font-weight: 700;
}

.accounts-table-wrap {
  width: 100%;
  overflow-x: auto;
}

.accounts-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  color: #17365d;
}

.accounts-table th,
.accounts-table td {
  padding: 13px 12px;
  border-bottom: 1px solid rgba(37, 99, 235, 0.10);
  text-align: left;
  vertical-align: middle;
  font-size: 13px;
}

.accounts-table th {
  color: #607895;
  font-weight: 900;
  background: rgba(239, 246, 255, 0.62);
}

.account-self-badge,
.account-role-badge,
.account-status-badge,
.permission-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 8px;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.account-self-badge,
.account-role-badge {
  color: #2563eb;
  background: rgba(37, 99, 235, 0.09);
}

.account-status-badge.is-active {
  color: #047857;
  background: rgba(16, 185, 129, 0.12);
}

.account-status-badge.is-disabled {
  color: #b91c1c;
  background: rgba(239, 68, 68, 0.12);
}

.account-role-select {
  width: 148px;
  height: 38px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 12px;
  padding: 0 10px;
  color: #17365d;
  background: #fff;
  font-weight: 800;
}

.permission-matrix {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}

.permission-role-card {
  padding: 14px;
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 16px;
  background: rgba(248, 251, 255, 0.76);
}

.permission-role-card strong {
  display: block;
  margin-bottom: 10px;
  color: #0f2742;
  font-size: 15px;
}

.permission-role-card > div {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.permission-chip {
  margin-left: 0;
  color: #7d8fa7;
  background: rgba(148, 163, 184, 0.13);
}

.permission-chip.is-on {
  color: #1d66e5;
  background: rgba(37, 99, 235, 0.10);
}


.account-create-form {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(180px, 1fr) 160px auto;
  gap: 10px;
  align-items: center;
  margin: 0 0 14px;
  padding: 12px;
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 16px;
  background: rgba(248, 251, 255, 0.72);
}

.account-create-form input,
.account-create-form select,
.account-status-select,
.account-reset-input {
  height: 38px;
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 12px;
  padding: 0 10px;
  color: #17365d;
  background: #fff;
  font-weight: 800;
  min-width: 0;
}

.account-row-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.account-status-select {
  width: 92px;
}

.account-reset-input {
  width: 128px;
}

.account-reset-btn {
  height: 38px;
}

@media (max-width: 1180px) {
  .account-create-form {
    grid-template-columns: 1fr 1fr;
  }
}


.account-permission-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-width: 430px;
}
.account-permission-toggle {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 8px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.07);
  color: #315071;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}
.account-permission-toggle.is-custom {
  background: rgba(14, 165, 233, 0.14);
  color: #0369a1;
}
.account-permission-toggle input {
  margin: 0;
  accent-color: #2563eb;
}
.account-row-actions .danger-action {
  color: #dc2626;
  border-color: rgba(239, 68, 68, 0.28);
}
.account-row-actions .danger-action:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}


.account-permission-dialog {
  width: min(720px, calc(100vw - 32px));
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 20px;
  padding: 0;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 26px 70px rgba(15, 35, 80, 0.24);
}
.account-permission-dialog::backdrop {
  background: rgba(15, 23, 42, 0.28);
  backdrop-filter: blur(8px);
}
.account-permission-dialog-body {
  padding: 18px 22px 6px;
}
.account-permission-tip {
  margin: 0 0 14px;
  color: #64748b;
  font-size: 13px;
  font-weight: 700;
}
.account-permission-dialog .account-permission-controls {
  max-width: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(128px, 1fr));
  gap: 10px;
}
.account-permission-dialog .account-permission-toggle {
  justify-content: flex-start;
  border-radius: 12px;
  padding: 9px 10px;
}


/* account permission dialog redesign 20260707 */
.account-permission-dialog {
  width: min(1000px, calc(100vw - 32px));
  height: min(82vh, 820px);
  max-height: min(82vh, 820px);
  padding: 0;
  border: 1px solid rgba(37, 99, 235, 0.16);
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 28px 72px rgba(15, 35, 80, 0.22);
  overflow: hidden;
}
.account-permission-dialog::backdrop {
  background: rgba(15, 23, 42, 0.24);
  backdrop-filter: blur(10px);
}
.account-permission-shell {
  height: 100%;
  max-height: min(82vh, 820px);
  display: flex;
  flex-direction: column;
  background: #ffffff;
}
.account-permission-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 26px 14px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  background: rgba(255, 255, 255, 0.98);
}
.account-permission-head h2 {
  margin: 0 0 12px;
  color: #0f1f35;
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: 0;
}
.account-permission-head p {
  margin: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  color: #1f3554;
  font-size: 15px;
  font-weight: 700;
}
.account-role-soft,
.account-permission-custom {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 8px;
  background: rgba(37, 99, 235, 0.10);
  color: #2563eb;
  font-size: 13px;
  font-weight: 800;
}
.account-permission-custom {
  background: rgba(14, 165, 233, 0.12);
  color: #0369a1;
}
.account-permission-head-actions {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  flex: 0 0 auto;
}
.account-permission-head-actions > span {
  width: 1px;
  height: 18px;
  background: rgba(148, 163, 184, 0.28);
}
.account-permission-text-btn {
  border: 0;
  background: transparent;
  color: #2563eb;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  padding: 6px 2px;
}
.account-permission-text-btn:hover { color: #0f4fd8; }
.account-permission-close {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 999px;
  background: #f1f5f9;
  color: #334155;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background-color .18s ease, color .18s ease, transform .18s ease;
}
.account-permission-close:hover {
  background: #2563eb;
  color: #ffffff;
  transform: scale(1.03);
}
.account-permission-close svg { width: 20px; height: 20px; stroke-width: 2.3; }
.account-permission-dialog-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 14px 24px 16px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}
.account-permission-groups {
  display: grid;
  gap: 12px;
  max-width: none;
}
.account-permission-group-card {
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.88);
  padding: 12px;
}
.account-permission-group-card > header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 12px;
  color: #17233d;
  font-size: 15px;
  font-weight: 900;
}
.account-permission-group-card > header svg {
  width: 19px;
  height: 19px;
  color: #2563eb;
  stroke: currentColor;
}
.account-permission-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}
.account-permission-option {
  position: relative;
  min-height: 62px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.94);
  cursor: pointer;
  transition: background-color .16s ease, border-color .16s ease;
}
.account-permission-option:hover { background: #f6faff; border-color: rgba(37, 99, 235, 0.24); }
.account-permission-option.is-disabled { opacity: .62; cursor: not-allowed; }
.account-permission-native {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.account-permission-check {
  width: 20px;
  height: 20px;
  border-radius: 5px;
  border: 1.5px solid #b8c4d6;
  background: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  transition: background-color .16s ease, border-color .16s ease;
}
.account-permission-check svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0;
}
.account-permission-option:hover .account-permission-check { border-color: #2563eb; }
.account-permission-option.is-checked .account-permission-check {
  background: #2563eb;
  border-color: #2563eb;
}
.account-permission-option.is-checked .account-permission-check svg { opacity: 1; }
.account-permission-copy { min-width: 0; display: grid; gap: 3px; }
.account-permission-copy b { color: #1e2f49; font-size: 14px; font-weight: 800; letter-spacing: 0; }
.account-permission-copy small { color: #6b7a90; font-size: 12px; line-height: 1.35; }
.account-permission-risk {
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: rgba(245, 158, 11, 0.14);
  color: #b45309;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 900;
}
.account-permission-footer {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 24px;
  border-top: 1px solid rgba(148, 163, 184, 0.16);
  background: #ffffff;
}
.account-permission-footer > span { color: #64748b; font-size: 13px; font-weight: 800; }
.account-permission-footer > div { display: inline-flex; justify-content: flex-end; gap: 12px; }
.account-permission-footer .primary-action,
.account-permission-footer .ghost-action { min-width: 106px; justify-content: center; }
@media (max-width: 760px) {
  .account-permission-head { padding: 18px; flex-direction: column; }
  .account-permission-head-actions { width: 100%; justify-content: flex-end; }
  .account-permission-grid { grid-template-columns: 1fr; }
  .account-permission-dialog-body { padding: 12px 14px; }
  .account-permission-footer { align-items: stretch; flex-direction: column; }
  .account-permission-footer > div { justify-content: flex-end; }
}

.account-permission-unsaved {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 24px;
  border-top: 1px solid rgba(245, 158, 11, 0.18);
  border-bottom: 1px solid rgba(245, 158, 11, 0.18);
  background: #fff8e8;
  position: sticky;
  top: 0;
  z-index: 120;
  color: #8a5a0a;
  font-size: 13px;
  font-weight: 800;
}
.account-permission-unsaved[hidden] { display: none; }
.account-permission-unsaved > div {
  display: inline-flex;
  gap: 10px;
  flex: 0 0 auto;
}
@media (max-width: 760px) {
  .account-permission-unsaved { align-items: stretch; flex-direction: column; }
  .account-permission-unsaved > div { justify-content: flex-end; }
}


.admin-accounts-panel {
  display: grid;
  gap: 16px;
  --account-blue: #2563eb;
  --account-blue-bg: #eef4ff;
  --enabled-green: #16a66a;
  --enabled-green-bg: #eaf8f1;
  --disabled-red: #ef4444;
  --disabled-red-bg: #fff0f0;
  --admin-purple: #7c3aed;
  --admin-purple-bg: #f3efff;
  --role-orange: #f59e0b;
  --role-orange-bg: #fff6e7;
  --role-cyan: #0891b2;
  --role-cyan-bg: #eafaff;
  --role-super: #f59e0b;
  --role-super-bg: #fff7e8;
  --role-admin: #2563eb;
  --role-admin-bg: #eef4ff;
  --role-editor: #8b5cf6;
  --role-editor-bg: #f4f0ff;
  --role-viewer: #06a9c7;
  --role-viewer-bg: #eafaff;
}
.account-stats-card,
.account-list-card,
.account-role-template-card,
.account-security-tip {
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 18px;
  background: rgba(255,255,255,.86);
  box-shadow: 0 14px 36px rgba(38, 91, 167, 0.08);
}
.account-stats-card {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  padding: 18px;
}
.account-stat-item {
  display: grid;
  grid-template-columns: 48px auto;
  grid-template-rows: auto auto;
  column-gap: 14px;
  align-items: center;
  padding: 4px 20px;
  border-right: 1px solid rgba(148, 163, 184, .18);
}
.account-stat-item:last-child { border-right: 0; }
.account-stat-item span {
  grid-row: 1 / 3;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #2563eb;
  background: rgba(37,99,235,.08);
}
.account-stat-item.is-total span { color: var(--account-blue); background: var(--account-blue-bg); }
.account-stat-item.is-active span { color: var(--enabled-green); background: var(--enabled-green-bg); }
.account-stat-item.is-disabled span { color: var(--disabled-red); background: var(--disabled-red-bg); }
.account-stat-item.is-admin span { color: var(--admin-purple); background: var(--admin-purple-bg); }
.account-stat-item svg { width: 22px; height: 22px; }
.account-stat-item strong { color: #0f1f35; font-size: 24px; line-height: 1; }
.account-stat-item em { color: #64748b; font-style: normal; font-size: 13px; font-weight: 700; }
.account-list-card { padding: 16px; }
.account-list-toolbar {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) 180px 180px auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}
.account-search-field {
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 12px;
  background: #fff;
}
.account-search-field svg { width: 18px; height: 18px; color: #64748b; }
.account-search-field input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
  color: #10213a;
  font: inherit;
}
.account-list-toolbar select {
  min-height: 44px;
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 12px;
  background: #fff;
  padding: 0 12px;
  color: #263b5c;
  font-weight: 700;
}
.account-modern-table-wrap { overflow: visible; }
.account-modern-table th,
.account-modern-table td { vertical-align: middle; }
.account-modern-table .account-actions-column {
  width: 190px;
  min-width: 190px;
  max-width: 190px;
  text-align: center;
  padding-left: 16px;
  padding-right: 16px;
}
.account-modern-table th.account-actions-column { text-align: center; }
.account-actions {
  width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}
.account-permission-btn {
  position: relative;
  z-index: 2;
  pointer-events: auto;
}
.account-role-badge.is-super-admin { color: #7c3aed; background: #f3efff; }
.account-role-badge.is-admin { color: #2563eb; background: #eef4ff; }
.account-role-badge.is-editor { color: #5b5eea; background: #f0f1ff; }
.account-role-badge.is-readonly { color: #2563eb; background: #eff6ff; }
.account-self-badge { color: #4b607c; background: #eef3fa; }
.account-identity { display: flex; align-items: center; gap: 12px; }
.account-avatar {
  width: 38px;
  height: 38px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #2563eb;
  background: #eef5ff;
  font-weight: 900;
}
.account-identity strong { color: #10213a; }
.account-identity p { margin: 4px 0 0; display: flex; gap: 6px; flex-wrap: wrap; }
.account-row-actions.modern { justify-content: center; flex-wrap: nowrap; position: relative; }
.account-more-menu { position: relative; }
.account-more-menu summary { list-style: none; cursor: pointer; }
.account-more-menu summary::-webkit-details-marker { display: none; }
.account-more-panel {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 20;
  min-width: 180px;
  padding: 8px;
  border: 1px solid rgba(37,99,235,.16);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 40px rgba(15, 35, 80, .18);
  display: grid;
  gap: 4px;
}
.account-more-panel button {
  width: 100%;
  min-height: 36px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #263b5c;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 10px;
  font-weight: 800;
  cursor: pointer;
}
.account-more-panel button:hover { background: #f3f7ff; color: #2563eb; }
.account-more-panel button:disabled { opacity: .45; cursor: not-allowed; }
.account-more-panel button.is-danger { color: #dc2626; }
.account-role-template-card { padding: 16px; }
.account-role-template-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}
.account-role-template {
  min-height: 168px;
  border: 1px solid rgba(148, 163, 184, .22);
  border-top: 2px solid var(--role-color);
  border-radius: 14px;
  background: rgba(255,255,255,.82);
  padding: 16px;
  display: grid;
  gap: 12px;
  transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
  --role-color: #2563eb;
  --role-bg: #eef4ff;
}
.account-role-template:hover {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--role-color) 42%, #dbe7ff);
  box-shadow: 0 16px 34px rgba(15, 35, 80, .10);
}
.account-role-template.is-super-admin { --role-color: var(--role-super); --role-bg: var(--role-super-bg); border-color: rgba(245, 158, 11, .26); }
.account-role-template.is-admin { --role-color: var(--role-admin); --role-bg: var(--role-admin-bg); border-color: rgba(37, 99, 235, .24); }
.account-role-template.is-editor { --role-color: var(--role-editor); --role-bg: var(--role-editor-bg); border-color: rgba(139, 92, 246, .24); }
.account-role-template.is-readonly { --role-color: var(--role-viewer); --role-bg: var(--role-viewer-bg); border-color: rgba(6, 169, 199, .24); }
.account-role-template.is-default { --role-color: #64748b; --role-bg: #f1f5f9; }
.role-template-lock {
  display: inline-flex;
  margin-left: 6px;
  vertical-align: -2px;
  color: var(--role-color);
}
.role-template-lock svg { width: 14px !important; height: 14px !important; }
.role-template-head { display: flex; align-items: center; gap: 12px; }
.role-template-head > span {
  width: 46px;
  height: 46px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--role-bg);
  color: var(--role-color);
}
.role-template-head svg { width: 22px; height: 22px; }
.role-template-head strong { color: #10213a; display: block; }
.role-template-head em {
  display: inline-flex;
  margin-top: 4px;
  padding: 2px 8px;
  border-radius: 999px;
  color: var(--role-color);
  background: var(--role-bg);
  font-size: 12px;
  font-style: normal;
  font-weight: 800;
}
.account-role-template p { margin: 0; color: #65758d; font-size: 13px; line-height: 1.55; }
.account-role-template .ghost-action {
  justify-content: center;
  width: 100%;
  color: var(--role-color);
  border-color: color-mix(in srgb, var(--role-color) 42%, #dbe7ff);
  background: #fff;
}
.account-role-template .ghost-action:hover {
  background: var(--role-bg);
  border-color: var(--role-color);
}
.account-security-tip { padding: 14px 16px; }
.account-security-tip > div { display: flex; align-items: center; gap: 10px; color: #49617f; }
.account-security-tip svg { width: 18px; height: 18px; color: #2563eb; }
.account-editor-dialog {
  width: min(560px, calc(100vw - 32px));
  border: 0;
  padding: 0;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 28px 72px rgba(15, 35, 80, .22);
}
.account-editor-dialog::backdrop { background: rgba(15,23,42,.22); backdrop-filter: blur(8px); }
.account-editor-shell { display: grid; max-height: min(82vh, 720px); grid-template-rows: auto minmax(0,1fr) auto; }
.account-editor-shell header,
.account-editor-shell footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid rgba(148,163,184,.16);
}
.account-editor-shell footer { border-top: 1px solid rgba(148,163,184,.16); border-bottom: 0; justify-content: flex-end; }
.account-editor-shell h2 { margin: 0 0 6px; font-size: 22px; color: #10213a; }
.account-editor-shell p { margin: 0; color: #64748b; font-size: 13px; }
.account-editor-shell main { overflow: auto; padding: 18px 22px; display: grid; gap: 14px; }
.account-editor-shell label { display: grid; gap: 8px; color: #334155; font-size: 13px; font-weight: 800; }
.account-editor-control {
  min-height: 46px;
  border: 1px solid rgba(37,99,235,.18);
  border-radius: 12px;
  padding: 0 12px;
  background: #fff;
  display: flex;
  align-items: center;
  gap: 10px;
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.account-editor-control:focus-within {
  border-color: rgba(37,99,235,.62);
  box-shadow: 0 0 0 3px rgba(37,99,235,.10);
}
.account-editor-control > svg,
.account-editor-control > i[data-lucide] {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}
.account-editor-control.is-user > svg,
.account-editor-control.is-role > svg { color: #2563eb; }
.account-editor-control.is-lock > svg { color: #7c3aed; }
.account-editor-control input,
.account-editor-control select {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 42px;
  border: 0;
  outline: 0;
  background: transparent;
  color: #10213a;
  font: inherit;
}
.account-editor-eye {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6b7a90;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.account-editor-eye:hover { background: #eef5ff; color: #2563eb; }
.account-editor-eye svg { width: 17px; height: 17px; }
.account-editor-control.is-status {
  background: #edfdf5;
  border-color: rgba(22, 166, 106, .24);
}
.account-editor-control.is-status.is-disabled {
  background: #fff3f3;
  border-color: rgba(239, 68, 68, .24);
}
.account-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: #16a66a;
  box-shadow: 0 0 0 6px rgba(22,166,106,.12);
}
.account-editor-control.is-status.is-disabled .account-status-dot {
  background: #ef4444;
  box-shadow: 0 0 0 6px rgba(239,68,68,.12);
}
.account-editor-note {
  padding: 10px 12px;
  border-radius: 12px;
  background: #f5f9ff;
  color: #64748b;
  font-size: 12px;
  line-height: 1.5;
}
.account-editor-note.is-muted {
  background: #f8fafc;
  color: #7b8aa3;
}
.account-editor-error {
  padding: 10px 12px;
  border-radius: 12px;
  background: #fff1f2;
  color: #be123c;
  font-size: 13px;
  font-weight: 800;
}
.account-check-row { display: flex !important; grid-template-columns: none !important; flex-direction: row; align-items: center; gap: 10px !important; }
.account-check-row input { min-height: auto; width: 16px; height: 16px; }
@media (max-width: 1500px) {
  .account-role-template-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .account-stats-card { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-stat-item { border-right: 0; border-bottom: 1px solid rgba(148,163,184,.14); }
  .account-list-toolbar { grid-template-columns: 1fr; }
  .account-role-template-grid { grid-template-columns: 1fr; }
}


.account-editor-unsaved {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(245, 158, 11, .24);
  border-radius: 12px;
  background: #fff8e8;
  color: #8a5a0a;
  font-size: 13px;
  font-weight: 800;
}
.account-editor-unsaved[hidden] { display: none; }
.account-editor-unsaved > div { display: inline-flex; gap: 8px; flex: 0 0 auto; }
@media (max-width: 760px) {
  .account-editor-unsaved { align-items: stretch; flex-direction: column; }
  .account-editor-unsaved > div { justify-content: flex-end; }
}

.role-permission-dialog {
  width: min(720px, calc(100vw - 32px));
  max-height: min(78vh, 760px);
  border: 0;
  padding: 0;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 30px 80px rgba(15, 35, 80, .24);
  overflow: hidden;
  --role-modal-color: #2563eb;
  --role-modal-bg: #eef4ff;
}
.role-permission-dialog::backdrop {
  background: rgba(15, 23, 42, .24);
  backdrop-filter: blur(9px);
}
.role-permission-dialog.is-super-admin { --role-modal-color: #7c3aed; --role-modal-bg: #f3efff; }
.role-permission-dialog.is-admin { --role-modal-color: #2563eb; --role-modal-bg: #eef4ff; }
.role-permission-dialog.is-editor { --role-modal-color: #7c3aed; --role-modal-bg: #f3efff; }
.role-permission-dialog.is-readonly { --role-modal-color: #0891b2; --role-modal-bg: #eafaff; }
.role-permission-shell {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  max-height: min(78vh, 760px);
}
.role-permission-head,
.role-permission-footer {
  padding: 20px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-bottom: 1px solid rgba(148,163,184,.18);
}
.role-permission-footer {
  justify-content: flex-end;
  border-top: 1px solid rgba(148,163,184,.18);
  border-bottom: 0;
}
.role-permission-footer .primary-action {
  min-width: 118px;
  justify-content: center;
}
.role-permission-title {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}
.role-permission-title > span {
  width: 58px;
  height: 58px;
  border-radius: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--role-modal-color);
  background: var(--role-modal-bg);
  flex: 0 0 auto;
}
.role-permission-title svg { width: 28px; height: 28px; }
.role-permission-title h2 {
  margin: 0 0 6px;
  color: #10213a;
  font-size: 24px;
  letter-spacing: 0;
}
.role-permission-title p {
  margin: 0;
  color: #53667f;
  font-size: 14px;
  line-height: 1.45;
}
.role-permission-body {
  overflow: auto;
  padding: 18px 24px;
  display: grid;
  gap: 16px;
}
.role-permission-group {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(148, 163, 184, .12);
}
.role-permission-group:last-child { border-bottom: 0; padding-bottom: 0; }
.role-permission-group-icon {
  width: 46px;
  height: 46px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--group-color);
  background: var(--group-bg);
}
.role-permission-group-icon svg { width: 22px; height: 22px; }
.role-permission-group h3 {
  margin: 2px 0 10px;
  color: #10213a;
  font-size: 17px;
}
.role-permission-group.is-blue { --group-color: #2563eb; --group-bg: #eef4ff; }
.role-permission-group.is-green { --group-color: #16a66a; --group-bg: #eaf8f1; }
.role-permission-group.is-orange { --group-color: #f59e0b; --group-bg: #fff6e7; }
.role-permission-group.is-purple { --group-color: #7c3aed; --group-bg: #f3efff; }
.role-permission-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.role-permission-chips span {
  padding: 6px 10px;
  border-radius: 999px;
  color: var(--group-color);
  background: var(--group-bg);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
}
.role-permission-empty {
  margin: 0;
  padding: 22px;
  text-align: center;
  color: #64748b;
  background: #f8fbff;
  border-radius: 16px;
}
.account-toast {
  position: fixed;
  z-index: 1200;
  right: 28px;
  top: 28px;
  padding: 12px 16px;
  border-radius: 999px;
  color: #0f5132;
  background: #eaf8f1;
  border: 1px solid rgba(22,166,106,.24);
  box-shadow: 0 18px 40px rgba(15, 35, 80, .16);
  font-size: 14px;
  font-weight: 900;
}
.account-toast[hidden] { display: none; }

/* Auxiliary crop workbench */
.admin-page-crop-workbench {
  height: calc(100vh - 176px);
  overflow: hidden;
}
.crop-manager {
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: auto auto auto minmax(0, 1fr) auto;
  gap: 8px;
  overflow: hidden;
}
.crop-manager[hidden],
.crop-workbench[hidden] {
  display: none !important;
}
.crop-manager-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.crop-manager-summary div,
.crop-manager-toolbar,
.crop-manager-bulk,
.crop-manager-table-wrap,
.crop-manager-pager {
  border: 1px solid rgba(147, 183, 255, .34);
  border-radius: 18px;
  background: rgba(255, 255, 255, .78);
  box-shadow: 0 16px 36px rgba(37, 99, 235, .08);
}
.crop-manager-summary div {
  padding: 9px 14px;
  display: grid;
  gap: 4px;
}
.crop-manager-summary span {
  color: #71829d;
  font-size: 12px;
  font-weight: 800;
}
.crop-manager-summary strong {
  color: #0f2746;
  font-size: 22px;
  line-height: 1;
  font-weight: 950;
}
.crop-manager-toolbar {
  padding: 10px 12px;
  display: grid;
  grid-template-columns: minmax(220px, 1.4fr) repeat(7, minmax(108px, 136px)) auto;
  gap: 8px;
  align-items: end;
}
.crop-manager-toolbar label {
  display: grid;
  gap: 7px;
  color: #516581;
  font-size: 12px;
  font-weight: 800;
}
.crop-manager-toolbar input,
.crop-manager-toolbar select {
  width: 100%;
  min-height: 36px;
  border: 1px solid rgba(37, 99, 235, .16);
  border-radius: 13px;
  background: #fff;
  color: #17233d;
  padding: 0 12px;
  outline: none;
}
.crop-manager-bulk,
.crop-manager-pager {
  min-height: 42px;
  padding: 6px 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.crop-manager-bulk > span,
.crop-manager-pager > span {
  color: #315071;
  font-size: 13px;
  font-weight: 900;
  margin-right: auto;
}
.crop-manager-table-wrap {
  min-height: 0;
  overflow: auto;
}
.crop-manager-table {
  width: 100%;
  min-width: 1000px;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0 8px;
  padding: 8px;
}
.crop-manager-table th:nth-child(1),
.crop-manager-table td:nth-child(1) { width: 46px; }
.crop-manager-table th:nth-child(2),
.crop-manager-table td:nth-child(2) { width: 26%; }
.crop-manager-table th:nth-child(3),
.crop-manager-table td:nth-child(3) { width: 13%; }
.crop-manager-table th:nth-child(4),
.crop-manager-table td:nth-child(4) { width: 7%; }
.crop-manager-table th:nth-child(5),
.crop-manager-table td:nth-child(5),
.crop-manager-table th:nth-child(6),
.crop-manager-table td:nth-child(6),
.crop-manager-table th:nth-child(7),
.crop-manager-table td:nth-child(7) { width: 10%; }
.crop-manager-table th:nth-child(8),
.crop-manager-table td:nth-child(8) { width: 10%; }
.crop-manager-table th:nth-child(9),
.crop-manager-table td:nth-child(9) { width: 14%; }
.crop-manager-table th {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 8px 10px;
  color: #49637f;
  font-size: 12px;
  text-align: left;
  background: rgba(241, 247, 255, .96);
  backdrop-filter: blur(8px);
}
.crop-manager-table td {
  padding: 8px 10px;
  color: #263850;
  font-size: 13px;
  vertical-align: middle;
  background: rgba(255, 255, 255, .88);
  border-top: 1px solid rgba(148, 163, 184, .12);
  border-bottom: 1px solid rgba(148, 163, 184, .12);
}
.crop-manager-table td:first-child {
  border-left: 1px solid rgba(148, 163, 184, .12);
  border-radius: 14px 0 0 14px;
}
.crop-manager-table td:last-child {
  border-right: 1px solid rgba(148, 163, 184, .12);
  border-radius: 0 14px 14px 0;
}
.crop-manager-table td small {
  display: block;
  margin-top: 4px;
  max-width: 150px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #7890ab;
  font-size: 12px;
  font-weight: 800;
}
.crop-manage-product {
  min-width: 0;
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  gap: 9px;
  align-items: center;
}
.crop-manage-product img {
  width: 48px;
  height: 48px;
  object-fit: cover;
  border-radius: 12px;
  background: #f3f6fb;
  box-shadow: 0 8px 18px rgba(15, 35, 80, .1);
}
.crop-manage-product span,
.crop-manage-product strong {
  min-width: 0;
}
.crop-manage-product strong {
  display: block;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #10213a;
  font-weight: 950;
}
.crop-manage-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.crop-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  min-height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
}
.crop-status.is-ok { color: #047857; background: rgba(16, 185, 129, .14); }
.crop-status.is-bad { color: #dc2626; background: rgba(239, 68, 68, .12); }
.crop-status.is-warn { color: #b45309; background: rgba(245, 158, 11, .15); }
.crop-status.is-skip { color: #64748b; background: rgba(100, 116, 139, .13); }
.crop-status.is-muted { color: #64748b; background: rgba(100, 116, 139, .10); }
.crop-baidu-image-dialog {
  width: min(860px, calc(100vw - 32px));
  border: 0;
  padding: 0;
  border-radius: 22px;
  background: transparent;
}
.crop-baidu-image-dialog::backdrop {
  background: rgba(15, 23, 42, .24);
  backdrop-filter: blur(10px);
}
.crop-baidu-image-dialog-shell {
  max-height: min(82vh, 760px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid rgba(147, 183, 255, .38);
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(238, 247, 255, .92));
  box-shadow: 0 24px 70px rgba(37, 99, 235, .18);
}
.crop-baidu-image-dialog-shell header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border-bottom: 1px solid rgba(147, 183, 255, .28);
}
.crop-baidu-image-dialog-shell h2,
.crop-baidu-image-dialog-shell h3,
.crop-baidu-image-dialog-shell p {
  margin: 0;
}
.crop-baidu-image-dialog-shell h2 {
  color: #10233f;
  font-size: 22px;
}
.crop-baidu-image-dialog-shell header p {
  margin-top: 4px;
  color: #6f819b;
  font-size: 13px;
}
.crop-baidu-image-dialog-shell main {
  min-height: 0;
  overflow: auto;
  padding: 18px 22px 22px;
  display: grid;
  gap: 16px;
}
.crop-baidu-image-dialog-shell h3 {
  margin-bottom: 10px;
  color: #17345a;
  font-size: 15px;
}
.crop-baidu-image-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid rgba(147, 183, 255, .24);
  border-radius: 14px;
  background: rgba(255, 255, 255, .58);
}
.crop-baidu-image-toolbar > span {
  margin-right: auto;
  color: #55708f;
  font-size: 13px;
  font-weight: 800;
}
.crop-baidu-image-tip {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid rgba(37, 99, 235, .18);
  border-radius: 14px;
  color: #2563eb;
  background: rgba(239, 246, 255, .86);
  font-size: 13px;
}
.crop-baidu-image-tip.is-error {
  color: #dc2626;
  border-color: rgba(239, 68, 68, .24);
  background: rgba(254, 242, 242, .9);
}
.crop-baidu-image-card {
  min-height: 86px;
  display: grid;
  grid-template-columns: 28px 76px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 10px;
  border: 1px solid rgba(147, 183, 255, .28);
  border-radius: 16px;
  background: rgba(255, 255, 255, .72);
}
.crop-baidu-image-card + .crop-baidu-image-card {
  margin-top: 10px;
}
.crop-baidu-image-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.crop-baidu-image-check input {
  width: 20px;
  height: 20px;
  accent-color: #2563eb;
  cursor: pointer;
}
.crop-baidu-image-check input:disabled {
  cursor: not-allowed;
  opacity: .35;
}
.crop-baidu-image-card img {
  width: 76px;
  height: 64px;
  object-fit: cover;
  border-radius: 12px;
  background: #f5f7fb;
  box-shadow: 0 8px 18px rgba(30, 64, 175, .12);
}
.crop-baidu-image-card div {
  min-width: 0;
  display: grid;
  gap: 4px;
}
.crop-baidu-image-card strong {
  color: #10233f;
  font-size: 14px;
}
.crop-baidu-image-card span,
.crop-baidu-image-card small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crop-baidu-image-card span {
  color: #49617e;
  font-size: 13px;
}
.crop-baidu-image-card small {
  color: #8292a8;
  font-size: 12px;
}
.crop-baidu-empty {
  padding: 16px;
  border: 1px dashed rgba(147, 183, 255, .38);
  border-radius: 16px;
  color: #71829d;
  background: rgba(255, 255, 255, .55);
}
.crop-workbench {
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-columns: minmax(240px, 270px) minmax(0, 1fr) minmax(260px, 300px);
  gap: 14px;
  align-items: stretch;
}
.crop-queue-card,
.crop-stage-card,
.crop-region-card {
  min-width: 0;
  min-height: 0;
  border: 1px solid rgba(147, 183, 255, .34);
  border-radius: 22px;
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 18px 44px rgba(37, 99, 235, .08);
  backdrop-filter: blur(16px);
}
.crop-queue-card,
.crop-region-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.crop-panel-head,
.crop-current-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(148, 163, 184, .16);
}
.crop-current-head {
  flex-wrap: wrap;
}
.crop-current-head > div:first-child {
  min-width: 0;
  flex: 1 1 240px;
}
.crop-panel-head strong,
.crop-current-head strong {
  color: #10213a;
  font-size: 16px;
  font-weight: 900;
}
.crop-panel-head span,
.crop-current-head span {
  color: #6f83a0;
  font-size: 12px;
  font-weight: 800;
}
.crop-queue-list,
.crop-region-list {
  flex: 1;
  min-height: 0;
  overflow: auto;
  padding: 12px;
  scrollbar-width: thin;
}
.crop-queue-item {
  width: 100%;
  border: 1px solid transparent;
  border-radius: 16px;
  background: transparent;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 8px;
  margin-bottom: 8px;
  color: #19304e;
  text-align: left;
  cursor: pointer;
}
.crop-queue-item:hover,
.crop-queue-item.is-active {
  border-color: rgba(37, 99, 235, .28);
  background: linear-gradient(135deg, rgba(239, 246, 255, .96), rgba(255, 255, 255, .78));
}
.crop-queue-item img {
  width: 54px;
  height: 54px;
  object-fit: cover;
  border-radius: 12px;
  background: #f3f6fb;
  box-shadow: 0 8px 18px rgba(15, 35, 80, .1);
}
.crop-queue-item strong,
.crop-queue-item small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crop-queue-item strong { font-size: 13px; font-weight: 900; }
.crop-queue-item small { margin-top: 3px; color: #70819b; font-size: 11px; }
.crop-queue-item em {
  padding: 5px 7px;
  border-radius: 999px;
  background: #eef4ff;
  color: #2563eb;
  font-style: normal;
  font-size: 11px;
  font-weight: 900;
}
.crop-queue-item b {
  display: none;
}
.crop-load-more,
.crop-manual-add {
  margin: 12px;
  justify-content: center;
}
.crop-stage-card {
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr) auto auto auto;
  overflow: hidden;
}
.crop-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 7px;
}
.crop-toolbar select {
  height: 36px;
  border: 1px solid rgba(147, 183, 255, .45);
  border-radius: 999px;
  padding: 0 14px;
  background: #fff;
  color: #19304e;
  font-weight: 800;
}
.crop-toolbar .crop-batch-recognize {
  color: #5b21b6;
  border-color: rgba(124, 58, 237, .28);
  background: linear-gradient(135deg, #f5f3ff, #eef2ff);
}
.crop-toolbar .crop-batch-recognize:hover {
  border-color: rgba(124, 58, 237, .5);
  background: linear-gradient(135deg, #ede9fe, #e0e7ff);
}
.cloud-model-dialog {
  width: min(680px, calc(100vw - 32px));
  padding: 0;
  border: 1px solid rgba(147, 183, 255, .5);
  border-radius: 22px;
  background: #fff;
  color: #152946;
  box-shadow: 0 28px 80px rgba(36, 78, 150, .24);
}
.cloud-model-dialog::backdrop {
  background: rgba(20, 38, 70, .45);
  backdrop-filter: blur(5px);
}
.cloud-model-dialog form {
  display: grid;
  gap: 18px;
  padding: 22px;
}
.cloud-model-head,
.cloud-model-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.cloud-model-head strong {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 19px;
}
.cloud-model-head p {
  margin: 6px 0 0;
  color: #6680a5;
  font-size: 13px;
}
.cloud-model-fields {
  display: grid;
  gap: 14px;
}
.cloud-model-fields label {
  display: grid;
  gap: 7px;
  color: #405b80;
  font-size: 13px;
  font-weight: 800;
}
.cloud-model-fields input,
.cloud-model-fields select {
  width: 100%;
  height: 42px;
  box-sizing: border-box;
  border: 1px solid #c9d9f2;
  border-radius: 11px;
  padding: 0 12px;
  background: #f9fbff;
  color: #172d4e;
  font: inherit;
}
.cloud-model-fields small {
  color: #7890b1;
  font-weight: 600;
}
.cloud-model-status {
  min-height: 20px;
  padding: 11px 13px;
  border-radius: 11px;
  background: #f1f6ff;
  color: #47658d;
  font-size: 13px;
  font-weight: 700;
}
.cloud-model-status[data-state="success"],
.cloud-model-status[data-state="ready"] { background: #ecfdf5; color: #047857; }
.cloud-model-status[data-state="error"] { background: #fff1f2; color: #be123c; }
.cloud-model-status[data-state="running"] { background: #eff6ff; color: #1d4ed8; }
.cloud-model-actions { justify-content: flex-end; }

/* Keep button labels readable when page-specific colors meet global hover styles. */
.filter-btn:not(:disabled):hover,
.ghost-action:not(:disabled):hover,
.card-actions button:not(:disabled):hover,
.select-toggle:not(:disabled):hover {
  color: #0f4fc7;
  border-color: rgba(37, 99, 235, .48);
  background: #eef5ff;
  box-shadow: 0 10px 24px rgba(37, 99, 235, .16), inset 0 1px 0 rgba(255, 255, 255, .9);
}
.filter-btn:not(:disabled):hover > *,
.ghost-action:not(:disabled):hover > *,
.card-actions button:not(:disabled):hover > *,
.select-toggle:not(:disabled):hover > * {
  color: inherit;
}
.primary-action:not(:disabled):hover {
  color: #fff;
  border-color: rgba(30, 64, 175, .78);
  background: linear-gradient(135deg, #1d4ed8, #0284c7);
  box-shadow: 0 12px 28px rgba(37, 99, 235, .26), inset 0 1px 0 rgba(255, 255, 255, .28);
}
.primary-action:not(:disabled):hover > * { color: inherit; }
.ghost-action:disabled:hover,
.primary-action:disabled:hover,
.filter-btn:disabled:hover,
.select-toggle:disabled:hover {
  color: #526b8e;
  border-color: rgba(148, 163, 184, .28);
  background: #f5f8fc;
  box-shadow: none;
  transform: none;
}
.ghost-action:disabled:hover > *,
.primary-action:disabled:hover > *,
.filter-btn:disabled:hover > *,
.select-toggle:disabled:hover > * { color: inherit; }
.crop-toolbar .crop-batch-recognize:not(:disabled):hover {
  color: #5b21b6;
  border-color: rgba(124, 58, 237, .46);
  background: linear-gradient(135deg, #ede9fe, #e0e7ff);
}
.account-role-template .ghost-action:not(:disabled):hover {
  color: var(--role-color);
  border-color: var(--role-color);
  background: var(--role-bg);
}
.crop-auto-toggle {
  min-height: 36px;
  padding: 0 11px;
  border: 1px solid rgba(147, 183, 255, .45);
  border-radius: 999px;
  background: #fff;
  color: #526b8e;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}
.crop-auto-toggle input,
.crop-select-all input,
.crop-region-check input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.crop-switch-track {
  position: relative;
  width: 34px;
  height: 20px;
  border-radius: 999px;
  background: #cbd5e1;
  box-shadow: inset 0 1px 3px rgba(15, 23, 42, .16);
  transition: .18s ease;
}
.crop-switch-track i {
  position: absolute;
  left: 3px;
  top: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 2px 5px rgba(15, 23, 42, .22);
  transition: .18s ease;
}
.crop-auto-toggle.is-enabled {
  border-color: rgba(37, 99, 235, .38);
  color: #1d4ed8;
  background: #eff6ff;
}
.crop-auto-toggle.is-enabled .crop-switch-track { background: #2563eb; }
.crop-auto-toggle.is-enabled .crop-switch-track i { transform: translateX(14px); }
.crop-ai-notice {
  margin: 10px 14px 0;
  padding: 9px 11px;
  border: 1px solid rgba(37, 99, 235, .18);
  border-radius: 14px;
  background: rgba(239, 246, 255, .78);
  color: #35608f;
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 13px;
  font-weight: 800;
}
  .crop-ai-notice.is-error {
    border-color: rgba(239, 68, 68, .24);
    background: #fff1f2;
    color: #b91c1c;
  }
  .crop-ai-notice.is-success {
    border-color: rgba(16, 185, 129, .28);
    background: rgba(236, 253, 245, .9);
    color: #047857;
  }
.crop-canvas-shell {
  position: relative;
  min-height: 0;
  margin: 12px 14px;
  border: 1px solid rgba(148, 163, 184, .2);
  border-radius: 18px;
  overflow: hidden;
  background:
    linear-gradient(45deg, rgba(226, 232, 240, .5) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(226, 232, 240, .5) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(226, 232, 240, .5) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(226, 232, 240, .5) 75%),
    #f7f9fd;
  background-size: 24px 24px;
  background-position: 0 0, 0 12px, 12px -12px, -12px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
}
#cropSourceImage {
  display: block;
  width: auto;
  height: auto;
  max-width: none;
  max-height: none;
  object-fit: contain;
  object-position: center;
}
.crop-canvas-empty,
.crop-empty-card {
  color: #7488a4;
  text-align: center;
  font-weight: 900;
}
.crop-region-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.crop-region-box {
  position: absolute;
  z-index: 3;
  border: 2px solid #2563eb;
  border-radius: 12px;
  background: rgba(37, 99, 235, .08);
  box-shadow: 0 0 0 9999px rgba(15, 23, 42, .06);
  pointer-events: auto;
  cursor: move;
}
.crop-region-box.is-active {
  border-color: #0ea5e9;
  background: rgba(14, 165, 233, .12);
}
.crop-region-box.is-excluded {
  border-color: #94a3b8;
  border-style: dashed;
  background: rgba(148, 163, 184, .08);
  box-shadow: none;
  opacity: .62;
}
.crop-region-box.is-drawing {
  border-style: dashed;
  pointer-events: none;
}
.crop-region-box.is-pulse {
  animation: cropPulse .9s ease;
}
@keyframes cropPulse {
  0%, 100% { box-shadow: 0 0 0 9999px rgba(15, 23, 42, .06), 0 0 0 0 rgba(37, 99, 235, .38); }
  50% { box-shadow: 0 0 0 9999px rgba(15, 23, 42, .06), 0 0 0 10px rgba(37, 99, 235, .18); }
}
.crop-region-box span {
  position: absolute;
  left: -2px;
  top: -25px;
  min-width: 24px;
  height: 22px;
  border-radius: 999px;
  background: #2563eb;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 900;
}
.crop-region-box i[data-handle="move"] {
  position: absolute;
  inset: 0;
  cursor: move;
}
.crop-region-handle {
  position: absolute;
  z-index: 2;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid #2563eb;
}
.crop-region-handle.is-nw { left: -7px; top: -7px; cursor: nwse-resize; }
.crop-region-handle.is-n { left: calc(50% - 7px); top: -7px; cursor: ns-resize; }
.crop-region-handle.is-ne { right: -7px; top: -7px; cursor: nesw-resize; }
.crop-region-handle.is-e { right: -7px; top: calc(50% - 7px); cursor: ew-resize; }
.crop-region-handle.is-se { right: -7px; bottom: -7px; cursor: nwse-resize; }
.crop-region-handle.is-s { left: calc(50% - 7px); bottom: -7px; cursor: ns-resize; }
.crop-region-handle.is-sw { left: -7px; bottom: -7px; cursor: nesw-resize; }
.crop-region-handle.is-w { left: -7px; top: calc(50% - 7px); cursor: ew-resize; }
.crop-canvas-shell {
  cursor: crosshair;
}
.crop-region-box,
.crop-region-box i[data-handle="move"] {
  cursor: move;
}
.crop-view-controls,
.crop-bottom-actions {
  padding: 0 14px 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}
.crop-bottom-actions {
  border-top: 1px solid rgba(148, 163, 184, .16);
  padding-top: 10px;
  padding-bottom: 10px;
}
.crop-recognition-progress {
  margin: -2px 14px 12px;
  padding: 9px 12px 10px;
  border: 1px solid rgba(37, 99, 235, .2);
  border-radius: 13px;
  background: rgba(239, 246, 255, .86);
}
.crop-recognition-progress[hidden] { display: none; }
.crop-recognition-progress > div:first-child {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #315b8e;
  font-size: 12px;
  font-weight: 900;
}
.crop-recognition-progress > div:first-child span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crop-recognition-progress > div:first-child b { color: #1d4ed8; }
.crop-recognition-progress-track {
  height: 8px;
  margin-top: 7px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(148, 163, 184, .24);
}
.crop-recognition-progress-track i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2563eb, #38bdf8, #2563eb);
  background-size: 200% 100%;
  box-shadow: 0 0 14px rgba(37, 99, 235, .28);
  transition: width .28s ease;
  animation: cropProgressFlow 1.2s linear infinite;
}
.crop-recognition-progress[data-state="success"] {
  border-color: rgba(16, 185, 129, .28);
  background: rgba(236, 253, 245, .9);
}
.crop-recognition-progress[data-state="success"] > div:first-child,
.crop-recognition-progress[data-state="success"] > div:first-child b { color: #047857; }
.crop-recognition-progress[data-state="success"] .crop-recognition-progress-track i {
  background: linear-gradient(90deg, #10b981, #34d399);
  animation: none;
}
.crop-recognition-progress[data-state="error"] {
  border-color: rgba(239, 68, 68, .28);
  background: #fff1f2;
}
.crop-recognition-progress[data-state="error"] > div:first-child,
.crop-recognition-progress[data-state="error"] > div:first-child b { color: #b91c1c; }
.crop-recognition-progress[data-state="error"] .crop-recognition-progress-track i {
  background: #ef4444;
  animation: none;
}
@keyframes cropProgressFlow {
  from { background-position: 100% 0; }
  to { background-position: -100% 0; }
}
.crop-region-head {
  align-items: flex-start;
}
.crop-region-head-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
}
.crop-select-all {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid rgba(147, 183, 255, .4);
  border-radius: 999px;
  background: #fff;
  color: #315b8e;
  display: inline-flex;
  align-items: center;
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}
.crop-select-all:has(input:checked) {
  border-color: rgba(37, 99, 235, .44);
  background: #eff6ff;
  color: #1d4ed8;
}
.crop-select-all:has(input:disabled) {
  opacity: .48;
  cursor: not-allowed;
}
.crop-region-item {
  display: grid;
  grid-template-columns: 24px 76px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 9px;
  margin-bottom: 10px;
  border: 1px solid rgba(147, 183, 255, .24);
  border-radius: 16px;
  background: rgba(248, 251, 255, .85);
}
.crop-region-item.is-active {
  border-color: rgba(37, 99, 235, .5);
  background: #eef5ff;
}
.crop-region-item.is-excluded {
  border-style: dashed;
  background: rgba(248, 250, 252, .72);
}
.crop-region-item.is-excluded canvas,
.crop-region-item.is-excluded .crop-region-copy {
  opacity: .5;
  filter: grayscale(.65);
}
.crop-region-item canvas {
  width: 76px;
  height: 58px;
  border-radius: 12px;
  background: #f5f7fb;
}
.crop-region-check {
  width: 24px;
  height: 24px;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}
.crop-region-check span {
  width: 20px;
  height: 20px;
  border: 2px solid #b9c8dc;
  border-radius: 7px;
  background: #fff;
  color: transparent;
  display: grid;
  place-items: center;
  transition: .16s ease;
}
.crop-region-check span svg { width: 13px; height: 13px; stroke-width: 3; }
.crop-region-check input:checked + span {
  border-color: #2563eb;
  background: #2563eb;
  color: #fff;
  box-shadow: 0 5px 12px rgba(37, 99, 235, .24);
}
.crop-region-copy { min-width: 0; }
.crop-region-item strong,
.crop-region-item small,
.crop-region-name-input {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.crop-region-name-input {
  width: 100%;
  height: 30px;
  border: 1px solid transparent;
  border-radius: 9px;
  padding: 0 8px;
  background: transparent;
  color: #10213a;
  font-size: 13px;
  font-weight: 900;
}
.crop-region-name-input:focus {
  outline: none;
  border-color: rgba(37, 99, 235, .32);
  background: #fff;
}
.crop-region-item strong {
  color: #10213a;
  font-size: 13px;
  font-weight: 900;
}
.crop-region-item small {
  color: #70819b;
  font-size: 12px;
  margin-top: 4px;
}
.crop-region-meta-row {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 5px;
}
.crop-region-meta-row small {
  min-width: 0;
  flex: 1 1 auto;
}
.crop-region-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
}
.crop-region-actions .icon-btn {
  width: 30px;
  height: 30px;
  min-width: 30px;
  padding: 0;
  border: 1px solid rgba(147, 183, 255, .42);
  border-radius: 9px;
  background: #fff;
  color: #3b6497;
  display: inline-grid;
  place-items: center;
}
.crop-region-actions .icon-btn svg {
  width: 16px;
  height: 16px;
  stroke-width: 2.2;
}
.crop-region-actions .icon-btn:hover {
  border-color: rgba(37, 99, 235, .52);
  background: #eff6ff;
  color: #1d4ed8;
}
.crop-region-actions .icon-btn.is-danger:hover {
  border-color: rgba(239, 68, 68, .42);
  background: #fff1f2;
  color: #dc2626;
}
.crop-advice-card {
  margin: 0 12px 12px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(239, 246, 255, .78);
  color: #496482;
  display: flex;
  gap: 8px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.55;
}
.crop-empty-card {
  min-height: 160px;
  border: 1px dashed rgba(147, 183, 255, .42);
  border-radius: 18px;
  background: rgba(248, 251, 255, .62);
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  padding: 20px;
}
.crop-empty-card svg {
  width: 30px;
  height: 30px;
  color: #2563eb;
}
.crop-empty-card strong {
  color: #19304e;
}
.crop-empty-card span {
  color: #7b8ca5;
  font-size: 12px;
  line-height: 1.5;
}
.is-crop-dragging,
.is-crop-dragging * {
  cursor: grabbing !important;
}
@media (max-width: 1500px) {
  .crop-manager-toolbar {
    grid-template-columns: minmax(170px, 1.2fr) repeat(7, minmax(92px, 1fr));
  }
  .crop-manager-toolbar #cropManageReset {
    grid-column: 1 / -1;
    justify-self: end;
  }
  .crop-workbench {
    grid-template-columns: 224px minmax(0, 1fr) 252px;
    gap: 10px;
  }
  .crop-panel-head,
  .crop-current-head {
    padding: 12px;
  }
  .crop-panel-head strong,
  .crop-current-head strong {
    font-size: 15px;
  }
  .crop-region-item {
    grid-template-columns: 22px 60px minmax(0, 1fr);
    gap: 6px;
  }
  .crop-region-item canvas {
    width: 60px;
    height: 48px;
  }
  .crop-toolbar .ghost-action.compact,
  .crop-view-controls .ghost-action.compact,
  .crop-bottom-actions .ghost-action.compact {
    min-height: 34px;
    padding: 0 10px;
  }
}

/* 前台搜索框输入状态：使用稳定的深蓝色细边框 */
.front-page .front-search-row:focus-within {
  border-color: #174a7e !important;
  box-shadow: 0 4px 14px rgba(23, 74, 126, 0.1) !important;
}

.back-to-top {
  position: fixed;
  z-index: 180;
  right: 24px;
  bottom: 24px;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(24, 119, 237, 0.24);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #1877ed;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 24px rgba(31, 91, 155, 0.14);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(10px);
  transition: opacity 180ms ease, transform 180ms ease, background 160ms ease, visibility 180ms ease;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top:hover {
  color: #fff;
  border-color: #1877ed;
  background: #1877ed;
  box-shadow: 0 12px 28px rgba(24, 119, 237, 0.24);
}

.back-to-top svg {
  width: 21px;
  height: 21px;
  stroke-width: 2.4;
}

@keyframes cardImageSkeletonShimmer {
  0% { transform: translateX(-125%); }
  100% { transform: translateX(125%); }
}

.front-page .category-section.cards-mounted {
  content-visibility: auto;
  contain-intrinsic-size: auto 800px;
}

.front-page .category-items.is-deferred {
  position: relative;
  min-height: var(--deferred-section-height, 340px);
  display: block !important;
  overflow: hidden;
  contain: layout paint;
}

.deferred-category-preview {
  position: absolute;
  inset: 0 0 auto;
  display: grid;
  grid-template-columns: repeat(var(--deferred-preview-columns, 5), minmax(0, 1fr));
  gap: 14px;
}

.deferred-card-skeleton {
  position: relative;
  min-width: 0;
  height: clamp(260px, 19vw, 360px);
  border: 1px solid rgba(221, 231, 245, 0.74);
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(135deg, #f2f7fd, #eaf2fb);
  box-shadow: 0 10px 24px rgba(47, 83, 117, 0.055);
}

.deferred-card-skeleton::before {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(105deg, transparent 28%, rgba(255, 255, 255, 0.7) 46%, rgba(255, 255, 255, 0.86) 52%, transparent 70%);
  transform: translateX(-125%);
  animation: cardImageSkeletonShimmer 1.65s ease-in-out infinite;
}

.front-page .factory-image-frame.has-lazy-image {
  background: linear-gradient(135deg, #f2f7fd, #eaf2fb);
}

.front-page .factory-image-frame.has-lazy-image::before {
  position: absolute;
  z-index: 0;
  inset: 0;
  content: "";
  background: linear-gradient(105deg, transparent 28%, rgba(255, 255, 255, 0.72) 46%, rgba(255, 255, 255, 0.86) 52%, transparent 70%);
  transform: translateX(-125%);
  opacity: 0;
  pointer-events: none;
}

.front-page .factory-image-frame.is-image-loading::before {
  opacity: 1;
  animation: cardImageSkeletonShimmer 1.65s ease-in-out infinite;
}

.front-page .factory-image-frame.has-lazy-image img {
  opacity: 0;
  transition: opacity 220ms ease;
}

.front-page .factory-image-frame.is-image-loaded img {
  opacity: 1;
}

.front-page .factory-image-frame.is-image-error::before {
  display: none;
}

@media (prefers-reduced-motion: reduce) {
  .deferred-card-skeleton::before,
  .front-page .factory-image-frame.is-image-loading::before {
    animation: none;
    opacity: 0.45;
  }
}

@media (max-width: 1100px) {
  .deferred-category-preview {
    grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  }
}

@media (max-width: 900px) {
  .back-to-top {
    right: 14px;
    bottom: 14px;
    width: 42px;
    height: 42px;
  }
}

/* Usage analytics */
.usage-analytics-panel { display: grid; gap: 16px; min-width: 0; width: 100%; }
.usage-analytics-panel > * { min-width: 0; max-width: 100%; }
.usage-table-card { overflow: hidden; }
.usage-analytics-toolbar { display: grid; grid-template-columns: minmax(260px, 1fr) 130px minmax(280px, 420px) auto; align-items: end; gap: 14px; padding: 18px 20px; }
.usage-analytics-toolbar > div { align-self: center; }
.usage-analytics-toolbar strong { color: #10233f; font-size: 16px; }
.usage-analytics-toolbar p { margin: 5px 0 0; color: #65758d; font-size: 12px; line-height: 1.55; }
.usage-analytics-toolbar label { display: grid; gap: 6px; color: #516581; font-size: 12px; font-weight: 800; }
.usage-analytics-toolbar select,
.usage-analytics-toolbar input { width: 100%; min-height: 42px; border: 1px solid rgba(37, 99, 235, 0.18); border-radius: 12px; background: #fff; color: #17233d; padding: 0 12px; outline: none; }
.usage-analytics-toolbar select:focus,
.usage-analytics-toolbar input:focus { border-color: #4f7df3; box-shadow: 0 0 0 3px rgba(79, 125, 243, 0.12); }
.usage-analytics-search { position: relative; }
.usage-analytics-search svg { position: absolute; left: 12px; bottom: 11px; width: 18px; height: 18px; color: #7b8aa2; }
.usage-analytics-search input { padding-left: 38px; }
.usage-analytics-status { min-height: 20px; color: #64748b; font-size: 12px; font-weight: 700; }
.usage-kpi-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 12px; }
.usage-kpi-card { min-width: 0; padding: 18px; border: 1px solid rgba(37, 99, 235, 0.12); border-radius: 16px; background: linear-gradient(145deg, #fff, #f8fbff); box-shadow: 0 8px 24px rgba(59, 91, 140, 0.06); }
.usage-kpi-card span { display: block; color: #60708a; font-size: 12px; font-weight: 850; }
.usage-kpi-card strong { display: block; margin: 8px 0 4px; color: #132a4a; font-size: clamp(24px, 2.2vw, 34px); font-variant-numeric: tabular-nums; line-height: 1; }
.usage-kpi-card small { color: #8592a7; font-size: 11px; }
.usage-kpi-card.is-accent { border-color: rgba(99, 102, 241, 0.22); background: linear-gradient(145deg, #fff, #f4f3ff); }
.usage-kpi-card.is-accent strong { color: #5b55d6; }
.usage-kpi-card.is-success { border-color: rgba(16, 185, 129, 0.22); background: linear-gradient(145deg, #fff, #f0fdf8); }
.usage-kpi-card.is-success strong { color: #078761; }
.usage-kpi-card.is-baidu { border-color: rgba(37, 99, 235, 0.24); background: linear-gradient(145deg, #fff, #eef6ff); }
.usage-kpi-card.is-baidu strong { color: #1769d2; }
.usage-trend-card,
.usage-table-card { padding: 18px 20px; }
.usage-trend { display: grid; grid-template-columns: repeat(auto-fit, minmax(20px, 1fr)); align-items: end; gap: 5px; min-height: 220px; padding: 20px 4px 2px; border-top: 1px solid rgba(148, 163, 184, 0.16); }
.usage-trend-day { display: grid; grid-template-rows: 168px auto; align-items: end; min-width: 0; text-align: center; }
.usage-trend-bars { display: flex; align-items: end; justify-content: center; gap: 2px; height: 160px; }
.usage-trend-bars i { display: block; width: min(9px, 42%); height: var(--usage-bar); min-height: 2px; border-radius: 5px 5px 2px 2px; background: linear-gradient(#5f8df6, #2563eb); }
.usage-trend-bars i + i { background: linear-gradient(#a88af5, #7c3aed); }
.usage-trend-day span { overflow: hidden; color: #8290a6; font-size: 9px; white-space: nowrap; text-overflow: ellipsis; }
.usage-table-wrap { overflow-x: auto; border: 1px solid rgba(37, 99, 235, 0.12); border-radius: 14px; background: rgba(255, 255, 255, 0.76); }
.usage-table { width: 100%; min-width: 880px; border-collapse: collapse; }
.usage-table th,
.usage-table td { padding: 12px 14px; border-bottom: 1px solid rgba(148, 163, 184, 0.16); color: #2d405c; font-size: 13px; text-align: left; vertical-align: middle; }
.usage-table th { background: #f2f7ff; color: #315071; font-size: 12px; font-weight: 900; }
.usage-table td strong,
.usage-table td small { display: block; }
.usage-table td strong { color: #132a4a; }
.usage-table td small { margin-top: 4px; color: #7c899c; font-size: 11px; }
.usage-table td b { color: #1e3a5f; font-variant-numeric: tabular-nums; }
.usage-rate,
.usage-result { display: inline-flex; align-items: center; min-height: 27px; padding: 4px 9px; border-radius: 999px; background: #eef2f7; color: #52657e; font-size: 11px; font-weight: 850; white-space: nowrap; }
.usage-rate.is-good,
.usage-result.is-success { background: #e9f9f1; color: #087956; }
.usage-result.is-failed { background: #fff0f0; color: #c93434; }
.usage-empty { padding: 28px !important; color: #8290a6 !important; text-align: center !important; }

@media (max-width: 1440px) {
  .usage-kpi-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .usage-analytics-toolbar { grid-template-columns: minmax(240px, 1fr) 120px minmax(260px, 360px) auto; }
}

@media (max-width: 900px) {
  .usage-analytics-toolbar { grid-template-columns: 1fr; align-items: stretch; }
  .usage-analytics-toolbar .ghost-action { min-height: 44px; justify-content: center; }
  .usage-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .usage-trend { min-width: 620px; }
  .usage-trend-card { overflow-x: auto; }
}

@media (max-width: 520px) {
  .usage-kpi-grid { grid-template-columns: 1fr; }
  .usage-kpi-card { padding: 16px; }
}


/* Tencent image-search isolated test banner */
.tencent-test-banner {
  position: fixed; top: 12px; right: 16px; z-index: 10000;
  max-width: calc(100vw - 32px); padding: 8px 12px;
  border: 1px solid rgba(37, 99, 235, .22); border-radius: 999px;
  background: rgba(239, 246, 255, .94); box-shadow: 0 8px 24px rgba(15, 23, 42, .10);
  color: #1d4ed8; font-size: 12px; font-weight: 850; line-height: 1.25;
  backdrop-filter: blur(10px);
}
@media (max-width: 600px) {
  .tencent-test-banner { top: 8px; right: 8px; padding: 6px 9px; font-size: 10px; }
}
