/* ============================================================
   Gathered Work — design system v3
   Anchor: the digital-forensics report. A document built to
   hold up under challenge. Dark navy/slate ground with a
   discernible blue cast (per Carrie), near-white text,
   hairline rules, one cold steel accent. No ornament, no
   rotation, no texture.
   Fonts: system stacks only — the local-only privacy posture
   forbids third-party requests, including font CDNs. Serif for
   argument, sans for apparatus, mono for data.
   Standing rule (Carrie): no warm/beige paper palettes, no
   royal blue, no neons.
   ============================================================ */

:root {
  --bg: #0d121d;
  --bg-raise: #131a29;
  --bg-inset: #101624;
  --text: #e7e9ee;
  --text-dim: #98a1b2;
  --hair: #263043;
  --hair-strong: #39455e;
  --accent: #85b7ce;        /* cold steel — links, data, section numbers */
  --accent-dim: #4e7386;

  --font-display: Charter, "Bitstream Charter", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --font-mono: ui-monospace, "SF Mono", Menlo, Consolas, "Courier New", monospace;

  --measure: 42rem;
  --gutter: clamp(1.25rem, 5vw, 4rem);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent); color: var(--bg); }

/* ---------- masthead ---------- */

.topline {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 1rem var(--gutter);
  border-bottom: 1px solid var(--hair);
}
.topline a { text-decoration: none; }
.topline .wordmark {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  color: var(--text);
}
.topline .wordmark:hover { color: var(--accent); }
.topline nav { display: flex; gap: 1.75rem; flex-wrap: wrap; }
.topline nav a {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  color: var(--text-dim);
}
.topline nav a:hover { color: var(--accent); }

/* ---------- typography ---------- */

h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.4rem, 6.5vw, 4.75rem);
  line-height: 1.04;
  letter-spacing: -0.015em;
  max-width: 18ch;
}
h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin-bottom: 1.1rem;
  max-width: 28ch;
}
h3 {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-dim);
  margin-bottom: 0.8rem;
}

p { max-width: var(--measure); margin-bottom: 1rem; }
p.lede {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.15rem, 2vw, 1.35rem);
  line-height: 1.5;
  color: var(--text);
}

a { color: var(--accent); text-decoration-color: var(--accent-dim); }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

strong { font-weight: 600; color: var(--text); }
em { font-style: italic; }

/* ---------- report sections ---------- */

.section {
  display: grid;
  grid-template-columns: minmax(5.5rem, 9rem) 1fr;
  gap: clamp(1rem, 3vw, 3rem);
  padding: clamp(2.5rem, 6vw, 4.5rem) var(--gutter);
  border-top: 1px solid var(--hair);
  max-width: 80rem;
}
.section:first-of-type { border-top: none; }
.section--raise { background: var(--bg-raise); }

.section-no {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
  padding-top: 0.5rem;
}
.section-no small {
  display: block;
  color: var(--text-dim);
  font-weight: 400;
  letter-spacing: 0.04em;
  margin-top: 0.35rem;
  text-transform: none;
}

@media (max-width: 720px) {
  .section { grid-template-columns: 1fr; gap: 0.75rem; }
}

/* ---------- data: false-positive scale ---------- */

.fpr-scale { max-width: 40rem; margin: 1.75rem 0 0.5rem; }
.fpr-row {
  display: grid;
  grid-template-columns: 1fr 4.5rem;
  align-items: end;
  gap: 0.75rem;
  margin-bottom: 1.1rem;
}
.fpr-row .label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  grid-column: 1 / -1;
  margin-bottom: 0.35rem;
}
.fpr-bar {
  height: 0.55rem;
  background: var(--bg-inset);
  border: 1px solid var(--hair);
}
.fpr-bar > span { display: block; height: 100%; background: var(--accent); }
.fpr-val {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  text-align: right;
}
.fpr-caption {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
  max-width: 40rem;
}

/* ---------- procedures ---------- */

.steps { counter-reset: step; list-style: none; max-width: var(--measure); }
.steps > li {
  counter-increment: step;
  position: relative;
  padding: 1.2rem 0 1.2rem 3.2rem;
  border-top: 1px solid var(--hair);
}
.steps > li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 1.35rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
}
.steps > li strong {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.3rem;
}
.steps > li p { margin-bottom: 0.5rem; color: var(--text-dim); }
.steps > li p strong { display: inline; color: var(--text); }

/* ---------- tables ---------- */

.claim-table { width: 100%; max-width: 48rem; border-collapse: collapse; }
.claim-table th, .claim-table td {
  text-align: left;
  padding: 0.8rem 1rem 0.8rem 0;
  border-bottom: 1px solid var(--hair);
  vertical-align: top;
  font-size: 0.92rem;
}
.claim-table th {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  border-bottom: 1px solid var(--hair-strong);
}
.claim-table td { color: var(--text-dim); }
.claim-table td:first-child { color: var(--text); font-weight: 500; }
.claim-yes { color: var(--accent); }
.table-scroll { overflow-x: auto; }

/* ---------- documents ---------- */

.document {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  line-height: 1.7;
  background: var(--bg-inset);
  border: 1px solid var(--hair);
  border-left: 2px solid var(--accent);
  padding: 1.75rem;
  max-width: 46rem;
  white-space: pre-wrap;
  overflow-x: auto;
  margin: 1.25rem 0 1.5rem;
  color: var(--text-dim);
}
.document .field { color: var(--accent); }

.hashline {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  word-break: break-all;
  background: var(--bg-inset);
  border: 1px solid var(--hair-strong);
  padding: 0.9rem 1.1rem;
  max-width: 46rem;
  margin: 0.75rem 0;
  color: var(--accent);
}

/* ---------- forms & buttons ---------- */

label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-dim);
  margin: 1rem 0 0.4rem;
}
input[type="file"], input[type="email"], input[type="text"] {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  padding: 0.65rem 0.8rem;
  background: var(--bg-inset);
  border: 1px solid var(--hair-strong);
  color: var(--text);
  max-width: 30rem;
  width: 100%;
}
input::placeholder { color: var(--text-dim); opacity: 0.6; }

button, .button {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--accent-dim);
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease;
}
button:hover, .button:hover { background: var(--accent); color: var(--bg); }
.button--solid { background: var(--accent); color: var(--bg); border-color: var(--accent); }
.button--solid:hover { background: var(--text); border-color: var(--text); }

/* ---------- dropzone ---------- */

.dropzone {
  border: 1px dashed var(--hair-strong);
  background: var(--bg-inset);
  padding: 2.5rem 1.5rem;
  text-align: center;
  max-width: 46rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-dim);
  cursor: pointer;
  transition: border-color 0.15s ease;
}
.dropzone:hover, .dropzone.dragover { border-color: var(--accent); color: var(--text); }

/* ---------- footer ---------- */

.colophon {
  border-top: 1px solid var(--hair);
  padding: 2.5rem var(--gutter) 3.5rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  line-height: 1.8;
  color: var(--text-dim);
}
.colophon a { color: var(--text-dim); }
.colophon a:hover { color: var(--accent); }
.colophon .rows { display: flex; flex-wrap: wrap; gap: 3rem; max-width: 80rem; }
.colophon .rows > div { max-width: 24rem; }
.colophon .mark {
  font-weight: 600;
  letter-spacing: 0.22em;
  color: var(--text);
}

/* ---------- motion: one settle ---------- */

@media (prefers-reduced-motion: no-preference) {
  .reveal > * {
    opacity: 0;
    transform: translateY(0.35rem);
    animation: settle 0.5s ease-out forwards;
  }
  .reveal > *:nth-child(1) { animation-delay: 0.05s; }
  .reveal > *:nth-child(2) { animation-delay: 0.13s; }
  .reveal > *:nth-child(3) { animation-delay: 0.21s; }
  @keyframes settle { to { opacity: 1; transform: none; } }
}

/* ---------- utilities ---------- */

.mono { font-family: var(--font-mono); }
.small { font-size: 0.85rem; }
.muted { color: var(--text-dim); }
.mw { max-width: var(--measure); }
