/* ──────────────────────────────────────────────────────────
   Vist · homepage (loads after site.css)
   ────────────────────────────────────────────────────────── */
/* ── hero ──────────────────────────────────────────── */
.hero { padding: clamp(48px, 8vw, 112px) 0 clamp(56px, 8vw, 104px); }
.hero-head { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: clamp(24px, 5vw, 72px); align-items: end; }
.hero h1 {
  font-size: clamp(2.7rem, 6vw, 5rem);
  line-height: .98;
  letter-spacing: -0.03em;
  font-weight: 500;
}
.hero h1 .second { display: block; }
.hero-side { display: grid; grid-template-columns: minmax(0, 1fr); min-width: 0; gap: 22px; padding-bottom: 8px; }
.hero-sub { font-size: clamp(18px, 1.5vw, 20px); color: var(--ink-2); max-width: 36em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.hero-fine { font-family: var(--sans); font-size: 14px; color: var(--ink-3); }

/* the same note, two readers */
.readers {
  margin-top: clamp(40px, 6vw, 72px);
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  border: 1.5px solid var(--ink);
  box-shadow: 0 14px 18px -12px rgba(22,23,26,.4);
  background: var(--paper-2);
}
.reader { display: grid; grid-template-rows: auto 1fr; min-width: 0; }
.reader-bar {
  display: flex; justify-content: space-between; gap: 12px;
  font-family: var(--sans); font-size: 13px; font-weight: 600;
  padding: 10px 18px; border-bottom: 1px solid var(--rule); color: var(--ink-3);
}
.reader-bar strong { color: var(--ink); font-weight: 700; }
.sheet { padding: clamp(22px, 3.5vw, 44px) clamp(20px, 4vw, 52px) clamp(26px, 4vw, 48px); }
.sheet h2.note-title { font-size: clamp(1.6rem, 2.6vw, 2.1rem); letter-spacing: -0.015em; line-height: 1.15; margin-bottom: 10px; }
.note-labels { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; font-family: var(--sans); font-size: 13px; }
.note-labels span { padding: 2px 8px; border: 1px solid var(--rule); border-radius: 999px; color: var(--ink-2); }
.sheet p { font-size: 18px; margin-bottom: 16px; }
.wikilink { border-bottom: 1.5px solid var(--ink); text-decoration: none; }
.wikilink::before { content: "[["; color: var(--ink-3); }
.wikilink::after  { content: "]]"; color: var(--ink-3); }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; font-size: 18px; }
.checks li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; align-items: baseline; }
.checks .box {
  position: relative; appearance: none; padding: 0; cursor: pointer;
  width: 16px; height: 16px; border: 1.5px solid var(--ink); border-radius: 3px; transform: translateY(2px);
  background: transparent; box-shadow: inset 0 0 0 8px var(--paper-2);
  transition: box-shadow .22s var(--ease-out), background-color .22s var(--ease-out);
}
.checks .box::after { content: ""; position: absolute; inset: -12px; } /* a finger-sized target */
.checks .box:hover { background: var(--mark); box-shadow: inset 0 0 0 3px var(--paper-2); }
.checks .done .box { background: var(--ink); box-shadow: inset 0 0 0 3px var(--paper-2); }
.checks .txt { transition: color .22s var(--ease-out); }
.checks .done .txt { color: var(--ink-3); text-decoration: line-through; text-decoration-thickness: 1px; }
.checks .due { font-family: var(--sans); font-size: 13px; color: var(--ink-3); margin-left: 6px; white-space: nowrap; }

.reader-term { background: var(--term); color: var(--term-text); }
.reader-term .reader-bar { border-bottom-color: var(--term-rule); color: var(--term-dim); }
.reader-term .reader-bar strong { color: var(--term-text); }
.tty {
  font-family: var(--mono); font-size: 14px; line-height: 1.7;
  padding: clamp(20px, 3vw, 32px) clamp(18px, 3vw, 30px);
  margin: 0; white-space: pre-wrap; word-break: break-word;
}
.tty .ps { color: var(--mark); }
.tty .cmd { color: var(--term-text); }
.tty .out { color: var(--term-dim); display: block; }
.tty .gap { display: block; height: .9em; }
.tty .task-line { display: block; max-height: 1.7em; overflow: hidden; transition: max-height .4s var(--ease-out), opacity .3s var(--ease-out); }
.tty .task-line.is-gone { max-height: 0; opacity: 0; }
.tty .cursor { display: inline-block; width: .6em; height: 1.1em; background: var(--term-text); vertical-align: -.2em; }

/* linked lines — the signature interaction */
[data-pair] { transition: background-color .25s var(--ease-out), color .25s var(--ease-out); border-radius: 2px; cursor: default; }
.sheet [data-pair].is-lit { background: var(--mark); color: var(--mark-ink); box-shadow: 0 0 0 4px var(--mark); }
.tty [data-pair].is-lit { background: var(--mark); color: var(--mark-ink); }
.readers-caption {
  display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 1fr);
  font-family: var(--sans); font-size: 14px; color: var(--ink-3); margin-top: 12px;
}
.readers-caption p + p { padding-left: 18px; }

/* the Obsidian contrast line */
.contrast {
  margin-top: clamp(28px, 4vw, 44px);
  display: flex; flex-wrap: wrap; gap: 8px 28px; align-items: baseline;
  font-family: var(--sans); font-size: 16px; color: var(--ink-2);
  border-top: 1px solid var(--rule); padding-top: 18px;
}
.contrast strong { color: var(--ink); font-weight: 700; }
.contrast span { white-space: nowrap; }
.contrast span::before { content: "–"; margin-right: 8px; color: var(--ink-3); }

/* ── voices ────────────────────────────────────────── */
.voices { background: var(--paper-2); border-top: 1.5px solid var(--ink); border-bottom: 1.5px solid var(--ink); }
.voices-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); }
.voice { padding: clamp(28px, 4vw, 48px) clamp(20px, 3vw, 40px); display: flex; flex-direction: column; justify-content: space-between; gap: 22px; }
.voice { margin: 0; }
.voice.lead { padding-left: 0; }
.voice + .voice { border-left: 1px solid var(--rule); }
.demo-cap { font-family: var(--sans); font-size: 13px; color: var(--ink-3); margin-top: 12px; }
.t-term .demo-cap { color: var(--term-dim); }
.memnote .demo-cap { margin: 10px 0 0; font-size: 12.5px; }
.voice blockquote { margin: 0; font-size: 20px; line-height: 1.45; }
.voice.lead blockquote { font-size: clamp(22px, 2.2vw, 28px); line-height: 1.3; letter-spacing: -0.01em; }
.voice figcaption { font-family: var(--sans); font-size: 14px; color: var(--ink-3); line-height: 1.45; }
.voice figcaption strong { color: var(--ink); display: block; font-weight: 700; }

/* ── chapter heads ─────────────────────────────────── */
.chapter { padding: var(--section-y) 0; }
.chapter-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(20px, 5vw, 72px); align-items: end; margin-bottom: clamp(44px, 6vw, 80px); }
.chapter-head h2 { font-size: clamp(2.4rem, 5.2vw, 4.4rem); line-height: 1; letter-spacing: -0.028em; }
.chapter-head p { font-size: 20px; color: var(--ink-2); max-width: 30em; }

/* writing chapter */
.w-row { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 80px); align-items: start; padding: clamp(40px, 5vw, 64px) 0; border-top: 1px solid var(--rule); }
.w-row.flip { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }
.w-row.flip .w-copy { order: 2; }
.w-copy h3 { font-size: clamp(1.7rem, 2.8vw, 2.4rem); line-height: 1.1; letter-spacing: -0.02em; margin-bottom: 18px; }
.w-copy p { color: var(--ink-2); margin-bottom: 16px; max-width: 34em; }
.more { font-family: var(--sans); font-size: 15px; font-weight: 700; }
.w-row-full { grid-template-columns: 1fr; }
.chapter-tight { padding-top: 0; padding-bottom: clamp(48px, 6vw, 80px); }
.t-term p code { font-family: var(--mono); font-size: .85em; color: #fff; background: var(--term-2); border: 1px solid var(--term-rule); border-radius: 4px; padding: .05em .35em; }
.modes { list-style: none; padding: 0; margin: 22px 0 22px; display: grid; border-top: 1px solid var(--rule); font-family: var(--sans); font-size: 16px; }
.modes li { display: grid; grid-template-columns: 7.5em 1fr auto; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.modes li b { font-weight: 700; }
.modes li span { color: var(--ink-3); }

.shot { margin: 0; }
.shot img { border: 1.5px solid var(--ink); background: #fff; }
.shot figcaption { font-family: var(--sans); font-size: 14px; color: var(--ink-3); padding-top: 10px; }
.shot img { width: 100%; }

/* handwriting */
.hand { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); border: 1.5px solid var(--ink); background: var(--paper-2); }
.hand-slot {
  aspect-ratio: 3 / 4; border-right: 1px solid var(--rule);
  background-color: #efefeb;
  background-image: repeating-linear-gradient(transparent 0 33px, #d4d6cf 33px 34px);
  display: grid; place-items: end start; padding: 16px;
  font-family: var(--sans); font-size: 13px; color: var(--ink-3);
}
.hand-note { padding: 22px 22px 26px; }
.hand-note h4 { font-family: var(--serif); font-weight: 500; font-size: 22px; margin: 0 0 6px; }
.hand-note .meta { font-family: var(--sans); font-size: 13px; color: var(--ink-3); margin-bottom: 14px; }
.hand-note p { font-size: 16px; margin-bottom: 10px; }
.ocr { border: 1px solid var(--rule); font-family: var(--sans); font-size: 14px; margin-top: 16px; }
.ocr summary { padding: 9px 12px; cursor: pointer; font-weight: 700; }
.ocr p { padding: 0 12px 12px; font-family: var(--serif); font-size: 15px; color: var(--ink-2); margin: 0; }

/* shortcut sheet — dense, ruled */
.keys { border: 1.5px solid var(--ink); background: var(--paper-2); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.keys section { padding: 18px 20px 20px; min-width: 0; }
.keys section + section { border-left: 1px solid var(--rule); }
.keys h4 { font-family: var(--sans); font-size: 14px; font-weight: 700; margin: 0 0 10px; color: var(--ink); }
.keys dl { margin: 0; display: grid; grid-template-columns: 1fr auto; font-family: var(--sans); font-size: 15px; }
.keys dt, .keys dd { padding: 7px 0; border-top: 1px solid var(--rule); margin: 0; }
.keys dd { text-align: right; white-space: nowrap; }
.keys dd .then { font-size: 12px; color: var(--ink-3); margin: 0 4px; }
.keys dt, .keys dd { transition: background-color .12s var(--ease-out), box-shadow .12s var(--ease-out); }
.keys dt.is-cursor { background: var(--mark); box-shadow: -8px 0 0 var(--mark); }
.keys dd.is-cursor { background: var(--mark); box-shadow: 8px 0 0 var(--mark); }
.keys dd.is-cursor .then { color: var(--ink); }
.keys-try { display: none; }
@media (hover: hover) and (pointer: fine) { .js .keys-try { display: inline; } }

/* ── the line ──────────────────────────────────────── */
.line-sec { background: var(--mark); color: var(--ink); padding: var(--section-y) 0; border-top: 1.5px solid var(--ink); }
.line-sec h2 { font-size: clamp(2.5rem, 7vw, 6rem); line-height: 1; letter-spacing: -0.035em; font-weight: 500; }
.line-sec h2 .dim { color: #5c5520; }
.line-sec h2 mark { background: var(--ink); color: var(--mark); padding: 0 .1em; }
.proofs { margin-top: clamp(40px, 6vw, 72px); display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1.5px solid var(--ink); }
.proofs > div { padding: 24px clamp(0px, 2vw, 28px) 0 0; }
.proofs > div + div { padding-left: clamp(16px, 2vw, 28px); border-left: 1px solid rgba(22,23,26,.35); }
.proofs h3 { font-size: 26px; margin-bottom: 10px; }
.proofs p { font-size: 17px; color: #3a3713; }

/* ── agents chapter (terminal) ─────────────────────── */
.t-term { background: var(--term); color: var(--term-text); font-family: var(--sans); font-size: 18px; }
.t-term .chapter-head h2 { font-family: var(--serif); }
.t-term .chapter-head p { color: var(--term-dim); }
.a-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--term-rule); }
.a-cell { padding: clamp(28px, 4vw, 48px) clamp(0px, 3vw, 44px) clamp(28px, 4vw, 48px) 0; border-bottom: 1px solid var(--term-rule); min-width: 0; }
.a-cell:nth-child(2n) { padding-left: clamp(20px, 3vw, 44px); padding-right: 0; border-left: 1px solid var(--term-rule); }
.a-cell h3 { font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1.15; letter-spacing: -0.015em; margin-bottom: 14px; color: #fff; }
.a-cell p { color: var(--term-dim); margin-bottom: 18px; max-width: 34em; }
.a-cell .more { font-size: 15px; font-weight: 700; color: var(--term-text); }
.snip { background: var(--term-2); border: 1px solid var(--term-rule); border-radius: 6px; font-family: var(--mono); font-size: 13.5px; line-height: 1.7; padding: 14px 16px; margin: 0 0 18px; overflow-x: auto; white-space: pre; color: var(--term-text); }
.snip .ps { color: var(--mark); }
.snip .c { color: var(--term-dim); }
.clients { list-style: none; padding: 0; margin: 0 0 18px; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 15px; color: var(--term-text); }
.clients li::before { content: "·"; color: var(--mark); margin-right: 8px; }
.wiki-flow { list-style: none; margin: 0 0 18px; padding: 0; border: 1px solid var(--term-rule); border-radius: 6px; font-size: 15px; }
.wiki-flow li { display: grid; grid-template-columns: 5.5em 1fr; gap: 12px; padding: 10px 14px; }
.wiki-flow li + li { border-top: 1px solid var(--term-rule); }
.wiki-flow b { font-weight: 700; color: var(--mark); }
.wiki-flow span { color: var(--term-text); }
.memnote { background: var(--paper-2); color: var(--ink); border-radius: 2px; padding: 18px 20px; margin-bottom: 18px; font-family: var(--serif); }
.memnote .meta { font-family: var(--sans); font-size: 12.5px; color: var(--ink-3); margin-bottom: 6px; }
.memnote h4 { font-weight: 500; font-size: 20px; margin: 0 0 8px; }
.memnote p { font-size: 16px; color: var(--ink-2); margin: 0 0 6px; }
.memnote p b { font-family: var(--sans); font-size: 13px; color: var(--ink); margin-right: 6px; }
.a-quote { margin: 0; padding: clamp(28px, 4vw, 48px) 0 0; display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 24px; align-items: end; }
.a-quote blockquote { margin: 0; font-family: var(--serif); font-size: clamp(22px, 2.4vw, 30px); line-height: 1.3; color: #fff; letter-spacing: -0.01em; }
.a-quote figcaption { font-size: 14px; color: var(--term-dim); }
.a-quote figcaption strong { display: block; color: var(--term-text); }

/* ── house rules ───────────────────────────────────── */
.rules-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.rules-grid h2 { font-size: clamp(2.2rem, 4.4vw, 3.8rem); line-height: 1.02; letter-spacing: -0.028em; margin-bottom: 20px; }
.rules-grid .intro p { color: var(--ink-2); margin-bottom: 18px; max-width: 26em; }
.rules { margin: 0; border: 1.5px solid var(--ink); background: var(--paper-2); font-family: var(--sans); font-size: 16px; }
.rules div { display: grid; grid-template-columns: 9.5em 1fr; gap: 16px; padding: 14px 18px; }
.rules div + div { border-top: 1px solid var(--rule); }
.rules dt { font-weight: 700; }
.rules dd { margin: 0; color: var(--ink-2); }

/* ── pricing teaser ────────────────────────────────── */
.pricing-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; flex-wrap: wrap; margin-bottom: 36px; }
.pricing-head h2 { font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1.05; letter-spacing: -0.025em; max-width: 18em; }
.tiers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border: 1.5px solid var(--ink); background: var(--paper-2); }
.tier { padding: 26px 24px 28px; font-family: var(--sans); }
.tier + .tier { border-left: 1px solid var(--rule); }
.tier.featured { background: var(--mark); }
.tier-name { font-size: 15px; font-weight: 700; }
.tier-price { font-family: var(--serif); font-size: 52px; line-height: 1; letter-spacing: -0.03em; margin: 12px 0 4px; }
.tier-price small { font-family: var(--sans); font-size: 15px; letter-spacing: 0; color: var(--ink-3); margin-left: 4px; }
.tier.featured .tier-price small, .tier.featured .tier-desc { color: var(--ink); }
.tier-desc { font-size: 15px; color: var(--ink-2); margin-bottom: 16px; }
.tier ul { list-style: none; padding: 0; margin: 0; font-size: 15px; display: grid; gap: 6px; }
.tier li { display: grid; grid-template-columns: 16px 1fr; gap: 8px; }
.tier li::before { content: ""; width: 10px; height: 2px; background: var(--ink); margin-top: .7em; }

/* ── close ─────────────────────────────────────────── */
.close { padding: var(--section-y) 0 clamp(56px, 7vw, 96px); border-top: 1.5px solid var(--ink); }
.close h2 { font-size: clamp(2.6rem, 6.4vw, 5.4rem); line-height: 1; letter-spacing: -0.032em; max-width: 12em; }
.close h2 .second { display: block; }
.close-row { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; }
.platforms { margin-top: clamp(48px, 6vw, 72px); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--rule); font-family: var(--sans); font-size: 15px; }
.platforms > div { padding: 16px 16px 0 0; }
.platforms > div + div { padding-left: 16px; border-left: 1px solid var(--rule); }
.platforms b { display: block; font-size: 16px; margin-bottom: 2px; }
.platforms span { color: var(--ink-3); display: block; margin-bottom: 8px; }
.platforms a { font-weight: 700; }

/* ── motion ────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .tty .task-line, .checks .box, .keys dt, .keys dd { transition: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .js .tty [data-step] { opacity: 0; transform: translateY(4px); transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
  .js .tty [data-step].is-in { opacity: 1; transform: none; }
  .checks .box:active { transform: translateY(2px) scale(.88); }
}

/* ── responsive ────────────────────────────────────── */
@media (max-width: 1020px) {
  .hero-head, .chapter-head, .rules-grid { grid-template-columns: minmax(0, 1fr); align-items: start; }
  .w-row, .w-row.flip { grid-template-columns: 1fr; }
  .w-row.flip .w-copy { order: 0; }
  .keys { grid-template-columns: 1fr 1fr; }
  .keys section:nth-child(3) { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--rule); }
}
@media (max-width: 760px) {
  .readers, .readers-caption { grid-template-columns: 1fr; }
  .readers-caption p + p { display: none; }
  .reader-term { border-top: 1.5px solid var(--ink); }
  .voices-grid { grid-template-columns: 1fr; }
  .voice { padding-left: 0; padding-right: 0; }
  .voice + .voice { border-left: 0; border-top: 1px solid var(--rule); }
  .tty { white-space: pre; overflow-x: auto; font-size: 12.5px; }
  .keys { grid-template-columns: 1fr; }
  .keys section + section { border-left: 0; border-top: 1px solid var(--rule); }
  .hand { grid-template-columns: 1fr; }
  .hand-slot { aspect-ratio: 4 / 3; border-right: 0; border-bottom: 1px solid var(--rule); }
  .proofs { grid-template-columns: 1fr; }
  .proofs > div + div { padding-left: 0; border-left: 0; border-top: 1px solid rgba(22,23,26,.35); margin-top: 24px; }
  .a-grid { grid-template-columns: 1fr; }
  .a-cell, .a-cell:nth-child(2n) { padding-left: 0; padding-right: 0; border-left: 0; }
  .a-quote { grid-template-columns: 1fr; }
  .rules div { grid-template-columns: 1fr; gap: 2px; }
  .tiers { grid-template-columns: 1fr; }
  .tier + .tier { border-left: 0; border-top: 1px solid var(--rule); }
  .platforms { grid-template-columns: 1fr 1fr; }
  .platforms > div:nth-child(3) { border-left: 0; padding-left: 0; }
  .platforms > div { padding-bottom: 16px; }
  .modes li { grid-template-columns: minmax(0, 1fr) auto; row-gap: 2px; }
  .modes li span { grid-column: 1 / -1; grid-row: 2; }
  .modes li kbd { grid-column: 2; grid-row: 1; }
  .contrast span { white-space: normal; }
}
