upload-success-modal.component.scss 26 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247
  1. // 上传成功弹窗样式
  2. // @import '../../../styles/_variables';
  3. // 弹窗背景遮罩
  4. // 响应式断点
  5. $mobile-breakpoint: 768px;
  6. $tablet-breakpoint: 1024px;
  7. $desktop-breakpoint: 1200px;
  8. // 动画变量
  9. $animation-duration-fast: 0.2s;
  10. $animation-duration-normal: 0.3s;
  11. $animation-duration-slow: 0.5s;
  12. $animation-easing: cubic-bezier(0.25, 0.8, 0.25, 1);
  13. .modal-backdrop {
  14. position: fixed;
  15. top: 0;
  16. left: 0;
  17. width: 100vw;
  18. height: 100vh;
  19. background: rgba(0, 0, 0, 0.6);
  20. backdrop-filter: blur(4px);
  21. z-index: 9999;
  22. display: flex;
  23. align-items: center;
  24. justify-content: center;
  25. padding: 1rem;
  26. // 响应式调整
  27. @media (max-width: $mobile-breakpoint) {
  28. padding: 0.5rem;
  29. align-items: flex-end;
  30. }
  31. @media (min-width: $mobile-breakpoint) and (max-width: $tablet-breakpoint) {
  32. padding: 1rem;
  33. }
  34. }
  35. // 弹窗主容器
  36. .modal-container {
  37. background: white;
  38. border-radius: 16px;
  39. box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  40. max-width: 600px;
  41. width: 100%;
  42. max-height: 80vh; // 减少最大高度,为滚动留出更多空间
  43. overflow: hidden;
  44. position: relative;
  45. transform-origin: center;
  46. display: flex;
  47. flex-direction: column;
  48. // 响应式调整
  49. @media (max-width: $mobile-breakpoint) {
  50. max-width: 100%;
  51. border-radius: 16px 16px 0 0;
  52. max-height: 75vh; // 移动端进一步减少高度
  53. margin-top: auto;
  54. }
  55. @media (min-width: $mobile-breakpoint) and (max-width: $tablet-breakpoint) {
  56. max-width: 90%;
  57. max-height: 78vh; // 平板端适中的高度
  58. }
  59. @media (min-width: $tablet-breakpoint) {
  60. max-width: 600px;
  61. max-height: 80vh; // 桌面端保持80vh
  62. }
  63. // 深色模式适配
  64. @media (prefers-color-scheme: dark) {
  65. background: #1a1a1a;
  66. color: #ffffff;
  67. box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
  68. }
  69. }
  70. // 弹窗头部
  71. .modal-header {
  72. padding: 32px 32px 24px 32px; // 增加左右内边距,确保对称
  73. border-bottom: 1px solid #f0f0f0;
  74. display: flex;
  75. align-items: flex-start;
  76. justify-content: space-between;
  77. // 响应式调整
  78. @media (max-width: $mobile-breakpoint) {
  79. padding: 24px 20px 20px 20px;
  80. }
  81. @media (min-width: $mobile-breakpoint) and (max-width: $tablet-breakpoint) {
  82. padding: 28px 28px 22px 28px;
  83. }
  84. .header-content {
  85. display: flex;
  86. align-items: flex-start;
  87. gap: 16px;
  88. flex: 1;
  89. min-width: 0; // 防止内容溢出
  90. .success-icon {
  91. width: 48px;
  92. height: 48px;
  93. background: linear-gradient(135deg, #34C759, #30D158);
  94. border-radius: 50%;
  95. display: flex;
  96. align-items: center;
  97. justify-content: center;
  98. flex-shrink: 0;
  99. svg {
  100. color: white;
  101. width: 24px;
  102. height: 24px;
  103. }
  104. }
  105. .header-text {
  106. flex: 1;
  107. min-width: 0; // 防止文本溢出
  108. h2 {
  109. margin: 0 0 8px 0;
  110. font-size: 20px;
  111. font-weight: 600;
  112. color: #1d1d1f;
  113. line-height: 1.2;
  114. // 响应式字体大小
  115. @media (max-width: $mobile-breakpoint) {
  116. font-size: 18px;
  117. }
  118. }
  119. p {
  120. margin: 0;
  121. font-size: 14px;
  122. color: #86868b;
  123. line-height: 1.4;
  124. @media (max-width: $mobile-breakpoint) {
  125. font-size: 13px;
  126. }
  127. }
  128. }
  129. }
  130. .close-button {
  131. width: 36px;
  132. height: 36px;
  133. border: none;
  134. background: #f2f2f7;
  135. border-radius: 50%;
  136. display: flex;
  137. align-items: center;
  138. justify-content: center;
  139. cursor: pointer;
  140. transition: all 0.2s ease;
  141. flex-shrink: 0;
  142. margin-left: 16px; // 确保与内容区域有适当间距
  143. // 响应式调整
  144. @media (max-width: $mobile-breakpoint) {
  145. width: 32px;
  146. height: 32px;
  147. margin-left: 12px;
  148. }
  149. &:hover {
  150. background: #e5e5ea;
  151. transform: scale(1.05);
  152. }
  153. &:active {
  154. transform: scale(0.95);
  155. }
  156. svg {
  157. color: #86868b;
  158. width: 18px;
  159. height: 18px;
  160. @media (max-width: $mobile-breakpoint) {
  161. width: 16px;
  162. height: 16px;
  163. }
  164. }
  165. }
  166. }
  167. // 弹窗内容
  168. .modal-content {
  169. padding: 0 32px 32px 32px; // 与头部保持一致的左右内边距
  170. overflow-y: auto;
  171. flex: 1;
  172. min-height: 0; // 确保flex子元素可以收缩
  173. // 自定义滚动条样式
  174. &::-webkit-scrollbar {
  175. width: 6px;
  176. }
  177. &::-webkit-scrollbar-track {
  178. background: transparent;
  179. }
  180. &::-webkit-scrollbar-thumb {
  181. background: rgba(0, 0, 0, 0.2);
  182. border-radius: 3px;
  183. &:hover {
  184. background: rgba(0, 0, 0, 0.3);
  185. }
  186. }
  187. // 深色模式滚动条
  188. @media (prefers-color-scheme: dark) {
  189. &::-webkit-scrollbar-thumb {
  190. background: rgba(255, 255, 255, 0.3);
  191. &:hover {
  192. background: rgba(255, 255, 255, 0.4);
  193. }
  194. }
  195. }
  196. // 响应式调整
  197. @media (max-width: $mobile-breakpoint) {
  198. padding: 0 20px 24px 20px;
  199. }
  200. @media (min-width: $mobile-breakpoint) and (max-width: $tablet-breakpoint) {
  201. padding: 0 28px 28px 28px;
  202. }
  203. }
  204. // 上传文件列表
  205. .uploaded-files {
  206. margin-bottom: 32px;
  207. h3 {
  208. margin: 0 0 20px 0;
  209. font-size: 18px;
  210. font-weight: 600;
  211. color: #1d1d1f;
  212. // 响应式字体大小
  213. @media (max-width: $mobile-breakpoint) {
  214. font-size: 16px;
  215. margin-bottom: 16px;
  216. }
  217. }
  218. .file-list {
  219. display: flex;
  220. flex-direction: column;
  221. gap: 12px;
  222. }
  223. .file-item {
  224. display: flex;
  225. align-items: center;
  226. gap: 16px;
  227. padding: 16px;
  228. background: #f9f9f9;
  229. border-radius: 12px;
  230. border: 1px solid #e5e5ea;
  231. transition: all 0.2s ease;
  232. // 响应式调整
  233. @media (max-width: $mobile-breakpoint) {
  234. padding: 12px;
  235. gap: 12px;
  236. }
  237. &:hover {
  238. background: #f5f5f7;
  239. border-color: #d1d1d6;
  240. }
  241. .file-icon {
  242. width: 48px;
  243. height: 48px;
  244. background: #007aff;
  245. border-radius: 10px;
  246. display: flex;
  247. align-items: center;
  248. justify-content: center;
  249. flex-shrink: 0;
  250. // 响应式调整
  251. @media (max-width: $mobile-breakpoint) {
  252. width: 40px;
  253. height: 40px;
  254. border-radius: 8px;
  255. }
  256. svg {
  257. color: white;
  258. width: 24px;
  259. height: 24px;
  260. @media (max-width: $mobile-breakpoint) {
  261. width: 20px;
  262. height: 20px;
  263. }
  264. }
  265. }
  266. .file-preview {
  267. width: 48px;
  268. height: 48px;
  269. border-radius: 10px;
  270. overflow: hidden;
  271. flex-shrink: 0;
  272. @media (max-width: $mobile-breakpoint) {
  273. width: 40px;
  274. height: 40px;
  275. border-radius: 8px;
  276. }
  277. img {
  278. width: 100%;
  279. height: 100%;
  280. object-fit: cover;
  281. }
  282. }
  283. .file-info {
  284. flex: 1;
  285. min-width: 0;
  286. display: flex;
  287. flex-direction: column;
  288. gap: 4px;
  289. .file-name {
  290. font-size: 15px;
  291. font-weight: 500;
  292. color: #1d1d1f;
  293. white-space: nowrap;
  294. overflow: hidden;
  295. text-overflow: ellipsis;
  296. line-height: 1.3;
  297. @media (max-width: $mobile-breakpoint) {
  298. font-size: 14px;
  299. }
  300. }
  301. .file-size {
  302. font-size: 13px;
  303. color: #86868b;
  304. line-height: 1.2;
  305. @media (max-width: $mobile-breakpoint) {
  306. font-size: 12px;
  307. }
  308. }
  309. }
  310. .file-status {
  311. width: 24px;
  312. height: 24px;
  313. display: flex;
  314. align-items: center;
  315. justify-content: center;
  316. flex-shrink: 0;
  317. &.success {
  318. svg {
  319. width: 20px;
  320. height: 20px;
  321. @media (max-width: $mobile-breakpoint) {
  322. width: 18px;
  323. height: 18px;
  324. }
  325. }
  326. }
  327. }
  328. }
  329. }
  330. // 颜色分析区域
  331. .color-analysis-section {
  332. border-top: 1px solid #f0f0f0;
  333. padding-top: 24px;
  334. .section-header {
  335. margin-bottom: 24px;
  336. text-align: center;
  337. h4 {
  338. margin: 0 0 8px 0;
  339. font-size: 18px;
  340. font-weight: 600;
  341. color: #1d1d1f;
  342. @media (max-width: $mobile-breakpoint) {
  343. font-size: 16px;
  344. }
  345. }
  346. p {
  347. margin: 0;
  348. font-size: 14px;
  349. color: #86868b;
  350. line-height: 1.5;
  351. max-width: 400px;
  352. margin: 0 auto;
  353. @media (max-width: $mobile-breakpoint) {
  354. font-size: 13px;
  355. }
  356. }
  357. }
  358. // 分析按钮
  359. .analysis-action {
  360. text-align: center;
  361. padding: 20px 0 32px 0;
  362. .analyze-btn {
  363. display: inline-flex;
  364. align-items: center;
  365. justify-content: center;
  366. gap: 10px;
  367. padding: 14px 28px;
  368. background: linear-gradient(135deg, #007aff, #0056cc);
  369. color: white;
  370. border: none;
  371. border-radius: 12px;
  372. font-size: 15px;
  373. font-weight: 600;
  374. cursor: pointer;
  375. transition: all 0.3s ease;
  376. min-width: 160px;
  377. @media (max-width: $mobile-breakpoint) {
  378. padding: 12px 24px;
  379. font-size: 14px;
  380. min-width: 140px;
  381. }
  382. &:hover:not(:disabled) {
  383. transform: translateY(-2px);
  384. box-shadow: 0 12px 24px rgba(0, 122, 255, 0.25);
  385. background: linear-gradient(135deg, #0056cc, #003d99);
  386. }
  387. &:active {
  388. transform: translateY(0);
  389. }
  390. &:disabled {
  391. opacity: 0.6;
  392. cursor: not-allowed;
  393. transform: none;
  394. box-shadow: none;
  395. }
  396. svg {
  397. width: 20px;
  398. height: 20px;
  399. @media (max-width: $mobile-breakpoint) {
  400. width: 18px;
  401. height: 18px;
  402. }
  403. }
  404. }
  405. }
  406. // 分析加载状态
  407. .analysis-loading {
  408. display: flex;
  409. align-items: center;
  410. gap: 16px;
  411. padding: 24px;
  412. background: #f9f9f9;
  413. border-radius: 12px;
  414. .loading-spinner {
  415. width: 32px;
  416. height: 32px;
  417. border: 3px solid #e5e5ea;
  418. border-top: 3px solid #007aff;
  419. border-radius: 50%;
  420. animation: spin 1s linear infinite;
  421. flex-shrink: 0;
  422. }
  423. .loading-text {
  424. h5 {
  425. margin: 0 0 4px 0;
  426. font-size: 14px;
  427. font-weight: 600;
  428. color: #1d1d1f;
  429. }
  430. p {
  431. margin: 0;
  432. font-size: 12px;
  433. color: #86868b;
  434. }
  435. }
  436. }
  437. // 分析结果
  438. .analysis-result {
  439. .result-header {
  440. display: flex;
  441. align-items: center;
  442. justify-content: space-between;
  443. margin-bottom: 20px;
  444. h5 {
  445. margin: 0;
  446. font-size: 16px;
  447. font-weight: 600;
  448. color: #1d1d1f;
  449. @media (max-width: $mobile-breakpoint) {
  450. font-size: 15px;
  451. }
  452. }
  453. .result-badge {
  454. background: #34c759;
  455. color: white;
  456. font-size: 11px;
  457. font-weight: 600;
  458. padding: 4px 10px;
  459. border-radius: 12px;
  460. text-transform: uppercase;
  461. letter-spacing: 0.5px;
  462. }
  463. }
  464. .color-palette {
  465. display: grid;
  466. grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  467. gap: 16px;
  468. margin-bottom: 24px;
  469. @media (max-width: $mobile-breakpoint) {
  470. grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  471. gap: 12px;
  472. }
  473. .color-item {
  474. display: flex;
  475. align-items: center;
  476. gap: 12px;
  477. padding: 12px;
  478. background: white;
  479. border: 1px solid #e5e5ea;
  480. border-radius: 12px;
  481. transition: all 0.2s ease;
  482. @media (max-width: $mobile-breakpoint) {
  483. padding: 10px;
  484. gap: 10px;
  485. }
  486. &:hover {
  487. border-color: #007aff;
  488. box-shadow: 0 2px 8px rgba(0, 122, 255, 0.1);
  489. }
  490. .color-swatch {
  491. width: 32px;
  492. height: 32px;
  493. border-radius: 8px;
  494. border: 2px solid rgba(255, 255, 255, 0.8);
  495. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  496. flex-shrink: 0;
  497. @media (max-width: $mobile-breakpoint) {
  498. width: 28px;
  499. height: 28px;
  500. border-radius: 6px;
  501. }
  502. }
  503. .color-info {
  504. flex: 1;
  505. min-width: 0;
  506. .color-value {
  507. font-size: 12px;
  508. font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
  509. color: #1d1d1f;
  510. margin-bottom: 4px;
  511. white-space: nowrap;
  512. overflow: hidden;
  513. text-overflow: ellipsis;
  514. font-weight: 500;
  515. @media (max-width: $mobile-breakpoint) {
  516. font-size: 11px;
  517. }
  518. }
  519. .color-percentage {
  520. font-size: 11px;
  521. color: #86868b;
  522. font-weight: 600;
  523. @media (max-width: $mobile-breakpoint) {
  524. font-size: 10px;
  525. }
  526. }
  527. }
  528. }
  529. }
  530. .result-actions {
  531. text-align: center;
  532. padding-top: 8px;
  533. .view-report-btn {
  534. display: inline-flex;
  535. align-items: center;
  536. justify-content: center;
  537. gap: 8px;
  538. padding: 12px 20px;
  539. background: #f2f2f7;
  540. color: #007aff;
  541. border: none;
  542. border-radius: 10px;
  543. font-size: 14px;
  544. font-weight: 600;
  545. cursor: pointer;
  546. transition: all 0.2s ease;
  547. min-width: 140px;
  548. @media (max-width: $mobile-breakpoint) {
  549. padding: 10px 16px;
  550. font-size: 13px;
  551. min-width: 120px;
  552. }
  553. &:hover {
  554. background: #e5e5ea;
  555. transform: translateY(-1px);
  556. }
  557. &:active {
  558. transform: translateY(0);
  559. }
  560. svg {
  561. width: 18px;
  562. height: 18px;
  563. @media (max-width: $mobile-breakpoint) {
  564. width: 16px;
  565. height: 16px;
  566. }
  567. }
  568. }
  569. }
  570. // 颜色描述区域
  571. .color-description {
  572. margin-top: 24px;
  573. padding: 24px;
  574. background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
  575. border: 1px solid #e5e5ea;
  576. border-radius: 16px;
  577. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  578. .description-header {
  579. margin-bottom: 16px;
  580. h6 {
  581. margin: 0 0 4px 0;
  582. font-size: 18px;
  583. font-weight: 700;
  584. color: #1d1d1f;
  585. display: flex;
  586. align-items: center;
  587. gap: 8px;
  588. &::before {
  589. content: '🎨';
  590. font-size: 20px;
  591. }
  592. }
  593. p {
  594. margin: 0;
  595. font-size: 14px;
  596. color: #8e8e93;
  597. font-weight: 400;
  598. }
  599. }
  600. .description-content {
  601. background: #ffffff;
  602. border: 2px solid #f0f0f0;
  603. border-radius: 12px;
  604. padding: 20px;
  605. margin-bottom: 16px;
  606. font-size: 15px;
  607. line-height: 1.7;
  608. color: #333333;
  609. white-space: pre-line;
  610. word-break: break-word;
  611. max-height: 180px;
  612. overflow-y: auto;
  613. font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  614. transition: all 0.2s ease;
  615. &:hover {
  616. border-color: #007aff;
  617. box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
  618. }
  619. &::-webkit-scrollbar {
  620. width: 4px;
  621. }
  622. &::-webkit-scrollbar-track {
  623. background: transparent;
  624. }
  625. &::-webkit-scrollbar-thumb {
  626. background: rgba(0, 122, 255, 0.3);
  627. border-radius: 2px;
  628. &:hover {
  629. background: rgba(0, 122, 255, 0.5);
  630. }
  631. }
  632. &.empty {
  633. color: #8e8e93;
  634. font-style: italic;
  635. text-align: center;
  636. padding: 32px 20px;
  637. background: #fafafa;
  638. border-style: dashed;
  639. }
  640. }
  641. .description-actions {
  642. display: flex;
  643. align-items: center;
  644. justify-content: space-between;
  645. gap: 16px;
  646. @media (max-width: $mobile-breakpoint) {
  647. flex-direction: column;
  648. align-items: stretch;
  649. }
  650. .copy-btn {
  651. display: inline-flex;
  652. align-items: center;
  653. justify-content: center;
  654. gap: 8px;
  655. padding: 12px 20px;
  656. background: linear-gradient(135deg, #007aff 0%, #0056cc 100%);
  657. color: #ffffff;
  658. border: none;
  659. border-radius: 10px;
  660. font-size: 14px;
  661. font-weight: 600;
  662. cursor: pointer;
  663. transition: all 0.3s ease;
  664. min-width: 100px;
  665. box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
  666. &:hover {
  667. transform: translateY(-2px);
  668. box-shadow: 0 6px 20px rgba(0, 122, 255, 0.4);
  669. background: linear-gradient(135deg, #0056cc 0%, #003d99 100%);
  670. }
  671. &:active {
  672. transform: translateY(0);
  673. box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
  674. }
  675. &.copied {
  676. background: linear-gradient(135deg, #34c759 0%, #28a745 100%);
  677. box-shadow: 0 4px 12px rgba(52, 199, 89, 0.3);
  678. &:hover {
  679. background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
  680. box-shadow: 0 6px 20px rgba(52, 199, 89, 0.4);
  681. }
  682. }
  683. svg {
  684. width: 14px;
  685. height: 14px;
  686. }
  687. }
  688. .description-tip {
  689. font-size: 12px;
  690. color: #8e8e93;
  691. flex: 1;
  692. @media (max-width: $mobile-breakpoint) {
  693. text-align: center;
  694. margin-top: 8px;
  695. }
  696. }
  697. }
  698. }
  699. }
  700. // 分析错误
  701. .analysis-error {
  702. display: flex;
  703. align-items: center;
  704. gap: 12px;
  705. padding: 16px;
  706. background: #fff2f2;
  707. border: 1px solid #fecaca;
  708. border-radius: 8px;
  709. .error-icon {
  710. width: 32px;
  711. height: 32px;
  712. background: #ef4444;
  713. border-radius: 50%;
  714. display: flex;
  715. align-items: center;
  716. justify-content: center;
  717. flex-shrink: 0;
  718. svg {
  719. color: white;
  720. width: 16px;
  721. height: 16px;
  722. }
  723. }
  724. .error-text {
  725. flex: 1;
  726. h5 {
  727. margin: 0 0 4px 0;
  728. font-size: 14px;
  729. font-weight: 600;
  730. color: #dc2626;
  731. }
  732. p {
  733. margin: 0;
  734. font-size: 12px;
  735. color: #991b1b;
  736. }
  737. }
  738. .retry-btn {
  739. padding: 6px 12px;
  740. background: #ef4444;
  741. color: white;
  742. border: none;
  743. border-radius: 4px;
  744. font-size: 12px;
  745. font-weight: 500;
  746. cursor: pointer;
  747. transition: all 0.2s ease;
  748. &:hover {
  749. background: #dc2626;
  750. }
  751. }
  752. }
  753. }
  754. // 弹窗底部操作区域
  755. .modal-footer {
  756. padding: 24px 32px 32px;
  757. border-top: 1px solid #e5e5ea;
  758. background: #fafafa;
  759. border-radius: 0 0 20px 20px;
  760. @media (max-width: $tablet-breakpoint) {
  761. padding: 20px 24px 24px;
  762. }
  763. @media (max-width: $mobile-breakpoint) {
  764. padding: 16px 20px 20px;
  765. }
  766. .footer-actions {
  767. display: flex;
  768. gap: 16px;
  769. justify-content: flex-end;
  770. align-items: center;
  771. @media (max-width: $mobile-breakpoint) {
  772. flex-direction: column-reverse;
  773. gap: 12px;
  774. }
  775. .secondary-btn,
  776. .primary-btn {
  777. display: inline-flex;
  778. align-items: center;
  779. justify-content: center;
  780. gap: 8px;
  781. padding: 12px 24px;
  782. border-radius: 10px;
  783. font-size: 14px;
  784. font-weight: 600;
  785. cursor: pointer;
  786. transition: all 0.2s ease;
  787. border: none;
  788. min-width: 120px;
  789. @media (max-width: $mobile-breakpoint) {
  790. width: 100%;
  791. padding: 14px 24px;
  792. }
  793. svg {
  794. width: 18px;
  795. height: 18px;
  796. }
  797. }
  798. .secondary-btn {
  799. background: #f2f2f7;
  800. color: #1d1d1f;
  801. &:hover {
  802. background: #e5e5ea;
  803. transform: translateY(-1px);
  804. }
  805. &:active {
  806. transform: translateY(0);
  807. }
  808. }
  809. .primary-btn {
  810. background: linear-gradient(135deg, #007aff 0%, #0056cc 100%);
  811. color: white;
  812. box-shadow: 0 2px 8px rgba(0, 122, 255, 0.3);
  813. &:hover {
  814. background: linear-gradient(135deg, #0056cc 0%, #003d99 100%);
  815. box-shadow: 0 4px 12px rgba(0, 122, 255, 0.4);
  816. transform: translateY(-1px);
  817. }
  818. &:active {
  819. transform: translateY(0);
  820. box-shadow: 0 2px 6px rgba(0, 122, 255, 0.3);
  821. }
  822. &:disabled {
  823. background: #c7c7cc;
  824. color: #8e8e93;
  825. cursor: not-allowed;
  826. box-shadow: none;
  827. transform: none;
  828. }
  829. .btn-spinner {
  830. width: 14px;
  831. height: 14px;
  832. border: 2px solid rgba(255, 255, 255, 0.3);
  833. border-top: 2px solid white;
  834. border-radius: 50%;
  835. animation: spin 1s linear infinite;
  836. }
  837. }
  838. }
  839. }
  840. // 动画
  841. @keyframes spin {
  842. 0% { transform: rotate(0deg); }
  843. 100% { transform: rotate(360deg); }
  844. }
  845. // 响应式设计
  846. @media (max-width: 768px) {
  847. .modal-backdrop {
  848. padding: 10px;
  849. }
  850. .modal-header {
  851. padding: 20px 16px 12px;
  852. .header-content {
  853. gap: 12px;
  854. .success-icon {
  855. width: 40px;
  856. height: 40px;
  857. svg {
  858. width: 20px;
  859. height: 20px;
  860. }
  861. }
  862. .header-text {
  863. h3 {
  864. font-size: 18px;
  865. }
  866. p {
  867. font-size: 13px;
  868. }
  869. }
  870. }
  871. }
  872. .modal-body {
  873. padding: 0 16px;
  874. }
  875. .modal-footer {
  876. padding: 12px 16px 20px;
  877. .footer-actions {
  878. flex-direction: column-reverse;
  879. .secondary-btn,
  880. .primary-btn {
  881. width: 100%;
  882. justify-content: center;
  883. }
  884. }
  885. }
  886. .color-analysis-section {
  887. .color-palette {
  888. grid-template-columns: 1fr;
  889. }
  890. }
  891. }
  892. // 深色模式支持
  893. @media (prefers-color-scheme: dark) {
  894. .modal-container {
  895. background: #1c1c1e;
  896. .modal-header {
  897. border-bottom-color: #38383a;
  898. .header-text {
  899. h3 {
  900. color: #f2f2f7;
  901. }
  902. p {
  903. color: #8e8e93;
  904. }
  905. }
  906. .close-btn {
  907. background: #2c2c2e;
  908. &:hover {
  909. background: #3a3a3c;
  910. }
  911. svg {
  912. color: #8e8e93;
  913. }
  914. }
  915. }
  916. .uploaded-files-section {
  917. h4 {
  918. color: #f2f2f7;
  919. }
  920. .file-item {
  921. background: #2c2c2e;
  922. border-color: #48484a;
  923. .file-info {
  924. .file-name {
  925. color: #f2f2f7;
  926. }
  927. .file-size {
  928. color: #8e8e93;
  929. }
  930. }
  931. }
  932. }
  933. .color-analysis-section {
  934. .section-header {
  935. h4 {
  936. color: #f2f2f7;
  937. }
  938. p {
  939. color: #8e8e93;
  940. }
  941. }
  942. .analysis-loading {
  943. background: #2c2c2e;
  944. .loading-text {
  945. h5 {
  946. color: #f2f2f7;
  947. }
  948. p {
  949. color: #8e8e93;
  950. }
  951. }
  952. }
  953. .analysis-result {
  954. .result-header {
  955. h5 {
  956. color: #f2f2f7;
  957. }
  958. .result-count {
  959. background: #2c2c2e;
  960. color: #8e8e93;
  961. }
  962. }
  963. .color-palette {
  964. .color-item {
  965. background: #2c2c2e;
  966. border-color: #48484a;
  967. .color-info {
  968. .color-value {
  969. color: #f2f2f7;
  970. }
  971. .color-percentage {
  972. color: #8e8e93;
  973. }
  974. }
  975. }
  976. }
  977. .result-actions {
  978. .view-report-btn {
  979. background: #2c2c2e;
  980. &:hover {
  981. background: #3a3a3c;
  982. }
  983. }
  984. }
  985. .color-description {
  986. background: linear-gradient(135deg, #2c2c2e 0%, #1c1c1e 100%);
  987. border-color: #48484a;
  988. box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  989. .description-header {
  990. h6 {
  991. color: #f2f2f7;
  992. }
  993. p {
  994. color: #8e8e93;
  995. }
  996. }
  997. .description-content {
  998. background: #1c1c1e;
  999. border-color: #48484a;
  1000. color: #f2f2f7;
  1001. &:hover {
  1002. border-color: #0a84ff;
  1003. box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.2);
  1004. }
  1005. &::-webkit-scrollbar-thumb {
  1006. background: rgba(10, 132, 255, 0.4);
  1007. &:hover {
  1008. background: rgba(10, 132, 255, 0.6);
  1009. }
  1010. }
  1011. &.empty {
  1012. background: #2c2c2e;
  1013. color: #8e8e93;
  1014. border-color: #48484a;
  1015. }
  1016. }
  1017. .description-actions {
  1018. .copy-btn {
  1019. background: linear-gradient(135deg, #0a84ff 0%, #0056cc 100%);
  1020. box-shadow: 0 4px 12px rgba(10, 132, 255, 0.3);
  1021. &:hover {
  1022. background: linear-gradient(135deg, #0056cc 0%, #003d99 100%);
  1023. box-shadow: 0 6px 20px rgba(10, 132, 255, 0.4);
  1024. }
  1025. &.copied {
  1026. background: linear-gradient(135deg, #30d158 0%, #28a745 100%);
  1027. box-shadow: 0 4px 12px rgba(48, 209, 88, 0.3);
  1028. &:hover {
  1029. background: linear-gradient(135deg, #28a745 0%, #1e7e34 100%);
  1030. box-shadow: 0 6px 20px rgba(48, 209, 88, 0.4);
  1031. }
  1032. }
  1033. }
  1034. }
  1035. }
  1036. }
  1037. }
  1038. .modal-footer {
  1039. border-top-color: #38383a;
  1040. .footer-actions {
  1041. .secondary-btn {
  1042. background: #2c2c2e;
  1043. color: #f2f2f7;
  1044. &:hover {
  1045. background: #3a3a3c;
  1046. }
  1047. }
  1048. }
  1049. }
  1050. }
  1051. }