:root { --side-bg: #14213d; --primary: #1677ff; --bg: #eef1f6; --line: #e4e7ed; --text: #1f2329; --muted: #8a8f99; }
* { box-sizing: border-box; }
html, body, #app { margin: 0; height: 100%; font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Segoe UI", sans-serif; font-size: 13px; color: var(--text); background: var(--bg); }
.boot { display: flex; height: 100%; align-items: center; justify-content: center; color: #999; }
.muted { color: var(--muted); } .red { color: #e5484d; } .green { color: #2f9e44; } .blue { color: var(--primary); } .fr { float: right; } .spacer { flex: 1; }
.tip { color: var(--muted); font-size: 12px; line-height: 1.6; }
.b { font-weight: 600; }

/* 登录 */
.login-wrap { height: 100%; display: flex; align-items: center; justify-content: center; gap: 80px; background: linear-gradient(135deg, #0d2b5e 0%, #1677ff 100%); }
.login-left .brand { display: flex; align-items: center; gap: 18px; color: #fff; }
.login-left .mark { width: 64px; height: 64px; border-radius: 14px; background: rgba(255,255,255,.18); display: flex; align-items: center; justify-content: center; font-size: 32px; font-weight: 700; }
.login-left h1 { margin: 0; font-size: 34px; letter-spacing: 2px; } .login-left p { margin: 8px 0 0; opacity: .8; font-size: 14px; }
.login-box { width: 380px; background: #fff; border-radius: 10px; padding: 36px 32px 30px; box-shadow: 0 12px 40px rgba(0,0,0,.2); }
.login-box h2 { margin: 0 0 6px; font-size: 22px; } .login-box .sub { color: var(--muted); margin-bottom: 24px; }
@media (max-width: 900px) { .login-left { display: none; } }

/* 布局 */
.layout { display: flex; height: 100%; }
.aside { width: 208px; background: var(--side-bg); display: flex; flex-direction: column; flex-shrink: 0; transition: width .2s; }
.aside.collapsed { width: 64px; }
.logo { height: 52px; display: flex; align-items: center; padding: 0 16px; font-size: 16px; font-weight: 600; color: #fff; white-space: nowrap; overflow: hidden; }
.logo .mark { width: 28px; height: 28px; border-radius: 6px; background: var(--primary); display: inline-flex; align-items: center; justify-content: center; margin-right: 10px; flex-shrink: 0; }
.aside .el-menu { border-right: none; flex: 1; overflow-y: auto; overflow-x: hidden; }
.aside .el-menu-item, .aside .el-sub-menu__title { height: 42px; line-height: 42px; }
.aside .el-menu-item.is-active { background: var(--primary) !important; }
.aside .el-sub-menu .el-menu-item { height: 38px; line-height: 38px; background: #0e1830 !important; }
.aside .el-sub-menu .el-menu-item.is-active { background: var(--primary) !important; }
.aside .el-menu::-webkit-scrollbar { width: 4px; } .aside .el-menu::-webkit-scrollbar-thumb { background: #33415c; }
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.header { height: 52px; background: #fff; display: flex; align-items: center; gap: 12px; padding: 0 16px; border-bottom: 1px solid var(--line); }
.header .toggle { cursor: pointer; font-size: 18px; color: #555; display: flex; }
.accset-btn { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; padding: 6px 10px; border-radius: 6px; background: #f0f5ff; color: var(--primary); }
.accset-btn b { font-weight: 600; }
.period-tag { font-size: 12px; }
.header .user { cursor: pointer; display: flex; align-items: center; gap: 8px; color: #333; }
.header .avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 12px; }
.content { flex: 1; overflow: auto; padding: 12px; }
.page-wrap { min-height: 100%; }
.page { background: #fff; border-radius: 6px; padding: 14px 16px; min-height: calc(100vh - 128px); }
.page-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; gap: 12px; flex-wrap: wrap; }
.ph-title { font-size: 16px; font-weight: 600; } .ph-sub { font-size: 12px; color: var(--muted); font-weight: normal; margin-left: 10px; }
.ph-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; } .ph-actions .el-button + .el-button { margin-left: 0; }
.page-title { font-size: 16px; font-weight: 600; margin-bottom: 14px; display: flex; align-items: center; justify-content: space-between; }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; align-items: center; }
.toolbar .el-input, .toolbar .el-select { width: 170px; }
.period-range { display: inline-flex; align-items: center; gap: 6px; } .period-range .sep { color: var(--muted); }
.pager { margin-top: 10px; display: flex; justify-content: flex-end; }
.sumbar { margin: 0 0 10px; color: #555; } .sumbar b { color: var(--text); margin: 0 2px; }
.upload-btn { cursor: pointer; } .upload-btn input { display: none; }
.form-2col { display: grid; grid-template-columns: 1fr 1fr; column-gap: 12px; } .form-2col .full { grid-column: 1 / 3; }
.el-table .row-total td { background: #f5f7fa !important; font-weight: 600; }
.el-table .row-l1 td { font-weight: 600; }
.el-table .cell { line-height: 20px; }
.subj-popper .code { color: var(--primary); }
.subj-popper .el-select-dropdown__item { height: auto; line-height: 28px; }

/* 网格表 */
table.grid { width: 100%; border-collapse: collapse; background: #fff; }
table.grid th, table.grid td { border: 1px solid var(--line); padding: 6px 8px; }
table.grid th { background: #f5f7fa; font-weight: 600; color: #444; text-align: center; white-space: nowrap; }
table.grid td.r { text-align: right; font-variant-numeric: tabular-nums; } table.grid td.c { text-align: center; }
table.grid tfoot td { background: #fafbfc; font-weight: 600; }
table.grid .empty { text-align: center; color: var(--muted); padding: 30px; }
.vlist table.grid tbody tr:hover td { background: #f5f9ff; }
.vlist tbody.checked td { background: #ecf5ff; }
.vlist tr.vsum td { background: #fafbfc; font-size: 12px; }
.vlist .src { font-size: 11px; color: var(--muted); }
.rpt.narrow { max-width: 900px; } .report { overflow-x: auto; }

/* 首页 */
.home .panel { background: #fff; border-radius: 6px; padding: 14px 16px; margin-bottom: 12px; }
.panel-h { font-size: 15px; font-weight: 600; margin-bottom: 12px; overflow: hidden; line-height: 28px; }
.home-top { display: grid; grid-template-columns: 2fr 1fr; gap: 12px; }
.shortcuts { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.sc { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px 4px; border-radius: 8px; cursor: pointer; }
.sc:hover { background: #f5f8ff; } .sc .ic { width: 42px; height: 42px; border-radius: 12px; color: #fff; font-size: 20px; display: flex; align-items: center; justify-content: center; }
.todo { display: flex; justify-content: space-between; padding: 9px 4px; border-bottom: 1px dashed var(--line); cursor: pointer; } .todo b { color: var(--primary); } .todo:hover { color: var(--primary); }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.kpi { border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; } .kpi.hl { background: linear-gradient(135deg, #f0f6ff, #fff); border-color: #c6dcff; }
.kpi .l { color: var(--muted); } .kpi .v { font-size: 22px; font-weight: 600; margin: 6px 0 4px; font-variant-numeric: tabular-nums; } .kpi .s { font-size: 12px; color: var(--muted); }
.kpis.small .v { font-size: 18px; }
.home-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 12px; }
.trend { margin-top: 14px; } .legend { font-size: 12px; color: #666; display: flex; gap: 6px; align-items: center; } .legend i { width: 10px; height: 10px; border-radius: 2px; display: inline-block; margin-left: 10px; }
.c1 { background: #1677ff; } .c2 { background: #ffa940; } .c3 { background: #73d13d; }
.bars3 { display: flex; gap: 10px; height: 170px; align-items: flex-end; margin-top: 8px; }
.bars3 .g { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; justify-content: flex-end; }
.bars3 .bs { display: flex; gap: 3px; align-items: flex-end; height: 130px; } .bars3 .bs i { width: 12px; border-radius: 3px 3px 0 0; min-height: 2px; display: block; }
.bars3 span { font-size: 12px; color: var(--muted); margin-top: 4px; } .bars3 em { font-style: normal; font-size: 11px; color: #555; }
.acct-row { display: flex; justify-content: space-between; padding: 10px 4px; border-bottom: 1px dashed var(--line); cursor: pointer; } .acct-row:hover { color: var(--primary); }
@media (max-width: 1100px) { .home-top, .home-grid { grid-template-columns: 1fr; } .kpis { grid-template-columns: repeat(2, 1fr); } .shortcuts { grid-template-columns: repeat(4, 1fr); } }

/* 凭证 */
.vbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; } .vbar .el-button + .el-button { margin-left: 0; }
.kbd { font-size: 11px; opacity: .7; margin-left: 4px; }
.voucher-paper { max-width: 1100px; margin: 0 auto; border: 1px solid #d0d7e2; border-radius: 6px; padding: 16px 20px; background: #fffef9; }
.vp-title { text-align: center; font-size: 22px; font-weight: 600; letter-spacing: 6px; color: #1d39c4; position: relative; margin-bottom: 10px; }
.vp-title .stamp { position: absolute; right: 0; top: 0; font-size: 13px; letter-spacing: 0; border: 2px solid #e5484d; color: #e5484d; padding: 0 8px; border-radius: 4px; transform: rotate(-8deg); }
.vp-title .stamp.ok { border-color: #2f9e44; color: #2f9e44; right: 80px; }
.vp-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; flex-wrap: wrap; gap: 10px; }
.vtable { width: 100%; border-collapse: collapse; table-layout: fixed; }
.vtable th { background: #eef3fb; border: 1px solid #b9c6dc; padding: 6px; font-weight: 600; color: #1d39c4; }
.vtable td { border: 1px solid #b9c6dc; padding: 0; vertical-align: top; background: #fff; }
.vtable td.ops { text-align: center; vertical-align: middle; color: var(--muted); position: relative; }
.vtable td.ops .tools { display: none; position: absolute; left: -2px; top: 50%; transform: translateY(-50%); background: #fff; border: 1px solid var(--line); border-radius: 4px; padding: 2px; z-index: 2; white-space: nowrap; }
.vtable td.ops .tools .el-icon { cursor: pointer; margin: 0 2px; } .vtable td.ops .tools .el-icon:hover { color: var(--primary); }
.vtable tr:hover td.ops .tools { display: inline-flex; } .vtable tr:hover td.ops .no { visibility: hidden; }
.vtable input { width: 100%; height: 40px; border: none; outline: none; padding: 0 8px; font-size: 13px; background: transparent; font-family: inherit; }
.vtable input:focus { background: #fffbe6; } .vtable input:disabled { color: #333; background: transparent; }
.vtable input.amt { text-align: right; font-family: Consolas, "Courier New", monospace; font-size: 14px; }
.vtable .subj-cell .el-select .el-input__wrapper, .vtable .subj-cell .el-select__wrapper { box-shadow: none !important; min-height: 40px; background: transparent; }
.vtable .aux-line { display: flex; gap: 4px; padding: 0 4px 4px; align-items: center; font-size: 12px; }
.vtable tfoot td { padding: 8px; background: #f7f9fc; } .vtable .amt-t { text-align: right; font-family: Consolas, monospace; font-size: 14px; font-weight: 600; }
.vp-foot { display: flex; gap: 40px; margin-top: 10px; color: #555; } .vp-foot .muted { margin-left: auto; font-size: 12px; }
.voucher-paper.ro { background: #fbfbfb; }
.vfiles { max-width: 1100px; margin: 12px auto 0; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.file-chip { display: inline-flex; gap: 4px; align-items: center; background: #f5f7fa; padding: 2px 8px; border-radius: 4px; } .file-chip .el-icon { cursor: pointer; }

/* 账簿 */
.book-split { display: flex; gap: 12px; padding: 0; background: transparent; }
.book-side { width: 220px; flex-shrink: 0; background: #fff; border-radius: 6px; padding: 10px; }
.side-list { margin-top: 8px; max-height: calc(100vh - 200px); overflow-y: auto; }
.side-item { padding: 6px 8px; cursor: pointer; border-radius: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12px; }
.side-item:hover { background: #f5f7fa; } .side-item.on { background: #e6f0ff; color: var(--primary); font-weight: 600; }
.book-main { flex: 1; min-width: 0; background: #fff; border-radius: 6px; padding: 14px 16px; }
.aux-block { margin-bottom: 16px; } .aux-title { font-weight: 600; margin: 8px 0; }

/* 结账 */
.close-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.close-card { border: 1px solid var(--line); border-radius: 8px; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.close-card.done { border-color: #b7eb8f; background: #f6ffed; }
.cc-h { display: flex; align-items: center; gap: 8px; } .cc-h b { flex: 1; font-size: 14px; } .cc-ic { font-size: 20px; color: var(--primary); }
.cc-desc { font-size: 12px; color: var(--muted); min-height: 34px; } .cc-foot { display: flex; align-items: center; margin-top: auto; }
.close-wrap { display: flex; gap: 30px; } .close-main { flex: 1; } .close-side { width: 300px; border-left: 1px solid var(--line); padding-left: 20px; }
.cur-period { font-size: 15px; margin-bottom: 16px; } .cur-period b { font-size: 22px; color: var(--primary); margin-left: 12px; }
.checks .check { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); }
.checks .n { width: 90px; font-weight: 600; } .checks .m { color: #555; }
.lv-ok { color: #52c41a; } .lv-warn { color: #faad14; } .lv-error { color: #f5222d; }

/* 出纳 */
.recon { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; } .recon h4 { margin: 4px 0 8px; }
.sheet-edit { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 12px; }
