.ticket-collage-dialog {
  box-sizing: border-box;
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: #0c1719;
  color: #edf5f3;
  padding: 0;
  box-shadow: 0 18px 56px rgba(0, 0, 0, 0.68);
}

.ticket-collage-dialog[open] { display: block; }
.ticket-collage-dialog::backdrop { background: rgba(3, 8, 12, 0.86); }
.ticket-collage-shell { display: grid; height: 100%; grid-template-rows: 50px minmax(0, 1fr); }

.ticket-collage-header {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid #557a78;
  background: #173d39;
  padding: 6px 8px 6px 14px;
}

.ticket-collage-header > div:first-child { display: grid; min-width: 0; gap: 2px; }
.ticket-collage-header strong { color: #ffe368; font-size: 17px; }
.ticket-collage-header span { overflow: hidden; color: #b9d0ca; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.ticket-collage-header__actions { display: flex; flex: 0 0 auto; gap: 5px; }

.ticket-collage-dialog button,
.collage-file-button {
  min-height: 32px;
  border: 1px solid #638296;
  border-radius: 3px;
  background: #31596d;
  color: #fff;
  padding: 0 10px;
  font-weight: 800;
  cursor: pointer;
}

.ticket-collage-dialog button:hover,
.collage-file-button:hover { border-color: #92c4d8; background: #3d7189; }
.ticket-collage-dialog button[aria-pressed="true"] { border-color: #ff8189; background: #bd3140; }
.ticket-collage-dialog .collage-mode-switch button[aria-pressed="true"] { border-color: #e7c95e; background: #6c5921; color: #fff2aa; }
.ticket-collage-dialog button.is-export { border-color: #c0a04e; background: #725f27; color: #fff4bd; }
.ticket-collage-dialog button.is-danger { border-color: #c76670; background: #842f3b; }
.ticket-collage-dialog button:disabled { opacity: 0.42; cursor: not-allowed; }

.ticket-collage-workspace {
  display: grid;
  min-width: 0;
  min-height: 0;
  grid-template-columns: 328px minmax(0, 1fr);
  overflow: hidden;
}

.ticket-collage-sidebar {
  min-width: 0;
  min-height: 0;
  overflow-y: auto;
  border-right: 1px solid #3f5e5b;
  background: #112321;
  padding: 7px;
  scrollbar-width: thin;
}

.collage-tool-section {
  display: grid;
  gap: 7px;
  margin-bottom: 7px;
  border: 1px solid #3f5d59;
  border-radius: 4px;
  background: #172d2a;
  padding: 8px;
}

.collage-section-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.collage-section-title strong { color: #ffe16a; font-size: 13px; }
.collage-section-title span,
.collage-section-title output { color: #9fc1ba; font-size: 10px; }
.collage-tool-section label { display: grid; gap: 4px; color: #d8e7e3; font-size: 11px; font-weight: 800; }
.collage-tool-section p { margin: 0; color: #abc0bb; font-size: 10px; line-height: 1.55; }

.collage-tool-section input:not([type="color"]):not([type="range"]),
.collage-tool-section select,
.collage-tool-section textarea {
  width: 100%;
  min-width: 0;
  border: 1px solid #5a777c;
  border-radius: 3px;
  background: #e9eff0;
  color: #17252b;
  padding: 6px 7px;
  font: 700 12px/1.45 "Microsoft YaHei", sans-serif;
  resize: vertical;
}

.collage-file-button { position: relative; display: grid; min-height: 38px; overflow: hidden; place-items: center; background: #23724f; border-color: #63ad84; }
.collage-mode-section { border-color: #796a39; background: #182b29; }
.collage-mode-section p { margin: 7px 0 0; color: #c9d8d4; font-size: 10px; line-height: 1.55; }
.collage-mode-switch { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ticket-collage-dialog .collage-file-button input[type="file"] {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  border: 0 !important;
  padding: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
  white-space: nowrap !important;
}
.collage-material-categories,
.collage-material-grid,
.collage-custom-sticker-panel { position: relative; isolation: isolate; z-index: 2; }
.collage-inline-actions,
.collage-tool-grid,
.collage-segmented,
.collage-swatches { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.collage-tool-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.collage-segmented { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.collage-inline-actions button,
.collage-tool-grid button,
.collage-segmented button { min-width: 0; min-height: 29px; padding: 0 4px; font-size: 11px; }
.collage-crop-actions { display: grid; grid-column: 1 / -1; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; margin-top: 4px; }
.collage-crop-actions { display: grid; }
.collage-crop-actions button { min-width: 0; min-height: 31px; padding: 0 4px; font-size: 11px; font-weight: 900; }
.collage-crop-actions .collage-workflow-compat-command { display: inline-flex !important; }
.collage-workflow-compat-command { display: none !important; }
.collage-crop-actions [data-collage-command="apply-crop"] { border-color: #e7c95e; background: #725f27; color: #fff4bd; }
.collage-crop-actions [data-collage-command="cancel-crop"] { border-color: #c76670; background: #842f3b; color: #fff0ef; }
.collage-crop-hint { grid-column: 1 / -1; color: #ffd75d; font-size: 10px; line-height: 1.35; text-align: center; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-crop-actions { display: none !important; }
.collage-workflow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; align-items: stretch; margin: 5px 0 4px; padding: 5px 6px; background: #102725; border: 1px solid #355e57; border-radius: 5px; }
.collage-workflow strong { grid-column: 1 / -1; display: flex; align-items: center; justify-content: flex-start; min-height: 20px; color: #ffe06b; font-size: 11px; white-space: nowrap; }
.collage-workflow button { min-width: 0; min-height: 30px; padding: 0 3px; color: #ecf7f3; background: #24534d; border: 1px solid #5d9b8c; border-radius: 7px; font-size: 10px; font-weight: 800; line-height: 1; white-space: nowrap; writing-mode: horizontal-tb; overflow: visible; text-overflow: clip; }
.collage-workflow button:hover, .collage-workflow button[aria-pressed="true"] { background: #9b792a; border-color: #ffe06b; color: #fff8cc; }
.collage-workflow button:active { transform: translateY(1px); }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-workflow > [data-collage-command="upload-images"] { grid-column: span 1; }
.collage-image-brightness-control { display: grid; grid-template-columns: auto minmax(42px, 1fr) minmax(34px, auto) minmax(42px, 1fr); align-items: center; gap: 4px; min-width: 0; color: #d8e7e3; font-size: 10px; font-weight: 800; white-space: nowrap; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-image-brightness-control { grid-column: span 2; }
.collage-image-brightness-control button { width: 100%; min-width: 42px; min-height: 28px; padding: 0; color: #ecf7f3; background: #24534d; border: 1px solid #5d9b8c; border-radius: 4px; font-size: 15px; font-weight: 900; line-height: 1; }
.collage-image-brightness-control button:hover { background: #9b792a; border-color: #ffe06b; color: #fff8cc; }
.collage-image-brightness-control output { color: #ffd75d; min-width: 28px; text-align: right; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-workflow-view-actions { grid-column: 1 / -1; }
.collage-workflow-layout-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; align-items: stretch; margin: 0 0 5px; padding: 4px 6px; background: #102725; border: 1px solid #355e57; border-top: 0; border-radius: 0 0 5px 5px; }
.collage-workflow-layout-row button { min-width: 0; min-height: 29px; padding: 0 2px; color: #ecf7f3; background: #24534d; border: 1px solid #5d9b8c; border-radius: 7px; font-size: 10px; font-weight: 800; line-height: 1; white-space: nowrap; overflow: visible; text-overflow: clip; }
.collage-workflow-layout-row button:hover, .collage-workflow-layout-row button[aria-pressed="true"] { background: #9b792a; border-color: #ffe06b; color: #fff8cc; }
.collage-workflow-layout-row button:active { transform: translateY(1px); }
.collage-layout-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; margin: 0 0 6px; padding: 4px 6px; background: #102725; border: 1px solid #355e57; border-top: 0; border-radius: 0 0 5px 5px; }
.collage-layout-actions button { min-width: 0; min-height: 29px; padding: 0 2px; color: #ecf7f3; background: #24534d; border: 1px solid #5d9b8c; border-radius: 7px; font-size: 10px; font-weight: 800; line-height: 1; white-space: nowrap; overflow: visible; text-overflow: clip; }
.collage-layout-actions button:hover { background: #9b792a; border-color: #ffe06b; color: #fff8cc; }
.collage-layout-actions button:disabled { opacity: .45; cursor: not-allowed; }
.collage-workflow-settings { margin: 0 0 6px; padding: 6px; background: #102725; border: 1px solid #355e57; border-radius: 5px; color: #ecf7f3; }
.collage-workflow-settings-title { color: #ffe06b; font-size: 12px; font-weight: 900; margin-bottom: 5px; }
.collage-workflow-settings-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; align-items: start; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-workflow-settings-grid > .collage-frame-width-setting { display: none; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-workflow-settings-grid > .collage-header-footer-row { display: none; }
.collage-workflow-settings label { display: flex; flex-direction: column; gap: 3px; min-width: 0; color: #d8e7e3; font-size: 10px; font-weight: 800; }
.collage-workflow-settings input, .collage-workflow-settings textarea { width: 100%; min-width: 0; box-sizing: border-box; color: #172523; background: #f2f7f4; border: 1px solid #6c9a8e; border-radius: 4px; font: inherit; }
.collage-workflow-settings input[type="color"] { height: 28px; padding: 1px; }
.collage-workflow-settings input[type="number"] { height: 28px; padding: 3px 5px; }
.collage-workflow-settings textarea { min-height: 38px; resize: vertical; padding: 4px; }
.collage-workflow-undo { margin-top: 6px; width: 100%; min-height: 29px; color: #fff8cc; background: #24534d; border: 1px solid #5d9b8c; border-radius: 5px; font-size: 11px; font-weight: 900; }
.collage-workflow-undo:disabled { opacity: .45; cursor: not-allowed; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-tool-section[hidden],
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-address-privacy[hidden] { display: none !important; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-workflow-layout-row:empty,
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-layout-actions:empty { display: none !important; }
.collage-text-settings, .collage-workflow-custom-stamp, .collage-workflow-stamp-presets { display: grid; gap: 5px; margin-top: 6px; padding: 6px; border-top: 1px solid #49665f; color: #d8e7e3; font-size: 10px; }
.collage-text-settings[hidden], .collage-workflow-custom-stamp[hidden], .collage-workflow-stamp-presets[hidden] { display: none; }
.collage-text-settings label, .collage-workflow-custom-stamp input { width: 100%; box-sizing: border-box; }
.collage-text-settings select, .collage-workflow-custom-stamp input { min-height: 28px; border: 1px solid #6c9a8e; border-radius: 4px; background: #f2f7f4; color: #172523; }
.collage-text-setting-controls { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; align-items: end; }
.collage-text-setting-controls > button { min-width: 0; min-height: 28px; padding: 3px 4px; border: 1px solid #6c9a8e; border-radius: 4px; background: #24534d; color: #ecf7f3; font-size: 10px; font-weight: 800; white-space: nowrap; }
.collage-text-setting-controls > button[aria-pressed="true"] { border-color: #ffe06b; background: #9d741c; color: #fff8cc; box-shadow: 0 0 0 1px #ffe06b inset; }
.collage-text-setting-color { display: grid !important; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 5px; width: 100%; }
.collage-text-setting-color input[type="color"] { width: 100%; min-width: 0; height: 30px; box-sizing: border-box; border: 1px solid #6c9a8e; border-radius: 4px; background: #f2f7f4; padding: 2px; }
.collage-header-footer-height-debug { display: grid; grid-column: 1 / -1; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 5px; align-items: end; }
.collage-header-footer-height-debug .collage-header-footer-height { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 5px; white-space: nowrap; }
.collage-header-footer-height-debug .collage-header-footer-height input[type="range"] { width: 100%; min-width: 0; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-color-opacity-row { display: grid !important; grid-column: 1 / -1; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 5px; align-items: end; width: 100%; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-color-opacity-row > .collage-text-setting-color,
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-color-opacity-row > .collage-text-opacity { grid-column: auto; min-width: 0; width: auto !important; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-color-opacity-row > .collage-text-setting-color { width: auto !important; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-color-opacity-row > .collage-text-opacity { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 5px; width: 100%; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-color-opacity-row > .collage-text-opacity input[type="range"] { width: 100%; min-width: 0; }
.collage-text-setting-source[hidden] { display: none; }
.collage-text-setting-source[data-text-setting-source="font"] label { width: 100%; }
.collage-text-setting-source[data-text-setting-source="background"] { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 5px; }
.collage-text-setting-source[data-text-setting-source="background"][hidden] { display: none; }
.collage-text-setting-source[data-text-setting-source="frame"] { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 5px; align-items: end; }
.collage-text-setting-source[data-text-setting-source="frame"][hidden] { display: none; }
.collage-text-setting-source[data-text-setting-source="frame"] > label { display: flex; flex-direction: column; gap: 3px; }
.collage-text-setting-source[data-text-setting-source="frame"] > .collage-frame-style-setting { order: 1; }
.collage-text-setting-source[data-text-setting-source="frame"] > .collage-frame-width-setting { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 5px; order: 2; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-setting-source[data-text-setting-source="background"] { display: none !important; }
.collage-text-setting-source[data-text-setting-source="canvas"] { min-height: 28px; }
.collage-canvas-header-footer-settings { display: grid; gap: 5px; }
.collage-canvas-header-footer-row { display: grid; grid-template-columns: 24px minmax(50px, 1fr) 58px 36px; gap: 4px; align-items: center; }
.collage-canvas-header-footer-row > strong { color: #ffe06b; font-size: 10px; white-space: nowrap; }
.collage-canvas-header-footer-row > input[type="text"],
.collage-canvas-header-footer-row > select,
.collage-canvas-header-footer-row > input[type="number"] { width: 100%; min-width: 0; height: 28px; box-sizing: border-box; border: 1px solid #6c9a8e; border-radius: 4px; background: #f2f7f4; color: #172523; font: 700 10px/1.2 "Microsoft YaHei", sans-serif; }
.collage-canvas-header-footer-row > input[type="text"] { padding: 3px 4px; }
.collage-canvas-header-footer-row > select,
.collage-canvas-header-footer-row > input[type="number"] { padding: 2px; }
.collage-canvas-header-footer-colors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; }
.collage-canvas-header-footer-colors label,
.collage-header-footer-colors label { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 5px; min-width: 0; color: #d8e7e3; font-size: 10px; font-weight: 800; }
.collage-canvas-header-footer-colors input[type="color"],
.collage-header-footer-colors input[type="color"] { width: 100%; height: 28px; min-width: 24px; box-sizing: border-box; padding: 1px; }
.collage-canvas-header-footer-heights { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; }
.collage-canvas-header-footer-height { display: grid; grid-template-columns: auto minmax(0, 1fr) 28px; align-items: center; gap: 3px; min-width: 0; color: #d8e7e3; font-size: 9px; white-space: nowrap; }
.collage-canvas-header-footer-height input[type="range"] { width: 100%; min-width: 0; }
.collage-canvas-header-footer-height output { color: #ffe16a; text-align: right; }
.collage-text-content-font-row { display: grid; grid-template-columns: minmax(0, 72%) minmax(0, 28%); gap: 5px; align-items: end; }
.collage-text-content-font-row > label { min-width: 0; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-content-font-row > label:nth-child(2) { justify-self: end; width: 100%; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-content-font-row > label:nth-child(2) select { width: 90%; margin-left: auto; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-settings { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-settings > .collage-text-setting-controls,
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-text-settings > .collage-text-setting-source { grid-column: 1 / -1; }
.collage-workflow-stamp-presets > div { display: grid; grid-template-rows: repeat(2, minmax(0, 1fr)); grid-auto-flow: column; grid-auto-columns: 82px; gap: 4px; max-width: 100%; overflow-x: auto; overflow-y: hidden; padding-bottom: 3px; scrollbar-width: thin; }
.collage-workflow-stamp-presets button { display: grid; min-width: 82px; gap: 2px; place-items: center; min-height: 52px; padding: 3px; color: #ecf7f3; background: #24534d; border: 1px solid #5d9b8c; border-radius: 5px; font-size: 9px; }
.collage-workflow-stamp-presets i { display: grid; width: 22px; height: 22px; place-items: center; border-radius: 50%; background: #9d2530; color: #ffe06b; font-style: normal; font-weight: 900; }
.collage-workflow-stamp-presets button > img { width: 54px; height: 32px; border-radius: 4px; background: transparent; object-fit: cover; }
.collage-workflow-stamp-presets button small { color: #b9d7cd; font-size: 8px; line-height: 1; }
.collage-workflow-stamp-presets > span { color: #9fc5b9; font-size: 9px; }
.collage-workflow-custom-stamp input { padding: 4px 6px; }
.collage-workflow-custom-stamp button { width: 100%; min-height: 29px; }
.collage-mobile-text-settings { display: grid; gap: 5px; margin-top: 6px; padding: 6px; border: 1px solid #355e57; border-radius: 5px; background: #102725; }
.collage-mobile-text-settings > strong { color: #ffe06b; font-size: 12px; font-weight: 900; }
.collage-mobile-text-settings[hidden] { display: none; }
/* 框内行横向两列（标签|控件），压缩到四项免滚动放进手机抽屉 */
.collage-mobile-text-settings label { grid-template-columns: 62px minmax(0, 1fr); align-items: center; gap: 6px; }
.collage-mobile-text-settings input[type="color"] { height: 30px; padding: 2px; border: 1px solid #5a777c; border-radius: 3px; background: #e9eff0; }
/* 手机端「拼图设置」框与内嵌文字设置子组永不显示：设置已拆进各工具专属面板，防 hidden 粘性残留与横屏同屏 */
.is-mobile-collage-editor .collage-workflow-settings { display: none !important; }
.is-mobile-collage-editor .collage-text-settings { display: none !important; }
.is-mobile-collage-editor .collage-workflow-stamp-presets, .is-mobile-collage-editor .collage-workflow-custom-stamp { display: none !important; }
.is-top-controls-relocated .ticket-collage-stage-wrap { grid-template-rows: minmax(0, 1fr); }
.collage-command-center { display: grid; grid-template-columns: repeat(3, 91px); gap: 4px; justify-content: start; }
.collage-command-center .collage-section-title { grid-column: 1 / -1; }
.collage-command-center > button,
.collage-command-center > label { min-width: 0; width: auto; }
.collage-command-center > label { display: flex; align-items: center; justify-content: center; gap: 5px; color: #d3e2de; font-size: 11px; font-weight: 800; }
.collage-command-center > label input[type="range"] { min-width: 70px; width: 100%; }
.collage-command-center > #ticketCollageStatus { grid-column: 1 / -1; color: #ffd75d; font-size: 11px; line-height: 1.3; }
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="mosaic"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="text"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="stamp"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="frame"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="crop"] { display: none; }
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="mosaic"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="text"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="stamp"],
.is-top-controls-relocated .collage-tool-section[data-collage-workflow-panel="annotation"] .collage-tool-grid [data-collage-tool="frame"] { display: none; }
.is-top-controls-relocated .collage-command-center > button,
.is-top-controls-relocated .collage-command-center > label { width: 91px; min-width: 91px; min-height: 32px; height: 32px; box-sizing: border-box; }
.is-top-controls-relocated .collage-command-center > label { padding: 0 5px; }
.is-top-controls-relocated .collage-command-center > button,
.is-top-controls-relocated .collage-workflow button,
.is-top-controls-relocated .collage-mode-switch button,
.is-top-controls-relocated .collage-tool-section button { white-space: nowrap; overflow: visible; text-overflow: clip; line-height: 1; font-size: 10px; }
.is-top-controls-relocated .collage-mode-switch button { width: 91px; min-width: 91px; height: 32px; min-height: 32px; }
.is-top-controls-relocated .collage-command-center > button { padding: 0 4px; }
.ticket-collage-dialog.is-store-assistant-embedded:not(.is-mobile-collage-editor) .ticket-collage-stage-wrap { grid-template-rows: 38px minmax(0, 1fr); }
.ticket-collage-dialog.is-store-assistant-embedded:not(.is-mobile-collage-editor) .collage-workflow button,
.ticket-collage-dialog.is-store-assistant-embedded:not(.is-mobile-collage-editor) .collage-workflow-layout-row button,
.ticket-collage-dialog.is-store-assistant-embedded:not(.is-mobile-collage-editor) .collage-layout-actions button { min-width: 0; padding: 0 3px !important; overflow: visible !important; text-overflow: clip !important; white-space: nowrap; font-size: 12px !important; font-weight: 900; }
@media (max-width: 640px) { .collage-workflow { grid-template-columns: repeat(3, minmax(0, 1fr)); } .collage-workflow strong { min-height: 24px; } .collage-workflow button { min-height: 34px; padding: 0 4px; font-size: 11px; } .collage-workflow-layout-row { grid-template-columns: repeat(3, minmax(0, 1fr)); padding-left: 4px; padding-right: 4px; } .collage-workflow-layout-row button { min-height: 34px; padding: 0 3px; font-size: 10px; } .collage-workflow-settings-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .collage-workflow-settings-grid label:nth-child(4), .collage-workflow-settings-grid label:nth-child(5) { grid-column: 1 / -1; } }
.collage-custom-columns { display: grid; grid-template-columns: minmax(0, 1fr) 74px; align-items: center; gap: 5px; color: #d8e7e3; font-size: 11px; font-weight: 800; }
.collage-custom-columns input { width: 100%; min-width: 0; box-sizing: border-box; }
.collage-custom-columns span { grid-column: 1 / -1; color: #9fc1ba; font-size: 10px; font-weight: 600; line-height: 1.4; }

.collage-swatches button { display: flex; min-width: 0; align-items: center; justify-content: center; gap: 4px; padding: 0 5px; font-size: 10px; }
.collage-swatches span { width: 14px; height: 14px; border: 1px solid #d9e4e1; border-radius: 2px; background: var(--swatch); }
.collage-background-controls { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
.collage-background-controls label { text-align: center; }
.collage-background-controls input[type="color"] { width: 100%; height: 30px; border: 1px solid #658088; border-radius: 3px; background: #243b40; padding: 2px; }
.collage-range-controls { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; }
.collage-range-controls label { grid-template-columns: auto minmax(0, 1fr) 24px; align-items: center; gap: 4px; }
.collage-range-controls input { width: 100%; min-width: 0; }
.collage-range-controls output { color: #ffe16a; font-size: 10px; text-align: right; }
.collage-property-row { display: grid; grid-template-columns: 1fr 1fr 54px; gap: 5px; }
.collage-property-row input[type="color"] { width: 100%; height: 32px; border: 1px solid #658088; border-radius: 3px; background: #243b40; padding: 2px; }
.collage-property-row--colors { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 1fr); align-items: end; }
.collage-sticker-upload-control { display: grid; min-width: 0; gap: 4px; }
.collage-property-row--colors input[type="range"] { width: 100%; min-width: 0; margin: 6px 0; }
.collage-sticker-file { min-height: 31px; background: #4c496e; border-color: #7771a0; font-size: 11px; }
.collage-sticker-name { overflow: hidden; color: #b8c9c5; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-property-row--colors {
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-sticker-upload-control {
  display: flex;
  min-height: 32px;
  align-items: center;
  gap: 4px;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-sticker-file {
  width: 80px;
  min-width: 76px;
  box-sizing: border-box;
  padding: 0 4px;
  white-space: nowrap;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-sticker-name {
  min-width: 0;
  flex: 1 1 auto;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-property-row--colors > label:has(#ticketCollageStampColor),
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-property-row--colors > label:has(#ticketCollageOpacity) {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-property-row--colors > label:has(#ticketCollageStampColor) input[type="color"] {
  width: 50px;
  min-width: 0;
  justify-self: end;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-property-row--colors > label:has(#ticketCollageOpacity) input[type="range"] {
  width: 100%;
  min-width: 0;
  margin: 0;
}
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-state-sticker { display: none !important; }
.collage-material-categories { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 4px; }
.collage-material-categories button[aria-selected="true"] { border-color: #ffe078; background: #84620c; color: #fff5b4; }
.collage-material-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 360px; gap: 5px; overflow-y: auto; }
.collage-material-grid > button { display: flex; min-width: 0; min-height: 62px; align-items: center; gap: 8px; padding: 5px; text-align: left; }
.collage-material-grid i { display: grid; width: 42px; height: 42px; flex: 0 0 42px; place-items: center; border: 2px solid var(--material-accent, #ffe078); border-radius: 12px; background: var(--material, #8b2635); color: var(--material-accent, #ffe078); font-size: 18px; font-style: normal; font-weight: 900; }
.collage-material-grid span { display: grid; min-width: 0; gap: 2px; }
.collage-material-grid small { overflow: hidden; color: #a9bbb5; font-size: 9px; text-overflow: ellipsis; white-space: nowrap; }
.collage-custom-sticker-panel { display: grid; gap: 6px; margin-top: 8px; border-top: 1px solid #49665f; padding-top: 8px; }
.collage-custom-sticker-panel > strong { color: #ffe06b; }
.collage-text-nudge { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 3px; }
.collage-text-nudge button { min-width: 0; min-height: 29px; padding: 0 2px; font-size: 9px; }
.collage-material-card { display: grid; min-width: 0; gap: 4px; border: 1px solid #4b6a69; border-radius: 5px; background: #122526; padding: 5px; }
.collage-material-card img { width: 100%; height: 92px; border-radius: 3px; background: transparent; object-fit: cover; object-position: center; }
.collage-material-card.is-real-sticker img { display: block; aspect-ratio: 1 / 1; height: auto; }
.collage-material-card p { height: 92px; overflow: hidden; margin: 0; border-radius: 3px; background: #eef1ed; padding: 7px; color: #243234; font-size: 11px; line-height: 1.5; }
.collage-material-card b { overflow: hidden; color: #f1f7f4; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.collage-material-card > small { color: #9db2ad; font-size: 9px; }
.collage-material-card > div { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px; }
.collage-material-card button { min-width: 0; min-height: 28px; padding: 0 3px; font-size: 9px; }

.collage-thumbnails {
  display: flex;
  min-height: 54px;
  gap: 5px;
  overflow-x: auto;
  color: #8ea9a3;
  font-size: 10px;
  scrollbar-width: thin;
}
.collage-address-privacy { display: grid; gap: 5px; border-top: 1px solid #42645f; padding-top: 6px; }
.collage-address-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.collage-address-actions button,
.collage-address-actions input { min-width: 0; min-height: 31px; box-sizing: border-box; }
.collage-address-actions .is-auto-mosaic { border-color: #dfbc62; background: #6f5623; color: #fff1a8; font-weight: 900; }
.collage-address-actions .is-auto-text { border-color: #53c59b; background: #185c4c; color: #eafff7; font-weight: 900; }
.collage-address-actions input { grid-column: 1 / -1; border-color: #769e92; background: #edf4f1; color: #122724; padding: 0 7px; font-weight: 800; }
.collage-privacy-style { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.collage-privacy-style label { display: flex; align-items: center; gap: 4px; min-height: 28px; color: #d6e2de; font-size: 10px; font-weight: 700; }
.collage-privacy-style .is-privacy-font { grid-column: 1 / -1; }
.collage-privacy-style label > span { flex: 0 0 31px; }
.collage-privacy-style select, .collage-privacy-style input[type="color"] { flex: 1; min-width: 0; min-height: 26px; box-sizing: border-box; border: 1px solid #709a90; border-radius: 3px; background: #edf4f1; color: #102522; padding: 0 4px; font: 800 12px/1.2 "Microsoft YaHei", sans-serif; }
.collage-privacy-style input[type="color"] { padding: 2px; }
.collage-requested-privacy { display: grid; gap: 4px; border: 1px solid #496c65; border-radius: 4px; background: #102522; padding: 6px; }
.collage-requested-privacy > strong { color: #ffe06b; font-size: 12px; }
.collage-requested-privacy textarea { min-height: 66px; resize: vertical; border: 1px solid #709a90; border-radius: 3px; background: #edf4f1; color: #102522; padding: 6px; font: 800 12px/1.45 "Microsoft YaHei", sans-serif; }
.collage-requested-actions { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.collage-requested-actions button { min-width: 0; min-height: 31px; }
.collage-requested-actions [data-collage-address="requested-mosaic"] { border-color: #d7af4d; background: #735719; color: #fff2ba; }
.collage-requested-actions [data-collage-address="requested-text"] { border-color: #55b893; background: #17604e; color: #effff9; }
.collage-requested-actions [data-collage-address="manual-locate"] { border-color: #df795f; background: #713429; color: #fff0e9; }
.collage-privacy-target-reports { display: grid; gap: 3px; color: #d6e2de; font-size: 10px; }
.collage-privacy-target-report { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(132px, auto); align-items: center; gap: 5px; border-radius: 3px; background: #19322e; padding: 4px 6px; }
.collage-privacy-target-report button { min-height: 25px; padding: 0 7px; font-size: 10px; }
.collage-privacy-target-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; }
.collage-privacy-target-buttons [data-confirm-privacy-index] { border-color: #55b893; background: #17604e; color: #effff9; }
.collage-privacy-target-report.is-found b { color: #82e5ae; }
.collage-privacy-target-report.is-missing b { color: #ff9a7f; }
.collage-address-candidates { display: grid; max-height: 138px; gap: 4px; overflow-y: auto; color: #b9cac6; font-size: 10px; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-address-actions,
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-privacy-style,
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-address-candidates,
.ticket-collage-dialog:not(.is-mobile-collage-editor) .collage-address-privacy > p { display: none !important; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) [data-collage-address][aria-busy="true"],
.ticket-collage-dialog:not(.is-mobile-collage-editor) [data-collage-workflow-address="auto-text"][aria-busy="true"],
.ticket-collage-dialog.is-mobile-collage-editor [data-collage-workflow-address="auto-text"][aria-busy="true"] {
  opacity: 1;
  animation: desktop-auto-privacy-pulse .72s ease-in-out infinite;
}
@keyframes desktop-auto-privacy-pulse {
  0%, 100% {
    border-color: #ffe36e;
    background-color: #876619;
    color: #fff4b8;
    filter: brightness(1.08) saturate(1.45);
    box-shadow: 0 0 0 3px rgba(255, 224, 107, .48);
  }
  50% {
    border-color: #ff6458;
    background-color: #9d332b;
    color: #fff0eb;
    filter: brightness(1.16) saturate(1.65);
    box-shadow: 0 0 0 3px rgba(255, 93, 80, .5);
  }
}
.collage-address-candidate { display: grid; grid-template-columns: 23px 72px minmax(0, 1fr) 42px; align-items: center; gap: 4px; border: 1px solid #486761; border-radius: 3px; background: #102321; padding: 4px; }
.collage-address-candidate input { width: 18px !important; height: 18px; }
.collage-address-candidate b { color: #ffe06b; font-size: 10px; }
.collage-address-candidate span { overflow: hidden; color: #eef5f2; text-overflow: ellipsis; white-space: nowrap; }
.collage-address-candidate small { color: #83d8aa; text-align: right; }

.collage-thumbnail {
  position: relative;
  flex: 0 0 54px;
  height: 54px;
  overflow: hidden;
  border: 2px solid #4c696b;
  border-radius: 3px;
  background: #0b1719;
  padding: 0;
}

.collage-thumbnail[aria-pressed="true"] { border-color: #ffdd53 !important; background: #263833 !important; }
.collage-thumbnail img { width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.collage-thumbnail small { position: absolute; right: 1px; bottom: 1px; border-radius: 2px; background: rgba(0,0,0,.75); padding: 1px 3px; font-size: 9px; }
.collage-thumbnail-delete { position: absolute; top: 1px; right: 1px; z-index: 2; display: grid; width: 18px; height: 18px; min-height: 18px; box-sizing: border-box; place-items: center; border: 1px solid #ffc0c0; border-radius: 50%; background: #8d2630; color: #fff; cursor: pointer; font: 900 13px/1 Arial, sans-serif; }
.collage-header-footer-properties { align-items: end; }
.collage-header-footer-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(120px, 26%) minmax(72px, 10%); align-items: end; gap: 7px; }
.collage-header-footer-settings { display: flex; flex-direction: column; gap: 6px; }
.collage-header-footer-settings .collage-header-row { order: 1; }
.collage-header-footer-settings .collage-footer-row { order: 2; }
.collage-header-footer-colors { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 7px; order: 3; }
.collage-header-footer-height-debug { order: 4; }
.collage-header-footer-settings .collage-header-footer-properties { display: none; }
.collage-header-footer-row > label { min-width: 0; }
.collage-header-footer-input input { min-height: 34px; box-sizing: border-box; }
.collage-header-footer-font,
.collage-header-footer-size { display: grid; gap: 3px; min-width: 0; color: #d8e7e3; font-size: 10px; font-weight: 800; }
.collage-header-footer-font select,
.collage-header-footer-size input { width: 100%; min-width: 0; height: 34px; box-sizing: border-box; }
.collage-header-footer-height { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 5px; white-space: nowrap; }
.collage-header-footer-height input[type="range"] { width: 100%; min-width: 0; }
@media (max-width: 640px) { .collage-header-footer-row { grid-template-columns: minmax(0, 1fr) minmax(100px, 26%) minmax(62px, 18%); gap: 4px; } .collage-header-footer-height { font-size: 10px; } }

.collage-layer-list { display: grid; max-height: 150px; gap: 3px; overflow-y: auto; }
.collage-layer-row { display: grid; grid-template-columns: minmax(0, 1fr) 28px; gap: 3px; }
.collage-layer-list button { display: flex; min-height: 27px; align-items: center; justify-content: space-between; padding: 0 6px; font-size: 10px; text-align: left; }
.collage-layer-list .collage-layer-delete { min-width: 28px; padding: 0; justify-content: center; border-color: #9c4d55; background: #6e3037; }

.ticket-collage-stage-wrap { display: grid; min-width: 0; min-height: 0; grid-template-rows: 38px 38px minmax(0, 1fr); background: #081213; }
.collage-detail-view-actions { display: flex; min-width: 0; align-items: center; gap: 5px; overflow-x: auto; border-bottom: 1px solid #34524f; background: #10211f; padding: 3px 7px; scrollbar-width: none; }
.collage-detail-view-actions::-webkit-scrollbar { display: none; }
.collage-detail-view-actions button { min-width: 74px; min-height: 30px; flex: 1 0 auto; }
.collage-detail-view-actions button[aria-pressed="true"] { border-color: #e6c765; background: #66511b; color: #fff5c8; }
.ticket-collage-stage canvas.is-pan-view { cursor: grab; }
.ticket-collage-stage canvas.is-pan-view:active { cursor: grabbing; }
.ticket-collage-stage-toolbar { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid #34524f; background: #142b29; padding: 4px 10px; }
.ticket-collage-stage-toolbar label { display: flex; align-items: center; gap: 7px; color: #d3e2de; font-size: 11px; font-weight: 800; }
.ticket-collage-stage-toolbar input { width: 150px; }
.ticket-collage-dialog:not(.is-mobile-collage-editor) .ticket-collage-stage-toolbar > label { display: none; }
#ticketCollageStatus { overflow: hidden; color: #ffd75d; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.ticket-collage-stage { min-width: 0; min-height: 0; overflow: auto; padding: 16px; scrollbar-color: #667d7c #0a1416; scrollbar-width: thin; }
.ticket-collage-stage canvas { display: block; width: 594px; height: auto; margin: 0 auto; background: #102c2c; box-shadow: 0 8px 28px rgba(0,0,0,.58); touch-action: none; }
.ticket-collage-empty-upload { position: absolute; z-index: 12; top: 50%; left: 50%; display: grid; width: min(440px, calc(100% - 40px)); box-sizing: border-box; gap: 12px; transform: translate(-50%, -50%); border: 1px solid #77a9a1; border-radius: 8px; background: rgba(13, 46, 43, .96); padding: 24px; color: #effffb; text-align: center; box-shadow: 0 12px 36px rgba(0,0,0,.48); }
.ticket-collage-empty-upload[hidden] { display: none !important; }
.ticket-collage-empty-upload strong { color: #ffe16a; font-size: 22px; }
.ticket-collage-empty-upload span { color: #c1d8d2; font-size: 13px; line-height: 1.55; }
.ticket-collage-empty-upload > div { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ticket-collage-empty-upload button { min-height: 48px; border-color: #66cba2; background: #176749; font-size: 15px; }
.ticket-collage-empty-upload button[data-collage-upload="camera"] { border-color: #d6b34e; background: #765b18; color: #fff3b2; }
.ticket-collage-empty-upload input[type="file"] { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; pointer-events: none; }
.ticket-collage-stage canvas.is-preview { cursor: default; }
.mobile-collage-tools,
.mobile-collage-view-actions,
.mobile-collage-magnifier { display: none; }

@media (max-width: 760px) {
  .ticket-collage-dialog { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; border: 0; border-radius: 0; }
  .is-mobile-collage-editor .ticket-collage-shell { grid-template-rows: auto 42px minmax(0, 1fr); }
  .is-mobile-collage-editor .ticket-collage-header { display: grid; grid-template-columns: minmax(0, 1fr); gap: 3px; padding: 4px 5px; }
  .is-mobile-collage-editor .ticket-collage-header > div:first-child { width: 100%; }
  .is-mobile-collage-editor .ticket-collage-header strong { font-size: 13px; }
  .is-mobile-collage-editor .ticket-collage-header span { display: none; }
  .is-mobile-collage-editor .ticket-collage-header__actions { display: flex; width: 100%; gap: 3px; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; }
  .is-mobile-collage-editor .ticket-collage-header__actions::-webkit-scrollbar,
  .mobile-collage-tools::-webkit-scrollbar,
  .mobile-collage-view-actions::-webkit-scrollbar { display: none; }
  .is-mobile-collage-editor .ticket-collage-header__actions button { min-width: 62px; min-height: 29px; flex: 0 0 auto; padding: 0 5px; font-size: 10px; }

  .mobile-collage-tools { display: flex; min-width: 0; gap: 3px; overflow-x: auto; overscroll-behavior-x: contain; border-bottom: 1px solid #557a78; background: #102826; padding: 4px; white-space: nowrap; scrollbar-width: none; }
  .mobile-collage-tools button { min-width: 62px; min-height: 33px; flex: 0 0 auto; padding: 0 9px; font-size: 11px; }
  .mobile-collage-tools .is-mobile-auto-mosaic { min-width: 76px; border-color: #c99f43; background: #745718; color: #fff2bd; }
  .mobile-collage-tools .is-mobile-auto-text { min-width: 76px; border-color: #4f9c87; background: #17624f; color: #e9fff8; }
  .mobile-collage-tools .is-mobile-auto-mosaic:active,
  .mobile-collage-tools .is-mobile-auto-text:active { filter: brightness(1.28); }
  .mobile-collage-tools .is-mobile-requested-privacy { min-width: 76px; border-color: #dd775d; background: #71352a; color: #fff0e9; }
  .is-mobile-collage-editor .collage-requested-privacy textarea { min-height: 78px; font-size: 13px; }
  .is-mobile-collage-editor .collage-privacy-target-report { grid-template-columns: minmax(0, 1fr); }
  .is-mobile-collage-editor .collage-privacy-target-buttons { width: 100%; }
  .mobile-collage-tools button[aria-pressed="true"] { border-color: #ffe478; background: #8a6418; color: #fff7be; box-shadow: inset 0 1px rgba(255,255,255,.22); }
  .mobile-collage-tools [data-collage-address][aria-busy="true"] { filter: brightness(.78); box-shadow: none; }

  .is-mobile-collage-editor .ticket-collage-workspace { position: relative; display: block; min-height: 0; overflow: hidden; }
  .is-mobile-collage-editor .ticket-collage-stage-wrap { position: absolute; z-index: 1; inset: 0 0 var(--mobile-collage-drawer-height, 205px); display: grid; grid-template-rows: 38px minmax(0, 1fr); background: #102c2c; transition: bottom .18s ease; }
  .is-mobile-collage-editor .ticket-collage-sidebar { position: absolute; z-index: 20; right: 0; bottom: 0; left: 0; height: var(--mobile-collage-drawer-height, 205px); box-sizing: border-box; overflow-y: auto; border: 0; border-top: 1px solid #658884; background: #102220; padding: 5px; transition: height .18s ease, padding .18s ease; }
  .is-mobile-collage-editor.is-drawer-collapsed .ticket-collage-stage-wrap { bottom: 0; }
  .is-mobile-collage-editor.is-drawer-collapsed .ticket-collage-sidebar { height: 0; overflow: hidden; border: 0; padding: 0; }
  /* 抽屉把手条(替代折叠箭头钮):全宽贴抽屉上缘,上下滑动收起/展开,点一下也能切换;收起态贴屏幕底保持可点。
     touch-action:none 防滑动被页面/抽屉滚动劫持。
     v476:整条可见的把手——底色实色与画布/抽屉区分,凹槽从左到右一条,比旧版细(26→20px),▲/▼文字隐藏(aria-label 仍朗读) */
  .is-mobile-collage-editor .mobile-drawer-toggle { position: absolute; z-index: 25; left: 0; right: 0; bottom: var(--mobile-collage-drawer-height, 205px); display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 20px; padding: 0; font-size: 0; line-height: 1; border: 0; border-top: 1px solid #34524f; background: #16332e; color: #9ecfce; touch-action: none; transition: bottom .18s ease; }
  .is-mobile-collage-editor .mobile-drawer-toggle::before { content: ""; position: absolute; left: 8px; right: 8px; height: 4px; border-radius: 2px; background: #5f7d79; }
  .is-mobile-collage-editor.is-drawer-collapsed .mobile-drawer-toggle { bottom: 0; }
  /* 抽屉自由拖高:拖拽中去过渡保跟手;低于收起阈值时把手变色提示"松手即收起" */
  .is-mobile-collage-editor.is-drawer-dragging .ticket-collage-stage-wrap,
  .is-mobile-collage-editor.is-drawer-dragging .ticket-collage-sidebar,
  .is-mobile-collage-editor.is-drawer-dragging .mobile-drawer-toggle { transition: none; }
  .is-mobile-collage-editor.is-drawer-collapse-hint .mobile-drawer-toggle { color: #ffb3a3; }
  .is-mobile-collage-editor.is-drawer-collapse-hint .mobile-drawer-toggle::before { background: #c96a53; }
  .is-mobile-collage-editor .ticket-collage-sidebar > [data-mobile-panel] { display: none; margin: 0; }
  .is-mobile-collage-editor .ticket-collage-sidebar > [data-mobile-panel].is-mobile-panel-active { display: grid; }
  .is-mobile-collage-editor .collage-tool-section { gap: 5px; padding: 6px; }
  .is-mobile-collage-editor .collage-tool-section p { font-size: 9px; }
  .is-mobile-collage-editor .collage-tool-grid { display: none; }
  .is-mobile-collage-editor.is-mobile-image-commands-collapsed [data-mobile-image-aux] { display: none; }

  .mobile-collage-view-actions { display: flex; min-width: 0; gap: 3px; overflow-x: auto; overscroll-behavior-x: contain; border-bottom: 1px solid #34524f; background: #10211f; padding: 3px 4px; white-space: nowrap; scrollbar-width: none; }
  .mobile-collage-view-actions button { min-width: 61px; min-height: 30px; flex: 0 0 auto; padding: 0 6px; font-size: 10px; }
  .mobile-collage-view-actions button[aria-pressed="true"] { border-color: #79e4b3; background: #226846; color: #eafff4; }

  .is-mobile-collage-editor .ticket-collage-stage-toolbar { gap: 6px; padding: 3px 6px; }
  /* 缩放滑条铺满剩余宽度(固定84px+max800时代滑块永远贴死最左):label 占满行内剩余空间,input 基准宽0独占label内余量,触摸命中高度提到28px */
  .is-mobile-collage-editor .ticket-collage-stage-toolbar label { gap: 4px; font-size: 9px; flex: 1 1 auto; min-width: 0; }
  .is-mobile-collage-editor .ticket-collage-stage-toolbar input { flex: 1 1 0; width: auto; min-width: 0; height: 28px; }
  .is-mobile-collage-editor #ticketCollageStatus { font-size: 9px; max-width: 40px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .is-mobile-collage-editor .ticket-collage-stage { position: relative; overflow: auto; overscroll-behavior: contain; padding: 7px; -webkit-overflow-scrolling: touch; }
  /* 手机端上传入口统一走第三排工具栏,画布中央不再叠放空态遮罩(挡住票面),桌面端保留 */
  .is-mobile-collage-editor .ticket-collage-empty-upload { display: none !important; }
  /* 手机端去掉抽屉里的"制作流程"条,功能按钮已并入第三排工具栏,桌面端保留 */
  .is-mobile-collage-editor .collage-workflow { display: none !important; }
  /* 手机端抽屉图片面板:排列/复制/撤销/缩放按钮组移出(排列走第三排工具栏同名按钮,复制图片/上一步/±步进移入画布上方工具条),抽屉只留图片缩略图,桌面端保留 */
  .is-mobile-collage-editor .collage-workflow-layout-row,
  .is-mobile-collage-editor .collage-layout-actions { display: none !important; }
  /* 画布上方工具条新增控件:−/＋缩放步进钮与"复制图片/上一步"操作钮 */
  .is-mobile-collage-editor .mobile-zoom-step { min-width: 27px; min-height: 27px; flex: 0 0 auto; padding: 0; font-size: 15px; font-weight: 900; line-height: 1; }
  .is-mobile-collage-editor .mobile-stage-extra { min-width: 0; min-height: 27px; flex: 0 0 auto; padding: 0 7px; font-size: 10px; font-weight: 900; }
  /* 抽屉图片面板:标题+缩略图两行铺满整个抽屉高度,缩略图多行换行,超出纵向滚动;隐藏态的地址遮挡子面板须显式隐藏(基线display:grid会盖掉[hidden]的UA样式,473px幽灵占位撑破面板) */
  .is-mobile-collage-editor .ticket-collage-sidebar > [data-mobile-panel="images"].is-mobile-panel-active { grid-template-rows: auto minmax(0, 1fr); min-height: 100%; }
  .is-mobile-collage-editor [data-mobile-panel="images"] .collage-address-privacy[hidden] { display: none !important; }
  .is-mobile-collage-editor #ticketCollageThumbnails.collage-thumbnails { flex-wrap: wrap; align-content: flex-start; min-height: 0; overflow-y: auto; }
  .is-mobile-collage-editor .ticket-collage-empty-upload strong { font-size: 20px; }
  .is-mobile-collage-editor .ticket-collage-empty-upload > div { grid-template-columns: 1fr; }
  .is-mobile-collage-editor .ticket-collage-empty-upload button { min-height: 50px; font-size: 15px; }
  .is-mobile-collage-editor .ticket-collage-stage canvas#ticketCollageCanvas { max-width: none; touch-action: none; }
  .is-mobile-collage-editor.is-mobile-overview .ticket-collage-stage canvas#ticketCollageCanvas { touch-action: pan-x pan-y; }
  .is-mobile-collage-editor .collage-material-categories { display: flex; grid-template-columns: none; overflow-x: auto; white-space: nowrap; }
  .is-mobile-collage-editor .collage-material-categories button { min-width: 66px; flex: 0 0 auto; }
  .is-mobile-collage-editor .collage-material-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: none; }
  .is-mobile-collage-editor .collage-text-nudge { display: flex; overflow-x: auto; }
  .is-mobile-collage-editor .collage-text-nudge button { min-width: 54px; flex: 0 0 auto; }

  /* 每个功能只显示自己的控件：标注面板内容默认全部收起（标题与通用图层操作除外） */
  .is-mobile-collage-editor [data-mobile-panel="edit"] > label,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > output,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > p,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-property-row,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-text-nudge,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-crop-actions,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-frame-style,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-mobile-text-settings { display: none; }

  /* 文字：只显示独立文字设置框（文字内容→字体→有无背景→背景颜色），其余（字号/角度行、微调、提示、图层操作）一律收起 */
  .is-mobile-collage-editor[data-mobile-active-tool="text"] [data-mobile-panel="edit"] > .collage-mobile-text-settings { display: grid; }
  .is-mobile-collage-editor[data-mobile-active-tool="text"] [data-mobile-panel="edit"] > .collage-inline-actions { display: none; }
  /* 文字工具抽屉加高一档（默认205px），四项设置免滚动全部可见；收起态仍优先归零。
     变量定义在 dialog 层(非 sidebar):折叠钮与 stage-wrap 也按 236px 定位/让高,否则文字态按钮会陷进抽屉压住控件 */
  .is-mobile-collage-editor[data-mobile-active-tool="text"]:not(.is-drawer-collapsed) { --mobile-collage-drawer-height: 236px; }

  /* 裁剪:v481 确认/取消移入画布HUD(✓✗⟳+比例chips),抽屉内按钮组永久退场(引擎隐藏按钮仍可用) */
  .is-mobile-collage-editor[data-mobile-active-tool="crop"] [data-mobile-panel="edit"] > .collage-crop-actions { display: none !important; }
  .is-mobile-collage-editor[data-mobile-active-tool="frame"] [data-mobile-panel="edit"] > .collage-frame-style { display: grid; }

  /* 专属控件靠上排，通用图层操作沉底 */
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-section-title { order: 0; }
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-crop-actions,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-frame-style,
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-mobile-text-settings { order: 1; }
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-property-row { order: 2; }
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-text-nudge { order: 3; }
  .is-mobile-collage-editor [data-mobile-panel="edit"] > p { order: 4; }
  .is-mobile-collage-editor [data-mobile-panel="edit"] > .collage-inline-actions { order: 9; }

  .collage-frame-style { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
  .is-mobile-collage-editor[data-mobile-active-tool="layers"] [data-mobile-panel="materials"] > .collage-material-categories,
  .is-mobile-collage-editor[data-mobile-active-tool="layers"] [data-mobile-panel="materials"] > #ticketCollageMaterialSearch,
  .is-mobile-collage-editor[data-mobile-active-tool="layers"] [data-mobile-panel="materials"] > #ticketCollageMaterialGrid,
  .is-mobile-collage-editor[data-mobile-active-tool="layers"] [data-mobile-panel="materials"] > .collage-custom-sticker-panel { display: none; }

  .mobile-collage-magnifier { position: fixed; z-index: 80; display: none !important; width: 116px !important; height: 116px !important; margin: 0 !important; border: 3px solid #ffe16a; border-radius: 50%; background: #fff; box-shadow: 0 5px 22px rgba(0,0,0,.72); pointer-events: none; touch-action: none; }
  .mobile-collage-magnifier.is-visible { display: block !important; }

  /* 手机端店主助手内嵌:空态保留对话框深色背景填满屏幕,与店主助手区视觉一致;只收起画布与抽屉避免出现空画布,上传后自动展开 */
  .ticket-collage-dialog.is-store-assistant-embedded.is-mobile-collage-editor.is-canvas-empty .ticket-collage-stage-wrap,
  .ticket-collage-dialog.is-store-assistant-embedded.is-mobile-collage-editor.is-canvas-empty .ticket-collage-sidebar,
  .ticket-collage-dialog.is-store-assistant-embedded.is-mobile-collage-editor.is-canvas-empty .mobile-drawer-toggle { display: none; }

  /* ===== v481 微信式浮层:裁剪HUD / 文字输入条 / 选中操作条 / 马赛克粗细 =====
     全部 absolute 挂 workspace(同把手/放大镜先例,不用 fixed——dialog 在 top-layer);
     容器 pointer-events:none+按钮 auto,条间空白触摸穿到画布 */
  .is-mobile-collage-editor .mobile-crop-hud { position: absolute; z-index: 30; left: 0; right: 0; bottom: 12px; display: none; align-items: center; justify-content: center; gap: 10px; padding: 6px 8px; pointer-events: none; }
  .is-mobile-collage-editor[data-mobile-active-tool="crop"] .mobile-crop-hud { display: flex; }
  .is-mobile-collage-editor .mobile-crop-hud-actions { display: flex; gap: 8px; pointer-events: auto; }
  .is-mobile-collage-editor .mobile-crop-hud-actions button { min-width: 50px; min-height: 42px; font-size: 20px; line-height: 1; border-radius: 21px; border: 1px solid #6b8f8a; background: #16332e; color: #e9fff8; }
  .is-mobile-collage-editor .mobile-crop-hud-actions [data-mobile-crop-hud-action="apply"] { border-color: #ffe478; background: #8a6418; color: #fff7be; }
  .is-mobile-collage-editor .mobile-crop-ratio-chips { display: flex; gap: 5px; pointer-events: auto; }
  .is-mobile-collage-editor .mobile-crop-ratio-chips button { min-width: 44px; min-height: 34px; padding: 0 7px; font-size: 11px; border-radius: 17px; border: 1px solid #557a78; background: #102220; color: #cfe8e4; }
  .is-mobile-collage-editor .mobile-crop-ratio-chips button[aria-pressed="true"] { border-color: #ffe478; background: #8a6418; color: #fff7be; }

  /* 文字原位输入条:固定底部全宽,键盘弹起由 controller 用 translateY 抬(Chrome/92 无 dvh) */
  .is-mobile-collage-editor .mobile-text-input-bar { position: absolute; z-index: 40; left: 0; right: 0; bottom: 0; display: flex; gap: 6px; padding: 7px 8px 8px; border-top: 1px solid #34524f; background: #102826; }
  .is-mobile-collage-editor .mobile-text-input-bar[hidden] { display: none; }
  .is-mobile-collage-editor .mobile-text-input-bar input { flex: 1; min-width: 0; min-height: 38px; padding: 0 10px; font-size: 16px; border-radius: 8px; border: 1px solid #557a78; background: #0b1d1c; color: #f2fffb; }
  .is-mobile-collage-editor .mobile-text-input-bar button { min-width: 46px; min-height: 38px; font-size: 18px; border-radius: 8px; border: 1px solid #557a78; background: #102220; color: #cfe8e4; }
  .is-mobile-collage-editor .mobile-text-input-bar [data-mobile-text-input-action="apply"] { border-color: #ffe478; background: #8a6418; color: #fff7be; }

  /* 选中操作条:文字层=颜色swatch,对象层=复制/层级,删除与⋯共用;悬浮画布下缘,条体不挡触摸 */
  .is-mobile-collage-editor .mobile-layer-tools-bar { position: absolute; z-index: 35; left: 0; right: 0; bottom: 22px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; padding: 5px 8px; pointer-events: none; }
  .is-mobile-collage-editor .mobile-layer-tools-bar[hidden] { display: none; }
  .is-mobile-collage-editor .mobile-layer-tools-bar > * { pointer-events: auto; }
  .is-mobile-collage-editor .mobile-layer-tools-bar button { min-height: 34px; padding: 0 10px; font-size: 12px; border-radius: 8px; border: 1px solid #557a78; background: rgba(16,34,32,.94); color: #cfe8e4; }
  .is-mobile-collage-editor .mobile-layer-tools-bar .mobile-layer-delete { border-color: #9c4d55; background: #6e3037; color: #ffd9d9; }
  .is-mobile-collage-editor .mobile-layer-tools-bar .mobile-text-swatches { display: none; }
  .is-mobile-collage-editor .mobile-layer-tools-bar.is-text-layer .mobile-text-swatches { display: flex; gap: 6px; }
  .is-mobile-collage-editor .mobile-layer-tools-bar .mobile-object-tools { display: none; }
  .is-mobile-collage-editor .mobile-layer-tools-bar.is-object-layer .mobile-object-tools { display: flex; gap: 6px; }
  .is-mobile-collage-editor .mobile-text-swatch { width: 30px; min-width: 30px; height: 30px; padding: 0; border-radius: 50%; border: 2px solid #557a78; background: var(--swatch); }
  .is-mobile-collage-editor .mobile-text-swatch[aria-pressed="true"] { border-color: #ffe478; box-shadow: 0 0 0 2px rgba(255,228,120,.4); }
  .is-mobile-collage-editor .mobile-text-more { position: absolute; right: 8px; bottom: calc(100% + 6px); display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 8px; border: 1px solid #34524f; border-radius: 10px; background: #102826; }
  .is-mobile-collage-editor .mobile-text-more[hidden] { display: none; }
  .is-mobile-collage-editor .mobile-text-more label { display: flex; align-items: center; gap: 4px; font-size: 11px; color: #9ecfce; }
  .is-mobile-collage-editor .mobile-text-more select, .is-mobile-collage-editor .mobile-text-more input[type="color"] { min-height: 30px; border-radius: 6px; border: 1px solid #557a78; background: #0b1d1c; color: #f2fffb; }

  /* 马赛克粗细chips:仅马赛克工具激活时出现,与放大镜配合 */
  .is-mobile-collage-editor .mobile-mosaic-chips { position: absolute; z-index: 30; left: 50%; transform: translateX(-50%); bottom: 12px; display: none; gap: 6px; padding: 5px 6px; border-radius: 20px; border: 1px solid #34524f; background: rgba(16,34,32,.92); }
  .is-mobile-collage-editor[data-mobile-active-tool="mosaic"] .mobile-mosaic-chips { display: flex; }
  .is-mobile-collage-editor .mobile-mosaic-chips button { min-width: 48px; min-height: 32px; border-radius: 16px; font-size: 12px; border: 1px solid #557a78; background: #102220; color: #cfe8e4; }
  .is-mobile-collage-editor .mobile-mosaic-chips button[aria-pressed="true"] { border-color: #ffe478; background: #8a6418; color: #fff7be; }

  /* 浮层出现时收掉抽屉把手,避免底栏叠压 */
  .is-mobile-collage-editor[data-mobile-active-tool="crop"] .mobile-drawer-toggle,
  .is-mobile-collage-editor[data-mobile-active-tool="mosaic"] .mobile-drawer-toggle,
  .is-mobile-collage-editor.is-mobile-text-composing .mobile-drawer-toggle { display: none; }
}
