/* Batch 4: the thin pages (Exhibitions, Contact, Film, Print Editions). Sections labelled with tracker IDs.
   Loaded after site-finish.css on those four pages only. */
html[data-theme] body.pgx {
  --x-paper: #fff; --x-ink: #000; --x-soft: #555; --x-line: #d9d9d9; --x-panel: #f2f2f2; --x-scrim: rgba(255,255,255,.97);
  --x-serif: Williwaw, Georgia, serif; --x-sans: Arial, Helvetica, sans-serif; --x-gut: clamp(16px, 4vw, 64px);
  background: var(--x-paper); color: var(--x-ink);
}
html[data-theme="dark"] body.pgx { --x-paper: #000; --x-ink: #fff; --x-soft: #bdbdbd; --x-line: #2a2a2a; --x-panel: #111; --x-scrim: rgba(0,0,0,.97); color-scheme: dark; }
.pgx main { background: var(--x-paper); color: var(--x-ink); }
.pgx [hidden] { display: none !important; }
.x-open { padding: clamp(60px, 9vw, 130px) var(--x-gut) clamp(30px, 5vw, 64px); display: grid; gap: 16px; }
.x-open h1 { margin: 0; font: 400 clamp(56px, 9vw, 140px)/.9 var(--x-serif); letter-spacing: -.045em; }
.x-kicker, .x-open .count { margin: 0; font: 12px/1.5 var(--x-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--x-soft); }
.x-link { font: 15px var(--x-sans); color: inherit; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 3px; justify-self: start; }

/* ---------- EXH-01 to EXH-03: every exhibition with its place, date and a line from its own page ---------- */
.x-shows { display: grid; gap: clamp(56px, 8vw, 120px); padding: 0 var(--x-gut) clamp(60px, 9vw, 130px); }
.x-show { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 72px); align-items: center; color: inherit; text-decoration: none; }
.x-show:nth-child(even) { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.x-show:nth-child(even) .x-img { order: 2; }
.x-show .x-img { margin: 0; overflow: hidden; background: var(--x-panel); }
.x-show .x-img img { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; transition: transform 1.1s cubic-bezier(.19,1,.22,1); }
.x-show:hover .x-img img { transform: scale(1.025); }
.x-show.lead { grid-template-columns: 1fr; }
.x-show.lead .x-img img { aspect-ratio: 16 / 8; }
.x-show.lead .x-txt { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 26rem); gap: 12px 48px; align-items: end; }
.x-show.lead .x-txt .x-kicker, .x-show.lead .x-txt h2 { grid-column: 1; }
.x-show.lead .x-txt blockquote, .x-show.lead .x-txt .x-more { grid-column: 2; }
.x-show.lead .x-txt blockquote { grid-row: 1 / span 2; }
.x-txt { display: grid; gap: 14px; align-content: center; }
.x-txt h2 { margin: 0; font: 400 clamp(30px, 3.2vw, 52px)/1 var(--x-serif); letter-spacing: -.025em; }
.x-txt blockquote { margin: 6px 0 0; padding: 0; font: clamp(17px, 1.3vw, 20px)/1.5 var(--x-serif); }
.x-txt blockquote p { margin: 0; }
.x-txt blockquote footer { margin-top: 8px; font: 13px/1.4 var(--x-sans); color: var(--x-soft); }
.x-more { font: 15px var(--x-sans); border-bottom: 1px solid currentColor; padding-bottom: 3px; justify-self: start; margin-top: 6px; }
@media (max-width: 800px) {
  .x-show, .x-show:nth-child(even) { grid-template-columns: 1fr; }
  .x-show:nth-child(even) .x-img { order: 0; }
  .x-show.lead .x-img img { aspect-ratio: 3 / 2; }
  .x-show.lead .x-txt { grid-template-columns: 1fr; }
  .x-show.lead .x-txt > * { grid-column: 1 !important; grid-row: auto !important; }
}

/* ---------- CNT-01, CNT-03: contact fills the first screen, with the studio beside it ---------- */
.x-contact { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); min-height: calc(100svh - var(--header-height, 76px)); }
.x-contact .x-portrait { margin: 0; background: var(--x-panel); overflow: hidden; }
.x-contact .x-portrait img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
.x-contact .x-card { display: grid; align-content: center; gap: clamp(28px, 4vw, 56px); padding: clamp(48px, 7vw, 120px) var(--x-gut); }
.x-contact h1 { margin: 0; font: 400 clamp(56px, 8vw, 128px)/.9 var(--x-serif); letter-spacing: -.045em; }
.x-contact dl { margin: 0; display: grid; }
.x-contact dl > div { display: grid; gap: 6px; padding: clamp(16px, 2vw, 26px) 0; border-top: 1px solid var(--x-line); }
.x-contact dl > div:last-child { border-bottom: 1px solid var(--x-line); }
.x-contact dt { font: 12px/1.4 var(--x-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--x-soft); }
.x-contact dd { margin: 0; font: clamp(24px, 2.6vw, 40px)/1.15 var(--x-serif); letter-spacing: -.015em; }
.x-contact dd a { color: inherit; text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .5s cubic-bezier(.19,1,.22,1); }
.x-contact dd a:hover, .x-contact dd a:focus-visible { background-size: 100% 1px; }
@media (max-width: 800px) {
  .x-contact { grid-template-columns: 1fr; min-height: 0; }
  .x-contact .x-portrait { order: 2; aspect-ratio: 4 / 5; }
}

/* ---------- FLM-01, FLM-02: bigger screen, no grey shadow; where it was first shown ---------- */
body.film-page .film-poster { width: min(84vw, 1000px, calc((100svh - 300px) * 4 / 3)); min-width: min(88vw, 520px); box-shadow: none; }
.x-screened { background: var(--x-paper); color: var(--x-ink); border-top: 1px solid var(--x-line); padding: clamp(60px, 9vw, 130px) var(--x-gut); display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 72px); align-items: center; }
.x-screened figure { margin: 0; overflow: hidden; }
.x-screened img { display: block; width: 100%; height: auto; }
.x-screened h2 { margin: 0; font: 400 clamp(30px, 3.2vw, 52px)/1 var(--x-serif); letter-spacing: -.025em; }
.x-screened .x-txt p { margin: 0; }
.x-screened a { color: inherit; }
@media (max-width: 800px) { .x-screened { grid-template-columns: 1fr; } }

/* ---------- PRT-01 to PRT-03: prints on the first screen, clear prices, a large view of each ---------- */
.x-prints { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(28px, 4vw, 72px); padding: clamp(48px, 7vw, 100px) var(--x-gut) clamp(60px, 8vw, 110px); align-items: start; }
.x-prints .x-side { position: sticky; top: calc(var(--header-height, 76px) + 32px); display: grid; gap: 22px; }
.x-prints h1 { margin: 0; font: 400 clamp(52px, 6.4vw, 110px)/.9 var(--x-serif); letter-spacing: -.045em; }
.x-prints .x-price { margin: 0; font: 400 clamp(34px, 3.4vw, 54px)/1 var(--x-serif); }
.x-prints .x-price span { display: block; margin-top: 8px; font: 12px/1.4 var(--x-sans); letter-spacing: .14em; text-transform: uppercase; color: var(--x-soft); }
.x-prints ul { list-style: none; margin: 0; padding: 0; font: 16px/1.5 var(--x-serif); }
.x-prints ul li { padding: 10px 0; border-top: 1px solid var(--x-line); }
.x-prints ul li:last-child { border-bottom: 1px solid var(--x-line); }
.x-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 12px 20px; border: 1px solid var(--x-ink); border-radius: 999px; background: var(--x-ink); color: var(--x-paper); font: 15px/1 var(--x-sans); text-decoration: none; cursor: pointer; justify-self: start; transition: background .3s, color .3s; }
.x-btn:hover, .x-btn:focus-visible { background: transparent; color: var(--x-ink); }
.x-btn.ghost { background: transparent; color: var(--x-ink); }
.x-btn.ghost:hover, .x-btn.ghost:focus-visible { background: var(--x-ink); color: var(--x-paper); }
.x-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(36px, 4vw, 64px) clamp(16px, 2vw, 32px); }
.x-ed { margin: 0; display: grid; gap: 12px; align-content: start; }
.x-ed > button { display: block; padding: 0; border: 0; background: var(--x-panel); cursor: zoom-in; overflow: hidden; }
.x-ed > button img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; transition: transform 1s cubic-bezier(.19,1,.22,1); }
.x-ed > button:hover img, .x-ed > button:focus-visible img { transform: scale(1.025); }
.x-ed .row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.x-ed .nm { font: clamp(22px, 1.9vw, 30px)/1.1 var(--x-serif); letter-spacing: -.015em; }
.x-ed .pr { font: clamp(20px, 1.6vw, 26px)/1 var(--x-serif); white-space: nowrap; }
.x-notes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(28px, 4vw, 56px) clamp(28px, 5vw, 80px); padding: clamp(56px, 8vw, 110px) var(--x-gut); border-top: 1px solid var(--x-line); }
.x-notes h2 { margin: 0 0 12px; font: 400 clamp(26px, 2.4vw, 38px)/1.05 var(--x-serif); letter-spacing: -.02em; }
.x-notes p { margin: 0; max-width: 56ch; font: 17px/1.6 var(--x-serif); }
@media (max-width: 900px) { .x-prints { grid-template-columns: 1fr; } .x-prints .x-side { position: static; } .x-notes { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .x-grid { gap: 36px 12px; } .x-ed .row { flex-direction: column; gap: 6px; } .x-ed .x-btn { padding: 10px 14px; font-size: 14px; } }

/* print viewer */
dialog.x-view { border: 0; margin: 0; padding: max(20px, env(safe-area-inset-top, 0px)) var(--x-gut) max(20px, env(safe-area-inset-bottom, 0px)); width: 100vw; max-width: 100vw; height: 100svh; max-height: none; background: var(--x-scrim); color: var(--x-ink); }
dialog.x-view[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; }
dialog.x-view::backdrop { background: transparent; }
.x-view img { width: 100%; height: 100%; object-fit: contain; min-height: 0; }
.x-view .bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; padding-top: 14px; font: 14px var(--x-sans); }
.x-view .t { font: 22px var(--x-serif); margin-right: auto; }
.x-view .bar button { background: none; border: 1px solid var(--x-line); border-radius: 999px; padding: 10px 16px; color: var(--x-ink); cursor: pointer; font: 14px var(--x-sans); }
html[data-theme="dark"] .x-view .bar button { border-color: #444; }
.x-view .bar .x-btn { padding: 10px 16px; font-size: 14px; }

/* titles of works and captions keep the serif over the shared caption role */
html body.pgx main .x-ed .nm, html body.pgx main .x-ed .pr { font-family: var(--x-serif); letter-spacing: 0; }
.x-txt .x-line { margin: 6px 0 0; font: clamp(17px, 1.3vw, 20px)/1.5 var(--x-serif); }

/* type roles: these pages' sizes beat the shared type system (which uses !important) */
html[data-theme] body.pgx main .x-txt h2, html[data-theme] body.pgx main .x-screened h2 { font-size: var(--type-card-title) !important; }
html[data-theme] body.pgx main .x-notes h2 { font-size: var(--type-card-title) !important; }
html[data-theme] body.pgx main .x-txt blockquote, html[data-theme] body.pgx main .x-txt blockquote p { font-family: var(--x-serif) !important; font-size: var(--type-lede) !important; line-height: 1.4 !important; letter-spacing: -.01em !important; max-width: 30ch; }
html[data-theme] body.pgx main .x-txt blockquote footer { font: 13px/1.4 var(--x-sans) !important; letter-spacing: 0 !important; color: var(--x-soft); }
html[data-theme] body.pgx main :is(.x-kicker, .x-open .count) { font-family: var(--x-sans) !important; font-size: 12px !important; line-height: 1.5 !important; letter-spacing: .14em; text-transform: uppercase; color: var(--x-soft); }
html[data-theme] body.pgx main :is(.x-txt .x-line, .x-screened .x-txt p:not(.x-kicker)) { font-size: var(--type-body) !important; line-height: 1.55 !important; max-width: 40ch; }
html[data-theme] body.pgx main .x-prints .x-price { font-size: clamp(34px, 3.4vw, 54px) !important; line-height: 1 !important; }
html[data-theme] body.pgx main .x-prints .x-price span { font-family: var(--x-sans) !important; font-size: 12px !important; line-height: 1.4 !important; letter-spacing: .14em; text-transform: uppercase; color: var(--x-soft); }
html[data-theme] body.pgx main .x-prints ul li { font-family: var(--x-serif) !important; font-size: var(--type-body) !important; line-height: 1.45 !important; }
html[data-theme] body.pgx main .x-more { font: 15px/1.2 var(--x-sans) !important; }
/* the lead exhibition: a plain stack under the wide photograph */
.x-show.lead .x-txt { display: grid; grid-template-columns: 1fr; gap: 14px; }
.x-show.lead .x-txt > * { grid-column: 1 !important; grid-row: auto !important; }
