/* 礼贸管家 - 自定义样式 */

:root {
    --sidebar-width: 240px;
    --sidebar-bg: #1e293b;
    --sidebar-active: #334155;
    --topbar-height: 56px;
    --primary-color: #4f46e5;
}

body {
    font-size: 14px;
    background: #f1f5f9;
    min-height: 100vh;
}

/* 侧边栏 */
#wrapper {
    display: flex;
    min-height: 100vh;
}

.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    color: #cbd5e1;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 1000;
    transition: margin-left 0.3s;
    overflow-y: auto;
}

.sidebar-header {
    padding: 16px 20px;
    border-bottom: 1px solid #334155;
}

.sidebar-nav {
    padding: 8px 0;
    overflow-y: auto;
    flex: 1;
    flex-wrap: nowrap !important;
}

.sidebar-nav .nav-link {
    color: #94a3b8;
    padding: 10px 20px;
    font-size: 14px;
    border-left: 3px solid transparent;
    transition: all 0.2s;
}

.sidebar-nav .nav-link:hover {
    color: #e2e8f0;
    background: #334155;
}

.sidebar-nav .nav-link.active {
    color: #fff;
    background: #334155;
    border-left-color: #818cf8;
}

.sidebar-nav .nav-link i {
    margin-right: 8px;
    width: 18px;
    text-align: center;
}

.sidebar-nav .nav-link.disabled {
    color: #475569;
    cursor: not-allowed;
    opacity: 0.6;
}

.sidebar-nav .nav-section {
    display: block;
    padding: 12px 20px 4px;
    font-size: 11px;
    text-transform: uppercase;
    color: #64748b;
    letter-spacing: 0.5px;
    font-weight: 500;
}

/* 主内容区 */
.content-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

/* 顶栏 */
.topbar {
    height: var(--topbar-height);
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.topbar .nav-link {
    color: #475569;
}

/* 页面标题区域 */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.page-header h4 {
    margin: 0;
    font-weight: 600;
    color: #1e293b;
}

/* 统计卡片 */
.stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    border: 1px solid #e2e8f0;
    transition: box-shadow 0.2s;
}

.stat-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.stat-card .stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.stat-card .stat-number {
    font-size: 24px;
    font-weight: 700;
    color: #1e293b;
    margin: 4px 0;
}

.stat-card .stat-label {
    font-size: 13px;
    color: #64748b;
}

/* 表格 */
.table th {
    font-weight: 600;
    color: #475569;
    border-top: none;
    background: #f8fafc;
    white-space: nowrap;
}

.table td {
    vertical-align: middle;
}

/* 表单 */
.form-label {
    font-weight: 500;
    color: #374151;
    margin-bottom: 4px;
}

.card {
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.card-header {
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    padding: 14px 20px;
    font-weight: 600;
}

/* 详情页 */
.detail-section {
    margin-bottom: 24px;
}

.detail-section h6 {
    color: #64748b;
    font-weight: 600;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
}

.detail-label {
    color: #64748b;
    font-size: 13px;
}

.detail-value {
    color: #1e293b;
    font-weight: 500;
}

/* 面包屑 */
.breadcrumb {
    margin-bottom: 16px;
}

/* 分页 */
.pagination {
    margin-bottom: 0;
}

/* 状态标签 */
.badge-status {
    font-size: 12px;
    padding: 4px 10px;
    border-radius: 20px;
}

/* 响应式 */
@media (max-width: 768px) {
    .sidebar {
        margin-left: calc(-1 * var(--sidebar-width));
    }
    .sidebar.show {
        margin-left: 0;
    }
    .content-wrapper {
        margin-left: 0;
    }
}
