/* Customer-facing estimates and invoices, plus the printable review poster and cards.
   Plain, quick on a phone, and clean on paper. */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; font-size: 16px; line-height: 1.5; color: #1c2127; background: #f3f4f6; }
a { color: inherit; }
.doc { max-width: 680px; margin: 0 auto; padding: 16px; display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }
.doc-head { display: flex; align-items: center; gap: 14px; padding: 6px 2px; }
.doc-head div { display: grid; min-width: 0; }
.doc-head strong { font-size: 1.15rem; overflow-wrap: anywhere; }
.doc-head span { color: #5b6470; font-size: .9rem; overflow-wrap: anywhere; }
.doc-logo { width: 52px; height: 52px; object-fit: contain; border-radius: 10px; flex: none; }
.doc-card { background: #fff; border: 1px solid #e3e6ea; border-radius: 14px; padding: 20px; min-width: 0; }
.doc-card h1 { font-size: 1.5rem; line-height: 1.2; margin: 0 0 4px; overflow-wrap: anywhere; }
.doc-card h2 { font-size: 1.15rem; margin: 0 0 10px; }
.doc-card p { margin: 0 0 10px; overflow-wrap: anywhere; }
.doc-card p:last-child { margin-bottom: 0; }
.doc-kind { color: #5b6470; font-weight: 700; font-size: .85rem; letter-spacing: .03em; text-transform: uppercase; margin-bottom: 4px !important; }
.doc-paid { background: #e6f4ea; color: #17673a; padding: 1px 8px; border-radius: 999px; margin-left: 6px; }
.doc-meta { color: #5b6470; font-size: .92rem; }
.doc-terms { color: #5b6470; font-size: .85rem; margin-top: 14px !important; }
.doc-notice { background: #e6f4ea; color: #17673a; border-radius: 10px; padding: 10px 14px; margin: 0; font-weight: 600; }
.doc-done { border-color: #bfe3cc; }
.doc-lines { width: 100%; border-collapse: collapse; margin: 14px 0 6px; }
.doc-lines th { text-align: left; font-size: .78rem; color: #5b6470; font-weight: 600; padding: 4px 0; border-bottom: 1px solid #e3e6ea; }
.doc-lines td { padding: 9px 0; border-bottom: 1px solid #eef0f3; vertical-align: top; overflow-wrap: anywhere; }
.doc-lines small { display: block; color: #5b6470; }
.doc-lines .num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; padding-left: 14px; }
.doc-lines tfoot td { border-bottom: 0; padding: 4px 0; }
.doc-total td { font-weight: 800; font-size: 1.15rem; padding-top: 8px !important; }
.doc-field { display: grid; gap: 6px; margin-bottom: 12px; font-weight: 600; }
.doc-field small { font-weight: 400; color: #5b6470; }
.doc-field input, .doc-field textarea { width: 100%; font: inherit; padding: 12px; border: 1.5px solid #c9ced6; border-radius: 10px; }
.doc-field input:focus, .doc-field textarea:focus { outline: 2px solid var(--biz-accent, #1f7a45); outline-offset: 1px; border-color: transparent; }
.doc-btn { display: inline-block; font: inherit; font-weight: 700; padding: 11px 18px; border-radius: 10px; border: 1.5px solid #c9ced6; background: #fff; color: #1c2127; text-decoration: none; cursor: pointer; }
.doc-btn:disabled { opacity: .6; cursor: default; }
.doc-btn-primary { background: var(--biz-accent, #1f7a45); border-color: var(--biz-accent, #1f7a45); color: #fff; width: 100%; text-align: center; font-size: 1.05rem; padding: 14px 18px; }
.doc-decline { margin-top: 14px; }
.doc-decline summary { cursor: pointer; color: #5b6470; font-size: .92rem; }
.doc-decline form { margin-top: 10px; }
.doc-contact { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0; justify-content: center; color: #5b6470; }
.doc-print { text-align: center; margin: 0; }
.doc-link { background: none; border: 0; font: inherit; color: #5b6470; text-decoration: underline; cursor: pointer; padding: 4px; }
.doc-foot { text-align: center; font-size: .78rem; padding: 6px 0 14px; color: #79828e; }
.doc-foot a { text-decoration: none; }

/* Review poster and cards */
.biz-print-bar { text-align: center; padding: 14px; margin: 0; }
.biz-print-bar button { font: inherit; font-weight: 700; padding: 10px 26px; border-radius: 10px; border: 0; background: var(--biz-accent, #1f7a45); color: #fff; cursor: pointer; }
.poster-page, .cards-page { background: #fff; }
.poster { max-width: 640px; margin: 0 auto; padding: 28px 24px; text-align: center; }
.poster h1 { font-size: clamp(2rem, 7vw, 3.1rem); line-height: 1.1; margin: 0 0 10px; }
.poster-sub { font-size: 1.25rem; margin: 0 0 22px; }
.poster .biz-qr { width: min(100%, 400px); height: auto; }
.poster-url { font-weight: 700; margin: 10px 0 22px; overflow-wrap: anywhere; }
.poster-thanks { color: #444; margin: 0; }
.cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; max-width: 8in; margin: 0 auto; }
.review-card { display: flex; align-items: center; gap: .15in; padding: .18in; border: 1px dashed #bbb; min-height: 2in; min-width: 0; }
.review-card div { min-width: 0; flex: 1 1 auto; }
.review-card strong { display: block; font-size: 1rem; overflow-wrap: anywhere; }
.review-card p { margin: .05in 0 0; font-size: .82rem; line-height: 1.3; }
.review-card .biz-qr { width: 1.35in; height: 1.35in; flex: none; }
@media (max-width: 560px) { .cards { grid-template-columns: minmax(0, 1fr); } }

@media print {
  body { background: #fff; font-size: 12pt; }
  .no-print, .doc-foot { display: none !important; }
  .doc { max-width: none; padding: 0; }
  .doc-card { border: 0; padding: 0; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .review-card { break-inside: avoid; }
}
