export-view.css 26 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268
  1. /* 确保 body 和 html 占满整个 iframe */
  2. html, body {
  3. margin: 0;
  4. padding: 0;
  5. width: 100%;
  6. height: 100%;
  7. overflow: hidden;
  8. background: transparent;
  9. }
  10. /* 弹出框遮罩层 */
  11. .export-overlay {
  12. position: fixed;
  13. top: 0;
  14. left: 0;
  15. right: 0;
  16. bottom: 0;
  17. width: 100%;
  18. height: 100%;
  19. background: rgba(0, 0, 0, 0.7);
  20. display: flex;
  21. align-items: center;
  22. justify-content: center;
  23. z-index: 999999;
  24. backdrop-filter: blur(4px);
  25. animation: overlayFadeIn 0.3s ease-out;
  26. margin: 0;
  27. padding: 0;
  28. }
  29. /* 关闭按钮(在弹窗右上角) */
  30. .modal-close-btn {
  31. position: absolute;
  32. width: 44px;
  33. height: 44px;
  34. border-radius: 50%;
  35. background: white;
  36. border: 2px solid #e5e7eb;
  37. color: #6b7280;
  38. cursor: pointer;
  39. display: flex;
  40. align-items: center;
  41. justify-content: center;
  42. transition: background-color 0.2s, color 0.2s, border-color 0.2s, box-shadow 0.2s, transform 0.2s;
  43. z-index: 10;
  44. padding: 0;
  45. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  46. top: -22px;
  47. right: -22px;
  48. }
  49. .modal-close-btn:hover {
  50. background: #f9fafb;
  51. color: #1f2937;
  52. border-color: #d1d5db;
  53. transform: scale(1.1);
  54. box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
  55. }
  56. .modal-close-btn:active {
  57. transform: scale(0.95);
  58. }
  59. .modal-close-btn svg {
  60. width: 20px;
  61. height: 20px;
  62. }
  63. @keyframes overlayFadeIn {
  64. from {
  65. background: rgba(0, 0, 0, 0);
  66. backdrop-filter: blur(0);
  67. }
  68. to {
  69. background: rgba(0, 0, 0, 0.7);
  70. backdrop-filter: blur(4px);
  71. }
  72. }
  73. /* 弹出框容器 */
  74. .export-modal {
  75. background: white;
  76. border-radius: 16px;
  77. box-shadow:
  78. 0 20px 60px rgba(0, 0, 0, 0.3),
  79. 0 0 0 1px rgba(0, 0, 0, 0.05);
  80. min-width: 800px;
  81. max-width: 1200px;
  82. width: 90%;
  83. max-height: 90vh;
  84. display: flex;
  85. flex-direction: column;
  86. animation: modalSlideIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  87. overflow: visible;
  88. position: relative;
  89. z-index: 1000000;
  90. margin: auto;
  91. }
  92. @keyframes modalSlideIn {
  93. from {
  94. opacity: 0;
  95. transform: translateY(-30px) scale(0.95);
  96. }
  97. to {
  98. opacity: 1;
  99. transform: translateY(0) scale(1);
  100. }
  101. }
  102. /* 图片预览容器 - 左右两个图框 */
  103. .export-preview-container {
  104. width: 100%;
  105. min-height: 500px;
  106. max-height: 70vh;
  107. display: flex;
  108. gap: 32px;
  109. padding: 32px;
  110. box-sizing: border-box;
  111. background: #fafbfc;
  112. }
  113. /* 单列预览容器(仅显示Spritesheet) */
  114. .export-preview-container.export-preview-single {
  115. justify-content: center;
  116. }
  117. .export-preview-container.export-preview-single .export-spritesheet-box {
  118. max-width: 800px;
  119. width: 100%;
  120. }
  121. /* 预览图框 - 左右各占一半 */
  122. .export-preview-box {
  123. flex: 1;
  124. min-height: 400px;
  125. background: repeating-conic-gradient(#f3f4f6 0% 25%, white 0% 50%) 50% / 20px 20px;
  126. border: 2px solid #e5e7eb;
  127. border-radius: 12px;
  128. display: flex;
  129. align-items: center;
  130. justify-content: center;
  131. position: relative;
  132. overflow: auto;
  133. box-sizing: border-box;
  134. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  135. transition: box-shadow 0.2s;
  136. }
  137. .export-preview-box:hover {
  138. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  139. }
  140. /* 右侧 Spritesheet 区域容器 */
  141. .export-spritesheet-section {
  142. flex: 1;
  143. display: flex;
  144. flex-direction: column;
  145. }
  146. /* 左侧:参考图上传区域 */
  147. .export-reference-section {
  148. flex: 1;
  149. display: flex;
  150. flex-direction: column;
  151. gap: 12px;
  152. }
  153. .export-reference-box {
  154. cursor: pointer;
  155. transition: border-color 0.2s;
  156. flex: 1;
  157. }
  158. .export-reference-box:hover {
  159. border-color: #667eea;
  160. }
  161. .reference-upload-area {
  162. display: flex;
  163. flex-direction: column;
  164. align-items: center;
  165. justify-content: center;
  166. gap: 12px;
  167. color: #9ca3af;
  168. pointer-events: none;
  169. width: 100%;
  170. height: 100%;
  171. position: absolute;
  172. top: 0;
  173. left: 0;
  174. }
  175. .reference-upload-area.hide {
  176. display: none;
  177. }
  178. .upload-icon {
  179. font-size: 48px;
  180. font-weight: 300;
  181. color: #d1d5db;
  182. line-height: 1;
  183. }
  184. .upload-text {
  185. font-size: 14px;
  186. font-weight: 500;
  187. }
  188. .reference-image-wrapper {
  189. position: relative;
  190. width: 100%;
  191. height: 100%;
  192. display: flex;
  193. align-items: center;
  194. justify-content: center;
  195. }
  196. .reference-image {
  197. max-width: 100%;
  198. max-height: 100%;
  199. object-fit: contain;
  200. }
  201. .reference-remove-btn {
  202. position: absolute;
  203. top: 12px;
  204. right: 12px;
  205. width: 32px;
  206. height: 32px;
  207. border-radius: 50%;
  208. background: rgba(0, 0, 0, 0.6);
  209. backdrop-filter: blur(4px);
  210. border: none;
  211. color: white;
  212. cursor: pointer;
  213. display: flex;
  214. align-items: center;
  215. justify-content: center;
  216. transition: all 0.2s;
  217. z-index: 10;
  218. padding: 0;
  219. }
  220. .reference-remove-btn:hover {
  221. background: rgba(239, 68, 68, 0.9);
  222. transform: scale(1.1);
  223. box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
  224. }
  225. .reference-remove-btn:active {
  226. transform: scale(0.95);
  227. }
  228. .reference-remove-btn svg {
  229. width: 16px;
  230. height: 16px;
  231. }
  232. /* 替换按钮 */
  233. .replace-btn {
  234. padding: 10px 24px;
  235. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  236. color: white;
  237. border: none;
  238. border-radius: 8px;
  239. font-size: 14px;
  240. font-weight: 500;
  241. cursor: pointer;
  242. transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  243. box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
  244. align-self: center;
  245. min-width: 100px;
  246. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  247. }
  248. .replace-btn:hover {
  249. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  250. transform: translateY(-1px);
  251. }
  252. .replace-btn:active {
  253. transform: translateY(0) scale(0.98);
  254. }
  255. .replace-btn:disabled {
  256. background: #d1d5db;
  257. color: #9ca3af;
  258. box-shadow: none;
  259. cursor: not-allowed;
  260. transform: none;
  261. }
  262. /* 右侧:Spritesheet 预览 */
  263. .export-spritesheet-box {
  264. background: repeating-conic-gradient(#f3f4f6 0% 25%, white 0% 50%) 50% / 20px 20px;
  265. }
  266. #previewImage {
  267. max-width: 100%;
  268. max-height: 100%;
  269. width: auto;
  270. height: auto;
  271. object-fit: contain;
  272. display: none;
  273. margin: auto;
  274. }
  275. #previewImage.show {
  276. display: block;
  277. }
  278. /* 悬浮按钮组 - 右下角 */
  279. .floating-btn-group {
  280. position: absolute;
  281. bottom: 16px;
  282. right: 16px;
  283. display: flex;
  284. flex-direction: column;
  285. gap: 10px;
  286. z-index: 100;
  287. }
  288. /* 悬浮AI按钮 */
  289. .floating-ai-btn {
  290. width: 46px;
  291. height: 46px;
  292. border-radius: 50%;
  293. background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  294. border: none;
  295. color: white;
  296. cursor: pointer;
  297. display: flex;
  298. align-items: center;
  299. justify-content: center;
  300. box-shadow:
  301. 0 6px 20px rgba(16, 185, 129, 0.4),
  302. 0 3px 10px rgba(0, 0, 0, 0.15);
  303. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  304. padding: 0;
  305. overflow: hidden;
  306. }
  307. .floating-ai-btn:hover:not(:disabled) {
  308. background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
  309. box-shadow:
  310. 0 10px 28px rgba(16, 185, 129, 0.5),
  311. 0 5px 14px rgba(0, 0, 0, 0.2);
  312. transform: translateY(-3px) scale(1.08);
  313. }
  314. .floating-ai-btn:active:not(:disabled) {
  315. transform: translateY(-1px) scale(1.03);
  316. }
  317. .floating-ai-btn:disabled {
  318. opacity: 0.4;
  319. cursor: not-allowed;
  320. transform: none;
  321. box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  322. background: linear-gradient(135deg, #d1d5db 0%, #9ca3af 100%);
  323. }
  324. .floating-ai-btn svg {
  325. width: 20px;
  326. height: 20px;
  327. flex-shrink: 0;
  328. filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
  329. }
  330. .floating-ai-btn.active {
  331. background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
  332. box-shadow:
  333. 0 0 0 3px rgba(16, 185, 129, 0.3),
  334. 0 6px 20px rgba(16, 185, 129, 0.4);
  335. }
  336. /* 悬浮下载按钮 */
  337. .floating-download-btn {
  338. width: 52px;
  339. height: 52px;
  340. border-radius: 50%;
  341. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  342. border: none;
  343. color: white;
  344. cursor: pointer;
  345. display: flex;
  346. align-items: center;
  347. justify-content: center;
  348. box-shadow:
  349. 0 8px 24px rgba(102, 126, 234, 0.4),
  350. 0 4px 12px rgba(0, 0, 0, 0.15);
  351. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  352. padding: 0;
  353. overflow: hidden;
  354. }
  355. .floating-download-btn::before {
  356. content: '';
  357. position: absolute;
  358. top: 50%;
  359. left: 50%;
  360. width: 0;
  361. height: 0;
  362. border-radius: 50%;
  363. background: rgba(255, 255, 255, 0.2);
  364. transform: translate(-50%, -50%);
  365. transition: width 0.6s, height 0.6s;
  366. }
  367. .floating-download-btn:hover::before {
  368. width: 200px;
  369. height: 200px;
  370. }
  371. .floating-download-btn:hover {
  372. background: linear-gradient(135deg, #7c8ef0 0%, #8a5fb8 100%);
  373. box-shadow:
  374. 0 12px 32px rgba(102, 126, 234, 0.5),
  375. 0 6px 16px rgba(0, 0, 0, 0.2);
  376. transform: translateY(-3px) scale(1.08);
  377. }
  378. .floating-download-btn:active {
  379. background: linear-gradient(135deg, #5a6fd8 0%, #6a3d92 100%);
  380. transform: translateY(-1px) scale(1.03);
  381. box-shadow:
  382. 0 6px 20px rgba(102, 126, 234, 0.4),
  383. 0 4px 12px rgba(0, 0, 0, 0.15);
  384. }
  385. .floating-download-btn:disabled {
  386. opacity: 0.4;
  387. cursor: not-allowed;
  388. transform: none;
  389. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  390. background: linear-gradient(135deg, #d1d5db 0%, #9ca3af 100%);
  391. }
  392. .floating-download-btn svg {
  393. width: 22px;
  394. height: 22px;
  395. flex-shrink: 0;
  396. position: relative;
  397. z-index: 1;
  398. filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
  399. transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  400. }
  401. .floating-download-btn:hover:not(:disabled) svg {
  402. transform: translateY(3px);
  403. }
  404. .floating-download-btn:active:not(:disabled) svg {
  405. transform: translateY(5px);
  406. }
  407. .preview-placeholder {
  408. position: absolute;
  409. display: flex;
  410. flex-direction: column;
  411. align-items: center;
  412. justify-content: center;
  413. gap: 16px;
  414. color: #9ca3af;
  415. }
  416. .preview-placeholder.hide {
  417. display: none;
  418. }
  419. .loading-spinner {
  420. width: 40px;
  421. height: 40px;
  422. border: 4px solid #e5e7eb;
  423. border-top-color: #667eea;
  424. border-radius: 50%;
  425. animation: spin 0.8s linear infinite;
  426. }
  427. .loading-text {
  428. font-size: 15px;
  429. font-weight: 500;
  430. color: #6b7280;
  431. }
  432. @keyframes spin {
  433. to {
  434. transform: rotate(360deg);
  435. }
  436. }
  437. /* 按钮区域 */
  438. .export-actions {
  439. padding: 20px 32px;
  440. display: flex;
  441. gap: 12px;
  442. justify-content: flex-end;
  443. align-items: center;
  444. flex-shrink: 0;
  445. border-top: 1px solid #e5e7eb;
  446. background: white;
  447. }
  448. .export-btn {
  449. padding: 12px 32px;
  450. border: none;
  451. border-radius: 10px;
  452. font-size: 15px;
  453. cursor: pointer;
  454. transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  455. font-weight: 600;
  456. letter-spacing: 0.3px;
  457. min-width: 120px;
  458. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  459. display: flex;
  460. align-items: center;
  461. justify-content: center;
  462. }
  463. .export-cancel {
  464. background: white;
  465. color: #374151;
  466. border: 2px solid #d1d5db;
  467. font-weight: 600;
  468. }
  469. .export-cancel:hover {
  470. background: #f9fafb;
  471. color: #1f2937;
  472. border-color: #9ca3af;
  473. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  474. transform: translateY(-1px);
  475. }
  476. .export-cancel:active {
  477. transform: translateY(0) scale(0.98);
  478. box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  479. }
  480. .export-confirm {
  481. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  482. color: white;
  483. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  484. }
  485. .export-confirm:hover {
  486. box-shadow: 0 6px 16px rgba(102, 126, 234, 0.5);
  487. transform: translateY(-1px);
  488. }
  489. .export-confirm:active {
  490. transform: translateY(0) scale(0.98);
  491. }
  492. .export-confirm:disabled {
  493. background: #d1d5db;
  494. color: #9ca3af;
  495. box-shadow: none;
  496. cursor: not-allowed;
  497. transform: none;
  498. }
  499. .export-confirm svg {
  500. flex-shrink: 0;
  501. transition: transform 0.2s;
  502. }
  503. .export-confirm:hover:not(:disabled) svg {
  504. transform: translateY(2px);
  505. }
  506. .export-confirm:active:not(:disabled) svg {
  507. transform: translateY(4px);
  508. }
  509. /* 替换按钮 */
  510. .replace-btn {
  511. padding: 10px 24px;
  512. border: none;
  513. border-radius: 8px;
  514. font-size: 14px;
  515. cursor: pointer;
  516. transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  517. font-weight: 500;
  518. letter-spacing: 0.3px;
  519. background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  520. color: white;
  521. box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
  522. align-self: center;
  523. min-width: 120px;
  524. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  525. }
  526. .replace-btn:hover {
  527. box-shadow: 0 6px 16px rgba(16, 185, 129, 0.5);
  528. transform: translateY(-1px);
  529. }
  530. .replace-btn:active {
  531. transform: translateY(0) scale(0.98);
  532. }
  533. .replace-btn:disabled {
  534. background: #d1d5db;
  535. color: #9ca3af;
  536. box-shadow: none;
  537. cursor: not-allowed;
  538. transform: none;
  539. }
  540. /* 提示词配置区域 */
  541. .prompt-config-section {
  542. padding: 24px 32px;
  543. border-top: 1px solid #e5e7eb;
  544. border-bottom: 1px solid #e5e7eb;
  545. background: white;
  546. display: flex;
  547. flex-direction: column;
  548. gap: 20px;
  549. }
  550. .config-row {
  551. display: flex;
  552. flex-direction: column;
  553. gap: 8px;
  554. }
  555. .config-label-wrapper {
  556. display: flex;
  557. align-items: center;
  558. gap: 8px;
  559. }
  560. .config-label {
  561. font-size: 14px;
  562. font-weight: 500;
  563. color: #374151;
  564. }
  565. .download-icon-hint {
  566. display: flex;
  567. align-items: center;
  568. justify-content: center;
  569. width: 24px;
  570. height: 24px;
  571. cursor: pointer;
  572. opacity: 0.7;
  573. transition: all 0.2s;
  574. border-radius: 4px;
  575. padding: 2px;
  576. }
  577. .download-icon-hint:hover {
  578. opacity: 1;
  579. background: rgba(102, 126, 234, 0.1);
  580. transform: scale(1.1);
  581. }
  582. .download-icon-hint svg {
  583. width: 20px;
  584. height: 20px;
  585. }
  586. .config-input {
  587. padding: 10px 12px;
  588. border: 1px solid #d1d5db;
  589. border-radius: 6px;
  590. font-size: 14px;
  591. color: #1f2937;
  592. background: white;
  593. outline: none;
  594. transition: all 0.2s;
  595. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  596. }
  597. .config-input:focus {
  598. border-color: #667eea;
  599. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
  600. }
  601. .config-textarea {
  602. padding: 10px 12px;
  603. border: 1px solid #d1d5db;
  604. border-radius: 6px;
  605. font-size: 14px;
  606. color: #1f2937;
  607. background: white;
  608. outline: none;
  609. transition: all 0.2s;
  610. resize: vertical;
  611. min-height: 80px;
  612. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  613. line-height: 1.5;
  614. }
  615. .config-textarea:focus {
  616. border-color: #667eea;
  617. box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
  618. }
  619. .prompt-actions {
  620. display: flex;
  621. justify-content: flex-end;
  622. align-items: center;
  623. gap: 12px;
  624. padding-top: 10px;
  625. }
  626. /* 操作按钮通用样式 */
  627. .action-btn {
  628. display: flex;
  629. align-items: center;
  630. justify-content: center;
  631. gap: 8px;
  632. padding: 12px 24px;
  633. border: none;
  634. border-radius: 10px;
  635. font-size: 15px;
  636. font-weight: 600;
  637. cursor: pointer;
  638. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  639. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
  640. letter-spacing: 0.3px;
  641. box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  642. position: relative;
  643. overflow: hidden;
  644. }
  645. .action-btn::before {
  646. content: '';
  647. position: absolute;
  648. top: 50%;
  649. left: 50%;
  650. width: 0;
  651. height: 0;
  652. border-radius: 50%;
  653. background: rgba(255, 255, 255, 0.3);
  654. transform: translate(-50%, -50%);
  655. transition: width 0.6s, height 0.6s;
  656. }
  657. .action-btn:hover::before {
  658. width: 300px;
  659. height: 300px;
  660. }
  661. .action-btn:hover {
  662. transform: translateY(-2px);
  663. box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  664. }
  665. .action-btn:active {
  666. transform: translateY(0) scale(0.98);
  667. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
  668. }
  669. .action-btn:disabled {
  670. opacity: 0.5;
  671. cursor: not-allowed;
  672. transform: none;
  673. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  674. }
  675. .action-btn svg {
  676. width: 20px;
  677. height: 20px;
  678. flex-shrink: 0;
  679. transition: transform 0.3s;
  680. }
  681. .action-btn:hover svg {
  682. transform: scale(1.1);
  683. }
  684. /* 下载按钮 */
  685. .download-action-btn {
  686. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  687. color: white;
  688. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  689. }
  690. .download-action-btn:hover {
  691. box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
  692. background: linear-gradient(135deg, #7c8ef0 0%, #8a5fb8 100%);
  693. }
  694. .download-action-btn:active {
  695. background: linear-gradient(135deg, #5a6fd8 0%, #6a3d92 100%);
  696. }
  697. /* 替换按钮 */
  698. .replace-action-btn {
  699. background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  700. color: white;
  701. box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
  702. }
  703. .replace-action-btn:hover {
  704. box-shadow: 0 6px 20px rgba(16, 185, 129, 0.5);
  705. background: linear-gradient(135deg, #34d399 0%, #10b981 100%);
  706. }
  707. .replace-action-btn:active {
  708. background: linear-gradient(135deg, #059669 0%, #047857 100%);
  709. }
  710. /* 响应式设计 */
  711. @media (max-width: 900px) {
  712. .export-modal {
  713. min-width: auto;
  714. width: 95%;
  715. }
  716. .export-preview-container {
  717. flex-direction: column;
  718. }
  719. .export-preview-box {
  720. min-height: 300px;
  721. }
  722. }
  723. /* 下载确认对话框 */
  724. .download-confirm-overlay {
  725. position: fixed;
  726. top: 0;
  727. left: 0;
  728. right: 0;
  729. bottom: 0;
  730. width: 100%;
  731. height: 100%;
  732. background: rgba(0, 0, 0, 0.7);
  733. display: none; /* 默认隐藏 */
  734. align-items: center;
  735. justify-content: center;
  736. z-index: 10000000;
  737. backdrop-filter: blur(4px);
  738. animation: overlayFadeIn 0.3s ease-out;
  739. }
  740. .download-confirm-modal {
  741. background: white;
  742. border-radius: 16px;
  743. padding: 0;
  744. max-width: 600px;
  745. width: 90%;
  746. max-height: 90vh;
  747. overflow: visible;
  748. overflow-y: auto;
  749. box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  750. animation: modalSlideIn 0.3s ease-out;
  751. /* 确保弹窗内容正确显示 */
  752. display: flex;
  753. flex-direction: column;
  754. }
  755. .download-confirm-header {
  756. display: flex;
  757. align-items: center;
  758. justify-content: space-between;
  759. padding: 24px;
  760. border-bottom: 1px solid #e5e7eb;
  761. flex-shrink: 0;
  762. }
  763. .download-confirm-header h3 {
  764. margin: 0;
  765. font-size: 20px;
  766. font-weight: 600;
  767. color: #111827;
  768. }
  769. .download-confirm-close {
  770. width: 36px;
  771. height: 36px;
  772. border-radius: 50%;
  773. background: #f3f4f6;
  774. border: none;
  775. color: #6b7280;
  776. cursor: pointer;
  777. display: flex;
  778. align-items: center;
  779. justify-content: center;
  780. transition: all 0.2s;
  781. padding: 0;
  782. }
  783. .download-confirm-close:hover {
  784. background: #e5e7eb;
  785. color: #374151;
  786. }
  787. .download-confirm-content {
  788. padding: 24px;
  789. display: flex;
  790. flex-direction: column;
  791. gap: 16px;
  792. flex-shrink: 0;
  793. }
  794. .download-option {
  795. display: flex;
  796. align-items: center;
  797. gap: 16px;
  798. padding: 20px;
  799. border: 2px solid #e5e7eb;
  800. border-radius: 12px;
  801. cursor: pointer;
  802. transition: all 0.2s;
  803. background: #f9fafb;
  804. }
  805. .download-option:hover {
  806. border-color: #667eea;
  807. background: #f0f4ff;
  808. transform: translateY(-2px);
  809. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
  810. }
  811. .download-option-icon {
  812. width: 32px;
  813. height: 32px;
  814. flex-shrink: 0;
  815. display: flex;
  816. align-items: center;
  817. justify-content: center;
  818. color: #667eea;
  819. }
  820. .download-option-icon svg {
  821. width: 100%;
  822. height: 100%;
  823. }
  824. .download-option-info {
  825. flex: 1;
  826. }
  827. .download-option-title {
  828. font-size: 16px;
  829. font-weight: 600;
  830. color: #111827;
  831. margin-bottom: 4px;
  832. }
  833. .download-option-desc {
  834. font-size: 14px;
  835. color: #6b7280;
  836. line-height: 1.5;
  837. }
  838. .download-option-price {
  839. margin-top: 8px;
  840. font-size: 16px;
  841. font-weight: 700;
  842. color: #667eea;
  843. background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
  844. padding: 6px 12px;
  845. border-radius: 8px;
  846. display: inline-block;
  847. border: 2px solid rgba(102, 126, 234, 0.3);
  848. box-shadow: 0 2px 8px rgba(102, 126, 234, 0.15);
  849. transition: all 0.3s ease;
  850. }
  851. .download-option:hover .download-option-price {
  852. background: linear-gradient(135deg, rgba(102, 126, 234, 0.15) 0%, rgba(118, 75, 162, 0.15) 100%);
  853. border-color: rgba(102, 126, 234, 0.5);
  854. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.25);
  855. transform: scale(1.05);
  856. }
  857. /* AI生图队列区域 */
  858. .ai-queue-section {
  859. padding: 0 20px 16px;
  860. }
  861. .ai-queue-title {
  862. font-size: 13px;
  863. font-weight: 600;
  864. color: #667eea;
  865. margin-bottom: 12px;
  866. display: flex;
  867. align-items: center;
  868. gap: 6px;
  869. }
  870. .ai-queue-title::before {
  871. content: '';
  872. width: 3px;
  873. height: 14px;
  874. background: linear-gradient(135deg, #667eea, #764ba2);
  875. border-radius: 2px;
  876. }
  877. .ai-queue-list {
  878. display: flex;
  879. gap: 12px;
  880. overflow-x: auto;
  881. overflow-y: hidden;
  882. padding-bottom: 10px;
  883. scroll-behavior: smooth;
  884. -webkit-overflow-scrolling: touch;
  885. }
  886. .ai-queue-list::-webkit-scrollbar {
  887. height: 6px;
  888. }
  889. .ai-queue-list::-webkit-scrollbar-track {
  890. background: #f1f1f1;
  891. border-radius: 3px;
  892. }
  893. .ai-queue-list::-webkit-scrollbar-thumb {
  894. background: linear-gradient(135deg, #667eea, #764ba2);
  895. border-radius: 3px;
  896. }
  897. .ai-queue-list::-webkit-scrollbar-thumb:hover {
  898. background: linear-gradient(135deg, #5a6fd6, #6a4190);
  899. }
  900. .ai-queue-item {
  901. flex-shrink: 0;
  902. width: 100px;
  903. height: 100px;
  904. border-radius: 12px;
  905. overflow: hidden;
  906. position: relative;
  907. background: #f8fafc;
  908. border: 2px solid #e5e7eb;
  909. cursor: pointer;
  910. transition: all 0.3s;
  911. }
  912. .ai-queue-item:hover {
  913. border-color: #667eea;
  914. transform: translateY(-2px);
  915. box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
  916. }
  917. .ai-queue-item.rendering {
  918. border-color: #667eea;
  919. }
  920. .ai-queue-item.completed {
  921. border-color: #10b981;
  922. }
  923. .ai-queue-item.failed {
  924. border-color: #ef4444;
  925. }
  926. .ai-queue-item-preview {
  927. width: 100%;
  928. height: 100%;
  929. object-fit: cover;
  930. filter: blur(4px) brightness(0.8);
  931. }
  932. .ai-queue-item.completed .ai-queue-item-preview {
  933. filter: none;
  934. }
  935. .ai-queue-item-overlay {
  936. position: absolute;
  937. top: 0;
  938. left: 0;
  939. right: 0;
  940. bottom: 0;
  941. display: flex;
  942. flex-direction: column;
  943. align-items: center;
  944. justify-content: center;
  945. background: rgba(0, 0, 0, 0.3);
  946. }
  947. .ai-queue-item.completed .ai-queue-item-overlay {
  948. background: transparent;
  949. opacity: 0;
  950. transition: opacity 0.2s;
  951. }
  952. .ai-queue-item.completed:hover .ai-queue-item-overlay {
  953. opacity: 1;
  954. background: rgba(0, 0, 0, 0.5);
  955. }
  956. .ai-queue-item-spinner {
  957. width: 24px;
  958. height: 24px;
  959. border: 3px solid rgba(255, 255, 255, 0.3);
  960. border-top-color: white;
  961. border-radius: 50%;
  962. animation: spin 1s linear infinite;
  963. }
  964. .ai-queue-item-status {
  965. font-size: 10px;
  966. color: white;
  967. margin-top: 6px;
  968. font-weight: 500;
  969. text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  970. }
  971. .ai-queue-item-icon {
  972. font-size: 20px;
  973. }
  974. .ai-queue-item-actions {
  975. display: flex;
  976. gap: 4px;
  977. }
  978. .ai-queue-item-action {
  979. width: 28px;
  980. height: 28px;
  981. border-radius: 50%;
  982. border: none;
  983. background: white;
  984. color: #667eea;
  985. cursor: pointer;
  986. display: flex;
  987. align-items: center;
  988. justify-content: center;
  989. transition: all 0.2s;
  990. }
  991. .ai-queue-item-action:hover {
  992. background: #667eea;
  993. color: white;
  994. transform: scale(1.1);
  995. }
  996. /* AI生图任务飞走动画 */
  997. .ai-task-fly-animation {
  998. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  999. color: white;
  1000. padding: 12px 20px;
  1001. border-radius: 12px;
  1002. box-shadow: 0 8px 32px rgba(102, 126, 234, 0.4);
  1003. display: flex;
  1004. align-items: center;
  1005. gap: 8px;
  1006. }
  1007. .ai-task-fly-animation .fly-content {
  1008. display: flex;
  1009. align-items: center;
  1010. gap: 8px;
  1011. font-size: 14px;
  1012. font-weight: 600;
  1013. white-space: nowrap;
  1014. }
  1015. .ai-task-fly-animation svg {
  1016. fill: rgba(255, 255, 255, 0.3);
  1017. animation: sparkle 0.3s ease-in-out infinite alternate;
  1018. }
  1019. @keyframes sparkle {
  1020. from {
  1021. filter: drop-shadow(0 0 2px rgba(255, 255, 255, 0.5));
  1022. }
  1023. to {
  1024. filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.8));
  1025. }
  1026. }
  1027. /* 图片放大预览弹窗 */
  1028. .image-preview-modal {
  1029. position: fixed;
  1030. top: 0;
  1031. left: 0;
  1032. right: 0;
  1033. bottom: 0;
  1034. z-index: 200000;
  1035. display: flex;
  1036. align-items: center;
  1037. justify-content: center;
  1038. opacity: 0;
  1039. transition: opacity 0.3s ease;
  1040. }
  1041. .image-preview-modal.show {
  1042. opacity: 1;
  1043. }
  1044. .image-preview-modal-backdrop {
  1045. position: absolute;
  1046. top: 0;
  1047. left: 0;
  1048. right: 0;
  1049. bottom: 0;
  1050. background: rgba(0, 0, 0, 0.85);
  1051. backdrop-filter: blur(8px);
  1052. }
  1053. .image-preview-modal-content {
  1054. position: relative;
  1055. max-width: 90vw;
  1056. max-height: 90vh;
  1057. transform: scale(0.9);
  1058. transition: transform 0.3s ease;
  1059. }
  1060. .image-preview-modal.show .image-preview-modal-content {
  1061. transform: scale(1);
  1062. }
  1063. .image-preview-modal-content img {
  1064. max-width: 100%;
  1065. max-height: 85vh;
  1066. border-radius: 12px;
  1067. box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
  1068. }
  1069. .image-preview-modal-close {
  1070. position: absolute;
  1071. top: -40px;
  1072. right: 0;
  1073. width: 36px;
  1074. height: 36px;
  1075. border: none;
  1076. background: rgba(255, 255, 255, 0.2);
  1077. color: white;
  1078. font-size: 24px;
  1079. border-radius: 50%;
  1080. cursor: pointer;
  1081. transition: all 0.2s;
  1082. display: flex;
  1083. align-items: center;
  1084. justify-content: center;
  1085. line-height: 1;
  1086. }
  1087. .image-preview-modal-close:hover {
  1088. background: rgba(255, 255, 255, 0.3);
  1089. transform: scale(1.1);
  1090. }
  1091. .image-preview-modal-download {
  1092. position: absolute;
  1093. bottom: -50px;
  1094. left: 50%;
  1095. transform: translateX(-50%);
  1096. display: flex;
  1097. align-items: center;
  1098. gap: 8px;
  1099. padding: 10px 24px;
  1100. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  1101. color: white;
  1102. text-decoration: none;
  1103. border-radius: 25px;
  1104. font-size: 14px;
  1105. font-weight: 600;
  1106. transition: all 0.2s;
  1107. box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
  1108. }
  1109. .image-preview-modal-download:hover {
  1110. transform: translateX(-50%) translateY(-2px);
  1111. box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
  1112. }