index.scss 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694
  1. // 全局样式文件:src/styles/index.scss
  2. // 1. 全局变量(可统一管理颜色、字体、间距等)
  3. $primary-color: #2D71FF; // 主色调(和 Element Plus 主色一致)
  4. $secondary-color: #667eea; // 辅助色
  5. $text-color: #333333; // 主要文字色
  6. $text-light-color: #666666; // 次要文字色
  7. $border-color: #eeeeee; // 边框色
  8. $bg-color: #f9f9f9; // 背景色
  9. $danger-color: #e63946; // 危险色(价格、警告等)
  10. .el-button--primary {
  11. &:not(.is-plain) {
  12. background-color: $primary-color;
  13. border-color: $primary-color;
  14. }
  15. &.is-plain {
  16. // color: $primary-color;
  17. border:none;
  18. // background-color: #ffffff;
  19. }
  20. }
  21. .container-height {
  22. min-height: calc(100vh - 60px);
  23. margin-bottom: 140px;
  24. }
  25. // 2. 全局重置样式(统一浏览器默认样式)
  26. * {
  27. box-sizing: border-box;
  28. font-family: PingFang SC, PingFang SC;
  29. }
  30. H1,
  31. H2,
  32. H3,
  33. H4,
  34. H5,
  35. H6,
  36. P {
  37. margin: 0;
  38. }
  39. body ,htm{
  40. font-family: "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  41. color: $text-color;
  42. background-color: #f5f5f5;
  43. line-height: 1.6;
  44. margin: 0;
  45. }
  46. body{
  47. background: url('@/assets/imgs/bg_2.png') no-repeat center center fixed;
  48. background-size: 100% 100%;
  49. }
  50. .detail_right{
  51. width: 410px;
  52. }
  53. .detail_right_content{
  54. position: fixed;
  55. }
  56. .contactInfo_bg{
  57. background: #F5F7FA;
  58. border-radius: 8px 8px 8px 8px;
  59. }
  60. // 3. 公共样式类(全局可复用)
  61. // 容器宽度限制(统一页面最大宽度,居中显示)
  62. .container {
  63. max-width: 1528px;
  64. width: 80%;
  65. min-width: 1200px;
  66. margin: 0 auto;
  67. // padding: 20px;
  68. padding: 0 4px;
  69. }
  70. .gradient{
  71. background: linear-gradient( 90deg, #0055FE 0%, #C832FA 100%);
  72. border: none;
  73. }
  74. // 清除浮动
  75. .clearfix::after {
  76. content: "";
  77. display: block;
  78. clear: both;
  79. }
  80. // 禁用选中
  81. .no-select {
  82. user-select: none;
  83. -webkit-user-select: none;
  84. }
  85. // 调整折叠面板样式
  86. .el-collapse-item__header {
  87. background-color: $bg-color;
  88. }
  89. // 5. 响应式相关样式(全局通用)
  90. // 小屏幕(手机)
  91. @media (max-width: 768px) {
  92. .container {
  93. // padding: 0 10px;
  94. }
  95. }
  96. // 中屏幕(平板)
  97. @media (min-width: 769px) and (max-width: 1024px) {
  98. .container {
  99. // padding: 0 15px;
  100. }
  101. }
  102. @charset "UTF-8";
  103. wx-image{
  104. height: auto;
  105. }
  106. .padding8 {
  107. padding: 8px
  108. }
  109. .padding12 {
  110. padding: 12px
  111. }
  112. .padding16 {
  113. padding: 16px
  114. }
  115. .padding20 {
  116. padding: 20px
  117. }
  118. .paddingTB20 {
  119. padding: 20px 0
  120. }
  121. .paddingTB30 {
  122. padding: 30px 0
  123. }
  124. .paddingTB10 {
  125. padding: 10px 0
  126. }
  127. .pad20 {
  128. padding: 0 20px
  129. }
  130. .padding15 {
  131. padding: 15px
  132. }
  133. .padding30 {
  134. padding: 30px
  135. }
  136. .pad30 {
  137. padding: 0 30px
  138. }
  139. .pt20 {
  140. padding-top: 20px
  141. }
  142. .pb15 {
  143. padding-bottom: 15px
  144. }
  145. .pb20 {
  146. padding-bottom: 20px
  147. }
  148. .pb30 {
  149. padding-bottom: 30px
  150. }
  151. .mb30 {
  152. margin-bottom: 30px;
  153. }
  154. .mr10 {
  155. margin-right: 10px;
  156. }
  157. .mr20 {
  158. margin-right: 20px;
  159. }
  160. .mr30 {
  161. margin-right: 30px;
  162. }
  163. .mr10 {
  164. margin-right: 10px;
  165. }
  166. .ml5 {
  167. margin-left: 5px;
  168. }
  169. .ml10 {
  170. margin-left: 10px;
  171. }
  172. .ml20 {
  173. margin-left: 20px;
  174. }
  175. .mt2 {
  176. margin-top: 2px;
  177. }
  178. .mt16 {
  179. margin-top: 16px;
  180. }
  181. .mt20 {
  182. margin-top: 20px;
  183. }
  184. .mt30 {
  185. margin-top: 30px;
  186. }
  187. .mt16 {
  188. margin-top: 16px;
  189. }
  190. .mt10 {
  191. margin-top: 10px;
  192. }
  193. .mt5 {
  194. margin-top: 5px;
  195. }
  196. .mb20 {
  197. margin-bottom: 20px;
  198. }
  199. .mb10 {
  200. margin-bottom: 10px;
  201. }
  202. .ellipsis {
  203. overflow: hidden;
  204. text-overflow: ellipsis;
  205. white-space: nowrap
  206. }
  207. .line1 {
  208. word-break: break-all;
  209. display: -webkit-box;
  210. -webkit-line-clamp: 1;
  211. -webkit-box-orient: vertical;
  212. overflow: hidden;
  213. /* height: 84px; */
  214. }
  215. .line2 {
  216. word-break: break-all;
  217. display: -webkit-box;
  218. -webkit-line-clamp: 2;
  219. -webkit-box-orient: vertical;
  220. overflow: hidden;
  221. /* height: 84px; */
  222. }
  223. .line3 {
  224. word-break: break-all;
  225. display: -webkit-box;
  226. -webkit-line-clamp: 3;
  227. -webkit-box-orient: vertical;
  228. overflow: hidden;
  229. /* height: 84px; */
  230. }
  231. .mask {
  232. position: fixed;
  233. top: 0;
  234. left: 0;
  235. right: 0;
  236. bottom: 0;
  237. background-color: #000;
  238. opacity: .5;
  239. z-index: 5
  240. }
  241. @keyframes load {
  242. from {
  243. transform: rotate(0)
  244. }
  245. to {
  246. transform: rotate(360deg)
  247. }
  248. }
  249. @-webkit-keyframes load {
  250. from {
  251. transform: rotate(0)
  252. }
  253. to {
  254. transform: rotate(360deg)
  255. }
  256. }
  257. .loadingpic {
  258. animation: load 3s linear 1s infinite;
  259. --webkit-animation: load 3s linear 1s infinite
  260. }
  261. .loading-list {
  262. animation: load linear 1s infinite;
  263. -webkit-animation: load linear 1s infinite;
  264. font-size: 40px;
  265. margin-right: 22px
  266. }
  267. .loading {
  268. width: 100%;
  269. height: 100px;
  270. line-height: 100px;
  271. align-items: center;
  272. justify-content: center;
  273. position: relative;
  274. text-align: center
  275. }
  276. .loading .line {
  277. position: absolute;
  278. width: 450px;
  279. left: 150px;
  280. top: 50px;
  281. height: 1px;
  282. border-top: 1px solid #eee
  283. }
  284. .loading .text {
  285. position: relative;
  286. display: inline-block;
  287. padding: 0 20px;
  288. background: #fff;
  289. z-index: 2;
  290. color: #777
  291. }
  292. .loadingicon .loading {
  293. animation: load linear 1s infinite;
  294. font-size: 45px;
  295. color: #000
  296. }
  297. .loadingicon {
  298. width: 100%;
  299. height: 80px;
  300. overflow: hidden
  301. }
  302. .bg-color-huic{
  303. background: #F1F1F1!important;
  304. border: 1px solid #ccc!important;
  305. color: #ccc!important;
  306. }
  307. .cursor-pointer{
  308. cursor: pointer;
  309. }
  310. .nowrap{
  311. white-space: nowrap;
  312. }
  313. .gap10{
  314. gap: 10px;
  315. }
  316. //首行缩进2em
  317. .indent_28{
  318. text-indent: 28px;
  319. }
  320. /*flex样式*/
  321. .flex_1{
  322. flex:1;
  323. }
  324. .flex{
  325. display: flex;
  326. }
  327. .flex_2{
  328. flex: 2;
  329. }
  330. .flex-between{/*两边对齐*/
  331. display: flex;
  332. justify-content: space-between;
  333. }
  334. .flex-align-center{/*垂直居中*/
  335. display: flex !important;
  336. align-items: center;
  337. }
  338. .flex-center{/*水平垂直居中*/
  339. display: flex;
  340. justify-content: center;
  341. align-items: center;
  342. }
  343. .flex-center-flex-end{/*水平垂直居中-尾部对齐*/
  344. display: flex;
  345. justify-content: flex-end;
  346. align-items: center;
  347. }
  348. .flex-center-box-end{/*水平垂直居中-铺满盒内*/
  349. display: -webkit-inline-box;
  350. justify-content: flex-end;
  351. align-items: center;
  352. }
  353. .flex-center-flex-start{/*水平垂直居中-首部对齐*/
  354. display: flex;
  355. justify-content: flex-start;
  356. align-items: center;
  357. }
  358. .flex-center-around{/*水平垂直居中-平均对齐*/
  359. display: flex;
  360. justify-content: space-around;
  361. align-items: center;
  362. }
  363. .flex-center-between{/*水平垂直居中-两边对齐*/
  364. display: flex;
  365. justify-content: space-between;
  366. align-items: center;
  367. }
  368. .flex-column{/*竖直方向*/
  369. display: flex;
  370. flex-direction: column;
  371. }
  372. .flex-column-center{/*竖直方向水平居中 两端对齐*/
  373. display: flex;
  374. flex-direction: column;
  375. justify-content: space-between;
  376. align-items: center;
  377. }
  378. .flex-column-start{/*竖直方向水平居中 首部对齐*/
  379. display: flex;
  380. flex-direction: column;
  381. justify-content: space-around;
  382. align-items: self-start;
  383. }
  384. .flex-column-start-between{/*竖直方向-首部对齐-两端对齐*/
  385. display: flex;
  386. flex-direction: column;
  387. justify-content: space-between;
  388. align-items: self-start;
  389. }
  390. .flex-column-align{/*竖直方向水平居中*/
  391. display: flex;
  392. flex-direction: column;
  393. align-items: center;
  394. }
  395. .flex-center-flex-start-warp{/*水平垂直居中-首部对齐*/
  396. display: flex;
  397. justify-content: flex-start;
  398. align-items: center;
  399. flex-wrap:wrap ;
  400. }
  401. .gap5{
  402. //水平垂直居中-首部对齐 间隙10px
  403. display: flex;
  404. justify-content: flex-start;
  405. align-items: center;
  406. gap: 5px;
  407. flex-wrap:wrap ;
  408. }
  409. .gap10{
  410. //水平垂直居中-首部对齐 间隙10px
  411. display: flex;
  412. justify-content: flex-start;
  413. align-items: center;
  414. gap: 10px;
  415. flex-wrap:wrap ;
  416. }
  417. .gap20{
  418. //水平垂直居中-首部对齐 间隙10px
  419. display: flex;
  420. justify-content: flex-start;
  421. align-items: center;
  422. gap: 20px;
  423. flex-wrap:wrap ;
  424. }
  425. //课程网格布局
  426. .course-grid {
  427. display: grid;
  428. grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  429. gap: 16px;
  430. }
  431. .order_btn{
  432. font-size: 25px;
  433. color: #ffffff;
  434. border-radius:10px;
  435. background-color: $primary-color;
  436. &.error{
  437. background-color: #E93323;
  438. }
  439. &.plain{
  440. border:1px solid #cccccc;
  441. color: #000000;
  442. background-color: #ffffff;
  443. }
  444. }
  445. .border{
  446. border: 1px solid #eeeeee;
  447. }
  448. .border-bottom{
  449. border-bottom: 1px solid #eeeeee;
  450. }
  451. .gray{
  452. color: #666666;
  453. }
  454. .gray999{
  455. color: #999999;
  456. }
  457. .link{
  458. color: #007aff;
  459. }
  460. .bg_color_f5{
  461. background-color: #f5f5f5;
  462. }
  463. .edit_gary {
  464. background: #EBEBEB;
  465. }
  466. .bg_color_fff{
  467. background-color: #ffffff;
  468. }
  469. .bg_color_primary{
  470. background-color: $primary-color;
  471. }
  472. .bg_gradient_primary{
  473. background: linear-gradient(180deg, #0089FF 0%, #F5F7FA 50%);
  474. background-size: 200% 100vh;
  475. background-repeat: no-repeat;
  476. }
  477. .bg_gradient_primary_toright{
  478. //从左到右渐变色
  479. background: linear-gradient(to right, rgba(73, 171, 255, 1), rgba(0, 137, 255, 1));
  480. }
  481. .border_radius_4{
  482. border-radius: 4px;
  483. }
  484. .border_radius_8{
  485. border-radius: 4px;
  486. }
  487. .border_radius_10{
  488. border-radius: 10px;
  489. }
  490. .border_radius_16{
  491. border-radius: 16px;
  492. }
  493. .border_radius_20{
  494. border-radius: 20px;
  495. }
  496. .border_radius_30{
  497. border-radius: 30px;
  498. }
  499. .bold{
  500. font-weight: bold;
  501. }
  502. .font_weight400{
  503. font-weight: 400;
  504. }
  505. .font_size40{
  506. font-size: 40px;
  507. }
  508. .font_size36{
  509. font-size: 36px;
  510. }
  511. .font_size35{
  512. font-size: 35px;
  513. }
  514. .font_size32{
  515. font-size: 32px;
  516. }
  517. .font_size30{
  518. font-size: 30px;
  519. }
  520. .font_size28{
  521. font-size: 28px;
  522. }
  523. .font_size20{
  524. font-size: 20px;
  525. }
  526. .font_size25{
  527. font-size: 25px;
  528. }
  529. .font_size24{
  530. font-size: 24px;
  531. }
  532. .font_size18{
  533. font-size: 18px;
  534. }
  535. .font_size16{
  536. font-size: 16px;
  537. }
  538. .font_size14{
  539. font-size: 14px;
  540. }
  541. .font_size13{
  542. font-size: 13px;
  543. }
  544. .line_height26{
  545. line-height: 26px;
  546. }
  547. .line_height24{
  548. line-height: 24px;
  549. }
  550. .line_height22{
  551. line-height: 22px;
  552. }
  553. .line_vertical{
  554. width: 6px;
  555. height: 24px;
  556. background-color: $primary-color;
  557. border-radius: 4px;
  558. }
  559. .color_price{
  560. color: #E43434;
  561. }
  562. .color_required{
  563. color: #f56c6c;
  564. margin-right: 5px;
  565. }
  566. .color_vip{
  567. color: #fee189;
  568. }
  569. .color_fff{
  570. color: #ffffff;
  571. }
  572. .color_000{
  573. color: #000000;
  574. }
  575. .color_theme{
  576. color: $primary-color;
  577. }
  578. .text_align_center{
  579. text-align: center;
  580. }
  581. .text_align_right{
  582. text-align: right;
  583. }
  584. .foot{
  585. padding: 20px 30px;
  586. width: 100%;
  587. position: fixed;
  588. bottom: 0;
  589. left: 0;
  590. box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
  591. z-index: 10;
  592. }
  593. .ellipsis{
  594. overflow: hidden;
  595. white-space: nowrap;
  596. text-overflow: ellipsis;
  597. }
  598. .bg_img{
  599. width: 100%;
  600. position: absolute;
  601. top: 0;
  602. left: 0;;
  603. z-index: -1;
  604. }
  605. .line_through{
  606. text-decoration: line-through;
  607. }
  608. .required{
  609. color: #E93323;
  610. }
  611. .u_popup_bottom{
  612. border-radius: 30px 30px 0 0;
  613. }
  614. .overflow_hidden{
  615. overflow: hidden;
  616. }
  617. .noData{
  618. text-align: center;
  619. padding: 30px 0;
  620. color: #c8c7cc;
  621. }
  622. .box_shadow{
  623. box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.1);
  624. }
  625. .box_shadow_card{
  626. box-shadow: 0px 2px 10px rgba(45,113,255,0.1);
  627. }
  628. .list_item_animation{
  629. transition: transform 0.3s;
  630. &:hover {
  631. transform: translateY(-5px);
  632. // box-shadow: 0 5px 15px rgba(0,0,0,0.1);
  633. box-shadow: 0px 2px 10px rgba(45,113,255,0.1);
  634. }
  635. }
  636. .page-add{
  637. .inputBg{
  638. background: #F5F7FA !important;
  639. }
  640. .el-form-item__label{
  641. font-size: 16px;
  642. color: #333333;
  643. font-weight: bold;
  644. }
  645. .el-input__wrapper {
  646. background: #F5F7FA !important;
  647. .el-input__inner{
  648. height: 44px !important;
  649. line-height: 44px !important;
  650. }
  651. }
  652. .el-date-editor.el-input, .el-select__wrapper{
  653. height: 44px !important;
  654. line-height: 44px !important;
  655. width: 100% !important;
  656. }
  657. .el-textarea__inner{
  658. background: #F5F7FA !important;
  659. }
  660. }