:root {
    --bg: #fafaf8;
    --bg-alt: #f3efea;
    --ink: #1a1714;
    --muted: #6f675f;
    --line: #e4ded6;
    --accent: #e07b39;      /* large type and decoration */
    --accent-ink: #b8551a;  /* buttons and small text: passes contrast on light and dark */
    --card: #fff;
    --gutter: clamp(18px, 5vw, 64px);
    --wrap: 1280px;
    --display: "Unbounded", "Arial Black", "Helvetica Neue", Arial, sans-serif; /* wide, like the poster lettering */
    --sans: "Jost", "Helvetica Neue", Arial, sans-serif;                        /* text that is read, not looked at */
    --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 300 18px/1.65 var(--sans); overflow-wrap: break-word; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3 { margin: 0; font-family: var(--display); font-weight: 500; line-height: 1.1; letter-spacing: -.02em; }
em { font-style: normal; color: var(--accent); }
strong { font-weight: 500; }
:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 3px; }
section { padding: clamp(56px, 8vw, 120px) var(--gutter); max-width: var(--wrap); margin: 0 auto; }

/* small uppercase labels */
.eyebrow, .sec-label { font: 400 12px/1.4 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--accent-ink); margin: 0 0 1.2em; }
.meta { font-size: 15px; font-weight: 400; color: var(--muted); }
.prose p { margin-bottom: .8em; }

/* section heading: ghost number, label, wide title with an accent-coloured tail */
.sec-head { position: relative; margin-bottom: clamp(28px, 4vw, 56px); padding-top: clamp(36px, 5vw, 60px); }
.sec-num { position: absolute; top: 0; left: -.04em; font: 600 clamp(70px, 11vw, 140px)/1 var(--display); color: var(--ink); opacity: .05; pointer-events: none; user-select: none; }
.sec-head h2 { font-size: clamp(24px, 3.7vw, 50px); }
.sec-label { position: relative; margin-bottom: .8em; }

/* buttons */
.btn { display: inline-block; background: var(--accent-ink); color: #fff; border: 1px solid var(--accent-ink); border-radius: 2px; padding: 15px 26px; font: 500 11px/1.2 var(--display); letter-spacing: .1em; text-transform: uppercase; text-decoration: none; cursor: pointer; min-height: 46px; transition: background .25s, color .25s, border-color .25s, transform .25s var(--ease); }
.btn:hover { background: var(--ink); border-color: var(--ink); transform: translateY(-2px); }
.btn-ghost { background: transparent; color: inherit; border-color: currentColor; }
.btn-ghost:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn-dark { background: var(--ink); border-color: var(--ink); }
.btn-small { padding: 12px 18px; min-height: 42px; font-size: 10px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; }
.soon { font-size: 13px; letter-spacing: .06em; color: var(--muted); margin: 0; }

/* header */
.site-header { position: sticky; top: 0; z-index: 50; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px var(--gutter); background: rgba(250, 250, 248, .88); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.brand { text-decoration: none; font: 500 15px/1 var(--display); letter-spacing: .02em; white-space: nowrap; }
.brand img { display: block; height: 32px; width: auto; }
.site-nav { display: none; gap: 28px; font: 400 12px/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; }
.site-nav a { text-decoration: none; padding: 10px 0; position: relative; }
.site-nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 4px; height: 1px; background: var(--accent-ink); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.site-nav a:hover::after { transform: scaleX(1); }
.btn-header { padding: 11px 16px; min-height: 40px; font-size: 10px; white-space: nowrap; }

/* hero: full-bleed photo under a dark veil; the photo drifts with --py (set by motion.js) */
.hero { position: relative; isolation: isolate; overflow: hidden; max-width: none; margin: 0; padding: 0; color: #fff; min-height: calc(100vh - 66px); display: flex; align-items: center; background: #2a2420; }
@supports (min-height: 100svh) { .hero { min-height: calc(100svh - 66px); } }
.hero::before { content: ""; position: absolute; inset: -12% 0; z-index: -2; background: var(--hero-img) center / cover no-repeat; transform: translate3d(0, var(--py, 0px), 0); will-change: transform; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(20, 16, 12, .84) 0%, rgba(20, 16, 12, .5) 60%, rgba(20, 16, 12, .22) 100%); }
.hero-inner { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: clamp(48px, 8vw, 96px) var(--gutter); }
.hero .eyebrow { color: #f0a06b; }
.hero-title { font-size: clamp(28px, 5.7vw, 78px); font-weight: 600; line-height: 1.04; letter-spacing: -.035em; margin-bottom: .5em; }
.hero-title .w { display: inline-block; }
.hero-title em { color: #f0a06b; }
.hero-dates { font: 400 clamp(20px, 2.8vw, 34px)/1.2 var(--display); letter-spacing: -.02em; color: #f0a06b; margin-bottom: .8em; }
.hero-lead { max-width: 30em; font-size: clamp(17px, 2vw, 21px); color: rgba(255, 255, 255, .86); margin-bottom: 2em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 2.4em; }
.hero-meta { font-size: 13px; letter-spacing: .08em; color: rgba(255, 255, 255, .7); margin: 0; }

/* hero entrance: words rise one after another, the rest follows */
@keyframes rise { from { opacity: 0; transform: translateY(.6em); } to { opacity: 1; transform: none; } }
.hero-title .w { animation: rise 1s var(--ease) both; animation-delay: calc(var(--i, 0) * 110ms + 150ms); }
.hero .eyebrow { animation: rise .9s var(--ease) both; animation-delay: 50ms; }
.hero-dates { animation: rise .9s var(--ease) both; animation-delay: 750ms; }
.hero-lead { animation: rise .9s var(--ease) both; animation-delay: 900ms; }
.hero-actions { animation: rise .9s var(--ease) both; animation-delay: 1050ms; }
.hero-meta { animation: rise .9s var(--ease) both; animation-delay: 1200ms; }

/* about: photo left, text right */
.about { max-width: none; padding: 0; display: grid; grid-template-columns: 1fr; background: var(--bg-alt); }
.about-photo { width: 100%; height: 100%; min-height: 320px; max-height: 70vh; object-fit: cover; }
.about-body { padding: clamp(40px, 7vw, 110px) var(--gutter); max-width: 720px; align-self: center; }
.about-body .sec-head { padding-top: clamp(30px, 4vw, 48px); }
.about-body p { font-size: clamp(17px, 1.6vw, 19px); color: #3c362f; }
.facts { list-style: none; display: flex; flex-wrap: wrap; gap: 20px 44px; margin: 36px 0 0; padding: 28px 0 0; border-top: 1px solid #d8d0c6; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.facts span { display: block; font: 500 clamp(28px, 3.2vw, 40px)/1.1 var(--display); letter-spacing: -.02em; color: var(--accent); text-transform: none; }

/* posters: the face of the series. A row of four on desktop, a swipeable rail on phones */
.poster-rail { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 calc(var(--gutter) * -1); padding: 4px var(--gutter) 16px; scrollbar-width: thin; }
.poster-card { flex: 0 0 min(76%, 320px); scroll-snap-align: start; display: flex; flex-direction: column; gap: 16px; scroll-margin-top: 80px; }
.poster-btn { display: block; width: 100%; padding: 0; border: 0; background: #2a2420; cursor: zoom-in; overflow: hidden; box-shadow: 0 1px 0 rgba(26, 23, 20, .06); transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.poster-btn .poster { width: 100%; aspect-ratio: 5 / 7; object-fit: cover; transition: transform .8s var(--ease); }
.poster-card:hover .poster-btn { transform: translateY(-6px); box-shadow: 0 22px 40px -18px rgba(26, 23, 20, .45); }
.poster-card:hover .poster { transform: scale(1.04); }
.poster-caption { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.poster-date { font: 500 clamp(24px, 2.6vw, 32px)/1 var(--display); letter-spacing: -.03em; color: var(--accent); margin: 0; }
.poster-who { font: 400 13px/1.4 var(--sans); letter-spacing: .14em; text-transform: uppercase; margin: 0 0 12px; }

/* program: ruled list */
.program-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.program-item { display: grid; grid-template-columns: 1fr; gap: 12px; padding: 30px 0; border-bottom: 1px solid var(--line); }
.program-date { font: 500 clamp(30px, 3.6vw, 46px)/1 var(--display); letter-spacing: -.04em; color: var(--accent); white-space: nowrap; }
.program-main h3 { font-size: clamp(17px, 1.9vw, 25px); font-weight: 400; line-height: 1.25; margin-bottom: .5em; }
.program-main .eyebrow { margin-bottom: .6em; }
.program-main summary { cursor: pointer; font: 400 12px/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; padding: 10px 0; }
.program-main summary:hover { color: var(--accent-ink); }
.program-main .prose { padding-top: 8px; max-width: 46em; }
.schedule { list-style: none; padding: 0 0 0 16px; margin: 0 0 1em; border-left: 2px solid var(--accent); font-weight: 400; }
.program-cta { align-self: start; }

/* gallery mosaic: edge to edge */
.last-year { max-width: none; padding: clamp(56px, 8vw, 120px) 0 0; }
.last-year-head { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.mosaic { display: grid; grid-template-columns: repeat(2, 1fr); grid-auto-rows: 44vw; gap: 2px; grid-auto-flow: dense; }
.tile { position: relative; padding: 0; border: 0; background: #2a2420; cursor: zoom-in; overflow: hidden; display: block; }
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.tile::after { content: ""; position: absolute; inset: 0; background: rgba(26, 23, 20, 0); transition: background .3s; }
.tile:hover img { transform: scale(1.05); }
.tile:hover::after { background: rgba(26, 23, 20, .18); }
.tile:first-child { grid-column: span 2; }
.tile:last-child { grid-column-end: -1; }

/* viewer (photos and posters) */
.lightbox { border: 0; padding: 0; width: 100vw; max-width: none; height: 100vh; height: 100dvh; max-height: none; background: rgba(12, 10, 8, .96); color: #fff; }
.lightbox[open] { display: flex; align-items: center; justify-content: center; animation: fade .3s ease both; }
.lightbox::backdrop { background: rgba(12, 10, 8, .96); }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.lb-img { max-width: calc(100vw - 24px); max-height: calc(100dvh - 90px); width: auto; height: auto; object-fit: contain; }
.lb-btn { position: absolute; width: 52px; height: 52px; border: 1px solid rgba(255, 255, 255, .4); border-radius: 50%; background: rgba(12, 10, 8, .5); color: #fff; font-size: 24px; line-height: 1; cursor: pointer; transition: background .2s, color .2s; }
.lb-btn:hover { background: #fff; color: var(--ink); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 12px; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: 18px; left: 0; right: 0; text-align: center; font: 400 12px/1 var(--sans); letter-spacing: .22em; color: rgba(255, 255, 255, .7); margin: 0; }

/* residents */
.lead { font-size: clamp(18px, 2vw, 22px); max-width: 44em; color: #3c362f; }
.resident-grid { display: grid; gap: 20px; grid-template-columns: 1fr; margin-top: 32px; }
.resident-card { background: var(--card); border: 1px solid var(--line); padding: 28px; display: flex; flex-direction: column; gap: 6px; transition: transform .4s var(--ease), box-shadow .4s var(--ease); }
.resident-card:hover { transform: translateY(-4px); box-shadow: 0 18px 32px -20px rgba(26, 23, 20, .4); }
.resident-logo-box { height: 84px; display: flex; align-items: center; margin-bottom: 8px; }
.resident-logo { max-height: 84px; width: auto; max-width: 70%; object-fit: contain; }
.resident-card h3 { font: 400 12px/1.4 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.offer { font: 500 clamp(18px, 2vw, 22px)/1.25 var(--display); letter-spacing: -.02em; color: var(--accent-ink); margin: 6px 0 0; }
.resident-card .link { margin-top: auto; padding-top: 10px; font: 400 12px/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; }

/* partners, contacts, footer */
.partners { text-align: center; }
.partners .sec-head { text-align: center; }
.partner-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 24px 64px; justify-content: center; align-items: center; }
.partner-logo { max-height: 56px; width: auto; }
.partner-name { font: 500 clamp(20px, 3vw, 32px)/1 var(--display); letter-spacing: -.02em; text-transform: uppercase; color: #3c362f; }
.contacts-grid { display: grid; gap: 24px; grid-template-columns: 1fr; }
.socials { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 22px; font: 400 12px/1.4 var(--sans); letter-spacing: .2em; text-transform: uppercase; }
.legal { font-size: 13px; color: var(--muted); }
.site-footer { text-align: center; font-size: 12px; letter-spacing: .12em; color: var(--muted); padding: 32px var(--gutter) 44px; border-top: 1px solid var(--line); }

/* registration dialog */
.modal { border: 0; border-radius: 2px; padding: 0; width: min(520px, calc(100vw - 24px)); max-height: calc(100dvh - 24px); background: var(--bg); color: var(--ink); }
.modal[open] { animation: rise .4s var(--ease) both; }
.modal::backdrop { background: rgba(26, 23, 20, .62); }
.reg-form, .reg-done { padding: clamp(24px, 5vw, 40px); position: relative; }
.modal-close { position: absolute; top: 8px; right: 8px; width: 44px; height: 44px; border: 0; background: transparent; font-size: 30px; line-height: 1; cursor: pointer; }
.modal-title { font-size: clamp(20px, 4vw, 26px); line-height: 1.2; margin-bottom: .5em; padding-right: 36px; }
.field { display: block; font: 400 12px/1.4 var(--sans); letter-spacing: .14em; text-transform: uppercase; margin-bottom: 16px; }
.field input { display: block; width: 100%; margin-top: 6px; padding: 13px 14px; font: 300 17px var(--sans); letter-spacing: 0; text-transform: none; border: 1px solid #cfc7bd; border-radius: 2px; background: #fff; }
.field input:focus { border-color: var(--accent-ink); outline: 0; box-shadow: 0 0 0 1px var(--accent-ink); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; margin: 4px 0; }
.check input { margin-top: 4px; width: 20px; height: 20px; flex: none; accent-color: var(--accent-ink); }
.err { display: block; color: #b32d2e; font-size: 13px; font-weight: 400; margin-top: 4px; letter-spacing: 0; text-transform: none; }
.err:empty { display: none; }
.form-err { margin: 10px 0; }
.reg-form .btn { margin-top: 14px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* scroll reveal: blocks fade up as they enter the screen (motion.js adds .is-in; --i staggers siblings) */
.js .reveal { opacity: 0; transform: translateY(32px); transition: opacity .9s var(--ease), transform .9s var(--ease); transition-delay: calc(var(--i, 0) * 90ms); }
.js .reveal.is-in { opacity: 1; transform: none; }
.reveal-fallback .reveal { opacity: 1 !important; transform: none !important; }

@media (min-width: 760px) {
    .program-item { grid-template-columns: 210px 1fr auto; gap: 32px; align-items: start; }
    .resident-grid { grid-template-columns: repeat(2, 1fr); }
    .contacts-grid { grid-template-columns: repeat(3, 1fr); }
    .mosaic { grid-template-columns: repeat(6, 1fr); grid-auto-rows: 17vw; }
    .tile:first-child { grid-column: span 3; grid-row: span 2; }
    .tile:nth-child(5n + 1) { grid-column: span 3; grid-row: span 2; }
    .tile:nth-child(5n + 2), .tile:nth-child(5n + 3) { grid-column: span 3; grid-row: span 1; }
    .tile:nth-child(5n + 4) { grid-column: span 2; grid-row: span 1; }
    .tile:nth-child(5n + 5) { grid-column: span 4; grid-row: span 1; }
    .tile:last-child { grid-column-end: -1; }
}
@media (min-width: 900px) {
    .site-nav { display: flex; }
    .about { grid-template-columns: 1fr 1fr; }
    .about-photo { max-height: none; min-height: 640px; }
}
@media (min-width: 960px) {
    .poster-rail { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 24px; overflow: visible; margin: 0; padding: 0; }
    .poster-card { flex: none; }
}
@media (min-width: 1100px) {
    .resident-grid { grid-template-columns: repeat(3, 1fr); }
}

/* people who asked their system for less motion get a static page */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .js .reveal { opacity: 1; transform: none; }
    .hero::before { transform: none; }
}

/* ordinary pages (privacy policy) and consent link */
.legal-page { max-width: 760px; margin: 0 auto; padding: clamp(40px, 6vw, 88px) var(--gutter) clamp(56px, 8vw, 110px); }
.legal-page .eyebrow a { text-decoration: none; }
.legal-page h1 { font-size: clamp(24px, 3.4vw, 40px); margin-bottom: 1em; }
.legal-body h2 { font-size: clamp(17px, 1.8vw, 22px); font-weight: 500; margin: 2em 0 .6em; }
.legal-body p, .legal-body li { font-size: 17px; color: #3c362f; }
.legal-body ul { padding-left: 1.2em; }
.site-footer a, .check a { text-decoration: underline; text-underline-offset: 3px; }
.check a { color: var(--accent-ink); }
.check span { line-height: 1.5; }
