Krishya | 7ec1dd0 | 2025-04-19 15:29:03 +0800 | [diff] [blame] | 1 | .create-post { |
Krishya | f1d0ea8 | 2025-05-03 17:01:58 +0800 | [diff] [blame^] | 2 | display: flex; |
| 3 | justify-content: center; |
| 4 | margin: 20px 0; |
| 5 | } |
Krishya | 1300cad | 2025-04-20 22:16:45 +0800 | [diff] [blame] | 6 | |
Krishya | f1d0ea8 | 2025-05-03 17:01:58 +0800 | [diff] [blame^] | 7 | .create-btn { |
| 8 | background-color: #BA929A; |
| 9 | color: white; |
| 10 | padding: 10px 20px; |
| 11 | border-radius: 8px; |
| 12 | border: none; |
| 13 | cursor: pointer; |
| 14 | font-size: 16px; |
| 15 | display: flex; |
| 16 | align-items: center; |
| 17 | transition: background-color 0.3s ease; |
| 18 | } |
| 19 | |
| 20 | .create-btn:hover { |
| 21 | background-color: #a17b83; |
| 22 | } |
| 23 | |
| 24 | /* Modal 样式 */ |
| 25 | .cp-modal-overlay { |
| 26 | position: fixed; |
| 27 | top: 0; |
| 28 | left: 0; |
| 29 | width: 100%; |
| 30 | height: 100%; |
| 31 | background: rgba(0,0,0,0.5); |
| 32 | display: flex; |
| 33 | justify-content: center; |
| 34 | align-items: center; |
| 35 | z-index: 1000; |
| 36 | } |
| 37 | |
| 38 | .cp-modal-dialog { |
| 39 | background: #e9ded2; |
| 40 | padding: 20px; |
| 41 | width: 35%; |
| 42 | max-width: 500px; |
| 43 | border-radius: 8px; |
| 44 | display: flex; |
| 45 | flex-direction: column; |
| 46 | gap: 20px; |
| 47 | } |
| 48 | |
| 49 | /* 标题 */ |
| 50 | .cp-modal-dialog h3 { |
| 51 | margin: 0; |
| 52 | color : #4A3B34; |
| 53 | } |
| 54 | |
| 55 | /* 文本输入和文本域 —— 宽度保持 97%,一致感更强 */ |
| 56 | .cp-modal-dialog input[type="text"], |
| 57 | .cp-modal-dialog textarea, |
| 58 | .cp-modal-dialog input[type="file"] { |
| 59 | width: 97%; |
| 60 | padding: 8px; |
| 61 | font-size: 14px; |
| 62 | border: 1px solid #ccc; |
| 63 | border-radius: 4px; |
| 64 | } |
| 65 | |
| 66 | /* 文本域高度 */ |
| 67 | .cp-modal-dialog textarea { |
| 68 | resize: vertical; |
| 69 | min-height: 80px; |
| 70 | } |
| 71 | |
| 72 | /* 文件选择按钮保持 label 方式,不变 */ |
| 73 | .file-label { |
| 74 | display: inline-block; |
| 75 | padding: 6px 10px; |
| 76 | background: #BA929A; |
| 77 | color: #fff; |
| 78 | border-radius: 4px; |
| 79 | cursor: pointer; |
| 80 | font-size: 14px; |
| 81 | user-select: none; |
| 82 | width : 12%; |
| 83 | } |
| 84 | |
| 85 | .file-label:hover { |
| 86 | background: #a17b83; |
| 87 | } |
| 88 | |
| 89 | /* 预览区 */ |
| 90 | .cp-preview { |
| 91 | display: flex; |
| 92 | flex-wrap: wrap; |
| 93 | gap: 8px; |
| 94 | } |
| 95 | |
| 96 | .cp-preview img { |
| 97 | width: 80px; |
| 98 | height: 80px; |
| 99 | object-fit: cover; |
| 100 | border-radius: 4px; |
| 101 | border: 1px solid #bbb; |
| 102 | } |
| 103 | |
| 104 | /* 按钮组 —— 同 .modal-actions */ |
| 105 | .cp-actions { |
| 106 | display: flex; |
| 107 | justify-content: flex-end; |
| 108 | margin-top: 10px; |
| 109 | } |
| 110 | |
| 111 | .cp-actions .btn { |
| 112 | padding: 6px 12px; |
| 113 | font-size: 14px; |
| 114 | cursor: pointer; |
| 115 | border: none; |
| 116 | border-radius: 4px; |
| 117 | } |
| 118 | |
| 119 | .cp-actions .btn.cancel { |
| 120 | background: #5F4437; |
| 121 | color: #fff; |
| 122 | } |
| 123 | |
| 124 | .cp-actions .btn.submit { |
| 125 | background: #BA929A; |
| 126 | color: #fff; |
| 127 | } |