/* Chassidus in Color: homepage. The official lockup and its colours (measured from the official image), set in
   Inter, the lockup's own face; the warm ground and ink of the judges' app; the brand's paint, used twice: under the
   lockup on the first screen and under the last word. */

@font-face {
  font-family: "Inter";
  src: url("assets/inter.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --ground: #f3f2ec;
  --ink: #1c1b19;
  --ink-2: #4e4b45;
  --ink-3: #6b675f;
  --line: rgba(28, 27, 25, .12);
  --line-2: rgba(28, 27, 25, .22);
  --canvas: #0c1c25;
  --teal: #0f3347;
  --magenta: #c72e72;
  --magenta-deep: #a8235f;
  --cyan: #67d4ee;
  --paint-white: #f0f0f0;
  --mist: #b9c6cc;
  --paint: url("assets/brand-paint-wide.jpg");
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --gutter: clamp(20px, 4vw, 48px);
  --measure: 1180px;
  --edge: max(var(--gutter), calc((100vw - var(--measure)) / 2));
  --header: 68px;
  --section: clamp(64px, 7vw, 104px);
  --quote-gap: clamp(32px, 5vw, 80px);
  --edge-top: url("assets/edges/paint-edge-top.png");
  --edge-bottom: url("assets/edges/paint-edge-bottom.png");
  --edge-left: url("assets/edges/paint-edge-left.png");
  --fringe: 56px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header); }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font: 400 17px/1.55 var(--sans); font-optical-sizing: auto; -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
p, li, dd, blockquote { text-wrap: pretty; }
:focus-visible { outline: 2px solid var(--magenta); outline-offset: 3px; }
::selection { background: var(--magenta); color: #fff; }
svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.skip-link {
  position: fixed; z-index: 40; left: var(--edge); top: 10px; padding: 12px 18px; background: var(--ink); color: #fff;
  font: 600 15px/1 var(--sans); text-decoration: none; transform: translateY(-160%); transition: transform .2s var(--ease);
}
.skip-link:focus { transform: none; }
/* ב״ה at the head of the page, small, in the corner */
.bh {
  position: absolute; z-index: 25; top: 7px; right: 12px; pointer-events: none;
  font: 500 13px/1 "Noto Sans Hebrew", "Arial Hebrew", Arial, sans-serif; color: #fff; text-shadow: 0 1px 6px rgba(12, 28, 37, .55);
}

.section-inner { width: min(var(--measure), 100% - var(--gutter) * 2); margin: 0 auto; }
/* Painted edges: wherever the paint meets the page it ends in a dry-brush edge (tools/generate_paint_edges.py), so the
   page reads as the primed canvas the paint lands on. Flat fields of colour keep clean edges. Top and bottom fringes
   tile across; the solid middle fills. */
.painted, .theme-band, .closing-band {
  -webkit-mask: var(--edge-top) 0 0 / auto var(--fringe) repeat-x, linear-gradient(#000 0 0) 0 calc(var(--fringe) - 1px) / 100% calc(100% - 2 * var(--fringe) + 2px) no-repeat, var(--edge-bottom) 0 100% / auto var(--fringe) repeat-x;
  mask: var(--edge-top) 0 0 / auto var(--fringe) repeat-x, linear-gradient(#000 0 0) 0 calc(var(--fringe) - 1px) / 100% calc(100% - 2 * var(--fringe) + 2px) no-repeat, var(--edge-bottom) 0 100% / auto var(--fringe) repeat-x;
}
/* a label kept for the section links and screen readers, where the content already says what the section is */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* One quiet label voice for every section title and label: sentence case, magenta on the ground, cyan on dark and
   on the paint. The content leads; sections whose content names itself (the Competition paragraph, Tefillah) carry
   their title for the section links and screen readers only. */
h2, .theme-label, .exhibition h3 { margin: 0 0 clamp(24px, 3vw, 36px); font: 600 15px/1.3 var(--sans); letter-spacing: 0; color: var(--magenta); }
.label-note { margin-left: .6em; font-weight: 500; color: var(--ink-3); }
h3 { margin: 0 0 16px; font: 650 17px/1.3 var(--sans); }
/* labels within a section, under its title */
.criteria-block h3, .judge-group h3 { font: 600 15px/1.3 var(--sans); color: var(--ink-3); }

/* Buttons: a word, never an icon beside it. The pill is kept for the main action only. */
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 56px; padding: 0 30px;
  border-radius: 999px; font: 600 16px/1.2 var(--sans); text-decoration: none; text-align: center;
  transition: background .25s var(--ease), color .25s;
}
.button-primary { background: var(--magenta); color: #fff; }
.button-light { background: var(--paint-white); color: var(--ink); }
.button-small { min-height: 40px; padding: 0 18px; font-size: 14px; }
.label-short { display: none; }
.text-link {
  display: inline-flex; align-items: center; min-height: 56px; font: 600 16px/1.2 var(--sans); color: var(--ink);
  text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 6px; text-decoration-color: var(--line-2);
  transition: text-decoration-color .2s;
}
.icon-button {
  display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%;
  background: transparent; color: var(--ink); cursor: pointer; transition: background .2s;
}
.icon-button svg { width: 24px; height: 24px; }
.icon-button:disabled { visibility: hidden; }
.icon-button-dark { color: var(--paint-white); }
@media (hover: hover) {
  .button-primary:hover { background: var(--magenta-deep); }
  .button-light:hover { background: #fff; }
  .text-link:hover { text-decoration-color: var(--magenta); }
  .icon-button:hover:not(:disabled) { background: rgba(28, 27, 25, .07); }
  .icon-button-dark:hover:not(:disabled) { background: rgba(240, 240, 240, .1); }
}
/* on the paint a magenta ring would vanish */
.closing-band :focus-visible, .viewer :focus-visible { outline-color: #fff; }

/* ---------- Header: clear over the first screen; once the page moves it takes the ground, the name and Join ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 20; height: var(--header); padding: 0 var(--edge);
  display: flex; align-items: center; gap: clamp(16px, 2.6vw, 36px);
  background: transparent; border-bottom: 1px solid transparent;
  transition: background .3s, border-color .3s, box-shadow .3s;
}
.scrolled .site-header { background: var(--ground); border-bottom-color: var(--line); box-shadow: 0 10px 30px -26px rgba(28, 27, 25, .55); }
.masthead {
  flex: none; font: 750 15px/1 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: .045em; text-transform: uppercase; text-decoration: none;
  opacity: 0; pointer-events: none; transition: opacity .3s;
}
.past-hero .masthead { opacity: 1; pointer-events: auto; }
.site-nav { display: flex; gap: clamp(16px, 2.4vw, 32px); margin-left: auto; }
.site-nav a {
  position: relative; display: inline-flex; align-items: center; min-height: 44px; font: 550 15px/1 var(--sans);
  text-decoration: none; color: var(--ink-2); transition: color .2s;
}
.site-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 8px; height: 2px; background: var(--magenta);
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a:hover::after, .site-nav a[aria-current="true"]::after { transform: scaleX(1); }
.site-nav a[aria-current="true"] { color: var(--ink); }
html:not(.scrolled) .site-nav a { color: #fff; text-shadow: 0 1px 14px rgba(12, 28, 37, .6); }
html:not(.scrolled) .site-nav a::after { background: #fff; }
html:not(.scrolled) .site-nav a:focus-visible { outline-color: #fff; }
/* Join is in the header from the first screen, so the row is full and never moves: light over the paint, magenta once
   the header takes the ground */
.header-cta { flex: none; transition: background .3s var(--ease), color .3s; }
html:not(.scrolled) .header-cta { background: transparent; color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .85); }
html:not(.scrolled) .header-cta:focus-visible { outline-color: #fff; }
.menu-button {
  display: none; place-items: center; width: 44px; height: 44px; margin: 0 -10px 0 auto; padding: 0; border: 0;
  background: transparent; color: var(--ink); cursor: pointer;
}
.menu-button svg { width: 24px; height: 24px; }

.menu { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0; border: 0; background: var(--ground); color: var(--ink); }
.menu::backdrop { background: rgba(12, 28, 37, .4); }
.menu-inner { min-height: 100%; display: flex; flex-direction: column; padding: 12px var(--gutter) calc(32px + env(safe-area-inset-bottom)); }
.menu-close { align-self: flex-end; margin-right: -10px; }
.menu-links { display: flex; flex-direction: column; margin: 24px 0 auto; }
.menu-links a { padding: 14px 0; border-bottom: 1px solid var(--line); text-decoration: none; font: 700 30px/1.1 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.01em; }
.menu .button { margin-top: 32px; width: 100%; }
/* the paint and the lockup at the foot of the menu */
.menu-paint {
  position: relative; height: 168px; margin: 28px calc(-1 * var(--gutter)) calc(-32px - env(safe-area-inset-bottom));
  background: url("assets/brand-paint-band.jpg") 30% 50% / cover;
  -webkit-mask: var(--edge-top) -2800px 0 / auto var(--fringe) repeat-x, linear-gradient(#000 0 0) 0 calc(var(--fringe) - 1px) / 100% 100% no-repeat;
  mask: var(--edge-top) -2800px 0 / auto var(--fringe) repeat-x, linear-gradient(#000 0 0) 0 calc(var(--fringe) - 1px) / 100% 100% no-repeat;
}
.menu-paint img { position: absolute; left: var(--gutter); bottom: calc(20px + env(safe-area-inset-bottom)); width: auto; height: 84px; }

/* ---------- First screen: the headline on the ground, on the page's measure; the lockup on the paint, out to the window's edge ---------- */
/* short enough that the paintings show under it, and never shorter than its words */
.hero { display: grid; grid-template-columns: calc(var(--edge) + min(500px, 38vw)) 1fr; min-height: clamp(560px, 100svh - 300px, 980px); }
.hero-text { align-self: center; padding: calc(var(--header) + 16px) clamp(24px, 3.4vw, 56px) 24px var(--edge); }
.hero h1 {
  margin: 0 0 clamp(24px, 3.4svh, 44px);
  font: 760 clamp(32px, min(4.1vw, 6.8svh), 62px)/1.04 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.024em;
}
/* the headline breaks only where its phrases do: There is a piece / of art locked / in the idea / you learned. */
.hero h1 > span, .hero .line { display: block; }
.hero-call { margin-top: .32em; color: var(--magenta); }
.hero-credit { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 24px; margin: clamp(24px, 3.6svh, 48px) 0 0; font: 500 14px/1.3 var(--sans); color: var(--ink-3); }
.organiser { color: var(--ink); font-weight: 600; }
.hosted { display: inline-flex; align-items: center; gap: 10px; }
.hosted img { height: 34px; width: auto; }
/* the paint meets the ground with a dry-brush edge at its left (on the panel) and at its foot (on the paint and the
   brush), so where the two meet, the corner takes both */
.hero-art {
  position: relative; overflow: hidden;
  -webkit-mask: var(--edge-left) 0 0 / 96px 100% no-repeat, linear-gradient(#000 0 0) 95px 0 / calc(100% - 95px) 100% no-repeat;
  mask: var(--edge-left) 0 0 / 96px 100% no-repeat, linear-gradient(#000 0 0) 95px 0 / calc(100% - 95px) 100% no-repeat;
}
.hero-art .hero-paint, .hero-art .brush-canvas {
  -webkit-mask: linear-gradient(#000 0 0) 0 0 / 100% calc(100% - var(--fringe) + 1px) no-repeat, var(--edge-bottom) -900px 100% / auto var(--fringe) repeat-x;
  mask: linear-gradient(#000 0 0) 0 0 / 100% calc(100% - var(--fringe) + 1px) no-repeat, var(--edge-bottom) -900px 100% / auto var(--fringe) repeat-x;
}
.hero-art img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-paint { object-fit: cover; object-position: 50% 55%; }
.hero-art .hero-lockup { inset: auto; top: 16%; left: 17%; width: 68%; height: 70%; max-width: none; object-fit: contain; }

.js .hero h1 > span, .js .hero-cta, .js .hero-credit { animation: rise .9s var(--ease) both; }
.js .hero h1 > span:nth-child(1) { animation-delay: .08s; }
.js .hero h1 > span:nth-child(2) { animation-delay: .22s; }
.js .hero-cta { animation-delay: .36s; }
.js .hero-credit { animation-delay: .48s; }
.js .hero-paint { animation: settle 2.4s var(--ease) both; }
.js .hero-lockup { animation: appear 1.2s .25s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes settle { from { transform: scale(1.06); } to { transform: none; } }
@keyframes appear { from { opacity: 0; } to { opacity: 1; } }

.js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: calc(var(--i, 0) * 90ms); }
.js [data-reveal].is-visible { opacity: 1; transform: none; }

/* ---------- Rails ---------- */
.rail-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: clamp(20px, 2.6vw, 28px); }
.rail-head h2 { margin: 0; }
.rail-controls { display: flex; gap: 4px; flex: none; margin-right: -10px; }
.reel, .works {
  list-style: none; margin: 0; display: flex; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory;
  scrollbar-width: none; padding: 0 var(--edge) 8px; scroll-padding: 0 var(--edge);
}
.reel::-webkit-scrollbar, .works::-webkit-scrollbar { display: none; }
.reel:focus-visible { outline-offset: -3px; }
.rail-progress { display: flex; gap: 6px; margin-bottom: 24px; }
.rail-progress span { flex: 1; height: 3px; border-radius: 2px; background: rgba(240, 240, 240, .16); overflow: hidden; position: relative; }
.rail-progress-light span { background: rgba(28, 27, 25, .1); }
.rail-progress span::after { content: ""; position: absolute; inset: 0; background: var(--magenta); transform: scaleX(0); transform-origin: left; transition: transform .45s var(--ease); }
.rail-progress span.seen::after { transform: scaleX(1); }

/* ---------- From past winners: a gallery wall ---------- */
.winners { display: grid; grid-template-columns: var(--edge) minmax(0, 1fr) auto var(--edge); padding: 24px 0 56px; }
.winners > .rail-head { grid-column: 2; grid-row: 1; display: block; width: auto; margin: 0 0 18px; }
.winners > .rail-controls { grid-column: 3; grid-row: 1; align-self: end; margin: 0 -10px 12px 0; }
.winners > .rail-progress { grid-column: 2 / 4; grid-row: 2; width: auto; margin: 0; }
.winners > .works { grid-column: 1 / -1; grid-row: 3; }
.works { gap: 32px; align-items: flex-start; padding-top: 14px; }
.work { flex: none; scroll-snap-align: start; display: flex; flex-direction: column; }
.work-open { display: block; padding: 0; border: 0; background: none; cursor: zoom-in; }
.work-open:focus-visible { outline: 3px solid var(--magenta); outline-offset: 4px; }
.work img {
  height: clamp(340px, min(46vw, calc(100svh - var(--header) - 280px)), 620px); width: auto; max-width: none;
  background: #fff; box-shadow: 0 1px 0 var(--line), 0 28px 50px -34px rgba(12, 28, 37, .7);
  transition: box-shadow .35s var(--ease), transform .35s var(--ease);
}
@media (hover: hover) {
  .work-open:hover img { transform: translateY(-3px); box-shadow: 0 1px 0 var(--line), 0 36px 60px -30px rgba(12, 28, 37, .8); }
  .work:has(.work-open:hover) .work-title { text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; }
}
.work-caption { display: flex; flex-direction: column; gap: 2px; width: 0; min-width: 100%; margin: 18px 0 0; }
.work-title { font: 650 17px/1.3 var(--sans); }
.work-artist { font: 400 15px/1.4 var(--sans); color: var(--ink-2); }
.work-place { font: 500 14px/1.4 var(--sans); color: var(--ink-3); }

/* ---------- Competition: the paragraph, and an idea beside its painting ---------- */
.competition { padding: var(--section) 0; border-top: 1px solid var(--line-2); }
.competition-grid { display: grid; grid-template-columns: 7fr 5fr; gap: clamp(40px, 6vw, 96px); align-items: start; }
.lead { max-width: 26ch; margin: -.2em 0 clamp(32px, 4vw, 44px); font: 400 clamp(24px, 2.8vw, 40px)/1.26 var(--sans); letter-spacing: -.014em; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px; }
.idea { margin: 0; justify-self: end; width: min(100%, 360px); }
.idea .detail-open { margin-bottom: 20px; box-shadow: 0 28px 50px -34px rgba(12, 28, 37, .7); }
/* a detail of a winning work; it opens the whole painting in the viewer */
.detail-open { display: block; width: 100%; padding: 0; border: 0; background: var(--canvas); cursor: zoom-in; overflow: hidden; }
.detail-open img { width: 100%; height: auto; transition: transform .7s var(--ease); }
@media (hover: hover) { .detail-open:hover img { transform: scale(1.035); } }
.idea blockquote { margin: 0 0 14px; }
.idea blockquote p { margin: 0; text-indent: -.42em; font: 450 17px/1.5 var(--sans); color: var(--ink); }
.idea-credit { margin: 0; font: 500 14px/1.4 var(--sans); color: var(--ink-3); }
.idea cite { font-style: italic; }

/* ---------- Inspiration: one saying large on the canvas, then the longer passages one at a time ---------- */
.craft { padding: var(--section) 0; background: var(--canvas); color: var(--paint-white); overflow: hidden; }
.craft h2 { color: var(--cyan); }
.pull-band { margin-bottom: 64px; }
.pull-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
/* the light falling on Nachshon, its top level with the saying's first line */
.pull-picture { justify-self: end; width: min(100%, 440px); margin: calc(15px * 1.3 + clamp(24px, 3vw, 36px)) 0 0; }
/* a close-up from the wider library of entries, with its artist */
.pull-picture figcaption, .criterion-picture figcaption { margin-top: 10px; font: 500 13px/1.35 var(--sans); }
.pull-picture figcaption { color: var(--mist); }
.criterion-picture figcaption { color: var(--ink-3); }
.pull-picture cite, .criterion-picture cite { font-style: italic; }
.pull { margin: 0; }
.pull blockquote { margin: 0 0 28px; }
.pull blockquote p {
  margin: 0; max-width: 21ch; text-indent: -.42em; color: var(--paint-white);
  font: 650 clamp(32px, 4.4vw, 60px)/1.12 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.02em;
}
.pull figcaption, .quote figcaption { display: flex; flex-direction: column; gap: 4px; padding-top: 14px; border-top: 2px solid var(--magenta); }
.pull figcaption { max-width: 30rem; }
.speaker { font: 650 16px/1.35 var(--sans); color: var(--paint-white); }
.occasion { font: 400 15px/1.4 var(--sans); color: var(--mist); }
.source { font: 400 15px/1.4 var(--sans); color: var(--cyan); }
/* the bar is the caption's rule, its arrows at its end; the arrows come after the passages in the tab order */
.craft-rail { display: grid; grid-template-columns: var(--edge) calc((min(var(--measure), 100vw - var(--gutter) * 2) - var(--quote-gap)) / 3) auto minmax(0, 1fr) var(--edge); align-items: center; }
.craft-rail > .rail-progress { grid-column: 2; grid-row: 1; margin: 0; }
.craft-rail > .rail-controls { grid-column: 3; grid-row: 1; margin: 0 0 0 10px; }
.craft-rail > .reel { grid-column: 1 / -1; grid-row: 2; margin-top: 18px; }
/* one passage per stop; the gap is wider than the margin by more than a hanging quotation mark, so nothing of the
   next or the last passage shows at the edges */
.craft .reel { gap: calc(var(--edge) + 20px); padding-bottom: 0; align-items: flex-start; overflow-y: hidden; transition: height .35s var(--ease); }
.quote { flex: 0 0 min(var(--measure), 100vw - var(--gutter) * 2); scroll-snap-align: start; }
.quote figure { margin: 0; display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: var(--quote-gap); align-items: start; }
.quote figcaption { grid-column: 1; grid-row: 1; padding-top: 0; border-top: 0; }
.quote blockquote { grid-column: 2; grid-row: 1; margin: 0; }
.quote blockquote p { margin: 0 0 .7em; max-width: 58ch; font: 400 clamp(18px, 1.6vw, 21px)/1.6 var(--sans); color: #e4e9ec; }
.quote blockquote p:first-child { text-indent: -.42em; }
.quote blockquote p:last-child { margin-bottom: 0; }
.quote-medium blockquote p { font-size: clamp(22px, 2.3vw, 30px); line-height: 1.4; color: var(--paint-white); }

/* ---------- Judges ---------- */
.judges { padding: var(--section) 0; }
.judge-groups { display: grid; grid-template-columns: 2fr 1fr; gap: clamp(40px, 6vw, 96px); }
.judge-group h3 { padding-top: 14px; margin-bottom: 28px; border-top: 1px solid var(--line-2); }
.judge-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 40px clamp(28px, 4vw, 56px); }
.judge-group-art .judge-list { grid-template-columns: 1fr 1fr; }
.judge p { margin: 0; max-width: 36ch; color: var(--ink-2); font-size: 17px; line-height: 1.55; }
/* the name runs into its sentence, in bold, so each judge is one full sentence */
/* the name is the head of its own sentence, large enough to find at a glance */
.judge strong { color: var(--ink); font: 700 24px/1.1 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.012em; }
.judge cite { font-style: italic; }

/* ---------- Details: the theme on the paint, the brief, the criteria, the rules, then the exhibition ---------- */
.details { padding: 0; }
.theme-band {
  position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end;
  min-height: clamp(300px, 26vw, 380px); padding: 72px 0 calc(var(--fringe) + 12px); margin-bottom: var(--section);
  background: linear-gradient(90deg, rgba(12, 28, 37, .55) 0%, rgba(12, 28, 37, .18) 50%, rgba(12, 28, 37, 0) 75%), url("assets/brand-paint-band.jpg") 50% 45% / cover;
}
.theme { position: relative; z-index: 1; }
.closing-band { -webkit-mask-position: -1500px 0, 0 calc(var(--fringe) - 1px), -2300px 100%; mask-position: -1500px 0, 0 calc(var(--fringe) - 1px), -2300px 100%; }
.theme-label { margin: 0 0 10px; color: var(--cyan); text-shadow: 0 1px 12px rgba(12, 28, 37, .5); }
.theme-word { margin: 0; color: #fff; font: 760 clamp(72px, 10vw, 144px)/.9 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.035em; text-shadow: 0 2px 30px rgba(12, 28, 37, .4); }
.brief { margin: 0 0 clamp(56px, 6vw, 80px); display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(32px, 5vw, 72px); }
.fact { display: grid; grid-template-columns: 9.5rem 1fr; gap: 16px; align-items: baseline; padding: 18px 0; border-top: 1px solid var(--line); }
.fact dt { font: 650 20px/1.25 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.01em; }
.fact dd { margin: 0; color: var(--ink-2); font-size: 17px; line-height: 1.5; }
.keep { white-space: nowrap; }
.criteria-block { margin-bottom: clamp(40px, 5vw, 64px); }
.criteria-block h3 { margin-bottom: 18px; }
/* each criterion a row: the word large, its one line, and a winning work that shows it */
.criteria { list-style: none; margin: 0; padding: 0; }
.criteria li { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 4fr) 220px; gap: clamp(24px, 4vw, 56px); align-items: center; padding: 20px 0; border-top: 1px solid var(--line); }
.criteria li:last-child { border-bottom: 1px solid var(--line); }
.criterion-picture { grid-column: 3; grid-row: 1; margin: 0; }
.criteria strong { grid-column: 1; grid-row: 1; color: var(--ink); font: 760 clamp(28px, 2.8vw, 36px)/1.05 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.03em; }
.criterion-line { grid-column: 2; grid-row: 1; color: var(--ink-2); font-size: 18px; line-height: 1.5; }
.exhibition-band { margin-top: var(--section); padding: clamp(56px, 6vw, 88px) 0; background: var(--canvas); color: var(--paint-white); }
.exhibition { display: grid; grid-template-columns: 1fr 1fr; gap: 0 clamp(32px, 5vw, 72px); align-items: end; }
.exhibition h3 { grid-column: 1 / -1; margin: 0 0 12px; color: var(--cyan); }
/* the two galleries by their own marks, in white, sized to the same optical weight */
.exhibition .galleries { display: flex; flex-direction: column; align-items: flex-start; gap: 18px; margin: 0; }
.galleries img { display: block; width: auto; max-width: 100%; }
.gallery-betzalel { height: clamp(80px, 8vw, 112px); }
.gallery-maor { height: clamp(16px, 1.6vw, 22px); }
.exhibition-note { margin: 0 0 .3em; max-width: 40ch; color: var(--mist); font-size: 18px; line-height: 1.5; }
/* the dates, once they are set: three stops under the galleries */
.timeline[hidden] { display: none; }
.timeline { grid-column: 1 / -1; list-style: none; margin: 36px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); }
.timeline li { position: relative; padding: 26px 12px 0 0; font: 600 16px/1.3 var(--sans); color: var(--paint-white); }
.timeline li::before { content: ""; position: absolute; z-index: 1; top: 0; left: 0; width: 12px; height: 12px; border: 2px solid var(--cyan); border-radius: 50%; background: var(--canvas); box-sizing: border-box; }
.timeline li::after { content: ""; position: absolute; top: 5px; left: 0; right: 0; height: 2px; background: rgba(240, 240, 240, .22); }
.timeline li:last-child::after { display: none; }
.rules { margin-top: clamp(32px, 4vw, 48px); border-top: 1px solid var(--line); }
.rules summary { display: flex; align-items: center; justify-content: space-between; min-height: 64px; cursor: pointer; list-style: none; font: 650 18px/1.3 var(--sans); }
.rules summary::-webkit-details-marker { display: none; }
.rules summary::after { content: ""; width: 12px; height: 12px; margin-right: 6px; border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(45deg) translateY(-4px); transition: transform .3s var(--ease); }
.rules[open] summary::after { transform: rotate(-135deg) translateY(-2px); }
.rule-list { margin: 0 0 8px; }
.rule { display: grid; grid-template-columns: 200px 1fr; gap: 8px 32px; align-items: baseline; padding: 20px 0; border-top: 1px solid var(--line); }
.rule dt { font: 650 16px/1.6 var(--sans); }
.rule dd { margin: 0; max-width: 62ch; color: var(--ink-2); font-size: 16px; line-height: 1.6; }
.rule dd p { margin: 0; }

/* ---------- In their words ---------- */
.words { padding: var(--section) 0; }
.words-head { margin-bottom: clamp(28px, 3.4vw, 44px); }
.words-head h2 { margin: 0; }
.testimonials { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 0 clamp(32px, 4vw, 56px); }
.testimonial { grid-column: span 2; }
.testimonial:nth-child(2), .testimonial:nth-child(3) { grid-column: span 3; }
.testimonial-lead { grid-column: 1 / -1; padding: 0 0 clamp(32px, 4vw, 48px); border-top: 0; }
.testimonial { display: flex; flex-direction: column; justify-content: space-between; gap: 20px; padding: 28px 0; border-top: 1px solid var(--line); }
.testimonial blockquote { margin: 0; }
.testimonial blockquote p { margin: 0; font: 450 19px/1.45 var(--sans); letter-spacing: -.005em; text-indent: -.42em; }
/* all six in one grid; the first a little larger */
.testimonial-lead blockquote p { max-width: 34ch; font: 600 clamp(26px, 2.8vw, 36px)/1.24 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.016em; }
.who { margin: 0; display: flex; flex-direction: column; gap: 2px; }
.name { font: 650 16px/1.3 var(--sans); }
.place { font: 400 15px/1.3 var(--sans); color: var(--ink-3); }

/* ---------- Footer: the last word on the paint, then the credits ---------- */
.site-footer { background: linear-gradient(var(--ground) 0 var(--fringe), var(--canvas) var(--fringe)); color: var(--paint-white); padding-bottom: calc(clamp(40px, 5vw, 64px) + env(safe-area-inset-bottom)); }
.closing-band {
  padding: calc(clamp(96px, 12vw, 176px) + 16px) 0; margin-bottom: clamp(32px, 4vw, 56px);
  background: linear-gradient(90deg, rgba(12, 28, 37, .42) 0%, rgba(12, 28, 37, .1) 50%, rgba(12, 28, 37, 0) 72%), var(--paint) 50% 40% / cover;
}
.closing { display: flex; flex-wrap: wrap; align-items: last baseline; justify-content: space-between; gap: 32px; }
.closing-line { margin: 0; font: 760 clamp(52px, 9vw, 128px)/.96 var(--sans); font-variation-settings: "opsz" 32; letter-spacing: -.03em; color: var(--paint-white); text-shadow: 0 2px 30px rgba(12, 28, 37, .45); }
.footer-inner { display: grid; grid-template-columns: minmax(180px, 260px) 1fr; gap: clamp(32px, 6vw, 96px); align-items: start; }
.footer-lockup { width: 100%; height: auto; }
.footer-line { margin: 0 0 12px; max-width: 52ch; color: var(--mist); font-size: 15px; }
.footer-contact { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0 28px; }
.footer-contact a { display: inline-flex; align-items: center; min-height: 44px; color: var(--cyan); text-decoration: none; font-weight: 500; }
.footer-contact a:hover { text-decoration: underline; text-underline-offset: 4px; }
.footer-contact a:focus-visible { outline-color: var(--cyan); }

/* ---------- The brush: over the paint a fine pointer becomes a flat brush head in the colour it carries ---------- */
.closing-band { position: relative; isolation: isolate; overflow: hidden; }
.closing { position: relative; z-index: 1; }
.brush-canvas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; transition: opacity 1.6s var(--ease); }
.brush-canvas.drying { opacity: 0; }
.brush-tip {
  position: absolute; z-index: 2; top: 0; left: 0; width: 24px; height: 7px; border: 1px solid currentColor; border-radius: 4px;
  pointer-events: none; box-shadow: 0 0 0 1px rgba(12, 28, 37, .25); opacity: 0; transition: opacity .2s;
}
.brush-tip.shown { opacity: .8; }
.brushing { cursor: none; }

/* ---------- The viewer: the work whole; Close at the top; the caption and steps beneath ---------- */
.viewer { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 0; border: 0; background: var(--canvas); color: var(--paint-white); }
.viewer::backdrop { background: var(--canvas); }
.viewer[open] { display: grid; grid-template-rows: minmax(0, 1fr) auto; height: 100dvh; }
.viewer-close { position: absolute; z-index: 2; top: calc(10px + env(safe-area-inset-top)); right: max(10px, calc(var(--edge) - 10px)); background: rgba(10, 19, 25, .6); }
.viewer-stage { position: relative; min-height: 0; overflow: hidden; touch-action: pinch-zoom; }
.viewer-image {
  position: absolute; inset: clamp(56px, 5vw, 64px) clamp(16px, 3vw, 40px) clamp(16px, 3vw, 40px);
  width: calc(100% - 2 * clamp(16px, 3vw, 40px)); height: calc(100% - clamp(56px, 5vw, 64px) - clamp(16px, 3vw, 40px));
  max-width: none; object-fit: contain;
}
.viewer-bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px var(--edge) calc(16px + env(safe-area-inset-bottom)); border-top: 1px solid rgba(240, 240, 240, .08); }
.viewer-caption { margin: 0; display: flex; flex-direction: column; gap: 2px; font-size: 15px; color: var(--mist); }
.viewer-caption strong { font-weight: 650; color: var(--paint-white); font-size: 17px; }
.viewer-controls { display: flex; align-items: center; gap: 4px; flex: none; margin-right: -10px; }
.viewer-position { display: flex; gap: 7px; margin-right: 14px; }
.viewer.single .viewer-position, .viewer.single [data-viewer] { display: none; }
.viewer-position span { width: 6px; height: 6px; border-radius: 50%; background: rgba(240, 240, 240, .26); transition: background .25s; }
.viewer-position span.current { background: var(--paint-white); }

/* ---------- Narrower screens ---------- */
/* below 1180 the header's Join is one word, so the section links stay clear of the paint's edge */
@media (max-width: 1180px) {
  .header-cta .label-long { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .header-cta .label-short { display: inline; }
}
@media (max-width: 1080px) {
  .site-nav { gap: 20px; }
  .site-nav a { font-size: 14px; }
  .testimonials { grid-template-columns: 1fr 1fr; }
  .testimonial, .testimonial:nth-child(2), .testimonial:nth-child(3) { grid-column: auto; }
  .testimonial-lead, .testimonial:last-child { grid-column: 1 / -1; }
  .criteria li { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 180px; }
}
@media (max-width: 960px) {
  .judge-groups { grid-template-columns: 1fr; }
  .exhibition { grid-template-columns: 1fr; align-items: start; }
  .exhibition .galleries { margin-bottom: 18px; }
  .lead { font-size: 25px; }
  .brief { grid-template-columns: 1fr; }
  .craft-rail { grid-template-columns: var(--edge) minmax(0, 1fr) auto var(--edge); }
  .quote figure { grid-template-columns: 1fr; gap: 24px; }
  .quote figcaption { grid-row: 2; padding-top: 14px; border-top: 2px solid var(--magenta); }
  .quote blockquote { grid-column: 1; }
}
/* tablets in portrait and phones: the image on top, the menu in place of the nav */
@media (max-width: 860px) {
  /* the first screen fills the window: the paint takes whatever the words leave */
  .hero { grid-template-columns: 1fr; grid-template-rows: minmax(300px, 1fr) auto; height: auto; min-height: 100svh; }
  .hero-art { order: -1; height: auto; min-height: 300px; -webkit-mask: none; mask: none; }
  .bh { right: auto; left: 12px; }
  .hero-paint { object-position: 45% 40%; }
  .hero-art .hero-lockup { top: calc(var(--header) + 4px); left: 9%; width: 82%; height: calc(100% - var(--header) - var(--fringe) - 8px); }
  .hero-text { padding: 26px var(--gutter) 30px; }
  .hero h1 { font-size: clamp(30px, 7.6vw, 64px); margin-bottom: 22px; }
  .hero-text { padding-top: 10px; }
  .hero-credit { margin-top: 22px; }
  /* the menu in place of the nav; once the headline's button has gone by, the name, Join and the menu */
  .site-nav { display: none; }
  .masthead { margin-right: auto; }
  .menu-button { display: grid; margin-left: 4px; }
  html:not(.scrolled) .menu-button { color: #fff; filter: drop-shadow(0 1px 8px rgba(12, 28, 37, .6)); }
}
@media (max-width: 720px) {
  :root { --header: 60px; }
  .masthead { font-size: 13px; }
  .header-cta .label-long { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .header-cta .label-short { display: inline; }
  .rail-controls { display: none; }
  .winners { padding-top: 28px; }
  .winners > .rail-progress { grid-column: 2 / 4; }
  .works { gap: 18px; }
  .work img { height: min(54svh, 400px, calc(84vw / var(--ratio, .75))); }
  .competition-grid { grid-template-columns: 1fr; }
  .lead { font-size: 22px; }
  .idea { justify-self: stretch; width: 100%; }
  .brief { grid-template-columns: 1fr; gap: 20px; }
  .criteria { grid-template-columns: 1fr; }
  .rule { grid-template-columns: 1fr; gap: 6px; }
  .judge-group-art .judge-list { grid-template-columns: 1fr; }
  .testimonials { grid-template-columns: 1fr; }
  .testimonial-lead blockquote p { font-size: 24px; }
  .judge strong { font-size: 20px; }
  .judge { padding-top: 18px; border-top: 1px solid var(--line); }
  .judge-list { gap: 22px; }
  .fact { grid-template-columns: 7.5rem 1fr; gap: 12px; }
  .fact dt { font-size: 18px; }
  .criteria li { grid-template-columns: minmax(0, 1fr) 112px; gap: 6px 18px; align-items: start; }
  .criteria strong { grid-column: 1; grid-row: 1; font-size: 28px; }
  .criterion-line { grid-column: 1; grid-row: 2; font-size: 16px; }
  .criterion-picture { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
  .criterion-picture figcaption { font-size: 12px; }
  .pull-grid { grid-template-columns: 1fr; gap: 40px; }
  .pull-picture { justify-self: stretch; width: 100%; margin-top: 0; }
  .theme-band { min-height: 200px; }
  .footer-inner { grid-template-columns: 1fr; }
  .footer-lockup { max-width: 220px; }
  .button { width: 100%; }
  .button-small { width: auto; }
  .actions { flex-direction: column; align-items: stretch; gap: 4px; }
  .text-link { justify-content: center; }
  .closing { flex-direction: column; align-items: stretch; }
  .closing-band { background-position: 30% 60%; }
  /* passages on a phone: one per swipe, like reels */
  .quote blockquote p { font-size: 17px; line-height: 1.55; }
  .quote-medium blockquote p { font-size: 21px; line-height: 1.42; }
  .pull blockquote p { font-size: 30px; }
  .speaker { font-size: 15px; }
  .source { font-size: 14px; }
  .theme-word { font-size: 80px; }
  .viewer-bar { flex-direction: column; align-items: stretch; gap: 8px; }
  .viewer-controls { justify-content: flex-end; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal] { opacity: 1; transform: none; }
}
