/* ============================================================
   SIGLONET — Shared document styling
   Brand navy: #37517E
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@500;600;700;800&family=IBM+Plex+Sans:ital,wght@0,400;0,500;0,600;1,400&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  --navy:        #37517E;
  --navy-700:    #2C4267;
  --navy-800:    #233351;
  --navy-tint:   #EEF1F8;
  --navy-tint-2: #F5F7FB;
  --line:        #D8DEEA;
  --line-soft:   #E7EBF2;
  --ink:         #1E2733;
  --muted:       #5E6B7E;
  --faint:       #97A1B1;
  --paper:       #FFFFFF;
  --desk:        #E7E9EF;
  --amber:       #B4791F;
  --amber-tint:  #FBF3E3;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--desk);
  color: var(--ink);
  font-family: 'IBM Plex Sans', system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* ---------- Paper sheet ---------- */
.sheet {
  max-width: 816px;
  margin: 40px auto;
  background: var(--paper);
  box-shadow: 0 1px 3px rgba(35,51,81,.10), 0 12px 36px rgba(35,51,81,.10);
  border-radius: 3px;
  overflow: hidden;
}

.body {
  padding: 52px 64px 40px;
}

/* ---------- Header band ---------- */
.masthead {
  background: var(--navy);
  color: #fff;
  padding: 26px 64px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.masthead__logo { height: 30px; width: auto; display: block; }
.masthead__meta {
  text-align: right;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .08em;
  line-height: 1.7;
  color: rgba(255,255,255,.82);
  text-transform: uppercase;
}
.masthead__meta strong { color: #fff; font-weight: 600; }

/* Title bar under masthead */
.titlebar {
  border-bottom: 2px solid var(--navy);
  padding: 38px 64px 26px;
}
.titlebar__kicker {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--navy);
  font-weight: 500;
  margin: 0 0 10px;
}
.titlebar h1 {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 30px;
  letter-spacing: -.01em;
  line-height: 1.08;
  margin: 0 0 10px;
  color: var(--ink);
}
.titlebar p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  max-width: 60ch;
}

/* ---------- Section headings ---------- */
.section { margin: 0 0 30px; break-inside: avoid; }
.section__head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.section__num {
  flex: none;
  width: 26px; height: 26px;
  border-radius: 5px;
  background: var(--navy);
  color: #fff;
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  print-color-adjust: exact; -webkit-print-color-adjust: exact;
}
.section__title {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 16.5px;
  letter-spacing: -.005em;
  color: var(--navy-800);
  margin: 0;
}
.section__intro {
  color: var(--muted);
  font-size: 13px;
  margin: -4px 0 16px;
  max-width: 64ch;
}

/* ---------- Field grid (label + fill area) ---------- */
.grid { display: grid; gap: 12px 18px; }
.grid--2 { grid-template-columns: 1fr 1fr; }
.grid--3 { grid-template-columns: 1fr 1fr 1fr; }

.field { display: flex; flex-direction: column; gap: 5px; break-inside: avoid; }
.field--full { grid-column: 1 / -1; }
.field__label {
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--navy-700);
}
.field__input {
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--navy-tint-2);
  min-height: 38px;
  padding: 9px 12px;
  color: var(--faint);
  font-size: 13px;
  font-style: italic;
  display: flex;
  align-items: center;
}
.field__input--area { min-height: 84px; align-items: flex-start; }
.field__input--lg { min-height: 110px; align-items: flex-start; }

/* ---------- Tables ---------- */
table.doc {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  margin: 0;
}
table.doc thead th {
  background: var(--navy);
  color: #fff;
  font-family: 'Archivo', sans-serif;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: .04em;
  text-transform: uppercase;
  text-align: left;
  padding: 9px 12px;
  border: 1px solid var(--navy);
  print-color-adjust: exact; -webkit-print-color-adjust: exact;
}
table.doc tbody td {
  border: 1px solid var(--line);
  padding: 9px 12px;
  vertical-align: top;
  color: var(--ink);
}
table.doc tbody tr:nth-child(even) td { background: var(--navy-tint-2); }
table.doc tbody tr { break-inside: avoid; }
.ph { color: var(--faint); font-style: italic; }
.num-cell { text-align: center; font-family: 'IBM Plex Mono', monospace; color: var(--navy-700); font-weight: 500; width: 34px; }
.example td { background: var(--navy-tint) !important; }
.example td:first-child { color: var(--navy-700); font-weight: 600; font-style: normal; }

/* ---------- Callouts ---------- */
.callout {
  border: 1px solid var(--line);
  border-left: 3px solid var(--navy);
  background: var(--navy-tint);
  border-radius: 5px;
  padding: 14px 18px;
  margin: 0 0 16px;
  break-inside: avoid;
  print-color-adjust: exact; -webkit-print-color-adjust: exact;
}
.callout--warn {
  border-left-color: var(--amber);
  background: var(--amber-tint);
}
.callout__title {
  font-family: 'Archivo', sans-serif;
  font-weight: 700;
  font-size: 13px;
  color: var(--navy-800);
  margin: 0 0 6px;
  display: flex; align-items: center; gap: 8px;
}
.callout--warn .callout__title { color: #7A5413; }
.callout p { margin: 0; font-size: 13px; color: var(--muted); }
.callout ol, .callout ul { margin: 6px 0 0; padding-left: 18px; font-size: 13px; color: var(--muted); }
.callout li { margin: 3px 0; }

/* ---------- Numbered / checklist lists ---------- */
.checklist { list-style: none; margin: 0; padding: 0; }
.checklist li {
  display: flex; gap: 11px; align-items: flex-start;
  padding: 9px 0;
  border-bottom: 1px solid var(--line-soft);
  font-size: 13.5px;
  break-inside: avoid;
}
.checklist li:last-child { border-bottom: 0; }
.checklist .box {
  flex: none; width: 16px; height: 16px; margin-top: 1px;
  border: 1.5px solid var(--navy); border-radius: 3px;
  print-color-adjust: exact; -webkit-print-color-adjust: exact;
}
.fill-line {
  border-bottom: 1px solid var(--line);
  min-height: 26px;
  margin: 8px 0;
}

.keyrow {
  display: flex; flex-wrap: wrap; gap: 8px 18px;
  font-size: 11.5px; color: var(--muted);
  margin-top: 12px;
}
.tag {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 500;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--navy-tint);
  color: var(--navy-700);
  border: 1px solid var(--line);
  letter-spacing: .02em;
}

/* ---------- Signature blocks ---------- */
.sigs { display: grid; grid-template-columns: 1fr 1fr; gap: 28px 36px; margin-top: 8px; }
.sig { break-inside: avoid; }
.sig__role {
  font-family: 'Archivo', sans-serif; font-weight: 700; font-size: 13px;
  color: var(--navy-800); margin: 0 0 18px;
}
.sig__line { border-bottom: 1px solid var(--ink); height: 30px; }
.sig__cap { font-size: 11px; color: var(--muted); margin-top: 5px; text-transform: uppercase; letter-spacing: .05em; }
.sig__row { display: grid; grid-template-columns: 2fr 1fr; gap: 24px; }

/* ---------- Footer ---------- */
.docfoot {
  border-top: 1px solid var(--line);
  margin-top: 36px;
  padding-top: 14px;
  display: flex; align-items: center; justify-content: space-between;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--faint);
}
.docfoot img { height: 13px; opacity: .9; }

.spacer-lg { height: 8px; }
hr.soft { border: 0; border-top: 1px solid var(--line-soft); margin: 28px 0; }

/* ---------- Print ---------- */
@media print {
  @page { margin: 0.6in 0.6in 0.55in; }
  body { background: #fff; }
  .sheet {
    max-width: none; margin: 0; box-shadow: none; border-radius: 0;
  }
  .masthead { padding: 14px 0 14px; margin: 0; }
  .titlebar { padding: 20px 0 16px; }
  .body { padding: 22px 0 0; }
  .docfoot { padding-top: 10px; }
  .section { break-inside: avoid; }
  a { color: inherit; text-decoration: none; }
}

@media (max-width: 720px) {
  .grid--2, .grid--3 { grid-template-columns: 1fr; }
  .body, .masthead, .titlebar { padding-left: 24px; padding-right: 24px; }
  .sheet { margin: 0; border-radius: 0; }
  .sigs { grid-template-columns: 1fr; }
}
