/* NUMMER18 — shared stylesheet
   The home grid reproduces the existing NUMMER18 homepage 1:1.
   Every other page reuses the same parts: banner, cards, 4px gaps, red hairlines. */

:root {
  --paper: #F1EDE4;
  --ink: #000000;
  --red: #B51F16;
  --grey: #8A837B;
  --line: #B51F16;
  --bw: 1px;
  --gap: 4px;
  --banner-h: 48px;
  --pad: clamp(1rem, 2vw, 2rem);
  --inset: clamp(1rem, 2vw, 1.65rem);
  --font: "Space Mono", "Courier New", monospace;
  color-scheme: light;
}

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

html, body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

.n18-loading {
  position: fixed; inset: 0; display: grid; place-items: center;
  font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
}

/* ---------------------------------------------------------------- BANNER */

.n18-banner {
  position: sticky; top: 0; z-index: 50;
  height: var(--banner-h);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: clamp(.6rem, 1.5vw, 1.5rem);
  padding: 5px max(10px, env(safe-area-inset-right)) 5px max(10px, env(safe-area-inset-left));
  background: var(--banner-bg, var(--paper));
  color: var(--banner-ink, var(--ink));
}
.n18-logo-wrap {
  justify-self: start; min-width: 0; display: flex; align-items: center; gap: .65rem;
  color: var(--banner-ink, var(--ink)); text-decoration: none;
}
.n18-logo { width: auto; max-width: min(28vw, 230px); max-height: calc(var(--banner-h) - 14px); object-fit: contain; }
.n18-logo-text {
  white-space: nowrap; font-size: clamp(.7rem, 1vw, .95rem); font-weight: 700;
  letter-spacing: .04em; text-transform: uppercase;
}
.n18-announcement {
  /* Exactly in the middle of the page; stops before the logo and the menu (--side is measured by the script) */
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  min-width: 0; max-width: calc(100% - 2 * var(--side, 30%)); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font-size: clamp(.56rem, .75vw, .72rem); font-weight: 700; letter-spacing: .04em;
  text-align: center; text-transform: uppercase; color: var(--banner-ink, var(--ink)); text-decoration: none;
}
a.n18-announcement:hover { color: var(--red); }
.n18-nav { grid-column: 3; justify-self: end; min-width: 0; display: flex; align-items: center; justify-content: flex-end; gap: clamp(.55rem, 1.2vw, 1.25rem); white-space: nowrap; }
.n18-nav a {
  color: var(--red); font-size: clamp(.54rem, .7vw, .68rem); font-weight: 700;
  letter-spacing: .02em; text-decoration: none; text-transform: uppercase;
}
.n18-nav a:hover, .n18-nav a:focus-visible, .n18-nav a.is-active { background: var(--red); color: var(--paper); outline: none; }
.n18-menu-toggle { display: none; }

@media (max-width: 760px) {
  .n18-banner { height: auto; min-height: var(--banner-h); grid-template-columns: auto minmax(0, 1fr); row-gap: 4px; padding-top: 8px; padding-bottom: 8px; }
  .n18-nav { grid-column: auto; }
  .n18-announcement { position: static; transform: none; grid-column: 1 / -1; grid-row: 2; max-width: none; font-size: .6rem; line-height: 1.35; text-align: left; white-space: normal; }
  .n18-banner[data-hide-text="true"] .n18-announcement { display: none; }

  /* Menu as a row of links, like the previous website */
  .n18-banner[data-menu="row"] .n18-nav { justify-self: stretch; overflow-x: auto; scrollbar-width: none; gap: .75rem; justify-content: flex-start; padding-left: .75rem;
    -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 .75rem, #000 calc(100% - 1rem), transparent); mask-image: linear-gradient(90deg, transparent 0, #000 .75rem, #000 calc(100% - 1rem), transparent); }
  .n18-banner[data-menu="row"] .n18-nav::-webkit-scrollbar { display: none; }
  .n18-banner[data-menu="row"] .n18-nav a:first-child { margin-left: auto; }
  .n18-banner[data-menu="row"] .n18-nav a { font-size: .62rem; flex: none; }

  /* Menu behind a button */
  .n18-banner[data-menu="button"] .n18-menu-toggle {
    display: block; justify-self: end; border: var(--bw) solid var(--red); background: none; color: var(--red);
    padding: 4px 8px; font-size: .62rem; font-weight: 700; text-transform: uppercase; cursor: pointer;
  }
  .n18-banner[data-menu="button"] .n18-nav {
    position: absolute; top: 100%; left: 0; right: 0;
    display: none; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-top: var(--bw) solid var(--line); border-bottom: var(--bw) solid var(--line);
  }
  .n18-banner[data-menu="button"] .n18-nav.is-open { display: flex; }
  .n18-banner[data-menu="button"] .n18-nav a { font-size: 1.4rem; padding: .55rem 12px; border-bottom: var(--bw) solid var(--line); letter-spacing: -.04em; }
  .n18-banner[data-menu="button"] .n18-nav a:last-child { border-bottom: 0; }
}

/* ---------------------------------------------------------------- CARDS (home language) */

.n18-card {
  position: relative; display: flex; min-width: 0; min-height: 0;
  padding: var(--pad);
  border: var(--bw) solid var(--line);
  background: var(--card-bg, var(--paper));
  color: var(--ink);
  text-align: left; text-decoration: none; font: inherit;
  overflow: hidden; isolation: isolate; cursor: pointer;
  -webkit-appearance: none; appearance: none;
}
.n18-card[data-static] { cursor: default; }
.n18-card-image {
  position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: center; pointer-events: none;
  transition: opacity .18s ease;
}
.n18-card-top {
  position: absolute; top: var(--inset); left: var(--inset); right: var(--inset); z-index: 3;
  display: flex; flex-direction: column; align-items: flex-start;
  gap: clamp(.3rem, .65vw, .55rem); pointer-events: none;
}
.n18-number { color: var(--grey); font-size: .62rem; letter-spacing: .02em; text-transform: uppercase; }
.n18-badge {
  display: inline-block; max-width: 100%; color: var(--red);
  font-size: calc(clamp(1.1rem, 1.9vw, 1.9rem) * var(--bs, .71));
  font-weight: 700; line-height: .92; letter-spacing: -.02em;
  overflow-wrap: anywhere; text-transform: uppercase;
}
.n18-badge:empty { display: none; }

.n18-copy { position: relative; z-index: 2; align-self: flex-end; width: 100%; }
.n18-title {
  display: block; max-width: 13ch;
  color: var(--title-color, var(--ink));
  font-size: calc(clamp(2.4rem, 4.7vw, 6.3rem) * var(--ts, 1));
  font-weight: 400; letter-spacing: -.075em; line-height: .87;
  overflow-wrap: anywhere; text-transform: uppercase;
}
.n18-title[data-bold="true"] { font-weight: 700; }
/* "Keep on one line": the script shrinks the title until it fits */
.n18-title[data-fit] { overflow-wrap: normal; word-break: normal; hyphens: none; }
.n18-meta {
  display: block; margin-top: 1rem; color: var(--red);
  font-size: calc(clamp(.56rem, .78vw, .76rem) * var(--ms, 1));
  font-weight: 700; letter-spacing: .05em; line-height: 1.4; text-transform: uppercase;
}

/* Card colour styles */
.n18-card[data-style="paper"] { --card-bg: var(--paper); }
.n18-card[data-style="white"] { --card-bg: #FFFFFF; }
.n18-card[data-style="red"]   { --card-bg: var(--red); }
.n18-card[data-style="black"] { --card-bg: #000000; }
.n18-card[data-style="event"] { --card-bg: var(--event); }
.n18-card[data-style="event"] .n18-number, .n18-card[data-style="event"] .n18-meta, .n18-card[data-style="event"] .n18-badge, .n18-card[data-style="event"] .n18-title { color: var(--event-ink) !important; }
.n18-card[data-style="red"] .n18-number, .n18-card[data-style="red"] .n18-meta, .n18-card[data-style="red"] .n18-badge,
.n18-card[data-style="black"] .n18-number, .n18-card[data-style="black"] .n18-meta, .n18-card[data-style="black"] .n18-badge,
.n18-card[data-has-image="true"] .n18-number, .n18-card[data-has-image="true"] .n18-meta, .n18-card[data-has-image="true"] .n18-badge {
  color: var(--paper);
}
.n18-card[data-style="red"] .n18-number, .n18-card[data-style="black"] .n18-number, .n18-card[data-has-image="true"] .n18-number { font-weight: 700; }

/* Hover: same as today — the card fills with the chosen colour, text turns white on red */
.n18-card[data-hover="red"]:hover, .n18-card[data-hover="red"]:focus-visible { --card-bg: var(--red); outline: none; }
.n18-card[data-hover="black"]:hover, .n18-card[data-hover="black"]:focus-visible { --card-bg: #000; outline: none; }
.n18-card[data-hover="paper"]:hover, .n18-card[data-hover="paper"]:focus-visible { --card-bg: var(--paper); outline: none; }
.n18-card[data-hover="red"]:hover *, .n18-card[data-hover="red"]:focus-visible *,
.n18-card[data-hover="black"]:hover *, .n18-card[data-hover="black"]:focus-visible * { color: #FFFFFF; }
.n18-card[data-hover="red"]:hover .n18-card-image, .n18-card[data-hover="black"]:hover .n18-card-image { opacity: .12 !important; }
.n18-card[data-hover="same"]:focus-visible { outline: 2px solid var(--ink); outline-offset: -4px; }

/* ---------------------------------------------------------------- HOME */

body.page-home { height: 100dvh; overflow: hidden; }
.n18-home-grid {
  position: fixed; top: var(--banner-h); left: 0; right: 0; bottom: 0;
  display: grid;
  grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr));
  grid-template-rows: repeat(var(--rows, 2), minmax(0, 1fr));
  gap: var(--gap); padding: var(--gap) var(--gap) calc(var(--gap) + 2px);
}
.n18-home-grid > .n18-card { grid-column: span var(--cs, 1); grid-row: span var(--rs, 1); }

@media (max-width: 760px) {
  body.page-home { height: auto; overflow: auto; }
  .n18-home-grid {
    position: static; min-height: calc(100dvh - var(--banner-h));
    grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; grid-auto-rows: 16.25rem;
  }
  .n18-home-grid > .n18-card { grid-column: span 1; grid-row: span 1; flex-direction: column; justify-content: flex-start; }
  .n18-home-grid > .n18-card:first-child { grid-column: 1 / -1; }
  .n18-home-grid .n18-card-top { position: relative; top: auto; left: auto; right: auto; margin-bottom: .75rem; }
  .n18-home-grid .n18-copy { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: flex-end; min-height: 0; overflow: hidden; }
  .n18-home-grid .n18-title { font-size: calc(clamp(1.45rem, 6.5vw, 2.35rem) * var(--ts, 1)); line-height: .88; max-width: 100%; }
  .n18-home-grid .n18-meta { margin-top: clamp(.65rem, 2.5vw, 1rem); font-size: calc(.6rem * var(--ms, 1)); }
  .n18-badge { font-size: calc(clamp(1.05rem, 4.8vw, 1.4rem) * var(--bs, .71)); }
}
@media (max-width: 430px) {
  .n18-home-grid > .n18-card { padding: .8rem; }
}

/* ---------------------------------------------------------------- POPUP (from the current homepage) */

.n18-veil { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: clamp(10px, 2vw, 24px); background: rgba(241, 237, 228, .82); }
.n18-veil[hidden] { display: none; }
.n18-dialog {
  position: relative; width: min(760px, calc(100vw - 48px)); max-height: calc(100dvh - 56px);
  display: grid; grid-template-rows: auto minmax(0, 1fr);
  border: 2px solid var(--red); background: var(--paper); color: var(--ink); overflow: hidden;
  animation: n18-open .14s ease-out both;
}
.n18-dialog-head {
  display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 14px;
  padding: 6px 9px; background: var(--ink); color: var(--paper);
  font-size: clamp(.66rem, .8vw, .82rem); font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
}
.n18-dialog-close { border: 0; background: none; color: inherit; padding: 0; cursor: pointer; font-weight: 700; text-transform: uppercase; }
.n18-dialog-close:hover, .n18-dialog-close:focus-visible { background: var(--red); outline: none; }
.n18-dialog-body { min-height: 0; overflow: auto; display: grid; grid-template-columns: minmax(0, 1fr) minmax(150px, 30%); }
.n18-dialog-body.no-image { grid-template-columns: 1fr; }
.n18-dialog-copy { padding: clamp(16px, 2.8vw, 30px); border-right: 2px solid var(--ink); }
.n18-dialog-body.no-image .n18-dialog-copy { border-right: 0; }
.n18-dialog-copy::before {
  content: "NUMMER18 // RECORD DETAILS"; display: block; margin-bottom: 18px;
  color: var(--red); font-size: clamp(.62rem, .76vw, .76rem); font-weight: 700; letter-spacing: .04em;
}
.n18-dialog-title {
  display: inline; margin: 0; padding: 2px 4px; background: var(--ink); color: var(--paper);
  font-size: clamp(1.75rem, 3.6vw, 3.8rem); font-weight: 400; line-height: 1.05; letter-spacing: -.04em;
  text-transform: uppercase; -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.n18-dialog-text { margin: 22px 0 0; max-width: 64ch; font-size: clamp(.76rem, .88vw, .9rem); line-height: 1.42; white-space: pre-wrap; }
.n18-dialog-text::before { content: "> "; color: var(--red); font-weight: 700; }
.n18-dialog-text.is-typing::after { content: "_"; color: var(--red); animation: n18-blink .5s steps(1, end) infinite; }
.n18-dialog-image { padding: clamp(12px, 2vw, 22px); }
.n18-dialog-image img { width: 100%; max-height: 48vh; object-fit: contain; object-position: top right; border: 2px solid var(--ink); }
.n18-dialog-action { margin-top: 24px; }
@media (max-width: 760px) {
  .n18-dialog { width: calc(100vw - 28px); }
  .n18-dialog-body { grid-template-columns: 1fr; }
  .n18-dialog-copy { border-right: 0; border-bottom: 2px solid var(--ink); }
  .n18-dialog-image img { max-height: 24vh; object-position: top left; }
}
@keyframes n18-open { from { transform: scale(.985); } to { transform: scale(1); } }
@keyframes n18-blink { 50% { opacity: 0; } }

/* ---------------------------------------------------------------- BUTTONS */

.n18-button {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: 12px 16px; border: var(--bw) solid var(--red); background: transparent; color: var(--red);
  font-size: .72rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; text-decoration: none; cursor: pointer;
}
.n18-button:hover, .n18-button:focus-visible { background: var(--red); color: var(--paper); outline: none; }
.n18-button.is-solid { background: var(--red); color: var(--paper); }
.n18-button.is-solid:hover { background: var(--ink); border-color: var(--ink); }
.n18-button[disabled] { opacity: .4; cursor: not-allowed; }
.n18-link { color: var(--red); text-decoration: underline; text-underline-offset: .18em; }

/* ---------------------------------------------------------------- INNER PAGES */

.n18-page { padding: var(--gap); min-height: calc(100dvh - var(--banner-h)); }
.n18-page-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
  padding: clamp(1.5rem, 4vw, 4rem) var(--inset) clamp(1rem, 2vw, 1.6rem);
}
.n18-page-title {
  margin: 0; font-size: clamp(3rem, 9vw, 9.5rem); font-weight: 400; letter-spacing: -.075em; line-height: .82; text-transform: uppercase;
}
.n18-page-title .n18-arrow { color: var(--red); font-size: .45em; vertical-align: .55em; margin-left: .08em; letter-spacing: 0; }
.n18-page-sub { max-width: 52ch; margin: 0; font-size: .74rem; line-height: 1.55; text-transform: uppercase; }
.n18-tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.n18-tiles > .n18-card { aspect-ratio: 1 / 1; }
.n18-tiles .n18-title { font-size: clamp(1.6rem, 2.9vw, 3.6rem); }
@media (max-width: 1000px) { .n18-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 520px)  {
  .n18-tiles .n18-card { padding: .75rem; }
  .n18-tiles .n18-card-top { top: .75rem; left: .75rem; right: .75rem; gap: .25rem; }
  .n18-tiles .n18-title { font-size: clamp(1.05rem, 5.6vw, 1.5rem); line-height: .9; }
  .n18-tiles .n18-badge { font-size: .68rem; }
  .n18-tiles .n18-number, .n18-tiles .n18-meta { font-size: .5rem; }
  .n18-tiles .n18-meta { margin-top: .4rem; }
  .n18-page-head { padding: 1.4rem .75rem 1rem; }
}
.n18-empty { padding: 2rem var(--inset); font-size: .74rem; text-transform: uppercase; color: var(--grey); }

/* Archive tiles: poster in red, full colour on hover */
.n18-tile-image .n18-title { color: var(--paper); }

/* Section dividers */
.n18-year {
  grid-column: 1 / -1; margin: 0; padding: clamp(1.4rem, 3vw, 2.4rem) var(--inset) .5rem; text-transform: uppercase;
  font-size: clamp(1.6rem, 3vw, 3rem); font-weight: 700; letter-spacing: -.06em; color: var(--red);
  border-bottom: var(--bw) solid var(--line);
}

/* ---------------------------------------------------------------- EXHIBITION DETAIL */

.n18-panel { border: var(--bw) solid var(--line); padding: var(--pad); background: var(--paper); min-width: 0; }
.n18-label { display: block; margin: 0 0 .9rem; color: var(--grey); font-size: .62rem; text-transform: uppercase; letter-spacing: .02em; }
.n18-body { margin: 0; max-width: 62ch; font-size: clamp(.8rem, .95vw, .95rem); line-height: 1.6; white-space: pre-line; }
.n18-openings { list-style: none; margin: 0; padding: 0; }
.n18-openings li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; align-items: baseline;
  padding: .45rem 0; border-bottom: var(--bw) solid var(--line);
  font-size: clamp(.95rem, 1.6vw, 1.6rem); font-weight: 700; letter-spacing: -.04em; text-transform: uppercase; color: var(--red);
}
.n18-openings li:first-child { border-top: var(--bw) solid var(--line); }
.n18-openings li.is-past { color: var(--grey); text-decoration: line-through; text-decoration-thickness: 1px; }
.n18-openings small { font-size: .62rem; letter-spacing: .02em; font-weight: 700; }

/* ---------------------------------------------------------------- CALENDAR */

.n18-cal-wrap { padding: clamp(1rem, 3vw, 3rem) clamp(.5rem, 3vw, 4.4rem) clamp(2rem, 4vw, 4rem); }
.n18-hours-strip {
  display: flex; flex-wrap: wrap; gap: .4rem 1.6rem; align-items: baseline; margin-bottom: clamp(.8rem, 1.5vw, 1.2rem);
  font-size: clamp(.7rem, 1.1vw, 1.05rem); font-weight: 700; text-transform: uppercase; letter-spacing: -.01em;
}
.n18-hours-strip span:first-child { color: var(--red); }
.n18-cal { border: 2px solid var(--ink); }
.n18-cal-week, .n18-cal-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.n18-cal-week { border-bottom: 2px solid var(--ink); }
.n18-cal-week div, .n18-cal-day {
  min-width: 0; overflow: hidden; white-space: nowrap; text-transform: uppercase; font-weight: 700;
  font-size: clamp(18px, 3.2vw, 54px); line-height: .9; letter-spacing: -.065em;
  padding: clamp(4px, .6vw, 10px) 2px; border-right: 1px solid var(--ink);
}
.n18-cal-week div:nth-child(7n), .n18-cal-day:nth-child(7n) { border-right: 0; }
.n18-cal-day { position: relative; height: clamp(42px, 6.1vw, 92px); padding: 3px 2px; border-bottom: 1px solid var(--ink); background: var(--paper); }
.n18-cal-days .n18-cal-day:nth-last-child(-n+7) { border-bottom: 0; }
.n18-cal-day.is-blank { color: transparent; }
.n18-cal-day.is-past { color: var(--grey); opacity: .45; }
.n18-cal-day.is-today { outline: 3px solid var(--ink); outline-offset: -3px; }
.n18-cal-day.is-open { background: var(--red); color: var(--paper); cursor: pointer; text-decoration: none; display: flex; flex-direction: column; justify-content: space-between; white-space: normal; }
.n18-cal-day.is-open:hover, .n18-cal-day.is-open:focus-visible { background: var(--ink); outline: none; }
.n18-cal-day.is-open.is-today { outline-color: var(--ink); }
.n18-cal-day .n18-cal-title { display: block; font-size: clamp(9px, 1.25vw, 19px); line-height: .9; letter-spacing: -.04em; padding-right: 3.2em; }
.n18-cal-day .n18-cal-time { position: absolute; right: 3px; bottom: 3px; font-size: clamp(7px, .7vw, 11px); letter-spacing: 0; line-height: 1; }
.n18-cal-month { grid-column: 1 / -1; }
.n18-cal-list { margin: .6rem 0 clamp(1.5rem, 3vw, 2.6rem); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.n18-cal-list .n18-panel { min-height: 9rem; display: flex; flex-direction: column; justify-content: space-between; text-decoration: none; }
.n18-cal-list .n18-panel:hover { background: var(--red); color: #fff; }
.n18-cal-list .n18-panel:hover * { color: #fff; }
.n18-cal-list strong { display: block; font-size: clamp(1.6rem, 2.6vw, 2.8rem); letter-spacing: -.07em; line-height: .9; text-transform: uppercase; }
.n18-cal-list span { font-size: .66rem; font-weight: 700; text-transform: uppercase; color: var(--red); }
@media (max-width: 760px) {
  .n18-cal-week div { font-size: clamp(9px, 3.2vw, 15px); letter-spacing: -.03em; }
  .n18-cal-day { height: clamp(34px, 11vw, 56px); font-size: clamp(10px, 3.7vw, 18px); letter-spacing: -.055em; }
  .n18-cal-day .n18-cal-title { display: none; }
  .n18-cal-day .n18-cal-time { font-size: clamp(7px, 2.2vw, 10px); }
  .n18-cal-list { grid-template-columns: 1fr 1fr; }
}

/* ---------------------------------------------------------------- CONTACT */

.n18-form { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.n18-form .full { grid-column: 1 / -1; }
.n18-field { display: grid; gap: 5px; font-size: .7rem; text-transform: uppercase; color: var(--red); }
.n18-field input, .n18-field textarea, .n18-field select {
  width: 100%; padding: 10px; border: var(--bw) solid var(--line); background: var(--paper); color: var(--ink);
  font-size: .9rem; border-radius: 0;
}
.n18-field textarea { min-height: 9rem; resize: vertical; }
.n18-field input:focus, .n18-field textarea:focus, .n18-field select:focus { outline: 2px solid var(--red); outline-offset: -1px; }
.n18-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.n18-form-status { grid-column: 1 / -1; min-height: 1.2em; font-size: .72rem; font-weight: 700; text-transform: uppercase; }
.n18-form-status.is-error { color: var(--red); }
@media (max-width: 560px) { .n18-form { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- SHOP */

.n18-products { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: var(--gap); }
.n18-product { display: grid; grid-template-rows: auto 1fr; border: var(--bw) solid var(--line); background: var(--paper); min-width: 0; }
.n18-product-image { position: relative; aspect-ratio: 4 / 5; border-bottom: var(--bw) solid var(--line); background: #E6E1D6; overflow: hidden; display: grid; place-items: center; }
.n18-product-image img { width: 100%; height: 100%; object-fit: cover; }
.n18-product-image img.n18-placeholder { width: 26%; height: auto; object-fit: contain; opacity: .35; }
.n18-sold { position: absolute; top: var(--inset); left: var(--inset); background: var(--ink); color: var(--paper); font-size: .7rem; font-weight: 700; padding: 3px 6px; text-transform: uppercase; }
.n18-product-copy { padding: clamp(.8rem, 1.4vw, 1.4rem); display: flex; flex-direction: column; gap: .4rem; }
.n18-product-copy .n18-badge { font-size: clamp(.85rem, 1.2vw, 1.15rem); }
.n18-product-title { margin: 0; font-size: clamp(1.1rem, 1.7vw, 1.9rem); font-weight: 400; letter-spacing: -.07em; line-height: .9; text-transform: uppercase; }
.n18-product-details { font-size: .66rem; color: var(--grey); text-transform: uppercase; }
.n18-product-desc { margin: .2rem 0 0; font-size: .74rem; line-height: 1.5; }
.n18-product-buy { margin-top: auto; padding-top: 1rem; display: flex; justify-content: space-between; align-items: center; gap: .6rem; flex-wrap: wrap; }
.n18-price { font-size: clamp(1.1rem, 1.6vw, 1.6rem); font-weight: 700; letter-spacing: -.05em; color: var(--red); }
.n18-pay-note { display: flex; align-items: center; gap: .6rem; margin-top: var(--gap); padding: .8rem var(--inset); border: var(--bw) solid var(--line); font-size: .66rem; font-weight: 700; text-transform: uppercase; }
.n18-bancontact { display: inline-flex; align-items: center; gap: 6px; }
.n18-bancontact i { display: inline-block; width: 10px; height: 10px; background: #005498; }
.n18-bancontact i + i { background: #FFD800; margin-left: -4px; }
@media (max-width: 1200px) { .n18-products { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 900px) { .n18-products { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) {
  .n18-products { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .n18-product-copy { padding: .7rem; gap: .3rem; }
  .n18-product-copy .n18-badge { font-size: .68rem; }
  .n18-product-title { font-size: 1.05rem; }
  .n18-product-desc { display: none; }
  .n18-product-details { font-size: .55rem; }
  .n18-product-buy { padding-top: .6rem; }
  .n18-price { font-size: 1rem; }
  .n18-product-buy .n18-button { padding: 8px 10px; font-size: .6rem; }
}

.n18-checkout .n18-dialog-body { grid-template-columns: 1fr; }
.n18-checkout .n18-dialog-copy { border-right: 0; }
.n18-checkout .n18-dialog-copy::before { content: "NUMMER18 // BESTELLING"; }
.n18-summary { display: grid; grid-template-columns: 1fr auto; gap: .3rem 1rem; margin: 1.2rem 0; padding: .8rem 0; border-top: var(--bw) solid var(--line); border-bottom: var(--bw) solid var(--line); font-size: .78rem; text-transform: uppercase; }
.n18-summary strong { font-size: 1rem; }
.n18-choice { display: flex; gap: .6rem; align-items: flex-start; padding: .7rem; border: var(--bw) solid var(--line); cursor: pointer; font-size: .74rem; text-transform: uppercase; color: var(--ink); }
.n18-choice input { accent-color: var(--red); margin-top: 2px; }
.n18-choice:has(input:checked) { background: var(--red); color: var(--paper); }

/* ---------------------------------------------------------------- RESULT PAGE */

.n18-result { min-height: calc(100dvh - var(--banner-h) - 2 * var(--gap)); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.n18-result > .n18-card { grid-column: span 2; }
.n18-result .n18-panel { grid-column: span 2; display: flex; flex-direction: column; justify-content: flex-end; gap: 1rem; }
@media (max-width: 760px) { .n18-result { grid-template-columns: 1fr; } .n18-result > * { grid-column: auto !important; min-height: 50vh; } }

/* ---------------------------------------------------------------- FOOTER */

.n18-footer { margin-top: clamp(2rem, 6vw, 6rem); border-top: var(--bw) solid var(--line); padding: 0 clamp(1rem, 3vw, 4.4rem) 1.6rem; }
.n18-footer-inner {
  display: grid; grid-template-columns: 1.2fr 1.6fr 1.4fr 1.2fr; gap: 1.5rem; align-items: start;
  border-top: var(--bw) solid var(--line); margin-top: 1.4rem; padding-top: 2.2rem;
  font-size: clamp(.7rem, .85vw, .86rem); text-transform: uppercase; color: var(--red); line-height: 1.55;
}
.n18-footer h2 { margin: 0; font-size: inherit; font-weight: 700; }
.n18-footer h2::after { content: " \25BC"; }
.n18-footer ul { list-style: none; margin: 0; padding: 0; }
.n18-footer a { color: var(--red); text-underline-offset: .18em; }
.n18-footer-brand { display: flex; flex-direction: column; gap: .8rem; align-self: end; }
.n18-footer-brand img { width: 42px; }
.n18-footer-brand span::before { content: "\25A0  "; }
@media (max-width: 760px) { .n18-footer-inner { grid-template-columns: 1fr 1fr; } .n18-footer-brand { grid-column: 1 / -1; order: 9; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}


/* ================================================================ FULL-SCREEN PAGES (contact, exhibition) */

.n18-fit { height: calc(100dvh - var(--banner-h)); min-height: 560px; padding: var(--gap) var(--gap) calc(var(--gap) + 2px); }
.n18-cc {
  position: relative; min-width: 0; min-height: 0; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between; gap: 1rem;
  padding: clamp(.9rem, min(2vw, 3.4vh), 2rem); border: var(--bw) solid var(--line); background: var(--paper); color: var(--ink);
}
.n18-cc-label { color: var(--grey); font-size: .62rem; letter-spacing: .02em; text-transform: uppercase; }
.n18-cc-meta { color: var(--red); font-size: clamp(.54rem, min(.78vw, 1.35vh), .76rem); font-weight: 700; letter-spacing: .05em; line-height: 1.6; text-transform: uppercase; }
.n18-cc-meta a { color: inherit; text-decoration: none; }
.n18-cc-meta a:hover { text-decoration: underline; text-underline-offset: .2em; }
.n18-cc.is-red { background: var(--red); border-color: var(--red); color: var(--paper); }
.n18-cc.is-red .n18-cc-label, .n18-cc.is-red .n18-cc-meta { color: var(--paper); }
.n18-cc.is-red .n18-cc-label { font-weight: 700; }

/* ---------- CONTACT: hours, about, map, message */
.n18-contact { height: 100%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: repeat(2, minmax(0, 1fr)); gap: var(--gap); }
.n18-contact > * { grid-column: span 2; }
.n18-hours-big { margin: 0; font-size: clamp(1.6rem, min(4.3vw, 7.5vh), 5.6rem); font-weight: 700; letter-spacing: -.075em; line-height: .9; text-transform: uppercase; }
.n18-hours-big span { display: block; }
.n18-lead { margin: 0; max-width: 18ch; font-size: clamp(1.3rem, min(3vw, 5vh), 4rem); font-weight: 400; letter-spacing: -.07em; line-height: .9; text-transform: uppercase; }
.n18-intro { margin: clamp(.4rem, 1.4vh, .9rem) 0 0; max-width: 52ch; font-size: clamp(.6rem, min(.8vw, 1.4vh), .8rem); line-height: 1.55; text-transform: uppercase; }
.n18-cc.is-map { padding: 0; }
.n18-cc.is-map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; filter: grayscale(1) sepia(.18) contrast(1.05) brightness(1.02); }
.n18-cc.is-map .n18-cc-label { position: absolute; top: var(--inset); left: var(--inset); z-index: 2; padding: 3px 6px; background: var(--paper); }
.n18-map-link {
  position: absolute; left: var(--inset); bottom: var(--inset); z-index: 2; padding: .45rem .6rem;
  background: var(--red); color: var(--paper); text-decoration: none;
  font-size: clamp(.7rem, 1vw, 1rem); font-weight: 700; letter-spacing: .02em; text-transform: uppercase;
}
.n18-map-link:hover { background: var(--ink); }
.n18-message { flex: 1 1 auto; min-height: 0; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: auto auto minmax(3rem, 1fr) auto; gap: clamp(.5rem, 1.6vh, 1rem) 1.2rem; }
.n18-message .full { grid-column: 1 / -1; }
.n18-line { display: flex; flex-direction: column; gap: 2px; min-height: 0; }
.n18-line > span { color: var(--grey); font-size: .58rem; letter-spacing: .03em; text-transform: uppercase; }
.n18-line input, .n18-line textarea {
  width: 100%; padding: 4px 0 6px; border: 0; border-bottom: var(--bw) solid var(--line); border-radius: 0;
  background: transparent; color: var(--ink); font-size: clamp(.8rem, .95vw, .95rem);
}
.n18-line textarea { flex: 1 1 auto; min-height: 2.6rem; resize: none; }
.n18-line input:focus, .n18-line textarea:focus { outline: none; border-bottom-color: var(--ink); border-bottom-width: 2px; }
.n18-send { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.n18-send button {
  border: 0; padding: 0; background: none; color: var(--red); cursor: pointer;
  font-size: clamp(.9rem, 1.3vw, 1.3rem); font-weight: 700; letter-spacing: -.03em; text-transform: uppercase;
}
.n18-send button:hover, .n18-send button:focus-visible { text-decoration: underline; text-underline-offset: .18em; outline: none; }
.n18-send .n18-form-status { grid-column: auto; margin: 0; text-align: right; }

/* ---------- EXHIBITION: photo left; opening days, text and gallery right */
.n18-expo { height: 100%; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-template-rows: auto minmax(0, 1fr) auto; gap: var(--gap); }
.n18-expo.no-gallery { grid-template-rows: auto minmax(0, 1fr); }
.n18-expo > .n18-card { grid-column: 1 / 3; grid-row: 1 / -1; }
.n18-expo .n18-title { font-size: calc(clamp(2.4rem, min(5.4vw, 11vh), 7rem) * var(--ts, 1)); max-width: 14ch; }
.n18-expo-open { grid-column: 3 / 5; grid-row: 1; }
.n18-expo-text { grid-column: 3 / 5; grid-row: 2; justify-content: flex-start; overflow: auto; }
.n18-expo-text .n18-body { font-size: clamp(.74rem, .9vw, .92rem); }
.n18-openings { list-style: none; margin: 0; padding: 0; }
.n18-openings li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 1rem; align-items: baseline;
  padding: clamp(.2rem, .6vh, .45rem) 0; border-bottom: var(--bw) solid var(--line);
  color: var(--red); font-size: clamp(.85rem, min(1.4vw, 2.6vh), 1.5rem); font-weight: 700; letter-spacing: -.045em; text-transform: uppercase;
}
.n18-openings li:first-child { border-top: var(--bw) solid var(--line); }
.n18-openings li.is-past { color: var(--grey); text-decoration: line-through; text-decoration-thickness: 1px; }
.n18-openings small { font-size: .58rem; letter-spacing: .02em; }
.n18-expo-gallery { grid-column: 3 / 5; grid-row: 3; height: clamp(84px, 19vh, 230px); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.n18-thumb { position: relative; padding: 0; border: var(--bw) solid var(--line); background: var(--paper); overflow: hidden; cursor: zoom-in; }
.n18-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.n18-thumb:hover img { transform: scale(1.04); }
.n18-thumb:nth-child(n+5) { display: none; }
.n18-thumb .n18-more {
  position: absolute; inset: 0; display: grid; place-items: center; background: rgba(181, 31, 22, .82); color: var(--paper);
  font-size: clamp(1.2rem, 2.2vw, 2.4rem); font-weight: 700; letter-spacing: -.06em;
}

@media (max-width: 900px), (max-height: 520px) {
  .n18-fit { height: auto; min-height: 0; }
  .n18-contact, .n18-expo { height: auto; grid-template-columns: 1fr; grid-template-rows: none; }
  .n18-contact > *, .n18-expo > * { grid-column: auto !important; grid-row: auto !important; }
  .n18-contact > .n18-cc { min-height: 19rem; }
  .n18-contact > .is-form { min-height: 0; }
  .n18-hours-big { font-size: clamp(1.5rem, 8.4vw, 3.2rem); }
  .n18-lead { font-size: clamp(1.6rem, 8.5vw, 2.8rem); }
  .n18-message { grid-template-rows: auto; }
  .n18-line textarea { min-height: 8rem; }
  .n18-expo > .n18-card { min-height: 72vh; }
  .n18-expo .n18-title { font-size: calc(clamp(1.9rem, 11vw, 3.4rem) * var(--ts, 1)); }
  .n18-expo-gallery { height: auto; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .n18-thumb { aspect-ratio: 1 / 1; }
  .n18-thumb:nth-child(n+5) { display: block; }
  .n18-thumb .n18-more { display: none; }
}

/* ---------- KALENDER: next opening days share the calendar's 7 columns and lines */
.n18-cal-next { margin-bottom: clamp(1.2rem, 2.4vw, 2.2rem); }
.n18-cal-next-head {
  padding: clamp(4px, .6vw, 10px) 4px; border-bottom: 2px solid var(--ink);
  font-size: clamp(14px, 1.6vw, 26px); font-weight: 700; letter-spacing: -.04em; line-height: 1; text-transform: uppercase; color: var(--red);
}
.n18-cal-next .n18-cal-day { height: auto; min-height: clamp(64px, 7.5vw, 112px); border-bottom: 0; }
.n18-next-day { display: flex; flex-direction: column; justify-content: space-between; gap: 6px; color: var(--red); text-decoration: none; white-space: normal; }
.n18-next-day span { font-size: clamp(14px, 2.1vw, 36px); line-height: .9; letter-spacing: -.06em; }
.n18-next-day small { font-size: clamp(8px, .72vw, 12px); line-height: 1.3; letter-spacing: .02em; font-weight: 700; }
.n18-next-day:hover, .n18-next-day:focus-visible { background: var(--red); color: var(--paper); outline: none; }
.n18-next-none { grid-column: 1 / -1; white-space: normal; font-size: clamp(11px, 1vw, 15px); letter-spacing: 0; font-weight: 700; color: var(--grey); }
@media (max-width: 760px) {
  .n18-cal-next .n18-cal-days { grid-template-columns: 1fr; }
  .n18-cal-next .n18-cal-days .n18-cal-day { min-height: 0; border-right: 0; border-bottom: 1px solid var(--ink); flex-direction: row; align-items: center; padding: 8px 6px; }
  .n18-cal-next .n18-cal-days .n18-cal-day:last-child { border-bottom: 0; }
  .n18-cal-next .n18-cal-day.is-blank { display: none; }
  .n18-next-day span { font-size: 22px; }
  .n18-next-day small { font-size: 10px; text-align: right; }
}

/* ---------- CONTACT: editorial layout, hairlines instead of boxes */
.n18-ct {
  height: 100%; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); grid-template-rows: minmax(0, 1.1fr) minmax(0, 1fr);
  border-top: var(--bw) solid var(--line); border-bottom: var(--bw) solid var(--line);
}
.n18-ct > section { position: relative; min-width: 0; min-height: 0; display: flex; flex-direction: column; justify-content: space-between; gap: clamp(.4rem, 1.5vh, 1.4rem); padding: clamp(.9rem, min(3vw, 3.8vh), 3.4rem) clamp(1.1rem, 3vw, 3.4rem); }
.n18-ct-hours, .n18-ct-map { border-right: var(--bw) solid var(--line); }
.n18-ct-hours, .n18-ct-about { border-bottom: var(--bw) solid var(--line); }
.n18-ct .n18-cc-label { font-weight: 700; }

.n18-ct-times { margin: 0; display: grid; grid-template-columns: auto 1fr; column-gap: clamp(1rem, 3vw, 3rem); row-gap: .05em; align-items: baseline;
  font-size: clamp(1.7rem, min(5.2vw, 9vh), 7rem); line-height: .95; letter-spacing: -.075em; text-transform: uppercase; }
.n18-ct-times dt { font-weight: 400; color: var(--ink); }
.n18-ct-times dd { margin: 0; font-weight: 700; color: var(--red); }
.n18-ct-note { margin: 0; max-width: 54ch; font-size: clamp(.6rem, min(.8vw, 1.4vh), .8rem); line-height: 1.6; text-transform: uppercase; letter-spacing: .03em; }
.n18-ct-note strong { color: var(--red); }

.n18-ct-lead { margin: 0; max-width: 20ch; font-size: clamp(1.05rem, min(2.2vw, 3.7vh), 3.1rem); font-weight: 400; letter-spacing: -.065em; line-height: .95; text-transform: uppercase; white-space: pre-line; }
.n18-ct-intro { margin: clamp(.5rem, 1.6vh, 1rem) 0 0; max-width: 46ch; font-size: clamp(.6rem, min(.78vw, 1.35vh), .78rem); line-height: 1.6; text-transform: uppercase; }
.n18-ct-details { list-style: none; margin: 0; padding: 0; border-top: var(--bw) solid var(--line); }
.n18-ct-details li { display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: 1rem; align-items: baseline; padding: clamp(.18rem, .7vh, .55rem) 0; border-bottom: var(--bw) solid var(--line);
  font-size: clamp(.62rem, min(.85vw, 1.5vh), .86rem); text-transform: uppercase; }
.n18-ct-details span { color: var(--grey); font-size: .85em; letter-spacing: .03em; }
.n18-ct-details a { color: var(--ink); font-weight: 700; text-decoration: none; overflow-wrap: anywhere; }
.n18-ct-details a:hover, .n18-ct-details a:focus-visible { color: var(--red); outline: none; }

.n18-ct-map { justify-content: flex-start; }
.n18-ct-frame { position: relative; flex: 1 1 auto; min-height: 9rem; overflow: hidden; }
.n18-ct-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; filter: grayscale(1) sepia(.15) contrast(1.05); }
.n18-ct-frame .n18-map-link { left: 0; bottom: 0; }

.n18-ct-formtext { margin: .5rem 0 0; color: var(--red); font-size: clamp(.58rem, min(.78vw, 1.35vh), .76rem); font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }

@media (max-width: 900px), (max-height: 520px) {
  .n18-ct { height: auto; grid-template-columns: 1fr; grid-template-rows: none; }
  .n18-ct > section { border-right: 0 !important; border-bottom: var(--bw) solid var(--line); padding: 1.6rem 1rem; }
  .n18-ct > section:last-child { border-bottom: 0; }
  .n18-ct-times { font-size: clamp(1.7rem, 9.5vw, 3.4rem); }
  .n18-ct-lead { font-size: clamp(1.4rem, 7.5vw, 2.4rem); }
  .n18-ct-frame { min-height: 18rem; }
}

@media (min-width: 901px) and (max-height: 800px) {
  .n18-ct-intro { display: none; } /* very short screens: the headline and the details list are enough */
}

/* ---------- SHOP: small prints, lots of room, like a wall in the gallery */
.n18-shop { padding-left: clamp(1rem, 5vw, 6rem); padding-right: clamp(1rem, 5vw, 6rem); }
.n18-shop .n18-page-head { padding-left: 0; padding-right: 0; }
.n18-shelf {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 210px), 1fr));
  gap: clamp(2.4rem, 5vw, 5rem) clamp(1.4rem, 3.5vw, 3.6rem);
  padding: clamp(1rem, 3vw, 3rem) 0 clamp(2rem, 5vw, 5rem); border-top: var(--bw) solid var(--line);
}
.n18-item { display: flex; flex-direction: column; gap: .9rem; min-width: 0; max-width: 300px; }
.n18-item-image { position: relative; display: block; padding: 0; border: 0; background: transparent; overflow: hidden; cursor: pointer; }
.n18-item-image img { width: 100%; height: auto; display: block; transition: transform .4s ease; }
/* Image shape, chosen in the CMS: as uploaded (default), portrait or square */
.n18-shelf.shape-natural { align-items: end; }
.n18-shelf.shape-portrait .n18-item-image, .n18-shelf.shape-square .n18-item-image { display: grid; place-items: center; }
.n18-shelf.shape-portrait .n18-item-image { aspect-ratio: 4 / 5; }
.n18-shelf.shape-square .n18-item-image { aspect-ratio: 1 / 1; }
.n18-shelf.shape-portrait .n18-item-image img, .n18-shelf.shape-square .n18-item-image img { height: 100%; object-fit: cover; }
.n18-shelf.shape-natural .n18-item-image:has(.n18-placeholder) { aspect-ratio: 4 / 5; display: grid; place-items: center; }
.n18-item-image img.n18-placeholder { width: 30%; height: auto; object-fit: contain; opacity: .35; }
.n18-item-image:hover img, .n18-item-image:focus-visible img { transform: scale(1.025); }
.n18-item-image:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
.n18-item.is-sold .n18-item-image { cursor: default; }
.n18-item.is-sold .n18-item-image img { opacity: .5; filter: grayscale(.6); }
.n18-item-copy { display: flex; flex-direction: column; gap: .25rem; }
.n18-item-artist { color: var(--red); font-size: .62rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.n18-item-title { margin: 0; font-size: clamp(1rem, 1.25vw, 1.3rem); font-weight: 400; letter-spacing: -.06em; line-height: 1; text-transform: uppercase; }
.n18-item-details { color: var(--grey); font-size: .6rem; letter-spacing: .02em; text-transform: uppercase; }
.n18-item-buy { display: flex; justify-content: space-between; align-items: baseline; margin-top: .55rem; padding-top: .55rem; border-top: var(--bw) solid var(--line); }
.n18-item-price { font-size: .9rem; font-weight: 700; letter-spacing: -.03em; }
.n18-item-cta { border: 0; padding: 0; background: none; color: var(--red); cursor: pointer; font-size: .72rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
.n18-item-cta:hover, .n18-item-cta:focus-visible { text-decoration: underline; text-underline-offset: .2em; outline: none; }
.n18-item-out { color: var(--grey); font-size: .66rem; font-weight: 700; text-transform: uppercase; }
.n18-shop-note { display: flex; align-items: center; gap: .6rem; margin: 0; padding: 1rem 0 0; border-top: var(--bw) solid var(--line); font-size: .62rem; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; }
@media (max-width: 560px) {
  .n18-shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 2rem 1rem; }
  .n18-item-title { font-size: .95rem; }
}

/* ================================================================ KALENDER (new) */
.n18-agenda-label, .n18-legend { margin: 0 0 var(--gap); padding: 0 var(--inset); color: var(--grey); font-size: .62rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.n18-agenda-next { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); }
.n18-agenda-next .n18-card { min-height: clamp(12rem, 28vh, 19rem); }
.n18-legend { display: flex; flex-wrap: wrap; gap: 1.4rem; margin-top: clamp(2.2rem, 4vw, 3.6rem); }
.n18-legend span::before { content: ""; display: inline-block; width: .8em; height: .8em; margin-right: .45em; vertical-align: -.1em; border: var(--bw) solid var(--line); background: var(--paper); }
.n18-legend .is-open::before { background: var(--open); border-color: var(--open); }
.n18-legend .is-event::before { background: var(--event); border-color: var(--event); }
.n18-legend .is-today::before { box-shadow: inset 0 0 0 2px var(--ink); }
.n18-month { margin-top: clamp(1.2rem, 2.4vw, 2.2rem); }
.n18-month-title { display: flex; align-items: baseline; justify-content: space-between; margin: 0 0 .5rem; padding: 0 var(--inset);
  font-size: clamp(1.8rem, 4vw, 4.4rem); font-weight: 400; letter-spacing: -.075em; line-height: .9; text-transform: uppercase; }
.n18-month-title span { color: var(--red); font-size: .4em; font-weight: 700; letter-spacing: -.02em; }
/* Hairlines: the gaps between the cells show the line colour, exactly the line width set in the CMS */
.n18-month-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: var(--bw); background: var(--line); border: var(--bw) solid var(--line); }
.n18-mhead { padding: .45rem clamp(6px, .7vw, 12px); background: var(--paper); color: var(--grey); font-size: .62rem; letter-spacing: .03em; text-transform: uppercase; }
.n18-mday {
  position: relative; min-width: 0; min-height: clamp(62px, 8.2vw, 124px); padding: clamp(6px, .7vw, 12px);
  display: flex; flex-direction: column; justify-content: space-between; gap: 4px;
  background: var(--paper); color: var(--ink); text-decoration: none;
}
.n18-mday.is-blank { background: var(--paper) repeating-linear-gradient(135deg, transparent 0 7px, rgba(138, 131, 123, .14) 7px 8px); }
.n18-mday-n { font-size: clamp(1rem, 1.9vw, 2.1rem); letter-spacing: -.07em; line-height: .9; }
.n18-mday.is-past .n18-mday-n { color: var(--grey); opacity: .55; }
.n18-mday.is-today { box-shadow: inset 0 0 0 2px var(--ink); }
.n18-mday-what { display: flex; flex-direction: column; gap: 1px; font-size: clamp(.48rem, .72vw, .72rem); font-weight: 700; letter-spacing: .03em; line-height: 1.25; text-transform: uppercase; }
.n18-mday-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Opening days and events: a coloured tile inside the day, so neighbouring days never merge
   and the calendar lines stay visible */
.n18-mday.is-open, .n18-mday.is-event { background: var(--paper); }
.n18-mday.is-open::before, .n18-mday.is-event::before { content: ""; position: absolute; inset: clamp(3px, .35vw, 6px); z-index: 0; background: var(--open); transition: background .15s; }
.n18-mday.is-event::before { background: var(--event); }
.n18-mday.is-open > *, .n18-mday.is-event > * { position: relative; z-index: 1; }
.n18-mday.is-open { color: var(--open-ink); padding: clamp(9px, 1vw, 17px); }
.n18-mday.is-event { color: var(--event-ink); padding: clamp(9px, 1vw, 17px); }
.n18-mday.is-open.is-past::before, .n18-mday.is-event.is-past::before { opacity: .45; }
.n18-mday.is-open .n18-mday-n, .n18-mday.is-event .n18-mday-n { color: inherit; opacity: 1; font-weight: 700; }
a.n18-mday:hover, a.n18-mday:focus-visible { outline: none; color: var(--paper); }
a.n18-mday:hover::before, a.n18-mday:focus-visible::before { background: var(--ink); opacity: 1; }
@media (max-width: 760px) {
  .n18-agenda-next { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .n18-agenda-next .n18-card { min-height: 11rem; padding: .8rem; }
  .n18-mday { min-height: 48px; padding: 5px; }
  .n18-mday-n { font-size: .95rem; }
  .n18-mday-title { display: none; }
  .n18-mday-what { font-size: .5rem; }
}

/* ================================================================ BLOCK PAGES (contact) */
/* Hairlines: the 1px gaps show the line colour, so every arrangement gets clean lines */
/* Each block draws a hairline around itself; neighbouring lines overlap into one line,
   and space no block fills stays plain paper */
.n18-blocks { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: minmax(20rem, auto); grid-auto-flow: row dense; gap: var(--bw); padding: var(--bw) 0; }
.n18-blocks > .n18-blk { box-shadow: 0 0 0 var(--bw) var(--line); }
.n18-blocks.is-fit { height: 100%; grid-template-rows: repeat(var(--rows, 2), minmax(0, 1fr)); grid-auto-rows: minmax(0, 1fr); }
.n18-blk {
  container-type: inline-size; position: relative; min-width: 0; min-height: 0; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between; gap: clamp(.4rem, 1.5vh, 1.4rem);
  padding: clamp(.9rem, min(3vw, 3.8vh), 3.4rem) clamp(1.1rem, 3vw, 3.4rem); background: var(--paper);
}
.n18-blk .n18-cc-label { font-weight: 700; }
.n18-blk.is-red { background: var(--red); color: var(--paper); }
.n18-blk.is-red .n18-cc-label, .n18-blk.is-red .n18-ct-times dt, .n18-blk.is-red .n18-ct-times dd, .n18-blk.is-red .n18-ct-note strong { color: var(--paper); }
/* Text follows the size of its block */
.n18-blk .n18-ct-times { font-size: clamp(1.3rem, min(10.5cqi, 9vh), 7rem); }
.n18-blk .n18-ct-lead { font-size: clamp(1.05rem, min(6.6cqi, 3.7vh), 3.4rem); }
.n18-blk.is-map { justify-content: flex-start; }
.n18-blk-image { flex: 1 1 auto; min-height: 0; }
.n18-blk-image img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px), (max-height: 520px) {
  .n18-blocks, .n18-blocks.is-fit { height: auto; grid-template-rows: none; grid-auto-rows: auto; }
  .n18-blk { grid-column: 1 / -1 !important; grid-row: auto !important; padding: 1.6rem 1rem; min-height: 0; }
  .n18-blk.is-map .n18-ct-frame { min-height: 18rem; }
  .n18-blk.is-image .n18-blk-image { min-height: 16rem; }
  .n18-blk .n18-ct-times { font-size: clamp(1.7rem, 9.5vw, 3.4rem); }
  .n18-blk .n18-ct-lead { font-size: clamp(1.4rem, 7.5vw, 2.4rem); }
}

/* ================================================================ OWN PAGES */
.n18-custom { min-height: calc(100dvh - var(--banner-h)); }
.n18-custom.has-padding { padding: clamp(1rem, 3vw, 3rem); }

/* ================================================================ PRINT: MS-DOS */
body.page-print { background: #000; }
.dos {
  min-height: 100dvh; padding: clamp(18px, 3vw, 40px) clamp(16px, 3vw, 44px) 30vh; background: #000; color: #C0C0C0;
  font-family: "VT323", "Lucida Console", "Courier New", monospace; font-size: clamp(20px, 2.1vw, 30px); line-height: 1.25; cursor: text;
}
.dos-line { white-space: pre-wrap; overflow-wrap: anywhere; min-height: 1.25em; }
.dos-in {
  width: min(100%, 40ch); padding: 0; border: 0; background: transparent; color: #FFFFFF; font: inherit; caret-color: #C0C0C0; caret-shape: block; outline: none;
}
.dos-ask { display: flex; flex-wrap: wrap; align-items: baseline; }
.dos-ask > span:first-child { white-space: pre-wrap; }
.dos-count { color: #6E6E6E; }
.dos-exit { position: fixed; top: 12px; right: 16px; color: #6E6E6E; font: inherit; font-size: .7em; text-decoration: none; }
.dos-exit:hover, .dos-exit:focus-visible { color: #FFF; background: #333; outline: none; }
::selection { background: #C0C0C0; color: #000; }

.n18-fit.is-overflow { height: auto; }
.n18-blocks.is-fit.is-overflow { height: auto; grid-template-rows: none; grid-auto-rows: minmax(max(18rem, 46vh), auto); }

/* ---------- SHOP: product window (gallery, information, then ordering) */
.n18-dialog.n18-pv { width: min(1180px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); }
.n18-pv-body { min-height: 0; overflow: auto; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(300px, 1fr); }
.n18-pv-gallery { display: flex; flex-direction: column; justify-content: center; gap: 10px; padding: clamp(14px, 2vw, 26px); border-right: var(--bw) solid var(--line); background: var(--paper); min-width: 0; }
.n18-pv-stage { position: relative; display: flex; justify-content: center; align-items: center; padding: 0; border: 0; background: none; cursor: zoom-in; }
.n18-pv-main { display: block; max-width: 100%; max-height: min(66dvh, 720px); width: auto; height: auto; object-fit: contain; }
.n18-pv-main.is-placeholder { width: 30%; box-shadow: none; opacity: .35; }
.n18-pv-zoom { position: absolute; right: 8px; bottom: 8px; padding: 3px 7px; background: var(--paper); color: var(--ink); font-size: .58rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; opacity: 0; transition: opacity .2s; }
.n18-pv-stage:hover .n18-pv-zoom, .n18-pv-stage:focus-visible .n18-pv-zoom { opacity: 1; }
.n18-pv-thumbs { display: flex; gap: 6px; overflow-x: auto; }
.n18-pv-thumbs button { flex: none; width: 64px; height: 64px; padding: 0; border: var(--bw) solid transparent; background: var(--paper); cursor: pointer; opacity: .65; }
.n18-pv-thumbs button.on, .n18-pv-thumbs button:hover { opacity: 1; border-color: var(--red); }
.n18-pv-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.n18-pv-info { display: flex; flex-direction: column; gap: .8rem; padding: clamp(18px, 2.6vw, 34px); min-width: 0; }
.n18-pv-title { margin: 0; font-size: clamp(1.7rem, 3vw, 3rem); font-weight: 400; letter-spacing: -.07em; line-height: .92; text-transform: uppercase; }
.n18-pv-price { margin: 0; color: var(--red); font-size: clamp(1.2rem, 1.8vw, 1.7rem); font-weight: 700; letter-spacing: -.04em; }
.n18-pv-text p { margin: 0 0 .7em; font-size: .8rem; line-height: 1.6; }
.n18-pv-facts { display: grid; grid-template-columns: auto 1fr; gap: 0 1.2rem; margin: 0; border-top: var(--bw) solid var(--line); }
.n18-pv-facts dt, .n18-pv-facts dd { margin: 0; padding: .45rem 0; border-bottom: var(--bw) solid var(--line); font-size: .68rem; text-transform: uppercase; }
.n18-pv-facts dt { color: var(--grey); letter-spacing: .03em; }
.n18-pv-facts dd { font-weight: 700; }
.n18-pv-order { align-self: flex-start; margin-top: .4rem; font-size: .8rem; padding: 14px 22px; }
.n18-pay-row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.n18-back-link { border: 0; padding: 0; background: none; color: var(--grey); cursor: pointer; font-size: .7rem; font-weight: 700; text-transform: uppercase; }
.n18-back-link:hover { color: var(--ink); }
.n18-pv-info .n18-form { margin-top: .4rem; }
@media (max-width: 820px) {
  /* On phones the window fills the screen: photo on top, information below, one scroll */
  .n18-veil:has(.n18-pv) { padding: 0; }
  .n18-dialog.n18-pv { width: 100vw; height: 100dvh; max-height: 100dvh; border: 0; }
  .n18-pv-body { display: block; overflow-y: auto; -webkit-overflow-scrolling: touch; }
  .n18-pv-gallery { border-right: 0; border-bottom: var(--bw) solid var(--line); padding: 14px; }
  .n18-pv-main { max-height: 46dvh; }
  .n18-pv-thumbs button { width: 54px; height: 54px; }
  .n18-pv-info { padding: 20px 16px 32px; }
  .n18-pv-title { font-size: clamp(1.6rem, 9vw, 2.4rem); }
  .n18-pv-text p { font-size: .82rem; }
  .n18-pv-facts dt, .n18-pv-facts dd { font-size: .62rem; }
  .n18-pv-order { width: 100%; }
  .n18-pv .n18-form { grid-template-columns: 1fr; }
  .n18-pv .n18-pay-row { flex-direction: column-reverse; align-items: stretch; }
  .n18-pv .n18-pay-row .n18-button { width: 100%; }
  .n18-pv .n18-summary { font-size: .7rem; }
  .n18-pv .n18-choice { font-size: .68rem; }
}

.n18-blk .n18-ct-times.is-many { font-size: clamp(1.1rem, min(7cqi, 5.5vh), 4.6rem); }

[hidden] { display: none !important; }

/* contact blocks: black background, link blocks, current exhibition */
.n18-blk.is-black { background: #000; color: var(--paper); }
.n18-blk.is-black .n18-cc-label, .n18-blk.is-black .n18-ct-formtext, .n18-blk.is-black .n18-ct-times dt, .n18-blk.is-black .n18-ct-note { color: var(--paper); }
.n18-blk-title { margin: 0; font-size: clamp(1.6rem, min(11cqi, 10vh), 6.5rem); font-weight: 400; letter-spacing: -.075em; line-height: .87; text-transform: uppercase; overflow-wrap: anywhere; }
.n18-blk-artist { display: block; margin-bottom: .4rem; color: var(--paper); font-size: clamp(.8rem, min(3.4cqi, 2.6vh), 1.6rem); font-weight: 700; letter-spacing: -.02em; text-transform: uppercase; }
.n18-blk.is-red .n18-ct-formtext { color: var(--paper); }
.n18-blk-cover { position: absolute; inset: 0; z-index: 3; }
.n18-blk.is-linked { transition: background .15s, color .15s; }
.n18-blk.is-linked:hover { background: var(--red); color: var(--paper); }
.n18-blk.is-linked:hover .n18-cc-label, .n18-blk.is-linked:hover .n18-ct-formtext { color: var(--paper); }
.n18-blk.is-linked:focus-within { outline: 2px solid var(--ink); outline-offset: -4px; }
.n18-blk.is-exhibition { background: var(--red); color: var(--paper); }
.n18-blk.is-exhibition .n18-cc-label, .n18-blk.is-exhibition .n18-ct-formtext { color: var(--paper); }
.n18-blk.is-exhibition > *:not(.n18-blk-bg):not(.n18-blk-cover) { position: relative; z-index: 2; }
.n18-blk-bg { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; }
.n18-blk.is-exhibition:hover { background: var(--ink); }

/* embed blocks (for example the receipt printer) */
.n18-blk.is-html { justify-content: flex-start; }
.n18-blk-html { min-width: 0; }
.n18-blk-html iframe { max-width: 100%; }

/* ---------- KALENDER: the next opening days as one large list */
.n18-agenda-open { display: grid; gap: clamp(1rem, 2.4vw, 2rem); padding: clamp(1.2rem, 3vw, 3rem) var(--inset); border-top: var(--bw) solid var(--line); border-bottom: var(--bw) solid var(--line); }
.n18-agenda-open .n18-cc-label { font-weight: 700; }
.n18-agenda-times { grid-template-columns: auto auto minmax(0, 1fr); font-size: clamp(1.8rem, min(4.6vw, 8.5vh), 6rem); }
.n18-agenda-times a { color: inherit; text-decoration: none; }
.n18-agenda-times a:hover, .n18-agenda-times a:focus-visible { text-decoration: underline; text-decoration-thickness: .06em; text-underline-offset: .12em; outline: none; }
.n18-agenda-times dd { white-space: nowrap; }
.n18-agenda-times dd.is-event a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--event); text-decoration-thickness: .14em; text-underline-offset: .08em; }
.n18-agenda-what { margin: 0; align-self: center; color: var(--grey); font-size: clamp(.6rem, .8vw, .82rem); font-weight: 700; letter-spacing: .03em; line-height: 1.3; text-transform: uppercase; }
.n18-agenda-what.is-same { visibility: hidden; }
.n18-agenda-open .n18-ct-note a { color: var(--red); font-weight: 700; text-decoration: none; }
.n18-agenda-open .n18-ct-note a:hover { text-decoration: underline; }
.n18-agenda .n18-legend { margin-top: clamp(1.4rem, 3vw, 2.4rem); }
@media (max-width: 760px) {
  /* Phone: day and hours on one line, the exhibition name small underneath */
  .n18-agenda-times { grid-template-columns: auto 1fr; column-gap: .5em; row-gap: 0; font-size: clamp(1.4rem, 7.6vw, 2.6rem); }
  .n18-agenda-what { grid-column: 1 / -1; margin: .15rem 0 .7rem; font-size: .6rem; }
  .n18-agenda-what.is-same { display: none; }
  .n18-agenda-open { padding: 1.4rem .75rem; }
}

/* ---------- KALENDER: next opening days as one row of cards (replaces the large list) */
.n18-agenda-open { border-bottom: 0; padding-bottom: 0; }
.n18-next-row {
  display: grid; grid-template-columns: repeat(var(--n, 3), minmax(0, 1fr)); gap: var(--bw); padding: var(--bw) 0;
}
.n18-next-card {
  display: flex; flex-direction: column; min-width: 0; min-height: clamp(10rem, 24vh, 15rem);
  padding: clamp(12px, 1.4vw, 22px); background: var(--paper); color: var(--ink); text-decoration: none;
  box-shadow: 0 0 0 var(--bw) var(--line); transition: background .15s, color .15s;
}
.n18-next-label { color: var(--grey); font-size: .62rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.n18-next-date { margin-top: auto; font-size: clamp(2rem, 4.2vw, 4.6rem); font-weight: 400; letter-spacing: -.075em; line-height: .9; text-transform: uppercase; white-space: nowrap; }
.n18-next-time { margin-top: .25em; color: var(--red); font-size: clamp(1.1rem, 2.1vw, 2.3rem); font-weight: 700; letter-spacing: -.06em; line-height: 1; text-transform: uppercase; white-space: nowrap; }
.n18-next-what { margin-top: .9rem; color: var(--red); font-size: .62rem; font-weight: 700; letter-spacing: .04em; line-height: 1.3; text-transform: uppercase; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.n18-next-card.is-event .n18-next-time { color: var(--ink); text-decoration: underline; text-decoration-color: var(--event); text-decoration-thickness: .16em; text-underline-offset: .1em; }
.n18-next-card.is-event .n18-next-label::before { content: ""; display: inline-block; width: .75em; height: .75em; margin-right: .4em; vertical-align: -.05em; background: var(--event); }
.n18-next-card:hover, .n18-next-card:focus-visible { background: var(--red); color: var(--paper); outline: none; }
.n18-next-card:hover *, .n18-next-card:focus-visible * { color: var(--paper) !important; }
@media (max-width: 760px) {
  /* Phone: still one row, swipe sideways; the next card peeks in as a hint */
  .n18-next-row {
    grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 66%;
    overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: var(--bw); margin: 0 calc(-1 * var(--bw));
  }
  .n18-next-row::-webkit-scrollbar { display: none; }
  .n18-next-card { scroll-snap-align: start; min-height: 9.5rem; padding: 14px; }
  .n18-next-date { font-size: clamp(2rem, 11vw, 2.8rem); }
  .n18-next-time { font-size: clamp(1.1rem, 6vw, 1.5rem); }
}

/* the row of cards is exactly as wide as the calendar below, so the lines line up */
.n18-agenda-open { padding-left: 0; padding-right: 0; }
.n18-agenda-open > .n18-cc-label, .n18-agenda-open > .n18-ct-lead { padding: 0 var(--inset); }
@media (max-width: 760px) { .n18-agenda-open { padding-left: 0; padding-right: 0; } .n18-next-row { margin: 0; } }

/* ---------- Photo overlays (archive tiles, exhibition page): mode and strength come from the CMS */
.n18-ov::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; transition: opacity .25s ease; }
.n18-ov[data-ov="red"]::after { background: var(--red); opacity: var(--ov, .35); }
.n18-ov[data-ov="dark"]::after { background: linear-gradient(to top, rgba(0, 0, 0, .85) 0%, rgba(0, 0, 0, .35) 45%, rgba(0, 0, 0, .1) 100%); opacity: calc(var(--ov, .35) * 1.6); }
.n18-ov[data-ov="bw"] .n18-card-image { filter: grayscale(1) contrast(1.05); }
.n18-ov[data-ov="bw"]::after { background: #000; opacity: calc(var(--ov, .35) * .8); }
.n18-ov[data-ov="none"]::after { display: none; }
.n18-ov .n18-card-top, .n18-ov .n18-copy { z-index: 2; }
.n18-ov .n18-title, .n18-ov .n18-badge, .n18-ov .n18-number, .n18-ov .n18-meta { color: var(--paper); text-shadow: 0 1px 14px rgba(0, 0, 0, .25); }
/* archive: on hover the photo shows more clearly; the titles never get boxes behind them */
.n18-tile-image:hover::after, .n18-tile-image:focus-visible::after { opacity: calc(var(--ov, .35) * .45); }
.n18-tile-image .n18-title { line-height: .92; }

/* ================================================================ EXHIBITION PAGE (new layout) */
/* A standing (4:5) image like a poster, one third wide; opening days, practical info and text next to it */
.n18-ex-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-template-rows: auto 1fr; gap: var(--gap); align-items: stretch; }
.n18-ex-hero { grid-column: 1 / 5; grid-row: 1 / 3; aspect-ratio: 4 / 5; min-height: 0; max-height: calc(100dvh - var(--banner-h) - 2 * var(--gap)); }
.n18-ex-hero .n18-title { font-size: calc(clamp(1.8rem, min(3.2vw, 6vh), 4rem) * var(--ts, 1)); max-width: 12ch; }
.n18-ex-hero .n18-badge { font-size: clamp(.9rem, 1.4vw, 1.4rem); }
.n18-ex-card { min-width: 0; padding: var(--pad); border: var(--bw) solid var(--line); background: var(--paper); display: flex; flex-direction: column; gap: 1rem; }
.n18-ex-open { grid-column: 5 / 9; grid-row: 1; justify-content: flex-start; }
.n18-ex-open .n18-openings li { font-size: clamp(.9rem, 1.35vw, 1.4rem); padding: .5rem 0; }
.n18-ex-range { margin: 0; color: var(--red); font-size: clamp(1rem, 1.6vw, 1.6rem); font-weight: 700; letter-spacing: -.05em; text-transform: uppercase; }
.n18-ex-facts { grid-column: 9 / 13; grid-row: 1; }
.n18-ex-text { grid-column: 5 / 13; grid-row: 2; }
.n18-ex-text .n18-body { font-size: clamp(.8rem, .95vw, .98rem); line-height: 1.7; max-width: 68ch; }
.n18-ex-facts dd a { color: inherit; text-decoration: none; }
.n18-ex-facts dd a:hover { color: var(--red); }
.n18-ex-links { display: flex; gap: 1.4rem; margin-top: auto; padding-top: .6rem; }
.n18-ex-gallery { margin-top: clamp(2rem, 4vw, 3.6rem); }
.n18-ex-gallery > .n18-cc-label { display: block; margin: 0 0 .9rem; padding: 0 var(--inset); font-weight: 700; }
/* Photos in their own proportions, in columns like a wall of prints */
.n18-ex-photos { --row-h: clamp(170px, 24vw, 360px); display: flex; flex-wrap: wrap; gap: var(--gap); }
.n18-ex-photos::after { content: ""; flex: 999 1 0; } /* the last row keeps its natural size instead of stretching */
.n18-ex-photo { --r: 1.4; flex: var(--r) 1 calc(var(--r) * var(--row-h)); display: block; min-width: 0; padding: 0; border: 0; background: none; cursor: zoom-in; }
.n18-ex-photo img { display: block; width: 100%; height: auto; transition: opacity .2s; }
.n18-ex-photo:hover img, .n18-ex-photo:focus-visible img { opacity: .86; }
.n18-ex-photo:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }
@media (max-width: 1100px) and (min-width: 901px) {
  .n18-ex-hero { grid-column: 1 / 6; }
  .n18-ex-open { grid-column: 6 / 13; grid-row: 1; }
  .n18-ex-facts { grid-column: 6 / 13; grid-row: 2; }
  .n18-ex-text { grid-column: 1 / -1; grid-row: 3; }
}
@media (max-width: 900px) {
  .n18-ex-grid { grid-template-rows: none; }
  .n18-ex-grid > * { grid-column: 1 / -1 !important; grid-row: auto !important; }
  .n18-ex-hero { width: min(100%, 520px); max-height: none; justify-self: center; }
  .n18-ex-hero .n18-title { font-size: calc(clamp(1.9rem, 10vw, 3.2rem) * var(--ts, 1)); }
  .n18-ex-photos { --row-h: clamp(110px, 34vw, 200px); }
}

/* ================================================================ LIGHTBOX (light) */
.n18-lightbox { position: fixed; inset: 0; z-index: 95; display: grid; grid-template-rows: auto minmax(0, 1fr); background: var(--paper); color: var(--ink); touch-action: pan-y; }
.n18-lb-bar { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; font-size: .7rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.n18-lb-count { color: var(--grey); }
.n18-lb-close { border: var(--bw) solid var(--line); background: var(--paper); color: var(--red); padding: 6px 10px; cursor: pointer; font: inherit; font-weight: 700; text-transform: uppercase; }
.n18-lb-close:hover, .n18-lb-close:focus-visible { background: var(--red); color: var(--paper); outline: none; }
.n18-lb-stage { min-height: 0; display: grid; place-items: center; padding: 0 clamp(56px, 7vw, 110px) clamp(14px, 3vh, 34px); }
.n18-lb-stage img { max-width: 100%; max-height: calc(100dvh - 90px); width: auto; height: auto; object-fit: contain; box-shadow: 0 12px 40px rgba(0, 0, 0, .12); user-select: none; -webkit-user-drag: none; }
.n18-lb-arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: clamp(44px, 4.4vw, 64px); height: clamp(44px, 4.4vw, 64px); display: grid; place-items: center;
  border: var(--bw) solid var(--line); border-radius: 0; background: var(--paper); color: var(--red); cursor: pointer;
  font: inherit; font-size: clamp(1.1rem, 1.6vw, 1.6rem); font-weight: 700;
}
.n18-lb-arrow.is-prev { left: clamp(6px, 1.5vw, 24px); }
.n18-lb-arrow.is-next { right: clamp(6px, 1.5vw, 24px); }
.n18-lb-arrow:hover, .n18-lb-arrow:focus-visible { background: var(--red); color: var(--paper); outline: none; }
@media (max-width: 600px) {
  .n18-lb-stage { padding: 0 8px 12px; }
  .n18-lb-arrow { width: 40px; height: 40px; background: color-mix(in srgb, var(--paper) 85%, transparent); }
}

/* ---------- KALENDER cards: artist and exhibition clearly; paper, a colour, or the exhibition image */
.n18-next-card { position: relative; overflow: hidden; }
.n18-next-top { display: flex; flex-direction: column; gap: .35rem; position: relative; z-index: 2; }
.n18-next-artist { font-size: clamp(.85rem, 1.25vw, 1.25rem); font-weight: 700; letter-spacing: -.02em; line-height: 1.05; text-transform: uppercase; color: var(--red); }
.n18-next-date, .n18-next-time, .n18-next-what { position: relative; z-index: 2; }
.n18-next-what { font-size: clamp(.7rem, .95vw, .92rem); letter-spacing: -.01em; }
.n18-next-bg { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; }
/* colour */
.n18-next-row.is-colour .n18-next-card { background: var(--nc-bg); color: var(--nc-ink); }
.n18-next-row.is-colour .n18-next-card * { color: var(--nc-ink) !important; }
/* image */
.n18-next-row.is-image .n18-next-card.has-image { background: #000; color: var(--paper); }
.n18-next-row.is-image .n18-next-card.has-image * { color: var(--paper) !important; }
.n18-next-row.is-image .n18-next-card.has-image:hover::after { opacity: .2; }
/* first card highlighted in the opening-day colour */
.n18-next-row.first-hi .n18-next-card:first-child { background: var(--open); color: var(--open-ink); }
.n18-next-row.first-hi .n18-next-card:first-child * { color: var(--open-ink) !important; }

/* ---------- CONTACT: all opening days of one exhibition */
.n18-ct-expo { display: grid; gap: clamp(.4rem, 1.2vh, .9rem); }
.n18-ct-expo-name { color: var(--red); font-size: clamp(.62rem, .85vw, .86rem); font-weight: 700; letter-spacing: .03em; text-transform: uppercase; text-decoration: none; }
.n18-ct-expo-name:hover { text-decoration: underline; }
.n18-ct-times .is-past { color: var(--grey) !important; text-decoration: line-through; text-decoration-thickness: .05em; }
.n18-blk.is-red .n18-ct-expo-name { color: var(--paper); }
.n18-ct-rule { font-weight: 700; color: var(--ink); }
.n18-blk.is-red .n18-ct-rule, .n18-blk.is-black .n18-ct-rule { color: var(--paper); }

/* ---------- CONTACT form: clear fields with example text */
.n18-line > span { color: var(--ink); font-size: .62rem; font-weight: 700; }
.n18-line input, .n18-line textarea {
  padding: 10px 12px; border: var(--bw) solid var(--line); background: #FFFDF8; background: color-mix(in srgb, #FFFFFF 70%, var(--paper));
  font-size: clamp(.82rem, .95vw, .95rem);
}
.n18-line input::placeholder, .n18-line textarea::placeholder { color: var(--grey); opacity: .9; }
.n18-line input:focus, .n18-line textarea:focus { border-color: var(--ink); border-width: var(--bw); outline: 2px solid var(--red); outline-offset: -1px; }
.n18-send .n18-button { font-size: .74rem; padding: 12px 18px; }
.n18-form-status.is-ok { color: var(--ink); background: color-mix(in srgb, var(--open) 12%, var(--paper)); padding: .5rem .7rem; text-align: left; }

/* ---------- SHOP: stock for visitors (optional) */
.n18-item-stock { color: var(--red); font-size: .6rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.n18-item-stock.is-low { background: var(--red); color: var(--paper); padding: 1px 5px; align-self: flex-start; }

/* exhibition page: artists with Instagram */
.n18-artists { display: grid; gap: .7rem; }
.n18-artist { display: grid; gap: .2rem; min-width: 0; }
.n18-artist-name { overflow-wrap: anywhere; }
.n18-artist-links { display: flex; flex-wrap: wrap; gap: .1rem 1rem; font-size: .9em; }
.n18-artist-links a { overflow-wrap: anywhere; }
.n18-ig { color: var(--red) !important; font-weight: 700; text-decoration: none; }
.n18-ig:hover { text-decoration: underline; text-underline-offset: .2em; }

/* works with captions */
.n18-ex-photo.has-caption { display: flex; flex-direction: column; text-align: left; }
.n18-ex-caption { display: grid; gap: .15rem; padding: .55rem 0 .2rem; font-size: .66rem; line-height: 1.35; text-transform: uppercase; color: var(--ink); }
.n18-ex-caption strong { font-size: .74rem; letter-spacing: -.01em; }
.n18-ex-caption span { color: var(--grey); letter-spacing: .02em; }
.n18-lb-figure { margin: 0; display: grid; justify-items: center; gap: .8rem; min-height: 0; }
.n18-lb-figure img { max-height: calc(100dvh - 140px); }
.n18-lb-caption { margin: 0; text-align: center; font-size: .72rem; line-height: 1.45; text-transform: uppercase; color: var(--grey); }
.n18-lb-caption strong { color: var(--ink); font-size: .8rem; }

/* The large image always stays inside its own column, whatever the length of the text next to it */
.n18-ex-hero { align-self: start; width: 100%; height: auto; }
.n18-ex-text { min-width: 0; }
.n18-ex-text .n18-body { overflow-wrap: anywhere; }
/* Extra text over the full width, above the works and photos */
.n18-ex-extra { margin-top: var(--gap); }
.n18-ex-extra-text { max-width: none !important; columns: 2 42ch; column-gap: clamp(1.5rem, 4vw, 4rem); overflow-wrap: anywhere; }
@media (max-width: 900px) { .n18-ex-extra-text { columns: 1; } }

/* The large image fills its frame: at least 4:5, and as tall as the cards next to it */
.n18-ex-hero { aspect-ratio: auto !important; align-self: stretch !important; max-height: none !important; }
.n18-ex-hero::before { content: ""; flex: none; width: 0; padding-bottom: 125%; }
.n18-ex-hero .n18-card-image { object-fit: cover; }

/* Card colours on the exhibition page */
.n18-ex-card.is-coloured { background: var(--c-bg); color: var(--c-ink); border-color: var(--c-bg); }
.n18-ex-card.is-coloured .n18-cc-label { color: var(--c-ink); opacity: .75; }
.n18-ex-card.is-coloured .n18-openings li, .n18-ex-card.is-coloured .n18-ex-range,
.n18-ex-card.is-coloured .n18-pv-facts dt, .n18-ex-card.is-coloured .n18-pv-facts dd,
.n18-ex-card.is-coloured a, .n18-ex-card.is-coloured .n18-ig, .n18-ex-card.is-coloured .n18-body { color: var(--c-ink) !important; }
.n18-ex-card.is-coloured .n18-openings li, .n18-ex-card.is-coloured .n18-openings li:first-child,
.n18-ex-card.is-coloured .n18-pv-facts dt, .n18-ex-card.is-coloured .n18-pv-facts dd { border-color: color-mix(in srgb, var(--c-ink) 35%, transparent); }
.n18-ex-card.is-coloured .n18-openings li.is-past { opacity: .55; }
.n18-ex-card.is-coloured .n18-pv-facts dt { opacity: .75; }
/* Larger text option */
.n18-ex-text.is-large .n18-body { font-size: clamp(.95rem, 1.25vw, 1.25rem); line-height: 1.6; }

/* while a photo loads, its place is already the right size and softly coloured */
.n18-ex-photo img { background: color-mix(in srgb, var(--ink) 6%, var(--paper)); aspect-ratio: var(--r, auto); object-fit: cover; }

/* ---------- newsletter block */
.n18-nl { display: grid; gap: .8rem; min-width: 0; }
.n18-nl-form { display: grid; gap: .8rem; max-width: 34rem; }
.n18-nl-row { display: flex; gap: .6rem; }
.n18-nl-row .n18-button { font-size: .74rem; padding: 12px 18px; }
.n18-nl-privacy { color: var(--grey); font-size: .6rem; letter-spacing: .02em; line-height: 1.5; text-transform: uppercase; }
.n18-blk.is-red .n18-nl-privacy, .n18-blk.is-black .n18-nl-privacy { color: inherit; opacity: .75; }
.n18-blk.is-red .n18-nl .n18-button, .n18-blk.is-black .n18-nl .n18-button { background: var(--paper); color: var(--red); }
.n18-optin { font-size: .66rem; }
.n18-optin input { accent-color: var(--red); }
.n18-nl .n18-button { background: var(--red); border-color: var(--red); color: var(--paper); }
