/* ============================================================
   Trades hub -- styles
   Screen: simple, sturdy, large type and tap targets (>= 48px), WCAG AA.
   Print: only the checklist sheet, black on white, Letter or A4.
   No external fonts, CDNs or trackers.
   ============================================================ */
:root {
  --ink: #0f1f3a;           /* logo navy */
  --muted: #475266;
  --bg: #f2f3f5;            /* light grey page */
  --paper: #fff;
  --line: #d3d7de;          /* 1px card borders */
  --field: #6b7280;         /* input borders: 4.8:1 on white */
  --header: #0f1f3a;
  --orange: #ff6a00;        /* safety orange fill; navy text on it: 5.6:1 */
  --orange-hover: #f05f00;
  --accent: #ff6a00;
  --accent-dark: #c2410c;   /* orange text/lines on white: 5.2:1 */
  --accent-soft: #fff3ea;
  --link: #1747a6;
  --danger: #9b1c1c;
  --focus: #f2a516;
  --radius: 4px;
  --radius-card: 6px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Liberation Sans", sans-serif;
  --font-head: "Barlow Condensed", "Roboto Condensed", "Arial Narrow", "Helvetica Neue Condensed", sans-serif;
}
/* Barlow Condensed Bold (SIL OFL 1.1, see /assets/fonts/OFL-BarlowCondensed.txt), Latin subset, self-hosted */
@font-face { font-family: "Barlow Condensed"; font-style: normal; font-weight: 700; font-display: swap; src: url("/assets/fonts/barlow-condensed-700.woff2") format("woff2"); }
*, *::before, *::after { box-sizing: border-box; }
html { font-size: 106.25%; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 1rem; line-height: 1.55; color: var(--ink); background: var(--bg); overflow-wrap: break-word; }
.wrap { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 1rem; }
main.wrap { padding-top: 1rem; padding-bottom: 3rem; }
main:focus { outline: none; }
h1, h2, h3, .step-h, legend, .trade-h, .nav-btn, .step-badge { font-family: var(--font-head); font-weight: 700; letter-spacing: 0.01em; }
h1, h2, h3 { line-height: 1.08; text-transform: uppercase; }
h1 { font-size: clamp(2rem, 5vw, 2.75rem); margin: 0.35em 0 0.3em; }
h2 { font-size: clamp(1.45rem, 3.2vw, 1.75rem); margin: 1.6em 0 0.5em; }
h3 { font-size: 1.25rem; }
p, li { max-width: 70ch; }
a { color: var(--link); text-underline-offset: 3px; text-decoration-thickness: 2px; }
a:hover { text-decoration-thickness: 3px; }
:focus-visible { outline: 4px solid var(--focus); outline-offset: 2px; box-shadow: 0 0 0 6px #000; border-radius: 4px; }
[hidden] { display: none !important; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: #000; color: #fff; padding: 0.8rem 1.2rem; z-index: 100; }
.skip-link:focus { left: 0; }
.ico { width: 1.15em; height: 1.15em; flex: none; vertical-align: middle; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- header ----------
   Phones/tablets (< 1000px): brand + Menu button; the menu opens a panel below with collapsible trade groups.
   Desktop: brand + "Make your own" on row 1, trade dropdown buttons on row 2. Dropdowns open on click/tap/keyboard (nav.js). */
.site-header { background: #fff; color: var(--ink); border-bottom: 3px solid var(--orange); position: relative; z-index: 20; }
.header-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 0.2rem 1rem; padding-top: 0.4rem; padding-bottom: 0.4rem; }
.brand { display: inline-flex; align-items: center; min-width: 0; min-height: 48px; padding: 2px 0; color: var(--ink); text-decoration: none; margin-right: auto; border-radius: 6px; }
.brand { gap: 0.6rem; }
.brand-mark { width: 2.5rem; height: 2.5rem; flex: none; display: block; }
.brand-word { font-family: var(--font-head); font-weight: 700; font-size: 1.6rem; line-height: 1; text-transform: uppercase; letter-spacing: 0.02em; color: var(--ink); }
.nav-make { display: inline-flex; align-items: center; gap: 0.45rem; min-height: 46px; padding: 0.3rem 1rem; border-radius: var(--radius); background: var(--orange); color: var(--ink); font-weight: 700; text-decoration: none; white-space: nowrap; border: 2px solid var(--orange); }
.nav-make:hover { background: var(--orange-hover); border-color: var(--orange-hover); color: var(--ink); }
.nav-make[aria-current] { border-color: var(--ink); }
.menu-toggle { display: inline-flex; align-items: center; gap: 0.5rem; min-height: 46px; padding: 0.3rem 0.9rem; border: 2px solid var(--ink); border-radius: var(--radius); background: #fff; color: var(--ink); font: inherit; font-weight: 700; cursor: pointer; }
.menu-toggle:hover { background: #eef0f4; }
.menu-toggle[aria-expanded="true"] { background: var(--ink); color: #fff; }
.menu-bars, .menu-bars::before, .menu-bars::after { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 1px; }
.menu-bars { position: relative; }
.menu-bars::before, .menu-bars::after { content: ""; position: absolute; left: 0; }
.menu-bars::before { top: -6px; }
.menu-bars::after { top: 6px; }
.nav-list { list-style: none; margin: 0; padding: 0; }
.nav-list li { max-width: none; }
.nav-btn { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; width: 100%; min-height: 46px; padding: 0.3rem 0.8rem; border: 1px solid transparent; border-radius: var(--radius); background: transparent; color: var(--ink); font-family: var(--font-head); font-size: 1.2rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; text-align: left; cursor: pointer; white-space: nowrap; }
.nav-btn, .menu-toggle { -webkit-tap-highlight-color: transparent; }
.nav-btn:hover { border-color: var(--ink); }
.nav-btn[aria-expanded="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.nav-group.is-current > .nav-btn { text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 3px; text-underline-offset: 6px; }
.nav-caret { width: 0.5em; height: 0.5em; border-right: 2.5px solid currentColor; border-bottom: 2.5px solid currentColor; transform: translateY(-25%) rotate(45deg); flex: none; }
.nav-btn[aria-expanded="true"] .nav-caret { transform: translateY(25%) rotate(-135deg); }
.nav-drop { list-style: none; margin: 0; padding: 0.25rem; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-card); }
.nav-drop a { display: flex; align-items: center; min-height: 46px; padding: 0.3rem 0.75rem; border-radius: 3px; color: var(--ink); font-weight: 600; text-decoration: none; }
.nav-drop a:hover { background: var(--accent-soft); color: var(--ink); text-decoration: underline; }
.nav-drop a[aria-current] { background: var(--accent-soft); box-shadow: inset 4px 0 0 var(--orange); font-weight: 700; }

@media (max-width: 999.98px) {
  .nav-make-wide { display: none; }
  .main-nav { display: none; flex: 1 1 100%; min-width: 0; padding: 0.5rem 0; border-top: 1px solid var(--line); margin-top: 0.3rem; }
  .menu-open .main-nav { display: block; }
  .nav-make-narrow { width: 100%; justify-content: center; margin-bottom: 0.5rem; }
  .nav-list { display: grid; gap: 0.25rem; }
  .nav-btn { border-color: var(--line); }
  .nav-drop { margin: 0.25rem 0 0.4rem; background: var(--bg); }
}
@media (min-width: 1000px) {
  .menu-toggle, .nav-make-narrow { display: none; }
  .main-nav { flex: 1 1 100%; min-width: 0; margin-left: -0.8rem; }
  .nav-list { display: flex; flex-wrap: wrap; gap: 0.2rem; }
  .nav-group { position: relative; }
  .nav-drop { position: absolute; left: 0; top: calc(100% + 6px); min-width: 15rem; width: max-content; max-width: min(26rem, calc(100vw - 2rem)); box-shadow: 0 6px 16px rgba(15,31,58,.14); z-index: 30; }
  .nav-group:nth-last-child(-n+2) .nav-drop { left: auto; right: 0; }
}

/* ---------- intro ---------- */
.intro-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem 1.2rem; margin-bottom: 1rem; }
.lead { font-size: 1.1rem; margin: 0; flex: 1 1 22rem; }
.howto-jump { flex: none; }

/* ---------- buttons + fields ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 48px; padding: 0.5rem 1.1rem;
  border-radius: var(--radius); border: 2px solid var(--orange); background: var(--orange); color: var(--ink); font: inherit; font-weight: 700;
  text-decoration: none; cursor: pointer; text-align: center; max-width: 100%; }
.btn:hover { background: var(--orange-hover); border-color: var(--orange-hover); color: var(--ink); }
.btn.secondary { background: var(--paper); color: var(--ink); border-color: var(--ink); }
.btn.secondary:hover { background: #e9ecf1; border-color: var(--ink); color: var(--ink); }
.btn.small { min-height: 46px; padding: 0.35rem 0.9rem; font-size: 0.95rem; }
.btn.big { min-height: 58px; font-size: 1.1rem; padding: 0.6rem 1.5rem; }
.btn-row { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0.8rem 0; }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 0.2rem 1.2rem 0.9rem; }
.form-step { padding: 0.9rem 0 1rem; border-bottom: 1px solid var(--line); }
.form-step:last-child { border-bottom: 0; }
.step-h { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin: 0 0 0.7rem; font-size: 1.45rem; line-height: 1.1; text-transform: uppercase; }
.step-badge { display: inline-flex; align-items: center; min-height: 1.9rem; padding: 0.05rem 0.6rem; border-radius: 3px; background: var(--ink); color: #fff; font-size: 1.05rem; letter-spacing: 0.04em; }
.step-note { font-family: var(--font); font-weight: 600; font-size: 0.95rem; text-transform: none; letter-spacing: 0; color: var(--muted); }
.field { margin: 0 0 0.75rem; min-width: 0; }
.field > label, .field > .label { display: block; font-weight: 700; margin-bottom: 0.2rem; }
input[type=text], input[type=tel], input[type=email], input[type=date], select {
  width: 100%; min-height: 48px; padding: 0.45rem 0.7rem; font: inherit; color: var(--ink); background: #fff;
  border: 1px solid var(--field); border-radius: var(--radius); }
input:hover, select:hover { border-color: var(--ink); }
.field-tpl, .field-title { max-width: 32rem; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius-card); padding: 0.6rem 1rem 0.4rem; margin: 0; min-width: 0; }
legend { padding: 0 0.4rem; font-size: 1.15rem; text-transform: uppercase; }
.details-grid { display: grid; gap: 1rem; }
@media (min-width: 820px) { .details-grid { grid-template-columns: 1fr 1fr; } }
.field-pair { display: grid; gap: 0 0.8rem; }
@media (min-width: 520px) { .field-pair { grid-template-columns: 1fr 1fr; } }
.hint { color: var(--muted); font-size: 0.95rem; margin: 0.2rem 0 0.6rem; }
.logo-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; }
.file-input { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.logo-row:focus-within .file-btn { outline: 4px solid var(--focus); outline-offset: 2px; box-shadow: 0 0 0 6px #000; }
.logo-thumb { max-height: 52px; max-width: 140px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.choice { display: inline-flex; align-items: center; gap: 0.55rem; min-height: 50px; font-weight: 700; cursor: pointer; }
.choice input { width: 1.5rem; height: 1.5rem; accent-color: var(--ink); }
.options-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0 1rem; }
.options-row .field { flex: 1 1 12rem; max-width: 20rem; }
.options-row .choice { margin-bottom: 0.75rem; }
.drafts { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; }
.drafts-open { display: flex; flex-wrap: wrap; gap: 0.6rem; flex: 1 1 18rem; min-width: 0; }
.drafts-open[hidden] { display: none; }
.drafts-open select { flex: 1 1 100%; width: 100%; min-width: 0; }
.tpl-line { margin: 0 0 0.3rem; font-size: 1.1rem; }
.tpl-hint { color: var(--muted); font-size: 0.95rem; margin: 0.4rem 0 0; }
.tpl-custom { margin: 0.8rem 0 0; padding: 0.5rem 0.8rem 0.1rem; border-left: 4px solid var(--orange); background: var(--accent-soft); border-radius: var(--radius); font-size: 1rem; }
.tpl-custom a { display: flex; align-items: center; gap: 0.3rem; width: fit-content; min-height: 44px; font-weight: 700; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.tpl-custom a:hover { color: var(--accent-dark); }
.browse-home { margin-top: 0.5rem; }
.browse-home > h2 { margin-top: 0.6em; }
.tpl-own-note { color: var(--muted); font-size: 0.95rem; margin-left: 0.4rem; }
.confirm-box { background: var(--accent-soft); border: 1px solid var(--accent-dark); border-left-width: 4px; border-radius: var(--radius); padding: 0.6rem 1rem; margin: 0.8rem 0; }
.confirm-box p { margin: 0.2rem 0 0; font-weight: 700; }
.confirm-box[hidden] { display: none; }
.status { min-height: 1.6em; margin: 0.6rem 0 0; font-weight: 700; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.notice { background: var(--accent-soft); border: 1px solid var(--accent-dark); border-left-width: 4px; border-radius: var(--radius); padding: 0.4rem 1rem; margin-bottom: 1rem; }

/* ---------- item editor ---------- */
.editor { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.9rem; margin: 0.4rem 0 0.9rem; }
.sec-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.6rem; background: #f8f9fa; }
.sec-head, .items li { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; }
.sec-head .sec-toggle { flex: 0 1 auto; min-width: 0; justify-content: flex-start; }
.chev { display: inline-block; width: 1em; }
.sec-body { margin-top: 0.5rem; }
.sec-head .sec-title { flex: 1 1 11rem; width: auto; min-width: 0; font-weight: 700; background: #eef0f4; }
.items { list-style: none; margin: 0 0 0.5rem; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.4rem; }
.items li { max-width: none; }
.items .item-text { flex: 1 1 11rem; width: auto; min-width: 0; }
.row-btns { display: flex; gap: 0.3rem; flex: none; margin-left: auto; }
.icon-btn { width: 48px; height: 48px; border-radius: var(--radius); border: 1px solid var(--field); background: #fff; color: var(--ink); font-size: 1.35rem; font-weight: 800; line-height: 1; cursor: pointer; display: inline-grid; place-items: center; padding: 0; }
.icon-btn:hover:not(:disabled) { background: #e9ecf1; border-color: var(--ink); }
.icon-btn:disabled { opacity: 0.35; cursor: default; }
.icon-btn.danger { color: var(--danger); border-color: var(--danger); }

/* ---------- preview ---------- */
.preview { margin-top: 1.4rem; }
.preview-bar { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 0.2rem 1rem; }
.preview-bar h2 { margin: 0 0 0.5rem; }
.print-ready { margin: 0.35rem 0 0.6rem; outline: none; }
.print-ready:focus { outline: 3px solid var(--focus); outline-offset: 2px; }
.preview-actions { margin: 0.9rem 0 0.2rem; display: flex; flex-direction: column; align-items: stretch; gap: 0.55rem; }
.preview-actions .btn-row { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.preview-actions .btn.big { flex: 1 1 10rem; }
.edit-back { align-self: flex-start; font-weight: 700; font-size: 0.95rem; min-height: 44px; display: inline-flex; align-items: center; text-decoration: underline; }
#print-preview { scroll-margin-top: 0.5rem; }
#step-edit, #step-print { scroll-margin-top: 0.5rem; }
.print-btns-form { margin-top: 0.5rem; }
@media (max-width: 600px) {
  .preview-actions .btn-row { flex-direction: column; }
  .preview-actions .btn.big { width: 100%; flex: 1 1 auto; }
}
.page-est { color: var(--muted); font-weight: 700; }
.preview-frame { overflow: hidden; position: relative; }
.preview-scale { transform-origin: top left; width: max-content; }

/* ---------- after the output ---------- */
.next-step { margin-top: 1.6rem; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 0.4rem 1.2rem 1rem; }
.next-step h2 { margin-top: 0.7rem; }
.next-all { margin: 0.8rem 0 0; }
.next-all a { display: inline-flex; align-items: center; min-height: 48px; font-weight: 700; }
.tpl-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.6rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); }
.tpl-cards li { max-width: none; }
.tpl-card { display: flex; align-items: center; gap: 0.7rem; min-height: 52px; height: 100%; padding: 0.45rem 0.8rem; border: 1px solid var(--line); border-left: 3px solid var(--orange); border-radius: var(--radius); background: #fff; color: var(--ink); font-weight: 700; text-decoration: none; }
.tpl-card:hover { border-color: var(--ink); border-left-color: var(--orange); color: var(--ink); text-decoration: underline; }
.tpl-ico { display: inline-grid; place-items: center; width: 1.6rem; height: 1.6rem; color: var(--ink); flex: none; font-size: 1.15rem; }
.referral { margin-top: 1rem; padding: 0.6rem 1rem; border: 1px solid var(--line); border-radius: var(--radius-card); background: #fff; font-size: 0.95rem; }
.referral[hidden] { display: none; }
.referral-note { color: var(--muted); font-size: 0.85rem; margin: 0.2rem 0 0; }

/* ---------- how to + FAQ ---------- */
.howto { margin-top: 2rem; scroll-margin-top: 0.5rem; }
.howto-steps { list-style: none; counter-reset: s; margin: 0; padding: 0; display: grid; gap: 0.6rem; }
.howto-steps li { counter-increment: s; display: flex; align-items: center; gap: 0.8rem; max-width: 46rem; }
.howto-steps li::before { content: counter(s); flex: none; display: inline-grid; place-items: center; width: 2rem; height: 2rem; border-radius: 3px; background: var(--ink); color: #fff; font-family: var(--font-head); font-size: 1.15rem; font-weight: 700; }
.how-ico { display: inline-grid; place-items: center; width: 1.8rem; height: 1.8rem; flex: none; color: var(--ink); font-size: 1.25rem; }
.back-top a { display: inline-flex; align-items: center; min-height: 48px; font-weight: 700; }
.faq { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; margin: 0 0 0.6rem; max-width: 50rem; }
.faq summary { min-height: 48px; padding: 0.65rem 1rem; font-weight: 700; cursor: pointer; display: list-item; }
.faq-a { padding: 0 1rem 0.4rem; }
.faq-a p { margin: 0 0 0.6rem; }
.page-info main p, .page-info main li { font-size: 1.05rem; }

/* ---------- footer ---------- */
.site-footer { background: var(--header); color: #fff; padding: 1.2rem 0 1.6rem; margin-top: 2rem; border-top: 3px solid var(--orange); }
.footer-links { display: flex; flex-wrap: wrap; gap: 0 1.2rem; }
.footer-links a, .footer-more a { color: #fff; display: inline-flex; align-items: center; justify-content: center; min-height: 46px; min-width: 44px; font-weight: 600; }
.footer-templates { border-bottom: 1px solid #45506b; padding-bottom: 0.4rem; margin-bottom: 0.4rem; }
.footer-more { margin: 0.3rem 0; border-top: 1px solid #45506b; padding-top: 0.3rem; max-width: none; }
.site-footer p { margin: 0.6rem 0 0; font-size: 0.95rem; }

@media (max-width: 600px) {
  .wrap { padding: 0 0.75rem; }
  .panel, .next-step { padding-left: 0.75rem; padding-right: 0.75rem; }
  .sec-card { padding: 0.45rem; }
  .tg-verb { display: none; }
  .row-btns { gap: 0.25rem; }
  .icon-btn { width: 46px; height: 46px; }
  .sec-head .sec-title { flex-basis: 100%; }
  .brand-mark { width: 2.2rem; height: 2.2rem; }
  .brand-word { font-size: 1.4rem; }
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }


/* ============================================================
   THE DOCUMENT SHEET (screen preview + print)
   Plain black on white. Units are pt/in so the preview matches paper.
   ============================================================ */
.sheet {
  --fs: 10pt; --row: 17pt; --gap: 8pt; --ln: 18pt; --sig: 26pt;
  width: 8.5in; min-height: 11in; padding: 0.4in; background: #fff; color: #000;
  font: var(--fs)/1.25 Arial, "Liberation Sans", Helvetica, sans-serif;
  box-shadow: 0 1px 4px rgba(0,0,0,.25); border: 1px solid #b9b4aa;
}
.sheet[data-paper="a4"] { width: 210mm; min-height: 297mm; }
.sheet[data-orient="landscape"] { width: 11in; min-height: 8.5in; }
.sheet[data-paper="a4"][data-orient="landscape"] { width: 297mm; min-height: 210mm; }
.sheet[data-density="compact"] { --fs: 9.5pt; --row: 14.5pt; --gap: 6pt; --ln: 15pt; --sig: 22pt; }
.sheet[data-density="tight"] { --fs: 8.5pt; --row: 12.5pt; --gap: 4pt; --ln: 13pt; --sig: 18pt; }
.sheet .sh-block + .sh-block { margin-top: var(--gap); }
.sh-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14pt; padding-bottom: 6pt; border-bottom: 2pt solid #000; }
.sh-biz { display: flex; align-items: center; gap: 8pt; min-width: 0; flex: 1 1 auto; }
.sh-logo { max-height: 0.6in; max-width: 1.7in; object-fit: contain; }
.sh-biz-name { font-size: 13pt; font-weight: 700; }
.sh-biz-meta { font-size: 8.5pt; margin-top: 1pt; }
.sh-biz-meta .nw { white-space: nowrap; }
.sh-titlebox { text-align: right; flex: none; min-width: 2.3in; max-width: 3.4in; }
.sh-title { font-size: 18pt; font-weight: 700; line-height: 1.1; text-transform: uppercase; letter-spacing: 0.02em; }
.sh-meta { margin: 4pt 0 0; }
.sh-mrow { display: flex; align-items: flex-end; gap: 6pt; margin-top: 2pt; }
.sh-mrow dt { font-size: 7.5pt; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; white-space: nowrap; }
.sh-mrow dd { margin: 0; flex: 1; min-width: 1.2in; min-height: 12pt; border-bottom: 0.75pt solid #000; text-align: left; overflow-wrap: anywhere; }
.sh-h { font-size: 9pt; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; border-bottom: 0.75pt solid #000; margin-bottom: 3pt; padding-bottom: 1pt; }
.sh-job { display: grid; grid-template-columns: repeat(12, 1fr); gap: 3pt 12pt; }
.sh-field { grid-column: span 6; display: flex; align-items: flex-end; gap: 4pt; min-height: 16pt; padding-bottom: 1pt; min-width: 0; border-bottom: 0.75pt solid #000; }
.sh-c3 { grid-column: span 3; } .sh-c4 { grid-column: span 4; } .sh-c6 { grid-column: span 6; } .sh-c8 { grid-column: span 8; } .sh-c12 { grid-column: span 12; }
.sh-field.sh-long { min-height: 30pt; align-items: flex-start; }
.sh-label { font-size: 7.5pt; font-weight: 700; text-transform: uppercase; letter-spacing: 0.02em; white-space: nowrap; }
.sh-val { font-size: var(--fs); flex: 1; min-width: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.sh-items, .sh-grid, .sh-table, .sh-totals { width: 100%; border-collapse: collapse; }
.sh-items { table-layout: fixed; }
.sh-items col.c-qty { width: 0.8in; } .sh-items col.c-rate { width: 1in; } .sh-items col.c-amt { width: 1.2in; } .sh-items col.c-tax { width: 0.4in; }
.sh-items th { font-size: 7.5pt; text-transform: uppercase; letter-spacing: 0.02em; padding: 2pt 4pt; border-bottom: 1.5pt solid #000; }
.sh-items td { height: var(--row); padding: 1pt 4pt; border-bottom: 0.75pt solid #8a8a8a; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.sh-items .l, .sh-grid .l { text-align: left; } .sh-items .r { text-align: right; } .sh-items .c { text-align: center; }
.sh-totals { width: 3.1in; margin: 4pt 0 0 auto; }
.sh-totals th { text-align: left; font-weight: 400; padding: 2pt 4pt; }
.sh-totals td { text-align: right; padding: 2pt 4pt; min-width: 1.2in; border-bottom: 0.75pt solid #8a8a8a; font-variant-numeric: tabular-nums; min-height: 14pt; height: 15pt; }
.sh-totals tr.strong th, .sh-totals tr.strong td { font-weight: 700; border-top: 1.2pt solid #000; }
.sh-text .sh-label { display: block; margin-bottom: 1pt; }
.sh-para { white-space: normal; overflow-wrap: anywhere; margin-bottom: 2pt; }
.sh-text .ln { display: block; height: var(--ln); border-bottom: 0.75pt solid #8a8a8a; }
.sh-grid { table-layout: fixed; }
.sh-grid th { font-size: 7.5pt; text-transform: uppercase; letter-spacing: 0.02em; padding: 2pt 3pt; border: 0.75pt solid #000; background: #e6e6e6; text-align: center; }
.sh-grid th.l { text-align: left; }
.sh-grid td { height: calc(var(--row) * 2.1); padding: 1pt 3pt; border: 0.75pt solid #000; vertical-align: top; overflow-wrap: anywhere; text-align: center; font-variant-numeric: tabular-nums; }
.sh-grid td.l { text-align: left; }
.sh-time td { vertical-align: middle; height: calc(var(--row) * 1.5); }
.sh-time-tot { width: 3.6in; }
.sh-table { table-layout: fixed; }
.sh-table col.c-chk { width: 0.6in; } .sh-table col.c-notes { width: 1.9in; }
.sh-table th, .sh-table td { padding: 1pt 4pt; vertical-align: middle; }
.sh-table thead th { font-size: 7.5pt; font-weight: 700; line-height: 1.05; text-align: center; padding: 2pt 2pt 3pt; border-bottom: 1.5pt solid #000; }
.sh-table thead th.sh-item, .sh-table thead th.sh-notes { text-align: left; padding-left: 4pt; }
.sh-table td { height: var(--row); border-bottom: 0.75pt solid #8a8a8a; }
.sh-table td.sh-notes { border-left: 0.75pt solid #8a8a8a; }
.sh-table td.sh-chk { text-align: center; padding: 0; }
.sh-sec th { text-align: left; font-weight: 700; padding: 2.5pt 4pt; background: #e6e6e6; border-top: 0.75pt solid #000; }
.box { display: inline-block; width: 9pt; height: 9pt; vertical-align: middle; border: 1.2pt solid #000; border-radius: 1pt; }
.blank { display: inline-block; width: 0.45in; height: 0.9em; vertical-align: baseline; border-bottom: 0.75pt solid #000; }
.sh-sign { display: grid; grid-template-columns: 3fr 1.3fr 3fr 1.3fr; gap: 0 12pt; padding-top: 4pt; }
.sh-sign:has(.sh-sig:only-of-type) { grid-template-columns: 3fr 1.3fr; max-width: 60%; }
.sh-sigline { display: block; height: var(--sig); border-bottom: 0.75pt solid #000; }
.sh-sig .sh-label, .sh-sigdate .sh-label { display: block; margin-top: 1pt; }

/* ---------- editor: blocks, fields, lines ---------- */
.blk { border: 1px solid var(--line); border-radius: var(--radius); padding: 0.7rem 0.8rem 0.4rem; background: #fff; margin: 0 0 0.8rem; }
.blk > .blk-h { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; margin: 0 0 0.6rem; }
.blk-h h3 { margin: 0; font-size: 1.25rem; text-transform: uppercase; flex: 1 1 8rem; }
.blk-h input.blk-title { flex: 1 1 10rem; width: auto; font-weight: 700; }
.fgrid { display: grid; gap: 0 0.8rem; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 560px) { .fgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .fgrid .f-full { grid-column: 1 / -1; } }
.field > textarea, textarea.long { width: 100%; min-height: 5.5rem; padding: 0.45rem 0.7rem; font: inherit; color: var(--ink); background: #fff; border: 1px solid var(--field); border-radius: var(--radius); resize: vertical; }
.field input[type=number], input[inputmode=decimal], input[type=time] { width: 100%; min-height: 48px; padding: 0.45rem 0.7rem; font: inherit; color: var(--ink); background: #fff; border: 1px solid var(--field); border-radius: var(--radius); }
.frow { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: flex-end; margin: 0 0 0.6rem; }
.frow .field { margin: 0; flex: 1 1 8rem; }
.frow .field.lab { flex: 1 1 9rem; }
.lines { list-style: none; margin: 0 0 0.6rem; padding: 0; display: grid; gap: 0.6rem; }
.lines li { max-width: none; border: 1px solid var(--line); border-radius: var(--radius); background: #f8f9fa; padding: 0.5rem; display: grid; gap: 0.4rem; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; }
.lines .l-desc { grid-column: 1 / -1; }
.lines label { font-size: 0.9rem; font-weight: 700; display: block; }
.lines .l-amt { font-weight: 700; min-height: 48px; display: flex; align-items: center; justify-content: flex-end; font-variant-numeric: tabular-nums; }
.lines .l-foot { grid-column: 1 / -1; display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.lines .l-tax { display: inline-flex; align-items: center; gap: 0.5rem; min-height: 46px; font-weight: 700; }
.lines .l-tax input { width: 1.4rem; height: 1.4rem; accent-color: var(--ink); }
@media (min-width: 760px) { .lines li { grid-template-columns: minmax(0, 1fr) 6.5rem 8rem 8rem auto; } .lines .l-desc { grid-column: auto; } .lines .l-foot { grid-column: auto; } }
.totals-set { display: grid; gap: 0 0.8rem; grid-template-columns: minmax(0, 1fr); border-top: 1px solid var(--line); padding-top: 0.6rem; }
@media (min-width: 560px) { .totals-set { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.sum { margin: 0.2rem 0 0.6rem; padding: 0.6rem 0.9rem; border: 1px solid var(--line); border-left: 4px solid var(--orange); border-radius: var(--radius); background: var(--accent-soft); font-weight: 700; font-variant-numeric: tabular-nums; }
.sum dl { margin: 0; display: grid; grid-template-columns: 1fr auto; gap: 0.15rem 1rem; max-width: 24rem; }
.sum dt, .sum dd { margin: 0; }
.sum dd { text-align: right; }
.sum .big { font-size: 1.15rem; }
.tc-rows { list-style: none; margin: 0 0 0.8rem; padding: 0; display: grid; gap: 0.5rem; }
.tc-rows li { max-width: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.3rem 0.5rem; align-items: end; border: 1px solid var(--line); border-radius: var(--radius); background: #f8f9fa; padding: 0.45rem 0.5rem; }
.tc-rows .tc-day { grid-column: 1 / -1; font-weight: 700; display: flex; justify-content: space-between; gap: 0.5rem; }
.tc-rows .tc-hrs { font-variant-numeric: tabular-nums; font-weight: 700; }
.tc-rows label { font-size: 0.9rem; font-weight: 700; display: block; }
@media (min-width: 760px) { .tc-rows li { grid-template-columns: 8rem repeat(3, minmax(0, 1fr)) 9rem; } .tc-rows .tc-day { grid-column: auto; flex-direction: column; justify-content: flex-end; min-height: 48px; } }
.grid-ed { display: grid; gap: 0.5rem; }
.grid-row { display: grid; gap: 0.3rem; grid-template-columns: repeat(2, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--radius); background: #f8f9fa; padding: 0.45rem; }
.grid-row .gr-first { grid-column: 1 / -1; }
@media (min-width: 900px) { .grid-row { grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); } .grid-row .gr-first { grid-column: auto; } }
.grid-row label { font-size: 0.85rem; font-weight: 700; display: block; }
.biz-details { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; margin: 0 0 0.8rem; }
.biz-details > summary { min-height: 48px; padding: 0.65rem 1rem; font-weight: 700; cursor: pointer; display: list-item; }
.biz-details[open] > summary { border-bottom: 1px solid var(--line); }
.biz-body { padding: 0.8rem 1rem 0.3rem; }
.add-block { display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: flex-end; border-top: 1px dashed var(--field); padding-top: 0.8rem; margin-top: 0.4rem; }
.add-block .field { flex: 1 1 14rem; max-width: 22rem; margin: 0; }
.tpl-note { margin: 0.6rem 0 0; padding: 0.4rem 0.8rem; border-left: 4px solid var(--ink); background: #eef0f4; border-radius: var(--radius); font-size: 0.95rem; max-width: 46rem; }
.link-btn { background: none; border: 0; padding: 0 0.2rem; min-height: 44px; font: inherit; font-weight: 700; color: var(--link); text-decoration: underline; cursor: pointer; text-underline-offset: 3px; }

/* ---------- print ---------- */
@page { size: letter; margin: 0.4in; }
@media print {
  html { font-size: 12pt !important; }
  body { background: #fff; }
  .site-header, .site-footer, .skip-link, .no-print, main > :not(.tool), .tool > :not(.preview) { display: none !important; }
  main.wrap { padding: 0; max-width: none; }
  .preview { margin: 0; }
  .preview-frame { height: auto !important; overflow: visible; }
  .preview-scale { transform: none !important; width: auto; }
  .sheet, .sheet[data-paper="a4"], .sheet[data-orient="landscape"], .sheet[data-paper="a4"][data-orient="landscape"] { width: auto; min-height: 0; padding: 0; border: 0; box-shadow: none; }
  .sh-block { break-inside: avoid; }
  .sh-table tr, .sh-items tr, .sh-grid tr, .sh-sign { break-inside: avoid; }
  .sheet * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* Browse by trade (home + 404): same trades and names as the main menu */
.trade-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); gap: 0.8rem; margin-top: 0.6rem; }
.trade-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-card); padding: 0.7rem 0.9rem 0.5rem; scroll-margin-top: 0.75rem; }
.trade-card:target { border-color: var(--ink); box-shadow: inset 0 3px 0 var(--orange); }
.trade-h { display: flex; align-items: center; gap: 0.5rem; font-size: 1.35rem; margin: 0 0 0.2rem; padding-bottom: 0.3rem; border-bottom: 2px solid var(--orange); }
.trade-ico { display: inline-grid; place-items: center; width: 1.5rem; height: 1.5rem; color: var(--ink); flex: none; font-size: 1.1rem; }
.trade-links { list-style: none; margin: 0; padding: 0; }
.trade-links li + li { border-top: 1px solid #ebe7de; }
.trade-links a { display: flex; align-items: center; min-height: 46px; font-weight: 600; }
.intro-links { display: flex; flex-wrap: wrap; gap: 0.6rem; flex: none; }
/* breadcrumbs (template pages) */
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; column-gap: 0.15rem; font-size: 0.95rem; }
.crumbs li { display: inline-flex; align-items: center; max-width: none; }
.crumbs a { display: inline-flex; align-items: center; min-height: 44px; padding: 0 0.15rem; font-weight: 600; }
.crumbs [aria-current] { color: var(--muted); font-weight: 600; padding: 0 0.15rem; }
.crumb-sep { color: var(--muted); padding: 0 0.3rem; }
main.wrap > .crumbs { margin-top: -0.6rem; }
main.wrap > .crumbs + h1 { margin-top: 0.1em; }
.tpl-own { margin: 1.2rem 0 0; }

.disclaimer { color: var(--muted); font-size: 0.95rem; margin: 1.5rem 0 0; }
.home-make { min-height: 52px; }
.trade-h a { color: inherit; text-decoration: none; }
.trade-h a:hover { text-decoration: underline; }
.sec-sum { min-height: 48px; display: flex; align-items: center; cursor: pointer; font-weight: 700; padding: 0.2rem 0.3rem; }
details.sec-card { margin: 0 0 0.6rem; }
.kw h3 { font-size: 1.2rem; margin: 1rem 0 0.3rem; }
.kw ul { margin: 0 0 0.8rem; padding-left: 1.2rem; }
