/* ---------- will builder ---------- */
.will-hero { padding-block: clamp(36px, 5vw, 64px) clamp(20px, 3vw, 32px); }
.will-hero h1 { font-size: clamp(38px, 5.4vw, 64px); line-height: 1.04; letter-spacing: -0.02em; margin-block: 14px 14px; }
.will-work { padding-bottom: clamp(56px, 8vw, 104px); }
.pane-tabs { display: none; gap: 4px; padding: 4px; background: var(--sand); border-radius: var(--r-pill); margin-bottom: 20px; width: fit-content; }
.pane-tabs button { appearance: none; border: 0; background: none; font: 600 15px/1 var(--sans); color: var(--ink-soft); padding: 12px 20px; border-radius: var(--r-pill); cursor: pointer; }
.pane-tabs button[aria-pressed="true"] { background: var(--grape); color: #fff; }
.will-layout { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: clamp(24px, 4vw, 56px); align-items: start; }
.wizard { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-xl); padding: clamp(22px, 3vw, 36px); display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; }
.progress { display: grid; gap: 8px; }
.p-top { display: flex; justify-content: space-between; font: 500 13px/1 var(--sans); color: var(--ink-mute); }
.pbar { height: 6px; border-radius: var(--r-pill); background: var(--sand); overflow: hidden; }
.pbar i { display: block; height: 100%; background: var(--leaf); border-radius: var(--r-pill); transition: width 0.3s; }

/* package flow: Essentials/Complete answer every document in the plan back to back (js/flow.js) */
.pkg-track { margin-bottom: 14px; }
.pkg-label { display: block; font: 700 11.5px/1.2 var(--sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--grape-deep); margin-bottom: 8px; }
.pkg-steps { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pkg-step { font: 600 12.5px/1.25 var(--sans); padding: 7px 12px; max-width: 100%; min-width: 0; overflow-wrap: anywhere; border-radius: var(--r-pill); background: var(--sand); color: var(--ink-mute); white-space: normal; text-decoration: none; display: inline-block; }
.pkg-step:hover { background: var(--grape-tint); color: var(--grape-deep); }
.pkg-step.pkg-done { background: var(--leaf-tint); color: var(--leaf-deep); }
.pkg-step.pkg-current { background: var(--grape); color: #fff; }
.pkg-sep { color: var(--ink-mute); font-size: 12px; }
.pkg-continue { flex-direction: column; align-items: flex-start; gap: 12px; }
.pkg-continue-note { font-size: 15px; color: var(--ink-soft); margin: 0; }
.pkg-complete { background: var(--leaf-tint); border: 1px solid var(--leaf); border-radius: var(--r-lg); padding: 20px; margin-bottom: 16px; display: grid; gap: 12px; }
.pkg-complete h3 { font: 700 19px/1.25 var(--serif); color: var(--leaf-deep); margin: 0; }
.pkg-complete > p { font-size: 14.5px; color: var(--ink-soft); max-width: 54ch; margin: 0; }
.pkg-done-list { display: grid; gap: 2px; }
.pkg-done-row { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--line); }
.pkg-done-row:last-child { border-bottom: 0; }
.pkg-check { width: 22px; height: 22px; border-radius: 50%; background: var(--leaf); color: #fff; font-size: 12.5px; line-height: 22px; text-align: center; flex: none; }
.pkg-doc-name { flex: 1; font: 600 14.5px/1.3 var(--sans); color: var(--ink); }
.pkg-here { font-size: 12.5px; color: var(--grape-deep); font-weight: 600; white-space: nowrap; }

#will-step { display: grid; gap: 18px; align-content: start; }
.q-title { font-size: clamp(26px, 2.8vw, 34px); line-height: 1.15; }
.q-sub { color: var(--ink-soft); margin-top: -6px; max-width: 46ch; }
.f { display: grid; gap: 6px; }
.f > label { font: 600 14.5px/1.3 var(--sans); }
.f > label em { font-weight: 400; color: var(--ink-mute); font-style: normal; }
.hint { font-size: 13.5px; color: var(--ink-mute); line-height: 1.45; }
.input { width: 100%; min-height: 48px; padding: 0 14px; font: 400 16px/1 var(--sans); color: var(--ink); background: var(--white); border: 1.5px solid var(--field-line); border-radius: var(--r-md); }
select.input { padding-right: 8px; }
textarea.input { min-height: 92px; padding: 12px 14px; line-height: 1.5; font-family: inherit; resize: vertical; }
.input:focus { outline: 3px solid var(--grape); outline-offset: 1px; border-color: var(--grape); }
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.pills { display: flex; flex-wrap: wrap; gap: 8px; }
.pills.col { flex-direction: column; align-items: flex-start; }
.pill input { position: absolute; opacity: 0; pointer-events: none; }
.pill span { display: inline-flex; align-items: center; padding: 12px 18px; border: 1.5px solid var(--field-line); border-radius: var(--r-pill); font: 600 15px/1.2 var(--sans); background: var(--white); cursor: pointer; text-align: left; }
.pill span:hover { background: var(--grape-tint); }
.pill input:checked + span { background: var(--grape); border-color: var(--grape); color: #fff; }
.pill input:focus-visible + span { outline: 3px solid var(--grape); outline-offset: 2px; }
.checks { display: grid; gap: 12px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; line-height: 1.45; cursor: pointer; }
.check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--grape); flex: none; }
.check.sm { font-size: 14px; white-space: nowrap; align-items: center; }
.rowset { display: grid; gap: 10px; }
.rowitem { display: flex; gap: 10px; align-items: center; }
.rowitem .input { flex: 1 1 auto; min-width: 0; }
.rowitem.stack { display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 8px; }
.rowitem.stack .input { grid-column: 1; }
.rowitem.stack .rm { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.rowitem.grid4 { display: grid; grid-template-columns: 1fr 1fr 40px; grid-template-rows: auto auto; gap: 8px; padding: 10px; border: 1.5px solid var(--field-line); border-radius: var(--r-md); }
.rowitem.grid4 .input:nth-child(1) { grid-column: 1; grid-row: 1; }
.rowitem.grid4 .input:nth-child(2) { grid-column: 2; grid-row: 1; }
.rowitem.grid4 .input:nth-child(3) { grid-column: 1; grid-row: 2; }
.rowitem.grid4 .input:nth-child(4) { grid-column: 2; grid-row: 2; }
.rowitem.grid4 .rm { grid-column: 3; grid-row: 1 / span 2; align-self: center; }
.pct { display: flex; align-items: center; gap: 6px; width: 104px; flex: none; }
.pct b { font-weight: 600; color: var(--ink-soft); }
.rm { width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--field-line); background: var(--white); font-size: 22px; line-height: 1; cursor: pointer; color: var(--ink-soft); flex: none; }
.rm:hover { background: var(--grape-tint); }
.errs { background: #fbe4e4; color: #9c2f2f; border-radius: var(--r-md); padding: 14px 16px; font-size: 15px; }
.errs ul { margin: 6px 0 0 18px; padding: 0; }
.errs p { margin-top: 4px; }
.restored { background: var(--leaf-tint); color: var(--leaf-deep); border-radius: var(--r-md); padding: 10px 14px; font-size: 14px; }
.nav-row { display: flex; justify-content: space-between; gap: 12px; margin-top: 6px; padding-top: 18px; border-top: 1px solid var(--line); }
.sum { display: grid; }
.sum-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.sum-l { display: block; font: 700 11.5px/1.2 var(--sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-mute); margin-bottom: 3px; }
.sum-v { display: block; font-size: 15.5px; line-height: 1.4; }
.link { appearance: none; background: none; border: 0; color: var(--grape); text-decoration: underline; text-underline-offset: 3px; font: 600 14px/1.2 var(--sans); cursor: pointer; padding: 0; white-space: nowrap; }
.unlock-banner { background: var(--grape-tint); border: 1px solid var(--lavender); border-radius: var(--r-lg); padding: 18px 20px; margin-bottom: 16px; display: grid; gap: 12px; justify-items: start; }
.unlock-banner p { font-size: 15px; line-height: 1.5; color: var(--grape-deep); max-width: 52ch; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 4px; }
.see-doc { display: none; }
.draft-inline { font-size: 14px; color: var(--overline); font-weight: 600; }
.instr { padding: 20px 22px; background: var(--sand); border-radius: var(--r-lg); }
.instr h2 { font: 600 12.5px/1.3 var(--sans); letter-spacing: 0.1em; text-transform: uppercase; color: var(--grape-deep); margin-bottom: 10px; }
.instr p { margin-bottom: 10px; font-size: 15.5px; }
.instr ul { margin: 0 0 12px; padding-left: 20px; display: grid; gap: 8px; font-size: 15.5px; }
.reset { margin: 0; }

.preview { position: sticky; top: calc(var(--header-h) + 16px); }
.preview-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.preview-head h2 { font-size: 22px; letter-spacing: -0.005em; }
.doc { position: relative; max-height: calc(100vh - var(--header-h) - 110px); overflow: auto; border: 1px solid var(--line); box-shadow: var(--shadow-card); padding: clamp(24px, 3.4vw, 44px); font-size: 16px; }
/* the sample watermark is the document's own scrolling background, so it repeats down the whole document (an overlay only covered the first screenful) */
.doc.draft { background-image: var(--wm); background-repeat: repeat; background-attachment: local; }
.doc { font-family: var(--serif); }
.doc p { font-size: 16px; line-height: 1.7; margin: 0 0 11px; text-align: justify; hyphens: none; }
.doc p.c { text-align: center; text-transform: uppercase; margin: 0; padding: 0; font: 700 16pt/1.25 var(--serif); letter-spacing: 0.06em; color: #252429; hyphens: none; }
.doc p.c:not(:has(+ p.c)) { padding-bottom: 14px; border-bottom: 3px double #252429; margin-bottom: 24pt; }
.doc .art-h { text-align: center; margin: 42px 0 18px; break-after: avoid; }
.doc .art-n { display: block; font: 600 11.5px/1 var(--sans); letter-spacing: 0.26em; color: var(--grape-deep); }
.doc .art-t { display: block; font: 700 17px/1.3 var(--serif); letter-spacing: 0.09em; margin-top: 9px; }
.doc .art-h::after { content: ""; display: block; width: 44px; height: 2px; background: var(--leaf); margin: 13px auto 0; }
.doc .art-h.plain { margin-top: 34px; }
.doc .sec-h { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 0 12px; align-items: baseline; margin: 24px 0 8px; break-after: avoid; }
.doc .sec-n { font: 600 12px/1.4 var(--sans); letter-spacing: 0.06em; color: var(--grape-deep); white-space: nowrap; }
.doc .sec-t { font: 700 16px/1.35 var(--serif); }
.doc .row2 { display: flex; align-items: baseline; gap: 8px; margin: 7px 0 7px 22px; font-size: 16px; break-inside: avoid; }
.doc .row2 .dots { flex: 1; border-bottom: 1.5px dotted #9b96a3; transform: translateY(-4px); min-width: 24px; }
.doc .row2 .r { font-weight: 700; }
.doc .hang { padding-left: 2.4em; text-indent: -1.7em; text-align: left; }
.doc .subh { font: 700 12.5px/1.3 var(--sans); letter-spacing: 0.14em; text-transform: uppercase; margin: 28px 0 10px; color: #252429; break-after: avoid; }
.doc ul { margin: 0 0 12px; padding-left: 24px; }
.doc .sig { margin-top: 36px; max-width: 380px; break-inside: avoid; }
.doc .sigline { display: block; border-bottom: 1px solid #252429; height: 26px; }
.doc .siglabel { display: block; font: 400 12.5px/1.4 var(--sans); color: #6b6570; margin-top: 4px; }
.doc .pagebreak { height: 2px; background: repeating-linear-gradient(90deg, rgba(37,36,41,.25) 0 6px, transparent 6px 12px); margin: 30px 0; }
.fill { background: rgba(181, 217, 122, 0.38); border-radius: 3px; padding: 0 1px; }
.blank { color: var(--grape); background: var(--grape-tint); border-radius: 3px; padding: 0 3px; }
.wm-print { display: none; }

@media (max-width: 960px) {
  .pane-tabs { display: flex; }
  .will-layout { grid-template-columns: minmax(0, 1fr); }
  .will-layout[data-pane="q"] .preview { display: none; }
  .will-layout[data-pane="p"] .wizard { display: none; }
  .preview { position: static; }
  .doc { max-height: none; }
  .see-doc { display: inline-flex; }
}
@media (max-width: 560px) {
  .doc .sec-h { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .two { grid-template-columns: minmax(0, 1fr); }
  .rowitem { flex-wrap: wrap; }
  .nav-row .btn { flex: 1; }
  .pkg-steps { flex-direction: column; align-items: stretch; }
  .pkg-step { text-align: center; }
  .pkg-sep { display: none; }
}

@media print {
  @page { margin: 1in; }
  .site-header, .site-footer, .draft-note, .will-hero, .pane-tabs, .wizard, .preview-head, .skip { display: none !important; }
  body { background: #fff; }
  .will-work { padding: 0; }
  .container { max-width: none; padding: 0; }
  .will-layout { display: block; }
  .will-layout .preview { display: block !important; position: static; }
  .doc { max-height: none; overflow: visible; box-shadow: none; border: 0; padding: 0; background: #fff; }
  .doc.draft { background-image: none; }
  .doc.draft::before { display: none; }
  .doc { font-family: "Times New Roman", Times, serif; }
  .doc p { font-size: 12pt; line-height: 1.4; margin: 0 0 8pt; }
  .doc p.c { font-size: 16pt; }
  .doc .art-t { font-size: 13pt; }
  .doc .art-n { font-size: 9pt; }
  .doc .sec-t { font-size: 12pt; }
  .doc .sec-n { font-size: 9pt; }
  .doc .row2 { font-size: 12pt; }
  .doc .art-h::after { background: #999; }
  .wm-print { display: grid; position: fixed; inset: 0; place-items: center; transform: rotate(-30deg); font: 700 54px/1 Arial, sans-serif; color: rgba(0, 0, 0, 0.09); pointer-events: none; z-index: 9; text-align: center; }
  .fill, .blank { background: none; color: inherit; padding: 0; }
  .doc .pagebreak { height: 0; background: none; margin: 0; break-after: page; }
  .doc .art-h { break-after: avoid; }
  .doc .sig { break-inside: avoid; }
}

@page { margin: 1in; }
/* residuary rows in the questions */
.bens { display: grid; gap: 12px; }
.ben { border: 1px solid var(--line); background: var(--stone); border-radius: var(--r-md); padding: 12px; display: grid; gap: 10px; }
.cont { display: grid; gap: 6px; }
.cont-l { font: 600 12.5px/1.3 var(--sans); color: var(--ink-mute); }

.kind-switch { margin-top: 10px; font-size: 15px; color: var(--ink-soft); }
.kind-switch a { color: var(--grape); font-weight: 600; }

.export-status { min-height: 1.4em; }
.export-status.bad { color: #9c2f2f; font-weight: 600; }

.doc p.ln { margin: 0 0 2px; text-align: left; }

.doc p.item { padding-left: 2.4em; padding-right: 2.4em; }
.checks.big { display: grid; gap: 14px; }
.check.big { padding: 14px 16px; border: 1.5px solid var(--field-line); border-radius: var(--r-md); background: var(--white); }
.check.big:has(input:checked) { border-color: var(--grape); background: var(--grape-tint); }
.check.big strong { display: block; font-weight: 600; }
.check.big span span { display: block; font-size: 14px; color: var(--ink-soft); line-height: 1.5; margin-top: 2px; }
.check.big input { margin-top: 3px; }

/* "mirror image" box on the second person's copy of a document */
.mirror-box { background: var(--stone); border: 1px solid var(--line); border-radius: var(--r-md); padding: 14px 16px; margin-bottom: 18px; font-size: 15px; }
.mirror-check { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.mirror-check input { margin-top: 4px; width: 18px; height: 18px; flex: none; }
.mirror-panel { margin-top: 12px; display: grid; gap: 8px; }
.mirror-panel[hidden] { display: none; }
.mirror-name { font-weight: 600; }
.mirror-done { border-color: #6b9a4b; }

/* long button labels (a person's name in "Continue to your ... — Lisa L. Merrill") wrap instead of pushing the questions box wider than its column */
.wizard .btn { max-width: 100%; white-space: normal; text-align: center; }
.wizard .actions .btn, .pkg-continue .btn { white-space: normal; }
/* property lists (trust, joint trust, Schedule A): one labeled box per line, grouped per item */
.rowitem.fields { display: grid; grid-template-columns: minmax(0, 1fr) 40px; gap: 10px; padding: 12px; border: 1.5px solid var(--field-line); border-radius: var(--r-md); }
.rowitem.fields .af { grid-column: 1; display: grid; gap: 4px; font: 500 13.5px/1.3 var(--sans); color: var(--ink-soft); }
.rowitem.fields .rm { grid-column: 2; grid-row: 1 / span 4; align-self: center; }
