        body { 
            font-family: 'Prompt', sans-serif; background-color: #F5F5F7; 
            background-image: radial-gradient(at 0% 0%, rgba(89, 68, 169, 0.04) 0px, transparent 50%), radial-gradient(at 100% 0%, rgba(52, 199, 89, 0.02) 0px, transparent 50%), radial-gradient(at 100% 100%, rgba(255, 59, 48, 0.02) 0px, transparent 50%);
            background-attachment: fixed; color: #1D1D1F; font-size: 15px; overflow-x: hidden; -webkit-font-smoothing: antialiased;
        }
        .premium-input { width: 100%; font-size: 15px; outline: none; transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); background: #FFFFFF; border: 1.5px solid #E5E7EB; border-radius: 12px; padding: 14px 16px; color: #111827; }
        .premium-input::placeholder { color: #9CA3AF; font-weight: 400; }
        .premium-input:focus { border-color: #111827; box-shadow: 0 0 0 4px rgba(17, 24, 39, 0.05); }

        .glass-panel, .glass-card { background: rgba(255, 255, 255, 0.7); backdrop-filter: blur(24px) saturate(150%); -webkit-backdrop-filter: blur(24px) saturate(150%); border: 1px solid rgba(255, 255, 255, 0.8); box-shadow: 0 8px 32px rgba(0, 0, 0, 0.04), inset 0 0 0 1px rgba(255, 255, 255, 0.5); border-radius: 24px; }
        .glass-header { background: rgba(255, 255, 255, 0.8); backdrop-filter: blur(20px) saturate(150%); -webkit-backdrop-filter: blur(20px) saturate(150%); border-bottom: 1px solid rgba(255, 255, 255, 0.8); }
        .glass-sidebar { background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(24px) saturate(150%); -webkit-backdrop-filter: blur(24px) saturate(150%); border-right: 1px solid rgba(255, 255, 255, 0.8); }

        .segmented-control { background: #EEEEF0; border-radius: 12px; padding: 3px; display: flex; }
        .segmented-control label { flex: 1; text-align: center; }
        .segmented-control input[type="radio"]:checked + div { background: #FFFFFF; box-shadow: 0 3px 8px rgba(0,0,0,0.12), 0 3px 1px rgba(0,0,0,0.04); color: #1D1D1F; font-weight: 600; }
        .segmented-control div { padding: 8px 12px; border-radius: 10px; color: #86868B; transition: all 0.2s ease; cursor: pointer; font-size: 14px; }

        .input-style { width: 100%; font-size: 15px; outline: none; transition: all 0.2s ease; background: #F5F5F7; border: 1px solid transparent; border-radius: 12px; padding: 12px 16px; color: #1D1D1F; }
        .input-style::placeholder { color: #86868B; font-weight: 400; }
        .input-style:focus { background: #FFFFFF; border-color: #5944A9; box-shadow: 0 0 0 4px rgba(89, 68, 169, 0.15); }
        .input-style:disabled { background: #E5E5EA; color: #86868B; cursor: not-allowed; opacity: 0.7;}

        .btn-modern { transition: all 0.2s ease; font-weight: 600; letter-spacing: -0.01em; display: inline-flex; align-items: center; justify-content: center; }
        .btn-modern:hover:not(:disabled) { opacity: 0.9; transform: scale(0.98); }
        .btn-modern:active:not(:disabled) { transform: scale(0.95); }
        .btn-primary { background: #5944A9; color: white; border-radius: 980px; }
        .btn-primary:hover:not(:disabled) { background-color: #463788; opacity: 1; }
        .btn-secondary { background: #EFEBF9; color: #5944A9; border-radius: 980px; font-weight: 600; }
        .btn-secondary:hover:not(:disabled) { background: #E3DCF5; }
        
        .btn-interactive { position: relative; overflow: hidden; transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1); }
        .btn-interactive::after { content: ''; position: absolute; top: -50%; left: -50%; width: 200%; height: 200%; background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.15) 50%, rgba(255,255,255,0) 100%); transform: rotate(30deg) translate(-50%, -50%); transition: all 0.6s ease; opacity: 0; }
        .btn-interactive:hover::after { opacity: 1; transform: rotate(30deg) translate(50%, 50%); }
        .btn-interactive i { transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); }
        .btn-interactive:hover i { transform: scale(1.3) rotate(90deg); }

        .sidebar-item { color: #86868B; font-weight: 500; padding: 10px 16px; border-radius: 12px; transition: all 0.2s ease; display: flex; align-items: center; margin-bottom: 4px; font-size: 14px; }
        .sidebar-item:hover { background: #F5F5F7; color: #1D1D1F; }
        .sidebar-item.active { background: #5944A9; color: #FFFFFF; font-weight: 600; }
        .sidebar-item-icon { width: 24px; text-align: center; margin-right: 12px; font-size: 16px; }

        .premium-sidebar-btn { position: relative; overflow: hidden; background: linear-gradient(135deg, rgba(89, 68, 169, 0.08), rgba(89, 68, 169, 0.02)); border: 1px solid rgba(89, 68, 169, 0.15); color: #5944A9; font-weight: 600; box-shadow: 0 2px 8px rgba(89, 68, 169, 0.05); z-index: 1; }
        .premium-sidebar-btn::before { content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%; background: linear-gradient(90deg, transparent, rgba(89, 68, 169, 0.15), transparent); transition: all 0.5s ease; z-index: -1; }
        .premium-sidebar-btn:hover { transform: translateY(-2px) scale(1.01); box-shadow: 0 6px 16px rgba(89, 68, 169, 0.12); border-color: rgba(89, 68, 169, 0.3); background: #FFFFFF; color: #463788; }
        .premium-sidebar-btn:hover::before { left: 100%; transition: left 0.6s ease-in-out; }
        .premium-sidebar-btn.active { background: #5944A9; color: #FFFFFF; box-shadow: 0 4px 15px rgba(89, 68, 169, 0.3); border-color: transparent; transform: none; }
        .premium-sidebar-btn.active::before { background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.25), transparent); }
        
        .wave-pulse { animation: ripple-wave 2s infinite; }
        @keyframes ripple-wave { 0% { box-shadow: 0 0 0 0 rgba(89, 68, 169, 0.5); } 70% { box-shadow: 0 0 0 12px rgba(89, 68, 169, 0); } 100% { box-shadow: 0 0 0 0 rgba(89, 68, 169, 0); } }
        .icon-wave-pulse { animation: icon-ripple-wave 2.5s infinite; }
        @keyframes icon-ripple-wave { 0% { box-shadow: 0 0 0 0 rgba(89, 68, 169, 0.4); transform: scale(0.95); } 50% { box-shadow: 0 0 0 8px rgba(89, 68, 169, 0); transform: scale(1.05); } 100% { box-shadow: 0 0 0 0 rgba(89, 68, 169, 0); transform: scale(0.95); } }
        
        .content-section { display: none; opacity: 0; }
        .content-section.active { display: block; animation: smoothFadeIn 0.4s ease forwards; }
        @keyframes smoothFadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
        .section-header { color: #1D1D1F; padding-bottom: 16px; margin-bottom: 24px; display: flex; align-items: center; font-weight: 700; font-size: 24px; letter-spacing: -0.02em; border-bottom: 1px solid #E5E5EA; }

        ::-webkit-scrollbar { width: 8px; height: 8px; }
        ::-webkit-scrollbar-track { background: transparent; }
        ::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.15); border-radius: 10px; border: 2px solid #F5F5F7;}
        ::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.3); }
        
        table { width: 100%; border-collapse: separate; border-spacing: 0; }
        th { letter-spacing: 0; text-transform: none; color: #86868B; font-weight: 500; font-size: 13px; border-bottom: 1px solid #E5E5EA; }
        td { border-bottom: 1px solid #F5F5F7; }
        tbody tr:last-child td { border-bottom: none; }
        tbody tr { transition: background-color 0.2s; }

        @media print {
            /* 🆕 @page ไม่กำหนดขนาดตายตัวไว้ที่นี่อีกต่อไป — ให้ printSection()/printRequisitionDocument()
               ใน utils.js / requisition-print.js เป็นผู้ตั้งค่า @page แบบไดนามิกผ่าน #dynamic-print-style
               ก่อนสั่งพิมพ์ทุกครั้ง (แนวนอนสำหรับรายงานตาราง, แนวตั้ง A4 สำหรับใบเบิกวัสดุ) */
            * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
            body, html { height: auto !important; overflow: visible !important; background: #fff !important; background-image: none !important; font-size: 11pt !important; color: #000 !important; display: block !important; }
            header, #auth-modal, #sidebar-nav, #mobile-menu-overlay, #admin-floating-alert, .print-hidden, #mobile-header { display: none !important; }
            main { display: block !important; padding: 0 !important; margin: 0 !important; width: 100% !important; max-width: 100% !important; overflow: visible !important; height: auto !important; }
            .content-section { display: none !important; }
            .content-section.active { display: block !important; }
            .content-section.force-hide-print { display: none !important; }
            .glass-panel, .glass-card { background: none !important; border: none !important; box-shadow: none !important; border-radius: 0 !important; padding: 0 !important; }
            .overflow-x-auto { overflow: visible !important; }
            table { border-collapse: collapse !important; width: 100% !important; min-width: 0 !important; table-layout: auto !important; }
            table.whitespace-nowrap, .whitespace-nowrap { white-space: normal !important; }
            thead { display: table-header-group !important; } 
            tfoot { display: table-footer-group !important; }
            tr, td, th { page-break-inside: avoid !important; break-inside: avoid !important; }
            th { background: #eef0f3 !important; border: 1px solid #999 !important; padding: 6px 10px !important; font-size: 10.5pt !important; font-weight: 600 !important; color: #000 !important; text-align: left !important; }
            td { border: 1px solid #ccc !important; padding: 6px 10px !important; font-size: 10.5pt !important; color: #000 !important; }
            tbody tr:nth-child(even) td { background: #f7f7f8 !important; }

            /* 🆕 พื้นที่พิมพ์ใบเบิกวัสดุ — ปกติซ่อนอยู่ (.hidden) จะแสดงเฉพาะตอน printRequisitionDocument()
               เพิ่ม body.printing-requisition แล้วสลับให้เห็นเฉพาะส่วนนี้ ซ่อนส่วนอื่นทั้งหมด */
            #print-requisition-root { display: none; }
            body.printing-requisition main,
            body.printing-requisition .content-section.active { display: none !important; }
            body.printing-requisition #print-requisition-root { display: block !important; }
        }

        .ultra-glass { background: rgba(255, 255, 255, 0.25); backdrop-filter: blur(40px) saturate(150%); -webkit-backdrop-filter: blur(40px) saturate(150%); border: 1px solid rgba(255, 255, 255, 0.5); box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15), inset 0 0 0 1px rgba(255, 255, 255, 0.4); border-radius: 28px; }
        .ultra-glass-inner { background: rgba(255, 255, 255, 0.4); border: 1px solid rgba(255, 255, 255, 0.5); }
        .login-glass-bg { background-color: #f1f3f7; background-image: radial-gradient(at 0% 0%, rgba(89, 68, 169, 0.15) 0px, transparent 50%), radial-gradient(at 100% 100%, rgba(52, 199, 89, 0.15) 0px, transparent 50%); }

        /* ============================================================
           🖨️ ใบเบิกวัสดุ (Print A4 Portrait) — ฟอนต์ Sarabun ตามมาตรฐานราชการ 🆕
           ============================================================ */
        @media print {
            .print-a4-page {
                width: 100%;
                min-height: 267mm; /* ความสูง A4 หักระยะขอบโดยประมาณ เพื่อดันลายเซ็นไปก้นหน้ากระดาษ */
                font-family: 'Sarabun', 'Prompt', sans-serif;
                color: #000;
                display: flex;
                flex-direction: column;
                font-size: 15px;
            }
            .print-a4-header { display: flex; align-items: center; gap: 16px; border-bottom: 2px solid #000; padding-bottom: 12px; margin-bottom: 16px; }
            .print-a4-logo { height: 64px; width: auto; object-fit: contain; }
            .print-a4-org-name { font-size: 18px; font-weight: 700; }
            .print-a4-org-address { font-size: 13px; color: #333; margin-top: 2px; }
            .print-a4-title { text-align: center; font-size: 22px; font-weight: 700; margin: 8px 0 16px; letter-spacing: 1px; }
            .print-a4-meta { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 6px; gap: 16px; }
            .print-a4-table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 13.5px; }
            .print-a4-table th, .print-a4-table td { border: 1px solid #000; padding: 6px 8px; text-align: left; }
            .print-a4-table th { background: #eee !important; font-weight: 700; text-align: center; }
            .print-a4-table td.text-center { text-align: center; } .print-a4-table td { vertical-align: top; }
            .print-a4-reason { font-size: 14px; margin: 10px 0 24px; }
            .print-a4-signatures { display: flex; justify-content: space-between; gap: 16px; margin-top: auto; padding-top: 40px; }
            .print-a4-sign-box { flex: 1; text-align: center; font-size: 13px; }
            .print-a4-sign-image-area { height: 60px; display: flex; align-items: flex-end; justify-content: center; margin-bottom: 4px; }
            .print-a4-sign-image { max-height: 56px; max-width: 90%; object-fit: contain; }
            .print-a4-sign-line { border-bottom: 1px dotted #000; margin: 0 8px 6px; }
            .print-a4-sign-label { font-weight: 600; }
            .print-a4-sign-role { color: #333; margin-top: 2px; }
            .print-a4-sign-date { color: #555; font-size: 12px; margin-top: 4px; }
        }

        .sidebar-item:focus-visible, .btn-modern:focus-visible, a:focus-visible, button:focus-visible { outline: 2px solid #5944A9; outline-offset: 2px; }
        @media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
        .swal2-popup { font-family: 'Prompt', sans-serif !important; }

        /* ===== หัวหน้าเพจ + แถบตัวกรอง (รูปแบบเดียวกันทุกเมนู) ===== */
        .page-head { margin-bottom: 22px; }
        .page-title { font-size: 1.75rem; font-weight: 700; letter-spacing: -0.02em; line-height: 1.3; color: #1D1D1F; margin: 0; }
        .page-sub { font-size: 14px; color: #86868B; line-height: 1.6; margin: 6px 0 0; max-width: 78ch; }
        .toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 16px; }
        .toolbar .input-style { width: auto; min-width: 150px; font-size: 14px; padding: 10px 14px; background: #fff; border: 1px solid #E5E5EA; border-radius: 12px; }
        .toolbar .input-style:focus { border-color: #5944A9; box-shadow: 0 0 0 3px rgba(89, 68, 169,0.12); }
        .toolbar .input-style.tb-search { width: 280px; max-width: 100%; }
        .toolbar .tb-actions { display: flex; gap: 8px; margin-left: auto; }
        .date-range { display: flex; align-items: center; gap: 4px; background: #fff; border: 1px solid #E5E5EA; border-radius: 12px; padding: 2px 6px; color: #86868B; }
        .date-range .input-style { min-width: 0; background: transparent; border: 0; padding: 8px 6px; }
        .btn-tool { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 1px solid #E5E5EA; border-radius: 12px; padding: 10px 16px; font-size: 14px; font-weight: 600; color: #1D1D1F; transition: all .2s ease; cursor: pointer; white-space: nowrap; }
        .btn-tool:hover { background: #F5F5F7; }
        .btn-tool i { font-size: 13px; color: #86868B; }
        @media (max-width: 640px) {
            .page-title { font-size: 1.5rem; }
            .toolbar .input-style, .toolbar .input-style.tb-search, .date-range { width: 100%; flex: 1 1 100%; }
            .toolbar .tb-actions { width: 100%; margin-left: 0; }
            .toolbar .tb-actions .btn-tool { flex: 1; justify-content: center; }
        }

        /* ===== หน้าอนุมัติของเจ้าหน้าที่คลัง: ช่องแก้จำนวนที่จ่าย + ปุ่ม ===== */
        .approve-qty { width: 84px; text-align: center; font-weight: 700; font-size: 16px; padding: 8px 6px; border-radius: 10px; border: 2px solid #D9D2F0; background: #fff; color: #1D1D1F; outline: none; transition: border-color .2s, box-shadow .2s; }
        .approve-qty:focus { border-color: #5944A9; box-shadow: 0 0 0 3px rgba(89, 68, 169, 0.15); }
        .approve-qty:disabled { background: #F5F5F7; color: #86868B; }
        .btn-approve { background: #5944A9; color: #fff; border-radius: 980px; padding: 8px 18px; font-size: 13px; font-weight: 600; transition: background .2s, opacity .2s; white-space: nowrap; cursor: pointer; }
        .btn-approve:hover:not(:disabled) { background: #463788; }
        .btn-approve:disabled { opacity: .4; cursor: not-allowed; }
        .btn-reject { background: #F5F5F7; color: #1D1D1F; border-radius: 980px; padding: 8px 16px; font-size: 13px; font-weight: 600; transition: background .2s; white-space: nowrap; cursor: pointer; }
        .btn-reject:hover { background: #E5E5EA; }

        /* ตารางที่เรียงซ้อนแนวตั้งบนจอเล็ก (ใช้กับหน้าอนุมัติ — กันปุ่มถูกตัดนอกจอ) */
        @media (max-width: 768px) {
            .stack-mobile, .stack-mobile tbody, .stack-mobile tr, .stack-mobile td { display: block; width: 100%; }
            .stack-mobile thead { display: none; }
            .stack-mobile td { padding-left: 18px !important; padding-right: 18px !important; }
            .stack-mobile td:first-child { padding-bottom: 4px !important; }
        }

        /* ===== แถบมูลค่าคงเหลือของวัสดุที่ค้นหา (Stock Card) ===== */
        .balance-bar { background: #fff; border: 1px solid #E5E5EA; border-radius: 16px; padding: 14px 18px; margin-bottom: 16px; }
        .balance-bar.hidden { display: none; }
        .bb-title { font-weight: 700; font-size: 14px; color: #1D1D1F; margin-bottom: 8px; }
        .bb-title i { color: #5944A9; margin-right: 6px; }
        .bb-sub { font-weight: 400; color: #86868B; }
        .bb-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 16px; align-items: baseline; padding: 7px 0; border-top: 1px solid #F5F5F7; font-size: 14px; }
        .bb-name { font-weight: 600; min-width: 0; }
        .bb-id { margin-left: 8px; font-weight: 400; font-size: 12px; color: #86868B; }
        .bb-qty { color: #6E6E73; white-space: nowrap; }
        .bb-exp { color: #AF52DE; font-size: 12px; }
        .bb-unit { color: #6E6E73; white-space: nowrap; }
        .bb-val { font-weight: 700; text-align: right; min-width: 110px; white-space: nowrap; }
        .bb-total { display: flex; justify-content: flex-end; align-items: baseline; gap: 14px; padding-top: 10px; margin-top: 4px; border-top: 2px solid #EFEBF9; font-size: 14px; color: #6E6E73; }
        .bb-total b { font-size: 22px; color: #5944A9; letter-spacing: -0.01em; }
        .bb-note { font-size: 13px; color: #86868B; padding: 6px 0; }
        .bb-foot { font-size: 11px; color: #86868B; text-align: right; margin-top: 2px; }
        @media (max-width: 640px) { .bb-row { grid-template-columns: 1fr auto; } .bb-qty, .bb-unit { grid-column: 1 / -1; order: 3; } }

        /* ===== หัว/ท้ายรายงานพิมพ์ (สร้างตอนสั่งพิมพ์เท่านั้น — หน้าจอไม่เห็น) ===== */
        .report-head, .report-foot { display: none; }
        @media print {
            /* ฟอนต์ราชการ (Sarabun) เฉพาะตอนพิมพ์รายงาน — หน้าจอหลักยังใช้ฟอนต์เดิม */
            body.printing-report, body.printing-report * { font-family: 'Sarabun', 'TH Sarabun New', 'Tahoma', sans-serif !important; }
            body.printing-report i { display: none !important; }
            body.printing-report { font-size: 12pt !important; line-height: 1.3 !important; }
            body.printing-report .report-head { display: block !important; margin: 0 0 4mm 0; color: #000; }
            body.printing-report .rh-top { display: flex !important; align-items: center; gap: 4mm; }
            body.printing-report .rh-logo { height: 16mm; width: auto; max-width: 28mm; object-fit: contain; }
            body.printing-report .rh-org { flex: 1; }
            body.printing-report .rh-org-name { font-size: 16pt !important; font-weight: 700 !important; line-height: 1.2; }
            body.printing-report .rh-org-addr { font-size: 11pt !important; color: #333 !important; }
            body.printing-report .rh-meta { text-align: right; font-size: 10.5pt !important; line-height: 1.35; color: #222; }
            body.printing-report .rh-rule { border-top: 2.2pt solid #000; border-bottom: 0.6pt solid #000; height: 1.2mm; margin: 2.5mm 0 3mm; }
            body.printing-report .rh-title { text-align: center; font-size: 22pt !important; font-weight: 700 !important; letter-spacing: 0.5pt; margin: 0 !important; line-height: 1.2; color: #000 !important; }
            body.printing-report .rh-sub { text-align: center; font-size: 14pt !important; margin-top: 0.5mm; }
            body.printing-report .rh-filters { text-align: center; font-size: 11.5pt !important; margin-top: 2mm; padding: 1.2mm 3mm; border: 0.6pt solid #666; border-radius: 1mm; background: #f4f4f4 !important; }
            /* แถบมูลค่าคงเหลือ */
            body.printing-report .balance-bar { border: 0.8pt solid #555 !important; border-radius: 0 !important; padding: 2.5mm 4mm !important; margin: 0 0 3.5mm 0 !important; break-inside: avoid; background: #fff !important; }
            body.printing-report .balance-bar.hidden { display: none !important; }
            body.printing-report .bb-title { font-size: 12pt !important; margin-bottom: 1.5mm !important; }
            body.printing-report .bb-row { font-size: 11pt !important; padding: 1mm 0 !important; border-top: 0.4pt solid #bbb !important; grid-template-columns: minmax(0, 1fr) auto auto auto !important; gap: 6mm !important; }
            body.printing-report .bb-total { border-top: 1pt solid #000 !important; padding-top: 1.5mm !important; font-size: 12pt !important; color: #000 !important; }
            body.printing-report .bb-total b { font-size: 15pt !important; color: #000 !important; }
            body.printing-report .bb-foot { font-size: 9pt !important; color: #444 !important; }
            /* ตารางรายงาน: เส้นตารางชัดเจน หัวตารางซ้ำทุกหน้า */
            body.printing-report .content-section.active .glass-card { border: none !important; }
            body.printing-report .content-section.active table { width: 100% !important; table-layout: fixed !important; border: 1pt solid #000 !important; }
            body.printing-report .content-section.active th { background: #e4e4e8 !important; border: 0.6pt solid #333 !important; padding: 1.6mm 1.6mm !important; font-size: 11pt !important; font-weight: 700 !important; text-align: center !important; color: #000 !important; }
            body.printing-report .content-section.active td { border: 0.5pt solid #555 !important; padding: 1.2mm 1.6mm !important; font-size: 10.5pt !important; line-height: 1.25 !important; vertical-align: top !important; word-break: break-word; background: #fff !important; color: #000 !important; }
            body.printing-report .content-section.active tbody tr:nth-child(even) td { background: #f6f6f6 !important; }
            body.printing-report .content-section.active td * { color: inherit !important; }
            body.printing-report .content-section.active .text-text_muted, body.printing-report .content-section.active .text-\[11px\], body.printing-report .content-section.active .text-\[12px\] { color: #333 !important; }
            body.printing-report .content-section.active tfoot td { font-weight: 700 !important; background: #ececf0 !important; border-top: 1.2pt double #000 !important; }
            body.printing-report .content-section.active tr { break-inside: avoid !important; page-break-inside: avoid !important; }
            body.printing-report .content-section.active thead { display: table-header-group !important; }
            body.printing-report .content-section.active tfoot { display: table-row-group !important; }
            /* Stock Card: 9 คอลัมน์ — เต็มความกว้าง 277 มม. */
            body.printing-report #admin-stockcard th:nth-child(1) { width: 9%; } body.printing-report #admin-stockcard th:nth-child(2) { width: 12%; }
            body.printing-report #admin-stockcard th:nth-child(3) { width: 22%; } body.printing-report #admin-stockcard th:nth-child(4) { width: 8%; }
            body.printing-report #admin-stockcard th:nth-child(5), body.printing-report #admin-stockcard th:nth-child(6) { width: 8%; }
            body.printing-report #admin-stockcard th:nth-child(7) { width: 7%; } body.printing-report #admin-stockcard th:nth-child(8) { width: 7%; }
            body.printing-report #admin-stockcard th:nth-child(9) { width: 19%; }
            body.printing-report #admin-stockcard tfoot td, body.printing-report #admin-stockcard tfoot td * { white-space: nowrap !important; }
            body.printing-report #admin-stockcard tfoot .text-\[11px\] { font-size: 9.5pt !important; font-weight: 400 !important; }
            body.printing-report #admin-stockcard td:nth-child(4) { text-align: right !important; }
            body.printing-report #admin-stockcard td:nth-child(5), body.printing-report #admin-stockcard td:nth-child(6), body.printing-report #admin-stockcard td:nth-child(7), body.printing-report #admin-stockcard td:nth-child(8) { text-align: center !important; }
            body.printing-report #admin-stockcard td:nth-child(1) { white-space: normal !important; font-size: 10pt !important; }
            /* รายงานวัสดุในคลัง: คอลัมน์รายการกว้างพอให้ชื่อวัสดุไม่ขาดบรรทัดมาก */
            body.printing-report #shared-stock th:nth-child(1) { width: 8%; } body.printing-report #shared-stock th:nth-child(2) { width: 32%; }
            body.printing-report #shared-stock th:nth-child(3) { width: 9%; } body.printing-report #shared-stock th:nth-child(4) { width: 10%; }
            body.printing-report #shared-stock th:nth-child(5) { width: 9%; } body.printing-report #shared-stock th:nth-child(6) { width: 13%; }
            body.printing-report #shared-stock th:nth-child(7) { width: 10%; } body.printing-report #shared-stock th:nth-child(8) { width: 9%; }
            body.printing-report #shared-stock td:nth-child(3), body.printing-report #shared-stock td:nth-child(7) { text-align: right !important; }
            body.printing-report #shared-stock td:nth-child(4), body.printing-report #shared-stock td:nth-child(5), body.printing-report #shared-stock td:nth-child(6), body.printing-report #shared-stock td:nth-child(8) { text-align: center !important; }
            /* ท้ายรายงาน: ลายเซ็น */
            body.printing-report .report-foot { display: flex !important; justify-content: space-around; gap: 20mm; margin-top: 10mm; break-inside: avoid; page-break-inside: avoid; color: #000; }
            body.printing-report .rf-sign { width: 78mm; text-align: center; font-size: 12pt; }
            body.printing-report .rf-line { border-top: 0.7pt dotted #000; margin-top: 14mm; }
            body.printing-report .rf-name { margin-top: 1.5mm; font-weight: 700; }
            body.printing-report .rf-date { margin-top: 0.5mm; font-size: 10.5pt; color: #333; }
        }

/* ปุ่ม +/− กดค้าง (หน้าเบิก) — กันเมนูกดค้าง/เลือกข้อความ/ซูมสองจิ้มบนมือถือ */
.qty-hold { touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; transition: transform .06s ease, background-color .15s ease; }
.qty-hold:active { background-color: #fff; transform: scale(.94); }
