/* 方案 B：顶部导航与清爽工作台。正式单据继续使用白底打印样式。 */
:root{--ink:#1b304c;--muted:#71839a;--green:#225fa7;--bg:#f7f9fc;--line:#e2e9f2}
body{background:var(--bg);color:var(--ink);font-family:Inter,"Microsoft YaHei",sans-serif}
.sidebar{position:sticky;top:0;inset:auto;width:100%;height:auto;z-index:60;padding:0 32px;background:#fff;border-right:0;border-bottom:1px solid var(--line);display:flex;flex-direction:row;align-items:center;gap:30px;box-shadow:0 2px 12px #1b304c08}
.brand{flex-shrink:0;font-size:22px;color:#18395f;gap:10px}
.brand-mark{width:36px;height:36px;border-radius:9px;background:#173d6d;font-size:22px}
.brand small,.workspace,.nav-label,.sidebar-bottom,.topbar{display:none}
#nav{display:flex;flex-direction:row;align-items:center;gap:2px;min-width:0;overflow-x:auto;scrollbar-width:thin}
#nav a,#nav a:last-child{position:relative;display:inline-flex;gap:6px;align-items:center;white-space:nowrap;margin:0;padding:23px 13px;border-radius:0;background:transparent;color:#657991;font-size:13px}
#nav a svg{width:16px;height:16px;flex:none}
#nav a:hover{color:#225fa7;background:#f4f8fd}
#nav a.active{color:#1b568f;font-weight:700;background:transparent}
#nav a.active::after{content:"";position:absolute;bottom:0;left:13px;right:13px;height:3px;border-radius:3px;background:#2b75b8}
.shell{margin-left:0}
main{max-width:1500px;padding:30px 34px;min-height:calc(100vh - 115px)}
footer{max-width:1500px;margin:auto}
body.composing main{padding:18px 28px}
.btn-primary{background:#225fa7;border-color:#225fa7;color:#fff}
.btn-primary:hover,.btn-primary:focus{background:#174c8b;border-color:#174c8b;color:#fff}
.btn-ghost{color:#225fa7}
.btn-ghost:hover{background:#edf4fc;color:#174c8b}
.form-control:focus,.form-select:focus{border-color:#2b75b8;box-shadow:0 0 0 3px #2b75b822}
.panel,.stat,.quick,.product-card,.editor-form-panel,.editor-preview-panel,dialog{border-color:var(--line);background:#fff}
.table th{background:#f7f9fc!important;color:#74869c}
.tag{background:#eaf3fd;color:#225fa7}
.tag.blue{background:#eaf3fd;color:#225fa7}
.stat-icon,.activity-icon,.record-avatar,.integration-logo{background:#eaf3fd;color:#225fa7}
.quick svg,.integration-logo svg{color:#225fa7}
.quick:hover,.product-card:hover{border-color:#a9c9ea;background:#f8fbff}
.notice,.quote-images-toggle,.export-details,.order-requirements,.visual-product-picker{background:#f5f8fc;border-color:#dce7f3}
.editor-preview-stage{background:#e9eef5}
.line-count,.line-model-field,.product-card-model,.visual-picker-model{background:#eaf3fd;border-color:#cddff2;color:#1c568d!important}
.line-index{background:#225fa7}
.line-collapse-button{color:#225fa7;border-color:#a9c9ea}
.line-remove-button{flex:none;border:1px solid #e4b8b8;border-radius:6px;background:#fff6f6;color:#a83535;padding:7px 10px;font-size:12px;font-weight:700;cursor:pointer}
.pi-bank-editor{margin:18px 0;padding:16px;border:1px solid #bdd4eb;border-radius:8px;background:#f5f9ff}
.pi-bank-editor textarea{min-height:130px;white-space:pre-wrap}
.pi-bank-editor .btn{margin-top:10px}
.pi-bank-editor .subtitle{margin:8px 0 0}
.line-remove-button:hover,.line-remove-button:focus-visible{background:#ffe8e8;border-color:#c96363;outline:2px solid #c96363;outline-offset:2px}
.editor-form-panel .doc-lines td:last-child{display:none}
@media(max-width:600px){.line-card-header{flex-wrap:wrap}.line-card-summary{flex-basis:calc(100% - 40px)}.line-collapse-button,.line-remove-button{min-height:38px}}
.editor-form-panel .doc-lines tr{background:#fff;border-color:#d5e3f2}
.editor-form-panel .doc-lines tr:nth-child(even){background:#f7faff;border-color:#c4d9ef}
.editor-form-panel .doc-lines tr::before,.editor-form-panel .doc-lines tr:nth-child(even)::before{background:#2b75b8}
.paper,.export-paper{background:#fff;color:#222}
.domestic-amount-table{font-size:9.5px!important;table-layout:fixed}
.domestic-amount-table th,.domestic-amount-table td{padding:7px 5px!important;overflow-wrap:anywhere}
.domestic-amount-table th:nth-child(1){width:5%}
.domestic-amount-table th:nth-child(2){width:38%}
.domestic-amount-table th:nth-child(3),.domestic-amount-table th:nth-child(4){width:8%}
.domestic-amount-table th:nth-child(5){width:19%}
.domestic-amount-table th:nth-child(6){width:22%}
.domestic-amount-table.with-tax{font-size:9px!important}
.domestic-amount-table.with-tax th:nth-child(1){width:4%}
.domestic-amount-table.with-tax th:nth-child(2){width:25%}
.domestic-amount-table.with-tax th:nth-child(3),.domestic-amount-table.with-tax th:nth-child(4){width:7%}
.domestic-amount-table.with-tax th:nth-child(5),.domestic-amount-table.with-tax th:nth-child(6){width:14%}
.domestic-amount-table.with-tax th:nth-child(7),.domestic-amount-table.with-tax th:nth-child(8){width:14.5%}
.logo-image-editor{display:flex;align-items:center;gap:16px;min-width:0;padding:14px;border:1px dashed #b9cde4;border-radius:9px;background:#f7faff}
.logo-image-preview{display:grid;place-items:center;flex:0 0 116px;width:116px;height:94px;overflow:hidden;background:#fff;border:1px solid #dce7f3;border-radius:7px;color:#8191a5;font-size:11px;text-align:center}
.logo-image-preview img{display:block;width:100%;height:100%;object-fit:contain}
.logo-image-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px;min-width:0}
.logo-image-actions b,.logo-image-actions small{flex-basis:100%}
.logo-image-actions b{font-size:12px}
.logo-image-actions small{color:#72839a;font-size:11px;line-height:1.5}
.paper-requirements .logo-artwork-row{align-items:start;break-inside:avoid}
.paper-requirements .logo-artwork-row span{display:block;max-width:260px;padding:4px;background:#fff;border:1px solid #d8e2ee;border-radius:4px}
.paper-requirements .logo-artwork-row img{display:block;max-width:100%;max-height:110px;width:auto;height:auto;object-fit:contain}
@media(max-width:600px){.logo-image-editor{align-items:flex-start;flex-wrap:wrap}.logo-image-preview{flex-basis:100%;width:100%;height:120px}}
.packing-helper{margin:12px 0;padding:12px 14px;border:1px solid #cddff2;border-radius:8px;background:#f6faff}
.packing-helper summary{cursor:pointer;color:#205b98;font-size:12px;font-weight:700}
.packing-helper p,.packing-helper small{display:block;margin:10px 0;color:#657d98;font-size:11px;line-height:1.5}
.packing-helper-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px;margin:12px 0}
.packing-helper-grid label{min-width:0;color:#516b86;font-size:11px}
.packing-helper-grid .form-control{margin-top:5px}
.packing-loose-heading{margin:5px 0 8px;color:#516b86;font-size:11px;font-weight:600}
.packing-loose-size{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-bottom:12px}
.packing-loose-size label{min-width:0;color:#516b86;font-size:11px}
.packing-loose-size .form-control{margin-top:5px}
.packing-helper-actions{display:flex;flex-wrap:wrap;gap:8px}
.packing-helper-actions .btn{font-size:11px}
.doc-lines input[readonly][name="qty"],.doc-lines input[readonly][name="boxes"]{background:#eaf4ff;border-color:#b9d4f1;color:#174d80;font-weight:700;cursor:default}
.export-packing-mix{margin-top:3px;color:#4e5f72;font-size:9px;line-height:1.45}
@media(max-width:600px){.packing-helper-grid{grid-template-columns:1fr}.packing-loose-size{gap:6px}}
.dashboard-b{display:flex;flex-direction:column;gap:24px}
.dashboard-hero{display:flex;justify-content:space-between;align-items:center;gap:28px;padding:28px 34px;border-radius:15px;background:#173d6d;color:#fff}
.dashboard-hero .eyebrow{font-size:12px;letter-spacing:.5px;color:#bad2eb;margin:0 0 10px}
.dashboard-hero h1{color:#fff;font-size:27px;margin:0 0 8px}
.dashboard-hero p:last-child{color:#c7d9eb;margin:0;font-size:13px}
.dashboard-hero-side{min-width:235px;padding:16px 20px;background:#2a517f;border-radius:10px;color:#fff}
.dashboard-hero-side span{display:block;color:#c7d9eb;font-size:12px;margin-bottom:5px}
.dashboard-hero-side strong{display:block;color:#fff;font-size:18px}
.dashboard-b-title{display:flex;justify-content:space-between;align-items:center;gap:10px;margin:0 0 14px}
.dashboard-b-title h2{font-size:19px;font-weight:700;margin:0}
.dashboard-shortcuts{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.dashboard-shortcut{display:flex;flex-direction:column;align-items:flex-start;gap:8px;min-width:0;min-height:112px;padding:18px;text-align:left;text-decoration:none;background:#fff;border:1px solid var(--line);border-radius:11px;cursor:pointer;color:var(--ink);transition:transform .18s,border-color .18s,box-shadow .18s}
.dashboard-shortcut:hover{transform:translateY(-2px);border-color:#a9c9ea;box-shadow:0 8px 22px #173d6d12}
.dashboard-shortcut:focus-visible{outline:3px solid #2b75b8;outline-offset:2px}
.dashboard-shortcut-icon{width:34px;height:34px;display:grid;place-items:center;border-radius:9px;background:#eaf3fd;color:#225fa7}
.dashboard-shortcut-icon svg{width:19px;height:19px}
.dashboard-shortcut b{font-size:14px}
.dashboard-shortcut small{font-size:11px;color:var(--muted)}
.dashboard-b-grid{display:grid;grid-template-columns:minmax(0,1.8fr) minmax(280px,1fr);gap:18px}
.dashboard-b-grid .panel{margin:0;min-width:0}
.dashboard-b-grid .panel-head{padding:17px 20px}
.dashboard-b-grid .table td{padding:12px 14px!important}
.dashboard-b-grid .table th{padding:10px 14px!important}
.dashboard-summary{padding:5px 20px}
.dashboard-summary-row{display:flex;justify-content:space-between;align-items:center;gap:15px;padding:14px 0;border-bottom:1px solid var(--line);font-size:13px}
.dashboard-summary-row:last-child{border-bottom:0}
.dashboard-summary-row strong{font-size:20px;color:#173d6d}
@media(max-width:900px){.sidebar{padding:0 16px;gap:12px}.brand{font-size:19px}.brand-mark{width:32px;height:32px;font-size:20px}#nav a,#nav a:last-child{padding:20px 10px;font-size:12px}#nav a svg{display:none}.dashboard-shortcuts{grid-template-columns:repeat(2,minmax(0,1fr))}.dashboard-b-grid{grid-template-columns:1fr}.dashboard-hero{padding:24px}.dashboard-hero-side{min-width:190px}}
@media(max-width:600px){.sidebar{display:block;padding:12px 14px 0}.brand{margin-bottom:5px}#nav{margin:0 -14px;padding:0 10px}#nav a,#nav a:last-child{padding:12px 9px;font-size:12px}main{padding:20px 15px}body.composing main{padding:15px}.dashboard-hero{display:block;padding:23px}.dashboard-hero h1{font-size:23px}.dashboard-hero-side{margin-top:18px;min-width:0}.dashboard-shortcuts{gap:10px}.dashboard-shortcut{padding:13px;min-height:110px}.dashboard-shortcut small{line-height:1.5}.dashboard-b-grid .table-responsive{overflow-x:auto}}
@media(prefers-reduced-motion:reduce){.dashboard-shortcut{transition:none}.dashboard-shortcut:hover{transform:none}}
@media print{.sidebar{display:none}.shell{margin:0}}
