:root {
  --ink: #1e293b;
  --ink-soft: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
  --paper: #ffffff;
  --app-bg: #f8fafc;
  --panel: #ffffff;
  --panel-tint: #f1f5f9;
  --accent: #1f4e79;
  --accent-dark: #163a5c;
  --accent-soft: #dbeafe;
  --accent-hover: #2e75b6;
  --gold: #d4760a;
  --gold-soft: #fff7ed;
  --danger: #b91c1c;
  --danger-soft: #fef2f2;
  --shadow: 0 16px 42px rgba(15, 23, 42, 0.14);
  --shadow-soft: 0 8px 24px rgba(15, 23, 42, 0.08);
  --hero-gradient: linear-gradient(135deg, #1f4e79 0%, #2e75b6 100%);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--app-bg);
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0) 320px),
    var(--app-bg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

h1,
h2,
h3,
h4,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 3px;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.08;
}

h2 {
  margin-bottom: 6px;
  font-size: 20px;
  line-height: 1.15;
}

h3 {
  margin-bottom: 10px;
  font-size: 22px;
  line-height: 1.16;
}

h4 {
  margin: 0 0 8px;
  font-size: 16px;
  line-height: 1.25;
}

.app-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 90px;
  padding: 16px 32px;
  color: #ffffff;
  background: var(--hero-gradient);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18);
}

.brand-lockup {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
}

.brand-logo {
  display: block;
  height: 56px;
  width: auto;
  flex: 0 0 auto;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.25));
}

.brand-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.brand-text h1 {
  margin: 0;
  color: #ffffff;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.01em;
}

.brand-lockup .eyebrow {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.header-subtitle,
.pane-title p,
.document-toolbar p,
.section-copy,
.help-text {
  color: var(--muted);
}

.header-subtitle {
  margin-bottom: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.progress-wrap {
  min-width: 220px;
  padding: 10px 14px;
  color: rgba(255, 255, 255, 0.94);
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 10px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  backdrop-filter: blur(6px);
}

.progress-track {
  height: 6px;
  margin-top: 8px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.18);
  border-radius: 999px;
}

#progressBar {
  width: 0;
  height: 100%;
  background: linear-gradient(90deg, #ffffff, #cfe3ff);
  border-radius: 999px;
  transition: width 220ms ease;
}

.primary,
.secondary,
.mode-btn,
.icon-button {
  min-height: 42px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.01em;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease;
}

.icon-button {
  border-radius: 10px;
}

.primary {
  padding: 0 22px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-hover) 100%);
  box-shadow: 0 8px 20px rgba(31, 78, 121, 0.28);
}

.primary:hover {
  background: linear-gradient(135deg, var(--accent-dark) 0%, var(--accent) 100%);
  box-shadow: 0 10px 24px rgba(31, 78, 121, 0.34);
}

.primary:active {
  transform: translateY(1px);
}

.secondary {
  padding: 0 18px;
  color: var(--accent-dark);
  background: #ffffff;
  border: 1px solid var(--line-strong);
}

.secondary:hover {
  background: var(--panel-tint);
  border-color: var(--accent-hover);
  color: var(--accent-dark);
}

.app-header .secondary {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.3);
  backdrop-filter: blur(6px);
}

.app-header .secondary:hover {
  background: rgba(255, 255, 255, 0.24);
  border-color: rgba(255, 255, 255, 0.5);
  color: #ffffff;
}

.app-header .primary {
  color: var(--accent-dark);
  background: #ffffff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

.app-header .primary:hover {
  background: #e8ecf4;
}

.small {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}

.layout {
  display: grid;
  grid-template-columns: minmax(440px, 650px) minmax(430px, 1fr);
  min-height: calc(100vh - 78px);
}

.form-pane {
  overflow: auto;
  max-height: calc(100vh - 78px);
  padding: 28px 32px 26px;
  background: var(--panel);
  border-right: 1px solid var(--line);
}

.pane-title {
  max-width: 590px;
  margin-bottom: 14px;
}

.pane-title p,
.section-copy {
  max-width: 58ch;
  margin-bottom: 0;
  font-size: 14px;
  line-height: 1.55;
}

.step-lede {
  max-width: 58ch;
  margin: 0 0 18px;
  color: var(--ink-soft);
  font-size: 17px;
  line-height: 1.5;
}

.field-stack {
  display: grid;
  gap: 18px;
}

.wizard-shell {
  display: grid;
  gap: 18px;
  max-width: 590px;
}

.step-count {
  width: fit-content;
  padding: 6px 10px;
  color: var(--accent-dark);
  background: var(--accent-soft);
  border: 1px solid #c8dbcf;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 900;
}

.wizard-step {
  min-height: 0;
  padding-bottom: 10px;
}

.wizard-step > h3 {
  margin-top: 4px;
}

.wizard-actions {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  margin-top: 8px;
  padding: 18px 0 0;
  background: var(--panel);
  border-top: 1px solid var(--line);
}

.wizard-action-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  min-width: 0;
}

.wizard-actions button {
  min-width: 116px;
}

.wizard-actions button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.decision-stop,
.risk-panel {
  padding: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.decision-stop {
  border-color: rgba(168, 50, 50, 0.32);
  background: var(--danger-soft);
}

.risk-panel {
  border-color: rgba(212, 118, 10, 0.38);
  background: var(--gold-soft);
}

.phase-panel {
  display: grid;
  gap: 7px;
  margin-bottom: 18px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-left: 5px solid var(--accent);
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
  color: var(--ink-soft);
  line-height: 1.48;
}

.phase-panel span {
  color: var(--accent-dark);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.phase-panel p {
  margin-bottom: 0;
}

.staff-phase {
  border-left-color: var(--gold);
  background: var(--gold-soft);
}

.locked-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 18px;
}

.locked-summary div {
  min-width: 0;
  padding: 13px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.locked-summary span {
  display: block;
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.locked-summary strong {
  display: block;
  color: var(--ink-soft);
  font-size: 13px;
  line-height: 1.35;
  word-break: break-word;
}

.handoff-panel,
.deposit-preview,
.payment-stack {
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.handoff-panel {
  display: grid;
  gap: 10px;
  margin-bottom: 18px;
  color: var(--ink-soft);
  line-height: 1.5;
}

.handoff-panel p {
  margin-bottom: 0;
}

.deposit-preview,
.payment-stack {
  display: grid;
  gap: 5px;
}

.deposit-preview span,
.payment-stack span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.deposit-preview strong,
.payment-stack strong {
  color: var(--accent-dark);
  font-size: 24px;
  line-height: 1.1;
}

.deposit-preview small {
  color: var(--muted);
}

.payment-stack {
  border-color: rgba(212, 118, 10, 0.36);
  background: var(--gold-soft);
}

.payment-stack.ready {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.payment-stack.omitted {
  border-color: var(--line);
  background: var(--panel-tint);
}

.payment-stack p {
  margin-bottom: 8px;
  color: var(--ink-soft);
  line-height: 1.45;
}

.deposit-controls {
  display: grid;
  gap: 12px;
}

.handoff-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 16px;
}

.action-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 8px;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}

.link-panel {
  display: grid;
  gap: 8px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.link-panel span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.link-panel strong {
  color: var(--accent-dark);
}

.link-panel p {
  margin-bottom: 0;
  color: var(--ink-soft);
  line-height: 1.45;
}

.link-panel code {
  display: block;
  max-height: 104px;
  overflow: auto;
  padding: 10px;
  color: var(--ink-soft);
  background: var(--panel-tint);
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.35;
  word-break: break-all;
  white-space: normal;
}

.copy-status {
  min-height: 18px;
  color: var(--accent-dark) !important;
  font-weight: 800;
}

.charge-lines {
  display: grid;
  gap: 10px;
}

.total-charge {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.charge-detail {
  display: grid;
  gap: 14px;
}

.conditional-fields[hidden] {
  display: none;
}

.risk-panel p:last-of-type,
.decision-stop p:last-of-type {
  margin-bottom: 0;
}

.field-control {
  display: grid;
  gap: 8px;
}

.field-label {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: var(--ink);
  font-weight: 850;
  line-height: 1.32;
}

.field-label > span:first-child,
.field-label label {
  min-width: 0;
}

.field-label label {
  cursor: pointer;
}

.info-tip {
  position: relative;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  margin-top: 1px;
  color: var(--accent-dark);
  outline: 0;
}

.info-icon {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  color: var(--accent-dark);
  background: var(--accent-soft);
  border: 1px solid #bfdbfe;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
}

.info-bubble {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 40;
  width: 300px;
  max-width: calc(100vw - 48px);
  padding: 11px 12px;
  visibility: hidden;
  color: #fff;
  background: #1f2937;
  border-radius: 8px;
  box-shadow: var(--shadow);
  font-size: 13px;
  font-weight: 650;
  line-height: 1.42;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 120ms ease, transform 120ms ease, visibility 120ms ease;
}

.info-tip:hover .info-bubble,
.info-tip:focus .info-bubble,
.info-tip:focus-within .info-bubble {
  visibility: visible;
  opacity: 1;
  transform: translateY(0);
}

.check-row label {
  cursor: pointer;
}

.check-row .info-tip {
  margin-left: auto;
}

.required-mark {
  color: var(--danger);
}

.field-control select,
.field-control input,
.field-control textarea {
  width: 100%;
  min-height: 52px;
  padding: 13px 14px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.8) inset;
}

.field-control select {
  appearance: none;
  padding-right: 42px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--accent-dark) 50%),
    linear-gradient(135deg, var(--accent-dark) 50%, transparent 50%);
  background-position:
    calc(100% - 21px) 23px,
    calc(100% - 15px) 23px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.field-control textarea {
  min-height: 126px;
  resize: vertical;
  line-height: 1.45;
}

.field-control .phone-entry {
  min-height: 52px;
  height: 52px;
  overflow: hidden;
  resize: none;
  white-space: nowrap;
}

.field-control select:hover,
.field-control input:hover,
.field-control textarea:hover {
  border-color: #87998e;
}

.field-control select:focus,
.field-control input:focus,
.field-control textarea:focus,
.check-row input:focus,
.mode-btn:focus,
button:focus,
summary:focus {
  outline: 3px solid rgba(46, 117, 182, 0.4);
  outline-offset: 2px;
}

.field-control.invalid select,
.field-control.invalid input,
.field-control.invalid textarea,
.check-row.invalid {
  border-color: var(--danger);
  background: #fffafa;
}

.error-text {
  display: none;
  color: var(--danger);
  font-size: 13px;
  font-weight: 800;
}

.field-control.invalid .error-text {
  display: block;
}

.conditional-note {
  margin: 0;
  color: #9a3412;
  font-size: 13px;
  line-height: 1.4;
}

.section-copy,
.policy-heading p,
.policy-terms {
  line-height: 1.56;
}

.policy-list {
  display: grid;
  gap: 14px;
  margin-top: 18px;
}

.policy-card {
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
}

.policy-card:nth-child(2n) {
  background: #fcfbf8;
}

.policy-heading h4 {
  color: var(--accent-dark);
}

.policy-heading p {
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 14px;
}

.policy-terms {
  display: grid;
  gap: 9px;
  color: var(--ink-soft);
  font-size: 14px;
}

.policy-terms p {
  margin-bottom: 0;
}

.check-row {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin-top: 18px;
  padding: 14px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink-soft);
  font-weight: 800;
  line-height: 1.42;
}

.check-row input {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  margin-top: 2px;
  accent-color: var(--accent);
}

.signature-grid {
  display: grid;
  grid-template-columns: 1fr 160px;
  gap: 14px;
}

.signature-mode {
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  margin: 18px 0;
  padding: 4px;
  background: var(--panel-tint);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.signature-mode .mode-btn {
  border-radius: 999px;
}

.mode-btn {
  min-width: 92px;
  padding: 0 12px;
  color: var(--ink-soft);
  background: transparent;
}

.mode-btn.active {
  color: #fff;
  background: var(--accent);
}

.signature-pad-wrap {
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
}

#signaturePad {
  display: block;
  width: 100%;
  height: 180px;
  touch-action: none;
}

.validation-summary {
  max-width: 270px;
  color: var(--danger);
  font-size: 13px;
  font-weight: 850;
  text-align: right;
}

.document-pane {
  min-width: 0;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.06), rgba(15, 23, 42, 0)),
    #e2e8f0;
}

.document-toolbar {
  position: sticky;
  top: 90px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 28px;
  background: rgba(241, 245, 249, 0.96);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

.document-toolbar h2 {
  margin-bottom: 0;
}

.document-scroll {
  display: grid;
  gap: 24px;
  justify-items: center;
  padding: 30px;
}

.page {
  position: relative;
  width: min(100%, 780px);
  aspect-ratio: 612 / 792;
  overflow: hidden;
  background: var(--paper);
  border-radius: 4px;
  box-shadow: var(--shadow);
}

.page img {
  display: block;
  width: 100%;
  height: 100%;
}

.preview-field {
  position: absolute;
  display: flex;
  align-items: center;
  min-height: 14px;
  padding: 1px 5px;
  overflow: hidden;
  color: #0f172a;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(31, 78, 121, 0.78);
  border-radius: 2px;
  font-size: 10px;
  line-height: 1.1;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.preview-field.hidden {
  display: none;
}

.preview-field.empty {
  color: #64748b;
}

.preview-field.signature-value {
  font-family: "Brush Script MT", "Segoe Script", cursive;
  font-size: 16px;
}

dialog {
  width: min(820px, calc(100vw - 32px));
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 8px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

dialog::backdrop {
  background: rgba(18, 25, 22, 0.52);
}

dialog form {
  margin: 0;
  background: var(--paper);
}

.dialog-header,
.dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 22px;
  border-bottom: 1px solid var(--line);
}

.dialog-actions {
  border-top: 1px solid var(--line);
  border-bottom: 0;
}

.dialog-header h2 {
  margin: 0;
}

.icon-button {
  width: 40px;
  color: var(--ink-soft);
  background: var(--panel-tint);
}

#reviewContent {
  max-height: min(70vh, 660px);
  overflow: auto;
  padding: 22px;
}

.review-list {
  display: grid;
  gap: 12px;
}

.review-item {
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}

.review-item strong {
  display: block;
  margin-bottom: 5px;
  color: var(--ink);
  line-height: 1.35;
}

.review-item span {
  color: var(--muted);
  line-height: 1.45;
}

@media (max-width: 1080px) {
  .layout {
    grid-template-columns: minmax(420px, 600px) minmax(360px, 1fr);
  }

  .form-pane,
  .document-scroll {
    padding: 26px;
  }
}

@media (max-width: 900px) {
  .app-header,
  .document-toolbar {
    position: static;
  }

  .app-header,
  .header-actions,
  .document-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .header-actions {
    width: 100%;
  }

  .progress-wrap {
    min-width: 0;
  }

  .layout {
    grid-template-columns: 1fr;
  }

  .form-pane {
    max-height: none;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .wizard-shell,
  .pane-title {
    max-width: none;
  }

  .signature-grid {
    grid-template-columns: 1fr;
  }

  .locked-summary {
    grid-template-columns: 1fr;
  }

  .wizard-actions,
  .wizard-action-right {
    align-items: stretch;
    flex-direction: column;
  }

  .wizard-actions button,
  .wizard-action-right,
  .validation-summary {
    width: 100%;
  }

  .validation-summary {
    max-width: none;
    text-align: left;
  }
}

@media (max-width: 760px) {
  body {
    background: var(--panel);
  }

  .app-header {
    position: sticky;
    top: 0;
    gap: 10px;
    min-height: 0;
    padding: 10px 14px;
  }

  .brand-lockup {
    gap: 12px;
    min-width: 0;
  }

  .brand-logo {
    height: 42px;
  }

  .brand-text h1 {
    font-size: 19px;
  }

  .brand-lockup .eyebrow {
    display: none;
  }

  h1 {
    font-size: 21px;
  }

  .eyebrow {
    margin-bottom: 3px;
    font-size: 11px;
  }

  .header-subtitle,
  .pane-title p {
    display: none;
  }

  .header-actions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 6px;
  }

  .progress-wrap {
    grid-column: 1 / -1;
    order: -1;
    padding: 7px 10px;
    font-size: 11.5px;
  }

  .header-actions button {
    min-height: 38px;
    padding: 0 10px;
    font-size: 13px;
  }

  .layout {
    display: block;
    min-height: auto;
  }

  .form-pane {
    padding: 16px 14px 0;
    background: var(--panel);
    border-bottom: 0;
  }

  .pane-title {
    margin-bottom: 10px;
  }

  .wizard-shell {
    gap: 14px;
  }

  .step-count {
    font-size: 12px;
  }

  .step-lede {
    margin-bottom: 14px;
    font-size: 15px;
  }

  .field-stack {
    gap: 15px;
  }

  .field-label {
    align-items: flex-start;
    gap: 7px;
    line-height: 1.25;
  }

  .field-control select,
  .field-control input,
  .field-control textarea {
    min-height: 56px;
    padding: 14px 13px;
    font-size: 16px;
  }

  .field-control textarea {
    min-height: 118px;
  }

  .field-control .phone-entry {
    min-height: 56px;
    height: 56px;
  }

  .check-row {
    gap: 10px;
    margin-top: 12px;
    padding: 12px;
    font-size: 14px;
  }

  .check-row input {
    width: 22px;
    height: 22px;
  }

  .phase-panel,
  .locked-summary div,
  .deposit-preview,
  .payment-stack,
  .decision-stop,
  .risk-panel {
    padding: 13px;
  }

  .locked-summary {
    gap: 8px;
  }

  .deposit-preview strong,
  .payment-stack strong {
    font-size: 21px;
  }

  .signature-mode {
    width: 100%;
  }

  .signature-mode .mode-btn {
    min-height: 44px;
  }

  .info-bubble {
    position: fixed;
    right: 14px;
    bottom: 86px;
    left: 14px;
    top: auto;
    width: auto;
    max-width: none;
  }

  .wizard-actions {
    position: sticky;
    bottom: 0;
    z-index: 15;
    margin: 8px -14px 0;
    padding: 10px 14px 12px;
    background: rgba(255, 255, 255, 0.98);
    border-top: 1px solid var(--line);
    box-shadow: 0 -8px 22px rgba(15, 23, 42, 0.08);
  }

  .wizard-actions button {
    min-height: 50px;
  }

  .handoff-actions {
    grid-template-columns: 1fr;
  }

  .action-link,
  .handoff-actions button {
    min-height: 50px;
  }

  .document-pane {
    display: none;
  }
}

@media print {
  .app-header,
  .form-pane,
  .document-toolbar,
  dialog {
    display: none;
  }

  .layout {
    display: block;
  }

  .document-scroll {
    padding: 0;
    background: #fff;
  }

  .page {
    width: 100%;
    border-radius: 0;
    box-shadow: none;
    page-break-after: always;
  }
}
