/* 自定义样式 */
body {
    padding-top: 56px; /* 适配固定导航栏 */
}

.navbar-brand {
    font-weight: bold;
}

.footer {
    padding: 20px 0;
    margin-top: 40px;
    background-color: #f8f9fa;
    border-top: 1px solid #dee2e6;
}

/* 仪表盘卡片样式 - 使用Bootstrap标准样式 */
.dashboard-card {
    transition: transform 0.2s ease-in-out;
}

.dashboard-card:hover {
    transform: translateY(-2px);
}

/* 表格样式调整 */
.table th {
    border-top: none;
}

.table-responsive {
    margin-bottom: 20px;
}

/* 分页样式 */
.pagination-container {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

/* 使用Bootstrap 5原生Toast组件，移除自定义样式 */

/* 报销明细项横向并排布局样式 - 桌面端 */
.expense-item-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 1rem;
}

.expense-category-col {
    flex: 1;
    min-width: 200px;
}

.expense-amount-col {
    flex: 1;
    min-width: 150px;
}

.expense-description-col {
    flex: 2;
    min-width: 200px;
}

.expense-action-col {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.remove-item-btn {
    width: auto;
}

/* 在中等及以上屏幕尺寸上优化布局 */
@media (min-width: 768px) {
    .expense-category-col {
        flex: 0 0 25%;
    }
    
    .expense-amount-col {
        flex: 0 0 15%;
    }
    
    .expense-description-col {
        flex: 0 0 40%;
    }
    
    .expense-action-col {
        flex: 0 0 10%;
    }
    
    .remove-item-btn {
        width: auto;
    }
}

/* 响应式优化 */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 0.875rem;
    }

    .table-responsive .btn {
        padding: 0.25rem 0.5rem;
        font-size: 0.875rem;
    }

    .form-row .form-group {
        margin-bottom: 1rem;
    }

    .card-body {
        padding: 1rem;
    }
    
    /* 移动端适配新的布局 */
    .expense-item-row {
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
        margin-bottom: 0.8rem;
    }

    .expense-category-col {
        flex: 1;
        min-width: 120px;
    }

    .expense-amount-col {
        flex: 1;
        min-width: 100px;
    }

    .expense-description-col {
        flex: 1 0 100%;
    }
    
    .expense-action-col {
        flex: 0 0 100%;
    }
}

@media (max-width: 576px) {
    body {
        padding-top: 56px;
    }

    .navbar-nav .nav-item {
        margin-right: 0.5rem;
    }

    .table th, .table td {
        padding: 0.5rem;
    }

    h1 {
        font-size: 1.75rem;
    }

    h5 {
        font-size: 1.1rem;
    }
    
    /* 移动端适配新的布局 */
    .expense-action-col {
        flex: 0 0 100%;
    }
}

/* 文件上传区域样式 */
.upload-area {
    transition: border-color 0.3s ease;
}

.upload-area:hover {
    border-color: #007bff !important;
}

/* 文件项样式 */
.file-item {
    transition: all 0.3s ease;
}

.file-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* 按钮悬停效果 */
.btn {
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
}

/* 卡片悬停效果 */
.card {
    transition: box-shadow 0.3s ease;
}

.card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* 消息内容样式 */
.message-content {
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.6;
}

/* 消息提醒弹窗样式 */
.modal-content {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

.modal-header {
    border-bottom: none;
}

.modal-footer {
    border-top: none;
}

/* 消息提醒角标动画 */
#msgBadge {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 10px rgba(220, 53, 69, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0);
    }
}