/* The Birth of Inner Worlds — exhibition section. */
.inner-worlds {
  --iw-paper: #f7f5f0;
  --iw-ink: #28231f;
  --iw-muted: #675f57;
  --iw-accent: #78443d;
  --iw-line: rgba(70, 54, 43, .22);
  background: var(--iw-paper);
  color: var(--iw-ink);
  border-top: 1px solid var(--iw-line);
  border-bottom: 1px solid var(--iw-line);
  padding-block: clamp(4rem, 7vw, 8rem);
}
.iw-container { max-width: 1360px; margin-inline: auto; }
.iw-masthead { display: flex; justify-content: space-between; gap: 1rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--iw-line); }
.iw-masthead p, .iw-label, .iw-artist { margin: 0; font: .68rem/1.6 Arial, Helvetica, sans-serif; letter-spacing: .14em; text-transform: uppercase; }
.iw-masthead p:last-child { color: var(--iw-muted); }
.iw-heading { display: grid; grid-template-columns: minmax(0, 2.2fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 5rem); align-items: end; padding-block: clamp(2.5rem, 5vw, 5.5rem); }
.iw-heading h2 { font: 400 clamp(3.5rem, 7.65vw, 7.8rem)/.99 Georgia, 'Times New Roman', serif; letter-spacing: -.055em; margin: 0; }
.iw-heading h2 span, .iw-heading h2 em { display: block; }
.iw-heading h2 em { font-weight: 400; color: var(--iw-accent); }
.iw-heading-note { max-width: 25rem; padding-bottom: .4rem; }
.iw-question { font: 400 clamp(1.3rem, 2.05vw, 1.9rem)/1.35 Georgia, 'Times New Roman', serif; letter-spacing: -.02em; margin: 0 0 1.7rem; }
.iw-artist { color: var(--iw-muted); }
.iw-work { margin: 0; min-width: 0; }
.iw-zoom { display: block; position: relative; width: 100%; cursor: zoom-in; }
.iw-zoom img { display: block; width: 100%; height: auto; }
.iw-enlarge { position: absolute; right: 1rem; bottom: 1rem; display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid rgba(40, 35, 31, .4); background: rgba(247, 245, 240, .88); transition: background .18s, color .18s; }
.iw-enlarge svg { width: 24px; height: 24px; }
.iw-zoom:hover .iw-enlarge, .iw-zoom:focus-visible .iw-enlarge { background: var(--iw-ink); color: var(--iw-paper); }
.iw-zoom:focus-visible { outline: 2px solid var(--iw-accent); outline-offset: 6px; }
.iw-caption { display: flex; justify-content: space-between; align-items: flex-start; gap: 1.5rem; padding-top: 1.35rem; }
.iw-label { color: var(--iw-accent); font-size: .64rem; letter-spacing: .13em; }
.iw-caption h3, .iw-caption h4 { font: 400 clamp(1.3rem, 2.1vw, 1.9rem)/1.2 Georgia, 'Times New Roman', serif; letter-spacing: -.025em; margin: .5rem 0 0; }
.iw-meta, .iw-caption-note { font: .76rem/1.65 Arial, Helvetica, sans-serif; color: var(--iw-muted); margin: .55rem 0 0; }
.iw-caption-note { margin-top: 0; text-align: right; max-width: 23rem; }
.iw-introduction, .iw-encounter-text { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: clamp(2rem, 7vw, 7rem); }
.iw-introduction { padding-block: clamp(4rem, 8vw, 8rem); }
.iw-margin-label { padding-top: .45rem; }
.iw-statement { font: 400 clamp(1.4rem, 2.25vw, 2rem)/1.5 Georgia, 'Times New Roman', serif; letter-spacing: -.02em; max-width: 37ch; margin: 0; }
.iw-origins-heading { display: flex; justify-content: space-between; align-items: end; gap: 1.5rem; border-top: 1px solid var(--iw-line); padding-top: 1.65rem; margin-bottom: 2rem; }
.iw-origins-heading h3 { font: 400 clamp(2.2rem, 3.6vw, 3.5rem)/1.1 Georgia, 'Times New Roman', serif; letter-spacing: -.035em; margin: .75rem 0 0; }
.iw-origins-heading > p { font: .75rem/1.6 Arial, Helvetica, sans-serif; color: var(--iw-muted); margin: 0 0 .25rem; }
.iw-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.5rem, 5vw, 5rem); }
.iw-portrait { aspect-ratio: 3 / 4; display: grid; place-items: center; }
.iw-portrait img { width: 100%; height: 100%; object-fit: contain; }
.iw-pair .iw-caption h4 { max-width: 24ch; }
.iw-encounter-text { margin-top: clamp(4rem, 8vw, 8rem); padding-top: clamp(2rem, 4vw, 4rem); border-top: 1px solid var(--iw-line); }
.iw-encounter-text h3 { font: 400 clamp(2.5rem, 4.2vw, 4rem)/1.06 Georgia, 'Times New Roman', serif; letter-spacing: -.04em; margin: 1.25rem 0 0; }
.iw-encounter-text h3 em { font-weight: 400; }
.iw-essay { max-width: 39rem; }
.iw-essay p { font: 1.1rem/1.8 Arial, Helvetica, sans-serif; margin: 0; }
.iw-coda { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); align-items: end; gap: clamp(2rem, 7vw, 7rem); margin-block: clamp(4rem, 8vw, 8rem); }
.iw-coda-line { font: 400 clamp(2.3rem, 4.6vw, 4.4rem)/1.12 Georgia, 'Times New Roman', serif; letter-spacing: -.04em; color: var(--iw-accent); margin: 0; }
.iw-coda-line span { display: block; }
.iw-coda-text { font: 400 clamp(1.2rem, 1.8vw, 1.6rem)/1.55 Georgia, 'Times New Roman', serif; letter-spacing: -.015em; max-width: 29ch; margin: 0 0 .3rem; }
.iw-colophon { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: clamp(2rem, 7vw, 7rem); padding-top: 1.5rem; border-top: 1px solid var(--iw-line); }
.iw-colophon > p:last-child { max-width: 41rem; margin: 0; font: .78rem/1.8 Arial, Helvetica, sans-serif; color: var(--iw-muted); }

/* A dedicated viewer keeps the studies together and preserves full images. */
dialog.iw-viewer { width: min(1500px, calc(100vw - 3rem)); height: calc(100vh - 3rem); height: calc(100svh - 3rem); max-width: none; max-height: none; padding: 0; border: 0; background: #f7f5f0; color: #28231f; overflow: hidden; }
dialog.iw-viewer[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
dialog.iw-viewer:not([open]) { display: none; }
dialog.iw-viewer::backdrop { background: rgba(24, 21, 19, .92); }
.iw-viewer-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .5rem .75rem .5rem 1.5rem; border-bottom: 1px solid rgba(70, 54, 43, .18); }
.iw-viewer-bar p { font: .67rem/1.5 Arial, Helvetica, sans-serif; letter-spacing: .1em; text-transform: uppercase; margin: 0; }
.iw-viewer button { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 1px solid transparent; background: transparent; cursor: pointer; }
.iw-viewer button:hover { border-color: currentColor; }
.iw-viewer button:focus-visible { outline: 2px solid #78443d; outline-offset: -2px; }
.iw-viewer button:disabled { opacity: .25; cursor: default; border-color: transparent; }
.iw-viewer button svg { width: 24px; height: 24px; }
.iw-viewer-stage { display: grid; place-items: center; min-height: 0; padding: clamp(.5rem, 2vw, 2rem); }
.iw-viewer-stage img { width: 100%; height: 100%; min-height: 0; max-width: 100%; max-height: 100%; object-fit: contain; margin: 0; }
.iw-viewer-footer { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 1rem 1.5rem; border-top: 1px solid rgba(70, 54, 43, .18); }
.iw-viewer-title { font: 400 1.2rem/1.3 Georgia, 'Times New Roman', serif; margin: 0; }
.iw-viewer-detail { font: .7rem/1.5 Arial, Helvetica, sans-serif; color: #675f57; margin: .35rem 0 0; }
.iw-viewer-controls { display: flex; align-items: center; flex-shrink: 0; gap: .35rem; }
.iw-viewer-count { min-width: 3.5rem; text-align: center; font: .7rem/1 Arial, Helvetica, sans-serif; font-variant-numeric: tabular-nums; }

@media (max-width: 800px) {
  .iw-heading { grid-template-columns: 1fr; gap: 2rem; padding-block: 2.5rem; }
  .iw-heading h2 { font-size: clamp(2.75rem, 12vw, 6rem); }
  .iw-heading-note { display: flex; max-width: none; justify-content: space-between; align-items: end; gap: 2rem; padding: 0; }
  .iw-question { max-width: 25ch; font-size: 1.4rem; margin: 0; }
  .iw-artist { flex-shrink: 0; }
  .iw-introduction, .iw-encounter-text, .iw-colophon { grid-template-columns: 1fr; gap: 1.5rem; }
  .iw-statement { max-width: 42ch; font-size: 1.5rem; }
  .iw-margin-label { padding: 0; }
  .iw-encounter-text h3 { margin-top: .8rem; }
  .iw-encounter-text h3 br { display: none; }
  .iw-encounter-text h3 em::before { content: ' '; }
  .iw-essay { max-width: 42rem; }
  .iw-essay p { font-size: 1rem; line-height: 1.8; }
  .iw-coda { grid-template-columns: 1fr; gap: 2rem; }
  .iw-coda-line { font-size: clamp(2.4rem, 6.3vw, 3.6rem); }
  .iw-coda-text { max-width: 38ch; font-size: 1.3rem; }
}
@media (max-width: 600px) {
  .inner-worlds { padding-block: 3.5rem; }
  .iw-masthead p { font-size: .6rem; letter-spacing: .1em; }
  .iw-heading-note { display: block; }
  .iw-question { font-size: 1.3rem; }
  .iw-artist { margin-top: 1.2rem; font-size: .62rem; }
  .iw-shared { margin-inline: -8px; }
  .iw-shared .iw-caption { margin-inline: 8px; }
  .iw-caption { display: block; padding-top: 1rem; }
  .iw-caption-note { text-align: left; font-size: .7rem; margin-top: 1rem; }
  .iw-caption h3, .iw-caption h4 { font-size: 1.5rem; }
  .iw-enlarge { width: 44px; height: 44px; right: .5rem; bottom: .5rem; }
  .iw-introduction { padding-block: 3.5rem; }
  .iw-statement { font-size: 1.35rem; line-height: 1.6; }
  .iw-origins-heading { display: block; margin-bottom: 1.5rem; }
  .iw-origins-heading > p { margin-top: 1rem; font-size: .7rem; }
  .iw-pair { grid-template-columns: 1fr; gap: 3rem; }
  .iw-portrait { aspect-ratio: auto; }
  .iw-portrait img { height: auto; }
  .iw-pair .iw-caption h4 { max-width: 25ch; }
  .iw-coda-line { font-size: clamp(2rem, 8vw, 2.8rem); }
  .iw-coda { margin-block: 3.5rem; }
  .iw-colophon { gap: .8rem; }
  dialog.iw-viewer { width: 100vw; height: 100vh; height: 100svh; margin: 0; }
  .iw-viewer-bar { padding: max(.4rem, env(safe-area-inset-top)) .5rem .4rem 1rem; }
  .iw-viewer-bar p { font-size: .6rem; }
  .iw-viewer-stage { padding: .5rem; }
  .iw-viewer-footer { flex-direction: column; align-items: stretch; gap: .75rem; padding: 1rem 1rem max(.5rem, env(safe-area-inset-bottom)); }
  .iw-viewer-title { font-size: 1.15rem; }
  .iw-viewer-detail { font-size: .66rem; }
  .iw-viewer-controls { justify-content: space-between; }
}
@media (prefers-reduced-motion: reduce) { .iw-enlarge { transition: none; } }
@media print { .inner-worlds { background: #fff; color: #111; padding: 2rem 0; } .iw-enlarge, .iw-origins-heading > p { display: none; } .iw-work { break-inside: avoid; } .iw-heading { padding-block: 2rem; } }
