/* 严禁省略代码 */
/*
 * 新增凭证页面样式
 * -------------------
 * 该部分定义了凭证录入界面的布局和视觉风格。
 * 核心样式包括：
 * - .voucher-header: 顶部凭证信息区域，采用Flexbox布局，实现左右对齐和元素间距。
 * - .voucher-table-full: 核心表格样式，用于展示凭证明细，采用table-layout: fixed确保列宽一致。
 * - .subject-select-container: 会计科目自动补全下拉列表的样式，通过position: absolute实现悬浮效果。
 * - .modal-overlay: 弹窗背景遮罩，用于制单人设置弹窗，实现居中和半透明背景。
 */

.voucher-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
}

.voucher-header .voucher-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.voucher-header .voucher-info label {
    white-space: nowrap;
}

.voucher-header .voucher-info select,
.voucher-header .voucher-info input {
    padding: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.voucher-header .voucher-info .voucher-word {
    width: 60px;
}

.voucher-header .voucher-info .voucher-num {
    width: 50px;
}

.voucher-header .voucher-info .voucher-date {
    width: 120px;
}

.voucher-header .voucher-toolbar {
    margin-left: auto;
}

.voucher-table-full {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.voucher-table-full th,
.voucher-table-full td {
    border: 1px solid #ddd;
    padding: 0;
    height: 40px;
}

.voucher-table-full th {
    background-color: #f2f2f2;
    text-align: center;
    vertical-align: middle;
    font-weight: normal;
    white-space: nowrap;
}

.voucher-table-full td {
    position: relative;
}

.voucher-table-full .summary-col {
    width: 30%;
}

.voucher-table-full .subject-col {
    width: 30%;
}

.voucher-table-full .debit-col,
.voucher-table-full .credit-col {
    width: 20%;
}

.voucher-table-full input {
    width: 100%;
    height: 100%;
    border: none;
    padding: 0 5px;
    box-sizing: border-box;
}

.voucher-table-full td:focus-within {
    border: 2px solid #007bff;
}

.subject-select-container {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 10;
    background: #fff;
    border: 1px solid #ccc;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 300px;
    display: none;
}

.subject-select-container.active {
    display: block;
}

.subject-select-container .search-input {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
    border: none;
    border-bottom: 1px solid #eee;
}

.subject-select-container .subject-list {
    max-height: 200px;
    overflow-y: auto;
}

.subject-select-container .subject-item {
    padding: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.subject-select-container .subject-item:hover {
    background-color: #f0f0f0;
}

.voucher-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 10px;
    border-top: 1px solid #ddd;
}

.voucher-footer .total-summary {
    font-weight: bold;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100;
    display: none;
}

.modal-content {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    width: 400px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.modal-content h3 {
    margin-top: 0;
}

.modal-content .form-group {
    margin-bottom: 15px;
}

.modal-content input {
    width: 100%;
    padding: 8px;
    box-sizing: border-box;
}

.modal-content .btn-group {
    text-align: right;
}