/* ProsperAI — candidate home page (index-b.html).

   Deliberately self-contained and deliberately font-free. Every other page on
   this site pulls Source Serif 4 and Public Sans from fonts.googleapis.com,
   which means every visitor's IP reaches Google before they read a word about
   how nothing leaves their device. This page makes a verifiable network claim,
   so it cannot afford a single third-party request. System fonts only. */

:root {
  --paper:  #f7f3ec;
  --panel:  #fffdfa;
  --raised: #fbf8f2;
  --ink:    #23201c;
  --ink-2:  #6d675f;
  --ink-3:  #948d83;
  --line:   #e3dbcd;
  --line-2: #d3c8b4;
  --red:    #9c2130;
  --blue:   #1f4e79;
  --amber:  #d98e1f;
  --mark:   #ffe9b8;
  --ok:     #2e7d5b;
  --ok-bg:  #e8f4ee;
  --radius: 14px;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", "Times New Roman", serif;
}
:root[data-theme="dark"], html[data-theme="dark"] {
  --paper: #1b1916; --panel: #242019; --raised: #2b2620; --ink: #f2ece2;
  --ink-2: #a79f92; --ink-3: #837b6f; --line: #3a342b; --line-2: #4a4238;
  --mark: #5a4415; --blue: #7fb0dd; --ok: #6fc79c; --ok-bg: #1f3129;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #1b1916; --panel: #242019; --raised: #2b2620; --ink: #f2ece2;
    --ink-2: #a79f92; --ink-3: #837b6f; --line: #3a342b; --line-2: #4a4238;
    --mark: #5a4415; --blue: #7fb0dd; --ok: #6fc79c; --ok-bg: #1f3129;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--blue); }
h1, h2, h3 { font-family: var(--serif); letter-spacing: -.015em; line-height: 1.14; }
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 22px; }
.wrap-wide { max-width: 1500px; margin: 0 auto; padding: 0 22px; }
section { padding: 66px 0; border-top: 1px solid var(--line); }
section.alt { background: var(--panel); }
.kicker {
  font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--red); margin-bottom: 10px;
}
.sec-head { max-width: 74ch; margin-bottom: 30px; }
.sec-head h2 { font-size: clamp(25px, 3.2vw, 34px); margin: 0 0 12px; }
.lede { font-size: 17.5px; color: var(--ink-2); margin: 0; }
.lede strong { color: var(--ink); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40; background: var(--paper);
  border-bottom: 1px solid var(--line);
}
:root[data-theme] .site-header { background: var(--paper); }
.nav { display: flex; align-items: center; gap: 18px; height: 60px; }
.nav .brand { display: flex; align-items: center; gap: 9px; text-decoration: none; color: var(--ink); }
.nav .brand img { height: 30px; width: auto; display: block; }
.nav-links { margin-left: auto; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nav-links a { color: var(--ink-2); text-decoration: none; font-size: 14.5px; font-weight: 500; padding: 7px 10px; border-radius: 8px; }
.nav-links a:hover { color: var(--ink); background: var(--panel); }
.theme-btn {
  font: inherit; font-size: 16px; cursor: pointer; margin-left: 4px;
  border: 1px solid var(--line); background: var(--panel); color: var(--ink-2);
  width: 34px; height: 32px; border-radius: 8px;
}
.btn {
  display: inline-block; font: inherit; font-weight: 600; font-size: 15px; cursor: pointer;
  padding: 10px 18px; border-radius: 10px; text-decoration: none; border: 1px solid transparent;
}
.btn-sm { font-size: 14px; padding: 7px 13px; }
.btn-primary { background: var(--red); color: #fff; }
.btn-ghost { background: var(--panel); color: var(--ink); border-color: var(--line-2); }
.btn:focus-visible, .lv-slider:focus-visible, .seg button:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; }

/* ---------- hero ---------- */
.hero { border-top: none; padding: 40px 0 56px; }
.hero h1 { font-size: clamp(31px, 4.6vw, 50px); margin: 0 0 14px; }
.hero h1 em { font-style: normal; color: var(--red); }
.hero .lede { max-width: 68ch; font-size: 18px; }
.hero-top { max-width: 78ch; margin-bottom: 26px; }

.reader {
  background: var(--panel); border: 1px solid var(--line); border-radius: 18px; overflow: hidden;
  box-shadow: 0 1px 2px rgba(0,0,0,.04), 0 8px 30px rgba(0,0,0,.05);
}
.reader-bar {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 15px 20px; background: var(--raised); border-bottom: 1px solid var(--line);
}
.reader-bar .src { flex: 1 1 260px; min-width: 0; }
.reader-bar .src b { display: block; font-family: var(--serif); font-size: 16px; }
.reader-bar .src span { font-size: 12.5px; color: var(--ink-2); }

.lv-wrap { flex: 1 1 420px; min-width: 280px; }
.lv-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 2px; }
.lv-head label { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-2); }
.lv-head .now { font-size: 14px; font-weight: 700; color: var(--red); }
.lv-slider {
  width: 100%; margin: 4px 0 2px; accent-color: var(--red); cursor: pointer; height: 22px;
}
.lv-ticks { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--ink-3); }
.lv-ticks span { flex: 1; text-align: center; }
.lv-ticks span:first-child { text-align: left; }
.lv-ticks span:last-child { text-align: right; }
.lv-ticks span.on { color: var(--ink); font-weight: 700; }

.reader-body {
  padding: 26px 30px 22px; font-family: var(--serif); font-size: 18px; line-height: 1.68;
  min-height: 330px;
}
.reader-body h3 { font-size: 23px; margin: 0 0 14px; }
.reader-body p { margin: 0 0 14px; }
.reader-body p:last-child { margin-bottom: 0; }
.reader-body.fade { animation: fadein .28s ease; }
@keyframes fadein { from { opacity: .25; } to { opacity: 1; } }
.reader-body mark { background: var(--mark); color: inherit; border-radius: 3px; padding: 0 2px; }

.reader-foot {
  border-top: 1px solid var(--line); background: var(--raised);
  padding: 14px 20px; display: flex; gap: 22px; flex-wrap: wrap; align-items: center;
}
.metrics { display: flex; gap: 20px; flex-wrap: wrap; font-size: 13px; color: var(--ink-2); }
.metrics b { color: var(--ink); font-variant-numeric: tabular-nums; }

/* the fact strip — computed live, not asserted */
.facts { border-top: 1px solid var(--line); padding: 14px 20px 16px; background: var(--panel); }
.facts h4 {
  margin: 0 0 9px; font-size: 11.5px; font-weight: 800; letter-spacing: .09em;
  text-transform: uppercase; color: var(--ink-2);
}
.fact-row { display: flex; gap: 8px; flex-wrap: wrap; }
.fact {
  display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600;
  padding: 5px 11px; border-radius: 999px; border: 1px solid var(--line-2);
  background: var(--ok-bg); color: var(--ok);
}
.fact.gone { background: transparent; color: var(--ink-3); border-style: dashed; font-weight: 500; }
.fact .tick { font-size: 11px; }
.facts .caption { margin: 10px 0 0; font-size: 12.5px; color: var(--ink-2); }

/* ---------- five readers wall ---------- */
/* Columns stretch to a common height so the five "what changed" footers line up
   across the wall — the comparison is the point of this section. */
.wall {
  display: grid; grid-template-columns: repeat(5, minmax(240px, 1fr)); gap: 13px;
  align-items: stretch; overflow-x: auto; padding-bottom: 8px;
}
@media (max-width: 1240px) { .wall { grid-template-columns: repeat(5, 290px); } }
.col {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
}
.col.orig { border-color: var(--red); box-shadow: 0 0 0 1px var(--red); }
/* Exact height, sized for the longest description (Rosa's, which wraps to two
   lines). A min-height would only set a floor and her column's text would still
   start lower than the other four — and the whole point of this wall is that
   the five readings line up for comparison. */
.col > header {
  display: flex; align-items: center; gap: 10px; padding: 10px 14px; height: 72px;
  border-bottom: 1px solid var(--line); background: var(--raised);
}
.col > header .emoji { font-size: 21px; flex: none; }
.col > header div { min-width: 0; }
.col > header strong { display: block; font-size: 14.5px; line-height: 1.25; }
.col > header span { display: block; font-size: 11.5px; line-height: 1.3; color: var(--ink-2); }
.col .body { padding: 14px; font-family: var(--serif); font-size: 15px; line-height: 1.6; }
.col .body p { margin: 0 0 10px; }
.col .body p:last-child { margin-bottom: 0; }
.col .body mark { background: var(--mark); color: inherit; border-radius: 3px; padding: 0 2px; }
.wall.no-marks mark { background: transparent; padding: 0; }
.col .changes { margin-top: auto; padding: 12px 14px; border-top: 1px solid var(--line); background: var(--raised); }
.col .changes h4 {
  margin: 0 0 6px; font-size: 10.5px; font-weight: 800; letter-spacing: .08em;
  text-transform: uppercase; color: var(--ink-2);
}
.col .changes ul { margin: 0; padding-left: 16px; font-size: 12.5px; color: var(--ink-2); }
.col .changes li { margin-bottom: 3px; }
.col .changes .keep { margin: 7px 0 0; font-size: 12px; color: var(--ok); font-weight: 600; }
.col.orig .changes .keep { color: var(--red); font-weight: 500; }
.wall-controls { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
label.chk { display: flex; align-items: center; gap: 7px; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.swipe-hint { display: none; font-size: 13px; color: var(--ink-2); margin: 0 0 12px; }
@media (max-width: 760px) {
  .wall { grid-template-columns: repeat(5, 86vw); gap: 12px; scroll-snap-type: x mandatory; }
  .col { scroll-snap-align: center; }
  .swipe-hint { display: block; }
  .reader-body { padding: 20px 18px; font-size: 17px; }
  /* The section links wrap into three ragged rows on a phone. Everything they
     point at is one scroll away, so drop them and keep the two controls. */
  .nav-links a:not(.btn) { display: none; }
  .reader-bar { padding: 13px 16px; }
}

/* ---------- mediation ---------- */
.med-grid { display: grid; grid-template-columns: 1.25fr .95fr; gap: 22px; align-items: start; }
@media (max-width: 900px) { .med-grid { grid-template-columns: 1fr; } }
.med-panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.med-panel > header {
  padding: 12px 16px; border-bottom: 1px solid var(--line); background: var(--raised);
  display: flex; align-items: center; gap: 9px; font-size: 13.5px; font-weight: 700;
}
.med-panel > header .who { margin-left: auto; font-weight: 500; color: var(--ink-2); font-size: 12.5px; }
.med-body { padding: 17px 19px; font-family: var(--serif); font-size: 16px; line-height: 1.62; }
.med-body p { margin: 0 0 12px; }
.med-body p:last-child { margin-bottom: 0; }
.med-body mark { background: var(--mark); border-radius: 3px; padding: 0 2px; }
.med-actions { padding: 13px 19px; border-top: 1px solid var(--line); background: var(--raised); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.med-note { font-size: 13px; color: var(--ink-2); }
.med-note.ok { color: var(--ok); font-weight: 600; }
.guardian-card { padding: 17px 19px; }
.guardian-card .empty { color: var(--ink-3); font-size: 14px; font-style: italic; }
.req {
  border: 1px solid var(--line-2); border-radius: 11px; padding: 13px 14px; background: var(--raised);
}
.req .r-top { font-size: 13px; color: var(--ink-2); margin-bottom: 7px; }
.req .r-quote { font-family: var(--serif); font-size: 14.5px; margin: 0 0 11px; padding-left: 11px; border-left: 3px solid var(--line-2); color: var(--ink); }
.req .r-why { font-size: 13px; color: var(--ink-2); margin: 0 0 12px; }
.req .r-btns { display: flex; gap: 8px; }
.btn-ok { background: var(--ok); color: #fff; }
.btn-no { background: var(--panel); color: var(--ink-2); border-color: var(--line-2); }
.med-steps { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 18px; }
.med-steps .s {
  font-size: 12.5px; font-weight: 600; padding: 5px 11px; border-radius: 999px;
  border: 1px solid var(--line-2); color: var(--ink-3); background: var(--panel);
}
.med-steps .s.on { border-color: var(--red); color: var(--red); }
.med-steps .s.done { border-color: var(--ok); color: var(--ok); background: var(--ok-bg); }

/* ---------- network receipt ---------- */
.receipt {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; max-width: 900px;
}
.receipt > header {
  display: flex; align-items: center; gap: 10px; padding: 12px 17px;
  border-bottom: 1px solid var(--line); background: var(--raised);
  font-size: 12.5px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-2);
}
.receipt .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--ok); flex: none; }
.rec-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.rec-table th, .rec-table td { text-align: left; padding: 10px 17px; border-bottom: 1px solid var(--line); }
.rec-table th { font-size: 11.5px; letter-spacing: .07em; text-transform: uppercase; color: var(--ink-3); font-weight: 700; }
.rec-table td.n { font-variant-numeric: tabular-nums; text-align: right; width: 1%; white-space: nowrap; }
.rec-table code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px;
  background: var(--raised); padding: 2px 6px; border-radius: 5px; border: 1px solid var(--line);
}
.rec-table tr.third td { color: var(--red); }
.rec-claims { padding: 4px 17px 6px; }
.claim { display: flex; align-items: flex-start; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.claim:last-child { border-bottom: none; }
.claim .big {
  font-size: 19px; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--ok);
  min-width: 2ch; text-align: right; line-height: 1.35;
}
.claim .big.warn { color: var(--red); }
.claim div strong { display: block; font-size: 14.5px; }
.claim div span { font-size: 13px; color: var(--ink-2); }
.rec-foot { padding: 13px 17px; background: var(--raised); border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-2); }
.rec-foot strong { color: var(--ink); }

/* ---------- two doors ---------- */
.doors { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 860px) { .doors { grid-template-columns: 1fr; } }
.door {
  display: block; text-decoration: none; color: inherit; background: var(--panel);
  border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 26px 22px;
}
.door:hover { border-color: var(--line-2); }
.door .ic { font-size: 27px; }
.door h3 { font-size: 21px; margin: 11px 0 8px; }
.door p { margin: 0 0 15px; color: var(--ink-2); font-size: 15px; }
.door ul { margin: 0 0 17px; padding-left: 19px; color: var(--ink-2); font-size: 14.5px; }
.door li { margin-bottom: 5px; }
.door .go { font-weight: 700; color: var(--red); font-size: 15px; }

/* ---------- how ---------- */
.how-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
@media (max-width: 860px) { .how-grid { grid-template-columns: 1fr; } }
.how-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 21px; }
.how-card .n { font-size: 12px; font-weight: 800; color: var(--red); letter-spacing: .1em; }
.how-card h3 { font-size: 18px; margin: 7px 0 8px; }
.how-card p { margin: 0; color: var(--ink-2); font-size: 14.5px; }

/* ---------- footer ---------- */
footer.site { border-top: 1px solid var(--line); padding: 34px 0 44px; background: var(--panel); }
footer.site .f-row { display: flex; gap: 20px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
footer.site img { height: 46px; width: auto; }
footer.site .f-links { margin-left: auto; display: flex; gap: 16px; flex-wrap: wrap; font-size: 14px; }
footer.site p { margin: 0 0 8px; font-size: 13px; color: var(--ink-2); max-width: 92ch; }
