* { box-sizing: border-box; }
[hidden] { display: none !important; }
/* Apply the persisted Worker view before the deferred admin script runs. */
html[data-worker-view="table"] .worker-channel-frame .worker-card-view { display: none; }
html[data-worker-view="table"] .worker-channel-frame .worker-table-view[hidden] { display: block !important; }
html[data-worker-view="table"] .worker-channel-frame .worker-card-view:not([hidden]) { display: block; }
html[data-worker-view="table"] .worker-channel-frame .worker-card-view:not([hidden]) ~ .worker-table-view { display: none !important; }
html, body { margin: 0; min-height: 100%; }
body { background: var(--bg); color: var(--text); font-family: Inter, "Segoe UI", Arial, sans-serif; font-size: 14px; letter-spacing: 0; }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.shell { min-height: 100vh; display: grid; grid-template-columns: 224px minmax(0, 1fr); }
.brand { display: flex; align-items: center; gap: 10px; padding: 2px 8px 10px; color: var(--nav-text-strong); font-size: 16px; font-weight: 700; }
.brand svg { width: 20px; height: 20px; color: var(--accent); }
.nav { display: grid; gap: 4px; }
.nav a { color: var(--nav-text); display: flex; align-items: center; gap: 10px; min-height: 38px; padding: 8px 10px; border-radius: 6px; }
.nav a:hover, .nav a.active { color: var(--nav-text-strong); background: var(--nav-surface); text-decoration: none; }
.nav svg { width: 17px; height: 17px; }
.content { min-width: 0; padding: 24px clamp(18px, 3vw, 42px) 44px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; }
.button, button { min-height: 34px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 7px; }
.button:hover, button:hover { border-color: var(--line-strong); text-decoration: none; }
.button:disabled, button:disabled { cursor: not-allowed; opacity: .55; }
.button.primary, button.primary { background: var(--accent); border-color: var(--accent); color: var(--text-on-strong); }
.button.danger, button.danger { color: var(--danger); border-color: var(--danger-soft); }
.button svg, button svg { width: 16px; height: 16px; }
.notice { margin-bottom: 16px; padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--accent-soft); color: var(--accent-hover); }
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 22px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 14px 16px; }
.stat-label { color: var(--muted); font-size: 12px; text-transform: uppercase; }
.stat-value { display: block; margin-top: 6px; font-size: 25px; font-weight: 700; }
.stat small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.dashboard-capacity-ring { --ring-color: var(--accent); --capacity-percent: 100; flex: 0 0 auto; width: 74px; height: 74px; display: grid; place-items: center; border-radius: 50%; background: conic-gradient(var(--ring-color) calc(var(--capacity-percent) * 1%), var(--surface-muted) 0); color: var(--ring-color); }
.dashboard-capacity-ring::before { content: ""; grid-area: 1 / 1; width: 58px; height: 58px; border-radius: 50%; background: var(--surface); }
.dashboard-capacity-ring span { grid-area: 1 / 1; position: relative; z-index: 1; max-width: 54px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 23px; font-weight: 800; }
.dashboard-capacity-ring.warning { --ring-color: var(--warning); }
.dashboard-capacity-ring.shortage { --ring-color: var(--danger); background: var(--ring-color); }
.dashboard-coupon-result.successful { background: var(--accent-soft); color: var(--accent-hover); font-weight: 700; }
.dashboard-coupon-result.not-successful { background: var(--surface-muted); color: var(--muted); font-weight: 600; }
.dashboard-coupon-result.undetermined { background: var(--warning-soft); color: var(--warning); font-weight: 700; }
.panel { margin-bottom: 20px; }
.panel-header { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.panel-header h2 { margin: 0; font-size: 16px; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); background: var(--surface); }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--surface-muted); text-align: left; vertical-align: middle; white-space: nowrap; }
th { background: var(--surface); color: var(--text-soft); font-size: 12px; font-weight: 600; }
tbody tr:last-child td { border-bottom: 0; }
/* 全站空状态：表格单元格与网格容器共用这一份。网格里要跨满所有列，表格里必须显式提高
   特异性，否则会被 .admin-data-table td 的 text-align: left 盖掉（那正是空状态看着左对齐的原因）。 */
.empty, .admin-data-table td.empty { grid-column: 1 / -1; margin: 0; padding: 28px 14px; color: var(--muted); text-align: center; }
.task-history-layout { min-width: 0; display: grid; grid-template-columns: 176px minmax(0, 1fr); align-items: start; }
.worker-region-content, .worker-detail-content { min-width: 0; padding-left: 18px; }
.sign-channel-frame.worker-channel-frame { padding-left: 0; border-top: 0; }
.worker-channel-frame .sign-filter-menu { left: auto; right: 0; z-index: 20; }
.settings-content { min-width: 0; padding-left: 18px; }
.settings-form { max-width: 760px; border: 1px solid var(--line); background: var(--surface); padding: 18px; }
.settings-form .panel-header { align-items: flex-start; }
.settings-form .panel-header h2 { margin: 0; font-size: 17px; }
.settings-form .panel-header p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.settings-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.settings-grid .settings-wide { grid-column: 1 / -1; }
.settings-grid .settings-wide:has(#worker-release-endpoint) { grid-column: auto; }
.settings-grid .field:has(#worker-release-channel) { grid-column: 2; grid-row: 1; align-self: start; align-content: start; }
.settings-grid .field:has(#worker-release-manifest) { grid-column: 1; grid-row: 2; }
.settings-grid .field:has(#worker-release-prefix) { grid-column: 2; grid-row: 2; }
.settings-form output { display: block; min-height: 42px; box-sizing: border-box; border: 1px solid var(--line); border-radius: 5px; padding: 10px 12px; background: var(--surface); color: var(--text); overflow-wrap: anywhere; }
.settings-actions { display: flex; justify-content: center; margin-top: 18px; }
.settings-retention-grid { grid-template-columns: minmax(0, 280px); }
.settings-release-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0; }
.settings-release-facts > div { min-width: 0; border-left: 2px solid var(--surface-muted); padding-left: 8px; }
.settings-release-facts dt { color: var(--muted); font-size: 11px; }
.settings-release-facts dd { min-width: 0; margin: 3px 0 0; overflow-wrap: anywhere; font-size: 12px; font-weight: 650; }
.settings-release-check { width: 34px; height: 34px; min-height: 34px; padding: 6px; border-color: transparent; background: transparent; color: var(--accent); box-shadow: none; }
.settings-release-check:hover, .settings-release-check:focus-visible { border-color: transparent; background: transparent; color: var(--accent-hover); }
.settings-release-target-version { display: flex; align-items: center; gap: 8px; }
.settings-release-update-form { display: inline-flex; margin: 0; }
.settings-release-update { width: 30px; height: 30px; min-height: 30px; padding: 5px; border-color: transparent; color: var(--danger); background: transparent; box-shadow: none; }
.settings-release-update:hover, .settings-release-update:focus-visible { border-color: transparent; background: transparent; color: var(--danger); }
.settings-release-update:disabled { color: var(--muted); background: transparent; }
@media (max-width: 640px) { .settings-release-facts { grid-template-columns: minmax(0, 1fr); } }
.worker-offline-toggle { display: inline-flex; align-items: center; gap: 6px; height: 32px; border-radius: 999px; padding: 0 12px; background: var(--surface-muted); color: var(--text-soft); font-size: 13px; font-weight: 600; white-space: nowrap; text-decoration: none; }
/* 与活动页的「暂停 / 运行」状态同色：离线 = --warning，在线 = --success */
.worker-offline-toggle.is-offline { background: var(--warning-soft); color: var(--warning); }
.worker-offline-toggle.is-online { background: var(--success-soft); color: var(--success); }
.worker-offline-toggle.is-offline:hover, .worker-offline-toggle.is-offline:focus-visible { background: color-mix(in srgb, var(--warning) 20%, var(--warning-soft)); color: var(--warning); text-decoration: none; }
.worker-offline-toggle.is-online:hover, .worker-offline-toggle.is-online:focus-visible { background: color-mix(in srgb, var(--success) 20%, var(--success-soft)); color: var(--success); text-decoration: none; }
.worker-offline-toggle svg { width: 13px; height: 13px; }
.worker-execution-stats { min-width: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0 0 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.worker-execution-stats > div { min-width: 0; border-right: 1px solid var(--surface-muted); padding: 8px 12px; }
.worker-execution-stats > div:last-child { border-right: 0; }
.worker-execution-stats dt { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.worker-execution-stats dd { min-width: 0; margin: 2px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 700; }
.worker-session-heading h3 { margin: 0; font-size: 14px; }
.worker-session-heading span { color: var(--muted); font-size: 11px; }
.worker-detail-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 14px; }
.worker-detail-tabs a { min-height: 38px; display: inline-flex; align-items: center; gap: 7px; border-bottom: 2px solid transparent; padding: 7px 11px; color: var(--muted); text-decoration: none; }
.worker-detail-tabs a:hover { color: var(--text); background: var(--surface-muted); }
.worker-detail-tabs a.active { border-color: var(--accent); color: var(--accent); font-weight: 700; }
.worker-detail-tabs svg { width: 16px; height: 16px; }
.worker-detail-tabs span { min-width: 22px; border-radius: 999px; padding: 1px 5px; background: var(--surface-muted); color: var(--muted); font-size: 11px; text-align: center; }
.worker-detail-tabs a.active span { background: var(--line); color: var(--accent); }
.worker-detail-panel { min-width: 0; }
.worker-session-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 0 0 8px; }
.worker-task-table table { min-width: 1250px; }
.worker-task-table th, .worker-task-table td { white-space: nowrap; }
.worker-task-table td:nth-child(2) { max-width: 210px; overflow: hidden; text-overflow: ellipsis; }
.worker-task-error { max-width: 240px; overflow: hidden; text-overflow: ellipsis; }
.worker-card-list { min-width: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
/* ------------------------------------------------------------
   Worker 标签管理页（/admin/worker-labels）
   外壳与其它列表页一致：crumbbar + surface + 工具条 + 二级栏 + 填充体 + 统一分页。
   标签导航从 176px 竖排侧栏改成二级栏里的 chips（与 Worker 地区、Store 分组同构），
   顺带退役了全项目最后一份 176px 双栏布局壳与整套抽屉样式。
   ------------------------------------------------------------ */
.worker-label-surface { overflow: hidden; }
.worker-label-toolbar { flex: 0 0 auto; }
/* 标签多时 chips 自己横向滚动，不要把二级栏撑高 */
.worker-label-tabs { flex-wrap: nowrap; }

.worker-label-detail {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding: 13px var(--sp-6);
  border-bottom: 1px solid var(--line);
}
.worker-label-detail-title { min-width: 0; flex: 0 0 auto; }
.worker-label-detail-title > span { color: var(--muted); font-size: 11px; }
.worker-label-detail-title h2 { margin: 3px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 17px; }
.worker-label-impact { flex: 1 1 auto; min-width: 0; display: flex; align-items: center; gap: var(--sp-2); margin: 0; }
.worker-label-impact > div { min-width: 0; display: flex; align-items: baseline; gap: 6px; border: 1px solid var(--line); border-radius: var(--radius-control); padding: 6px 11px; background: var(--surface-soft); }
.worker-label-impact dt { color: var(--muted); font-size: 11px; white-space: nowrap; }
.worker-label-impact dd { margin: 0; font-size: 15px; font-weight: 750; font-variant-numeric: tabular-nums; }
.worker-label-impact .warning dd { color: var(--warning); }
.worker-label-delete-inline { flex: 0 0 auto; margin: 0; }

.worker-label-warning { flex: 0 0 auto; display: flex; align-items: flex-start; gap: 9px; border-bottom: 1px solid var(--line); padding: 10px var(--sp-6); background: var(--warning-soft); color: var(--warning); }
.worker-label-warning svg { flex: 0 0 auto; width: 16px; height: 16px; margin-top: 1px; }
.worker-label-warning strong { font-size: 12.5px; }
.worker-label-warning p { margin: 3px 0 0; font-size: 12px; line-height: 1.5; }

/* 批量：与 Worker 列表 / 执行任务同构 —— 工具栏开关 + 顶部批量条，不再用底部浮层胶囊 */
.worker-label-batch-bar { flex: 0 0 auto; display: flex; align-items: center; gap: var(--sp-3); min-height: 54px; padding: 10px var(--sp-6); border-bottom: 1px solid var(--line); background: var(--accent-soft); }
.worker-label-batch-bar[hidden] { display: none; }
.worker-label-batch-bar strong { color: var(--text); font-size: 13px; font-weight: 650; white-space: nowrap; }
.worker-label-batch-divider { width: 1px; height: 24px; background: var(--line-strong); opacity: .6; }
.worker-label-batch-bar button { display: inline-flex; align-items: center; gap: 6px; height: 32px; min-height: 0; padding: 0 12px; border: 1px solid var(--line); border-radius: var(--radius-control); background: var(--surface); color: var(--text-soft); font-size: 13px; font-weight: 550; white-space: nowrap; cursor: pointer; }
.worker-label-batch-bar button:hover, .worker-label-batch-bar button:focus-visible { border-color: var(--line-strong); background: var(--surface-soft); color: var(--text); }
.worker-label-batch-bar button.danger { border-color: var(--danger-soft); color: var(--danger); }
.worker-label-batch-bar button.danger:hover, .worker-label-batch-bar button.danger:focus-visible { border-color: var(--danger); background: var(--danger-soft); color: var(--danger); }
.worker-label-batch-bar button svg { width: 14px; height: 14px; }
.worker-label-batch-close { margin-left: auto; }

/* 选择列只在批量管理打开时出现（与 Worker 列表的 selection-mode 同构） */
.worker-label-pick { width: 44px; text-align: center; }
.worker-label-worker-table th.worker-label-pick,
.worker-label-worker-table td.worker-label-pick { display: none; }
.worker-label-frame.selection-mode .worker-label-worker-table th.worker-label-pick,
.worker-label-frame.selection-mode .worker-label-worker-table td.worker-label-pick { display: table-cell; }
.worker-label-worker-table table { min-width: 720px; }
/* 五列显式分配空间：Worker 与标签都需要承载可变长度内容，IP / 地区 / 状态保持均衡。
   旧的 18/14/12/12 + 标签 auto 会把宽屏剩余空间集中到标签列，Worker 名称反而没有余量；
   现在 Worker 与标签各 28%，短列为 16/14/14%。窄屏继续依靠 720px 下限和横向滚动，
   不压缩 nowrap 的机器名、IP 与状态徽章。批量选择列显示时会额外占用其固定点击区宽度。 */
.worker-label-worker-table th:nth-child(2), .worker-label-worker-table td:nth-child(2) { width: 28%; white-space: nowrap; }
.worker-label-worker-table th:nth-child(3), .worker-label-worker-table td:nth-child(3) { width: 16%; white-space: nowrap; }
.worker-label-worker-table th:nth-child(4), .worker-label-worker-table td:nth-child(4) { width: 14%; white-space: nowrap; }
.worker-label-worker-table th:nth-child(5), .worker-label-worker-table td:nth-child(5) { width: 14%; white-space: nowrap; }
.worker-label-worker-table th:nth-child(6), .worker-label-worker-table td:nth-child(6) { width: 28%; }
.worker-label-worker-table code { font-size: 12.5px; }

.worker-label-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.worker-label-chips .worker-label-chip { min-height: 22px; padding: 2px 9px; font-size: 11.5px; }
.worker-label-none { color: var(--muted); font-size: 12px; }

@media (max-width: 900px) {
  .worker-label-surface { overflow: visible; }
  .worker-label-detail { flex-wrap: wrap; gap: var(--sp-2); padding: 12px var(--sp-4); }
  .worker-label-impact { flex: 1 1 100%; flex-wrap: wrap; }
  .worker-label-warning { padding: 10px var(--sp-4); }
  .worker-label-batch-bar { flex-wrap: wrap; padding: 10px var(--sp-4); }
  .worker-label-batch-close { margin-left: 0; }
}

.worker-label-batch-dialog { width: min(360px, calc(100vw - 28px)); max-width: calc(100vw - 28px); border: 1px solid var(--line); border-radius: 8px; padding: 0; background: var(--surface); color: var(--text); box-shadow: 0 24px 70px rgb(var(--shadow-rgb) / .28); }
.worker-label-batch-dialog form { display: grid; gap: 14px; padding: 16px; }
.worker-label-batch-dialog header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.worker-label-batch-dialog h2 { margin: 0; font-size: 16px; }
.worker-label-batch-dialog label { display: grid; gap: 6px; color: var(--muted); font-size: 12px; font-weight: 600; }
.worker-label-batch-dialog input { width: 100%; }
.worker-label-batch-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; }
.worker-card { position: relative; min-width: 0; min-height: 172px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 6px; padding: 14px 16px; background: var(--surface); color: var(--text); }
.worker-card-select { position: absolute; z-index: 2; top: 12px; left: 12px; display: none; align-items: center; justify-content: center; width: 24px; height: 24px; cursor: pointer; }
.worker-card-select input { position: absolute; opacity: 0; pointer-events: none; }
.worker-card-select span { width: 21px; height: 21px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgb(var(--shadow-rgb) / 8%); }
.worker-card-select input:checked + span { border-color: var(--accent); background: var(--accent); box-shadow: inset 0 0 0 5px var(--surface); }
.worker-channel-frame.selection-mode .worker-card-select { display: inline-flex; }
.worker-channel-frame.selection-mode .worker-card { padding-left: 48px; }
.worker-channel-frame.selection-mode .worker-card:has([data-worker-select]:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.worker-view-panel { min-width: 0; min-height: 0; }
.admin-table-view { overflow: hidden; padding: 0 16px 16px; }
.admin-table-scroll { height: 100%; overflow: auto; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.admin-data-table { width: 100%; min-width: 920px; border-collapse: collapse; font-size: 12px; }
.admin-data-table th, .admin-data-table td { border-bottom: 1px solid var(--surface-muted); padding: 10px 12px; text-align: left; vertical-align: middle; white-space: nowrap; }
.admin-data-table th { position: sticky; top: 0; z-index: 1; background: var(--surface); color: var(--muted); font-size: 11px; font-weight: 700; }
.admin-data-table tbody tr:hover { background: var(--surface); }
/* Worker 表格比同族的 meituan 表多几列（11 列），左右内边距从 12 收到 10：
   每列省 4px、共 ~40px（序号列是固定 48px，不跟着缩）。
   用双类提高特异性，别靠源码顺序赢 —— `.admin-data-table th` 与 `.worker-table th` 同权重，
   谁在后面谁生效，这种胜负太脆。 */
.admin-data-table.worker-table th, .admin-data-table.worker-table td { padding-left: 10px; padding-right: 10px; }
/* 11 列（含「销毁时间」）的内容自然宽度实测：
   真实 CVM 那种 24 字符 ID（ap-shanghai-8-0917-1913-1）在 12px 内边距下要 1126px，
   收到 10px 内边距后 1086px。取 1090 恰好盖住后者。
   注意真正生效的声明在 shell.css 的 `.worker-page-surface .worker-table`
   （特异性更高、加载更晚），这一条只是基底，两处必须一致 —— 只改一处会静默失效。 */
.worker-table { min-width: 1090px; }
/* 「销毁时间」列与卡片视图共用同一套三态文案（时间 / 已到期 / 未销毁 / -）。
   数字用等宽字形，扫列时不会左右跳。
   「已到期」和「未销毁」是两件相反的事，颜色必须分开：
   已到期 = 时刻已过且 Worker 已下线，正常（云实例到点被腾讯云销毁了，剩下的是历史会话）；
   未销毁 = 时刻已过但 Worker 还在线，说明那次销毁没生效（定时器失效，或是本就不会被自动
   销毁的手动 Worker），是要去看一眼的信号 —— 所以给危险色。 */
.worker-table-destroy, .worker-destroy-value { font-variant-numeric: tabular-nums; }
.worker-destroy-overdue { color: var(--danger); }
.worker-destroy-expired { color: var(--warning); }
.worker-destroy-unset { color: var(--muted); }
.worker-slot-projected { display: block; margin-top: 2px; color: var(--muted); font-size: 10px; font-weight: 500; }
.worker-destroy-scope { display: block; margin-top: 3px; color: var(--warning); font-size: 10px; font-weight: 500; white-space: nowrap; }
.worker-table tbody tr:has([data-worker-select]:checked) { background: var(--surface-muted); box-shadow: inset 2px 0 0 var(--accent); }
.worker-table-index { width: 48px; min-width: 48px; color: var(--muted); font-variant-numeric: tabular-nums; text-align: left !important; }
/* Worker 列（第 2 列）留 180px 下限，不再贴住内容。
   试过「width: 1% + nowrap」（缩到 ID 的宽度）：短 ID（DESKTOP-*）时它会缩到 106px，
   「状态」徽章几乎贴着 ID；而表格拉伸的余量会集中跑到「操作」列，最右侧出现一大片空白。
   退回按 180px 兜底：ID 与「状态」之间有稳定间隔，各列宽度也更均匀。
   注意 nowrap 仍然在，长 ID 不会被压断 —— 只是列宽不再随内容缩到最小。 */
.worker-table td:nth-child(2) { min-width: 180px; }
.worker-table-select { display: none; align-items: center; justify-content: center; width: 22px; height: 22px; margin-right: 6px; vertical-align: middle; cursor: pointer; }
.worker-table-select input { position: absolute; opacity: 0; pointer-events: none; }
.worker-table-select span { display: block; width: 18px; height: 18px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); }
.worker-table-select input:checked + span { border-color: var(--accent); background: var(--accent); box-shadow: inset 0 0 0 4px var(--surface); }
.worker-channel-frame.selection-mode .worker-table-select { display: inline-flex; }
.worker-table-labels { display: flex; max-width: 210px; gap: 4px; overflow: hidden; }
.worker-view-toggle { display: inline-flex; align-items: center; height: 32px; gap: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; padding: 2px; background: var(--surface-muted); }
.worker-view-toggle button { width: 28px; height: 28px; min-height: 0; display: inline-flex; align-items: center; justify-content: center; border: 0 !important; border-radius: 6px; padding: 0; background: transparent; color: var(--muted); appearance: none; }
.worker-view-toggle button:hover, .worker-view-toggle button:focus-visible { color: var(--text); }
.worker-view-toggle button.active, .worker-view-toggle button[aria-pressed="true"] { background: var(--accent); color: var(--text-on-strong); box-shadow: 0 1px 3px rgb(var(--shadow-rgb) / 14%); }
.worker-view-toggle svg { width: 15px; height: 15px; }
.worker-card:hover { border-color: var(--line-strong); background: var(--surface); text-decoration: none; }
.worker-card.is-paused { border-color: var(--line); background: var(--surface-muted); }
.worker-card.is-paused:hover { background: var(--surface-muted); }
.worker-card.is-paused .worker-card-title,
.worker-card.is-paused .worker-settings-edit { opacity: .52; filter: grayscale(1); }
.worker-card.is-paused .worker-card-body dl > div:not(.worker-card-status-fact) { opacity: .52; filter: grayscale(1); }
.worker-card.is-offline { filter: grayscale(.85); background: var(--surface-muted); color: var(--muted); }
.worker-card.is-offline:hover { background: var(--surface-muted); }
.worker-card > header { min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.worker-card-title { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); }
.worker-card-title:hover { text-decoration: none; }
.worker-card-title code { font-size: 14px; font-weight: 700; }
.worker-card-actions { flex: 0 0 auto; display: flex; align-items: center; gap: 7px; }
.worker-card-body { order: 2; }
.worker-accept-form { display: flex; margin: 0; }
.worker-accept-toggle { width: 30px; min-height: 30px; border-color: transparent; padding: 5px; background: transparent; }
.worker-accept-toggle.running { color: var(--accent); }
.worker-accept-toggle.paused { color: var(--danger); }
.worker-accept-toggle:hover, .worker-accept-toggle:focus-visible { border-color: currentColor; background: var(--surface); }
.worker-settings-edit { width: 30px; min-height: 30px; border-color: transparent; padding: 5px; background: transparent; color: var(--muted); }
.worker-settings-edit:hover, .worker-settings-edit:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--accent); }
.worker-settings-edit svg { width: 15px; height: 15px; }
.worker-card-labels { order: 1; min-height: 20px; display: flex; align-items: center; flex-wrap: wrap; gap: 4px; margin-top: 5px; overflow: hidden; }
.worker-label-chip { max-width: 100%; display: inline-flex; align-items: center; min-height: 19px; overflow: hidden; border: 1px solid var(--line); border-radius: 999px; padding: 1px 7px; background: var(--surface-muted); color: var(--accent-hover); text-overflow: ellipsis; white-space: nowrap; font-size: 10px; font-weight: 700; }
.task-group-selected-state .worker-label-chip { min-height: 22px; padding: 2px 7px; font-size: 12px; font-weight: 700; }
.worker-label-combobox { min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 5px; box-sizing: border-box; min-height: 40px; border: 1px solid var(--line); border-radius: 8px; padding: 5px 8px; background: var(--surface); color: var(--text); }
.worker-label-combobox:focus-within { border-color: var(--info); box-shadow: 0 0 0 3px color-mix(in srgb, var(--info) 24%, transparent); }
.worker-label-combobox-values { display: contents; }
.worker-label-combobox > input { flex: 1 1 180px; min-width: 150px; min-height: 28px; border: 0; outline: 0; padding: 3px 2px; background: transparent; color: var(--text); }
.worker-label-input-chip { display: inline-flex; align-items: center; gap: 3px; max-width: 100%; border: 1px solid var(--line); border-radius: 999px; padding: 3px 5px 3px 8px; background: var(--surface-muted); color: var(--accent-hover); font-size: 12px; font-weight: 650; line-height: 1.1; }
.worker-label-input-remove { width: 18px; height: 18px; min-height: 18px; display: inline-flex; align-items: center; justify-content: center; border: 0; border-radius: 50%; padding: 0; background: transparent; color: currentColor; }
.worker-label-input-remove:hover, .worker-label-input-remove:focus-visible { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--danger); }
.worker-label-input-remove svg { width: 12px; height: 12px; }
.worker-label-empty { color: var(--muted); font-size: 10px; }
/* flex-basis 必须是 auto（`flex: 1` 会写成 0%）：这个元素裹着整张 dl，basis 为 0 时
   卡片算固有高度只得到 147px，而 dl 实际要 183px —— 多出来的「状态 / 销毁时间」那一行
   被画到卡片框外，正好落在下一行卡片的背景下面，等于看不见。改成 1 1 auto 后卡片会长到
   装得下内容，仍受 min-height 托底、在更高的行里也能把底部撑满。 */
.worker-card-body { min-width: 0; flex: 1 1 auto; color: var(--text); }
.worker-card-body:hover { text-decoration: none; }
.worker-card dl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; border-top: 1px solid var(--surface-muted); margin: 12px 0 0; padding-top: 10px; }
.worker-card dl > div { min-width: 0; border-left: 2px solid var(--surface-muted); padding-left: 6px; }
.worker-card dt { color: var(--muted); font-size: 11px; }
.worker-card dd { min-width: 0; margin: 3px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 600; }
.worker-card-status-inline { display: flex; align-items: center; gap: 8px; }
.worker-ntp-value { display: block; max-width: 100%; }
.worker-ntp-value svg { width: 15px; height: 15px; }
.worker-platform-value code { display: block; overflow: hidden; text-overflow: ellipsis; font-size: inherit; font-weight: inherit; line-height: inherit; }
.worker-paused-label { color: var(--danger); font-size: 11px; font-weight: 700; }
.worker-batch-bar { position: absolute; z-index: 10; right: 50%; bottom: 68px; transform: translateX(50%); min-height: 58px; display: inline-flex; align-items: center; gap: 12px; border: 1px solid var(--surface-muted); border-radius: 30px; padding: 8px 12px; background: rgb(var(--surface-rgb) / 96%); box-shadow: 0 14px 30px rgb(var(--shadow-rgb) / 18%); white-space: nowrap; }
.worker-batch-bar[hidden] { display: none; }
.worker-batch-bar strong { color: var(--text); font-size: 14px; font-weight: 600; }
.worker-batch-bar button { width: 40px; height: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--surface-muted); border-radius: 50%; padding: 0; background: var(--surface); color: var(--text); }
.worker-batch-bar button:hover, .worker-batch-bar button:focus-visible { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); }
.worker-batch-bar button[data-worker-batch-action="remove"] { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.worker-batch-bar button svg { width: 18px; height: 18px; }
.worker-batch-close { border-color: var(--line) !important; background: var(--surface) !important; }
.worker-batch-divider { width: 1px; height: 28px; background: var(--surface-muted); }
.card-pagination { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; margin: 16px 0 2px; }
.card-pagination-summary { margin-right: 6px; color: var(--muted); font-size: 13px; white-space: nowrap; }
.card-pagination-link, .card-pagination-ellipsis { min-width: 32px; height: 32px; min-height: 0; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text-soft); font-size: 13px; font-variant-numeric: tabular-nums; text-decoration: none; }
.card-pagination-link:hover { color: var(--text); border-color: var(--line-strong); background: var(--surface-soft); text-decoration: none; }
.card-pagination-link.current { border-color: var(--accent); background: var(--accent); color: var(--text-on-strong); font-weight: 650; }
.card-pagination-link svg { width: 14px; height: 14px; }
.card-pagination-ellipsis { min-width: 22px; border-color: transparent; background: transparent; color: var(--muted); }
.worker-slot-dialog { box-sizing: border-box; width: min(436px, calc(100vw - 28px)); max-width: calc(100vw - 28px); max-height: calc(100vh - 24px); overflow: hidden; }
.worker-slot-dialog > form { display: grid; gap: 12px; min-width: 0; max-height: calc(100vh - 24px); overflow-y: auto; padding: 14px; }
.worker-slot-dialog form > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.worker-slot-dialog form > header > div { min-width: 0; display: grid; gap: 4px; }
.worker-slot-dialog h2 { display: flex; align-items: center; gap: 7px; margin: 0; font-size: 16px; }
.worker-slot-dialog h2 svg { width: 17px; height: 17px; color: var(--accent); }
.worker-slot-dialog header code { min-width: 0; overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; }
.worker-slot-dialog-body { display: grid; gap: 6px; min-width: 0; }
.worker-slot-dialog-body label { color: var(--muted); font-size: 12px; font-weight: 600; }
.worker-slot-dialog-body input, .worker-slot-dialog-body select { width: 100%; min-height: 34px; border: 1px solid var(--line); border-radius: 5px; padding: 6px 8px; background: var(--surface); color: var(--text); }
.worker-slot-dialog-body p { margin: 2px 0 0; color: var(--muted); font-size: 11px; }
/* 这个对话框（创建 Worker / Worker 创建计划）宽 436px，内容区 406px —— 贴着最宽的那一行：
   「定时创建时间」= 日期组 128 + 时间段 111 + 现在 72 + 清空 72 + 三个 7px 间距 = 404，
   加上左右各 14px 内边距与 2px 容差。行尾因此不再拖一段空白，左右也对称。
   容差只有 2px，所以两个时间字段的分组形态不能悄悄退回「日期时间合成一个框」——
   那反倒更窄、会重新留白（见 admin.js 的 data-segmented-split-groups）。
   再窄（<404 内容区）就折行：分段组一行、两个按钮一行。 */
.worker-slot-dialog .ax-dt { flex-wrap: wrap; row-gap: 6px; }
.worker-slot-dialog-actions { display: flex; justify-content: center; }
.worker-plan-list-dialog > section { display: grid; gap: 12px; min-width: 0; max-height: calc(100vh - 24px); overflow: hidden; padding: 14px; }
.worker-plan-list-dialog > section > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.worker-plan-toolbar { display: flex; justify-content: flex-end; min-height: 30px; }
.worker-plan-archive-toggle { width: 30px; min-height: 30px; border-color: transparent; background: transparent; color: var(--muted); }
.worker-plan-archive-toggle:hover, .worker-plan-archive-toggle:focus-visible { border-color: var(--accent-soft); background: var(--accent-soft); color: var(--accent); }
.worker-plan-archive-toggle[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }
.worker-settings-dialog { width: min(672px, calc(100vw - 28px)); max-width: calc(100vw - 28px); max-height: min(90vh, 760px); margin: auto; overflow: hidden; border: 1px solid var(--line); border-radius: 12px; padding: 0; background: var(--surface); color: var(--text); box-shadow: 0 24px 70px rgb(var(--shadow-rgb) / .28); }
.worker-settings-dialog::backdrop { background: rgb(var(--shadow-rgb) / .42); backdrop-filter: blur(2px); }
.worker-settings-dialog[open] { animation: worker-settings-open .12s ease-out; }
@keyframes worker-settings-open { from { opacity: 0; transform: scale(.97); } to { opacity: 1; transform: scale(1); } }
.worker-settings-dialog > form { min-width: 0; max-height: min(90vh, 760px); display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.worker-settings-dialog-header { min-width: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 24px 17px; }
.worker-settings-dialog-header > div { min-width: 0; }
.worker-settings-dialog-header h2 { margin: 0; font-size: 17px; font-weight: 650; line-height: 1.25; }
.worker-settings-dialog-header h2 code { overflow-wrap: anywhere; font-family: inherit; font-size: inherit; }
.worker-settings-dialog-header p { margin: 7px 0 0; color: var(--muted); font-size: 13px; }
.worker-settings-dialog-header > button { flex: 0 0 auto; margin: -8px -8px 0 0; border-color: transparent; background: transparent; }
.worker-settings-dialog-scroll { min-height: 0; overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; padding: 4px 24px 24px; scrollbar-gutter: stable; }
.worker-settings-section { display: grid; gap: 10px; padding: 6px 0; }
.worker-settings-section > label, .worker-settings-section-label { color: var(--text); font-size: 14px; font-weight: 650; }
.worker-settings-section > label span, .worker-settings-section-label span { margin-left: 10px; color: var(--muted); font-size: 11px; font-weight: 500; }
.worker-settings-section > input { width: 100%; min-width: 0; min-height: 40px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 11px; background: var(--surface); color: var(--text); outline: none; transition: border-color .12s ease, box-shadow .12s ease; }
.worker-settings-section > input:focus { border-color: var(--info); box-shadow: 0 0 0 3px color-mix(in srgb, var(--info) 24%, transparent); }
.worker-settings-section > input:disabled { background: var(--surface-muted); color: var(--muted); cursor: not-allowed; }
.worker-settings-destroy-input { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 8px; }
.worker-settings-destroy-input input { width: 100%; min-width: 0; min-height: 40px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 11px; background: var(--surface); color: var(--text); outline: none; transition: border-color .12s ease, box-shadow .12s ease; }
.worker-settings-destroy-input input:focus { border-color: var(--info); box-shadow: 0 0 0 3px color-mix(in srgb, var(--info) 24%, transparent); }
.worker-settings-destroy-input button { width: 40px; height: 40px; min-height: 40px; border-color: var(--line); border-radius: 8px; background: var(--surface); color: var(--muted); }
.worker-settings-destroy-input button:hover, .worker-settings-destroy-input button:focus-visible { border-color: var(--line-strong); color: var(--danger); }
.worker-settings-destroy-input button:disabled { opacity: .35; cursor: not-allowed; }
.worker-settings-section p { margin: -2px 0 0; color: var(--muted); font-size: 11px; line-height: 1.45; }
.worker-settings-dialog-scroll > hr { height: 1px; margin: 18px 0; overflow: hidden; border: 0; background: var(--surface-muted); }
.worker-settings-dialog-footer { display: flex; align-items: center; justify-content: flex-end; gap: 8px; border-top: 1px solid var(--surface-muted); padding: 16px 24px; background: var(--surface-muted); }
.worker-settings-dialog-footer button { min-height: 36px; border-radius: 8px; }
.task-date-content { position: relative; min-width: 0; overflow: hidden; border: 1px solid var(--surface-muted); border-radius: 12px; background: var(--surface); padding-left: 0; container: task-content / inline-size; }
.task-status-filter { position: relative; z-index: 30; }
.task-navigation-form { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.task-navigation-field { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 11px; font-weight: 650; }
.task-navigation-field input,
.task-navigation-field select { min-width: 150px; min-height: 32px; border: 1px solid var(--line); border-radius: 6px; padding: 5px 26px 5px 8px; background: var(--surface); color: var(--text); font-size: 12px; }
.task-navigation-field input { width: 150px; padding-right: 8px; }
@media (max-width: 720px) {
  .tasks-toolbar .tool-group { width: 100%; flex-wrap: wrap; }
  .task-navigation-form { width: 100%; }
  .task-navigation-field { flex: 1 1 100%; display: grid; grid-template-columns: 34px minmax(0, 1fr); }
  .task-navigation-field > span { white-space: nowrap; }
  .task-navigation-field input, .task-navigation-field select { width: 100%; min-width: 0; }
}
.task-status-filter .sign-filter-menu { right: 0; left: auto; width: min(260px, calc(100vw - 32px)); min-width: 0; max-height: min(520px, calc(100vh - 170px)); overflow-y: auto; }
.task-history-layout:not(.task-detail-layout) .task-date-content:has(.task-status-filter [data-task-status-menu]:not([hidden])) { overflow: visible; }
.task-batch-bar { min-height: 52px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--surface-muted); padding: 8px 16px; background: var(--surface); }
.task-batch-bar[hidden] { display: none; }
.task-batch-bar strong { color: var(--text); font-size: 12px; }
.task-batch-close, .task-batch-bar > button[data-task-batch-action] { width: 32px; height: 32px; min-height: 32px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--line); border-radius: 8px; padding: 0; background: var(--surface); color: var(--muted); }
.task-batch-bar > button[data-task-batch-action] { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.task-batch-close svg, .task-batch-bar > button[data-task-batch-action] svg { width: 15px; height: 15px; }
.task-batch-divider { width: 1px; height: 24px; background: var(--line); }
.task-batch-card { position: relative; min-width: 0; min-height: 326px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; background: var(--surface); color: var(--text); cursor: pointer; }
.task-batch-card:hover { border-color: var(--line-strong); background: var(--surface); text-decoration: none; }
.task-batch-card.active { border-color: var(--accent); box-shadow: inset 3px 0 0 var(--accent); }
.task-batch-card.task-batch-selected { border-color: var(--accent); box-shadow: inset 3px 0 0 var(--accent); background: var(--surface); }
.task-batch-card.has-worker-risk-warning::after,
.task-batch-card.has-worker-risk-danger::after { content: ""; position: absolute; top: -1px; right: 12px; left: 12px; height: 3px; border-radius: 0 0 3px 3px; pointer-events: none; background: var(--warning); }
.task-batch-card.has-worker-risk-danger::after { background: var(--danger); }
.task-batch-select { position: absolute; top: 11px; left: 11px; z-index: 1; width: 24px; height: 24px; display: none; align-items: center; justify-content: center; cursor: pointer; }
.task-history-layout.task-selection-mode .task-batch-select { display: inline-flex; }
.task-history-layout:has([data-task-batch-mode]:checked) .task-batch-select { display: inline-flex; }
.task-history-layout.task-selection-mode .task-batch-card > header { padding-left: 22px; }
.task-history-layout:has([data-task-batch-mode]:checked) .task-batch-card > header { padding-left: 22px; }
.task-batch-select input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.task-batch-select span { width: 21px; height: 21px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgb(var(--shadow-rgb) / 8%); }
.task-batch-select input:checked + span { border-color: var(--accent); background: var(--accent); box-shadow: inset 0 0 0 4px var(--surface); }
.task-batch-select input:disabled + span { opacity: .35; cursor: not-allowed; }
.task-batch-card > header { padding-left: 0; }
.task-batch-card-actions form { display: flex; }
.task-batch-card > header { min-width: 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.task-batch-card > header > div { min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.task-batch-card h3 { min-width: 0; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; }
.task-batch-card > header svg { width: 17px; height: 17px; flex: 0 0 auto; color: var(--muted); }
.task-batch-card-actions { display: flex !important; flex: 0 0 auto; gap: 4px; }
/* 这一排四个图标按钮尺寸/吃框必须完全一致：`.task-body-batch-edit` 以前没被列进来，
   于是它套的是 .button 的默认样式 —— 34×34、常驻灰底灰框，在一排透明按钮里像是被选中了。
   默认态与 hover 态写在同一组里（同权重的规则靠源码顺序决胜，拆开写会被别处抢走）。 */
.task-batch-card-actions .task-batch-view,
.task-batch-card-actions .task-batch-delete,
.task-batch-card-actions .task-runtime-edit,
.task-batch-card-actions .task-body-batch-edit { width: 30px; height: 30px; min-height: 30px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 8px; padding: 6px; background: transparent; color: var(--muted); }
.task-batch-card-actions .task-batch-view:hover, .task-batch-card-actions .task-batch-view:focus-visible,
.task-batch-card-actions .task-runtime-edit:hover, .task-batch-card-actions .task-runtime-edit:focus-visible,
.task-batch-card-actions .task-body-batch-edit:hover, .task-batch-card-actions .task-body-batch-edit:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--text); }
.task-batch-card-actions .task-batch-delete { color: var(--danger); }
.task-batch-card-actions .task-batch-delete:hover, .task-batch-card-actions .task-batch-delete:focus-visible { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.task-batch-card-actions .task-batch-view svg, .task-batch-card-actions .task-batch-delete svg, .task-batch-card-actions .task-runtime-edit svg, .task-batch-card-actions .task-body-batch-edit svg { width: 16px; height: 16px; }
.task-runtime-edit { border-color: transparent; background: transparent; color: var(--muted); }
.task-runtime-edit:hover, .task-runtime-edit:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--accent); }
.task-batch-totals small, .task-batch-schedule span, .task-batch-runtime dt { color: var(--muted); font-size: 11px; }
.task-batch-totals { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 9px; }
.task-batch-totals > span { display: grid; gap: 2px; border-left: 2px solid var(--surface-muted); padding-left: 6px; }
.task-batch-totals b { font-size: 18px; }
.task-batch-statuses { min-height: 25px; display: flex; flex-wrap: wrap; gap: 3px 0; border-top: 1px solid var(--surface-muted); margin-top: 9px; padding-top: 7px; color: var(--muted); font-size: 10px; }
/* 状态 chip **平分卡片长度**（4 个状态 = 每格 1/4，分隔线落在 153/306/459 而不是挤在左边半屏）。
   `flex: 1 1 0` 让每格等宽；`min-width: max-content` 是换行的前提 —— flex item 上的
   `overflow: hidden` 会把自动最小尺寸变成 0，不给下限的话 chip 一多就会被压成省略号，
   而 `min-width: max-content` 让它"放不下就换行"（实测 8~9 个 chip 排成两行，卡片高 333→347）。
   注意 flex-basis 不要拿来补首格的宽度：basis 会被 `min-width: max-content` 夹住，补了等于没补（实测 Δ 仍有 6px）。 */
.task-batch-statuses span { min-width: max-content; flex: 1 1 0; display: flex; align-items: baseline; gap: 3px; border-left: 1px solid var(--surface-muted); padding: 0 8px; overflow: hidden; white-space: nowrap; }
/* 首个 chip 没有左边框与左内边距（比邻居少 1px + 8px），不补的话它比后面三格窄 9px、
   分隔线落在 146/302/457（实测最大偏差 7px，肉眼可见不齐）。在它的右侧把这 9px 补回来
   （8 + 9 = 17），四格就严格相等：实测 0 / 153 / 306 / 459，偏差 0px。
   **改这里的左右内边距，17px 要一起改**（17 = 自己的右内边距 8 + 邻居的左内边距 8 + 邻居的左边框 1）。 */
.task-batch-statuses span:first-child { border-left: 0; padding-left: 0; padding-right: 17px; }
.task-batch-statuses b { overflow: hidden; text-overflow: ellipsis; }
.task-batch-statuses .coupon-success-summary:last-child { font-size: 9px; }
.task-batch-statuses .collecting { color: var(--info); }
.task-batch-statuses .pending { color: var(--warning); }
.task-batch-statuses .running { color: var(--info); }
.task-batch-statuses .succeeded { color: var(--accent); }
.task-batch-statuses .failed, .task-batch-statuses .cancelled { color: var(--danger); }
.task-batch-statuses .coupon-undetermined-summary { color: var(--warning); }
.task-batch-success-sequences { height: 102px; flex: 0 0 102px; overflow: hidden; border-top: 1px solid var(--surface-muted); padding: 6px 0; color: var(--accent-hover); font: 13px/18px "Cascadia Mono", Consolas, monospace; }
.task-batch-success-sequence-text { height: 90px; display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 5; }
.task-batch-success-sequences .empty { padding: 0; color: var(--muted); font: inherit; text-align: left; }
.task-batch-footer { display: grid; gap: 9px; border-top: 1px solid var(--line); margin-top: auto; padding-top: 9px; }
.task-batch-schedule { min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.task-batch-schedule > div { min-width: 0; display: grid; gap: 2px; border-left: 2px solid var(--surface-muted); padding-left: 6px; }
.task-batch-schedule > .task-batch-interval-cell { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; border-left: 0; padding-left: 0; }
.task-batch-interval-cell > div { min-width: 0; display: grid; gap: 2px; border-left: 2px solid var(--surface-muted); padding-left: 6px; }
.task-batch-proxy.enabled strong,
.task-batch-proxy.disabled strong { color: var(--text); }
.task-batch-schedule time { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 700; }
.task-batch-schedule strong { font-size: 13px; }
/* 「执行时间」这一格是两行：第一行 = label + 时钟图标 + 倒计时（距现在 / 已过去），
   第二行 = 日期时间值。与活动卡片同一套语言 —— 提示跟 label 走，值单独一行。
   `.task-batch-schedule span`（0,1,1）会把颜色/字号压成 muted 11px，倒计时沿用那个 muted，
   只有「还没到点」的态才转成与活动卡片状态行同一个绿。
   提示放在 label 行还有个好处：这一格内容宽只有 233px（卡片网格下限 520px），
   值那一行（19 字符 116px）与提示（96px）挤在一行会贴到边界。 */
.task-batch-countdown { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
/* 时钟图标表达「这是个时间字段」，所以跟 label 走、颜色随 label muted，不参与倒计时的绿/灰态。
   inline-flex 让「执行时间 / 图标 / 倒计时」三者垂直居中并保持 4px 间距。 */
.task-batch-schedule .task-batch-execute-label { display: inline-flex; align-items: center; gap: 4px; min-width: 0; }
.task-batch-execute-label svg { flex: 0 0 auto; width: 12px; height: 12px; }
.task-batch-countdown.is-ok { color: var(--success); }
.task-worker-risk-summary { display: flex; align-items: center; gap: 8px; min-height: 38px; margin-bottom: 10px; border: 1px solid var(--warning-soft); border-left: 3px solid var(--warning); border-radius: 6px; padding: 7px 10px; background: var(--warning-soft); color: var(--warning); font-size: 13px; }
.task-worker-risk-summary.is-danger { border-color: var(--danger-soft); border-left-color: var(--danger); background: var(--danger-soft); color: var(--danger); }
.task-worker-risk-summary svg { width: 16px; height: 16px; flex: 0 0 auto; }
.task-worker-risk { display: flex; align-items: center; gap: 6px; min-width: 0; margin-top: 8px; border-left: 3px solid var(--warning); padding: 5px 7px; background: var(--warning-soft); color: var(--warning); font-size: 11px; line-height: 1.35; }
.task-worker-risk.is-danger { border-left-color: var(--danger); background: var(--danger-soft); color: var(--danger); }
.task-worker-risk svg { width: 14px; height: 14px; flex: 0 0 auto; }
.task-worker-risk span { min-width: 0; overflow-wrap: anywhere; }
.task-worker-risk a { flex: 0 0 auto; margin-left: auto; color: inherit; font-weight: 650; text-decoration: underline; }
.task-worker-risk-detail { margin: 0 16px 10px; }
.task-batch-runtime { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 0; }
.task-batch-runtime div { min-width: 0; border-left: 2px solid var(--surface-muted); padding-left: 6px; }
.task-batch-runtime dt { white-space: nowrap; }
.task-batch-runtime dd { margin: 2px 0 0; font-size: 13px; font-weight: 700; }
/* 死声明：同权重的 `.field-picker-dialog`（760px）在文件更后面，这条从来不会生效，
   实际宽度是 760px。留着是为了不动其它已依赖 760px 的弹窗；要改宽度请显式用双类。 */
.task-runtime-dialog { width: min(920px, calc(100vw - 28px)); }
.task-runtime-form { display: grid; gap: 18px; padding: 20px; }
.task-runtime-form > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.task-runtime-form h2 { margin: 0; font-size: 16px; }
.task-runtime-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: end; gap: 14px 16px; }
.task-runtime-grid .field.datetime { grid-column: 2 / span 2; grid-row: 1; width: 100%; min-width: 0; justify-items: stretch; }
.task-runtime-grid .field:nth-child(2) { grid-column: 1; grid-row: 1; }
.task-runtime-grid .field:nth-child(3) { grid-column: 4; grid-row: 1; }
.task-runtime-grid .field:nth-child(4) { grid-column: 1; grid-row: 2; }
.task-runtime-grid .field:nth-child(5) { grid-column: 2; grid-row: 2; }
.task-runtime-grid .field:nth-child(6) { grid-column: 3; grid-row: 2; }
.task-runtime-grid .field:nth-child(7) { grid-column: 4; grid-row: 2; }
.task-runtime-grid > input[type="hidden"] + .field { grid-column: 3; grid-row: 2; }
.task-runtime-grid input,
.task-runtime-grid select,
.task-runtime-grid .worker-picker-trigger { width: 100%; min-height: 40px; }
.task-runtime-grid .field.compact { justify-items: stretch; }
.task-runtime-grid .field.compact input,
.task-runtime-grid .field.compact select { width: 100%; min-width: 0; }
/* 「执行时间」现在是分段式（.ax-dt-box），比同排的数字字段多一行状态提示。
   把状态行挪到 label 那一行、紧贴 label 右边：提示不占额外高度，本字段就与其它参数同高、
   label 也对齐 —— 与活动卡片（.sign-runtime-metrics 那段）同一套做法，视觉语言保持一致。
   提示靠左而不是靠右：它是「执行时间」的补充说明，飘到字段另一端会跟旁边的 Threads 挨上，
   而且字段宽度随窗口变时它会来回跑。column-gap 单独放大给 label 与提示留呼吸，
   行间距仍按字段自己的 row-gap；.ax-dt 跨两列，行宽不受这个 gap 影响。
   不动 .task-runtime-grid 的 align-items: end：那条是给数字字段用的。 */
.task-runtime-grid .field.datetime:has(> .ax-dt-box) { grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 8px; }
.task-runtime-grid .field.datetime:has(> .ax-dt-box) > label { grid-area: 1 / 1; }
.task-runtime-grid .field.datetime:has(> .ax-dt-box) > .ax-dt-box { display: contents; }
.task-runtime-grid .field.datetime:has(> .ax-dt-box) .ax-dt { grid-area: 2 / 1 / 3 / 3; }
.task-runtime-grid .field.datetime:has(> .ax-dt-box) .ax-dt-state { grid-area: 1 / 2; min-width: 0; justify-content: flex-start; }
.task-runtime-grid .field.datetime:has(> .ax-dt-box) .ax-dt-state > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-runtime-routing { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 14px 16px; border-top: 1px solid var(--line); padding-top: 16px; }
.task-runtime-routing > .task-runtime-target-ip,
.task-runtime-routing > .worker-selector-fields { min-width: 0; width: 100%; }
.task-runtime-routing .worker-selector-fields { display: grid; grid-template-columns: 1fr; }
.task-runtime-routing .worker-selector-fields > .field { grid-column: 1 / -1; width: 100%; min-width: 0; }
.task-runtime-routing .worker-picker-trigger { width: 100%; }
/* 「请求组执行参数」比「批次执行参数」少两个字段（执行时间 / 任务上传重试次数），
   于是 4 列网格只剩 5 个数字字段：第 1 行第 3 列、第 2 行第 3~4 列全是空的。
   早先给这两个路由字段单开了一整行（.task-runtime-routing，整宽 + 上边线），在 760px 的
   对话框里白占 79px 高度。现在它们直接住进空位：Repeats 让到第 1 行第 3 列、执行 Worker
   占第 1 行第 4 列，DNS 占第 2 行第 3~4 列（它的标签本来就长）—— 8 个格子填满，不再多一行。
   注意权重：这几条都带了 `.compact`/`.worker-selector-fields` 以提高权重——
   Repeats 要压过 `.field:nth-child(3)`（0,3,0）写死的 `grid-column: 4`，DNS 要压过
   `.field:nth-child(6)`（0,3,0）的 `grid-column: 3`。别简化成 `.field.xxx`，那样只能靠
   文件顺序取胜，谁把这段往上挪一格就静默错位（第 1 行会渲染成「Repeats 压在 Worker 下面」）。
   批次对话框没有空位（7 个字段填满两行），继续用 .task-runtime-routing 整行，两处互不影响。 */
.task-runtime-grid > .worker-selector-fields { grid-column: 4; grid-row: 1; grid-template-columns: 1fr; }
.task-runtime-grid > .field.compact.task-runtime-repeats { grid-column: 3; }
.task-runtime-grid > .field.compact.task-runtime-dns { grid-column: 3 / -1; grid-row: 2; }
.task-runtime-actions { border-top: 1px solid var(--line); padding-top: 16px; }
@media (max-width: 760px) {
  .task-runtime-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-runtime-grid .field.datetime { grid-column: 1 / -1; grid-row: auto; }
  .task-runtime-grid .field:nth-child(n+2) { grid-column: auto; grid-row: auto; }
  .task-runtime-grid > input[type="hidden"] + .field { grid-column: auto; grid-row: auto; }
  .task-runtime-grid > .worker-selector-fields,
  .task-runtime-grid > .field.compact.task-runtime-repeats,
  .task-runtime-grid > .field.compact.task-runtime-dns { grid-column: auto; grid-row: auto; }
  .task-runtime-routing { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .task-runtime-grid { grid-template-columns: 1fr; }
  .task-runtime-grid .field.datetime { grid-column: auto; }
}
.task-runtime-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; }

/* ── 「修改请求 Body」编辑器：批次卡片 / 请求组 / 单请求 三处共用 ──
   这三处原先都把唯一的 .field 塞进 .task-runtime-grid —— 那是给紧凑数字参数设计的
   4 列网格（位置由 :nth-child(2)~(7) 按下标写死），于是字段落在第 1 列，
   760px 的对话框里 textarea 只有 168px（22%）。编辑器现在自己占满整宽，不再进那个网格。
   头部用 <div> 而不是 <header>：`.task-runtime-form > header`（0,1,1）权重高于
   `.task-body-head`（0,1,0），用 header 的话 display/justify-content 会被它抢走。 */
/* 宽度用双类压过 `.field-picker-dialog`（760px，同权重且在文件更后面）——
   别只写 .task-body-dialog，那样是死声明。本项目在宽度上已经栽过四次。 */
.field-picker-dialog.task-body-dialog { width: min(860px, calc(100vw - 28px)); overflow: auto; }
/* 备注弹窗只有一行输入，用 .task-runtime-dialog 的默认宽度（被 .field-picker-dialog 盖成 760px）
   会空得离谱 —— 同样必须写双类才赢得下来。 */
.field-picker-dialog.task-note-dialog { width: min(520px, calc(100vw - 28px)); }

.task-body-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.task-body-head-icon { flex: 0 0 32px; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 8px; background: var(--accent-soft); color: var(--accent); }
.task-body-head-icon svg { width: 16px; height: 16px; }
.task-body-head-text { min-width: 0; }
.task-body-head-text p { margin: 3px 0 0; overflow: hidden; color: var(--muted); font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }

/* 作用域：改之前先让人看清会影响什么 */
.task-body-scope { display: flex; flex-wrap: wrap; gap: 8px; }
.task-body-chip { display: inline-flex; align-items: center; gap: 6px; min-width: 0; border: 1px solid var(--line); border-radius: 6px; padding: 5px 9px; background: var(--surface-soft); color: var(--text-soft); font-size: 12px; }
.task-body-chip svg { flex: 0 0 auto; width: 13px; height: 13px; color: var(--muted); }
.task-body-chip.is-warn { border-color: var(--warning); background: var(--warning-soft); color: var(--warning); }
.task-body-chip.is-warn svg { color: var(--warning); }
/* 工具栏 */
.task-body-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.task-body-tools { display: flex; align-items: center; gap: 2px; }
.task-body-tools button { min-height: 28px; border-color: transparent; padding: 4px 9px; background: transparent; color: var(--text-soft); font-size: 12px; }
.task-body-tools button:hover:not([disabled]) { border-color: var(--line); background: var(--surface); color: var(--accent); }
.task-body-tools button[disabled] { opacity: .5; }
.task-body-tool-sep { width: 1px; height: 16px; margin: 0 5px; background: var(--line); }

/* 编辑器：行号 + 等宽文本域。软换行，与只读视图（.task-request-content pre）保持同一套规则：
   pre-wrap + overflow-wrap: anywhere。单请求里装的常常是一整行 base64 或压缩过的 JSON，
   横向滚动根本没法读。换行后一个逻辑行会占多个视觉行，行号得跟着撑开 ——
   由 .task-body-mirror（同样式、不可见）让浏览器自己算出每行的视觉高度，再写进 li 的 height，
   见 admin.js 的 measureRowHeights。position: relative 是给那个镜像定位用的。 */
.task-body-editor { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); border: 1px solid var(--line); border-radius: 10px; background: var(--surface); overflow: hidden; }
.task-body-editor:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-ring); }
.task-body-editor.is-error { border-color: var(--danger); }
.task-body-editor.is-error .task-body-gutter { background: var(--danger-soft); }
.task-body-gutter { overflow: hidden; margin: 0; border-right: 1px solid var(--line); padding: 13px 10px 13px 14px; background: var(--surface-soft); list-style: none; color: var(--muted); font: 12px/1.75 var(--mono); font-variant-numeric: tabular-nums; text-align: right; user-select: none; }
.task-body-gutter li { min-width: 1.6em; }
.task-body-gutter li.is-error { color: var(--danger); font-weight: 700; }
.task-body-input { width: 100%; min-height: 300px; max-height: 52vh; border: 0; border-radius: 0; margin: 0; padding: 13px 16px; background: transparent; color: var(--text); font: 12px/1.75 var(--mono); tab-size: 2; resize: vertical; outline: none; white-space: pre-wrap; overflow-wrap: anywhere; overflow-x: hidden; }
/* 量行高的镜像：与 textarea 同字体、同宽、同换行规则，不可见且不参与布局。
   让浏览器自己算换行，比在 JS 里估算「每行占几列」可靠 —— CJK 是双宽，tab 按 tab-size 算。 */
.task-body-mirror { position: absolute; top: 0; left: 0; visibility: hidden; pointer-events: none; padding: 13px 16px; font: 12px/1.75 var(--mono); tab-size: 2; white-space: pre-wrap; overflow-wrap: anywhere; }

/* 状态栏：校验结论 + 体量 */
.task-body-statusbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; color: var(--muted); font-size: 12px; }
.task-body-state { display: inline-flex; align-items: center; gap: 6px; }
.task-body-state.is-ok { color: var(--accent); }
.task-body-state.is-bad { color: var(--danger); }
.task-body-stats { color: var(--muted); font-family: var(--mono); font-variant-numeric: tabular-nums; }
.task-body-note { margin-left: auto; color: var(--muted); }

@media (max-width: 760px) {
  .task-body-gutter { display: none; }
  .task-body-input { padding-left: 12px; padding-right: 12px; }
  .task-body-mirror { padding-left: 12px; padding-right: 12px; }
  .task-body-note { margin-left: 0; }
}

.worker-plan-list { --worker-plan-list-max-height: 313px; display: grid; align-content: start; gap: 10px; height: min(var(--worker-plan-list-max-height), calc(100vh - 220px)); min-height: 0; max-height: min(var(--worker-plan-list-max-height), calc(100vh - 220px)); overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.worker-plan-list > .empty { min-height: 240px; display: flex; align-items: center; justify-content: center; margin: 0; }
.worker-plan-item { min-width: 0; border: 1px solid var(--line); padding: 10px 12px; display: grid; gap: 5px; }
.worker-plan-item > header { min-width: 0; display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.worker-plan-item > header > strong { min-width: 0; overflow-wrap: anywhere; }
.worker-plan-item > header > .badge { flex: 0 0 auto; }
.worker-plan-item p { min-width: 0; margin: 0; overflow-wrap: anywhere; color: var(--muted); font-size: 12px; }
.worker-plan-item > form { justify-self: center; }
.task-batch-detail { min-width: 0; border-top: 1px solid var(--line); margin-top: 18px; padding-top: 14px; }
.task-detail-content { min-height: 0; height: 100%; display: flex; flex-direction: column; overflow: hidden; }
.task-detail-heading { flex: 0 0 auto; min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 52px; margin-bottom: 0; border-bottom: 1px solid var(--surface-muted); padding: 10px 16px; }
.task-detail-heading > div { min-width: 0; flex: 1 1 auto; display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
.task-detail-heading h2 { margin: 0; font-size: 17px; }
.task-detail-heading > span { min-width: 0; max-width: min(50%, 360px); flex: 0 1 360px; margin-left: auto; color: var(--muted); font-size: 12px; line-height: 1.4; text-align: right; overflow-wrap: anywhere; }
.task-detail-summary { flex: 0 0 auto; min-width: 0; display: grid; gap: 10px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 12px 0; }
.task-detail-summary dl { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; margin: 0; }
.task-detail-summary dl > div { min-width: 0; border-left: 2px solid var(--surface-muted); padding-left: 8px; }
.task-detail-summary dt { overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.task-detail-summary dd { margin: 3px 0 0; font-size: 14px; font-weight: 700; }
.task-detail-statuses { min-height: 22px; display: flex; flex-wrap: wrap; gap: 7px 16px; padding-left: 10px; color: var(--muted); font-size: 12px; }
.task-detail-statuses .collecting { color: var(--info); }
.task-detail-statuses .pending { color: var(--warning); }
.task-detail-statuses .running { color: var(--info); }
.task-detail-statuses .succeeded { color: var(--accent); }
.task-detail-statuses .failed, .task-detail-statuses .cancelled { color: var(--danger); }
.task-detail-statuses .coupon-undetermined-summary { color: var(--warning); font-weight: 600; }
.coupon-success-summary { color: var(--accent-hover); font-weight: 600; }
.coupon-success-summary b { color: var(--accent-hover); }
.task-group-facts { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; margin: 0; border-top: 1px solid var(--line); padding: 10px 14px; background: var(--surface); }
.task-group-facts > div { min-width: 0; }
.task-group-facts dt { color: var(--muted); font-size: 11px; }
.task-group-facts dd { min-width: 0; margin: 3px 0 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 600; }
.task-request-list { border-top: 1px solid var(--surface-muted); }
.task-request-detail + .task-request-detail { border-top: 1px solid var(--line); }
.task-request-detail > summary { min-width: 0; display: grid; grid-template-columns: 38px 62px minmax(0, 1fr) 168px; align-items: center; gap: 9px; padding: 9px 14px; cursor: pointer; list-style: none; }
.task-request-detail > summary::-webkit-details-marker { display: none; }
.task-request-detail > summary span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.task-request-detail > summary time { color: var(--muted); font-size: 11px; white-space: nowrap; }
.task-cached-response-heading { min-width: 0; display: flex; align-items: center; gap: 14px; padding: 9px 14px; }
.task-cached-response-heading span { color: var(--text); }
.task-cached-response-heading .task-cached-worker-meta { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 12px; }
.task-request-content { min-width: 0; display: grid; gap: 10px; border-top: 1px solid var(--surface-muted); padding: 12px 14px; background: var(--surface); }
.task-request-content h5 { margin: 0 0 5px; color: var(--muted); font-size: 11px; }
.task-request-content pre { max-height: 260px; margin: 0; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; font: 12px/1.5 "Cascadia Mono", Consolas, monospace; }
.task-group-workspace { flex: 1 1 auto; min-width: 0; min-height: 0; display: grid; grid-template-columns: 220px minmax(0, 1fr); align-items: stretch; gap: 12px; margin-top: 14px; }
.task-group-account-list { min-width: 0; min-height: 0; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.task-group-list-tabs { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); border-bottom: 1px solid var(--line); }
.task-group-list-tabs a { min-width: 0; min-height: 42px; display: flex; align-items: center; justify-content: center; gap: 7px; padding: 8px 7px; color: var(--muted); font-size: 12px; font-weight: 700; text-decoration: none; }
.task-group-list-tabs a + a { border-left: 1px solid var(--line); }
.task-group-list-tabs a:hover, .task-group-list-tabs a:focus-visible { background: var(--surface-muted); color: var(--text); outline: 0; }
.task-group-list-tabs a.active { background: color-mix(in srgb, var(--info) 10%, transparent); box-shadow: inset 0 -2px 0 var(--info); color: var(--text); }
.task-group-list-tabs a.successful.active { background: color-mix(in srgb, var(--success) 10%, transparent); box-shadow: inset 0 -2px 0 var(--success); color: var(--success); }
.task-group-list-tabs a b { flex: 0 0 auto; color: inherit; font-size: 11px; font-variant-numeric: tabular-nums; }
.task-group-account-list nav { flex: 1 1 auto; min-height: 0; max-height: none; overflow: auto; }
.task-group-account-row { position: relative; min-width: 0; }
.task-group-account-row .task-group-note-inline { position: absolute; z-index: 1; top: 50%; right: 5px; width: 20px; height: 20px; min-width: 20px; min-height: 20px; transform: translateY(-50%); border: 1px solid transparent; border-radius: 4px; padding: 0; background: var(--surface); color: var(--muted); opacity: 0; pointer-events: none; }
.task-group-account-row:hover .task-group-note-inline, .task-group-account-row:focus-within .task-group-note-inline, .task-group-account-row > a.active + .task-group-note-inline { opacity: 1; pointer-events: auto; }
.task-group-account-row:has(> a.success:not(.blacklisted):not(.active)) > .task-group-note-inline { background: color-mix(in srgb, var(--success) 12%, transparent); color: var(--success); }
.task-group-account-row:has(> a.undetermined:not(.blacklisted):not(.active)) > .task-group-note-inline { background: var(--warning-soft); color: var(--warning); }
.task-group-account-row:has(> a.active) > .task-group-note-inline { background: color-mix(in srgb, var(--info) 26%, transparent); color: var(--text); }
.task-group-account-row:has(> a.blacklisted:not(.active)) > .task-group-note-inline { background: var(--surface); color: var(--danger); }
/* 笔比方框细，而且这格只有 20px。这一版先按 16px 试（盒子与点击区仍是 20px）。
   不写这条就会落回前面 `button svg { width: 16px }`（同一个值）；
   如果最后定 16，这条整条删掉即可，定 14 就把数字改回去。
   和同组几条规则一样带 .task-group-account-row 前缀，这一片统一这么写。 */
.task-group-account-row .task-group-note-inline svg { width: 16px; height: 16px; }
.task-group-note-inline:hover, .task-group-note-inline:focus-visible { border-color: var(--line-strong); background: var(--surface-muted); color: var(--accent); outline: 0; }
@media (hover: none) { .task-group-note-inline { opacity: 1; pointer-events: auto; } }
/* 每个请求组两段：上面「#序号 + 主标签」，下面原名。
   主标签有备注时是备注、没备注时就是原名本身 —— 两种情况都渲染两行，行高一致，列表不会参差。
   字号统一 12px（原名不再因为「有备注」而退成 11px）：这一格内容 196px，
   实测最长的原名（2088052364842523:陈德义 ≈148px）与最常见的备注（105px）都放得下。
   行高写成显式的两行 16px（= 12px 字的行高）而不是靠内容撑：没备注的行第二行是空的，
   靠内容撑就会塌成一行 —— 显式行高才能让两种行都是 50px。 */
.task-group-account-list nav a { min-width: 0; display: grid; grid-template-rows: repeat(2, 16px); align-content: center; row-gap: 1px; border-bottom: 1px solid color-mix(in srgb, var(--text) 20%, transparent); padding: 8px 11px; color: var(--text); text-decoration: none; }
/* 行分隔线不能写死成 `var(--line)`：行底色是**算出来的**（成功 = `--success` 12% 叠在列表底色上），
   而 `--line` 恰好落在那个绿底的同亮度附近 —— 实测成功行上只有 **1.03:1**，
   等于看不见，两个相邻的成功行会连成一块（散帅截图里的 #1 / #2）。
   改成 `var(--text)` 20% 叠在**本行自己的底色**上：底色越亮这条线也越亮，
   三种底色的对比度都被拉到同一个量级（实测普通 1.85 / 成功 1.8 / 选中 1.72，改前是 1.25 / 1.03 / 1.3）。
   **别换成 `--line-strong`**：它在选中的蓝底上同样塌成 1.01。 */
/* 行状态用两套色相区分：**绿 = 抢券成功**（字色 + 淡绿底）、**蓝 = 当前选中**（蓝底 + 左竖条，
   字色不变）、红 = 黑号 / 任务失败。暗色主题下 `--success` 与 `--accent` 是同一个值、
   `--success-soft` 与 `--accent-soft` 也同值 —— 所以「选中」绝不能再借 accent：那样它和「成功」
   就是同一个颜色，只有深浅之差，根本分不出来（散帅的原话）。
   选中底色写两条：`.active` 给普通行，`.success.active` 显式覆盖（`.success` 那条特异性更高，
   不写就会被它盖掉，只剩成功底色）。 */
.task-group-account-list nav a.success:not(.blacklisted) { background: color-mix(in srgb, var(--success) 12%, transparent); color: var(--success); }
.task-group-account-list nav a.undetermined:not(.blacklisted) { background: var(--warning-soft); color: var(--warning); }
.task-group-account-list nav a:hover { background: var(--surface-muted); }
.task-group-account-list nav a.active { background: color-mix(in srgb, var(--info) 26%, transparent); box-shadow: inset 3px 0 0 var(--info); color: var(--text); }
/* 任务失败（Worker 没跑完）= 异常态，但**只改字色、不抢底色** —— 底色只有一格，已经给了「选中」和
   「抢券成功」，再给失败一块红底就会出现"失败 + 黑号"这类叠加行互相盖掉（实测过）。
   两种红靠行内 chip 区分：**红字无 chip = 任务失败，红字有 chip = 黑号**；任务状态另外写进了
   title/aria（`groupRowLabel` 的「任务失败」），所以不依赖颜色也能读出来。 */
.task-group-account-list nav a.failed { color: var(--danger); }
/* 选中的左竖条跟着**行状态**的色相走：成功=绿、失败/黑号=红、其余=选中本身的蓝。
   底色仍然是「选中」的蓝，所以「选中」和「成功」不会退化成只有深浅之差。 */
.task-group-account-list nav a.success.active:not(.blacklisted) { background: color-mix(in srgb, var(--info) 26%, transparent); box-shadow: inset 3px 0 0 var(--success); color: var(--success); }
.task-group-account-list nav a.undetermined.active:not(.blacklisted) { background: color-mix(in srgb, var(--info) 26%, transparent); box-shadow: inset 3px 0 0 var(--warning); color: var(--warning); }
.task-group-account-list nav a.failed.active { box-shadow: inset 3px 0 0 var(--danger); color: var(--danger); }
.task-group-account-list nav a.blacklisted { background: var(--surface); color: var(--danger); }
.task-group-account-list nav a.blacklisted.active { box-shadow: inset 3px 0 0 var(--danger); background: var(--surface-muted); color: var(--danger); }
.task-group-account-list nav a .account-line { min-width: 0; display: flex; align-items: center; gap: 7px; }
.task-group-account-list nav a b { flex: 0 0 auto; font-size: 12px; }
.task-group-account-list nav a .account-name { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 12px "Cascadia Mono", Consolas, monospace; }
/* 备注是主标签：颜色跟着行状态走（选中时变强调色），争宽时让位全落在它身上 —— 原名是对账要用的身份。 */
.task-group-account-list nav a .account-note { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: inherit; font-size: 12px; }
.task-group-account-list nav a .account-sub { grid-row: 2; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font: 12px "Cascadia Mono", Consolas, monospace; }
/* 没有备注的行第二行是空的：让第一行跨两行、垂直居中，否则文字会贴在框的上半部分、下面空一块。 */
.task-group-account-list nav a:has(.account-sub:empty) .account-line { grid-row: 1 / 3; align-self: center; }
.blacklist-mark { box-sizing: border-box; flex: 0 0 auto; height: 20px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--danger-soft); border-radius: 4px; padding: 0 4px; color: var(--danger); font-size: 10px; font-weight: 700; }
.task-group-account-list nav p { margin: 0; padding: 20px 11px; color: var(--muted); font-size: 12px; }
.task-group-selected { min-width: 0; min-height: 0; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.task-group-selected-head { min-height: 48px; display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 7px 12px; }
.task-group-selected-state, .task-group-selected-actions { min-width: 0; display: flex; align-items: center; gap: 8px; }
.task-group-selected-actions { margin-left: auto; }
/* 请求组这排图标按钮与批次卡片同一套语言：默认只有图标（muted），hover/focus 才出现外框。
   「统一修改该请求组 Body」与「删除请求组」原先带着 .button 的默认框（灰底 / 淡红底），
   夹在透明的「修改执行参数」旁边像是被选中了。
   颜色同理：基础 `button { color: var(--text) }` 是给正文按钮用的，落到这一排的图标按钮上
   就是「同一排只有它发白」——「统一修改该请求组 Body」没有像 .task-runtime-edit 那样的
   通用默认色（admin.css 里那条 `.task-runtime-edit { color: var(--muted) }`），
   于是继承了 button 的正文白。这里整排统一 muted，危险操作由下面的 .danger.icon-only 覆盖成红。
   默认态与 hover 态必须相邻同处声明：同权重规则靠源码顺序决胜，分开写会被别处
   （例如通用的 .task-runtime-edit:hover）抢先。 */
.task-group-selected-actions .icon-only { border-color: transparent; background: transparent; color: var(--muted); }
.task-group-selected-actions .task-runtime-edit:hover, .task-group-selected-actions .task-runtime-edit:focus-visible,
.task-group-selected-actions .task-body-group-edit:hover, .task-group-selected-actions .task-body-group-edit:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--accent); }
.task-group-selected-actions .danger.icon-only { color: var(--danger); }
.task-group-selected-actions .danger.icon-only:hover,
.task-group-selected-actions .danger.icon-only:focus-visible { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.task-group-selected-head form { display: flex; }
.task-group-selected > .attempt-warning { margin: 0; border-top: 1px solid var(--line); padding: 12px 14px; }
.badge.custom { color: var(--warning); border-color: var(--warning); background: var(--warning-soft); }
.task-group-selected > .task-group-facts { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.task-group-view-tabs { display: flex; gap: 4px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 0 3px; }
.task-group-view-tabs button { min-height: 40px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; padding: 8px 11px; background: transparent; color: var(--muted); }
.task-group-view-tabs button.active { border-bottom-color: var(--accent); color: var(--accent); font-weight: 600; }
.task-group-view-panel { flex: 1 1 auto; min-width: 0; min-height: 0; overflow: auto; }
.task-group-view-panel[hidden] { display: none; }
.task-group-view-panel > .task-request-list { border-top: 0; }
.task-response-output { width: 100%; height: 100%; max-height: none; min-height: 0; overflow: auto; }
.task-group-view-panel[data-task-view-panel="execution"] { padding: 14px; background: var(--surface); }
.task-execution-identity { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: -14px -14px 14px; border-bottom: 1px solid var(--line); padding: 13px 14px; background: var(--surface); color: var(--muted); font-size: 12px; }
.task-execution-attempt { overflow: hidden; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.task-execution-attempt + .task-execution-attempt { margin-top: 12px; }
.task-execution-attempt > header { min-width: 0; display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-height: 50px; padding: 10px 14px; }
.task-execution-attempt > header > .badge { display: none; }
.task-execution-attempt > header code { margin-left: auto; color: var(--muted); }
.task-execution-attempt > .attempt-warning { margin: 9px 13px; }
.badge { display: inline-flex; align-items: center; min-height: 22px; padding: 2px 7px; border-radius: 999px; background: var(--surface-muted); color: var(--text-soft); font-size: 12px; }
.badge.online, .badge.succeeded, .badge.successful, .badge.enabled { background: var(--surface-muted); color: var(--accent-hover); }
.badge.pending, .badge.acknowledged, .badge.leased { background: var(--warning-soft); color: var(--warning); }
.badge.running { background: var(--info-soft); color: var(--info); }
.badge.failed, .badge.cancelled, .badge.offline, .badge.disabled { background: var(--surface-muted); color: var(--danger); }
.badge.not-successful { background: var(--surface-muted); color: var(--muted); }
.badge.undetermined { background: var(--warning-soft); color: var(--warning); }
.badge.blacklisted { background: var(--surface-muted); color: var(--danger); }
.task-cached-response-list .task-request-detail.blacklisted { border-color: var(--danger-soft); background: var(--surface); }
.activity-view-content, .signature-card-column { min-width: 0; }
.activity-view-content[data-activity-view="sign"], .activity-view-content[data-activity-view="store"], .activity-view-content[data-activity-view="requests"], .activity-view-content[data-activity-view="workers"] { height: calc(100vh - 178px); overflow: hidden; }
.activity-view-sidebar { align-self: start; min-width: 0; height: min(680px, calc(100vh - 180px)); min-height: 420px; border-right: 1px solid var(--line); padding: 2px 16px 24px 0; display: flex; flex-direction: column; overflow: hidden; }
.activity-view-sidebar nav { min-height: 0; display: grid; align-content: start; gap: 4px; overflow-y: auto; scrollbar-gutter: stable; }
.activity-view-sidebar nav > a { min-width: 0; min-height: 42px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 6px; border-radius: 5px; padding: 8px 12px; color: var(--muted); text-decoration: none; }
.activity-view-sidebar nav > a:hover { background: var(--surface-muted); color: var(--text); }
.activity-view-sidebar nav > a.active { background: var(--surface-muted); color: var(--accent); font-weight: 700; }
.activity-view-sidebar nav > a b { min-width: 25px; border-radius: 999px; padding: 2px 7px; background: var(--surface-muted); color: var(--muted); font-size: 12px; text-align: center; }
.activity-view-sidebar nav > a.active b { background: var(--line); color: var(--accent); }
.signature-card-column { display: grid; gap: 12px; }
.meituan-channel-create { flex: 0 0 auto; min-height: 32px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 6px; padding: 6px 10px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 600; line-height: 1; text-decoration: none; }
.sign-lottery-create { flex: 0 0 auto; min-height: 32px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 6px; padding: 6px 10px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 600; line-height: 1; text-decoration: none; }
.sign-channel-toolbar-actions { min-width: 0; margin-left: auto; display: inline-flex; align-items: center; justify-content: flex-end; gap: 8px; }
.sign-toolbar-control, .sign-batch-toggle { min-height: 32px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 6px; padding: 6px 10px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 600; white-space: nowrap; }
.sign-toolbar-control:hover, .sign-toolbar-control:focus-visible, .sign-batch-toggle:has(input:checked) { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); }
.sign-toolbar-control svg, .sign-batch-toggle svg { width: 15px; height: 15px; }
.sign-filter-current { min-height: 24px; display: inline-flex; align-items: center; border-radius: 999px; padding: 3px 8px; background: var(--surface-muted); color: var(--accent); font-size: 12px; font-weight: 600; white-space: nowrap; }
.sign-batch-toggle { cursor: pointer; }
.sign-batch-toggle input { width: 30px; min-height: 18px; height: 18px; margin: 0 0 0 2px; border: 0; border-radius: 9px; appearance: none; background: var(--line); cursor: pointer; }
.sign-batch-toggle input::after { content: ""; display: block; width: 14px; height: 14px; margin: 2px; border-radius: 50%; background: var(--surface); transition: transform .15s ease; }
.sign-batch-toggle input:checked { background: var(--accent); }
.sign-batch-toggle input:checked::after { transform: translateX(12px); }
.sign-filter-control { position: relative; }
.sign-filter-menu { position: absolute; z-index: 8; top: calc(100% + 6px); left: 0; min-width: 260px; display: grid; gap: 2px; border: 1px solid var(--line); border-radius: 16px; padding: 10px; background: var(--surface); box-shadow: 0 12px 28px rgb(var(--shadow-rgb) / 16%); }
.sign-filter-menu[hidden] { display: none; }
.sign-filter-menu a { min-height: 36px; display: flex; align-items: center; gap: 10px; border-radius: 11px; padding: 5px 10px; background: transparent; color: var(--text); text-align: left; text-decoration: none; font-size: 14px; }
.sign-filter-menu a:hover, .sign-filter-menu a.active { background: var(--surface-muted); color: var(--text); }
.sign-filter-radio { width: 22px; height: 22px; flex: 0 0 auto; border: 1px solid var(--info); border-radius: 50%; background: transparent; }
.sign-filter-menu a.active .sign-filter-radio { box-shadow: inset 0 0 0 6px var(--surface); background: var(--accent); }
.meituan-channel-create:hover, .meituan-channel-create:focus-visible { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); text-decoration: none; }
.sign-lottery-create:hover, .sign-lottery-create:focus-visible { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); text-decoration: none; }
.meituan-channel-create svg { width: 15px; height: 15px; stroke-width: 2.4; }
.sign-lottery-create svg { width: 15px; height: 15px; stroke-width: 2.4; }
.sign-channel-frame { position: relative; }
.admin-card, [data-admin-card] { transition: border-color .16s ease, background-color .16s ease; }
.admin-card.is-disabled,
[data-admin-card].is-disabled,
[data-admin-card][data-store-enabled="false"] { background: var(--surface-muted); }
.admin-card-action { width: 34px; height: 34px; min-height: 34px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 6px; padding: 7px; background: transparent; }
.admin-card-action svg { width: 16px; height: 16px; }
.admin-card:hover,
.admin-card:focus-within,
[data-admin-card]:hover,
[data-admin-card]:focus-within { border-color: var(--accent); background: var(--surface); outline: none; }
.admin-card.is-disabled .admin-card-action:hover,
.admin-card.is-disabled .admin-card-action:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--text); }
.sign-activity-card { position: relative; }
.sign-card-select { position: absolute; z-index: 2; top: 11px; left: 11px; display: none; align-items: center; justify-content: center; width: 24px; height: 24px; cursor: pointer; }
.sign-card-select input { position: absolute; opacity: 0; pointer-events: none; }
.sign-card-select span { width: 21px; height: 21px; border: 1px solid var(--line); border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgb(var(--shadow-rgb) / 8%); }
.sign-card-select input:checked + span { border-color: var(--accent); background: var(--accent); box-shadow: inset 0 0 0 5px var(--surface); }
.sign-channel-frame.selection-mode .sign-card-select, .sign-channel-frame:has([data-sign-batch-mode]:checked) .sign-card-select { display: inline-flex; }
.sign-channel-frame.selection-mode .sign-activity-card { padding-left: 40px; }
.sign-channel-frame.selection-mode .sign-activity-card:has([data-sign-select]:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.sign-batch-bar { position: absolute; z-index: 10; right: 50%; bottom: 74px; transform: translateX(50%); min-height: 58px; display: inline-flex; align-items: center; gap: 12px; border: 1px solid var(--surface-muted); border-radius: 30px; padding: 8px 12px; background: rgb(var(--surface-rgb) / 96%); box-shadow: 0 14px 30px rgb(var(--shadow-rgb) / 18%); white-space: nowrap; }
.sign-batch-bar[hidden] { display: none; }
.sign-batch-bar strong { color: var(--text); font-size: 14px; font-weight: 600; }
.sign-batch-bar button { width: 40px; height: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--surface-muted); border-radius: 50%; padding: 0; background: var(--surface); color: var(--text); }
.sign-batch-bar button:hover, .sign-batch-bar button:focus-visible { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); }
.sign-batch-bar button[data-sign-batch-action="delete"] { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.sign-batch-bar button svg { width: 18px; height: 18px; }
.sign-batch-close { border-color: var(--line) !important; background: var(--surface) !important; }
.sign-batch-divider { width: 1px; height: 28px; background: var(--surface-muted); }
.task-date-content > .task-batch-bar { position: absolute; z-index: 10; right: 50%; bottom: 74px; transform: translateX(50%); min-height: 58px; display: inline-flex; align-items: center; gap: 12px; border: 1px solid var(--surface-muted); border-radius: 30px; padding: 8px 12px; background: rgb(var(--surface-rgb) / 96%); box-shadow: 0 14px 30px rgb(var(--shadow-rgb) / 18%); white-space: nowrap; }
.task-date-content > .task-batch-bar strong { color: var(--text); font-size: 14px; font-weight: 600; }
.task-date-content > .task-batch-bar button { width: 40px; height: 40px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--surface-muted); border-radius: 50%; padding: 0; background: var(--surface); color: var(--text); }
.task-date-content > .task-batch-bar button:hover, .task-date-content > .task-batch-bar button:focus-visible { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); }
.task-date-content > .task-batch-bar > button[data-task-batch-action="delete"] { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.task-date-content > .task-batch-bar button svg { width: 18px; height: 18px; }
.task-date-content > .task-batch-bar .task-batch-close { border-color: var(--line) !important; background: var(--surface) !important; }
.task-date-content > .task-batch-bar .task-batch-divider { width: 1px; height: 28px; background: var(--surface-muted); }
/* .sign-pagination / .sign-pagination-* 的尺寸与字号已并入 shell.css 的 .table-foot
   统一分页块（.table-foot .sign-pagination-total / -size / -controls），这里不再重复定义，
   否则同一套分页在不同页面会出现两套尺寸。 */
.signature-card-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr)); align-items: stretch; gap: 12px; }
.meituan-entry-column .signature-card-list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.signature-card { min-width: 0; height: 100%; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); padding: 12px; }
.signature-card > header { display: flex; align-items: start; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.signature-card > header h3 { max-width: 18rem; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; }
.signature-card > header small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.signature-summary-card { min-height: 176px; }
.signature-summary-link { display: block; min-width: 0; color: var(--text); text-decoration: none; }
.signature-summary-link:hover { text-decoration: none; }
.meituan-entry-card { display: block; color: var(--text); text-decoration: none; }
.meituan-entry-card { min-height: 290px; padding: 14px 16px; }
.meituan-entry-card > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 18px; }
.signature-summary-link > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 18px; }
.signature-summary-link > header h3 { max-width: 22rem; }
.signature-summary-link > header > svg { width: 17px; height: 17px; color: var(--muted); }
.signature-summary-card.is-disabled > .signature-summary-link { opacity: .56; filter: grayscale(1); }
.signature-summary-meta { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0; border-top: 1px solid var(--surface-muted); padding-top: 12px; }
.signature-summary-meta > div { min-width: 0; display: grid; gap: 4px; border-left: 2px solid var(--surface-muted); padding-left: 8px; }
.signature-summary-meta dt { color: var(--muted); font-size: 11px; }
.signature-summary-meta dd { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; font-weight: 700; }
.cookie-check-card { min-height: 242px; }
.cookie-check-card > form { min-width: 0; display: grid; gap: 12px; }
.cookie-check-card header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.cookie-check-card header h3 { margin: 0; font-size: 15px; }
.cookie-check-card header small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.cookie-check-card.is-disabled > form > :not(header) { opacity: .56; filter: grayscale(1); }
.cookie-check-head-actions { display: flex; align-items: center; gap: 7px; }
.cookie-check-toggle { width: 30px; min-height: 30px; border-color: transparent; padding: 5px; background: transparent; }
.cookie-check-toggle.running { color: var(--accent); }
.cookie-check-toggle.paused { color: var(--danger); }
.cookie-check-toggle:hover, .cookie-check-toggle:focus-visible { border-color: currentColor; background: var(--surface); }
.cookie-check-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cookie-check-times { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; border-top: 1px solid var(--surface-muted); padding-top: 10px; }
.cookie-check-times > div { min-width: 0; display: grid; gap: 3px; }
.cookie-check-times span, .cookie-check-controls label > span { color: var(--muted); font-size: 11px; }
.cookie-check-times strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 600; }
.cookie-check-controls { display: grid; grid-template-columns: minmax(126px, 1fr) auto auto minmax(56px, .72fr); align-items: end; gap: 8px; }
.cookie-check-controls label { display: grid; gap: 4px; }
.cookie-check-controls input { min-height: 34px; padding: 5px 8px; }
.cookie-check-controls input[type="hidden"] { display: none; }
.cookie-check-disabled-value { display: flex; align-items: center; min-height: 34px; color: var(--muted); font-size: 16px; font-weight: 500; }
.cookie-check-controls .icon-only { width: 34px; height: 34px; min-height: 34px; }
.cookie-check-push { align-self: center; color: var(--warning); font-size: 11px; white-space: nowrap; }
.cookie-check-push.ready { color: var(--accent); }
.cookie-check-controls label.cookie-check-push { display: inline-flex; align-items: center; gap: 7px; min-height: 34px; border: 0; border-radius: 0; padding: 7px 0; background: transparent; color: var(--muted); white-space: nowrap; }
.cookie-check-controls label.cookie-check-push input { position: relative; width: 34px; height: 18px; min-height: 18px; margin: 0; padding: 0; border: 0; border-radius: 9px; appearance: none; background: var(--line-strong); cursor: pointer; transition: background .15s ease; }
.cookie-check-controls label.cookie-check-push input::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgb(var(--shadow-rgb) / 18%); transition: transform .15s ease; }
.cookie-check-controls label.cookie-check-push input:checked { background: var(--accent); }
.cookie-check-controls label.cookie-check-push input:checked::after { transform: translateX(16px); }
.cookie-check-controls label.cookie-check-push input:disabled { cursor: not-allowed; opacity: .55; }
.cookie-check-save-state { align-self: center; overflow: hidden; text-align: right; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 11px; }
.cookie-check-save-state.error { color: var(--danger); }
.meituan-lottery-card { display: flex; flex-direction: column; }
.meituan-lottery-card > header { margin-bottom: 12px; }
.meituan-lottery-card .signature-summary-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.meituan-lottery-card > header > .signature-summary-link { flex: 1 1 auto; }
.meituan-lottery-card > header > form { display: flex; }
.meituan-lottery-card.is-disabled > header > form,
.meituan-lottery-card.is-disabled > header > .meituan-edit-link { opacity: .62; filter: grayscale(.7); }
.meituan-edit-link, .meituan-runtime-toggle { width: 30px; height: 30px; min-height: 30px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 6px; padding: 5px; background: transparent; }
.meituan-edit-link svg, .meituan-runtime-toggle svg { width: 15px; height: 15px; }
.meituan-edit-link { color: var(--muted); }
.meituan-runtime-toggle.running { color: var(--accent); }
.meituan-runtime-toggle.paused { color: var(--danger); }
.meituan-edit-link:hover, .meituan-edit-link:focus-visible, .meituan-runtime-toggle:hover, .meituan-runtime-toggle:focus-visible { border-color: currentColor; background: var(--surface); text-decoration: none; }
.sign-workspace { min-width: 0; width: 100%; }
.sign-workspace > .editor-panel-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); padding: 0 0 13px; }
.sign-workspace > .editor-panel-head h2 { margin: 0; font-size: 17px; }
.sign-workspace > .editor-panel-head p { max-width: 58rem; margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.sign-lottery-title-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; }
.sign-lottery-title-row .sign-lottery-create { flex: 0 0 auto; }
.sign-basic-workspace { display: flex; flex-direction: column; gap: 0; }
.sign-basic-workspace > .editor-panel-head { flex: 0 0 auto; }
.signature-edit-grid { display: grid; grid-template-columns: minmax(260px, 1fr) 196px; align-items: end; gap: 14px; }
.sign-target-templates { min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sign-target-field { min-width: 0; display: flex; flex-direction: column; }
.sign-target-field textarea, .signature-edit-form .sign-request-template { width: 100%; font: 12px/1.5 "Cascadia Mono", Consolas, monospace; resize: vertical; }
.sign-target-field textarea { min-height: 174px; }
.sign-target-field small { min-height: 34px; margin: 0 0 5px; line-height: 1.4; }
.sign-fixed-headers { display: grid; grid-template-columns: minmax(180px, .62fr) minmax(0, 1.38fr); align-items: start; gap: 18px; border-top: 1px solid var(--line); padding: 14px 0; }
.sign-fixed-headers h3 { margin: 0; font-size: 13px; }
.sign-fixed-headers p { margin: 5px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.sign-fixed-headers dl { min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 14px; margin: 0; }
.sign-fixed-headers dl > div { min-width: 0; display: grid; grid-template-columns: 86px minmax(0, 1fr); align-items: center; gap: 8px; }
.sign-fixed-headers dt { color: var(--muted); font-size: 11px; }
.sign-fixed-headers dd { min-width: 0; margin: 0; }
.sign-fixed-headers code { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); font: 12px/1.5 "Cascadia Mono", Consolas, monospace; }
.sign-advanced-template { flex: 0 0 auto; min-width: 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 10px 0 12px; }
.sign-advanced-template > h3 { margin: 0 0 8px; color: var(--accent); font-size: 13px; font-weight: 600; }
.sign-advanced-grid { min-width: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.sign-advanced-grid > .field { min-width: 0; }
.sign-advanced-template .sign-request-template { min-height: 280px; height: 280px; max-height: 280px; overflow: auto; resize: none; }
.sign-advanced-template .sign-test-output { background: var(--surface); color: var(--text); }
.sign-advanced-help { min-width: 0; min-height: 28px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: center; column-gap: 14px; margin-top: 5px; }
.sign-advanced-help .muted { min-width: 0; line-height: 1.45; }
.sign-request-test-button { min-height: 26px; height: 26px; justify-self: center; padding: 3px 9px; background: var(--surface); color: var(--accent); font-size: 12px; }
.sign-request-test-button svg { width: 14px; height: 14px; }
.sign-basic-workspace .form-band { flex: 0 0 auto; border-top: 1px solid var(--line); margin: 0; padding: 12px 16px; }
.sign-accounts-workspace { display: grid; align-content: start; gap: 14px; }
.meituan-lottery-workspace { align-content: stretch; }
.meituan-account-list-page { align-content: stretch; }
.meituan-account-form-page { display: grid; align-content: start; gap: 14px; }
.meituan-account-table { min-height: 0; }
.meituan-account-data-table { min-width: 1260px; }
.meituan-account-table th:last-child, .meituan-account-table td:last-child { width: 72px; text-align: right; }
.meituan-account-error { max-width: 22rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.meituan-account-table .icon-only { width: 30px; height: 30px; min-height: 30px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; color: var(--muted); padding: 5px; }
.meituan-account-table .icon-only:hover, .meituan-account-table .icon-only:focus-visible { border-color: currentColor; background: var(--surface); }
.meituan-account-table .icon-only svg { width: 15px; height: 15px; }
.meituan-account-table .danger.icon-only { color: var(--danger); }
.meituan-account-value { max-width: 17rem; }
.meituan-account-value > code { display: inline-block; max-width: calc(100% - 36px); overflow: hidden; text-overflow: ellipsis; vertical-align: middle; white-space: nowrap; }
.meituan-account-value > .icon-only { vertical-align: middle; }
.meituan-account-row-actions { height: 30px; display: inline-flex; align-items: center; gap: 2px; vertical-align: middle; }
.meituan-account-row-actions form { height: 30px; display: inline-flex; align-items: center; margin: 0; }
.meituan-account-form { display: grid; grid-template-columns: minmax(240px, .38fr) minmax(0, 1fr); gap: 16px; border: 1px solid var(--line); border-radius: 6px; padding: 16px; background: var(--surface); }
.meituan-account-form textarea { min-height: 220px; width: 100%; font: 12px/1.5 "Cascadia Mono", Consolas, monospace; resize: vertical; }
.meituan-account-form .form-band { grid-column: 1 / -1; margin: 0; border-top: 1px solid var(--line); padding-top: 12px; }
.sign-lottery-list { display: grid; gap: 8px; }
.sign-lottery-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 5px; padding: 8px; background: var(--surface); }
.sign-lottery-row > form:first-child { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.sign-campaign-add, .signature-account-add { margin: 0; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.sign-campaign-add:not([open]) { display: none; }
.sign-campaign-add summary, .signature-account-add summary { display: flex; align-items: center; gap: 7px; min-height: 42px; padding: 8px 12px; color: var(--accent); cursor: pointer; font-weight: 600; }
.sign-campaign-add summary::marker, .signature-account-add summary::marker { content: ""; }
.sign-campaign-add summary svg { width: 16px; height: 16px; }
.sign-campaign-add > form { display: grid; grid-template-columns: minmax(140px, 1fr) minmax(140px, 1fr) minmax(180px, 1.25fr) repeat(3, minmax(82px, .55fr)) auto auto; align-items: end; gap: 8px; border-top: 1px solid var(--line); padding: 12px; }
.sign-campaign-add .checkbox-field, .sign-campaign-form .checkbox-field { min-height: 38px; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; }
.sign-campaign-add .checkbox-field input, .sign-campaign-form .checkbox-field input { width: 16px; min-height: 16px; margin: 0; }
.sign-campaign-list, .sign-account-list { min-width: 0; display: grid; align-items: start; gap: 12px; }
.sign-campaign-list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.sign-account-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sign-campaign-card { min-width: 0; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); overflow: hidden; }
.sign-campaign-card.is-disabled { border-color: var(--line); background: var(--surface-muted); color: var(--muted); }
.sign-campaign-card:hover,
.sign-campaign-card:focus-within { border-color: var(--accent); background: var(--surface); outline: none; }
.sign-campaign-card.is-disabled .sign-campaign-head { border-bottom-color: var(--line); }
.sign-campaign-card.is-disabled .sign-campaign-head > .sign-campaign-form,
.sign-campaign-card.is-disabled .sign-campaign-items { opacity: .56; filter: grayscale(1); }
.sign-campaign-card.is-disabled .sign-campaign-items { background: transparent; }
.sign-lottery-workspace { position: relative; gap: 0; }
.sign-lottery-workspace > .sign-section-head { min-height: 60px; padding: 14px 16px 12px; }
.sign-lottery-workspace > .sign-section-head > div { flex: 1 1 auto; min-width: 0; }
.sign-lottery-workspace > .sign-section-head p { display: none; }
.sign-lottery-workspace > .sign-campaign-list { grid-row: 2; min-height: 0; overflow: auto; align-content: start; padding: 0 16px 16px; scrollbar-gutter: stable; }
.sign-lottery-workspace > .sign-campaign-add[open] { position: absolute; z-index: 5; top: 60px; right: 16px; left: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: 0 12px 28px rgb(var(--shadow-rgb) / 16%); }
.sign-lottery-workspace > .table-foot .sign-pagination-size select:disabled { opacity: 1; color: var(--text); cursor: default; }
.sign-lottery-workspace .sign-lottery-create { border-color: var(--line); background: var(--surface); color: var(--muted); }
.sign-lottery-workspace .sign-lottery-create:hover, .sign-lottery-workspace .sign-lottery-create:focus-visible { border-color: var(--accent); background: var(--surface-muted); color: var(--accent); }
.sign-campaign-head { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: end; gap: 6px; border-bottom: 1px solid var(--surface-muted); padding: 12px; }
.sign-campaign-form { min-width: 0; display: grid; grid-template-columns: minmax(130px, 1fr) minmax(130px, 1fr) minmax(140px, 1.15fr) repeat(3, minmax(76px, .54fr)) auto auto; align-items: end; gap: 8px; }
.sign-campaign-form .field.compact, .sign-campaign-form .checkbox-field { grid-column: auto; }
.sign-campaign-form .field.compact { justify-items: stretch; }
.sign-campaign-form .icon-only { grid-column: auto; justify-self: end; }
.sign-campaign-form .field label, .sign-campaign-add .field label { font-size: 11px; }
.sign-campaign-form .field input { min-width: 0; width: 100%; max-width: 100%; justify-self: stretch; }
.sign-campaign-form .field.compact input { width: 100%; max-width: 100%; }
.sign-campaign-toggle, .sign-campaign-head > form:last-child { display: flex; }
.sign-campaign-items { min-width: 0; border-top: 0; padding: 10px 12px 12px; background: var(--surface); }
.sign-campaign-items-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.sign-campaign-items-title h3 { margin: 0; font-size: 13px; }
.sign-campaign-items-title span { display: none; }
.sign-item-add { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; margin-bottom: 8px; }
.sign-item-add .icon-only { justify-self: start; }
.sign-lottery-row { grid-template-columns: minmax(0, 1fr) auto auto; }
.sign-lottery-row > form:first-child { grid-template-columns: minmax(0, 1fr) auto; }
.danger-text { color: var(--danger); }
.success-text { color: var(--accent); }
.sign-campaign-card { height: clamp(340px, calc((100dvh - 250px) / 2), 400px); min-height: 340px; }
.sign-campaign-head { position: relative; height: 126px; min-height: 126px; display: block; padding: 7px 8px; }
.sign-campaign-form { --campaign-actions-width: 76px; box-sizing: border-box; min-width: 0; width: 100%; display: flex; flex-wrap: wrap; align-items: end; gap: 8px; }
.sign-campaign-form > .field:first-of-type { flex: 0 0 144px; min-width: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); align-items: center; gap: 8px; margin-right: 0; }
.sign-campaign-form > .field:first-of-type label { white-space: nowrap; }
.sign-campaign-form > .field:first-of-type input { min-height: 30px; max-width: 96px; padding: 5px 7px; }
.sign-campaign-form > .field:nth-of-type(3), .sign-campaign-form > .checkbox-field, .sign-campaign-form > button { display: none; }
.sign-campaign-form > .field:nth-of-type(2) { flex: 0 1 calc(100% - 228px); min-width: 0; display: grid; grid-template-columns: max-content minmax(0, 1fr); align-items: center; gap: 8px; margin-right: 0; }
.sign-campaign-form > .field:nth-of-type(2) input { min-height: 30px; min-width: 0; overflow: hidden; padding: 5px 7px; text-overflow: ellipsis; white-space: nowrap; }
.sign-campaign-form > .field:first-of-type { order: 1; }
.sign-campaign-form > .field:nth-of-type(2) { order: 3; flex: 1 1 100%; min-width: 0; }
.sign-campaign-form .field.compact { order: 2; flex: 0 1 calc((100% - 16px) / 3); min-width: 0; gap: 3px; }
.sign-campaign-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(3, 40px); align-items: end; column-gap: 8px; row-gap: 6px; padding: 38px 0 0; }
.sign-campaign-form > .field:first-of-type { grid-column: 1 / -1; grid-row: 1; display: grid; grid-template-columns: 1fr; gap: 3px; }
.sign-campaign-form > .field:first-of-type input { max-width: none; }
.sign-campaign-form > .field:nth-of-type(2) { grid-column: 1 / -1; grid-row: 3; display: grid; grid-template-columns: 1fr; gap: 3px; }
.sign-campaign-form .field.compact { display: grid; flex: none; }
.sign-campaign-form .field.compact:nth-of-type(4) { grid-column: 1; grid-row: 2; }
.sign-campaign-form .field.compact:nth-of-type(5) { grid-column: 2; grid-row: 2; }
.sign-campaign-form .field.compact:nth-of-type(6) { grid-column: 3; grid-row: 2; }
.sign-campaign-form .field.compact input { box-sizing: border-box; width: 100%; max-width: none; min-width: 0; height: 30px; min-height: 30px; padding: 5px 7px; }
.sign-campaign-form .field.compact label { overflow: visible; font-size: 10px; line-height: 1; text-overflow: clip; white-space: nowrap; }
.sign-campaign-form .request-source-save-state { position: absolute; left: 50%; right: auto; bottom: 7px; min-height: 12px; transform: translateX(-50%); color: var(--muted); font-size: 10px; }
.sign-campaign-items { min-height: 0; display: flex; flex: 1 1 auto; flex-direction: column; }
.sign-campaign-items { padding: 6px 8px 8px; }
.sign-campaign-items-title { margin-bottom: 4px; }
.sign-campaign-items-title h3 { font-size: 11px; }
.sign-lottery-scroll { min-height: 0; max-height: 132px; flex: 0 0 132px; overflow-y: auto; overscroll-behavior: contain; padding-right: 2px; }
.sign-lottery-scroll .sign-lottery-row { grid-template-columns: minmax(0, 1fr) auto auto; }
.sign-lottery-row { gap: 5px; padding: 4px 5px; }
.sign-lottery-row input { min-height: 30px; padding: 5px 7px; }
.sign-lottery-row .icon-only, .sign-item-add .icon-only { width: 30px; height: 30px; min-height: 30px; padding: 6px; }
.sign-lottery-edit-form { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) max-content; align-items: center; gap: 8px; }
.sign-lottery-row > .sign-lottery-edit-form { width: 100%; }
.sign-lottery-row > .sign-lottery-edit-form { min-width: 0; justify-self: stretch; grid-template-columns: minmax(0, 1fr) 0; gap: 0; }
.sign-lottery-row > .sign-lottery-edit-form .request-source-save-state { width: 0; min-width: 0; overflow: hidden; }
.sign-lottery-edit-form input { width: 100%; min-width: 0; }
.sign-lottery-edit-form .request-source-save-state { min-width: 42px; color: var(--muted); font-size: 10px; white-space: nowrap; }
.sign-campaign-toggle, .sign-campaign-head > form:last-child { position: absolute; top: 7px; display: flex; align-items: center; }
.sign-campaign-toggle { right: 42px; }
.sign-campaign-head > form:last-child { right: 8px; }
.sign-campaign-head > form .icon-only { width: 30px; height: 30px; min-height: 30px; padding: 6px; }
.sign-item-add { flex: 0 0 auto; margin-top: 5px; gap: 5px; }
.sign-item-add input { min-height: 30px; padding: 5px 7px; }
.sign-account-card { min-width: 0; min-height: 162px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: start; border: 1px solid var(--line); border-radius: 6px; padding: 14px; background: var(--surface); }
.sign-account-card > form:first-child { min-width: 0; display: grid; gap: 8px; }
.sign-account-summary { min-width: 0; display: grid; gap: 12px; }
.sign-account-heading { display: flex; align-items: center; gap: 8px; }
.sign-account-heading strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sign-account-values { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; border-top: 1px solid var(--surface-muted); padding-top: 10px; }
.sign-account-values label { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) 30px; gap: 4px 6px; color: var(--muted); font-size: 11px; }
.sign-account-label { grid-column: 1 / -1; }
.sign-account-values label > .sign-account-value { min-width: 0; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text); font-family: "Cascadia Mono", Consolas, monospace; font-size: 12px; line-height: 30px; }
.sign-account-values label > .icon-only { grid-column: 2; grid-row: 2; }
.signature-account-add form { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 12px; border-top: 1px solid var(--line); padding: 14px; }
.signature-account-add form .field { min-width: 0; }
.signature-card-form { display: grid; gap: 9px; }
.signature-card-form .field { gap: 4px; }
.signature-card-form .field label { font-size: 11px; }
.signature-card-form input, .signature-card-form textarea { min-height: 34px; padding: 6px 8px; font-size: 12px; }
.signature-card-form textarea { min-height: 64px; font-family: "Cascadia Mono", Consolas, monospace; resize: vertical; }
.lottery-item-row { display: grid; grid-template-columns: minmax(0, 1fr) 5.25rem 32px; align-items: center; gap: 6px; }
.lottery-item-row input { width: 100%; }
.lottery-item-row .icon-only { width: 32px; height: 32px; min-height: 32px; padding: 0; }
.activity-card { min-width: 0; min-height: 270px; display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); padding: 12px; cursor: pointer; }
.activity-card input, .activity-card button, .activity-card a { cursor: auto; }
.activity-card button, .activity-card a { cursor: pointer; }
.activity-card-head { min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 10px; }
.activity-card-identity { min-width: 0; display: grid; gap: 6px; }
.activity-card-title { min-width: 0; display: flex; align-items: center; gap: 8px; }
.activity-card-title h2 { min-width: 0; margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 16px; }
.activity-status-form { display: flex; }
.activity-card-url { min-width: 0; display: flex; flex-wrap: nowrap; align-items: baseline; gap: 8px; color: var(--muted); font-size: 12px; white-space: nowrap; }
.activity-card-url > span { flex: 0 0 auto; }
.activity-card-url code { min-width: 0; overflow: hidden; color: var(--text); text-overflow: ellipsis; white-space: nowrap; }
.activity-card-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.activity-card-actions form { display: flex; }
.activity-card-action { border-color: transparent; background: transparent; }
.activity-card-action:hover, .activity-card-action:focus-visible { border-color: currentColor; background: var(--surface); }
.icon-only { width: 34px; padding: 7px; }
.activity-runtime-form { min-width: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 9px; border-top: 1px solid var(--line); margin-top: 12px; padding-top: 12px; }
.activity-runtime-form .field { gap: 4px; }
.activity-runtime-form .field label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.activity-runtime-form .field.compact { justify-items: stretch; }
.activity-runtime-form .field.compact input, .activity-runtime-form .field.datetime input { width: 100%; min-width: 0; min-height: 34px; padding: 6px 7px; }
.activity-runtime-form .field.datetime { grid-column: 1 / -1; justify-items: stretch; }
.activity-runtime-form .activity-save-state { min-height: 16px; color: var(--muted); font-size: 11px; }
.activity-runtime-form .activity-save-state.error { color: var(--danger); }
.activity-edit-form { border-radius: 8px; border-color: var(--line); box-shadow: 0 4px 16px rgb(var(--shadow-rgb) / .06); }
.activity-card[data-store-activity-card] { cursor: default; }
.activity-card[data-store-activity-card] { position: relative; }
.activity-card[data-store-activity-card][data-store-enabled="false"] .activity-card-head { opacity: .62; filter: grayscale(.7); }
.activity-card[data-store-activity-card][data-store-enabled="false"] .activity-runtime-form { opacity: 1; filter: none; }
.activity-card[data-store-activity-card][data-store-enabled="false"] .activity-runtime-form input:not(:disabled) { background: var(--surface); color: var(--text); border-color: var(--accent-soft); cursor: text; }
.activity-card[data-store-activity-card] .activity-runtime-form { display: block; border-top: 1px solid var(--surface-muted); margin-top: 12px; padding-top: 10px; }
.activity-card[data-store-activity-card] .activity-runtime-execute-at { grid-column: 1 / -1; }
/* 启停按钮用图标 + 文案表达「点击后会发生什么」：运行中→暂停，已停用→启动。
   活动状态本身已经由卡片是否置灰表达，所以按钮不再用颜色区分状态，而是颜色跟着动作走：
   启动用 accent，暂停用编辑页 PAUSED 胶囊的 warning（可逆操作，不用 danger 红）。 */
.activity-runtime-toggle, .sign-runtime-toggle { min-width: 34px; height: 34px; min-height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 2px; border: 1px solid transparent; border-radius: 6px; padding: 0 4px; background: transparent; font-size: 12px; font-weight: 600; white-space: nowrap; }
.activity-runtime-toggle svg, .sign-runtime-toggle svg { width: 13px; height: 13px; }
.activity-runtime-toggle.running, .sign-runtime-toggle.running { border-color: var(--warning); color: var(--warning); }
.activity-runtime-toggle.paused, .sign-runtime-toggle.paused { border-color: var(--accent); color: var(--accent); }
.activity-runtime-toggle:hover, .activity-runtime-toggle:focus-visible, .sign-runtime-toggle:hover, .sign-runtime-toggle:focus-visible { background: var(--surface); }
.activity-runtime-toggle.running:hover, .activity-runtime-toggle.running:focus-visible, .sign-runtime-toggle.running:hover, .sign-runtime-toggle.running:focus-visible { border-color: var(--warning); background: var(--warning-soft); }
.activity-runtime-toggle.paused:hover, .activity-runtime-toggle.paused:focus-visible, .sign-runtime-toggle.paused:hover, .sign-runtime-toggle.paused:focus-visible { border-color: var(--accent); background: var(--accent-soft); }
.activity-card[data-store-activity-card] .activity-card-action { width: 34px; height: 34px; min-height: 34px; }
.admin-card .activity-card-action:hover,
.admin-card .activity-card-action:focus-visible,
[data-admin-card] .activity-card-action:hover,
[data-admin-card] .activity-card-action:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--text); }
.admin-card.activity-card, [data-admin-card].activity-card { min-height: 270px; height: auto; padding: 14px 16px; }
.admin-card.activity-card .activity-card-head, [data-admin-card].activity-card .activity-card-head { align-items: center; }
.activity-card[data-store-activity-card] .activity-card-title { min-height: 22px; }
.activity-card[data-store-activity-card] .sign-runtime-metrics { gap: 10px 12px; }
.store-channel-frame:not(.store-group-active):not(.selection-mode) [data-store-activity-card] .sign-card-select { display: none !important; }
.store-channel-frame:not(.store-group-active).selection-mode .store-group-card,
.store-channel-frame:not(.store-group-active).selection-mode [data-store-activity-card] { padding-left: 52px; }
.store-channel-frame.selection-mode [data-store-activity-card]:has([data-sign-select]:checked) { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.store-card-feature-status { margin-top: auto; }
.store-group-edit, .store-group-add, .store-group-delete { position: absolute; z-index: 1; top: 10px; width: 32px; height: 32px; min-height: 32px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 7px; padding: 6px; background: transparent; color: var(--muted); }
.store-group-delete { right: 10px; }
.store-group-edit { right: 48px; }
.store-group-edit:hover, .store-group-edit:focus-visible, .store-group-add:hover, .store-group-add:focus-visible, .store-group-delete:hover, .store-group-delete:focus-visible { border-color: var(--line-strong); background: var(--surface); color: var(--text); }
button.store-group-delete { border-color: transparent; background: transparent; color: var(--danger); }
button.store-group-delete:hover, button.store-group-delete:focus-visible { border-color: var(--danger-soft); background: var(--surface); color: var(--danger); }
.store-group-edit svg, .store-group-add svg, .store-group-delete svg { width: 16px; height: 16px; }
.store-group-dialog { width: min(500px, calc(100vw - 28px)); padding: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); box-shadow: 0 20px 60px rgb(var(--shadow-rgb) / .24); }
.store-group-dialog::backdrop { background: rgb(var(--shadow-rgb) / .42); }
.store-group-dialog form { display: grid; gap: 16px; padding: 18px; }
.store-group-dialog header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.store-group-dialog h2 { margin: 0; font-size: 17px; }
.store-group-dialog-actions { display: flex; justify-content: flex-end; gap: 8px; }
.admin-alert-dialog { width: min(420px, calc(100vw - 28px)); max-width: calc(100vw - 28px); padding: 0; border: 0; border-radius: 12px; background: var(--surface); color: var(--text); box-shadow: 0 20px 60px rgb(var(--shadow-rgb) / .24); }
.admin-alert-dialog::backdrop { background: rgb(var(--shadow-rgb) / .46); }
.admin-alert-dialog form { display: grid; gap: 12px; padding: 18px 18px 0; }
.admin-alert-dialog header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.admin-alert-dialog h2 { margin: 0; font-size: 17px; font-weight: 650; }
.admin-alert-dialog p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.55; overflow-wrap: anywhere; }
.admin-alert-dialog footer { display: flex; justify-content: flex-end; gap: 8px; margin: 4px -18px 0; padding: 14px 18px; border-top: 1px solid var(--line); background: var(--surface-muted); }
.admin-alert-dialog footer .button { min-width: 72px; }
.admin-alert-dialog footer .button.danger { border-color: transparent; background: color-mix(in srgb, var(--danger) 10%, transparent); color: var(--danger); }
.admin-alert-dialog footer .button.danger:hover, .admin-alert-dialog footer .button.danger:focus-visible { border-color: color-mix(in srgb, var(--danger) 25%, transparent); background: color-mix(in srgb, var(--danger) 17%, transparent); color: var(--danger); }
@media (max-width: 560px) { .admin-alert-dialog footer { flex-direction: column-reverse; } .admin-alert-dialog footer .button { width: 100%; } }
.sign-activity-card { cursor: default; }
.sign-activity-card.is-disabled .activity-card-head { opacity: .62; filter: grayscale(.7); }
.sign-activity-card.is-disabled .activity-runtime-form { opacity: 1; filter: none; }
.sign-activity-card.is-disabled .activity-runtime-form input:not(:disabled) {
  background: var(--surface);
  color: var(--text);
  border-color: var(--accent-soft);
  cursor: text;
}
.sign-activity-card.is-disabled .activity-runtime-form input:not(:disabled):focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 14%, transparent);
  outline: none;
}
.sign-activity-card .activity-runtime-form { display: block; border-top: 1px solid var(--surface-muted); margin-top: 12px; padding-top: 10px; }
.sign-runtime-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 12px; }
.sign-runtime-metrics .field { min-width: 0; gap: 3px; border-left: 2px solid var(--surface-muted); padding-left: 6px; }
.sign-runtime-metrics .field label { color: var(--muted); font-size: 11px; }
.sign-runtime-metrics .field input { box-sizing: border-box; width: 100%; min-width: 0; min-height: 30px; padding: 5px 7px; font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.sign-runtime-metrics .sign-runtime-execute-at { grid-column: 1 / -1; }
/* 卡片上的执行时间沿用编辑页的分段输入：提示与标签同排、紧贴 label 右边，
   控件高度对齐同卡片其它输入框，所以卡片高度不变（原 .ax-dt 是按编辑页 40px 行高设计的，这里压到 30px）。 */
.sign-runtime-metrics .field:has(> .ax-dt-box) { grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 8px; }
.sign-runtime-metrics .field:has(> .ax-dt-box) > label { grid-area: 1 / 1; }
.sign-runtime-metrics .field:has(> .ax-dt-box) > .ax-dt-box { display: contents; }
/* 卡片上的分段控件是两段式（日期框 + 时间框）：比合并态宽 19px，而卡片网格最窄只到 360px
   （可用内容宽 ~319px）。这里把组间距 7→6、组内边距 7→6、「现在」内边距 9→8，共省 8px，
   让它在最窄的卡片上也按自然宽度渲染 —— 否则 flex 只能压缩分组，内部数字会顶到边框上。
   合并态时代余量本来就够，所以这组收紧只对两段式有意义。 */
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt { grid-area: 2 / 1 / 3 / 3; gap: 6px; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-group { min-height: 30px; border-color: var(--line); border-radius: 5px; padding: 0 6px; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-seg { min-height: 22px !important; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-seg::placeholder { color: var(--muted); opacity: 1; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-now { min-height: 30px; padding: 4px 8px; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-now svg { width: 14px; height: 14px; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-state { grid-area: 1 / 2; min-width: 0; justify-content: flex-start; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-state svg { flex: 0 0 auto; }
.sign-runtime-metrics .field:has(> .ax-dt-box) .ax-dt-state > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sign-card-feature-status { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; border-top: 1px solid var(--surface-muted); margin-top: 11px; padding-top: 9px; }
.sign-card-feature-form, .sign-card-tls-form { margin: 0; }
.sign-card-feature-status > form { display: flex; align-items: center; }
.sign-card-feature { min-height: 28px; display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 600; }
.sign-card-feature:has(.sign-card-feature-input:not(:disabled)) { cursor: pointer; }
.sign-card-feature-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.sign-card-feature i { position: relative; width: 30px; height: 18px; flex: 0 0 auto; border-radius: 9px; background: var(--line); }
.sign-card-feature i::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgb(var(--shadow-rgb) / 18%); }
.sign-card-feature.is-on { color: var(--accent-hover); }
.sign-card-feature.is-on i { background: var(--accent); }
.sign-card-feature.is-on i::after { transform: translateX(12px); }
.sign-card-feature-input:focus-visible + i { outline: 2px solid var(--accent); outline-offset: 2px; }
.sign-console-status { display: inline-flex; align-items: center; gap: 5px; border-radius: 999px; padding: 5px 8px; font: 700 10px/1 Inter, "Segoe UI", Arial, sans-serif; letter-spacing: .04em; }
.sign-console-status svg { width: 13px; height: 13px; }
.sign-console-status.running { background: var(--surface-muted); color: var(--accent-hover); }
.sign-console-status.paused { background: var(--surface-muted); color: var(--danger); }
.sign-activity-card .activity-card-action { width: 34px; height: 34px; min-height: 34px; display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; padding: 7px; background: transparent; }
.sign-activity-card .activity-card-action svg { width: 16px; height: 16px; }
.success-text { color: var(--accent); }
.warning-text, .attempt-warning { color: var(--danger); }
.preparation-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: stretch; border-top: 1px solid var(--line); background: var(--surface); font-size: 12px; }
.preparation-summary > span { min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 4px; min-height: 74px; border-right: 1px solid var(--line); padding: 12px 14px; color: var(--muted); }
.preparation-summary > span:last-child { border-right: 0; }
.preparation-summary > span b { color: var(--text); font-size: 18px; line-height: 1.15; }
.preparation-summary > .dns-resolution { border-top: 2px solid var(--accent); background: var(--accent-soft); color: var(--accent-hover); }
.preparation-summary > .dns-resolution.dns-fallback { border-top-color: var(--warning); background: var(--surface-muted); color: var(--warning); }
.preparation-summary > .attempt-warning { grid-column: 1 / -1; flex-direction: row; align-items: center; min-height: 42px; border-top: 1px solid var(--danger-soft); border-right: 0; padding-top: 9px; padding-bottom: 9px; }
.preparation-summary > .attempt-warning { color: var(--danger); }
.preparation-summary > .attempt-warning svg { color: var(--danger); stroke: currentColor; }
.preparation-summary > .attempt-warning b { font-size: 12px; }
.attempt-warning { display: inline-flex; align-items: center; gap: 5px; }
.attempt-warning svg { width: 15px; height: 15px; }
.ntp-warning { color: var(--danger); background: var(--surface); border: 1px solid var(--danger-soft); border-radius: 4px; padding: 6px 8px; font-weight: 650; }
.preparation-summary > .ntp-warning { border-top: 1px solid var(--danger-soft); }
.proxy-warning { margin-top: 10px; font-weight: 650; }
.proxy-direct-fallback { color: var(--danger); background: var(--surface); border: 1px solid var(--danger-soft); padding: 10px 12px; }
.attempt-results { max-height: 560px; overflow: auto; }
.task-response-output.attempt-results { height: 100%; max-height: none; min-height: 0; }
/* width: max-content 会让整个 grid 按「内容不折行的理想宽度」布局，
   于是 minmax(300px, 1fr) 那一列被长响应撑到上千像素、pre-wrap 根本没机会生效
   （实测一条 289 字符的单行 JSON 把整行推到 2753px，横向滚动 1453px）。
   改成 100% 后列宽受容器约束，长响应正常折行；最小宽度仍由 .result-log-line 兜底。 */
.result-log { width: 100%; min-height: 100%; background: var(--nav); color: var(--nav-text); font: 12px/1.5 "Cascadia Mono", Consolas, monospace; }
.result-log-line { min-width: 1180px; display: grid; grid-template-columns: 190px minmax(150px, 190px) 58px 58px 72px minmax(300px, 1fr) 10px max-content; align-items: start; gap: 10px; padding: 8px 16px 8px 12px; border-bottom: 1px solid var(--nav-line); }
.result-log-line:last-child { border-bottom: 0; }
.result-log-line.coupon-success-result { background: color-mix(in srgb, var(--accent) 28%, var(--nav)); box-shadow: inset 5px 0 0 var(--accent); }
.result-log-line.coupon-success-result .result-log-response { color: var(--nav-text-strong); font-weight: 700; }
.result-log-line time { color: var(--nav-text); white-space: nowrap; }
.result-log-user { overflow: hidden; color: var(--nav-text); text-overflow: ellipsis; white-space: nowrap; }
.result-log-line b { color: var(--nav-text); white-space: nowrap; }
/* 级别与状态色都画在深色的结果日志上，所以用 --nav-* 一档亮色，
   而不是为浅底调的 --accent / --danger（它们在深底上只有 2.4~3.4:1）。 */
.result-log-level.info { color: var(--nav-success); }
.result-log-level.error { color: var(--nav-danger); }
/* 状态按 HTTP 状态码着色（判定在 Go 侧做一次，模板只负责挂类）：
   2xx 绿、其余红。注意这与整行的 .coupon-success-result 无关 —— 那个跟的是
   「业务成功」，一条 status=200 但业务返回 success:false 的记录仍应是绿色的 200。 */
.result-log-status.ok { color: var(--nav-success); }
.result-log-status.bad { color: var(--nav-danger); }
/* 响应体常常是一整行没有换行的 JSON。折行之后长内容仍会占掉十几行，
   把其它记录挤出视野，所以行内截断到 6 行、末尾渐隐，点击打开完整查看。 */
.result-log-response { color: var(--nav-text); white-space: pre-wrap; overflow-wrap: anywhere; max-height: 108px; overflow: hidden; cursor: zoom-in; }
.result-log-response.is-truncated { -webkit-mask-image: linear-gradient(black 65%, transparent); mask-image: linear-gradient(black 65%, transparent); }
.result-log-tail { min-width: 0; color: var(--nav-text); white-space: nowrap; }

/* 响应全文弹窗：行内只放得下 6 行，完整内容在这里看。
   注意 display:flex 会盖掉 dialog 未打开时的 display:none，所以显式补一条。 */
.result-detail-dialog { box-sizing: border-box; width: min(1080px, calc(100vw - 48px)); max-width: calc(100vw - 48px); max-height: calc(100dvh - 56px); display: flex; flex-direction: column; overflow: hidden; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--text); box-shadow: 0 30px 90px rgb(var(--shadow-rgb) / .34); }
.result-detail-dialog:not([open]) { display: none; }
.result-detail-dialog::backdrop { background: rgb(var(--shadow-rgb) / .52); }
.result-detail-dialog > header { flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.result-detail-dialog h2 { display: flex; align-items: center; gap: 7px; margin: 0; font-size: 15px; }
.result-detail-dialog h2 svg { width: 16px; height: 16px; color: var(--accent); }
.result-detail-meta { flex: 0 0 auto; display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 9px 14px; border-bottom: 1px solid var(--line); background: var(--surface-soft); color: var(--muted); font-size: 12px; }
.result-detail-meta b { color: var(--text-soft); font-weight: 650; }
.result-detail-meta .result-detail-ready { color: var(--success); }
.result-detail-meta .result-detail-failed { color: var(--danger); }
.result-detail-body { flex: 1 1 auto; min-height: 140px; margin: 0; overflow: auto; padding: 14px; background: var(--nav); color: var(--nav-text); font: 12px/1.6 "Cascadia Mono", Consolas, monospace; white-space: pre-wrap; overflow-wrap: anywhere; tab-size: 2; }
.result-detail-dialog > footer { flex: 0 0 auto; display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 11px 14px; border-top: 1px solid var(--line); }
.result-detail-length { margin-right: auto; color: var(--muted); font-size: 12px; }
.execution-controls { min-width: 0; display: flex; flex-wrap: wrap; align-items: end; gap: 14px 18px; }
.worker-selector-fields { position: relative; width: 100%; max-width: 100%; min-width: 0; flex: 1 1 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 10px 12px; }
.worker-selector-fields [hidden] { display: none !important; }
.worker-selector-fields > [data-worker-selector-region],
.worker-selector-fields > [data-worker-selector-labels] { display: none !important; }
.worker-selector-fields .field input,
.worker-selector-fields .field select { width: 100%; min-width: 0; min-height: 38px; }
.worker-selector-fields [data-worker-selector-labels] { grid-template-columns: minmax(0, 1fr) minmax(150px, .65fr); align-items: end; }
.worker-selector-fields [data-worker-selector-labels] > label { grid-column: 1 / -1; }
.forward-worker-selector { width: 100%; flex: 1 1 100%; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 10px 12px; padding-top: 4px; }
.forward-worker-selector .field input,
.forward-worker-selector .field select { width: 100%; min-width: 0; min-height: 38px; }
/* 这几个都是「留在 DOM 里但必须看不见」的原生表单控件（真正带 name 的提交字段，
   可见的那层只是界面）。规矩与 .ax-dt-native 一致：光靠 1px + clip-path 不够 ——
   box-sizing: border-box 下 padding/border 会把 1px 的盒子撑到 18×14，
   全靠 clip-path 挡着；那道防线一失效就露出来。所以四件事一起做：
   ① padding/border 清零，盒子真的 1px；② overflow/clip/clip-path 裁剪；
   ③ 全部 !important，免得被泛化的 input/select 规则顶掉；④ opacity + pointer-events 兜底。 */
.worker-picker-native { position: absolute !important; width: 1px !important; height: 1px !important; min-width: 1px !important; min-height: 1px !important; padding: 0 !important; border: 0 !important; overflow: hidden !important; clip: rect(0 0 0 0); clip-path: inset(50%); opacity: 0; pointer-events: none; }
.worker-picker-trigger { width: 100%; min-width: 0; min-height: 38px; display: inline-flex; align-items: center; justify-content: space-between; gap: 8px; border: 1px solid var(--line); border-radius: 5px; padding: 8px 10px; background: var(--surface); color: var(--text); text-align: left; }
.worker-picker-trigger:hover, .worker-picker-trigger:focus-visible { border-color: var(--line-strong); background: var(--surface); outline: 0; }
.worker-picker-trigger:disabled { cursor: not-allowed; opacity: .55; }
.worker-picker-trigger span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.worker-picker-trigger svg { flex: 0 0 auto; width: 15px; height: 15px; color: var(--muted); }
.worker-selector-popover { position: fixed; z-index: 90; box-sizing: border-box; min-width: 260px; max-width: min(460px, calc(100vw - 16px)); border: 1px solid var(--line); border-radius: 6px; padding: 8px; background: var(--surface); box-shadow: 0 12px 28px rgb(var(--shadow-rgb) / .22); }
.worker-selector-popover.worker-picker-mode-layout { display: grid; gap: 10px; grid-template-columns: minmax(150px, .8fr) minmax(180px, 1fr); }
.worker-selector-popover.worker-picker-mode-layout[data-worker-picker-open-kind="mode"] { grid-template-columns: minmax(180px, 1fr); }
.worker-selector-popover.worker-picker-mode-layout[data-worker-picker-open-kind="labels"] { grid-template-columns: minmax(150px, .8fr) minmax(280px, 1.2fr); }
.worker-picker-panel[hidden] { display: none !important; }
.worker-picker-columns { display: grid; grid-template-columns: minmax(150px, 1fr) minmax(120px, .8fr); gap: 10px; }
.worker-picker-column { min-width: 0; display: grid; gap: 5px; }
.worker-picker-column-title { color: var(--muted); font-size: 11px; font-weight: 700; }
.worker-picker-scroll { display: grid; gap: 2px; min-width: 0; max-height: 190px; overflow-y: auto; overscroll-behavior: contain; scrollbar-color: var(--muted) transparent; scrollbar-width: thin; border: 1px solid var(--line); border-radius: 5px; background: var(--surface-muted); padding: 3px; }
/* justify-content 必须显式写 flex-start：不写就会被上面第 22 行的全局 `button` 基座
   （inline-flex + justify-content: center）接管，选项文字变成居中 —— 实测选项盒 234px、文字左右各空 105px，
   而列表（标签长短不一时尤其明显）应当左对齐，也是原下拉的样子。 */
.worker-picker-option { width: 100%; min-height: 34px; display: flex; align-items: center; justify-content: flex-start; gap: 7px; border: 0; border-radius: 3px; padding: 6px 8px; background: var(--surface-muted); color: var(--text); font-size: 12px; text-align: left; cursor: pointer; }
.worker-picker-option:hover, .worker-picker-option:focus-visible { background: var(--accent-soft); color: var(--accent); outline: 0; }
.worker-picker-option[aria-selected="true"], .worker-picker-option.active { background: var(--accent); color: var(--text-on-strong); }
.field { min-width: 0; display: grid; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 12px; color: var(--text-soft); font-weight: 600; }
.field input, .field select, .field textarea { width: 100%; min-height: 38px; border: 1px solid var(--line); border-radius: 5px; padding: 8px 10px; background: var(--surface); color: var(--text); }
.field textarea { min-height: 82px; resize: vertical; }
/* 上面那条 `.field input` 的 width:100% / min-height:38px 是给**文本框**的。勾选框落在同一条规则里
   会被拉成 860×38 的一条横幅，label 的文字还被顶到下一行 —— 设置页「清除 Bridge Token」就是这样，
   看起来像一块没做完的灰方块。勾选框按 16px 的控件走，label 变 inline-flex 让它和文字同一行
   （点了文字也能切换），尺寸与 .checkbox-field / .proxy-toggle 那两处既有写法一致。 */
.field label:has(> input[type="checkbox"]) { min-height: 38px; display: inline-flex; align-items: center; gap: 8px; }
.field input[type="checkbox"] { width: 16px; min-width: 16px; height: 16px; min-height: 16px; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; }
.field.compact { justify-items: start; }
.field.compact input, .field.compact select { width: 9rem; }
.field.compact-wide { justify-items: start; }
.field.compact-wide select { width: 12rem; }
.field.datetime { justify-items: start; }
.field .execution-datetime { width: 15rem; }
.success-keyword-field { flex: 1 1 18rem; width: auto; max-width: none; }
.success-keyword-field input { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.success-keyword-field input:focus { text-overflow: clip; }
.cache-settings-row { width: calc(50% - 9px); max-width: calc(50% - 9px); display: grid; grid-template-columns: 1.25fr .8fr .8fr 1.4fr; align-items: end; }
.cache-settings-row .field.compact, .cache-settings-row .field.compact-wide { min-width: 0; justify-items: stretch; }
.cache-settings-row .field.compact input, .cache-settings-row .field.compact select, .cache-settings-row .field.compact-wide select { width: 100%; }
.cache-settings-row .success-keyword-field { width: auto; max-width: none; }
.push-toggle-field { align-self: end; }
.proxy-policy { grid-column: 1 / -1; display: flex; align-items: end; gap: 14px; padding-top: 4px; }
.proxy-toggle { min-height: 38px; display: inline-flex; align-items: center; gap: 8px; color: var(--text-soft); font-size: 12px; font-weight: 600; }
.proxy-toggle input { width: 18px; min-height: 18px; }
.proxy-policy-fields { display: flex; flex-wrap: wrap; align-items: end; gap: 14px 18px; }
.activity-edit-save-state { min-height: 20px; color: var(--muted); font-size: 12px; }
.activity-edit-save-state.error { color: var(--danger); }
.editor-panel-head { margin-bottom: 18px; }
.editor-panel-head h2 { margin: 0; font-size: 17px; }
.editor-panel-head p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.field-picker-dialog { width: min(760px, calc(100vw - 28px)); max-height: min(720px, calc(100vh - 36px)); padding: 0; border: 1px solid var(--line); border-radius: 7px; background: var(--surface); color: var(--text); box-shadow: 0 20px 60px rgb(var(--shadow-rgb) / .24); }
.field-picker-dialog::backdrop { background: rgb(var(--shadow-rgb) / .42); }
.field-picker-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 16px 18px 12px; border-bottom: 1px solid var(--line); }
.field-picker-head h2 { margin: 0; font-size: 17px; }
.field-picker-head p { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.field-picker-filters { display: flex; gap: 6px; overflow-x: auto; padding: 10px 18px 0; scrollbar-width: thin; }
.field-picker-filters button { min-height: 30px; padding: 5px 10px; border-radius: 5px; white-space: nowrap; color: var(--muted); }
.field-picker-filters button.active { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.field-picker-candidates { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; max-height: 250px; overflow-y: auto; padding: 10px 18px; }
.field-picker-candidate { min-width: 0; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-rows: auto auto; align-items: center; column-gap: 8px; padding: 8px 9px; text-align: left; }
.field-picker-candidate code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field-picker-candidate small { grid-column: 2 / 4; min-width: 0; overflow: hidden; color: var(--muted); text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.field-picker-candidate svg { width: 15px; color: var(--accent); opacity: 0; }
.field-picker-candidate.selected { border-color: var(--accent); background: var(--accent-soft); }
.field-picker-candidate.selected svg { opacity: 1; }
.candidate-source { padding: 2px 5px; border-radius: 4px; background: var(--surface-muted); color: var(--text-soft); font-size: 11px; white-space: nowrap; }
.field-picker-selected { border-top: 1px solid var(--line); padding: 10px 18px 0; }
.field-picker-subhead { display: flex; justify-content: space-between; margin-bottom: 6px; color: var(--text-soft); font-size: 12px; font-weight: 600; }
.field-picker-selected-item { min-width: 0; display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 7px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 4px; background: var(--surface); }
.field-picker-selected-item > code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field-picker-selected-index { color: var(--muted); font-size: 12px; text-align: center; }
.field-picker-selected-actions { display: flex; gap: 3px; }
.field-picker-selected-actions button { min-height: 27px; width: 27px; padding: 4px; }
.field-picker-selected-actions svg { width: 14px; height: 14px; }
.field-picker-fixed-item { min-width: 0; display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: end; gap: 7px; margin-top: 5px; padding: 6px 7px; border: 1px solid var(--line); border-radius: 4px; background: var(--surface); }
.field-picker-fixed-input { min-width: 0; display: grid; gap: 4px; }
.field-picker-fixed-input label { color: var(--muted); font-size: 11px; }
.field-picker-fixed-input input { width: 100%; min-width: 0; min-height: 32px; border: 1px solid var(--line); border-radius: 4px; padding: 6px 8px; background: var(--surface); color: var(--text); }
.field-picker-add-fixed { width: 30px; min-height: 30px; display: flex; margin: 6px auto 0; padding: 5px; color: var(--accent); }
.field-picker-limit { display: flex; align-items: center; justify-content: flex-start; gap: 6px; border-top: 1px solid var(--line); margin-top: 10px; padding: 12px 18px 5px; color: var(--text-soft); font-size: 12px; font-weight: 600; }
.field-picker-limit input { width: 7rem; min-height: 34px; border: 1px solid var(--line); border-radius: 5px; padding: 6px 9px; background: var(--surface); color: var(--text); }
.field-picker-status { min-height: 20px; padding: 5px 18px 0; color: var(--danger); font-size: 12px; }
.field-picker-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px 16px; border-top: 1px solid var(--line); }
.field-picker-actions.centered { justify-content: center; }
.header-picker-candidates { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; max-height: 420px; overflow-y: auto; padding: 14px 18px; }
.header-picker-candidate { min-width: 0; justify-content: flex-start; overflow: hidden; padding: 7px 9px; }
.header-picker-candidate code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.header-picker-candidate svg { width: 15px; color: var(--accent); opacity: 0; }
.header-picker-candidate.selected { border-color: var(--accent); background: var(--accent-soft); }
.header-picker-candidate.selected svg { opacity: 1; }
.sample-picker-dialog { width: min(900px, calc(100vw - 28px)); }
.sample-picker-empty-dialog,
.field-picker-dialog.worker-slot-dialog { width: min(436px, calc(100vw - 28px)); max-width: calc(100vw - 28px); margin: auto; }
.sample-picker-list { max-height: min(610px, calc(100vh - 180px)); overflow-y: auto; padding: 0 18px; }
.sample-preview { width: 100%; min-width: 0; display: block; padding: 13px 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; text-align: left; }
.sample-preview:hover { background: var(--surface); }
.sample-preview:last-child { border-bottom: 0; }
.sample-preview-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 12px; margin-bottom: 8px; color: var(--muted); font-size: 12px; }
.sample-preview-head code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sample-preview-head svg { width: 15px; color: var(--muted); }
.sample-preview-grid { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: 6px; }
.sample-value-line { min-width: 0; display: grid; grid-template-columns: 58px minmax(0, 1fr); gap: 8px; border: 1px solid var(--line); border-radius: 5px; padding: 7px 9px; background: var(--surface); }
.sample-value-line:not(:first-child) { grid-column: 1 / -1; }
.sample-value-line b { color: var(--muted); font-size: 11px; font-weight: 500; }
.sample-value-line code { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sample-preview.copied { background: var(--accent-soft); }
.sample-picker-status { min-height: 28px; padding: 6px 18px; color: var(--muted); font-size: 12px; text-align: right; }
.sample-picker-status.error { color: var(--danger); }
.sample-picker-empty { padding: 26px 0; text-align: center; }
.muted { color: var(--muted); }
.form-band { border-top: 1px solid var(--line); margin-top: 16px; padding-top: 16px; display: flex; justify-content: flex-end; gap: 8px; }
.form-band.centered { justify-content: center; }
.filter { display: flex; align-items: center; gap: 8px; }
.filter select { min-height: 34px; border: 1px solid var(--line); border-radius: 5px; padding: 5px 30px 5px 9px; background: var(--surface); }
.login-page { min-height: 100vh; display: grid; place-items: center; padding: 20px; background: var(--surface-muted); }
.login-box { width: min(390px, 100%); background: var(--surface); border: 1px solid var(--line); border-radius: 7px; padding: 26px; }
.login-box .brand { color: var(--text); padding: 0; margin-bottom: 24px; }
.login-box h1 { margin: 0 0 18px; font-size: 21px; }
.login-box .field { margin-bottom: 14px; }
.login-box button { width: 100%; margin-top: 4px; }
.login-error { color: var(--danger); margin: 0 0 14px; }
code { font-family: "Cascadia Mono", Consolas, monospace; font-size: 12px; }
@container task-content (max-width: 1180px) {
  .task-response-output .result-log { width: 100%; min-width: 100%; }
  .task-response-output .result-log-line { min-width: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; }
  .task-response-output .result-log-response, .task-response-output .result-log-tail { flex: 1 0 100%; min-width: 0; }
  .task-response-output .result-log-tail { overflow-wrap: anywhere; white-space: normal; }
}

/* Final desktop override: retain the shared admin sidebar and header actions. */
@media (min-width: 701px) {
}

@container activity-content (max-width: 1239px) {
  .meituan-entry-column .signature-card-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@container activity-content (max-width: 929px) {
  .meituan-entry-column .signature-card-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@container activity-content (max-width: 619px) {
  .meituan-entry-column .signature-card-list { grid-template-columns: 1fr; }
}
@media (max-width: 1499px) and (min-width: 921px) {
  .worker-card-list { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 920px) {
  .shell { width: 100%; display: block; }
  .sidebar, .content { width: 100%; min-width: 0; }
  .nav { width: 100%; min-width: 0; display: flex; overflow-x: auto; scrollbar-width: none; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { white-space: nowrap; }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-history-layout { grid-template-columns: 1fr; }
  .activity-view-sidebar { height: auto; max-height: none; min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); padding: 0 0 12px; }
  .sign-channel-toolbar-actions { flex-wrap: wrap; }
  .sign-pagination { justify-content: space-between; gap: 10px; }
  .sign-batch-bar, .worker-batch-bar, .task-date-content > .task-batch-bar { right: 12px; left: 12px; justify-content: center; transform: none; gap: 8px; padding: 7px 9px; }
  .sign-batch-bar strong, .worker-batch-bar strong, .task-date-content > .task-batch-bar strong { font-size: 12px; }
  .sign-campaign-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .signature-edit-grid, .sign-target-templates, .sign-advanced-grid, .sign-advanced-help, .signature-account-fields, .sign-account-values { grid-template-columns: 1fr; }
  .sign-fixed-headers { grid-template-columns: 1fr; }
  .sign-fixed-headers dl { grid-template-columns: 1fr; }
  .sign-inline-add, .sign-lottery-row > form:first-child, .sign-campaign-add > form, .sign-item-add, .signature-account-add form { grid-template-columns: 1fr; }
  .meituan-account-form { grid-template-columns: 1fr; }
  .cookie-check-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cookie-check-times, .cookie-check-controls { grid-template-columns: 1fr; }
  .cookie-check-controls .icon-only { justify-self: end; }

  .worker-region-content, .worker-detail-content { padding: 14px 0 0; }
  .worker-channel-frame { padding: 0; }
  .settings-content { padding: 14px 0 0; }
  .worker-card-list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-date-content { padding: 14px 0 0; }
  .task-detail-summary dl { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .task-group-workspace { grid-template-columns: 180px minmax(0, 1fr); }
  .cache-settings-row { width: 100%; max-width: none; grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1499px) and (min-width: 921px) {
  .sign-campaign-list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cache-settings-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Execution settings layout matching the shared Sign form: two columns for
   the keyword/region row, followed by the proxy/push switches. */
.sign-execution-workspace .execution-controls > .success-keyword-field {
  grid-column: 1;
  grid-row: 1;
}
.sign-execution-workspace .execution-controls > .field.compact-wide {
  grid-column: 2;
  grid-row: 1;
}
.sign-execution-workspace .execution-controls > .push-toggle-field {
  grid-column: 2;
  grid-row: 2;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle {
  grid-column: 1;
  grid-row: 2;
}
.sign-execution-workspace > .sign-section-footer {
  justify-content: center;
}
@media (max-width: 920px) {
  .sign-execution-workspace .execution-controls > .success-keyword-field,
  .sign-execution-workspace .execution-controls > .field.compact-wide,
  .sign-execution-workspace .execution-controls > .push-toggle-field,
  .sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle {
    grid-column: auto;
    grid-row: auto;
  }
}

/* Shared Sign execution toggles: proxy and push sit on one horizontal row. */
.sign-execution-workspace .execution-controls > .success-keyword-field {
  grid-column: 1 / -1;
  grid-row: 1;
}
.sign-execution-workspace .execution-controls > .push-toggle-field {
  grid-column: 2;
  grid-row: 2;
}
.sign-execution-workspace .execution-controls > .field.compact-wide {
  grid-column: 1 / -1;
  grid-row: 3;
}
.sign-execution-workspace .execution-controls > .proxy-policy {
  display: contents;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle {
  grid-column: 1;
  grid-row: 2;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 7px;
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input {
  position: relative;
  width: 34px;
  min-width: 34px;
  min-height: 18px;
  height: 18px;
  margin: 0;
  border: 0;
  border-radius: 9px;
  appearance: none;
  background: var(--line-strong);
  cursor: pointer;
  transition: background .15s ease;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--surface);
  transition: transform .15s ease;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input:checked {
  background: var(--accent);
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input:checked::after {
  transform: translateX(16px);
}

/* Message Push uses the same borderless left-switch/right-label treatment as
   Proxy.  Keep this selector independent from the legacy .push-toggle wrapper
   so no outer card frame is introduced. */
.sign-execution-workspace .execution-controls > .push-toggle-field {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 600;
}
.sign-execution-workspace .execution-controls > .push-toggle-field input {
  position: relative;
  box-sizing: border-box;
  width: 34px !important;
  min-width: 34px !important;
  height: 18px !important;
  min-height: 18px !important;
  margin: 0;
  border: 0;
  border-radius: 9px;
  appearance: none;
  background: var(--line-strong);
  cursor: pointer;
  transition: background .15s ease;
}
.sign-execution-workspace .execution-controls > .push-toggle-field input::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--surface);
  transition: transform .15s ease;
}
.sign-execution-workspace .execution-controls > .push-toggle-field input:checked {
  background: var(--accent);
}
.sign-execution-workspace .execution-controls > .push-toggle-field input:checked::after {
  transform: translateX(16px);
}

/* Paused Cookie checks and the Meituan lottery card share one treatment: paused
   is actionable (click to resume), so it stays visible even when the rest of a
   disabled card is intentionally de-emphasized. Activity cards express the same
   idea with a labeled button instead, see .activity-runtime-toggle. */
.cookie-check-toggle.paused,
.meituan-runtime-toggle.paused {
  border-color: transparent;
  background: transparent;
  color: var(--danger);
}
.cookie-check-toggle.paused:hover,
.cookie-check-toggle.paused:focus-visible,
.meituan-runtime-toggle.paused:hover,
.meituan-runtime-toggle.paused:focus-visible,
.admin-card.is-disabled .admin-card-action.meituan-runtime-toggle.paused:hover,
.admin-card.is-disabled .admin-card-action.meituan-runtime-toggle.paused:focus-visible {
  border-color: currentColor;
  background: var(--surface);
  color: var(--danger);
}
.meituan-lottery-card.is-disabled > header > form:has(.meituan-runtime-toggle.paused) {
  opacity: 1;
  filter: none;
}
.activity-card[data-store-activity-card][data-store-enabled="false"] .activity-card-identity,
.activity-card[data-store-activity-card][data-store-enabled="false"] .activity-card-actions > :not(.activity-runtime-toggle.paused),
.sign-activity-card.is-disabled .activity-card-identity,
.sign-activity-card.is-disabled .activity-card-actions > :not(.sign-runtime-toggle.paused) {
  opacity: .62;
  filter: grayscale(.7);
}
.activity-card[data-store-activity-card][data-store-enabled="false"] .activity-card-head,
.sign-activity-card.is-disabled .activity-card-head {
  opacity: 1;
  filter: none;
}

.sign-basic-workspace > .sign-section-head {
  min-height: 60px;
  padding: 14px 16px 12px;
}
.sign-basic-workspace > .sign-section-head > div:first-child { min-width: 0; }
.sign-basic-workspace > .sign-section-head h2 { margin: 0; font-size: 17px; }
.sign-basic-workspace > .sign-section-head p { max-width: 58rem; margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.5; }
.sign-basic-workspace .signature-edit-grid { grid-template-columns: minmax(260px, 1fr); }
.sign-basic-workspace > .sign-basic-content {
  grid-row: 2;
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 12px;
  padding: 8px 16px 10px;
  overflow: hidden;
  scrollbar-gutter: stable;
}
.sign-basic-workspace .sign-target-field textarea { min-height: 138px; height: 138px; max-height: 138px; overflow: auto; resize: none; }
.sign-basic-workspace .sign-target-field small { min-height: 18px; }
.sign-basic-workspace > .sign-section-footer {
  grid-row: 3;
  min-height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  border-top: 1px solid var(--surface-muted);
  padding: 10px 16px;
}
.sign-basic-workspace > .sign-section-footer.form-band { border-top: 1px solid var(--surface-muted); }
@media (max-width: 920px) {
  .sign-basic-workspace > .sign-basic-content { overflow: visible; }
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-policy-fields {
  grid-column: 1 / -1;
  grid-row: 4;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 14px 18px;
}
@media (max-width: 920px) {
  .sign-execution-workspace .execution-controls > .success-keyword-field,
  .sign-execution-workspace .execution-controls > .push-toggle-field,
  .sign-execution-workspace .execution-controls > .field.compact-wide,
  .sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle,
  .sign-execution-workspace .execution-controls > .proxy-policy > .proxy-policy-fields {
    grid-column: auto;
    grid-row: auto;
  }
}

/* Sign execution settings use the same workspace shell as lottery, store,
   and worker views while keeping the existing shared save endpoint. */
.sign-execution-workspace { gap: 0; }
.sign-execution-workspace > .sign-section-head {
  min-height: 60px;
  padding: 14px 16px 12px;
}
.sign-execution-workspace > .sign-section-head > div {
  min-width: 0;
}
.sign-execution-workspace > .sign-section-head h2 {
  margin: 0;
  font-size: 17px;
}
.sign-execution-workspace > .sign-section-head p {
  max-width: 58rem;
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}
.sign-execution-workspace > .sign-execution-content {
  grid-row: 2;
  min-height: 0;
  padding: 16px;
}
.sign-execution-workspace .execution-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 16px 20px;
}
.sign-execution-workspace .execution-controls > .success-keyword-field {
  grid-column: 1;
}
.sign-execution-workspace .execution-controls > .push-toggle-field {
  grid-column: 2;
}
.sign-execution-workspace .execution-controls > .proxy-policy {
  grid-column: 1 / -1;
}
.sign-execution-workspace .execution-controls .field input,
.sign-execution-workspace .execution-controls .field select {
  width: 100%;
  min-height: 40px;
}
.sign-execution-workspace > .sign-section-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 56px;
  padding: 10px 16px;
  border-top: 1px solid var(--surface-muted);
}
@media (max-width: 920px) {
  .sign-execution-workspace .execution-controls {
    grid-template-columns: 1fr;
  }
  .sign-execution-workspace .execution-controls > .success-keyword-field,
  .sign-execution-workspace .execution-controls > .push-toggle-field,
  .sign-execution-workspace .execution-controls > .proxy-policy {
    grid-column: auto;
  }
}
@media (max-width: 600px) {
  .content { padding: 18px 12px 32px; }
  .sign-page-actions, .sign-page-actions .button, .sign-lottery-create { width: 100%; }
  .sign-lottery-title-row { align-items: stretch; flex-direction: column; }
  .stats, .form-grid { grid-template-columns: 1fr; }
  .execution-controls { align-items: start; gap: 14px 18px; }
  .worker-selector-fields,
  .worker-selector-fields [data-worker-selector-labels] { grid-template-columns: 1fr; }
  .worker-selector-fields [data-worker-selector-labels] > label { grid-column: auto; }
  .form-grid > .full,
  .field.full { grid-column: auto; }
  .sign-campaign-list { grid-template-columns: 1fr; }
  .worker-card-list { grid-template-columns: 1fr; }
  .worker-settings-dialog { width: calc(100vw - 16px); max-width: calc(100vw - 16px); max-height: calc(100vh - 16px); border-radius: 10px; }
  .worker-settings-dialog > form { max-height: calc(100vh - 16px); }
  .worker-settings-dialog-header { padding: 18px 18px 14px; }
  .worker-settings-dialog-scroll { padding: 4px 18px 20px; }
  .worker-settings-section label { display: grid; gap: 4px; }
  .worker-settings-section label span { margin-left: 0; }
  .worker-settings-dialog-footer { padding: 13px 18px; }
  .worker-settings-dialog-footer button { flex: 1 1 0; }
  .worker-pagination { flex-wrap: wrap; row-gap: 8px; }
  .worker-pagination .sign-pagination-controls { margin-left: auto; }
  .worker-execution-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .worker-execution-stats > div { border-bottom: 1px solid var(--surface-muted); }
  .worker-execution-stats > div:nth-child(2n) { border-right: 0; }
  .worker-execution-stats > div:nth-last-child(-n+2) { border-bottom: 0; }
  .worker-detail-tabs { overflow-x: auto; scrollbar-width: thin; }
  .worker-detail-tabs a { flex: 0 0 auto; }
  .settings-grid, .settings-retention-grid { grid-template-columns: 1fr; }
  .settings-grid .settings-wide { grid-column: auto; }
  .settings-grid .field:has(#worker-release-channel),
  .settings-grid .field:has(#worker-release-manifest),
  .settings-grid .field:has(#worker-release-prefix) { grid-column: auto; grid-row: auto; }
  .task-batch-card { padding: 14px 16px; }
  .task-batch-runtime { gap: 4px; }
  .task-batch-runtime div { padding-left: 4px; }
  .task-batch-runtime dt { font-size: 10px; }
  .task-detail-heading, .task-group-detail-card > header { align-items: flex-start; flex-direction: column; }
  .task-detail-heading { width: 100%; box-sizing: border-box; }
  .task-detail-heading > span { max-width: 100%; flex-basis: auto; margin-left: 0; text-align: left; }
  .task-detail-summary dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-group-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .task-request-detail > summary { grid-template-columns: 34px 58px minmax(0, 1fr); }
  .task-request-detail > summary time { grid-column: 3; }
  .task-detail-content { height: auto; overflow: visible; }
  .task-group-workspace { flex: none; height: 70dvh; min-height: 520px; grid-template-columns: 1fr; grid-template-rows: auto minmax(0, 1fr); overflow: hidden; }
  .task-group-account-list { max-height: 92px; }
  .task-group-account-list nav { min-height: 0; max-height: none; height: auto; display: flex; overflow-x: auto; overflow-y: hidden; }
  .task-group-account-list nav .task-group-account-row { flex: 0 0 min(180px, 70vw); }
  .task-group-account-list nav .task-group-account-row > a { border-bottom: 0; border-right: 1px solid var(--surface-muted); }
  .task-group-account-list nav a.active { box-shadow: inset 0 -3px 0 var(--accent); }
  .task-group-selected > .task-group-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .preparation-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .preparation-summary > span:nth-child(2n) { border-right: 0; }
  .task-response-output { min-height: 0; max-height: none; }
  .field.compact input, .field.compact select, .field.compact-wide select { width: min(100%, 15rem); }
  .success-keyword-field { flex: 1 1 100%; width: 100%; max-width: none; }
  .cache-settings-row { grid-template-columns: 1fr; }
  .field-picker-candidates { grid-template-columns: 1fr; padding-left: 12px; padding-right: 12px; }
  .header-picker-candidates { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-left: 12px; padding-right: 12px; }
  .sample-picker-list { padding-left: 12px; padding-right: 12px; }
  .sample-preview-grid { grid-template-columns: 1fr; }
  .sample-value-line, .sample-value-line:not(:first-child) { grid-column: auto; }
  .field-picker-head, .field-picker-filters, .field-picker-selected, .field-picker-limit, .field-picker-actions { padding-left: 12px; padding-right: 12px; }
}

/* Final desktop override: retain the shared admin sidebar and header actions. */
@media (min-width: 701px) {
}

/* Keep the global admin navigation visible on the Sign editor. */
@media (min-width: 701px) {
}

/* Final desktop override: retain the shared admin sidebar and header actions. */
@media (min-width: 701px) {
}

/* Wide Sign editor: full header, centered 1760px workspace, fixed viewport. */
@media (min-width: 1101px) {
}

/* Fixed feedback stack: newest notice sits on top without changing document height. */
.toast-stack {
  position: fixed;
  z-index: 1200;
  top: 22px;
  left: 50%;
  display: grid;
  width: max-content;
  max-width: calc(100vw - 32px);
  min-height: 104px;
  transform: translateX(-50%);
  pointer-events: none;
}
.toast {
  position: relative;
  grid-area: 1 / 1;
  z-index: 1;
  align-self: start;
  justify-self: center;
  width: fit-content;
  max-width: min(620px, calc(100vw - 32px));
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 48px 14px 20px;
  border: 1px solid transparent;
  border-radius: 17px;
  box-shadow: 0 12px 28px rgb(var(--shadow-rgb) / .14);
  color: var(--accent-hover);
  font-size: 15px;
  line-height: 1.35;
  opacity: 0;
  transform: translateY(-14px) scale(.98);
  transform-origin: top center;
  transition: opacity .18s ease, transform .18s ease;
  pointer-events: none;
}
.toast-stack .toast:nth-child(1) { z-index: 3; }
.toast-stack .toast:nth-child(2) { z-index: 2; }
.toast-stack .toast:nth-child(3) { z-index: 1; }
.toast-stack .toast:nth-child(1).is-visible { opacity: 1; transform: translateY(0) scale(1); pointer-events: auto; }
.toast-stack .toast:nth-child(2).is-visible { opacity: .96; transform: translateY(22px) scale(.97); pointer-events: auto; }
.toast-stack .toast:nth-child(3).is-visible { opacity: .9; transform: translateY(43px) scale(.94); pointer-events: auto; }
.toast.toast-success { border-color: var(--accent); background: var(--surface-muted); color: var(--accent-hover); }
.toast.toast-error { border-color: var(--danger-soft); background: var(--danger-soft); color: var(--danger); }
.toast > svg { flex: 0 0 auto; width: 24px; height: 24px; stroke-width: 2.4; }
.toast-close {
  position: absolute;
  top: -13px;
  left: -13px;
  width: 28px;
  min-height: 28px;
  padding: 4px;
  border: 1px solid currentColor;
  border-radius: 50%;
  background: inherit;
  color: inherit;
  opacity: .72;
}
.toast-close:hover { opacity: 1; }
.toast-close svg { width: 16px; height: 16px; }
@media (max-width: 700px) {
  .toast-stack { top: 14px; max-width: calc(100vw - 28px); }
  .toast { width: calc(100vw - 28px); max-width: none; padding-left: 16px; font-size: 14px; }
}

/* Store editor uses the Sign workspace frame while retaining its full Store configuration. */
[data-store-activity-console] {
  width: min(100%, 1100px);
  max-width: 1100px;
  margin: 0 auto 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0;
  background: var(--surface);
  box-shadow: 0 3px 10px rgb(var(--shadow-rgb) / .05);
}
body:has([data-store-activity-console]) { overflow: auto; }
body:has([data-store-activity-console]) .content { min-width: 0; overflow: visible; }
[data-store-activity-console] .editor-panel-head { margin-bottom: 22px; }
[data-store-activity-console] .editor-panel-head h2 { font-size: 18px; }
[data-store-activity-console] .execution-controls { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: end; gap: 15px 16px; }
[data-store-activity-console] .execution-controls .field { min-width: 0; }
[data-store-activity-console] .execution-controls .field.datetime { grid-column: span 2; }
[data-store-activity-console] .execution-controls .field input,
[data-store-activity-console] .execution-controls .field select { width: 100%; min-height: 40px; }
[data-store-activity-console] .execution-controls .push-toggle input,
[data-store-activity-console] .execution-controls .cache-user-toggle input,
[data-store-activity-console] .execution-controls .proxy-toggle input {
  width: 38px;
  min-width: 38px;
  min-height: 20px;
  height: 20px;
}
[data-store-activity-console] .push-toggle input,
[data-store-activity-console] .field.compact .cache-user-toggle input,
[data-store-activity-console] .proxy-toggle input {
  position: relative;
  width: 38px;
  min-width: 38px;
  min-height: 20px;
  height: 20px;
  margin: 0;
  border: 0;
  border-radius: 10px;
  appearance: none;
  background: var(--line-strong);
  cursor: pointer;
  transition: background .15s ease;
}
[data-store-activity-console] .push-toggle input::after,
[data-store-activity-console] .field.compact .cache-user-toggle input::after,
[data-store-activity-console] .proxy-toggle input::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--surface);
  transition: transform .15s ease;
}
[data-store-activity-console] .push-toggle input:checked,
[data-store-activity-console] .field.compact .cache-user-toggle input:checked,
[data-store-activity-console] .proxy-toggle input:checked { background: var(--accent); }
[data-store-activity-console] .push-toggle input:checked::after,
[data-store-activity-console] .field.compact .cache-user-toggle input:checked::after,
[data-store-activity-console] .proxy-toggle input:checked::after { transform: translateX(18px); }
[data-store-activity-console] .proxy-toggle {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 0;
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 600;
}
[data-store-activity-console] .cache-settings-row { width: 100%; max-width: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 15px 16px; border-top: 0; }
[data-store-activity-console] .cache-settings-row:has([data-cache-setting]:not([hidden])) { grid-template-columns: repeat(5, minmax(0, 1fr)); }
[data-store-activity-console] .cache-settings-row .proxy-policy { grid-column: 1 / -1; }
[data-store-activity-console] .cache-settings-row .worker-selector-fields {
  grid-column: auto;
  width: auto;
  display: block;
  align-self: start;
}
[data-store-activity-console] .cache-settings-row .worker-selector-fields > .field { width: 100%; }
[data-store-activity-console] .proxy-policy { min-height: 0; display: grid; gap: 8px; padding-top: 6px; }
[data-store-activity-console] .proxy-policy-fields { display: grid; width: 100%; min-height: 0; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 12px 16px; }
[data-store-activity-console] .proxy-policy-fields[hidden] { display: grid !important; visibility: hidden; pointer-events: none; }
[data-store-activity-console] > .form-band { border-top: 1px solid var(--line); margin: 0 20px; padding: 16px 0 0; }
[data-store-activity-console] > .form-band.centered { width: 100%; margin: 0; align-items: center; justify-content: center; padding: 10px 0 0; }
[data-store-activity-console] > .form-band.centered .primary { min-width: 220px; min-height: 34px; }
@media (max-width: 920px) {
  [data-store-activity-console] .execution-controls,
  [data-store-activity-console] .cache-settings-row,
  [data-store-activity-console] .cache-settings-row:has([data-cache-setting]:not([hidden])) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  [data-store-activity-console] .execution-controls .field.datetime,
  [data-store-activity-console] .cache-settings-row .success-keyword-field,
  [data-store-activity-console] .cache-settings-row .store-worker-region-field { grid-column: auto; }
  [data-store-activity-console] .cache-settings-row .proxy-policy { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  [data-store-activity-console] .execution-controls,
  [data-store-activity-console] .cache-settings-row,
  [data-store-activity-console] .cache-settings-row:has([data-cache-setting]:not([hidden])),
  [data-store-activity-console] .basic-row,
  [data-store-activity-console] .store-policy-toggles,
  [data-store-activity-console] .config-picker-grid { grid-template-columns: 1fr; }
  [data-store-activity-console] .execution-controls .field.datetime,
  [data-store-activity-console] .cache-settings-row .success-keyword-field,
  [data-store-activity-console] .cache-settings-row .store-worker-region-field,
  [data-store-activity-console] .cache-settings-row .proxy-policy { grid-column: auto; }
  [data-store-activity-console] .proxy-policy-fields { grid-template-columns: 1fr; }
  [data-store-activity-console] > .form-band { margin-left: 14px; margin-right: 14px; }
}

@media (min-width: 921px) {
  body:has([data-store-activity-console]) { overflow: hidden; }
  body:has([data-store-activity-console]) .content { height: 100vh; overflow: hidden; }
  body:has([data-store-activity-console]) [data-store-activity-console] {
    height: calc(100vh - 142px);
    max-height: calc(100vh - 142px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }
}

/* Store cache controls keep the capture-only row stable. Forward-only
   controls appear in a dedicated row below it when that mode is selected. */
[data-store-activity-console] .cache-settings-row,
[data-store-activity-console] .cache-settings-row:has([data-cache-setting]:not([hidden])) {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-flow: row;
}
[data-store-activity-console] .cache-settings-row > [data-cache-setting] {
  grid-row: 2;
}
[data-store-activity-console] .cache-settings-row > .success-keyword-field {
  grid-column: 2;
  grid-row: 1;
}
[data-store-activity-console] .cache-settings-row > .worker-selector-fields {
  grid-column: 3;
  grid-row: 1;
  width: 100%;
}
[data-store-activity-console] .cache-settings-row + .forward-worker-selector {
  width: 100%;
  margin-top: 10px;
  padding-top: 0;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
[data-store-activity-console] .cache-settings-row + .forward-worker-selector[hidden] {
  display: none !important;
}
[data-store-activity-console] .cache-forward-settings {
  width: 100%;
  display: grid;
  /* Keep the three visible cache controls on the same rhythm as the row
     above: isolation, blacklist keyword, and forwarding Worker each get a
     single equal-width track. */
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: end;
  gap: 15px 16px;
  margin-top: 10px;
}
[data-store-activity-console] .cache-forward-settings[hidden] {
  display: none !important;
}
[data-store-activity-console] .cache-forward-settings > [data-cache-setting] {
  min-width: 0;
}
[data-store-activity-console] .cache-forward-settings > .forward-worker-selector {
  grid-column: 3;
  order: 2;
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 12px;
  padding-top: 0;
}
[data-store-activity-console] .cache-forward-settings > .forward-worker-selector > .field:first-child {
  grid-column: 1 / -1;
}
@media (max-width: 920px) {
  [data-store-activity-console] .cache-settings-row,
  [data-store-activity-console] .cache-settings-row:has([data-cache-setting]:not([hidden])),
  [data-store-activity-console] .cache-settings-row + .forward-worker-selector,
  [data-store-activity-console] .cache-forward-settings {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  [data-store-activity-console] .cache-settings-row > .success-keyword-field,
  [data-store-activity-console] .cache-settings-row > .worker-selector-fields {
    grid-column: auto;
    grid-row: 1;
  }
  [data-store-activity-console] .cache-settings-row > [data-cache-setting] {
    grid-row: 2;
  }
  [data-store-activity-console] .cache-forward-settings > .forward-worker-selector {
    grid-column: 1 / -1;
  }
}
@media (max-width: 600px) {
  [data-store-activity-console] .cache-settings-row,
  [data-store-activity-console] .cache-settings-row:has([data-cache-setting]:not([hidden])),
  [data-store-activity-console] .cache-settings-row + .forward-worker-selector,
  [data-store-activity-console] .cache-forward-settings {
    grid-template-columns: 1fr;
  }
  [data-store-activity-console] .cache-settings-row > .success-keyword-field,
  [data-store-activity-console] .cache-settings-row > .worker-selector-fields,
  [data-store-activity-console] .cache-settings-row > [data-cache-setting] {
    grid-column: auto;
    grid-row: auto;
  }
  [data-store-activity-console] .cache-forward-settings > .forward-worker-selector {
    grid-column: auto;
  }
}

/* Final execution row ordering after shared responsive rules. */
@media (min-width: 921px) {
  .sign-execution-workspace .execution-controls > .success-keyword-field {
    grid-column: 1;
    grid-row: 1;
  }
  .sign-execution-workspace .execution-controls > .field.compact-wide {
    grid-column: 2;
    grid-row: 1;
  }
  .sign-execution-workspace .execution-controls > .push-toggle-field {
    grid-column: 2;
    grid-row: 2;
  }
  .sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle {
    grid-column: 1;
    grid-row: 2;
  }
  .sign-execution-workspace > .sign-section-footer {
    justify-content: center;
  }
}

/* Keep the task workspace visually aligned with the rounded Sign channel frame. */
.task-history-layout .task-date-content { border-radius: 12px; }
.task-history-layout .card-pagination {
  min-height: 56px;
  margin: 0;
  border-top: 1px solid var(--surface-muted);
  border-radius: 0 0 12px 12px;
  padding: 10px 16px;
  background: var(--surface);
}
/* 任务列表页的「确定高度」已下沉到 shell.css 的填充模型（.page-wrap:has(> .surface)），
   这里不再保留 calc(100vh - 178px) 这个人肉估算。 */

.sign-campaign-card {
  position: relative;
  min-height: 340px;
  height: clamp(340px, calc((100dvh - 250px) / 2), 380px);
}
.sign-campaign-head {
  position: relative;
  height: 177px;
  min-height: 177px;
  border-bottom: 0 !important;
}
.sign-campaign-head::after {
  content: "";
  position: absolute;
  z-index: 2;
  top: 205px;
  right: 0;
  left: 0;
  border-top: 1px solid var(--surface-muted);
  pointer-events: none;
}
.sign-campaign-head > form:last-child {
  top: 7px;
  right: 8px;
  bottom: auto;
  transform: none;
}
.sign-campaign-form > .field:first-of-type {
  grid-template-columns: max-content minmax(0, 1fr);
  align-items: center;
  gap: 8px;
}
.sign-campaign-form > .field:first-of-type label {
  white-space: nowrap;
}
.sign-campaign-form .field.compact {
  transform: translateY(10px);
}
.sign-campaign-form > .field:nth-of-type(2) {
  transform: translateY(20px);
}
.sign-lottery-scroll {
  max-height: 114px;
  flex: 0 0 114px;
}
.sign-campaign-items {
  padding: 4px 8px 4px;
  justify-content: flex-end;
}
.sign-campaign-items-title {
  margin-bottom: 2px;
}
.sign-item-add {
  margin-top: 2px;
  margin-bottom: 0;
}
@media (max-width: 920px) {
}

/* Final cascade for the execution settings row. */
.sign-execution-workspace .execution-controls > .success-keyword-field {
  grid-column: 1;
  grid-row: 1;
}
.sign-execution-workspace .execution-controls > .push-toggle-field {
  grid-column: 2;
  grid-row: 2;
}
.sign-execution-workspace .execution-controls > .field.compact-wide {
  grid-column: 2;
  grid-row: 1;
}
.sign-execution-workspace .execution-controls > .proxy-policy {
  display: contents;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle {
  grid-column: 1;
  grid-row: 2;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-policy-fields {
  grid-column: 1 / -1;
  grid-row: 4;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input {
  width: 34px;
  min-width: 34px;
  min-height: 18px;
  height: 18px;
  border: 0;
  border-radius: 9px;
  appearance: none;
  background: var(--line-strong);
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--surface);
  transition: transform .15s ease;
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input:checked {
  background: var(--accent);
}
.sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle input:checked::after {
  transform: translateX(16px);
}
@media (max-width: 920px) {
  .sign-execution-workspace .execution-controls > .success-keyword-field,
  .sign-execution-workspace .execution-controls > .push-toggle-field,
  .sign-execution-workspace .execution-controls > .field.compact-wide,
  .sign-execution-workspace .execution-controls > .proxy-policy > .proxy-toggle,
  .sign-execution-workspace .execution-controls > .proxy-policy > .proxy-policy-fields {
    grid-column: auto;
    grid-row: auto;
  }
}

html[data-theme="dark"] img,
html[data-theme="dark"] video { filter: brightness(.92); }
