* { margin: 0; padding: 0; box-sizing: border-box; }
:root {
  --primary: #7c6cf0;
  --primary-dark: #6a5ce6;
  --primary-light: #f0edff;
  --bg: #f4f6fb;
  --card: #fff;
  --border: #e8eaf3;
  --text: #1f2330;
  --muted: #8b90a5;
  --success: #22c55e;
  --warn: #f59e0b;
  --error: #ef4444;
  --sidebar-w: 220px;
}
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; background: var(--bg); color: var(--text); min-height: 100vh; }

.app { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); background: var(--card); border-right: 1px solid var(--border);
  display: flex; flex-direction: column; flex-shrink: 0;
}
.brand-card {
  display: flex; align-items: center; gap: 12px; padding: 18px 14px;
  margin: 12px 10px; border-radius: 14px;
  background: linear-gradient(135deg, var(--primary), #9b8df8); color: #fff;
}
.brand-logo {
  width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.2);
  display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 16px;
  flex-shrink: 0;
}
.brand-logo-img {
  width: 42px; height: 42px; border-radius: 12px; object-fit: cover; flex-shrink: 0;
  background: rgba(255,255,255,.15);
}
.brand-card h1 { font-size: 16px; font-weight: 700; }
.brand-card p { font-size: 10px; opacity: .9; margin-top: 2px; }
.nav-ico { width: 20px; text-align: center; }
.vip-tag {
  font-size: 9px; padding: 2px 6px; border-radius: 999px;
  background: linear-gradient(135deg, #fbbf24, #f59e0b); color: #fff; margin-left: 4px;
}
.badge.hot { margin-left: auto; font-size: 9px; padding: 2px 6px; border-radius: 999px; background: rgba(255,255,255,.25); color: inherit; }
.badge.lock { background: #fff4e6; color: #d97706; font-weight: 600; }
.nav-item.active .badge.lock { background: rgba(255,255,255,.35); color: #fff; }
.nav-item--locked { color: #666; }
.nav-item--locked:hover { background: #f5f6fa; }
.nav-item.active .badge.hot { background: rgba(255,255,255,.3); }
.sidebar-footer { margin-top: auto; border-top: 1px solid var(--border); }
.update-log { padding: 10px 14px; font-size: 12px; color: var(--muted); display: flex; justify-content: space-between; }
.update-log .ver { color: var(--primary); font-weight: 600; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.nav { padding: 12px 8px; flex: 1; }
.nav-item {
  display: flex; align-items: center; gap: 10px; padding: 11px 14px; margin-bottom: 4px;
  border-radius: 10px; cursor: pointer; font-size: 14px; color: #555; transition: .15s;
}
.nav-item:hover { background: #f5f6fa; }
.nav-item.active { background: linear-gradient(135deg, var(--primary), #9b8df8); color: #fff; font-weight: 600; }
.nav-item .badge { margin-left: auto; font-size: 10px; padding: 2px 6px; border-radius: 999px; background: #ffe4e6; color: #e11; }
.nav-section { font-size: 11px; color: var(--muted); padding: 12px 14px 6px; }

.sidebar-config { padding: 12px; border-top: 1px solid var(--border); }
.sidebar-config label { font-size: 11px; color: var(--muted); display: block; margin-bottom: 4px; }
.sidebar-config input {
  width: 100%; padding: 7px 10px; border: 1px solid var(--border); border-radius: 8px;
  font-size: 12px; margin-bottom: 8px;
}

.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  background: var(--card); border-bottom: 1px solid var(--border); padding: 14px 24px;
  display: flex; align-items: center; justify-content: space-between;
}
.topbar h2 { font-size: 20px; font-weight: 700; color: var(--primary); }
.topbar-meta { font-size: 12px; color: var(--muted); }

.page { display: none; flex: 1; padding: 20px 24px; overflow: auto; }
.page.active { display: block; }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 1100px) { .two-col { grid-template-columns: 1fr; } }

.card {
  background: var(--card); border-radius: 16px; border: 1px solid var(--border);
  box-shadow: 0 4px 20px rgba(124,108,240,.06); padding: 20px;
}
.card-title { font-size: 15px; font-weight: 700; margin-bottom: 16px; display: flex; align-items: center; gap: 8px; }
.card-title-row { justify-content: space-between; flex-wrap: wrap; gap: 8px; }

.profile-field { margin-top: 16px; }
.profile-field > label { display: block; margin-bottom: 8px; font-size: 13px; font-weight: 600; color: var(--text); }
.profile-input {
  width: 100%; padding: 8px 12px; border-radius: 8px; border: 1px solid var(--border);
  background: var(--card); color: var(--text); font-size: 14px; font-family: inherit; margin-bottom: 8px;
}
.profile-input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,108,240,.12); }
.profile-redeem-row { display: flex; gap: 8px; align-items: stretch; }
.profile-redeem-row .profile-input { flex: 1; margin-bottom: 0; }
.profile-buy-link { margin-top: 8px; }

.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: #444; }
.field label .req { color: var(--error); }
.field-hint { font-size: 11px; color: var(--muted); margin-top: 4px; }
textarea, select, input[type=text], input[type=password], input[type=number] {
  width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 10px;
  font-size: 14px; font-family: inherit; background: #fafbff;
}
textarea { min-height: 100px; resize: vertical; }
textarea:focus, select:focus, input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(124,108,240,.12); }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 18px; border-radius: 10px; border: none; font-size: 14px; font-weight: 600;
  cursor: pointer; transition: .15s;
}
.btn-primary { background: linear-gradient(135deg, var(--primary), #9b8df8); color: #fff; }
.btn-primary:hover { filter: brightness(1.05); }
.btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.btn-outline { background: #fff; border: 1px solid var(--primary); color: var(--primary); }
.btn-ghost { background: #f5f6fa; color: #555; }
.btn-block { width: 100%; padding: 13px; font-size: 15px; border-radius: 12px; }
.btn-sm { padding: 6px 12px; font-size: 12px; border-radius: 8px; }

.ref-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.ref-grid.ref-grid-omni { grid-template-columns: repeat(5, 1fr); }
.ref-grid.ref-grid-frames { grid-template-columns: repeat(2, 1fr); }
.ref-grid.ref-grid-7 { grid-template-columns: repeat(4, 1fr); }
@media (min-width: 720px) { .ref-grid.ref-grid-7 { grid-template-columns: repeat(7, 1fr); } }
.ref-grid-8 { grid-template-columns: repeat(4, 1fr); }
.ref-grid.drag-over { opacity: 0.85; outline: 2px dashed var(--primary); border-radius: 12px; }
@media (min-width: 600px) { .ref-grid-8 { grid-template-columns: repeat(4, 1fr); } }

.seg-control { display: flex; gap: 8px; flex-wrap: wrap; }
.seg-control.seg-dur .seg { flex: 1; min-width: 56px; text-align: center; padding: 10px 8px; }
.omni-flash-badge {
  padding: 12px 16px; border-radius: 12px; border: 1px solid var(--border);
  background: #fafbff; font-weight: 600; font-size: 14px;
}
.seg-control .seg {
  flex: 1; min-width: 120px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--border);
  background: #fafbff; font-size: 12px; cursor: pointer; transition: .15s;
}
.seg-control .seg.active { background: var(--primary-light); border-color: var(--primary); color: var(--primary); font-weight: 600; }

.table-scroll { overflow: auto; margin: 12px 0; border: 1px solid var(--border); border-radius: 12px; }

.filter-card { background: #f8f9fd; border-radius: 12px; padding: 16px; margin-bottom: 16px; }
.filter-title { font-weight: 700; margin-bottom: 12px; display: flex; align-items: center; justify-content: space-between; }
.filter-grid { display: grid; grid-template-columns: 2fr 1fr 1fr auto; gap: 12px; align-items: end; }
@media (max-width: 900px) { .filter-grid { grid-template-columns: 1fr 1fr; } }
.date-range { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.date-range input { flex: 1; min-width: 140px; font-size: 12px; padding: 8px; }
.btn-row { display: flex; gap: 8px; }
.batch-bar { margin-top: 0; }

.pagination-bar {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 12px; margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); font-size: 13px;
}
.pag-left, .pag-center, .pag-right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.page-jump-input { width: 56px; padding: 6px 8px; border: 1px solid var(--border); border-radius: 8px; }

.progress-cell { min-width: 80px; }
.progress-bar {
  height: 6px; background: #e8eaf3; border-radius: 999px; overflow: hidden; margin-top: 4px;
}
.progress-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), #9b8df8); border-radius: 999px; transition: width .3s; }
.task-id { font-family: monospace; font-size: 11px; color: var(--muted); }

.route-pills { display: flex; flex-wrap: wrap; gap: 4px; }
.route-pill {
  padding: 2px 8px; border-radius: 999px; font-size: 10px; border: 1px solid var(--primary-light);
  background: var(--primary-light); color: var(--primary); text-decoration: none; cursor: pointer;
}
.route-pill:hover { background: var(--primary); color: #fff; }
button.route-pill { font: inherit; appearance: none; }

.stats-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.stat-item {
  background: #f8f9fd; border-radius: 12px; padding: 16px; text-align: center;
}
.stat-num { display: block; font-size: 28px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 12px; color: var(--muted); margin-top: 4px; }

.modal {
  position: fixed; inset: 0; background: rgba(0,0,0,.45); z-index: 1000;
  display: flex; align-items: center; justify-content: center; padding: 20px;
}
.modal.hidden { display: none !important; }
.modal-box {
  background: var(--card); border-radius: 16px; max-width: 560px; width: 100%;
  box-shadow: 0 20px 60px rgba(0,0,0,.2); overflow: hidden;
}
.modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; border-bottom: 1px solid var(--border);
}
.modal-head h3 { font-size: 16px; color: var(--primary); }
.modal-close { background: none; border: none; font-size: 24px; cursor: pointer; color: var(--muted); line-height: 1; }
.modal-body { padding: 20px; font-size: 14px; line-height: 1.8; }
.modal-body ol { padding-left: 20px; }
.modal-body li { margin-bottom: 8px; }
.ref-slot {
  aspect-ratio: 1; border: 2px dashed var(--border); border-radius: 12px; background: #fafbff;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  cursor: pointer; position: relative; overflow: hidden; font-size: 11px; color: var(--muted);
  transition: border-color .15s, background .15s;
}
.ref-slot:hover { border-color: var(--primary); background: var(--primary-light); }
.ref-slot .slot-label {
  position: absolute; top: 6px; left: 6px; z-index: 2;
  font-size: 10px; font-weight: 700; color: var(--primary);
  background: rgba(255,255,255,.9); padding: 2px 6px; border-radius: 6px;
}
.ref-slot .slot-plus { font-size: 22px; color: var(--primary); line-height: 1; }
.ref-slot .slot-hint { font-size: 10px; margin-top: 4px; }
.ref-slot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ref-slot .rm {
  position: absolute; top: 4px; right: 4px; width: 20px; height: 20px; border-radius: 50%;
  background: rgba(0,0,0,.65); color: #fff; border: none; cursor: pointer; z-index: 2;
}
.ref-counter {
  float: right; font-size: 12px; color: var(--primary); font-weight: 600;
}
.route-order-hint { margin-left: auto; font-size: 11px; }

.preview-empty {
  min-height: 360px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: var(--muted); text-align: center; gap: 12px;
}
.preview-empty .ico { font-size: 48px; opacity: .3; }
.preview-result video, .preview-result img { max-width: 100%; border-radius: 12px; margin-top: 8px; }

.info-box {
  background: var(--primary-light); border-left: 4px solid var(--primary);
  padding: 12px 14px; border-radius: 0 10px 10px 0; font-size: 12px; line-height: 1.7; color: #555;
  margin-bottom: 16px;
}
.warn-box { background: #fff7ed; border-left: 4px solid var(--warn); padding: 12px 14px; border-radius: 0 10px 10px 0; font-size: 12px; color: #924; margin-top: 12px; }
.error-box { background: #fef2f2; border-left: 4px solid var(--error); padding: 12px 14px; border-radius: 0 10px 10px 0; font-size: 12px; color: #991; margin-top: 12px; }

.model-tabs { display: flex; gap: 10px; margin-bottom: 16px; flex-wrap: wrap; }
.model-tab {
  flex: 1; min-width: 140px; padding: 14px; border-radius: 14px; cursor: pointer; text-align: center;
  background: linear-gradient(135deg, #e8e4ff, #f3f0ff); border: 2px solid transparent; transition: .15s;
}
.model-tab.active { border-color: var(--primary); box-shadow: 0 4px 16px rgba(124,108,240,.2); }
.model-tab h4 { font-size: 14px; margin-bottom: 4px; }
.model-tab p { font-size: 11px; color: var(--muted); }

.batch-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; }

.upload-two-col {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 16px;
}
@media (max-width: 768px) { .upload-two-col { grid-template-columns: 1fr; } }
.upload-block {
  background: #f8f9fd; border: 1px solid var(--border); border-radius: 14px; padding: 16px;
}
.upload-label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 10px; }
.upload-label .muted { font-weight: 400; color: var(--muted); font-size: 12px; }
.upload-btns { display: flex; flex-wrap: wrap; gap: 8px; }

.section-title { font-size: 14px; font-weight: 700; margin: 16px 0 10px; color: var(--primary); }
.info-box.warn-style { background: #fffbeb; border-left-color: var(--warn); }
.info-box.warn-style ul { margin: 8px 0 0 18px; }
.info-box.warn-style li { margin-bottom: 4px; }
.doc-table code { font-size: 12px; background: #f0edff; padding: 2px 6px; border-radius: 4px; }

.col-hidden { display: none !important; }
.col-settings label { display: block; margin-bottom: 10px; font-size: 14px; cursor: pointer; }
.col-settings input { margin-right: 8px; }

table.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
table.data-table th, table.data-table td { border: 1px solid var(--border); padding: 10px 12px; text-align: left; }
table.data-table th { background: #f8f9fd; font-weight: 600; }

.task-toolbar {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 14px;
  padding: 12px; background: #f8f9fd; border-radius: 12px;
}
.task-table-wrap { overflow: auto; max-height: calc(100vh - 280px); border: 1px solid var(--border); border-radius: 12px; }
.task-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.task-table thead tr {
  background: linear-gradient(135deg, var(--primary), #9b8df8); color: #fff;
}
.task-table th, .task-table td { padding: 10px 8px; border-bottom: 1px solid var(--border); text-align: left; white-space: nowrap; }
.task-table th { background: transparent; position: sticky; top: 0; z-index: 1; font-weight: 600; color: #fff; }
.task-table td.prompt { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.status-pill {
  display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 11px; font-weight: 600;
}
.status-pending { background: #f3f4f6; color: #666; }
.status-running { background: #fef9c3; color: #854; }
.status-success { background: #dcfce7; color: #166; }
.status-failed { background: #fee2e2; color: #991; }

.log-box {
  background: #1a1b26; color: #aaa; padding: 12px; border-radius: 10px; font-size: 12px;
  max-height: 180px; overflow: auto; white-space: pre-wrap; word-break: break-all; margin-top: 12px;
}

.task-error-hint {
  margin-top: 6px; font-size: 11px; line-height: 1.45; color: #c0392b;
  max-width: 280px; text-align: left;
}
.task-error-msg { font-size: 11px; color: #888; margin-top: 4px; word-break: break-all; }
.progress-stage { font-size: 11px; color: var(--muted); margin-bottom: 2px; }
.task-dl-btn { margin-right: 4px; }
.task-conc-label { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.task-conc-label select { padding: 4px 8px; border-radius: 6px; border: 1px solid var(--border); font-size: 12px; }
.hidden { display: none !important; }

body.theme-modern {
  --primary: #2563eb;
  --primary-light: #dbeafe;
}
body.theme-modern .brand-card {
  background: linear-gradient(135deg, #eff6ff, #f5f3ff);
}

body.dark {
  --bg: #12131a;
  --card: #1a1b26;
  --border: #2a2b3a;
  --text: #e1e1e6;
  --muted: #888;
  --primary-light: #2a2540;
}
html.theme-dark-boot { color-scheme: dark; }
body.dark .sidebar { background: var(--card); border-color: var(--border); }
body.dark .main { background: var(--bg); }
body.dark .topbar { background: var(--card); border-color: var(--border); }
body.dark .topbar h2 { color: #c4b5fd; }
body.dark .nav-item { color: #aaa; }
body.dark .nav-item:hover { background: #252636; }
body.dark .nav-item.active { background: linear-gradient(135deg, #5b4fc7, #7c6cf0); color: #fff; }
body.dark .brand-card { background: linear-gradient(135deg, #4c3d99, #6a5ce6); }
body.dark .card { box-shadow: none; border-color: var(--border); }
body.dark .card-title { color: var(--text); }
body.dark .field label { color: #ccc; }
body.dark .profile-field > label { color: #ccc; }
body.dark textarea, body.dark select, body.dark input[type=text], body.dark input[type=password], body.dark input[type=number] {
  background: #0f1117; color: #e1e1e6; border-color: var(--border);
}
body.dark .seg, body.dark .seg-control .seg { background: #0f1117; border-color: var(--border); color: #ccc; }
body.dark .seg.active, body.dark .seg-control .seg.active { background: var(--primary); color: #fff; border-color: var(--primary); }
body.dark .info-box { color: #ccc; background: #0f1117; border-color: var(--border); }
body.dark .task-table th { background: transparent; color: #fff; }
body.dark .task-toolbar { background: #1e1f2e; }
body.dark .btn-outline { background: transparent; border-color: var(--primary); color: #c4b5fd; }
body.dark .btn-ghost { background: #252636; color: #ccc; border: 1px solid var(--border); }
body.dark .btn-ghost:hover { background: #2a2b3a; }
body.dark .omni-flash-badge { background: #0f1117; border-color: var(--border); color: var(--text); }
body.dark .modal { background: rgba(0,0,0,.65); }
body.dark .modal-head { border-color: var(--border); }
body.dark .modal-foot { border-color: var(--border); }
body.dark .modal-head h3, body.dark .modal-head-title h3 { color: #c4b5fd; }
body.dark .sidebar-footer { border-color: var(--border); }
body.dark .update-log { color: var(--muted); }
body.dark a.https-folder-link { color: #a5b4fc; }

/* 多行批量 */
.multiline-input {
  min-height: 120px; font-family: inherit; font-size: 13px; line-height: 1.6;
  resize: vertical;
}
.multiline-rows { display: flex; flex-direction: column; gap: 12px; margin: 12px 0; max-height: 420px; overflow-y: auto; }
.ml-row-card {
  background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: 12px;
}
.ml-row-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.ml-row-num { font-weight: 700; color: var(--primary); font-size: 13px; }
.ml-prompt {
  width: 100%; min-height: 56px; border: 1px solid var(--border); border-radius: 8px;
  padding: 8px 10px; font: inherit; resize: vertical; background: var(--card); color: var(--text);
}
.ml-row-controls { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.ml-row-controls select {
  flex: 1; min-width: 90px; padding: 6px 8px; border-radius: 8px; border: 1px solid var(--border);
  font-size: 12px; background: var(--card); color: var(--text);
}
.ml-ref-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 6px; }
.ml-ref-thumb { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; cursor: pointer; border: 1px solid var(--border); }
.ml-model-hint { margin-top: 6px; font-size: 11px; }
.multiline-empty { text-align: center; padding: 16px; color: var(--muted); }

.preview-modal-box { max-width: 900px; }
.preview-modal-body { text-align: center; background: var(--bg); }
.modal-foot {
  display: flex; justify-content: flex-end; align-items: center; gap: 8px;
  padding: 12px 20px; border-top: 1px solid var(--border);
}
.announce-modal-box { max-width: 520px; }
.announce-modal-body {
  max-height: 50vh; overflow-y: auto; font-size: 14px; line-height: 1.75; color: var(--text);
}
.announce-modal-foot { justify-content: space-between; }
.announce-dismiss-label {
  display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); cursor: pointer;
}
.announce-dismiss-label input { width: 16px; height: 16px; cursor: pointer; }

/* 增强弹窗 */
.modal-box-enhanced { max-width: 520px; }
.modal-head-enhanced {
  padding: 18px 20px;
  background: linear-gradient(135deg, var(--primary-light), transparent);
}
.modal-head-title { display: flex; align-items: center; gap: 10px; }
.modal-head-title h3 { margin: 0; font-size: 16px; color: var(--primary); }
.modal-head-icon { font-size: 22px; line-height: 1; }
.modal-close-round {
  width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--border);
  display: inline-flex; align-items: center; justify-content: center;
}
.modal-lead { font-size: 15px; font-weight: 600; margin: 0 0 8px; color: var(--text); }

/* 联系方式 */
.contact-panel {
  margin-top: 16px; padding: 16px; border-radius: 12px;
  border: 1px solid var(--border); background: var(--bg);
}
.contact-panel-title { font-size: 14px; font-weight: 700; margin-bottom: 12px; color: var(--text); }
.contact-slot { padding: 0 20px 16px; }
.contact-slot--embed { padding: 0; }
.contact-slot--compact { padding: 12px 0 0; }
.contact-slot--modal-foot {
  padding: 0 20px 12px; border-top: 1px solid var(--border); margin-top: 4px; padding-top: 12px;
}
#announceModalContact.contact-slot--modal-foot { margin-top: 0; }
.contact-block {
  border: 1px solid var(--border); border-radius: 12px; padding: 16px;
  background: var(--bg); text-align: center;
}
.contact-block-title { font-size: 14px; font-weight: 600; margin-bottom: 12px; color: var(--text); }
.contact-tabs { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-bottom: 12px; }
.contact-tab {
  border: 1px solid var(--border); background: var(--card); color: var(--text);
  padding: 6px 12px; border-radius: 999px; font-size: 12px; cursor: pointer; transition: .15s;
}
.contact-tab:hover { border-color: var(--primary); }
.contact-tab.active {
  border-color: var(--primary); background: var(--primary-light); color: var(--primary); font-weight: 600;
}
.contact-qr-box {
  display: inline-flex; padding: 10px; background: #fff; border-radius: 12px;
  border: 1px solid var(--border); box-shadow: 0 4px 12px rgba(0,0,0,.06);
}
.contact-qr-img { width: 160px; height: 160px; object-fit: contain; display: block; }
.contact-block-hint { margin-top: 10px; margin-bottom: 0; }
.sidebar-footer { margin-top: auto; border-top: 1px solid var(--border); padding-bottom: 10px; }
.sidebar-contact { margin: 0 10px 10px; }
.sidebar-contact .contact-block--sidebar {
  background: #fff; border-radius: 12px; padding: 14px 12px 12px;
  border: 1px solid #e8eaf3; box-shadow: 0 4px 14px rgba(0,0,0,.06); text-align: center;
}
.sidebar-contact .contact-qr-wrap { display: flex; flex-direction: column; align-items: center; }
.sidebar-contact .contact-qr-box {
  padding: 0; border: none; box-shadow: none; background: transparent; width: 100%;
  display: flex; justify-content: center;
}
.sidebar-contact .contact-qr-img { width: 100%; max-width: 176px; height: auto; aspect-ratio: 1; object-fit: contain; }
.sidebar-contact .contact-sidebar-label {
  margin-top: 10px; font-size: 13px; font-weight: 600; color: #333; letter-spacing: 0.02em;
}
.sidebar-contact .contact-tabs { margin-bottom: 10px; gap: 6px; }
.sidebar-contact .contact-tab { padding: 4px 10px; font-size: 11px; }
.contact-block--large .contact-qr-img { width: 200px; height: 200px; }
.contact-block--large .contact-qr-box { padding: 12px; }
.contact-block--large .contact-block-title { font-size: 15px; margin-bottom: 14px; }

.route-pill.danger-text { color: #c0392b; border-color: #fecaca; background: #fff5f5; }
.route-pill.danger-text:hover { background: #c0392b; color: #fff; }
.https-folder-link { color: var(--primary); text-decoration: underline; }
.https-folder-link:hover { opacity: 0.85; }

body.dark .stat-item { background: #1e1f2e; }
body.dark table.data-table th { background: #1e1f2e; color: var(--text); }
body.dark .info-box.warn-style { background: #2a2410; color: #fbbf24; border-left-color: #f59e0b; }
body.dark .doc-table code { background: #2a2540; color: #c4b5fd; }
body.dark .filter-card { background: var(--card); }
body.dark .ref-slot { background: #0f1117; }
body.dark .ref-slot .slot-label { background: rgba(26,27,38,.92); color: #c4b5fd; }
body.dark .status-pending { background: #2a2b3a; color: #aaa; }
body.dark .status-running { background: #3a3418; color: #fbbf24; }
body.dark .status-success { background: #143024; color: #86efac; }
body.dark .status-failed { background: #3a1818; color: #fca5a5; }
body.dark .progress-bar { background: #2a2b3a; }
body.dark .ml-row-card { background: #0f1117; }
body.dark .modal-box { background: var(--card); }
body.dark .modal-head-enhanced { background: linear-gradient(135deg, #2a2540, transparent); }
body.dark .modal-close-round { background: #0f1117; }
body.dark .modal-lead { color: var(--text); }
body.dark .contact-block { background: #0f1117; }
body.dark .contact-panel { background: #0f1117; border-color: var(--border); }
body.dark .contact-panel-title { color: var(--text); }
body.dark .contact-tab { background: #1a1b26; color: #ccc; }
body.dark .contact-tab.active { background: #2a2540; color: #c4b5fd; }
body.dark .contact-qr-box { background: #fff; }
body.dark .contact-slot--modal-foot { border-color: var(--border); }
body.dark .btn-primary { background: linear-gradient(135deg, #5b4fc7, #7c6cf0); color: #fff; }
body.dark .btn-primary:hover { filter: brightness(1.08); }
body.dark .col-settings { color: var(--text); }
body.dark .modal-close-round:hover { background: #252636; }
body.dark input[type=datetime-local] { background: #0f1117; color: #e1e1e6; border-color: var(--border); }
body.dark .warn-box { background: #2a2410; border-color: #f59e0b; color: #fde68a; }
body.dark .preview-empty { color: var(--muted); }
body.dark .stat-num { color: #c4b5fd; }
body.dark .stat-label { color: var(--muted); }
body.dark .topbar-meta { color: var(--muted); }
body.dark .task-table td { color: var(--text); }
body.dark .task-table-wrap { border-color: var(--border); }
body.dark .task-error-msg { color: #888; }
body.dark .task-error-hint { color: #fca5a5; }
body.dark .model-tab { background: #1e1f2e; border-color: transparent; color: var(--text); }
body.dark .model-tab.active { border-color: var(--primary); box-shadow: 0 4px 16px rgba(124,108,240,.25); }
body.dark .model-tab p { color: var(--muted); }
body.dark .upload-block { background: #0f1117; border-color: var(--border); }
body.dark .error-box { background: #3a1818; color: #fca5a5; border-left-color: #ef4444; }
body.dark .pagination-bar { border-color: var(--border); color: var(--text); }
body.dark .page-jump-input { background: #0f1117; color: var(--text); border-color: var(--border); }
body.dark .route-pill { background: #2a2540; border-color: #3d3560; color: #c4b5fd; }
body.dark .route-pill:hover { background: var(--primary); color: #fff; }
body.dark .route-pill.danger-text { background: #3a1818; border-color: #7f1d1d; color: #fca5a5; }
body.dark .col-settings label { color: var(--text); }
body.dark .profile-input { background: #0f1117; color: #e1e1e6; border-color: var(--border); }
body.dark .field-hint a, body.dark #buyRedeemLink { color: #a5b4fc; }
body.dark .table-scroll { border-color: var(--border); }
body.dark table.data-table td { color: var(--text); border-color: var(--border); }
body.dark .nav-item .badge { background: #3a1818; color: #fca5a5; }
body.dark .nav-item--locked { color: #999; }
body.dark .nav-item--locked:hover { background: #252636; }
body.dark .badge.lock { background: #3a2a10; color: #fbbf24; }
body.dark .nav-item.active .badge.lock { background: rgba(255,255,255,.25); color: #fff; }
body.dark .sidebar-contact .contact-block--sidebar { background: #fff; border-color: #e8eaf3; }
body.dark .sidebar-contact .contact-sidebar-label { color: #333; }
body.dark .nav-item.active .badge { background: rgba(255,255,255,.25); color: #fff; }
body.dark .seg-control .seg.active { color: #fff; }
body.dark .announce-modal-body { color: var(--text); }
body.dark .announce-dismiss-label { color: var(--muted); }
body.dark .modal-close { color: var(--muted); }
body.dark .modal-close-round { color: var(--muted); }
body.dark .log-box { background: #0a0b10; color: #aaa; }
