/* =========================================================
   Extracted from inline <style> block 1 during v66.3 CSS extraction
   ========================================================= */


:root {
    --border:#1f2937; --light:#f3f4f6; --muted:#6b7280; --accent:#0f4c81;
    --danger:#b91c1c; --good:#047857; --warn:#b45309; --paper:#fff;
  }
  * { box-sizing: border-box; }
  body { font-family: Arial, Helvetica, sans-serif; margin:0; background:#eef2f7; color:#111827; }
  .app-shell { max-width:1200px; margin:0 auto; padding:18px; }
  .topbar { display:flex; justify-content:space-between; align-items:center; gap:12px; margin-bottom:14px; }
  .topbar-actions { display:flex; align-items:center; gap:8px; flex-wrap:wrap; justify-content:flex-end; }
  .topbar-actions button { padding:7px 11px; }
  .job-address-under-jobnumber { grid-column:3 / span 2; }
  .brand h1 { margin:0; font-size:22px; }
  .brand p { margin:3px 0 0; color:var(--muted); font-size:13px; }
  .brand-with-logo { display:flex; align-items:center; gap:12px; }
  .brand-logo { height:46px; width:auto; max-width:150px; display:block; object-fit:contain; }
  .void-action-wrap { display:flex; flex-direction:column; gap:4px; align-items:flex-start; }
  .void-action-note { font-size:11px; color:var(--muted); }
  .badge { border:1px solid #cbd5e1; background:white; border-radius:999px; padding:7px 12px; font-size:13px; color:#334155; }
  .card { background:white; border:1px solid #d1d5db; border-radius:10px; padding:16px; margin-bottom:16px; box-shadow:0 1px 3px rgba(0,0,0,0.05); }
  .hidden { display:none !important; }
  .grid { display:grid; gap:12px; }
  .grid.two { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .grid.three { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .grid.four { grid-template-columns:repeat(4,minmax(0,1fr)); }
  .grid.five { grid-template-columns:repeat(5,minmax(0,1fr)); }
  .grid.po-meta-grid { grid-template-columns:1fr .8fr .8fr 1fr .8fr; }
  label { font-weight:bold; font-size:13px; display:block; margin-bottom:5px; }
  input, select, textarea, button { font-family:inherit; font-size:15px; }
  input, select, textarea { width:100%; border:1px solid #94a3b8; border-radius:6px; padding:10px 11px; background:white; min-height:42px; line-height:1.3; }
  textarea { min-height:72px; resize:vertical; }
  input[readonly], textarea[readonly] { background:#f8fafc; }
  button { border:0; border-radius:7px; padding:9px 12px; background:var(--accent); color:white; cursor:pointer; font-weight:bold; }
  button.secondary { background:#475569; }
  button.light { background:#e2e8f0; color:#111827; }
  button.good { background:var(--good); }
  button.danger { background:var(--danger); }
  button:disabled { opacity:.5; cursor:not-allowed; }
  .button-row { display:flex; flex-wrap:wrap; gap:8px; align-items:center; }
  .inline-field { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:8px; align-items:start; }
  .modal-overlay { position:fixed; inset:0; background:rgba(15,23,42,.62); z-index:99999; display:flex; align-items:center; justify-content:center; padding:18px; }
  .modal-panel { width:min(640px,100%); background:white; border:1px solid #cbd5e1; border-radius:12px; padding:16px; box-shadow:0 14px 40px rgba(0,0,0,.22); }
  .modal-panel h2 { margin-top:0; }
  .status { border-left:4px solid #94a3b8; background:#f8fafc; padding:10px 12px; border-radius:6px; font-size:14px; margin-bottom:12px; white-space:pre-wrap; }
  .status.ok { border-left-color:var(--good); background:#ecfdf5; color:#064e3b; }
  .status.warn { border-left-color:#f59e0b; background:#fffbeb; color:#78350f; }
  .status.error { border-left-color:var(--danger); background:#fef2f2; color:#7f1d1d; }
  .small { font-size:12px; color:var(--muted); }
  .attachment-box { border:1px dashed #94a3b8; background:#f8fafc; border-radius:8px; padding:12px; }
  .attachment-box input[type="file"] { background:white; }
  .attachment-list { margin-top:8px; display:grid; gap:4px; }
  .attachment-pill { display:flex; justify-content:space-between; gap:8px; border:1px solid #cbd5e1; background:white; border-radius:6px; padding:6px 8px; font-size:12px; color:#334155; }
  .required-missing { border-color:#ef4444 !important; background:#fff1f2 !important; box-shadow:0 0 0 2px rgba(239,68,68,.15); }
  .compact-profile { display:flex; flex-wrap:wrap; gap:10px; align-items:center; font-size:14px; }
  .compact-profile span { border:1px solid #cbd5e1; background:#f8fafc; border-radius:999px; padding:6px 10px; }
  .step-card { border:1px solid #cbd5e1; border-radius:10px; padding:14px; background:#f8fafc; margin-top:12px; }
  table { width:100%; border-collapse:collapse; }
  th, td { border:1px solid #cbd5e1; padding:6px; vertical-align:top; }
  th { background:#f8fafc; font-size:12px; text-transform:uppercase; letter-spacing:.02em; }
  td input, td textarea { border:0; padding:8px 9px; border-radius:0; font-size:15px; min-height:40px; }
  td textarea { min-height:46px; line-height:1.3; }
  .line-num { text-align:center; color:#475569; width:36px; }
  .qty-cell { width:120px; }
  .qty-wrap input { text-align:right; }
  .char-count { font-size:10.5px; color:var(--muted); text-align:right; padding:0 4px 3px; }
  .char-count.warn { color:var(--danger); font-weight:bold; }
  .amount { text-align:right; white-space:nowrap; }
  .totals-box { max-width:360px; margin-left:auto; }
  .totals-box .row { display:flex; justify-content:space-between; border-bottom:1px solid #e5e7eb; padding:6px 0; }
  .totals-box .grand { font-weight:bold; font-size:18px; }
  .report-summary-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; }
  .report-summary-tile { border:1px solid #cbd5e1; border-radius:8px; background:#f8fafc; padding:10px; }
  .report-summary-tile .label { color:var(--muted); font-size:11px; text-transform:uppercase; letter-spacing:.03em; margin-bottom:4px; }
  .report-summary-tile .value { font-size:18px; font-weight:bold; }
  .report-table-wrap { overflow:auto; border:1px solid #cbd5e1; border-radius:8px; }
  .report-table-wrap table { width:100%; min-width:1080px; table-layout:fixed; font-size:12px; }
  #reportTable th, #reportTable td { padding:5px 6px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
  #reportTable th:nth-child(1), #reportTable td:nth-child(1) { width:92px; }
  #reportTable th:nth-child(2), #reportTable td:nth-child(2) { width:150px; }
  #reportTable th:nth-child(3), #reportTable td:nth-child(3) { width:92px; }
  #reportTable th:nth-child(4), #reportTable td:nth-child(4) { width:96px; }
  #reportTable th:nth-child(5), #reportTable td:nth-child(5) { width:122px; }
  #reportTable th:nth-child(6), #reportTable td:nth-child(6) { width:105px; }
  #reportTable th:nth-child(7), #reportTable td:nth-child(7) { width:110px; }
  #reportTable th:nth-child(8), #reportTable td:nth-child(8) { width:126px; }
  #reportTable th:nth-child(9), #reportTable td:nth-child(9) { width:92px; }
  #reportTable th:nth-child(10), #reportTable td:nth-child(10) { width:92px; }
  #reportTable th:nth-child(11), #reportTable td:nth-child(11) { width:105px; }
  .report-pdf-col { white-space:nowrap; }
  .report-pdf-col .light { padding:4px 7px !important; font-size:11px !important; }
  @media (max-width:850px) { .report-summary-grid { grid-template-columns:1fr 1fr; } }
  .report-filter-dropdown { position:absolute; z-index:99999; display:none; max-height:260px; overflow:auto; background:#fff; border:1px solid #94a3b8; border-radius:8px; box-shadow:0 10px 28px rgba(15,23,42,.18); font-size:13px; }
  .report-filter-dropdown .option { padding:7px 10px; cursor:pointer; white-space:nowrap; border-bottom:1px solid #f1f5f9; }
  .report-filter-dropdown .option:hover, .report-filter-dropdown .option.active { background:#e0f2fe; }
  .report-filter-dropdown .empty { padding:8px 10px; color:#64748b; font-style:italic; }
  .config-code { font-family:Consolas, Monaco, monospace; background:#0f172a; color:#e5e7eb; border-radius:8px; padding:12px; overflow:auto; font-size:13px; }
  @media (max-width:850px) { .grid.two, .grid.three, .grid.four, .grid.five, .grid.po-meta-grid, .inline-field { grid-template-columns:1fr; } .job-address-under-jobnumber { grid-column:auto; } }


/* =========================================================
   Extracted from inline <style> block 2 during v66.3 CSS extraction
   ========================================================= */


@page { size: letter; margin: 0.35in; }
  * { box-sizing:border-box; }
  body { font-family: Arial, Helvetica, sans-serif; color:#111827; margin:0; background:#fff; font-size:12px; }
  .screen-actions { position:fixed; top:10px; right:10px; display:flex; gap:8px; z-index:5; }
  .screen-actions button { border:0; border-radius:6px; padding:8px 10px; background:#0f4c81; color:white; font-weight:bold; cursor:pointer; }
  .po-paper, .terms-page { background:#fff; border:1px solid #d1d5db; padding:22px; margin:16px auto; max-width:8.5in; min-height:10.5in; }
  .po-header { display:grid; grid-template-columns:1fr 1fr; gap:12px; border-bottom:2px solid #1f2937; padding-bottom:10px; margin-bottom:12px; }
  .company { font-weight:bold; font-size:15px; line-height:1.35; }
  .company-with-logo { display:flex; align-items:flex-start; gap:10px; }
  .pdf-logo { width:auto; height:50px; max-width:150px; object-fit:contain; flex:0 0 auto; }
  .po-title { text-align:right; }
  .po-title h2 { margin:0; font-size:22px; }
  .preview-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-bottom:10px; }
  .preview-field { margin-bottom:6px; }
  .preview-label { font-weight:bold; color:#374151; }
  table { width:100%; border-collapse:collapse; margin-top:8px; }
  th, td { border:1px solid #cbd5e1; padding:6px; vertical-align:top; }
  th { background:#f8fafc; font-size:12px; text-transform:uppercase; letter-spacing:.02em; }
  .line-num { text-align:center; color:#475569; width:36px; }
  .qty-cell-print { width:80px; text-align:right; }
  .amount { text-align:right; white-space:nowrap; }
  .empty { text-align:center; color:#6b7280; padding:18px; }
  .totals-box { max-width:420px; margin-left:auto; margin-top:12px; }
  .totals-box .row { display:flex; justify-content:space-between; border-bottom:1px solid #e5e7eb; padding:6px 0; }
  .totals-box .grand { font-weight:bold; font-size:18px; }
  .report-summary-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; }
  .report-summary-tile { border:1px solid #cbd5e1; border-radius:8px; background:#f8fafc; padding:10px; }
  .report-summary-tile .label { color:var(--muted); font-size:11px; text-transform:uppercase; letter-spacing:.03em; margin-bottom:4px; }
  .report-summary-tile .value { font-size:18px; font-weight:bold; }
  .report-table-wrap { overflow:auto; border:1px solid #cbd5e1; border-radius:8px; }
  .report-table-wrap table { min-width:1280px; }
  @media (max-width:850px) { .report-summary-grid { grid-template-columns:1fr 1fr; } }
  .report-filter-dropdown { position:absolute; z-index:99999; display:none; max-height:260px; overflow:auto; background:#fff; border:1px solid #94a3b8; border-radius:8px; box-shadow:0 10px 28px rgba(15,23,42,.18); font-size:13px; }
  .report-filter-dropdown .option { padding:7px 10px; cursor:pointer; white-space:nowrap; border-bottom:1px solid #f1f5f9; }
  .report-filter-dropdown .option:hover, .report-filter-dropdown .option.active { background:#e0f2fe; }
  .report-filter-dropdown .empty { padding:8px 10px; color:#64748b; font-style:italic; }
  .terms-page h2 { margin-top:0; text-align:center; font-size:16px; }
  .terms-page p { font-size:10.5px; line-height:1.22; margin:0 0 6px; }
  @media print {
    body { background:white; }
    .screen-actions { display:none; }
    .po-paper, .terms-page { border:0; margin:0; padding:0.25in; max-width:none; min-height:auto; page-break-after:always; }
    .terms-page { page-break-before:always; page-break-after:auto; }
    tr { page-break-inside:avoid; page-break-after:auto; }
    th { background:#f0f0f0 !important; -webkit-print-color-adjust:exact; print-color-adjust:exact; }
    .terms-page p { font-size:9.25px; line-height:1.22; margin:0 0 5px; }
  }


/* =========================================================
   Extracted from inline <style> block 3 during v66.3 CSS extraction
   ========================================================= */


@page { size: letter; margin: 0.35in; }
  * { box-sizing:border-box; }
  body { font-family: Arial, Helvetica, sans-serif; color:#111827; margin:0; background:#fff; font-size:12px; }
  .screen-actions { position:fixed; top:10px; right:10px; display:flex; gap:8px; z-index:5; }
  .screen-actions button { border:0; border-radius:6px; padding:8px 10px; background:#0f4c81; color:white; font-weight:bold; cursor:pointer; }
  .po-paper, .terms-page { background:#fff; border:1px solid #d1d5db; padding:22px; margin:16px auto; max-width:8.5in; min-height:10.5in; }
  .po-header { display:grid; grid-template-columns:1fr 1fr; gap:12px; border-bottom:2px solid #1f2937; padding-bottom:10px; margin-bottom:12px; }
  .company { font-weight:bold; font-size:15px; line-height:1.35; }
  .company-with-logo { display:flex; align-items:flex-start; gap:10px; }
  .pdf-logo { width:auto; height:50px; max-width:150px; object-fit:contain; flex:0 0 auto; }
  .po-title { text-align:right; }
  .po-title h2 { margin:0; font-size:22px; }
  .preview-grid { display:grid; grid-template-columns:1fr 1fr; gap:12px; margin-bottom:10px; }
  .preview-field { margin-bottom:6px; }
  .preview-label { font-weight:bold; color:#374151; }
  table { width:100%; border-collapse:collapse; margin-top:8px; }
  th, td { border:1px solid #cbd5e1; padding:6px; vertical-align:top; }
  th { background:#f8fafc; font-size:12px; text-transform:uppercase; letter-spacing:.02em; }
  .line-num { text-align:center; color:#475569; width:36px; }
  .qty-cell-print { width:80px; text-align:right; }
  .amount { text-align:right; white-space:nowrap; }
  .empty { text-align:center; color:#6b7280; padding:18px; }
  .totals-box { max-width:360px; margin-left:auto; margin-top:12px; }
  .totals-box .row { display:flex; justify-content:space-between; border-bottom:1px solid #e5e7eb; padding:6px 0; }
  .totals-box .grand { font-weight:bold; font-size:18px; }
  .report-summary-grid { display:grid; grid-template-columns:repeat(6,minmax(0,1fr)); gap:10px; }
  .report-summary-tile { border:1px solid #cbd5e1; border-radius:8px; background:#f8fafc; padding:10px; }
  .report-summary-tile .label { color:var(--muted); font-size:11px; text-transform:uppercase; letter-spacing:.03em; margin-bottom:4px; }
  .report-summary-tile .value { font-size:18px; font-weight:bold; }
  .report-table-wrap { overflow:auto; border:1px solid #cbd5e1; border-radius:8px; }
  .report-table-wrap table { min-width:1280px; }
  @media (max-width:850px) { .report-summary-grid { grid-template-columns:1fr 1fr; } }
  .report-filter-dropdown { position:absolute; z-index:99999; display:none; max-height:260px; overflow:auto; background:#fff; border:1px solid #94a3b8; border-radius:8px; box-shadow:0 10px 28px rgba(15,23,42,.18); font-size:13px; }
  .report-filter-dropdown .option { padding:7px 10px; cursor:pointer; white-space:nowrap; border-bottom:1px solid #f1f5f9; }
  .report-filter-dropdown .option:hover, .report-filter-dropdown .option.active { background:#e0f2fe; }
  .report-filter-dropdown .empty { padding:8px 10px; color:#64748b; font-style:italic; }
  .test-note { margin-top:12px; color:#6b7280; font-size:11px; }
  .terms-page h2 { margin-top:0; text-align:center; font-size:16px; }
  .terms-page p { font-size:10.5px; line-height:1.22; margin:0 0 6px; }
  @media print {
    body { background:white; }
    .screen-actions { display:none; }
    .po-paper, .terms-page { border:0; margin:0; padding:0.25in; max-width:none; min-height:auto; page-break-after:always; }
    .terms-page { page-break-before:always; page-break-after:auto; }
    table { page-break-inside:auto; }
    tr { page-break-inside:avoid; page-break-after:auto; }
    th { background:#f0f0f0 !important; -webkit-print-color-adjust:exact; print-color-adjust:exact; }
    .terms-page p { font-size:9.25px; line-height:1.22; margin:0 0 5px; }
  }

/* v66.6 PO Tax Option form controls */
.po-tax-totals { max-width:460px; }
.po-tax-totals .tax-row { align-items:center; gap:12px; }
.po-tax-totals .tax-row label { font-weight:bold; margin:0; }
.po-tax-totals .tax-row select,
.po-tax-totals .tax-row input { max-width:240px; margin:0; }
.po-tax-totals .tax-row input { text-align:right; }
.po-tax-totals .tax-help { margin:6px 0 8px; text-align:left; color:var(--muted); }
