@import url('https://fonts.googleapis.com/css2?family=Instrument+Sans:wght@400;500;600;700&family=Instrument+Serif:ital@0;1&display=swap');

:root {
  color-scheme: light;
  --ink: #252525;
  --muted: #656565;
  --faint: #757575;
  --line: #e9e9e9;
  --serif: 'Instrument Serif', Georgia, serif;
  --gutter: clamp(22px, 6vw, 88px);
  font: 16px/1.55 'Instrument Sans', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: #fff; }
[hidden] { display: none !important; }
h1, h2, h3, p, blockquote { margin: 0; }
a { color: inherit; text-underline-offset: 3px; }
button, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .64; }
:focus-visible { outline: 2px solid #555; outline-offset: 4px; }
.sr-only {
  position: absolute; clip-path: inset(50%); width: 1px; height: 1px;
  overflow: hidden; white-space: nowrap;
}

.thread {
  width: min(100% - 2 * var(--gutter), 72rem);
  margin-inline: auto;
  padding-block: clamp(70px, 13vh, 152px) 80px;
}
.thread:not(.has-turns) {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 19rem);
  grid-template-areas: 'intro examples' 'ask examples' 'status examples';
  column-gap: clamp(44px, 9vw, 135px);
  align-items: start;
}
.thread.has-turns {
  --source-column: clamp(15rem, 24vw, 19rem);
  --reading-gap: clamp(38px, 8vw, 120px);
  padding-top: clamp(28px, 6vh, 65px);
}
.thread.has-turns .composer { width: calc(100% - var(--source-column) - var(--reading-gap)); }
.intro { grid-area: intro; margin-bottom: clamp(27px, 4.8vh, 52px); }
.intro h1 {
  font: 400 clamp(3.75rem, 8.3vw, 7.75rem) / .9 var(--serif);
  letter-spacing: -.034em;
}
.intro h1 span { display: block; font-style: italic; }
.intro p { max-width: 36ch; margin-top: 22px; color: var(--muted); font-size: .96rem; }
.intro .archive-context { max-width: 44ch; margin-top: 12px; font-size: .78rem; line-height: 1.65; }
.archive-context a { text-decoration-color: #c6c6c6; }
.archive-context a:hover { color: var(--ink); text-decoration-color: currentColor; }
.composer {
  grid-area: ask;
  border: 1px solid #f1f1f1;
  border-radius: 42px;
  background: #fff;
  box-shadow: 0 9px 32px rgb(0 0 0 / .04);
  padding: 16px 22px 9px;
  transition: border-color 180ms, box-shadow 180ms;
}
.composer:hover { border-color: #e4e4e4; }
.composer:focus-within { border-color: #949494; box-shadow: 0 9px 32px rgb(0 0 0 / .06); }
.composer textarea {
  display: block; width: 100%; resize: none; field-sizing: content;
  min-height: 3rem; max-height: 14rem; padding: 5px 4px 0;
  border: 0; background: transparent; outline: 0; font-size: 1rem;
}
.composer textarea::placeholder { color: var(--faint); opacity: 1; }
.composer-actions { display: flex; align-items: center; justify-content: flex-end; gap: 12px; }
.submit {
  min-height: 44px;
  border: 0; border-radius: 999px; background: transparent;
  padding: 5px 7px 5px 12px; color: var(--muted); font-size: .81rem; font-weight: 600;
}
.submit:hover:enabled { color: var(--ink); text-decoration: underline; }
.text-button {
  border: 0; min-height: 44px; padding: 5px 7px; background: transparent; color: var(--muted);
  font-size: .81rem;
}
.text-button:hover { text-decoration: underline; }
.examples {
  grid-area: examples;
  display: grid;
  justify-items: start;
  gap: 13px;
  padding-top: clamp(64px, 10vh, 110px);
}
.examples-label { color: var(--muted); font-size: .75rem; margin-bottom: 2px; }
.examples button, .follow-ups button {
  min-height: 44px; padding: 4px 0;
  border: 0; background: transparent; text-align: left;
  color: var(--faint); font: italic 400 clamp(1.25rem, 2vw, 1.6rem) / 1.16 var(--serif);
  text-wrap: pretty;
  transition: color 180ms;
}
.examples button {
  color: #383838;
  text-decoration: underline;
  text-decoration-color: #999;
  text-decoration-thickness: 1px;
  text-underline-offset: .17em;
}
.examples button:hover, .examples button:focus-visible, .follow-ups button:hover, .follow-ups button:focus-visible {
  color: var(--ink); text-decoration: underline; text-decoration-thickness: 1px;
  text-underline-offset: .18em;
}
.follow-up-jump {
  min-height: 44px;
  margin-top: 12px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-size: .82rem;
  text-decoration: underline;
  text-underline-offset: .18em;
}
.follow-ups {
  display: grid;
  justify-items: start;
  gap: 3px;
  margin-top: clamp(29px, 5vw, 56px);
  scroll-margin-top: 24px;
}
.follow-ups h3 {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: .78rem;
  font-weight: 600;
}
.follow-ups button { font-size: clamp(1.2rem, 2.05vw, 1.42rem); text-decoration: underline; text-decoration-color: #cdcdcd; text-underline-offset: .17em; }
.status { grid-area: status; margin: 10px 24px 0; color: var(--muted); font-size: .83rem; }
.status:empty { display: none; }

.search-wait {
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 20px;
  border: 0;
  background: transparent;
  color: var(--muted);
  opacity: 1;
  transition: opacity 1400ms ease-out;
}
.search-wait[open] { display: grid; place-items: center; }
.search-wait::backdrop {
  background: rgb(255 255 255 / .83);
  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
  opacity: 1;
  transition: opacity 1400ms ease-out, backdrop-filter 1400ms ease-out;
}
.search-wait.is-leaving, .search-wait.is-leaving::backdrop { opacity: 0; }
.search-wait.is-leaving::backdrop { backdrop-filter: blur(0); -webkit-backdrop-filter: blur(0); }
body:has(.search-wait[open]) { overflow: hidden; }
.search-wait-content { text-align: center; }
.loading-compass {
  position: relative;
  width: clamp(142px, 22vw, 184px);
  aspect-ratio: 1;
  margin-inline: auto;
}
.loading-compass canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.compass-needle { transform-origin: 50% 53.055556%; }
.search-wait p { margin-top: 9px; font: italic 400 1.4rem/1.3 var(--serif); }

.turn { margin-bottom: clamp(36px, 7vh, 80px); }
.turn + .turn { padding-top: 32px; border-top: 1px solid var(--line); }
.turn h2 {
  max-width: 26ch;
  font: 400 clamp(2.55rem, 5.2vw, 4.5rem) / .98 var(--serif);
  letter-spacing: -.023em;
  text-wrap: balance;
  scroll-margin-top: 26px;
}
.turn h2[tabindex="-1"]:focus { outline: none; }
.answer { margin-top: clamp(30px, 5.5vw, 66px); }
.campaign-answer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--source-column);
  column-gap: var(--reading-gap);
  align-items: start;
}
.campaign-answer + .campaign-answer {
  margin-top: clamp(34px, 6vw, 70px);
  padding-top: clamp(26px, 4vw, 48px);
  border-top: 1px solid var(--line);
}
.campaign-copy h3 {
  margin-bottom: 11px;
  color: var(--muted);
  font-size: .84rem;
  font-weight: 600;
}
.campaign-lead {
  max-width: 35ch;
  font: 400 clamp(1.85rem, 2.85vw, 2.45rem) / 1.17 var(--serif);
  text-wrap: pretty;
  letter-spacing: -.01em;
}
.campaign-lead strong { font-weight: 700; }
.campaign-issue {
  max-width: 64ch;
  margin-top: 18px;
  color: var(--muted);
  font-size: .94rem;
}
.timeline {
  display: grid;
  gap: 21px;
  max-width: 42rem;
  margin: 30px 0 0;
  padding: 0;
  list-style: none;
}
.timeline li {
  display: grid;
  grid-template-columns: 6rem minmax(0, 1fr);
  gap: 12px;
  align-items: baseline;
}
.timeline time { color: var(--faint); font-size: .76rem; font-variant-numeric: tabular-nums; }
.timeline p { font: 400 clamp(1.2rem, 1.75vw, 1.42rem) / 1.32 var(--serif); }
.campaign-archive {
  display: inline-block;
  margin-top: 21px;
  color: var(--muted);
  font-size: .82rem;
}
.citation {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  min-height: 1.15rem;
  padding-inline: 3px;
  margin-left: .14em;
  color: var(--muted);
  vertical-align: .5em;
  text-decoration: none;
  font: 600 .65rem/1 'Instrument Sans', system-ui, sans-serif;
}
.citation:hover, .citation:focus-visible { color: var(--ink); text-decoration: underline; }
.fragments { padding-top: 2px; overflow-wrap: anywhere; }
.fragments h4 {
  margin: 0 0 10px;
  color: var(--faint);
  font-size: .75rem;
  font-weight: 600;
}
.fragment { padding: 12px 0 13px; border-top: 1px solid var(--line); }
.fragment-meta { color: var(--faint); font-size: .72rem; line-height: 1.4; }
.fragment-index { margin-right: 5px; color: var(--ink); font-weight: 700; }
.fragment-title {
  display: inline-block;
  margin: 3px 0;
  color: var(--ink);
  font: 400 1.23rem/1.16 var(--serif);
  text-decoration: none;
}
.fragment-title span { color: var(--faint); font: .7rem 'Instrument Sans', system-ui, sans-serif; }
.fragment-title:hover, .fragment-title:focus-visible { text-decoration: underline; }
.fragment-action { margin: 3px 0 5px; color: var(--muted); font-size: .76rem; line-height: 1.45; }
.fragment-passage { padding-top: 5px; scroll-margin-top: 24px; }
.fragment-passage:target, .fragment-passage:focus { outline: 1px solid #979797; outline-offset: 4px; }
.fragment-label { margin-bottom: 2px; }
.fragment-text { color: #404040; font-size: .8rem; line-height: 1.48; }
blockquote.fragment-text { font: italic 400 1.08rem/1.25 var(--serif); }
@media (max-width: 780px) {
  .thread:not(.has-turns) {
    display: block;
    max-width: 34rem;
  }
  .thread.has-turns { max-width: 38rem; }
  .thread.has-turns .composer { width: 100%; }
  .campaign-answer { display: block; }
  .fragments { margin: 27px 0 0 clamp(16px, 5vw, 36px); }
  .examples { margin: clamp(20px, 3vh, 30px) 0 0 clamp(16px, 5vw, 36px); padding-top: 0; }
}
@media (max-width: 550px) {
  .thread { padding: clamp(54px, 12vh, 105px) 0 56px; }
  .thread.has-turns { padding-top: 27px; }
  .intro h1 { font-size: clamp(3.4rem, 14vw, 5.3rem); }
  .intro p { margin-top: 17px; }
  .composer { border-radius: 34px; padding: 12px 15px 5px; }
  .timeline { gap: 16px; margin-top: 24px; }
  .timeline li { grid-template-columns: minmax(0, 1fr); gap: 2px; }
}
@media (prefers-reduced-motion: reduce) {
  .composer, .examples button, .follow-ups button { transition: none; }
  .search-wait, .search-wait::backdrop { transition: none; }
}
@media (forced-colors: active) {
  .composer { border-color: ButtonBorder; }
  .composer:focus-within { border-color: Highlight; }
}

.poderosa-stamp {
  position: fixed;
  right: max(28px, calc(env(safe-area-inset-right) + 16px));
  bottom: max(24px, calc(env(safe-area-inset-bottom) + 12px));
  z-index: 9;
  display: block;
  width: 56px;
  line-height: 0;
  text-decoration: none;
  transform: rotate(-4deg);
  filter: drop-shadow(0 2px 3px #422c3c20);
  transition: transform 250ms, filter 250ms;
}
.poderosa-stamp svg { display: block; width: 100%; height: auto; overflow: visible; }
.poderosa-stamp-wink { display: none; }
.poderosa-stamp:hover { transform: translateY(-2px) rotate(0); filter: drop-shadow(0 4px 5px #422c3c30); }
.poderosa-stamp:focus-visible { outline: 3px solid #b34720; outline-offset: 5px; border-radius: 50%; }
@media (max-width: 550px) {
  .poderosa-stamp { width: 44px; right: max(14px, calc(env(safe-area-inset-right) + 8px)); bottom: max(8px, env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) { .poderosa-stamp { transition: none; } }
