/* cdm-checklist.css — interactive CDM 2015 checklist styles. */

.cdm-list {
  display: grid;
  border-top: 1px solid var(--rule);
  border-left: 1px solid var(--rule);
}
.cdm-item {
  display: grid;
  grid-template-columns: 28px 40px 1fr 28px;
  gap: 16px;
  padding: 18px 22px;
  border-right: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
  cursor: pointer;
  align-items: start;
  transition: background 0.15s ease;
}
.cdm-item:hover { background: var(--paper-2); }
.cdm-item input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  margin: 0;
  border: 1.5px solid var(--ink);
  border-radius: 3px;
  background: var(--paper);
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  align-self: flex-start;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.cdm-item input[type="checkbox"]:checked {
  background: var(--hazard);
  border-color: var(--hazard);
}
.cdm-item input[type="checkbox"]:checked::after {
  content: "✓";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -52%);
  color: var(--hazard-ink);
  font-size: 16px;
  font-weight: 700;
  line-height: 1;
}
.cdm-num {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-mute);
  border-top: 1px solid var(--ink);
  padding-top: 6px;
  width: 28px;
  align-self: flex-start;
}
.cdm-body { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.cdm-body b {
  font-family: var(--f-display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.015em;
  color: var(--ink);
}
.cdm-body span {
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 64ch;
}
.cdm-tick {
  font-family: var(--f-mono);
  font-size: 16px;
  color: var(--ink-mute);
  align-self: center;
  text-align: center;
  opacity: 0;
  transition: opacity 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.cdm-item:has(input:checked) .cdm-tick {
  opacity: 1;
  color: var(--good);
  transform: scale(1.2);
}
.cdm-item:has(input:checked) .cdm-body b {
  color: var(--ink-mute);
  text-decoration: line-through;
  text-decoration-color: var(--rule);
}
.cdm-item:has(input:checked) .cdm-body span {
  color: var(--ink-mute);
}

/* Action row (Save PDF / Email / Reset + note) */
.cdm-reset {
  margin-top: 22px;
  padding: 14px 22px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--ink-mute);
  text-transform: uppercase;
}
.cdm-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.cdm-actions [data-cdm-print] {
  background: var(--hazard);
  color: var(--hazard-ink);
  border-color: var(--hazard);
}
.cdm-actions [data-cdm-print]:hover { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.cdm-reset-note { color: var(--ink-mute); }


@media (max-width: 720px) {
  .cdm-item {
    grid-template-columns: 26px 32px 1fr;
    padding: 14px 16px;
    gap: 12px;
  }
  .cdm-tick { display: none; }
  .cdm-body b { font-size: 15px; }
  .cdm-body span { font-size: 13.5px; }
  .cdm-reset { flex-direction: column; align-items: flex-start; }
  .cdm-actions { width: 100%; }
  .cdm-actions .btn { flex: 1; min-width: 0; }
}


/* Print stylesheet — Save as PDF */
@media print {
  .site-header,
  .header-strip,
  .mobile-sheet,
  .mega-backdrop,
  .mega-panel-wrap,
  .sticky-cta,
  .foot,
  .cdm-reset,
  .ctas,
  .tp-cross,
  .sec[data-screen-label="05 What Unibuild does"],
  .sec[data-screen-label="06 Cross-links"],
  .final {
    display: none !important;
  }
  body { background: #fff; color: #000; }
  .tp-hero {
    padding: 0 0 16pt;
    border-bottom: 1pt solid #000;
    background: #fff;
  }
  .tp-hero::before { display: none; }
  .tp-hero-grid { display: block; }
  .tp-spec { display: none; }
  .tp-hero-text h1 { font-size: 28pt; line-height: 1.1; margin: 8pt 0 4pt; }
  .tp-hero-text .sub { font-size: 11pt; line-height: 1.4; max-width: none; }
  .tp-hero-text .meta { display: none; }
  .hazard-mark {
    background: #000 !important; color: #fff !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  .sec, .sec.sec-paper-2 { padding: 14pt 0 8pt; background: #fff !important; }
  .sec-hd { display: block; margin-bottom: 8pt; }
  .sec-hd h2 { font-size: 18pt; line-height: 1.15; margin: 6pt 0; }
  .sec-hd .lede { font-size: 10.5pt; max-width: none; }
  .num span { font-size: 9pt; }
  .cdm-list { page-break-inside: avoid; border: 1pt solid #000; }
  .cdm-item {
    grid-template-columns: 22pt 28pt 1fr;
    padding: 8pt 10pt;
    gap: 8pt;
    page-break-inside: avoid;
    background: #fff !important;
    border-bottom: 1pt solid #999;
  }
  .cdm-item input[type="checkbox"] {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    width: 14pt; height: 14pt;
    border: 1pt solid #000;
    background: #fff;
  }
  .cdm-item input[type="checkbox"]:checked {
    background: #000;
  }
  .cdm-item input[type="checkbox"]:checked::after {
    color: #fff;
    font-size: 10pt;
  }
  .cdm-tick { display: none; }
  .cdm-body b { font-size: 11pt; color: #000 !important; text-decoration: none !important; }
  .cdm-body span { font-size: 10pt; color: #333 !important; }
  a { color: #000; text-decoration: none; }
  @page { size: A4; margin: 14mm 12mm; }
}


/* ── Basis chip · legal reference per duty ───────────────────────── */
.cdm-body .cdm-head { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; flex-wrap: wrap; max-width: none; width: 100%; }
.cdm-body .cdm-ref { font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--hazard-ink); white-space: nowrap; flex-shrink: 0; padding-top: 2px; }
.cdm-body .cdm-ref.is-gp { color: var(--ink-mute); text-transform: none; letter-spacing: 0; font-style: italic; }
.cdm-item:has(input:checked) .cdm-body .cdm-ref { color: var(--ink-mute); }

/* ── Evidence notes · opt-in, hidden by default ──────────────────── */
.cdm-body .cdm-note { display: none; max-width: none; margin-top: 9px; }
body.cdm-notes-on .cdm-body .cdm-note { display: block; }
.cdm-note-input { width: 100%; max-width: 62ch; font-family: var(--f-display); font-size: 13px; padding: 7px 10px; border: 1px solid var(--rule); border-radius: 3px; background: var(--paper); color: var(--ink); }
.cdm-note-input::placeholder { color: var(--ink-mute); }
.cdm-note-input:focus { outline: none; border-color: var(--ink); }

/* ── Tools row · project context + actions ───────────────────────── */
.cdm-tools { margin-top: 22px; padding: 16px 22px; background: var(--paper-2); border: 1px solid var(--rule); display: flex; justify-content: space-between; align-items: flex-end; gap: 18px 28px; flex-wrap: wrap; }
.cdm-proj { display: flex; gap: 14px 18px; align-items: flex-end; flex-wrap: wrap; }
.cdm-field { display: flex; flex-direction: column; gap: 5px; font-family: var(--f-mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-mute); }
.cdm-field input { font-family: var(--f-display); font-size: 13px; text-transform: none; letter-spacing: 0; padding: 7px 10px; border: 1px solid var(--rule); border-radius: 3px; background: var(--paper); color: var(--ink); min-width: 210px; }
.cdm-field input:focus { outline: none; border-color: var(--ink); }
.cdm-toggle { display: flex; align-items: center; gap: 9px; font-family: var(--f-mono); font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-2); cursor: pointer; user-select: none; padding-bottom: 7px; }
.cdm-toggle input { width: 17px; height: 17px; accent-color: var(--hazard); cursor: pointer; }

/* ── Disclaimer + print head ─────────────────────────────────────── */
.cdm-disclaimer { margin: 14px 0 0; font-size: 12px; line-height: 1.55; color: var(--ink-mute); max-width: 82ch; }
.cdm-disclaimer a { color: var(--ink-2); border-bottom: 1px solid var(--rule); }
.cdm-disclaimer a:hover { color: var(--ink); }
.cdm-print-head { display: none; }

@media (max-width: 720px) {
  .cdm-tools { flex-direction: column; align-items: stretch; }
  .cdm-proj { width: 100%; }
  .cdm-field { width: 100%; }
  .cdm-field input { min-width: 0; width: 100%; }
  .cdm-actions { width: 100%; }
  .cdm-actions .btn { flex: 1; min-width: 0; }
}

@media print {
  .cdm-tools { display: none !important; }
  .cdm-print-head { display: block !important; font-family: var(--f-mono); font-size: 9pt; color: #000; border: 1pt solid #000; padding: 6pt 8pt; margin: 0 0 10pt; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .cdm-body .cdm-head { display: flex; justify-content: space-between; gap: 10pt; }
  .cdm-body .cdm-ref { color: #000 !important; font-size: 8pt; }
  .cdm-body .cdm-note { display: none !important; }
  .cdm-item.has-note .cdm-body .cdm-note { display: block !important; margin-top: 3pt; }
  .cdm-item.has-note .cdm-note-input { border: none !important; padding: 0 !important; font-size: 9pt !important; color: #000 !important; width: 100%; }
  .cdm-item.has-note .cdm-body .cdm-note::before { content: "\21B3  note: "; font-family: var(--f-mono); font-size: 8pt; color: #333; }
  .cdm-disclaimer { font-size: 8.5pt; color: #333 !important; margin-top: 10pt; }
  .cdm-disclaimer a { color: #000; }
}
