/* ============================================================
   GRAVITY — PLATES, deck edition
   Brings the pitch deck onto the same inks and print treatment
   as the site, without touching the slide structure.
   Loaded after deck.css, so it only retints and re-textures.
   ============================================================ */

:root {
  /* riso inks, same set the site prints from */
  --ink:        #14130d;
  --paper:      #f7f4ec;
  --klein:      #1d3ebf;
  --flare:      #ff5330;
  --beacon:     #ffc23c;
  --verified:   #0f9d78;
  --void:       #0b1030;

  --bg:            #f7f4ec;
  --bg-raised:     #fffdf7;
  --bg-sunk:       #efeadc;
  --ink-soft:      #55524a;
  --ink-faint:     #8c8879;
  --hairline:      #d9d3c3;
  --hairline-strong: #c2bba6;
  --accent:        #1d3ebf;
  --accent-ink:    #12297d;
  --accent-soft:   #dfe4f7;
  --accent-soft-2: #eaedfa;

  /* a failed attempt is a faded flare, not grey */
  --killed:    #dda28d;
  --killed-bg: #f6ece6;

  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.42'/%3E%3C/svg%3E");
}

html, body { background: var(--bg); }

/* paper grain over the whole deck */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  background-image: var(--grain);
  background-size: 200px 200px;
  opacity: 0.3;
  mix-blend-mode: multiply;
  pointer-events: none;
  z-index: 9999;
}

/* --- the full stop keeps an orbit --- */
.wordmark-huge .dot { position: relative; color: var(--klein); }
.wordmark-huge .dot::after {
  content: "";
  position: absolute;
  left: 50%; top: 72%;
  width: 0.42em; height: 0.17em;
  border: 0.022em solid var(--klein);
  border-radius: 50%;
  transform: translate(-50%, -50%) rotate(-20deg);
  opacity: 0.7;
  pointer-events: none;
}

/* --- printed buttons, same block-shadow as the site --- */
.btn { border-radius: 0; font-weight: 600; }
.btn-primary { background: var(--klein); border-color: var(--klein); color: #fff; box-shadow: 3px 3px 0 var(--ink); }
.btn-primary:hover { transform: translate(-1px, -1px); box-shadow: 4px 4px 0 var(--ink); background: #1834a5; }
.btn-outline, .btn-ghost { border-radius: 0; box-shadow: 3px 3px 0 rgba(20,19,13,0.16); }

/* --- panels and grids read as printed plates --- */
.q-grid, .verify-channels, .join-grid { border-width: 1.4px; border-color: var(--ink); }
.q-cell, .vc-cell, .join-cell { background: var(--bg-raised); }
.vc-tag { color: var(--klein); }
.join-cta { color: var(--klein); }

/* --- deck chrome --- */
.deck-nav-hint kbd { border-radius: 2px; }

/* ------------------------------------------------------------
   PANELS AS PLATES
   deck.css draws every panel as a near-white card on a 1px
   hairline. Against warm paper that is almost no contrast, so
   the slides read as one flat wash. Same treatment as the site:
   paper stock, a real ink rule, and a block shadow that looks
   like a second impression.
   ------------------------------------------------------------ */

.stat-tiles,
.problem-card,
.receipt,
.engine-panel,
.ladder-block,
.p001-panel,
.gov-grid,
.q-grid,
.verify-channels,
.join-grid,
.path-columns,
.tier-row {
  border-width: 1.4px;
  border-color: var(--ink);
  border-radius: 0;
}

.engine-panel,
.receipt,
.p001-panel,
.ladder-block {
  box-shadow: 5px 6px 0 rgba(20,19,13,0.13);
}

.problem-card,
.gov-card,
.q-cell,
.vc-cell,
.join-cell,
.engine-panel,
.receipt,
.p001-panel,
.ladder-block,
.stat-tiles {
  background: #fffdf7;
}

/* the gov grid's inner cells keep hairlines, the block keeps the ink rule */
.gov-grid > * { border-color: rgba(20,19,13,0.18); }

/* the highlighted governance card prints on the klein wash */
.gov-card.is-key { background: var(--accent-soft); }

/* the pull-quote block on the founding-insight slide */
.insight-turn { border-left-width: 3px; border-left-color: var(--klein); background: #fffdf7; }

/* the three "too small / too local / too niche" examples need room to sit
   on one line each, otherwise the trailing clause wraps to a stray comma */
.insight-examples { gap: 30px; }
.insight-example p { max-width: 30ch; }

/* ------------------------------------------------------------
   THE TITLE SLIDE GETS THE WELL
   Same opener as the site: a mass in a rubber sheet with
   attempts falling in.
   ------------------------------------------------------------ */

.title-slide { position: relative; overflow: hidden; }
.title-slide .particle-field { display: none; }

.title-slide .well-stage { position: absolute; inset: 0; z-index: 0; }
.title-slide .well-stage canvas {
  position: absolute; inset: 0; width: 100%; height: 100%;
  -webkit-mask-image: radial-gradient(78% 46% at 50% 82%, #000 34%, rgba(0,0,0,0.72) 66%, rgba(0,0,0,0) 100%);
  mask-image: radial-gradient(78% 46% at 50% 82%, #000 34%, rgba(0,0,0,0.72) 66%, rgba(0,0,0,0) 100%);
}
.title-slide::before {
  content: "";
  position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: radial-gradient(52% 34% at 50% 38%, var(--paper) 0%, rgba(247,244,236,0.9) 52%, rgba(247,244,236,0) 84%);
}
.title-slide .slide-inner,
.title-slide .title-footer,
.title-slide .scroll-hint { position: relative; z-index: 2; }

.title-slide .well-readout {
  position: absolute;
  right: 40px;
  bottom: 108px;
  z-index: 2;
  text-align: right;
  font-size: 12px;
  line-height: 1.8;
  color: rgba(20,19,13,0.6);
  background: rgba(247,244,236,0.82);
  border: 1px solid rgba(20,19,13,0.16);
  padding: 12px 15px 11px;
  pointer-events: none;
}
.title-slide .well-readout b { font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }
.title-slide .well-readout .kill { color: var(--flare); }
.title-slide .well-readout .hit  { color: var(--verified); }
@media (max-width: 900px) { .title-slide .well-readout { display: none; } }

/* ------------------------------------------------------------
   CHAPTERS
   Four breaths that turn twenty arguments into a story:
   the predicament, the response, the doubt, the invitation.
   They are dividers, not slides, so they take no number.
   ------------------------------------------------------------ */

.chapter-slide { background: var(--paper); }

.chapter-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 60px;
  align-items: center;
  width: 100%;
}

.chapter-mark {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
  color: var(--klein);
  margin-bottom: 26px;
}
.chapter-rule { width: 54px; height: 1.6px; background: var(--klein); display: block; }

.chapter-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 0.98;
  letter-spacing: -0.026em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}

.chapter-line {
  margin-top: 26px;
  max-width: 46ch;
  font-size: clamp(16px, 1.5vw, 19px);
  line-height: 1.6;
  color: var(--ink-soft);
  text-wrap: pretty;
}

.chapter-plate svg { width: 100%; height: auto; max-height: 380px; display: block; }

@media (max-width: 900px) {
  .chapter-inner { grid-template-columns: 1fr; gap: 30px; }
  .chapter-plate { max-width: 380px; }
}

/* Get the chrome out of the mesh rather than punching paper holes through
   it: the scroll hint is redundant next to the pager and the navigate keys,
   and the footer drops below the near edge of the sheet. */
.title-slide .scroll-hint { display: none; }
.title-slide .title-footer {
  position: absolute;
  left: 0; right: 0;
  bottom: 26px;
  top: auto;
  text-align: center;
  background: none;
}
.title-slide .slide-inner { transform: translateY(-38px); }

/* the qualifying clause sits under its example, not as a comma orphan */
.insight-example { flex-wrap: wrap; }
.insight-example p { max-width: 34ch; }
.insight-dim {
  flex-basis: 100%;
  margin: 2px 0 0 32px;
  font-size: 13.5px;
  line-height: 1.45;
  color: var(--ink-faint);
}

/* ------------------------------------------------------------
   THE PRECEDENT
   A timeline, because this is the one slide that is a story
   rather than an argument, and stories have dates.
   ------------------------------------------------------------ */

.precedent-timeline {
  list-style: none;
  margin: 40px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.pt-step {
  position: relative;
  padding: 0 26px 0 0;
}

/* the rule runs through every step and stops at the last dot */
.pt-step::before {
  content: "";
  position: absolute;
  left: 0; right: 0;
  top: 33px;
  height: 1.4px;
  background: rgba(20,19,13,0.22);
}
.pt-step.is-end::before { right: auto; width: 8px; }

.pt-year {
  display: block;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--ink-faint);
  font-variant-numeric: tabular-nums;
  margin-bottom: 8px;
}

.pt-dot {
  position: relative;
  z-index: 1;
  display: block;
  width: 13px; height: 13px;
  border-radius: 50%;
  background: var(--paper);
  border: 1.8px solid var(--ink);
  margin-bottom: 20px;
}
.pt-step.is-end .pt-dot {
  width: 17px; height: 17px;
  margin-top: -2px;
  background: var(--beacon);
  border-color: var(--ink);
}

.pt-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 17.5px;
  line-height: 1.15;
  color: var(--ink);
  margin: 0 0 9px;
}
.pt-step p {
  font-size: 13.5px;
  line-height: 1.52;
  color: var(--ink-soft);
  max-width: 30ch;
  margin: 0;
}

.precedent-turn {
  margin-top: 44px;
  border-left: 3px solid var(--flare);
  padding: 4px 0 4px 22px;
}
.precedent-turn-line {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(19px, 2.1vw, 25px);
  line-height: 1.2;
  color: var(--ink);
  letter-spacing: -0.012em;
}
.precedent-turn-sub {
  margin-top: 10px;
  max-width: 74ch;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink-soft);
}

.precedent-source {
  margin-top: 22px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--ink-faint);
}

@media (max-width: 900px) {
  .precedent-timeline { grid-template-columns: 1fr; gap: 26px; }
  .pt-step { padding: 0 0 0 26px; }
  .pt-step::before { left: 6px; right: auto; top: 0; bottom: -26px; width: 1.4px; height: auto; }
  .pt-step.is-end::before { bottom: auto; height: 8px; }
  .pt-dot { position: absolute; left: 0; top: 24px; margin: 0; }
  .pt-year { margin-left: 0; }
}

#slide-precedent .slide-h { margin-bottom: 22px; }
#slide-precedent .slide-lede { max-width: 76ch; }
#slide-precedent .precedent-timeline { margin-top: 52px; }

/* ------------------------------------------------------------
   A WAY BACK
   The deck is otherwise a dead end: you land on it from a link
   and there is nothing to click. Quiet enough to ignore on all
   25 slides, obvious the moment you look for it.
   ------------------------------------------------------------ */

.deck-home {
  position: fixed;
  top: 26px;
  right: 30px;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  padding: 7px 14px 7px 11px;
  border: 1px solid rgba(20,19,13,0.16);
  border-radius: 999px;
  background: rgba(247,244,236,0.82);
  backdrop-filter: blur(3px);
  transition: border-color 140ms ease, background 140ms ease;
}
.deck-home:hover { border-color: var(--ink); background: var(--paper); }

.deck-home-mark { width: 20px; height: 20px; flex: 0 0 20px; overflow: visible; }
.deck-home-mark ellipse { fill: none; stroke: var(--klein); stroke-width: 1.2; }
.deck-home-mark .b { fill: var(--ink); }

.deck-home-word {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.deck-home-back {
  font-size: 11.5px;
  letter-spacing: 0.02em;
  color: var(--ink-faint);
  padding-left: 9px;
  border-left: 1px solid rgba(20,19,13,0.16);
}
.deck-home:hover .deck-home-back { color: var(--ink-soft); }

@media (max-width: 700px) {
  .deck-home { top: 14px; right: 14px; padding: 6px 11px 6px 9px; }
  .deck-home-back { display: none; }
}

/* MOO: the initials carry the three states */
.wordmark .wm-m, .deck-nav-word .wm-m { color: #ffc23c; }
.wordmark .wm-o1, .deck-nav-word .wm-o1 { color: #ff5330; }
.wordmark .wm-o2, .deck-nav-word .wm-o2 { color: #0f9d78; }
.site-footer .wordmark .wm-m { color: #ffc23c; } .site-footer .wordmark .wm-o1 { color: #ff5330; } .site-footer .wordmark .wm-o2 { color: #0f9d78; }
