/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Arial', sans-serif;
}

body {
    background-color: #f5f7fa;
    color: #333;
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: #007bff;
}

a:hover {
    text-decoration: underline;
}

/* 容器样式 */
.container {
    display: flex;
    min-height: 100vh;
}

/* 头部样式 */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 60px;
    background-color: #2c3e50;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    z-index: 100;
}

.header h1 {
    font-size: 1.5rem;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logout-btn {
    color: #fff;
    background-color: #e74c3c;
    padding: 5px 10px;
    border-radius: 3px;
    text-decoration: none;
}

.logout-btn:hover {
    background-color: #c0392b;
    text-decoration: none;
}

/* 侧边栏样式 */
.sidebar {
    width: 220px;
    background-color: #34495e;
    color: #fff;
    padding-top: 75px;
    min-height: 100vh;
    position: fixed;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin-bottom: 5px;
}

.sidebar a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ecf0f1;
    padding: 12px 20px;
    text-decoration: none;
    transition: background-color 0.3s;
}

.sidebar a:hover {
    background-color: #2c3e50;
}

.sidebar .active a {
    background-color: #1abc9c;
    color: #fff;
}

.sidebar i {
    width: 20px;
    text-align: center;
}

/* 主内容区样式 */
.main-content {
    flex: 1;
    margin-left: 220px;
    padding: 80px 30px 30px;
}

.page-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #ddd;
}

.page-title h2 {
    color: #2c3e50;
}

/* 按钮样式 */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
    text-decoration: none;
}

.add-btn {
    background-color: #2ecc71;
    color: white;
}

.add-btn:hover {
    background-color: #27ae60;
    text-decoration: none;
}

.edit-btn {
    background-color: #f39c12;
    color: white;
}

.edit-btn:hover {
    background-color: #e67e22;
}

.delete-btn {
    background-color: #e74c3c;
    color: white;
}

.delete-btn:hover {
    background-color: #c0392b;
}

.save-btn {
    background-color: #3498db;
    color: white;
}

.save-btn:hover {
    background-color: #2980b9;
}

.cancel-btn {
    background-color: #95a5a6;
    color: white;
}

.cancel-btn:hover {
    background-color: #7f8c8d;
}

.upload-btn {
    background-color: #1abc9c;
    color: white;
}

.upload-btn:hover {
    background-color: #16a085;
}

.download-btn {
    background-color: #3498db;
    color: white;
}

.download-btn:hover {
    background-color: #2980b9;
}

.print-btn {
    background-color: #9b59b6;
    color: white;
}

.print-btn:hover {
    background-color: #8e44ad;
}

.reset-btn {
    background-color: #95a5a6;
    color: white;
}

.reset-btn:hover {
    background-color: #7f8c8d;
}

.view-btn {
    background-color: #3498db;
    color: white;
}

.view-btn:hover {
    background-color: #2980b9;
}

/* 表格样式 */
.data-table {
    background-color: white;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: #2c3e50;
}

tr:hover {
    background-color: #f9f9f9;
}

.action-buttons {
    display: flex;
    gap: 5px;
}

.no-data {
    text-align: center;
    padding: 30px;
    color: #7f8c8d;
}

/* 表单样式 */
.form-group {
    margin-bottom: 15px;
}

label {
    display: inline-block;
    width: 120px;
    font-weight: 500;
    margin-bottom: 5px;
}

input, select, textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.form-actions {
    margin-top: 20px;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.form-container {
    background-color: white;
    padding: 25px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    max-width: 800px;
}

.form-hint {
    display: block;
    margin-top: 5px;
    color: #7f8c8d;
    font-size: 12px;
}

.required {
    color: #e74c3c;
}

.filter-form {
    background-color: white;
    padding: 20px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    margin-bottom: 25px;
}

.search-form {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
}

.search-form .form-group {
    flex: 1;
    min-width: 200px;
}

.search-form label {
    width: 100%;
}

/* 弹窗样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: white;
    border-radius: 5px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    animation: modalFadeIn 0.3s;
}

.large-modal {
    max-width: 900px;
}

.modal-header {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    color: #2c3e50;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #7f8c8d;
}

.close-btn:hover {
    color: #333;
}

.modal-body {
    padding: 20px;
}

/* 消息提示样式 */
.message {
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    font-size: 14px;
}

.success {
    background-color: #dff0d8;
    color: #3c763d;
    border: 1px solid #d6e9c6;
}

.error {
    background-color: #f2dede;
    color: #a94442;
    border: 1px solid #ebccd1;
}

.warning {
    background-color: #fcf8e3;
    color: #8a6d3b;
    border: 1px solid #faebcc;
}

.info {
    background-color: #d9edf7;
    color: #31708f;
    border: 1px solid #bce8f1;
}

/* 登录页面样式 */
.login-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background-color: #f5f7fa;
}

.login-box {
    background-color: white;
    padding: 30px;
    border-radius: 5px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

.login-box h2 {
    text-align: center;
    margin-bottom: 25px;
    color: #2c3e50;
}

.login-btn {
    width: 100%;
    background-color: #3498db;
    color: white;
    padding: 10px;
    font-size: 16px;
}

.login-btn:hover {
    background-color: #2980b9;
}

.error-message {
    color: #e74c3c;
    text-align: center;
    margin-bottom: 15px;
    padding: 10px;
    background-color: #f2dede;
    border-radius: 4px;
}

/* 工资详情样式 */
.salary-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.salary-info {
    background-color: white;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    flex: 1;
    min-width: 300px;
}

.salary-info p {
    margin-bottom: 8px;
}

.salary-selector {
    display: flex;
    align-items: center;
    gap: 15px;
}

.month-selector {
    display: flex;
    align-items: center;
    gap: 10px;
}

.month-selector select {
    width: auto;
    min-width: 150px;
}

.salary-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 30px;
}

@media (max-width: 992px) {
    .salary-details {
        grid-template-columns: 1fr;
    }
}

.salary-section {
    background-color: white;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.salary-section h3 {
    background-color: #f8f9fa;
    padding: 15px 20px;
    margin: 0;
    color: #2c3e50;
    border-bottom: 1px solid #eee;
}

.salary-table {
    width: 100%;
}

.salary-table tr:nth-child(even) {
    background-color: #f9f9f9;
}

.salary-table .amount {
    text-align: right;
    font-weight: 500;
}

.total-row {
    background-color: #f1f1f1;
    font-weight: bold;
}

.final-salary {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px;
}

.final-amount {
    font-size: 2.5rem;
    font-weight: bold;
    color: #e74c3c;
    margin-top: 15px;
}

/* 上传指南样式 */
.upload-guide {
    margin-top: 30px;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 5px;
}

.upload-guide h3 {
    margin-bottom: 15px;
    color: #2c3e50;
}

.upload-guide ul {
    padding-left: 20px;
}

