/* 旭彭设备监管系统 - 公共样式 */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; font-size: 14px; color: #333; background: #f5f7fa; line-height: 1.6; }
a { color: #4a6cf7; text-decoration: none; }
a:hover { text-decoration: underline; }

/* 按钮 */
.btn { display: inline-block; padding: 8px 18px; border: 1px solid #ddd; border-radius: 6px; background: #fff; color: #333; font-size: 14px; cursor: pointer; transition: all 0.2s; text-align: center; }
.btn:hover { background: #f0f0f0; border-color: #ccc; }
.btn-primary { background: linear-gradient(135deg, #4a6cf7, #6b8cff); color: #fff; border-color: #4a6cf7; }
.btn-primary:hover { background: linear-gradient(135deg, #3a5ce7, #5b7cff); border-color: #3a5ce7; }
.btn-warning { background: #ff9f43; color: #fff; border-color: #ff9f43; }
.btn-warning:hover { background: #ef8f33; }
.btn-danger { background: #ff6b6b; color: #fff; border-color: #ff6b6b; }
.btn-danger:hover { background: #ef5b5b; }
.btn-success { background: #00c896; color: #fff; border-color: #00c896; }
.btn-sm { padding: 5px 12px; font-size: 12px; }
.btn-block { display: block; width: 100%; padding: 12px; }
.btn-link { background: none; border: none; color: #4a6cf7; cursor: pointer; padding: 2px 6px; font-size: 13px; }
.btn-link:hover { text-decoration: underline; }
.btn-link.btn-danger { color: #ff6b6b; }
.btn-link.btn-warning { color: #ff9f43; }
.btn-link.btn-success { color: #00c896; }

/* 表单 */
.form-row { margin-bottom: 16px; }
.form-row label { display: block; margin-bottom: 6px; font-weight: 500; color: #555; font-size: 13px; }
.form-row input, .form-row select, .form-row textarea { width: 100%; padding: 10px 12px; border: 1px solid #ddd; border-radius: 6px; font-size: 14px; transition: border-color 0.2s; box-sizing: border-box; }
.form-row input:focus, .form-row select:focus, .form-row textarea:focus { outline: none; border-color: #4a6cf7; box-shadow: 0 0 0 3px rgba(74,108,247,0.1); }
.form-section { font-size: 15px; font-weight: 600; color: #333; margin: 24px 0 12px; padding-bottom: 8px; border-bottom: 1px solid #eee; }
.form-hint { font-size: 12px; color: #999; margin-top: 4px; }

/* 表格 */
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th { background: #f8f9fb; padding: 12px 10px; text-align: left; font-weight: 600; color: #555; border-bottom: 2px solid #e8eaf0; white-space: nowrap; }
.data-table td { padding: 10px; border-bottom: 1px solid #f0f0f0; color: #444; }
.data-table tr:hover { background: #f8f9ff; }
.data-table .mono { font-family: 'Courier New', monospace; font-weight: 600; color: #4a6cf7; }
.empty-row { text-align: center; color: #999; padding: 30px !important; }

/* 状态标签 */
.status-tag { display: inline-block; padding: 2px 10px; border-radius: 12px; font-size: 12px; font-weight: 500; }
.status-0 { background: #f0f0f0; color: #999; }
.status-1 { background: #e6f7ef; color: #00c896; }
.status-2 { background: #fef0f0; color: #ff6b6b; }
.status-3 { background: #e8f0fe; color: #4a6cf7; }
.status-4 { background: #fff7e6; color: #ff9f43; }
.order-0 { background: #f0f0f0; color: #999; }
.order-1 { background: #fff7e6; color: #ff9f43; }
.order-2 { background: #e6f0ff; color: #4a6cf7; }
.order-3 { background: #e6f7ef; color: #00c896; }
.order-4 { background: #f0e6ff; color: #a55eea; }
.order-5 { background: #e6f7ef; color: #00c896; }
.order-6 { background: #fef0f0; color: #ff6b6b; }
.order-7 { background: #e8f0fe; color: #4a6cf7; }
.order-8 { background: #f0f0f0; color: #666; }
.order-9 { background: #fef0f0; color: #ff6b6b; }

/* 信用分 */
.credit-score { font-weight: 700; padding: 2px 8px; border-radius: 4px; }
.credit-score.high { background: #e6f7ef; color: #00c896; }
.credit-score.mid { background: #fff7e6; color: #ff9f43; }
.credit-score.low { background: #fef0f0; color: #ff6b6b; }

/* 圆点 */
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 4px; }
.dot-green { background: #00c896; }
.dot-red { background: #ff6b6b; }
.dot-gray { background: #ccc; }

/* 提示框 */
.alert { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.alert-success { background: #e6f7ef; color: #00a876; border: 1px solid #b3e8d5; }
.alert-error { background: #fef0f0; color: #e74c3c; border: 1px solid #f5c6c6; }
.alert-warning { background: #fff7e6; color: #e67e22; border: 1px solid #fde3a7; }

/* 弹窗 */
.modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); z-index: 9999; align-items: center; justify-content: center; }
.modal.show { display: flex; }
.modal-content { background: #fff; border-radius: 12px; padding: 24px; width: 90%; max-width: 500px; max-height: 80vh; overflow-y: auto; box-shadow: 0 20px 60px rgba(0,0,0,0.3); }
.modal-content h3 { margin-bottom: 16px; font-size: 18px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 20px; }

/* 分页 */
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 20px; flex-wrap: wrap; }
.pagination a, .pagination span { padding: 6px 12px; border: 1px solid #ddd; border-radius: 4px; text-decoration: none; color: #4a6cf7; font-size: 13px; }
.pagination a:hover { background: #f0f4ff; border-color: #4a6cf7; }
.pagination .current { background: #4a6cf7; color: #fff; border-color: #4a6cf7; }

/* 操作单元格 */
.action-cell { white-space: nowrap; }
.action-cell form { display: inline; }

/* 搜索表单 */
.search-form { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.search-form input, .search-form select { padding: 8px 12px; border: 1px solid #ddd; border-radius: 6px; font-size: 13px; }
.search-form input { min-width: 200px; }

/* 响应式 */
@media (max-width: 768px) {
    .data-table { font-size: 12px; }
    .data-table th, .data-table td { padding: 8px 6px; }
    .search-form input { min-width: 150px; }
}
