/* 创意工坊深水区交互：历史对话面板、风格广场、参考素材。仅使用 tokens.css 语义变量。 */
.workshop-page [hidden], .df-dialog [hidden], .workshop-history [hidden] { display: none !important; }

/* ---------- 历史对话面板 ---------- */
.workshop-page.has-history .workshop-chat-tools { display: none; }
.main-wrap .workshop-history { padding: 24px 20px 16px; box-sizing: border-box; }
.workshop-history .history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}
.workshop-history .history-head h2 {
  margin: 0;
  font-size: var(--df-font-size-md);
  font-weight: var(--df-font-weight-medium);
}
.history-collapse {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 0;
  border-radius: var(--df-radius-sm);
  background: transparent;
  color: var(--df-color-text-faint);
  font: inherit;
  cursor: pointer;
}
.history-collapse:hover { background: var(--df-color-surface-hover); color: var(--df-color-text); }

.history-new {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  height: 32px;
  padding: 4px 12px;
  border: 1px solid var(--df-color-text-on-card);
  border-radius: 4px;
  background: var(--df-color-surface-panel-2);
  color: var(--df-color-text-on-card);
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}
.history-new:hover { background: var(--df-color-fill); }

.history-filters {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  width: 100%;
  height: 32px;
  padding: 4px 8px;
  border: 1px solid var(--df-color-fill);
  border-radius: var(--df-radius-lg);
  margin: 12px 0;
}
.history-search-icon { display: inline-flex; flex: none; width: 30px; justify-content: center; padding: 0; border: 0; background: transparent; color: var(--df-color-text); cursor: pointer; }
.history-filters[hidden], .history-search-box[hidden] { display: none; }
.history-search-box { display: flex; align-items: center; height: 32px; margin: var(--df-space-3) 0; border: 1px solid var(--df-color-divider); border-radius: var(--df-radius-lg); background: var(--df-color-surface); }
.history-search-box input { flex: 1; min-width: 0; height: 100%; padding: 0 8px; border: 0; background: transparent; color: var(--df-color-text); font: inherit; font-size: var(--df-font-size-xs); outline: none; }
.history-search-box button { display: grid; width: 32px; height: 32px; place-items: center; border: 0; background: transparent; color: var(--df-color-text-faint); cursor: pointer; }
.history-search-box .df-icon { width: 12px; height: 12px; }
.history-filter { position: relative; display: flex; flex: none; align-items: center; }
.history-filter-divider { flex: none; width: 1px; height: 12px; background: var(--df-color-divider-strong); }
.history-filter__trigger {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 78px;
  height: 20px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-xs);
  cursor: pointer;
}
.history-filter__trigger .df-icon { flex: none; width: 12px; height: 12px; color: var(--df-color-text); }
/* 该 SVG 在本页会被更高优先级的 display 规则命中，开合态必须用 !important 才能生效 */
.history-filter__caret-up { display: none !important; }
.history-filter.is-open .history-filter__caret-down { display: none !important; }
.history-filter.is-open .history-filter__caret-up { display: block !important; }
/* fixed：逃出 .left { overflow:hidden }，避免被历史侧栏裁切/被主内容盖住（对标线上 el-popper） */
.history-filter__menu {
  position: fixed;
  top: auto;
  left: auto;
  width: 100px;
  min-width: 100px;
  transform: none;
  z-index: var(--df-z-dropdown);
}
.history-filter__menu--sort { width: 160px; min-width: 160px; }

.history-list {
  display: flex;
  flex-direction: column;
  gap: var(--df-space-2);
  padding: 0;
  overflow-y: auto;
}
.history-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding-top: 114px;
  color: var(--df-color-text-secondary);
  font-size: var(--df-font-size-xs);
}
.history-empty svg, .history-empty .df-icon--xl { width: 28px; height: 28px; color: var(--df-color-text-secondary); }
.history-item {
  display: flex;
  flex-direction: column;
  gap: var(--df-space-1);
  width: 100%;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface);
  color: var(--df-color-text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.history-item:hover { background: var(--df-color-surface-hover); }
.history-item[aria-current="true"] { border-color: var(--df-color-accent); }
.history-item span { color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }

#workshop-form { position: relative; }
/* 拖拽上传遮罩：线上 .chat-drag-upload-wrap（MessageInput-BXa8SypH.css / data-v-948b0344）
   inset:0、圆角 8、1px dashed #be9bff、底 10% 白 + blur(4px)、插图 42px、文案 14px #fff */
.chat-drag-upload-wrap {
  position: absolute;
  inset: 0;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--df-space-4);
  padding: 4px 8px;
  border: 1px dashed var(--df-color-accent);
  border-radius: var(--df-radius-lg);
  background: var(--df-color-fill-soft);
  backdrop-filter: blur(4px);
}
.chat-drag-upload-wrap[hidden] { display: none; }
.chat-drag-upload-wrap img { width: 42px; height: auto; }
.chat-drag-upload-wrap div { color: var(--df-color-primary-text); font-size: var(--df-font-size-md); }

/* ---------- 参考素材 ---------- */
.workshop-attachments .reference-chips { display: flex; align-items: center; gap: var(--df-space-2); flex-wrap: wrap; }
.reference-chip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--df-space-1);
  height: 48px;
  padding: 0 8px 0 0;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface);
  color: var(--df-color-text-secondary);
  font-size: var(--df-font-size-xs);
}
.reference-chip img { width: 48px; height: 48px; border-radius: var(--df-radius-md) 0 0 var(--df-radius-md); object-fit: cover; }
.reference-chip button { border: 0; background: transparent; color: inherit; font: inherit; cursor: pointer; }

.reference-popover {
  position: fixed;
  z-index: var(--df-z-dropdown);
  display: flex;
  flex-direction: column;
  gap: 0;
  width: 160px;
  padding: 0 0 8px;
  border: 0;
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface-raised);
  box-shadow: var(--df-shadow-popover);
}
.reference-popover[hidden] { display: none; }
.reference-popover__title { padding: 12px 12px 13px; color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.reference-popover button {
  height: 40px;
  padding: 8px 12px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-xs);
  text-align: left;
  cursor: pointer;
}
.reference-popover button:hover { background: var(--df-color-surface-hover); }

/* ---------- 资产库弹窗 ---------- */
.workshop-asset-dialog {
  width: min(880px, 92vw);
  max-height: 80vh;
  padding: var(--df-space-6);
  border: 1px solid var(--df-color-divider);
  border-radius: var(--df-radius-2xl);
  background: var(--df-color-panel);
  color: var(--df-color-text);
  box-shadow: var(--df-shadow-dialog);
}
.workshop-asset-dialog::backdrop { background: var(--df-color-mask); }
.workshop-asset-dialog header { display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--df-space-4); }
.workshop-asset-dialog h2 { margin: 0; font-size: var(--df-font-size-lg); font-weight: var(--df-font-weight-medium); }
.workshop-asset-dialog header button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: var(--df-radius-md);
  background: transparent;
  color: var(--df-color-text-secondary);
  font: inherit;
  cursor: pointer;
}
.workshop-asset-sources { display: flex; gap: var(--df-space-2); margin-bottom: var(--df-space-4); }
.workshop-asset-sources button {
  padding: 6px 12px;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-pill);
  background: var(--df-color-surface);
  color: var(--df-color-text-secondary);
  font: inherit;
  font-size: var(--df-font-size-sm);
  cursor: pointer;
}
.workshop-asset-sources button[aria-pressed="true"] { border-color: var(--df-color-accent); color: var(--df-color-text); }
.workshop-asset-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--df-space-3);
  max-height: 52vh;
  overflow-y: auto;
}
.workshop-asset-grid button { padding: 0; border: 1px solid transparent; border-radius: var(--df-radius-lg); background: transparent; overflow: hidden; cursor: pointer; }
.workshop-asset-grid button[aria-pressed="true"] { border-color: var(--df-color-accent); }
.workshop-asset-grid img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

/* ---------- 风格广场弹窗 ---------- */
/* 风格广场弹窗外壳使用 .df-dialog（见 workshop.html），这里保留尺寸与内容样式 */
.style-dialog { width: min(1240px, 94vw); height: min(720px, 90vh); }
/* 头部使用 .df-dialog__head，仅保留标签栏布局 */
.style-dialog__head { padding: var(--df-space-4) var(--df-space-6); }
.style-tabs { display: flex; gap: var(--df-space-6); }
.style-tabs button { padding: 4px 0 10px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--df-color-text-secondary); font: inherit; cursor: pointer; }
.style-tabs button[aria-pressed="true"] { border-bottom-color: var(--df-color-text); color: var(--df-color-text); font-weight: var(--df-font-weight-semibold); }
.style-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--df-space-4);
  padding: 0 var(--df-space-6) var(--df-space-8);
}
.style-chips { display: flex; flex-wrap: wrap; gap: 12px; }
.style-chips button {
  height: 32px;
  padding: 0 14px;
  border: 1px solid transparent;
  border-radius: var(--df-radius-pill);
  background: var(--df-color-surface);
  color: var(--df-color-text-secondary);
  font: inherit;
  font-size: var(--df-font-size-sm);
  cursor: pointer;
}
.style-chips button[aria-pressed="true"] { padding: 0 15px; background: var(--df-color-surface-active); color: var(--df-color-text); font-weight: var(--df-font-weight-semibold); }
.style-search { display: flex; align-items: center; gap: var(--df-space-2); flex: 0 0 auto; }
.style-search input {
  width: 200px;
  padding: 7px 10px;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface);
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-sm);
}
.style-search button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: var(--df-radius-md);
  background: transparent;
  color: var(--df-color-text-secondary);
  font: inherit;
  cursor: pointer;
}
.style-search button:hover { background: var(--df-color-surface-hover); }

.style-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  padding: 0 34px 16px 24px;
  overflow-y: auto;
  flex: 1;
  align-content: start;
}
.style-card { position: relative; min-width: 0; }
.style-card__main {
  display: block;
  width: 100%;
  padding: 0 0 11px;
  overflow: hidden;
  border: 2px solid transparent;
  border-radius: var(--df-radius-lg);
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  text-align: left;
  cursor: pointer;
}
.style-card__main img { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; margin-bottom: 13px; }
.style-card__main span { display: block; padding: 0 28px 0 12px; font-size: var(--df-font-size-sm); line-height: 24px; }
.style-card__main[aria-pressed="true"] { border-color: var(--df-color-primary-hover); }
.style-card__favorite {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 0;
  border-radius: var(--df-radius-sm);
  background: var(--df-color-surface);
  color: var(--df-color-text-strong);
  box-shadow: inset 0 0 0 1px var(--df-color-border-subtle);
  font: inherit;
  opacity: 0;
  cursor: pointer;
}
.style-card:hover .style-card__favorite,
.style-card__favorite:focus-visible,
.style-card__main[aria-pressed="true"] + .style-card__favorite,
.style-card__favorite[aria-pressed="true"] { opacity: 1; }
.style-card__favorite:hover { background: var(--df-color-surface-hover); }
.style-card__favorite:focus-visible { outline: 2px solid var(--df-color-focus-ring); outline-offset: 2px; }
.style-card__more { position: absolute; right: 8px; bottom: 6px; display: grid; width: 24px; height: 24px; place-items: center; padding: 0; border: 0; background: transparent; color: var(--df-color-text-faint); cursor: pointer; }
.style-card__more .df-icon { width: 14px; height: 14px; }
.style-custom-menu { position: absolute; right: 6px; top: auto; bottom: 34px; z-index: var(--df-z-dropdown); min-width: 88px; }
.style-custom-menu button:last-child { color: var(--df-color-danger); }
.style-empty { grid-column: 1 / -1; padding: 64px 0; color: var(--df-color-text-faint); text-align: center; }

/* 底部使用 .df-dialog__footer + .df-btn */
.style-dialog__footer { padding: var(--df-space-4) var(--df-space-6); }
.style-cancel { border: 1px solid var(--df-color-border); background: transparent; color: var(--df-color-text); }
.style-confirm { border: 1px solid transparent; background: var(--df-color-primary); color: var(--df-color-primary-text); }
.style-confirm:hover { background: var(--df-color-primary-hover); }

/* ---------- 会话与生成结果 ---------- */
.workshop-page .right.is-chatting .page-title,
.workshop-page .right.is-chatting .gallery { display: none; }
.right-conversation[hidden] { display: none; }
.right-conversation { display: flex; flex-direction: column; gap: var(--df-space-4); flex: 1; padding: var(--df-space-5) 0; overflow-y: auto; }
.conversation-turn { display: flex; flex-direction: column; gap: var(--df-space-3); }
/* 对标线上 .message-query：深色底 #1f2126 / 字 #e5eaf3；浅色改为白底描边，避免 surface-raised 与页面底糊成一片 */
.conversation-prompt {
  align-self: flex-end;
  width: fit-content;
  max-width: 60%;
  margin-bottom: 8px;
  padding: 12px 16px;
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface-panel-2);
  color: var(--df-color-text-on-card);
  font-size: var(--df-font-size-md);
  font-weight: 400;
  line-height: 24px;
  text-align: left;
  white-space: pre-wrap;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}
.conversation-prompt.is-expanded { display: block; overflow: visible; -webkit-line-clamp: unset; max-height: none; }
.message-query-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  align-self: flex-end;
  width: 60%;
  height: 20px;
  color: var(--df-color-text-secondary);
  font-size: var(--df-font-size-xs);
}
.message-query-btns {
  display: none;
  flex: 1;
  align-items: center;
  justify-content: flex-end;
  gap: 20px;
  margin-right: 20px;
}
.conversation-turn:hover .message-query-btns { display: flex; }
.message-query-actions button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.message-query-actions button:hover { opacity: .8; }
.message-query-actions .df-icon { width: 12px; height: 12px; }
/* 对标线上 .message-time：14/20、#86909c，默认常显（复制/编辑才悬停出现） */
.message-time {
  color: var(--df-color-text-faint);
  font-size: var(--df-font-size-md);
  font-weight: 400;
  line-height: 20px;
  white-space: nowrap;
}
.conversation-meta { color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.conversation-result {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--df-space-3);
}
.conversation-result figure { margin: 0; overflow: hidden; border: 1px solid var(--df-color-border); border-radius: var(--df-radius-lg); background: var(--df-color-surface); }
.conversation-result img, .conversation-result video { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: var(--df-color-surface-sunken); }
.conversation-result figcaption { padding: 6px 10px; color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.conversation-loading { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--df-space-3); }
.conversation-progress { display: flex; grid-column: 1 / -1; align-items: center; gap: var(--df-space-3); color: var(--df-color-text); font-size: var(--df-font-size-sm); font-weight: var(--df-font-weight-medium); }
.conversation-progress__track { display: block; width: 160px; height: 6px; overflow: hidden; border-radius: var(--df-radius-pill); background: var(--df-color-fill-strong); }
.conversation-progress__track i { display: block; height: 100%; border-radius: inherit; background: var(--df-color-text-secondary); }
.conversation-loading span {
  aspect-ratio: 1 / 1;
  border-radius: var(--df-radius-lg);
  background: linear-gradient(100deg, var(--df-color-surface) 30%, var(--df-color-surface-hover) 50%, var(--df-color-surface) 70%);
  background-size: 220% 100%;
  animation: df-skeleton 1.2s linear infinite;
}
@keyframes df-skeleton { from { background-position: 120% 0; } to { background-position: -20% 0; } }

@media (prefers-reduced-motion: reduce) {
  .conversation-loading span { animation: none; }
}

@media (max-width: 1080px) {
  .style-grid, .workshop-asset-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .style-toolbar { flex-wrap: wrap; }
}

/* ---------- 积分与发送状态 ---------- */
.workshop-credit-warning {
  display: inline-flex;
  align-items: center;
  gap: var(--df-space-1);
  padding: 2px 8px;
  border: 1px solid var(--df-color-danger);
  border-radius: var(--df-radius-pill);
  color: var(--df-color-danger);
  font-size: var(--df-font-size-xs);
}
.workshop-credit-warning[hidden] { display: none; }
.workshop-send button[disabled] {
  cursor: not-allowed;
  background: transparent;
}

/* ---------- 结果卡片：放大与失败态 ---------- */
.conversation-result figure { position: relative; }
.conversation-result figure button {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
}
.conversation-result figure img { transition: transform var(--df-duration-base) var(--df-ease-standard); }
.conversation-result figure button:hover img { transform: scale(1.03); }
.conversation-result .result-play {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 50%;
  background: var(--df-color-tag-bg);
  color: var(--df-color-tag-text);
  font-size: 14px;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.conversation-error {
  display: flex;
  flex-direction: column;
  gap: var(--df-space-3);
  padding: var(--df-space-3) var(--df-space-4);
  border: 1px solid var(--df-color-danger);
  border-radius: var(--df-radius-xl);
  background: var(--df-color-surface);
  color: var(--df-color-danger);
  font-size: var(--df-font-size-sm);
}
.conversation-error__header { display: flex; align-items: center; gap: var(--df-space-2); }
.conversation-error__desc { margin: 0; color: var(--df-color-text-secondary); }
.conversation-error__actions { display: flex; align-items: center; justify-content: space-between; gap: var(--df-space-3); }
.conversation-error button { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: transparent; color: var(--df-color-text); font: inherit; cursor: pointer; }
.conversation-error__task { display: inline-flex; align-items: center; gap: 4px; color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.conversation-error__task code { overflow: hidden; max-width: 280px; text-overflow: ellipsis; white-space: nowrap; }
.conversation-error__task button { padding: 4px; }
.conversation-error__task button.is-copied { color: var(--df-color-success); }

/* ---------- 结果预览 ---------- */
/* 结果预览弹窗使用 .df-dialog--xl（见 workshop.html），这里只保留媒体区与工具栏 */
.result-preview__actions { display: flex; gap: var(--df-space-2); }
.result-preview__body { display: grid; grid-template-columns: minmax(0, 1fr) 360px; flex: 1; min-height: 0; }
.result-preview__info { display: flex; flex-direction: column; gap: var(--df-space-4); padding: var(--df-space-6); overflow-y: auto; }
.result-preview__info h2 { margin: 0 0 var(--df-space-2); font-size: var(--df-font-size-lg); }
.result-preview__row { display: flex; flex-direction: column; gap: var(--df-space-2); color: var(--df-color-text-secondary); font-size: var(--df-font-size-sm); overflow-wrap: anywhere; }
.result-preview__label { display: flex; align-items: center; justify-content: space-between; color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.result-preview__label button { padding: 0; border: 0; background: transparent; color: inherit; cursor: pointer; }
.result-preview__label button.is-copied { color: var(--df-color-success); }
.result-preview__thumbnails { display: flex; gap: var(--df-space-2); padding: var(--df-space-2) var(--df-space-4); overflow-x: auto; }
.result-preview__thumbnails[hidden] { display: none; }
.result-preview__thumb { flex: none; width: 56px; height: 56px; padding: 0; overflow: hidden; border: 2px solid transparent; border-radius: var(--df-radius-md); background: transparent; cursor: pointer; }
.result-preview__thumb[aria-pressed="true"] { border-color: var(--df-color-accent); }
.result-preview__thumb img { width: 100%; height: 100%; object-fit: cover; }
.result-preview__actions { margin-top: auto; }
.result-preview__media {
  display: grid;
  flex: 1;
  min-height: 0;
  place-items: center;
  padding: var(--df-space-4);
  background: var(--df-color-surface-sunken);
}
.result-preview__media img, .result-preview__media video { display: block; max-width: 100%; max-height: 64vh; border-radius: var(--df-radius-lg); object-fit: contain; }
.result-preview__meta { color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.result-preview__actions { display: flex; gap: var(--df-space-2); }
.result-preview__actions button {
  padding: 7px 14px;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-lg);
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-sm);
  cursor: pointer;
}
.result-preview__actions button:hover { background: var(--df-color-surface-hover); }
.result-preview__actions .is-primary { border-color: transparent; background: var(--df-color-primary); color: var(--df-color-primary-text); }
.result-preview__actions .is-primary:hover { background: var(--df-color-primary-hover); }

/* ---------- 历史会话：补充线上结构缺失的样式 ---------- */
.workshop-history { position: relative; }
.history-card .card-header .more-btn { color: inherit; font: inherit; }
.history-card .card-info .card-time { color: var(--df-color-text-faint); }
/* 菜单外壳复用 styles/components.css 的 .df-menu；fixed 逃出侧栏 overflow */
.history-menu {
  position: fixed;
  z-index: var(--df-z-dropdown);
}
.history-menu button, .style-custom-menu button { display: flex; align-items: center; gap: 6px; }
.history-menu .df-icon, .style-custom-menu .df-icon { width: 14px; height: 14px; }
.history-menu button[data-history-action="delete"] { color: var(--df-color-danger); }

/* 会话弹窗使用 styles/components.css 的 .df-dialog（见 workshop.html） */

/* ---------- @ 引用参考素材 ---------- */
/* @ 引用素材浮层：线上 .material-list-popover / .material-item / .material-list-empty（MessageInput-BXa8SypH.css / data-v-948b0344）
   width:200; border-radius:4; padding:8px 0; background:#272a30；行 padding:8px 16px、hover/active #3b404880 */
.mention-popover {
  position: fixed;
  z-index: var(--df-z-dropdown);
  display: flex;
  flex-direction: column;
  width: 200px;
  max-height: 360px;
  padding: 8px 0;
  overflow: hidden;
  border: 0;
  border-radius: var(--df-radius-sm);
  background: var(--df-color-surface-raised);
}
.mention-popover[hidden] { display: none; }
.mention-popover__body { flex: 1; padding: 8px 0; overflow-y: auto; }
.mention-item {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 8px 16px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.2s ease;
}
.mention-item:hover, .mention-item[aria-selected="true"] { background: var(--df-color-option-hover); }
.mention-item__image { position: relative; flex: none; width: 32px; height: 32px; margin-right: 12px; border-radius: var(--df-radius-md); overflow: hidden; }
.mention-item__image img { width: 100%; height: 100%; object-fit: cover; }
.mention-item__badge { position: absolute; left: 4px; bottom: 4px; width: 12px; height: 12px; }
.mention-item__info { display: flex; flex: 1; flex-direction: column; gap: 4px; min-width: 0; }
.mention-item__title { overflow: hidden; color: var(--df-color-text); font-size: var(--df-font-size-xs); font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- 自定义风格创建（W-03） ---------- */
.style-search .style-create { width: auto; white-space: nowrap; }
.style-create {
  margin-right: var(--df-space-2);
  padding: 6px 14px;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-pill);
  background: var(--df-color-surface);
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-sm);
  cursor: pointer;
}
.style-create:hover { background: var(--df-color-surface-hover); }
.style-create[hidden] { display: none; }

.style-dialog--custom { width: min(560px, 94vw); height: auto; }
.style-dialog--custom h2 { margin: 0; padding: var(--df-space-4) var(--df-space-6); border-bottom: 1px solid var(--df-color-divider); font-size: var(--df-font-size-lg); font-weight: var(--df-font-weight-medium); }
.style-form { display: flex; flex-direction: column; gap: var(--df-space-4); padding: var(--df-space-5) var(--df-space-6) var(--df-space-2); }
.style-form__field { display: grid; grid-template-columns: 72px minmax(0, 1fr); align-items: start; gap: var(--df-space-3); color: var(--df-color-text-faint); font-size: var(--df-font-size-sm); }
.style-form__field > span { padding-top: 8px; }
.style-form__field .df-input,
.style-form__field .df-textarea { font-size: var(--df-font-size-sm); }
.style-form__field .df-textarea { min-height: 84px; }
.style-form__cover {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 128px;
  height: 72px;
  overflow: hidden;
  border: 1px dashed var(--df-color-border);
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface-sunken);
  color: var(--df-color-text-faint);
  font-size: var(--df-font-size-xs);
  cursor: pointer;
}
.style-form__cover img { width: 100%; height: 100%; object-fit: cover; }
.style-form__field input[type="file"] { margin-top: var(--df-space-2); color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.style-dialog--custom .style-dialog__footer { border-top: 1px solid var(--df-color-divider); }
.style-card__placeholder {
  display: grid;
  width: 100%;
  aspect-ratio: 16 / 9;
  margin-bottom: var(--df-space-2);
  place-items: center;
  border-radius: var(--df-radius-lg) var(--df-radius-lg) 0 0;
  background: linear-gradient(135deg, var(--df-color-primary-soft), var(--df-color-surface-raised));
  color: var(--df-color-primary-text);
  font-size: var(--df-font-size-xs);
}

/* ---------- 结果操作与排队态（对齐线上） ---------- */
.conversation-result figure { position: relative; }
.result-actions {
  position: absolute;
  right: var(--df-space-2);
  bottom: 26px;
  left: var(--df-space-2);
  display: flex;
  gap: var(--df-space-1);
  padding: var(--df-space-1);
  border-radius: var(--df-radius-lg);
  background: var(--df-color-tag-bg);
  opacity: 0;
  transition: opacity var(--df-duration-fast) var(--df-ease-standard);
}
/* 对标线上 .message-content-actions + .operate-btn：行宽随内容，时间跟在删除后（勿 margin-left:auto 顶到通栏右侧） */
.message-content-actions {
  display: flex;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  gap: 20px;
  color: var(--df-color-text-strong);
  font-size: var(--df-font-size-md);
}
.message-content-actions button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 20px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
.message-content-actions button:hover { opacity: .8; }
.message-content-actions .df-icon { width: 14px; height: 14px; }
.conversation-result figure:hover .result-actions,
.result-actions:focus-within { opacity: 1; }
.result-actions button {
  flex: 1;
  padding: 4px 6px;
  border: 0;
  border-radius: var(--df-radius-sm);
  background: transparent;
  color: var(--df-color-tag-text);
  font: inherit;
  font-size: var(--df-font-size-xs);
  white-space: nowrap;
  cursor: pointer;
}
.result-actions button:hover { background: var(--df-color-fill-mid); }
.result-actions button[data-action="delete"] { color: var(--df-color-danger-hover); }

.conversation-queue {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--df-space-3);
  padding: var(--df-space-4);
  border: 1px solid var(--df-color-divider);
  border-radius: var(--df-radius-xl);
  background: var(--df-color-surface);
}
.conversation-queue__title { color: var(--df-color-text); font-size: var(--df-font-size-sm); }
.conversation-queue__desc { color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.conversation-queue__cancel {
  margin-left: auto;
  padding: 5px 12px;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-md);
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-xs);
  cursor: pointer;
}

/* ---------- 线上图标（assets/online-icons.js） ---------- */
.df-icon { display: inline-block; width: 1em; height: 1em; flex: none; fill: currentColor; vertical-align: -0.15em; }
.df-icon--xl { width: 44px; height: 44px; }
.history-card .card-thumbnail .df-icon { width: 16px; height: 16px; }
.history-card .more-btn .df-icon { width: 14px; height: 14px; }
.history-filters .history-search-icon .df-icon { width: 12px; height: 12px; }
.style-dialog__close .df-icon, .df-dialog__close .df-icon { width: 16px; height: 16px; }
.style-card__favorite .df-icon { width: 14px; height: 14px; }
.conversation-result .result-play .df-icon { width: 18px; height: 18px; }
.result-actions .df-icon, .result-preview__actions .df-icon { width: 12px; height: 12px; }
.result-preview__actions .df-icon:has(use[href="#icon-workshop/download"]) { width: 16px; height: 16px; }
.history-new .df-icon, .style-create .df-icon { width: 12px; height: 12px; }
.reference-popover .df-icon, .style-form__cover .df-icon { width: 14px; height: 14px; }
.history-card .card-stats .stat-icon .df-icon { width: 12px; height: 12px; }

/* 风格广场页签：当前页签 16px，下划线与线上 1440 基线同高 */
#style-dialog .style-dialog__head { padding: 15px 24px 12px; }
#style-dialog .style-dialog__close { position: absolute; top: 11px; right: 18px; }
#style-dialog .style-dialog__close .df-icon { width: 14px; height: 14px; }
#style-dialog .style-dialog__footer { padding: 14px 24px 11px; }
#style-dialog .style-dialog__footer .df-btn { min-width: 0; height: 32px; }
#style-dialog .style-dialog__footer .style-cancel { padding: 0 14px; }
#style-dialog .style-dialog__footer .style-confirm { padding: 0 12px; }
#style-dialog .style-tabs { align-items: flex-start; gap: 40px; }
#style-dialog .style-tabs button:not([aria-pressed="true"]) { padding-top: 6px; }
#style-dialog .style-tabs button[aria-pressed="true"] { padding-bottom: 13px; font-size: 16px; }

/* 风格广场工具栏：搜索图标位于输入框内，右侧仅保留刷新（对齐线上 1440 基线） */
#style-dialog .style-toolbar { padding: 12px 24px 20px; }
#style-dialog .style-search { position: relative; }
#style-dialog .style-search input { box-sizing: border-box; height: 32px; padding: 5px 34px 5px 10px; }
#style-dialog .style-search button[aria-label="搜索"] { position: absolute; top: 50%; right: 48px; width: 28px; height: 28px; transform: translateY(-50%); }
#style-dialog .style-search .style-refresh { width: 32px; height: 32px; border: 1px solid var(--df-color-border); border-radius: var(--df-radius-md); }
.history-empty .df-icon--xl { width: 28px; height: 28px; transform: translateY(-3px); }
.history-collapse .df-icon { width: 14px; height: 14px; }

/* ---------- 生成类型 / 模型 / 参数下拉 ---------- */
.ws-select { position: relative; display: inline-flex; }
.ws-select[hidden] { display: none; }
/* 配置栏触发器：线上 .popover-trigger（MessageInput-BXa8SypH.css / data-v-267e4d15）
   height:32px; border-radius:8px; padding:4px 8px; gap:4px; border:1px solid rgba(255,255,255,.1); font-size:14px */
#workshop-form #type-trigger { gap: 4px; width: 98px; min-width: 0; height: 32px; padding: 4px 8px; line-height: 18px; white-space: nowrap; border-color: var(--df-color-fill); border-radius: var(--df-radius-lg); background: var(--df-color-workshop-type-bg); color: var(--df-color-accent); }
#workshop-form #type-trigger .df-icon { width: 16.8px; height: 16.8px; }
#workshop-form .ws-select__trigger.workshop-model, #workshop-form #params-trigger, #workshop-form #mode-trigger { gap: 6px; padding: 6px 10px; border: 0; }
#workshop-form .ws-select__trigger.workshop-model { gap: 4px; height: 32px; padding: 4px 8px; background: transparent; color: var(--df-color-text-strong); }
#workshop-form #params-trigger { padding-right: 14px; padding-left: 14px; }
#workshop-form .workshop-send button { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; padding: 0; position: relative; top: -1px; left: -1px; }
.workshop-send__icon { display: block; width: 32px; height: 32px; }
.workshop-model::before { content: none; }
#workshop-form #params-trigger, #workshop-form #mode-trigger { background: var(--df-color-workshop-params-bg); color: var(--df-color-text-strong); }
#generation-params { padding: 0; border: 0; white-space: nowrap; }
#generation-params .parameter-sound { width: 14px; height: 14px; margin: 0 2px; }
.ws-select__trigger {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border: 1px solid var(--df-color-border-input);
  border-radius: var(--df-radius-md);
  background: var(--df-color-surface-raised);
  color: var(--df-color-text);
  font: inherit;
  cursor: pointer;
}
.ws-select__trigger .df-icon, .ws-option .df-icon { width: 14px; height: 14px; }
.workshop-model .df-icon { width: 16px; height: 16px; }
.workshop-model .model-brand { display: block; flex: none; width: 20px; height: 20px; object-fit: contain; }
.workshop-model .df-icon { color: var(--df-color-primary-hover); }
.workshop-send > span:last-of-type { display: inline-flex; align-items: center; gap: 4px; }
.workshop-send > span:last-of-type .df-icon { width: 14px; height: 14px; }
.workshop-send button .df-icon { width: 18px; height: 18px; }
.workshop-send button.is-generating { opacity: 0.6; cursor: wait; }
.ws-select__trigger[aria-expanded="true"] { border-color: var(--df-color-accent); }
.ws-popover {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 0;
  z-index: var(--df-z-dropdown);
  display: flex;
  flex-direction: column;
  min-width: 200px;
  max-height: 420px;
  padding: var(--df-space-2);
  overflow-y: auto;
  border: 1px solid var(--df-color-divider);
  border-radius: var(--df-radius-lg);
  background: var(--df-color-surface-raised);
  box-shadow: var(--df-shadow-popover);
}
.ws-popover[hidden] { display: none; }
.ws-popover--list { min-width: 220px; }
#workshop-form :is(#type-popover, #model-popover, #mode-popover) { border-radius: var(--df-radius-xl); }
#workshop-form :is(#type-popover, #model-popover, #mode-popover) .ws-option { border-radius: var(--df-radius-lg); }
#workshop-form .ws-option .ws-option__check { display: block; margin-inline-start: auto; visibility: hidden; }
#workshop-form .ws-option[aria-selected="true"] .ws-option__check { visibility: visible; }
/* 模型浮层：2026-11-08 按线上 .el-popper.model-select-popover / .popover-content / .model-item 重写
   （qa/live-css/PromptOptimize-QPU2zxMB.css；几何与配色经 qa/workshop/models/original-image-1440.png 逐像素复核） */
.ws-popover--models { left: -47px; max-height: 300px; min-width: 294px; padding: 0; border: 0; box-shadow: var(--df-shadow-popover-tight); }
.ws-popover--models.is-video { left: -38px; min-width: 247px; }
.ws-popover--models .ws-params__label { display: flex; align-items: center; flex: none; height: 40px; margin: 0; padding: 0 12px; color: var(--df-color-text-label); }
#model-popover .ws-option {
  height: 48px;
  min-height: 48px;
  gap: 8px;
  padding: 0 16px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: var(--df-font-size-xs);
  transition: background-color 0.2s ease;
}
#model-popover .ws-option:hover,
#model-popover .ws-option[aria-selected="true"],
#model-popover .ws-option[aria-disabled="true"]:hover { background: var(--df-color-option-hover); }
#model-popover .ws-option__icon { flex: none; display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border: 1px solid var(--df-color-fill); border-radius: var(--df-radius-lg); }
#model-popover .ws-option__brand { width: 24px; height: 24px; object-fit: contain; }
#model-popover .ws-option__body { flex: 1; display: flex; flex-direction: column; justify-content: center; min-width: 0; height: 38px; }
#model-popover .ws-option__header { display: flex; align-items: center; flex-wrap: nowrap; gap: 6px; }
#model-popover .ws-option__name { color: var(--df-color-text); font-size: var(--df-font-size-sm); font-weight: var(--df-font-weight-semibold); line-height: 18px; white-space: nowrap; }
#model-popover .ws-option[aria-disabled="true"] .ws-option__name,
#model-popover .ws-option[aria-disabled="true"] .ws-option__desc { opacity: 0.5; }
#model-popover .ws-option__desc { display: none; overflow: hidden; color: var(--df-color-text-secondary); font-size: var(--df-font-size-xs); line-height: 18px; text-overflow: ellipsis; -webkit-box-orient: vertical; }
#model-popover .ws-option:hover .ws-option__desc { display: -webkit-box; -webkit-line-clamp: 1; line-clamp: 1; }
#model-popover .ws-option__tag { flex: none; max-width: 72px; height: 18px; overflow: hidden; padding: 0 3px; border-radius: var(--df-radius-sm); font-size: var(--df-font-size-xs); line-height: 18px; text-overflow: ellipsis; vertical-align: middle; white-space: nowrap; }
#model-popover .ws-option__tag--diamond { background: transparent; color: var(--df-color-vip-diamond); }
.ws-option__icon { flex: none; width: 20px; height: 20px; object-fit: contain; }
.ws-option__meta { margin-left: auto; }
/* 行基座改由 components.css 的 .df-popover-row 提供（display/width/padding/hover/字号） */
.ws-option:hover { background-color: var(--df-color-option-hover); }
#type-popover .ws-option:hover,
#model-popover .ws-option:hover,
#mode-popover .ws-option:hover { background-color: var(--df-color-option-hover); }
/* 线上发送按钮为静态图片，无 hover 底色（仅禁用态有余额 tooltip） */
.ws-option:disabled { color: var(--df-color-text-faint); cursor: not-allowed; opacity: 0.55; }
.ws-option:disabled:hover { background: transparent; }
.ws-option__tag--diamond .df-icon { width: 14px; height: 14px; }
/* 类型/模态浮层：线上 .el-popper.type-popover(120) / .mode-popover(100) + .popover-title/.popover-item
   行 41px 通栏、padding 0 12px、gap 6px、hover 与选中同为 #3b404880 且字重 600（浮层底色用 el-popper 主题 #191919） */
#type-popover, #mode-popover { padding: 0; border: 0; border-radius: var(--df-radius-lg); background: var(--df-color-surface-media); box-shadow: var(--df-shadow-popover-list); }
#type-popover { width: 156px; min-width: 156px; padding: var(--df-space-1); border: 1px solid var(--df-color-popover-border); background: var(--df-color-surface); }
#mode-popover { width: 100px; min-width: 100px; }
#type-popover .ws-params__label, #mode-popover .ws-params__label { display: flex; align-items: center; height: 41px; margin: 0; padding: 0 12px; color: var(--df-color-text-label); }
/* 行规格见 components.css 的 .df-popover-row（41px 通栏 / hover 与选中 #3b404880 + 600），此处只保留页面差异 */
#type-popover .ws-option, #mode-popover .ws-option { justify-content: flex-start; }
#type-popover .ws-option .df-icon { flex: none; }
#mode-popover .ws-option .df-icon:not(.ws-option__check) { display: none; }
/* 选中行改由 .df-popover-row[aria-selected="true"] 提供（线上 #3b404880，非紫色填充） */
#model-popover .ws-option[aria-selected="true"] { background: var(--df-color-option-hover); color: var(--df-color-text); }
#model-popover .ws-option[aria-selected="true"] .ws-option__meta, #mode-popover .ws-option[aria-selected="true"] .ws-option__meta { color: var(--df-color-text-faint); }
.ws-option__meta { display: inline-flex; align-items: center; gap: var(--df-space-1); color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }
.ws-option[aria-selected="true"] .ws-option__meta { color: var(--df-color-text-secondary); }
.ws-option__tag { padding: 1px 4px; border-radius: var(--df-radius-xs); background: var(--df-color-tag-deprecated-bg); color: var(--df-color-accent); font-size: var(--df-font-size-xs); line-height: 16px; white-space: nowrap; }
.ws-option__tag--diamond { background: transparent; color: var(--df-color-accent); }
.ws-option__check { flex: none; font-size: var(--df-font-size-xs); }

.ws-popover--params { right: auto; left: 50%; width: 368px; padding: 12px; border: 0; transform: translateX(calc(-50% - 1px)); }
.ws-params__group { display: flex; flex-direction: column; gap: var(--df-space-3); margin-bottom: var(--df-space-3); }
.ws-params__group:last-child { margin-bottom: 0; }
/* 浮层标题：线上 .popover-title 的 color:#a3a6ad */
.ws-params__label { color: var(--df-color-text-label); font-size: var(--df-font-size-xs); }
.ws-params__chips { display: flex; flex-wrap: wrap; gap: 2px; padding: 2px; border-radius: calc(var(--df-radius-lg) + 2px); background: var(--df-color-surface-active); }
#workshop-form .ws-params__chips button {
  flex: 1;
  min-width: 0;
  height: 36px;
  padding: 0 2px;
  border: 0;
  border-radius: var(--df-radius-lg);
  background: transparent;
  color: var(--df-color-text);
  font: inherit;
  font-size: var(--df-font-size-xs);
  white-space: nowrap;
  cursor: pointer;
}
#workshop-form [data-param-group="选择比例"] .ws-params__chips button { padding: 8px 0; font-size: 11px; }
#workshop-form .ws-params__chips button[aria-pressed="true"] { background: var(--df-color-ratio-hover); color: var(--df-color-text); }
#workshop-form .ws-params__chips button:hover { background: var(--df-color-ratio-hover); }
html[data-theme="light"] #workshop-form #params-popover .ws-params__chips {
  background: var(--df-color-surface-raised);
}
html[data-theme="light"] #workshop-form #params-popover .ws-params__chips button {
  color: var(--df-color-text-secondary);
}
html[data-theme="light"] #workshop-form #params-popover .ws-params__chips button:hover {
  background: var(--df-color-surface-hover);
  color: var(--df-color-text);
}
html[data-theme="light"] #workshop-form #params-popover .ws-params__chips button[aria-pressed="true"] {
  background: var(--df-color-surface);
  color: var(--df-color-text-strong);
  font-weight: var(--df-font-weight-semibold);
}
html[data-theme="light"] #workshop-form #params-popover .ws-params__chips button:focus-visible {
  outline: 2px solid var(--df-color-focus-ring);
  outline-offset: -2px;
}
#workshop-form .ws-params__chips[data-grid="true"] { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.ws-params__slider { display: flex; align-items: center; gap: 20px; }
.ws-params__range { flex: 1; display: flex; flex-direction: column; gap: var(--df-space-2); min-width: 0; padding-top: var(--df-space-3); }
.ws-params__range input[type="range"] {
  width: 100%;
  height: 4px;
  margin: 0;
  border: 0;
  border-radius: 2px;
  background: linear-gradient(to right, var(--df-color-range-fill) var(--range-fill, 0%), var(--df-color-range-track) var(--range-fill, 0%));
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}
.ws-params__range input[type="range"]::-webkit-slider-thumb {
  width: 14px;
  height: 14px;
  border: 0;
  border-radius: 50%;
  background: var(--df-color-range-thumb);
  box-shadow: 0 0 4px var(--df-color-mask);
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}
.ws-params__range input[type="range"]::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: 0;
  border-radius: 50%;
  background: var(--df-color-range-thumb);
}
.ws-params__range-scale { display: flex; justify-content: space-between; color: var(--df-color-text); font-size: 11px; line-height: 1; }
.ws-params__duration { display: flex; align-items: flex-end; gap: 8px; }
.ws-params__stepper { display: flex; align-items: stretch; width: 80px; height: 32px; border: 1px solid var(--df-color-range-border); border-radius: var(--df-radius-sm); overflow: hidden; }
.ws-params__stepper:hover,
.ws-params__stepper:focus-within { border-color: var(--df-color-range-border-hover); }
.ws-params__stepper input[type="number"] {
  flex: 1;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--df-color-text-strong);
  font: inherit;
  font-size: var(--df-font-size-sm);
  text-align: center;
  -moz-appearance: textfield;
  appearance: textfield;
}
.ws-params__stepper input[type="number"]::-webkit-outer-spin-button,
.ws-params__stepper input[type="number"]::-webkit-inner-spin-button { margin: 0; -webkit-appearance: none; appearance: none; }
.ws-params__stepper-buttons { display: flex; flex-direction: column; width: 32px; border-left: 1px solid var(--df-color-range-border); }
.ws-params__step { position: relative; flex: 1; padding: 0; border: 0; background: transparent; cursor: pointer; }
.ws-params__step--down { border-top: 1px solid var(--df-color-range-border); }
.ws-params__step::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 5px;
  height: 5px;
  border-top: 1px solid var(--df-color-text-body);
  border-left: 1px solid var(--df-color-text-body);
  transform: translate(-50%, -50%) rotate(45deg);
}
.ws-params__step--down::before { transform: translate(-50%, -50%) rotate(225deg); }
.ws-params__step:hover::before { border-color: var(--df-color-primary-hover); }
.ws-params__suffix { color: var(--df-color-text-dim); font-size: var(--df-font-size-xs); }

/* ---------- 资产选择弹窗：线上三来源 + 多选 ---------- */
.workshop-asset-toolbar { display: flex; align-items: center; gap: var(--df-space-3); margin-bottom: var(--df-space-4); }
.workshop-asset-toolbar .workshop-asset-sources { margin-bottom: 0; }
.workshop-asset-mine { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; color: var(--df-color-text-secondary); font-size: var(--df-font-size-xs); }
.workshop-asset-mine input { margin: 0; accent-color: var(--df-color-primary-hover); }
#workshop-asset-sort {
  height: 32px;
  padding: 0 12px;
  border: 1px solid var(--df-color-border);
  border-radius: var(--df-radius-md);
  background: var(--df-color-surface);
  color: var(--df-color-text-secondary);
  font: inherit;
  font-size: var(--df-font-size-xs);
  cursor: pointer;
}
#workshop-asset-sort[aria-pressed="true"] { border-color: var(--df-color-accent); color: var(--df-color-text); }
.workshop-asset-empty { padding: 48px 0; color: var(--df-color-text-faint); text-align: center; font-size: var(--df-font-size-sm); }
.workshop-asset-empty[hidden] { display: none; }
.workshop-asset-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--df-space-3);
  margin-top: var(--df-space-4);
  padding-top: var(--df-space-4);
  border-top: 1px solid var(--df-color-divider);
}
#workshop-asset-count { margin-right: auto; color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); }

.mention-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; margin: 0; padding: 0; color: var(--df-color-text); font-size: var(--df-font-size-xs); text-align: center; }
.mention-empty img { width: 62px; height: auto; }

/* 模型选项副标题与会员提示（2026-11-07 线上） */
.ws-option__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ws-option__desc { color: var(--df-color-text-faint); font-size: var(--df-font-size-xs); line-height: 16px; }
.ws-option[aria-disabled="true"] { cursor: pointer; }
.ws-option[aria-disabled="true"]:hover { background: var(--df-color-surface-hover); }
.workshop-model-toast {
  position: absolute;
  bottom: calc(100% + 12px);
  left: 50%;
  z-index: var(--df-z-dropdown);
  display: inline-flex;
  gap: 4px;
  padding: 8px 14px;
  border-radius: var(--df-radius-lg);
  background: var(--df-color-panel);
  box-shadow: var(--df-shadow-popover);
  color: var(--df-color-text-secondary);
  font-size: var(--df-font-size-xs);
  white-space: nowrap;
  transform: translateX(-50%);
}
.workshop-model-toast[hidden] { display: none; }
.workshop-model-toast a { color: var(--df-color-accent); text-decoration: none; }


/* 与 2026-11-09 线上 MessageInput 量测一致的工具栏：32px、细线框、8px 圆角。 */
#workshop-form #workshop-editor { resize: none; }
html:not([data-theme="light"]) .workshop-page .right-container { font-family: var(--df-font-family-ui); }
html:not([data-theme="light"]) #workshop-form :is(#model-trigger,#params-trigger,#mode-trigger) {
  height: 32px; padding: 4px 8px; gap: 4px;
  border: 1px solid var(--df-color-fill); border-radius: var(--df-radius-lg);
  background: transparent; font-size: var(--df-font-size-md);
}
html:not([data-theme="light"]) #model-popover .ws-option__name { font-size: var(--df-font-size-xs); }
html:not([data-theme="light"]) .workshop-page #workshop-form {
  border-radius: var(--df-radius-2xl); box-shadow: var(--df-shadow-workshop-form);
}
html:not([data-theme="light"]) #workshop-form #type-trigger { width: auto; }
html:not([data-theme="light"]) .workshop-config { gap: var(--df-space-3); }
html:not([data-theme="light"]) #params-select { margin-left: 0; }
/* 同会话 1440 基线的输入区右边界为 x1390；仅校正深色展开态的 2px。 */
/* 深色历史打开：右侧仍须避让快捷栏（对标 demo 74px，勿用 50 导致叠压） */
html:not([data-theme="light"]) .workshop-page .workshop-history:not([hidden]) + .right-container .right { padding-right: 74px; padding-left: 48px; }
.fullscreen-preview__media-placeholder { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; width: 100%; height: 100%; color: var(--df-color-text-secondary); font-size: 24px; line-height: 36px; }
.fullscreen-preview__media-placeholder--video { gap: 16px; font-size: 14px; line-height: 22px; }
.fullscreen-preview__media-placeholder--video > .df-icon { width: 112px; height: 112px; color: var(--df-color-text-secondary); }
.fullscreen-preview__media-placeholder--video span { max-width: 80%; text-align: center; word-break: break-all; }
.fullscreen-preview__media-placeholder--video .transcoding-title { color: var(--df-color-text-on-card); font-size: 14px; font-weight: 600; line-height: 24px; }
.fullscreen-preview__media-placeholder--video .transcoding-desc { color: var(--df-color-text-label); font-size: 12px; line-height: 1.6; }
.error-retry { padding: 0; border: 0; background: transparent; color: var(--df-color-info); font-size: 12px; line-height: 18px; cursor: pointer; }

html[data-theme="light"] .workshop-page .right-bg:has(.page-title:not([hidden])) #workshop-form.df-composer-shell {
  background-image: radial-gradient(ellipse 65% 90% at 48% 20%, color-mix(in srgb, var(--df-color-workshop-glow) 17%, transparent), transparent);
}
html[data-theme="light"] #workshop-form #type-trigger {
  background-color: var(--df-color-surface-raised);
  color: var(--df-color-text-strong);
}
html[data-theme="light"] #workshop-form #type-trigger:is(:hover,[aria-expanded="true"]) {
  background-color: var(--df-color-surface-active);
}
html[data-theme="light"] #workshop-form :is(#model-popover,#type-popover,#mode-popover) .ws-option[aria-selected="true"] {
  background-color: var(--df-color-surface-raised);
  color: var(--df-color-text-strong);
}
