/* ARTVUE — black and blue.
 *
 * One ground: a neutral near-black, so the paintings carry all the warmth
 * on the page. Off-white type. One pigment: a cobalt blue, the colour of
 * the brush stroke in the logo, for the buy buttons, the "best value" flag
 * and the few words that need to stand out. There is no light mode.
 *
 * Deliberately flat. No gradients on anything you press, no rounded
 * pill shapes, no glow. Corners are square because frames are square.
 * What carries the identity is typography — a soft serif for names
 * against small tracked caps for labels — and the catalogue voice:
 * every collection numbered and labelled like a wall card.
 */

/* ───────────────────────────────────────────────────────────────────────
   Tokens
   ─────────────────────────────────────────────────────────────────────── */

:root {
  /* Near-black, neutral rather than warm: brown-black fights the blue. */
  --bg: #0E0F11;
  --bg-raised: #16181B;
  --bg-sunk: #08090A;
  --fg: #ECEAE5;          /* 16:1 on the ground */
  --fg-soft: #A3A6AB;     /* 7.9:1 */
  --fg-faint: #71757C;    /* 4.1:1 — small print only */
  --line: #24272B;
  --line-strong: #ECEAE5;

  /* Cobalt: the one pigment. White type on it is 4.8:1. */
  --accent: #1F6FE0;
  --accent-hover: #2B7BE8;
  --accent-ink: #FFFFFF;
  /* Blue as TEXT on black is lifted so it reads (7.3:1). */
  --accent-text: #5EA2F5;

  /* The solid (non-accent) button: off-white on black. */
  --solid: #ECEAE5;
  --solid-ink: #0E0F11;

  --focus: #5EA2F5;

  --gutter: 18px;
  --max: 1240px;
  --header-h: 64px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --serif: "Fraunces", "Iowan Old Style", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  color-scheme: dark;
}

/* ───────────────────────────────────────────────────────────────────────
   Base
   ─────────────────────────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
  scroll-padding-top: calc(var(--header-h) + 12px);
  background: var(--bg);
}
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease);
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }

:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--solid); color: var(--solid-ink); padding: 10px 16px;
}
.skip:focus { left: 8px; top: 8px; }

/* Images fade in as they arrive rather than popping. The JS adds
   .is-loaded; without JS (no .js on <html>) nothing is ever hidden. */
.js main img[loading="lazy"] { opacity: 0; transition: opacity 0.6s var(--ease); }
.js main img[loading="lazy"].is-loaded { opacity: 1; }

.band { padding-bottom: 56px; border-bottom: 1px solid var(--line); }
.band--slim { padding-bottom: 0; border-bottom: 0; }

/* ───────────────────────────────────────────────────────────────────────
   Type
   ─────────────────────────────────────────────────────────────────────── */

.display {
  margin: 0;
  font-family: var(--serif);
  font-optical-sizing: auto;
  font-weight: 400;
  font-size: clamp(40px, 9vw, 76px);
  line-height: 1;
  letter-spacing: -0.03em;
}
.display em, .h2 em, .oneliner em { font-style: italic; font-weight: 300; }

.h2 {
  margin: 6px 0 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(30px, 5vw, 44px);
  line-height: 1.05;
  letter-spacing: -0.025em;
}
.h3 { margin: 0; font-family: var(--serif); font-weight: 500; font-size: 24px; }

.muted { color: var(--fg-soft); line-height: 1.65; }

/* Small tracked caps: every label in the shop. */
.eyebrow {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.eyebrow--accent { color: var(--accent-text); }

/* ───────────────────────────────────────────────────────────────────────
   Header
   ─────────────────────────────────────────────────────────────────────── */

/* The header sits on the page's own black, frosted as the art scrolls
   under it, with a hairline to mark its edge. */
.masthead {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.masthead-in {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
  letter-spacing: 0.01em;
}
/* The logo: a serif A with a cobalt brush stroke dragged through it.
   Drawn from the #artvue-mark symbol in the page, so it inherits colour:
   the letter is currentColor, the stroke is --accent. */
.logo-mark { display: block; width: 40px; height: 35px; flex: 0 0 auto; color: var(--fg); }
.logo-mark--xs { width: 18px; height: 16px; }
.wordmark .wm-text {
  font-family: var(--serif);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}

.masthead nav { display: flex; align-items: center; gap: 2px; }
.navlink {
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-soft);
  transition: color 0.2s;
}
.navlink:hover { color: var(--fg); }
@media (max-width: 520px) { .navlink--hide-sm { display: none; } }


/* ───────────────────────────────────────────────────────────────────────
   Buttons — flat, square, one fill each
   ─────────────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 24px;
  border: 1px solid var(--solid);
  border-radius: 0;
  background: var(--solid);
  color: var(--solid-ink);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s var(--ease);
}
.btn svg { width: 16px; height: 16px; flex: 0 0 16px; }
.btn:active { transform: translateY(1px); }

.btn--accent { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn--accent:hover { background: var(--accent-hover); border-color: var(--accent-hover); }

/* Outline: the secondary action on either ground. */
.btn--line, .btn--ghost { background: transparent; border-color: var(--line-strong); color: var(--fg); }
.btn--line:hover, .btn--ghost:hover { background: var(--fg); color: var(--bg); }

.btn--light { background: #ECEAE5; border-color: #ECEAE5; color: #0E0F11; }

.btn--sm { min-height: 40px; padding: 0 16px; font-size: 11px; }
.btn--lg { min-height: 60px; font-size: 14px; }
.btn--block { width: 100%; }
.btn:disabled, .btn[aria-busy="true"] { opacity: 0.6; cursor: progress; }

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.cta-row--center { justify-content: center; }

.clear-link, .link-arrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
}

/* ───────────────────────────────────────────────────────────────────────
   Shop head — the one line
   ─────────────────────────────────────────────────────────────────────── */

.shop-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 26px;
  padding-bottom: 22px;
}
.oneliner {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(26px, 4.6vw, 44px);
  line-height: 1.1;
  letter-spacing: -0.025em;
}
.oneliner em { color: var(--accent-text); }
.shop-sum {
  margin: 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-faint);
}

/* ───────────────────────────────────────────────────────────────────────
   Collection labels (used on the collection page header)
   ─────────────────────────────────────────────────────────────────────── */



.bundle-flags { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; min-height: 20px; }
.flag {
  display: inline-block;
  padding: 7px 11px;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}


.bundle-count {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  margin: 12px 0 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.bundle-count strong {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--accent-text);
}
.bundle-count .dash { width: 34px; height: 1px; background: var(--accent); }


.bundle-price { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.bundle-price .amt {
  font-family: var(--serif);
  font-size: clamp(34px, 6vw, 46px);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}
.bundle-price .each {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-faint);
}



/* ───────────────────────────────────────────────────────────────────────
   Themes
   ─────────────────────────────────────────────────────────────────────── */

.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  margin: 0 calc(var(--gutter) * -1) 18px;
  padding: 2px var(--gutter);
}
.chips::-webkit-scrollbar { display: none; }
.chip-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--line);
  color: var(--fg-soft);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: border-color 0.2s, color 0.2s, background-color 0.2s;
}
.chip-btn:hover { border-color: var(--fg-soft); color: var(--fg); }
.chip-btn[aria-current="true"] { background: var(--fg); border-color: var(--fg); color: var(--bg); }

/* ───────────────────────────────────────────────────────────────────────
   Sections on canvas
   ─────────────────────────────────────────────────────────────────────── */

.wall-sec { padding-top: 48px; padding-bottom: 24px; }
.sec-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 18px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--line-strong);
}

/* ── Collection cards ────────────────────────────────────────────────── */

.pieces {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 34px 22px;
}
.piece { content-visibility: auto; contain-intrinsic-size: auto 420px; }
.piece-art {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: var(--bg-sunk);
  cursor: zoom-in;
}
.piece-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.6s var(--ease), transform 0.9s var(--ease);
}
.piece-art:hover img { transform: scale(1.03); }
.piece-no {
  position: absolute;
  top: 12px; left: 14px;
  font-family: var(--serif);
  font-size: 15px;
  font-style: italic;
  color: #ECEAE5;
  text-shadow: 0 1px 6px rgba(0, 0, 0, 0.55);
}
.piece-tag {
  position: absolute;
  top: 12px; right: 12px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 6px 10px;
  background: #0E0F11;
  color: #ECEAE5;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.piece-tag .logo-mark { color: #ECEAE5; --bg: #0E0F11; }
.piece-tag--accent { background: var(--accent); color: var(--accent-ink); }
.piece-name a { transition: color 0.2s; }
.piece-name a:hover { color: var(--fg-soft); }


.piece-label {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 0 18px;
  border-bottom: 1px solid var(--line);
}
/* The name takes the line; on a narrow card the price and button drop
   underneath it instead of squeezing it. */
.piece-what { flex: 1 1 220px; min-width: 0; }
.piece-name {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  margin: 4px 0 2px;
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.piece-in {
  font-size: 13px;
  color: var(--fg-soft);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--line);
}
.piece-in:hover { text-decoration-color: currentColor; }
.piece-buy { display: flex; align-items: center; gap: 14px; flex-shrink: 0; margin: 0; }
.piece-price {
  font-family: var(--serif);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.02em;
  white-space: nowrap;
}


/* ───────────────────────────────────────────────────────────────────────
   Bundle preview dialog — full screen on a phone, a sheet on desktop
   ─────────────────────────────────────────────────────────────────────── */

.bundle-dlg {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--fg);
}
.bundle-dlg[open] { display: flex; flex-direction: column; }
.bundle-dlg::backdrop { background: rgba(10, 9, 8, 0.8); }
@media (prefers-reduced-motion: no-preference) {
  .bundle-dlg[open] { animation: sheet-in 0.45s var(--ease); }
  .bundle-dlg[open]::backdrop { animation: fade-in 0.35s var(--ease); }
}
@keyframes sheet-in { from { opacity: 0; transform: translateY(28px); } }
@keyframes fade-in { from { opacity: 0; } }

.bd-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px var(--gutter);
  border-bottom: 1px solid var(--line);
}
.bd-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--fg-soft);
}

.bd-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 30px var(--gutter) 32px;
}
.bd-intro { max-width: 760px; margin: 0 auto 28px; text-align: center; }
.bd-title {
  margin: 10px 0 0;
  font-family: var(--serif);
  font-size: clamp(38px, 8vw, 64px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.03em;
}
.bd-sub { margin: 14px 0 0; color: var(--fg-soft); }

.bd-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px 12px;
  max-width: var(--max);
  margin: 0 auto;
}
.bd-piece { display: block; cursor: zoom-in; content-visibility: auto; contain-intrinsic-size: auto 200px; }
.bd-img {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: var(--bg-sunk);
}
.bd-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.5s var(--ease), transform 0.8s var(--ease);
}
.bd-piece:hover .bd-img img { transform: scale(1.04); }
.bd-num {
  position: absolute;
  left: 8px; bottom: 6px;
  font-family: var(--serif);
  font-size: 12px;
  font-style: italic;
  color: #ECEAE5;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.7);
}
.bd-name {
  display: block;
  margin-top: 8px;
  font-size: 13px;
  color: var(--fg-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bd-skel { display: block; aspect-ratio: 16 / 10; background: var(--bg-raised); }
@media (prefers-reduced-motion: no-preference) {
  .bd-skel { animation: pulse 1.2s ease-in-out infinite alternate; }
}
@keyframes pulse { to { background: var(--line); } }
.bd-error { text-align: center; color: var(--fg-soft); }
.bd-error a { text-decoration: underline; text-underline-offset: 3px; }

/* The buy bar, pinned to the foot of the dialog. */
.bd-buy {
  display: grid;
  gap: 12px;
  padding: 16px var(--gutter) calc(16px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: var(--bg-raised);
}
.bd-sum strong {
  display: block;
  font-family: var(--serif);
  font-size: 36px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}
.bd-sum span { font-size: 13px; color: var(--fg-soft); }

/* ───────────────────────────────────────────────────────────────────────
   Bundle page
   ─────────────────────────────────────────────────────────────────────── */

.coll-head { padding-top: 14px; }
.back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-soft);
  transition: color 0.2s;
}
.back svg { width: 15px; height: 15px; }
.back:hover { color: var(--fg); }

.coll-grid { display: grid; gap: 28px; padding-top: 22px; }
.coll-title .display { margin-top: 12px; }
.coll-buy {
  display: grid;
  gap: 14px;
  padding: 22px;
  border: 1px solid var(--line);
  background: var(--bg-raised);
}
.buy-note { font-size: 12px; color: var(--fg-faint); text-align: center; }

.bd-grid--page { gap: 26px 14px; }

.others { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.other { position: relative; display: block; overflow: hidden; aspect-ratio: 16 / 9; background: var(--bg-sunk); }
.other img { width: 100%; height: 100%; object-fit: cover; transition: opacity 0.6s var(--ease), transform 0.9s var(--ease); }
.other:hover img { transform: scale(1.04); }
.other-label {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px;
  background: linear-gradient(180deg, transparent, rgba(18, 17, 16, 0.85));
  color: #ECEAE5;
}
.other-label .eyebrow { color: #8DBCF7; }
.other-name { font-family: var(--serif); font-size: 26px; line-height: 1.1; }
.other-meta { font-size: 12px; color: rgba(239, 234, 224, 0.75); }

.buybar {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 40;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  transform: translateY(110%);
  transition: transform 0.4s var(--ease);
  background: var(--bg-raised);
}
.buybar.is-shown { transform: none; }
.buybar-in {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.buybar-text { display: flex; flex-direction: column; min-width: 0; }
.buybar-name {
  font-family: var(--serif);
  font-size: 18px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.buybar-price { font-size: 12px; color: var(--fg-soft); }

/* ───────────────────────────────────────────────────────────────────────
   Checkout, thanks, downloads, resend, error
   ─────────────────────────────────────────────────────────────────────── */

.flow { padding-top: 26px; padding-bottom: 40px; }
.flow--narrow { max-width: 600px; }

.progress {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 8px;
  margin: 0 0 26px;
  padding: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--fg-faint);
}
.progress li { display: flex; align-items: center; gap: 8px; }
.progress li + li::before { content: ""; width: 24px; height: 1px; background: var(--line); }
.progress span {
  display: grid;
  place-items: center;
  width: 24px; height: 24px;
  border: 1px solid var(--line);
  font-size: 11px;
  letter-spacing: 0;
}
.progress .done { color: var(--fg-soft); }
.progress .done span { border-color: var(--fg-soft); }
.progress .now { color: var(--fg); }
.progress .now span { background: var(--fg); border-color: var(--fg); color: var(--bg); }

.flow-grid { display: grid; gap: 16px; }
.card {
  position: relative;
  padding: clamp(22px, 5vw, 36px);
  border: 1px solid var(--line);
  background: var(--bg-raised);
}
.card .h2 { margin-bottom: 10px; }
.center-card { text-align: center; }
.center-card .muted { max-width: 44ch; margin-left: auto; margin-right: auto; }
.center-card > .eyebrow { display: block; }

.line {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.line .thumb { flex: 0 0 96px; overflow: hidden; background: var(--bg-sunk); }
.line .thumb img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.line-text { display: flex; flex-direction: column; min-width: 0; }
.lname { font-size: 16px; font-weight: 600; }
.lmeta { font-size: 13px; color: var(--fg-faint); }
.lprice { margin-left: auto; font-size: 16px; font-weight: 600; white-space: nowrap; }

.total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 18px 0 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.total .amt {
  font-family: var(--serif);
  font-size: 38px;
  font-weight: 500;
  letter-spacing: -0.03em;
  text-transform: none;
  color: var(--fg);
}

.checks { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 8px; font-size: 14px; color: var(--fg-soft); }
.checks li { display: flex; align-items: center; gap: 10px; }
.checks li::before { content: ""; width: 12px; height: 7px; border-left: 2px solid var(--fg); border-bottom: 2px solid var(--fg); transform: rotate(-45deg) translateY(-2px); flex: 0 0 auto; }
.checks--sm { font-size: 13px; }

.field { display: flex; flex-direction: column; gap: 8px; margin: 22px 0; }
.field label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.field input {
  width: 100%;
  min-height: 56px;
  padding: 0 16px;
  border: 1px solid var(--fg);
  border-radius: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: inherit;
  font-size: 16px; /* anything smaller and iOS Safari zooms on focus */
}
.field input:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.field .hint { font-size: 13px; line-height: 1.5; color: var(--fg-faint); }

.trust {
  display: grid;
  gap: 10px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--fg-soft);
}
.trust div { display: flex; align-items: center; gap: 10px; }
.trust svg { width: 16px; height: 16px; flex: 0 0 16px; }

.seal {
  display: grid;
  place-items: center;
  width: 60px; height: 60px;
  margin: 0 auto 18px;
  background: var(--accent);
  color: var(--accent-ink);
}
.seal svg { width: 28px; height: 28px; }
@media (prefers-reduced-motion: no-preference) {
  .seal svg path { stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw 0.6s 0.2s var(--ease) forwards; }
}
@keyframes draw { to { stroke-dashoffset: 0; } }

.receipt {
  margin-top: 24px;
  padding: 20px;
  text-align: left;
  border: 1px dashed var(--fg-faint);
}
.receipt ul { margin: 10px 0 0; padding: 0 0 0 18px; display: grid; gap: 4px; font-size: 15px; }
.receipt-foot {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--fg-faint);
}

.dl-list { display: grid; gap: 10px; margin-top: 22px; }
.dl-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  background: var(--bg);
}
.dl-files { display: flex; flex-wrap: wrap; gap: 8px; }
.dl-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 14px;
  border: 1px solid var(--fg);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: background-color 0.2s, color 0.2s;
}
.dl-chip svg { width: 15px; height: 15px; }
.dl-chip small { font-weight: 500; letter-spacing: 0; text-transform: none; opacity: 0.7; }
.dl-chip:hover { background: var(--fg); color: var(--bg); }

.err-code {
  display: block;
  font-family: var(--serif);
  font-size: clamp(72px, 18vw, 120px);
  font-style: italic;
  font-weight: 300;
  line-height: 1;
}

.note {
  padding: 18px 20px;
  border: 1px solid var(--line);
  background: var(--bg-raised);
  color: var(--fg-soft);
}
.note--ok { border-color: var(--fg); color: var(--fg); }

.err {
  margin: 16px 0 0;
  padding: 12px 16px;
  border-left: 3px solid #B5422E;
  background: rgba(181, 66, 46, 0.08);
  font-size: 14px;
}

/* ───────────────────────────────────────────────────────────────────────
   Lightbox
   ─────────────────────────────────────────────────────────────────────── */

.lightbox {
  width: 100vw; height: 100dvh;
  max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: transparent;
  color: #ECEAE5;
  overflow: hidden;
}
.lightbox::backdrop { background: rgba(10, 9, 8, 0.94); }
.lightbox[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; }
@media (prefers-reduced-motion: no-preference) {
  .lightbox[open] { animation: fade-in 0.3s var(--ease); }
}
.lb-stage { display: grid; place-items: center; min-height: 0; overflow: hidden; padding: 64px 16px 8px; }
.lb-img {
  max-width: 100%;
  max-height: calc(100dvh - 150px);
  width: auto;
  height: auto;
  object-fit: contain;
  transition: opacity 0.25s var(--ease);
  touch-action: pan-y;
}
.lb-img.is-swapping { opacity: 0; }
.lb-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 14px 16px calc(18px + env(safe-area-inset-bottom));
}
.lb-caption { font-family: var(--serif); font-size: 20px; }
.lb-count { font-family: var(--sans); font-size: 12px; color: rgba(239, 234, 224, 0.6); margin-left: 6px; }
.lb-btn {
  position: absolute;
  display: grid;
  place-items: center;
  width: 48px; height: 48px;
  border: 1px solid rgba(239, 234, 224, 0.35);
  background: #0E0F11;
  color: #ECEAE5;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}
.lb-btn:hover { background: #ECEAE5; color: #0E0F11; }
.lb-btn svg { width: 20px; height: 20px; }
.lb-close { top: 12px; right: 12px; }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
@media (max-width: 640px) {
  .lb-prev, .lb-next { top: auto; bottom: 78px; transform: none; }
}

/* ───────────────────────────────────────────────────────────────────────
   Footer
   ─────────────────────────────────────────────────────────────────────── */

.foot { margin-top: 70px; border-top: 1px solid var(--line-strong); }
.foot-grid { display: grid; gap: 28px; padding-top: 44px; padding-bottom: 30px; }
.foot-brand p { margin: 14px 0 0; max-width: 36ch; font-size: 14px; color: var(--fg-soft); }
.foot-col { display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.foot-col .eyebrow { margin-bottom: 4px; }
.foot-col a { color: var(--fg-soft); width: fit-content; transition: color 0.2s; }
.foot-col a:hover { color: var(--fg); }
.foot-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 20px;
  padding-top: 18px;
  padding-bottom: calc(26px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--fg-faint);
}
.has-buybar .foot-base { padding-bottom: 96px; }

/* ───────────────────────────────────────────────────────────────────────
   Motion: reveal on scroll, page transitions
   ─────────────────────────────────────────────────────────────────────── */

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] {
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
    transition-delay: var(--d, 0ms);
  }
  .js [data-reveal].is-in { opacity: 1; transform: none; }
}

@view-transition { navigation: auto; }
@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
}
::view-transition-old(root),
::view-transition-new(root) { animation-duration: 0.3s; animation-timing-function: var(--ease); }
::view-transition-group(*) { animation-duration: 0.5s; animation-timing-function: var(--ease); }
.masthead { view-transition-name: masthead; }

/* ───────────────────────────────────────────────────────────────────────
   Wider screens. Phone is the base; these are additions.
   ─────────────────────────────────────────────────────────────────────── */

@media (min-width: 640px) {
  :root { --gutter: 32px; }
  .pieces { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .bd-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .others { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot-grid { grid-template-columns: 2fr 1fr 1fr; }
  .dl-row { flex-direction: row; align-items: center; justify-content: space-between; }
  .bd-buy { grid-template-columns: 1fr minmax(0, 360px); align-items: center; }
}

@media (min-width: 760px) {
  .flow-grid { grid-template-columns: 1fr 1.15fr; align-items: start; }
  .order-card { position: sticky; top: calc(var(--header-h) + 20px); }
  .buybar { display: none; }
  .has-buybar .foot-base { padding-bottom: calc(26px + env(safe-area-inset-bottom)); }

  /* On a wide screen the preview is a sheet over the page, not the page. */
  .bundle-dlg {
    width: min(1180px, calc(100vw - 64px));
    height: calc(100dvh - 64px);
    margin: auto;
    border: 1px solid var(--line);
  }
}

@media (min-width: 960px) {
  .band { padding-bottom: 72px; }
  .band--slim { padding-bottom: 0; border-bottom: 0; }
  .shop-head { padding-top: 40px; padding-bottom: 28px; }
  .wall-sec { padding-top: 72px; }
  .pieces { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .bd-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .bd-grid--page { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .others { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .coll-grid { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: end; gap: 56px; }
}

@media (min-width: 1200px) {
  .bd-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ───────────────────────────────────────────────────────────────────────
   Touch targets. Small text links keep their look but get a 44px-tall
   hit area (the size Apple and Google recommend for a fingertip); the
   negative margins stop the extra padding from moving the layout.
   ─────────────────────────────────────────────────────────────────────── */

.navlink, .wordmark { min-height: 44px; display: inline-flex; align-items: center; }
.piece-in, .clear-link, .back, .link-arrow {
  display: inline-block;
  padding-top: 13px;
  padding-bottom: 13px;
  margin-top: -13px;
  margin-bottom: -13px;
}
.back { display: inline-flex; padding-top: 12px; padding-bottom: 12px; margin-top: -4px; margin-bottom: -4px; }

/* Must come after the touch-target rule above, which sets display. */
@media (max-width: 520px) { .navlink.navlink--hide-sm { display: none; } }

/* The checkout steps fit a 320px screen: shorter connectors, no labels on
   the steps already done. */
@media (max-width: 360px) {
  .progress { gap: 6px; }
  .progress li + li::before { width: 12px; }
  .progress .done { font-size: 0; gap: 0; }
  .progress .done span { font-size: 11px; }
}

/* ───────────────────────────────────────────────────────────────────────
   Downloads: one ZIP per screen size
   ─────────────────────────────────────────────────────────────────────── */

.zips { display: grid; gap: 10px; margin-top: 22px; }
.zip {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 12px 16px;
  border: 1px solid var(--line);
  background: var(--bg);
  transition: border-color 0.2s, background-color 0.2s;
}
.zip:hover { border-color: var(--fg-soft); }
.zip svg { width: 22px; height: 22px; flex: 0 0 22px; color: var(--accent-text); }
.zip-text { display: flex; flex-direction: column; }
.zip-label { font-size: 16px; font-weight: 600; }
.zip-meta { font-size: 13px; color: var(--fg-soft); }
.zip--all { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.zip--all svg, .zip--all .zip-meta { color: var(--accent-ink); }
.zip--all:hover { background: var(--accent-hover); border-color: var(--accent-hover); }

.dl-more { margin-top: 22px; border-top: 1px solid var(--line); padding-top: 14px; }
.dl-more summary { cursor: pointer; min-height: 44px; display: flex; align-items: center; font-size: 14px; font-weight: 600; color: var(--fg-soft); }
.dl-more[open] summary { color: var(--fg); }


/* ───────────────────────────────────────────────────────────────────────
   Payment window: a drawer from the right on a wide screen, the whole
   screen on a phone. Same bar and close button as the preview sheet.
   ─────────────────────────────────────────────────────────────────────── */

.pay-dlg {
  width: 100vw;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: var(--bg);
  color: var(--fg);
  overflow: hidden;
}
.pay-dlg[open] { display: flex; flex-direction: column; }
.pay-dlg::backdrop { background: rgba(6, 7, 8, 0.72); }
@media (prefers-reduced-motion: no-preference) {
  .pay-dlg[open] { animation: drawer-in 0.4s var(--ease); }
  .pay-dlg[open]::backdrop { animation: fade-in 0.3s var(--ease); }
}
@keyframes drawer-in { from { transform: translateY(24px); opacity: 0; } }

.pay-body { flex: 1; overflow-y: auto; padding: 22px var(--gutter) calc(24px + env(safe-area-inset-bottom)); }
.pay-line {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  align-items: center;
  gap: 14px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}
.pay-thumb { width: 96px; aspect-ratio: 16 / 10; object-fit: cover; background: var(--bg-sunk); }
.pay-what { display: flex; flex-direction: column; min-width: 0; }
.pay-name { font-family: var(--serif); font-size: 20px; line-height: 1.15; }
.pay-meta { font-size: 12px; color: var(--fg-soft); }
.pay-price { font-weight: 600; white-space: nowrap; }
.pay-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 18px 0 2px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--fg-soft);
}
.pay-total strong { font-family: var(--serif); font-size: 40px; font-weight: 500; letter-spacing: -0.03em; color: var(--fg); text-transform: none; }
.pay-trust { margin: 14px 0 0; font-size: 12px; text-align: center; color: var(--fg-faint); }

@media (min-width: 760px) {
  .pay-dlg {
    width: min(460px, 100vw);
    margin: 0 0 0 auto;
    border-left: 1px solid var(--line);
  }
  @media (prefers-reduced-motion: no-preference) {
    .pay-dlg[open] { animation: drawer-side 0.4s var(--ease); }
  }
}
@keyframes drawer-side { from { transform: translateX(40px); opacity: 0; } }
