| .create-post { |
| display: flex; |
| justify-content: center; |
| margin-top: 3%; |
| margin-bottom: -1%; |
| } |
| |
| .create-btn { |
| /* background-color: #BA929A; |
| color: white; */ |
| /* background-color: #e9ded2; */ |
| /* 使用浅色背景,符合整体风格 */ |
| background: none; |
| color: #5F4437; |
| padding: 7px 15px; |
| border-radius: 8px; |
| border: none; |
| cursor: pointer; |
| font-size: 16px; |
| display: flex; |
| align-items: center; |
| transition: background-color 0.3s ease; |
| } |
| |
| .create-btn:hover { |
| background-color: #e9ded2; |
| } |
| |
| .view-btn { |
| background: none; |
| color: #0f5e51; |
| padding: 7px 15px; |
| border-radius: 8px; |
| border: none; |
| cursor: pointer; |
| font-size: 16px; |
| display: flex; |
| align-items: center; |
| transition: background-color 0.3s ease; |
| } |
| |
| .view-btn:hover { |
| background-color: #e9ded2; |
| } |
| |
| /* Modal 样式 */ |
| .cp-modal-overlay { |
| position: fixed; |
| top: 0; |
| left: 0; |
| width: 100%; |
| height: 100%; |
| background: rgba(0,0,0,0.5); |
| display: flex; |
| justify-content: center; |
| align-items: center; |
| z-index: 1000; |
| } |
| |
| .cp-modal-dialog { |
| background: #e9ded2; |
| padding: 20px; |
| width: 35%; |
| max-width: 500px; |
| border-radius: 8px; |
| display: flex; |
| flex-direction: column; |
| gap: 20px; |
| } |
| |
| /* 标题 */ |
| .cp-modal-dialog h3 { |
| margin: 0; |
| color : #4A3B34; |
| } |
| |
| /* 文本输入和文本域 —— 宽度保持 97%,一致感更强 */ |
| .cp-modal-dialog input[type="text"], |
| .cp-modal-dialog textarea, |
| .cp-modal-dialog input[type="file"] { |
| width: 97%; |
| padding: 8px; |
| font-size: 14px; |
| border: 1px solid #ccc; |
| border-radius: 4px; |
| } |
| |
| /* 文本域高度 */ |
| .cp-modal-dialog textarea { |
| resize: vertical; |
| min-height: 80px; |
| } |
| |
| /* 文件选择按钮保持 label 方式,不变 */ |
| .file-label { |
| display: inline-block; |
| padding: 6px 10px; |
| background: #BA929A; |
| color: #fff; |
| border-radius: 4px; |
| cursor: pointer; |
| font-size: 14px; |
| user-select: none; |
| width : 12%; |
| } |
| |
| .file-label:hover { |
| background: #a17b83; |
| } |
| |
| /* 预览区 */ |
| .cp-preview { |
| display: flex; |
| flex-wrap: wrap; |
| gap: 8px; |
| } |
| |
| .cp-preview img { |
| width: 80px; |
| height: 80px; |
| object-fit: cover; |
| border-radius: 4px; |
| border: 1px solid #bbb; |
| } |
| |
| /* 按钮组 —— 同 .modal-actions */ |
| .cp-actions { |
| display: flex; |
| justify-content: flex-end; |
| margin-top: 10px; |
| } |
| |
| .cp-actions .btn { |
| padding: 6px 12px; |
| font-size: 14px; |
| cursor: pointer; |
| border: none; |
| border-radius: 4px; |
| } |
| |
| .cp-actions .btn.cancel { |
| background: #5F4437; |
| color: #fff; |
| } |
| |
| .cp-actions .btn.submit { |
| background: #BA929A; |
| color: #fff; |
| } |