与牧同行-兽医端小程序
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

456 lines
8.7 KiB

  1. .container {
  2. min-height: 100vh;
  3. background: linear-gradient(145deg, #f8f9ff 0%, #f0f2f6 100%);
  4. position: relative;
  5. }
  6. /* 背景装饰 */
  7. .bg-decoration {
  8. position: fixed;
  9. top: 0;
  10. left: 0;
  11. right: 0;
  12. bottom: 0;
  13. pointer-events: none;
  14. z-index: 0;
  15. }
  16. .circle {
  17. position: absolute;
  18. border-radius: 50%;
  19. background: linear-gradient(135deg, rgba(7, 193, 96, 0.1) 0%, rgba(7, 193, 96, 0.05) 100%);
  20. }
  21. .circle-1 {
  22. width: 400rpx;
  23. height: 400rpx;
  24. top: -100rpx;
  25. right: -100rpx;
  26. background: linear-gradient(135deg, rgba(64, 169, 255, 0.1) 0%, rgba(64, 169, 255, 0.05) 100%);
  27. }
  28. .circle-2 {
  29. width: 300rpx;
  30. height: 300rpx;
  31. bottom: 100rpx;
  32. left: -100rpx;
  33. background: linear-gradient(135deg, rgba(255, 184, 0, 0.1) 0%, rgba(255, 184, 0, 0.05) 100%);
  34. }
  35. /* 切换卡片 */
  36. .tab-card {
  37. margin: 30rpx 30rpx 20rpx;
  38. background: rgba(255, 255, 255, 0.9);
  39. backdrop-filter: blur(20px);
  40. border-radius: 60rpx;
  41. padding: 10rpx;
  42. box-shadow:
  43. 0 20rpx 40rpx rgba(0, 0, 0, 0.06),
  44. 0 8rpx 20rpx rgba(0, 0, 0, 0.03),
  45. inset 0 2rpx 4rpx rgba(255, 255, 255, 0.8);
  46. border: 1px solid rgba(255, 255, 255, 0.9);
  47. position: relative;
  48. z-index: 10;
  49. transition: all 0.3s ease;
  50. }
  51. /* 内层标签容器 */
  52. .category-tab {
  53. display: flex;
  54. background: rgba(0, 0, 0, 0.02);
  55. border-radius: 56rpx;
  56. padding: 6rpx;
  57. gap: 6rpx;
  58. }
  59. /* 单个标签项 */
  60. .tab-item {
  61. flex: 1;
  62. text-align: center;
  63. padding: 24rpx 0;
  64. position: relative;
  65. border-radius: 50rpx;
  66. transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  67. cursor: pointer;
  68. overflow: hidden;
  69. }
  70. /* 标签文字 */
  71. .tab-text {
  72. font-size: 30rpx;
  73. font-weight: 500;
  74. color: #666;
  75. letter-spacing: 2rpx;
  76. position: relative;
  77. z-index: 2;
  78. transition: all 0.3s ease;
  79. }
  80. /* 选中状态 - 渐变背景 */
  81. .tab-item.active {
  82. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  83. box-shadow:
  84. 0 10rpx 20rpx rgba(102, 126, 234, 0.3),
  85. 0 4rpx 8rpx rgba(0, 0, 0, 0.1),
  86. inset 0 2rpx 4rpx rgba(255, 255, 255, 0.5);
  87. transform: translateY(-2rpx);
  88. }
  89. /* 选中状态的文字 */
  90. .tab-item.active .tab-text {
  91. color: #ffffff;
  92. font-weight: 600;
  93. text-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.2);
  94. }
  95. /* 添加光泽效果 */
  96. .tab-item.active::before {
  97. content: '';
  98. position: absolute;
  99. top: 0;
  100. left: 0;
  101. right: 0;
  102. bottom: 0;
  103. background: linear-gradient(45deg,
  104. rgba(255, 255, 255, 0.3) 0%,
  105. rgba(255, 255, 255, 0.2) 20%,
  106. transparent 50%);
  107. border-radius: 50rpx;
  108. pointer-events: none;
  109. z-index: 1;
  110. }
  111. /* 添加微光动画 */
  112. .tab-item.active::after {
  113. content: '';
  114. position: absolute;
  115. top: -50%;
  116. left: -50%;
  117. width: 200%;
  118. height: 200%;
  119. background: radial-gradient(circle, rgba(255, 255, 255, 0.3) 0%, transparent 70%);
  120. opacity: 0.5;
  121. animation: shimmer 3s infinite;
  122. pointer-events: none;
  123. z-index: 1;
  124. }
  125. /* 悬停效果 */
  126. @media (hover: hover) {
  127. .tab-item:hover:not(.active) {
  128. background: rgba(255, 255, 255, 0.8);
  129. transform: translateY(-2rpx);
  130. box-shadow: 0 8rpx 16rpx rgba(0, 0, 0, 0.05);
  131. }
  132. .tab-item:hover:not(.active) .tab-text {
  133. color: #333;
  134. }
  135. }
  136. /* 点击效果 */
  137. .tab-item:active {
  138. transform: scale(0.98);
  139. }
  140. /* 微光动画 */
  141. @keyframes shimmer {
  142. 0% {
  143. transform: translateX(-100%) translateY(-100%) rotate(45deg);
  144. opacity: 0;
  145. }
  146. 20% {
  147. opacity: 0.5;
  148. }
  149. 40% {
  150. transform: translateX(100%) translateY(100%) rotate(45deg);
  151. opacity: 0;
  152. }
  153. 100% {
  154. transform: translateX(100%) translateY(100%) rotate(45deg);
  155. opacity: 0;
  156. }
  157. }
  158. .tab-item.active:nth-child(1) {
  159. background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  160. }
  161. .tab-item.active:nth-child(2) {
  162. background-image: linear-gradient(to right, #f78ca0 0%, #f9748f 19%, #fd868c 60%, #fe9a8b 100%);
  163. }
  164. .tab-item.active-bottom {
  165. position: relative;
  166. }
  167. .tab-item.active-bottom::after {
  168. content: '';
  169. position: absolute;
  170. bottom: -10rpx;
  171. left: 50%;
  172. transform: translateX(-50%);
  173. width: 60rpx;
  174. height: 4rpx;
  175. background: linear-gradient(90deg, #667eea, #764ba2);
  176. border-radius: 4rpx;
  177. animation: slideIn 0.3s ease;
  178. }
  179. /* 表单容器 */
  180. .form-container {
  181. padding: 0 30rpx 40rpx;
  182. position: relative;
  183. z-index: 10;
  184. }
  185. .form-card {
  186. background: rgba(255, 255, 255, 0.9);
  187. backdrop-filter: blur(20px);
  188. border-radius: 32rpx;
  189. margin-bottom: 20rpx;
  190. padding: 30rpx;
  191. box-shadow: 0 10rpx 30rpx rgba(0, 0, 0, 0.02),
  192. 0 2rpx 8rpx rgba(0, 0, 0, 0.01);
  193. border: 1px solid rgba(255, 255, 255, 0.8);
  194. }
  195. .form-item {
  196. width: 100%;
  197. }
  198. .label-wrapper {
  199. display: flex;
  200. align-items: center;
  201. margin-bottom: 20rpx;
  202. }
  203. .label {
  204. font-size: 28rpx;
  205. font-weight: 600;
  206. color: #333;
  207. margin-right: 8rpx;
  208. }
  209. .required {
  210. font-size: 24rpx;
  211. color: #ff6b6b;
  212. margin-left: 8rpx;
  213. }
  214. .optional {
  215. font-size: 24rpx;
  216. color: #999;
  217. background: rgba(0, 0, 0, 0.03);
  218. padding: 4rpx 12rpx;
  219. border-radius: 20rpx;
  220. margin-left: 8rpx;
  221. }
  222. .input {
  223. width: 100%;
  224. height: 88rpx;
  225. background: #f8f9fc;
  226. border-radius: 20rpx;
  227. padding: 0 30rpx;
  228. font-size: 28rpx;
  229. color: #333;
  230. border: 2rpx solid transparent;
  231. box-sizing: border-box;
  232. }
  233. .input:focus {
  234. border-color: #07c160;
  235. background: #fff;
  236. }
  237. .placeholder {
  238. color: #b8b8b8;
  239. font-size: 28rpx;
  240. }
  241. .textarea {
  242. width: 100%;
  243. min-height: 240rpx;
  244. background: #f8f9fc;
  245. border-radius: 20rpx;
  246. padding: 24rpx 30rpx;
  247. font-size: 28rpx;
  248. color: #333;
  249. border: 2rpx solid transparent;
  250. box-sizing: border-box;
  251. }
  252. .textarea:focus {
  253. border-color: #07c160;
  254. background: #fff;
  255. }
  256. .word-count {
  257. display: block;
  258. text-align: right;
  259. font-size: 24rpx;
  260. color: #999;
  261. margin-top: 12rpx;
  262. }
  263. /* 分类选择器 */
  264. .category-selector {
  265. width: 100%;
  266. min-height: 88rpx;
  267. display: flex;
  268. align-items: center;
  269. }
  270. .category-badge {
  271. display: inline-block;
  272. padding: 16rpx 32rpx;
  273. border-radius: 40rpx;
  274. color: #648ac2;
  275. font-size: 28rpx;
  276. font-weight: 500;
  277. box-shadow: 0 8rpx 16rpx rgba(0, 0, 0, 0.1);
  278. letter-spacing: 1rpx;
  279. }
  280. .category-placeholder {
  281. width: 100%;
  282. height: 88rpx;
  283. background: #f8f9fc;
  284. border-radius: 20rpx;
  285. padding: 0 30rpx;
  286. font-size: 28rpx;
  287. line-height: 88rpx;
  288. color: #b8b8b8;
  289. border: 2rpx solid transparent;
  290. display: flex;
  291. align-items: center;
  292. justify-content: space-between;
  293. }
  294. .category-placeholder .arrow {
  295. font-size: 40rpx;
  296. color: #999;
  297. transform: rotate(90deg);
  298. display: inline-block;
  299. }
  300. /* 上传器 */
  301. .uploader-wrapper {
  302. display: flex;
  303. flex-direction: column;
  304. align-items: flex-start;
  305. }
  306. .uploader {
  307. width: 220rpx;
  308. height: 220rpx;
  309. background: #f8f9fc;
  310. border-radius: 24rpx;
  311. display: flex;
  312. align-items: center;
  313. justify-content: center;
  314. overflow: hidden;
  315. border: 2rpx dashed #ddd;
  316. }
  317. .preview {
  318. width: 100%;
  319. height: 100%;
  320. object-fit: cover;
  321. }
  322. .upload-placeholder {
  323. display: flex;
  324. flex-direction: column;
  325. align-items: center;
  326. justify-content: center;
  327. }
  328. .upload-placeholder .plus {
  329. font-size: 60rpx;
  330. color: #ccc;
  331. line-height: 1;
  332. margin-bottom: 8rpx;
  333. }
  334. .upload-placeholder .hint {
  335. font-size: 22rpx;
  336. color: #999;
  337. }
  338. .upload-tip {
  339. font-size: 22rpx;
  340. color: #999;
  341. margin-top: 12rpx;
  342. }
  343. /* 视频选择器 */
  344. .video-picker {
  345. width: 100%;
  346. min-height: 120rpx;
  347. background: #f8f9fc;
  348. border-radius: 20rpx;
  349. padding: 20rpx 30rpx;
  350. box-sizing: border-box;
  351. border: 2rpx dashed #ddd;
  352. }
  353. .video-info {
  354. display: flex;
  355. align-items: center;
  356. }
  357. .video-name {
  358. font-size: 26rpx;
  359. color: #333;
  360. flex: 1;
  361. word-break: break-all;
  362. }
  363. .video-placeholder {
  364. display: flex;
  365. align-items: center;
  366. justify-content: center;
  367. gap: 16rpx;
  368. height: 80rpx;
  369. }
  370. .video-placeholder .plus {
  371. font-size: 40rpx;
  372. color: #ccc;
  373. }
  374. .video-placeholder .hint {
  375. font-size: 26rpx;
  376. color: #999;
  377. }
  378. /* 提交按钮 */
  379. .btn-wrapper {
  380. margin-top: 40rpx;
  381. padding: 0 20rpx;
  382. }
  383. .submit-btn {
  384. width: 100%;
  385. height: 96rpx;
  386. background: linear-gradient(135deg, #07c160 0%, #08994d 100%);
  387. color: #ffffff;
  388. font-size: 32rpx;
  389. font-weight: 600;
  390. border-radius: 48rpx;
  391. display: flex;
  392. align-items: center;
  393. justify-content: center;
  394. box-shadow: 0 20rpx 40rpx rgba(7, 193, 96, 0.3);
  395. border: none;
  396. }
  397. .submit-btn.disabled {
  398. background: linear-gradient(135deg, #c0c0c0 0%, #a0a0a0 100%);
  399. box-shadow: 0 10rpx 20rpx rgba(0, 0, 0, 0.1);
  400. }