/* Document styles shared by the editor, signing pages and the signed PDF.
   Everything is scoped to .sfdoc so the page and the PDF look the same. */
.sfdoc { font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Liberation Serif", "DejaVu Serif", serif; font-size: 17px; line-height: 1.65; color: #1E2433; }
.sfdoc h1 { font-size: 1.76em; font-weight: 600; letter-spacing: -.01em; line-height: 1.25; margin: 0 0 .6em; }
.sfdoc h2 { font-size: 1.3em; font-weight: 600; line-height: 1.3; margin: 1.2em 0 .4em; }
.sfdoc h3 { font-size: 1.06em; font-weight: 600; margin: 1em 0 .3em; }
.sfdoc p { margin: 0 0 .9em; }
.sfdoc ul, .sfdoc ol { padding-left: 1.4em; margin: 0 0 .9em; }
.sfdoc hr { border: 0; border-top: 1px solid #C9CFDA; margin: 1.4em 0; }

/* Font choices offered in the editor */
.sfdoc .ff-sans, .sfdoc [style*="font-family: sans"] { font-family: Arial, "Liberation Sans", Helvetica, sans-serif; }

/* Tables */
.sfdoc table { border-collapse: collapse; width: 100%; margin: 0 0 1.1em; font-size: .94em; }
.sfdoc th, .sfdoc td { border: 1px solid #C9CFDA; padding: 6px 9px; vertical-align: top; text-align: left; min-width: 40px; }
.sfdoc th { background: #F1F3F7; font-family: Arial, "Liberation Sans", Helvetica, sans-serif; font-size: .82em; font-weight: 650; color: #4A5468; }

/* Line items */
.sfdoc table.sf-items { font-size: .9em; }
.sfdoc table.sf-items .num { text-align: right; white-space: nowrap; }
.sfdoc table.sf-items .empty { color: #7A8396; font-style: italic; text-align: center; }
.sfdoc table.sf-items tfoot td { border-left: 0; border-right: 0; text-align: right; }
.sfdoc table.sf-items tfoot tr.sub td { color: #4A5468; border-bottom: 0; padding-top: 3px; padding-bottom: 3px; }
.sfdoc table.sf-items tfoot tr.total td { font-weight: 700; border-top: 2px solid #1E2433; border-bottom: 0; }

/* Layout blocks */
.sfdoc .sf-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin: 0 0 .9em; }
.sfdoc .sf-col { min-width: 0; }
.sfdoc .sf-box { background: #F3F5F9; border-left: 4px solid #8A94A8; padding: 12px 16px; margin: 0 0 1em; border-radius: 2px; }
.sfdoc .sf-box > :last-child, .sfdoc .sf-col > :last-child { margin-bottom: 0; }
.sfdoc .sf-pagebreak { break-after: page; height: 0; }
.sfdoc img { max-width: 100%; height: auto; }
.sfdoc img.sf-img-small { width: 30%; }
.sfdoc img.sf-img-medium { width: 60%; }
.sfdoc img.sf-img-full { width: 100%; }

/* Filled-in values */
.sfdoc .filled { border-bottom: 1px solid #9AA3B5; padding: 0 2px; }
.sfdoc .blank { color: #9AA3B5; }

/* Letterhead */
.sfdoc .letterhead { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; padding-bottom: 16px; margin-bottom: 30px; border-bottom: 1px solid #DCE0E7; font-family: Arial, "Liberation Sans", Helvetica, sans-serif; font-size: 12px; line-height: 1.45; color: #7A8396; user-select: none; }
.sfdoc .letterhead img { max-height: 58px; max-width: 210px; object-fit: contain; }
.sfdoc .letterhead .lh-text { text-align: right; }
.sfdoc .letterhead .lh-text strong { display: block; color: #1A2233; font-size: 14px; }

/* Signatures */
.sfdoc .sigbox { display: inline-flex; flex-direction: column; min-width: 220px; padding: 4px 4px 0; border-bottom: 1px solid #6E778A; vertical-align: bottom; margin: 6px 0; }
.sfdoc .sigbox img { height: 46px; width: auto; max-width: 240px; object-fit: contain; object-position: left; }
.sfdoc .sigbox .typed { font-family: "Iowan Old Style", "Palatino Linotype", Georgia, "Liberation Serif", serif; font-style: italic; font-size: 28px; color: #13308F; line-height: 1.2; }
.sfdoc .sigbox small { font-family: Arial, "Liberation Sans", Helvetica, sans-serif; font-size: 11px; color: #7A8396; padding-top: 2px; }
.sfdoc td .sigbox { min-width: 0; }

/* Printing (signed PDF) */
.sfdoc.print { font-size: 11.5pt; }
.sfdoc.print tr, .sfdoc.print .sigbox, .sfdoc.print img, .sfdoc.print .sf-box { break-inside: avoid; }
.sfdoc.print h1, .sfdoc.print h2, .sfdoc.print h3 { break-after: avoid; }
