consultation-order.scss 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680
  1. // iOS风格变量定义
  2. $primary-color: #007AFF;
  3. $primary-dark: #0062CC;
  4. $secondary-color: #34C759;
  5. $success-color: #34C759;
  6. $warning-color: #FF9500;
  7. $danger-color: #FF3B30;
  8. $text-primary: #000000;
  9. $text-secondary: #3C3C43;
  10. $text-tertiary: #8E8E93;
  11. $border-color: #D1D1D6;
  12. $background-primary: #FFFFFF;
  13. $background-secondary: #F2F2F7;
  14. $background-tertiary: #E5E5EA;
  15. $shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  16. $shadow-md: 0 4px 10px rgba(0,0,0,0.1);
  17. $shadow-lg: 0 10px 30px rgba(0,0,0,0.1);
  18. $border-radius: 10px;
  19. $transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
  20. $main-font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', sans-serif;
  21. $heading-font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', sans-serif;
  22. $grid-gap: 16px;
  23. $card-padding: 16px;
  24. // iOS风格主容器
  25. .consultation-order-container {
  26. max-width: 100%;
  27. margin: 0 auto;
  28. padding: 16px;
  29. color: $text-primary;
  30. font-family: $main-font-family;
  31. font-size: 17px;
  32. line-height: 1.5;
  33. min-height: 100vh;
  34. background-color: $background-secondary;
  35. @media (min-width: 768px) {
  36. padding: 20px;
  37. display: grid;
  38. grid-template-columns: 1fr;
  39. gap: $grid-gap;
  40. }
  41. @media (min-width: 1024px) {
  42. grid-template-columns: 280px 1fr;
  43. max-width: 1200px;
  44. }
  45. }
  46. // 页面标题 - 财务风格
  47. .page-header {
  48. grid-column: 1 / -1;
  49. margin-bottom: $grid-gap;
  50. padding-bottom: 16px;
  51. border-bottom: 1px solid $border-color;
  52. h1 {
  53. font-size: 24px;
  54. font-weight: 500;
  55. margin: 0 0 8px 0;
  56. color: $text-primary;
  57. font-family: $heading-font-family;
  58. display: flex;
  59. align-items: center;
  60. gap: 12px;
  61. }
  62. p {
  63. font-size: 14px;
  64. color: $text-secondary;
  65. margin: 0;
  66. }
  67. }
  68. // 成功提示
  69. .success-message {
  70. display: flex;
  71. align-items: center;
  72. gap: 8px;
  73. padding: 12px 16px;
  74. background-color: color-mix(in srgb, $success-color 10%, transparent);
  75. color: $success-color;
  76. border-radius: $border-radius;
  77. border-left: 4px solid $success-color;
  78. margin-bottom: 24px;
  79. animation: slideIn 0.3s ease;
  80. }
  81. @keyframes slideIn {
  82. from {
  83. opacity: 0;
  84. transform: translateY(-10px);
  85. }
  86. to {
  87. opacity: 1;
  88. transform: translateY(0);
  89. }
  90. }
  91. // 通用区域样式 - 财务风格
  92. .section-header {
  93. display: flex;
  94. justify-content: space-between;
  95. align-items: center;
  96. margin-bottom: 16px;
  97. h2 {
  98. font-size: 18px;
  99. font-weight: 500;
  100. color: $text-primary;
  101. font-family: $heading-font-family;
  102. margin: 0;
  103. display: flex;
  104. align-items: center;
  105. gap: 8px;
  106. }
  107. .section-actions {
  108. display: flex;
  109. gap: 8px;
  110. }
  111. }
  112. // iOS风格卡片
  113. .card {
  114. background-color: $background-primary;
  115. border-radius: $border-radius;
  116. padding: $card-padding;
  117. margin-bottom: $grid-gap;
  118. transition: $transition;
  119. border: 0.5px solid rgba(0,0,0,0.1);
  120. &:hover {
  121. box-shadow: $shadow-sm;
  122. }
  123. &.highlight {
  124. border-left: 4px solid $primary-color;
  125. }
  126. + .card {
  127. margin-top: -$grid-gap/2;
  128. border-top: 0.5px solid $border-color;
  129. border-radius: 0 0 $border-radius $border-radius;
  130. }
  131. }
  132. // 客户信息区域
  133. .customer-info-section {
  134. @extend .card;
  135. @extend .highlight;
  136. }
  137. // 客户搜索
  138. .customer-search {
  139. margin-bottom: 24px;
  140. }
  141. .search-input-group {
  142. display: flex;
  143. align-items: center;
  144. position: relative;
  145. max-width: 400px;
  146. }
  147. .search-input {
  148. flex: 1;
  149. padding: 10px 12px;
  150. border: 1px solid $border-color;
  151. border-radius: $border-radius 0 0 $border-radius;
  152. font-size: 14px;
  153. transition: $transition;
  154. &:focus {
  155. outline: none;
  156. border-color: $primary-color;
  157. box-shadow: 0 0 0 3px color-mix(in srgb, $primary-color 10%, transparent);
  158. }
  159. }
  160. .search-btn {
  161. padding: 10px 16px;
  162. background-color: $primary-color;
  163. color: white;
  164. border: none;
  165. border-radius: 0 $border-radius $border-radius 0;
  166. cursor: pointer;
  167. transition: $transition;
  168. &:hover {
  169. background-color: $primary-dark;
  170. transform: translateY(-1px);
  171. box-shadow: $shadow-md;
  172. }
  173. &:active {
  174. transform: translateY(0);
  175. }
  176. }
  177. // 搜索结果
  178. .search-results {
  179. position: absolute;
  180. top: 100%;
  181. left: 0;
  182. right: 0;
  183. margin-top: 4px;
  184. background-color: $background-primary;
  185. border: 1px solid $border-color;
  186. border-radius: $border-radius;
  187. box-shadow: $shadow-lg;
  188. z-index: 1000;
  189. max-height: 300px;
  190. overflow-y: auto;
  191. }
  192. .customer-item {
  193. display: flex;
  194. align-items: center;
  195. gap: 12px;
  196. padding: 12px 16px;
  197. cursor: pointer;
  198. transition: $transition;
  199. &:hover {
  200. background-color: $background-secondary;
  201. }
  202. }
  203. .customer-avatar {
  204. width: 36px;
  205. height: 36px;
  206. border-radius: 50%;
  207. object-fit: cover;
  208. }
  209. .customer-details {
  210. flex: 1;
  211. }
  212. .customer-name {
  213. font-weight: 500;
  214. color: $text-primary;
  215. margin-bottom: 2px;
  216. }
  217. .customer-phone {
  218. font-size: 12px;
  219. color: $text-secondary;
  220. margin-bottom: 4px;
  221. }
  222. .customer-tags {
  223. display: flex;
  224. gap: 6px;
  225. }
  226. .tag {
  227. font-size: 11px;
  228. padding: 2px 8px;
  229. background-color: color-mix(in srgb, $primary-color 10%, transparent);
  230. color: $primary-color;
  231. border-radius: 12px;
  232. }
  233. .tag.source {
  234. background-color: color-mix(in srgb, $secondary-color 10%, transparent);
  235. color: $secondary-color;
  236. }
  237. // 偏好标签样式
  238. .tags-container {
  239. margin-top: 12px;
  240. }
  241. .preference-tag {
  242. background-color: color-mix(in srgb, $primary-color 15%, transparent);
  243. color: $primary-color;
  244. font-size: 16px;
  245. padding: 8px 16px;
  246. margin-right: 12px;
  247. margin-bottom: 12px;
  248. font-weight: 500;
  249. border-radius: 24px;
  250. transition: all 0.3s ease;
  251. &:hover {
  252. background-color: color-mix(in srgb, $primary-color 30%, transparent);
  253. }
  254. }
  255. .tag-input {
  256. font-size: 16px;
  257. padding: 8px;
  258. margin-top: 8px;
  259. width: 100%;
  260. border: 2px solid $border-color;
  261. border-radius: 8px;
  262. transition: border-color 0.3s ease;
  263. &:focus {
  264. outline: none;
  265. border-color: $primary-color;
  266. }
  267. }
  268. // 预设标签样式
  269. .preset-tags {
  270. margin-top: 16px;
  271. display: flex;
  272. flex-wrap: wrap;
  273. align-items: center;
  274. gap: 12px;
  275. }
  276. .preset-label {
  277. font-size: 16px;
  278. font-weight: 600;
  279. color: $text-primary;
  280. min-width: 100px;
  281. }
  282. .preset-tag-btn {
  283. padding: 8px 16px;
  284. background-color: $background-tertiary;
  285. color: $text-secondary;
  286. border: 2px solid $border-color;
  287. border-radius: 24px;
  288. font-size: 14px;
  289. cursor: pointer;
  290. transition: all 0.3s ease;
  291. &:hover {
  292. background-color: color-mix(in srgb, $primary-color 10%, transparent);
  293. color: $primary-color;
  294. border-color: $primary-color;
  295. transform: translateY(-2px);
  296. }
  297. &.active {
  298. background-color: $primary-color;
  299. color: white;
  300. border-color: $primary-color;
  301. }
  302. }
  303. // 表单样式
  304. .customer-form,
  305. .requirement-form {
  306. .form-row {
  307. display: flex;
  308. gap: 24px; // 增加行内表单元素间距防止重合
  309. margin-bottom: 24px;
  310. flex-wrap: wrap;
  311. }
  312. .form-group {
  313. flex: 1;
  314. min-width: 200px;
  315. label {
  316. display: block;
  317. font-size: 18px; // 放大表单标签
  318. font-weight: 500;
  319. color: $text-primary;
  320. margin-bottom: 8px;
  321. }
  322. input,
  323. select,
  324. textarea {
  325. width: 100%;
  326. padding: 12px 16px; // 增加内边距
  327. border: 1px solid $border-color;
  328. border-radius: $border-radius;
  329. font-size: 16px; // 放大输入元素字体
  330. transition: $transition;
  331. &:focus {
  332. outline: none;
  333. border-color: $primary-color;
  334. box-shadow: 0 0 0 3px color-mix(in srgb, $primary-color 10%, transparent);
  335. }
  336. }
  337. textarea {
  338. resize: vertical;
  339. min-height: 80px;
  340. line-height: 1.6;
  341. }
  342. }
  343. .form-group.full-width {
  344. min-width: 100%;
  345. }
  346. }
  347. .required {
  348. color: $danger-color;
  349. }
  350. // 清除客户按钮
  351. .clear-customer-btn {
  352. padding: 6px 12px;
  353. background-color: transparent;
  354. color: $text-secondary;
  355. border: 1px solid $border-color;
  356. border-radius: $border-radius;
  357. font-size: 14px;
  358. cursor: pointer;
  359. transition: $transition;
  360. &:hover {
  361. background-color: $background-secondary;
  362. border-color: $danger-color;
  363. color: $danger-color;
  364. }
  365. }
  366. // 需求信息区域
  367. .requirement-section {
  368. @extend .card;
  369. }
  370. // 报价与案例匹配区域
  371. .price-match-section {
  372. @extend .card;
  373. }
  374. // 价格信息
  375. .price-info {
  376. display: flex;
  377. justify-content: space-between;
  378. align-items: center;
  379. padding: 20px 24px;
  380. background-color: color-mix(in srgb, $primary-color 5%, transparent);
  381. border-radius: $border-radius;
  382. margin-bottom: 24px;
  383. box-shadow: $shadow-sm;
  384. }
  385. .price-label {
  386. font-size: 18px; // 放大价格标签
  387. color: $text-secondary;
  388. font-weight: 500;
  389. }
  390. .price-value {
  391. font-size: 24px; // 放大价格值
  392. font-weight: 700;
  393. color: $primary-color;
  394. letter-spacing: 0.5px;
  395. }
  396. // 匹配案例
  397. .matched-cases {
  398. h3 {
  399. font-size: 18px;
  400. font-weight: 600;
  401. color: $text-primary;
  402. margin-bottom: 16px;
  403. }
  404. }
  405. .cases-grid {
  406. display: grid;
  407. grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  408. gap: 16px;
  409. }
  410. .case-card {
  411. background-color: $background-tertiary;
  412. border: 2px solid transparent;
  413. border-radius: $border-radius;
  414. overflow: hidden;
  415. cursor: pointer;
  416. transition: $transition;
  417. &:hover {
  418. border-color: $primary-color;
  419. transform: translateY(-2px);
  420. box-shadow: $shadow-md;
  421. }
  422. }
  423. .case-image {
  424. width: 100%;
  425. height: 180px;
  426. object-fit: cover;
  427. }
  428. .case-info {
  429. padding: 16px;
  430. }
  431. .case-name {
  432. font-size: 16px;
  433. font-weight: 500;
  434. color: $text-primary;
  435. margin-bottom: 8px;
  436. }
  437. .case-details {
  438. display: flex;
  439. justify-content: space-between;
  440. align-items: center;
  441. margin-bottom: 8px;
  442. .case-designer,
  443. .case-area {
  444. font-size: 13px;
  445. color: $text-secondary;
  446. }
  447. }
  448. .similarity-badge {
  449. display: inline-block;
  450. padding: 4px 12px;
  451. background-color: color-mix(in srgb, $success-color 10%, transparent);
  452. color: $success-color;
  453. border-radius: 12px;
  454. font-size: 12px;
  455. font-weight: 500;
  456. }
  457. // 已选参考案例
  458. .selected-cases {
  459. margin-top: 24px;
  460. h3 {
  461. font-size: 16px;
  462. font-weight: 600;
  463. color: $text-primary;
  464. margin-bottom: 12px;
  465. }
  466. }
  467. .selected-cases-list {
  468. display: flex;
  469. flex-wrap: wrap;
  470. gap: 8px;
  471. }
  472. .selected-case-item {
  473. display: flex;
  474. align-items: center;
  475. gap: 6px;
  476. padding: 6px 12px;
  477. background-color: color-mix(in srgb, $primary-color 10%, transparent);
  478. color: $primary-color;
  479. border-radius: 16px;
  480. font-size: 13px;
  481. }
  482. .remove-case-btn {
  483. background: none;
  484. border: none;
  485. color: $text-tertiary;
  486. cursor: pointer;
  487. padding: 2px;
  488. transition: $transition;
  489. &:hover {
  490. color: $danger-color;
  491. }
  492. }
  493. // iOS风格操作按钮区域
  494. .action-section {
  495. background-color: $background-tertiary;
  496. padding: 16px;
  497. position: fixed;
  498. bottom: 0;
  499. left: 0;
  500. right: 0;
  501. z-index: 100;
  502. display: flex;
  503. gap: 16px;
  504. justify-content: space-between;
  505. border-top: 0.5px solid $border-color;
  506. @media (min-width: 768px) {
  507. position: sticky;
  508. bottom: 20px;
  509. left: auto;
  510. right: auto;
  511. width: calc(100% - 40px);
  512. max-width: 1200px;
  513. margin: $grid-gap auto 0;
  514. border-radius: $border-radius;
  515. border: 0.5px solid rgba(0,0,0,0.1);
  516. box-shadow: $shadow-sm;
  517. }
  518. .primary-btn, .secondary-btn {
  519. flex: 1;
  520. text-align: center;
  521. }
  522. }
  523. .primary-btn,
  524. .secondary-btn {
  525. padding: 16px 32px; // 增大按钮尺寸
  526. border-radius: $border-radius;
  527. font-size: 18px; // 放大按钮字体
  528. font-weight: 600;
  529. cursor: pointer;
  530. transition: $transition;
  531. border: none;
  532. display: inline-flex;
  533. align-items: center;
  534. justify-content: center;
  535. gap: 8px;
  536. min-width: 160px;
  537. text-transform: none;
  538. letter-spacing: 0.5px;
  539. }
  540. .primary-btn {
  541. background-color: $primary-color;
  542. color: white;
  543. &:hover:not(:disabled) {
  544. background-color: $primary-dark;
  545. transform: translateY(-2px);
  546. box-shadow: $shadow-md;
  547. }
  548. &:active:not(:disabled) {
  549. transform: translateY(0);
  550. }
  551. &:disabled {
  552. background-color: $text-tertiary;
  553. cursor: not-allowed;
  554. }
  555. }
  556. .secondary-btn {
  557. background-color: $background-tertiary;
  558. color: $text-primary;
  559. border: 2px solid $border-color;
  560. &:hover:not(:disabled) {
  561. background-color: $background-secondary;
  562. border-color: $primary-color;
  563. color: $primary-color;
  564. transform: translateY(-2px);
  565. box-shadow: $shadow-md;
  566. }
  567. &:active:not(:disabled) {
  568. transform: translateY(0);
  569. }
  570. &:disabled {
  571. background-color: $background-tertiary;
  572. color: $text-tertiary;
  573. border-color: $border-color;
  574. cursor: not-allowed;
  575. }
  576. }
  577. // 响应式设计
  578. @media (max-width: 768px) {
  579. .consultation-order-container {
  580. padding: 16px;
  581. }
  582. .page-header {
  583. h1 {
  584. font-size: 24px;
  585. }
  586. }
  587. .form-row {
  588. flex-direction: column;
  589. gap: 12px;
  590. }
  591. .form-group {
  592. min-width: 100%;
  593. }
  594. .cases-grid {
  595. grid-template-columns: 1fr;
  596. }
  597. .action-section {
  598. flex-direction: column;
  599. }
  600. .primary-btn,
  601. .secondary-btn {
  602. width: 100%;
  603. }
  604. .section-header {
  605. flex-direction: column;
  606. align-items: flex-start;
  607. gap: 8px;
  608. }
  609. }