/* Contract document + signature pad (used by the client portal and the admin area) */
.contract-doc { background: #fff; border: 1px solid #DEE2EE; border-radius: 14px; padding: clamp(22px, 5vw, 56px); max-width: 860px; margin: 0 auto; color: #141B3A; font-family: Georgia, 'Times New Roman', serif; font-size: 1.02rem; line-height: 1.65; }
.contract-letterhead { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; border-bottom: 3px solid #2350D8; padding-bottom: 18px; margin-bottom: 26px; font-family: system-ui, -apple-system, 'Segoe UI', sans-serif; font-size: .9rem; color: #4A5170; }
.contract-letterhead strong { display: block; font-size: 1.25rem; color: #141B3A; }
.contract-title { font-family: system-ui, -apple-system, 'Segoe UI', sans-serif; font-size: clamp(1.4rem, 3vw, 1.9rem); margin: 0 0 6px; line-height: 1.2; }
.contract-ref { font-family: system-ui, sans-serif; color: #4A5170; margin: 0 0 26px; font-size: .95rem; }
.contract-body h2 { font-family: system-ui, -apple-system, 'Segoe UI', sans-serif; font-size: 1.08rem; margin: 26px 0 8px; }
.contract-body h3 { font-family: system-ui, sans-serif; font-size: 1rem; margin: 18px 0 6px; }
.contract-body p { margin: 0 0 12px; }
.contract-body ul { margin: 0 0 12px 22px; padding: 0; }
.schedule { width: 100%; border-collapse: collapse; margin: 10px 0 24px; font-family: system-ui, sans-serif; font-size: .95rem; }
.schedule th, .schedule td { border: 1px solid #DEE2EE; padding: 9px 12px; text-align: left; vertical-align: top; }
.schedule th { width: 38%; background: #F5F6FB; font-weight: 600; }
.sign-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 28px; margin-top: 32px; font-family: system-ui, sans-serif; font-size: .95rem; }
.sign-block { border-top: 1px solid #DEE2EE; padding-top: 14px; display: grid; gap: 4px; }
.sign-block .sig-img { height: 80px; max-width: 100%; object-fit: contain; object-position: left; border-bottom: 1.5px solid #141B3A; margin: 6px 0; }
.sign-block .sig-empty { height: 80px; border-bottom: 1.5px dashed #A3A9C4; margin: 6px 0; display: flex; align-items: flex-end; color: #8D93B3; font-style: italic; padding-bottom: 6px; }
.sign-label { font-weight: 700; text-transform: none; color: #2350D8; }
.audit { margin-top: 32px; padding-top: 14px; border-top: 1px solid #DEE2EE; font-family: ui-monospace, 'Courier New', monospace; font-size: .78rem; color: #5B6280; word-break: break-all; }
.audit p { margin: 2px 0; }

/* Signature pad */
.sigpad { display: grid; gap: 8px; }
.sigpad-canvas { width: 100%; height: 180px; background: #fff; border: 2px dashed #A3A9C4; border-radius: 10px; touch-action: none; cursor: crosshair; display: block; }
.sigpad.has-ink .sigpad-canvas { border-style: solid; border-color: #2350D8; }
.sigpad-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; font-size: .9rem; color: #5B6280; }
.sigpad-clear { background: none; border: 1.5px solid #141B3A; border-radius: 8px; padding: 6px 14px; min-height: 40px; font: 600 .9rem system-ui, sans-serif; cursor: pointer; }

.no-print { }
@media print {
  @page { margin: 16mm; }
  body { background: #fff !important; }
  .no-print, .portal-header, .a-header, .portal-footer, .a-alert, .alert { display: none !important; }
  .contract-doc { border: 0; padding: 0; max-width: none; }
  .portal-main, .a-main { margin: 0 !important; width: auto !important; }
}
.contract-logo { height: 54px; width: auto; margin-bottom: 8px; }
