/* 직접 작성 견적서 양식 (frontend/quote-templates.js)
   품목 표 칸 규칙 (모든 양식 공통)
   - 고정: 수량 8%, 단가 13.5%, 공급가액(금액) 13.5% (단가와 금액은 같은 너비, 천만원대까지 한 줄), 세액 12.5%
   - 나머지(품명, 규격, 비고)는 견적서마다 가장 긴 글자에 맞춰 나눠 갖는다 (quote-templates.js planCols)
     최소: 품명 22%, 규격 8%, 비고 8% / 남으면 품명에, 모자라면 긴 칸부터 양보
   - 그래도 길면 품명, 규격은 두 줄로, 비고는 두 줄 없이 글자를 줄인다
   - 금액은 오른쪽, 수량은 가운데 정렬 */

.qt-page { width: 210mm; height: 297mm; padding: 45px 42px; box-sizing: border-box; background: #fff; color: #111; font-family: var(--qt-font, 'Nanum Gothic'), sans-serif;
  position: relative; overflow: hidden; display: flex; flex-direction: column; font-size: 10.5pt; line-height: 1.3; }
.qt-page *, .qt-page *::before, .qt-page *::after { box-sizing: border-box; }
.qt-pages .qt-page { margin: 0 auto 18px; box-shadow: 0 4px 24px rgba(0,0,0,.12); }
/* 품목 줄을 채울 때 위쪽 칸이 눌려 줄어들지 않게 */
.qt-page > *, .qt-page .md-card > * { flex-shrink: 0; }
.qt-render-host { position: fixed; left: -12000px; top: 0; width: 210mm; }
.qt-fit { display: block; overflow: hidden; white-space: nowrap; }
.qt-pageno { position: absolute; bottom: 5mm; right: 11mm; font-size: 8pt; color: #6b7280; }

/* ── 테두리형 ── */
.qt-frame .fr { border: 2px solid #111; display: flex; flex-direction: column; }
.qt-frame .fr-head { position: relative; height: 80px; display: flex; align-items: center; justify-content: center; border-bottom: 2px solid #111; }
.qt-frame .fr-no { position: absolute; left: 5mm; bottom: 4.5mm; width: 54mm; display: flex; align-items: baseline; gap: 3mm; border-bottom: 1px solid #111; padding: 0 1mm 1mm; font-size: 10pt; }
.qt-frame .fr-no-v { flex: 1; }
.qt-frame .fr-title { font-size: 25pt; font-weight: 800; letter-spacing: 9mm; margin-right: -9mm; }
.qt-frame .fr-info { display: flex; height: 182px; border-bottom: 2px solid #111; }
.qt-frame .fr-left { width: 41%; padding: 5mm 4mm 3.5mm 5mm; display: flex; flex-direction: column; }
.qt-frame .fr-date { font-size: 11pt; word-spacing: 1.5mm; }
.qt-frame .fr-date b { font-weight: 400; }
.qt-frame .fr-to { margin-top: 7mm; display: flex; align-items: flex-end; gap: 2mm; border-bottom: 1.2px solid #111; padding: 0 1mm 1.5mm; }
.qt-frame .fr-to-v { flex: 1; text-align: center; font-size: 12.5pt; font-weight: 800; }
.qt-frame .fr-to > span:last-child { font-size: 11pt; flex: none; }
.qt-frame .fr-fields { margin-top: 2.5mm; font-size: 8.6pt; line-height: 1.55; }
.qt-frame .fr-fields > div { display: flex; gap: 2mm; }
.qt-frame .fr-fields > div > span:first-child { flex: none; width: 15mm; color: #374151; }
.qt-frame .fr-fields .qt-fit { flex: 1; }
.qt-frame .fr-gap { flex: 1; }
.qt-frame .fr-lead { margin-top: auto; font-size: 10.5pt; }
.qt-frame .fr-sup { flex: 1; height: 100%; align-self: stretch; border-collapse: collapse; table-layout: fixed; border-left: 2px solid #111; }
.qt-frame .fr-sup col.c-v { width: 9mm; }
.qt-frame .fr-sup col.c-th { width: 25mm; }
.qt-frame .fr-sup col.c-th2 { width: 11mm; }
.qt-frame .fr-sup col.c-v2 { width: 33mm; }
.qt-frame .fr-sup th, .qt-frame .fr-sup td { border: 1px solid #111; font-weight: 400; text-align: center; padding: 0 1.5mm; font-size: 10.5pt; }
.qt-frame .fr-sup tr:first-child > * { border-top: 0; }
.qt-frame .fr-sup tr:last-child > * { border-bottom: 0; }
.qt-frame .fr-sup tr > *:last-child { border-right: 0; }
.qt-frame .fr-sup th { letter-spacing: .3mm; }
.qt-frame .fr-sup th.v { line-height: 1.05; border-bottom: 0; }
.qt-frame .fr-sup tr { height: 36px; }
.qt-frame .fr-sup th.n { padding: 0; letter-spacing: 0; }
.qt-frame .fr-sup td.ceo { position: relative; }
.qt-frame .fr-sup td.ceo .qt-fit { padding-right: 8mm; }
.qt-frame .fr-sup td.ceo .in { position: absolute; right: 1.5mm; top: 50%; transform: translateY(-50%); }
.qt-frame .fr-stamp { position: absolute; right: -1mm; top: 50%; transform: translateY(-50%); opacity: .92; pointer-events: none; }
.qt-frame .fr-amt { display: flex; align-items: center; height: 56px; border-bottom: 2px solid #111; padding: 0 4mm 0 5mm; font-size: 10.5pt; }
.qt-frame .fr-amt .l { flex: none; width: 52mm; }
.qt-frame .fr-amt .k { flex: 1; text-align: center; font-size: 12pt; }
.qt-frame .fr-amt .r { flex: none; width: 52mm; text-align: right; white-space: nowrap; }
.qt-frame .fr-amt .r b { font-size: 12pt; margin: 0 2mm 0 6mm; }
.qt-frame .fr-items { width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-frame .fr-items col.c1 { width: 40%; } .qt-frame .fr-items col.c2 { width: 11%; } .qt-frame .fr-items col.c3 { width: 8%; }
.qt-frame .fr-items col.c4 { width: 13.5%; } .qt-frame .fr-items col.c5 { width: 13.5%; } .qt-frame .fr-items col.c6 { width: 14%; }
.qt-frame .fr-items th { height: 36px; font-weight: 400; font-size: 11pt; border-bottom: 2px solid #111; border-right: 1px solid #111; white-space: nowrap; }
.qt-frame .fr-items td { height: 34px; border-bottom: 1px solid #111; border-right: 1px solid #111; padding: 0 1.5mm; text-align: center; font-size: 10.5pt; }
.qt-frame .fr-items th:nth-child(4), .qt-frame .fr-items td:nth-child(4) { border-right: 2px solid #111; }
.qt-frame .fr-items th:nth-child(5), .qt-frame .fr-items td:nth-child(5) { border-right: 2px solid #111; }
.qt-frame .fr-items th:last-child, .qt-frame .fr-items td:last-child { border-right: 0; }
.qt-frame .fr-items td.n { text-align: right; padding-right: 2.5mm; }
.qt-frame .fr-items tbody tr:last-child td { border-bottom: 0; }
.qt-frame .fr-items tr.fr-sec td { text-align: left; padding-left: 3mm; font-weight: 700; border-right: 0; }
.qt-frame .fr-items tr.fr-subt td { background: #f3f4f6; font-weight: 700; }
.qt-frame .fr-items tfoot td { height: 38px; font-size: 11pt; border-bottom: 1px solid #111; }
.qt-frame .fr-items tfoot tr:first-child td { border-top: 2px solid #111; }
.qt-frame .fr-items tfoot tr.last td { border-bottom: 0; font-weight: 700; }

.qt-frame .fr-notes { margin-top: 3.5mm; font-size: 10pt; line-height: 1.6; }

@media print {
  body.printing .qt-pages .qt-page { box-shadow: none; margin: 0; break-after: page; }
  body.printing .qt-pages .qt-page:last-child { break-after: auto; }
}

/* ── 선형 (회색, 베이지) ── */
.qt-line { --ln-th: #f1f1f1; --ln-sum: #f1f1f1; --ln-line: #c4c4c4; }
.qt-line.beige { --ln-th: #f8e8cc; --ln-sum: #f3f3f3; }
.qt-line .ln-title { text-align: center; font-size: 28pt; font-weight: 800; letter-spacing: 14px; margin: 8px 0 26px; padding-left: 14px; }
.qt-line .ln-info { display: flex; height: 186px; border-bottom: 3px solid #111; }
.qt-line .ln-left { width: 42%; padding: 8px 18px 10px 4px; display: flex; flex-direction: column; }
.qt-line .ln-date { font-size: 11.5pt; word-spacing: 4px; }
.qt-line .ln-date b { font-weight: 400; }
.qt-line .ln-to { margin-top: 36px; display: flex; align-items: flex-end; gap: 6px; border-bottom: 1.5px solid #111; padding: 0 2px 4px; }
.qt-line .ln-to-v { flex: 1; text-align: center; font-size: 13pt; font-weight: 800; }
.qt-line .ln-to > span:last-child { font-size: 11pt; flex: none; }
.qt-line .ln-fields { margin-top: 8px; font-size: 8.6pt; line-height: 1.5; }
.qt-line .ln-fields > div { display: flex; gap: 6px; }
.qt-line .ln-fields > div > span:first-child { flex: none; width: 54px; color: #374151; }
.qt-line .ln-fields .qt-fit { flex: 1; }
.qt-line .ln-gap { flex: 1; }
.qt-line .ln-lead { margin-top: auto; font-size: 11pt; }
.qt-line .ln-sup { flex: 1; height: 183px; border-collapse: collapse; table-layout: fixed; border-top: 3px solid #111; }
.qt-line .ln-sup col.c-v { width: 34px; } .qt-line .ln-sup col.c-th { width: 84px; }
.qt-line .ln-sup tr { height: 36px; }
.qt-line .ln-sup th, .qt-line .ln-sup td { border-bottom: 1px solid var(--ln-line); border-left: 1px solid var(--ln-line); font-size: 10.5pt; text-align: center; padding: 0 4px; font-weight: 400; }
.qt-line .ln-sup th { background: var(--ln-th); letter-spacing: 1px; white-space: nowrap; }
.qt-line .ln-sup th.v { background: #fff; line-height: 1.9; border-left: 0; }
.qt-line .ln-sup tr:last-child > * { border-bottom: 0; }
.qt-line .ln-sup td.ceo { position: relative; }
.qt-line .ln-sup td.ceo .qt-fit { padding-right: 28px; }
.qt-line .ln-sup td.ceo .in { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); }
.qt-line .ln-stamp { position: absolute; right: -4px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-line .ln-amt { display: flex; height: 68px; border-bottom: 3px solid #111; }
.qt-line .ln-amt .l { width: 160px; background: var(--ln-th); display: flex; flex-direction: column; justify-content: center; align-items: center; font-weight: 800; font-size: 12pt; line-height: 1.3; border-right: 1px solid var(--ln-line); }
.qt-line .ln-amt .l span { font-size: 9.5pt; font-weight: 700; }
.qt-line .ln-amt .v { flex: 1; display: flex; align-items: center; gap: 12px; padding: 0 16px; font-size: 12pt; }
.qt-line .ln-amt .v b { flex: 1; text-align: right; font-weight: 800; }
.qt-line .ln-amt .w { white-space: nowrap; margin-left: 18px; }
.qt-line .ln-amt .w b { font-weight: 800; margin: 0 8px 0 18px; }
.qt-line .ln-items { width: 100%; border-collapse: collapse; table-layout: fixed; border-bottom: 3px solid #111; line-height: 1.2; }
.qt-line .ln-items th { height: 38px; background: var(--ln-th); font-weight: 400; font-size: 11.5pt; border-bottom: 1px solid #8a8a8a; border-left: 1px solid var(--ln-line); white-space: nowrap; }
.qt-line .ln-items td { height: 34px; border-bottom: 1px solid var(--ln-line); border-left: 1px solid var(--ln-line); text-align: center; padding: 0 6px; font-size: 11pt; }
.qt-line .ln-items th:first-child, .qt-line .ln-items td:first-child { border-left: 0; }
.qt-line .ln-items td.n { text-align: right; padding-right: 10px; }
.qt-line .ln-items tr.ln-sec td { text-align: left; padding-left: 12px; font-weight: 700; }
.qt-line .ln-items tr.ln-subt td { background: var(--ln-sum); font-weight: 700; }
.qt-line .ln-items tfoot td { height: 42px; background: var(--ln-sum); font-size: 11.5pt; border-top: 1px solid #8a8a8a; }
.qt-line .ln-items tfoot tr.total td { font-weight: 800; }
.qt-line .ln-notes { margin-top: 10px; font-size: 10pt; line-height: 1.6; }

/* ── 단정형 ── */
.qt-simple .sm-title { text-align: center; font-size: 30pt; font-weight: 700; letter-spacing: 16px; padding-left: 16px; margin-top: 16px; }
.qt-simple .sm-rule { width: 300px; height: 10px; margin: 6px auto 34px; border-top: 6px solid #111; border-bottom: 2px solid #111; border-radius: 3px 3px 0 0; }
.qt-simple .sm-info { display: flex; gap: 28px; height: 232px; }
.qt-simple .sm-left { width: 34%; display: flex; flex-direction: column; justify-content: space-between; padding-bottom: 2px; }
.qt-simple .sm-line { display: flex; align-items: flex-end; justify-content: flex-end; gap: 6px; border-bottom: 1px solid #333; padding: 0 2px 6px; font-size: 12pt; }
.qt-simple .sm-line.to .sm-to-v { flex: 1; text-align: center; font-weight: 700; }
.qt-simple .sm-line.amt { justify-content: space-between; }
.qt-simple .sm-line.amt .sm-k { flex: 1; text-align: center; font-weight: 700; }
.qt-simple .sm-sub { font-size: 9pt; color: #555; text-align: right; }
.qt-simple .sm-sup { flex: 1; height: 232px; border-collapse: collapse; table-layout: fixed; border: 1px solid #222; }
.qt-simple .sm-sup col.c-th { width: 104px; } .qt-simple .sm-sup col.c-th2 { width: 66px; }
.qt-simple .sm-sup th, .qt-simple .sm-sup td { border: 1px solid #222; padding: 0 6px; font-size: 10.5pt; }
.qt-simple .sm-sup th { background: #e8e6e3; font-weight: 400; font-size: 9.5pt; }
.qt-simple .sm-sup td.ceo { position: relative; }
.qt-simple .sm-stamp { position: absolute; right: 2px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-simple .sm-items { margin-top: 30px; width: 100%; border-collapse: collapse; table-layout: fixed; border: 1px solid #222; line-height: 1.2; }
.qt-simple .sm-items th { height: 42px; background: #e8e6e3; font-weight: 400; font-size: 10.5pt; border: 1px solid #222; }
.qt-simple .sm-items td { height: 40px; border: 1px solid #222; text-align: center; padding: 0 6px; font-size: 10.5pt; }
.qt-simple .sm-items td.l { text-align: left; padding-left: 10px; }
.qt-simple .sm-items td.n { text-align: right; padding-right: 10px; }
.qt-simple .sm-items tr.sm-sec td { text-align: left; padding-left: 10px; font-weight: 700; }
.qt-simple .sm-items tr.sm-subt td { background: #f3f2f0; font-weight: 700; }
.qt-simple .sm-items tfoot td { height: 42px; background: #e8e6e3; font-size: 11pt; }
.qt-simple .sm-notes { margin-top: 10px; font-size: 10pt; line-height: 1.6; }
.qt-simple .sm-thanks { margin-top: auto; padding-top: 14px; text-align: center; font-size: 14pt; }

/* ── 블루형 ── */
.qt-blue { --bl: #1d4c8f; --bl-soft: #dbe8fb; padding: 0 42px 92px; }
.qt-blue .bl-band { position: absolute; left: 0; right: 0; top: 0; height: 150px; background: var(--bl-soft); }
.qt-blue .bl-band.short { height: 48px; }
.qt-blue .bl-cont { position: relative; height: 48px; display: flex; align-items: center; font-weight: 700; color: var(--bl); margin-bottom: 18px; }
.qt-blue .bl-head { position: relative; height: 150px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.qt-blue .bl-sup-name { flex: 1; min-width: 0; font-size: 20pt; font-weight: 800; color: var(--bl); }
.qt-blue .bl-titlebox { text-align: right; flex: none; }
.qt-blue .bl-title { font-size: 34pt; font-weight: 800; color: var(--bl); letter-spacing: 14px; margin-right: -14px; }
.qt-blue .bl-no { color: #5d7fb5; letter-spacing: 2px; font-size: 11pt; margin-top: 6px; }
.qt-blue .bl-meta { position: relative; width: 300px; margin: 18px 0 0 auto; }
.qt-blue .bl-meta-line { border-bottom: 1.5px solid var(--bl); padding: 8px 2px 6px; text-align: right; font-size: 12pt; }
.qt-blue .bl-meta-line.to { display: flex; gap: 8px; }
.qt-blue .bl-meta-line.to .qt-fit { flex: 1; text-align: center; font-weight: 700; }
.qt-blue .bl-boxes { display: flex; gap: 22px; margin-top: 24px; }
.qt-blue .bl-left { width: 47%; display: flex; flex-direction: column; gap: 14px; }
.qt-blue .bl-box { border: 1px solid var(--bl); }
.qt-blue .bl-box .h { background: var(--bl); color: #fff; text-align: center; font-size: 10pt; height: 26px; line-height: 26px; font-weight: 700; }
.qt-blue .bl-box .v { background: var(--bl-soft); height: 38px; display: flex; align-items: center; padding: 0 12px; font-size: 11pt; gap: 6px; }
.qt-blue .bl-box .v .qt-fit { flex: 1; }
.qt-blue .bl-box .v.amt .bl-k { text-align: right; font-weight: 700; }
.qt-blue .bl-box .v.sub { height: 24px; justify-content: flex-end; font-size: 10pt; background: #eef4fd; color: var(--bl); font-weight: 700; }
.qt-blue .bl-sup { flex: 1; border-collapse: collapse; table-layout: fixed; align-self: flex-start; }
.qt-blue .bl-sup col.c-th { width: 98px; } .qt-blue .bl-sup col.c-th2 { width: 46px; }
.qt-blue .bl-sup th { white-space: nowrap; }
.qt-blue .bl-sup th, .qt-blue .bl-sup td { height: 29px; border-bottom: 1px solid var(--bl); font-size: 9.5pt; padding: 0 6px; }
.qt-blue .bl-sup th { background: var(--bl-soft); color: var(--bl); font-weight: 400; }
.qt-blue .bl-sup th.h { background: var(--bl); color: #fff; font-weight: 700; font-size: 10pt; height: 26px; }
.qt-blue .bl-items { margin-top: 26px; width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-blue .bl-items th { background: var(--bl); color: #fff; height: 34px; font-size: 10pt; font-weight: 700; border-left: 1px solid #fff; }
.qt-blue .bl-items th:first-child { border-left: 0; }
.qt-blue .bl-items td { height: 32px; border: 1px solid var(--bl); text-align: center; padding: 0 5px; font-size: 10pt; }
.qt-blue .bl-items td.n { text-align: right; padding-right: 8px; }
.qt-blue .bl-items tr.bl-sec td { text-align: left; padding-left: 10px; font-weight: 700; }
.qt-blue .bl-items tr.bl-subt td { background: #eef4fd; font-weight: 700; }
.qt-blue .bl-items tfoot td { height: 36px; background: var(--bl-soft); color: var(--bl); font-weight: 700; font-size: 10.5pt; }
.qt-blue .bl-notes { margin-top: 10px; font-size: 9.5pt; line-height: 1.6; }
.qt-blue .bl-close { display: flex; justify-content: space-between; align-items: center; margin-top: 18px; font-size: 11.5pt; line-height: 1.75; }
.qt-blue .bl-thanks { font-family: 'Great Vibes', cursive; font-size: 36pt; color: #111; padding-right: 10px; }
.qt-blue .bl-bottom { position: absolute; left: 0; right: 0; bottom: 0; height: 62px; background: var(--bl-soft); display: flex; flex-direction: column; justify-content: center; gap: 3px; padding: 0 60px; font-size: 9.5pt; color: var(--bl); }

/* ── 세금계산서형 (초록) ── */
.qt-tax { --tx: #2f8f46; --tx-soft: #b9dcc2; }
.qt-tax .tx { border: 2px solid var(--tx); display: flex; flex-direction: column; }
.qt-tax .tx-title { position: relative; height: 72px; display: flex; align-items: center; justify-content: center; font-size: 28pt; font-weight: 800; letter-spacing: 22px; padding-left: 22px; border-bottom: 2px solid var(--tx); }
.qt-tax .tx-no { position: absolute; right: 12px; bottom: 8px; font-size: 9pt; letter-spacing: 0; font-weight: 400; color: var(--tx); }
.qt-tax .tx-parties { display: flex; border-bottom: 2px solid var(--tx); }
.qt-tax .tx-party { width: 50%; border-collapse: collapse; table-layout: fixed; }
.qt-tax .tx-party + .tx-party { border-left: 2px solid var(--tx); }
.qt-tax .tx-party col.c-v { width: 30px; } .qt-tax .tx-party col.c-th { width: 72px; } .qt-tax .tx-party col.c-th2 { width: 26px; }
.qt-tax .tx-party th, .qt-tax .tx-party td { border: 1px solid var(--tx); height: 44px; font-size: 10pt; padding: 0 4px; text-align: center; font-weight: 400; line-height: 1.25; }
.qt-tax .tx-party tr:first-child > * { border-top: 0; }
.qt-tax .tx-party tr:last-child > * { border-bottom: 0; }
.qt-tax .tx-party th.v { border-left: 0; font-size: 11pt; line-height: 1.35; }
.qt-tax .tx-party tr > *:last-child { border-right: 0; }
.qt-tax .tx-party td.big { font-size: 15pt; font-weight: 700; letter-spacing: 1px; }
.qt-tax .tx-party td.ceo { position: relative; }
.qt-tax .tx-stamp { position: absolute; right: -6px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-tax .tx-items { width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-tax .tx-items th { height: 34px; font-weight: 400; font-size: 11pt; border-bottom: 1.5px solid var(--tx); border-left: 1px solid var(--tx); }
.qt-tax .tx-items td { height: 34px; border-left: 1px solid var(--tx); border-bottom: 1px solid var(--tx-soft); text-align: center; padding: 0 5px; font-size: 10.5pt; }
.qt-tax .tx-items th:first-child, .qt-tax .tx-items td:first-child { border-left: 0; }
.qt-tax .tx-items td.l { text-align: left; padding-left: 8px; }
.qt-tax .tx-items td.n { text-align: right; padding-right: 8px; }
.qt-tax .tx-items tr.tx-mark td, .qt-tax .tx-items tr.tx-sec td { text-align: left; padding-left: 8px; }
.qt-tax .tx-items tr.tx-subt td { font-weight: 700; background: #eef7f0; }
.qt-tax .tx-items tfoot td { height: 54px; border-top: 2px solid var(--tx); border-left: 1px solid var(--tx); font-size: 10pt; line-height: 1.25; }
.qt-tax .tx-items tfoot td.n { font-size: 12pt; font-weight: 700; }

/* ── 공사 설비형 ── */
.qt-site { --st-g: #e6e8eb; --st-line: #3a3f47; }
.qt-site .st-title { text-align: center; font-size: 26pt; font-weight: 800; letter-spacing: 16px; padding-left: 16px; margin-top: 4px; }
.qt-site .st-meta { display: flex; justify-content: space-between; margin-top: 16px; padding: 0 2px 6px; border-bottom: 2px solid var(--st-line); font-size: 10pt; }
.qt-site .st-info { display: flex; gap: 24px; margin-top: 14px; }
.qt-site .st-left { width: 44%; display: flex; flex-direction: column; }
.qt-site .st-to { display: flex; align-items: flex-end; gap: 6px; border-bottom: 1.5px solid var(--st-line); padding: 4px 2px 5px; margin-bottom: 8px; }
.qt-site .st-to-v { flex: 1; text-align: center; font-size: 15pt; font-weight: 800; }
.qt-site .st-to > span:last-child { font-size: 11pt; flex: none; }
.qt-site .st-lead { margin-top: auto; padding-top: 8px; font-size: 10.5pt; }
.qt-site .st-right { flex: 1; min-width: 0; }
.qt-site .st-kvt { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 9.5pt; }
.qt-site .st-kvt col.k { width: 78px; }
.qt-site .st-kvt th { width: 66px; text-align: left; font-weight: 700; color: #4b5563; padding: 3px 0; vertical-align: top; }
.qt-site .st-kvt td { padding: 3px 0; position: relative; }
.qt-site .st-kvt.sup { border-top: 2px solid var(--st-line); border-bottom: 1px solid #c5c9cf; }
.qt-site .st-kvt.sup th, .qt-site .st-kvt.sup td { border-bottom: 1px solid #e3e5e8; padding: 4px 4px; }
.qt-site .st-kvt.sup th { width: 78px; background: #f6f7f8; text-align: center; color: #333; font-weight: 400; }
.qt-site .st-kvt.sup th.h { width: auto; background: var(--st-g); font-weight: 700; letter-spacing: 4px; }
.qt-site .st-stamp { position: absolute; right: 0; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-site .st-extra { font-size: 9pt; color: #4b5563; margin-top: 3px; }
.qt-site .st-amt { display: flex; height: 40px; margin-top: 14px; border: 1.5px solid var(--st-line); border-bottom: 0; }
.qt-site .st-amt .l { width: 120px; background: var(--st-g); display: flex; align-items: center; justify-content: center; font-weight: 800; border-right: 1px solid var(--st-line); }
.qt-site .st-amt .v { flex: 1; display: flex; align-items: center; gap: 14px; padding: 0 12px; font-size: 11.5pt; min-width: 0; }
.qt-site .st-amt .st-k { flex: 1; font-weight: 800; }
.qt-site .st-amt .w { font-weight: 800; white-space: nowrap; flex: none; }
.qt-site .st-amt .t { font-size: 9.5pt; color: #4b5563; white-space: nowrap; flex: none; }
.qt-site .st-items { width: 100%; border-collapse: collapse; table-layout: fixed; border: 1.5px solid var(--st-line); line-height: 1.2; }
.qt-site .st-items th { background: var(--st-g); border: 1px solid var(--st-line); height: 34px; font-size: 10.5pt; font-weight: 700; }
.qt-site .st-items td { height: 24px; border-left: 1px solid #9aa0a8; border-right: 1px solid #9aa0a8; text-align: center; padding: 0 6px; font-size: 10.5pt; }
.qt-site .st-items td.l { text-align: left; }
.qt-site .st-items td.n { text-align: right; padding-right: 8px; }
.qt-site .st-items tr.st-sec td.l { font-weight: 700; }
.qt-site .st-items td.lab { text-align: center; }
.qt-site .st-items tr.st-subt td.lab, .qt-site .st-items tr.st-subt td.n { background: var(--st-g); border-top: 1px solid #9aa0a8; border-bottom: 1px solid #9aa0a8; font-weight: 700; }
.qt-site .st-items tfoot td { border-left: 1px solid #9aa0a8; border-right: 1px solid #9aa0a8; }
.qt-site .st-items tfoot td.lab, .qt-site .st-items tfoot td.n { background: var(--st-g); border-top: 1px solid var(--st-line); font-weight: 700; height: 28px; }
.qt-site .st-notes { border: 1.5px solid var(--st-line); border-top: 0; display: flex; }
.qt-site .st-notes .h { width: 120px; flex: none; background: var(--st-g); display: flex; align-items: center; justify-content: center; font-weight: 700; border-right: 1px solid var(--st-line); border-top: 1px solid var(--st-line); }
.qt-site .st-notes .b { flex: 1; padding: 5px 10px; font-size: 10pt; line-height: 1.5; min-height: 40px; border-top: 1px solid var(--st-line); }

/* ── 모던형 (보라) ── */
.qt-modern { padding: 34px 36px; background: linear-gradient(160deg, #eef0f9 0%, #e1e5f7 55%, #d7eff1 100%); }
.qt-modern .md-card { position: relative; height: 100%; display: flex; flex-direction: column; background: rgba(255,255,255,.7); border: 1px solid #c9cee0; border-radius: 22px; padding: 34px 40px 0; }
.qt-modern .md-spacer { height: 84px; margin-top: auto; }
.qt-modern .md-wavebox { position: absolute; left: 0; right: 0; bottom: 0; height: 76px; overflow: hidden; border-radius: 0 0 22px 22px; }
.qt-modern .md-wavebox i { position: absolute; border-radius: 50%; }
.qt-modern .md-wavebox .w1 { left: -12%; width: 124%; height: 200px; top: 22px; background: #7cc4d8; transform: rotate(-3deg); }
.qt-modern .md-wavebox .w2 { left: -30%; width: 120%; height: 200px; top: 42px; background: #12352f; transform: rotate(4deg); }
.qt-modern .md-wavebox .w3 { left: 34%; width: 110%; height: 200px; top: 40px; background: #3e5f9e; transform: rotate(-6deg); }
.qt-modern .md-head { display: flex; justify-content: space-between; align-items: flex-start; }
.qt-modern .md-title { font-size: 28pt; font-weight: 800; }
.qt-modern .md-title.sm { font-size: 16pt; }
.qt-modern .md-no { font-size: 9.5pt; color: #333; }
.qt-modern .md-info { display: flex; justify-content: space-between; gap: 30px; margin-top: 38px; }
.qt-modern .md-to { width: 340px; border-collapse: collapse; font-size: 10.5pt; table-layout: fixed; }
.qt-modern .md-to th { width: 66px; text-align: left; font-weight: 400; color: #444; padding: 8px 0; border-top: 1px solid #d3d7e4; }
.qt-modern .md-to td { padding: 8px 0; border-top: 1px solid #d3d7e4; }
.qt-modern .md-to tr:last-child > * { border-bottom: 1px solid #d3d7e4; }
.qt-modern .md-right { text-align: right; font-size: 9pt; line-height: 1.75; }
.qt-modern .md-items { margin-top: 30px; width: 100%; border-collapse: collapse; table-layout: fixed; border-top: 2px solid #555; line-height: 1.2; }
.qt-modern .md-items th { height: 36px; font-size: 10pt; font-weight: 700; border-bottom: 1px solid #999; border-left: 1px solid #dcdfe9; }
.qt-modern .md-items td { height: 31px; border-left: 1px solid #dcdfe9; text-align: center; padding: 0 6px; font-size: 10pt; }
.qt-modern .md-items th:first-child, .qt-modern .md-items td:first-child { border-left: 0; }
.qt-modern .md-items td.l { text-align: left; }
.qt-modern .md-items td.n { text-align: right; padding-right: 8px; }
.qt-modern .md-items tr.md-sec td { text-align: left; font-weight: 700; }
.qt-modern .md-items tr.md-subt td { background: rgba(230,233,245,.7); font-weight: 700; }
.qt-modern .md-items tfoot td { height: 36px; border-top: 1px solid #999; border-bottom: 1px solid #999; font-weight: 700; }
.qt-modern .md-bottom { display: flex; justify-content: space-between; gap: 24px; margin-top: 24px; padding-top: 14px; border-top: 1px solid #555; }
.qt-modern .md-notes { flex: 1; font-size: 9pt; line-height: 1.75; }
.qt-modern .md-totals { width: 262px; border-collapse: collapse; font-size: 10pt; }
.qt-modern .md-totals th { text-align: center; padding: 8px; font-weight: 700; border-bottom: 1px solid #d8dbe6; }
.qt-modern .md-totals td { text-align: right; padding: 8px 12px; background: #fff; border-bottom: 1px solid #d8dbe6; }
.qt-modern .md-totals tr.last > * { font-weight: 800; border-bottom: 1.5px solid #555; }
.qt-modern .md-foot { display: flex; justify-content: space-between; align-items: flex-end; margin-top: 20px; font-size: 9.5pt; line-height: 1.6; }
.qt-modern .md-sup { text-align: right; }

/* ── 모던 표형 ── */
.qt-modern2 { --m2: #8aa5bd; --m2-line: #d5dbe3; --m2-soft: #f1f4f7; padding: 40px 46px 36px; }
.qt-modern2 .m2-no.top { position: absolute; top: 22px; right: 46px; font-size: 9pt; color: #444; }
.qt-modern2 .m2-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-top: 14px; }
.qt-modern2 .m2-title { font-size: 26pt; font-weight: 800; letter-spacing: 12px; flex: none; }
.qt-modern2 .m2-title.sm { font-size: 14pt; letter-spacing: 4px; }
.qt-modern2 .m2-brand { flex: 1; min-width: 0; font-size: 13pt; font-weight: 800; color: #2c3e50; text-align: right; }
.qt-modern2 .m2-bar { position: relative; height: 12px; margin-top: 22px; border-bottom: 3px solid var(--m2); }
.qt-modern2 .m2-bar span { position: absolute; right: 0; bottom: -3px; width: 120px; height: 12px; background: var(--m2); border-radius: 8px 0 0 0; }
.qt-modern2 .m2-info { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 9.5pt; }
.qt-modern2 .m2-info col.c-l { width: 86px; } .qt-modern2 .m2-info col.c-lv { width: 214px; } .qt-modern2 .m2-info col.c-th { width: 84px; }
.qt-modern2 .m2-info th, .qt-modern2 .m2-info td { border: 1px solid var(--m2-line); height: 31px; padding: 0 6px; }
.qt-modern2 .m2-info tr:first-child > * { border-top: 0; }
.qt-modern2 .m2-info th { background: var(--m2-soft); font-weight: 400; color: #333; }
.qt-modern2 .m2-info th.h, .qt-modern2 .m2-info th.l { font-weight: 700; }
.qt-modern2 .m2-info td.c { text-align: center; }
.qt-modern2 .m2-info td.to { font-weight: 700; font-size: 11pt; }
.qt-modern2 .m2-info td.amt { font-weight: 700; }
.qt-modern2 .m2-info td { position: relative; }
.qt-modern2 .m2-stamp { position: absolute; right: 0; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-modern2 .m2-items { margin-top: 26px; width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-modern2 .m2-items th { background: var(--m2); color: #fff; height: 34px; font-size: 10pt; font-weight: 700; }
.qt-modern2 .m2-items td { height: 31px; text-align: center; padding: 0 6px; font-size: 10pt; border-bottom: 1px solid #fff; background: #fafbfc; }
.qt-modern2 .m2-items tbody tr:nth-child(even) td { background: #edf0f4; }
.qt-modern2 .m2-items td.l { text-align: left; }
.qt-modern2 .m2-items td.n { text-align: right; padding-right: 10px; }
.qt-modern2 .m2-items tr.m2-sec td { text-align: left; font-weight: 700; }
.qt-modern2 .m2-items tr.m2-subt td { font-weight: 700; background: #e3e8ee; }
.qt-modern2 .m2-items tfoot td { height: 34px; background: #e1e6ec; font-weight: 700; }
.qt-modern2 .m2-total { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; margin-top: 18px; padding-bottom: 8px; border-bottom: 2px solid var(--m2); font-size: 11pt; }
.qt-modern2 .m2-total .v { font-size: 14pt; text-align: right; }
.qt-modern2 .m2-cond { width: 100%; border-collapse: collapse; margin-top: 16px; font-size: 9.5pt; }
.qt-modern2 .m2-cond th { width: 130px; background: var(--m2-soft); font-weight: 700; border: 1px solid var(--m2-line); height: 30px; }
.qt-modern2 .m2-cond td { border: 1px solid var(--m2-line); text-align: center; padding: 5px 10px; line-height: 1.5; }
.qt-modern2 .m2-foot { display: flex; justify-content: space-between; align-items: center; gap: 16px; margin-top: auto; padding-top: 12px; border-top: 1px solid #c8ced6; font-size: 9pt; }
.qt-modern2 .m2-foot b { font-size: 12pt; }

/* ── 요약 박스형 ── */
.qt-box .bx-title { text-align: center; font-size: 28pt; font-weight: 800; letter-spacing: 18px; padding-left: 18px; margin: 4px 0 18px; }
.qt-box .bx-top { width: 100%; border-collapse: collapse; table-layout: fixed; border: 2px solid #222; font-size: 9.5pt; }
.qt-box .bx-top col.c-l { width: 64px; } .qt-box .bx-top col.c-lv { width: 172px; } .qt-box .bx-top col.c-v { width: 26px; }
.qt-box .bx-top col.c-th { width: 98px; } .qt-box .bx-top col.c-th2 { width: 52px; }
.qt-box .bx-top th, .qt-box .bx-top td { border: 1px solid #555; height: 28px; padding: 0 6px; }
.qt-box .bx-top th { font-weight: 400; text-align: center; }
.qt-box .bx-top th.v { line-height: 1.5; }
.qt-box .bx-top td.c { text-align: center; }
.qt-box .bx-top td.n { text-align: right; }
.qt-box .bx-top td.b { font-weight: 700; }
.qt-box .bx-top td.to { position: relative; }
.qt-box .bx-top td.to .qt-fit { padding-right: 26px; text-align: center; }
.qt-box .bx-top td.to span:last-child { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); }
.qt-box .bx-top td.ceo { position: relative; }
.qt-box .bx-top td.ceo .qt-fit { padding-right: 26px; }
.qt-box .bx-top td.ceo .in { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); color: #555; }
.qt-box .bx-stamp { position: absolute; right: -4px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-box .bx-amt { display: flex; height: 50px; margin-top: 12px; border: 2px solid #222; }
.qt-box .bx-amt .l { width: 200px; background: #f6eded; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 12pt; border-right: 1px solid #555; }
.qt-box .bx-amt .v { flex: 1; display: flex; align-items: center; gap: 10px; padding: 0 14px; font-size: 11pt; }
.qt-box .bx-amt .v b { margin-right: auto; font-size: 12pt; }
.qt-box .bx-amt .v span { font-size: 9.5pt; color: #333; }
.qt-box .bx-items { margin-top: 12px; width: 100%; border-collapse: collapse; table-layout: fixed; border: 2px solid #222; line-height: 1.2; }
.qt-box .bx-items th { background: #dfe9f3; height: 32px; font-weight: 400; font-size: 9.5pt; border: 1px solid #555; }
.qt-box .bx-items td { height: 27px; border: 1px solid #777; text-align: center; padding: 0 4px; font-size: 9.5pt; }
.qt-box .bx-items td.l { text-align: left; padding-left: 6px; }
.qt-box .bx-items td.n { text-align: right; padding-right: 6px; }
.qt-box .bx-items tr.bx-sec td { text-align: left; padding-left: 6px; font-weight: 700; }
.qt-box .bx-items tr.bx-subt td { background: #eef3f8; font-weight: 700; }
.qt-box .bx-items tfoot td { height: 30px; background: #dfe9f3; font-weight: 700; }
.qt-box .bx-notes { border: 2px solid #222; border-top: 0; min-height: 110px; padding: 6px 8px; font-size: 9.5pt; line-height: 1.6; }
.qt-box .bx-notes .h { font-weight: 700; }

/* ── 클래식형 ── */
.qt-classic { --cl-g: #e6e6e6; --cl-l: #444; }
.qt-classic .cl-no { font-size: 9.5pt; font-weight: 700; }
.qt-classic .cl-title { width: 280px; margin: 4px auto 22px; text-align: center; font-size: 22pt; letter-spacing: 22px; padding: 0 0 6px 22px; border-bottom: 3px solid #9ca3af; }
.qt-classic .cl-info { width: 100%; border-collapse: collapse; table-layout: fixed; border: 1.5px solid var(--cl-l); font-size: 9.5pt; }
.qt-classic .cl-info col.c-l { width: 40%; } .qt-classic .cl-info col.c-v { width: 26px; } .qt-classic .cl-info col.c-th { width: 72px; } .qt-classic .cl-info col.c-th2 { width: 62px; }
.qt-classic .cl-info th, .qt-classic .cl-info td { border: 1px solid #888; height: 30px; padding: 0 6px; font-weight: 400; }
.qt-classic .cl-info th { background: var(--cl-g); text-align: center; line-height: 1.15; white-space: nowrap; font-size: 9pt; }
.qt-classic .cl-info th.v { background: #fff; line-height: 1.7; }
.qt-classic .cl-info td.l { vertical-align: top; padding: 12px 14px; text-align: center; border-right: 1.5px solid var(--cl-l); }
.qt-classic .cl-info td.ceo { position: relative; }
.qt-classic .cl-stamp { position: absolute; right: -4px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-classic .cl-date { font-size: 10.5pt; word-spacing: 3px; }
.qt-classic .cl-to { margin-top: 26px; }
.qt-classic .cl-to-v { font-size: 13pt; font-weight: 700; }
.qt-classic .cl-site { margin-top: 8px; font-size: 9.5pt; display: flex; justify-content: center; }
.qt-classic .cl-site .qt-fit { max-width: 220px; display: inline-block; vertical-align: bottom; }
.qt-classic .cl-lead { margin-top: 24px; font-size: 10pt; }
.qt-classic .cl-amt { display: flex; height: 44px; border: 1.5px solid var(--cl-l); border-top: 0; }
.qt-classic .cl-amt .l { width: 150px; background: var(--cl-g); border-right: 1px solid #888; display: flex; flex-direction: column; justify-content: center; align-items: center; font-size: 10pt; line-height: 1.25; }
.qt-classic .cl-amt .l span { font-size: 8.5pt; }
.qt-classic .cl-amt .v { flex: 1; display: flex; align-items: center; justify-content: center; font-size: 11.5pt; font-weight: 700; }
.qt-classic .cl-items { width: 100%; border-collapse: collapse; table-layout: fixed; border: 1.5px solid var(--cl-l); border-top: 0; line-height: 1.2; }
.qt-classic .cl-items th { background: var(--cl-g); height: 32px; font-weight: 400; font-size: 10pt; border: 1px solid #888; white-space: nowrap; }
.qt-classic .cl-items td { height: 27px; border-left: 1px solid #888; border-right: 1px solid #888; border-bottom: 1px solid #c4c4c4; text-align: center; padding: 0 5px; font-size: 10pt; }
.qt-classic .cl-items td.n { text-align: right; padding-right: 8px; }
.qt-classic .cl-items tr.cl-sec td { text-align: left; padding-left: 10px; font-weight: 700; }
.qt-classic .cl-items tr.cl-subt td { background: #f3f3f3; font-weight: 700; }
.qt-classic .cl-items tfoot td { height: 32px; background: var(--cl-g); border: 1px solid #888; }
.qt-classic .cl-memo { border: 1.5px solid var(--cl-l); border-top: 0; }
.qt-classic .cl-memo .h { background: var(--cl-g); text-align: center; height: 28px; line-height: 28px; font-size: 10pt; border-bottom: 1px solid #888; }
.qt-classic .cl-memo .b { min-height: 62px; padding: 8px 12px; font-size: 9.5pt; line-height: 1.6; }
.qt-classic .cl-contact { width: 100%; margin-top: 14px; border-collapse: collapse; table-layout: fixed; border: 1.5px solid var(--cl-l); font-size: 9.5pt; }
.qt-classic .cl-contact th { width: 74px; background: var(--cl-g); font-weight: 400; border: 1px solid #888; height: 30px; }
.qt-classic .cl-contact td { border: 1px solid #888; text-align: center; padding: 0 6px; }

/* ── 계약금형 ── */
.qt-contract { padding: 34px 34px; }
.qt-contract .ct-box { min-height: 100%; border: 1.5px solid #222; display: flex; flex-direction: column; padding: 0; }
.qt-contract .ct-box > * { flex-shrink: 0; }
.qt-contract .ct-no.blank { border-bottom-color: transparent; height: 22px; }
.qt-contract .ct-no { width: 200px; margin: 8px 0 0 10px; border-bottom: 1.5px solid #222; font-size: 10.5pt; display: flex; gap: 28px; padding: 0 4px 2px; }
.qt-contract .ct-title { text-align: center; font-size: 26pt; font-weight: 800; letter-spacing: 22px; padding-left: 22px; margin: 0 0 12px; }
.qt-contract .ct-info { display: flex; border-top: 1.5px solid #222; border-bottom: 1.5px solid #222; }
.qt-contract .ct-left { width: 42%; padding: 10px 14px 8px; display: flex; flex-direction: column; }
.qt-contract .ct-date { text-align: center; font-size: 10.5pt; }
.qt-contract .ct-to { margin-top: 16px; display: flex; align-items: flex-end; gap: 6px; border-bottom: 1.5px solid #222; padding-bottom: 3px; }
.qt-contract .ct-to-v { flex: 1; text-align: center; font-size: 15pt; font-weight: 800; letter-spacing: 4px; }
.qt-contract .ct-to > span:last-child { font-size: 9.5pt; flex: none; }
.qt-contract .ct-thanks { margin-top: auto; padding-top: 10px; font-size: 9pt; }
.qt-contract .ct-sup { flex: 1; border-collapse: collapse; table-layout: fixed; border-left: 1.5px solid #222; font-size: 9.5pt; }
.qt-contract .ct-sup col.c-v { width: 24px; } .qt-contract .ct-sup col.c-th { width: 62px; }
.qt-contract .ct-sup th, .qt-contract .ct-sup td { border: 1px solid #777; height: 26px; padding: 0 5px; font-weight: 400; text-align: center; }
.qt-contract .ct-sup tr:first-child > * { border-top: 0; } .qt-contract .ct-sup tr:last-child > * { border-bottom: 0; } .qt-contract .ct-sup tr > *:last-child { border-right: 0; }
.qt-contract .ct-sup th.v { line-height: 1.6; border-left: 0; }
.qt-contract .ct-sup td.ceo { position: relative; }
.qt-contract .ct-stamp { position: absolute; right: -4px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-contract .ct-amt { display: flex; align-items: center; height: 54px; padding: 0 14px; border-bottom: 1.5px solid #222; gap: 14px; }
.qt-contract .ct-amt .l { display: flex; flex-direction: column; align-items: center; width: 110px; font-size: 10.5pt; line-height: 1.3; }
.qt-contract .ct-amt .l span { font-size: 8.5pt; }
.qt-contract .ct-amt .k { font-weight: 800; font-size: 11.5pt; width: 60px; text-align: center; }
.qt-contract .ct-amt .v { flex: 1; min-width: 0; text-align: center; font-weight: 800; font-size: 12pt; }
.qt-contract .ct-amt .w { white-space: nowrap; font-size: 11.5pt; }
.qt-contract .ct-amt .w b { margin: 0 8px 0 24px; }
.qt-contract .ct-items { width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-contract .ct-items th { height: 30px; font-weight: 400; font-size: 10.5pt; border-bottom: 1px solid #777; border-right: 1px solid #777; }
.qt-contract .ct-items td { height: 27px; border-bottom: 1px solid #777; border-right: 1px solid #777; text-align: center; padding: 0 5px; font-size: 10.5pt; }
.qt-contract .ct-items th:last-child, .qt-contract .ct-items td:last-child { border-right: 0; }
.qt-contract .ct-items td.n { text-align: right; padding-right: 8px; }
.qt-contract .ct-items tr.ct-sec td { text-align: left; padding-left: 10px; font-weight: 700; }
.qt-contract .ct-items tr.ct-subt td { background: #f3f4f6; font-weight: 700; }
.qt-contract .ct-items tfoot td { height: 30px; border-bottom: 1.5px solid #222; }
.qt-contract .ct-sums { display: flex; border-bottom: 1.5px solid #222; }
.qt-contract .ct-cell { flex: 1; display: flex; justify-content: space-between; align-items: center; height: 36px; padding: 0 10px; font-size: 10.5pt; border-right: 1.5px solid #222; }
.qt-contract .ct-cell:last-child { border-right: 0; }
.qt-contract .ct-memo { padding: 6px 10px 8px; font-size: 9.5pt; line-height: 1.65; border-bottom: 1.5px solid #222; }
.qt-contract .ct-memo .h { margin-bottom: 2px; }
.qt-contract .ct-contact { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 10pt; border-bottom: 1.5px solid #222; }
.qt-contract .ct-contact col.c-th { width: 62px; }
.qt-contract .ct-contact th, .qt-contract .ct-contact td { height: 32px; border-right: 1px solid #777; border-bottom: 1px solid #777; font-weight: 400; text-align: center; padding: 0 5px; }
.qt-contract .ct-contact tr:last-child > * { border-bottom: 0; } .qt-contract .ct-contact tr > *:last-child { border-right: 0; }
.qt-contract .ct-footer { display: flex; align-items: center; gap: 20px; padding: 8px 16px; }
.qt-contract .ct-footer .nm { width: 180px; font-size: 17pt; font-weight: 800; }
.qt-contract .ct-footer .tx { flex: 1; font-size: 9pt; line-height: 1.6; }

/* ── 조건표형 ── */
.qt-terms { padding: 34px 34px; }
.qt-terms .tm-box { min-height: 100%; border: 1.5px solid #333; display: flex; flex-direction: column; }
.qt-terms .tm-box > * { flex-shrink: 0; }
.qt-terms .tm-title { height: 66px; display: flex; align-items: center; justify-content: center; font-size: 24pt; font-weight: 800; letter-spacing: 6px; border-bottom: 1px solid #333; }
.qt-terms .tm-title.sm { height: 44px; font-size: 14pt; }
.qt-terms .tm-info { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 9.5pt; }
.qt-terms .tm-info col.c-l { width: 43%; } .qt-terms .tm-info col.c-th { width: 66px; }
.qt-terms .tm-info th, .qt-terms .tm-info td { border: 1px solid #777; height: 30px; padding: 0 6px; font-weight: 400; }
.qt-terms .tm-info tr:first-child > * { border-top: 0; } .qt-terms .tm-info tr > *:last-child { border-right: 0; }
.qt-terms .tm-info th { background: #f3f4f6; text-align: center; white-space: nowrap; }
.qt-terms .tm-info td.l { border-left: 0; vertical-align: middle; padding: 0 22px; }
.qt-terms .tm-info td.ceo { position: relative; }
.qt-terms .tm-stamp { position: absolute; right: -4px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-terms .tm-to { display: flex; align-items: flex-end; gap: 8px; border-bottom: 1px solid #333; padding-bottom: 4px; }
.qt-terms .tm-to-v { flex: 1; text-align: center; font-size: 14pt; font-weight: 700; }
.qt-terms .tm-rcv { margin-top: 12px; font-size: 10pt; display: flex; gap: 6px; }
.qt-terms .tm-rcv .qt-fit { flex: 1; }
.qt-terms .tm-lead { height: 30px; line-height: 30px; padding: 0 10px; font-size: 9.5pt; border-top: 1px solid #777; border-bottom: 1px solid #777; }
.qt-terms .tm-amt { display: flex; height: 34px; align-items: stretch; font-size: 10pt; border-bottom: 1px solid #777; }
.qt-terms .tm-amt > div { display: flex; align-items: center; padding: 0 10px; }
.qt-terms .tm-amt .l { width: 90px; justify-content: center; background: #f3f4f6; border-right: 1px solid #777; }
.qt-terms .tm-amt .v { flex: 1; min-width: 0; gap: 4px; font-weight: 700; }
.qt-terms .tm-amt .v .qt-fit { display: inline-block; max-width: 300px; }
.qt-terms .tm-amt .th { width: 80px; justify-content: center; background: #f3f4f6; border-left: 1px solid #777; border-right: 1px solid #777; }
.qt-terms .tm-amt .t { width: 104px; justify-content: center; }
.qt-terms .tm-items { width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-terms .tm-items th { height: 30px; background: #f3f4f6; font-weight: 400; font-size: 9.5pt; border-right: 1px dashed #999; border-bottom: 1px solid #777; }
.qt-terms .tm-items td { height: 27px; border-right: 1px dashed #999; border-bottom: 1px dashed #bbb; text-align: center; padding: 0 5px; font-size: 9.5pt; }
.qt-terms .tm-items th:last-child, .qt-terms .tm-items td:last-child { border-right: 0; }
.qt-terms .tm-items td.l, .qt-terms .tm-items tr.tm-mark td:nth-child(2) { text-align: left; }
.qt-terms .tm-items td.n { text-align: right; padding-right: 8px; }
.qt-terms .tm-items tr.tm-sec td { text-align: left; font-weight: 700; }
.qt-terms .tm-items tr.tm-subt td { background: #f7f7f7; font-weight: 700; }
.qt-terms .tm-items tfoot td { height: 30px; border-top: 1px solid #777; border-bottom: 1px solid #777; text-align: center; }
.qt-terms .tm-items tfoot td.n { text-align: right; }
.qt-terms .tm-grid { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 9.5pt; }
.qt-terms .tm-grid col.c-th { width: 90px; }
.qt-terms .tm-grid th, .qt-terms .tm-grid td { border-right: 1px solid #777; border-bottom: 1px solid #777; height: 30px; padding: 0 8px; font-weight: 400; }
.qt-terms .tm-grid tr > *:last-child { border-right: 0; } .qt-terms .tm-grid tr:last-child > * { border-bottom: 0; }
.qt-terms .tm-grid tr.memo td { height: 52px; vertical-align: top; padding-top: 6px; line-height: 1.55; }
.qt-terms .tm-grid tr.memo th { height: 52px; }


/* ── 미니멀형 ── */
.qt-minimal { padding: 54px 50px 40px; }
.qt-minimal .mn-head { display: flex; justify-content: space-between; align-items: flex-start; }
.qt-minimal .mn-title { font-size: 30pt; font-weight: 800; }
.qt-minimal .mn-title.sm { font-size: 16pt; }
.qt-minimal .mn-r { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; font-size: 8.5pt; padding-top: 14px; }
.qt-minimal .mn-r span { color: #6b7280; }
.qt-minimal .mn-proj { display: flex; gap: 18px; align-items: center; margin-top: 34px; padding-bottom: 6px; border-bottom: 1.5px solid #111; font-size: 10pt; }
.qt-minimal .mn-proj.empty { margin-top: 30px; padding: 0; }
.qt-minimal .mn-proj .qt-fit { flex: 1; }
.qt-minimal .mn-sec { display: flex; gap: 10px; padding: 14px 0; border-bottom: 1px solid #222; }
.qt-minimal .mn-sec > .t { width: 82px; flex: none; font-size: 10pt; font-weight: 700; }
.qt-minimal .mn-sec > .g { flex: 1; margin-left: 110px; display: grid; grid-template-columns: 1.25fr 1fr; column-gap: 18px; row-gap: 10px; min-width: 0; }
.qt-minimal .mn-pair { display: flex; gap: 10px; align-items: center; font-size: 8.5pt; font-weight: 700; min-width: 0; position: relative; }
.qt-minimal .mn-pair > span { flex: none; width: 60px; white-space: nowrap; font-weight: 400; color: #6b7280; }
.qt-minimal .mn-pair .qt-fit { flex: 1; }
.qt-minimal .mn-stamp { position: absolute; right: 0; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-minimal .mn-bars { grid-column: 1 / -1; margin-top: 6px; font-size: 8.5pt; }
.qt-minimal .mn-bars > div { display: flex; height: 22px; align-items: center; padding: 0 8px; }
.qt-minimal .mn-bars span { width: 80px; }
.qt-minimal .mn-bars b { flex: 1; text-align: center; }
.qt-minimal .mn-bars em { font-style: normal; font-size: 7.5pt; opacity: .8; }
.qt-minimal .mn-bars .g1 { background: #f1f1f1; }
.qt-minimal .mn-bars .g2 { background: #111; color: #fff; }
.qt-minimal .mn-sec.items { border-bottom: 0; flex: 1; min-height: 0; }
.qt-minimal .mn-sec.items > div:last-child { flex: 1; min-width: 0; }
.qt-minimal .mn-items { width: 100%; border-collapse: collapse; table-layout: fixed; line-height: 1.2; }
.qt-minimal .mn-items th { font-size: 8pt; font-weight: 400; color: #555; padding: 0 2px 6px; vertical-align: bottom; border-bottom: 1px solid #ccc; }
.qt-minimal .mn-items th small { display: block; font-size: 7pt; color: #888; margin-top: 2px; }
.qt-minimal .mn-items td { height: 23px; border-bottom: 1px solid #e3e3e3; font-size: 8.5pt; text-align: center; padding: 0 3px; font-weight: 700; }
.qt-minimal .mn-items td:first-child { font-weight: 400; text-align: left; }
.qt-minimal .mn-items td.n { text-align: right; }
.qt-minimal .mn-items tr.mn-sec-row td { text-align: left; }
.qt-minimal .mn-items tfoot td { background: #f1f1f1; border-bottom: 0; height: 24px; font-size: 8.5pt; }
.qt-minimal .mn-items tfoot tr:first-child td { border-top: 1.5px solid #222; }
.qt-minimal .mn-items tfoot td.k { text-align: right; font-weight: 400; color: #555; }
.qt-minimal .mn-items tfoot td.e { text-align: left; font-weight: 400; color: #888; font-size: 7.5pt; }
.qt-minimal .mn-items tfoot tr.last td.k { font-weight: 700; color: #111; }
.qt-minimal .mn-notes { margin-top: 12px; font-size: 8.5pt; line-height: 1.6; color: #333; }

/* ── 산출내역형 ── */
.qt-labor { --lb-y: #fff6a8; }
.qt-labor .lb-title { width: 300px; margin: 0 auto; text-align: center; font-size: 20pt; font-weight: 700; padding-bottom: 4px; border-bottom: 1.5px solid #111; }
.qt-labor .lb-title.sm { font-size: 13pt; }
.qt-labor .lb-tel { text-align: right; font-size: 9pt; font-weight: 700; margin-top: 14px; padding-bottom: 4px; border-bottom: 2px solid #111; min-height: 18px; }
.qt-labor .lb-info { display: flex; gap: 40px; margin-top: 14px; }
.qt-labor .lb-box { flex: 1; border: 1.5px solid #111; padding: 4px 8px; font-size: 9pt; position: relative; min-width: 0; }
.qt-labor .lb-box > div { display: flex; gap: 6px; height: 24px; align-items: center; border-bottom: 1px solid #ccc; }
.qt-labor .lb-box > div:last-of-type { border-bottom: 0; }
.qt-labor .lb-box span { flex: none; width: 66px; font-weight: 700; }
.qt-labor .lb-box b { flex: none; }
.qt-labor .lb-box .qt-fit { flex: 1; }
.qt-labor .lb-stamp { position: absolute; right: 6px; top: 6px; opacity: .92; }
.qt-labor .lb-vat { text-align: right; font-size: 8.5pt; margin-top: 8px; }
.qt-labor .lb-amt { display: flex; height: 34px; margin-top: 4px; border: 1.5px solid #111; font-size: 11pt; }
.qt-labor .lb-amt > div { display: flex; align-items: center; }
.qt-labor .lb-amt .l { width: 70px; justify-content: center; background: #e9eef5; font-weight: 700; border-right: 1px solid #111; font-size: 9.5pt; }
.qt-labor .lb-amt .k { width: 60px; justify-content: center; font-weight: 700; }
.qt-labor .lb-amt .v { flex: 1; min-width: 0; justify-content: flex-end; padding-right: 10px; font-weight: 700; }
.qt-labor .lb-amt .w { width: 240px; justify-content: center; background: #bfe0f7; font-weight: 800; font-size: 13pt; border-left: 1px solid #111; }
.qt-labor .lb-items { width: 100%; margin-top: 14px; border-collapse: collapse; table-layout: fixed; border: 1.5px solid #111; line-height: 1.2; }
.qt-labor .lb-items th { height: 32px; background: var(--lb-y); font-size: 9.5pt; border: 1px solid #111; }
.qt-labor .lb-items td { height: 22px; border-left: 1px solid #888; border-right: 1px solid #888; border-bottom: 1px solid #ddd; text-align: center; padding: 0 5px; font-size: 9pt; }
.qt-labor .lb-items td.l { text-align: left; }
.qt-labor .lb-items td.n { text-align: right; padding-right: 8px; }
.qt-labor .lb-items tr.lb-sec td { text-align: left; font-weight: 800; height: 26px; }
.qt-labor .lb-items tr.lb-sec td:first-child { text-align: center; }
.qt-labor .lb-items tr.lb-subt td { background: #fafafa; font-weight: 700; }
.qt-labor .lb-items tfoot td { height: 32px; background: var(--lb-y); border: 1px solid #111; font-weight: 800; letter-spacing: 6px; }
.qt-labor .lb-items tfoot td.g { background: #c9c9c9; }
.qt-labor .lb-items tfoot td.n { letter-spacing: 0; }
.qt-labor .lb-tail { display: flex; justify-content: space-between; gap: 30px; margin-top: 12px; }
.qt-labor .lb-remark { flex: 1; font-size: 9pt; line-height: 1.7; }
.qt-labor .lb-sums { width: 250px; border-collapse: collapse; border: 1.5px solid #111; font-size: 9.5pt; align-self: flex-start; }
.qt-labor .lb-sums th { width: 110px; background: var(--lb-y); border: 1px solid #111; height: 26px; letter-spacing: 4px; }
.qt-labor .lb-sums td { border: 1px solid #111; text-align: right; padding: 0 8px; }

/* ── 참고사항형 ── */
.qt-note .nt-top { display: flex; justify-content: space-between; align-items: flex-start; }
.qt-note .nt-title { width: 210px; height: 100px; border: 1.5px solid #111; display: flex; align-items: center; justify-content: center; font-size: 22pt; }
.qt-note .nt-title.sm { width: auto; height: auto; border: 0; font-size: 14pt; margin-bottom: 10px; }
.qt-note .nt-co { text-align: right; display: flex; flex-direction: column; gap: 4px; font-size: 10pt; font-weight: 700; padding-top: 6px; }
.qt-note .nt-co b { font-size: 13pt; margin-bottom: 8px; }
.qt-note .nt-info { width: 100%; margin-top: 12px; border-collapse: collapse; table-layout: fixed; border: 1.5px solid #111; font-size: 9.5pt; }
.qt-note .nt-info col.c-l { width: 36%; } .qt-note .nt-info col.c-v { width: 22px; } .qt-note .nt-info col.c-th { width: 66px; }
.qt-note .nt-info th, .qt-note .nt-info td { border: 1px solid #555; height: 30px; padding: 0 6px; font-weight: 400; }
.qt-note .nt-info th { text-align: center; white-space: nowrap; }
.qt-note .nt-info th.v { line-height: 1.5; }
.qt-note .nt-info td.l { text-align: center; padding: 6px 14px; line-height: 2; border-right: 1.5px solid #111; }
.qt-note .nt-info td.ceo { position: relative; }
.qt-note .nt-stamp { position: absolute; right: -4px; top: 50%; transform: translateY(-50%); opacity: .92; }
.qt-note .nt-to { display: flex; gap: 6px; align-items: flex-end; border-bottom: 1px solid #111; }
.qt-note .nt-to-v { flex: 1; font-weight: 700; text-align: center; }
.qt-note .nt-items { width: 100%; border-collapse: collapse; table-layout: fixed; border: 1.5px solid #111; border-top: 0; line-height: 1.2; }
.qt-note .nt-items th { height: 30px; font-size: 10pt; border: 1px solid #555; border-bottom: 1.5px solid #111; letter-spacing: 2px; }
.qt-note .nt-items td { height: 28px; border: 1px solid #555; text-align: center; padding: 0 5px; font-size: 10pt; }
.qt-note .nt-items td.l { text-align: left; }
.qt-note .nt-items td.n { text-align: right; padding-right: 8px; }
.qt-note .nt-items tr.nt-sec td { text-align: left; font-weight: 700; }
.qt-note .nt-items tr.nt-subt td { background: #f3f4f6; font-weight: 700; }
.qt-note .nt-items tfoot td { height: 30px; font-weight: 700; }
.qt-note .nt-memo { border: 1.5px solid #111; border-top: 0; min-height: 90px; padding: 8px 10px; font-size: 9.5pt; line-height: 1.6; }
.qt-note .u { text-decoration: underline; font-weight: 700; margin-bottom: 4px; }
.qt-note .nt-ref { border: 1.5px solid #111; border-top: 0; padding: 6px 10px 0; font-size: 9.5pt; }
.qt-note .nt-ref .r { display: flex; gap: 8px; height: 30px; align-items: center; border-top: 1px solid #555; margin: 0 -10px; padding: 0 10px; }
.qt-note .nt-ref .r span { flex: none; font-weight: 700; }
.qt-note .nt-ref .r .qt-fit { flex: 1; }
.qt-note .nt-valid { margin-top: 6px; font-size: 9.5pt; }
.qt-contract .ct-gap { flex: 1 1 auto !important; min-height: 0; }
.qt-contract .ct-footer { border-top: 1.5px solid #222; }

/* ── 세부 내역서 (견적서 뒤에 붙는 장): 고른 양식의 색과 선을 따른다 ── */
.qt-detail { --dh-bg: #fff; --dh-fg: #111; --dl: #555; --do: #111; --ds-bg: #fff; --dsub: transparent; --dsec: transparent; }
.qt-detail.t-basic { --dh-bg: #e9e9ea; --dl: #9ca3af; --ds-bg: #f3f4f6; }
.qt-detail.t-lineGray { --dh-bg: #f1f1f1; --dl: #c4c4c4; --ds-bg: #f1f1f1; }
.qt-detail.t-lineBeige { --dh-bg: #f8e8cc; --dl: #c4c4c4; --ds-bg: #f3f3f3; }
.qt-detail.t-simple { --dh-bg: #e8e6e3; --dl: #222; --ds-bg: #e8e6e3; }
.qt-detail.t-blue { --dh-bg: #1d4c8f; --dh-fg: #fff; --dl: #1d4c8f; --do: #1d4c8f; --ds-bg: #dbe8fb; --dsub: #eef4fd; }
.qt-detail.t-tax { --dl: #2f8f46; --do: #2f8f46; --ds-bg: #eef7f0; }
.qt-detail.t-site { --dh-bg: #e6e8eb; --dl: #9aa0a8; --do: #3a3f47; --ds-bg: #e6e8eb; --dsub: #f3f4f6; }
.qt-detail.t-modern { --dh-bg: #eef0f9; --dl: #dcdfe9; --do: #555; --ds-bg: #eef0f9; }
.qt-detail.t-modern2 { --dh-bg: #8aa5bd; --dh-fg: #fff; --dl: #d5dbe3; --do: #8aa5bd; --ds-bg: #e1e6ec; --dsub: #edf0f4; }
.qt-detail.t-box { --dh-bg: #dfe9f3; --dl: #777; --do: #222; --ds-bg: #dfe9f3; --dsub: #eef3f8; }
.qt-detail.t-classic { --dh-bg: #e6e6e6; --dl: #888; --do: #444; --ds-bg: #e6e6e6; }
.qt-detail.t-terms { --dh-bg: #f3f4f6; --dl: #999; --do: #333; --ds-bg: #f3f4f6; }
.qt-detail.t-minimal { --dh-bg: #fff; --dh-fg: #555; --dl: #e3e3e3; --do: #222; --ds-bg: #f1f1f1; }
.qt-detail.t-labor { --dh-bg: #fff6a8; --dl: #888; --do: #111; --ds-bg: #fff6a8; --dsub: #fffbd6; }
.qt-detail .dt-title { text-align: center; font-size: 22pt; letter-spacing: 14px; padding-left: 14px; margin: 6px 0 18px; }
.qt-detail .dt-meta { display: flex; justify-content: space-between; font-size: 9.5pt; margin-bottom: 6px; }
.qt-detail .dt-items { width: 100%; border-collapse: collapse; table-layout: fixed; border: 1.5px solid var(--do); line-height: 1.2; }
.qt-detail .dt-items th { height: 30px; font-weight: 700; font-size: 10pt; background: var(--dh-bg); color: var(--dh-fg); border: 1px solid var(--dl); border-bottom: 1.5px solid var(--do); }
.qt-detail .dt-items td { height: 30px; border: 1px solid var(--dl); text-align: center; padding: 0 5px; font-size: 9.5pt; }
.qt-detail .dt-items td.l { text-align: left; }
.qt-detail .dt-items td.n { text-align: right; padding-right: 8px; }
.qt-detail .dt-items tr.dt-name td, .qt-detail .dt-items tr.dt-sec td { text-align: left; font-weight: 700; background: var(--dsec); }
.qt-detail .dt-items tr.dt-subt td { font-weight: 700; background: var(--dsub); }
.qt-detail .dt-items tr.dt-subt td:first-child { text-align: left; }
.qt-detail .dt-items tfoot td { height: 32px; font-weight: 800; background: var(--ds-bg); border-top: 1.5px solid var(--do); }
.qt-detail.t-minimal .dt-items, .qt-detail.t-minimal .dt-items td, .qt-detail.t-minimal .dt-items th { border-left: 0; border-right: 0; }
.qt-detail.t-terms .dt-items td { border-style: dashed; }
