/* Rule8200 — staged build styles. Neutral contractor palette: charcoal + safety orange. */
* { box-sizing: border-box; }
body { margin: 0; font-family: -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: #1d1f23; background: #f6f6f4; line-height: 1.5; }
.wrap { max-width: 960px; margin: 0 auto; padding: 0 20px; }
a { color: #c94f0c; }

.site-header { background: #1d1f23; color: #fff; }
.header-in { display: flex; justify-content: space-between; align-items: center; padding-top: 14px; padding-bottom: 14px; }
.logo { font-size: 22px; font-weight: 700; letter-spacing: .2px; }
.logo span { color: #f26a1b; }
.site-header nav a { color: #eee; text-decoration: none; margin-left: 18px; font-size: 15px; }
.site-header nav a:hover { color: #f26a1b; }

.demo-banner { background: #fff3e0; border-bottom: 1px solid #f0c48a; color: #7a4a00; text-align: center; padding: 8px 16px; font-size: 14px; }

.hero { background: #23272b; color: #fff; padding: 56px 0 48px; }
.hero h1 { font-size: 38px; line-height: 1.15; margin: 0 0 16px; }
.hero h1 em { color: #f26a1b; font-style: normal; }
.lede { font-size: 18px; max-width: 640px; color: #ddd; }
.hero-note { color: #9aa0a6; font-size: 13px; margin-top: 22px; }

.btn { display: inline-block; border: 1px solid transparent; border-radius: 6px; padding: 10px 18px; font-size: 15px; cursor: pointer; text-decoration: none; }
.btn-primary { background: #c94f0c; color: #fff; }
.btn-primary:hover { background: #a8420a; }
.btn-primary:disabled { background: #b9b9b9; cursor: not-allowed; }
.btn-ghost { background: transparent; color: #c94f0c; border-color: #c94f0c; }
.btn-ghost:disabled { color: #999; border-color: #ccc; cursor: not-allowed; }
.hero .btn-ghost { color: #fff; border-color: #888; margin-left: 8px; }

.tabs { display: flex; gap: 8px; margin: 28px 0 0; flex-wrap: wrap; }
.tab { background: #e8e8e6; border: 1px solid #d5d5d2; border-bottom: none; border-radius: 8px 8px 0 0; padding: 10px 16px; font-size: 15px; cursor: pointer; }
.tab.active { background: #fff; font-weight: 600; }

.panel { background: #fff; border: 1px solid #e2e2df; border-radius: 8px; padding: 24px; margin: 0 0 24px; }
.tab-panel { border-radius: 0 8px 8px 8px; margin-top: 0; }
.panel h2 { margin-top: 0; font-size: 22px; }
.panel-note { color: #555; font-size: 14px; }

.calc-form fieldset { border: 1px solid #e2e2df; border-radius: 6px; margin: 0 0 16px; padding: 14px 16px; }
.calc-form legend { font-weight: 600; padding: 0 6px; }
.calc-form label { display: block; margin: 10px 0; font-size: 14px; color: #333; }
.calc-form label.check { display: flex; gap: 8px; align-items: flex-start; }
.calc-form input[type="number"], .calc-form input[type="text"], .calc-form select {
  display: block; width: 100%; max-width: 520px; margin-top: 4px; padding: 8px 10px;
  border: 1px solid #c9c9c6; border-radius: 5px; font-size: 15px; background: #fff;
}
.calc-form input[type="file"] { display: block; margin-top: 4px; }
.form-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-top: 6px; }
.saved-note { color: #2e7d32; font-size: 14px; }

.result { margin-top: 20px; border-top: 2px solid #f26a1b; padding-top: 14px; }
table.lines { width: 100%; border-collapse: collapse; font-size: 14px; }
table.lines td { border-bottom: 1px solid #eee; padding: 7px 8px; vertical-align: top; }
table.lines td.rule { white-space: nowrap; color: #555; font-variant-numeric: tabular-nums; width: 130px; }
table.lines td.w { text-align: right; white-space: nowrap; font-weight: 600; width: 110px; }
.line-detail { color: #666; font-size: 12.5px; margin-top: 2px; }
.totals { margin-top: 14px; font-size: 15px; }
.totals .big { font-size: 17px; }
.warn { background: #fff3e0; border: 1px solid #f0c48a; border-radius: 6px; padding: 10px 12px; font-size: 14px; }

.job-row { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid #eee; align-items: center; }
.job-meta { color: #666; font-size: 13px; }

.price-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.price-card { border: 1px solid #e2e2df; border-radius: 8px; padding: 20px; }
.price-card.featured { border-color: #f26a1b; box-shadow: 0 2px 10px rgba(242,106,27,.15); }
.price-card .price { font-size: 32px; font-weight: 700; margin: 6px 0 12px; }
.price-card .price small { font-size: 15px; color: #666; font-weight: 400; }
.price-card ul { padding-left: 18px; margin: 0 0 16px; font-size: 14px; }

.site-footer { background: #1d1f23; color: #bbb; padding: 28px 0; margin-top: 12px; font-size: 14px; }
.site-footer .fineprint { color: #888; font-size: 12.5px; }
.site-footer a { color: #f0c48a; }

/* ---------- terms gate / terms view ---------- */
.terms-overlay { position: fixed; inset: 0; background: rgba(20, 22, 25, .74); z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 16px; }
.terms-overlay[hidden] { display: none; }
.terms-gate { z-index: 1100; }
.terms-panel { background: #fff; color: #1d1f23; width: 100%; max-width: 680px; max-height: 92vh; display: flex; flex-direction: column; border-radius: 10px; overflow: hidden; box-shadow: 0 12px 40px rgba(0,0,0,.35); }
.terms-head { padding: 20px 24px 4px; }
.terms-head h2 { margin: 0 0 4px; font-size: 22px; }
.terms-meta { color: #666; font-size: 13px; margin: 0 0 6px; }
.terms-record { color: #2e7d32; font-size: 13.5px; margin: 0 0 6px; }
.terms-body { overflow-y: auto; padding: 6px 24px 10px; font-size: 14px; }
.terms-body h3 { font-size: 15px; margin: 14px 0 4px; }
.terms-body p { margin: 0 0 8px; }
.terms-actions { padding: 14px 24px 20px; border-top: 1px solid #e2e2df; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.terms-declined { color: #a8420a; font-size: 13.5px; margin: 0; flex-basis: 100%; }

/* ---------- print report ---------- */
.report-sheet { background: #fff; color: #111; padding: 40px; max-width: 820px; margin: 0 auto; font-size: 14px; }
.report-head { display: flex; gap: 18px; align-items: center; border-bottom: 3px solid #f26a1b; padding-bottom: 14px; margin-bottom: 18px; }
.report-logo { max-height: 64px; max-width: 200px; }
.report-company { font-size: 22px; font-weight: 700; }
.report-meta { color: #444; font-size: 13px; }
.report-job h1 { font-size: 19px; margin: 0 0 8px; }
.report-job p { margin: 3px 0; }
.report-foot { border-top: 1px solid #ccc; margin-top: 20px; padding-top: 10px; font-size: 11.5px; color: #555; }
.report-h2 { font-size: 15px; margin: 18px 0 6px; }
.report-inputs td:first-child { color: #333; }
.sample-banner { background: #fff3e0; border: 1px solid #f0c48a; border-radius: 6px; padding: 8px 10px; font-size: 13px; }
.report-notice { border: 1.5px solid #c94f0c; background: #fff8f2; border-radius: 6px; padding: 10px 12px; margin-top: 22px; font-size: 12.5px; color: #333; }
.report-notice p { margin: 0; }
.report-sign { margin-top: 26px; font-size: 13px; color: #333; }
.report-sign .sign-line { margin-top: 22px; }
.report-sheet { position: relative; }
.sample-watermark { position: absolute; top: 38%; left: 50%; transform: translate(-50%, -50%) rotate(-24deg); font-size: 110px; font-weight: 800; letter-spacing: 8px; color: rgba(201, 79, 12, 0.13); pointer-events: none; white-space: nowrap; }

@media print {
  body.printing-report > *:not(.report-sheet) { display: none !important; }
  body.printing-report .report-sheet { display: block !important; }
  .report-sheet { padding: 0; max-width: none; }
}
@media (max-width: 640px) {
  .hero h1 { font-size: 29px; }
  .header-in { flex-direction: column; align-items: flex-start; gap: 8px; }
  .site-header nav a { margin: 0 14px 0 0; }
}
