/* transaction-diligence.css -- page-scoped styles for transaction-diligence.html.
   Nothing here belongs in the shared CSS. It depends on tokens defined by
   inner-page.css (--cyan, --cyan-rgb, --gold, --gold-rgb, --bone, --bone-soft,
   --bone-dim, --hairline, --crimson) and on the form and readout primitives in
   vates-console.css (.field, .fg, .est, .est-grid, .est-readout, .ro-cta).
   Every colour below is a token or a token-derived alpha, so the page stays in
   step with the rest of the site. */

/* The standing on-screen data rule. It sits above the tool and is repeated
   inside it, because people scroll straight to a form. */
.td-rule {
  margin: 18px 0 0;
  padding: 13px 16px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  line-height: 1.6;
  letter-spacing: .02em;
  color: var(--gold);
  background: rgba(var(--gold-rgb), .07);
  border: 1px solid rgba(var(--gold-rgb), .3);
  border-radius: 2px;
}

/* Category lede inside the form, under the .fg divider. */
.td-glede {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11.5px;
  line-height: 1.6;
  color: var(--bone-dim);
  margin: -6px 0 16px;
}

/* Tool shell -------------------------------------------------------------- */

.td-tool {
  border: 1px solid var(--hairline);
  border-radius: 2px;
  padding: 22px 22px 26px;
  background: linear-gradient(180deg, rgba(14, 10, 26, .55), rgba(8, 6, 14, .8));
}
@media (max-width: 560px) { .td-tool { padding: 18px 15px 20px; } }

.td-tool-h {
  font-family: Cinzel, serif;
  font-weight: 700;
  font-size: clamp(19px, 2.6vw, 24px);
  line-height: 1.25;
  color: var(--bone);
  margin: 0 0 10px;
}
.td-tool-lede {
  color: var(--bone-soft);
  font-size: 15.5px;
  line-height: 1.62;
  max-width: 68ch;
  margin: 0 0 6px;
}

.td-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}
.td-actions .ro-cta { width: auto; flex: 1 1 220px; }
.td-reset {
  flex: 0 0 auto;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--bone-dim);
  background: transparent;
  border: 1px solid var(--hairline);
  border-radius: 2px;
  padding: 13px 16px;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
.td-reset:hover { border-color: rgba(var(--cyan-rgb), .45); color: var(--bone-soft); }

/* Output ------------------------------------------------------------------ */

.td-out {
  margin-top: 26px;
  padding: 22px 22px 20px;
  border: 1px solid rgba(var(--cyan-rgb), .3);
  border-radius: 2px;
  background: linear-gradient(180deg, rgba(var(--cyan-rgb), .05), rgba(5, 3, 9, .6));
}
@media (max-width: 560px) { .td-out { padding: 17px 14px 16px; } }

.td-out-h {
  font-family: Cinzel, serif;
  font-weight: 700;
  font-size: clamp(17px, 2.4vw, 21px);
  line-height: 1.3;
  color: var(--cyan);
  margin: 0 0 4px;
}
.td-out-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 22px 0 10px;
  padding-bottom: 7px;
  border-bottom: 1px solid rgba(var(--gold-rgb), .26);
}

/* The eleven category lines. */
.td-lines { list-style: none; padding: 0; margin: 16px 0 0; }
.td-line {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 6px 16px;
  padding: 11px 0 11px 13px;
  border-bottom: 1px solid var(--hairline);
  border-left: 2px solid transparent;
}
.td-line:last-child { border-bottom: none; }
.td-line.is-clear { border-left-color: var(--cyan); }
.td-line.is-open { border-left-color: var(--gold); }
@media (max-width: 700px) { .td-line { grid-template-columns: minmax(0, 1fr); } }

.td-line-k {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--bone-dim);
}
.td-line-v {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12.5px;
  line-height: 1.62;
  color: var(--bone-soft);
}
.td-line.is-clear .td-line-v { color: var(--cyan); }

.td-list {
  margin: 0;
  padding-left: 22px;
  color: var(--bone-soft);
  font-size: 14.5px;
  line-height: 1.62;
}
.td-list li { margin-bottom: 9px; }
.td-list li::marker { color: var(--cyan); font-family: 'JetBrains Mono', monospace; }
.td-list-pro li::marker { color: var(--gold); }
.td-list-risk li::marker { color: var(--crimson, #ff6680); }

.td-steps {
  margin: 0;
  padding-left: 22px;
  color: var(--bone-soft);
  font-size: 14.5px;
  line-height: 1.62;
}
.td-steps li { margin-bottom: 9px; }
.td-steps li::marker { color: var(--cyan); font-family: 'JetBrains Mono', monospace; }

.td-fine {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  line-height: 1.66;
  color: var(--bone-dim);
  margin: 16px 0 0;
}

/* Output actions: download / email --------------------------------------- */

.td-out-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--hairline);
}
.td-out-actions .btn { flex: 1 1 220px; text-align: center; }
/* .btn sets display, which beats the browser's own [hidden] rule: without
   this the two actions showed, as dead links, before any checklist existed. */
.td-out-actions[hidden], .td-out-actions .btn[hidden] { display: none; }

/* Consent block ----------------------------------------------------------- */

.td-consent-box {
  margin-top: 24px;
  padding: 20px 20px 18px;
  border: 1px solid rgba(var(--gold-rgb), .3);
  border-radius: 2px;
  background: rgba(var(--gold-rgb), .04);
}
.td-consent-h {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 10px;
}
.td-consent-lede {
  font-size: 14.5px;
  line-height: 1.62;
  color: var(--bone-soft);
  margin: 0 0 16px;
  max-width: 68ch;
}
.td-consent-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
@media (max-width: 700px) { .td-consent-grid { grid-template-columns: minmax(0, 1fr); } }

.td-consent-row {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  margin: 16px 0 0;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  line-height: 1.6;
  color: var(--bone-soft);
  cursor: pointer;
}
.td-consent-row input {
  width: 17px;
  height: 17px;
  flex: none;
  margin-top: 2px;
  accent-color: var(--cyan);
  cursor: pointer;
}
.td-send { margin-top: 16px; }
.td-send-note {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10.5px;
  letter-spacing: .04em;
  color: var(--bone-dim);
  text-align: center;
  margin-top: 10px;
  min-height: 14px;
}

/* Category grid (prose overview before the form) --------------------------- */

.td-cats { list-style: none; padding: 0; margin: 20px 0 0; }
.td-cats li {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 6px 20px;
  padding: 14px 0;
  border-bottom: 1px solid var(--hairline);
}
.td-cats li:last-child { border-bottom: none; }
@media (max-width: 760px) { .td-cats li { grid-template-columns: minmax(0, 1fr); } }

.td-cats-t {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  letter-spacing: .06em;
  color: var(--cyan);
}
.td-cats-d {
  font-size: 14.5px;
  line-height: 1.62;
  color: var(--bone-soft);
}

/* Sources ----------------------------------------------------------------- */

.td-src { list-style: none; padding: 0; margin: 18px 0 0; }
.td-src li {
  padding: 11px 0;
  border-bottom: 1px solid var(--hairline);
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  line-height: 1.66;
  color: var(--bone-dim);
}
.td-src li:last-child { border-bottom: none; }
.td-src b {
  color: var(--bone-soft);
  font-weight: 500;
  display: block;
  margin-bottom: 3px;
}
.td-src a { color: var(--cyan); word-break: break-word; }

.td-noscript {
  margin-top: 20px;
  padding: 14px 16px;
  border: 1px solid rgba(var(--crimson, #ff6680), .35);
  border-radius: 2px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12.5px;
  line-height: 1.66;
  color: var(--bone-soft);
}

@media (prefers-reduced-motion: reduce) {
  .td-reset, .td-send { transition: none; }
}

/* Print: "Download this checklist" ----------------------------------------
   window.print() prints the whole document, so this stylesheet strips it
   down to something worth printing: no nav chrome, no hero art, no form
   controls, no consent box, just the readable prose and, when it has been
   generated, the diligence picture output. */
@media print {
  nav.nav,
  header.hero,
  .td-actions,
  #td-form,
  .td-consent-box,
  .td-out-actions,
  footer,
  script { display: none !important; }

  body { background: #fff; color: #000; }
  .td-out { border: 1px solid #000; background: none; }
  .td-out-h, .td-tool-h { color: #000; }
  .td-line-v, .td-line-k, .td-list, .td-steps, .td-fine, .td-cats-d { color: #111; }
  .td-line.is-clear .td-line-v { color: #111; }
  a { color: #000; text-decoration: underline; }
}
