/* CAPEX Web 应用主样式 - 匹配桌面版Flet应用 */

/* 全局样式 */
body {
    background-color: #f8f9fa;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

/* 顶部导航栏 */
.top-navbar {
    background-color: #2196F3;
    color: white;
    padding: 0 24px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.navbar-brand {
    display: flex;
    align-items: center;
    font-size: 18px;
    font-weight: 600;
}

.navbar-brand i {
    font-size: 24px;
    margin-right: 8px;
}

.navbar-user {
    display: flex;
    align-items: center;
    font-size: 14px;
}

/* 主容器 */
.main-container {
    display: flex;
    height: calc(100vh - 56px);
}

/* 左侧导航栏 - 匹配Flet的NavigationRail */
.sidebar-nav {
    width: 70px;
    min-width: 70px;
    background-color: #f3f4f6;
    border-right: 1px solid #dee2e6;
    display: flex;
    flex-direction: column;
    padding: 8px 0;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 12px 4px;
    cursor: pointer;
    color: #6c757d;
    text-decoration: none;
    transition: all 0.2s;
    border-left: 3px solid transparent;
    margin: 2px 0;
}

.nav-item:hover {
    background-color: #e9ecef;
    color: #495057;
}

.nav-item.active {
    background-color: #e3f2fd;
    color: #2196F3;
    border-left-color: #2196F3;
}

.nav-item i {
    font-size: 22px;
    margin-bottom: 4px;
}

.nav-item span {
    font-size: 11px;
    font-weight: 500;
    text-align: center;
}

/* 内容区域 */
.content-area {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
    background-color: #ffffff;
}

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

.page-title {
    font-size: 24px;
    font-weight: bold;
    color: #212529;
}

/* 统计卡片 */
.stat-card {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 10px;
    padding: 15px;
    min-width: 200px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.stat-card .stat-label {
    font-size: 12px;
    color: #6c757d;
    margin-bottom: 4px;
}

.stat-card .stat-value {
    font-size: 22px;
    font-weight: bold;
    color: #2196F3;
}

/* 数据录入统计卡片彩色背景 */
.bg-blue-soft {
    background-color: #e7f1ff !important;
    border: 1px solid #b8daff;
}
.bg-green-soft {
    background-color: #d4edda !important;
    border: 1px solid #c3e6cb;
}
.bg-orange-soft {
    background-color: #fff3cd !important;
    border: 1px solid #ffeaa7;
}
.bg-purple-soft {
    background-color: #e2d9f3 !important;
    border: 1px solid #d5c8e6;
}
.bg-blue-soft .stat-value,
.bg-green-soft .stat-value,
.bg-orange-soft .stat-value,
.bg-purple-soft .stat-value {
    color: inherit;
}

/* 数据表格 */
.data-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
}

.data-table thead th {
    background-color: #f8f9fa;
    font-weight: 600;
    padding: 12px;
    border-bottom: 2px solid #dee2e6;
    text-align: left;
    font-size: 13px;
}

.data-table tbody td {
    padding: 12px;
    border-bottom: 1px solid #dee2e6;
    font-size: 13px;
}

.data-table tbody tr:hover {
    background-color: #f8f9fa;
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

/* 工具栏 */
.toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    gap: 10px;
}

.toolbar-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* 搜索框 */
.search-box {
    position: relative;
}

.search-box input {
    padding-left: 35px;
    border-radius: 20px;
    width: 280px;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
}

/* 按钮 */
.btn-action {
    padding: 4px 8px;
    font-size: 14px;
}

/* 徽章/标签 */
.badge-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 500;
    color: white;
}

.badge-primary {
    background-color: #2196F3;
}

.badge-success {
    background-color: #4caf50;
}

.badge-warning {
    background-color: #ff9800;
}

.badge-danger {
    background-color: #f44336;
}

.badge-info {
    background-color: #00bcd4;
}

/* 模态框 */
.modal-header-primary {
    background-color: #2196F3;
    color: white;
}

.modal-header-primary .btn-close {
    filter: brightness(0) invert(1);
}

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

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.empty-state i {
    font-size: 60px;
    color: #dee2e6;
    margin-bottom: 16px;
}

.empty-state p {
    font-size: 16px;
    margin-bottom: 8px;
}

.empty-state .hint {
    font-size: 13px;
    color: #adb5bd;
}

/* 标签页 */
.tab-container {
    border-bottom: 1px solid #dee2e6;
    margin-bottom: 16px;
}

.tab-item {
    display: inline-block;
    padding: 12px 16px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    color: #6c757d;
    font-weight: 500;
    font-size: 14px;
}

.tab-item:hover {
    color: #495057;
}

.tab-item.active {
    color: #2196F3;
    border-bottom-color: #2196F3;
}

/* 进度条 */
.progress-bar-custom {
    height: 8px;
    background-color: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar-custom .progress-fill {
    height: 100%;
    background-color: #2196F3;
    transition: width 0.3s;
}

/* 卡片 */
.card-custom {
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
}

.card-custom-header {
    font-weight: 600;
    font-size: 15px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid #dee2e6;
}
