/*
  Jason Broadbent — events page
  Self-contained, following the consent.html pattern.

  IMPORTANT: token values below come from the SECOND :root in site-v2.css
  (line 1845, "Approved all-light paper direction"), which overrides the dark
  values earlier in that file and in index.html's inline <style>. The site is
  ink-on-paper. Both sets of dark tokens are dead — do not copy them.
*/

:root {
  --ink: #171715;
  --ink-2: #23231f;
  --ink-3: #33312c;
  --paper: #eee9df;
  --paper-cool: #e7e8e5;
  --paper-blue: #e2e9ee;
  --paper-blush: #f0e4df;
  --paper-dim: #5f5a53;
  --paper-faint: #777168;
  --blue: #4252d4;
  --blood: #7b2829;
  --rule: rgba(23, 23, 21, .18);
  --display: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --gut: clamp(1.25rem, 4vw, 4rem);
  --max: 1680px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box }
[hidden] { display: none !important }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  background: var(--paper);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: clamp(15px, .25vw + 14px, 18px);
  line-height: 1.7;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.is-locked { overflow: hidden }

img { max-width: 100%; display: block; height: auto }
a { color: inherit; text-decoration: none }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer }

::selection { background: var(--blue); color: #fff }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px }

h1, h2, h3 {
  font-family: var(--display);
  font-weight: 300;
  line-height: 1.02;
  margin: 0;
  letter-spacing: -.01em;
}

h1 { font-size: clamp(2.6rem, 7vw, 5.4rem) }
h2 { font-size: clamp(2.1rem, 5.2vw, 4.1rem) }
h3 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); line-height: 1.15 }

.wrap { max-width: var(--max); margin-inline: auto; padding-inline: var(--gut) }

.sr-only, .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  left: var(--gut);
  top: .75rem;
  z-index: 1200;
  background: var(--ink);
  color: var(--paper);
  padding: .7rem 1rem;
  font-size: .68rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  transform: translateY(-160%);
  transition: transform .2s;
}

.skip-link:focus { transform: none }

.eyebrow {
  font-size: .66rem;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--paper-faint);
  font-weight: 400;
  margin: 0 0 1.6rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.eyebrow::after { content: ""; flex: 1; height: 1px; background: var(--rule) }

.btn {
  display: inline-block;
  padding: .95rem 2.2rem;
  border: 1px solid currentColor;
  color: var(--ink);
  font-size: .68rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  transition: background .45s var(--ease), color .45s var(--ease), border-color .45s var(--ease);
}

.btn:hover, .btn:focus-visible { background: var(--ink); color: var(--paper); border-color: var(--ink) }
.btn--accent { background: var(--blue); border-color: var(--blue); color: #fff }
.btn--accent:hover, .btn--accent:focus-visible { background: var(--ink); border-color: var(--ink); color: var(--paper) }
.btn--ghost { color: var(--ink) }
.btn--ghost:hover, .btn--ghost:focus-visible { background: transparent; color: var(--blue); border-color: var(--blue) }

/* Gate — same behaviour and key as the homepage's, light treatment */

#gate {
  position: fixed;
  inset: 0;
  z-index: 1000;
  color: var(--ink);
  background:
    radial-gradient(ellipse at 78% 22%, rgba(112, 151, 181, .19), transparent 32%),
    radial-gradient(ellipse at 15% 78%, rgba(123, 40, 41, .08), transparent 27%),
    var(--paper);
  display: grid;
  place-items: center;
  padding: var(--gut);
  transition: opacity .9s var(--ease), visibility .9s;
}

#gate.is-open { opacity: 0; visibility: hidden; pointer-events: none }

.gate-inner { max-width: 44rem; text-align: center; animation: rise 1.1s var(--ease) both }

.gate-mark {
  font-family: var(--display);
  font-size: clamp(2.4rem, 6vw, 4.4rem);
  line-height: 1;
  margin: 0 0 2rem;
  letter-spacing: -.02em;
}

.gate-mark small {
  display: block;
  font-family: var(--body);
  font-size: .6rem;
  letter-spacing: .4em;
  text-transform: uppercase;
  color: #5b564f;
  margin-top: 1.2rem;
}

.gate-copy { color: #5b564f; max-width: 34rem; margin: 0 auto 2.6rem; font-size: .95rem }
.gate-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap }

@keyframes rise { from { opacity: 0; transform: translateY(18px) } to { opacity: 1; transform: none } }

/* Page chrome */

.site-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding: 1.7rem var(--gut) 1.4rem;
  max-width: var(--max);
  margin-inline: auto;
  border-bottom: 1px solid rgba(23, 23, 21, .14);
}

.brand strong { font-weight: 400; font-size: .74rem; letter-spacing: -.01em }
.brand span { color: var(--paper-faint); font-size: .74rem; margin-left: .4rem }

.site-head nav { display: flex; gap: clamp(1.2rem, 3vw, 2.6rem); flex-wrap: wrap }

.site-head nav a {
  font-size: .62rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--paper-dim);
  transition: color .4s;
}

.site-head nav a:hover, .site-head nav a:focus-visible { color: var(--blue) }

/* Hero */

.page-hero {
  /* padding-block, not the `padding` shorthand: the shorthand would zero
     padding-inline and defeat .wrap's gutter on the same element. */
  padding-block: clamp(3.5rem, 10vw, 8rem) clamp(2.5rem, 6vw, 4.5rem);
}

.page-hero .lede {
  font-family: var(--display);
  font-size: clamp(1.35rem, 2.5vw, 2rem);
  line-height: 1.45;
  font-weight: 300;
  max-width: 34ch;
  margin: 1.8rem 0 0;
  color: #413e39;
}

/* Upcoming event */

#upcoming {
  padding-block-end: clamp(3rem, 8vw, 6rem);
}

.event {
  padding-top: clamp(2rem, 5vw, 3.5rem);
  border-top: 1px solid var(--rule);
}

/* The banner is key art carrying the event title, so it runs the full content
   width above the details rather than sitting in a column beside them. No
   forced aspect-ratio and no object-fit: cover anywhere on this page — the
   width/height attributes on the <img> reserve the right box while it loads,
   and cropping the artwork to fit a layout is not a decision this page gets to
   make. */

.event__banner img {
  width: 100%;
  max-width: 1536px;   /* the artwork's native width — never upscale it */
  height: auto;
  background: #f4f0e8;
  box-shadow: 0 1.5rem 4rem rgba(54, 48, 39, .14);
}

.event > h2 {
  margin: clamp(2rem, 4vw, 3.2rem) 0 clamp(1.5rem, 3vw, 2.4rem);
  line-height: .95;
  letter-spacing: -.035em;
}

.event__cols {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 7fr);
  gap: clamp(1.5rem, 4vw, 4rem);
  align-items: start;
  border-top: 1px solid rgba(23, 23, 21, .35);
  padding-top: clamp(1.5rem, 3vw, 2.5rem);
}

.event__meta p {
  margin: 0 0 1.2rem;
  font-size: .95rem;
  line-height: 1.5;
}

.event__meta .label {
  display: block;
  font-size: .58rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--blue);
  margin-bottom: .4rem;
}

.event__body p { max-width: 62ch; color: #413e39; margin: 0 0 1.35em }
.event__body p.italic { font-style: italic; color: var(--ink); font-family: var(--display); font-size: 1.2em; line-height: 1.4 }

.event__detail {
  border-left: 2px solid var(--blue);
  background: rgba(246, 243, 236, .75);
  padding: 1.1rem 1.4rem;
  margin: 2.2rem 0;
}

.event__detail h3 { font-size: 1.15rem; margin-bottom: .5rem }
.event__detail p { font-size: .92rem; margin-bottom: 0 }

.event__actions { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 2.6rem }

/* Past events */

#past {
  padding-block: clamp(3rem, 8vw, 6rem);
  background: var(--paper-blush);
}

.event--past {
  display: block;
  border-bottom: 1px solid var(--rule);
  padding: 1.6rem 0;
}

.event--past h3 { font-size: 1.4rem; margin-bottom: .4rem }
.event--past p, .event--past time { color: var(--paper-dim); font-size: .9rem }
.event--past p { margin: 0 0 .2rem }

/* Footer */

.page-foot {
  border-top: 1px solid var(--rule);
  padding: clamp(3rem, 7vw, 5.5rem) var(--gut) 3rem;
  max-width: var(--max);
  margin-inline: auto;
}

.page-foot .foot-name {
  font-family: var(--display);
  font-size: clamp(3.4rem, 9vw, 8rem);
  line-height: .7;
  letter-spacing: -.06em;
  margin: 0 0 2.5rem;
}

.foot-links { display: flex; gap: clamp(1.2rem, 3vw, 2.6rem); flex-wrap: wrap; margin-bottom: 2rem }

.foot-links a {
  font-size: .64rem;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--paper-dim);
  transition: color .4s;
}

.foot-links a:hover, .foot-links a:focus-visible { color: var(--blue) }
.foot-small { font-size: .72rem; color: var(--paper-faint); margin: 0 }

/* Responsive */

@media (max-width: 860px) {
  .event__cols { grid-template-columns: 1fr }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  html { scroll-behavior: auto }
}
