/* v2-archive (MARK 45) — Archive page, source pages, fragment page. Black intro, cream rest, soft lifts. */
.v2a { --v2a-pad: clamp(64px, 10vw, 140px); --v2a-lift: 0 10px 24px -12px rgba(0,0,0,.25); background: var(--cream); color: var(--ink); }
.v2a h2, .v2a h1 { color: var(--ink); }
.v2a .kicker { color: var(--muted); }
.v2a .hand-accent { font-family: "Cedarville Cursive", cursive; font-weight: 400; font-size: 1.18em; color: var(--orange); display: inline-block; transform: rotate(-3deg); letter-spacing: 0; line-height: 1; }
.v2a-sec { padding: var(--v2a-pad) 0; }
.v2a-sec + .v2a-sec { padding-top: 0; border-top: 0; }
.v2a-sechead { margin-bottom: clamp(28px, 4vw, 48px); max-width: 640px; }
.v2a-sechead h2 { margin: 0 0 12px; }
.v2a-sub { margin: 0; font-size: 17px; line-height: 1.5; color: var(--muted); max-width: 46ch; }

/* ---------- black header (ported homepage panel) ---------- */
.v2a-head.panel { padding: clamp(56px, 8vw, 112px) 0 clamp(64px, 9vw, 120px); background-color: var(--black); }
.v2a-head .panel-title { color: var(--cream); }
.v2a-head .lede { color: rgba(241,236,226,.78); max-width: 40ch; }
.v2a-head .btn-outline-light { border-radius: 999px; }
.v2a-head .btn-outline-light:hover { translate: 0 -2px; box-shadow: 0 10px 24px -12px rgba(0,0,0,.6); }
.v2a-head .stack-card.is-frag { cursor: pointer; }
.v2a-head .stack-card.top.is-frag::after { content: "Open →"; position: absolute; right: 10px; bottom: -26px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; color: rgba(241,236,226,.6); }
.v2a-head .stack-card { touch-action: pan-y; }
.v2a-head .stack-card .sc-inner { border-radius: 2px; }
.v2a-head .stack-card.letter .sc-inner { max-height: 300px; overflow: hidden; }
.v2a-head .stack-ctrl { justify-content: flex-end; }
@media (max-width: 899px) { .v2a-head .panel-grid { gap: 40px; } }
@media (max-width: 600px) {
  .v2a-head .stack { height: 340px; }
  .v2a-head .stack-card { left: 20%; width: 60%; }
  .v2a-head .stack-card.letter .sc-inner, .v2a-head .stack-card.notebook .sc-inner { min-height: 200px; max-height: 250px; padding: 18px 16px; }
  .v2a-head .stack-card.notebook .sc-inner { padding-left: 36px; }
  .v2a-head .typed, .v2a-head .hand { font-size: 13px; line-height: 21px; }
  .v2a-head .index-card { top: 62%; left: 6%; min-width: 96px; font-size: 20px; padding: 22px 12px 14px; }
  .v2a-head .stack-info { display: none; }
}

/* ---------- six-area stripes ---------- */
.v2a-areas { background: var(--cream); }
.v2a-stripes { border-radius: 14px; box-shadow: 0 24px 48px -30px rgba(0,0,0,.35);
  touch-action: pan-y; overscroll-behavior-x: contain; -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; }
.v2a-hint { margin: 14px 2px 0; color: var(--muted); opacity: .8; }
.v2a-stripe .s-label { font-size: clamp(32px, 3.6vw, 50px); max-width: 14ch; }
.v2a-stripe .s-q { max-width: 36ch; }
.v2a-stripe .s-btn-solid { border-radius: 999px; transition: translate 220ms ease-out, box-shadow 220ms ease-out; }
.v2a-stripe .s-btn-solid:hover { translate: 0 -2px; box-shadow: var(--v2a-lift); }
@media (max-width: 719px) {
  .v2a-stripe .s-spine { height: 60px; font-size: 12px; white-space: normal; line-height: 1.3; }
  .v2a-stripe .s-spine::after { content: "+"; margin-left: auto; font-size: 20px; font-family: var(--f-ui); transition: transform 300ms ease; }
  .v2a-stripe.open .s-spine::after { transform: rotate(45deg); }
}
@media (min-width: 720px) {
  .v2a-stripes { height: 460px; }
  .v2a-stripe .s-body { min-width: 340px; }
}
@media (min-width: 720px) and (max-width: 899px) { .v2a-stripe .s-body { min-width: 300px; padding: 24px 24px 24px 68px; } }

/* ---------- library tools ---------- */
.v2a-lib { background: var(--cream); }
.v2a-tools { display: flex; flex-direction: column; gap: 18px; margin-bottom: clamp(36px, 5vw, 56px); }
.v2a-search { display: flex; align-items: center; gap: 12px; max-width: 640px; padding: 0 20px; height: 58px; border-radius: 999px;
  background: #fff; box-shadow: 0 1px 0 rgba(0,0,0,.04), 0 10px 26px -18px rgba(0,0,0,.35); transition: box-shadow 220ms ease-out; }
.v2a-search:focus-within { box-shadow: 0 0 0 2px var(--ink), 0 10px 26px -18px rgba(0,0,0,.35); }
.v2a-search svg { width: 20px; height: 20px; flex: none; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.v2a-search input { flex: 1; min-width: 0; height: 100%; border: 0; outline: 0; background: transparent; color: var(--ink); font: 400 17px/1.2 var(--f-ui); letter-spacing: 0; padding: 0; box-shadow: none; }
.v2a-search input::placeholder { color: rgba(26,26,26,.45); }
.v2a-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.v2a-chip { --c: var(--ink); --ci: #fff; display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 7px 15px; border-radius: 999px;
  border: 1px solid rgba(26,26,26,.16); background: rgba(255,255,255,.6); color: var(--ink); font: 500 14px/1.2 var(--f-ui); cursor: pointer; text-decoration: none;
  transition: translate 220ms ease-out, box-shadow 220ms ease-out, background 200ms, color 200ms, border-color 200ms; }
.v2a-chip i { width: 10px; height: 10px; border-radius: 50%; background: var(--c); flex: none; }
.v2a-chip .n { font-family: var(--f-mono); font-size: 11px; opacity: .6; }
.v2a-chip:hover { translate: 0 -2px; box-shadow: var(--v2a-lift); color: var(--ink); }
.v2a-chip.on { background: var(--c); color: var(--ci); border-color: var(--c); }
.v2a-chip.all.on { background: var(--ink); color: var(--cream); }
.v2a-chip.on i { background: currentColor; opacity: .6; }
.v2a-chip.sm { min-height: 34px; padding: 5px 13px; font-size: 13px; }
.v2a-count { margin: 0; font-size: 14px; color: var(--muted); }
.v2a-count b { color: var(--ink); }
.v2a-clear { background: none; border: 0; padding: 0; font: inherit; color: var(--ink); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* ---------- fragment cards ---------- */
.v2a-grid { columns: 1; column-gap: clamp(24px, 3vw, 40px); }
@media (min-width: 620px) { .v2a-grid { columns: 2; } }
@media (min-width: 1000px) { .v2a-grid { columns: 3; } }
.v2a-card { break-inside: avoid; display: block; margin: 0 0 clamp(36px, 4vw, 52px); padding: 6px 4px 0; transition: translate 220ms ease-out; }
.v2a-card .strip { animation: none; }
.v2a-open { display: block; color: inherit; text-decoration: none; border-radius: 12px; }
.v2a-open:focus-visible { outline: 2px solid var(--ink); outline-offset: 6px; }
@media (hover: hover) and (pointer: fine) {
  .v2a-card:hover { translate: 0 -4px; }
  .v2a-card .strip:hover { transform: rotate(var(--rot)); }
  .v2a-card:hover .strip { filter: drop-shadow(0 14px 18px rgba(60,40,20,.26)) drop-shadow(0 1px 1px rgba(60,40,20,.2)); }
}
.v2a-card .strip.in-basket::after { content: "In your builder"; }
.v2a-acts { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; padding: 0 4px; }
.v2a-src { font: 500 14px/1.2 var(--f-ui); color: var(--ink); text-decoration: none; display: inline-flex; gap: 6px; align-items: center; padding: 8px 0; }
.v2a-src .arr { transition: transform 220ms ease-out; }
.v2a-src:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.v2a-src:hover .arr { transform: translateX(3px); }
.v2a-use { min-height: 40px; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--ink); background: var(--ink); color: var(--cream);
  font: 600 14px/1.2 var(--f-ui); cursor: pointer; transition: translate 220ms ease-out, box-shadow 220ms ease-out, background 200ms, color 200ms; }
.v2a-use:hover { translate: 0 -2px; box-shadow: var(--v2a-lift); background: #000; }
.v2a-use.on { background: var(--yellow); border-color: var(--yellow); color: var(--ink); }
.v2a-use.on:hover { background: var(--yellow); }
.v2a-empty { column-span: all; padding: 40px 0; text-align: left; }
.v2a-empty .serif { font-size: 32px; margin: 0 0 6px; }

/* ---------- toast with link ---------- */
.v2a-toast { position: fixed; left: 50%; bottom: 24px; z-index: 400; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px;
  max-width: calc(100vw - 32px); width: max-content; padding: 14px 20px; border-radius: 14px; background: var(--ink); color: var(--cream);
  font: 500 15px/1.35 var(--f-ui); box-shadow: 0 18px 36px -16px rgba(0,0,0,.55);
  opacity: 0; transform: translate(-50%, 16px); pointer-events: none; transition: opacity 220ms ease-out, transform 260ms ease-out; }
.v2a-toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.v2a-toast a { color: var(--yellow); font-weight: 600; text-decoration: none; white-space: nowrap; }
.v2a-toast a:hover { color: var(--yellow); text-decoration: underline; text-underline-offset: 3px; }
.v2a-tn { opacity: .6; font-size: 13px; }

/* ---------- source page ---------- */
.v2a-srchead { padding: clamp(48px, 8vw, 112px) 0 clamp(40px, 6vw, 72px); }
.v2a-crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-family: var(--f-mono); font-size: 12px; letter-spacing: .06em; color: var(--muted); margin-bottom: clamp(28px, 4vw, 48px); }
.v2a-crumbs a { color: var(--ink); text-decoration: none; }
.v2a-crumbs a:hover { text-decoration: underline; text-underline-offset: 3px; }
.v2a-h1 { font-size: clamp(38px, 6vw, 78px); line-height: 1; letter-spacing: -.03em; max-width: 18ch; margin: 0 0 16px; overflow-wrap: anywhere; }
.v2a-by { font-family: var(--f-display); font-style: italic; font-size: clamp(20px, 2.2vw, 26px); margin: 0 0 20px; }
.v2a-line { font-size: 17px; color: var(--muted); max-width: 52ch; margin: 0 0 32px; }
.v2a-dl { display: grid; grid-template-columns: 1fr; gap: 16px 40px; margin: 0 0 28px; max-width: 900px; }
@media (min-width: 720px) { .v2a-dl { grid-template-columns: 1fr 1fr; } }
.v2a-dl div { border-top: 1px solid rgba(26,26,26,.14); padding-top: 10px; }
.v2a-dl dt { font-family: var(--f-mono); font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.v2a-dl dd { margin: 0; font-size: 15px; line-height: 1.45; }
.v2a-areachips { display: flex; flex-wrap: wrap; gap: 8px; }
.v2a-source .v2a-sec { padding-top: 0; }
.v2a-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: clamp(32px, 5vw, 56px); }
.v2a-pager a { display: flex; flex-direction: column; gap: 6px; padding: 18px 20px; border-radius: 12px; background: rgba(255,255,255,.55); color: var(--ink); text-decoration: none; min-width: 0;
  transition: translate 220ms ease-out, box-shadow 220ms ease-out; }
.v2a-pager a.nx { text-align: right; }
.v2a-pager a:hover { translate: 0 -4px; box-shadow: var(--v2a-lift); color: var(--ink); }
.v2a-pager .meta { color: var(--muted); }
.v2a-pager .t { font-family: var(--f-display); font-size: 19px; line-height: 1.2; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.v2a-back { margin-top: 40px; }
.v2a-back .btn { border-radius: 999px; color: var(--ink); border-color: rgba(26,26,26,.3); }
.v2a-back .btn:hover { color: var(--ink); border-color: var(--ink); translate: 0 -2px; box-shadow: var(--v2a-lift); transform: none; }

/* ---------- fragment page ---------- */
.v2a-frag .v2a-sec { padding-top: clamp(40px, 6vw, 80px); }
.v2f-grid { display: grid; grid-template-columns: 1fr; gap: clamp(40px, 5vw, 72px); align-items: start; }
@media (min-width: 900px) { .v2f-grid { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); } }
.v2f-strip { max-width: 760px; }
.v2f-strip .strip { animation: none; }
.v2f-strip .strip.text { padding: clamp(28px, 4vw, 48px) clamp(24px, 4vw, 52px) clamp(22px, 3vw, 32px); }
.v2f-strip .strip-text { font-size: clamp(24px, 3vw, 36px); line-height: 1.3; }
.v2f-strip .strip.img .strip-meta { display: none; }
.v2f-strip .strip.text .strip-meta { margin-top: 14px; }
.v2f-text { margin: 28px 0 0; font-family: var(--f-display); font-size: clamp(22px, 2.6vw, 30px); line-height: 1.3; color: var(--ink); max-width: 34ch; }
.v2f-areas { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 28px; }
.v2f-side { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.v2f-side .kicker { margin-bottom: 4px; }
.v2f-use { border-radius: 999px; transition: translate 220ms ease-out, box-shadow 220ms ease-out, background 200ms; }
.v2f-use:hover { translate: 0 -2px; box-shadow: var(--v2a-lift); transform: none; }
.v2f-use.on, .v2f-use.on:hover { background: var(--yellow); color: var(--ink); border-color: var(--yellow); }
.v2f-builder { font-size: 14px; color: var(--ink); text-decoration: none; padding: 2px 0; }
.v2f-builder:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; }
.v2f-source { display: flex; flex-direction: column; gap: 6px; width: 100%; margin-top: 24px; padding: 22px 22px 16px; border-radius: 12px; background: rgba(255,255,255,.6); }
.v2f-source .meta { color: var(--muted); }
.v2f-stitle { font-family: var(--f-display); font-size: 24px; line-height: 1.15; color: var(--ink); text-decoration: none; }
.v2f-stitle:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
.v2f-sby { font-size: 14px; color: var(--muted); }
.v2f-ctx { font-size: 14px; line-height: 1.5; color: var(--muted); margin: 8px 0 0; }

@media (max-width: 600px) {
  .v2a-pager { grid-template-columns: 1fr; }
  .v2a-pager a.nx { text-align: left; }
  .v2a-acts { gap: 6px; }
}
@media (prefers-reduced-motion: reduce) {
  .v2a-card, .v2a-chip, .v2a-use, .v2a-pager a, .v2a-toast { transition: none; }
}

/* ---------- CCA library photo (replaces the placeholder exhibition-hall photo in the stack; same b/w photo-card treatment) ---------- */
.v2a-head .stack-card.lib img { aspect-ratio: 187 / 136; height: auto; object-fit: cover; object-position: 42% 55%; }
/* Reading library (#credits) head photo */
.page-credits .credits-lib { width: clamp(220px, 30vw, 320px); }
.page-credits .credits-lib img { display: block; width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 40% 50%; }

/* ---------- "Read the full article →" (only rendered when a source has a scan) ---------- */
.scan-link { appearance: none; border: 0; background: none; cursor: pointer; font: 500 14px/1.2 var(--f-ui); color: var(--ink); display: inline-flex; gap: 6px; align-items: center; padding: 8px 0; text-align: left; }
.scan-link .arr { transition: transform 220ms ease-out; }
.scan-link:hover { text-decoration: underline; text-underline-offset: 4px; }
.scan-link:hover .arr { transform: translateX(3px); }
.scan-link:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; border-radius: 2px; }
.book .scan-link.book-scan { margin-top: 6px; font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .1em; text-transform: uppercase; padding: 6px 0 0; }
.v2a-scan { margin: 22px 0 20px; }
.v2a-scan .scan-link { font-size: 15px; padding: 10px 18px; border: 1px solid var(--ink); border-radius: 999px; }
.v2a-scan .scan-link:hover { background: var(--ink); color: var(--cream); text-decoration: none; }
.v2f-source .scan-link { display: flex; }

/* ---------- full-screen scan reader ---------- */
.scan-reader { position: fixed; inset: 0; z-index: 400; display: flex; flex-direction: column; background: #121110; color: var(--cream); opacity: 0; transition: opacity .2s ease; }
.scan-reader.open { opacity: 1; }
.scan-reader .sr-bar { flex: none; display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: max(12px, env(safe-area-inset-top)) clamp(14px, 3vw, 32px) 12px; border-bottom: 1px solid rgba(241,236,226,.14); }
.scan-reader .sr-meta { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.scan-reader .sr-meta .meta { color: rgba(241,236,226,.6); font-family: var(--f-mono); font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; }
.scan-reader .sr-title { margin: 0; color: var(--cream); font-family: var(--f-display); font-weight: 400; font-size: clamp(20px, 2.6vw, 30px); line-height: 1.1; overflow-wrap: anywhere; }
.scan-reader .sr-by { font-size: 13px; color: rgba(241,236,226,.7); }
.scan-reader .sr-tools { flex: none; display: flex; align-items: center; gap: 12px; }
.scan-reader .sr-pdf { color: var(--cream); font: 500 13px/1 var(--f-ui); padding: 10px 14px; border: 1px solid rgba(241,236,226,.4); border-radius: 999px; text-decoration: none; }
.scan-reader .sr-pdf:hover { background: var(--cream); color: var(--ink); }
.scan-reader .sr-close { width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(241,236,226,.4); background: none; color: var(--cream); font-size: 26px; line-height: 1; cursor: pointer; }
.scan-reader .sr-close:hover { background: var(--cream); color: var(--ink); }
.scan-reader :focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }
.scan-reader .sr-scroll { flex: 1; overflow: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; padding: clamp(16px, 3vw, 40px) clamp(8px, 3vw, 32px) max(40px, env(safe-area-inset-bottom)); }
.scan-reader .sr-scroll:focus { outline: none; }
.scan-reader .sr-pages { display: flex; flex-direction: column; align-items: center; gap: clamp(16px, 3vw, 32px); }
.scan-reader .sr-page { margin: 0; width: 100%; max-width: 880px; cursor: zoom-in; }
.scan-reader .sr-page img { display: block; width: 100%; height: auto; background: #fff; box-shadow: 0 18px 40px -18px rgba(0,0,0,.8); }
.scan-reader .sr-page figcaption { margin-top: 8px; text-align: center; color: rgba(241,236,226,.55); font-family: var(--f-mono); font-size: 10px; letter-spacing: .12em; }
.scan-reader .sr-page.zoom { max-width: none; width: 200%; cursor: zoom-out; align-self: flex-start; }
@media (min-width: 1000px) { .scan-reader .sr-page.zoom { width: 160%; } }
.scan-reader .sr-wait { margin: 40px auto; color: rgba(241,236,226,.75); font-size: 15px; text-align: center; }
.scan-reader .sr-wait a { color: var(--cream); }
.scan-reader .sr-cite { max-width: 880px; margin: 28px auto 0; color: rgba(241,236,226,.6); font-size: 13px; line-height: 1.5; text-align: center; }
@media (prefers-reduced-motion: reduce) { .scan-reader { transition: none; } .scan-link .arr { transition: none; } }
