@page { size: A4; margin: 14mm 12mm; }
body  { font-family: 'DejaVu Sans', sans-serif; font-size: 10pt; color: #1f2937; margin: 0; }
.ff-doc { width: 100%; }

.ff-header { width: 100%; display: table; table-layout: fixed; margin-bottom: 16px; border-bottom: 2px solid #1f2937; padding-bottom: 10px; }
.ff-shop { display: table-cell; vertical-align: top; width: 60%; }
.ff-doc-meta { display: table-cell; vertical-align: top; width: 40%; text-align: right; }
.ff-logo { max-height: 40px; max-width: 200px; margin-bottom: 6px; }
.ff-shop-name { font-size: 14pt; font-weight: bold; }
.ff-shop-addr { font-size: 9pt; line-height: 1.5; color: #4b5563; }
.ff-doc-meta h1 { margin: 0 0 6px 0; font-size: 22pt; letter-spacing: 1px; color: #1f2937; }
.ff-doc-meta table { margin-left: auto; font-size: 9pt; }
.ff-doc-meta th { text-align: right; font-weight: normal; color: #6b7280; padding-right: 6px; }
.ff-doc-meta td { font-weight: bold; }

.ff-addresses { width: 100%; display: table; table-layout: fixed; margin-bottom: 14px; }
.ff-addr { display: table-cell; vertical-align: top; padding-right: 12px; width: 50%; }
.ff-addr h3 { margin: 0 0 4px 0; font-size: 9pt; font-weight: bold; color: #6b7280; text-transform: uppercase; letter-spacing: 0.5px; }
.ff-addr { font-size: 9.5pt; line-height: 1.5; }

.ff-lines { width: 100%; border-collapse: collapse; margin-bottom: 12px; }
.ff-lines th, .ff-lines td { padding: 7px 6px; border-bottom: 1px solid #e5e7eb; vertical-align: top; }
.ff-lines thead th { background: #f3f4f6; font-size: 9pt; text-transform: uppercase; letter-spacing: 0.5px; color: #6b7280; }
.ff-lines .col-desc { text-align: left; }
.ff-lines .col-qty,
.ff-lines .col-price,
.ff-lines .col-total { text-align: right; white-space: nowrap; }
.ff-lines .col-qty { width: 12%; }
.ff-lines .col-price,
.ff-lines .col-total { width: 18%; }
.ff-lines small { color: #6b7280; font-size: 8pt; }

.ff-totals { margin-left: auto; margin-top: 6px; border-collapse: collapse; min-width: 40%; }
.ff-totals th, .ff-totals td { padding: 4px 8px; }
.ff-totals th { text-align: right; font-weight: normal; color: #4b5563; }
.ff-totals td { text-align: right; font-weight: bold; }
.ff-grand-total { border-top: 2px solid #1f2937; }
.ff-grand-total th, .ff-grand-total td { font-size: 12pt; padding-top: 8px; }

.ff-notes { margin-top: 18px; padding: 10px; background: #f9fafb; border-left: 3px solid #d1d5db; }
.ff-notes h3 { margin: 0 0 4px 0; font-size: 9pt; color: #6b7280; text-transform: uppercase; letter-spacing: 0.5px; }
.ff-notes p { margin: 0; font-size: 9.5pt; }

.ff-footer { margin-top: 24px; padding-top: 10px; border-top: 1px solid #e5e7eb; text-align: center; color: #9ca3af; font-size: 8pt; }
