/* 1.19.0 — Báo giá ghép in (ghép tem, ghép tờ rơi, ghép danh thiếp). */
/* 1.20.0: trang khách cùng khung báo giá in (dpm-tgi-khach-trang). Màu in ghép = tím (--tgi-g), in nhanh = --tgi-k, in offset = --tgi-o như báo giá in. */
.dpm-tgi-gh { --tgi-g: #7c3aed; --tgi-g2: #5b21b6; }
.dpm-tgi .dpm-tgi-pp-tab.dpm-tgi-pp-the-gh { border-color: var(--tgi-g); color: var(--tgi-g); }
.dpm-tgi .dpm-tgi-pp-tab.dpm-tgi-pp-the-gh.dpm-tgi-pp-the-mo { background: var(--tgi-g); color: #fff !important; }
.dpm-tgi .dpm-tgi-the-gh { border-color: var(--tgi-g); color: var(--tgi-g); }
.dpm-tgi .dpm-tgi-the-gh.dpm-tgi-the-mo { background: var(--tgi-g); color: #fff; }
.dpm-tgi .dpm-tgi-mau-gh { background: var(--tgi-g); }
.dpm-tgi .dpm-tgi-pp-gh { border-color: var(--tgi-g); background: color-mix(in srgb, var(--tgi-g) 7%, #fff); }
.dpm-tgi .dpm-tgi-pp-gh .dpm-tgi-pp-cau { color: var(--tgi-g); }
.dpm-tgi .dpm-tgi-bg.dpm-tgi-bg-gh thead th { background: var(--tgi-g); color: #fff; }
.dpm-tgi .dpm-tgi-bg.dpm-tgi-bg-gh tr.dpm-tgi-dong-pp th { background: var(--tgi-g2); }
.dpm-tgi .dpm-tgi-bg.dpm-tgi-bg-o thead th { background: var(--tgi-o, #b5121b); color: #fff; }
.dpm-tgi .dpm-tgi-bg.dpm-tgi-bg-o tr.dpm-tgi-dong-pp th { background: var(--tgi-o2, #7f1d1d); }
.dpm-tgi-gh .dpm-tgi-bg td small.dpm-tgi-1sp { display: block; font-weight: 400; font-size: 11.5px; opacity: .75; white-space: nowrap; }
.dpm-tgi-gh .dpm-tgi-bg td { white-space: nowrap; }
.dpm-tgi-gh .dpm-tgi-dt-cot::before { content: "📈"; }
.dpm-tgi-gh .dpm-tgi-pp-goi-y { margin: 6px 0 0; font-size: 13px; color: #475569; }
/* Đồ thị 3 đường: chú thích màu */
.dpm-tgi-gh-dt-giai { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 4px 0 6px; font-size: 13.5px; font-weight: 700; color: #1e293b; }
.dpm-tgi-gh-dt-giai span { display: inline-flex; align-items: center; gap: 6px; }
.dpm-tgi-gh-dt-giai i { display: inline-block; width: 22px; height: 5px; border-radius: 3px; }
/* Phân tích lỗ lãi (nhân viên) */
.dpm-tgi-gh-pt { margin-top: 16px; padding: 14px 16px; border-radius: 12px; border: 2px dashed #94a3b8; background: #f8fafc; }
.dpm-tgi-gh-pt h3 { margin: 0 0 6px; font-size: 16px; }
.dpm-tgi-gh-pt h4 { margin: 14px 0 6px; padding: 6px 10px; border-radius: 6px; background: #334155; color: #fff; font-size: 14px; }
.dpm-tgi-gh-cach { margin: 0 0 8px; font-size: 13.5px; }
.dpm-tgi-gh-do { margin: 0 0 10px; padding: 10px 14px 10px 30px; border-radius: 8px; background: #fef2f2; border: 1px solid #fca5a5; color: #b91c1c; font-size: 13.5px; }
.dpm-tgi-gh-pt .dpm-tgi-gck-dong { display: flex; justify-content: space-between; gap: 12px; padding: 5px 0; border-bottom: 1px solid #e2e8f0; font-size: 13.5px; }
.dpm-tgi-gh-pt .dpm-tgi-gck-dong small { display: block; color: #64748b; font-size: 12px; }
.dpm-tgi-gh-pt .dpm-tgi-gck-dong b { white-space: nowrap; }
.dpm-tgi-gh-dong-do, .dpm-tgi-gh-dong-do b { color: #b91c1c; }
.dpm-tgi-gh-dong-xanh, .dpm-tgi-gh-dong-xanh b { color: #15803d; }
/* Hộp cài đặt trong trang sửa bài */
.dpm-tgi-gh-qt { display: flex; flex-direction: column; gap: 10px; }
.dpm-tgi-gh-muc { border: 1px solid #e2e8f0; border-radius: 8px; overflow: hidden; background: #fff; }
.dpm-tgi-gh-muc-ten { padding: 7px 12px; background: #b5121b; color: #fff; font-weight: 600; font-size: 14px; }
.dpm-tgi-gh-hang { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; padding: 8px 12px; }
.dpm-tgi-gh-hang + .dpm-tgi-gh-hang { border-top: 1px solid #f1f5f9; }
.dpm-tgi-gh-hang small { color: #64748b; }
.dpm-tgi-gh-thu { margin: 18px 0 8px; padding: 7px 12px; border-radius: 6px; background: #1e293b; color: #fff; font-size: 14px; }
@media (max-width: 600px) {
	.dpm-tgi-gh-hang { padding: 8px; }
}


/* 1.19.5: dải tiêu đề trên 4 ô, như trang báo giá in (chữ, màu ở Cài đặt chung) */
.dpm-tgi-gh .dpm-tgi-khoi-ten.dpm-tgi-tg-dau { display: flex; align-items: center; margin: 0 0 12px; padding: 10px 16px; background: var(--tgi-dai, #0f766e); color: #fff; font-size: 17px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; border-radius: 6px; box-shadow: inset 0 -2px 0 rgba(0,0,0,.12); }

/* 1.19.6: ô Số lượng sổ xuống 10 mốc */
.dpm-tgi-gh-sl { position: relative; display: flex; }
.dpm-tgi-gh-sl input { flex: 1 1 auto; min-width: 0; border-top-right-radius: 0 !important; border-bottom-right-radius: 0 !important; }
.dpm-tgi-gh-sl .dpm-tgi-gh-sl-mo { height: auto; align-self: stretch; }
.dpm-tgi-gh-sl-mo { flex: 0 0 38px; height: 38px; border: 1px solid #cbd5e1; border-left: 0; border-radius: 0 6px 6px 0; background: #f1f5f9; font-size: 16px; cursor: pointer; color: #334155; }
.dpm-tgi-gh-sl-ds { position: absolute; top: 40px; left: 0; right: 0; z-index: 50; display: flex; flex-direction: column; max-height: 320px; overflow: auto; background: #fff; border: 1px solid #cbd5e1; border-radius: 6px; box-shadow: 0 8px 24px rgba(0,0,0,.15); }
.dpm-tgi-gh-sl-ds[hidden] { display: none; }
.dpm-tgi-gh-sl-ds button { text-align: left; padding: 8px 12px; border: 0; border-bottom: 1px solid #f1f5f9; background: #fff; font-size: 15px; cursor: pointer; color: #1e293b; }
.dpm-tgi-gh-sl-ds button:hover, .dpm-tgi-gh-sl-ds button.dang { background: #eff6ff; font-weight: 700; }
.dpm-tgi-gh-sl-ds small { padding: 6px 12px; color: #64748b; font-size: 12px; }

/* 1.19.7: hộp Ghép in gọn, cùng kiểu mục 1–5 của báo giá in */
.dpm-tgi-gh-qt.dpm-tgi-sp { max-width: none; }
.dpm-tgi-gh-qt .dpm-tgi-gh-khoi { border: 1px solid #e2e8f0; border-radius: 10px; background: #fff; padding: 12px 14px; }
.dpm-tgi-gh-qt .dpm-tgi-hang { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: flex-end; }
.dpm-tgi-gh-qt .dpm-tgi-hang .dpm-tgi-o { display: flex; flex-direction: column; gap: 3px; font-size: 12.5px; color: #475569; min-width: 120px; }
.dpm-tgi-gh-qt .dpm-tgi-hang .dpm-tgi-o input, .dpm-tgi-gh-qt .dpm-tgi-hang .dpm-tgi-o select { height: 36px; min-width: 120px; font-size: 14px; }
.dpm-tgi-gh-qt .dpm-tgi-gh-o-lt select { min-width: 220px; }
.dpm-tgi-gh-goi { margin: 10px 0 0; font-size: 13px; color: #475569; }
.dpm-tgi-gh-goi-do { color: #b91c1c; }
.dpm-tgi-gh-qt .dpm-tgi-gh { max-width: none; }
.dpm-tgi-gh-qt .dpm-tgi-gh-pt { border: 0; background: #f8fafc; border-radius: 8px; padding: 10px 12px; }
.dpm-tgi-gh-qt .dpm-tgi-gh-pt h3 { font-size: 15px; color: #0f766e; }

/* 1.20.0: trang ghép in rộng bằng trang báo giá in (khung bọc nút Yêu cầu / In / PDF không bó hẹp theo bề rộng bài viết) */
.dpm-tgi-yc-goc[data-loai="gh"] { max-width: none; }
/* 3 tab phương pháp trên điện thoại: chữ nhỏ lại cho vừa */
@container (max-width: 520px) {
	.dpm-tgi-gh .dpm-tgi-pp-tab { padding: 6px 8px; min-width: 0; }
	.dpm-tgi-gh .dpm-tgi-pp-tab b { font-size: 13px; white-space: normal; }
	.dpm-tgi-gh .dpm-tgi-pp-tab span { font-size: 13.5px; white-space: nowrap; }
}
.dpm-tgi-gh-qt .dpm-tgi-gh-o-lt[hidden] { display: none !important; }
.dpm-tgi-gh-lt-rieng { margin: 8px 0 10px; }
/* 1.20.1: bảng nhỏ đứng riêng giữ đủ 4 cột như bảng "Lãi đang áp" */
.dpm-tgi-gh-lt-rieng td:first-child { width: 45%; }
.dpm-tgi-gh-lt-dong td small { display: block; color: #64748b; font-weight: 400; }
/* 1.20.5: danh sách ▾ của ô Số lượng (khối Tính giá nhanh) hiện đè lên trên các thẻ giá bên dưới, không bị khối cắt mất */
.dpm-tgi-gh .dpm-tgi-khoi[data-vung="v1"] { overflow: visible; position: relative; z-index: 30; }
/* 1.20.15: tab IN NHANH/ IN GHÉP (bài tích ở hộp Ghép in) */
.dpm-tgi .dpm-tgi-pp-tab.dpm-tgi-pp-the-kg, .dpm-tgi .dpm-tgi-the-kg { border-color: #4c1d95; color: #4c1d95; --dpm-tab-mau: #4c1d95; }
.dpm-tgi .dpm-tgi-pp-tab.dpm-tgi-pp-the-kg.dpm-tgi-pp-the-mo, .dpm-tgi .dpm-tgi-the-kg.dpm-tgi-the-mo { background: #4c1d95; color: #fff !important; }
.dpm-tgi .dpm-tgi-bg.dpm-tgi-bg-kg thead th { background: #4c1d95; color: #fff; }
.dpm-tgi .dpm-tgi-gh-nhanh { color: var(--tgi-k, #1d4ed8); font-weight: 600; }
.dpm-tgi .dpm-tgi-mau-kg { background: #4c1d95; }
/* 1.20.16: tab IN NHANH/ IN GHÉP — chữ tên nhỏ hơn ~15% cho đủ chỗ; thanh mốc của bảng */
.dpm-tgi .dpm-tgi-pp-tab.dpm-tgi-pp-the-kg b { font-size: .85em; }
.dpm-tgi .dpm-tgi-bg tr.dpm-tgi-dong-ngan-kg td { background: var(--tgi-o, #b5121b) !important; }
/* 1.20.17: dòng đã chọn nhân bản ở đầu bảng — tô đậm hơn dòng gốc */
.dpm-tgi-gh table.dpm-tgi-bg tbody tr.dpm-tgi-dong-chon-dau th, .dpm-tgi-gh table.dpm-tgi-bg tbody tr.dpm-tgi-dong-chon-dau td { background: #fcd34d !important; font-weight: 800; border-bottom: 3px solid #b45309; }
.dpm-tgi-gh .dpm-tgi-cuon table.dpm-tgi-bg tbody tr.dpm-tgi-dong-chon-dau > :first-child { background-color: #fcd34d !important; }
.dpm-tgi-gh table.dpm-tgi-bg tbody tr.dpm-tgi-dong-chon-dau td.dpm-tgi-cot-chon { background: #fbbf24 !important; box-shadow: inset 0 0 0 2px #92400e; }
/* 1.20.17: chữ tên 4 tab trang ghép in cùng một cỡ, nhỏ hơn chút; số tiền giữ cỡ cũ */
.dpm-tgi.dpm-tgi-gh .dpm-tgi-pp-tab b, .dpm-tgi.dpm-tgi-gh .dpm-tgi-pp-tab.dpm-tgi-pp-the-kg b { font-size: 16px; }
@container (max-width: 520px) { .dpm-tgi.dpm-tgi-gh .dpm-tgi-pp-tab b, .dpm-tgi.dpm-tgi-gh .dpm-tgi-pp-tab.dpm-tgi-pp-the-kg b { font-size: 13px; } }
