@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@300;400;500;700&display=swap');

:root {
    --primary-blue: #003366;
    --primary-blue-dark: #002244;
    --accent-blue: #2980b9;
    --bg-light: #f0f4f8;
    --bg-white: #ffffff;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --border-color: #dce1e6;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans SC', 'Microsoft YaHei', sans-serif;
    background-color: #ffffff;
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* 顶部工具栏 */
.top-bar {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-dark) 100%);
    padding: 10px 40px;
    font-size: 14px;
}

/* 横幅 */
.banner {
    background: #ffffff !important;
    text-align: center;
    padding: 8px 0;
    border-bottom: 3px solid var(--primary-blue);
}

.banner-img {
    max-width: 600px !important;
    max-height: 80px !important;
    object-fit: contain !important;
}


/* 导航栏 */
.nav-bar {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-dark) 100%);
    padding: 0 40px;
}

.nav-item {
    color: white;
    text-decoration: none;
    padding: 14px 22px;
    font-size: 16px;
    font-weight: 500;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    display: inline-block;
}

.nav-item:hover {
    background: rgba(255,255,255,0.1);
    border-bottom-color: rgba(255,255,255,0.5);
    color: white;
}

.nav-item.active {
    background: rgba(255,255,255,0.15);
    border-bottom-color: white;
    font-weight: 600;
    color: white;
}

/* 主内容区 */
.main-content {
    flex: 1;
    padding: 30px 0;
}

/* 卡片 */
.card {
    background: white;
    border-radius: 12px;
    padding: 28px;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0,51,102,0.08);
    border: 1px solid var(--border-color);
}

.card-header-custom {
    color: var(--primary-blue);
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--primary-blue);
}

/* 表单样式 */
.form-label {
    color: var(--primary-blue);
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 8px;
}

.form-control, .form-select {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px 16px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: #fafbfc;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(0,51,102,0.1);
    background: white;
}

/* 按钮 */
.btn-primary {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--accent-blue) 100%);
    border: none;
    border-radius: 8px;
    padding: 12px 28px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-blue-dark) 0%, var(--primary-blue) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,51,102,0.3);
}

.btn-secondary {
    border-radius: 8px;
    padding: 12px 28px;
    font-weight: 600;
}

/* 状态标签 */
.badge-status {
    padding: 8px 20px;
    border-radius: 24px;
    font-size: 14px;
    font-weight: 600;
    display: inline-block;
}

.badge-pending {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    color: #1565c0;
    box-shadow: 0 2px 8px rgba(21,101,192,0.2);
}

.badge-rejected {
    background: linear-gradient(135deg, #fce4ec 0%, #f8bbd0 100%);
    color: #c62828;
    box-shadow: 0 2px 8px rgba(198,40,40,0.2);
}

.badge-approved {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    color: #2e7d32;
    box-shadow: 0 2px 8px rgba(46,125,50,0.2);
}

/* 提示框 */
.alert-custom {
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 20px;
}

.alert-info-custom {
    background: linear-gradient(135deg, #e3f2fd 0%, #f8fbff 100%);
    border: 1px solid #90caf9;
    color: #1565c0;
}

.alert-warning-custom {
    background: linear-gradient(135deg, #fff3e0 0%, #fff8e1 100%);
    border: 1px solid #ffb74d;
    color: #e65100;
}

.alert-danger-custom {
    background: linear-gradient(135deg, #fce4ec 0%, #fff0f3 100%);
    border: 1px solid #ef9a9a;
    color: #c62828;
}

.alert-success-custom {
    background: linear-gradient(135deg, #e8f5e9 0%, #f1f8e9 100%);
    border: 1px solid #a5d6a7;
    color: #2e7d32;
}

/* 登录容器 */
.login-container {
    background: linear-gradient(135deg, #ffffff 0%, #f8fbff 100%);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 8px 32px rgba(0,51,102,0.12);
    border: 1px solid #dce6f0;
    max-width: 450px;
    margin: 0 auto;
}

.login-title {
    text-align: center;
    color: var(--primary-blue);
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 30px;
}

/* 页脚 */
.footer {
    background: var(--primary-blue-dark);
    color: rgba(255,255,255,0.7);
    padding: 20px 0;
    font-size: 13px;
}

/* 表格样式 */
.table {
    border-radius: 8px;
    overflow: hidden;
}

.table thead th {
    background: var(--primary-blue);
    color: white;
    border: none;
    padding: 14px 16px;
    font-weight: 600;
}

.table tbody td {
    padding: 14px 16px;
    vertical-align: middle;
    border-color: #e8eef5;
}

.table-hover tbody tr:hover {
    background-color: rgba(0,51,102,0.02);
}

/* 卡片列表项 */
.order-card {
    background: white;
    border-radius: 12px;
    padding: 24px 28px;
    margin-bottom: 20px;
    box-shadow: 0 4px 16px rgba(0,51,102,0.08);
    border: 1px solid #e8eef5;
    border-left: 4px solid var(--primary-blue);
    transition: all 0.3s ease;
}

.order-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,51,102,0.12);
}

.order-card.pending {
    border-left-color: #1565c0;
}

.order-card.rejected {
    border-left-color: #c62828;
}

.order-card.approved {
    border-left-color: #2e7d32;
}

/* 分组标题 */
.section-title {
    color: var(--primary-blue);
    font-weight: 600;
    font-size: 15px;
    margin: 24px 0 16px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid #e8eef5;
}

/* 信息项 */
.info-item {
    margin-bottom: 16px;
}

.info-label {
    color: var(--text-light);
    font-size: 12px;
    margin-bottom: 4px;
}

.info-value {
    color: var(--primary-blue);
    font-weight: 500;
    font-size: 15px;
}

/* 时间线 */
.timeline-item {
    display: flex;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid #f0f0f0;
}

.timeline-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.timeline-content {
    flex: 1;
}

.timeline-action {
    font-weight: 500;
    font-size: 14px;
}

.timeline-time {
    color: var(--text-light);
    font-size: 12px;
}

.timeline-comment {
    margin-top: 8px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 3px solid var(--primary-blue);
    font-size: 13px;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .banner-img {
        height: auto;
    }
    
    .nav-bar {
        padding: 0 10px;
        overflow-x: auto;
    }
    
    .nav-item {
        padding: 12px 16px;
        font-size: 14px;
        white-space: nowrap;
    }
    
    .main-content {
        padding: 20px 0;
    }
    
    .card {
        padding: 20px;
    }
}

/* ============================================
   审批流程图样式
   ============================================ */
.approval-flow {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0;
    padding: 20px 0;
}

.flow-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 120px;
    text-align: center;
}

.flow-node {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
}

.flow-step.completed .flow-node {
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    color: #2e7d32;
    box-shadow: 0 4px 12px rgba(46,125,50,0.3);
}

.flow-step.rejected .flow-node {
    background: linear-gradient(135deg, #fce4ec 0%, #f8bbd0 100%);
    color: #c62828;
    box-shadow: 0 4px 12px rgba(198,40,40,0.3);
}

.flow-step.active .flow-node {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    color: #1565c0;
    box-shadow: 0 4px 12px rgba(21,101,192,0.3);
    animation: pulse 2s infinite;
}

.flow-step.pending .flow-node {
    background: #f5f5f5;
    color: #bdbdbd;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.flow-info {
    max-width: 120px;
}

.flow-title {
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.flow-approver {
    font-size: 13px;
    color: #666;
}

.flow-time {
    font-size: 11px;
    color: #999;
    margin-top: 4px;
}

.flow-comment {
    font-size: 12px;
    color: #c62828;
    margin-top: 4px;
    max-width: 120px;
    word-wrap: break-word;
}

.flow-connector {
    width: 60px;
    height: 3px;
    background: #e0e0e0;
    margin-top: 25px;
    margin-left: -10px;
    margin-right: -10px;
}

.flow-connector.completed {
    background: linear-gradient(90deg, #2e7d32, #4caf50);
}
