/* 2026-10-27（6A）任务视图：出图后整页为任务列表、对话流、当前套图三栏，取代结果弹窗。石墨玻璃风格，变量见 tokens.css。 */
body[data-task-view="open"] main > :not(#taskView) { display: none !important; }
/* 照飞象：作图页不要顶部「商品作图 / 我的作品」栏，三栏从顶部开始；手机保留顶部栏（有导航按钮） */
@media (min-width: 761px) {
  body[data-task-view="open"] .app-header { display: none; }
  body[data-task-view="open"] main { grid-row: 1 / -1; padding: 10px; }
}
.task-view[hidden] { display: none !important; }
/* 照飞象：左栏 232px；右栏「任务图片 / 收藏夹」宽屏常驻（296px），关掉后右上角留「收藏夹」按钮 */
.task-view {
  position: relative;
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 6px;
}
.task-view.is-list-collapsed { grid-template-columns: 76px minmax(0, 1fr); }
.task-view.is-set-open:not(.is-set-empty) { grid-template-columns: 232px minmax(0, 1fr) 296px; }
.task-view.is-list-collapsed.is-set-open:not(.is-set-empty) { grid-template-columns: 76px minmax(0, 1fr) 296px; }
.task-view:not(.is-set-open) .tv-set, .task-view.is-set-empty .tv-set { display: none; }

.task-view { --tv-line: #e3e5ea; --tv-card: rgb(255 255 255 / 62%); --tv-chip: rgb(16 18 23 / 6%); --tv-chip-hover: rgb(16 18 23 / 10%); }
.tv-list, .tv-set {
  background: var(--color-glass);
  -webkit-backdrop-filter: var(--blur-glass);
  backdrop-filter: var(--blur-glass);
  border: 1px solid var(--color-glass-border);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-panel);
}

/* ---------- 左栏：任务列表 ---------- */
.tv-list { min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
/* 左栏顶部照飞象：图标在上、文字在下的小按钮，新建在左、收起在右 */
.tv-list-head { display: flex; gap: 14px; align-items: center; padding: 16px 18px 14px; border-bottom: 1px solid rgb(16 18 23 / 7%); }
.tv-head-btn {
  display: inline-flex; flex-direction: column; align-items: center; gap: 4px; min-width: 40px; padding: 4px 2px; border: 0; border-radius: 8px;
  background: none; color: var(--color-text); font: inherit; font-size: 12px; font-weight: 500; line-height: 1.2; white-space: nowrap; cursor: pointer;
}
.tv-head-btn:hover { background: var(--tv-chip); }
.tv-head-btn .tv-icon { width: 18px; height: 18px; }
.tv-list-head .tv-collapse { margin-left: auto; }
.tv-tasks { flex: 1; min-height: 0; overflow-x: hidden; overflow-y: auto; padding: 6px 8px 12px; }
.tv-group h3 { margin: 12px 8px 6px; font-size: 13px; font-weight: 600; color: var(--color-text-muted); }
/* minmax(0, 1fr): a long title ends in … instead of widening the list. */
.tv-group ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px; }
.tv-task {
  display: flex; align-items: center; gap: 10px; width: 100%; min-height: 60px; padding: 8px;
  border: 1px solid transparent; border-radius: var(--radius-control); background: transparent;
  color: var(--color-text); text-align: left; cursor: pointer; font: inherit;
}
.tv-task:hover { background: rgb(16 18 23 / 5%); }
.tv-task.is-active { background: var(--color-surface); border-color: var(--color-border); box-shadow: 0 1px 2px rgb(16 18 23 / 6%); }
.tv-task:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 2px; }
.tv-task-thumb { flex: none; width: 44px; height: 44px; border-radius: 8px; overflow: hidden; background: var(--color-surface-muted); }
.tv-task-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tv-task-text { flex: 1; display: flex; flex-direction: column; min-width: 0; gap: 1px; line-height: 1.35; }
.tv-task-text strong { font-size: 14px; font-weight: 600; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tv-task-meta, .tv-task-state { font-size: 12px; color: var(--color-text-muted); }
.tv-task-state.is-busy { color: var(--color-text-secondary); }
.tv-task-state.is-warn { color: var(--color-text); font-weight: 600; }
.tv-empty { margin: 16px 8px; color: var(--color-text-muted); font-size: var(--font-size-caption); }
.tv-tasks > .primary { margin: 0 8px; }
.tv-drafts { margin: 0 14px 14px; align-self: flex-start; font-size: var(--font-size-caption); }
.is-list-collapsed .tv-list-head { flex-direction: column; gap: 10px; padding: 16px 8px; border-bottom: 0; }
.is-list-collapsed .tv-list-head .tv-collapse { margin-left: 0; }
.is-list-collapsed .tv-tasks, .is-list-collapsed .tv-drafts { display: none; }

/* ---------- 中间：对话流 ---------- */
.tv-flow { min-width: 0; min-height: 0; overflow: auto; display: flex; flex-direction: column; gap: 18px; padding: 2px 2px 16px; }
/* 卡片保持自身高度，由对话流滚动；否则结果卡会被压到一屏高、超出部分被裁掉 */
.tv-flow > * { flex: none; }
/* 照飞象：对话流内容最宽 980px，居中 */
.tv-flow > :not(.tv-bar):not(.tv-composer) { width: 100%; max-width: 980px; margin-inline: auto; box-sizing: border-box; }
.tv-bar { display: none; }
/* 右上角「收藏夹」按钮，照飞象「成品库」 */
@media (min-width: 761px) {
  .tv-bar { position: absolute; top: 0; right: 0; z-index: 6; display: flex; }
  .tv-bar [data-task-list-toggle], .is-set-open .tv-bar, .is-set-empty .tv-bar { display: none; }
  .task-view:not(.is-set-open):not(.is-set-empty) .tv-summary { padding-right: 140px; }
}
.tv-set-trigger {
  display: inline-flex; align-items: center; gap: 4px; height: 34px; padding: 5px 18px; border: 0; border-radius: 10px;
  background: var(--tv-trigger, var(--color-border)); color: var(--color-text); font: inherit; font-size: 12px; font-weight: 500; line-height: 24px; white-space: nowrap; cursor: pointer;
}
.tv-set-trigger:hover { background: var(--tv-trigger-hover, var(--color-border-strong)); }
.tv-set-trigger .tv-icon { width: 16px; height: 16px; margin-right: 3px; }
/* 制作请求：照飞象的用户消息，封面小图加名称和一行设置，不套卡片 */
.tv-summary { display: flex; align-items: center; gap: 12px; padding: 2px; }
.tv-summary-thumb { flex: none; width: 52px; height: 52px; border-radius: 12px; overflow: hidden; background: var(--color-surface); border: 1px solid var(--tv-line); }
.tv-summary-thumb:empty { display: none; }
.tv-summary-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tv-summary-text { flex: 1; min-width: 0; }
.tv-summary-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.tv-summary h2 { margin: 0; font-size: 14px; font-weight: 600; line-height: 1.4; overflow-wrap: anywhere; }
.tv-summary-time { flex: none; font-size: 12px; color: var(--color-text-muted); }
.tv-chips { list-style: none; display: flex; flex-wrap: wrap; align-items: center; row-gap: 2px; margin: 4px 0 0; padding: 0; }
.tv-chips li { font-size: 12px; line-height: 1.5; color: var(--color-text-muted); }
.tv-chips li + li::before { content: ""; display: inline-block; width: 1px; height: 10px; margin: 0 8px; background: rgb(16 18 23 / 16%); vertical-align: -1px; }
/* 结果卡：照飞象，细边框大圆角，标题小、操作在卡片底部 */
.tv-result {
  display: flex; flex-direction: column; gap: 14px; padding: 20px 14px 14px;
  border: 1px solid var(--tv-line); border-radius: 20px; background: var(--tv-card);
  -webkit-backdrop-filter: var(--blur-glass); backdrop-filter: var(--blur-glass);
}
.tv-result .image-results-header { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 8px 16px; padding: 0 2px; border: 0; background: none; }
.tv-result .image-results-heading { flex: 1 1 220px; min-width: 0; display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 10px; }
.tv-result .image-results-header h2 { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-size: 14px; font-weight: 600; }
.tv-result .image-results-header h2 .tv-icon { width: 16px; height: 16px; }
.tv-result .image-results-header p { margin: 0; font-size: 12px; color: var(--color-text-muted); }
.tv-result .image-results-tabs { display: inline-flex; gap: 2px; padding: 2px; border: 0; border-radius: 10px; background: var(--tv-chip); }
.tv-result .image-results-tab { min-height: 28px; margin: 0; padding: 0 12px; border: 0; border-radius: 8px; font-size: 12px; font-weight: 500; color: var(--color-text-secondary); }
.tv-result .image-results-tab.is-active { background: var(--color-surface); color: var(--color-text); font-weight: 600; box-shadow: 0 1px 2px rgb(16 18 23 / 8%); }
.tv-card-progress { padding: 0 2px; }
.tv-card-progress .image-results-step { margin-top: 6px; font-size: 12px; }
/* 2026-10-28 生图进度（照飞象，图片下方）：已出的小图叠放、正在画哪几张、进度条和百分比、已出几张、还要多久、已用多久 */
.tv-gen { display: flex; align-items: center; gap: 14px; margin-top: 12px; padding: 12px 14px; border: 1px solid var(--color-border); border-radius: 14px; background: var(--color-surface); }
.tv-gen-thumbs { position: relative; flex: none; width: calc(52px + (var(--n, 1) - 1) * 16px); height: 56px; }
.tv-gen-thumb {
  position: absolute; left: calc(var(--i, 0) * 16px); top: 2px; z-index: calc(5 - var(--i, 0)); width: 52px; height: 52px; padding: 0; overflow: hidden;
  border: 2px solid var(--color-surface); border-radius: 10px; background: var(--color-surface-muted); cursor: zoom-in;
  transform: rotate(calc(-6deg + var(--i, 0) * 6deg));
}
.tv-gen-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; animation: tv-pop .5s cubic-bezier(.2, .9, .3, 1.2); }
.tv-gen-thumb.is-empty { cursor: default; transform: rotate(-4deg); }
.tv-gen-main { flex: 1; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 7px; }
.tv-gen-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.tv-gen-head strong { min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; font-size: 13px; font-weight: 600; }
.tv-gen-percent { flex: none; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--color-text-secondary); }
.tv-gen-bar { position: relative; height: 4px; overflow: hidden; border-radius: 4px; background: rgb(var(--ink) / 10%); }
.tv-gen-bar span { position: absolute; inset: 0 auto 0 0; border-radius: inherit; background: var(--color-primary); transition: width 1s linear; overflow: hidden; }
.tv-gen-bar span::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, rgb(255 255 255 / 45%), transparent); transform: translateX(-100%); animation: tv-bar-sheen 1.8s ease-in-out infinite; }
.tv-gen-meta { display: flex; flex-wrap: wrap; gap: 2px 14px; font-size: 12px; color: var(--color-text-muted); font-variant-numeric: tabular-nums; }
.tv-gen-meta .image-results-step { margin: 0; font-size: 12px; color: var(--color-text-muted); }
.tv-result .image-results-body { padding: 0; max-height: none; overflow: visible; }
.tv-steps { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 16px; padding: 0; }
.tv-steps li { padding: 4px 12px; border-radius: 999px; background: var(--color-surface-muted); color: var(--color-text-muted); font-size: 13px; }
.tv-steps li.is-complete { color: var(--color-text-secondary); }
.tv-steps li.is-current { background: var(--color-primary); color: var(--color-on-primary); }
.tv-empty-state { padding: 48px 24px; text-align: center; }
.tv-empty-state h2 { margin: 0 0 8px; font-size: var(--font-size-section); }
.tv-empty-state p { margin: 0 0 20px; color: var(--color-text-muted); }

/* A+ 模块按页面顺序竖排，图宽撑满，方便看整页 */
.image-result-grid.is-detail { grid-template-columns: minmax(0, 760px); justify-content: center; }
.image-result-grid.is-detail .image-result-picture { height: auto; min-height: 200px; }
.image-result-grid.is-detail .image-result-picture img { width: 100%; height: auto; object-fit: contain; }

/* ---------- 2026-10-28 右栏：照飞象「会话资产 / 成品库」，名字为「任务图片 / 收藏夹」；4 列小图，悬停出圆圈，底部固定操作 ---------- */
.tv-set { position: relative; min-height: 0; display: flex; flex-direction: column; overflow: hidden; padding: 14px 0 0; }
.tv-set.is-drop { outline: 2px dashed var(--color-primary); outline-offset: -6px; }
.tv-set-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 0 14px 12px; }
.tv-side-tabs { display: flex; gap: 4px; }
.tv-side-tab { height: 32px; padding: 0 14px; border: 0; border-radius: 10px; background: none; color: var(--color-text-muted); font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; }
.tv-side-tab:hover { color: var(--color-text); }
.tv-side-tab.is-active { background: var(--tv-chip); color: var(--color-text); }
.tv-set-close { display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 8px; background: none; color: var(--color-text-secondary); cursor: pointer; }
.tv-set-close:hover { background: var(--tv-chip); color: var(--color-text); }
.tv-set-close .tv-icon { width: 16px; height: 16px; }
.tv-side-body { flex: 1; min-height: 0; overflow: auto; padding: 0 14px 12px; }
.tv-side-count { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 2px 0 8px; font-size: 12px; color: var(--color-text-muted); }
.tv-side-count .textbtn { min-height: 24px; padding: 0 10px; font-size: 12px; }
.tv-side-empty { margin: 18px 4px; font-size: 12px; line-height: 1.7; color: var(--color-text-muted); text-align: center; }
.tv-side-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.tv-side-tile { position: relative; aspect-ratio: 1; overflow: hidden; border-radius: 6px; background: var(--color-surface-muted); }
.tv-side-tile.is-picked { box-shadow: 0 0 0 2px var(--color-primary) inset; }
.tv-side-image { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; }
.tv-side-image img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tv-side-tile.is-picked .tv-side-image img { opacity: .82; }
.tv-side-check {
  position: absolute; right: 4px; top: 4px; display: grid; place-items: center; width: 16px; height: 16px; padding: 0;
  border: 1px solid #fff; border-radius: 50%; background: rgb(0 0 0 / 25%); color: #fff; cursor: pointer; opacity: 0; transition: opacity .12s ease;
}
.tv-side-check .tv-icon { width: 11px; height: 11px; stroke-width: 2.4; opacity: 0; }
.tv-side-check[aria-checked="true"] { background: var(--color-primary); border-color: var(--color-primary); }
.tv-side-check[aria-checked="true"] .tv-icon { opacity: 1; }
.tv-side-tile:hover .tv-side-check, .tv-side-tile:focus-within .tv-side-check, .tv-side-grid.is-picking .tv-side-check { opacity: 1; }
.tv-side-tag { position: absolute; left: 3px; bottom: 3px; padding: 0 4px; border-radius: 4px; background: rgb(0 0 0 / 60%); color: #fff; font-size: 10px; line-height: 16px; pointer-events: none; }
.tv-side-foot { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 12px 14px 14px; border-top: 1px solid var(--color-border); }
.tv-side-foot.is-three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
/* 任务图片的五个按钮：上排三个、下排两个 */
.tv-side-foot.is-five { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.tv-side-foot.is-five > .tv-side-btn { grid-column: span 2; }
.tv-side-foot.is-five > .tv-side-btn:nth-of-type(n+4) { grid-column: span 3; }
.tv-side-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 4px; height: 34px; padding: 0 8px; border: 0; border-radius: 10px;
  background: var(--tv-chip); color: var(--color-text); font: inherit; font-size: 12px; font-weight: 500; text-decoration: none; white-space: nowrap; cursor: pointer;
}
.tv-side-btn:hover:not(:disabled) { background: var(--tv-chip-hover); }
.tv-side-btn:disabled { opacity: .4; cursor: not-allowed; }
.tv-side-btn .tv-icon { width: 15px; height: 15px; }
/* 收藏：底部弹出收藏夹列表，可搜索、可新建 */
.tv-fav-menu {
  position: absolute; left: 14px; right: 14px; bottom: calc(100% - 4px); z-index: 4; display: grid; gap: 6px; padding: 8px;
  border: 1px solid var(--color-border); border-radius: 12px; background: var(--color-surface); box-shadow: var(--shadow-floating);
}
.tv-fav-menu input { width: 100%; height: 32px; font-size: 13px; }
.tv-fav-list { display: grid; max-height: 200px; overflow: auto; }
.tv-fav-list button, .tv-fav-new { display: flex; align-items: center; justify-content: space-between; gap: 8px; height: 34px; padding: 0 8px; border: 0; border-radius: 8px; background: none; color: var(--color-text); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.tv-fav-list button span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tv-fav-list em, .tv-fav-group h3 em { font-style: normal; font-size: 12px; color: var(--color-text-muted); }
.tv-fav-list button:hover, .tv-fav-new:hover { background: var(--tv-chip); }
.tv-fav-new { justify-content: flex-start; border-top: 1px solid var(--color-border); border-radius: 0 0 8px 8px; color: var(--color-text-secondary); }
.tv-fav-new .tv-icon { width: 16px; height: 16px; }
/* 收藏夹：选库 + 新建、筛选、统计、按库分组 */
.tv-fav-bar { display: flex; gap: 6px; margin-bottom: 8px; }
.tv-fav-bar select { flex: 1; min-width: 0; }
.tv-set select { height: 32px; min-height: 32px; padding-top: 0; padding-bottom: 0; font-size: 12px; }
.tv-side-new { display: inline-flex; align-items: center; gap: 3px; height: 32px; padding: 0 10px; border: 0; border-radius: 10px; background: var(--tv-chip); color: var(--color-text); font: inherit; font-size: 12px; cursor: pointer; white-space: nowrap; }
.tv-side-new:hover { background: var(--tv-chip-hover); }
.tv-side-new .tv-icon { width: 15px; height: 15px; }
.tv-fav-manage { display: flex; gap: 14px; margin: -2px 2px 8px; }
.tv-fav-manage .textbtn, .tv-fav-filters .textbtn { min-height: 24px; padding: 0 10px; font-size: 12px; }
.tv-fav-filters { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 6px; margin-bottom: 8px; }
.tv-fav-filters .textbtn { grid-column: 1 / -1; justify-self: end; }
.tv-fav-group + .tv-fav-group { margin-top: 14px; }
.tv-fav-group h3 { display: flex; align-items: baseline; gap: 6px; margin: 0 0 6px; font-size: 13px; font-weight: 600; }
.tv-fav-group h3 span { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tv-fav-group .tv-side-empty { margin: 6px 0 4px; padding: 14px 8px; border: 1px dashed var(--color-border); border-radius: 10px; }
.tv-ask input { width: 100%; margin-bottom: 16px; }
/* 左栏每个任务右侧的「⋮」：重命名、删除 */
.tv-task-row { position: relative; }
.tv-task-row .tv-task { padding-right: 34px; }
.tv-task-more {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%); display: grid; place-items: center; width: 26px; height: 26px; padding: 0;
  border: 0; border-radius: 8px; background: none; color: var(--color-text-secondary); cursor: pointer; opacity: 0;
}
.tv-task-more .tv-icon { width: 18px; height: 18px; stroke-width: 3; }
.tv-task-row:hover .tv-task-more, .tv-task-more:focus-visible, .tv-task-row.is-menu-open .tv-task-more { opacity: 1; }
.tv-task-more:hover, .tv-task-row.is-menu-open .tv-task-more { background: var(--tv-chip-hover); color: var(--color-text); }
.tv-task-menu {
  position: absolute; right: 6px; top: calc(50% + 16px); z-index: 5; display: grid; min-width: 112px; padding: 4px;
  border: 1px solid var(--color-border); border-radius: 10px; background: var(--color-surface); box-shadow: var(--shadow-floating);
}
.tv-task-menu button { height: 32px; padding: 0 10px; border: 0; border-radius: 6px; background: none; color: var(--color-text); font: inherit; font-size: 13px; text-align: left; cursor: pointer; }
.tv-task-menu button:hover { background: var(--tv-chip); }
.tv-task-menu .is-danger { color: var(--color-required); }
.is-list-collapsed .tv-task-more, .is-list-collapsed .tv-task-menu { display: none; }
@media (hover: none) { .tv-task-more, .tv-side-check { opacity: 1; } }

.tv-scrim { display: none; }

/* ---------- 手机宽度：左栏、右栏改为抽屉 ---------- */
@media (max-width: 760px) {
  .task-view, .task-view.is-list-collapsed, .task-view.is-set-open:not(.is-set-empty), .task-view.is-list-collapsed.is-set-open:not(.is-set-empty) {
    height: auto; grid-template-columns: minmax(0, 1fr); gap: 12px;
  }
  .task-view:not(.is-set-open) .tv-set { display: flex; }
  .tv-flow { overflow: visible; gap: 12px; }
  .tv-bar { display: flex; gap: 8px; }
  .tv-bar button { flex: 1; min-height: 40px; }
  .tv-collapse { display: none; }
  .tv-list, .tv-set {
    position: fixed; z-index: 95; visibility: hidden; border-radius: 0;
    transition: transform .18s ease, visibility .18s;
  }
  .tv-list { inset: 0 auto 0 0; width: min(300px, 86vw); transform: translateX(-102%); border-radius: 0 20px 20px 0; }
  .tv-set { left: 0; right: 0; bottom: 0; max-height: 72dvh; transform: translateY(102%); border-radius: 20px 20px 0 0; }
  .is-list-open .tv-list, .is-set-open .tv-set { visibility: visible; transform: none; }
  .is-list-collapsed .tv-tasks, .is-list-collapsed .tv-drafts { display: block; }
  .is-list-collapsed .tv-list-head { flex-direction: row; }
  .is-set-empty .tv-set { display: none; }
  .tv-scrim:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 90; border: 0; background: rgb(0 0 0 / 60%); }
}
/* ---------- 中等宽度（笔记本、平板横屏）：三栏放不下，右栏打开时浮在右侧 ---------- */
@media (min-width: 761px) and (max-width: 1365px) {
  .task-view.is-set-open:not(.is-set-empty) { grid-template-columns: 232px minmax(0, 1fr); }
  .task-view.is-list-collapsed.is-set-open:not(.is-set-empty) { grid-template-columns: 76px minmax(0, 1fr); }
  .tv-set {
    position: fixed; z-index: 95; top: 10px; right: 10px; bottom: 10px; width: min(296px, 86vw);
    visibility: hidden; transform: translateX(110%); transition: transform .18s ease, visibility .18s;
  }
  .task-view:not(.is-set-open) .tv-set { display: flex; }
  .is-set-open .tv-set { visibility: visible; transform: none; }
  .tv-scrim:not([hidden]) { display: block; position: fixed; inset: 0; z-index: 90; border: 0; background: rgb(0 0 0 / 50%); }
}
@media (prefers-reduced-motion: reduce) { .tv-list, .tv-set { transition: none; } }
.task-view a.primary, .task-view a.secondary { text-decoration: none; }
/* ---------- 2026-10-27（6B）结果图：照飞象，图片紧排（间距 4px、无圆角），图上方是带弧形肩的小页签，悬停出深色半透明工具 ---------- */
.tv-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(200px, 100%), 1fr)); gap: 4px; }
.tv-tiles.is-detail { grid-template-columns: repeat(auto-fill, minmax(min(240px, 100%), 1fr)); }
.tv-tiles.is-reference { grid-template-columns: repeat(auto-fill, minmax(min(380px, 100%), 1fr)); }
.tv-tile { min-width: 0; display: flex; flex-direction: column; align-items: flex-start; }
.tv-tile-label {
  position: relative; display: inline-flex; align-items: center; min-height: 24px; max-width: calc(100% - 40px);
  padding: 4px 2px 4px 9px; border-radius: 10px 0 0 0; background: var(--tv-line);
  font-size: 12px; line-height: 16px; color: rgb(17 19 24 / 58%);
}
/* 2026-10-29 用户：名字不能截断——放不下时换到第二行，弧形肩跟着贴在页签底部 */
.tv-tile-label > span { overflow-wrap: anywhere; }
.tv-tile-label::after {
  content: ""; position: absolute; left: 100%; bottom: 0; width: 40px; height: 24px; background: var(--tv-line);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='52 0 40 23' preserveAspectRatio='none'%3E%3Cpath d='M52.2 0C57.9 0 63.3 2.1 67.12 6.35c1.46 1.62 3.24 3.65 5.38 6.15C81.5 23 92 23 92 23H52V0Z'/%3E%3C/svg%3E") no-repeat 0 0 / 100% 100%;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='52 0 40 23' preserveAspectRatio='none'%3E%3Cpath d='M52.2 0C57.9 0 63.3 2.1 67.12 6.35c1.46 1.62 3.24 3.65 5.38 6.15C81.5 23 92 23 92 23H52V0Z'/%3E%3C/svg%3E") no-repeat 0 0 / 100% 100%;
}
.tv-tile-compare { width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 4px; }
.tv-tile-reference { position: relative; margin: 0; aspect-ratio: var(--ratio, 1 / 1); overflow: hidden; background: #eceef1; }
.tv-tile-reference img { display: block; width: 100%; height: 100%; object-fit: cover; }
.tv-tile-reference figcaption, .tv-tile-view {
  position: absolute; left: 10px; top: 10px; z-index: 2; display: inline-flex; align-items: center; height: 26px; padding: 0 7px;
  border: 1px solid rgb(255 255 255 / 20%); border-radius: 8px; background: rgb(0 0 0 / 60%);
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); color: #fff; font-size: 12px; line-height: 1;
}
.tv-tile-picture { position: relative; width: 100%; aspect-ratio: var(--ratio, 1 / 1); overflow: hidden; background: #eceef1; }
/* 第几版和比例：图片左下角的小牌；悬停或选中时底部出工具，小牌让开 */
.tv-tile-meta {
  position: absolute; left: 8px; bottom: 8px; z-index: 2; display: inline-flex; align-items: center; height: 22px; padding: 0 7px;
  border-radius: 7px; background: rgb(0 0 0 / 55%); color: #fff; font-size: 11px; line-height: 1; white-space: nowrap; pointer-events: none;
  font-variant-numeric: tabular-nums; transition: opacity .15s ease;
}
.tv-tile-picture:hover .tv-tile-meta, .tv-tile-picture:focus-within .tv-tile-meta, .tv-tile.is-selected .tv-tile-meta { opacity: 0; }
@media (hover: none) { .tv-tile-picture:focus-within .tv-tile-meta { opacity: 1; } }
/* 悬停时顶部压一层渐暗，白色按钮在浅色图上也看得清 */
.tv-tile-picture::before {
  content: ""; position: absolute; inset: 0 0 auto; z-index: 1; height: 88px; pointer-events: none;
  background: linear-gradient(rgb(0 0 0 / 40%), rgb(0 0 0 / 0)); opacity: 0; transition: opacity .15s ease;
}
.tv-tile-picture::after { content: ""; position: absolute; inset: 0; z-index: 3; border: 2px solid transparent; pointer-events: none; }
.tv-tile-picture:hover::before, .tv-tile-picture:focus-within::before, .tv-tile.is-selected .tv-tile-picture::before { opacity: 1; }
.tv-tile.is-selected .tv-tile-picture::after { border-color: var(--color-primary); }
.tv-tile-image { display: block; width: 100%; height: 100%; padding: 0; border: 0; border-radius: 0; background: none; cursor: zoom-in; }
.is-selecting .tv-tile-image { cursor: pointer; }
.tv-tile-image img, .tv-tile-old { display: block; width: 100%; height: 100%; object-fit: cover; }
.tv-tile-image:focus-visible { outline: 2px solid var(--color-focus); outline-offset: -2px; }
.tv-tile-old { opacity: .4; filter: grayscale(.4); }
.tv-tile-state { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px; padding: 16px; text-align: center; font-size: 13px; color: var(--color-text-muted); }
.tv-tile-state .image-error { margin: 0; font-size: 12px; }
/* 2026-10-29 正在生成的格子（照飞象）：一块干净的底色，一道柔光从左到右慢慢扫过；不放文字，进度在图片下方 */
.tv-tile-picture.is-busy { background: var(--color-surface-muted); }
.tv-tile-state.is-busy { overflow: hidden; }
.tv-tile-shimmer {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(100deg, rgb(var(--ink) / 3%) 30%, rgb(var(--ink) / 11%) 50%, rgb(var(--ink) / 3%) 70%);
  background-size: 220% 100%; animation: tv-shimmer 1.8s cubic-bezier(.4, 0, .6, 1) infinite;
}
.tv-tile-state.is-queued .tv-tile-shimmer { opacity: .5; animation-duration: 2.6s; }
.tv-tile-picture.is-redrawing .tv-tile-shimmer { z-index: 1; }
@keyframes tv-shimmer { from { background-position: 160% 0; } to { background-position: -60% 0; } }
@keyframes tv-pop { from { opacity: 0; transform: scale(.6); } }
@keyframes tv-bar-sheen { to { transform: translateX(100%); } }
@media (prefers-reduced-motion: reduce) {
  .tv-tile-shimmer, .tv-gen-thumb img, .tv-gen-bar span::after { animation: none; }
  .tv-gen-bar span { transition: none; }
}
.tv-tile-badge {
  position: absolute; left: 10px; bottom: 10px; z-index: 2; width: fit-content; max-width: calc(100% - 20px); padding: 5px 9px;
  border: 1px solid rgb(255 255 255 / 20%); border-radius: 8px; background: rgb(0 0 0 / 60%);
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px); font-size: 12px; line-height: 1.45; color: #fff;
}
.tv-tile-view, .tv-tile-check, .tv-tile-tools { opacity: 0; transition: opacity .12s ease; }
.tv-tile-picture:hover > .tv-tile-view, .tv-tile-picture:hover > .tv-tile-check, .tv-tile-picture:hover > .tv-tile-tools,
.tv-tile-picture:focus-within > .tv-tile-view, .tv-tile-picture:focus-within > .tv-tile-check, .tv-tile-picture:focus-within > .tv-tile-tools,
.is-selecting .tv-tile-check, .tv-tile.is-selected .tv-tile-check { opacity: 1; }
.tv-tile-view { cursor: pointer; }
.tv-tile-check {
  position: absolute; right: 10px; top: 10px; z-index: 2; display: grid; place-items: center; width: 20px; height: 20px; padding: 0;
  border: 1px solid #fff; border-radius: 50%; background: rgb(0 0 0 / 20%); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  color: #fff; cursor: pointer;
}
.tv-tile-check .tv-icon { width: 14px; height: 14px; stroke-width: 2.2; opacity: 0; }
.tv-tile-check[aria-checked="true"] { background: var(--color-primary); }
.tv-tile-check[aria-checked="true"] .tv-icon { opacity: 1; }
.tv-tile-tools {
  position: absolute; left: 50%; bottom: 10px; z-index: 2; transform: translateX(-50%); display: flex; gap: 8px; padding: 5px 8px;
  border: 1px solid rgb(255 255 255 / 20%); border-radius: 8px; background: rgb(0 0 0 / 60%);
  -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
}
.tv-tile-tool {
  position: relative; display: grid; place-items: center; width: 24px; height: 24px; padding: 0; border: 0; border-radius: 6px;
  background: none; color: #fff; cursor: pointer; transition: background .2s ease;
}
.tv-tile-tool:hover:not(:disabled), .tv-tile-tool:focus-visible { background: rgb(255 255 255 / 16%); }
.tv-tile-tool:disabled { opacity: .45; cursor: default; }
.tv-tile-tool .tv-icon { width: 16px; height: 16px; }
.tv-tip {
  position: absolute; left: 50%; bottom: calc(100% + 9px); transform: translateX(-50%); padding: 4px 8px; border-radius: 6px;
  background: #111318; color: #fff; font-size: 12px; line-height: 1.4; white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .12s ease;
}
.tv-tile-tool:hover .tv-tip, .tv-tile-tool:focus-visible .tv-tip { opacity: 1; }
.tv-tile-tools.is-edit { padding: 0; }
.tv-tile-edit { height: 32px; padding: 0 14px; border: 0; background: none; color: #fff; font-size: 12px; cursor: pointer; }
.tv-icon { display: block; flex: none; width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
/* 触屏没有悬停：圆圈和查看常显，其余工具在查看大图里 */
@media (hover: none) {
  .tv-tile-view, .tv-tile-check { opacity: 1; }
  .tv-tile-tools { display: none; }
}
@media (prefers-reduced-motion: reduce) { .tv-tile-view, .tv-tile-check, .tv-tile-tools, .tv-tile-picture::before, .tv-tip { transition: none; } }
/* 选中后卡片右上：已选数量、全选、取消 */
.tv-select-bar { display: flex; align-items: center; gap: 10px; }
.tv-select-count { font-size: 12px; color: rgb(17 19 24 / 60%); white-space: nowrap; }
.tv-select-all, .tv-select-cancel { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px; border: 0; border-radius: 8px; font-size: 12px; font-weight: 500; color: var(--color-text); white-space: nowrap; cursor: pointer; }
.tv-select-all { background: var(--tv-chip); }
.tv-select-all:hover { background: var(--tv-chip-hover); }
.tv-select-cancel { background: none; padding: 0 8px; }
.tv-select-cancel:hover { background: var(--tv-chip); }
.tv-dot { display: grid; place-items: center; width: 14px; height: 14px; border: 1px solid rgb(17 19 24 / 35%); border-radius: 50%; color: #fff; }
.tv-dot .tv-icon { width: 10px; height: 10px; stroke-width: 2.4; opacity: 0; }
.tv-select-all.is-on .tv-dot { border-color: var(--color-primary); background: var(--color-primary); }
.tv-select-all.is-on .tv-dot .tv-icon { opacity: 1; }
/* 卡片底部整组操作：浅灰小按钮，批量操作用黑色 */
.tv-card-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 8px; }
.tv-foot-btn, .tv-card-foot .image-language-switch select {
  display: inline-flex; align-items: center; gap: 4px; height: 30px; min-height: 30px; padding: 0 10px; border: 0; border-radius: 8px;
  background: var(--tv-chip); color: var(--color-text); font: inherit; font-size: 12px; font-weight: 500; line-height: 1; text-decoration: none; white-space: nowrap; cursor: pointer; list-style: none;
}
.tv-foot-btn:hover:not(:disabled) { background: var(--tv-chip-hover); }
.tv-foot-btn:disabled { color: var(--color-text-muted); cursor: default; }
.tv-foot-btn .tv-icon { width: 14px; height: 14px; }
.tv-foot-btn::-webkit-details-marker { display: none; }
.tv-foot-btn.is-primary { background: var(--color-primary); color: var(--color-on-primary); }
.tv-foot-btn.is-primary:hover { background: var(--color-primary-hover); }
.tv-card-foot .image-language-switch { gap: 0; font-size: 0; }
.tv-card-foot .image-language-switch span { font-size: 12px; color: var(--color-text-muted); margin-right: 6px; }
.tv-card-foot .image-language-switch select { padding-right: 26px; box-shadow: none; }
.tv-card-foot .image-language-switch .select-control { width: auto; min-height: 30px; height: 30px; padding: 0 10px; gap: 8px; border: 0; border-radius: 8px;
  background: var(--tv-chip); font-size: 12px; font-weight: 500; box-shadow: none; }
.tv-card-foot .image-language-switch .select-control:hover:not(:disabled) { background: var(--tv-chip-hover); }
.tv-card-foot .image-language-switch .select-arrow { width: 6px; height: 6px; }
.tv-batch { position: relative; margin: 0; padding: 0; }
.tv-batch-menu {
  position: absolute; left: 0; bottom: calc(100% + 6px); z-index: 5; display: grid; min-width: 180px; padding: 6px;
  border: 1px solid var(--color-border); border-radius: 12px; background: var(--color-surface); box-shadow: var(--shadow-floating);
}
.tv-batch-menu p { margin: 4px 8px 6px; font-size: 12px; color: var(--color-text-muted); }
.tv-batch-menu button { height: 34px; padding: 0 10px; border: 0; border-radius: 8px; background: none; text-align: left; font-size: 13px; color: var(--color-text); cursor: pointer; }
.tv-batch-menu button:hover { background: var(--color-surface-muted); }

/* ---------- 查看大图 ---------- */
.tv-viewer-history { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 13px; color: var(--color-text-secondary); }
.tv-viewer-history a { color: var(--color-text); }
/* 历史版本：下载链接后跟「设为当前」 */
.tv-version { display: inline-flex; align-items: baseline; gap: 6px; }

/* ---------- 统一工具窗口：左边选图，右边预览与设置，可切换工具 ---------- */
.tv-tool-form { display: grid; gap: 12px; }
.tv-tool-form label { display: grid; gap: 6px; font-size: 13px; color: var(--color-text-secondary); }
.tv-tool-form textarea { width: 100%; box-sizing: border-box; padding: 10px 12px; font: inherit; font-size: 14px; color: var(--color-text); resize: vertical; }
.tv-tool-submit { display: flex; justify-content: flex-end; align-items: center; gap: 12px; }
.tv-tool-cost { margin: 0; font-size: 13px; color: var(--color-text-muted); white-space: nowrap; }
.tv-tool-settings .image-text-editor { margin-top: 0; padding-top: 0; border-top: 0; }
/* 2026-10-27 (6B 第二段) 局部重绘：图片上叠一层画布，涂过的地方显示为半透明强调色 */
.tv-paint { position: relative; display: inline-block; max-width: 100%; line-height: 0; }
.tv-paint img { display: block; user-select: none; -webkit-user-drag: none; }
.tv-paint canvas { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 8px; opacity: .55; cursor: crosshair; touch-action: none; }
.tv-paint-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.tv-paint-modes { display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--color-surface-muted); }
.tv-paint-modes button { height: 30px; padding: 0 14px; border: 0; border-radius: 8px; background: none; color: var(--color-text-secondary); font: inherit; font-size: 13px; cursor: pointer; }
.tv-paint-modes button[aria-pressed="true"] { background: var(--color-hover); color: var(--color-text); font-weight: 500; }
.tv-tool-form .tv-paint-size { display: flex; align-items: center; gap: 8px; }
.tv-paint-size input { width: 120px; accent-color: var(--color-primary); }
.tv-paint-hint { margin: 0; font-size: 13px; color: var(--color-text-muted); }

/* ---------- 底部输入框：照飞象固定在中间栏最下面、浮在内容上；平时收成一行，点进去或选了图后展开 ---------- */
.tv-composer { position: sticky; bottom: 16px; z-index: 4; flex: none; align-self: center; width: min(655px, 100%); margin-top: auto; transition: width .2s ease; }
.tv-composer[hidden] { display: none; }
.tv-composer.is-open, .tv-composer:focus-within { width: min(100%, 980px); }
.tv-composer-box {
  border: 1px solid rgb(16 18 23 / 10%); border-radius: 20px; background: rgb(var(--ink) / 86%);
  -webkit-backdrop-filter: blur(24px) saturate(160%); backdrop-filter: blur(24px) saturate(160%);
  box-shadow: 0 1px 0 rgb(var(--ink) / 80%) inset, 0 18px 44px -16px rgb(16 18 23 / 24%);
}
.tv-composer-input { display: flex; align-items: flex-start; gap: 12px; padding: 12px 14px 10px; }
.tv-composer-picks { flex: none; }
.tv-composer-add {
  display: grid; place-content: center; justify-items: center; gap: 1px; width: 42px; height: 46px; padding: 0; border: 0; border-radius: 12px;
  background: var(--tv-chip); color: var(--color-text-secondary); font-size: 11px; line-height: 1.2; cursor: pointer;
}
.tv-composer-add span { font-size: 18px; line-height: 1; font-weight: 300; }
.tv-composer-add:hover { background: var(--tv-chip-hover); }
.tv-composer-stack { display: flex; align-items: center; }
.tv-composer-pick { position: relative; width: 40px; height: 46px; }
.tv-composer-pick + .tv-composer-pick { margin-left: -14px; }
.tv-composer-pick img { display: block; width: 100%; height: 100%; object-fit: cover; border: 2px solid #fff; border-radius: 10px; box-shadow: 0 1px 4px rgb(16 18 23 / 18%); }
.tv-composer-pick button {
  position: absolute; right: -5px; top: -5px; width: 18px; height: 18px; padding: 0; border: 0; border-radius: 50%;
  background: var(--color-primary); color: var(--color-on-primary); font-size: 12px; line-height: 18px; cursor: pointer; opacity: 0; transition: opacity .12s ease;
}
.tv-composer-pick:hover button, .tv-composer-pick button:focus-visible { opacity: 1; }
.tv-composer-more { margin-left: 6px; font-size: 12px; color: var(--color-text-muted); }
.tv-composer .tv-composer-input textarea {
  flex: 1; min-width: 0; height: 66px; min-height: 0; max-height: 160px; margin: 0; padding: 12px 0 0; border: 0; border-radius: 0;
  background: none; box-shadow: none; outline: 0; resize: none; font: inherit; font-size: 14px; line-height: 22px; color: var(--color-text);
}
.tv-composer .tv-composer-input textarea::placeholder { color: var(--color-text-muted); }
.tv-composer-bar { display: flex; align-items: center; gap: 10px; padding: 0 14px 14px; }
.tv-composer-chips { flex: 1; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.tv-chip { display: inline-flex; align-items: center; height: 34px; padding: 0 12px; border: 0; border-radius: 10px; background: var(--tv-chip); font-size: 12px; font-weight: 500; color: var(--color-text); white-space: nowrap; cursor: pointer; }
.tv-chip:hover:not(.is-static) { background: var(--tv-chip-hover); }
.tv-chip.is-static { cursor: default; }
.tv-composer-hint { font-size: 12px; color: var(--color-text-muted); }
.tv-composer-send .primary { min-height: 34px; height: 34px; padding: 0 18px; border-radius: 999px; font-size: 13px; white-space: nowrap; }
/* 收起：一行，左边选图、中间输入、右边发送 */
.tv-composer:not(.is-open):not(:focus-within) .tv-composer-box { display: flex; align-items: center; }
.tv-composer:not(.is-open):not(:focus-within) .tv-composer-input { flex: 1; min-width: 0; padding-right: 0; }
.tv-composer:not(.is-open):not(:focus-within) .tv-composer-input textarea { height: 34px; padding-top: 12px; overflow: hidden; }
.tv-composer:not(.is-open):not(:focus-within) .tv-composer-bar { padding: 0 14px 0 0; }
.tv-composer:not(.is-open):not(:focus-within) .tv-composer-chips { display: none; }
@media (prefers-reduced-motion: reduce) { .tv-composer, .tv-composer-pick button { transition: none; } }

@media (max-width: 760px) {
  .tv-result { padding: 16px 10px 10px; border-radius: 16px; }
  .tv-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tv-tile-label { font-size: 11px; }
  .tv-tiles.is-reference { grid-template-columns: minmax(0, 1fr); }
  .tv-composer, .tv-composer.is-open, .tv-composer:focus-within { width: 100%; bottom: 8px; }
  .tv-composer-bar { flex-wrap: wrap; }
}

/* ---------- 2026-10-27 作品页配色照飞象深色主题（全站变量已在 tokens.css 换成深色，这里只放作品页自己的细节） ---------- */
body[data-task-view="open"] .task-view {
  --tv-line: var(--color-surface-muted); --tv-card: transparent; --tv-chip: var(--color-surface-muted); --tv-chip-hover: var(--color-hover); --tv-trigger: var(--color-border); --tv-trigger-hover: var(--color-border-strong);
  scrollbar-color: rgb(var(--ink) / 15%) transparent;
}
body[data-task-view="open"] .tv-list, body[data-task-view="open"] .tv-set {
  background: var(--color-surface); border: 1px solid var(--color-border); border-radius: 20px; box-shadow: -2px 0 10px rgb(0 0 0 / 2%); -webkit-backdrop-filter: none; backdrop-filter: none;
}
body[data-task-view="open"] .tv-list-head { border-bottom-color: var(--color-border); }
body[data-task-view="open"] .tv-task:hover { background: rgb(var(--ink) / 6%); }
body[data-task-view="open"] .tv-task.is-active { background: var(--color-border); border-color: transparent; box-shadow: none; }
body[data-task-view="open"] .tv-task-thumb, body[data-task-view="open"] .tv-summary-thumb { background: var(--color-surface-muted); border-color: var(--color-border); }
body[data-task-view="open"] .tv-task-state.is-warn { color: #fff; }
body[data-task-view="open"] .tv-result { background: transparent; border-color: var(--color-surface-muted); -webkit-backdrop-filter: none; backdrop-filter: none; }
body[data-task-view="open"] .tv-chips li + li::before { background: rgb(var(--ink) / 16%); }
body[data-task-view="open"] .tv-result .image-results-tab { color: rgb(var(--ink) / 60%); }
body[data-task-view="open"] .tv-result .image-results-tab.is-active { background: var(--color-hover); color: var(--color-text); box-shadow: none; }
body[data-task-view="open"] .image-job-progress progress { background: var(--color-border); }
body[data-task-view="open"] .image-job-progress progress::-webkit-progress-bar { background: var(--color-border); }
body[data-task-view="open"] .image-job-progress progress::-webkit-progress-value { background: #f3f3f3; }
body[data-task-view="open"] .image-job-progress progress::-moz-progress-bar { background: #f3f3f3; }
body[data-task-view="open"] .tv-tile-label { color: rgb(var(--ink) / 50%); }
body[data-task-view="open"] .tv-tile-label > i { background: rgb(var(--ink) / 12%); }
body[data-task-view="open"] .tv-tile-picture, body[data-task-view="open"] .tv-tile-reference { background: var(--color-surface-muted); }
body[data-task-view="open"] .tv-tip { background: var(--color-border); }
body[data-task-view="open"] .tv-select-count { color: rgb(var(--ink) / 60%); }
body[data-task-view="open"] .tv-select-cancel { color: var(--color-primary); }
body[data-task-view="open"] .tv-dot { border-color: rgb(255 255 255 / 45%); }
body[data-task-view="open"] .tv-batch-menu { background: rgb(29 29 32 / 96%); border-color: var(--color-border); }
body[data-task-view="open"] .tv-batch-menu button:hover { background: var(--color-hover); }
body[data-task-view="open"] .image-error { color: #ff7a72; }
/* 按钮、输入框的深色已在 theme-graphite.css 全站统一 */
body[data-task-view="open"] .tv-card-foot .image-language-switch select { background-color: var(--color-surface-muted); }
/* 底部输入框：照飞象，黑色半透明加强模糊 */
body[data-task-view="open"] .tv-composer-box {
  border: 1px solid rgb(var(--ink) / 10%); background: rgb(0 0 0 / 60%); box-shadow: 0 1px 0 rgb(var(--ink) / 8%) inset;
  -webkit-backdrop-filter: blur(80px); backdrop-filter: blur(80px);
}
body[data-task-view="open"] .tv-composer .tv-composer-input textarea { background: none; border: 0; color: var(--color-text); font-weight: 300; }
body[data-task-view="open"] .tv-composer .tv-composer-input textarea::placeholder { color: rgb(var(--ink) / 50%); }
body[data-task-view="open"] .tv-composer { --tv-chip: rgb(var(--ink) / 10%); --tv-chip-hover: rgb(var(--ink) / 16%); }
body[data-task-view="open"] .tv-composer-pick img { border-color: var(--color-surface); }
/* 查看大图、工具窗口 */
body[data-task-view="open"] .tv-steps li { background: var(--color-surface-muted); }
/* 手机：顶部栏也换成黑色 */
@media (max-width: 760px) {
  body[data-task-view="open"] .app-header { background: var(--color-page); border-bottom-color: var(--color-surface-muted); -webkit-backdrop-filter: none; backdrop-filter: none; }
  body[data-task-view="open"] .app-header h1, body[data-task-view="open"] .app-header .wb-page-title { color: var(--color-text); }
  body[data-task-view="open"] .wb-menu-button { background: var(--color-surface); border-color: var(--color-border); }
  body[data-task-view="open"] .wb-menu-button span { background: var(--color-text); }
  body[data-task-view="open"] .tv-list, body[data-task-view="open"] .tv-set { border-radius: 0 20px 20px 0; }
  body[data-task-view="open"] .tv-set { border-radius: 20px 20px 0 0; }
}

/* ---------- 查看大图（2026-10-27 照飞象：黑底大图铺满主区，右侧「下载」和工具分组卡片） ---------- */
.tv-viewer { position: fixed; inset: 0 0 0 var(--wb-rail, 0px); width: auto; height: auto; max-width: none; max-height: none; margin: 0; padding: 0;
  border: 0; border-radius: 0; background: var(--color-page); color: var(--color-text); overflow: hidden; }
.tv-viewer[open] { display: flex; }
.tv-viewer::backdrop { background: transparent; }
.tv-viewer-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.tv-viewer-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 24px 24px 0 32px; }
.tv-viewer-info { min-width: 0; }
.tv-viewer-info h2 { margin: 0; font-size: 15px; font-weight: 500; }
.tv-viewer-info p { max-width: 640px; margin: 4px 0 0; font-size: 12px; color: rgb(var(--ink) / 50%); overflow-wrap: anywhere; }
.tv-viewer-actions { flex: none; display: flex; align-items: center; gap: 12px; }
.tv-viewer-count { font-size: 13px; color: rgb(var(--ink) / 60%); }
.tv-viewer-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border: 0; border-radius: 10px;
  background: var(--color-border); color: var(--color-text); font: inherit; font-size: 14px; font-weight: 500; text-decoration: none; cursor: pointer; }
.tv-viewer-btn:hover { background: var(--color-border-strong); }
.tv-viewer-btn .tv-icon { width: 16px; height: 16px; }
.tv-viewer-btn.is-icon { width: 36px; padding: 0; }
.tv-viewer-btn.is-icon .tv-icon { width: 20px; height: 20px; }
.tv-viewer-stage { flex: 1; min-height: 0; display: flex; align-items: center; gap: 16px; padding: 24px 32px 40px; }
.tv-viewer-pictures { flex: 1; min-width: 0; height: 100%; display: flex; align-items: center; justify-content: center; gap: 12px; }
.tv-viewer-image, .tv-viewer-pictures figure img { display: block; max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 10px; }
.tv-viewer-pictures figure { position: relative; margin: 0; max-width: 40%; max-height: 100%; display: flex; }
.tv-viewer-pictures figcaption { position: absolute; left: 8px; top: 8px; padding: 1px 8px; border-radius: 999px; background: rgb(0 0 0 / 60%); color: #fff; font-size: 12px; }
.tv-viewer-step { flex: none; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%; background: var(--color-surface-muted); color: var(--color-text); display: grid; place-items: center; cursor: pointer; }
.tv-viewer-step:hover { background: var(--color-border); }
.tv-viewer-step .tv-icon { width: 20px; height: 20px; }
.tv-viewer-side { flex: none; width: 420px; display: flex; flex-direction: column; border-left: 1px solid var(--color-surface-muted); background: var(--color-page); }
.tv-viewer-side-head { padding: 24px 22px 20px; border-bottom: 1px solid var(--color-surface-muted); }
.tv-viewer-groups { flex: 1; min-height: 0; overflow: auto; padding: 4px 22px 24px; }
.tv-viewer-group h3 { margin: 24px 0 12px; font-size: 16px; font-weight: 500; }
.tv-op-grid, .tv-viewer-versions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; padding: 8px 10px; border-radius: 20px; background: var(--color-surface); }
.tv-op { display: flex; align-items: center; gap: 8px; min-width: 0; height: 48px; padding: 0 10px; border: 0; border-radius: 10px; background: none;
  color: var(--color-text); font: inherit; font-size: 14px; text-align: left; text-decoration: none; cursor: pointer; }
.tv-op:hover:not(:disabled):not(.tv-op-field) { background: var(--color-border); }
.tv-op:disabled { color: rgb(var(--ink) / 40%); cursor: default; }
.tv-op > .tv-icon { flex: none; width: 18px; height: 18px; }
.tv-op > span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tv-op > em { font-style: normal; font-size: 12px; color: rgb(var(--ink) / 50%); white-space: nowrap; }
.tv-op-field { grid-column: 1 / -1; cursor: default; }
.tv-op-field .image-language-switch { flex: 1; display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 14px; color: var(--color-text); }
.tv-op-field .image-language-switch > span { flex: 1; }
.tv-op-field .select-control { width: auto; min-width: 120px; height: 32px; min-height: 32px; padding: 0 12px; gap: 10px; border: 0; border-radius: 8px; background: var(--color-border); font-size: 13px; box-shadow: none; }
.tv-op-field .select-control:hover:not(:disabled) { background: var(--color-border-strong); }
.tv-viewer-versions { grid-template-columns: minmax(0, 1fr); }
.tv-viewer-versions .tv-version { display: flex; align-items: center; justify-content: space-between; height: 44px; padding: 0 10px; font-size: 14px; }
.tv-viewer-versions .tv-version a { color: var(--color-text); }
.tv-viewer-note { margin: 24px 0 0; font-size: 13px; color: rgb(var(--ink) / 50%); }

/* ---------- 统一工具窗口（2026-10-27 照飞象 special-layout：左 387px 工具卡与选图，右侧预览和设置） ---------- */
.tv-tool { position: relative; width: min(1070px, calc(100vw - 32px)); max-width: none; max-height: calc(100dvh - 32px); padding: 0;
  border: 0; border-radius: 30px; background: var(--color-surface); color: var(--color-text); overflow: hidden; }
.tv-tool[open] { display: flex; flex-direction: column; }
.tv-tool::backdrop { background: rgb(0 0 0 / 70%); }
.tv-tool-close { position: absolute; top: 24px; right: 24px; z-index: 3; width: 18px; height: 18px; padding: 0; border: 0; background: none; color: var(--color-text);
  display: grid; place-items: center; cursor: pointer; filter: drop-shadow(0 1px 3px rgb(0 0 0 / 90%)); }
.tv-tool-close:hover { opacity: .6; }
.tv-tool-close .tv-icon { width: 18px; height: 18px; }
.tv-tool-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 387px minmax(0, 1fr); }
.tv-tool-picks { min-height: 0; display: flex; flex-direction: column; padding-bottom: 14px; border-right: .5px solid var(--color-border); }
.tv-tool-card { position: relative; display: flex; align-items: flex-start; gap: 12px; margin: 20px 20px 18px; padding: 19px 14px 19px 18px; border-radius: 16px; background: var(--color-surface-muted); }
.tv-tool-card-icon { flex: none; width: 36px; height: 36px; border-radius: 10px; background: var(--color-border); display: grid; place-items: center; }
.tv-tool-card-icon .tv-icon { width: 18px; height: 18px; }
.tv-tool-head { flex: 1; min-width: 0; }
.tv-tool-head h2 { margin: 0; font-size: 15px; font-weight: 600; letter-spacing: .5px; }
.tv-tool-head p { margin: 4px 0 0; font-size: 12px; line-height: 18px; color: rgb(var(--ink) / 50%); }
.tv-tool-switch { flex: none; display: inline-flex; align-items: center; gap: 8px; height: 28px; padding: 0 10px; border: 0; border-radius: 8px;
  background: var(--color-border); color: var(--color-text); font: inherit; font-size: 12px; cursor: pointer; }
.tv-tool-switch:hover { background: var(--color-border-strong); }
.tv-tool-switch .select-arrow { width: 6px; height: 6px; margin: 0 0 3px; }
.tv-tool-switch[aria-expanded="true"] .select-arrow { transform: rotate(225deg); margin: 4px 0 0; }
.tv-tool-menu { position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 4; display: grid; gap: 2px; padding: 6px;
  border: 1px solid var(--color-border); border-radius: 14px; background: var(--color-surface); box-shadow: 0 12px 32px rgb(0 0 0 / 40%); }
.tv-tool-menu button { display: flex; align-items: center; gap: 10px; height: 40px; padding: 0 12px; border: 0; border-radius: 10px; background: none;
  color: var(--color-text); font: inherit; font-size: 14px; text-align: left; cursor: pointer; }
.tv-tool-menu button:hover, .tv-tool-menu button[aria-checked="true"] { background: var(--color-border); }
.tv-tool-menu button[aria-checked="true"] { font-weight: 500; }
.tv-tool-menu .tv-icon { width: 18px; height: 18px; }
.tv-tool-picks-head { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; padding: 0 24px; }
.tv-tool-picks-head strong { flex: 1; font-size: 15px; font-weight: 500; letter-spacing: .5px; }
.tv-tool-picks-head span { font-size: 11px; color: rgb(var(--ink) / 50%); }
.tv-tool-all { height: 34px; padding: 0 14px; border: 0; border-radius: 8px; background: transparent; color: var(--color-text); font: inherit; font-size: 12px; font-weight: 500; cursor: pointer; }
.tv-tool-all:hover { background: var(--color-surface-muted); }
.tv-tool-pick-list { flex: 1; min-height: 0; overflow: auto; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-content: start; gap: 4px; padding: 0 20px; }
.tv-tool-pick { position: relative; display: grid; gap: 4px; padding: 0 0 6px; border: 0; background: none; color: inherit; text-align: left; font: inherit; cursor: pointer; }
.tv-tool-pick img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; border-radius: 10px; border: 1px solid transparent; background: var(--color-surface-muted); box-sizing: border-box; }
.tv-tool-pick span { font-size: 11px; color: rgb(var(--ink) / 60%); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tv-tool-pick::after { content: ""; position: absolute; right: 6px; top: 6px; width: 16px; height: 16px; box-sizing: border-box; border: 1.5px solid #fff; border-radius: 50%; background: rgb(0 0 0 / 30%); }
.tv-tool-pick.is-on img { border-color: #7b76ff; }
.tv-tool-pick.is-on::after {
  border-color: var(--color-primary); background: var(--color-primary) no-repeat center / 11px 11px
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12.5 4 4L18 8'/%3E%3C/svg%3E");
}
.tv-tool-main { min-height: 0; overflow: auto; display: flex; flex-direction: column; padding: 20px 20px 0; }
.tv-tool-preview { flex: none; height: min(459px, 50dvh); box-sizing: border-box; display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px; padding: 22px 57px 11px 21px; border-radius: 10px; background: #17171a; }
.tv-tool-preview > img, .tv-tool-preview .tv-paint img { max-width: 100%; max-height: calc(min(459px, 50dvh) - 33px); object-fit: contain; border-radius: 10px; }
.tv-tool-preview .tv-paint canvas { border-radius: 10px; }
.tv-tool-settings { padding: 0 0 20px; }
.tv-tool-form label { gap: 8px; font-size: 15px; font-weight: 600; letter-spacing: .5px; color: var(--color-text); }
.tv-tool-form .tv-paint-size { font-size: 13px; font-weight: 400; letter-spacing: 0; color: rgb(var(--ink) / 80%); }
.tv-tool-form textarea { border-radius: 10px; background: var(--color-surface-muted); font-weight: 400; letter-spacing: 0; }
.tv-tool-submit .primary { min-width: 92px; height: 34px; min-height: 34px; padding: 0 16px; border-radius: 10px; font-size: 13px; }

/* 2026-10-31 图片工具（换颜色、换场景、换商品、改尺寸、促销主图、放大、抠图）的设置。 */
.tv-tool-menu { max-height: min(520px, 70dvh); overflow: auto; }
.tv-tool-menu-group { margin: 6px 12px 2px; font-size: 11px; color: rgb(var(--ink) / 50%); }
.tv-tool-menu-group:first-child { margin-top: 2px; }
.tv-tool-field { display: grid; gap: 8px; }
.tv-tool-label { font-size: 15px; font-weight: 600; letter-spacing: .5px; color: var(--color-text); }
.tv-tool-sub { margin: 2px 0 0; font-size: 12px; color: rgb(var(--ink) / 60%); }
.tv-tool-hint { margin: 0; font-size: 12px; line-height: 18px; color: var(--color-text-muted); }
.tv-tool-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.tv-tool-chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border: 1px solid var(--color-border); border-radius: 8px;
  background: var(--color-surface-muted); color: var(--color-text); font: inherit; font-size: 13px; cursor: pointer; }
.tv-tool-chip:hover { border-color: var(--color-border-strong); }
.tv-tool-chip[aria-pressed="true"] { border-color: var(--color-primary); background: var(--color-primary-soft); }
.tv-tool-chip:disabled { opacity: .4; cursor: not-allowed; }
.tv-swatch { width: 14px; height: 14px; border-radius: 50%; box-shadow: inset 0 0 0 1px rgb(var(--ink) / 25%); }
.tv-tool-own { display: flex; align-items: center; gap: 8px; }
.tv-tool-own input[type="color"] { width: 34px; height: 30px; padding: 2px; border: 1px solid var(--color-border); border-radius: 8px; background: var(--color-surface-muted); cursor: pointer; }
.tv-tool-form input[type="text"] { width: 100%; box-sizing: border-box; height: 40px; padding: 0 12px; border: 1px solid var(--color-border); border-radius: 10px;
  background: var(--color-surface-muted); color: var(--color-text); font: inherit; font-size: 14px; font-weight: 400; letter-spacing: 0; }
.tv-tool-upload { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 64px; padding: 8px 12px; box-sizing: border-box;
  border: 1px dashed var(--color-border-strong); border-radius: 10px; background: var(--color-surface-muted); color: var(--color-text-secondary); font: inherit; font-size: 13px; cursor: pointer; }
.tv-tool-upload:hover { border-color: var(--color-primary); color: var(--color-text); }
.tv-tool-upload.is-filled { justify-content: flex-start; border-style: solid; cursor: default; }
.tv-tool-upload.is-filled img { width: 48px; height: 48px; object-fit: cover; border-radius: 8px; }
.tv-tool-upload.is-filled span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 760px) {
  .tv-viewer { inset: 0; flex-direction: column; }
  .tv-viewer-top { padding: 16px 16px 0; }
  .tv-viewer-stage { padding: 12px 8px; gap: 8px; }
  .tv-viewer-step { width: 32px; height: 32px; }
  .tv-viewer-side { width: auto; max-height: 46dvh; border-left: 0; border-top: 1px solid var(--color-surface-muted); }
  .tv-viewer-side-head { padding: 12px 16px; }
  .tv-viewer-groups { padding: 0 16px 16px; }
  .tv-tool { border-radius: 20px; }
  .tv-tool-body { grid-template-columns: minmax(0, 1fr); overflow: auto; }
  .tv-tool-picks { border-right: 0; border-bottom: .5px solid var(--color-border); }
  .tv-tool-card { margin: 16px 48px 12px 16px; }
  .tv-tool-pick-list { grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 0 16px; }
  .tv-tool-main { padding: 16px 16px 0; overflow: visible; }
  .tv-tool-preview { height: 40dvh; padding: 12px; }
  .tv-tool-preview > img, .tv-tool-preview .tv-paint img { max-height: calc(40dvh - 24px); }
}

/* ---------- 2026-10-29 照飞象聊天流：每次修改在下面接一轮——右边是这次的修改要求（改自哪几张图），下面是这一轮的新图 ---------- */
.tv-rounds { display: flex; flex-direction: column; gap: 20px; }
.tv-rounds:empty { display: none; }
.tv-round { display: flex; flex-direction: column; gap: 12px; scroll-margin-top: 16px; }
.tv-ask { align-self: flex-end; max-width: min(560px, 86%); display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.tv-ask-pics { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.tv-ask-pic { position: relative; margin: 0; width: 64px; }
.tv-ask-pic button { display: block; width: 64px; height: 64px; padding: 0; border: 0; border-radius: 10px; overflow: hidden; background: var(--color-surface-muted); cursor: zoom-in; }
.tv-ask-pic > img, .tv-ask-pic button img { display: block; width: 64px; height: 64px; object-fit: cover; border-radius: 10px; background: var(--color-surface-muted); }
.tv-ask-pic figcaption { margin-top: 3px; font-size: 11px; line-height: 14px; color: var(--color-text-muted); text-align: center; overflow-wrap: anywhere; }
.tv-ask-more { align-self: center; padding: 0 6px; font-size: 12px; color: var(--color-text-muted); }
.tv-ask p { margin: 0; padding: 10px 14px; border-radius: 16px 4px 16px 16px; background: var(--tv-chip); font-size: 13px; line-height: 1.6; color: var(--color-text); overflow-wrap: anywhere; }
.tv-ask p strong { margin-right: 8px; font-weight: 600; color: var(--color-text-secondary); }
.tv-round-card { gap: 12px; }
/* 查看大图（2026-10-29 用户：点图只放大看）：没有右侧工具栏，下载和编辑在右上角 */
.tv-viewer-actions .tv-viewer-btn { flex: none; }
@media (max-width: 720px) {
  .tv-ask { max-width: 100%; }
  .tv-viewer-top { flex-direction: column; gap: 10px; }
  .tv-viewer-actions { align-self: flex-end; gap: 8px; }
}

/* 2026-10-30 改文字 · 干净底图与文字图层：像 Canva 一样在大图上直接改——上方工具栏，点选、双击改字、拖动。 */
.tv-tool-preview.is-canvas { --canvas-h: min(600px, calc(100dvh - 300px)); height: auto; padding: 14px 20px 20px; align-items: stretch; }
.tv-canvas { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 14px; min-width: 0; }
.tv-canvas-top { align-self: stretch; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tv-canvas-undo { flex: none; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border: 1px solid var(--color-border); border-radius: 10px; background: none; color: var(--color-text); font: inherit; font-size: 13px; cursor: pointer; }
.tv-canvas-undo:hover:not(:disabled) { background: var(--color-hover); }
.tv-canvas-undo:disabled { opacity: .4; cursor: default; }
.tv-canvas-undo .tv-icon { width: 16px; height: 16px; }
.tv-handle { position: absolute; width: 9px; height: 9px; box-sizing: border-box; border: 1.5px solid var(--color-primary); border-radius: 2px; background: #fff; }
.tv-handle.is-nw, .tv-handle.is-sw, .tv-handle.is-w { left: -8px; }
.tv-handle.is-ne, .tv-handle.is-se, .tv-handle.is-e { right: -8px; }
.tv-handle.is-n, .tv-handle.is-s { left: calc(50% - 4.5px); }
.tv-handle.is-nw, .tv-handle.is-ne, .tv-handle.is-n { top: -8px; }
.tv-handle.is-sw, .tv-handle.is-se, .tv-handle.is-s { bottom: -8px; }
.tv-handle.is-w, .tv-handle.is-e { top: calc(50% - 4.5px); }
.tv-handle.is-nw, .tv-handle.is-se { cursor: nwse-resize; }
.tv-handle.is-ne, .tv-handle.is-sw { cursor: nesw-resize; }
.tv-handle.is-n, .tv-handle.is-s { cursor: ns-resize; }
.tv-handle.is-e, .tv-handle.is-w { cursor: ew-resize; }
.tv-layer-bar { display: flex; align-items: center; gap: 12px; min-height: 40px; padding: 4px 8px; box-sizing: border-box; border: 1px solid var(--color-border); border-radius: 10px; background: var(--color-surface, var(--color-surface-muted)); font-size: 13px; color: var(--color-text); }
.tv-layer-bar.is-empty { border-style: dashed; padding: 4px 14px; color: var(--color-text-muted); }
.tv-layer-bar-gap { width: 1px; height: 20px; background: var(--color-border); }
.tv-layer-size { display: inline-flex; align-items: center; gap: 2px; }
.tv-layer-size button { width: 30px; height: 30px; border: 0; border-radius: 8px; background: none; color: var(--color-text); font: inherit; font-size: 16px; cursor: pointer; }
.tv-layer-size button:hover { background: var(--color-hover); }
.tv-layer-size input { width: 52px; height: 30px; padding: 0 4px; box-sizing: border-box; text-align: center; font: inherit; color: var(--color-text); }
.tv-layer-swatch { display: inline-flex; }
.tv-layer-swatch input { width: 30px; height: 30px; padding: 2px; border: 1px solid var(--color-border); border-radius: 8px; background: none; cursor: pointer; }
.tv-layers { position: relative; max-height: var(--canvas-h); container-type: size; overflow: visible; border-radius: 10px; line-height: 1; }
.tv-layers > img { display: block; width: 100%; height: 100%; border-radius: 10px; user-select: none; -webkit-user-drag: none; }
.tv-layer { position: absolute; white-space: pre; cursor: move; touch-action: none; user-select: none; outline: 1px dashed transparent; outline-offset: 3px; }
.tv-layer.is-original { background-repeat: no-repeat; }
.tv-layer.is-vertical { writing-mode: vertical-rl; }
.tv-layer:hover { outline-color: rgb(123 118 255 / 60%); }
.tv-layer.is-selected { outline: 1.5px solid var(--color-primary); }
.tv-layer.is-editing { cursor: text; user-select: text; outline: 1.5px solid var(--color-primary); min-width: 1em; }
.tv-text-lines { margin: 0; padding-left: 20px; display: grid; gap: 4px; font-size: 14px; color: var(--color-text); }
.tv-canvas-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

/* 页签上的小标签（11-02 起只用于改文字的「正在抹字…」等；「待确认」已去掉） */
.tv-tile-doubt {
  flex: none; margin-left: 6px; padding: 1px 6px; border: 0; border-radius: 6px; background: var(--color-primary);
  color: var(--color-on-primary); font: inherit; font-size: 11px; line-height: 16px; cursor: pointer;
}
.tv-tile-doubt:hover { background: var(--color-primary-hover); }
/* 2026-11-01 改文字抹字进度挂在图片页签上（作品页不显示右下角卡片），点一下回到改字 */
.tv-tile-doubt.is-text.is-busy { background: var(--color-surface-muted); color: var(--color-text-secondary); }
.tv-tile-doubt.is-text.is-busy:hover { background: var(--color-hover); }
