/* LayUI后台管理公共样式 - 精简版 */

/* 基础重置 */
* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    background: #f0f2f5;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #333;
    line-height: 1.6;
}

/* 布局 */
.layui-container { width: 1200px; max-width: 100%; margin: 0 auto; padding: 0 15px; }
.layui-row { display: flex; flex-wrap: wrap; margin: 0 -10px; }
.layui-col-xs12 { width: 100%; padding: 0 10px; }
.layui-col-sm6 { width: 50%; padding: 0 10px; }
.layui-col-sm4 { width: 33.3333%; padding: 0 10px; }
.layui-col-sm3 { width: 25%; padding: 0 10px; }

/* 表格 */
.layui-table { width: 100%; background: #fff; border: 1px solid #e6e6e6; border-collapse: collapse; }
.layui-table th, .layui-table td { padding: 12px; border: 1px solid #e8e8e8; text-align: left; }
.layui-table th { background: #fafafa; font-weight: 600; color: #333; }
.layui-table tr:hover { background: #fafafa; }
.layui-table img { max-width: 60px; max-height: 60px; object-fit: cover; border-radius: 4px; }

/* 表单 */
.layui-form { }
.layui-form-item { margin-bottom: 20px; clear: both; }
.layui-form-label { display: inline-block; width: 100px; text-align: right; padding: 9px 15px 9px 0; font-weight: 500; }
.layui-input-block { margin-left: 115px; }
.layui-input, .layui-textarea, .layui-select {
    width: 100%;
    padding: 9px 15px;
    border: 1px solid #e6e6e6;
    border-radius: 4px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}
.layui-input:focus, .layui-textarea:focus, .layui-select:focus { border-color: #1890ff; }
.layui-form-switch { display: inline-block; vertical-align: middle; }
.layui-form-pane .layui-form-item { margin-bottom: 15px; }

/* 按钮 */
.layui-btn {
    display: inline-block;
    padding: 8px 20px;
    background: #1890ff;
    color: #fff;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    line-height: 1.5;
    text-decoration: none;
}
.layui-btn:hover { background: #40a9ff; color: #fff; }
.layui-btn-primary { background: #1890ff; }
.layui-btn-normal { background: #52c41a; }
.layui-btn-warm { background: #faad14; }
.layui-btn-danger { background: #ff4d4f; }
.layui-btn-default { background: #fff; color: #333; border: 1px solid #d9d9d9; }
.layui-btn-default:hover { border-color: #1890ff; color: #1890ff; }
.layui-btn-sm { padding: 4px 12px; font-size: 12px; }
.layui-btn-xs { padding: 2px 6px; font-size: 12px; }
.layui-btn-fluid { width: 100%; }
.layui-btn-group { display: inline-block; vertical-align: middle; }
.layui-btn-group .layui-btn { margin-left: -1px; border-radius: 0; }
.layui-btn-group .layui-btn:first-child { border-radius: 4px 0 0 4px; }
.layui-btn-group .layui-btn:last-child { border-radius: 0 4px 4px 0; }

/* 搜索栏 */
.search-bar {
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}
.search-bar .layui-inline { margin-right: 10px; margin-bottom: 10px; }
.search-bar .layui-input { width: 200px; }

/* 分页 */
.layui-laypage { margin: 20px 0; text-align: center; }
.layui-laypage a, .layui-laypage span {
    display: inline-block;
    padding: 6px 12px;
    margin: 0 2px;
    border: 1px solid #e6e6e6;
    border-radius: 4px;
    color: #333;
    text-decoration: none;
    background: #fff;
}
.layui-laypage .layui-laypage-curr .layui-laypage-em {
    background: #1890ff;
    color: #fff;
    border-color: #1890ff;
}
.layui-laypage a:hover { border-color: #1890ff; color: #1890ff; }

/* 卡片 */
.layui-card { background: #fff; border-radius: 8px; margin-bottom: 16px; box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
.layui-card-header { padding: 15px 20px; border-bottom: 1px solid #f0f0f0; font-weight: 600; }
.layui-card-body { padding: 20px; }

/* 面板/区块 */
.layui-panel { background: #fff; border-radius: 8px; padding: 20px; margin-bottom: 16px; }
.content-section { background: #fff; border-radius: 8px; padding: 24px; margin-bottom: 20px; box-shadow: 0 2px 8px rgba(0,0,0,0.05); }
.section-title { font-size: 18px; font-weight: 600; margin-bottom: 20px; padding-bottom: 12px; border-bottom: 1px solid #f0f0f0; }

/* 徽章/标签 */
.layui-badge, .layui-badge-rim, .layui-badge-dot { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 12px; }
.layui-badge { background: #ff4d4f; color: #fff; }
.layui-badge-primary { background: #1890ff; }
.layui-badge-success { background: #52c41a; }
.layui-badge-warning { background: #faad14; color: #fff; }
.layui-badge-danger { background: #ff4d4f; }
.layui-badge-normal { background: #d9d9d9; color: #333; }
.layui-badge-green { background: #52c41a; }
.layui-bg-green { background: #52c41a; }
.layui-bg-blue { background: #1890ff; }

/* 状态标签 */
.status-tag { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 12px; }
.status-tag.active { background: #f6ffed; color: #52c41a; }
.status-tag.inactive { background: #f5f5f5; color: #999; }
.status-tag.pending { background: #fff7e6; color: #fa8c16; }

/* 进度条 */
.layui-progress { height: 6px; border-radius: 3px; background: #f0f0f0; margin-bottom: 20px; }
.layui-progress-bar { height: 100%; border-radius: 3px; background: #1890ff; transition: width 0.3s; }

/* 时间线 */
.layui-timeline { padding-left: 30px; }
.layui-timeline-item { position: relative; padding-bottom: 20px; }
.layui-timeline-item::before { content: ''; position: absolute; left: -20px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: #1890ff; }
.layui-timeline-item::after { content: ''; position: absolute; left: -16px; top: 15px; width: 2px; height: calc(100% - 10px); background: #e6e6e6; }
.layui-timeline-item:last-child::after { display: none; }

/* 导航/头像 */
.layui-nav { background: #fff; }
.layui-nav-user-photo { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }

/* 面包屑 */
.layui-breadcrumb { font-size: 14px; color: #999; }
.layui-breadcrumb a { color: #1890ff; text-decoration: none; }
.layui-breadcrumb a:hover { text-decoration: underline; }

/* 图标 */
.layui-icon { font-size: 16px; }

/* 金额 */
.amount { font-weight: 600; color: #ff4d4f; }
.money { font-weight: 600; color: #ff4d4f; }

/* 响应式 */
@media (max-width: 768px) {
    .layui-col-sm6, .layui-col-sm4, .layui-col-sm3 { width: 100%; }
    .search-bar .layui-input { width: 100%; }
    .layui-form-label { width: 80px; }
    .layui-input-block { margin-left: 0; }
}
