:root {
  font-family: system-ui, sans-serif;
  line-height: 1.55;
  color: #102039;
  background: #f4f8fc;
  --border: #d5e4ee;
  --blue: #0e5f9f;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
.container { width: min(100% - 2rem, 60rem); margin-inline: auto; }
.site-header { background: #102039; color: white; }
.masthead { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem 1.1rem; padding-block: 1rem; }
.wordmark { color: #ffdb37; font-weight: 850; }
main { padding-block: clamp(1.5rem, 5vw, 3.5rem); }
.panel { background: white; border: 1px solid var(--border); border-radius: 1rem; padding: clamp(1rem, 4vw, 2rem); margin-block: 1rem; }
.signer { max-width: 55rem; }
h1, h2, h3 { margin: 0 0 .55rem; line-height: 1.15; overflow-wrap: anywhere; }
h1 { font-size: clamp(1.85rem, 5vw, 2.8rem); letter-spacing: -.035em; }
h2 { font-size: 1.35rem; }
p { margin: .55rem 0 1rem; overflow-wrap: anywhere; }
form { display: grid; gap: .9rem; }
label { display: grid; gap: .3rem; font-weight: 650; }
label.check { display: flex; align-items: flex-start; gap: .6rem; font-weight: 400; }
input { font: inherit; }
input:not([type="checkbox"], [type="radio"]) { width: 100%; min-width: 0; padding: .55rem; border: 1px solid #7892aa; border-radius: .4rem; }
input:is([type="checkbox"], [type="radio"]) { width: 1.1rem; height: 1.1rem; margin: .2rem 0 0; flex-shrink: 0; }
button { justify-self: start; min-height: 44px; padding: .55rem .95rem; border: 1px solid var(--blue); border-radius: .5rem; font: inherit; font-weight: 700; color: white; background: var(--blue); cursor: pointer; }
button.secondary { background: white; color: var(--blue); }
button:disabled { cursor: wait; opacity: .55; }
button:focus-visible, input:focus-visible { outline: 3px solid #997200; outline-offset: 3px; }
.actions { display: flex; flex-wrap: wrap; gap: .55rem; }
.status { display: inline-block; background: #e7f2fa; border-radius: .35rem; padding: .2rem .5rem; font-weight: 650; }
.message { margin: .65rem 0; }
.message:empty { display: none; }
.error { color: #a21d20; }
.item + .item { border-top: 1px solid var(--border); margin-top: 1.2rem; padding-top: 1.2rem; }
.subform { margin-top: .75rem; padding: 1rem; border: 1px solid var(--border); border-radius: .5rem; }
.more { margin-top: 1rem; }
.privacy { font-size: .9rem; }

[hidden] { display: none !important; }
.pdf-viewer { margin: .85rem 0; }
.pdf-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin: .5rem 0; }
.pdf-toolbar button { font-size: .9rem; padding-inline: .65rem; }
.pdf-toolbar button[aria-pressed="true"] { color: white; background: var(--blue); }
.pdf-toolbar [role="status"] { font-weight: 650; }
.field-type { font-size: .9rem; }
.field-type select { font: inherit; color: inherit; background: white; border: 1px solid #7892aa; border-radius: .4rem; padding: .45rem; }
.pdf-scroll { overflow: auto; max-height: 76vh; border: 1px solid #7892aa; background: #e8eef5; padding: 6px; }
.pdf-paper { position: relative; background: white; }
.pdf-paper.pdf-zoom { width: 150%; }
.pdf-paper > canvas { display: block; width: 100%; height: auto; }
.pdf-overlay { position: absolute; inset: 0; pointer-events: none; }
.pdf-overlay.placing { cursor: crosshair; pointer-events: auto; touch-action: none; }
.pdf-field, .pdf-draft { position: absolute; }
.pdf-field {
  display: flex;
  align-items: center;
  overflow: hidden;
  justify-content: flex-start;
  color: #102039;
  border: 1px dashed #0e5f9f;
  border-radius: 3px;
  background: #d0edffed;
  min-height: 0;
  padding: 0 3px;
  font: 700 clamp(.55rem, 2vw, .9rem)/1 system-ui, sans-serif;
  text-align: left;
  white-space: nowrap;
}
.pdf-field.staff { background: #ffeaa7ed; border-color: #8c6500; }
button.pdf-field { pointer-events: auto; border-style: solid; }
.pdf-field.text-field { padding: 0; pointer-events: auto; border-style: solid; }
.pdf-field.text-field input { height: 100%; padding: 0 3px; border: 0; background: transparent; color: inherit; font-weight: 500; }
.pdf-field.text-field:focus-within { outline: 2px solid #0e5f9f; outline-offset: 2px; }
.pdf-field.text-field input:focus-visible { outline: none; }
.pdf-field.filled { background: #fff9; color: #102039; }
.pdf-field.selected { outline: 2px solid #0e5f9f; outline-offset: 2px; }
.pdf-field svg { display: block; width: 100%; height: 100%; }
.pdf-draft { border: 1px solid var(--blue); background: #d0edffa0; pointer-events: none; }
.placement-help { font-size: .95rem; }
.sign-progress { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .9rem; margin-top: .85rem; }
.sign-progress p { margin: 0; font-weight: 650; }
.field-submit { margin-block: 1rem; }
.signature-dialog { width: min(34rem, 100% - 2rem); border: 1px solid var(--border); border-radius: .75rem; padding: 1.2rem; color: #102039; }
.signature-dialog::backdrop { background: #102039a6; }
.signature-modes { border: 1px solid var(--border); border-radius: .4rem; margin: 0; }
.signature-modes label + label { margin-top: .4rem; }
.typed-mark { font: italic 1.65rem/1.1 "Times New Roman", serif; }
.typed-preview { min-height: 3.5rem; border-bottom: 1px solid #7892aa; overflow-wrap: anywhere; padding: .5rem; }
.ink-pad { display: block; width: 100%; aspect-ratio: 3 / 1; border: 1px solid #7892aa; background: #f9fcff; cursor: crosshair; touch-action: none; }
.draw-pad button { margin-top: .45rem; }
