/* ================================================================ Ozon Seller Kit - 自定义组件样式 原先内联于 HTML 的 Tailwind @layer utilities,已展开为标准 CSS (Play CDN 不处理外部文件里的 @apply)。配色与 js/tailwind.config.js 中的调色板保持一致。 ================================================================ */ :root { --color-primary: #3B82F6; --color-secondary: #10B981; --color-dark-light: #2D2D3F; --color-warning: #F59E0B; --color-danger: #EF4444; --color-gray-700: #374151; --shadow-primary-lg: 0 10px 15px -3px rgba(59, 130, 246, 0.1), 0 4px 6px -4px rgba(59, 130, 246, 0.1); --neon: 0 0 5px rgba(59, 130, 246, 0.5), inset 0 0 5px rgba(59, 130, 246, 0.3); } /* 输入框聚焦态 */ .input-focus { transition: all 0.2s ease; } .input-focus:focus { outline: none; border-color: var(--color-primary); box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.5); } /* 阴影 */ .card-shadow, .panel-shadow { box-shadow: var(--shadow-primary-lg); } /* 结果卡片 */ .result-card { background-color: var(--color-dark-light); border-radius: 0.75rem; padding: 1.25rem; border-color: var(--color-secondary); transition: all 0.3s ease; } /* 警告 / 错误卡片 */ .warning-card, .error-card { background-color: var(--color-dark-light); border-radius: 0.75rem; padding: 1.25rem; box-shadow: var(--shadow-primary-lg); transition: all 0.3s ease; } .warning-card { border-left: 4px solid var(--color-warning); } .error-card { border-left: 4px solid var(--color-danger); } /* 文字发光 / 霓虹描边 */ .text-glow { text-shadow: 0 0 10px rgba(59, 130, 246, 0.5); } .neon-border { box-shadow: var(--neon); } /* 图片上传区 */ .upload-area { border: 2px dashed var(--color-gray-700); border-radius: 0.75rem; padding: 2rem; text-align: center; cursor: pointer; transition: border-color 0.2s ease; } .upload-area:hover { border-color: var(--color-primary); } /* 预览图片 */ .preview-frame { position: relative; display: inline-block; max-width: 100%; } .preview-img { display: block; max-width: 100%; height: auto; border-radius: 0.5rem; object-fit: contain; border: 1px solid var(--color-gray-700); transition: box-shadow 0.2s ease; } .preview-img:hover { box-shadow: var(--neon); } /* 已加水印:可拖动调整位置 */ .preview-img-draggable { cursor: move; touch-action: none; } /* 预览图右上角的单图操作按钮 */ .preview-actions { position: absolute; top: 0.375rem; right: 0.375rem; display: flex; gap: 0.25rem; } .preview-action-btn { padding: 0.2rem 0.5rem; border: 1px solid rgba(255, 255, 255, 0.15); border-radius: 0.375rem; background: rgba(17, 17, 27, 0.75); color: #e5e7eb; font-size: 0.6875rem; line-height: 1.5; white-space: nowrap; cursor: pointer; transition: background-color 0.2s ease, color 0.2s ease; } .preview-action-btn:hover:not(:disabled) { background: var(--color-primary); color: #fff; } .preview-action-btn:disabled { opacity: 0.6; cursor: default; } /* 俄文文案:平铺只读文本 */ .ai-text-block { white-space: pre-wrap; word-break: break-word; line-height: 1.7; } .ai-text-block:empty::before { content: attr(data-placeholder); color: #6b7280; font-size: 0.875rem; } .ai-text-block-ru { color: #f3f4f6; font-size: 0.9375rem; } .ai-text-block-zh { color: #9ca3af; font-size: 0.875rem; } .ai-text-divider { margin: 0.875rem 0; border-top: 1px dashed var(--color-gray-700); } /* 俄文文案:推荐标题卡片 */ .ai-title-card { padding: 0.75rem; border: 1px solid var(--color-gray-700); border-radius: 0.5rem; background: var(--color-dark-light); } .ai-title-card-head { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; margin-bottom: 0.35rem; } .ai-title-card-index { color: #9ca3af; font-size: 0.75rem; } .ai-title-card-ru { color: #f3f4f6; font-size: 0.9375rem; line-height: 1.5; word-break: break-word; } .ai-title-card-zh { margin-top: 0.35rem; color: #9ca3af; font-size: 0.8125rem; line-height: 1.5; word-break: break-word; } /* 俄文文案:标签芯片 */ .ai-tag-chip { display: inline-flex; align-items: center; gap: 0.35rem; max-width: 100%; padding: 0.4rem 0.75rem; border: 1px solid var(--color-gray-700); border-radius: 9999px; background: var(--color-dark-light); color: var(--color-gray-100); font-size: 0.875rem; line-height: 1.3; cursor: pointer; transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.15s ease; } .ai-tag-chip:hover { border-color: var(--color-primary); background: rgba(59, 130, 246, 0.12); transform: translateY(-1px); } .ai-tag-chip-ru { color: #f3f4f6; font-weight: 500; } .ai-tag-chip-sep { color: #6b7280; } .ai-tag-chip-zh { color: #9ca3af; } .ai-copy-btn.is-copied, .ai-copy-trigger.is-copied, .ai-copy-all-tags-btn.is-copied { background: rgba(16, 185, 129, 0.25) !important; color: #34d399 !important; } .ai-tag-chip.is-copied { border-color: #34d399; background: rgba(16, 185, 129, 0.15); transform: none; } /* 上品登记表:型号 / 重量 / 尺寸 默认隐藏 */ #historyTable:not(.show-optional-cols) .history-col-optional { display: none; } /* ================================================================ Toast 轻提示 ================================================================ */ .toast-container { position: fixed; top: 1.25rem; left: 50%; transform: translateX(-50%); z-index: 9999; display: flex; flex-direction: column; align-items: center; gap: 0.625rem; pointer-events: none; } .toast { pointer-events: auto; min-width: 12rem; max-width: 22rem; display: flex; align-items: center; gap: 0.625rem; padding: 0.75rem 1.125rem; border-radius: 0.625rem; background: var(--color-dark-light); border: 1px solid var(--color-gray-700); border-left: 4px solid var(--color-secondary); color: #f3f4f6; font-size: 0.9375rem; line-height: 1.4; box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.45); opacity: 0; transform: translateY(-12px); transition: opacity 0.25s ease, transform 0.25s ease; } .toast.show { opacity: 1; transform: translateY(0); } .toast.hide { opacity: 0; transform: translateY(-12px); } .toast .toast-icon { flex: 0 0 auto; font-size: 1.125rem; line-height: 1; } .toast.success { border-left-color: var(--color-secondary); } .toast.success .toast-icon { color: #34d399; } .toast.error { border-left-color: var(--color-danger); } .toast.error .toast-icon { color: #f87171; } .toast.info { border-left-color: var(--color-primary); } .toast.info .toast-icon { color: #60a5fa; }